1 1.1 joerg //===-- restFP.S - Implement restFP ---------------------------------------===// 2 1.1 joerg // 3 1.1 joerg // The LLVM Compiler Infrastructure 4 1.1 joerg // 5 1.1 joerg // This file is dual licensed under the MIT and the University of Illinois Open 6 1.1 joerg // Source Licenses. See LICENSE.TXT for details. 7 1.1 joerg // 8 1.1 joerg //===----------------------------------------------------------------------===// 9 1.1 joerg 10 1.1 joerg #include "../assembly.h" 11 1.1 joerg 12 1.1 joerg // 13 1.1 joerg // Helper function used by compiler to restore ppc floating point registers at 14 1.1 joerg // the end of the function epilog. This function returns to the address 15 1.1 joerg // in the LR slot. So a function epilog must branch (b) not branch and link 16 1.1 joerg // (bl) to this function. 17 1.1 joerg // If the compiler wants to restore f27..f31, it does a "b restFP+52" 18 1.1 joerg // 19 1.1 joerg // This function should never be exported by a shared library. Each linkage 20 1.1 joerg // unit carries its own copy of this function. 21 1.1 joerg // 22 1.1 joerg DEFINE_COMPILERRT_PRIVATE_FUNCTION_UNMANGLED(restFP) 23 1.1 joerg lfd f14,-144(r1) 24 1.1 joerg lfd f15,-136(r1) 25 1.1 joerg lfd f16,-128(r1) 26 1.1 joerg lfd f17,-120(r1) 27 1.1 joerg lfd f18,-112(r1) 28 1.1 joerg lfd f19,-104(r1) 29 1.1 joerg lfd f20,-96(r1) 30 1.1 joerg lfd f21,-88(r1) 31 1.1 joerg lfd f22,-80(r1) 32 1.1 joerg lfd f23,-72(r1) 33 1.1 joerg lfd f24,-64(r1) 34 1.1 joerg lfd f25,-56(r1) 35 1.1 joerg lfd f26,-48(r1) 36 1.1 joerg lfd f27,-40(r1) 37 1.1 joerg lfd f28,-32(r1) 38 1.1 joerg lfd f29,-24(r1) 39 1.1 joerg lfd f30,-16(r1) 40 1.1 joerg lfd f31,-8(r1) 41 1.1 joerg lwz r0,8(r1) 42 1.1 joerg mtlr r0 43 1.1 joerg blr 44