1 //===---- Mips16HardFloatInfo.cpp for Mips16 Hard Float -----===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // This file contains the Mips16 implementation of Mips16HardFloatInfo
13 //===----------------------------------------------------------------------===//
15 #include "Mips16HardFloatInfo.h"
20 namespace Mips16HardFloatInfo
{
22 const FuncNameSignature PredefinedFuncs
[] = {
23 { "__floatdidf", { NoSig
, DRet
} },
24 { "__floatdisf", { NoSig
, FRet
} },
25 { "__floatundidf", { NoSig
, DRet
} },
26 { "__fixsfdi", { FSig
, NoFPRet
} },
27 { "__fixunsdfsi", { DSig
, NoFPRet
} },
28 { "__fixunsdfdi", { DSig
, NoFPRet
} },
29 { "__fixdfdi", { DSig
, NoFPRet
} },
30 { "__fixunssfsi", { FSig
, NoFPRet
} },
31 { "__fixunssfdi", { FSig
, NoFPRet
} },
32 { "__floatundisf", { NoSig
, FRet
} },
33 { nullptr, { NoSig
, NoFPRet
} }
36 // just do a search for now. there are very few of these special cases.
38 extern FuncSignature
const *findFuncSignature(const char *name
) {
41 while (PredefinedFuncs
[i
].Name
) {
42 name_
= PredefinedFuncs
[i
].Name
;
43 if (strcmp(name
, name_
) == 0)
44 return &PredefinedFuncs
[i
].Signature
;