1*0b57cec5SDimitry Andric//===-- restFP.S - Implement restFP ---------------------------------------===// 2*0b57cec5SDimitry Andric// 3*0b57cec5SDimitry Andric// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4*0b57cec5SDimitry Andric// See https://llvm.org/LICENSE.txt for license information. 5*0b57cec5SDimitry Andric// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6*0b57cec5SDimitry Andric// 7*0b57cec5SDimitry Andric//===----------------------------------------------------------------------===// 8*0b57cec5SDimitry Andric 9*0b57cec5SDimitry Andric#include "../assembly.h" 10*0b57cec5SDimitry Andric 11*0b57cec5SDimitry Andric// 12*0b57cec5SDimitry Andric// Helper function used by compiler to restore ppc floating point registers at 13*0b57cec5SDimitry Andric// the end of the function epilog. This function returns to the address 14*0b57cec5SDimitry Andric// in the LR slot. So a function epilog must branch (b) not branch and link 15*0b57cec5SDimitry Andric// (bl) to this function. 16*0b57cec5SDimitry Andric// If the compiler wants to restore f27..f31, it does a "b restFP+52" 17*0b57cec5SDimitry Andric// 18*0b57cec5SDimitry Andric// This function should never be exported by a shared library. Each linkage 19*0b57cec5SDimitry Andric// unit carries its own copy of this function. 20*0b57cec5SDimitry Andric// 21*0b57cec5SDimitry AndricDEFINE_COMPILERRT_PRIVATE_FUNCTION_UNMANGLED(restFP) 22*0b57cec5SDimitry Andric lfd f14,-144(r1) 23*0b57cec5SDimitry Andric lfd f15,-136(r1) 24*0b57cec5SDimitry Andric lfd f16,-128(r1) 25*0b57cec5SDimitry Andric lfd f17,-120(r1) 26*0b57cec5SDimitry Andric lfd f18,-112(r1) 27*0b57cec5SDimitry Andric lfd f19,-104(r1) 28*0b57cec5SDimitry Andric lfd f20,-96(r1) 29*0b57cec5SDimitry Andric lfd f21,-88(r1) 30*0b57cec5SDimitry Andric lfd f22,-80(r1) 31*0b57cec5SDimitry Andric lfd f23,-72(r1) 32*0b57cec5SDimitry Andric lfd f24,-64(r1) 33*0b57cec5SDimitry Andric lfd f25,-56(r1) 34*0b57cec5SDimitry Andric lfd f26,-48(r1) 35*0b57cec5SDimitry Andric lfd f27,-40(r1) 36*0b57cec5SDimitry Andric lfd f28,-32(r1) 37*0b57cec5SDimitry Andric lfd f29,-24(r1) 38*0b57cec5SDimitry Andric lfd f30,-16(r1) 39*0b57cec5SDimitry Andric lfd f31,-8(r1) 40*0b57cec5SDimitry Andric lwz r0,8(r1) 41*0b57cec5SDimitry Andric mtlr r0 42*0b57cec5SDimitry Andric blr 43*0b57cec5SDimitry Andric 44*0b57cec5SDimitry AndricNO_EXEC_STACK_DIRECTIVE 45*0b57cec5SDimitry Andric 46