From ebafc217f9c3f932965c0581f4dbc8f19a26b37e Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Tue, 21 Nov 2006 13:26:46 +0000 Subject: [PATCH] cas(): modify assembly syntax to make it work everywhere (hopefully) --- includes/SMP.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/SMP.h b/includes/SMP.h index 89aa420..bba80f7 100644 --- a/includes/SMP.h +++ b/includes/SMP.h @@ -103,7 +103,7 @@ cas(StgVolatilePtr p, StgWord o, StgWord n) { #if i386_HOST_ARCH || x86_64_HOST_ARCH __asm__ __volatile__ ( - "lock cmpxchg %3,%1" + "lock\ncmpxchg %3,%1" :"=a"(o), "=m" (*(volatile unsigned int *)p) :"0" (o), "r" (n)); return o; -- 1.7.10.4