[PATCH] D98174: [MCA] Add tests for IPC on Cortex-A55

Andrew Savonichev via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Mar 9 04:02:52 PST 2021


asavonic added a comment.

In D98174#2611655 <https://reviews.llvm.org/D98174#2611655>, @dmgreen wrote:

> Any chance we can use more descriptive testcases names? :-)

Done :)



================
Comment at: llvm/test/tools/llvm-mca/AArch64/Cortex/IPC/A55-0.s:1
+# RUN: llvm-mca -mtriple=aarch64 -mcpu=cortex-a55 --dispatch-stats --iterations=1000 < %s | FileCheck %s
+# CHECK: IPC:
----------------
andreadb wrote:
> Do you actually need --dispatch-stats?
> If the goal of these tests is to simply check the IPC, then you should be able to simply pass flags `--all-views=false -summary-view`.
> 
> I also suggest to pass all these tests through the update_mca python script. If you only enable the summary-view, then the number of checks in the output will be very small.
> Do you actually need --dispatch-stats?
> If the goal of these tests is to simply check the IPC, then you should be able to simply pass flags `--all-views=false -summary-view`.

Thanks. I replaced --dispatch-stats with --summary-view.

> I also suggest to pass all these tests through the update_mca python script. If you only enable the summary-view, then the number of checks in the output will be very small.

I cannot figure out to how to combine both the reference checks and the checks
from update_mca. They match the same lines (IPC: X.XX), so we cannot use different
check prefixes:
```
    # RUN: llvm-mca $(args) < %s | FileCheck %s --check-prefixes=CHECK,CHECK-IPC
    # CHECK-IPC: IPC:
    # CHECK-IPC-SAME: 1.00

    add	w8, w8, #1

    # CHECK:      Iterations:        1000  <-- this check does not match, scan continues from IPC: 1.00
    # CHECK-NEXT: Instructions:      1000 
```         
I tried to add two FileCheck calls, but update_mca cannot handle this:
```
    # RUN: llvm-mca $(args) < %s > %t.log
    # RUN: FileCheck %s < %t.log
    # RUN: FileCheck %s --check-prefix CHECK-IPC < %t.log

    update_mca_test_checks.py:93: Warning: could not split tool and filecheck commands
```





Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D98174



More information about the llvm-commits mailing list