summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2013-11-26 18:24:22 -0800
committerH. Peter Anvin <hpa@zytor.com>2013-11-26 18:24:22 -0800
commit186b533425405ac4e1172c7f0e6751848f04aabd (patch)
treeb250a4b6174041524ef0a098f144db2335e58b17
parent89a2ac0d0aabb586f0f6f051a721a1f2256c7492 (diff)
downloadnasm-186b533425405ac4e1172c7f0e6751848f04aabd.tar.gz
test: Add a test for various 32- and 64-bit relocations
Test signedness in a couple of different contexts. Signed-off-by: H. Peter Anvin <hpa@zytor.com>
-rw-r--r--test/relocs.asm13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/relocs.asm b/test/relocs.asm
new file mode 100644
index 00000000..a293f50f
--- /dev/null
+++ b/test/relocs.asm
@@ -0,0 +1,13 @@
+ bits 64
+ extern foo
+
+ mov eax,[foo]
+ mov rax,[foo]
+ mov rax,[qword foo]
+
+ mov eax,foo
+ mov rax,dword foo
+ mov rax,qword foo
+
+ dd foo
+ dq foo