Issue 180873
Summary MIPS: optimize some floating load to mfc1
Labels new issue
Assignees
Reporter wzssyqa
    ```
double f(double a) {
        return a * 4.0;
}
```
        lui     $2, %hi(_gp_disp)
        addiu   $2, $2, %lo(_gp_disp)
        addu    $1, $2, $25
        lw      $1, %got($CPI0_0)($1)
        ldc1    $f0, %lo($CPI0_0)($1)
        jr $ra
        mul.d   $f0, $f12, $f0
```

In fact we can use
```
lui 0x4010
mfhc1
```

_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to