[llvm-bugs] [Bug 47299] New: llvm.get.active.lane.mask crashes for vl=64
via llvm-bugs
llvm-bugs at lists.llvm.org
Mon Aug 24 16:03:32 PDT 2020
https://bugs.llvm.org/show_bug.cgi?id=47299
Bug ID: 47299
Summary: llvm.get.active.lane.mask crashes for vl=64
Product: new-bugs
Version: unspecified
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: new bugs
Assignee: unassignedbugs at nondot.org
Reporter: ajcbik at google.com
CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org
Given
declare <16 x i1> @llvm.get.active.lane.mask.v16i1.i64(i64, i64)
define <16 x i1> @create_mask64(i64 %0, i64 %1) {
%3 = call <16 x i1> @llvm.get.active.lane.mask.v16i1.i64(i64 %0, i64 %1)
ret <16 x i1> %3
}
and compiling this for avx512 yields the following code without issues
vpbroadcastq zmm0, rsi
vpbroadcastq zmm1, rdi
vpaddq zmm2, zmm1, zmmword ptr [rip + .LCPI0_0]
vpcmpleuq k0, zmm2, zmm0
vpaddq zmm3, zmm1, zmmword ptr [rip + .LCPI0_1]
vpcmpleuq k1, zmm3, zmm0
kunpckbw k0, k1, k0
vpcmpltuq k1, zmm2, zmm1
vpcmpltuq k2, zmm3, zmm1
kunpckbw k1, k2, k1
kandnw k0, k1, k0
vpmovm2b xmm0, k0
vzeroupper
ret
However, using a longer vector length, like 64, crashes the backend
declare <64 x i1> @llvm.get.active.lane.mask.v64i1.i64(i64, i64)
define <64 x i1> @create_mask64(i64 %0, i64 %1) {
%3 = call <64 x i1> @llvm.get.active.lane.mask.v64i1.i64(i64 %0, i64 %1)
ret <64 x i1> %3
}
PLEASE submit a bug report to https://bugs.llvm.org/ and include the crash
backtrace.
Stack dump:
0. Program arguments: PATH/llvm/llvm-project/build/bin/llc -O3
--x86-asm-syntax=intel -mtriple=x86_64-grtev4-linux-gnu -march=x86-64
-mcpu=skylake-avx512 -mattr=fma,avx512f
1. Running pass 'Function Pass Manager' on module '<stdin>'.
2. Running pass 'X86 DAG->DAG Instruction Selection' on function
'@create_mask64'
#0 0x00005581034306a6 llvm::sys::PrintStackTrace(llvm::raw_ostream&)
PATH/llvm/llvm-project/llvm/lib/Support/Unix/Signals.inc:563:22
#1 0x0000558103430739 PrintStackTraceSignalHandler(void*)
PATH/llvm/llvm-project/llvm/lib/Support/Unix/Signals.inc:624:1
#2 0x000055810342e806 llvm::sys::RunSignalHandlers()
PATH/llvm/llvm-project/llvm/lib/Support/Signals.cpp:70:20
#3 0x00005581034300f0 SignalHandler(int)
PATH/llvm/llvm-project/llvm/lib/Support/Unix/Signals.inc:405:1
#4 0x00007f956d292110 __restore_rt
(/lib/x86_64-linux-gnu/libpthread.so.0+0x14110)
#5 0x0000558100bf3d9e llvm::Type::getTypeID() const
PATH/llvm/llvm-project/llvm/include/llvm/IR/Type.h:135:37
#6 0x0000558100bfa344 llvm::Type::isVectorTy() const
PATH/llvm/llvm-project/llvm/include/llvm/IR/Type.h:232:46
#7 0x000055810292fb34 llvm::EVT::isExtendedVector() const
PATH/llvm/llvm-project/llvm/lib/CodeGen/ValueTypes.cpp:75:1
#8 0x000055810292fe16 llvm::EVT::isExtendedScalableVector() const
PATH/llvm/llvm-project/llvm/lib/CodeGen/ValueTypes.cpp:114:29
#9 0x0000558100cc0710 llvm::EVT::isScalableVector() const
PATH/llvm/llvm-project/llvm/include/llvm/CodeGen/ValueTypes.h:163:74
#10 0x00005581031faae0 FoldBUILD_VECTOR(llvm::SDLoc const&, llvm::EVT,
llvm::ArrayRef<llvm::SDValue>, llvm::SelectionDAG&)
PATH/llvm/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:4296:3
#11 0x000055810321010b llvm::SelectionDAG::getNode(unsigned int, llvm::SDLoc
const&, llvm::EVT, llvm::ArrayRef<llvm::SDValue>, llvm::SDNodeFlags)
PATH/llvm/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp:7512:56
#12 0x0000558100d32f32 llvm::SelectionDAG::getBuildVector(llvm::EVT,
llvm::SDLoc const&, llvm::ArrayRef<llvm::SDValue>)
PATH/llvm/llvm-project/llvm/include/llvm/CodeGen/SelectionDAG.h:775:50
#13 0x00005581031b6d2f
llvm::SelectionDAGBuilder::visitIntrinsicCall(llvm::CallInst const&, unsigned
int)
PATH/llvm/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:6911:65
....
--
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/20200824/ef90e4c8/attachment.html>
More information about the llvm-bugs
mailing list