[llvm-bugs] [Bug 29086] New: Clang didn't emit the right debug information for vla a[3][m]
https://llvm.org/bugs/show_bug.cgi?id=29086 Bug ID: 29086 Summary: Clang didn't emit the right debug information for vla a[3][m] Product: clang Version: trunk Hardware: PC OS: Windows NT Status: NEW Severity: normal Priority: P Component: Frontend Assignee: unassignedclangb...@nondot.org Reporter: qsh...@cn.ibm.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified > cat a.C int m; int main() { int a[3][m]; return a[0][0]; } > clang++ a.C -g -S -emit-llvm > cat a.ll call void @llvm.dbg.declare(metadata i32* %7, metadata !14, metadata !18), !dbg !19 !14 = !DILocalVariable(name: "a", scope: !9, file: !1, line: 4, type: !15) !15 = !DICompositeType(tag: DW_TAG_array_type, baseType: !5, align: 32, elements: !16) !16 = !{!17, !17} !17 = !DISubrange(count: -1) > clang -v clang version 4.0.0 (trunk) Note that, clang emit both two subrange as "-1" which is not right. It should be "3" and "-1". -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29087] New: Assertion `isa(Val) && "cast() argument of incompatible type!"' failed from EvaluateUnaryTypeTrait in lib/Sema/SemaExprCXX.cpp
https://llvm.org/bugs/show_bug.cgi?id=29087 Bug ID: 29087 Summary: Assertion `isa(Val) && "cast() argument of incompatible type!"' failed from EvaluateUnaryTypeTrait in lib/Sema/SemaExprCXX.cpp Product: clang Version: trunk Hardware: PC OS: All Status: NEW Severity: normal Priority: P Component: C++11 Assignee: unassignedclangb...@nondot.org Reporter: t...@fb.com CC: dgre...@apple.com, llvm-bugs@lists.llvm.org Classification: Unclassified Created attachment 17023 --> https://llvm.org/bugs/attachment.cgi?id=17023&action=edit preprocess test case ### Repro test case: #include struct X { X() {} }; struct Y : public X { public: using X::X; }; int main() { assert(__has_nothrow_constructor(Y)); } ### Stack trace: /data/users/twoh/llvms/latest-dev/build-debug/bin/clang -std=c++11 -O0 -c -o test.o test.cpp clang-3.9: /home/twoh/llvms/latest-dev/llvm/include/llvm/Support/Casting.h:237: typename llvm::cast_retty::ret_type llvm::cast(Y*) [with X = clang::CXXConstructorDecl; Y = const clang::NamedDecl; typename llvm::cast_retty::ret_type = const clang::CXXConstructorDecl*]: Assertion `isa(Val) && "cast() argument of incompatible type!"' failed. #0 0x0290683d llvm::sys::PrintStackTrace(llvm::raw_ostream&) /home/twoh/llvms/latest-dev/llvm/lib/Support/Unix/Signals.inc:402:0 #1 0x02906bff PrintStackTraceSignalHandler(void*) /home/twoh/llvms/latest-dev/llvm/lib/Support/Unix/Signals.inc:470:0 #2 0x02904f6a llvm::sys::RunSignalHandlers() /home/twoh/llvms/latest-dev/llvm/lib/Support/Signals.cpp:44:0 #3 0x029061ce SignalHandler(int) /home/twoh/llvms/latest-dev/llvm/lib/Support/Unix/Signals.inc:256:0 #4 0x7f373bebc100 __restore_rt (/lib64/libpthread.so.0+0xf100) #5 0x7f373aab45f7 __GI_raise (/lib64/libc.so.6+0x355f7) #6 0x7f373aab5ce8 __GI_abort (/lib64/libc.so.6+0x36ce8) #7 0x7f373aaad566 __assert_fail_base (/lib64/libc.so.6+0x2e566) #8 0x7f373aaad612 (/lib64/libc.so.6+0x2e612) #9 0x02ccc4a0 llvm::cast_retty::ret_type llvm::cast(clang::NamedDecl const*) /home/twoh/llvms/latest-dev/llvm/include/llvm/Support/Casting.h:239:0 #10 0x045e91f5 EvaluateUnaryTypeTrait(clang::Sema&, clang::TypeTrait, clang::SourceLocation, clang::QualType) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Sema/SemaExprCXX.cpp:4262:0 #11 0x045e94a4 evaluateTypeTrait(clang::Sema&, clang::TypeTrait, clang::SourceLocation, llvm::ArrayRef, clang::SourceLocation) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Sema/SemaExprCXX.cpp:4325:0 #12 0x045e9db1 clang::Sema::BuildTypeTrait(clang::TypeTrait, clang::SourceLocation, llvm::ArrayRef, clang::SourceLocation) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Sema/SemaExprCXX.cpp:4450:0 #13 0x045e9f44 clang::Sema::ActOnTypeTrait(clang::TypeTrait, clang::SourceLocation, llvm::ArrayRef >, clang::SourceLocation) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Sema/SemaExprCXX.cpp:4471:0 #14 0x03fab253 clang::Parser::ParseTypeTrait() /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExprCXX.cpp:3025:0 #15 0x03f95009 clang::Parser::ParseCastExpression(bool, bool, bool&, clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:1318:0 #16 0x03f9179a clang::Parser::ParseCastExpression(bool, bool, clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:481:0 #17 0x03f90450 clang::Parser::ParseAssignmentExpression(clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:170:0 #18 0x03f90254 clang::Parser::ParseExpression(clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:120:0 #19 0x03f99e6b clang::Parser::ParseParenExpression(clang::Parser::ParenParseOption&, bool, bool, clang::OpaquePtr&, clang::SourceLocation&) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:2412:0 #20 0x03f91af7 clang::Parser::ParseCastExpression(bool, bool, bool&, clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:723:0 #21 0x03f9179a clang::Parser::ParseCastExpression(bool, bool, clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:481:0 #22 0x03f90450 clang::Parser::ParseAssignmentExpression(clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:170:0 #23 0x03f90254 clang::Parser::ParseExpression(clang::Parser::TypeCastState) /home/twoh/llvms/latest-dev/llvm/tools/clang/lib/Parse/ParseExpr.cpp:120:0 #24 0x03f99e6b clang::Parser::ParseParenExpression(clang::Parser::ParenParseOption&, bool, bool, clang::OpaquePtr&, clang::SourceL
[llvm-bugs] [Bug 28661] [AVX512] incorrect code for boolean expression at -O0.
https://llvm.org/bugs/show_bug.cgi?id=28661 Guy Blank changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED --- Comment #1 from Guy Blank --- Fixed in revision 279393. https://reviews.llvm.org/rL279393 -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29088] New: Rev. 276416 ruins LLC.
https://llvm.org/bugs/show_bug.cgi?id=29088 Bug ID: 29088 Summary: Rev. 276416 ruins LLC. Product: tools Version: trunk Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: llc Assignee: unassignedb...@nondot.org Reporter: shishpanov2...@yandex.ru CC: llvm-bugs@lists.llvm.org Classification: Unclassified Created attachment 17025 --> https://llvm.org/bugs/attachment.cgi?id=17025&action=edit reproducer In r276416 LLC with attached test file emits this: "LLVM ERROR: Cannot select: t142: v8i32 = X86ISD::SUBV_BROADCAST t121 ". Key to launch: -mcpu=corei7-avx -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29090] New: Invalid diagnostic on conversion error of implicit object parameter for ref-qualified methods
https://llvm.org/bugs/show_bug.cgi?id=29090 Bug ID: 29090 Summary: Invalid diagnostic on conversion error of implicit object parameter for ref-qualified methods Product: clang Version: 3.9 Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: C++11 Assignee: unassignedclangb...@nondot.org Reporter: clement.cour...@gmail.com CC: dgre...@apple.com, llvm-bugs@lists.llvm.org Classification: Unclassified refref.cc: struct A { void f() && {} }; void g() { A a; a.f(); } clang++ -std=c++11 -c refref.cc refref.cc:7:3: error: cannot initialize object parameter of type 'A' with an expression of type 'A' a.f(); I would expect: refref.cc:7:3: error: cannot initialize object parameter of type 'A&&' with an expression of type 'A' a.f(); Or: refref.cc:7:3: error:member function 'f' not viable: 'this' argument has type 'A', but function is marked &&. (the latter is modeled after the error message when a is const but f() is not const-qualified) -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29091] New: ICE when using boost::container::small_vector
https://llvm.org/bugs/show_bug.cgi?id=29091 Bug ID: 29091 Summary: ICE when using boost::container::small_vector Product: clang Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: Frontend Assignee: unassignedclangb...@nondot.org Reporter: gonzalob...@gmail.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified I get the following ICE when trying to compile the following code that uses "boost::container::small_vector" (I can reproduce this with clang trunk for Boost 1.58 and Boost 1.61): #include #include using boost::container::small_vector; struct A : small_vector { using vector_t = small_vector; using vector_t::vector_t; using vector_t::operator=; }; template inline void foo(P) { small_vector pls; pls.push_back(P{}); } int main() { foo(A{}); return 0; } -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29092] New: psABI inconsistency when passing vector registers?
https://llvm.org/bugs/show_bug.cgi?id=29092 Bug ID: 29092 Summary: psABI inconsistency when passing vector registers? Product: libraries Version: trunk Hardware: PC OS: All Status: NEW Severity: normal Priority: P Component: Backend: X86 Assignee: unassignedb...@nondot.org Reporter: wenzel.ja...@epfl.ch CC: llvm-bugs@lists.llvm.org Classification: Unclassified Clang trunk does not pass vector types through registers when they are contained in an aggregate data type. Consider the following simple program: -- C code: #include typedef struct __attribute__((aligned(16))) { __m128 x, y; } Structure; __m128 test1(__m128 x, __m128 y) { return y; } __m128 test2(Structure t) { return t.y; } -- Assembly: $ clang++ test.cpp -msse4.2 -I include -std=c++14 -o - -S -fomit-frame-pointer -O3 __Z5test1Dv4_fS_: vmovaps%xmm1, %xmm0 retq __Z5test29Structure: vmovaps24(%rsp), %xmm0 <-- copy from memory :( retq -- The psABI spec (https://github.com/hjl-tools/x86-psABI/blob/master/low-level-sys-info.tex#L506) has the following to say about this: Each field of an object is classified *recursively* (emphasis added) so that always two fields are considered. The resulting class is calculated according to the classes of the fields in the eightbyte [...]. (a)-(e) [... cases which don't apply ...] (f) Otherwise class SSE is used. Intuitively (and according to the spec), I would have expected that "x" is assigned to %xmm0 and "y" is assigned to %xmm1. I'm wondering if I am misreading the ABI here, or if Clang is in violation? -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29020] Thin LTO is broken on 32-bit hosts
https://llvm.org/bugs/show_bug.cgi?id=29020 Teresa Johnson changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED --- Comment #10 from Teresa Johnson --- This should be fixed by r279356 -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29081] error: call to function 'is_contained' that is neither visible in the template definition nor found by argument-dependent lookup
https://llvm.org/bugs/show_bug.cgi?id=29081 Vassil Vassilev changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #4 from Vassil Vassilev --- This issue was fixed in r279298 by Richard Smith. -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29093] New: version script does not support [chars] wildcards
https://llvm.org/bugs/show_bug.cgi?id=29093 Bug ID: 29093 Summary: version script does not support [chars] wildcards Product: lld Version: unspecified Hardware: PC OS: FreeBSD Status: NEW Severity: normal Priority: P Component: ELF Assignee: unassignedb...@nondot.org Reporter: ema...@freebsd.org CC: llvm-bugs@lists.llvm.org Classification: Unclassified GNU ld supports [chars] wildcards in version scripts, to match a single instance of any of the chars. I encountered this on FreeBSD building GNU libstdc++ (which is not used in the base system on x86-64, but is on MIPS). A - may be used to specify a range of characters (e.g. [a-z]) and ^ inverts the sense (so any character not in the set, e.g. [^a-z]). Here is an excerpt from libstdc++'s version script in FreeBSD: extern "C++" { ... std::locale::_[T-Za-z]*; # std::[A-Zm-r]*; std::[A-Zm]*; std::n[^u]*; std::nu[^m]*; std::num[^e]*; ... } -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29088] Rev. 276416 ruins LLC.
https://llvm.org/bugs/show_bug.cgi?id=29088 Simon Pilgrim changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #4 from Simon Pilgrim --- Fixed by https://reviews.llvm.org/rL279441 -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29086] Clang didn't emit the right debug information for vla a[3][m]
https://llvm.org/bugs/show_bug.cgi?id=29086 David Blaikie changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29094] New: C++11 attributes not accepted in template explicit instantiation
https://llvm.org/bugs/show_bug.cgi?id=29094 Bug ID: 29094 Summary: C++11 attributes not accepted in template explicit instantiation Product: clang Version: 3.8 Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: C++11 Assignee: unassignedclangb...@nondot.org Reporter: matthew.woeh...@kitware.com CC: dgre...@apple.com, llvm-bugs@lists.llvm.org Classification: Unclassified Clang rejects the following code, with the error "an attribute list cannot appear here": template T foo(T) { return 0; } template [[gnu::visibility("default")]] int foo(int); Live example: https://gcc.godbolt.org/#compilers:!((compiler:clang380,options:'-std%3Dc%2B%2B11',source:'template+%3Ctypename+T%3E%0AT+foo(T)+%7B+return+0%3B+%7D%0A%0Atemplate+%5B%5Bgnu::visibility(%22default%22)%5D%5D%0Aint+foo%3Cint%3E(int)%3B%0A')),filterAsm:(commentOnly:!t,directives:!t,labels:!t),version:3 GCC accepts this code. As I read N4606 [A.6] and [A.12], this should be accepted as: --> [extern] template --> [extern] template --> [extern] template [] ; Moreover, there doesn't seem to be any manner in which Clang accepts an attribute on an explicit instantiation, which seems surely not intended. Also, the old style attribute, `__attribute__((visibility("default")))`, is accepted. -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29095] New: CGP generates inefficient branch for double selects
https://llvm.org/bugs/show_bug.cgi?id=29095 Bug ID: 29095 Summary: CGP generates inefficient branch for double selects Product: clang Version: trunk Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: LLVM Codegen Assignee: unassignedclangb...@nondot.org Reporter: daniel...@gmail.com CC: davi...@google.com, llvm-bugs@lists.llvm.org Classification: Unclassified int* rbsearch(int c, int *t, int n, int ne) { int *p; int m; while(n > 1) { m = n >> 1; p = t + m*ne; if(__builtin_expect(c >= p[0], true)) { t = p; n = n-m; } else n = m; } return t; } For this test case, building with clang -O2, the generated x86 code is has something like: cmpl%edi, %r9d jle .LBB0_3 # BB#2: movl%r10d, %edx jmp .LBB0_4 .p2align4, 0x90 .LBB0_3: subl%r10d, %edx .LBB0_4: cmpl%edi, %r9d jg .LBB0_6 Note that the two cmpl instructions are redundant. The problem is gone if the code is compiled with -mllvm -phi-node-folding-threshold=0 The issue is that CGP generates 2 conditional branches (with same condition) for 2 select instructions. -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29094] C++11 attributes not accepted in template explicit instantiation
https://llvm.org/bugs/show_bug.cgi?id=29094 Richard Smith changed: What|Removed |Added Status|NEW |RESOLVED CC||richard-l...@metafoo.co.uk Resolution|--- |INVALID --- Comment #1 from Richard Smith --- [dcl.attr.grammar]/5: "No attribute-specifier-seq shall appertain to an explicit instantiation (14.7.2)." -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29068] Static TLS for i386: addend ignored
https://llvm.org/bugs/show_bug.cgi?id=29068 Hans Wennborg changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #5 from Hans Wennborg --- Since we'll need to do another cycle after rc2 anyway, and this seems important and straight-forward, I've merged it to 3.9 in r279476. -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 28600] [meta] 3.9.0 Release Blockers
https://llvm.org/bugs/show_bug.cgi?id=28600 Bug 28600 depends on bug 29068, which changed state. Bug 29068 Summary: Static TLS for i386: addend ignored https://llvm.org/bugs/show_bug.cgi?id=29068 What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29096] New: Crashes in 32 bit libcxx/libcxxabi regressions
https://llvm.org/bugs/show_bug.cgi?id=29096 Bug ID: 29096 Summary: Crashes in 32 bit libcxx/libcxxabi regressions Product: lld Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: ELF Assignee: unassignedb...@nondot.org Reporter: eugene.zele...@gmail.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified I observed crashes in 32 bit libcxx/libcxxabi regressions when LLD was used as linker for libcxx/libcxxabi (LLVM_USE_LLD=ON). libcxx/libcxxabi were built standalone. Both 3.9 and trunk (as of r279449) are affected. -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 27897] [ppc] slow vector load instruction
https://llvm.org/bugs/show_bug.cgi?id=27897 Carrot changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #5 from Carrot --- Fixed in r271333. -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29097] New: r279314 broke modules selfhost
https://llvm.org/bugs/show_bug.cgi?id=29097 Bug ID: 29097 Summary: r279314 broke modules selfhost Product: clang Version: trunk Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: Modules Assignee: unassignedclangb...@nondot.org Reporter: richard-l...@metafoo.co.uk CC: biancacristinacriste...@gmail.com, dexonsm...@apple.com, dgre...@apple.com, llvm-bugs@lists.llvm.org, vvasi...@cern.ch Classification: Unclassified Clang modules selfhost bots are currently failing during IR emission with: clang-3.8: /home/buildbot/modules-slave-1/clang-x86_64-linux-selfhost-modules/llvm.src/tools/clang/include/clang/AST/ExprCXX.h:1067: clang::Expr *clang::CXXDefaultInitExpr::getExpr(): Assertion `Field->getInClassInitializer() && "initializer hasn't been parsed"' failed. [...] 3. /home/buildbot/modules-slave-1/clang-x86_64-linux-selfhost-modules/llvm.src/include/llvm/ADT/ilist.h:199:3: Generating code for declaration 'llvm::ilist_iterator::ilist_iterator' I would guess the problem is that we merged multiple FieldDecls together, and then asked the wrong declaration of the field for its initializer. (It's valid for one FieldDecl for a field to have an initializer and another FieldDecl to not have one, since we lazily instantiate the initializer if the field is a member of a class template, and we don't attempt to accomodate that.) Once we have a reduced testcase, we can presumably fix this by copying the initializer onto the canonical declaration whenever we merge FieldDecls, and making FieldDecl::getInClassInitializer look on the canonical declaration. -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29098] New: Assertion failed: Data.size() <= UINT16_MAX, file llvm\lib\DebugInfo\CodeView\MemoryTypeTableBuilder.cpp, line 17
https://llvm.org/bugs/show_bug.cgi?id=29098 Bug ID: 29098 Summary: Assertion failed: Data.size() <= UINT16_MAX, file llvm\lib\DebugInfo\CodeView\MemoryTypeTableBuilder.cpp , line 17 Product: clang Version: trunk Hardware: PC OS: Windows NT Status: NEW Severity: normal Priority: P Component: -New Bugs Assignee: unassignedclangb...@nondot.org Reporter: mikhail.strelni...@gmail.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified Created attachment 17030 --> https://llvm.org/bugs/attachment.cgi?id=17030&action=edit main-266263.cpp I'm using LLVM-4.0.0-r277442-win64.exe (same for trunk) to compile attached source file in "Release" mode ("Debug" does compile normally). 1> Assertion failed: Data.size() <= UINT16_MAX, file F:\llvm_package_HEAD\llvm\lib\DebugInfo\CodeView\MemoryTypeTableBuilder.cpp, line 17 1> Wrote crash dump file "F:\TEMP\CL.exe-a8e6f0.dmp" 1> 0x7FF6554D6616 (0x0016 0x001E46F8BD88 0x7FF6554D6610 0x7FF656FA5583) 1> 0x7FF656FA5926 (0x0001 0x001E 0x7FF6 0x) 1> 0x7FF656F97E80 (0x7FF657CEB500 0x0404 0x7FF657AFEA7E 0x7FF657AFE9E6) 1> 0x7FF656F92B7E (0x0003 0x9521 0x015EBEF5A8F0 0x015EBEF5) 1> 0x7FF656F92C1A (0x015EBEB9DEC0 0xBE870280 0x001E46F8C81C 0x) 1> 0x7FF655BFBBCA (0x015EBEF5A900 0x7FF6540B4BB5 0x001E46F8C560 0x7FF655170B20) 1> 0x7FF655BE707A (0x 0x015EBEE883B8 0x 0x015EBEE883A0) 1> 0x7FF655B9FCE0 (0x015EBE875B30 0x001E46F8C840 0x015EBEBE0980 0x) 1> 0x7FF655B9E024 (0x001E46F8C8D8 0x003F 0x015EBEB9E0A8 0x001E46F8C8B0) 1> 0x7FF655B9604D (0x 0x 0x 0x) 1> 0x7FF655BA1D04 (0x3231643230336131 0x7372617040333263 0x7261686355407265 0x407265737261705F) 1> 0x7FF655BA2D87 (0x001E46F8CA18 0x 0x001E46F8C9E0 0x7FF655B96FE3) 1> 0x7FF655B99F91 (0x0009 0x 0x000F 0x44555DDF9145) 1> 0x7FF655B970CF (0x015EBE840F00 0x001E46F8CCB0 0x001E46F8CCE0 0x7FF657D2077C) 1> 0x7FF655B85A79 (0x015EBEE42E10 0x015EBCB4ABA0 0x015EBCB4ABA0 0x7FF657D10B8E) 1> 0x7FF6550C34F8 (0x44555DDF9145 0x015EBEC66430 0x015EBEC66428 0x) 1> 0x7FF6550C3A7F (0x0100015E 0x001E46F8D2B8 0x0003 0x001E46F8D2F4) 1> 0x7FF655720DB7 (0x015EBCBF94D0 0x44555DDF9145 0x 0x) 1> 0x7FF656F5CBE2 (0x015EBCB08EB0 0x00050010 0x0008 0x015EBCB07150) 1> 0x7FF6561696E2 (0x 0x 0x015EBCB43990 0x015EBCB0CF00) 1> 0x7FF655B237C9 (0x0001 0x7FF65773CD07 0x0004 0x7FF60013) 1> 0x7FF655AD50B1 (0x0028 0x7FF656F8B9D5 0x001E 0x0010) 1> 0x7FF655B6CCE2 (0x0D20 0x0001 0x003100E5 0x) 1> 0x7FF6540B6809 (0x005E 0x015EBCB244B0 0x001E46F8E620 0x7FF9BB48BDFF) 1> 0x7FF6540B42AD (0x 0x 0x 0x) 1> 0x7FF656F8C1DD (0x 0x 0x 0x) 1> 0x7FF9B9748364 (0x 0x 0x 0x), BaseThreadInitThunk() + 0x14 bytes(s) 1> 0x7FF9BB4C5E91 (0x 0x 0x 0x), RtlUserThreadStart() + 0x21 bytes(s) 1>clang-cl.exe : error : clang frontend command failed due to signal (use -v to see invocation) 1> clang version 4.0.0 (trunk) 1> Target: x86_64-pc-windows-msvc 1> Thread model: posix -- You are receiving this mail because: You are on the CC list for the bug. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs
[llvm-bugs] [Bug 29099] New: Clang crashes when parsing lambda with try catch and undefined identifiers
https://llvm.org/bugs/show_bug.cgi?id=29099 Bug ID: 29099 Summary: Clang crashes when parsing lambda with try catch and undefined identifiers Product: clang Version: 3.8 Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: C++14 Assignee: unassignedclangb...@nondot.org Reporter: r...@rufflewind.com CC: llvm-bugs@lists.llvm.org Classification: Unclassified Clang seems to crash when parsing this file: int main() { auto x = []() { try { return 0; } catch (...) { return z; } }; } # Crash reproducer for clang version 3.8.1 (tags/RELEASE_381/final) # Driver args: "--driver-mode=g++" "-std=c++14" "foo-b2aebf.cpp" # Original command: "/usr/bin/clang-3.8" "-cc1" "-triple" "x86_64-unknown-linux-gnu" "-emit-obj" "-mrelax-all" "-disable-free" "-disable-llvm-verifier" "-main-file-name" "foo-b2aebf.cpp" "-mrelocation-model" "static" "-mthread-model" "posix" "-mdisable-fp-elim" "-fmath-errno" "-masm-verbose" "-mconstructor-aliases" "-munwind-tables" "-fuse-init-array" "-target-cpu" "x86-64" "-dwarf-column-info" "-debugger-tuning=gdb" "-resource-dir" "/usr/bin/../lib/clang/3.8.1" "-c-isystem" "/home/rf/.local/include" "-c-isystem" "/usr/local/include" "-cxx-isystem" "/home/rf/.local/include" "-cxx-isystem" "/usr/local/include" "-internal-isystem" "/usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.1.1/../../../../include/c++/6.1.1" "-internal-isystem" "/usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.1.1/../../../../include/c++/6.1.1/x86_64-pc-linux-gnu" "-internal-isystem" "/usr/bin/../lib64/gcc/x86_64-pc-linux-gnu/6.1.1/../../../../include/c++/6.1.1/backward" "-internal-isystem" "/usr/local/include" "-internal-isystem" "/usr/bin/../lib/clang/3.8.1/include" "-internal-externc-isystem" "/include" "-internal-externc-isystem" "/usr/include" "-std=c++14" "-fdeprecated-macro" "-fdebug-compilation-dir" "/home/rf/trash/clang-crash" "-ferror-limit" "19" "-fmessage-length" "191" "-fobjc-runtime=gcc" "-fcxx-exceptions" "-fexceptions" "-fdiagnostics-show-option" "-fcolor-diagnostics" "-o" "/tmp/foo-b2aebf-d18d19.o" "-x" "c++" "foo-b2aebf.cpp" "/usr/bin/clang-3.8" "-cc1" "-triple" "x86_64-unknown-linux-gnu" "-emit-obj" "-mrelax-all" "-disable-free" "-disable-llvm-verifier" "-main-file-name" "foo-b2aebf.cpp" "-mrelocation-model" "static" "-mthread-model" "posix" "-mdisable-fp-elim" "-fmath-errno" "-masm-verbose" "-mconstructor-aliases" "-munwind-tables" "-fuse-init-array" "-target-cpu" "x86-64" "-dwarf-column-info" "-debugger-tuning=gdb" "-c-isystem" "/home/rf/.local/include" "-c-isystem" "/usr/local/include" "-cxx-isystem" "/home/rf/.local/include" "-cxx-isystem" "/usr/local/include" "-std=c++14" "-fdeprecated-macro" "-ferror-limit" "19" "-fmessage-length" "191" "-fobjc-runtime=gcc" "-fcxx-exceptions" "-fexceptions" "-fdiagnostics-show-option" "-fcolor-diagnostics" "-x" "c++" "foo-b2aebf-43bb51.cpp" 0 libLLVM-3.8.so 0x7f3c87a087d8 llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 56 1 libLLVM-3.8.so 0x7f3c87a063c6 llvm::sys::RunSignalHandlers() + 54 2 libLLVM-3.8.so 0x7f3c87a065aa 3 libc.so.6 0x7f3c86b0f0b0 4 clang-3.8 0x01450e87 clang::ASTContext::getCanonicalFunctionResultType(clang::QualType) const + 7 5 clang-3.8 0x0103dfc4 clang::Sema::DeduceFunctionTypeFromReturnExpr(clang::FunctionDecl*, clang::SourceLocation, clang::Expr*&, clang::AutoType*) + 324 6 clang-3.8 0x0103e4a6 clang::Sema::ActOnCapScopeReturnStmt(clang::SourceLocation, clang::Expr*) + 246 7 clang-3.8 0x0103ed7f clang::Sema::BuildReturnStmt(clang::SourceLocation, clang::Expr*) + 591 8 clang-3.8 0x0103f63a clang::Sema::ActOnReturnStmt(clang::SourceLocation, clang::Expr*, clang::Scope*) + 42 9 clang-3.8 0x00c0c7ff clang::Parser::ParseReturnStatement() + 223 10 clang-3.8 0x00c0e58f clang::Parser::ParseStatementOrDeclarationAfterAttributes(llvm::SmallVector&, clang::Parser::AllowedContsructsKind, clang::SourceLocation*, clang::Parser::ParsedAttributesWithRange&) + 2255 11 clang-3.8 0x00c0eb87 clang::Parser::ParseStatementOrDeclaration(llvm::SmallVector&, clang::Parser::AllowedContsructsKind, clang::SourceLocation*) + 135 12 clang-3.8 0x00c13949 clang::Parser::ParseCompoundStatementBody(bool) + 1769 13 clang-3.8 0x00c140be clang::Parser::ParseCompoundStatement(bool, unsigned int) + 30 14 clang-3.8 0x00c140f2 clang::Parser::ParseCompoundStatement(bool) + 18 15 clang-3.8 0x00c15652 clang::Parser::ParseCXXCatchBlock(bool) + 2626 16 clang-3.8 0x00c15cf2 clang::Parser::ParseCXXTryBlockCommon(clang::SourceLocation, bool) + 370 17 clang-3.8 0x00c15ed4 clang::Parser::ParseCXXTryBlock() + 36 18 clang-3.8 0x00c0e4c8 cla