Implemented builtins for mtmsr, mfspr, mtspr on PowerPC;
the patch is intended for XL Compatibility.
Details
- Reviewers
nemanjai - Commits
- rG2fd1520247de: [PowerPC] Implemented mtmsr, mfspr, mtspr Builtins
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Why does this review have no reviewers listed?
clang/lib/CodeGen/CGBuiltin.cpp | ||
---|---|---|
15694 | Is this the formatting that clang-format produces? Seems surprising it would format it that way. | |
clang/lib/Sema/SemaChecking.cpp | ||
3374 ↗ | (On Diff #359236) | I don't think we should enforce the range. The architecture may add more SPR's in the future and then this check will need to be updated. Just ensure that the register number (as well as the value for mtspr) are constants. |
llvm/include/llvm/IR/IntrinsicsPowerPC.td | ||
1579 | Nit: line too long | |
llvm/lib/Target/PowerPC/PPCInstr64Bit.td | ||
497 | Unrelated whitespace change. | |
llvm/lib/Target/PowerPC/PPCInstrInfo.td | ||
5486 | Shouldn't this be imm instead of i32? |
Changed i32 to timm for patterns, some nits
clang/lib/CodeGen/CGBuiltin.cpp | ||
---|---|---|
15694 | I ran git clang-format HEAD^ and it didn't change it, so seems like it was happy with this. |
Could you please add a check for constant arguments to clang/test/CodeGen/builtins-ppc-xlcompat-error.c?
llvm/test/CodeGen/builtins-ppc-xlcompat-move-tofrom-regs.ll | ||
---|---|---|
3 ↗ | (On Diff #359424) | No need to add this NOTE. Just remove the atuo generate line above. |
Is this the formatting that clang-format produces? Seems surprising it would format it that way.