Bug 1465452 Part 6 - Don't record assertion crashing flag, r=froydnj.
authorBrian Hackett <bhackett1024@gmail.com>
Sat, 21 Jul 2018 14:31:21 +0000
changeset 482776 ef7ed9b4ee4957960bbfe6370a0282f7e362a77e
parent 482775 7b542f98c02c0a22e57ef7472b71cb8659d5058c
child 482777 554c3f761c64f0bc0bb706a481c9f6950025fe7c
push id9719
push userffxbld-merge
push dateFri, 24 Aug 2018 17:49:46 +0000
treeherdermozilla-beta@719ec98fba77 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfroydnj
bugs1465452
milestone63.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1465452 Part 6 - Don't record assertion crashing flag, r=froydnj.
mfbt/Assertions.cpp
--- a/mfbt/Assertions.cpp
+++ b/mfbt/Assertions.cpp
@@ -29,17 +29,22 @@ MOZ_CrashOOL(const char* aFilename, int 
 #ifdef DEBUG
   MOZ_ReportCrash(aReason, aFilename, aLine);
 #endif
   gMozCrashReason = aReason;
   MOZ_REALLY_CRASH(aLine);
 }
 
 static char sPrintfCrashReason[sPrintfCrashReasonSize] = {};
-static mozilla::Atomic<bool> sCrashing(false);
+
+// Accesses to this atomic are not included in web replay recordings, so that
+// if we crash in an area where recorded events are not allowed the true reason
+// for the crash is not obscured by a record/replay error.
+static mozilla::Atomic<bool, mozilla::SequentiallyConsistent,
+                       mozilla::recordreplay::Behavior::DontPreserve> sCrashing(false);
 
 #ifndef DEBUG
 MFBT_API MOZ_COLD MOZ_NORETURN MOZ_NEVER_INLINE MOZ_FORMAT_PRINTF(2, 3) void
 MOZ_CrashPrintf(int aLine, const char* aFormat, ...)
 #else
 MFBT_API MOZ_COLD MOZ_NORETURN MOZ_NEVER_INLINE MOZ_FORMAT_PRINTF(3, 4) void
 MOZ_CrashPrintf(const char* aFilename, int aLine, const char* aFormat, ...)
 #endif