This is the first of three patches which creates stubs used for
authorReed Kotler <rkotler@mips.com>
Tue, 14 May 2013 02:00:24 +0000 (02:00 +0000)
committerReed Kotler <rkotler@mips.com>
Tue, 14 May 2013 02:00:24 +0000 (02:00 +0000)
commiteafa96485a6c3ce0de4f511ed080a64a7a44f2bb
tree4d5763f006f55954147e2e564a68ee67cb72e366
parentdd29df06fa72de9e370cdd9d8e32ac5437a578c7
This is the first of three patches which creates stubs used for
Mips16/32 floating point interoperability.

When Mips16 code calls external functions that would normally have some
of its parameters or return values passed in floating point registers,
it needs (Mips32) helper functions to do this because while in Mips16 mode
there is no ability to access the floating point registers.

In Pic mode, this is done with a set of predefined functions in libc.
This case is already handled in llvm for Mips16.

In static relocation mode, for efficiency reasons, the compiler generates
stubs that the linker will use if it turns out that the external function
is a Mips32 function. (If it's Mips16, then it does not need the helper
stubs).

These stubs are identically named and the linker knows about these tricks
and will not create multiple copies and will delete them if they are not
needed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181753 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/Mips/Mips16HardFloat.cpp
test/CodeGen/Mips/hf16call32.ll [new file with mode: 0644]