[PATCH] D77357: [PowerPC][UpdateTestChecks] Remove the extra # when scrubbing loop comments

Jinsong Ji via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 6 07:33:03 PDT 2020


jsji added inline comments.


================
Comment at: llvm/utils/UpdateTestChecks/asm.py:236
+  # Stripe unimportant loop comments.
+  asm = common.SCRUB_LOOP_COMMENT_RE.sub(r'', asm)
   # Strip trailing whitespace.
----------------
Why we want to scrub loop comment **TWICE**?
If the extra comments `#` is bothering you, 
can we try to add one regex to scrub it **AFTER** SCRUB_LOOP_COMMENT_RE?

Something like:
```
asm = common.SCRUB_LOOP_COMMENT_RE.sub(r'#', asm)
asm = common.SCRUB_TAILING_COMMENT_TOKEN_RE.sub(r'', asm)
```



Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D77357





More information about the llvm-commits mailing list