[git commit] build system: combat gcc zealotry in data alignment, now for x86_64 too

Denys Vlasenko vda.linux at googlemail.com
Tue Dec 15 17:39:05 UTC 2020


commit: https://git.busybox.net/busybox/commit/?id=fad8d6b6c0290e92b89cd18493c0c336f3619ee1
branch: https://git.busybox.net/busybox/commit/?id=refs/heads/master

function                                             old     new   delta
.rodata                                           182928  182620    -308

Signed-off-by: Denys Vlasenko <vda.linux at googlemail.com>
---
 arch/x86_64/Makefile | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/arch/x86_64/Makefile b/arch/x86_64/Makefile
new file mode 100644
index 000000000..16576fb81
--- /dev/null
+++ b/arch/x86_64/Makefile
@@ -0,0 +1,11 @@
+# ==========================================================================
+# Build system
+# ==========================================================================
+
+# "Control how GCC aligns variables.
+# Supported values for type are compat uses increased alignment value
+# compatible uses GCC 4.8 and earlier, abi uses alignment value as specified by the psABI,
+# and cacheline uses increased alignment value to match the cache line size.
+# compat is the default."
+# "abi" seems to be somewhat successful in preventing oversealous data alignment.
+CFLAGS += $(call cc-option,-malign-data=abi,)


More information about the busybox-cvs mailing list