This is an archive of the discontinued LLVM Phabricator instance.

[CallPromotion] Check for inalloca/byval mismatch
ClosedPublic

Authored by aeubanks on Aug 12 2021, 2:33 PM.

Details

Summary

Previously we would allow promotion even if the byval/inalloca
attributes on the call and the callee didn't match.

It's ok if the byval/inalloca types aren't the same. For example, LTO
importing may rename types.

Fixes PR51397.

Diff Detail

Unit TestsFailed

Event Timeline

aeubanks created this revision.Aug 12 2021, 2:33 PM
aeubanks requested review of this revision.Aug 12 2021, 2:33 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 12 2021, 2:33 PM
aeubanks updated this revision to Diff 366115.Aug 12 2021, 2:45 PM

use hasParamAttribute()

rnk accepted this revision.Aug 13 2021, 10:12 AM

lgtm

This revision is now accepted and ready to land.Aug 13 2021, 10:12 AM
This revision was landed with ongoing or failed builds.Aug 13 2021, 4:56 PM
This revision was automatically updated to reflect the committed changes.