[LLVMbugs] [Bug 12012] New: Clang asserts when compiling libcxx against FreeBSD-HEAD on Intel Atom

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Wed Feb 15 15:52:20 PST 2012


http://llvm.org/bugs/show_bug.cgi?id=12012

             Bug #: 12012
           Summary: Clang asserts when compiling libcxx against
                    FreeBSD-HEAD on Intel Atom
           Product: clang
           Version: trunk
          Platform: PC
        OS/Version: FreeBSD
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: LLVM Codegen
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: ed at extraordinarymachine.nl
                CC: llvmbugs at cs.uiuc.edu
    Classification: Unclassified


Created attachment 8060
  --> http://llvm.org/bugs/attachment.cgi?id=8060
Command arguments

System:
FreeBSD-9.0 on Intel Atom (amd64). Compiling with Clang ToT against
FreeBSD-HEAD headers.

I do see warnings flying by about additional padding bytes, but that should
create assertions, should it?

Attached are build script and .ii and .sh files.

-- Edward

Partial output:
---------------
In file included from /home/emeewis/contrib/FreeBSD-HEAD/include/xlocale.h:134:
/home/emeewis/contrib/FreeBSD-HEAD/include/_xlocale_ctype.h:57:43: warning:
implicit conversion loses integer
      precision: 'unsigned long' to 'int' [-Wshorten-64-to-32]
        return (_c < 0 || _c >= _CACHED_RUNES) ? ___runetype_l(_c, locale) :
                                               ~ ^~~~~~~~~~~~~~~~~~~~~~~~~
/home/emeewis/contrib/FreeBSD-HEAD/include/_xlocale_ctype.h:58:31: warning:
implicit conversion loses integer
      precision: 'unsigned long' to 'int' [-Wshorten-64-to-32]
               runes->__runetype[_c] & _f;
               ~~~~~~~~~~~~~~~~~~~~~~^~~~
In file included from ../src/iostream.cpp:10:
In file included from ../include/__std_stream:15:
In file included from ../include/ostream:130:
In file included from ../include/ios:216:
In file included from ../include/__locale:15:
In file included from ../include/string:432:
In file included from ../include/cstdio:100:
/home/emeewis/contrib/FreeBSD-HEAD/include/stdio.h:77:8: warning: padding size
of '__sbuf' with 4 bytes to alignment
      boundary [-Wpadded]
struct __sbuf {
       ^
/home/emeewis/contrib/FreeBSD-HEAD/include/stdio.h:116:16: warning: padding
struct '__sFILE' with 4 bytes to align
      '_bf' [-Wpadded]
        struct  __sbuf _bf;     /* (*) the buffer (at least 1 byte, if !NULL)
*/
                       ^
/home/emeewis/contrib/FreeBSD-HEAD/include/stdio.h:120:8: warning: padding
struct '__sFILE' with 4 bytes to align
      '_cookie' [-Wpadded]
        void    *_cookie;       /* (*) cookie passed to io functions */
                 ^
/home/emeewis/contrib/FreeBSD-HEAD/include/stdio.h:140:9: warning: padding
struct '__sFILE' with 4 bytes to align
      '_offset' [-Wpadded]
        fpos_t  _offset;        /* current lseek offset */
                ^
Assertion failed: (CXXInfo->BaseOffsets.count(Base) && "Did not find base!"),
function getBaseClassOffset, file
/usr/home/emeewis/contrib/llvm/tools/clang/lib/CodeGen/../../include/clang/AST/RecordLayout.h,
line 173.
Stack dump:
0.      Program arguments: /usr/local/bin/clang -cc1 -triple
x86_64-unknown-freebsd9.0 -emit-obj -disable-free -main-file-name iostream.cpp
-pic-level 2 -mdisable-fp-elim -masm-verbose -mconstructor-aliases
-munwind-tables -target-cpu x86-64 -momit-leaf-frame-pointer -g -coverage-file
iostream.o -nostdsysteminc -nobuiltininc -resource-dir
/usr/local/bin/../lib/clang/3.1 -I ../include -I
/home/emeewis/contrib/FreeBSD-HEAD/include -I
/home/emeewis/contrib/FreeBSD-HEAD/lib/msun/src -I
/home/emeewis/contrib/FreeBSD-HEAD/sys -I
/home/emeewis/contrib/FreeBSD-HEAD/sys/amd64/include -I
/home/emeewis/contrib/FreeBSD-HEAD/sys/sys -fmodule-cache-path
/var/tmp/clang-module-cache -Os -Wall -Wextra -Wshadow -Wconversion
-Wnewline-eof -Wpadded -Wmissing-prototypes -Wstrict-aliasing=2
-Wstrict-overflow=4 -std=c++11 -fdeprecated-macro -fdebug-compilation-dir
/home/emeewis/contrib/llvm/projects/libcxx/lib -ferror-limit 19
-fmessage-length 116 -mstackrealign -fgnu-runtime -fobjc-runtime-has-arc
-fobjc-runtime-has-weak -fobjc-fragile-abi -fcxx-exceptions -fexceptions
-fdiagnostics-show-option -fcolor-diagnostics -o iostream.o -x c++
../src/iostream.cpp
1.      <eof> parser at end of file
2.      ../src/iostream.cpp:13:1 <Spelling=../include/__config:249:47>: LLVM IR
generation of declaration 'std'
3.      ../src/iostream.cpp:22:9: Generating code for declaration
'std::__1::cin'
clang: error: unable to execute command: Abort trap: 6 (core dumped)

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



More information about the llvm-bugs mailing list