[llvm-commits] [compiler-rt] r167834 - in /compiler-rt/trunk/lib/tsan/rtl: tsan_rtl.cc tsan_update_shadow_word_inl.h
Dmitry Vyukov
dvyukov at google.com
Tue Nov 13 06:05:58 PST 2012
Author: dvyukov
Date: Tue Nov 13 08:05:58 2012
New Revision: 167834
URL: http://llvm.org/viewvc/llvm-project?rev=167834&view=rev
Log:
tsan: better function names
Modified:
compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc
compiler-rt/trunk/lib/tsan/rtl/tsan_update_shadow_word_inl.h
Modified: compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc?rev=167834&r1=167833&r2=167834&view=diff
==============================================================================
--- compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc (original)
+++ compiler-rt/trunk/lib/tsan/rtl/tsan_rtl.cc Tue Nov 13 08:05:58 2012
@@ -331,11 +331,11 @@
return !kAccessIsWrite && !s.is_write();
}
-static inline bool OldIsRWStronger(Shadow old, int kAccessIsWrite) {
+static inline bool OldIsRWNotWeaker(Shadow old, int kAccessIsWrite) {
return old.is_write() || !kAccessIsWrite;
}
-static inline bool OldIsRWWeaker(Shadow old, int kAccessIsWrite) {
+static inline bool OldIsRWWeakerOrEqual(Shadow old, int kAccessIsWrite) {
return !old.is_write() || kAccessIsWrite;
}
Modified: compiler-rt/trunk/lib/tsan/rtl/tsan_update_shadow_word_inl.h
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/tsan/rtl/tsan_update_shadow_word_inl.h?rev=167834&r1=167833&r2=167834&view=diff
==============================================================================
--- compiler-rt/trunk/lib/tsan/rtl/tsan_update_shadow_word_inl.h (original)
+++ compiler-rt/trunk/lib/tsan/rtl/tsan_update_shadow_word_inl.h Tue Nov 13 08:05:58 2012
@@ -34,7 +34,7 @@
if (Shadow::TidsAreEqual(old, cur)) {
StatInc(thr, StatShadowSameThread);
if (OldIsInSameSynchEpoch(old, thr)) {
- if (OldIsRWStronger(old, kAccessIsWrite)) {
+ if (OldIsRWNotWeaker(old, kAccessIsWrite)) {
// found a slot that holds effectively the same info
// (that is, same tid, same sync epoch and same size)
StatInc(thr, StatMopSame);
@@ -43,7 +43,7 @@
StoreIfNotYetStored(sp, &store_word);
break;
}
- if (OldIsRWWeaker(old, kAccessIsWrite))
+ if (OldIsRWWeakerOrEqual(old, kAccessIsWrite))
StoreIfNotYetStored(sp, &store_word);
break;
}
More information about the llvm-commits
mailing list