1*9880d681SAndroid Build Coastguard Worker; RUN: llc < %s -mtriple=powerpc64-unknown-linux-gnu -mcpu=pwr7 2*9880d681SAndroid Build Coastguard Workertarget datalayout = "E-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-f128:128:128-v128:128:128-n32:64" 3*9880d681SAndroid Build Coastguard Workertarget triple = "powerpc64-unknown-linux-gnu" 4*9880d681SAndroid Build Coastguard Worker 5*9880d681SAndroid Build Coastguard Worker; This tests that the GPRC/GPRC_NOR0 intersection subclass relationship with 6*9880d681SAndroid Build Coastguard Worker; GPRC is handled correctly. When it was not, this test would assert. 7*9880d681SAndroid Build Coastguard Worker 8*9880d681SAndroid Build Coastguard Worker@gen_random.last = external unnamed_addr global i64, align 8 9*9880d681SAndroid Build Coastguard Worker@.str = external unnamed_addr constant [4 x i8], align 1 10*9880d681SAndroid Build Coastguard Worker 11*9880d681SAndroid Build Coastguard Workerdeclare double @gen_random(double) #0 12*9880d681SAndroid Build Coastguard Worker 13*9880d681SAndroid Build Coastguard Workerdeclare void @benchmark_heapsort(i32 signext, double* nocapture) #0 14*9880d681SAndroid Build Coastguard Worker 15*9880d681SAndroid Build Coastguard Workerdefine signext i32 @main(i32 signext %argc, i8** nocapture %argv) #0 { 16*9880d681SAndroid Build Coastguard Workerentry: 17*9880d681SAndroid Build Coastguard Worker br i1 undef, label %cond.true, label %cond.end 18*9880d681SAndroid Build Coastguard Worker 19*9880d681SAndroid Build Coastguard Workercond.true: ; preds = %entry 20*9880d681SAndroid Build Coastguard Worker br label %cond.end 21*9880d681SAndroid Build Coastguard Worker 22*9880d681SAndroid Build Coastguard Workercond.end: ; preds = %cond.true, %entry 23*9880d681SAndroid Build Coastguard Worker %cond = phi i32 [ 0, %cond.true ], [ 8000000, %entry ] 24*9880d681SAndroid Build Coastguard Worker %add = add i32 %cond, 1 25*9880d681SAndroid Build Coastguard Worker %conv = sext i32 %add to i64 26*9880d681SAndroid Build Coastguard Worker %mul = shl nsw i64 %conv, 3 27*9880d681SAndroid Build Coastguard Worker %call1 = tail call noalias i8* @malloc(i64 %mul) #1 28*9880d681SAndroid Build Coastguard Worker br i1 undef, label %for.end, label %for.body.lr.ph 29*9880d681SAndroid Build Coastguard Worker 30*9880d681SAndroid Build Coastguard Workerfor.body.lr.ph: ; preds = %cond.end 31*9880d681SAndroid Build Coastguard Worker br label %for.body 32*9880d681SAndroid Build Coastguard Worker 33*9880d681SAndroid Build Coastguard Workerfor.body: ; preds = %for.body, %for.body.lr.ph 34*9880d681SAndroid Build Coastguard Worker %indvars.iv = phi i64 [ 1, %for.body.lr.ph ], [ %indvars.iv.next, %for.body ] 35*9880d681SAndroid Build Coastguard Worker %indvars.iv.next = add i64 %indvars.iv, 1 36*9880d681SAndroid Build Coastguard Worker %lftr.wideiv = trunc i64 %indvars.iv.next to i32 37*9880d681SAndroid Build Coastguard Worker %exitcond = icmp eq i32 %lftr.wideiv, %add 38*9880d681SAndroid Build Coastguard Worker br i1 %exitcond, label %for.cond.for.end_crit_edge, label %for.body 39*9880d681SAndroid Build Coastguard Worker 40*9880d681SAndroid Build Coastguard Workerfor.cond.for.end_crit_edge: ; preds = %for.body 41*9880d681SAndroid Build Coastguard Worker br label %for.end 42*9880d681SAndroid Build Coastguard Worker 43*9880d681SAndroid Build Coastguard Workerfor.end: ; preds = %for.cond.for.end_crit_edge, %cond.end 44*9880d681SAndroid Build Coastguard Worker ret i32 0 45*9880d681SAndroid Build Coastguard Worker} 46*9880d681SAndroid Build Coastguard Worker 47*9880d681SAndroid Build Coastguard Workerdeclare noalias i8* @malloc(i64) #0 48*9880d681SAndroid Build Coastguard Worker 49*9880d681SAndroid Build Coastguard Workerdeclare signext i32 @printf(i8* nocapture, ...) #0 50*9880d681SAndroid Build Coastguard Worker 51*9880d681SAndroid Build Coastguard Workerdeclare void @free(i8* nocapture) #0 52*9880d681SAndroid Build Coastguard Worker 53*9880d681SAndroid Build Coastguard Workerdeclare i64 @strtol(i8*, i8** nocapture, i32 signext) #0 54*9880d681SAndroid Build Coastguard Worker 55*9880d681SAndroid Build Coastguard Workerattributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" "no-frame-pointer-elim-non-leaf" "no-infs-fp-math"="false" "no-nans-fp-math"="false" "unsafe-fp-math"="false" "use-soft-float"="false" } 56*9880d681SAndroid Build Coastguard Workerattributes #1 = { nounwind } 57