test: nasm-t -- Add imm64

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
This commit is contained in:
Cyrill Gorcunov 2018-11-05 17:50:37 +03:00
parent 536f28188c
commit 752c72e204
8 changed files with 135 additions and 0 deletions

BIN
travis/test/imm64-o0.bin.t Normal file

Binary file not shown.

View file

@ -0,0 +1,16 @@
./travis/test/imm64.asm:24: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:24: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:25: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:26: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:27: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:27: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:28: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:28: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:52: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:52: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:53: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:54: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:55: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:55: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:56: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:56: warning: dword data exceeds bounds [-w+number-overflow]

BIN
travis/test/imm64-o1.bin.t Normal file

Binary file not shown.

View file

@ -0,0 +1,16 @@
./travis/test/imm64.asm:24: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:24: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:25: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:26: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:27: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:27: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:28: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:28: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:52: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:52: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:53: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:54: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:55: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:55: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:56: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:56: warning: dword data exceeds bounds [-w+number-overflow]

BIN
travis/test/imm64-ox.bin.t Normal file

Binary file not shown.

View file

@ -0,0 +1,16 @@
./travis/test/imm64.asm:24: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:24: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:25: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:26: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:27: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:27: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:28: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:28: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:52: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:52: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:53: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:54: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:55: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:55: warning: dword data exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:56: warning: signed dword immediate exceeds bounds [-w+number-overflow]
./travis/test/imm64.asm:56: warning: dword data exceeds bounds [-w+number-overflow]

56
travis/test/imm64.asm Normal file
View file

@ -0,0 +1,56 @@
bits 64
mov rax,11223344h
mov rax,dword 11223344h
mov eax,11223344h
mov [rax],dword 11223344h ; 32-bit operation
mov qword [rax],11223344h
mov qword [rax],dword 11223344h
mov rax,0_ffffffff_8899aabbh
mov rax,dword 0_ffffffff_8899aabbh
mov eax,0_ffffffff_8899aabbh
mov [rax],dword 0_ffffffff_8899aabbh ; 32-bit operation
mov qword [rax],0_ffffffff_8899aabbh
mov qword [rax],dword 0_ffffffff_8899aabbh
mov rax,7fffffffh
mov rax,80000000h
mov rax,0_ffffffffh
mov rax,1_00000000h
mov rax,0_ffffffff_7fffffffh
mov rax,0_ffffffff_80000000h
mov rax,0_11223344_8899aabbh
mov rax,dword 0_11223344_8899aabbh
mov eax,0_11223344_8899aabbh
mov [rax],dword 0_11223344_8899aabbh ; 32-bit operation
mov qword [rax],0_11223344_8899aabbh
mov qword [rax],dword 0_11223344_8899aabbh
mov rax,strict 11223344h
mov rax,strict dword 11223344h
mov eax,strict 11223344h
mov [rax],strict dword 11223344h ; 32-bit operation
mov qword [rax],strict 11223344h
mov qword [rax],strict dword 11223344h
mov rax,strict 0_ffffffff_8899aabbh
mov rax,strict dword 0_ffffffff_8899aabbh
mov eax,strict 0_ffffffff_8899aabbh
mov [rax],strict dword 0_ffffffff_8899aabbh ; 32-bit operation
mov qword [rax],strict 0_ffffffff_8899aabbh
mov qword [rax],strict dword 0_ffffffff_8899aabbh
mov rax,strict 7fffffffh
mov rax,strict 80000000h
mov rax,strict 0_ffffffffh
mov rax,strict 1_00000000h
mov rax,strict 0_ffffffff_7fffffffh
mov rax,strict 0_ffffffff_80000000h
mov rax,strict 0_11223344_8899aabbh
mov rax,strict dword 0_11223344_8899aabbh
mov eax,strict 0_11223344_8899aabbh
mov [rax],strict dword 0_11223344_8899aabbh ; 32-bit operation
mov qword [rax],strict 0_11223344_8899aabbh
mov qword [rax],strict dword 0_11223344_8899aabbh

31
travis/test/imm64.json Normal file
View file

@ -0,0 +1,31 @@
[
{
"description": "Test imm64 operations (-Ox)",
"id": "imm64",
"format": "bin",
"source": "imm64.asm",
"option": "-Ox",
"target": [
{ "output": "imm64-ox.bin" },
{ "stderr": "imm64-ox.stderr" }
]
},
{
"description": "Test imm64 operations (-O1)",
"ref": "imm64",
"option": "-O1",
"target": [
{ "output": "imm64-o1.bin" },
{ "stderr": "imm64-o1.stderr" }
]
},
{
"description": "Test imm64 operations (-O0)",
"ref": "imm64",
"option": "-O0",
"target": [
{ "output": "imm64-o0.bin" },
{ "stderr": "imm64-o0.stderr" }
]
}
]