This happened to work with clang-9 but is caught in clang-10 now.
We were constructing an iterator temp then pulling a node through it
past the destruction.
Remove the iterator construction entirely and removes the unused lambda
from the AArch64 JIT that had the same problem.
Turns out my Threadripper stomps these tests so the arbitrary wait time
actually slows down my unit test time.
Don't want to make it shorter since `strace -f` becomes ugly at that
point.
Instead set up a semaphore style waiting structure that waits until
there are no longer any participants in the atomic
There were four independent arrays for each size of the RA.
Missed the 16bit and 8bit registers when removing a register.
This removes the redundant arrays and just uses one and transforms the
register to the right size depending on what the JIT wants
Currently RA is shared between threads(!).
If the RA had been previously allocated then don't allocate it again.
Fixes a race condition when multiple threads are spinning up and one is
compiling code
Adds some additional validation that an IR op is generating RA for ops
that set a destination.
Ensuring correct register class and that there is a physical register
assigned
Some of these are just there to get us farther in some cases. They can
result in behaviour the app isn't expecting like when signals are setup
but not handled correctly.
Is fine for the cases that the app doesn't actually use them.
x86's cvtsi2ss can take a 32bit or 64bit input and convert it to a 32bit
float.
This ensures the register passed in is 32bit so it uses the 32bit
instruction
Fixing some bugs in threading required fixing how the futexes operate.
Instead of the terrible condition variables and atomic values just use
the kernel futex facility directly.
This required fixing some of the threading management since otherwise
there was a issue around the weird mixture of our threads using our
"Futex" class and the kernel expecting real futexes on the values.
Just switch everything over and it ends up being cleaner
Fixes random mutex failures that were happening in various applications
This is pretty easy to implement. Kind of flies in the face of why the
instruction implementation exists (icache and frontend issue overhead
savings) but it is easy to implement.
BMI1 would be straightforward to implement, BMI2 would take a bit more
effort because of the PDEP, PEXT, and BZHI instructions.
Bigger problem is that we don't support VEX three operand decoding in
the frontend at all.
Disable these until then