[llvm-bugs] [Bug 24893] New: Crash on class containing function named free()
via llvm-bugs
llvm-bugs at lists.llvm.org
Mon Sep 21 06:15:32 PDT 2015
https://llvm.org/bugs/show_bug.cgi?id=24893
Bug ID: 24893
Summary: Crash on class containing function named free()
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
Assignee: unassignedclangbugs at nondot.org
Reporter: jeanmichael.celerier at gmail.com
CC: dgregor at apple.com, llvm-bugs at lists.llvm.org
Classification: Unclassified
Created attachment 14918
--> https://llvm.org/bugs/attachment.cgi?id=14918&action=edit
A file that crashes
I get the following stack trace with the given attachment and clang3.7 (asked
on IRC and it's the case on latest trunk too).
% clang++-3.7 -std=c++14 test.cpp
0 libLLVM-3.7.so.1 0x00007f8957d5735d
llvm::sys::PrintStackTrace(llvm::raw_ostream&) + 45
1 libLLVM-3.7.so.1 0x00007f8957d56961
2 libpthread.so.0 0x00007f89566178d0
3 clang 0x0000000001288478 clang::Expr::IgnoreParens() + 8
4 clang 0x00000000012890ad clang::Expr::IgnoreParenImpCasts() + 13
5 clang 0x0000000000c23c29
6 clang 0x0000000000c24137
7 clang 0x0000000000c3a29c
8 clang 0x0000000000c3b528
clang::Sema::ActOnCXXDelete(clang::SourceLocation, bool, bool, clang::Expr*) +
264
9 clang 0x0000000000dc3f5d
10 clang 0x0000000000dc03dc
11 clang 0x0000000000dce10d
12 clang 0x0000000000dcf543
13 clang 0x0000000000dcf65b
14 clang 0x0000000000dce435
15 clang 0x0000000000dd194f clang::Sema::SubstStmt(clang::Stmt*,
clang::MultiLevelTemplateArgumentList const&) + 79
16 clang 0x0000000000de4a57
clang::Sema::InstantiateFunctionDefinition(clang::SourceLocation,
clang::FunctionDecl*, bool, bool) + 3687
17 clang 0x0000000000de4cca
clang::Sema::PerformPendingInstantiations(bool) + 282
18 clang 0x0000000000a97866 clang::Sema::ActOnEndOfTranslationUnit()
+ 278
19 clang 0x00000000009f0bc9
clang::Parser::ParseTopLevelDecl(clang::OpaquePtr<clang::DeclGroupRef>&) + 553
20 clang 0x00000000009e62ab clang::ParseAST(clang::Sema&, bool,
bool) + 459
21 clang 0x00000000006858be clang::FrontendAction::Execute() + 478
22 clang 0x000000000065deb9
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 297
23 clang 0x0000000000645e83
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 1907
24 clang 0x0000000000640b30 cc1_main(llvm::ArrayRef<char const*>,
char const*, void*) + 2256
25 clang 0x000000000063d60f main + 975
26 libc.so.6 0x00007f895517cb45 __libc_start_main + 245
27 clang 0x000000000063fbe4
Stack dump:
0. Program arguments: /usr/lib/llvm-3.7/bin/clang -cc1 -triple
x86_64-pc-linux-gnu -emit-obj -mrelax-all -disable-free -disable-llvm-verifier
-main-file-name test.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 -target-linker-version
2.25.1 -dwarf-column-info -resource-dir
/usr/lib/llvm-3.7/bin/../lib/clang/3.7.0 -internal-isystem
/usr/bin/../lib/gcc/x86_64-linux-gnu/5.2.1/../../../../include/c++/5.2.1
-internal-isystem
/usr/bin/../lib/gcc/x86_64-linux-gnu/5.2.1/../../../../include/x86_64-linux-gnu/c++/5.2.1
-internal-isystem
/usr/bin/../lib/gcc/x86_64-linux-gnu/5.2.1/../../../../include/x86_64-linux-gnu/c++/5.2.1
-internal-isystem
/usr/bin/../lib/gcc/x86_64-linux-gnu/5.2.1/../../../../include/c++/5.2.1/backward
-internal-isystem /usr/local/include -internal-isystem
/usr/lib/llvm-3.7/bin/../lib/clang/3.7.0/include -internal-externc-isystem
/usr/include/x86_64-linux-gnu -internal-externc-isystem /include
-internal-externc-isystem /usr/include -std=c++14 -fdeprecated-macro
-fdebug-compilation-dir /tmp -ferror-limit 19 -fmessage-length 135
-mstackrealign -fobjc-runtime=gcc -fcxx-exceptions -fexceptions
-fdiagnostics-show-option -fcolor-diagnostics -o /tmp/test-f3fc53.o -x c++
test.cpp
1. <eof> parser at end of file
2. test.cpp:11:14: instantiating function definition 'free'
clang: error: unable to execute command: Segmentation fault
clang: error: clang frontend command failed due to signal (use -v to see
invocation)
Debian clang version 3.7.0-2 (tags/RELEASE_370/final) (based on LLVM 3.7.0)
Target: x86_64-pc-linux-gnu
Thread model: posix
clang: note: diagnostic msg: PLEASE submit a bug report to
http://bugs.debian.org/ and include the crash backtrace, preprocessed source,
and associated run script.
clang: note: diagnostic msg:
********************
PLEASE ATTACH THE FOLLOWING FILES TO THE BUG REPORT:
Preprocessed source(s) and associated run script(s) are located at:
clang: note: diagnostic msg: /tmp/test-de646a.cpp
clang: note: diagnostic msg: /tmp/test-de646a.sh
clang: note: diagnostic msg:
********************
[1] 12952 exit 254 clang++-3.7 -std=c++14 test.cpp
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150921/1d89826e/attachment.html>
More information about the llvm-bugs
mailing list