This is an archive of the discontinued LLVM Phabricator instance.

[PowerPC][GISEL]support for float point and integer convertion
ClosedPublic

Authored by shchenz on Dec 2 2022, 12:45 AM.

Details

Summary

Add support for fptosi,fptoui,sitofp,uitofp

For now only handle 64 bit integer to make it does not depend on any other patches. 32 bit integer needs handling for G_SEXT/G_ZEXT.

Diff Detail

Event Timeline

shchenz created this revision.Dec 2 2022, 12:45 AM
Herald added a project: Restricted Project. · View Herald TranscriptDec 2 2022, 12:45 AM
shchenz requested review of this revision.Dec 2 2022, 12:45 AM
Herald added a project: Restricted Project. · View Herald TranscriptDec 2 2022, 12:45 AM
arsenm accepted this revision.Dec 2 2022, 8:20 AM

Seems a shame to have to have all that manual selection for such a simple instruction

llvm/lib/Target/PowerPC/GISel/PPCInstructionSelector.cpp
136

Typo inteter

This revision is now accepted and ready to land.Dec 2 2022, 8:20 AM
shchenz added a comment.EditedDec 4 2022, 7:21 PM

Seems a shame to have to have all that manual selection for such a simple instruction

Thanks for review. Yeah, we can improve this at least for simple patterns when direct move and fpcvt are available on the targets in future.

This revision was landed with ongoing or failed builds.Dec 4 2022, 7:22 PM
This revision was automatically updated to reflect the committed changes.