[PATCH] D116787: [llvm-readobj][MachO] Add option to sort the symbol table before dumping (MachO only, for now).

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 30 06:42:27 PDT 2022


jhenderson added inline comments.


================
Comment at: llvm/test/tools/llvm-readobj/sort-symbols.test:68
+...
+
----------------
Too many blank lines at EOF (should be exactly one \n at the end).


================
Comment at: llvm/test/tools/llvm-readobj/sort-symbols.test:16
+# CHECK: Format: aixcoff-rs6000
+# CHECK-NOT: warning '{{.+}}_macho': --sort-symbols is not supported yet for this format.
+# CHECK: Format: Mach-O 64-bit x86-64
----------------
oontvoo wrote:
> jhenderson wrote:
> > I'd consider pruning this back to just `warning '{{.+}}_macho':` to reduce the risk of false negatives due to a slight change in the warning message.
> Wouldn't that make the test more prone to false positives? that is, if some new warning pops up somewhere else, this would trip. So i'm going to keep this.
Yes, it would, but we probably shouldn't be invoking behaviour that causes those warnings anyway, so they're harmless (it would be easy to fix the test if it did trigger one in the future).

The test as it was before the last edit demonstrates why overly strict CHECK-NOTs are not much use, because typos can cause them to pass spuriously.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D116787



More information about the llvm-commits mailing list