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

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

Issue 265703002: Add Om1 lowering with no optimizations (Closed) Base URL: https://gerrit.chromium.org/gerrit/p/native_client/pnacl-subzero.git@master
Patch Set: Address Jan's second-round comments Created 6 years, 7 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
OLDNEW
1 ; RUIN: %llvm2ice -verbose inst %s | FileCheck %s 1 ; Trivial smoke test of bitcast between integer and FP types.
2 ; RUIN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s 2
3 ; RUN: %llvm2ice --verbose inst %s | FileCheck %s
4 ; RUN: %llvm2ice --verbose none %s | FileCheck --check-prefix=ERRORS %s
3 ; RUN: %szdiff --llvm2ice=%llvm2ice %s | FileCheck --check-prefix=DUMP %s 5 ; RUN: %szdiff --llvm2ice=%llvm2ice %s | FileCheck --check-prefix=DUMP %s
4 6
5 define internal i32 @cast_f2i(float %f) { 7 define internal i32 @cast_f2i(float %f) {
6 entry: 8 entry:
7 %v0 = bitcast float %f to i32 9 %v0 = bitcast float %f to i32
10 ; CHECK: bitcast
8 ret i32 %v0 11 ret i32 %v0
9 } 12 }
10 13
11 define internal float @cast_i2f(i32 %i) { 14 define internal float @cast_i2f(i32 %i) {
12 entry: 15 entry:
13 %v0 = bitcast i32 %i to float 16 %v0 = bitcast i32 %i to float
17 ; CHECK: bitcast
14 ret float %v0 18 ret float %v0
15 } 19 }
16 20
17 define internal i64 @cast_d2ll(double %d) { 21 define internal i64 @cast_d2ll(double %d) {
18 entry: 22 entry:
19 %v0 = bitcast double %d to i64 23 %v0 = bitcast double %d to i64
24 ; CHECK: bitcast
20 ret i64 %v0 25 ret i64 %v0
21 } 26 }
22 27
23 define internal double @cast_ll2d(i64 %ll) { 28 define internal double @cast_ll2d(i64 %ll) {
24 entry: 29 entry:
25 %v0 = bitcast i64 %ll to double 30 %v0 = bitcast i64 %ll to double
31 ; CHECK: bitcast
26 ret double %v0 32 ret double %v0
27 } 33 }
28 34
29 ; ERRORS-NOT: ICE translation error 35 ; ERRORS-NOT: ICE translation error
30 ; DUMP-NOT: SZ 36 ; DUMP-NOT: SZ
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698