1*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mattr=mips16 -relocation-model=static < %s | FileCheck %s -check-prefix=1 2*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mattr=mips16 -relocation-model=static < %s | FileCheck %s -check-prefix=2 3*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mattr=mips16 -relocation-model=static < %s | FileCheck %s -check-prefix=3 4*9880d681SAndroid Build Coastguard Worker; RUN: llc -mtriple=mipsel-linux-gnu -march=mipsel -mattr=mips16 -relocation-model=static < %s | FileCheck %s -check-prefix=4 5*9880d681SAndroid Build Coastguard Worker 6*9880d681SAndroid Build Coastguard Worker 7*9880d681SAndroid Build Coastguard Worker@x = global float 0x41F487E980000000, align 4 8*9880d681SAndroid Build Coastguard Worker@dx = global double 0x41CDCC8BC4800000, align 8 9*9880d681SAndroid Build Coastguard Worker@cx = global { float, float } { float 1.000000e+00, float 9.900000e+01 }, align 4 10*9880d681SAndroid Build Coastguard Worker@dcx = global { double, double } { double 0x42CE5E14A412B480, double 0x423AA4C580DB0000 }, align 8 11*9880d681SAndroid Build Coastguard Worker 12*9880d681SAndroid Build Coastguard Workerdefine float @foox() { 13*9880d681SAndroid Build Coastguard Workerentry: 14*9880d681SAndroid Build Coastguard Worker %0 = load float, float* @x, align 4 15*9880d681SAndroid Build Coastguard Worker ret float %0 16*9880d681SAndroid Build Coastguard Worker; 1: .ent foox 17*9880d681SAndroid Build Coastguard Worker; 1: lw $2, %lo(x)(${{[0-9]+}}) 18*9880d681SAndroid Build Coastguard Worker; 1: jal __mips16_ret_sf 19*9880d681SAndroid Build Coastguard Worker} 20*9880d681SAndroid Build Coastguard Worker 21*9880d681SAndroid Build Coastguard Workerdefine double @foodx() { 22*9880d681SAndroid Build Coastguard Workerentry: 23*9880d681SAndroid Build Coastguard Worker %0 = load double, double* @dx, align 8 24*9880d681SAndroid Build Coastguard Worker ret double %0 25*9880d681SAndroid Build Coastguard Worker; 1: .ent foodx 26*9880d681SAndroid Build Coastguard Worker; 1: lw $2, %lo(dx)(${{[0-9]+}}) 27*9880d681SAndroid Build Coastguard Worker; 1: jal __mips16_ret_df 28*9880d681SAndroid Build Coastguard Worker; 2: .ent foodx 29*9880d681SAndroid Build Coastguard Worker; 2: lw $3, 4(${{[0-9]+}}) 30*9880d681SAndroid Build Coastguard Worker; 2: jal __mips16_ret_df 31*9880d681SAndroid Build Coastguard Worker 32*9880d681SAndroid Build Coastguard Worker} 33*9880d681SAndroid Build Coastguard Worker 34*9880d681SAndroid Build Coastguard Workerdefine { float, float } @foocx() { 35*9880d681SAndroid Build Coastguard Workerentry: 36*9880d681SAndroid Build Coastguard Worker %retval = alloca { float, float }, align 4 37*9880d681SAndroid Build Coastguard Worker %cx.real = load float, float* getelementptr inbounds ({ float, float }, { float, float }* @cx, i32 0, i32 0) 38*9880d681SAndroid Build Coastguard Worker %cx.imag = load float, float* getelementptr inbounds ({ float, float }, { float, float }* @cx, i32 0, i32 1) 39*9880d681SAndroid Build Coastguard Worker %real = getelementptr inbounds { float, float }, { float, float }* %retval, i32 0, i32 0 40*9880d681SAndroid Build Coastguard Worker %imag = getelementptr inbounds { float, float }, { float, float }* %retval, i32 0, i32 1 41*9880d681SAndroid Build Coastguard Worker store float %cx.real, float* %real 42*9880d681SAndroid Build Coastguard Worker store float %cx.imag, float* %imag 43*9880d681SAndroid Build Coastguard Worker %0 = load { float, float }, { float, float }* %retval 44*9880d681SAndroid Build Coastguard Worker ret { float, float } %0 45*9880d681SAndroid Build Coastguard Worker; 1: .ent foocx 46*9880d681SAndroid Build Coastguard Worker; 1: lw $2, %lo(cx)(${{[0-9]+}}) 47*9880d681SAndroid Build Coastguard Worker; 1: jal __mips16_ret_sc 48*9880d681SAndroid Build Coastguard Worker; 2: .ent foocx 49*9880d681SAndroid Build Coastguard Worker; 2: lw $3, 4(${{[0-9]+}}) 50*9880d681SAndroid Build Coastguard Worker; 2: jal __mips16_ret_sc 51*9880d681SAndroid Build Coastguard Worker} 52*9880d681SAndroid Build Coastguard Worker 53*9880d681SAndroid Build Coastguard Workerdefine { double, double } @foodcx() { 54*9880d681SAndroid Build Coastguard Workerentry: 55*9880d681SAndroid Build Coastguard Worker %retval = alloca { double, double }, align 8 56*9880d681SAndroid Build Coastguard Worker %dcx.real = load double, double* getelementptr inbounds ({ double, double }, { double, double }* @dcx, i32 0, i32 0) 57*9880d681SAndroid Build Coastguard Worker %dcx.imag = load double, double* getelementptr inbounds ({ double, double }, { double, double }* @dcx, i32 0, i32 1) 58*9880d681SAndroid Build Coastguard Worker %real = getelementptr inbounds { double, double }, { double, double }* %retval, i32 0, i32 0 59*9880d681SAndroid Build Coastguard Worker %imag = getelementptr inbounds { double, double }, { double, double }* %retval, i32 0, i32 1 60*9880d681SAndroid Build Coastguard Worker store double %dcx.real, double* %real 61*9880d681SAndroid Build Coastguard Worker store double %dcx.imag, double* %imag 62*9880d681SAndroid Build Coastguard Worker %0 = load { double, double }, { double, double }* %retval 63*9880d681SAndroid Build Coastguard Worker ret { double, double } %0 64*9880d681SAndroid Build Coastguard Worker; 1: .ent foodcx 65*9880d681SAndroid Build Coastguard Worker; 1: lw ${{[0-9]}}, %lo(dcx)(${{[0-9]+}}) 66*9880d681SAndroid Build Coastguard Worker; 1: jal __mips16_ret_dc 67*9880d681SAndroid Build Coastguard Worker; 2: .ent foodcx 68*9880d681SAndroid Build Coastguard Worker; 2: lw ${{[0-9]}}, 4(${{[0-9]+}}) 69*9880d681SAndroid Build Coastguard Worker; 2: jal __mips16_ret_dc 70*9880d681SAndroid Build Coastguard Worker; 3: .ent foodcx 71*9880d681SAndroid Build Coastguard Worker; 3: lw $4, 8(${{[0-9]+}}) 72*9880d681SAndroid Build Coastguard Worker; 3: jal __mips16_ret_dc 73*9880d681SAndroid Build Coastguard Worker; 4: .ent foodcx 74*9880d681SAndroid Build Coastguard Worker; 4: lw $5, 12(${{[0-9]+}}) 75*9880d681SAndroid Build Coastguard Worker; 4: jal __mips16_ret_dc 76*9880d681SAndroid Build Coastguard Worker} 77