Re: About speed
- From: "Joanna Carter [TeamB]" <joanna@xxxxxxxxxxxx>
- Date: Mon, 26 Jun 2006 09:24:42 +0100
"Alex" <zencovich@xxxxxxxxxxxxx> a écrit dans le message de news:
449f854d@xxxxxxxxxxxxxxxxxxxxxxxxx
| Hmm..There is the same whta I ask. Why I need to look deep inside into
code
| to get it work properly? What is benefit? Force me to study Reflector?
Force
| me to get deep understanding in IL code? It is all out of my work I think.
| Your argument seems like - "you cannot write a good application in Delphi
| Win32 if you have not a good knowledge in Asm x86". Sometimes it is
| true..but not for so simple tasks like in code I show, I think. Most .NET
| advantage is using a outer language to process text into internal
language
| (IL) which are the same for all platforms, .NET languages etc etc. But it
| seems like absolutely not true. Some languages a better than others. Is it
| not true?
The point that you are missing in this discussion is that Delphi for .NET is
trying to allow you to port your legacy code to .NET but, in so doing, it is
lulling you into a false sense of security.
Programming for a managed environment is not the same as programming for a
deterministic memory model. There are differences in how you have to write
code to allow for garbage collection.
Unlike in Win32, .NET strings are immutable, you have to consider this
factor when doing long concatenations in loops.
..NET arrays are not dynamic, unless you want to have to re-allocate and copy
an array every time you add to an array, you would move to using the generic
list classes instead.
Unlike Win32, .NET types all derive from System.Object, this then influences
how you program due to overheads involved with boxing and unboxing of value
types. You would not use IntToStr, instead you should be able to call
myIntVar.ToString(), in fact, all types inherit the ToString() method from
System.Object.
You really need to understand that, although you appear to be using the same
compiler, you really are not. The target platform is not just Win32 with a
different library, the Delphi for .NET compiler targets a totally different
memory model and runtime library.
IMO, *good* Delphi for .NET projects cannot be simply recompiled from Win32
source, there are many more considerations that will influence how a progam
is written for a managed environment as opposed to an unmanaged one.
VB programmers underwent a sever culture shock having to move to .NET, after
all, they had never had a true OO language before. At least Delphi has
allowed you to program in a manner that prepares you for the totally OO
environment that is .NET. Even though you have to make small alterations to
your code, most of the class and code structure will remain unaltered.
Joanna
--
Joanna Carter [TeamB]
Consultant Software Engineer
.
- Follow-Ups:
- Re: About speed
- From: Alex
- Re: About speed
- From: Alex
- Re: About speed
- From: I.P. Nichols
- Re: About speed
- References:
- Re: About speed
- From: Árpád Soós
- Re: About speed
- From: Oliver Townshend
- Re: About speed
- From: Don Strenczewilk
- Re: About speed
- From: Bryce K. Nielsen
- Re: About speed
- From: Craig Stuntz [TeamB]
- Re: About speed
- From: Bryce K. Nielsen
- Re: About speed
- From: Ingvar Nilsen
- Re: About speed
- From: Bryce K. Nielsen
- Re: About speed
- From: Ingvar Nilsen
- Re: About speed
- From: Bryce K. Nielsen
- Re: About speed
- From: Joanna Carter [TeamB]
- Re: About speed
- From: Ingvar Nilsen
- Re: About speed
- From: Robert Giesecke
- Re: About speed
- From: Barry Kelly
- Re: About speed
- From: Alex
- Re: About speed
- From: Robert Giesecke
- Re: About speed
- From: Alex
- Re: About speed
- Prev by Date: Re: About speed
- Next by Date: Re: About speed
- Previous by thread: Re: About speed
- Next by thread: Re: About speed
- Index(es):
Relevant Pages
|
|