Christoph Guentner
2006-08-23 15:17:27 UTC
Hello,
I use Visual Basic 6 to create my application.
P-code ist smaller than native code. I think that is clear.
But I have always read (and though thought) that native code is faster and
better.
When I compile my application to P-code it runs faster than when compiled to
native code,
e.g. one routine takes around 20 ms in P Code, but in native code almost one
second!
All in all in P-Code the application runs double fast as in native code.
It seems that P Code is much faster with objects.
Native code seems only to be a bit faster on arithmetic code.
And I have had some weired crashes when compiling to native code, e.g. the
exe crashed when returning from a subroutine on 'End Sub'! In the IDE there
was no crash.
And I "fixed" some other crash by just moving some declaration some lines up
or down!
I have not yet had such crashes with P-ode or in the IDE
So, it seems that P code is smaller, faster and more robust.
But in the documents and in the web always native code is recommended. Why?
What is the disadvantage of P-Code?
Chris
I use Visual Basic 6 to create my application.
P-code ist smaller than native code. I think that is clear.
But I have always read (and though thought) that native code is faster and
better.
When I compile my application to P-code it runs faster than when compiled to
native code,
e.g. one routine takes around 20 ms in P Code, but in native code almost one
second!
All in all in P-Code the application runs double fast as in native code.
It seems that P Code is much faster with objects.
Native code seems only to be a bit faster on arithmetic code.
And I have had some weired crashes when compiling to native code, e.g. the
exe crashed when returning from a subroutine on 'End Sub'! In the IDE there
was no crash.
And I "fixed" some other crash by just moving some declaration some lines up
or down!
I have not yet had such crashes with P-ode or in the IDE
So, it seems that P code is smaller, faster and more robust.
But in the documents and in the web always native code is recommended. Why?
What is the disadvantage of P-Code?
Chris