Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(65)

Side by Side Diff: tests_lit/llvm2ice_tests/div_legalization.ll

Issue 955003002: Subzero: Clean up function header emission. (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Fix the tests that were broken as a result Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tests_lit/llvm2ice_tests/convert.ll ('k') | tests_lit/llvm2ice_tests/ebp_args.ll » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 ; This is a regression test that idiv and div operands are legalized 1 ; This is a regression test that idiv and div operands are legalized
2 ; (they cannot be constants and can only be reg/mem for x86). 2 ; (they cannot be constants and can only be reg/mem for x86).
3 3
4 ; RUN: %p2i --assemble --disassemble -i %s --args -O2 --verbose none \ 4 ; RUN: %p2i --filetype=obj --disassemble -i %s --args -O2 | FileCheck %s
5 ; RUN: | FileCheck %s 5 ; RUN: %p2i --filetype=obj --disassemble -i %s --args -Om1 | FileCheck %s
6 ; RUN: %p2i --assemble --disassemble -i %s --args -Om1 --verbose none \
7 ; RUN: | FileCheck %s
8 6
9 define i32 @Sdiv_const8_b(i8 %a) { 7 define i32 @Sdiv_const8_b(i8 %a) {
10 ; CHECK-LABEL: Sdiv_const8_b 8 ; CHECK-LABEL: Sdiv_const8_b
11 entry: 9 entry:
12 %div = sdiv i8 %a, 12 10 %div = sdiv i8 %a, 12
13 ; CHECK: mov {{.*}},0xc 11 ; CHECK: mov {{.*}},0xc
14 ; CHECK-NOT: idiv 0xc 12 ; CHECK-NOT: idiv 0xc
15 %div_ext = sext i8 %div to i32 13 %div_ext = sext i8 %div to i32
16 ret i32 %div_ext 14 ret i32 %div_ext
17 } 15 }
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 } 52 }
55 53
56 define i32 @Urem_const_b(i32 %a) { 54 define i32 @Urem_const_b(i32 %a) {
57 ; CHECK-LABEL: Urem_const_b 55 ; CHECK-LABEL: Urem_const_b
58 entry: 56 entry:
59 %rem = urem i32 %a, 4567 57 %rem = urem i32 %a, 4567
60 ; CHECK: mov {{.*}},0x11d7 58 ; CHECK: mov {{.*}},0x11d7
61 ; CHECK-NOT: div 0x11d7 59 ; CHECK-NOT: div 0x11d7
62 ret i32 %rem 60 ret i32 %rem
63 } 61 }
OLDNEW
« no previous file with comments | « tests_lit/llvm2ice_tests/convert.ll ('k') | tests_lit/llvm2ice_tests/ebp_args.ll » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698