summary refs log tree commit diff
path: root/ops.h
diff options
context:
space:
mode:
authorBor Grošelj Simić <bor.groseljsimic@telemach.net>2022-01-28 02:06:18 +0100
committerQuentin Carbonneaux <quentin@c9x.me>2022-01-28 09:24:15 +0100
commit3964574a8325ab802f98856195b8214dcce3124c (patch)
tree0ac6128a201088b186d642b990a02c6e78cf715a /ops.h
parent74d022f975f22fda20c0d1fe09a3f6fc7680f64f (diff)
downloadroux-3964574a8325ab802f98856195b8214dcce3124c.tar.gz
implement float -> unsigned casts
amd64 lacks instruction for this so it has to be implemented with
float -> signed casts. The approach is borrowed from llvm.
Diffstat (limited to 'ops.h')
-rw-r--r--ops.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/ops.h b/ops.h
index 04b0cf8..9f02262 100644
--- a/ops.h
+++ b/ops.h
@@ -96,7 +96,9 @@ O(extuw,   T(e,w,e,e, e,x,e,e), 1) X(0, 0, 1)
 O(exts,    T(e,e,e,s, e,e,e,x), 1) X(0, 0, 1)
 O(truncd,  T(e,e,d,e, e,e,x,e), 1) X(0, 0, 1)
 O(stosi,   T(s,s,e,e, x,x,e,e), 1) X(0, 0, 1)
+O(stoui,   T(s,s,e,e, x,x,e,e), 1) X(0, 0, 1)
 O(dtosi,   T(d,d,e,e, x,x,e,e), 1) X(0, 0, 1)
+O(dtoui,   T(d,d,e,e, x,x,e,e), 1) X(0, 0, 1)
 O(swtof,   T(e,e,w,w, e,e,x,x), 1) X(0, 0, 1)
 O(uwtof,   T(e,e,w,w, e,e,x,x), 1) X(0, 0, 1)
 O(sltof,   T(e,e,l,l, e,e,x,x), 1) X(0, 0, 1)