This is subsequent patch of https://reviews.llvm.org/D70116.
This is one of patches for enabling LTO support in RISCV, in some time LTO code generator will handle below case with `-mabi=ilp32f`, it's similar to `llc example.c -mtriple=riscv32 -mabi=ilp32f`.
```
define float @foo(i32 %a) nounwind #0 {
...
}
attributes #0 = { "target-features"="+f"}
```
1. at this moment we assume one compilation unit only have same abi.
2. The target-features is per function attribute, and the original checking is at
too early stage so backned can't get the function attribute at that times.
so I think maybe moving the checking to RISCVTargetLowering is a good ideal.
3. if users don't specific `-mattr`, the default target-feature come from IR attribute.
4. fix https://reviews.llvm.org/D70116 failed case