This is an archive of the discontinued LLVM Phabricator instance.

[lld-macho] Change personalities entry type to Ptr to avoid overflowing uint32
ClosedPublic

Authored by oontvoo on Jul 28 2021, 10:10 PM.

Details

Summary

We push the CompactUnwindEntry::personality into this vector<uint32_t>.
On 64-bit, CompactUnwindEntry::personality is uint64 so it'd overflow and cause the find() to never find a matching entry, hence the "too many personalities ...." error message.

Bug: PR51262

Diff Detail

Event Timeline

oontvoo created this revision.Jul 28 2021, 10:10 PM
Herald added a project: Restricted Project. · View Herald Transcript
Herald added a reviewer: Restricted Project. · View Herald Transcript
oontvoo requested review of this revision.Jul 28 2021, 10:10 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 28 2021, 10:10 PM
oontvoo edited the summary of this revision. (Show Details)Jul 28 2021, 10:13 PM
int3 accepted this revision.Jul 29 2021, 8:01 AM
int3 added a subscriber: int3.

would be nice to have a test for this, but I guess it's somewhat awkward to write...

This revision is now accepted and ready to land.Jul 29 2021, 8:01 AM