[PATCH] D52996: [GlobalISel] Fix the artifact combiner to fold G_IMPLICIT_DEF properly
Volkan Keles via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Oct 8 12:46:40 PDT 2018
volkan created this revision.
volkan added reviewers: aditya_nandakumar, dsanders, aemerson.
Herald added subscribers: kristof.beyls, rovka.
Herald added a reviewer: javed.absar.
GlobalISel generates incorrect code because the legalizer artifact
combiner assumes `G_[SZ]EXT (G_IMPLICIT_DEF)` is equivalent to
`G_IMPLICIT_DEF `.
Replace `G_[SZ]EXT (G_IMPLICIT_DEF)` with 0 because the top bits
will be 0 for G_ZEXT and 0/1 for the G_SEXT.
https://reviews.llvm.org/D52996
Files:
include/llvm/CodeGen/GlobalISel/LegalizationArtifactCombiner.h
test/CodeGen/AArch64/GlobalISel/legalize-ext.mir
test/CodeGen/X86/GlobalISel/legalize-ext.mir
test/CodeGen/X86/GlobalISel/legalize-undef.mir
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D52996.168701.patch
Type: text/x-patch
Size: 8682 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20181008/8ad32ca3/attachment.bin>
More information about the llvm-commits
mailing list