Last Comment Bug 762675 - MOZ_CRASH() should have noreturn semantics
: MOZ_CRASH() should have noreturn semantics
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: MFBT (show other bugs)
: unspecified
: All All
: -- normal (vote)
: ---
Assigned To: Nobody; OK to take it and work on it
:
Mentors:
Depends on:
Blocks: 761859
  Show dependency treegraph
 
Reported: 2012-06-07 14:22 PDT by Jeff Walden [:Waldo] (remove +bmo to email)
Modified: 2012-06-19 15:51 PDT (History)
1 user (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments

Description Jeff Walden [:Waldo] (remove +bmo to email) 2012-06-07 14:22:44 PDT
Compilers aren't informed that MOZ_CRASH() will halt execution, so compilers expect control flow might proceed past it, leading to suboptimal code and the possibility of build warnings.  See bug 761859 comment 5.
Comment 1 Jeff Walden [:Waldo] (remove +bmo to email) 2012-06-19 15:41:36 PDT
Fixed in bug 763000.
Comment 2 Mike Hommey [:glandium] 2012-06-19 15:51:20 PDT
The problem with this is that it also allows the compiler to do some optimizations that don't help when doing a stack trace. Specifically, on ARM, the compiler may not preserve the lr register which is detrimental to getting good stack traces, and thus good crash reports. See bug 697301.

Note You need to log in before you can comment on or make changes to this bug.