-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[UpdateTestChecks] Add EVM support in update_llc_test_checks.py
- Loading branch information
1 parent
1cddc81
commit 6d6934d
Showing
4 changed files
with
49 additions
and
0 deletions.
There are no files selected for viewing
6 changes: 6 additions & 0 deletions
6
llvm/test/tools/UpdateTestChecks/update_llc_test_checks/Inputs/evm-basic.ll
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
; RUN: llc < %s -mtriple=evm | FileCheck %s | ||
|
||
define i256 @swap_second_no_junk(i256 %a1, i256 %a2, i256 %a3, i256 %a4) nounwind { | ||
%x1 = sub i256 %a4, %a1 | ||
ret i256 %x1 | ||
} |
22 changes: 22 additions & 0 deletions
22
llvm/test/tools/UpdateTestChecks/update_llc_test_checks/Inputs/evm-basic.ll.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py | ||
; RUN: llc < %s -mtriple=evm | FileCheck %s | ||
|
||
define i256 @swap_second_no_junk(i256 %a1, i256 %a2, i256 %a3, i256 %a4) nounwind { | ||
; CHECK-LABEL: swap_second_no_junk: | ||
; CHECK: ; %bb.0: | ||
; CHECK-NEXT: JUMPDEST | ||
; CHECK-NEXT: DUP2 | ||
; CHECK-NEXT: DUP6 | ||
; CHECK-NEXT: SUB | ||
; CHECK-NEXT: SWAP5 | ||
; CHECK-NEXT: POP | ||
; CHECK-NEXT: DUP1 | ||
; CHECK-NEXT: SWAP4 | ||
; CHECK-NEXT: POP | ||
; CHECK-NEXT: POP | ||
; CHECK-NEXT: POP | ||
; CHECK-NEXT: POP | ||
; CHECK-NEXT: JUMP | ||
%x1 = sub i256 %a4, %a1 | ||
ret i256 %x1 | ||
} |
4 changes: 4 additions & 0 deletions
4
llvm/test/tools/UpdateTestChecks/update_llc_test_checks/evm-basic.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# REQUIRES: evm-registered-target | ||
|
||
# RUN: cp -f %S/Inputs/evm-basic.ll %t.ll && %update_llc_test_checks %t.ll | ||
# RUN: diff -u %S/Inputs/evm-basic.ll.expected %t.ll |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters