Commit Graph
848 Commits
Author SHA1 Message Date
Stefanos Kornilios Mitsis Poiitidis 63ea0358bd syscalls/x64: Add pselect6 2020-05-31 15:31:16 +03:00
Stefanos Kornilios Mitsis Poiitidis a47f9d48f5 Merge pull request #221 from Sonicadvance1/fix_config_zero_size
Fixes a crash that can occur when the config exists but has nothing
2020-05-31 12:02:55 +03:00
Stefanos Kornilios Mitsis Poiitidis f1173a3bca Merge pull request #218 from Sonicadvance1/implements_lods
Implements LODS instruction
2020-05-31 12:02:11 +03:00
Stefanos Kornilios Mitsis Poiitidis a659024547 Merge pull request #220 from Sonicadvance1/psadbw
Implements psadbw for MMX and SSE2
2020-05-31 12:00:36 +03:00
Stefanos Kornilios Mitsis Poiitidis 3b9204341c Merge pull request #219 from Sonicadvance1/scas_unittests
Implements SCAS unit tests
2020-05-31 11:42:05 +03:00
Stefanos Kornilios Mitsis Poiitidis 5f7b3883f4 Merge pull request #217 from Sonicadvance1/llvm_native_target
Forces LLVM backend to use the native CPU architecture
2020-05-31 11:28:57 +03:00
Ryan Houdek ceab504211 Implements unit tests for psadbw 2020-05-31 03:22:11 +01:00
Ryan Houdek a147e5eca1 Implements psadbw for MMX and SSE2
Saw this when running Freedreno on x86-64
2020-05-31 03:22:11 +01:00
Ryan Houdek 3dae3f4b84 Fixes bug that cropped up in cvtpi2ps from previous changes 2020-05-31 03:22:11 +01:00
Ryan Houdek 2ba797a992 Implements new IR ops in the CPU backends 2020-05-31 03:22:11 +01:00
Ryan Houdek 03b885816e Fixes a crash that can occur when the config exists but has nothing
Common when I'm testing and wiping the config away
2020-05-30 18:56:39 -07:00
Ryan Houdek 1541b29662 Updates vixl to latest master 2020-05-30 18:50:32 -07:00
Ryan Houdek 2f1d7f70a2 Adds new IR ops that PSADBW will need 2020-05-30 18:49:09 -07:00
Ryan Houdek 4db38f389a Implements SCAS unit tests 2020-05-29 23:38:27 -07:00
Ryan Houdek 6cf5c00fe9 Implements LODS unit tests 2020-05-29 23:37:27 -07:00
Ryan Houdek 111b0624ca Implements LODS instruction
Theoretically the REP case can be optimized if it is known not to fault,
but that is one legitimate use case of this instruction.
This is just to ensure that we have this instruction covered, it hasn't
been encountered in a real program yet.
2020-05-29 23:35:36 -07:00
Ryan Houdek c0711404e9 Forces LLVM backend to use the native CPU architecture
Better than relying on a hardcoded CPU target
Should fix a crash on x86 host cpus that don't support BMI1
2020-05-29 17:51:37 -07:00
Ryan Houdek c8b2aefb9a Merge pull request #216 from FEX-Emu/skmp/posix-tests-investigation
Hook up SYSCALL_MSYNC, update passing tests
2020-05-29 13:51:41 -07:00
Stefanos Kornilios Mitsis Poiitidis 6cc3b6b0ea Syscalls/x64: Hook up SYSCALL_MSYNC, remove fixed tests from known failures 2020-05-29 12:43:52 +03:00
Stefanos Kornilios Mitsis Poiitidis 0b3fab9f44 Renable conformance-interfaces-sched_rr_get_interval-1-1 2020-05-29 12:16:08 +03:00
Ryan Houdek e476c92dc6 Merge pull request #214 from Sonicadvance1/x87_rebase
Interpreter based x87 support!
2020-05-28 15:15:39 -07:00
Ryan Houdek 98ed6fb875 Disables test D9_F2
This changes precision depending on if it is running on x86 or AArch64,
so we can't nail down an exact answer
2020-05-28 15:10:19 -07:00
Ryan Houdek 2474ca1437 Adds support for disabled tests in the IR and ASM runners 2020-05-28 15:09:51 -07:00
Ryan Houdek 633e3ddb33 x87 based unit tests! 2020-05-28 14:47:43 -07:00
Ryan Houdek 5efab1eff9 Updates list of known failures for unit tests
x87 implementation has changed these
2020-05-28 14:47:43 -07:00
Ryan Houdek 3759cbdb65 Interpreter based x87 support!
This implements support for 130 of the 132 x87 ops as interpreter
fallbacks.

The two missing ops are the BCD load and BCD store instructions and can
be implemented another time.

This allows us to no longer have to rely on a libstdc++ modification to
handle their usage of long double. This instead works entirely through
using `long double` directly in the interpreter. Which will either use
real x87 on an x86 host. Or in the case of ARM devices, fall down
glibc's long double soft float path.

