Article View: gnu.gcc.help
Article #49709recursion
From: Igor Durdanovic
Date: Thu, 30 Dec 1993 11:42
Date: Thu, 30 Dec 1993 11:42
29 lines
1111 bytes
1111 bytes
Hello,
Can anyone explain me strange behaviour on SPARC
for following function:
void pp( int *i )
{
int j;
pp( &j );
}
when compiled with -O2 (-O4 for cc) by
gcc uses about 120 bytes on stack for each call,
cc ... 104 ...
acc ... 112 ...
when in reality (if I'm not mistaken) all we need is:
Instruction pointer,
Stack pointer,
Argument "i"
Local variable "j"
-------------------
= 16 bytes !!
why is WINDOWSIZE in gcc 20, and in cc 16 ?
Thanks, Igor
Technical Details
Message-ID:
<2fueqc$nf2@news.uni-paderborn.de>Path:
arc1-ca.pugleaf.net!gmd.de!xlink.net!howland.reston.ans.net!europa.eng.gtefsd.com!uunet!zib-berlin.de!uni-paderborn.de!igorShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 11318c,77ed4294c69534c5,start X-Google-Attributes: gid11318c,public X-Google-ArrivalTime: 1993-12-30 03:37:35 PST Path: arc1-ca.pugleaf.net!gmd.de!xlink.net!howland.reston.ans.net!europa.eng.gtefsd.com!uunet!zib-berlin.de!uni-paderborn.de!igor From: igor@uni-paderborn.de (Igor Durdanovic) Newsgroups: gnu.gcc.help Subject: recursion Date: 30 Dec 1993 11:42:04 GMT Organization: Uni-GH Paderborn, Germany Lines: 31 Distribution: world Message-ID: <2fueqc$nf2@news.uni-paderborn.de> NNTP-Posting-Host: faust.uni-paderborn.de Keywords: resursion,stack