http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45996

--- Comment #2 from Udo Steinberg <us15 at os dot inf.tu-dresden.de> 2010-10-13 
12:06:32 UTC ---
Created attachment 22029
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=22029
Testcase

gcc -Os -falign-functions=32 foo.cc -o foo
nm foo | c++filt | grep func_
00000000004004f6 T func_bar()
0000000000400500 T func_baz()
00000000004004ec T func_foo()

gcc -falign-functions=32 foo.cc -o foo
nm foo | c++filt | grep func_
0000000000400520 T func_bar()
0000000000400540 T func_baz()
0000000000400500 T func_foo()

So it seems to be related to the -Os option. My gcc is configured as follows:

gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-slackware-linux/4.6.0/lto-wrapper
Target: x86_64-slackware-linux
Configured with: ../gcc-svn/configure --prefix=/usr --libdir=/usr/lib64
--enable-shared --enable-bootstrap --enable-languages=c,c++
--enable-threads=posix --enable-checking=release --with-system-zlib
--disable-libunwind-exceptions --enable-__cxa_atexit --enable-libssp
--with-gnu-ld --verbose --disable-multilib --target=x86_64-slackware-linux
--build=x86_64-slackware-linux --host=x86_64-slackware-linux
Thread model: posix
gcc version 4.6.0 20101005 (experimental) (GCC)

Reply via email to