[LLVMdev] RegAllocFast uses too much stack

Eric Christopher echristo at apple.com
Mon Jul 11 15:43:21 PDT 2011


On Jul 11, 2011, at 3:41 PM, Dan Gohman wrote:

> On Jul 11, 2011, at 3:06 PM, Eli Friedman wrote:
> 
>> On Mon, Jul 11, 2011 at 2:44 PM, Eric Christopher <echristo at apple.com> wrote:
>>> 
>>> On Jul 11, 2011, at 1:48 PM, Nick Lewycky wrote:
>>> 
>>> This seems odd. I'd think that fast-isel should be able to materialize the constants when we want them rather than at the beginning of the block.
>> 
>> I'm not entirely sure why, but FastISel does intentionally materialize
>> constants at the beginning of the block.  See
>> FastISel::enterLocalValueArea etc.  Maybe Dan knows why?
> 
> 
> Going bottom-up, FastISel doesn't know when it'll see the first use of a value
> in a block. Cleverer schemes are possible.

Or less clever by not caching the result? :)

-eric



More information about the llvm-dev mailing list