diff options
| author | 2014-05-01 23:03:50 -0400 | |
|---|---|---|
| committer | 2014-05-01 23:03:50 -0400 | |
| commit | f7c6302009aa2453c37a6a7a3b1af4843f620078 (patch) | |
| tree | 59d429e36b9c3acd60a779ffbf063c59b2079e32 /src/core/hle/coprocessor.cpp | |
| parent | fixed include in coprocessor.cpp (diff) | |
| download | yuzu-f7c6302009aa2453c37a6a7a3b1af4843f620078.tar.gz yuzu-f7c6302009aa2453c37a6a7a3b1af4843f620078.tar.xz yuzu-f7c6302009aa2453c37a6a7a3b1af4843f620078.zip | |
- added CallMCR function to coprocessor HLE module
- moved instruction decoding to coprocessor HLE module
Diffstat (limited to 'src/core/hle/coprocessor.cpp')
| -rw-r--r-- | src/core/hle/coprocessor.cpp | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/src/core/hle/coprocessor.cpp b/src/core/hle/coprocessor.cpp index 5b412c586..df1362176 100644 --- a/src/core/hle/coprocessor.cpp +++ b/src/core/hle/coprocessor.cpp | |||
| @@ -44,8 +44,18 @@ Addr GetThreadCommandBuffer() { | |||
| 44 | return CMD_BUFFER_ADDR; | 44 | return CMD_BUFFER_ADDR; |
| 45 | } | 45 | } |
| 46 | 46 | ||
| 47 | /// Call an MRC operation in HLE | 47 | /// Call an MCR (move to coprocessor from ARM register) instruction in HLE |
| 48 | u32 CallMRC(ARM11_MRC_OPERATION operation) { | 48 | s32 CallMCR(u32 instruction, u32 value) { |
| 49 | CoprocessorOperation operation = (CoprocessorOperation)((instruction >> 20) & 0xFF); | ||
| 50 | ERROR_LOG(OSHLE, "unimplemented MCR instruction=0x%08X, operation=%02X, value=%08X", | ||
| 51 | instruction, operation, value); | ||
| 52 | return -1; | ||
| 53 | } | ||
| 54 | |||
| 55 | /// Call an MRC (move to ARM register from coprocessor) instruction in HLE | ||
| 56 | s32 CallMRC(u32 instruction) { | ||
| 57 | CoprocessorOperation operation = (CoprocessorOperation)((instruction >> 20) & 0xFF); | ||
| 58 | |||
| 49 | switch (operation) { | 59 | switch (operation) { |
| 50 | 60 | ||
| 51 | case DATA_SYNCHRONIZATION_BARRIER: | 61 | case DATA_SYNCHRONIZATION_BARRIER: |
| @@ -55,7 +65,7 @@ u32 CallMRC(ARM11_MRC_OPERATION operation) { | |||
| 55 | return GetThreadCommandBuffer(); | 65 | return GetThreadCommandBuffer(); |
| 56 | 66 | ||
| 57 | default: | 67 | default: |
| 58 | ERROR_LOG(OSHLE, "unimplemented MRC operation 0x%02X", operation); | 68 | ERROR_LOG(OSHLE, "unimplemented MRC instruction 0x%08X", instruction); |
| 59 | break; | 69 | break; |
| 60 | } | 70 | } |
| 61 | return -1; | 71 | return -1; |