]> Git Repo - qemu.git/commitdiff
lockable: workaround GCC link issue with ASAN
authorMarc-André Lureau <[email protected]>
Thu, 15 Feb 2018 21:25:48 +0000 (22:25 +0100)
committerPaolo Bonzini <[email protected]>
Tue, 6 Mar 2018 13:01:27 +0000 (14:01 +0100)
Current GCC has an optimization bug when compiling with ASAN.

See also GCC bug:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84307

Signed-off-by: Marc-André Lureau <[email protected]>
Message-Id: <20180215212552[email protected]>
Signed-off-by: Paolo Bonzini <[email protected]>
include/qemu/lockable.h

index b6ed6c89ec745d4a05b9c39c88de9d2010cbe335..84ea794bcf616f7f06f85f342bbb60652ad45371 100644 (file)
@@ -28,7 +28,7 @@ struct QemuLockable {
  * to QEMU_MAKE_LOCKABLE.  For optimized builds, we can rely on dead-code elimination
  * from the compiler, and give the errors already at link time.
  */
-#ifdef __OPTIMIZE__
+#if defined(__OPTIMIZE__) && !defined(__SANITIZE_ADDRESS__)
 void unknown_lock_type(void *);
 #else
 static inline void unknown_lock_type(void *unused)
This page took 0.021494 seconds and 4 git commands to generate.