llvm.org GIT mirror llvm / bc49cf7
Make some code a little simpler. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173649 91177308-0d34-0410-b5e6-96231b3b80d8 Reed Kotler 7 years ago
2 changed file(s) with 40 addition(s) and 40 deletion(s). Raw diff Collapse all Expand all
221221
222222 }
223223
224 void MipsTargetLowering::SetMips16LibcallName
225 (RTLIB::Libcall l, const char *Name) {
226 setLibcallName(l, Name);
227 noHelperNeeded.insert(Name);
228 }
229
224230 void MipsTargetLowering::setMips16HardFloatLibCalls() {
225 setLibcallName(RTLIB::ADD_F32, addToNoHelperNeeded("__mips16_addsf3"));
226 setLibcallName(RTLIB::ADD_F64, addToNoHelperNeeded("__mips16_adddf3"));
227 setLibcallName(RTLIB::SUB_F32, addToNoHelperNeeded("__mips16_subsf3"));
228 setLibcallName(RTLIB::SUB_F64, addToNoHelperNeeded("__mips16_subdf3"));
229 setLibcallName(RTLIB::MUL_F32, addToNoHelperNeeded("__mips16_mulsf3"));
230 setLibcallName(RTLIB::MUL_F64, addToNoHelperNeeded("__mips16_muldf3"));
231 setLibcallName(RTLIB::DIV_F32, addToNoHelperNeeded("__mips16_divsf3"));
232 setLibcallName(RTLIB::DIV_F64, addToNoHelperNeeded("__mips16_divdf3"));
233 setLibcallName(RTLIB::FPEXT_F32_F64,
234 addToNoHelperNeeded("__mips16_extendsfdf2"));
235 setLibcallName(RTLIB::FPROUND_F64_F32,
236 addToNoHelperNeeded("__mips16_truncdfsf2"));
237 setLibcallName(RTLIB::FPTOSINT_F32_I32,
238 addToNoHelperNeeded("__mips16_fix_truncsfsi"));
239 setLibcallName(RTLIB::FPTOSINT_F64_I32,
240 addToNoHelperNeeded("__mips16_fix_truncdfsi"));
241 setLibcallName(RTLIB::SINTTOFP_I32_F32,
242 addToNoHelperNeeded("__mips16_floatsisf"));
243 setLibcallName(RTLIB::SINTTOFP_I32_F64,
244 addToNoHelperNeeded("__mips16_floatsidf"));
245 setLibcallName(RTLIB::UINTTOFP_I32_F32,
246 addToNoHelperNeeded("__mips16_floatunsisf"));
247 setLibcallName(RTLIB::UINTTOFP_I32_F64,
248 addToNoHelperNeeded("__mips16_floatunsidf"));
249 setLibcallName(RTLIB::OEQ_F32, addToNoHelperNeeded("__mips16_eqsf2"));
250 setLibcallName(RTLIB::OEQ_F64, addToNoHelperNeeded("__mips16_eqdf2"));
251 setLibcallName(RTLIB::UNE_F32, addToNoHelperNeeded("__mips16_nesf2"));
252 setLibcallName(RTLIB::UNE_F64, addToNoHelperNeeded("__mips16_nedf2"));
253 setLibcallName(RTLIB::OGE_F32, addToNoHelperNeeded("__mips16_gesf2"));
254 setLibcallName(RTLIB::OGE_F64, addToNoHelperNeeded("__mips16_gedf2"));
255 setLibcallName(RTLIB::OLT_F32, addToNoHelperNeeded("__mips16_ltsf2"));
256 setLibcallName(RTLIB::OLT_F64, addToNoHelperNeeded("__mips16_ltdf2"));
257 setLibcallName(RTLIB::OLE_F32, addToNoHelperNeeded("__mips16_lesf2"));
258 setLibcallName(RTLIB::OLE_F64, addToNoHelperNeeded("__mips16_ledf2"));
259 setLibcallName(RTLIB::OGT_F32, addToNoHelperNeeded("__mips16_gtsf2"));
260 setLibcallName(RTLIB::OGT_F64, addToNoHelperNeeded("__mips16_gtdf2"));
261 setLibcallName(RTLIB::UO_F32, addToNoHelperNeeded("__mips16_unordsf2"));
262 setLibcallName(RTLIB::UO_F64, addToNoHelperNeeded("__mips16_unorddf2"));
263 setLibcallName(RTLIB::O_F32, addToNoHelperNeeded("__mips16_unordsf2"));
264 setLibcallName(RTLIB::O_F64, addToNoHelperNeeded("__mips16_unorddf2"));
231 SetMips16LibcallName(RTLIB::ADD_F32, "__mips16_addsf3");
232 SetMips16LibcallName(RTLIB::ADD_F64, "__mips16_adddf3");
233 SetMips16LibcallName(RTLIB::SUB_F32, "__mips16_subsf3");
234 SetMips16LibcallName(RTLIB::SUB_F64, "__mips16_subdf3");
235 SetMips16LibcallName(RTLIB::MUL_F32, "__mips16_mulsf3");
236 SetMips16LibcallName(RTLIB::MUL_F64, "__mips16_muldf3");
237 SetMips16LibcallName(RTLIB::DIV_F32, "__mips16_divsf3");
238 SetMips16LibcallName(RTLIB::DIV_F64, "__mips16_divdf3");
239 SetMips16LibcallName(RTLIB::FPEXT_F32_F64, "__mips16_extendsfdf2");
240 SetMips16LibcallName(RTLIB::FPROUND_F64_F32, "__mips16_truncdfsf2");
241 SetMips16LibcallName(RTLIB::FPTOSINT_F32_I32, "__mips16_fix_truncsfsi");
242 SetMips16LibcallName(RTLIB::FPTOSINT_F64_I32, "__mips16_fix_truncdfsi");
243 SetMips16LibcallName(RTLIB::SINTTOFP_I32_F32, "__mips16_floatsisf");
244 SetMips16LibcallName(RTLIB::SINTTOFP_I32_F64, "__mips16_floatsidf");
245 SetMips16LibcallName(RTLIB::UINTTOFP_I32_F32, "__mips16_floatunsisf");
246 SetMips16LibcallName(RTLIB::UINTTOFP_I32_F64, "__mips16_floatunsidf");
247 SetMips16LibcallName(RTLIB::OEQ_F32, "__mips16_eqsf2");
248 SetMips16LibcallName(RTLIB::OEQ_F64, "__mips16_eqdf2");
249 SetMips16LibcallName(RTLIB::UNE_F32, "__mips16_nesf2");
250 SetMips16LibcallName(RTLIB::UNE_F64, "__mips16_nedf2");
251 SetMips16LibcallName(RTLIB::OGE_F32, "__mips16_gesf2");
252 SetMips16LibcallName(RTLIB::OGE_F64, "__mips16_gedf2");
253 SetMips16LibcallName(RTLIB::OLT_F32, "__mips16_ltsf2");
254 SetMips16LibcallName(RTLIB::OLT_F64, "__mips16_ltdf2");
255 SetMips16LibcallName(RTLIB::OLE_F32, "__mips16_lesf2");
256 SetMips16LibcallName(RTLIB::OLE_F64, "__mips16_ledf2");
257 SetMips16LibcallName(RTLIB::OGT_F32, "__mips16_gtsf2");
258 SetMips16LibcallName(RTLIB::OGT_F64, "__mips16_gtdf2");
259 SetMips16LibcallName(RTLIB::UO_F32, "__mips16_unordsf2");
260 SetMips16LibcallName(RTLIB::UO_F64, "__mips16_unorddf2");
261 SetMips16LibcallName(RTLIB::O_F32, "__mips16_unordsf2");
262 SetMips16LibcallName(RTLIB::O_F64, "__mips16_unorddf2");
265263 }
266264
267265 MipsTargetLowering::
174174
175175 virtual SDValue PerformDAGCombine(SDNode *N, DAGCombinerInfo &DCI) const;
176176 private:
177
178 void SetMips16LibcallName(RTLIB::Libcall, const char *Name);
177179
178180 void setMips16HardFloatLibCalls();
179181