QBasic compiler

by Ben (no login)


I would assume that when you open some code in the qbasic 1,1, it is an interpreter and will have to do a bunch of stuff like check what graphics mode and stuff, and then not do many checks to keep it fast so that it interprets ast when pressing f5.

But I was wondering, if the QBasic 4+ compiler will be clever about things like whether image is \8 or width of screen, or optimize vga-like for stuff like pset in simpler modes? If it must only do these checks once and it is writing machine code, then it probably has such features that will make code optimal?

I tried disassembling some qbasic exes to investigate something I saw posted on forum. I read somewhere that the SLEEP statement will somehow suspend the program from the multitasker, but the do:loop until inkey$<>""... would always keep checking for key press in the multitasker. I thought, what the hell? It sounded stupid as qbasic was written for dos and stuff like multitasker wasnt considered. I disassemble the exes and it was full of garbage, i checked the difference and couldnt understand anything. so i was confused about how qbasic generate exes.

Posted on Feb 22, 2009, 8:28 PM

Respond to this message   

Return to Index

Response TitleAuthor and Date
Well... on Feb 23, 3:46 AM
 Waiting for input... on Feb 23, 8:04 AM
 xorBen on Feb 23, 12:47 PM
  XOR is a mathmatical function on Feb 23, 4:50 PM
   * Port 890..?? on Feb 23, 9:56 PM
    &H378, 379, 37A are the first 3 addresses for common LPT port programs. on Feb 23, 10:40 PM
     * Oh... NO ONE ever writes those in decimal on Feb 24, 11:17 AM
      I DO! What is the BIG DEAL about Hex? It is just converted by QB anyhow! on Feb 24, 11:38 AM
  Re: xor on Feb 23, 10:11 PM
   interesting informationBen on Mar 4, 12:05 PM
    Computers used big buildings and lots of tubes. on Mar 4, 1:39 PM
     tubes = semiconductors?Ben on Mar 4, 3:56 PM
      Probably vacuum tubesqbguy on Mar 4, 4:56 PM
       Wow!Ben on Mar 5, 10:14 AM
        Relays use coils to produce magnetism on Mar 5, 11:28 AM
        hmmmBen on Mar 5, 11:29 AM
         All is not lost. You can create a magnet coil to pick up stuff. on Mar 5, 11:49 AM
          I knew about the coil since i took apart the speaker, butBen on Mar 5, 12:50 PM
           Y'er learning kid. on Mar 5, 1:07 PM
          *Why insulated?Ben on Jul 29, 1:15 PM
           Because the wires would short the coil circuit.Clippy on Jul 29, 10:51 PM
         Welcome to the 21st century. on Mar 7, 1:32 AM
      * Vacuum Tubes (URL) on Mar 4, 6:54 PM
    Re: interesting information on Mar 4, 2:05 PM
    Re: interesting information on Mar 4, 2:59 PM
     * Analog is like AM and Digital is like FM radio. on Mar 4, 3:29 PM
      er... no. AM, FM and PM are ways of transfering data.lkt153 on Mar 4, 5:48 PM
       It was just a comparison. Not literal ! AM and PM are also time related. on Mar 4, 6:58 PM
     *turing machine in the game of life(URL) on Mar 4, 9:00 PM
    A tube calculatorDavid on Jun 5, 11:16 AM
   Been there (relays)Iain on Jun 6, 12:13 PM
  also on Feb 23, 10:22 PM
 BC.EXE /ABen on Apr 12, 12:34 PM
  AnswersAnonymous on Apr 12, 4:19 PM
   * http://pastebin.com/f71ce8a40* on Apr 12, 4:35 PM
    ThanksBen on Apr 13, 11:10 AM
  Calling convention on Apr 13, 6:00 PM
   I was wondering...Ben on Apr 13, 8:32 PM
    No, but yes! on Apr 14, 1:25 AM
     *kb(url) on Apr 14, 1:36 PM
     Can I find their address?Ben on Dec 30, 1:43 PM
      Re: Can I find their address?Laanan Fisher on Jan 2, 1:16 AM

 Copyright © 1999-2014 Network54. All rights reserved.   Terms of Use   Privacy Statement