[all-commits] [llvm/llvm-project] 1de053: [llvm-mca] Abort on parse error without -skip-unsu...
Peter Waller via All-commits
all-commits at lists.llvm.org
Tue May 7 01:14:06 PDT 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 1de0535e84f03941badc8021bbc87a8c674a379f
https://github.com/llvm/llvm-project/commit/1de0535e84f03941badc8021bbc87a8c674a379f
Author: Peter Waller <peter.waller at arm.com>
Date: 2024-05-07 (Tue, 07 May 2024)
Changed paths:
M llvm/docs/CommandGuide/llvm-mca.rst
M llvm/docs/ReleaseNotes.rst
M llvm/test/tools/llvm-mca/AArch64/Exynos/float-divide-multiply.s
M llvm/test/tools/llvm-mca/AArch64/Exynos/float-integer.s
M llvm/test/tools/llvm-mca/ARM/cortex-a57-basic-instructions.s
M llvm/test/tools/llvm-mca/ARM/cortex-a57-thumb.s
M llvm/test/tools/llvm-mca/X86/BtVer2/simple-test.s
M llvm/test/tools/llvm-mca/X86/BtVer2/skip-unsupported-instructions-none-remain.s
M llvm/test/tools/llvm-mca/X86/BtVer2/unsupported-instruction.s
A llvm/test/tools/llvm-mca/bad-input.s
M llvm/tools/llvm-mca/CodeRegionGenerator.cpp
M llvm/tools/llvm-mca/CodeRegionGenerator.h
M llvm/tools/llvm-mca/llvm-mca.cpp
Log Message:
-----------
[llvm-mca] Abort on parse error without -skip-unsupported-instructions (#90474)
[llvm-mca] Abort on parse error without -skip-unsupported-instructions
Prior to this patch, llvm-mca would continue executing after parse
errors. These errors can lead to some confusion since some analysis
results are printed on the standard output, and they're printed after
the errors, which could otherwise be easy to miss.
However it is still useful to be able to continue analysis after errors;
so extend the recently added -skip-unsupported-instructions to support
this.
Two tests which have parse errors for some of the 'RUN' branches are
updated to use -skip-unsupported-instructions so they can remain as-is.
Add a description of -skip-unsupported-instructions to the llvm-mca
command guide, and add it to the llvm-mca --help output:
```
--skip-unsupported-instructions=<value> - Force analysis to continue in the presence of unsupported instructions
=none - Exit with an error when an instruction is unsupported for any reason (default)
=lack-sched - Skip instructions on input which lack scheduling information
=parse-failure - Skip lines on the input which fail to parse for any reason
=any - Skip instructions or lines on input which are unsupported for any reason
```
Tests within this patch are intended to cover each of the cases.
Reason | Flag | Comment
--------------|------|-------
none | none | Usual case, existing test suite
lack-sched | none | Advises user to use -skip-unsupported-instructions=lack-sched, tested in llvm/test/tools/llvm-mca/X86/BtVer2/unsupported-instruction.s
parse-failure | none | Advises user to use -skip-unsupported-instructions=parse-failure, tested in llvm/test/tools/llvm-mca/bad-input.s
any | none | (N/A, covered above)
lack-sched | any | Continues, prints warnings, tested in llvm/test/tools/llvm-mca/X86/BtVer2/unsupported-instruction.s
parse-failure | any | Continues, prints errors, tested in llvm/test/tools/llvm-mca/bad-input.s
lack-sched | parse-failure | Advises user to use -skip-unsupported-instructions=lack-sched, tested in llvm/test/tools/llvm-mca/X86/BtVer2/unsupported-instruction.s
parse-failure | lack-sched | Advises user to use -skip-unsupported-instructions=parse-failure, tested in llvm/test/tools/llvm-mca/bad-input.s
none | * | This would be any test case with skip-unsupported-instructions, coverage added in llvm/test/tools/llvm-mca/X86/BtVer2/simple-test.s
any | * | (Logically covered by the other cases)
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list