This is an archive of the discontinued LLVM Phabricator instance.

[X86] Add test suite for stack realignment.
ClosedPublic

Authored by LuoYuanke on Mar 13 2023, 5:00 AM.

Details

Summary

These test case is created to test D145650 and D146862 which create extra prolog and epilog when base pointer register is clobbered.

Event Timeline

LuoYuanke created this revision.Mar 13 2023, 5:00 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 13 2023, 5:00 AM
LuoYuanke requested review of this revision.Mar 13 2023, 5:00 AM
LuoYuanke updated this revision to Diff 508287.Mar 25 2023, 1:30 AM

Add test case to check function can return correctly with
extra prolog and epilog.

LuoYuanke edited the summary of this revision. (Show Details)
pengfei accepted this revision.Mar 25 2023, 6:44 PM

LGTM.

SingleSource/UnitTests/dyn_stack_alloc_realign.cpp
31

Why don't use aligned?

This revision is now accepted and ready to land.Mar 25 2023, 6:44 PM
LuoYuanke added inline comments.Mar 25 2023, 6:46 PM
SingleSource/UnitTests/dyn_stack_alloc_realign.cpp
31

Yes, using aligned looks better.

LuoYuanke updated this revision to Diff 508367.Mar 25 2023, 6:49 PM

Address Phoebe's comments.

LuoYuanke marked an inline comment as done.Mar 25 2023, 6:50 PM
This revision was automatically updated to reflect the committed changes.

It should be caused by x86 inline assembly. Let me create a X86 fold for these test.

Let me revert the patch first.