Article View: comp.dsp
Article #1337Re: 96002 Question
From: Jeff Enderwick
Date: Thu, 15 Oct 1992 00:18
Date: Thu, 15 Oct 1992 00:18
24 lines
1896 bytes
1896 bytes
> I don't use a C compiler. But I'm curious about how they handle subroutines > calls. Do they use a separate stack for parameters and local storage? Is > the Stack Register used for subroutine calls? Are nesting of subroutines > calls and used of hardware DO loop used sparingly? For both g56k and g96k, we manage a software stack in addition to the hardware stack. When a function is called, the jsr instruction is used. The callee will then transfer the saved program counter off of the hardware stack and onto the software stack, thus freeing up that stack location. At the end of the function, the saved program counter is restored to the hardware stack, and the rts instruction is used. Leaf functions, which make no function calls themselves, don't bother; they just leave the program counter on the hardware stack. We, by default, issue up to three nested do loops. We won't issue a do loop if the loop body contains a function call for obvious reasons. The number three was picked so that most of the do loop benefit would be derived in most cases, with plenty of room for interrupt nesting. The user can change this limit. The user can also turn off leaf function optimizations. Jeff Enderwick jeff@dsp.sps.mot.com
Technical Details
Message-ID:
<JEFF.92Oct15001826@dsp.sps.mot.com>Path:
arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!iggy.GW.Vitalink.COM!cs.widener.edu!eff!sol.ctr.columbia.edu!usc!elroy.jpl.nasa.gov!swrinde!news.dell.com!natinst.com!cs.utexas.edu!oakhill!oakhill!jeffReferences:
<1992Oct15.003553.14620@news.Hawaii.Edu>Show Full Headers
Complete Article Headers
Newsgroups: comp.dsp Path: arc1-ca.pugleaf.net!sparky!uunet!charon.amdahl.com!pacbell.com!iggy.GW.Vitalink.COM!cs.widener.edu!eff!sol.ctr.columbia.edu!usc!elroy.jpl.nasa.gov!swrinde!news.dell.com!natinst.com!cs.utexas.edu!oakhill!oakhill!jeff From: jeff@dsp.sps.mot.com (Jeff Enderwick) Subject: Re: 96002 Question In-Reply-To: denault@galileo.ifa.hawaii.edu's message of Thu, 15 Oct 1992 00:35:53 GMT Message-ID: <JEFF.92Oct15001826@dsp.sps.mot.com> Sender: news@oakhill.sps.mot.com Nntp-Posting-Host: 223.10.249.92 Organization: Motorola DSP Compilers References: <1992Oct15.003553.14620@news.Hawaii.Edu> Date: 15 Oct 92 00:18:26 Lines: 26