Jump to content

Photo

New Compiler Loader


4 replies to this topic

#1 senior_falcon OFFLINE  

senior_falcon

    Dragonstomper

  • 908 posts
  • Location:Lansing, NY, USA

Posted Thu Sep 7, 2017 6:38 PM

gallery_34177_1071_35078.gif

I have been reworking the compiler loader to make it faster and easier to use.  The video above shows the results.  The first part shows the old compiler loader which takes about 40 seconds to load a compiled version of Aperture.  Once loaded I save it in EA5 format and then RUN the program.  The second part shows the new version, which you can see is way faster.  Once the program is loaded you are presented with three options.  The first is to save in EA5 format.  Press Enter to save under the suggested file name, or edit the name, or press F3 if you don't want to save as EA5.  The second option is to save in XB format and as before you can press Enter, or edit the file name or press F3 if you don't want to save in XB format.  The third option is to run the program.  Press Enter to run or F3 if you don't want to run the program.  In the video I save the program as EA5, skip saving as XB and then RUN the program.

 

The major insight I had in speeding the loader up is to use the EA utilities loaded by TI BASIC with CALL INIT.  There is an assembly language loader used by CALL LOAD, but it can also be BLWP'd to within an assembly program which is how I access it.  CLOADER2 will load the EA utilities when needed and then reload the XB utilities when done using the fast loader.

 

The second trick is a little routine that copies the last line of the XB program out of high memory and into low memory and resets the pointer to the new location.  The last line is where the CALL LINK is done that uses the assembly loader.  This completely overwrites the XB program and line number table but it doesn't matter because after the program is loaded the XB interpreter comes to END in the XB program and happily returns to the XB command line with no error.  

 

The third trick is to set up an interrupt driven routine that prints a suggested response on the screen and sets the pointers for the line editor to point to the new beginning position(at >8320), end position (at >832A) and cursor position (at >8361).

When you press Enter or F3 the pointers at >8320 and >832A become the same because there now is a blank line and the interrupt routine knows it is time to provide the next suggested response.  Press Enter 3 times and you have saved in EA5, in XB format, and run the program.

 

The new loader is attached as CLOADER2.  You can copy it to the compiler disk and change line 15 of LOAD to use CLOADER2.  Or you can change the filename to CLOADER, but you might want to save the original CLOADER in case there are bugs in the new one.

 

(Forgot to mention that I am using different file extensions.  -X indicates an XB format file and -E is EA5 format)

 

Attached Files


Edited by senior_falcon, Thu Sep 7, 2017 6:45 PM.


#2 Ksarul OFFLINE  

Ksarul

    River Patroller

  • 4,126 posts

Posted Thu Sep 7, 2017 8:07 PM

Nice!



#3 mmartin OFFLINE  

mmartin

    Space Invader

  • 13 posts
  • Location:Lanus,Buenos Aires,Argentina

Posted Thu Sep 7, 2017 8:45 PM

exelent job°  congratulations @senior_falcon    :::)   incredible fast running aperture..



#4 Airshack OFFLINE  

Airshack

    Dragonstomper

  • 508 posts
  • Location:Phoenix, AZ

Posted Thu Sep 7, 2017 9:29 PM

Thanks again Harry for making the process easier and faster! This is a BIG win for BASIC programmers looking for a way to speed up their code.

Glad to see you've cleared up the file extensions as well! No more "-C" extension confusion with large files and XB files! I was going to ask about this but you fixed it! :)))

#5 LASooner ONLINE  

LASooner

    Chopper Commander

  • 134 posts

Posted Fri Sep 8, 2017 2:16 PM

Thanks Harry!

 

Auto completing CALL LOAD and CALL LINK is also a huge time saver






0 user(s) are browsing this forum

0 members, 0 guests, 0 anonymous users