Login
Forum Help



Post Your Message
Username: (Login)

Topic:
Message:
 


Previous Messages
Posted By

MMS
on 2025-01-16
12:49:54
 Re: FBI+4

@Litwr This is what I expected based on the size. But then I do not get the message "my dream to expand FBI+4 to accelerate more Basic routines".
You mean the speed up just partially come from you switched off the RAM/ROM switching, but the mentioned patches also improved the speed too? Nice! It is like the ATARI guys who rewrote their BASIC interpreter commands.

Posted By

Litwr
on 2025-01-16
09:41:00
 Re: FBI+4

@MMS I just copied ROM to RAM and applied several little patches.

Posted By

MMS
on 2025-01-15
13:51:20
 Re: FBI+4

@Litwr BTW, what does FBI exactly do? grin
I tested my drwaing routines (though they are full of FORs) they seems to be faster, but I did not make a proper measurement yet.

Posted By

Litwr
on 2025-01-15
10:31:08
 Re: FBI+4

It is my dream to expand FBI+4 to accelerate more Basic routines... But It seems I have too many dreams and too little power to realize them. sad

EDIT. I forgot to mention another good benchmark for Basic.

Posted By

MMS
on 2025-01-14
15:52:51
 Re: FBI+4

Benchmarking different systems is an interesting matter. Litwr made a huge list of benchmarked computers in the past with the help of a routine calculating PI.

What I referred if focusing on basic elements,this one is similar:

https://techtinkering.com/articles/benchmarking-basic-on-vintage-computers/

The program:
https://github.com/lawrencewoodman/vintage_basic_benchmark/blob/master/commodore/bench.bas

I just chacked this list, and it sems that after using FBI+4, probably the +4 would be faster than the Sinclair QL. happy
(certainly I will download and check it)

It is really something, as the QL inside is a 32 bit Motorola 68008 CPU, though it is linked to a 8 bit external bus. And it rans @7.5MHz It is planned to be more powerful than the IBM PC... happy

Posted By

Haegar
on 2025-01-14
15:16:01
 Re: FBI+4

I was interested in which Basic is faster and how much. For my first test, I used a simple For Next loop and added a Print command. Since I didn't have a C64 set up at the moment, I used to test it on the VICE emulator (Luca, please don't moan wink. The result is, that both the V2 Basic on the C64 and the V3.5 on the Plus/4 were almost equally fast. On the Plus/4, the 500 loops were even 0.15 seconds faster. I'm curious to see how it works on a real machine.

Maybe I'll expand the bench further to test other commands.

By the way, how can I upload pictures here in the forum?

Posted By

Luca
on 2025-01-13
18:36:28
 Re: FBI+4

@Haegar if I remember well, I recently compiled the original Nukewar Plus/4 with the Austrosimple, included in the Austrospeed Compiler's page, and the result runs like a bomb! Put both the compiler and your program into the same disk image and run it.

Posted By

MMS
on 2025-01-14
15:30:25
 Re: FBI+4

@Luca: you are right. I just wish sometimes float are faster for 3D drawing (or a math FPU happy ) and real integers could be used with gfx commands happy

Posted By

Luca
on 2025-01-13
16:33:33
 Re: FBI+4

@MMS oh well my post did not regard about that argument, we were talking about the interpreter's overall speed in different BASIC versions only...

Posted By

MMS
on 2025-01-14
15:30:01
 Re: FBI+4

Thanks for the hints.
BTW on ATARI there is an interesting concept stays between the interpreter and compiled program.
It turns the BASIC code into P-code at once, and store it in the memory like this. So there is not translation from words into token at every loop of a FOR cycle, but only once.
The tokens could be quickly translated into machine code.

The use of real integers and different (faster than float) number formats also help to speed things up, like in @Litwr 's compiler, that one is blazing fast compiler.
https://atariwiki.org/wiki/Wiki.jsp?page=FastBasic

Certainly my friends know what I hunt: the way faster gfx drawing routines from BASIC without the hassle of assembly program. As I want to reproduce a BASIC V10 program.
There were some great and very fast extensions on C64 (like BLARG), could be converted to add some extreme fast line drawing routine to BASIC, but missed the box and the fill routines. Some other extensions are simply too big for the task.
My aim is to somehow reproduce the C65's BASIC V10.0 demo on it's disc, but while the first few screens could be easily created, the circle and box fill routines are terribly slow compared to the C65 (supported by a blitter like cooprocessor). I mean I could reproduce the gfx seen, but it would take a loooong time to be ready.

In fact, the C65 V10.0 BASIC was not THAT fast, so could be challenged (as you may find it on the video), or at least reproduced, just I wish you also enjoy the show.

As as I described beforehand, compiling is not an option, as does not speed up the gfx commands of V3.5, Austrospeed just passing it to the parser, Litwr's compiler does not accept such a code and Plus!comp seems to be broken.

And why? Just for fun happy

https://www.youtube.com/watch?v=0fRuYfjvvVE

@Luca: I may add few comments from my side, you may agree or disagree with that. C64 was a powerhouse of 8bit machines, but the BASIC provided with that was puny, you need to use POKE commands for the simpliest things, like changing border color. V3.5 was a great improvement (released for C64 too) and if you do not like the fancy features like gfx and sound (but I would be really surprised :-) ) then there are the commands of structured programming, made the programs - more structured.
Even without GOTO is possible to create a real working but complex program (I suppose not really possible on C64).



Posted By

Litwr
on 2025-01-13
08:36:18
 Re: FBI+4

@MMS You should have tested PAL systems for both machines. The NTSC machines are faster and this gives the C64 an unfair advantage. BTW the fastest 6502 Basic interpreter was made for the BBC Micro, but it has some annoying drawbacks: it lacks some C+4 graphics statements (e.g. CIRCLE), it can't work with dynamic strings, ... But the fastest Basics for the 8-bit micros were Mallard Basic for the Amstrad systems and ROM Basic for the ABC computers.

Posted By

gerliczer
on 2025-01-13
07:36:00
 Re: FBI+4

But does the number of BASIC commands, instructions and functions really matter regarding the speed of the running code? Tokenization, I imagine, will transform these items into indexing entities. Their number should not change the speed of calling the relevant ROM routines. The use of BASIC jump tables should be about O(1).

Posted By

Haegar
on 2025-01-13
06:03:30
 Re: FBI+4

It is well known that an extended command set in Basic usually comes at the cost of a reduction in the speed of the interpreter. Even if 3.5 is slower than 2 on the C64, I think that 3.5 Basic is a successful variant. The worst Basic I know is on the Atari VC2600 console, max. 80 characters, only a handful of commands and sloooooow. I wanted to try out Basic on the MTX512 or Coleco Adam one of these days. Let's see what I can do there.

I was never able to speed up my previous entries in the Basic 10Liner Contest with known compilers, I always got error messages. Is there anything I need to watch out for?

Posted By

Luca
on 2025-01-13
03:20:38
 Re: FBI+4

Oh well, I guess that the bad performance in the BASIC V3.5 interpreter is mostly due to... Well, the number of commands to be interpreted. 71 Vs. 108, a proportion which would slow down the Plus/4 perfomance – if we consider it has a linear proportional influence, aiming for ease (but that's not the truth of course) – of a 100% Vs. 66% by alone.

Clearly, there exist no real improved BASIC after the official V2.0, which was basically a fix of the V1.0 originally purchased for the PET line. They only stuffed MOAR WUORDS into the same engine.

Posted By

MMS
on 2025-01-12
19:15:46
 Re: FBI+4

There was a thread on Retrocomputing side, and they clearly showed the weak point of +4 and C128.

Due to continous Bank switched between Kernal, ROM, RAM, the BASIC interpreter is slower than on C64 with the same program. With their 8 step simple Benchmark program the result was humiliating:

If we take the C64 has the speed in BASIC 100%, Plus/4 had 78%, and C128 was just 71%
(but we knew it beforehand)

Certainly compilation would help, but the V3.5 specific commands would not speed up even after Austrospeed.
(i dunno if Plus4Comp really works, I never had the chance to get a proper code from it, despite go though the IFU sevetral times, even translated to English)

But @Litwr FBI+4 program made a real change! I attach the result. So, sacrificing 22KB of RAM increased the speed by 32% by switching off the RAM/ROM swapping.

And certainly Plus/4 became faster than the C64 grin

I need to test the GFX commands too, I have high hopes on speed increase :-) As it is not possible by compiling them.




I still have no idea why the GO and GOSUB still slower than in C64.
Any ideas?

Posted By

MMS
on 2025-01-12
18:51:23
 FBI+4

Title:FBI+4
Category:Utility/Programming
Release Date:2020-11-03
Language:English
Size:64K
Machine:PAL & NTSC
Code Type:Machine code
Distribution:Freeware
FBI+4 Screenshot



Copyright © Plus/4 World Team, 2001-2025. Support Plus/4 World on Patreon