mirror of
https://github.com/FEX-Emu/FEX.git
synced 2025-01-25 07:57:03 +00:00
555d2e5b0b
All of these operations were only testing positive integers which is why they didn't show 16-bit failures. Adds a bunch of negative tests to each ones now that #2314 is merged, which would have caught them.
37 lines
554 B
NASM
37 lines
554 B
NASM
%ifdef CONFIG
|
|
{
|
|
"RegData": {
|
|
"RCX": ["0xbff0000000000000"],
|
|
"RSI": ["0x4008000000000000"]
|
|
},
|
|
"Env": { "FEX_X87REDUCEDPRECISION" : "1" }
|
|
}
|
|
%endif
|
|
|
|
mov rdx, 0xe0000000
|
|
|
|
mov rax, 0x3ff0000000000000 ; 1.0
|
|
mov [rdx + 8 * 0], rax
|
|
mov eax, 2
|
|
mov [rdx + 8 * 1], eax
|
|
|
|
fld qword [rdx + 8 * 0]
|
|
fisub dword [rdx + 8 * 1]
|
|
|
|
fst qword [rdx]
|
|
mov rcx, [rdx]
|
|
|
|
; Test negative
|
|
mov rax, 0x3ff0000000000000 ; 1.0
|
|
mov [rdx + 8 * 0], rax
|
|
mov eax, -2
|
|
mov [rdx + 8 * 1], eax
|
|
|
|
fld qword [rdx + 8 * 0]
|
|
fisub dword [rdx + 8 * 1]
|
|
|
|
fst qword [rdx]
|
|
mov rsi, [rdx]
|
|
|
|
hlt
|