diff options
author | Tim Deegan <Tim.Deegan@citrix.com> | 2011-03-07 11:34:09 +0000 |
---|---|---|
committer | Tim Deegan <Tim.Deegan@citrix.com> | 2011-03-07 11:34:09 +0000 |
commit | e4cdd74f02eaeea96348dc51534eff8e03d87697 (patch) | |
tree | 7e6947edf542bd1c6e87205fe7e7cec3d0388fa9 /xen/arch/x86/boot | |
parent | 436323c065f0ace4f469f5854f43423702a5082a (diff) | |
download | xen-e4cdd74f02eaeea96348dc51534eff8e03d87697.tar.gz xen-e4cdd74f02eaeea96348dc51534eff8e03d87697.tar.bz2 xen-e4cdd74f02eaeea96348dc51534eff8e03d87697.zip |
xen: add "lto=y" option to build Xen with link-time optimizations.
This involves gathering object files from .asm (which will be binary)
and object files from .c (which will be in LTO format) separately
until the final link.
Only tested for x86_64 Xen builds using Clang/LLVM bitcode; it should be
possible to do the same with newer GCCs and GIMPLE.
Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Acked-by: Keir Fraser <keir@xen.org>
Diffstat (limited to 'xen/arch/x86/boot')
-rw-r--r-- | xen/arch/x86/boot/Makefile | 2 | ||||
-rw-r--r-- | xen/arch/x86/boot/build32.mk | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/xen/arch/x86/boot/Makefile b/xen/arch/x86/boot/Makefile index 3a1f91240a..fb921173c2 100644 --- a/xen/arch/x86/boot/Makefile +++ b/xen/arch/x86/boot/Makefile @@ -1,4 +1,4 @@ -obj-y += head.o +obj-bin-y += head.o head.o: reloc.S diff --git a/xen/arch/x86/boot/build32.mk b/xen/arch/x86/boot/build32.mk index 1364d3b509..4dfb12f0a6 100644 --- a/xen/arch/x86/boot/build32.mk +++ b/xen/arch/x86/boot/build32.mk @@ -6,6 +6,7 @@ include $(XEN_ROOT)/Config.mk $(call cc-options-add,CFLAGS,CC,$(EMBEDDED_EXTRA_CFLAGS)) CFLAGS += -Werror -fno-builtin -msoft-float +CFLAGS := $(filter-out -flto,$(CFLAGS)) # NB. awk invocation is a portable alternative to 'head -n -1' %.S: %.bin |