[tip:tools/kvm] kvm tools: disable LTO by default

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Commit-ID:  5b63a37435f5dd4f8956351a5af5a57efe827e77
Gitweb:     http://git.kernel.org/tip/5b63a37435f5dd4f8956351a5af5a57efe827e77
Author:     Sasha Levin <sasha.levin@xxxxxxxxxx>
AuthorDate: Mon, 19 Nov 2012 19:31:30 -0500
Committer:  Pekka Enberg <penberg@xxxxxxxxxx>
CommitDate: Tue, 20 Nov 2012 08:55:25 +0200

kvm tools: disable LTO by default

A bug only seen with LTO enabled was reported by Ron Minnich. Since the issue
appears to be a linker issue, we disable LTO by default until it's more stable.

We can still run LTO builds by setting LTO=1.

Reported-by: Ron Minnich <rminnich@xxxxxxxxx>
Signed-off-by: Sasha Levin <sasha.levin@xxxxxxxxxx>
Signed-off-by: Pekka Enberg <penberg@xxxxxxxxxx>
---
 tools/kvm/Makefile | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/tools/kvm/Makefile b/tools/kvm/Makefile
index c105de1..de11060 100644
--- a/tools/kvm/Makefile
+++ b/tools/kvm/Makefile
@@ -221,9 +221,11 @@ ifeq ($(call try-cc,$(SOURCE_AIO),$(FLAGS_AIO) -static),y)
 	LIBS_STATOPT	+= -laio
 endif
 
-FLAGS_LTO := -flto
-ifeq ($(call try-cc,$(SOURCE_HELLO),$(FLAGS_LTO)),y)
-	CFLAGS		+= $(FLAGS_LTO)
+ifeq ($(LTO),1)
+	FLAGS_LTO := -flto
+	ifeq ($(call try-cc,$(SOURCE_HELLO),$(FLAGS_LTO)),y)
+		CFLAGS		+= $(FLAGS_LTO)
+	endif
 endif
 
 ifneq ($(call try-build,$(SOURCE_STATIC),-static,),y)
--
To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Stable Commits]     [Linux Stable Kernel]     [Linux Kernel]     [Linux USB Devel]     [Linux Video &Media]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux