Re: Delphi 7 vs 2007
- From: "Bruce McGee" <bmcgee@xxxxxxxxxxxx>
- Date: 15 Apr 2007 09:13:54 -0800
Bob D. wrote:
Hello,
I have a project written in Delphi 7.
I want to ask, if I move to Delphi 2007 will I have any benefit to
the generated executable file? I mean does the compiler has any
change or improvement?
Others already pointed out that you will get better performance just by
rebuilding your project with the latest compiler.
1) FastMM Memory Manager
There is a new memory manager, which is faster (especially in
multi-threaded apps) and less susceptible to fragmentation. It's also
been pointed out that you can use this without upgrading. You just
need to make sure you distribute the right sharemem if you're using
packages and be careful about load order if you're using exception
loggers like MadExcept.
In fact, I'd suggest getting the latest FastMM, even if you do upgrade.
Pierre releases fixes and improvements fairly regularly, and the full
package has more debugging/leak detection options than the one that
ships with Delphi.
http://sourceforge.net/projects/fastmm/
There is something you need to watch out for. FastMM is less tolerant
of memory bugs than the previous one. Your existing application might
access freed memory and happen to work by accident, but you will see an
exception using FastMM. I consider this to be a good thing since these
are legitimate bugs in my code, which usually only show up as random
failures. Still, I'd do some testing before releasing anything.
2) FastCode routines in the RTL
You can use the FastCode routines without upgrading, too. In fact,
they have a lot that hasn't been included in Delphi, at least not yet.
http://www.fastcodeproject.org/
If you use the FastCode libraries and call the routines directly, only
these direct calls from your code will get the benefit. The VCL and
RTL will still use the default routines. You can get around this by
rebuilding the VCL/RTL or by patching the to redirect all calls to
their FastCode equivalents if you're comfortable with these.
With Delphi 2007, you don't have to worry about any of this. All of
the replaced routines are used everywhere in (and tested with) the
VCL/RTL.
3) Inlining
If a routine is small enough, removing the calling overhead and
including the code inline gives you a performance increase. the
tradeoff is increased application size. This is used generously
throughout the VCL/RTL.
4) Miscellaneous
And, of course, there have been lots of little tweaks and fixes in the
VCL/RTL/Compiler.
One example I found was the use of MOVZX in the compiler which gives
slightly smaller and faster code generation on P3/P4 and up at the
expense of slightly slower code on older processors.
These are just the things that will affect the generated EXE and
doesn't include other improvements and fixes in the compiler, VCL, RTL,
IDE, help, unit testing, modelling, build system, etc.
The link Dan Downs posted covers a lot of these in better detail.
--
Regards,
Bruce McGee
Glooscap Software
.
- Follow-Ups:
- Re: Delphi 7 vs 2007
- From: Bruce McGee
- Re: Delphi 7 vs 2007
- References:
- Delphi 7 vs 2007
- From: Bob D.
- Delphi 7 vs 2007
- Prev by Date: Re: ANN: DelphiSpeedUp 2.5
- Next by Date: What's the best combination tools for runtime Forms designer and Scripting
- Previous by thread: Re: Delphi 7 vs 2007
- Next by thread: Re: Delphi 7 vs 2007
- Index(es):
Relevant Pages
|
|