summaryrefslogtreecommitdiff
path: root/src/runtime/runtime.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/runtime.c')
-rw-r--r--src/runtime/runtime.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/runtime/runtime.c b/src/runtime/runtime.c
index f19f8e4be..a68414284 100644
--- a/src/runtime/runtime.c
+++ b/src/runtime/runtime.c
@@ -226,6 +226,12 @@ runtime·check(void)
if(z != 4)
runtime·throw("cas4");
+ z = 0xffffffff;
+ if(!runtime·cas(&z, 0xffffffff, 0xfffffffe))
+ runtime·throw("cas5");
+ if(z != 0xfffffffe)
+ runtime·throw("cas6");
+
k = (byte*)0xfedcb123;
if(sizeof(void*) == 8)
k = (byte*)((uintptr)k<<10);