From: Paul Eggert Date: Tue, 12 Feb 2013 18:33:42 +0000 (-0800) Subject: * pre-crt0.c (data_start): Initialize to 1. X-Git-Tag: emacs-24.3-rc1~68 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=4458c2551b1a0bd89e5c299b009516e17f255c28;p=emacs.git * pre-crt0.c (data_start): Initialize to 1. This ports to compilers that optimize the external declaration 'int x = 0;' as if it were 'int x;' to shrink the executable. --- diff --git a/src/ChangeLog b/src/ChangeLog index 8397e3d26ec..95e58e2d92c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2013-02-12 Paul Eggert + + * pre-crt0.c (data_start): Initialize to 1. + This ports to compilers that optimize the external declaration + 'int x = 0;' as if it were 'int x;' to shrink the executable. + 2013-02-11 Paul Eggert Improve AIX port (Bug#13650). diff --git a/src/pre-crt0.c b/src/pre-crt0.c index ea5736eba2a..6b9618c8dc3 100644 --- a/src/pre-crt0.c +++ b/src/pre-crt0.c @@ -4,7 +4,7 @@ that make environ an initialized variable. However, we do need to make sure the label data_start exists anyway. */ -/* Create a label to appear at the beginning of data space. */ - -int data_start = 0; +/* Create a label to appear at the beginning of data space. + Its value is nonzero so that it cannot be put into bss. */ +int data_start = 1;