[LLVMdev] Finding live registers at a specific point in a MachineFunction and spilling them

Manuel Jacob me at manueljacob.de
Tue Sep 3 17:21:14 PDT 2013


Hi,

I'm trying to implement my ideas about better garbage collection
support [1]. The hardest problem seems to be to find all registers that
are live at safe points (for example, during a call) and spilling them.
Since nobody responded on the original thread, I decided to start a new
thread specifically for this question.

The problem is to safe registers that contain gc pointers to the stack
before a call and reload them after the call. Is there an Analysis Pass
that computes information about which registers are live during a
specific instruction? I looked at LiveIntervals and LiveVariables, but
they seem to be for cases when the pass knows the register and wants to
find the points where it is live. My code knows the point and wants to
find the registers that are live.

Another part of the problem is to spill the registers to the stack. Do
you think this is possible with the existing register spilling code?

-Manuel

[1] http://lists.cs.uiuc.edu/pipermail/llvmdev/2013-July/064408.html



More information about the llvm-dev mailing list