Optimize my code =)
Kapps
opantm2+spam at gmail.com
Tue Feb 18 07:36:38 PST 2014
On Tuesday, 18 February 2014 at 09:05:33 UTC, Stanislav Blinov
wrote:
>
> allocationTest ...
> Time required: 2 hnsecs (o_O)
> identityMatrixTest ...
> Time required: 4 hnsecs (o_O)
LDC is probably detecting that you're never actually using the
results of the operation and that none of the steps have
side-effects, so it's optimizing the call out. One way of
avoiding this is to do something like writeln the result of an
operation.
More information about the Digitalmars-d-learn
mailing list