[fpc-pascal] Assert (in System) overhead
peter at freepascal.org
Mon Apr 4 07:56:34 CEST 2005
> The System Unit provides the Assert procedures. Code generation for
> Assert can be activated through a compiler switch or command-line option:
> However, if you do leave them in, what is the overhead? In particular,
> (1) does the generated code always involve a procedure call,
> or is the condition check inlined, and
> (2) is the (optional) message parameter (when present) always
> or only when the condition fails?
>>From the generated assembler listing of a small example, I get the
> impression that the check is inlined and the message parameter is
> evaluated only on failure.
> Can someone confirm that this is indeed always the way it is handled?
More information about the fpc-pascal