This doesn't necessarily need to be quick right now. It's more important
to have the compatibility improvement from this.
2020-05-28 14:47:43 -07:00
Ryan Houdek f5273e1505 Merge pull request #215 from FEX-Emu/skmp/unimplemented-syscalls-always-fail
Add ERROR_AND_DIE, use it on unhandled syscalls
2020-05-28 14:20:58 -07:00
Stefanos Kornilios Mitsis Poiitidis 8206aa0413 Add ERROR_AND_DIE, use it on unhandled syscalls 2020-05-28 18:47:24 +03:00
Stefanos Kornilios Mitsis Poiitidis 88c87eb214 Merge pull request #213 from Sonicadvance1/more_syscalls
Implements three more syscalls
2020-05-28 10:11:54 +03:00
Stefanos Kornilios Mitsis Poiitidis eed60e775a Merge pull request #212 from Sonicadvance1/fix_multiprocess_crash
Fixes crashes in unit tests
2020-05-28 10:10:47 +03:00
Ryan Houdek 1d6aac1a5d Implements two handle_at syscalls 2020-05-27 18:32:17 -07:00
Ryan Houdek c78520c526 Implements symlink syscall 2020-05-27 18:32:17 -07:00
Ryan Houdek 5e4a75e8a6 Fixes crashes in unit tests
In the case of multiple dozens of tests running, they will end up
loading and saving the config files dozens of times.
This was causing the configuration system to load in half saved files
that were causing common crashes in the posix unit tests.

Theoretically this could have happened at any time but it looks like
with the posix unit tests added, it is just more likely to happen.

Makes it so loading the configuration file is much more robust and
verbose on failure.
Makes it so saving the config file first saves to a temporary and then
moves in to the correct location. This causes the config saving to be
atomic in a sense so the unit tests won't corrupt other processes of FEX
trying to load the config file.
2020-05-27 16:52:45 -07:00
Ryan Houdek e84dbafd2a Merge pull request #205 from Sonicadvance1/threaded_compilation_fix
Makes threaded compilation not rely on a global mutex
2020-05-27 10:27:56 -07:00
Ryan Houdek fd857e4966 Makes threaded compilation not rely on a global mutex
As we run more threaded applications it is becoming apparent that this
needs to be fixed now.
This duplicates the FrontendDecoder and Passmanager per thread so they
no longer block each other while compiling.
Increases a bit of memory usage but completely worth it.
2020-05-27 10:18:02 -07:00
Stefanos Kornilios Mitsis Poiitidis a773a4e627 Merge pull request #211 from Sonicadvance1/softfloat
Implements softfloat library for x87
2020-05-27 14:30:02 +03:00
Stefanos Kornilios Mitsis Poiitidis 6669bcfffd Merge pull request #209 from Sonicadvance1/minor_opts
Minor memory allocation optimizations in the IR passes.
2020-05-27 14:27:08 +03:00
Stefanos Kornilios Mitsis Poiitidis 2fd8e617ff Merge pull request #207 from Sonicadvance1/interpreter_fallback
Adds support for interpreter fallback
2020-05-27 14:20:58 +03:00
Stefanos Kornilios Mitsis Poiitidis 22a4c5185d Merge pull request #208 from Sonicadvance1/fence_ops
Implements fence ops
2020-05-27 14:18:21 +03:00
Ryan Houdek 56087a029d Implements softfloat library for x87 2020-05-27 00:05:48 -07:00
Stefanos Kornilios Mitsis Poiitidis 670869ccd7 Merge pull request #210 from Sonicadvance1/fix_scas
Fixes SCAS
2020-05-27 09:14:45 +03:00
Ryan Houdek 77e444e8a5 Fixes SCAS
Adds a couple of assets in the other repeat instructions.
Jump targets were accidently inverted.
SCAS and LODS are the two repeat instructions we don't have unit tests
for.
Unit tests are forthcoming for this
2020-05-26 22:51:11 -07:00
Ryan Houdek b3b6727a8e Minor optimization in IRCompaction pass
Codeblock array was constantly being reallocated.
Changes the remap array over to a allocate in multiples of the alignment
size.
Was hitting a pedantic case where the compaction would hit slightly
increasing function sizes so large numbers of reallocations occured
quickly.
2020-05-26 22:25:15 -07:00
Ryan Houdek f8579d5458 Minor optimization in the RCLSE pass
We already have an unmodified classification struct. Just memcpy it to
reset the state. Reduces a bunch of temporary allocations.
Also disables the CFG calculation since we aren't using it currently
2020-05-26 22:23:10 -07:00
Ryan Houdek 38ff936c81 Adds support for interpreter fallback
The IRHeader itself contains a flag for if a block should fallback to
the interpreter.
This is necessary for the case that an IR is loaded and the Frontend
object no longer has the data necessary to know if it should do an
interpreter fallback.
This is super useful for bisecting JIT versus Intepreter failures, and
also cases where falling back to intepreter for compatibility is a lot
more simple than wiring things through the JIT (ala x87)

This isn't currently utilized, but will be once x87 work lands
2020-05-26 19:08:18 -07:00
Ryan Houdek 19cecdbd2b Adds fence unit tests
Just execution tests
2020-05-26 19:06:21 -07:00
Ryan Houdek 5569894d81 Implements fence ops
These map directly to x86 fence instructions, which have equivalent ARM
versions as well.
2020-05-26 19:04:35 -07:00
Ryan Houdek 719094445b Merge pull request #206 from FEX-Emu/skmp/posixtest-python-disable-list
posixtests: Move disabled list to file from filenames
2020-05-26 13:36:26 -07:00
Stefanos Kornilios Mitsis Poiitidis 41a6cccfe8 posxitests: disable conformance-interfaces-sched_rr_get_interval-1-1.test 2020-05-26 18:34:01 +03:00
Stefanos Kornilios Mitsis Poiitidis f10891eb11 posixtests: Move disabled list to file from filenames 2020-05-26 17:39:22 +03:00