<html>
<head>
<base href="https://bugs.llvm.org/">
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - clang crashes in CodeGen::CodeGenModule::getNaturalTypeAlignment with __builtin_neon_vld1q_v"
href="https://bugs.llvm.org/show_bug.cgi?id=46084">46084</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>clang crashes in CodeGen::CodeGenModule::getNaturalTypeAlignment with __builtin_neon_vld1q_v
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>trunk
</td>
</tr>
<tr>
<th>Hardware</th>
<td>PC
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>-New Bugs
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>samitolvanen@google.com
</td>
</tr>
<tr>
<th>CC</th>
<td>htmldeveloper@gmail.com, llvm-bugs@lists.llvm.org, ndesaulniers@google.com, neeilans@live.com, richard-llvm@metafoo.co.uk
</td>
</tr></table>
<p>
<div>
<pre>Building the arm64 Linux kernel with allyesconfig crashes clang when generating
code for crypto_aegis128_init_neon in crypto/aegis128-neon-inner.c. creduce
generates the following reproducer:
$ cat repro.c
#define a(b) __builtin_neon_vld1q_v(b, 48)
c;
d(void) { a(c); }
$ clang-11 -cc1 -triple aarch64-unknown-linux-gnu -emit-llvm-bc -x c repro.c
...
PLEASE submit a bug report to <a href="https://bugs.llvm.org/">https://bugs.llvm.org/</a> and include the crash
backtrace, preprocessed source, and associated run script.
Stack dump:
0. Program arguments: clang-11 -cc1 -triple aarch64-unknown-linux-gnu
-emit-llvm-bc -x c repro.c
1. <eof> parser at end of file
2. repro.c:3:1: LLVM IR generation of declaration 'd'
3. repro.c:3:1: Generating code for declaration 'd'
#0 0x00000000027b6274 PrintStackTraceSignalHandler(void*) (clang-11+0x27b6274)
#1 0x00000000027b3f8e llvm::sys::RunSignalHandlers() (clang-11+0x27b3f8e)
#2 0x00000000027b657c SignalHandler(int) (clang-11+0x27b657c)
#3 0x00007fa1a2d3c110 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x14110)
#4 0x0000000002b24fe1
clang::CodeGen::CodeGenModule::getNaturalTypeAlignment(clang::QualType,
clang::CodeGen::LValueBaseInfo*, clang::CodeGen::TBAAAccessInfo*, bool)
(clang-11+0x2b24fe1)
#5 0x0000000002d37fde
clang::CodeGen::CodeGenFunction::EmitAArch64BuiltinExpr(unsigned int,
clang::CallExpr const*, llvm::Triple::ArchType) (clang-11+0x2d37fde)
#6 0x0000000002cd2e2d
clang::CodeGen::CodeGenFunction::EmitBuiltinExpr(clang::GlobalDecl, unsigned
int, clang::CallExpr const*, clang::CodeGen::ReturnValueSlot)
(clang-11+0x2cd2e2d)
#7 0x0000000002b9ee03
clang::CodeGen::CodeGenFunction::EmitCallExpr(clang::CallExpr const*,
clang::CodeGen::ReturnValueSlot) (clang-11+0x2b9ee03)
#8 0x0000000002c29339 (anonymous
namespace)::ScalarExprEmitter::VisitCallExpr(clang::CallExpr const*)
(clang-11+0x2c29339)
#9 0x0000000002c19b8f
clang::CodeGen::CodeGenFunction::EmitScalarExpr(clang::Expr const*, bool)
(clang-11+0x2c19b8f)
#10 0x0000000002b861f5
clang::CodeGen::CodeGenFunction::EmitIgnoredExpr(clang::Expr const*)
(clang-11+0x2b861f5)
#11 0x0000000002c3d437 clang::CodeGen::CodeGenFunction::EmitStmt(clang::Stmt
const*, llvm::ArrayRef<clang::Attr const*>) (clang-11+0x2c3d437)
#12 0x0000000002c47910
clang::CodeGen::CodeGenFunction::EmitCompoundStmtWithoutScope(clang::CompoundStmt
const&, bool, clang::CodeGen::AggValueSlot) (clang-11+0x2c47910)
#13 0x0000000002b79395
clang::CodeGen::CodeGenFunction::EmitFunctionBody(clang::Stmt const*)
(clang-11+0x2b79395)
#14 0x0000000002b79e91
clang::CodeGen::CodeGenFunction::GenerateCode(clang::GlobalDecl,
llvm::Function*, clang::CodeGen::CGFunctionInfo const&) (clang-11+0x2b79e91)
#15 0x0000000002b1dd4c
clang::CodeGen::CodeGenModule::EmitGlobalFunctionDefinition(clang::GlobalDecl,
llvm::GlobalValue*) (clang-11+0x2b1dd4c)
#16 0x0000000002b17b3d
clang::CodeGen::CodeGenModule::EmitGlobalDefinition(clang::GlobalDecl,
llvm::GlobalValue*) (clang-11+0x2b17b3d)
#17 0x0000000002b20d2e
clang::CodeGen::CodeGenModule::EmitTopLevelDecl(clang::Decl*)
(clang-11+0x2b20d2e)
#18 0x00000000030f037f (anonymous
namespace)::CodeGeneratorImpl::HandleTopLevelDecl(clang::DeclGroupRef)
(clang-11+0x30f037f)
#19 0x00000000030ee1c2
clang::BackendConsumer::HandleTopLevelDecl(clang::DeclGroupRef)
(clang-11+0x30ee1c2)
#20 0x0000000003d60bb4 clang::ParseAST(clang::Sema&, bool, bool)
(clang-11+0x3d60bb4)
#21 0x000000000304a5b5 clang::FrontendAction::Execute() (clang-11+0x304a5b5)
#22 0x0000000002fa9451
clang::CompilerInstance::ExecuteAction(clang::FrontendAction&)
(clang-11+0x2fa9451)
#23 0x00000000030e99fb
clang::ExecuteCompilerInvocation(clang::CompilerInstance*) (clang-11+0x30e99fb)
#24 0x0000000001648d30 cc1_main(llvm::ArrayRef<char const*>, char const*,
void*) (clang-11+0x1648d30)
#25 0x00000000016470e1 ExecuteCC1Tool(llvm::SmallVectorImpl<char const*>&)
(clang-11+0x16470e1)
#26 0x0000000001646ea6 main (clang-11+0x1646ea6)
#27 0x00007fa1a12a2e0b __libc_start_main
/build/glibc-M65Gwz/glibc-2.30/csu/../csu/libc-start.c:342:3
#28 0x000000000164402a _start (clang-11+0x164402a)
...</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>