Efficient Code

When Visual Basic version 4 was compared with Borland’s Delphi versions 1 or 2, the conversation tended to go like this:

Delphite: Your pitiful language generates p-code. Our language generates native code. Our programs run circles around yours.

VBer: Native code won’t make your hard disk faster. Our data access application runs just as fast with p-code as yours does with native code. And we developed it faster. We don’t have to compile our program before running it, and edit-and-continue lets us fix bugs in the environment while the program is
running.

Delphite: Nonsense. We have the fastest compiler around, and our debugger is easy to use. Besides, we’re serving customers, not ourselves. The bottom line is program speed. Don’t tell me you don’t have bottleneck sections in your code.

VBer: Well, there are a few places…. But we write C++ DLLs or controls to get around them. Besides, p-code is smaller. Your language creates giant EXE files.

Delphite: Well, at least we can generate stand-alone EXE files. You have to ship megabytes of support DLLs to make even your tiniest program run. And by the way, if we need a DLL, we can write it in Delphi, not C++.

VBer: Well, we can create DLLs too.

Delphite: Yeah, p-code DLLs. Forget it.

VBer: This is all irrelevant. The bottom line is that our language is Basic. It’s the easiest, most popular language in the world. Pascal is dead.

Delphite: Basic? Pascal is a much easier language than Basic.

VBer: Basic!

Delphite: Pascal!

Joe Hacker (breaking in): A pox on both of you. I don’t want to choose between native code and p-code. I want both: p-code for the user interface and data access, native code for bottlenecks. I don’t want a fast compiler. I want an interpreter. I don’t want my language to choose whether I get a little EXE with big DLLs or a big EXE. I want to choose. And I don’t care about language wars. I’ll find a way to make any language do what I want. Just wait for Visual Basic version 5. Then we’ll be able to match languages feature for feature.

Well, Visual Basic version 5 is here. Let’s see how it measures up against Joe Hacker’s wish list.