This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Increase alignment of LDS globals if necessary before LDS lowering.
AbandonedPublic

Authored by hsmhsm on Jun 4 2021, 12:25 AM.

Details

Summary

Before packing LDS globals into a sorted structure, make sure that
their alignment is properly updated based on their size. This will make
sure that the members of sorted structure are properly aligned, and
hence it will further reduce the probability of unaligned LDS access.

Diff Detail

Unit TestsFailed

Event Timeline

hsmhsm created this revision.Jun 4 2021, 12:25 AM
hsmhsm requested review of this revision.Jun 4 2021, 12:25 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 4 2021, 12:25 AM

The earlier commited patch https://reviews.llvm.org/D103261 had to be reverted since Align Alignment(GV->getAlignment()); was causing assert when GV->getAlignment() returns 0.

Please continue the review in the existing place (i.e. reopen it) instead of making a new one