[PATCH] D77105: [GlobalISel] Implement identity transforms for x op x -> x
Jessica Paquette via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 30 16:57:20 PDT 2020
paquette created this revision.
paquette added reviewers: aemerson, arsenm.
Herald added subscribers: danielkiss, volkan, hiraditya, kristof.beyls, rovka, wdng.
When we have
a = G_OR x, x
or
b = G_AND y, y
We can drop the `G_OR`/`G_AND` and just use `x`/`y` respectively.
Also update arm64-fallback.ll because there was an `or` in there which hits this transformation.
https://reviews.llvm.org/D77105
Files:
llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h
llvm/include/llvm/Target/GlobalISel/Combine.td
llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
llvm/test/CodeGen/AArch64/GlobalISel/arm64-fallback.ll
llvm/test/CodeGen/AArch64/GlobalISel/prelegalizercombiner-binop-same-val.mir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D77105.253741.patch
Type: text/x-patch
Size: 5970 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200330/87f372a6/attachment-0001.bin>
More information about the llvm-commits
mailing list