[LLVMdev] Patch - Big stacks on SPU, take 2

Jakob Stoklund Olesen stoklund at 2pi.dk
Mon Mar 29 10:39:50 PDT 2010


On Mar 29, 2010, at 6:50 AM, Kalle Raiskila wrote:

> attached is a second try for the bigstack patch for SPU, with testcase. It is essentially the patch committed as 97091, and reverted as 97099, but with the following additions:
> -in vararg handling, registers are marked to be live, to not confuse the register scavenger

Looks good. You can try running with -verify-machineinstrs to detect more issues like that.

> -function prologue and epilogue are not emitted, if the stack size is 16. 16 means it is empty - there is only the register scavenger emergency spill slot, which is not used as there is no stack.

Would it be possible to detect this before allocating the emergency spill slot, and not request a scavenger at all?

> This time there are no new unexpected failures in the regression tests.

I noticed that CellSPU has a bunch of isS10Constant() functions. These already exist in MathExtras.h: isInt<10>(). Also, there is no need for 5 overloads of those functions, AFAICT.

Please use the MathExtras.h functions, and remove all of the is*Constant functions in SPU.h.

/jakob





More information about the llvm-dev mailing list