Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(614)

Unified Diff: src/atomicops_internals_x86_gcc.h

Issue 228613005: Introduced Atomic8 and added no-barrier Atomic8 accessors. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/atomicops_internals_tsan.h ('k') | src/atomicops_internals_x86_msvc.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/atomicops_internals_x86_gcc.h
diff --git a/src/atomicops_internals_x86_gcc.h b/src/atomicops_internals_x86_gcc.h
index e58d598fbd4ea97cf84917bcafbde928626bfa04..1624b8238907afed62da0de405d1bd74f40909f1 100644
--- a/src/atomicops_internals_x86_gcc.h
+++ b/src/atomicops_internals_x86_gcc.h
@@ -107,6 +107,10 @@ inline Atomic32 Release_CompareAndSwap(volatile Atomic32* ptr,
return NoBarrier_CompareAndSwap(ptr, old_value, new_value);
}
+inline void NoBarrier_Store(volatile Atomic8* ptr, Atomic8 value) {
+ *ptr = value;
+}
+
inline void NoBarrier_Store(volatile Atomic32* ptr, Atomic32 value) {
*ptr = value;
}
@@ -152,6 +156,10 @@ inline void Release_Store(volatile Atomic32* ptr, Atomic32 value) {
// See comments in Atomic64 version of Release_Store(), below.
}
+inline Atomic8 NoBarrier_Load(volatile const Atomic8* ptr) {
+ return *ptr;
+}
+
inline Atomic32 NoBarrier_Load(volatile const Atomic32* ptr) {
return *ptr;
}
« no previous file with comments | « src/atomicops_internals_tsan.h ('k') | src/atomicops_internals_x86_msvc.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698