Giter VIP home page Giter VIP logo

Comments (35)

Vweber73 avatar Vweber73 commented on June 2, 2024 2

I found out why ! Well, not why, but at least the setting responsible for the sound interruptions. If I turn off "save auto snapshots", everything is fine again !

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024 1

Excellent, many thanks !
Cheers

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024 1

fast 😎

image

and it goes still faster 😱
image

what a computing monster 🀀

how fast do we actually need ?

from vamigaweb.

mras0 avatar mras0 commented on June 2, 2024 1

1: You need the amiga program to actually use (and run from) true fast memory for the increased clock speed to make a noticeable difference. Otherwise it'll just be stuck waiting like @mithrendal explained. Unless chip memory is explicitly requested AmigaOS will allocate what it considers the best (and fastest) memory. If you're using KS 1.x and have slow memory (at $c00000) available it doesn't know that this isn't really fast and will allocate that first. BTW running "FastMemFirst" from the WB disk fixes it. If you've ever wondered why that program was useful (like I did back in the day) this is the reason!
4: I think caches are helping out a lot here in addition to faster execution speeds (especially for the '030 which has both data and instruction caches), but I haven't looked at what the bottlenecks are for interceptor

I remember reading somewhere that releasing the A1200 with 2MB Chip with non sense, and that Fast RAM would have doubled the speed of the computer, even 1MB chip/1MB Fast would have been better. Yet on PUAE with a 2MB Chip only A1200, Interceptor flies... how come ?

It's because of the same issue you're seeing here (though much worse because the plain 68000 is much simpler) - increasing clock frequency is not enough on it's own if the CPU is always waiting for chip ram. Interceptor is probably simple enough that the instruction cache + faster execution speed helps enough that it feels fast on a stock A1200. 3D stuff usually requires a lot of heavy CPU processing (MUL/DIV) and these are very slow on a normal 68000 (even if it's doing nothing else and running at full speed it can only do around 5-10K divisions per second).

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

it is already planned for version 2.1 ... see dirkwhoffmann/vAmiga#661

fast forwarding is already implemented... switch warp mode on... with enabled warp mode it will fast forward when floppy disk activity is going on ... speed is up to 25x

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

@dirkwhoffmann and @mras0 got vAmiga Core running overclocked 😎😎 see here dirkwhoffmann/vAmiga#661

needs still some more work on the compatibility front ... looking forward to include the overclocked Core in vAmigaWeb to run frontier and interceptor at x8 the original CPU speed 🀀

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Excellent progress, thanks !

from vamigaweb.

dirkwhoffmann avatar dirkwhoffmann commented on June 2, 2024

how fast do we actually need ?

Unknown

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

I would say Interceptor is already superfast on a 68030...

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

image

could you try interceptor ?

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Many thanks ! I've just tried interceptor, but I fail to notice any difference no matter what clock speed I put, whereas trying it with A1200 settings on RetroArch makes it fly like hell... ??

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

But I confirm that the ECS Agnus bug is well corrected - Burning Spear works as expected both in OCS and ECS config ! :)

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

have you checked sysinfo ? hm... maybe I have still an bug somewhere ? I try to test frontier elite 2 a bit...

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

I have played with quite a few games and demo and the clock setting has no visible effect at all... As if it was completely unplugged from the engine !

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

yes I see it too ... not really visible to me neither ... only sysinfo gives me a higher score ... but why ? Maybe I call the core in a wrong way ? we have to ask tomorrow @dirkwhoffmann

we need an amiga game which shows its fps

maybe it has to do with the fact that vAmigaWeb runs in single thread mode whereas vAmiga for Mac runs multithreaded

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

one thing is also misleading I noticed...

the clock speed is saved in snapshots ... and on restoring a snapshot it is not updated in the settings dialog ... have to query the current settings on opening the dialogue

that is it makes you think you are at a certain clock speed but you are on the speed when the snapshot was saved ...

I have added three actionbuttons see here

image

also all above 60 Mhz or seems to be contra productive on my laptop as the rendered frames will drop below 30 or so

with that problems in mind ... I did a retest on my laptop with frontier/elite2 ...

my test results
frontier renders noticeably faster when using up to 56 Mhz compared to only 7 Mhz ... but above 56 Mhz the situation changes ... rendered frame rate drops below 20-30 fps ... the higher the cpu speed the lower the rendered frames ... seems my laptop system is not fast enough for anything above 56 Mhz...

more thoughts:
sysinfo4.4 does not take dropped frames into account ... it only shows the processing power in emulation time not in host time ...

