You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[RS4GC] Copy argument attributes from call to statepoint
The current implementation completely ignores argument attributes on calls, discarding them completely when creating a statepoint from a call instruction.
This is problematic in some scenarios as the argument attributes affect the ABI of the call, leading to undefined behavior if called with the wrong ABI attributes.
Note that this cannot be solved either by just having the function declaration annotated with the right parameter attributes as the call might be indirect, therefore requiring them to be present on the arguments.
This PR simply copies all parameter attributes over from the original call to the created statepoint.
declare i32 @personality_function()
declare i32 @personality_function()
Note that some argument attributes become invalid after the lowering as they imply memory effects that no longer hold with the statepoints. These do not need to be explicitly handled in this PR as they are removed by the `stripNonValidDataFromBody`.
0 commit comments