summaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorSøren Sandmann Pedersen <ssp@redhat.com>2012-11-29 03:32:52 -0500
committerSøren Sandmann Pedersen <ssp@redhat.com>2012-11-29 03:32:52 -0500
commit96bb19009b25053627d961ef9d3b32e30f4fac98 (patch)
tree5276a62b4f26187b2195a430882761c24b861818 /main.c
parent715101e57eec442cb2ee0e919f7aaf7543ce6c66 (diff)
Add movzx/movsx and other things
Diffstat (limited to 'main.c')
-rw-r--r--main.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/main.c b/main.c
index 3f46ee1..0015e42 100644
--- a/main.c
+++ b/main.c
@@ -150,6 +150,13 @@ main ()
"call", r13,
"sub", ax, IMM (234),
+
+ "movzx.16", esi, ax,
+ "movsx.16", rax, ax,
+ "movsx.32", rax, INDEX (rbx, 1234, rax, 8),
+ "movsx.8", rax, al,
+ "movzx.8", r9d, cl,
+ "movzx.8", r9, cl,
/* The ABI spec claims that %al is used as an "upper bound" of
* the number of vector registers used in a vararg function.
@@ -158,7 +165,8 @@ main ()
"mov", al, IMM (0),
"mov", r9l, IMM (0),
"mov", ah, IMM (8),
- "xor", ah, al,
+ "xor", bh, r9l,
+ "xor", r9l, al,
"mov", r13, RIP_REL ("printf"),
"mov", rdi, RIP_REL ("hello2"),
"call", r13,