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 target/22447] New: gcc produces code that generate unaligned exceptions


/usr/test/bin/gcc -v
Using built-in specs.
Target: alpha-redhat-linux
Configured with: ../configure --prefix=/usr/test --enable-shared
--enable-threads=posix --enable-checking=release --with-system-zlib
--enable-__cxa_atexit --disable-libunwind-exceptions --host=alpha-redhat-linux
--enable-languages=c,c++
Thread model: posix
gcc version 4.0.2 20050712 (prerelease)
and
gcc -v
Using built-in specs.
Target: alpha-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man
--infodir=/usr/share/info --enable-shared --enable-threads=posix
--enable-checking=release --with-system-zlib --enable-__cxa_atexit
--disable-libunwind-exceptions --enable-libgcj-multifile
--enable-languages=c,c++,objc,java,f95 --enable-java-awt=gtk
--with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --host=alpha-redhat-linux
Thread model: posix
gcc version 4.0.0 20050519 (Red Hat 4.0.0-8)

Both version of compilers produce the code that generates unaligned exceptions
on EV4 processor. 
Instead of generating the code to store a byte using unaligned load/store
instruction it uses aligned LDL/STL. The assembler code looks correct using -O0
optimization flag and incorrect with -O1 and -O2. I tried to write smaler test
case with the same pattern, but compiler compiles it correctly, so I am
attaching the original preprocessed source. The function to look at:
init_one_value. Check the byte manupilation code.

Thank you,

-- 
           Summary: gcc produces code that generate unaligned exceptions
           Product: gcc
           Version: 4.0.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tsv at solvo dot ru
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: alpha-redhat-linux-gnu
  GCC host triplet: alpha-redhat-linux-gnu
GCC target triplet: alpha-redhat-linux-gnu


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


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