This is a demo for: https://llvm.discourse.group/t/adding-comments-to-declarative-assembly-format/5906/
It isn't fleshed out and requires more thoughts: again this is just a demo to help the discussion on Discourse.
Differential D117942
Add a `printTrailingComment` method on OpAsmOpInterface mehdi_amini on Jan 21 2022, 8:51 PM. Authored by
Details
This is a demo for: https://llvm.discourse.group/t/adding-comments-to-declarative-assembly-format/5906/ It isn't fleshed out and requires more thoughts: again this is just a demo to help the discussion on Discourse.
Diff Detail
Event Timeline
Comment Actions I'd rather not have trailing in the name. If we have multiple things adding comments, how is this going to interact? Comment Actions I used trailing to express that it comes after the op completes (after trailing locations), and also because nothing can come after a trailing comment on the same line. Comment Actions (assuming this is multiple comments on 1 line) -1 there, that looks clunky (especially if the comments are more than a few characters) and would likely be very unreadable. That being said, I think right now your documentation leaves it open ended what "after the operation" means; i.e. I guess it could mean on separate line/same line/etc.
Comment Actions Discussed this with River:
|
Can you expand this a bit? Giving more detail, examples, etc?
It also isn't clear here if the comment is allowed to span multiple lines (which I guess not right now from the implementation?).