Honza, > Honza said: > I am bit confused here. If I wanted a free register in prologue only, I > would probably look at the caller saved ones. But I gues it is just > typo.
> I don't see much value in making the register callee-saved especially if > you say that virtual reg (pseudo?) is used afterward. I'm sorry for the confusing word. But I did mean callee-save register, in case none caller-save register is available. For i386, eax, edx and ecx can all be used to pass register parameters. So there must be a callee-save register in stock. Due to faked bug we said only callee-save register can be used. It has been clarified now. > When you just need a temporary in prologue, I think you can go with RAX > in most cases getting shortest code. It is used by x86-64 stdargs > prologue and by i386 regparm. You can improve bit broken > ix86_eax_live_at_start_p to test this. Using alternative choice if RAX > is taken. In case callee-save registers are available, ECX is a good candidate for i386 because it is the latest register to use for parameter passing. RAX is a good candiate for x86_64. Thanks - Joey