This is an archive of the discontinued LLVM Phabricator instance.

[compiler-rt][profile] Script for ABI checking
AcceptedPublic

Authored by phosek on May 6 2023, 2:46 PM.

Details

Reviewers
paulkirth
gulfem
Summary

This change includes a simple script that generates a textual summary
of the library ABI which is useful when detecting ABI breaking changes.

To demonstrate the output, this script was used to generate a summary of
the profile runtime ABI which could be helpful in C++ migration, see
https://reviews.llvm.org/D118421.

The output format is intentionally similar to the output of llvm-ifs.
While llvm-ifs doesn't (yet) support static archives, such support might
be implemented in the future at which point this script could be
replaced with llvm-ifs.

Note that this script currently only supports ELF since it relies on the
--elf-output-style=JSON option.

Diff Detail

Event Timeline

phosek created this revision.May 6 2023, 2:46 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 6 2023, 2:46 PM
Herald added subscribers: Enna1, dberris. · View Herald Transcript
phosek requested review of this revision.May 6 2023, 2:46 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 6 2023, 2:46 PM
Herald added a subscriber: Restricted Project. · View Herald Transcript
phosek edited the summary of this revision. (Show Details)May 6 2023, 2:47 PM
phosek updated this revision to Diff 520127.May 6 2023, 3:05 PM
paulkirth accepted this revision.May 25 2023, 11:18 AM

LGTM modulo one nit.

compiler-rt/utils/generate_abi_list.py
67–68

nit: can we rename content? its a bit confusing to shadow them like this. I've suggested headers, but anything is fine.

This revision is now accepted and ready to land.May 25 2023, 11:18 AM