Ryan Houdek
0aaed41f72
Merge pull request #751 from FEX-Emu/skmp/fix-fchmodat-faccessat
...
Syscalls: chmodat, faccessat glibc interface differs from kernel
2021-02-02 05:52:38 -08:00
Stefanos Kornilios Mitsis Poiitidis
4d05438796
Merge pull request #747 from phire/android_build_fixes
...
Android build fixes
2021-02-02 14:40:34 +02:00
Stefanos Kornilios Mitsis Poiitidis
f9aa457e3f
Syscalls: chmodat, faccessat glibc interface differs from kernel
2021-02-02 14:35:27 +02:00
Stefanos Kornilios Mitsis Poiitidis
a3b5234d1c
HarnessHelpers: Fix empty arg forwarding
2021-02-02 14:19:23 +02:00
Scott Mansell
9fa108ff33
Move -lnuma to correct place
2021-02-02 16:47:55 +13:00
Scott Mansell
45962098ef
Refactor LinuxSyscalls to it's own static library
2021-02-02 16:47:55 +13:00
Scott Mansell
622c437829
undef PAGE_SIZE if it's defined
...
The android NDK defines this.
2021-02-02 16:47:55 +13:00
Scott Mansell
16e7ba6fa8
Move nasm check inside unit tests
...
Allow building of fex without nasm if unit tests are disabled
2021-02-02 16:47:55 +13:00
Scott Mansell
93d5cdde1f
Fix missing libc++ includes
...
gnu's libc++ is lenient and allows you to miss includes at times.
Android's binoic is more strict and needs these fixes to build.
2021-02-01 21:08:45 +13:00
Ryan Houdek
1b1e922830
Removes warnings from HostFactory
2021-01-31 08:01:53 -08:00
Stefanos Kornilios Mitsis Poiitidis
513112919b
RA: Move allocation data to RAData
2021-01-29 10:42:40 +02:00
Stefanos Kornilios Mitsis Poiitidis
d6ee3caad4
Syscalls: Define MREMAP_DONTUNMAP if missing
2021-01-28 17:09:08 +02:00
Ryan Houdek
a98eaa6a27
Finishes 32bit memory allocator
...
This was partially implemented before but it had some bugs still.
This fixes those bugs and also implements mremap, shmat, and shmdt.
This now works well enough for 32bit graphical applications
2021-01-27 10:49:28 -08:00
Ryan Houdek
2d8b70bbd5
Merge pull request #710 from Sonicadvance1/brk_improvements
...
More improvements to BRK handling
2021-01-27 10:49:07 -08:00
Ryan Houdek
a5d9e62cc6
More improvements to BRK handling
...
Base size is now only one page in size. We will then increment that BRK
size by 8MB alignments. 256MB for 32bit applications was causing some
applications on the edge to run out of virtual memory
I was hitting some 32bit applications that were being fairly mean with
BRK. They were allocating all of BRK space then running out of virtual
memory space with its mmap handler fallback after freeing BRK space.
This means we now munmap BRK pages on release for the guest, similar to
behaviour that Linux does.
Additionally I had an application that was getting very upset that BRK
wasn't actually at the end of program space. So allocate at the end of
program space like expected.
brk test now passes from gvisor
2021-01-27 10:12:25 -08:00
Ryan Houdek
15df787710
Implements ioctl32 for x86-64
...
If you have the COMPAT feature enabled then this just works there.
AArch64 not implemented currently since changes aren't upstream
2021-01-27 08:02:49 -08:00
Stefanos Kornilios Mitsis Poiitidis
8ff0b870b1
Merge pull request #712 from Sonicadvance1/fix_timers
...
Fixes timer syscall API
2021-01-26 15:33:00 +02:00
Ryan Houdek
3679156dd7
Fixes timer syscall API
...
The glibc and kernel timer interfaces are sufficiently different enough
that unwrapping this through glibc is impossible.
Pass it directly through to the kernel.
2021-01-26 05:02:44 -08:00
Ryan Houdek
cab317e2f0
Removes all references to Boost
...
We don't require this
Fixes #699
2021-01-26 02:34:26 -08:00
Ryan Houdek
2721418fb7
Merge pull request #698 from phire/better_defaults
...
Better Default Configuration
2021-01-22 16:56:29 -08:00
Scott Mansell
3cae0a0932
Better Default Configuration
...
Make FEX have good performance out of the box
resolves #685
2021-01-23 13:47:53 +13:00
Stefanos Kornilios Mitsis Poiitidis
8b025d4c26
IRLoader: Actually set EntryRIP if the IR was parsed
2021-01-21 22:19:16 +02:00
Stefanos Kornilios Mitsis Poiitidis
e7f2a650b5
Fix compilation
2021-01-21 22:18:48 +02:00
Stefanos Kornilios Mitsis Poiitidis
3bd8731b26
IR: Add CONFIG_VALIDATE_IR_PARSER, enable it on TestHarnessRunner
2021-01-21 21:38:41 +02:00
Stefanos Kornilios Mitsis Poiitidis
1177c375ff
IR: Further parser cleanups, add fence types
2021-01-21 21:17:27 +02:00
Stefanos Kornilios Mitsis Poiitidis
072067b5fd
IR: Split parser from IRLoader, add IR::Parse()
2021-01-21 19:17:51 +02:00
Stefanos Kornilios Mitsis Poiitidis
036771d825
IR: Fix Printing and Parsing for float conds
2021-01-21 10:16:08 +02:00
Ryan Houdek
108992de80
Merge pull request #653 from Sonicadvance1/add_O0
...
Adds an option to disable optimization passes
2021-01-18 00:10:48 -08:00
Ryan Houdek
544a1f307f
Adds an option to disable optimization passes
...
Instead of forcing someone to test by modifying code, allow a -O0 option
to be passed in.
Also added to FEXConfig GUI for easily touching.
Fixes #652
2021-01-17 23:51:22 -08:00
Ryan Houdek
0e11dea46f
Adds kernel version check to FEXLoader
...
We require kernel 4.17 minimum on the host to run correctly
2021-01-15 13:55:04 -08:00
Ryan Houdek
80dfa76d48
Have SyscallHandler calculate host kernel version
2021-01-15 13:44:08 -08:00
Stefanos Kornilios Mitsis Poiitidis
f951bc969e
Merge pull request #628 from Sonicadvance1/more_syscalls
...
Implements more syscalls
2021-01-13 20:45:02 +02:00
Stefanos Kornilios Mitsis Poiitidis
271d5898fb
Merge pull request #642 from Sonicadvance1/fix_llvm_asan
...
Fixes 64bit ELF loading when LLVM ASAN is used
2021-01-13 12:55:58 +02:00
Stefanos Kornilios Mitsis Poiitidis
0c1510e763
Merge pull request #641 from Sonicadvance1/uninstall_handlers
...
Uninstalls both the signal delegator and logmanager handlers on shutdown
2021-01-13 12:15:10 +02:00
Ryan Houdek
433162004a
Implements more syscalls
2021-01-12 14:50:17 -08:00
Ryan Houdek
43af4e26d1
Fixes 64bit ELF loading when LLVM ASAN is used
...
Instead of hardcoding 64bit dynamic ELF files to 0x1'0000'0000 we
instead calculate the size of the ELF in memory. Then allocate the
ELF base up front.
LLVM ASAN steals a large amount of virtual memory space that intersected
with the original hardcoded range which caused memory allocations to
fail.
2021-01-11 09:07:16 -08:00
Ryan Houdek
aa3b77e4c8
Uninstalls LogManager handlers on shutdown
...
In case something manages to have stayed alive and tried throwing a
message, this will no longer crash.
Noticed this with the previous commit
2021-01-11 09:03:56 -08:00
Ryan Houdek
f83698cb50
Uninstalls SignalDelegator signals on destruction
...
Tear this down earlier so if we catch a signal on shutdown then we don't
crash in the handler.
Fixes some pain around debugging shutdown crashes
2021-01-11 09:01:06 -08:00
Stefanos Kornilios Mitsis Poiitidis
6542f08f27
Merge pull request #623 from Sonicadvance1/capture_fsstatat
...
Captures fsstatat in filesystem overlay
2021-01-11 16:20:15 +02:00
Stefanos Kornilios Mitsis Poiitidis
1e80d3527b
Merge pull request #624 from Sonicadvance1/capture_osrelease
...
Have EmulatedFiles support osrelease file
2021-01-11 16:20:04 +02:00
Stefanos Kornilios Mitsis Poiitidis
a1ac4c711c
Merge pull request #631 from duck-37/dump-ir-runner
...
Pass DumpIR to TestHarnessRunner
2021-01-11 11:02:03 +02:00
Stefanos Kornilios Mitsis Poiitidis
d7868fd2bd
Merge pull request #627 from Sonicadvance1/disable_visual_debugger
...
Disables visual debugger by default
2021-01-11 11:00:16 +02:00
Stefanos Kornilios Mitsis Poiitidis
db71916ee4
Merge pull request #625 from Sonicadvance1/shebang_improvements
...
Shebang improvements
2021-01-11 10:58:51 +02:00
duck
d1b1e5ae07
pass DumpIR to TestHarnessRunner
2021-01-10 17:44:33 -05:00
Ryan Houdek
c2b1d68ed1
Disables visual debugger by default
...
This is currently broken and going to be broken more soon
2021-01-10 02:19:39 -08:00
Ryan Houdek
8f1978a33a
Shebang improvements
...
Fixes a problem where a space between the shebang and application
argument would result in us trying to execute a null program.
Additionally it now captures all the arguments passed in the shebang
header rather than just the application and first argument.
2021-01-10 02:15:51 -08:00
Ryan Houdek
22377d9c2c
Have EmulatedFiles support osrelease file
...
This was being checked by an application for kernel version. Which was
seeing too new of a kernel and using things that were unsupported.
Also removes the EmulatedMap which is an unnecessary lookup.
2021-01-10 02:14:44 -08:00
Ryan Houdek
66e98365eb
Captures fsstatat in filesystem overlay
...
Fixes Vulkan loader searching for vulkan json ICD files
2021-01-10 02:13:48 -08:00
Ryan Houdek
a29371dbf5
Fixes execve with rootfs
...
We need to check to see if the application wanting to be executed is in
the rootfs first. Otherwise we end up in a case where we either lose
tracking of applications in FEX, or applications fail to launch since
they don't exist in the global filesystem
2021-01-10 02:12:42 -08:00
duck
6388151fc0
Oops.
2021-01-06 18:12:09 -05:00