[PATCH] [Sanitizers] Enable stack traces on recent versions of FreeBSD

Alexey Samsonov vonosmas at gmail.com
Mon Nov 3 11:28:38 PST 2014


================
Comment at: lib/sanitizer_common/sanitizer_stacktrace.h:56
@@ +55,3 @@
+#elif SANITIZER_FREEBSD
+# if __FreeBSD_version <= 902001  // v9.2
+    const bool UseFastUnwind = true;
----------------
kutuzov.viktor.84 wrote:
> emaste wrote:
> > Did you check that 9.3 works?  (I'm curious if the test should actually be for FreeBSD version < 10.0 .)
> > 
> > 
> > 
> > 
> > 
> I didn't check it on 9.3 and I'm not sure if there is a simple way to find the revision affected the behavior of _Unwind_Backtrace().
Why did you switch to const bool instead of returns?
Also, I think it would be cleaner to introduce SANITIZER_CAN_SLOW_UNWIND macro next to SANITIZER_CAN_FAST_UNWIND

http://reviews.llvm.org/D6086






More information about the llvm-commits mailing list