🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.nativeapi
Article #15205

Re: __fastcall - Where should I use it?

#15205
From: Andrue Cope
Date: Fri, 11 Jul 2003 08:36
20 lines
1941 bytes
Phuoc Can HUA,

> Does that mean... If I have a (frequently called) complex function without 
> any parameter, but lots of locals variables, I have to avoid to use 
> fastcall and let the compiler optimize the code?
>

Well if it doesn't have any parameters then I don't think __fastcall would do 
anything. What it does is tell the compiler to pass the first three 
parameters in registers rather than on the stack so if you have no arguments 
it does nothing.

I would not use it for functions that take a lot of arguments /and/ have a 
lot of local variables because /then/ there might be a conflict.

OTOH I'd like to stress that this is all informed speculation on my part and 
given the level of documentation for __fastcall I could be wrong :)
--
Andrue Cope
[Bicester, UK]
Technical Details
Message-ID: <VA.00001df3.002f01dd@email.address.sorry>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <oprr23nbz2bq7az6@newsgroups.borland.com> <VA.00001de2.00254a4e@email.address.sorry> <oprr4fj8rabq7az6@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10cc67,cafd0a3f947fe702
X-Google-Attributes: gid10cc67,public
X-Google-ArrivalTime: 2003-07-11 01:41:00 PST
Date: Fri, 11 Jul 2003 09:36:49 +0100
Newsgroups: borland.public.cppbuilder.nativeapi
Mime-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8bit
X-Newsreader: Virtual Access by Atlantic Coast PLC, http://www.atlantic-coast.com/va
Message-ID: <VA.00001df3.002f01dd@email.address.sorry>
Subject: Re: __fastcall - Where should I use it?
From: Andrue Cope <not.a.valid@email.address.sorry>
Reply-To: not.a.valid@email.address.sorry
References: <oprr23nbz2bq7az6@newsgroups.borland.com> <VA.00001de2.00254a4e@email.address.sorry> <oprr4fj8rabq7az6@newsgroups.borland.com>
NNTP-Posting-Host: 217.207.223.34
X-Trace: newsgroups.borland.com 1057912655 217.207.223.34 (11 Jul 2003 01:37:35 -0700)
Lines: 21
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-03!sn-xit-01!sn-xit-09!supernews.com!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail