[PATCH] D65189: [MC] Support returning a structured rich disassembly output
Seiya Nuta via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 6 04:34:41 PDT 2019
seiya added inline comments.
================
Comment at: llvm/include/llvm/MC/MCInstPrinter.h:113-114
+ /// A stack of pointers which points to &MS set by setMarkupSpans or
+ /// InnerSpans of unclosed MarkupSpans. Here we use std::vector as a stack
+ /// instead of std::stack because we need "clear" method.
+ std::vector<std::vector<MarkupSpan> *> MarkupSpans;
----------------
jhenderson wrote:
> You could just use `while(!MarupSpans.empty()) MarkupSpans.pop();` instead of `clear`, if you want to use a `std::stack`.
Fixed. First I thought iterating all elements (`O(n)`) is not good but it won't be issue because `n` is small (typically n < 3) here...
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65189/new/
https://reviews.llvm.org/D65189
More information about the llvm-commits
mailing list