This is an archive of the discontinued LLVM Phabricator instance.

[docs][NewPM] Move pass plugin documentation into existing new PM docs
ClosedPublic

Authored by aeubanks on Oct 24 2022, 10:47 AM.

Diff Detail

Event Timeline

aeubanks created this revision.Oct 24 2022, 10:47 AM
Herald added a project: Restricted Project. · View Herald Transcript
Herald added a subscriber: awarzynski. · View Herald Transcript
aeubanks requested review of this revision.Oct 24 2022, 10:47 AM
Herald added a project: Restricted Project. · View Herald TranscriptOct 24 2022, 10:47 AM

Thanks for all the effort @aeubanks ! Left some comments inline.

llvm/docs/WritingAnLLVMNewPMPass.rst
239–240

To me, "automatic pass registration" equals "static registration". However, IIUC, this is meant to cover both "static" and "dynamic" registration. And the first sentence here suggests that only static/automatic registration is covered.

256
257
262

Can you elaborate a bit? This isn't needed for Bye, is it? So when would it be needed?

Matt added a subscriber: Matt.Oct 27 2022, 9:15 AM
Meinersbur added inline comments.Oct 27 2022, 1:11 PM
llvm/docs/WritingAnLLVMNewPMPass.rst
262

"Bye" is already included in llvm/Support/Extension.def (if enabled in CMake configuration).

This needed is when you want to write a tool (like opt, bugpoint, ...) that uses the NPM pipeline builder to automatically add pass-extension plugins (such as "Bye") when creating an O1/O2/... pipeline (in addition to a the pre-registered set of passes). I.e. that does not just happen automatically if the tool itself does not add code for it.

aeubanks updated this revision to Diff 471688.Oct 28 2022, 5:00 PM

address comments

aeubanks updated this revision to Diff 471689.Oct 28 2022, 5:01 PM
aeubanks marked 2 inline comments as done.

fix awkward wording

llvm/docs/WritingAnLLVMNewPMPass.rst
239–240

better?

262

clearer now?

awarzynski accepted this revision.Oct 31 2022, 1:36 AM

Thanks for addressing my comments @aeubanks , LGTM!

This revision is now accepted and ready to land.Oct 31 2022, 1:36 AM
asbirlea accepted this revision.Nov 1 2022, 2:48 PM
asbirlea added a subscriber: asbirlea.

Thank you for adding this!

This revision was landed with ongoing or failed builds.Nov 2 2022, 10:47 AM
This revision was automatically updated to reflect the committed changes.