[llvm-bugs] [Bug 34974] New: LLI build with LLVM_USE_INTEL_JITEVENTS crashes on Windows 7
https://bugs.llvm.org/show_bug.cgi?id=34974 Bug ID: 34974 Summary: LLI build with LLVM_USE_INTEL_JITEVENTS crashes on Windows 7 Product: tools Version: 4.0 Hardware: PC OS: other Status: NEW Severity: normal Priority: P Component: lli Assignee: unassignedb...@nondot.org Reporter: florian.pichlme...@3ds.com CC: llvm-bugs@lists.llvm.org Created attachment 19299 --> https://bugs.llvm.org/attachment.cgi?id=19299&action=edit Reproducer Hi, I have build LLVM 4 with -DLLVM_USE_INTEL_JITEVENTS=true, which works fine on Linux, but on Windows it crashes in lli. The problem occurs at the access of the DebugObj.getData().data() in IntelJITEventListener.cpp, with DebugObj being a struct at NULL. I tried LLVM 5.0 and the same issue appeared Attached is a minimal reproducer generated with Clang -- 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 34171] Simple no-op loops with an exit flag are not optimized out
https://bugs.llvm.org/show_bug.cgi?id=34171 Jatin Bhateja changed: What|Removed |Added Resolution|DUPLICATE |FIXED CC||jatin.bhat...@gmail.com --- Comment #6 from Jatin Bhateja --- Hi Jun Ryung Ju, I don't think the patch fixed this, loop is getting optimized out in LICM even without patch with -O3. Thanks -- 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 34975] New: Out-of-bounds vector access in MipsLongBranch.cpp
https://bugs.llvm.org/show_bug.cgi?id=34975 Bug ID: 34975 Summary: Out-of-bounds vector access in MipsLongBranch.cpp Product: libraries Version: trunk Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: Backend: MIPS Assignee: unassignedb...@nondot.org Reporter: arichardson@gmail.com CC: llvm-bugs@lists.llvm.org I was getting crashes compiling pngtran.c from FreeBSD (well actually https://github.com/CTSRD-CHERI/cheribsd/blob/master/contrib/libpng/pngrtran.c). MipsLongBranch.cpp accesses a vector at index -1 because MachineBasicBlock->getNumber() returns -1 After running creduce I get the following reduced test case: ``` ; RUN: llc -mtriple=mips64-unknown-freebsd -target-abi n64 -relocation-model pic -o /dev/null %s -thread-model posix -mattr=-noabicalls -mips-ssection-threshold=0 -O2 -vectorize-loops -vectorize-slp ; ModuleID = '/local/scratch/alr48/cheri/llvm/tools/clang/test/CodeGen/cheri-pngtran-crash.c' source_filename = "/local/scratch/alr48/cheri/llvm/tools/clang/test/CodeGen/cheri-pngtran-crash.c" target datalayout = "E-m:e-i8:8:32-i16:16:32-i64:64-n32:64-S128" target triple = "mips64-unknown-freebsd" ; Generated from the following creduce source code: ; unsigned char *a; ; *b; ; c, d; ; e() { ; for (; c;) ; if (a[d] >= c) { ; int f = a[d]; ; g(b[f]); ; } ; } @c = common local_unnamed_addr global i32 0, align 4, !dbg !0 @a = common local_unnamed_addr global i8* null, align 8, !dbg !6 @d = common local_unnamed_addr global i32 0, align 4, !dbg !15 @b = common local_unnamed_addr global i32* null, align 8, !dbg !11 ; Function Attrs: nounwind define i32 @e() local_unnamed_addr #0 !dbg !22 { entry: %0 = load i32, i32* @c, align 4, !dbg !31, !tbaa !32 %tobool8 = icmp eq i32 %0, 0, !dbg !36 br i1 %tobool8, label %for.end, label %for.body.preheader, !dbg !36 for.body.preheader: ; preds = %entry br label %for.body, !dbg !37 for.body: ; preds = %for.body.preheader, %if.end %1 = phi i32 [ %7, %if.end ], [ %0, %for.body.preheader ] %2 = load i8*, i8** @a, align 8, !dbg !37, !tbaa !38 %3 = load i32, i32* @d, align 4, !dbg !40, !tbaa !32 %idxprom = sext i32 %3 to i64, !dbg !37 %arrayidx = getelementptr inbounds i8, i8* %2, i64 %idxprom, !dbg !37 %4 = load i8, i8* %arrayidx, align 1, !dbg !37, !tbaa !41 %conv = zext i8 %4 to i32, !dbg !37 %cmp = icmp sgt i32 %1, %conv, !dbg !42 br i1 %cmp, label %if.end, label %if.then, !dbg !43 if.then: ; preds = %for.body tail call void @llvm.dbg.value(metadata i32 %conv, metadata !26, metadata !DIExpression()), !dbg !44 %5 = load i32*, i32** @b, align 8, !dbg !45, !tbaa !38 %idxprom5 = zext i8 %4 to i64, !dbg !45 %arrayidx6 = getelementptr inbounds i32, i32* %5, i64 %idxprom5, !dbg !45 %6 = load i32, i32* %arrayidx6, align 4, !dbg !45, !tbaa !32 %call = tail call i32 bitcast (i32 (...)* @g to i32 (i32)*)(i32 signext %6) #3, !dbg !46 %.pre = load i32, i32* @c, align 4, !dbg !31, !tbaa !32 br label %if.end, !dbg !47 if.end: ; preds = %for.body, %if.then %7 = phi i32 [ %1, %for.body ], [ %.pre, %if.then ], !dbg !31 %tobool = icmp eq i32 %7, 0, !dbg !36 br i1 %tobool, label %for.end, label %for.body, !dbg !36, !llvm.loop !48 for.end: ; preds = %if.end, %entry ret i32 undef, !dbg !50 } declare i32 @g(...) local_unnamed_addr #1 ; Function Attrs: nounwind readnone speculatable declare void @llvm.dbg.value(metadata, metadata, metadata) #2 attributes #0 = { nounwind "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="false" "no-jump-tables"="false" "no-nans-fp-math"="false" "no-signed-zeros-fp-math"="false" "no-trapping-math"="false" "stack-protector-buffer-size"="8" "target-features"="+mips64r2,-noabicalls" "unsafe-fp-math"="false" "use-soft-float"="false" } attributes #1 = { "correctly-rounded-divide-sqrt-fp-math"="false" "disable-tail-calls"="false" "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "no-signed-zeros-fp-math"="false" "no-trapping-math"="false" "stack-protector-buffer-size"="8" "target-features"="+mips64r2,-noabicalls" "unsafe-fp-math"="false" "use-soft-float"="false" } attributes #2 = { nounwind readnone speculatable } attributes #3 = { nounwind } !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!17, !18, !19, !20} !llvm.ident = !{!21} !0 = !DIGlobalVariableExpression(var: !1, expr: !DIExpression()) !1 = distinct !DIGlobalVariable(name: "c", scope: !2, file: !8, line: 8, type: !14, isLocal: false, isDefinition: true) !2 = distinct !DICompileUnit(language: DW_LA
[llvm-bugs] [Bug 34976] New: Use of 'concurrency::parallel_for_each' with the Multi-threaded Debug (/MTd) run-time library causes unhandled exceptions on program exit
https://bugs.llvm.org/show_bug.cgi?id=34976 Bug ID: 34976 Summary: Use of 'concurrency::parallel_for_each' with the Multi-threaded Debug (/MTd) run-time library causes unhandled exceptions on program exit Product: libraries Version: trunk Hardware: PC OS: Windows NT Status: NEW Severity: normal Priority: P Component: Support Libraries Assignee: unassignedb...@nondot.org Reporter: gbrey...@gmail.com CC: llvm-bugs@lists.llvm.org Use of 'parallel_for_each' when compiling with the Visual C++ Compiler uses the Windows Concurrency Library. We have found that when compiling with /MTd, the use of 'concurrency::parallel_for_each' can cause unhandled exceptions when the program is exiting. This is problematic when debugging or testing. This issue does not occur when compiling to release or DLL run-time libraries, and the issue has been raised with Microsoft. However in the meantime we suggest the removal of this MSVC specific functionality and use the generic implementation. To reproduce this issue consistently: - Create an an executable with calls to 'parallel_for_each' - Run executable multiple times in parallel - The exit codes will be as below: -1073741819 = C005 = Access Violation exception See attached files for example -- 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 34977] New: llvm-config --link-shared --libs bitwriter produces errors with -DLLVM_BUILD_LLVM_DYLIB=ON
https://bugs.llvm.org/show_bug.cgi?id=34977 Bug ID: 34977 Summary: llvm-config --link-shared --libs bitwriter produces errors with -DLLVM_BUILD_LLVM_DYLIB=ON Product: new-bugs Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: enhancement Priority: P Component: new bugs Assignee: unassignedb...@nondot.org Reporter: adf.li...@gmail.com CC: llvm-bugs@lists.llvm.org Building git llvm like - cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DLLVM_TARGETS_TO_BUILD="host;AMDGPU" -DLLVM_ENABLE_ASSERTIONS=ON -DLLVM_BUILD_LLVM_DYLIB=ON .. Mesa will fail to build after a recent llvm detection change. llvm-config result below seems to be the issue. llvm-config --link-shared --libs bitwriter llvm-config: error: missing: /usr/lib/libLLVMDemangle.so llvm-config: error: missing: /usr/lib/libLLVMSupport.so llvm-config: error: missing: /usr/lib/libLLVMBinaryFormat.so llvm-config: error: missing: /usr/lib/libLLVMCore.so llvm-config: error: missing: /usr/lib/libLLVMBitReader.so llvm-config: error: missing: /usr/lib/libLLVMMC.so llvm-config: error: missing: /usr/lib/libLLVMMCParser.so llvm-config: error: missing: /usr/lib/libLLVMObject.so llvm-config: error: missing: /usr/lib/libLLVMProfileData.so llvm-config: error: missing: /usr/lib/libLLVMAnalysis.so llvm-config: error: missing: /usr/lib/libLLVMBitWriter.so Built with -DLLVM_LINK_LLVM_DYLIB=ON The result is -lLLVM-6.0svn -- 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 34978] New: [InterleavedAccess] Crash with "(castIsValid(op, S, Ty) && "Invalid cast!")" on haswell
https://bugs.llvm.org/show_bug.cgi?id=34978 Bug ID: 34978 Summary: [InterleavedAccess] Crash with "(castIsValid(op, S, Ty) && "Invalid cast!")" on haswell Product: libraries Version: trunk Hardware: PC OS: All Status: NEW Severity: enhancement Priority: P Component: Backend: X86 Assignee: unassignedb...@nondot.org Reporter: i...@azulsystems.com CC: llvm-bugs@lists.llvm.org Created attachment 19306 --> https://bugs.llvm.org/attachment.cgi?id=19306&action=edit Reduced test case llc crashes on haswell processors with following message: Assertion failed: (castIsValid(op, S, Ty) && "Invalid cast!"), function Create, file /Users/igor/Projects/llvm/lib/IR/Instructions.cpp, line 2565. Reverting this change fixes the issue: commit 563f2fdd9270bb57a619e28caffceb7bda297ad3 Author: Michael Zuckerman Date: Thu Sep 7 14:02:13 2017 + [X86][LLVM]Expanding Supports lowerInterleavedLoad() in X86InterleavedAccess (VF{8|16|32} stride 3). Reduced test case attached. Use "llc -mcpu=haswell test.ll" to get the crash. -- 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 34979] New: [AArch64] After r308025, Assertion failed: (isReg() && "This is not a register operand!"), function getReg, file include/llvm/CodeGen/MachineOperand.h, line 278.
https://bugs.llvm.org/show_bug.cgi?id=34979 Bug ID: 34979 Summary: [AArch64] After r308025, Assertion failed: (isReg() && "This is not a register operand!"), function getReg, file include/llvm/CodeGen/MachineOperand.h, line 278. Product: new-bugs Version: trunk Hardware: All OS: All Status: NEW Severity: normal Priority: P Component: new bugs Assignee: unassignedb...@nondot.org Reporter: dimi...@andric.com CC: llvm-bugs@lists.llvm.org Created attachment 19307 --> https://bugs.llvm.org/attachment.cgi?id=19307&action=edit Reduced test case for producing assertion on AArch64 In https://bugs.freebsd.org/223048, Jan Beich reports an assertion failure in clang while compiling a recent version of Firefox for AArch64. A reduced test case is attached. Compile this with: clang -cc1 -triple aarch64 -S -O2 -std=c++11 assertion-r308025-aarch64.cpp Gdb backtrace, with some additional information: (gdb) run Starting program: /home/dim/obj/llvm-trunk-r308025-dbg/bin/clang -cc1 -triple aarch64 -S -O2 -std=c++11 testcase.cpp Assertion failed: (isReg() && "This is not a register operand!"), function getReg, file /home/dim/src/llvm-trunk/include/llvm/CodeGen/MachineOperand.h, line 278. Program received signal SIGABRT, Aborted. 0x0008077d851a in thr_kill () from /lib/libc.so.7 (gdb) bt #0 0x0008077d851a in thr_kill () from /lib/libc.so.7 #1 0x0008077d84e4 in raise () from /lib/libc.so.7 #2 0x0008077d8459 in abort () from /lib/libc.so.7 #3 0x0008078544b1 in __assert () from /lib/libc.so.7 #4 0x008f34ea in llvm::MachineOperand::getReg (this=0x808793d18) at /home/dim/src/llvm-trunk/include/llvm/CodeGen/MachineOperand.h:278 #5 0x00a1ef65 in llvm::AArch64InstrInfo::analyzeCompare (this=0x8088ae0e0, MI=..., SrcReg=@0x7fff5fc4: 8, SrcReg2=@0x7fff5fc0: 142163032, CmpMask=@0x7fff5fbc: 9, CmpValue=@0x7fff5fb8: 0) at /home/dim/src/llvm-trunk/lib/Target/AArch64/AArch64InstrInfo.cpp:971 #6 0x011c5742 in (anonymous namespace)::PeepholeOptimizer::optimizeCmpInstr (this=0x80870b480, MI=0x808793c58, MBB=0x808786428) at /home/dim/src/llvm-trunk/lib/CodeGen/PeepholeOptimizer.cpp:629 #7 0x011c4693 in (anonymous namespace)::PeepholeOptimizer::runOnMachineFunction (this=0x80870b480, MF=...) at /home/dim/src/llvm-trunk/lib/CodeGen/PeepholeOptimizer.cpp:1754 #8 0x0111e541 in llvm::MachineFunctionPass::runOnFunction (this=0x80870b480, F=...) at /home/dim/src/llvm-trunk/lib/CodeGen/MachineFunctionPass.cpp:62 #9 0x0171504f in llvm::FPPassManager::runOnFunction (this=0x8064aa9c0, F=...) at /home/dim/src/llvm-trunk/lib/IR/LegacyPassManager.cpp:1514 #10 0x01715365 in llvm::FPPassManager::runOnModule (this=0x8064aa9c0, M=...) at /home/dim/src/llvm-trunk/lib/IR/LegacyPassManager.cpp:1535 #11 0x01716068 in (anonymous namespace)::MPPassManager::runOnModule (this=0x8087a0c00, M=...) at /home/dim/src/llvm-trunk/lib/IR/LegacyPassManager.cpp:1591 #12 0x01715626 in llvm::legacy::PassManagerImpl::run (this=0x80884c500, M=...) at /home/dim/src/llvm-trunk/lib/IR/LegacyPassManager.cpp:1694 #13 0x01716c51 in llvm::legacy::PassManager::run (this=0x7fff71c0, M=...) at /home/dim/src/llvm-trunk/lib/IR/LegacyPassManager.cpp:1725 #14 0x022ce261 in (anonymous namespace)::EmitAssemblyHelper::EmitAssembly (this=0x7fff7cb8, Action=clang::Backend_EmitAssembly, OS=...) at /home/dim/src/llvm-trunk/tools/clang/lib/CodeGen/BackendUtil.cpp:790 #15 0x022c8c11 in clang::EmitBackendOutput (Diags=..., HeaderOpts=..., CGOpts=..., TOpts=..., LOpts=..., TDesc=..., M=0x80870d600, Action=clang::Backend_EmitAssembly, OS=...) at /home/dim/src/llvm-trunk/tools/clang/lib/CodeGen/BackendUtil.cpp:1134 #16 0x0326a371 in clang::BackendConsumer::HandleTranslationUnit (this=0x80651c300, C=...) at /home/dim/src/llvm-trunk/tools/clang/lib/CodeGen/CodeGenAction.cpp:261 #17 0x039a66c7 in clang::ParseAST (S=..., PrintStats=false, SkipFunctionBodies=false) at /home/dim/src/llvm-trunk/tools/clang/lib/Parse/ParseAST.cpp:159 #18 0x02b90495 in clang::ASTFrontendAction::ExecuteAction (this=0x80649a180) at /home/dim/src/llvm-trunk/tools/clang/lib/Frontend/FrontendAction.cpp:1003 #19 0x032651ae in clang::CodeGenAction::ExecuteAction (this=0x80649a180) at /home/dim/src/llvm-trunk/tools/clang/lib/CodeGen/CodeGenAction.cpp:992 #20 0x02b8fa00 in clang::FrontendAction::Execute (this=0x80649a180) at /home/dim/src/llvm-trunk/tools/clang/lib/Frontend/FrontendAction.cpp:902 #21 0x02adc5c1 in clang::CompilerInstance::ExecuteAction (this=0x80651c000, Act=...) at /home/dim/src/llvm-trunk/tools/clang/lib/Frontend/CompilerInstance.cpp:980 #22 0x02d5317c in clang::ExecuteCompilerInvocation (Clang=0x80651c000) at /home/dim/src/llvm-t
[llvm-bugs] [Bug 34980] New: Code generation fails with AESIMC intrinsic
https://bugs.llvm.org/show_bug.cgi?id=34980 Bug ID: 34980 Summary: Code generation fails with AESIMC intrinsic Product: clang Version: 5.0 Hardware: PC OS: All Status: NEW Severity: enhancement Priority: P Component: -New Bugs Assignee: unassignedclangb...@nondot.org Reporter: pavel.kryu...@phystech.edu CC: llvm-bugs@lists.llvm.org Created attachment 19308 --> https://bugs.llvm.org/attachment.cgi?id=19308&action=edit LLVM output (BC file) Hello This is a duplicate of #34967 with simpler testing code. I faced a code generator bug while compiling AES-NI instrinsics. That code is compiled with GCC and Visual Studio without problems, but different versions of Clang fail in different environments. I've attached simplified clang test case from Clang 5.0.0. Command line: fatal error: error in backend: Cannot select: intrinsic %llvm.x86.aesni.aesimc clang: error: clang frontend command failed with exit code 70 (use -v to see invocation) clang version 5.0.1-svn315836-1~exp1 (branches/release_50) Target: x86_64-pc-linux-gnu -- 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 30877] cmake/gmake build fails
https://bugs.llvm.org/show_bug.cgi?id=30877 Petr Penzin changed: What|Removed |Added Resolution|--- |FIXED Status|NEW |RESOLVED Fixed By Commit(s)||rL315952 -- 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 34967] Code generation fails with AESIMC intrinsic
https://bugs.llvm.org/show_bug.cgi?id=34967 Pavel Kryukov changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |DUPLICATE --- Comment #6 from Pavel Kryukov --- *** This bug has been marked as a duplicate of bug 34980 *** -- 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 33465] llvm-cov: the '||' operator in an assign statement lead to the statement marked as unexecuted
https://bugs.llvm.org/show_bug.cgi?id=33465 Vedant Kumar changed: What|Removed |Added Status|NEW |RESOLVED CC||v...@apple.com Resolution|--- |FIXED --- Comment #1 from Vedant Kumar --- Fixed in r315982. -- 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 34962] llvm-cov: Wrong coverage with macro use in if/else
https://bugs.llvm.org/show_bug.cgi?id=34962 Vedant Kumar changed: What|Removed |Added Resolution|--- |FIXED Status|NEW |RESOLVED -- 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 34981] New: Crash on invalid
https://bugs.llvm.org/show_bug.cgi?id=34981 Bug ID: 34981 Summary: Crash on invalid Product: clang Version: unspecified Hardware: PC OS: All Status: NEW Severity: enhancement Priority: P Component: Frontend Assignee: unassignedclangb...@nondot.org Reporter: nicolaswe...@gmx.de CC: llvm-bugs@lists.llvm.org Download foo.ii from https://bugs.chromium.org/p/chromium/issues/detail?id=775590 , then run: /Users/thakis/src/chrome/src/third_party/llvm-build/Release+Asserts/bin/clang -cc1 -triple i386-pc-windows-msvc19.11.0 -emit-obj -mrelax-all -mincremental-linker-compatible -disable-free -main-file-name base_jumbo_3.cc -mrelocation-model static -mthread-model posix -mdisable-fp-elim -relaxed-aliasing -fmath-errno -masm-verbose -mconstructor-aliases -target-cpu pentium4 --dependent-lib=msvcrtd --dependent-lib=oldnames -fno-rtti-data -stack-protector 2 -fms-volatile -fdiagnostics-format msvc -dwarf-column-info -debugger-tuning=gdb -target-linker-version 274.1 -ffunction-sections -coverage-notes-file /Users/thakis/src/chrome/src/out/gnwin/base_jumbo_3.gcno -resource-dir /Users/thakis/src/chrome/src/third_party/llvm-build/Release+Asserts/lib/clang/6.0.0 -O0 -fdeprecated-macro -fdebug-compilation-dir /Users/thakis/src/chrome/src/out/gnwin -ferror-limit 19 -fmessage-length 0 -fno-use-cxa-atexit -fms-extensions -fms-compatibility -fms-compatibility-version=19.11 -std=c++14 -fdelayed-template-parsing -fno-inline -fobjc-runtime=gcc -fdiagnostics-show-option -fcolor-diagnostics -o obj/base/base/base_jumbo_3.obj -w -x c++ foo.ii Emits a bunch of errors and then crashes like so: 0 clang0x000102fc0c18 llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 40 1 clang0x000102fc1306 llvm::sys::PrintStackTraceOnErrorSignal(llvm::StringRef, bool) + 886 2 libsystem_platform.dylib 0x7fff9f311b3a _sigtramp + 26 3 libsystem_platform.dylib 0x7f93e3065000 _sigtramp + 1138046176 4 clang0x0001040f3edf clang::Sema::ActOnFunctionDeclarator(clang::Scope*, clang::Declarator&, clang::DeclContext*, clang::TypeSourceInfo*, clang::LookupResult&, llvm::MutableArrayRef, bool&) + 23343 5 clang0x0001040ec44c clang::Sema::HandleDeclarator(clang::Scope*, clang::Declarator&, llvm::MutableArrayRef) + 3564 6 clang0x000104113a28 clang::Sema::ActOnStartOfFunctionDef(clang::Scope*, clang::Declarator&, llvm::MutableArrayRef, clang::Sema::SkipBodyInfo*) + 200 7 clang0x000103dfbd7b clang::Parser::ParseFunctionDefinition(clang::ParsingDeclarator&, clang::Parser::ParsedTemplateInfo const&, clang::Parser::LateParsedAttrList*) + 1771 8 clang0x000103d66e36 clang::Parser::ParseDeclGroup(clang::ParsingDeclSpec&, unsigned int, clang::SourceLocation*, clang::Parser::ForRangeInit*) + 2694 9 clang0x000103dfb441 clang::Parser::ParseDeclOrFunctionDefInternal(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec&, clang::AccessSpecifier) + 913 10 clang0x000103dfae0c clang::Parser::ParseDeclarationOrFunctionDefinition(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*, clang::AccessSpecifier) + 588 11 clang0x000103df9885 clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) + 2965 12 clang0x000103d7bfaa clang::Parser::ParseInnerNamespace(std::__1::vector >&, std::__1::vector >&, std::__1::vector >&, unsigned int, clang::SourceLocation&, clang::ParsedAttributes&, clang::BalancedDelimiterTracker&) + 298 13 clang0x000103d7b846 clang::Parser::ParseNamespace(unsigned int, clang::SourceLocation&, clang::SourceLocation) + 5142 14 clang0x000103d61f2c clang::Parser::ParseDeclaration(unsigned int, clang::SourceLocation&, clang::Parser::ParsedAttributesWithRange&) + 460 15 clang0x000103df8d99 clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) + 169 16 clang0x000103d7c60d clang::Parser::ParseLinkage(clang::ParsingDeclSpec&, unsigned int) + 1357 17 clang0x000103dfb424 clang::Parser::ParseDeclOrFunctionDefInternal(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec&, clang::AccessSpecifier) + 884 18 clang0x000103dfae0c clang::Parser::ParseDeclarationOrFunctionDefinition(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*, clang::AccessSpecifier) + 588 19 clang0x000103df9885 clang::Parser::ParseExternalDeclaration(clang::Parser::ParsedAttributesWithRange&, clang::ParsingDeclSpec*) + 2965 20 clang0x000103df8395 clang
[llvm-bugs] [Bug 34982] New: [coroutines] assertion failure diagnosing bad coroutine await_suspend function
https://bugs.llvm.org/show_bug.cgi?id=34982 Bug ID: 34982 Summary: [coroutines] assertion failure diagnosing bad coroutine await_suspend function Product: clang Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: C++ Assignee: gornisha...@gmail.com Reporter: richard-l...@metafoo.co.uk CC: dgre...@apple.com, llvm-bugs@lists.llvm.org Testcase: #include namespace std { using namespace std::experimental; } struct corotype { struct promise_type { std::suspend_always initial_suspend(); std::suspend_always final_suspend(); }; bool await_ready() { return false; } void await_suspend(); }; static corotype f() { } void h(); corotype g() { auto a = f(); while (co_await a) h(); } Results in an assertion failure when diagnosing the bad await_suspend function: :17:10: error: too many arguments to function call, expected 0, have 1 clang-6.0: /usr/local/google/home/richardsmith/build/llvm-2/src/tools/clang/lib/Frontend/TextDiagnostic.cpp:1015: void highlightRange(const clang::CharSourceRange &, unsigned int, clang::FileID, const (anonymous namespace)::SourceColumnMap &, std::string &, const clang::SourceManager &, const clang::LangOptions &): Assertion `StartColNo <= EndColNo && "Invalid range!"' failed. -- 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 34983] New: [coroutines] diagnostics for missing coroutine promise members produce invalid typo corrections
https://bugs.llvm.org/show_bug.cgi?id=34983 Bug ID: 34983 Summary: [coroutines] diagnostics for missing coroutine promise members produce invalid typo corrections Product: clang Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: enhancement Priority: P Component: C++ Assignee: unassignedclangb...@nondot.org Reporter: richard-l...@metafoo.co.uk CC: dgre...@apple.com, gornisha...@gmail.com, llvm-bugs@lists.llvm.org Testcase: #include namespace std { using namespace std::experimental; } struct corotype { struct promise_type { std::suspend_always initial_suspend(); }; }; static corotype f() { } void h(); corotype g() { auto a = f(); while (co_await a) h(); } Produces this wrong typo correction: :12:10: error: no member named 'final_suspend' in 'corotype::promise_type'; did you mean 'initial_suspend'? corotype g() { ^ initial_suspend :6:25: note: 'initial_suspend' declared here std::suspend_always initial_suspend(); ^ -- 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 34984] New: [coroutines] accepts-invalid and codegen crash on missing await_resume function
https://bugs.llvm.org/show_bug.cgi?id=34984 Bug ID: 34984 Summary: [coroutines] accepts-invalid and codegen crash on missing await_resume function Product: clang Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: C++ Assignee: unassignedclangb...@nondot.org Reporter: richard-l...@metafoo.co.uk CC: dgre...@apple.com, gornisha...@gmail.com, llvm-bugs@lists.llvm.org If an awaitable type fails to declare an await_resume function: #include namespace std { using namespace std::experimental; } struct corotype { struct promise_type { std::suspend_always initial_suspend(); std::suspend_always final_suspend(); corotype get_return_object() { return {}; } void unhandled_exception(); void return_void(); }; bool await_ready() { return false; } void await_suspend(std::coroutine_handle); // bool await_resume(); }; static corotype f() { } void h(); corotype g() { auto a = f(); while (co_await a) h(); } ... we get no diagnostic from the frontend, and instead see a crash in codegen: clang-6.0: /home/richardsmith/build/llvm-2/src/tools/clang/include/clang/AST/Type.h:6165: const T *clang::Type::castAs() const [T = clang::Funct ionType]: Assertion `isa(CanonicalType)' failed. [...] #10 0x0a0a89ef clang::CallExpr::getCallReturnType(clang::ASTContext const&) const /home/richardsmith/build/llvm-2/src/tools/clang/lib/AST/Expr.cpp:1322:23 [...] #16 0x066d2141 emitSuspendExpression(clang::CodeGen::CodeGenFunction&, clang::CodeGen::CGCoroData&, clang::CoroutineSuspendExpr const&, (anonymous namespace)::AwaitKind, clang::CodeGen::AggValueSlot, bool, bool) /home/richardsmith/build/llvm-2/src/tools/clang/lib/CodeGen/CGCoroutine.cpp:215:18 #17 0x066d1925 clang::CodeGen::CodeGenFunction::EmitCoawaitExpr(clang::CoawaitExpr const&, clang::CodeGen::AggValueSlot, bool) /home/richardsmith/build/llvm-2/src/tools/clang/lib/CodeGen/CGCoroutine.cpp:222:10 -- 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 34940] SROA miscomputes struct element offsets
https://bugs.llvm.org/show_bug.cgi?id=34940 vtjn...@gmail.com changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #1 from vtjn...@gmail.com --- Sorry, this was just my confusion: I forgot to set the isPacked attribute in my code. -- 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 34985] New: Double text output on include file not found error
https://bugs.llvm.org/show_bug.cgi?id=34985 Bug ID: 34985 Summary: Double text output on include file not found error Product: clang Version: 5.0 Hardware: PC OS: Linux Status: NEW Severity: normal Priority: P Component: -New Bugs Assignee: unassignedclangb...@nondot.org Reporter: anthonym.lee...@gmail.com CC: llvm-bugs@lists.llvm.org fatal errorfatal error: : 'foo.hpp''foo.hpp' filefile notnot foundfound #include "foo.hpp"#include "foo.hpp" ^ ^ 1 error generated. 1 error generated. Getting the above error message. -- 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 34981] Crash on invalid in extern c with files differing only in return type when first declaration is dllimported
https://bugs.llvm.org/show_bug.cgi?id=34981 Nico Weber changed: What|Removed |Added Resolution|--- |FIXED Status|NEW |RESOLVED --- Comment #5 from Nico Weber --- r316032 -- 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 34986] New: clang rejects --analyze parameter
https://bugs.llvm.org/show_bug.cgi?id=34986 Bug ID: 34986 Summary: clang rejects --analyze parameter Product: clang Version: 5.0 Hardware: PC OS: Windows NT Status: NEW Severity: enhancement Priority: P Component: Static Analyzer Assignee: dcough...@apple.com Reporter: msherma...@gmail.com CC: llvm-bugs@lists.llvm.org Hi. I want to run clang --analyze against a legacy MFC/C++ code base on Windows. In my Makefile, the CFLAGS looks like: CFLAGS= -I$(RESOURCES) -I$(IMPORTED_HEADERS) -I$(EXPORTED_HEADERS) -isystem$(ATL_MFC_INCLUDE) -isystem$(SDK7INCLUDE) -isystem$(VCINCLUDE) -ferror-limit=0 -std=c++14 -fsyntax-only -Wmicrosoft -fms-extensions -fms-compatibility -Wno-microsoft-extra-qualification -Wno-non-pod-varargs -Wno-microsoft-cast -Wno-invalid-token-paste -Wno-inconsistent-dllimport -D_ATL_NO_HOSTING -DUNICODE -D_UNICODE -DWIN32 -D_DEBUG -DDEBUG No matter where I type --analyze, as a first or the last parameter, I get this message: clang.exe: warning: argument unused during compilation: '--analyze' [-Wunused-command-line-argument] However --analyze does work with a contrived example like this: clang --analyze test.cpp, where test.cpp looks like that: #include int main(int, char**) { strcpy(NULL, "Hello"); return 0; } Regards, Michael -- 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 34987] New: Merge r310475 into the 5.0 branch : [Support] PR33388 - Fix formatv_object move constructor
https://bugs.llvm.org/show_bug.cgi?id=34987 Bug ID: 34987 Summary: Merge r310475 into the 5.0 branch : [Support] PR33388 - Fix formatv_object move constructor Product: new-bugs Version: 5.0 Hardware: All OS: All Status: NEW Severity: enhancement Priority: P Component: new bugs Assignee: unassignedb...@nondot.org Reporter: zhen@autodesk.com CC: llvm-bugs@lists.llvm.org Blocks: 34492 Is it OK to merge the following revision(s) to the 5.0 branch? Referenced Bugs: https://bugs.llvm.org/show_bug.cgi?id=34492 [Bug 34492] [meta] 5.0.1 Release Blockers -- 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 34989] New: clang crashes at -O3 with polly: `isl_set_is_subset(StmtDom, AccDom) && "Scalar must be loaded in all statement instances"' failed.
https://bugs.llvm.org/show_bug.cgi?id=34989 Bug ID: 34989 Summary: clang crashes at -O3 with polly: `isl_set_is_subset(StmtDom, AccDom) && "Scalar must be loaded in all statement instances"' failed. Product: Polly Version: unspecified Hardware: PC OS: Linux Status: NEW Severity: enhancement Priority: P Component: Optimizer Assignee: polly-...@googlegroups.com Reporter: helloqi...@gmail.com CC: llvm-bugs@lists.llvm.org It crashes with polly at "-O3" in 32-bit mode only. $ clang-trunk -v clang version 6.0.0 (trunk 315983) Target: x86_64-unknown-linux-gnu Thread model: posix InstalledDir: /usr/local/bin $ clang-trunk -mllvm -polly -m32 -O3 abc.c abc.c:10:7: warning: incompatible pointer types assigning to 'int *' from 'long long *' [-Wincompatible-pointer-types] h = &d; ^ ~~ abc.c:8:17: warning: relational comparison result unused [-Wunused-comparison] (d -= 0 || a) > (*g = 5); ~~^~ clang-6.0: /home/absozero/trunk/llvm/tools/polly/lib/CodeGen/BlockGenerators.cpp:564: void polly::BlockGenerator::generateScalarLoads(polly::ScopStmt&, llvm::LoopToScevMapT&, polly::ValueMapT&, isl_id_to_ast_expr*): Assertion `isl_set_is_subset(StmtDom, AccDom) && "Scalar must be loaded in all statement instances"' failed. #0 0x023e165a llvm::sys::PrintStackTrace(llvm::raw_ostream&) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x23e165a) #1 0x023df81e llvm::sys::RunSignalHandlers() (/home/absozero/trunk/root-clang/bin/clang-6.0+0x23df81e) #2 0x023df980 SignalHandler(int) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x23df980) #3 0x7faf2046d340 __restore_rt (/lib/x86_64-linux-gnu/libpthread.so.0+0x10340) #4 0x7faf1f25ecc9 gsignal /build/buildd/eglibc-2.19/signal/../nptl/sysdeps/unix/sysv/linux/raise.c:56:0 #5 0x7faf1f2620d8 abort /build/buildd/eglibc-2.19/stdlib/abort.c:91:0 #6 0x7faf1f257b86 __assert_fail_base /build/buildd/eglibc-2.19/assert/assert.c:92:0 #7 0x7faf1f257c32 (/lib/x86_64-linux-gnu/libc.so.6+0x2fc32) #8 0x02ad0b42 (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2ad0b42) #9 0x02ad0ba7 polly::BlockGenerator::copyBB(polly::ScopStmt&, llvm::BasicBlock*, llvm::DenseMap, llvm::AssertingVH, llvm::DenseMapInfo >, llvm::detail::DenseMapPair, llvm::AssertingVH > >&, llvm::DenseMap, llvm::detail::DenseMapPair >&, isl_id_to_ast_expr*) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2ad0ba7) #10 0x02ad0c51 polly::BlockGenerator::copyStmt(polly::ScopStmt&, llvm::DenseMap, llvm::detail::DenseMapPair >&, isl_id_to_ast_expr*) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2ad0c51) #11 0x02ae0b20 IslNodeBuilder::createUser(isl_ast_node*) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2ae0b20) #12 0x02add478 IslNodeBuilder::createBlock(isl_ast_node*) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2add478) #13 0x02add478 IslNodeBuilder::createBlock(isl_ast_node*) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2add478) #14 0x02a86294 CodeGen(polly::Scop&, polly::IslAstInfo&, llvm::LoopInfo&, llvm::DominatorTree&, llvm::ScalarEvolution&, llvm::RegionInfo&) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2a86294) #15 0x01aad8dd llvm::RGPassManager::runOnFunction(llvm::Function&) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x1aad8dd) #16 0x01f48343 llvm::FPPassManager::runOnFunction(llvm::Function&) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x1f48343) #17 0x01f483ec llvm::FPPassManager::runOnModule(llvm::Module&) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x1f483ec) #18 0x01f48c5a llvm::legacy::PassManagerImpl::run(llvm::Module&) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x1f48c5a) #19 0x02588805 (anonymous namespace)::EmitAssemblyHelper::EmitAssembly(clang::BackendAction, std::unique_ptr >) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2588805) #20 0x02589be3 clang::EmitBackendOutput(clang::DiagnosticsEngine&, clang::HeaderSearchOptions const&, clang::CodeGenOptions const&, clang::TargetOptions const&, clang::LangOptions const&, llvm::DataLayout const&, llvm::Module*, clang::BackendAction, std::unique_ptr >) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2589be3) #21 0x02dca97c clang::BackendConsumer::HandleTranslationUnit(clang::ASTContext&) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2dca97c) #22 0x02ff657c clang::ParseAST(clang::Sema&, bool, bool) (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2ff657c) #23 0x02dc9dc0 clang::CodeGenAction::ExecuteAction() (/home/absozero/trunk/root-clang/bin/clang-6.0+0x2dc9dc0) #24 0x0294b296 clang::FrontendAction::Execute() (/home/absozero/trunk/root-clang/bin/clang-6.0+0x294b296) #25 0x0291dc16 clang::CompilerInstance::ExecuteAction(clang::Frontend
[llvm-bugs] [Bug 34922] llvm-cov gcov on Windows fails with "function identifiers do not match" with simple test case using templates
https://bugs.llvm.org/show_bug.cgi?id=34922 Marco Castelluccio changed: What|Removed |Added Resolution|--- |FIXED Status|ASSIGNED|RESOLVED --- Comment #3 from Marco Castelluccio --- Fixed by r316048. -- 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] Issue 3669 in oss-fuzz: llvm: ASSERT: NumParams == params.size() && "function has too many parameters"
Status: New Owner: CC: k...@google.com, masc...@google.com, jdevlieg...@apple.com, llvm-b...@lists.llvm.org, v...@apple.com Labels: ClusterFuzz Stability-Memory-AddressSanitizer Reproducible Engine-libfuzzer Proj-llvm Reported-2017-10-18 New issue 3669 by monor...@clusterfuzz-external.iam.gserviceaccount.com: llvm: ASSERT: NumParams == params.size() && "function has too many parameters" https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=3669 Detailed report: https://oss-fuzz.com/testcase?key=6634601540747264 Project: llvm Fuzzer: libFuzzer_llvm_clang-fuzzer Job Type: libfuzzer_asan_llvm Platform Id: linux Crash Type: ASSERT Crash Address: Crash State: NumParams == params.size() && "function has too many parameters" clang::FunctionProtoType::FunctionProtoType clang::ASTContext::getFunctionTypeInternal Sanitizer: address (ASAN) Reproducer Testcase: https://oss-fuzz.com/download?testcase_id=6634601540747264 Issue filed automatically. See https://github.com/google/oss-fuzz/blob/master/docs/reproducing.md for more information. When you fix this bug, please * mention the fix revision(s). * state whether the bug was a short-lived regression or an old bug in any stable releases. * add any other useful information. This information can help downstream consumers. If you have questions for the OSS-Fuzz team, please file an issue at https://github.com/google/oss-fuzz/issues. -- You received this message because: 1. You were specifically CC'd on the issue You may adjust your notification preferences at: https://bugs.chromium.org/hosting/settings Reply to this email to add a comment. ___ llvm-bugs mailing list llvm-bugs@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs