1*9880d681SAndroid Build Coastguard Worker; Check that [sl]dc1 are normally emitted. MIPS32r2 should have [sl]dxc1 too. 2*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -mcpu=mips32 -relocation-model=pic < %s | \ 3*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R1-LDC1 4*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -mcpu=mips32r2 -relocation-model=pic < %s | \ 5*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R2-LDXC1 6*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -mcpu=mips32r6 -relocation-model=pic < %s | \ 7*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R6-LDC1 8*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -mcpu=mips32r3 -mattr=+micromips \ 9*9880d681SAndroid Build Coastguard Worker; RUN: -relocation-model=pic < %s | FileCheck %s -check-prefixes=ALL,MM 10*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -mcpu=mips32r6 -mattr=+micromips \ 11*9880d681SAndroid Build Coastguard Worker; RUN: -relocation-model=pic < %s | FileCheck %s -check-prefixes=ALL,MM 12*9880d681SAndroid Build Coastguard Worker 13*9880d681SAndroid Build Coastguard Worker; Check that -mno-ldc1-sdc1 disables [sl]dc1 14*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=pic -mno-ldc1-sdc1 \ 15*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32 < %s | \ 16*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R1,32R1-LE,32R1-LE-PIC 17*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=pic -mno-ldc1-sdc1 \ 18*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32r2 < %s | \ 19*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R2,32R2-LE,32R2-LE-PIC 20*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=pic -mno-ldc1-sdc1 \ 21*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32r6 < %s | \ 22*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R6,32R6-LE,32R6-LE-PIC 23*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=pic -mno-ldc1-sdc1 -mcpu=mips32r3 \ 24*9880d681SAndroid Build Coastguard Worker; RUN: -mattr=+micromips < %s | \ 25*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,MM-MNO-PIC,MM-MNO-LE-PIC 26*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=pic -mno-ldc1-sdc1 -mcpu=mips32r6 \ 27*9880d681SAndroid Build Coastguard Worker; RUN: -mattr=+micromips < %s | \ 28*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,MM-MNO-PIC,MM-MNO-LE-PIC 29*9880d681SAndroid Build Coastguard Worker 30*9880d681SAndroid Build Coastguard Worker; Check again for big-endian 31*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips -relocation-model=pic -mno-ldc1-sdc1 \ 32*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32 < %s | \ 33*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R1,32R1-BE,32R1-BE-PIC 34*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips -relocation-model=pic -mno-ldc1-sdc1 \ 35*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32r2 < %s | \ 36*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R2,32R2-BE,32R2-BE-PIC 37*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips -relocation-model=pic -mno-ldc1-sdc1 \ 38*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32r6 < %s | \ 39*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R6,32R6-BE,32R6-BE-PIC 40*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips -relocation-model=pic -mno-ldc1-sdc1 -mcpu=mips32r3 \ 41*9880d681SAndroid Build Coastguard Worker; RUN: -mattr=+micromips < %s | \ 42*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,MM-MNO-PIC,MM-MNO-BE-PIC 43*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mips -relocation-model=pic -mno-ldc1-sdc1 -mcpu=mips32r6 \ 44*9880d681SAndroid Build Coastguard Worker; RUN: -mattr=+micromips < %s | \ 45*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,MM-MNO-PIC,MM-MNO-BE-PIC 46*9880d681SAndroid Build Coastguard Worker 47*9880d681SAndroid Build Coastguard Worker; Check again for the static relocation model 48*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=static -mno-ldc1-sdc1 \ 49*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32 < %s | \ 50*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R1,32R1-LE,32R1-LE-STATIC 51*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=static -mno-ldc1-sdc1 \ 52*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32r2 < %s | \ 53*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R2,32R2-LE,32R2-LE-STATIC 54*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=static -mno-ldc1-sdc1 \ 55*9880d681SAndroid Build Coastguard Worker; RUN: -mcpu=mips32r6 < %s | \ 56*9880d681SAndroid Build Coastguard Worker; RUN: FileCheck %s -check-prefixes=ALL,32R6,32R6-LE,32R6-LE-STATIC 57*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=static -mcpu=mips32r3 \ 58*9880d681SAndroid Build Coastguard Worker; RUN: -mattr=+micromips < %s | FileCheck %s -check-prefixes=ALL,MM-STATIC_PIC 59*9880d681SAndroid Build Coastguard Worker; RUN: llc -march=mipsel -relocation-model=static -mcpu=mips32r6 \ 60*9880d681SAndroid Build Coastguard Worker; RUN: -mattr=+micromips < %s | FileCheck %s -check-prefixes=ALL,MM-STATIC-PIC 61*9880d681SAndroid Build Coastguard Worker 62*9880d681SAndroid Build Coastguard Worker@g0 = common global double 0.000000e+00, align 8 63*9880d681SAndroid Build Coastguard Worker 64*9880d681SAndroid Build Coastguard Worker; ALL-LABEL: test_ldc1: 65*9880d681SAndroid Build Coastguard Worker 66*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 67*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 68*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: mtc1 $[[R0]], $f0 69*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: mtc1 $[[R1]], $f1 70*9880d681SAndroid Build Coastguard Worker 71*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 72*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 73*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: mtc1 $[[R0]], $f0 74*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: mthc1 $[[R1]], $f0 75*9880d681SAndroid Build Coastguard Worker 76*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 77*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 78*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: mtc1 $[[R0]], $f0 79*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: mthc1 $[[R1]], $f0 80*9880d681SAndroid Build Coastguard Worker 81*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: lui $[[R0:[0-9]+]], %hi(g0) 82*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: lw $[[R1:[0-9]+]], %lo(g0)($[[R0]]) 83*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: addiu $[[R2:[0-9]+]], $[[R0]], %lo(g0) 84*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: lw $[[R3:[0-9]+]], 4($[[R2]]) 85*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: mtc1 $[[R1]], $f0 86*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: mtc1 $[[R3]], $f1 87*9880d681SAndroid Build Coastguard Worker 88*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: lui $[[R0:[0-9]+]], %hi(g0) 89*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: lw $[[R1:[0-9]+]], %lo(g0)($[[R0]]) 90*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: addiu $[[R2:[0-9]+]], $[[R0]], %lo(g0) 91*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: lw $[[R3:[0-9]+]], 4($[[R2]]) 92*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: mtc1 $[[R1]], $f0 93*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: mthc1 $[[R3]], $f0 94*9880d681SAndroid Build Coastguard Worker 95*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: lui $[[R0:[0-9]+]], %hi(g0) 96*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: lw $[[R1:[0-9]+]], %lo(g0)($[[R0]]) 97*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: addiu $[[R2:[0-9]+]], $[[R0]], %lo(g0) 98*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: lw $[[R3:[0-9]+]], 4($[[R2]]) 99*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: mtc1 $[[R1]], $f0 100*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: mthc1 $[[R3]], $f0 101*9880d681SAndroid Build Coastguard Worker 102*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 103*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 104*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: mtc1 $[[R1]], $f0 105*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: mtc1 $[[R0]], $f1 106*9880d681SAndroid Build Coastguard Worker 107*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 108*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 109*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: mtc1 $[[R1]], $f0 110*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: mthc1 $[[R0]], $f0 111*9880d681SAndroid Build Coastguard Worker 112*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 113*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 114*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: mtc1 $[[R1]], $f0 115*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: mthc1 $[[R0]], $f0 116*9880d681SAndroid Build Coastguard Worker 117*9880d681SAndroid Build Coastguard Worker; 32R1-LDC1: ldc1 $f0, 0(${{[0-9]+}}) 118*9880d681SAndroid Build Coastguard Worker 119*9880d681SAndroid Build Coastguard Worker; 32R2-LDXC1: ldc1 $f0, 0(${{[0-9]+}}) 120*9880d681SAndroid Build Coastguard Worker 121*9880d681SAndroid Build Coastguard Worker; 32R6-LDC1: ldc1 $f0, 0(${{[0-9]+}}) 122*9880d681SAndroid Build Coastguard Worker 123*9880d681SAndroid Build Coastguard Worker; MM: lui $[[R0:[0-9]+]], %hi(_gp_disp) 124*9880d681SAndroid Build Coastguard Worker; MM: addiu $[[R1:[0-9]+]], $[[R0]], %lo(_gp_disp) 125*9880d681SAndroid Build Coastguard Worker; MM: addu $[[R2:[0-9]+]], $[[R1]], $25 126*9880d681SAndroid Build Coastguard Worker; MM: lw $[[R3:[0-9]+]], %got(g0)($[[R2]]) 127*9880d681SAndroid Build Coastguard Worker; MM: ldc1 $f0, 0($[[R3]]) 128*9880d681SAndroid Build Coastguard Worker 129*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lui $[[R0:[0-9]+]], %hi(_gp_disp) 130*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: addiu $[[R1:[0-9]+]], $[[R0]], %lo(_gp_disp) 131*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: addu $[[R2:[0-9]+]], $[[R1]], $25 132*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lw $[[R3:[0-9]+]], %got(g0)($[[R2]]) 133*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lw16 $[[R4:[0-9]+]], 0($[[R3]]) 134*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lw16 $[[R5:[0-9]+]], 4($[[R3]]) 135*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mtc1 $[[R4]], $f0 136*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mthc1 $[[R5]], $f0 137*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mtc1 $[[R5]], $f0 138*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mthc1 $[[R4]], $f0 139*9880d681SAndroid Build Coastguard Worker 140*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: lui $[[R0:[0-9]+]], %hi(g0) 141*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: ldc1 $f0, %lo(g0)($[[R0]]) 142*9880d681SAndroid Build Coastguard Worker 143*9880d681SAndroid Build Coastguard Workerdefine double @test_ldc1() { 144*9880d681SAndroid Build Coastguard Workerentry: 145*9880d681SAndroid Build Coastguard Worker %0 = load double, double* @g0, align 8 146*9880d681SAndroid Build Coastguard Worker ret double %0 147*9880d681SAndroid Build Coastguard Worker} 148*9880d681SAndroid Build Coastguard Worker 149*9880d681SAndroid Build Coastguard Worker; ALL-LABEL: test_sdc1: 150*9880d681SAndroid Build Coastguard Worker 151*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 152*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: mfc1 $[[R1:[0-9]+]], $f13 153*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: sw $[[R0]], 0(${{[0-9]+}}) 154*9880d681SAndroid Build Coastguard Worker; 32R1-LE-PIC-DAG: sw $[[R1]], 4(${{[0-9]+}}) 155*9880d681SAndroid Build Coastguard Worker 156*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 157*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: mfhc1 $[[R1:[0-9]+]], $f12 158*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: sw $[[R0]], 0(${{[0-9]+}}) 159*9880d681SAndroid Build Coastguard Worker; 32R2-LE-PIC-DAG: sw $[[R1]], 4(${{[0-9]+}}) 160*9880d681SAndroid Build Coastguard Worker 161*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 162*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: mfhc1 $[[R1:[0-9]+]], $f12 163*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: sw $[[R0]], 0(${{[0-9]+}}) 164*9880d681SAndroid Build Coastguard Worker; 32R6-LE-PIC-DAG: sw $[[R1]], 4(${{[0-9]+}}) 165*9880d681SAndroid Build Coastguard Worker 166*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 167*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: mfc1 $[[R1:[0-9]+]], $f13 168*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: lui $[[R2:[0-9]+]], %hi(g0) 169*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: sw $[[R0]], %lo(g0)($[[R2]]) 170*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: addiu $[[R3:[0-9]+]], $[[R2]], %lo(g0) 171*9880d681SAndroid Build Coastguard Worker; 32R1-LE-STATIC-DAG: sw $[[R1]], 4($[[R3]]) 172*9880d681SAndroid Build Coastguard Worker 173*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 174*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: mfhc1 $[[R1:[0-9]+]], $f12 175*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: lui $[[R2:[0-9]+]], %hi(g0) 176*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: sw $[[R0]], %lo(g0)($[[R2]]) 177*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: addiu $[[R3:[0-9]+]], $[[R2]], %lo(g0) 178*9880d681SAndroid Build Coastguard Worker; 32R2-LE-STATIC-DAG: sw $[[R1]], 4($[[R3]]) 179*9880d681SAndroid Build Coastguard Worker 180*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 181*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: mfhc1 $[[R1:[0-9]+]], $f12 182*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: lui $[[R2:[0-9]+]], %hi(g0) 183*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: sw $[[R0]], %lo(g0)($[[R2]]) 184*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: addiu $[[R3:[0-9]+]], $[[R2]], %lo(g0) 185*9880d681SAndroid Build Coastguard Worker; 32R6-LE-STATIC-DAG: sw $[[R1]], 4($[[R3]]) 186*9880d681SAndroid Build Coastguard Worker 187*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 188*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: mfc1 $[[R1:[0-9]+]], $f13 189*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: sw $[[R1]], 0(${{[0-9]+}}) 190*9880d681SAndroid Build Coastguard Worker; 32R1-BE-PIC-DAG: sw $[[R0]], 4(${{[0-9]+}}) 191*9880d681SAndroid Build Coastguard Worker 192*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 193*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: mfhc1 $[[R1:[0-9]+]], $f12 194*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: sw $[[R1]], 0(${{[0-9]+}}) 195*9880d681SAndroid Build Coastguard Worker; 32R2-BE-PIC-DAG: sw $[[R0]], 4(${{[0-9]+}}) 196*9880d681SAndroid Build Coastguard Worker 197*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: mfc1 $[[R0:[0-9]+]], $f12 198*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: mfhc1 $[[R1:[0-9]+]], $f12 199*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: sw $[[R1]], 0(${{[0-9]+}}) 200*9880d681SAndroid Build Coastguard Worker; 32R6-BE-PIC-DAG: sw $[[R0]], 4(${{[0-9]+}}) 201*9880d681SAndroid Build Coastguard Worker 202*9880d681SAndroid Build Coastguard Worker; 32R1-LDC1: sdc1 $f{{[0-9]+}}, 0(${{[0-9]+}}) 203*9880d681SAndroid Build Coastguard Worker 204*9880d681SAndroid Build Coastguard Worker; 32R2-LDXC1: sdc1 $f{{[0-9]+}}, 0(${{[0-9]+}}) 205*9880d681SAndroid Build Coastguard Worker 206*9880d681SAndroid Build Coastguard Worker; 32R6-LDC1: sdc1 $f{{[0-9]+}}, 0(${{[0-9]+}}) 207*9880d681SAndroid Build Coastguard Worker 208*9880d681SAndroid Build Coastguard Worker; MM: lui $[[R0:[0-9]+]], %hi(_gp_disp) 209*9880d681SAndroid Build Coastguard Worker; MM: addiu $[[R1:[0-9]+]], $[[R0]], %lo(_gp_disp) 210*9880d681SAndroid Build Coastguard Worker; MM: addu $[[R2:[0-9]+]], $[[R1]], $25 211*9880d681SAndroid Build Coastguard Worker; MM: lw $[[R3:[0-9]+]], %got(g0)($[[R2]]) 212*9880d681SAndroid Build Coastguard Worker; MM: sdc1 $f12, 0($[[R3]]) 213*9880d681SAndroid Build Coastguard Worker 214*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lui $[[R0:[0-9]+]], %hi(_gp_disp) 215*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: addiu $[[R1:[0-9]+]], $[[R0]], %lo(_gp_disp) 216*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: addu $[[R2:[0-9]+]], $[[R1]], $25 217*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mfc1 $[[R3:[0-9]+]], $f12 218*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mfhc1 $[[R3:[0-9]+]], $f12 219*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lw $[[R4:[0-9]+]], %got(g0)($[[R2]]) 220*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: sw16 $[[R3]], 0($[[R4]]) 221*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mfhc1 $[[R5:[0-9]+]], $f12 222*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mfc1 $[[R5:[0-9]+]], $f12 223*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: sw16 $[[R5]], 4($[[R4]]) 224*9880d681SAndroid Build Coastguard Worker 225*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: lui $[[R0:[0-9]+]], %hi(g0) 226*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: sdc1 $f12, %lo(g0)($[[R0]]) 227*9880d681SAndroid Build Coastguard Worker 228*9880d681SAndroid Build Coastguard Workerdefine void @test_sdc1(double %a) { 229*9880d681SAndroid Build Coastguard Workerentry: 230*9880d681SAndroid Build Coastguard Worker store double %a, double* @g0, align 8 231*9880d681SAndroid Build Coastguard Worker ret void 232*9880d681SAndroid Build Coastguard Worker} 233*9880d681SAndroid Build Coastguard Worker 234*9880d681SAndroid Build Coastguard Worker; ALL-LABEL: test_ldxc1: 235*9880d681SAndroid Build Coastguard Worker 236*9880d681SAndroid Build Coastguard Worker; 32R1-LE-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 237*9880d681SAndroid Build Coastguard Worker; 32R1-LE-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 238*9880d681SAndroid Build Coastguard Worker; 32R1-BE-DAG: lw $[[R0:[0-9]+]], 4(${{[0-9]+}}) 239*9880d681SAndroid Build Coastguard Worker; 32R1-BE-DAG: lw $[[R1:[0-9]+]], 0(${{[0-9]+}}) 240*9880d681SAndroid Build Coastguard Worker; 32R1-DAG: mtc1 $[[R0]], $f0 241*9880d681SAndroid Build Coastguard Worker; 32R1-DAG: mtc1 $[[R1]], $f1 242*9880d681SAndroid Build Coastguard Worker 243*9880d681SAndroid Build Coastguard Worker; 32R2-LE-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 244*9880d681SAndroid Build Coastguard Worker; 32R2-LE-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 245*9880d681SAndroid Build Coastguard Worker; 32R2-BE-DAG: lw $[[R0:[0-9]+]], 4(${{[0-9]+}}) 246*9880d681SAndroid Build Coastguard Worker; 32R2-BE-DAG: lw $[[R1:[0-9]+]], 0(${{[0-9]+}}) 247*9880d681SAndroid Build Coastguard Worker; 32R2-DAG: mtc1 $[[R0]], $f0 248*9880d681SAndroid Build Coastguard Worker; 32R2-DAG: mthc1 $[[R1]], $f0 249*9880d681SAndroid Build Coastguard Worker 250*9880d681SAndroid Build Coastguard Worker; 32R6-LE-DAG: lw $[[R0:[0-9]+]], 0(${{[0-9]+}}) 251*9880d681SAndroid Build Coastguard Worker; 32R6-LE-DAG: lw $[[R1:[0-9]+]], 4(${{[0-9]+}}) 252*9880d681SAndroid Build Coastguard Worker; 32R6-BE-DAG: lw $[[R0:[0-9]+]], 4(${{[0-9]+}}) 253*9880d681SAndroid Build Coastguard Worker; 32R6-BE-DAG: lw $[[R1:[0-9]+]], 0(${{[0-9]+}}) 254*9880d681SAndroid Build Coastguard Worker; 32R6-DAG: mtc1 $[[R0]], $f0 255*9880d681SAndroid Build Coastguard Worker; 32R6-DAG: mthc1 $[[R1]], $f0 256*9880d681SAndroid Build Coastguard Worker 257*9880d681SAndroid Build Coastguard Worker; 32R1-LDC1: ldc1 $f0, 0(${{[0-9]+}}) 258*9880d681SAndroid Build Coastguard Worker 259*9880d681SAndroid Build Coastguard Worker; 32R2-LDXC1: sll $[[OFFSET:[0-9]+]], $5, 3 260*9880d681SAndroid Build Coastguard Worker; 32R2-LDXC1: ldxc1 $f0, $[[OFFSET]]($4) 261*9880d681SAndroid Build Coastguard Worker 262*9880d681SAndroid Build Coastguard Worker; 32R6-LDC1: ldc1 $f0, 0(${{[0-9]+}}) 263*9880d681SAndroid Build Coastguard Worker 264*9880d681SAndroid Build Coastguard Worker; MM: sll16 $[[R0:[0-9]+]], $5, 3 265*9880d681SAndroid Build Coastguard Worker; MM: addu16 $[[R1:[0-9]+]], $4, $[[R0]] 266*9880d681SAndroid Build Coastguard Worker; MM: ldc1 $f0, 0($[[R1]]) 267*9880d681SAndroid Build Coastguard Worker 268*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: sll16 $[[R0:[0-9]+]], $5, 3 269*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: addu16 $[[R1:[0-9]+]], $4, $[[R0]] 270*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lw16 $[[R2:[0-9]+]], 0($[[R1]]) 271*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: lw16 $[[R3:[0-9]+]], 4($[[R1]]) 272*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mtc1 $[[R2]], $f0 273*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mthc1 $[[R3]], $f0 274*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mtc1 $[[R3]], $f0 275*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mthc1 $[[R2]], $f0 276*9880d681SAndroid Build Coastguard Worker 277*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: sll16 $[[R0:[0-9]+]], $5, 3 278*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: addu16 $[[R1:[0-9]+]], $4, $[[R0]] 279*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: ldc1 $f0, 0($[[R1]]) 280*9880d681SAndroid Build Coastguard Worker 281*9880d681SAndroid Build Coastguard Workerdefine double @test_ldxc1(double* nocapture readonly %a, i32 %i) { 282*9880d681SAndroid Build Coastguard Workerentry: 283*9880d681SAndroid Build Coastguard Worker %arrayidx = getelementptr inbounds double, double* %a, i32 %i 284*9880d681SAndroid Build Coastguard Worker %0 = load double, double* %arrayidx, align 8 285*9880d681SAndroid Build Coastguard Worker ret double %0 286*9880d681SAndroid Build Coastguard Worker} 287*9880d681SAndroid Build Coastguard Worker 288*9880d681SAndroid Build Coastguard Worker; ALL-LABEL: test_sdxc1: 289*9880d681SAndroid Build Coastguard Worker 290*9880d681SAndroid Build Coastguard Worker; 32R1-DAG: mfc1 $[[R0:[0-9]+]], $f12 291*9880d681SAndroid Build Coastguard Worker; 32R1-DAG: mfc1 $[[R1:[0-9]+]], $f13 292*9880d681SAndroid Build Coastguard Worker; 32R1-DAG: sw $[[R0]], 0(${{[0-9]+}}) 293*9880d681SAndroid Build Coastguard Worker; 32R1-DAG: sw $[[R1]], 4(${{[0-9]+}}) 294*9880d681SAndroid Build Coastguard Worker 295*9880d681SAndroid Build Coastguard Worker; 32R2-DAG: mfc1 $[[R0:[0-9]+]], $f12 296*9880d681SAndroid Build Coastguard Worker; 32R2-DAG: mfhc1 $[[R1:[0-9]+]], $f12 297*9880d681SAndroid Build Coastguard Worker; 32R2-DAG: sw $[[R0]], 0(${{[0-9]+}}) 298*9880d681SAndroid Build Coastguard Worker; 32R2-DAG: sw $[[R1]], 4(${{[0-9]+}}) 299*9880d681SAndroid Build Coastguard Worker 300*9880d681SAndroid Build Coastguard Worker; 32R6-DAG: mfc1 $[[R0:[0-9]+]], $f12 301*9880d681SAndroid Build Coastguard Worker; 32R6-DAG: mfhc1 $[[R1:[0-9]+]], $f12 302*9880d681SAndroid Build Coastguard Worker; 32R6-DAG: sw $[[R0]], 0(${{[0-9]+}}) 303*9880d681SAndroid Build Coastguard Worker; 32R6-DAG: sw $[[R1]], 4(${{[0-9]+}}) 304*9880d681SAndroid Build Coastguard Worker 305*9880d681SAndroid Build Coastguard Worker; 32R1-LDC1: sdc1 $f{{[0-9]+}}, 0(${{[0-9]+}}) 306*9880d681SAndroid Build Coastguard Worker 307*9880d681SAndroid Build Coastguard Worker; 32R2-LDXC1: sll $[[OFFSET:[0-9]+]], $7, 3 308*9880d681SAndroid Build Coastguard Worker; 32R2-LDXC1: sdxc1 $f{{[0-9]+}}, $[[OFFSET]]($6) 309*9880d681SAndroid Build Coastguard Worker 310*9880d681SAndroid Build Coastguard Worker; 32R6-LDC1: sdc1 $f{{[0-9]+}}, 0(${{[0-9]+}}) 311*9880d681SAndroid Build Coastguard Worker 312*9880d681SAndroid Build Coastguard Worker; MM: sll16 $[[R0:[0-9]+]], $7, 3 313*9880d681SAndroid Build Coastguard Worker; MM: addu16 $[[R1:[0-9]+]], $6, $[[R0]] 314*9880d681SAndroid Build Coastguard Worker; MM: sdc1 $f12, 0($[[R1]]) 315*9880d681SAndroid Build Coastguard Worker 316*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: sll16 $[[R0:[0-9]+]], $7, 3 317*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: addu16 $[[R1:[0-9]+]], $6, $[[R0]] 318*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mfc1 $[[R2:[0-9]+]], $f12 319*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mfhc1 $[[R2:[0-9]+]], $f12 320*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: sw16 $[[R2]], 0($[[R1]]) 321*9880d681SAndroid Build Coastguard Worker; MM-MNO-LE-PIC: mfhc1 $[[R3:[0-9]+]], $f12 322*9880d681SAndroid Build Coastguard Worker; MM-MNO-BE-PIC: mfc1 $[[R3:[0-9]+]], $f12 323*9880d681SAndroid Build Coastguard Worker; MM-MNO-PIC: sw16 $[[R3]], 4($[[R1]]) 324*9880d681SAndroid Build Coastguard Worker 325*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: sll16 $[[R0:[0-9]+]], $7, 3 326*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: addu16 $[[R1:[0-9]+]], $6, $[[R0]] 327*9880d681SAndroid Build Coastguard Worker; MM-STATIC-PIC: sdc1 $f12, 0($[[R1]]) 328*9880d681SAndroid Build Coastguard Worker 329*9880d681SAndroid Build Coastguard Workerdefine void @test_sdxc1(double %b, double* nocapture %a, i32 %i) { 330*9880d681SAndroid Build Coastguard Workerentry: 331*9880d681SAndroid Build Coastguard Worker %arrayidx = getelementptr inbounds double, double* %a, i32 %i 332*9880d681SAndroid Build Coastguard Worker store double %b, double* %arrayidx, align 8 333*9880d681SAndroid Build Coastguard Worker ret void 334*9880d681SAndroid Build Coastguard Worker} 335