| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ref: https://github.com/ffi/ffi/pull/991
Write barrier protected objects are allowed to be promoted to the old generation,
which means they only get marked on major GC.
The downside is that the RB_BJ_WRITE macro MUST be used to set references,
otherwise the referenced object may be garbaged collected.
This commit also implement a `dsize` function so that these instance report
a more relevant size in various memory profilers. It's not counting everything
because some types are opaque right now, so a larger refactoring would be needed.
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
And FFI::DynamicLibrary::Symbol
Ref: https://github.com/ffi/ffi/pull/991
Write barrier protected objects are allowed to be promoted to the old generation,
which means they only get marked on major GC.
The downside is that the RB_BJ_WRITE macro MUST be used to set references,
otherwise the referenced object may be garbaged collected.
This commit also implement a `dsize` function so that these instance report
a more relevant size in various memory profilers. It's not counting everything
because some types are opaque right now, so a larger refactoring would be needed.
While I was at it, I moved `Symbol.library` into the unused `Symbol.base.rbParent`
which seemed appropriate and saves a pointer.
|
|/ |
|
|
|
|
|
|
|
| |
Ref: ffi#991
The old untyped DATA API is soft deprecated and
this new one open the door to write barriers, compaction, memsize etc.
|
|
|
|
|
|
|
| |
Ref: https://github.com/ffi/ffi/pull/991
The old untyped DATA API is soft deprecated and
this new one open the door to write barriers, compaction, memsize etc.
|
|
|
|
|
|
|
|
| |
Only very old Visual-C compilers before 2010 didn't contain these files.
Since the copyright of the included files conflicts with ffi's license,
we better remove it.
Fixes #693
|
|
|
|
|
|
|
|
|
|
| |
Ruby 2.7 deprecates taint and it no longer has an effect.
https://bugs.ruby-lang.org/issues/16131
The APIs related to taint cause deprecation warning message and the lack
of taint support should not cause a problem in previous Ruby versions.
So I removed that. But if need to taint support that to old versions
of Ruby, I will update PR.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
According to [1] the flag LOAD_WITH_ALTERED_SEARCH_PATH
should be used with absolute paths only. It has the effect,
that the path of the DLL to be loaded is temporary added
to the search path, so that dependent DLLs in the same
directory can be found and loaded implicit.
However for relative paths the standard LoadLibrary()
search order should be used, because the behaviour of
LOAD_WITH_ALTERED_SEARCH_PATH isn't defined for relative
paths. In practice (on Windows 10) relative paths to
Windows system DLLs do work, so that the library is loaded,
but DLLs in other search paths are not found, when this
flag is set.
Ruby's fiddle library uses LoadLibrary without flags in
both cases.
[1]
https://msdn.microsoft.com/en-us/library/windows/desktop/ms684179(v=vs.85).aspx
|
| |
|
| |
|
| |
|
|
|
|
| |
Signed-off-by: Wayne Meissner <wmeissner@gmail.com>
|
|
|
|
| |
Signed-off-by: Wayne Meissner <wmeissner@gmail.com>
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
and ConstGenerator.
|
|
|
|
| |
Library, Platform and FFI class methods from types.rb.
|
|
|
|
| |
redefiniction errors.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|