Commit Graph
981 Commits
Author SHA1 Message Date
Ryan Houdek f397bf3349 Merge pull request #281 from FEX-Emu/skmp/native-lib-thunking-3
Thunks: ALTINST, OP_THUNK, basic infrastructure
2020-07-20 13:36:13 -07:00
Stefanos Kornilios Mitsis Poiitidis 106892f824 Thunks: Use shared_mutex 2020-07-20 14:58:49 +03:00
Stefanos Kornilios Mitsis Poiitidis 8c8e6294b6 Thunks: ALTINST, OP_THUNK, basic infrastructure 2020-07-20 13:52:28 +03:00
Stefanos Kornilios Mitsis Poiitidis f77005c0e0 Merge pull request #280 from Sonicadvance1/add_new_runner
Adds new ARMv8.0 runner tag
2020-07-19 20:40:11 +03:00
Ryan Houdek d70f2e6854 Actually run the IRJIT for the JIT posix test 2020-07-19 04:03:38 -07:00
Ryan Houdek f613d670c7 Increase timeout of test runner 2020-07-19 04:03:21 -07:00
Ryan Houdek dcf3899346 Adds new ARMv8.0 runner tag
This ensures we can run on ARMv8.2, ARMv8.0 and X64
2020-07-19 03:39:16 -07:00
Ryan Houdek 88becfb168 Merge pull request #279 from Sonicadvance1/fix_llvm_codeclear
Fixes LLVM not clearing code cache on ARM platforms
2020-07-19 03:26:58 -07:00
Ryan Houdek 9b78876862 Fixes LLVM not clearing code cache on ARM platforms
Surprised this hasn't caused issues before but was picked up on the
SolidRun Honeycomb LX2K
2020-07-19 12:08:27 +11:00
Ryan Houdek 57ec876961 Merge pull request #278 from phire/pid_self
Filesystem HLE: Intercept /proc/${getpid}/exe too
2020-07-17 14:27:24 -07:00
Scott Mansell 183c5d9e22 Filesystem HLE: Intercept /proc/${getpid}/exe too 2020-07-18 09:16:59 +12:00
Stefanos Kornilios Mitsis Poiitidis 98f1c9c3a5 Merge pull request #277 from Sonicadvance1/fix_curl
Fix Curl
2020-07-16 10:35:29 +01:00
Ryan Houdek 2536bfe42c Correctly fixes prefix ordering in the frontend
This was sort of partially worked around.
The issue comes down to REX.W and Operand size prefix ordering on an
instruction.
When an instruction has both prefixes, then the one that has occured
later will overwrite the previous one.
Additionally in the case of 66h being reused as an escape prefix, we
needed to ignore it in this case.

The previous workaround was that if an instruction happened to have both
widening and narrowing, then widening would win(for MODRM args),
but then later on in the instruction decoding the literal constant
decoding would properly check which order the flags came in.
This resulted in literal constants working, but not modrm bytes

Instead replace the "last" flag handling with a two deep stack that we
can push and pop the flags correctly on to it, this ensures that the
flags stay around in the 66h ignoring mode (so widening doesn't get
obliterated).

This effects every instruction that supports REX.W and 66h Operand size
prefix, so it could be fixing some unknown bugs elsewhere.
Very specifically this one was found in OpenSSL, because it looks like
GCC is padding a mov instruction with 66h.

Instruction Examples:
Only difference is the prefix order being swapped
0x00000000   4                 66488b1f  mov rbx, qword [rdi]
0x00000004   4                 48668b1f  mov bx, word [rdi]
2020-07-15 00:10:20 -07:00
Ryan Houdek ac68dc40e5 Fixes INC and DEC flag setting
These two instructions explicitly don't set the CF flag.
Otherwise they behave the same as ADD/SUB flag setting
Fixes part of curl
2020-07-15 00:09:16 -07:00
Ryan Houdek a00b740c11 Merge pull request #274 from Kamaropoulos/master
Adds multi-stage building for Docker image
2020-07-14 10:04:57 -07:00
Kamaropoulos c2b29b10d1 Adds multi-stage building for Docker image 2020-07-14 03:43:50 -07:00
Stefanos Kornilios Mitsis Poiitidis 43133b6a3b Merge pull request #271 from Sonicadvance1/remove_clmul
Disables CLMUL in CPUID
2020-07-14 11:59:02 +03:00
Ryan Houdek b02ef28c46 Merge pull request #273 from Kamaropoulos/master
Adds Dockerfile configuration for use as a base image
2020-07-13 11:21:39 -07:00
Kamaropoulos 36b12f934d Changes Dockerfile image to Release build 2020-07-13 11:08:28 -07:00
Kamaropoulos 2abb2a7a3d Adds Dockerfile configuration for use as a base image 2020-07-13 10:59:01 -07:00
Ryan Houdek 2dd7a8d16d Disables CLMUL in CPUID
This would be a pain to support in NEON since it requires a 128bit
resulting multiply
2020-07-13 10:27:48 -07:00
Stefanos Kornilios Mitsis Poiitidis 66ea34d60e Merge pull request #269 from Sonicadvance1/environment_variables
Support Environment variables passed as arguments
2020-07-13 12:32:01 +03:00
Stefanos Kornilios Mitsis Poiitidis f3014e43b8 Merge pull request #268 from Sonicadvance1/minor_fixes
Minor fixes
2020-07-13 12:31:09 +03:00
Stefanos Kornilios Mitsis Poiitidis 174127fa73 Merge pull request #259 from Sonicadvance1/signal_delegate
Adds new signal delegator class
2020-07-13 12:30:02 +03:00
Ryan Houdek 383b8b7bb5 Fixes VADDV assert and implementation detail
AArch64's ADDV instruction doesn't support 8byte elements, it instead
needs to use ADDP(scalar) for the operation.

