This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Conditional call instruction



On Wednesday, February 13, 2002, at 02:48 PM, Geoff Keating wrote:

> Dale Johannesen <dalej@apple.com> writes:
>
>> On Wednesday, February 13, 2002, at 08:06 AM, Mark Mitchell wrote:
>>
>>> Do any of GCC's currently supported targets have a predicated call
>>> instruction that GCC will use when appropriate?  Roughly speaking,
>>> this is an instruction that calls only if some condition is true,
>>> and otherwise falls through.
>>
>> rs6000/powerpc has this in the architecture, but I've never seen
>> gcc use it.
>
> It is unusable because the range of the call is only 32k.

For the PC-relative branch, that's true, but you can also conditionally
call to the contents of LR or CTR.  It may be that it's better code
not to load those registers when the condition is false, though.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]