This is an archive of the discontinued LLVM Phabricator instance.

GlobalISel: Move code into lowering for G_MERGE_VALUES
ClosedPublic

Authored by arsenm on Mar 31 2020, 6:00 AM.

Details

Summary

Currently this code exists in widenScalar for G_MERGE_VALUE
sources. I'm not sure if the existing expansion in widenScalar should
be removed or not. The widenScalar variant tries to extend to the
requested size, but this just uses the original bitwidth.

Diff Detail

Event Timeline

arsenm created this revision.Mar 31 2020, 6:00 AM
gargaroff added inline comments.Mar 31 2020, 6:24 AM
llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp
4826

Should this check be done before we create new instructions? Not sure what the current policy for this is. I'm also fine with leaving it down here since it will abort legalization anyway.

arsenm marked an inline comment as done.Apr 1 2020, 12:20 PM
arsenm added inline comments.
llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp
4826

I used to try avoiding creating instructions, but as you said it will be deleted

This revision is now accepted and ready to land.Apr 1 2020, 11:49 PM

Are you still planning on landing this?

Herald added a project: Restricted Project. · View Herald TranscriptMay 3 2020, 11:20 PM
arsenm added a comment.May 4 2020, 7:30 AM

Are you still planning on landing this?

Yes but I think this depended on some other patch first

llvm/test/CodeGen/AMDGPU/GlobalISel/legalize-load-global.mir