This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/40641] New: gcc-4.4.0 does not honor the alway_inline attribute when using -Os


This is a bug report from an OpenWrt user that I have also noticed myself.
uClibc requires its syscalls to be inlined and therefore the attribute
always_inline was added to ensure inlining.

When gcc is called with -Os the always_inline attribute is not honored,
resulting in a non working uClibc ldso. Please find the environmnet below.

This is probably related to the regression closed here:

System type: Debian testing compiling OpenWrt trunk 16656
GCC configuration: Using built-in specs.
Target: mips-openwrt-linux-uclibc
Configured with:
/home/florian/dev/openwrt/trunk/build_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/gcc-4.4.0/configure
--prefix=/home/florian/dev/openwrt/trunk/staging_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/usr
--build=i486-linux-gnu --host=i486-linux-gnu --target=mips-openwrt-linux-uclibc
--with-gnu-ld --enable-target-optspace --disable-libgomp --disable-libmudflap
--disable-multilib --disable-nls --with-float=soft
--with-gmp=/home/florian/dev/openwrt/trunk/staging_dir/host
--with-mpfr=/home/florian/dev/openwrt/trunk/staging_dir/host
--disable-decimal-float --disable-libssp --disable-__cxa_atexit
--enable-languages=c --enable-shared --enable-threads --disable-tls
--with-slibdir=/home/florian/dev/openwrt/trunk/staging_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/lib
Thread model: posix
gcc version 4.4.0 (GCC)

Compiler output:
mips-openwrt-linux-uclibc-gcc -c ldso/ldso/ldso.c -o ldso/ldso/ldso.oS -include
./include/libc-symbols.h -Wall -Wstrict-prototypes -fno-strict-aliasing -Os
-march=octeon -pipe -funit-at-a-time -fhonour-copts -msoft-float
-fno-stack-protector -fno-builtin -nostdinc -I./include -I.
-I./libc/sysdeps/linux/mips -fno-asm -msoft-float -DUCLIBC_INTERNAL -std=gnu99
-Os -funit-at-a-time -fno-tree-loop-optimize -fno-tree-dominator-opts
-fno-strength-reduce -mno-split-addresses
-I./libpthread/linuxthreads.old/sysdeps/unix/sysv/linux/mips
-I./libpthread/linuxthreads.old/sysdeps/mips
-I./libpthread/linuxthreads.old/sysdeps/unix/sysv/linux
-I./libpthread/linuxthreads.old/sysdeps/pthread -I./libpthread/linuxthreads.old
-I./libpthread
-I/home/florian/dev/openwrt/trunk/build_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/linux-dev/usr/include/
-I/home/florian/dev/openwrt/trunk/staging_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/usr/lib/gcc/mips-openwrt-linux-uclibc/4.4.0//include-fixed
-I/home/florian/dev/openwrt/trunk/staging_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/usr/lib/gcc/mips-openwrt-linux-uclibc/4.4.0/include
-DNDEBUG -mno-split-addresses -fPIC -DSHARED -DNOT_IN_libc -DIS_IN_rtld
-fno-stack-protector -E -fno-omit-frame-pointer -I./ldso/ldso/mips
-I./ldso/include -I./ldso/ldso -DUCLIBC_RUNTIME_PREFIX="/"
-DUCLIBC_LDSO="ld-uClibc.so.0" -DLDSO_ELFINTERP="mips/elfinterp.c"
-DNOT_IN_libc -DIS_IN_rtld -fno-stack-protector -E -fno-omit-frame-pointer
-I./ldso/ldso/mips -I./ldso/include -I./ldso/ldso -DUCLIBC_RUNTIME_PREFIX="/"
-DUCLIBC_LDSO="ld-uClibc.so.0" -MT ldso/ldso/ldso.oS -MD -MP -MF
ldso/ldso/.ldso.oS.dep
mips-openwrt-linux-uclibc-gcc -c ldso/ldso/mips/resolve.S -o
ldso/ldso/mips/resolve.oS -include ./include/libc-symbols.h -Wall
-Wstrict-prototypes -fno-strict-aliasing -Os -march=octeon -pipe
-funit-at-a-time -fhonour-copts -msoft-float -fno-stack-protector -fno-builtin
-nostdinc -I./include -I. -I./libc/sysdeps/linux/mips -fno-asm -msoft-float
-DUCLIBC_INTERNAL -Os -funit-at-a-time -fno-tree-loop-optimize
-fno-tree-dominator-opts -fno-strength-reduce -mno-split-addresses
-I./libpthread/linuxthreads.old/sysdeps/unix/sysv/linux/mips
-I./libpthread/linuxthreads.old/sysdeps/mips
-I./libpthread/linuxthreads.old/sysdeps/unix/sysv/linux
-I./libpthread/linuxthreads.old/sysdeps/pthread -I./libpthread/linuxthreads.old
-I./libpthread
-I/home/florian/dev/openwrt/trunk/build_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/linux-dev/usr/include/
-I/home/florian/dev/openwrt/trunk/staging_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/usr/lib/gcc/mips-openwrt-linux-uclibc/4.4.0//include-fixed
-I/home/florian/dev/openwrt/trunk/staging_dir/toolchain-mips_gcc-4.4.0_uClibc-0.9.30.1/usr/lib/gcc/mips-openwrt-linux-uclibc/4.4.0/include
-DNDEBUG -mno-split-addresses -fPIC -DSHARED -DNOT_IN_libc -DIS_IN_rtld
-fno-stack-protector -E -fno-omit-frame-pointer -I./ldso/ldso/mips
-I./ldso/include -I./ldso/ldso -DUCLIBC_RUNTIME_PREFIX="/"
-DUCLIBC_LDSO="ld-uClibc.so.0" -MT ldso/ldso/mips/resolve.oS -MD -MP -MF
ldso/ldso/mips/.resolve.oS.dep -D__ASSEMBLER__ -Wa,--noexecstack


-- 
           Summary: gcc-4.4.0 does not honor the alway_inline attribute when
                    using -Os
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: florian at openwrt dot org
 GCC build triplet: i486-linux-gnu-
  GCC host triplet: i486-linux-gnu-
GCC target triplet: mips-openwrt-linux-uclibc


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]