Author: Frederik Tack
Date: 09:25:31 12/23/05
Go up one level in this thread
On December 23, 2005 at 10:49:00, Gerd Isenberg wrote: >>About the assembler routine being slower : >>I found that using a call by reference instead of a call by value speeds up the >>function in Delphi a great deal because you get the adress of the bitboard >>directly in the EAX register, don't know about C though but perhaps it will be >>the same or perhaps its just a thing of the Delphi compiler. > > >Yes, but even if the pointer is passed via a register (fastcall calling >convention in C is via ECX or EDX in 32-bit mode) your bitboard has to be in >memory - even if it is already in a register pair. That's true, it has to be a variable that is passed. If i have to scan a constant bitboard or a result from a logical expression, i use another function. Most of the times though, its a variable. > >Does Delfi inline short functions? Or is it allways a function call? > Not sure what you mean with 'short function'. I'm not familiar with C. If you are referring to the length of the return value, a Delphi inline assembler function can return 32-bit, 16-bit, and 8-bit results. Fred
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.