[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 2/6] lockable: workaround GCC link issue with ASAN
From: |
Marc-André Lureau |
Subject: |
[Qemu-devel] [PATCH 2/6] lockable: workaround GCC link issue with ASAN |
Date: |
Thu, 15 Feb 2018 22:25:48 +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 <address@hidden>
---
include/qemu/lockable.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/qemu/lockable.h b/include/qemu/lockable.h
index b6ed6c89ec..84ea794bcf 100644
--- a/include/qemu/lockable.h
+++ b/include/qemu/lockable.h
@@ -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)
--
2.16.1.73.g5832b7e9f2
- [Qemu-devel] [PATCH 0/6] vhost-user-test and leak fixes, Marc-André Lureau, 2018/02/15
- [Qemu-devel] [PATCH 2/6] lockable: workaround GCC link issue with ASAN,
Marc-André Lureau <=
- [Qemu-devel] [PATCH 6/6] sdhci-test: fix leaks, Marc-André Lureau, 2018/02/15
- [Qemu-devel] [PATCH 5/6] ahci-test: fix opts leak of skip tests, Marc-André Lureau, 2018/02/15
- [Qemu-devel] [PATCH 4/6] vhost-user-test: do not hang if chardev creation failed, Marc-André Lureau, 2018/02/15
- [Qemu-devel] [PATCH 3/6] vhost-user-test: add back memfd check, Marc-André Lureau, 2018/02/15
- [Qemu-devel] [PATCH 1/6] build-sys: fix -fsanitize=address check, Marc-André Lureau, 2018/02/15