This is an archive of the discontinued LLVM Phabricator instance.

[PowerPC] make splat struct like an array for function arguments
Needs ReviewPublic

Authored by shchenz on Mar 4 2022, 1:16 AM.

Details

Reviewers
nemanjai
jsji
Group Reviewers
Restricted Project
Summary

Splat struct should be the same with an array. With this, we can get a more accurate alignment in CalculateStackSlotAlignment instead of conservative pointer size alignment.

In some cases, with accurate alignment, we can save parameter save areas like the test case change shows.

Diff Detail

Event Timeline

shchenz created this revision.Mar 4 2022, 1:16 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 4 2022, 1:16 AM
shchenz requested review of this revision.Mar 4 2022, 1:16 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 4 2022, 1:16 AM
amyk added a subscriber: amyk.Mar 8 2022, 7:18 AM
amyk added inline comments.
llvm/lib/Target/PowerPC/PPCISelLowering.cpp
16789

Could we maybe add a comment that describes that we do this for the more accurate alignment?

I am not sure if it is directly obvious in that this is the case.

shchenz updated this revision to Diff 413994.Mar 8 2022, 7:11 PM

address @amyk comments

shchenz marked an inline comment as done.Mar 8 2022, 7:11 PM
shchenz added inline comments.
llvm/lib/Target/PowerPC/PPCISelLowering.cpp
16789

Updated, thanks.

shchenz marked an inline comment as done.Mar 13 2022, 6:09 PM

gentle ping

gentle ping.

gentle ping

gentle ping

gentle ping

gentle ping

jsji resigned from this revision.Jun 2 2022, 7:52 AM

gentle ping

gentle ping

shchenz added a comment.EditedJul 7 2022, 9:59 PM

Gentle ping