This is an archive of the discontinued LLVM Phabricator instance.

Extend -fkeep-persistent-storage-variables to cover compiler generated artifacts with reasonable mangled names that have persistent storage
Needs ReviewPublic

Authored by qianzhen on Jul 19 2023, 7:11 AM.

Details

Summary

This is a follow-up patch to https://reviews.llvm.org/D150221. It extends -fkeep-persistent-storage-variables to cover compiler generated artifacts—including the symbols for temporaries bound to references with persistent storage and guard variables.

Question:
The guard variables are created in each derived CXXABI class (namely ItaniumCXXABI and MicrosoftCXXABI). Hence, they are emitted after their creation accordingly in this patch. I'm not sure if there is a common place to emit them for all CXXABIs outside the derived CXXABI classes. Any suggestions would be appreciated.

Diff Detail

Event Timeline

qianzhen created this revision.Jul 19 2023, 7:11 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 19 2023, 7:11 AM
qianzhen requested review of this revision.Jul 19 2023, 7:11 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 19 2023, 7:11 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript