David Chisnall
8809f0122e
Fix memory corruption with weak references.
...
When removing a WeakRef from the map, we use its obj field to find the
key, but the obj field has already been zeroed by this point and so we
end up leaving dangling pointers in the map.
7 years ago
David Chisnall
336d8a828c
Fix test failure.
...
This bug is also present in the original version:
When removing a WeakRef from the map, we use its obj field to find the
key, but the obj field has already been zeroed by this point and so we
end up leaving dangling pointers in the map.
7 years ago
David Chisnall
066a4e65a9
Another go at fixing Cirrus...
7 years ago
David Chisnall
af55c29007
Fix the build on Windows.
7 years ago
David Chisnall
a04d0e8547
Attempt to make submodules work with cirrus.
7 years ago
David Chisnall
824135cc54
Tell Azure CI to get submodules.
7 years ago
David Chisnall
de9f74015f
Fix warning.
7 years ago
David Chisnall
3f38f691af
Rework ARC code as C++.
...
Move the weak references hash table to use a well-tested third-party
implementation instead of the hand-rolled version.
7 years ago
David Chisnall
e1c10af124
Merge pull request #113 from triplef/fix-android-cxx-runtime-check
...
Pass on Android toolchain flags for CXX runtime check.
7 years ago
Frederik Seiffert
61eee9e0a2
Pass on Android toolchain flags for CXX runtime check.
7 years ago
David Chisnall
8560a65f21
Add a missing `extern "C"` to slot.h.
...
Fixes #117
7 years ago
David Chisnall
e6e86d309b
Merge pull request #116 from jordo/cpp-compile-fix
...
_Bool fix for cpp compilation
7 years ago
Jordan Schidlowsky
6e3c618b82
cleanup in blocks runtime for closer consistency with apple
7 years ago
David Chisnall
414e0baa0e
Add Control Flow Guard checks on Windows.
7 years ago
Frederik Seiffert
5308d21c1e
Use const pointers for associated object keys.
...
Matches Apple platform implementations.
7 years ago
Jordan Schidlowsky
a1a3b7a4db
cleanup cpp and c defines
7 years ago
Jordan Schidlowsky
72b1f9d1fa
_Bool fix for cpp compilation
7 years ago
Frederik Seiffert
d16faeded9
Fixed warning in imp_implementationWithBlock.
...
This was caused by switching the method signature to use "id" for the block parameter.
7 years ago
David Chisnall
375018a933
Fix upgrading legacy properties with qualifiers.
...
This fixes PropertyIntrospectionTest2_arc with the 1.x ABI and enables
the test that was disabled in this mode.
7 years ago
Frederik Seiffert
5aa82d059a
Disabled atomic property tests on legacy ABI versions.
7 years ago
Frederik Seiffert
09fdceaa7d
Fixed property_copyAttributeList skipping logic
...
Was incrementing the index twice and thereby possibly skipping over the string end with undefined results.
7 years ago
Frederik Seiffert
fb32780698
Extended property introspection test with atomic-type property.
7 years ago
Frederik Seiffert
5917514ac1
Added test for atomic ivars.
7 years ago
Frederik Seiffert
ae6a777742
Add support for atomic type qualifiers.
...
Fixes #101 .
7 years ago
Frederik Seiffert
a2463192d0
Use `id` as type for block runtime functions.
...
Fixes #103 .
7 years ago
David Chisnall
1ab65ca818
Replace incorrect magic number with sensible number.
7 years ago
David Chisnall
945bbd760d
Mark some tests as big.
...
Setting these tests to use 3 processors is weird, but it means that in
CI (where we do 4 tests in parallel), we won't ever run more than one of
these at a time (though we can run any other one test at the same time
as these). This should fix the intermittent failure.
7 years ago
David Chisnall
c4cb965033
Add more assertions to ManyManySelectors test.
...
This is intermittently failing in CI. It looks as if the CI machine is
running out of memory in a way that we are not gracefully handling.
7 years ago
David Chisnall
e5eaeae9ac
Update ANNOUNCE.
7 years ago
David Chisnall
9d790b4118
Fix long vs size_t error on Windows.
...
On win64, long is 32 bits, not 64 bits as it is everywhere else.
7 years ago
David Chisnall
d4438095ed
Add note to ANNOUNCE about WinObjC.
7 years ago
David Chisnall
ed1de9e9f6
Explain the badges.
7 years ago
David Chisnall
54f7840d92
Add badge for FreeBSD CI.
7 years ago
David Chisnall
893417c7c9
Bump clang to 8.0 - some tests fail with 6.
7 years ago
David Chisnall
405b745a17
Initial attempt at FreeBSD CI.
7 years ago
David Chisnall
f0d7fd4165
Optimise some ARC functions a little bit.
...
The calls to objc_storeWeak were not being inlined, so we were not
benefiting from optimisations based on the invariants.
7 years ago
David Chisnall
722a2c3b0d
Fix some weak pointer bugs.
...
These most likely led to some intermittent failures in weak references.
The `objc_moveWeak` and `objc_copyWeak` functions were assuming that the
target may contain valid data, but the spec for these says that it may
be uninitialised data. We were reading uninitialised data and then
seeing if it happened to be a valid object. Most of the time it was
likely to be nil, so this wasn't an easily reproduceable problem...
I believe this is the correct fix for PR #95 .
Fixes #95
7 years ago
David Chisnall
369c84db35
Fix compiler warnings.
7 years ago
David Chisnall
50493c38d7
Don't use pthread storage for exceptions.
...
If an exception unwinds to the top of a thread, the process will die, so
don't worry about leaking memory for this case.
7 years ago
David Chisnall
00ce6fe46f
Make CI work with 32-bit and 64-bit Windows
7 years ago
David Chisnall
2b9b868cf7
Remove inline from isSelRegistered.
...
It seems to not be exported in the Windows release configuration.
7 years ago
David Chisnall
318ae27d8b
Allow attempting to load a module twice.
...
This is necessary because FreeBSD/ARM and possibly other platforms use
.init_array and not .ctors, so never call the init functions. As a
result, we will need the compiler to move to putting the load function
in .init_array and may end up with it being called by both variants.
7 years ago
Li Keqing
6eb1e51a49
_CYGWIN is not defined internally in cygwin but __CYGWIN__
7 years ago
Li Keqing
e9e8bd3997
__CYGWIN32__ to _CYGWIN
7 years ago
Li Keqing
a48030b12e
Fix some link-stage errors when compiling with Cygwin
7 years ago
David Chisnall
2e6528e82b
Fix accidentally inverted preprocessor directive.
7 years ago
David Chisnall
f05f3f73b3
Revert C++ exception structure changes.
...
The C++ runtime library passes pointers to the middle of the structure,
so we need to ignore the fields that were previously missing.
7 years ago
David Chisnall
acf44d64cb
Fix invalid preprocessor directives.
7 years ago
David Chisnall
6cb6d15dfe
Fix unwind info in objc_msgSend.arm.S
...
We were failing to properly indicate the locations of the spilled
floating-point (vector) registers.
7 years ago
David Chisnall
088977679e
DWARF EH cleanups.
...
Update the C++ ABI for the C++11 ABI and fix the missing ARM-specific
bits. Work around a bug in ARM.
7 years ago