[LLVMdev] bug in ARMFrameLowering.cpp:processFunctionBeforeCalleeSavedScan

James Molloy james.molloy at arm.com
Mon Dec 5 06:44:30 PST 2011


Hi Alok,

Echoing Anton's statements, please provide a testcase! :)

Apart from that, looking at your patch and description I actually think that it is estimateRSStackSizeLimit that is wrong.

It is performing a check for a Thumb2 addressing mode whether the target has a FP register. That's the main check - for some reason it is appending another check AFI->hasStackFrame() which seems wrong. The function should assume the function has a stack frame, because its entire function is to estimate its size!

It looks like that check has been copy-pasted from elsewhere in the file. Anton, would you agree with this? I haven't looked at ARMFrameLowering before.

Cheers,

James

-----Original Message-----
From: llvmdev-bounces at cs.uiuc.edu [mailto:llvmdev-bounces at cs.uiuc.edu] On Behalf Of Anton Korobeynikov
Sent: 05 December 2011 11:11
To: Alok Manchanda
Cc: llvmdev at cs.uiuc.edu
Subject: Re: [LLVMdev] bug in ARMFrameLowering.cpp:processFunctionBeforeCalleeSavedScan

Hello Alok,

> I fixed this by performing the CanEliminateFrame and
> RegInfo->cannotEliminateFrame checks before the call to
> estimateRSSStackSizeLimit, since these values are available before BigStack
> is initialized. Does that sound reasonable? I’ve attached a patch with my
> change.
Will you please provide a testcase which reproduces the problem?

Thanks!
-- 
With best regards, Anton Korobeynikov
Faculty of Mathematics and Mechanics, Saint Petersburg State University

_______________________________________________
LLVM Developers mailing list
LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev







More information about the llvm-dev mailing list