]> granicus.if.org Git - llvm/commit
[NFC][PowerPC] Use -check-prefixes to simplify the check in code-align.ll
authorKang Zhang <shkzhang@cn.ibm.com>
Tue, 30 Apr 2019 03:39:05 +0000 (03:39 +0000)
committerKang Zhang <shkzhang@cn.ibm.com>
Tue, 30 Apr 2019 03:39:05 +0000 (03:39 +0000)
commit4e6d30850cf2888e9ce451f6bed2de1c1c287850
tree103d2b3f8f46b17e21b86fab36a32e2b381bf29f
parent392c1020bc6bfbabe2853382e00f3c2f22f9b08d
[NFC][PowerPC] Use -check-prefixes to simplify the check in code-align.ll

Summary:
When checking the same output, we can use the `-check-prefixes` to simplify the check.
For example, if we want to check below output.
```
; GENERIC-LABEL: .globl  foo
; BASIC-LABEL: .globl  foo
; PWR-LABEL: .globl  foo
; GENERIC: .p2align  2
; BASIC: .p2align  4
; PWR: .p2align  4
; GENERIC: @foo
; BASIC: @foo
; PWR: @foo

```
If we use `-check-prefixes`
```
... -check-prefixes=CHECK,GENERAL
... -check-prefixes=CHECK,BASIC
... -check-prefixes=CHECK,PWR
```
Above check can be simplify to:
```
; CHECK-LABEL: .globl  foo
; GENERIC: .p2align  2
; BASIC: .p2align  4
; PWR: .p2align  4
; CHECK: @foo
```

Reviewed By: hfinkel
Differential Revision: https://reviews.llvm.org/D61227

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@359533 91177308-0d34-0410-b5e6-96231b3b80d8
test/CodeGen/PowerPC/code-align.ll