[PATCH] D71363: [MIPS GlobalISel] Select bitreverse
Petar Avramovic via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 30 09:27:18 PST 2019
Petar.Avramovic added a comment.
Buildbot failures depend on compiler used to build clang.
Problem was in order which new MachineInstructions get inserted into MachineFunction.
Generated assembler does the same thing, but regression tests require consistent behavior regardless of compiler used.
In:
return B.buildOr(Dst, B.buildLShr(Ty, B.buildAnd(Ty, Src, MaskLoNTo0), C_N),
B.buildAnd(Ty, B.buildShl(Ty, Src, C_N), MaskLoNTo0));
it is important which method was executed first since they insert MachineInstructions into MachineFunction. Order of execution:
gcc
B.buildAnd(Ty, B.buildShl(Ty, Src, C_N), MaskLoNTo0)
B.buildLShr(Ty, B.buildAnd(Ty, Src, MaskLoNTo0), C_N)
clang
B.buildLShr(Ty, B.buildAnd(Ty, Src, MaskLoNTo0), C_N)
B.buildAnd(Ty, B.buildShl(Ty, Src, C_N), MaskLoNTo0)
recommit notes:
Introduce temporary variables in order to make sure instructions get inserted into MachineFunction in same order regardless of compiler used to build llvm.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D71363/new/
https://reviews.llvm.org/D71363
More information about the llvm-commits
mailing list