Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
P
protobuf
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
protobuf
Commits
da89eb25
Unverified
Commit
da89eb25
authored
Nov 30, 2017
by
Feng Xiao
Committed by
GitHub
Nov 30, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #3955 from linux-on-ibm-z/master
Adding Release_CompareAndSwap 64-bit variant
parents
6d609955
642e1ac6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
atomicops_internals_generic_gcc.h
src/google/protobuf/stubs/atomicops_internals_generic_gcc.h
+8
-0
No files found.
src/google/protobuf/stubs/atomicops_internals_generic_gcc.h
View file @
da89eb25
...
...
@@ -146,6 +146,14 @@ inline Atomic64 NoBarrier_Load(volatile const Atomic64* ptr) {
return
__atomic_load_n
(
ptr
,
__ATOMIC_RELAXED
);
}
inline
Atomic64
Release_CompareAndSwap
(
volatile
Atomic64
*
ptr
,
Atomic64
old_value
,
Atomic64
new_value
)
{
__atomic_compare_exchange_n
(
ptr
,
&
old_value
,
new_value
,
false
,
__ATOMIC_RELEASE
,
__ATOMIC_ACQUIRE
);
return
old_value
;
}
#endif // defined(__LP64__)
}
// namespace internal
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment