Open NoamDev opened 2 years ago
Also, we have problems with masks:
so I replaced the bitfields with masks). However I'm still getting errors.
LLVM ERROR: Cannot select: 0x2e1d320: i257 = ctlz 0x2e13308
0x2e13308: i257,ch = CopyFromReg 0x2dd2198, Register:i257 %31
0x2e12dc0: i257 = Register %31
LLVM ERROR: Cannot select: 0x353b5c8: i257 = sign_extend_inreg 0x353c398, ValueType:ch:i128
0x353c398: i257,ch = CopyFromReg 0x34230b8, Register:i257 %9
0x353bde8: i257 = Register %9
While TVM-llvm only supports i257 type, in bit fields, it still chooses types like i128.
Reproduce Instructions:
Contract.cpp
compile command:
Note: The -O0 is important, -O3 would optimize the problem away in simple cases such as this example.
Resulting IR code:
Note the "i128" in line number 4.