[PATCH] D89240: Add initial infra to convert annotations to MD and display summary remarks (WIP)

Francis Visoiu Mistrih via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 6 12:02:21 PST 2020


thegameg added inline comments.


================
Comment at: llvm/lib/IR/Instruction.cpp:127
+    auto *Tuple = cast<MDTuple>(Existing->getOperand(0));
+    for (auto &N : make_range(Tuple->op_begin(), Tuple->op_end()))
+      Ops.push_back(N.get());
----------------



================
Comment at: llvm/lib/Transforms/Scalar/AnnotationRemarks.cpp:40
+    MDTuple *Strs = cast<MDTuple>(I.getMetadata("annotation")->getOperand(0));
+    for (const MDOperand &Op : make_range(Strs->op_begin(), Strs->op_end())) {
+      auto Iter = Mapping.insert({cast<MDString>(Op.get())->getString(), 0});
----------------



Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D89240/new/

https://reviews.llvm.org/D89240



More information about the llvm-commits mailing list