The builtin __rlwnm is currently constrained to accept only constants
for the shift parameter but the instructions emitted for it have no such
constraint, this patch allows the builtins to accept variable shift.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/test/CodeGen/builtins-ppc-xlcompat-error.c | ||
---|---|---|
44–45 | Please also remove __builtin_ppc_rlwnm(ui, shift, 7); in this test. We only keep cases trigger sema check errors. |
Comment Actions
Please check and add a test in clang/test/CodeGen/builtins-ppc-xlcompat-rotate.c with shift as a variable.
Comment Actions
Adding shift variable test case to builtins-ppc-xlcompat-rotate.c as per
review comment request.
Comment Actions
Thanks. LGTM. One minor can be addressed when commit it.
clang/test/CodeGen/builtins-ppc-xlcompat-rotate.c | ||
---|---|---|
71 | please remove shift = 31, in the comment |
Please also remove __builtin_ppc_rlwnm(ui, shift, 7); in this test. We only keep cases trigger sema check errors.