On 7 April 2014 12:11, Claudio Fontana <claudio.font...@huawei.com> wrote: [your mail client is generating very long lines] > My doubt was about the AAPCS64 (Procedure Call standard for the > ARM 64-bit Architecture), and what the platforms in our case dictate > regarding FP and LR use. > > I think that LR should be ok to use, because basically the whole > generated code from the prologue to the end can be seen as a single > big subroutine, and there does not seem to be a clear mandate to > keep LR's special significance inside subroutines at all times.
Agreed. > The role of the registers is described in 5.1.1, where it is > mentioned that "in all variants of the pcs, registers r16,r17,r29 > and r30 have special roles" [...] > > The standard says at 5.2.3 that "conforming code" shall construct > a linked list of stack frames, [...] A platform shall mandate the > minimum level of conformance[...]. Since our TCG generated code is not platform specific we should take the most conservative approach, and make sure we set up a frame record in the prologue and don't touch FP after that. thanks -- PMM