Fixes an assert and minor behaviour difference there
2020-07-12 03:41:02 +01:00
Ryan Houdek 43a8915074 Works around some vixl asserts
These don't change behaviour, but in debug mode were causing asserts
2020-07-12 03:39:55 +01:00
Ryan Houdek 48c73ca780 Adds support for -E to the ELFLoader
Now you can pass environment variables to the guest using -E

ex. `./Bin/ELFLoader -E DISPLAY=:0 -E GALLIUM_HUD=fps,cpu /usr/bin/glxgears`
2020-07-11 09:38:57 +01:00
Ryan Houdek f3bdd9c612 Adds additional environment variable loading to the ELF HarnessHelper 2020-07-11 09:37:55 +01:00
Ryan Houdek bbf39d3f4e Adds support for the argument loader to have a new -E argument
This allows us to pass environment variables to the guest system without
polluting the host environment variable space
2020-07-11 09:37:18 +01:00
Ryan Houdek c64ad6f868 Adds support for Config values with lists of variables
Only works for lists with std::string at the moment since that is all we
need for environment variables
2020-07-11 09:36:24 +01:00
Ryan Houdek 80b9b45b3e Cleans up a couple warnings 2020-07-11 06:21:28 +01:00
Ryan Houdek f593906c9a Fixes LORegion feature detection problem
LORegion is a requirement of ARMv8.1, but the hypervisor of the c630
isn't exposing the identification register correctly.
If the host supports atomics, just assume it supports LORegions as well

Fixes an assert when building vixl in debug
2020-07-11 06:21:08 +01:00
Ryan Houdek 1f727c5826 Fixes Vector_FToF op on AArch64 JIT
Only fixes asserts, no code emission changes
2020-07-11 06:20:57 +01:00
Ryan Houdek cb74beadb4 Fixes Zext on FPR->GPR conversion for AArch64
The 32bit and lower sizes were making vixl asserts fire.
Wouldn't actually change emitted code
2020-07-11 06:20:50 +01:00
Ryan Houdek d281e9f7ff Fixes LDIV bug in aarch64 JIT
vixl asserts were firing for the 16bit variant, and we needed to sext
the divisor for the 32bit variant
2020-07-11 06:20:40 +01:00
Ryan Houdek a1db6a0dec Adds new signal delegator class
Allows us to register host and guest signal delegators.
Currently only host signals are handled, guest signal delegation will
take a bit of work still.
2020-07-11 06:12:06 +01:00
Ryan Houdek bd05a5e1de Merge pull request #266 from FEX-Emu/skmp/fix-uname
uname: Should return x86_64, not x64_64
2020-07-08 13:33:54 -07:00
Stefanos Kornilios Mitsis Poiitidis 630d66942c uname: Should return x86_64, not x64_64
Run into this in CS:GO.
With this fix it progresses much further, but still doesn't get to the menu.
2020-07-08 20:58:57 +03:00
Ryan Houdek 73729446f1 Merge pull request #265 from FEX-Emu/skmp/fix-15-byte-ops
Frontend: Fix 15-byte long opcode assert
2020-07-08 04:31:23 -07:00
Stefanos Kornilios Mitsis Poiitidis 951ff40904 Frontend: Fix 15-byte long opcode assert 2020-07-08 14:00:14 +03:00
Ryan Houdek 15d6f48ca2 Merge pull request #258 from FEX-Emu/skmp/more-syscalls
syscalls: fork, vfork, eventfd2
2020-07-06 09:51:41 -07:00
Ryan Houdek d9eadc0a3d Merge pull request #260 from FEX-Emu/skmp/implement-pavgb-pavgw
Implement PAVGB/PAVGW
2020-07-04 15:45:35 -07:00
Stefanos Kornilios Mitsis Poiitidis 560d467058 VURAvg: Fix arm64 jit 2020-07-04 21:52:15 +03:00
Stefanos Kornilios Mitsis Poiitidis 8eaa11f4f2 VURAvg: Fix llvm implementation 2020-07-04 20:51:13 +03:00
Stefanos Kornilios Mitsis Poiitidis c19e8b3d2f Implement PAVGB/PAVGW 2020-07-04 19:30:53 +03:00
Stefanos Kornilios Mitsis Poiitidis fc2d7656e0 syscalls: Warn on clone + ptrace instead of assert 2020-07-04 19:04:08 +03:00
Stefanos Kornilios Mitsis Poiitidis cb8f250078 syscalls: fork, vfork, eventfd2 2020-07-03 11:17:51 +03:00
Stefanos Kornilios Mitsis Poiitidis 82e43ad35d Merge pull request #257 from Sonicadvance1/fix_x86_crash
Fixes AtomicSwap IR op on x86
2020-07-03 09:41:11 +03:00
Ryan Houdek 9c99dbfbdc Fixes AtomicSwap IR op on x86
lock prefix needed to go before the xchg, not before the move that was
there
2020-07-02 22:18:44 -07:00
Ryan Houdek 95f1775df5 Merge pull request #255 from FEX-Emu/skmp/implement-execve
syscalls: implement execve
2020-07-02 14:41:13 -07:00