in case of frontier / interceptor ... we have emulation fps which the emulation core renders into the framebuffer and a second frame rendering when the amiga framebuffer is copied into the host systems gpu ... when cpu clock is very high then the amiga framebuffer in amiga chip ram gets filled very at a higher frame rate but the host system frame rendering rate will drop

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

more tests and findings

  1. restoring snapshots does reset the cpu clock speed to the value when the snapshot was taken
  2. going from 7Mhz to 57mhz has roughly an increase of 40% from the host computing ressources
  3. the yesterdays spotted massive frame drops with speeds higher than 57Mhz were because of the live debug text scrolling. without live debug enabled the host renders at 60Hz of its maximum display rate when 68k runs at 227Mhz
  4. interceptor runs very smooth at a 68k clock speed of 28Mhz whereas frontier/elite2 needs a bit more maybe 57Mhz to execute in all scenarious absolutely smooth

we have to address finding 1 and maybe also finding 3

PS: interceptor is so cool at 28Mhz... what a game !

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Hi,

I don't get it, is a new version out ? I have no live debug enabled, yet at 28Mhz Inteceptor is not faster that at 7Mhz... ?? I could also see the ressource consumtion seems to be very high...

Yes, what a game ! My favourite back in the day, it was jar-dropping... I hope that with 28Mhz it will be better than even in NTSC mode (with 16 more lines).

The sound of the reactors is a bit weak compared to the loud Retroarch/PUAE, even with volume set to max, is there anyway to pump up the volume ? :)

Cheers

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

no new version out, still the same from yesterday... but I can see here a massive speed bumb in rendering watching the demo flight of interceptor (where you press 1 in the beginning)

strangely yesterday I also thought at first nothing changed in terms of rendering improvement... maybe still a bug ? ... we have to find what causes it ... currently it works so well for me with the same version from yesterday...

I would suggest that you create two action buttons for further testing ... one which enables 7 Mhz and another for lets say 28 Mhz

then while watching the demo you could switch between 7 and 28 Mhz... and see the massive difference

the number in the Actionbuttons script wasm_configure("CPU_OVERCLOCKING","4"); means 4*7Mhz=28Mhz

when choosing 7 Mhz you can use as a number "0" which completely shuts off overclocking or "1" as a multiplier

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

Ah now I think I have got the bug too ... I did configure fast ram=0 and only gave chipram=2MB and now there is no difference between 7 and 28 Mhz ... even worse it gets stuttering and eats power of the host device ...

did you try with fastram =2MB ? I think there is still a bug in the core regarding overclocking when only chipram is used... maybe ... we have to do further tests

the different ram types have a huge impact on overclocking ... when a 68k code runs in chip ram then it is blocked by the custom chips e.g. Agnus ... maybe we will find the bug there ...

when running sysinfo4.4.adf for example only with chip it gives me at most only a acceleration of factor 1.18 even when I overclock by factor 4 ... that said when I enable fastram then it gives me the correct speed in sysinfo speed check ...

The sound of the reactors is a bit weak compared to the loud Retroarch/PUAE, even with volume set to max, is there anyway to pump up the volume ? :)

sure ... we do that after we stabilized the overclocking ...

EDIT 1:
I reloaded interceptor again with FASTRAM=0 but this time without WARP=OFF and now it does not stutter and behaves well but OVERCLOCKING has no effect... slow like with 7Mhz

EDIT2:
will try the same setup with FASTRAM=2048 again

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

restested two times... interceptor needs FASTRAM in order to benefit from OVERCLOCKING... probably OVERCLOCKED CPU is blocked by DMA when the game runs in CHIPRAM and also it does not seem to use any MULU 68K operations as these would also benefit from OVERCLOCKING even in chip ram ...

@Vweber73 so please retest on Z3 fold with 2MB fastram and 2MB chipram, and please disable slow ram ...

the same is true for frontier elite2 ... no improvement with chipram only ... fast ram brings the speed improvements

EDIT: also for the time being ... disable warp ... there seems something wrong in conjunction with overclock

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Thanks a lot !

Ok, I did some extensive testing, and here are my findings:

  1. I confirm your analysis. If you don't have fast ram, overclocking has not effect. Even if you have fast ram, having slow ram makes that overclocking has not effect as well ! But if you have pure chip + fast, yes, Interceptor starts to fly :)
  2. At 227Mhz I get complete saturation. But everything below on my Z3 is fast and smooth.
  3. I compared this with Retroarch/PAUE, and it is pretty consistant with vAmigaWeb: I set "Cycle-exact" and changed the clock to 28Mhz. This has no speed effect on a 512/512 standard A500, but on a A600 with 2MB chip + 8Mb Fast, it flies !
  4. On RetroaArch/PUAE it also flies on a A1200 with 68030 but only 2MB of Chip RAM and no fast. I guess the 32 bit architecture helps here, different beast ?
  5. On RetroArch/PUAE, however, the "fast forward" mode makes Inteceptor flies on every configuration, even base A500. I guess this is not using overclocking of the processor, it just warps everything (the sound is garbage), a bit like your warp mode, except that it is always on, even with no disk activity...

Interesting ! :) I remember reading somewhere that releasing the A1200 with 2MB Chip with non sense, and that Fast RAM would have doubled the speed of the computer, even 1MB chip/1MB Fast would have been better. Yet on PUAE with a 2MB Chip only A1200, Interceptor flies... how come ?

Thanks and cheers

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Very interesting, many thanks for these explanations !

Cheers

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

"FastMemFirst" from the WB disk fixes it. If you've ever wondered why that program was useful (like I did back in the day) this is the reason!

me also always wondered why ... my A1000 has only got 512Kb and I never upgraded it ... @mras0 thanks for the explanation now that makes sense (I remember the icon was a rabbit and there was a slowmem with a turtle too on workbench disk ... back then in the 90ties I clicked it and nothing happened ... yeah only 512kb and no internet to get explanations for it!)

also for the time being ... disable warp ... there seems something wrong in conjunction with overclock

everything is fine with warp... I retested warp and looked in the logs ... everything is as expected

even worse it gets stuttering and eats power of the host device ...

I got it now what happened here ... this is when live debug is enabled which displays a scrolling text area with the debug output ... if this is getting really full of text and lines then it slows down everything so that frames will drop and this is even more the case when warp is enabled then it is literally only busy with pumping lines and scolling no time left for emulation rendering ... Maybe we should just remove it ... on the other hand we got no other console log viewer on iOS / iPad / Android

the only really bug left is snapshot restoration and the restoration of the snapshots CPU clock speed... this is not what I would expect ... what should we do here ? I would propose always after snapshot loading we set the CPU speed which is in the current setting and thereby overriding the snapshots saved clock speed... any thoughts ? Or is there something which speaks against this ? The question is why did @dirkwhoffmann stored the CPU clock speed in the snapshot so that it gets restored too ?

UPDATE:
image

I explained the memtype problematic in the settings description .. and I lowered the presets value from 227 MHz down to 99 MHz ... no need for that much speed I think

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Testing again, this works well, except that interceptor has every 10'seconds or so a very small interruption in the sound. Even at 7Mhz.
Besides, the sound level is quite low compared to PUAE. Any way to pump up the volume ? :)

I'm just being curious, is overclocking the 68000 enough to enjoy high speed, or would there be any benefit to emulate the specifics of 68020/30/40/60 processors, like cache etc ?

Cheers

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

this works well, except that interceptor has every 10'seconds or so a very small interruption in the sound. Even at 7Mhz.

I just watched the flight demo of interceptor and there were no sound interruptions at all... watched two times from runway start to final landing ... maybe 5 Minutes....
did you play ? or watch demo when you heard the interruptions ? Maybe host specific ... did you try iPad?

BTW the sounds are so fantastic ... could not have been done better today !!! Concerning the volume I make it louder next release ... or wait I look maybe in the meantime with an action button ?

from vamigaweb.

mras0 avatar mras0 commented on June 2, 2024

I'm just being curious, is overclocking the 68000 enough to enjoy high speed, or would there be any benefit to emulate the specifics of 68020/30/40/60 processors, like cache etc ?

If all you want is the biggest number in SysInfo it would be much easier to simply let the CPU run as fast as possible (potentially also using JIT) and not emulate it cycle accurately. Emulating caches etc will probably just make it slower.

But there really aren't that many programs that you'd usually run on a 68000 that benefits from an ultra fast processor. Assembling/compiling large programs is probably fast enough, and it's not like you're going to be rendering complex 3d scenes anyway (you'll also start to feel constrained by only having 8MB RAM if you do).

Most software that really benefits (e.g. 3d shooters) are going to need a 020 (or above) and probably also AGA, maybe even RTG etc.

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

I also watched the demo. The interruptions are not only for Interceptor, they seem general, they are also in Burning Spear demo. I made sure I had the warp mode off, but they are still there. This didn't happen before the overclocking changes...

I tried on Ipad and got no interruptions at all, everything perfect and smooth (even if I see little speed difference between 28mhz and 99mhz). I'm quite jealous for my Z3 !

Yes, what a game ! Revolutionary for its time... Amazing sounds, yes. Great if you can make the volume configurable, thanks !

Cheers

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

@mras0: Interesting, many thanks ! So, as long as the game was intended to run on a 68000 (e.g 100% of OCS/ECS), I understand they is no point emulating a 68030, overclocking is enough for those well programmed gamed that can handle it, like Interceptor (did I say that this Amiga-exclusive game is one of the most revolutionary games ever written, still impressive to this day, and is alone worth the emulator ?).

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

This didn't happen before the overclocking changes ... I tried on Ipad and got no interruptions at all, everything perfect and smooth (even if I see little speed difference between 28mhz and 99mhz). I'm quite jealous for my Z3 !

ok, what you could do is a device reboot on your z3 and see if it fixes this (maybe a process in the background has gone crazy and does something weird and eats computing capacity...)
if after reboot this problem still shows up then you could try to install parallel on the z3 the ancient version v1.08 and see if it also shows the 10 seconds sound hickup ... https://vamigaweb.github.io/v108/ I made this version once for a guy who had spent countless hours in finishing "captain planet" on his iPad and who made thousands of snapshots which were broken on a current verison of vAmigaWeb

did I say that this Amiga-exclusive game is one of the most revolutionary games ever written, still impressive to this day, and is alone worth the emulator ?

it is !!! 🀀 the sounds... the grafiques ... the game play ... everything top notch

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

I rebooted the Z3. No change whatsoever wrt the sound interruptions, including at 7Mhz.
I tried v1.08 online. No screen no clock options, but no interruptions, perfect sound...
Any idea why ?
Cheers

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

you are great 😊... that makes perfectly sense now...

what happens in auto save is this

                wasm_halt();
                wasm_take_user_snapshot(); 
                wasm_run();
                var snapshot_json= wasm_pull_user_snapshot_file();

                var snap_obj = JSON.parse(snapshot_json);
                var snapshot_buffer = new Uint8Array(Module.HEAPU8.buffer, snap_obj.address, snap_obj.size);
        
                //snapshot_buffer is only a typed array view therefore slice, which creates a new array with byteposition 0 ...
                auto_snaps.push(snapshot_buffer.slice(0,snap_obj.size));
                wasm_delete_user_snapshot();

it is triggered every 5 seconds when enabled

did you spot the wasm_halt() and wasm_run() ?

effectively what happens all 5 seconds is:
stop everything ... dump out complete state i.e. kickstartmem, chipmem, fastmem, slowmem (if any), chipset states, floppy drive, harddisk (if any was mounted) .. into a binary stream, then start the emulation again... pull this binary stream over into javascript space, delete old auto save snapshot ... oh dear🫒 ... I developed the auto save for the Commodore 64 and took this feature over into the vAmigaWeb...

to be stutter free it needs to have EITHER a very fast computer OR only 512K of chipram with no hard disk connected

that said I have here a laptop core i5 11th gen (geekbench5 singlecore speed 1324 points) which does the auto save job at 7.09Mhz fine and without pause or lag ...

my old iPhone 6s Plus ... 7 years old ... stops every 5 seconds for a fraction of a second when doing autosave of 2MB chip + 2 MB fastram... but runs interceptor otherwise fine and very smooth up to 43Mhz 😍... with 57 Mhz and above I see frame drops and the sound is not so clean with a lot of crackling ...

Maybe we should write a comment on the auto save switchin the settings about the stop/dump/start thing ? πŸ€”

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Thanks !
When you say your old iphone 6s runs Interceptor fine, do you mean that you don't have the 5 seconds problem with it ? Or that it runs ok except that if you put 2Mb chip and 2Mb fast, you have a small drop every 5 seconds if you enable auto save of snapshots, like I have on my powerful Z3 ?

from vamigaweb.

mithrendal avatar mithrendal commented on June 2, 2024

true ... on the iPhone 6s I got with auto save every 5s a short stop in emulation and sound.... when auto save is disabled then it keeps to run up to 43Mhz overclocking with very smooth frame rates and no sound distortions

from vamigaweb.

Vweber73 avatar Vweber73 commented on June 2, 2024

Ok, thanks, that's consistant with what I have ! :)

from vamigaweb.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.