mirror of
https://github.com/FEX-Emu/FEX.git
synced 2026-10-28 07:00:49 +01:00
Test behaviour themselves not changed at all, just data moved or aligned. For tests that aren't explicitly testing out SMC behaviour, we were accidentally relying on some aggressive SMC tracking by mixing data and code in the same page. To fix this just align the test's data to the next page boundary which means FEX's SMC tracking won't get triggered since it is no longer living in the same page. This has been a thorn for a while, so just get rid of it. We obviously still have ASM tests that still exist that /do/ rely on SMC, and those are still expected to work.
46 lines
721 B
NASM
46 lines
721 B
NASM
%ifdef CONFIG
|
|
{
|
|
"RegData": {
|
|
"RAX": "0x3f800000",
|
|
"RBX": "0x3f800000",
|
|
"RCX": "0x3f800000",
|
|
"RBP": "0x3f800000",
|
|
"RDI": "0x3f800000",
|
|
"RSP": "0x3f800000"
|
|
},
|
|
"MemoryRegions": {
|
|
"0xf0000000": "4096"
|
|
},
|
|
"Mode": "32BIT"
|
|
}
|
|
%endif
|
|
|
|
; Setup
|
|
fld1
|
|
lea edx, [rel base]
|
|
mov esi, 0x64
|
|
|
|
; Test fst
|
|
fst dword [edx]
|
|
fst dword [edx + 0xa]
|
|
fst dword [edx + esi]
|
|
fst dword [edx + esi * 4]
|
|
fst dword [edx + esi + 0xa]
|
|
fst dword [edx + esi * 4 + 0xa]
|
|
|
|
; Result check
|
|
mov eax, dword [edx]
|
|
mov ebx, dword [edx + 0xa]
|
|
mov ecx, dword [edx + esi]
|
|
mov ebp, dword [edx + esi * 4]
|
|
mov edi, dword [edx + esi + 0xa]
|
|
mov esp, dword [edx + esi * 4 + 0xa]
|
|
|
|
hlt
|
|
|
|
align 4096
|
|
section .bss
|
|
base resb 4096
|
|
|
|
section .text
|