1 ; RUN: opt -slp-vectorizer -S < %s | FileCheck %s 2 target datalayout = "e-m:w-i64:64-f80:128-n8:16:32:64-S128" 3 target triple = "x86_64-pc-windows-msvc18.0.0" 4 5 %struct.B = type { i64, i64 } 6 7 define void @test1(%struct.B* %p) personality i32 (...)* @__CxxFrameHandler3 { 8 invoke.cont: 9 %gep1 = getelementptr inbounds %struct.B, %struct.B* %p, i64 0, i32 0 10 %gep2 = getelementptr inbounds %struct.B, %struct.B* %p, i64 0, i32 1 11 %load1 = load i64, i64* %gep1, align 8 12 %load2 = load i64, i64* %gep2, align 8 13 store i64 %load1, i64* %gep1, align 8 14 store i64 %load2, i64* %gep2, align 8 15 invoke void @throw() 16 to label %unreachable unwind label %catch.dispatch 17 18 catch.dispatch: ; preds = %invoke.cont 19 %cs = catchswitch within none [label %invoke.cont1] unwind label %ehcleanup 20 21 invoke.cont1: ; preds = %catch.dispatch 22 %catch = catchpad within %cs [i8* null, i32 64, i8* null] 23 invoke void @throw() [ "funclet"(token %catch) ] 24 to label %unreachable unwind label %ehcleanup 25 26 ehcleanup: ; preds = %invoke.cont1, %catch.dispatch 27 %phi = phi i64 [ %load1, %catch.dispatch ], [ 9, %invoke.cont1 ] 28 %cleanup = cleanuppad within none [] 29 call void @release(i64 %phi) [ "funclet"(token %cleanup) ] 30 cleanupret from %cleanup unwind to caller 31 32 unreachable: ; preds = %invoke.cont1, %invoke.cont 33 unreachable 34 } 35 36 37 ; CHECK-LABEL: define void @test1( 38 ; CHECK: %[[gep:.*]] = getelementptr inbounds %struct.B, %struct.B* %p, i64 0, i32 0 39 ; CHECK: %[[bc:.*]] = bitcast i64* %[[gep]] to <2 x i64>* 40 ; CHECK: %[[ld:.*]] = load <2 x i64>, <2 x i64>* %[[bc]], align 8 41 ; CHECK: %[[ee:.*]] = extractelement <2 x i64> %[[ld]], i32 0 42 43 ; CHECK: %[[phi:.*]] = phi i64 [ %[[ee]], {{.*}} ], [ 9, {{.*}} ] 44 ; CHECK: call void @release(i64 %[[phi]]) 45 46 declare i32 @__CxxFrameHandler3(...) 47 48 declare void @throw() 49 50 declare void @release(i64) 51