You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
unsigned long int __my__mulXf3__(unsigned long int a) {
unsigned long int Res = a + ((1UL << 52) - 1U);
int Exp = a + ((1 << 12) >> 1);
if (Exp <= 6) {
int shift = 5 - Exp;
if (shift < 7) {
Res = Res + shift;
}
} else {
Res &= ((1UL << 52) - 1U);
}
return Res;
}
复现的llvm分支: main
复现的编译选项: ./build/bin/clang -O1 -S -target riscv32 -mcpu=ventus-gpgpu test.cl
由CTS的geom_normalize测试发现的问题, 下面是分析出的一个最小复现用例:
复现的llvm分支: main
复现的编译选项: ./build/bin/clang -O1 -S -target riscv32 -mcpu=ventus-gpgpu test.cl
生成的汇编:
分析: 看标的注释, 在分支的前面定义了t0, 在else分支用到了这个t0, 但是在if分支重复定义了t0, 这会导致else分支的t0会被覆盖
现在的初步想法是: 不允许在分支中定义标量寄存器
The text was updated successfully, but these errors were encountered: