Jiahui17 wrote:

Somehow, in a quite old LLVM version 
(https://github.com/llvm/llvm-project/tree/26eb4285b56edd8c897642078d91f16ff0fd3472)
 clang could report the correct bitwidth

For instance, 
```c
unsigned _BitInt(5) weight[10] = {10, 9, 8, 7, 6, 5, 4, 3, 2, 1};
```

can be correctly translated into 

```llvm
@__const.main.weight = private unnamed_addr constant [10 x i5] [i5 10, i5 9, i5 
8, i5 7, i5 6, i5 5, i5 4, i5 3, i5 2, i5 1], align 1
```

But currently it would be 
```
@__const.main.weight = private unnamed_addr constant [10 x i8]
```


https://github.com/llvm/llvm-project/pull/161796
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to