https://bugs.llvm.org/show_bug.cgi?id=48615
Bug ID: 48615
Summary: Assertion `NumBits <= MAX_INT_BITS && "bitwidth too
large"' on large store
Product: new-bugs
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: new bugs
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected]
`splitMergedValStore` tries to create an integer with the number of bits that
the size of the type has - for example, a 5 mb type will try to create an
integer with 5*1024*1024*8 bits which fails the MAX_INT_BITS check.
https://github.com/llvm/llvm-project/blob/a485a59d2172daaee1d5e734da54fbb243f7d54c/llvm/lib/CodeGen/CodeGenPrepare.cpp#L7271
```
%large = type { [42000000 x i8] }
define void @set(%large, %large*) {
store %large %0, %large* %1
ret void
}
```
```
$ llc test.ll
llc: ../lib/IR/Type.cpp:256: static llvm::IntegerType*
llvm::IntegerType::get(llvm::LLVMContext&, unsigned int): Assertion `NumBits <=
MAX_INT_BITS && "bitwidth too large"' failed.
...
#9 0x00007fc02ab9c4f7 llvm::IntegerType::get(llvm::LLVMContext&, unsigned int)
../lib/IR/Type.cpp:255:3
#10 0x00007fc02ac4a02a llvm::DataLayout::getTypeStoreSize(llvm::Type*) const
../include/llvm/IR/DataLayout.h:459:45
#11 0x00007fc02ac4a02a llvm::DataLayout::getTypeStoreSizeInBits(llvm::Type*)
../include/llvm/IR/DataLayout.h:471:35
#12 0x00007fc02ac4a02a llvm::DataLayout::typeSizeEqualsStoreSize(llvm::Type*)
../include/llvm/IR/DataLayout.h:479:62
#13 0x00007fc02ac4a02a splitMergedValStore
../lib/CodeGen/CodeGenPrepare.cpp:7191:34
```
--
You are receiving this mail because:
You are on the CC list for the bug._______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs