X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fthreads%2Fsynch.h;h=a19e88b181dff1208839ff890154aa69b299ce91;hb=8b801a69f8e0c2c4ef7e32a2476786f80f433b8e;hp=6b8f550e8798f6b9b916cf15ce8ec72861e283a8;hpb=f35d56069db7eb1bc09f48f7f40a594718611f95;p=pintos-anon diff --git a/src/threads/synch.h b/src/threads/synch.h index 6b8f550..a19e88b 100644 --- a/src/threads/synch.h +++ b/src/threads/synch.h @@ -44,7 +44,8 @@ void cond_broadcast (struct condition *, struct lock *); /* Optimization barrier. The compiler will not reorder operations across an - optimization barrier. */ -#define barrier() asm volatile ("") + optimization barrier. See "Optimization Barriers" in the + reference guide for more information.*/ +#define barrier() asm volatile ("" : : : "memory") #endif /* threads/synch.h */