2131 Commits

Author SHA1 Message Date
MerryMage
3315faf592 bit_util: Add CountLeadingZeros 2020-04-02 13:33:53 +01:00
MerryMage
be2f78bb60 print_info: Add -exec parameter to test execution 2020-04-02 13:33:53 +01:00
MerryMage
de63384ad4 a64_emit_x64: Reduce patchpoint sizes 2020-03-31 19:14:02 +01:00
MerryMage
a84a746831 A64: Add options for detecting misaligned loads and stores 2020-03-31 14:45:04 +01:00
Marshall Mohror
f1bfa5b5c0
A32/x64: Create a global_offset optimization for the page table (#507)
Instead of looking up the page table like:
  table[addr >> 12][addr & 0xFFF]
We can use a global offset on the table to query the memory like:
  table[addr >> 12][addr]

This saves two instructions on *every* memory access within the recompiler.

Original change by degasus in A64 emitter
2020-03-22 17:55:07 +00:00
MerryMage
525cac401e ir/basic_block: Add FastDispatchHint to TerminalToString
Use a boost::static_visitor to ensure this is caught at compile-time in the future.
2020-03-21 13:20:46 +00:00
Lioncash
0046466107 A64/impl: Move AccType and MemOp enum into general IR emitter header
These will be used by both frontends in the future, so this performs the
migratory changes separate from the changes that will make use of them.
2020-03-15 22:19:16 +00:00
Lioncash
206bb7074a externals: Update catch to 2.11.1
Updates our unit testing library from 2.9.1 to 2.11.1.

Keeps it up to date.
2020-01-27 14:10:20 +00:00
Merry
f6ae9e1c33
Merge pull request #505 from degasus/page_table
A64/x64: Create a global_offset optimization for the page table.
2019-12-31 18:52:10 +00:00
Markus Wick
f2c7c6a0d0 A64/x64: Create a global_offset optimization for the page table.
Instead of looking up the page table like:
  table[addr >> 12][addr & 0xFFF]
We can use a global offset on the table to query the memory like:
  table[addr >> 12][addr]

This saves two instructions on *every* memory access within the recompiler.

Thanks at skmp for the idea.
2019-12-31 00:08:35 +01:00
MerryMage
087a74417a Reduce requirements to macOS 10.12 2019-08-14 21:14:23 +01:00
MerryMage
79db0c7c40 a32_emit_x64: Use std::get_if in EmitA32Coproc* 2019-08-14 21:14:21 +01:00
MerryMage
8c6cab482f CMakeLists: Put -Wfatal-errors behind a CMake flag 2019-08-14 20:50:36 +01:00
MerryMage
af8e6c4127 test_arm_instruction: Revive some old tests 2019-07-28 21:31:05 +01:00
MerryMage
156cfa97db constant_propagation_pass: Handle GetCarryFromOp for MostSignificantWord 2019-07-28 21:28:02 +01:00
MerryMage
6921ef5632 a32_interface: Remove unused TransferJitState function 2019-07-28 21:23:16 +01:00
MerryMage
3aecba9833 a32_jitstate: Only transfer required state
Importantly, reset exclusive state upon transfer.
2019-07-28 18:59:44 +01:00
MerryMage
0e7b6b1a60 A32/Thumb: Correct behaviour for UDF and Unpredictable instructions
Raise an exception instead of calling the interpreter and ASSERT-ing respectively.
2019-07-27 19:56:18 +01:00
MerryMage
1b17d1e7bd fuzz_arm: Test MSR and MRS instructions against unicorn
* Add always_little_endian option to mach unicorn behavior.
* Correct CPSR.Mode = Usermode
2019-07-27 19:54:57 +01:00
MerryMage
993784faa3 print_info: Add support for printing A32 instructions 2019-07-27 16:33:19 +01:00
MerryMage
e656eb0b82 a32_emit_x64: EmitA32SetCpsr: BUGFIX: Actually set CPSR.GE
Was unintentionally masking the writing of CPSR.GE due to 32-bit immediate sign extension.
2019-07-27 08:29:32 +01:00
MerryMage
6049e3ef91 a32_emit_x64: GenTerminalHandlers: Remove unnecessary mov 2019-07-27 08:28:39 +01:00
MerryMage
e814b47812 A64: Add hook_hint_instructions option 2019-07-25 12:15:54 +01:00
MerryMage
534eb0fe1d A32: Add hook_hint_instructions option 2019-07-25 12:11:39 +01:00
MerryMage
254ab9355e a32_jitstate: Consolidate upper bits of location descriptor into upper_location_descriptor
Also solves a performance regression initially introduced by b6e8297e369f2dc4758bafe944e51efb8d1a2552,
primarily due to excessively mismatched load/store sizes causing less than optimal load-to-store forwarding.
2019-07-25 11:40:40 +01:00
MerryMage
dc8e6ccf74 CMakeLists: Temporarily remove export
Unable to export fmt in projects that have DYNARMIC_NO_BUNDLED_FMT enabled
2019-07-23 21:42:14 +01:00
Lioncash
e1709546f9
externals: Update catch to 2.9.1
Keeps the unit-testing library up to date.
2019-06-17 06:36:01 -04:00
Merry
313622a53a
Merge pull request #503 from lioncash/cmp
A64: Implement half-precision variants of FCMEQ
2019-05-30 00:58:57 +01:00
Merry
f67690157a
Merge pull request #502 from lioncash/header
General: Remove unnecessary includes
2019-05-27 13:45:05 +01:00
Lioncash
4715b11216
A64: Implement all half-precision variants of FCMEQ 2019-05-25 23:51:39 -04:00
Lioncash
a3f211847c
frontend/ir_emitter: Add half-precision opcode for FPVectorEquals 2019-05-25 23:51:39 -04:00
Lioncash
6d8c9a7dd9
common/fp/op: Add soft-float implementation of FPCompareEQ
This will be used to implement the half-precision floating-point
variants of FCMEQ in following changes.
2019-05-25 23:51:35 -04:00
Lioncash
a9e12969c0
backend/x64/reg_alloc: Apply const where applicable
Also tidies up bracing where applicable along the way.
2019-05-25 17:41:24 -04:00
Lioncash
0a5a34bda4
backend/x64/emit_*: Apply const where applicable 2019-05-25 17:35:05 -04:00
Lioncash
81a3c1c477
A64/translate/*: Apply const where applicable
Just some tidying up for consistency
2019-05-25 17:27:01 -04:00
Lioncash
dfca10ed73
disassembler_arm: Apply const where applicable 2019-05-25 17:15:00 -04:00
Lioncash
8a4439808d
a64_emit_x64: Apply [[maybe_unused]] to unused lambda parameter
This can result in an unused variable warning on Windows otherwise.
2019-05-25 17:07:23 -04:00
Lioncash
d079a4812c
A64/translate/impl: Mark DecodeBitMasks and AdvSIMDExpandImm as static
These don't rely on instance state to perform their behavior. They're
just helper functions.
2019-05-24 02:29:41 -04:00
Lioncash
4dc39252fd
x64/exception_handler_windows: Join namespace declaration
Uses a nested namespace declaration like the rest of the codebase.
2019-05-24 02:18:36 -04:00
Lioncash
2f09577dbf
a32_interface: Remove duplicated documentation comments
These already exist in the header, so these ones can be removed.
2019-05-24 02:15:51 -04:00
Lioncash
d01ec837d2
frontend/A32/types: Remove redundant std::string initializer
std::string initializes to empty by default. While we're at it, brace a
lone unbraced if statement.
2019-05-24 02:05:19 -04:00
Lioncash
31754c6918
ir_opt/a64_get_set_elimination_pass: Remove redundant return
This lambda function has a void return type, so we don't need to
explicitly return at the end of it.
2019-05-24 02:03:28 -04:00
Lioncash
76ca184afc
General: Make parameter names from declarations and implementations consistent
Most of the time when this occurs, it's a bug. Thankfully this isn't the
case. However, we can resolve these cases to make the codebase more
consistent.
2019-05-24 01:59:08 -04:00
Lioncash
c6b321d31c
A32/translate/translate: Add missing doxygen parameter string 2019-05-24 01:48:00 -04:00
Lioncash
2bc8a095dd
General: Correct typos is code comments 2019-05-24 01:37:03 -04:00
Lioncash
268d08511e
a32_interface: std::move UserConfig where applicable
UserConfig instances contain up to 16 std::shared_ptr<Coprocessor>
instances. We can std::move here to avoid performing 16 redundant atomic
reference increment and decrement operations.

Mostly inconsequential on x64, but we may as well signify intent.
2019-05-23 22:09:16 -04:00
Lioncash
9100696696
ir/basic_block: std::move Terminal within SetTerminal and ReplaceTerminal
A terminal isn't a trivial type (and boost::variant is allowed to heap
allocate), so we can std::move it here to avoid a redundant copy.
2019-05-23 22:05:45 -04:00
Lioncash
72f863a223
ir/terminal: std::move constructor parameters where applicable
Allows the compiler to choose the most suitable code in this scenario,
given a Terminal isn't a trivial type.
2019-05-23 22:02:32 -04:00
Lioncash
1d65e3a521
a32_interface: Default destructor in the cpp file
Makes it more consistent with code throughout the codebase.
2019-05-23 21:56:24 -04:00
Lioncash
a178031d6c
General: Remove unnecessary includes
Removes unnecessary header dependencies that have accumulated over time
as changes have been made. Lessens the amount of files that need to be
rebuilt when the headers change.
2019-05-23 21:43:10 -04:00