Skip to contentSkip to conversation

build: avoid putting local absolute symbols in symbol tables

PATCH In review Jan Beulich 3 participants 4 messages Mar 24, 2016 – Mar 30, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 build: avoid putting local absolute symbols in symbol tables

They're not really useful past the building stage and only needlessly increase binary file sizes.

xen/Rules.mk +1 -0
@@ -50,6 +50,7 @@ ALL_OBJS-$(CONFIG_X86)   += $(BASEDIR)/c
 CFLAGS += -nostdinc -fno-builtin -fno-common
 CFLAGS += -Werror -Wredundant-decls -Wno-pointer-arith
 CFLAGS += -pipe -g -D__XEN__ -include $(BASEDIR)/include/xen/config.h
+CFLAGS += -Wa,--strip-local-absolute
 CFLAGS += '-D__OBJECT_FILE__="$@"'
 
 CFLAGS-$(verbose)       += -DVERBOSE

build: avoid putting local absolute symbols in symbol tables

They're not really useful past the building stage and only needlessly increase binary file sizes.

xen/Rules.mk +1 -0
@@ -50,6 +50,7 @@ ALL_OBJS-$(CONFIG_X86)   += $(BASEDIR)/c
 CFLAGS += -nostdinc -fno-builtin -fno-common
 CFLAGS += -Werror -Wredundant-decls -Wno-pointer-arith
 CFLAGS += -pipe -g -D__XEN__ -include $(BASEDIR)/include/xen/config.h
+CFLAGS += -Wa,--strip-local-absolute
 CFLAGS += '-D__OBJECT_FILE__="$@"'
 
 CFLAGS-$(verbose)       += -DVERBOSE

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#2 lore raw
In reply to Jan Beulich
Quoted 9 lines · Jan Beulich

They're not really useful past the building stage and only needlessly increase binary file sizes.

xen/Rules.mk ALL_OBJS-$(CONFIG_X86) += $(BASEDIR)/c · line 56

Quoted 7 lines
xen/Rules.mk +1 -0
@@ -50,6 +50,7 @@ ALL_OBJS-$(CONFIG_X86)   += $(BASEDIR)/c
 CFLAGS += -nostdinc -fno-builtin -fno-common
 CFLAGS += -Werror -Wredundant-decls -Wno-pointer-arith
 CFLAGS += -pipe -g -D__XEN__ -include $(BASEDIR)/include/xen/config.h
+CFLAGS += -Wa,--strip-local-absolute
 CFLAGS += '-D__OBJECT_FILE__="$@"'
 
 CFLAGS-$(verbose)       += -DVERBOSE

This was committed as 607044bf9a8c8a8b37666a3a64c0d9b005875b13 and breaks the build on clang.

https://travis-ci.org/xen-project/xen/jobs/119333381#L1004
https://travis-ci.org/xen-project/xen/jobs/119333382#L1002

Signature · 1 line
Doug Goldstein

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#3 lore raw
Quoted 16 lines
Quoted 1 line
Quoted 1 line · On 29.03.16 at 22:07, <[email protected]> wrote:
Quoted 14 lines · Jan Beulich

They're not really useful past the building stage and only needlessly increase binary file sizes.

xen/Rules.mk +1 -0
@@ -50,6 +50,7 @@ ALL_OBJS-$(CONFIG_X86)   += $(BASEDIR)/c
 CFLAGS += -nostdinc -fno-builtin -fno-common
 CFLAGS += -Werror -Wredundant-decls -Wno-pointer-arith
 CFLAGS += -pipe -g -D__XEN__ -include $(BASEDIR)/include/xen/config.h
+CFLAGS += -Wa,--strip-local-absolute
 CFLAGS += '-D__OBJECT_FILE__="$@"'
 
Quoted 8 lines

xen/Rules.mk ALL_OBJS-$(CONFIG_X86) += $(BASEDIR)/c · line 56

Quoted 2 lines
xen/Rules.mk +0 -0
 CFLAGS-$(verbose)       += -DVERBOSE

This was committed as 607044bf9a8c8a8b37666a3a64c0d9b005875b13 and breaks the build on clang.

https://travis-ci.org/xen-project/xen/jobs/119333381#L1004
https://travis-ci.org/xen-project/xen/jobs/119333382#L1002

Yet I do not know clang, and hence don't know what to do about it. Care to suggest a fix (or rather workaround, considering that I'd expect them to be reasonably command line compatible with gcc)? Simply omitting the new command line option for clang is clearly not what we want.

Jan

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel