Classic Computer Magazine Archive COMPUTE! ISSUE 77 / OCTOBER 1986 / PAGE 10

Readers Feedback

The Editors and Readers of COMPUTE!

If you have any questions, comments, or suggestions you would like to see addressed in this column, write to "Readers' Feedback", COMPUTE!, P.O. Box 5406, Greensboro, NC 27403. Due to the volume of mail we receive, we regret that we cannot provide personal answers to technical questions.

Defining Power

I have just purchased an IBM PC–compatible computer for the purpose of running a long BASIC program, and now I know how the emperor must have felt about his new clothes. This program, which is approximately 20K long, uses an in-memory file of string variables which is about 40K long. It had previously been running on a Commodore 128 with a 1571 disk drive, and it was working perfectly. Since it was being used for an important aerospace industry application, I felt it was time to upgrade to a higher-powered computer.

We were able to use modems to transfer the program from one computer to the other; the problem came when we tried to run it. We found that it was dismally slow, and the GW-BASIC we were using would only allow 64K for program and data—hardly any room for expansion. We then purchased a more highly touted and supposedly higher-powered version of BASIC (promoted as running many times faster than other BASICs) and found that the complied BASIC was still far slower than Commodore BASIC. I realize that I could speed up the program considerably by going to C or another more powerful language, but the increased power could only be achieved at the expense of user-friendliness.

We are now going to take one more shot at finding a more powerful version of BASIC or a complied version of BASIC, but for the moment the conclusion is that none of the professional's tools can do the job as well as the hobbyist's tool we are currently using.

Stephen R. Collins

Since we don't have your program it's impossible to account for the difference with certainty. However, the size of a particular computer's BASIC's has a lot to do with how fast it runs. Because BASIC is an interpreted language (the computer looks up each statement individually as it runs the program), the number of BASIC keywords has a significant effect on how fast it runs. The longer the list of keywords, the more time it takes the computer to scan the list and find each one. Microsoft/IBM BASIC is roughly twice the size of the 128's BASIC 7.0, so it takes the PC more time to interpret and execute each statement. Similarly, BASIC 7.0 is four times as long as the Commodore 64's BAISC 2.0, so comparable BASIC programs run somewhat slower on the 128 than on the 64.

A second reason may be the efficiency of the microprocessor itself. The PC's 8088 processor has a more powerful and varied instruction set than the 128's 8502, plus a faster clock speed. However, most 8088 ML instructions take more than twice as many clock cycles to execute as corresponding 8502 instructions, so the advantage of the PC's faster clock speeds is much reduced. Thus, the 8502's simpler instruction set can lead to greater efficiency in some cases.

A third factor, which is much more difficult to quantify, has to do with the efficiency of individual BASIC statements. For instance, the PC's routines for printing to the screen also tend to be much slower than those used on the 128, which further reduces the speed of IBM BASIC programs that involve substantial video output. This factor, of course, depends to a large extent on which commands are used in a particular program.

Your letter describes one case where the 128 appears to outperform a much more expensive machine. But in other applications the opposite might be true. For instance, the PC and its clones can transfer data to and from disk a great deal faster than the 128. Even burst mode loading with a Commodore 1571 disk drive is considerably slower than normal loading on any MS-Dos machine. As a result, the PC can outrun the 128 significantly and consistently in any application that requires heavy disk access.

Because every machine has different strengths and weaknesses, it's extremely risky to evaluate a computer's capabilities on the basis of general assumptions. Thousands of people use so-called hobbyist computers for professinal purposes, and thousands of others use so-called professional computers chiefly for entertainment. Perhaps the most useful definition of computer power is strictly functional: If a computer gets the job done in a way that satisfies your individual needs, then it's powerful—regardless of brand name or pricetag.

Your experience highlights a rule that we've emphasized many times: Before buying any piece of computer hardware or software, give it a thorough test under conditions that resemble your actual situation as closely as possible. If that's not practical—as it may not have been in your case—try to get specific advice from someone who already owns and uses the product in question. Local user groups are often an excellent source for this information.