brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.9 KiB · e724f15 Raw
79 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py2; RUN: opt < %s -mtriple=aarch64-linux-gnu -passes="print<cost-model>" -cost-kind=all 2>&1 -disable-output | FileCheck %s3 4target datalayout = "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128"5 6define i32 @extract_first_i32({i32, i32} %agg) {7; CHECK-LABEL: 'extract_first_i32'8; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, i32 } %agg, 09; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i32 %r10;11  %r = extractvalue {i32, i32} %agg, 012  ret i32 %r13}14 15define i32 @extract_second_i32({i32, i32} %agg) {16; CHECK-LABEL: 'extract_second_i32'17; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, i32 } %agg, 118; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i32 %r19;20  %r = extractvalue {i32, i32} %agg, 121  ret i32 %r22}23 24define i32 @extract_i32({i32, i1} %agg) {25; CHECK-LABEL: 'extract_i32'26; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, i1 } %agg, 027; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i32 %r28;29  %r = extractvalue {i32, i1} %agg, 030  ret i32 %r31}32 33define i1 @extract_i1({i32, i1} %agg) {34; CHECK-LABEL: 'extract_i1'35; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, i1 } %agg, 136; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret i1 %r37;38  %r = extractvalue {i32, i1} %agg, 139  ret i1 %r40}41 42define float @extract_float({i32, float} %agg) {43; CHECK-LABEL: 'extract_float'44; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, float } %agg, 145; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret float %r46;47  %r = extractvalue {i32, float} %agg, 148  ret float %r49}50 51define [42 x i42] @extract_array({i32, [42 x i42]} %agg) {52; CHECK-LABEL: 'extract_array'53; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, [42 x i42] } %agg, 154; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret [42 x i42] %r55;56  %r = extractvalue {i32, [42 x i42]} %agg, 157  ret [42 x i42] %r58}59 60define <42 x i42> @extract_vector({i32, <42 x i42>} %agg) {61; CHECK-LABEL: 'extract_vector'62; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, <42 x i42> } %agg, 163; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret <42 x i42> %r64;65  %r = extractvalue {i32, <42 x i42>} %agg, 166  ret <42 x i42> %r67}68 69%T1 = type { i32, float, <4 x i1> }70 71define %T1 @extract_struct({i32, %T1} %agg) {72; CHECK-LABEL: 'extract_struct'73; CHECK-NEXT:  Cost Model: Found costs of 0 for: %r = extractvalue { i32, %T1 } %agg, 174; CHECK-NEXT:  Cost Model: Found costs of RThru:0 CodeSize:1 Lat:1 SizeLat:1 for: ret %T1 %r75;76  %r = extractvalue {i32, %T1} %agg, 177  ret %T1 %r78}79