English Amiga Board


Go Back   English Amiga Board > Main > Amiga scene

 
 
Thread Tools
Old 23 September 2022, 01:46   #21
Gorf
Registered User

Gorf's Avatar
 
Join Date: May 2017
Location: Munich/Bavaria
Posts: 1,650
Quote:
Originally Posted by meynaf View Post
68k-to-68k JIT, huh ? This sounds like no-op
Changing addresses and pointers would probably better be done by use of some MMU. Else every memory access has to go through some costly handmade address translation.
Good point ... if you got a (usable) MMU.
Till now neither PiStorm nor Vampire offer one. And even on UEA or Amithlon it slows you down.
So while leveraging a MMU on systems that have one, would be clearly preferable, I guess doing some kind of address-translation for chunks of code for other systems will be faster.

Quote:
A simple sandbox, we already have : it's called WhdLoad.
But that's not helping here, since WHDLoad still needs the reals chipset to be present - so it can't give you AGA on ESC or RTG ...
Gorf is offline  
Old 23 September 2022, 01:50   #22
Gorf
Registered User

Gorf's Avatar
 
Join Date: May 2017
Location: Munich/Bavaria
Posts: 1,650
Quote:
Originally Posted by Tigerskunk View Post
Yeah, let's emulate AGA on the 1200...
Promote any game to any screen you want ... while still multitasking and WB running ...
Gorf is offline  
Old 23 September 2022, 04:42   #23
hammer
Registered User

 
Join Date: Aug 2020
Location: Australia
Posts: 164
Quote:
Originally Posted by Gorf View Post
Good point ... if you got a (usable) MMU.
Till now neither PiStorm nor Vampire offer one. And even on UEA or Amithlon it slows you down.
So while leveraging a MMU on systems that have one, would be clearly preferable, I guess doing some kind of address-translation for chunks of code for other systems will be faster.

But that's not helping here, since WHDLoad still needs the reals chipset to be present - so it can't give you AGA on ESC or RTG ...
WHDLoad can store and restore chipset context e.g. run workbench mod player/editor (e.g. Octamed), run WHDLoad game, and exit from it.

Amiga chipset is not a virtual machine capable. Amiga chipset would need modification to support multiple context pipelines and resource partitioning.

Amiga chipset would need a Direct2D-like layer to handle multiple contexts via the CPU's management. The software layer will need to duplicate all Amiga chipset functions.

Direct3D layer and hardware features for Radeon GCN to support virtual machines and multiple concurrent Direct3D programs running workloads are not for show.

When I run CAMD tools' Soft Synth/GMPlay with MIDI applications such as Deluxe Music 2 and, Bars-n-Pipes 2.5b that depends on Paula, these applications do not work i.e. the play buttons are frozen, hence I can't exploit the large-scale CPU power increase for Midi Soft Syn with my existing Amiga music applications. Paula audio's resource needs to be virtualized and mixed together for the final audio output.

AHI does not fake Paula's audio resources and presents them to applications that need them.

Last edited by hammer; 23 September 2022 at 05:51.
hammer is offline  
Old 23 September 2022, 05:05   #24
grelbfarlk
Registered User

 
Join Date: Dec 2015
Location: USA
Posts: 2,539
What exactly is the MIPS cost of emulating AGA vs ECS in an emulator? Put a number on it, like 15 68K MIPS?
grelbfarlk is offline  
Old 23 September 2022, 06:05   #25
Supamax
Da Digger :)

Supamax's Avatar
 
Join Date: Nov 2008
Location: Monza, Italy
Posts: 2,594
Quote:
Originally Posted by Romanujan View Post
I'm wondering: will it be very expensive? Hope not...
Also, I read that it will be only for ECS machines, not OCS.

Quote:
Originally Posted by Gorf View Post
Thanks
Supamax is offline  
Old 23 September 2022, 08:27   #26
meynaf
son of 68k
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 49
Posts: 4,598
Quote:
Originally Posted by Gorf View Post
Good point ... if you got a (usable) MMU.
Till now neither PiStorm nor Vampire offer one. And even on UEA or Amithlon it slows you down.
So while leveraging a MMU on systems that have one, would be clearly preferable, I guess doing some kind of address-translation for chunks of code for other systems will be faster.
Doing address translation means every memory access has to be translated by hand in the code itself. This means native speed can never be reached.
Of course this is still supposed to be faster than doing simple interpretive emulation, but the generated code is gonna be larger than the original one, which in turn requires all offsets to be altered. It makes the situation a lot more complicated than just changing a few values in the code...
Now the funny part is, that you can detect the presence of unsupported instructions and convert them to regular ones, i.e. 68080 extensions could in theory work on other machines.

But how to do this ? JIT is not something easy to write, especially if you want it to be real fast. You need to know when to stop converting, what to output if you find a branch, etc.
We don't have easy-to-use, freely available source code for JIT-skeleton we can alter at will.


Quote:
Originally Posted by Gorf View Post
But that's not helping here, since WHDLoad still needs the reals chipset to be present - so it can't give you AGA on ESC or RTG ...
AGA on ECS - forget it. ECS is simply not able to do the trick.
AGA on RTG - maybe, but it is incredibly costly to emulate the chipset and you'll need a damned fast 68k cpu.
What doesn't help here is the mere idea of virtualization - it's not enough.



Quote:
Originally Posted by grelbfarlk View Post
What exactly is the MIPS cost of emulating AGA vs ECS in an emulator? Put a number on it, like 15 68K MIPS?
I'd say, rather 200 !
meynaf is offline  
Old 23 September 2022, 09:58   #27
Promilus
Registered User

 
Join Date: Sep 2013
Location: Poland
Posts: 362
@meynaf - depending how accurate that emulation would have to be... I'd say even 500 might be insufficient. But PiStorm does have much more than that. But my point stands - if you already emulate hard disk, fast ram, cpu and chipset ... why not emulate whole thing without touching such beautiful classic hardware. Because - giving PiStorm AGA emulation will just restrict your Amiga to be mouse/joystick/keyboard and power interface. What's the point exactly? You won't get benefits from using real hardware. And the cost is bigger than just using PiMiga distro on things like Rpi400...
Promilus is offline  
Old 23 September 2022, 10:04   #28
Bruce Abbott
Registered User

Bruce Abbott's Avatar
 
Join Date: Mar 2018
Location: Hastings, New Zealand
Posts: 1,151
Quote:
Originally Posted by hammer View Post
Amiga chipset is not a virtual machine capable. Amiga chipset would need modification to support multiple context pipelines and resource partitioning.
Not true. But that is not what was wanted. The OP asked if there's a way to emulate the AGA chipset, so that playing AGA games would be possible on the A500/A600/A2000.

Quote:
Amiga chipset would need a Direct2D-like layer to handle multiple contexts via the CPU's management. The software layer will need to duplicate all Amiga chipset functions.
Pointless. All the software layers in the world won't magically turn OCS into AGA.

Quote:
Direct3D layer and hardware features for Radeon GCN to support virtual machines and multiple concurrent Direct3D programs running workloads are not for show.
We don't have Direct3D on the Amiga, so this is useless information.

Quote:
When I run CAMD tools' Soft Synth/GMPlay with MIDI applications such as Deluxe Music 2 and, Bars-n-Pipes 2.5b that depends on Paula, these applications do not work i.e. the play buttons are frozen, hence I can't exploit the large-scale CPU power increase for Midi Soft Syn with my existing Amiga music applications. Paula audio's resource needs to be virtualized and mixed together for the final audio output.
Audio Device - are those programs not using it? tsk tsk.

Quote:
AHI does not fake Paula's audio resources and presents them to applications that need them.
Obviously, since this is not one of its functions.

What have your issues with Soft Synth/GMPlay got to do with getting AGA games to run on an OCS Amiga?
Bruce Abbott is offline  
Old 23 September 2022, 11:35   #29
Gorf
Registered User

Gorf's Avatar
 
Join Date: May 2017
Location: Munich/Bavaria
Posts: 1,650
Quote:
Originally Posted by meynaf View Post
Doing address translation means every memory access has to be translated by hand in the code itself. This means native speed can never be reached.
Of course this is still supposed to be faster than doing simple interpretive emulation, but the generated code is gonna be larger than the original one, which in turn requires all offsets to be altered. It makes the situation a lot more complicated than just changing a few values in the code...
Now the funny part is, that you can detect the presence of unsupported instructions and convert them to regular ones, i.e. 68080 extensions could in theory work on other machines.

But how to do this ? JIT is not something easy to write, especially if you want it to be real fast. You need to know when to stop converting, what to output if you find a branch, etc.
We don't have easy-to-use, freely available source code for JIT-skeleton we can alter at will.
Well, we have of course the JIT of WinUAE … but Emu68 is probably the better candidate …

Not saying it is easy, only that there should be a faster way than what UEA for 68k is doing now.

Quote:
AGA on ECS - forget it. ECS is simply not able to do the trick.
Sorry my wording was wrong: should have been "ESC with RTG" like the framebuffer the PiStorm provides…

Quote:
AGA on RTG - maybe, but it is incredibly costly to emulate the chipset and you'll need a damned fast 68k cpu.
Yes, but that is a given here in this thread (PiStorm)

Quote:
What doesn't help here is the mere idea of virtualization - it's not enough.
Virtualization is a very broad term …

Last edited by Gorf; 23 September 2022 at 12:21.
Gorf is offline  
Old 23 September 2022, 12:10   #30
meynaf
son of 68k
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 49
Posts: 4,598
Quote:
Originally Posted by Gorf View Post
Well, we have of course the JIT of WinUAE … but Emu68 is probably the besser candidate …
Well, JIT of WinUAE does not look easy to enter into.


Quote:
Originally Posted by Gorf View Post
Yes, but that is a given here in this thread (PiStorm)
Really ? AGA emulation, while still leaving enough cpu power to have decent 68k cpu, is gonna cost at least 500Mhz 68060 level.
meynaf is offline  
Old 23 September 2022, 12:45   #31
Gorf
Registered User

Gorf's Avatar
 
Join Date: May 2017
Location: Munich/Bavaria
Posts: 1,650
Quote:
Originally Posted by meynaf View Post
Well, JIT of WinUAE does not look easy to enter into.
it is definitive some kind of black magic.

Quote:
Really ? AGA emulation, while still leaving enough cpu power to have decent 68k cpu, is gonna cost at least 500Mhz 68060 level.
My argument here is, that the CPU-part should be much cheaper on 68k as it is right now.

Vx32 does something like this for x86 to x86, as described in this paper:
https://pdos.csail.mit.edu/papers/vx32:usenix08.pdf

Last edited by Gorf; 23 September 2022 at 13:08. Reason: link added
Gorf is offline  
Old 23 September 2022, 14:07   #32
freakofnature
Registered User

 
Join Date: Jan 2021
Location: Darksideofthemoon
Posts: 50
I don't think Vx32 is an option here.
It requires a working and fast MMU. Sandboxed code and data is stored in protected memory. Only unprivileged code is executed normally.
Situation on 680x0 is a bit different. MMU is slow and lacks features. How do you prevent MC680x0 to load code into data segment and execute it? I think you'll need to scan constantly for these kind of operations, which slows down everything. Selfmodifying code will crash like on UAE with JIT enabled, i presume.
Virtualization is not supported by the underlying OS.
freakofnature is offline  
Old 23 September 2022, 15:07   #33
Gorf
Registered User

Gorf's Avatar
 
Join Date: May 2017
Location: Munich/Bavaria
Posts: 1,650
The question was about AGA ... since most selfmodifying code will break on a 020 and later anyways, there should be fewer games affected.
Gorf is offline  
Old 23 September 2022, 15:49   #34
freakofnature
Registered User

 
Join Date: Jan 2021
Location: Darksideofthemoon
Posts: 50
How is AGA done? Via code on cpu? Where is the code stored in memory? How will AGA graphics be displayed? What kind of game is there, that doesn't access chipmem or blitter directly? How does software virtualization like Vx32 help? Is c2p required to bring amiga bitplanes to screen? Where is that code located later on?

If you like to fastblit with cpu only and mimic AGA modes up to 8 bit, i think software virtualization won't help. You need a fully featured emulator. No matter what or where user code is stored.
freakofnature is offline  
Old 23 September 2022, 16:01   #35
Bruce Abbott
Registered User

Bruce Abbott's Avatar
 
Join Date: Mar 2018
Location: Hastings, New Zealand
Posts: 1,151
Quote:
Originally Posted by Gorf View Post
The question was about AGA ... since most selfmodifying code will break on a 020 and later anyways, there should be fewer games affected.
There is definitely some AGA code out there that is self-modifying, as I have seen it in C2P routines. However it should be combined with clearing the cache (eg. by calling CacheClearU()). If PiStorm doesn't support this then it is very broken.

Quote:
Originally Posted by Supamax View Post
Hi mates,
I'm very tempted by the PiStorm...
it's packed with interesting features, RTG graphics included, but again (as for the Vampire), I'm wondering if there's a way to emulate the AGA chipset so that playing AGA games would be possible on the A500/A600/A2000.
Theoretically it could do it using a similar technique to the V4, by emulating the AGA chipset. But someone would have to write the code for it (not an easy task).

Quote:
Or some software "translation" between Picasso 96 and AGA? (I don't think it would be possible / fast enough).
The problem is that AGA games tend to hit the hardware directly and use it in ways that P96 doesn't support. Your best bet for AGA game compatibility is an actual A1200 or CD32.
Bruce Abbott is offline  
Old 23 September 2022, 22:54   #36
Gorf
Registered User

Gorf's Avatar
 
Join Date: May 2017
Location: Munich/Bavaria
Posts: 1,650
Quote:
Originally Posted by freakofnature View Post
How is AGA done? Via code on cpu?
Yes - that is how UAE works
Quote:
Where is the code stored in memory?
Where Exec puts it …

Quote:
How will AGA graphics be displayed?
On a RTG screen

Quote:
What kind of game is there, that doesn't access chipmem or blitter directly?
That is why UAE emulates this hardware ..

Quote:
How does software virtualization like Vx32 help?
Vx32 is not just virtualization, see the paper I linked above.
It translates x86 into x86 more like a JIT.

Quote:
Is c2p required to bring amiga bitplanes to screen?
Sure: in the end UAE uses chunky modes to display planar screens.

Quote:
Where is that code located later on?


Quote:
If you like to fastblit with cpu only and mimic AGA modes up to 8 bit, i think software virtualization won't help.
Not sure to whom this is directed… nobody suggested that.

Quote:
You need a fully featured emulator. No matter what or where user code is stored.
UAE is a fully featured emulator … but I think the CPU part could be done faster on 68k hosts.
Gorf is offline  
Old 24 September 2022, 00:54   #37
grelbfarlk
Registered User

 
Join Date: Dec 2015
Location: USA
Posts: 2,539
I was just wondering, since in the Sonnet 7200 thread a long time ago we had got the ancient WarpOS UAE version running ECS and RTG at around A3000 speed on a 500MHz G3.

Later on there were some half hearted attempts to get JIT and AGA working but never really finished it, but we have much faster boards now too. So, I was just wondering what the performance hit was estimated to be.

RTG made the emulated environment far faster, so that's a gimme. And once you're running an AGA game it's not like you need much CPU anyway.
grelbfarlk is offline  
Old 24 September 2022, 01:04   #38
hammer
Registered User

 
Join Date: Aug 2020
Location: Australia
Posts: 164
Quote:
Originally Posted by Bruce Abbott View Post
Not true. But that is not what was wanted. The OP asked if there's a way to emulate the AGA chipset, so that playing AGA games would be possible on the A500/A600/A2000.
Run WinUAE or EUAE on RPi.

Quote:
Originally Posted by Bruce Abbott View Post
Pointless. All the software layers in the world won't magically turn OCS into AGA.
That's not the argument. Furthermore, API can't turn Feature Level 11.0 GPU into DirectX12 Ultimate Feature Level 12_2 GPU. Your statement is ignorant when certain middleware needs actual hardware support.

If you follow the thread, the argument is about sharing Amiga chipset resources in a multitasking situation.

Your argument is useless.

Quote:
Originally Posted by Bruce Abbott View Post
We don't have Direct3D on the Amiga, so this is useless information.
If you follow the thread, the argument is about sharing Amiga chipset resources in a multitasking situation instead of WHDLoad's single task.

Direct3D enables multitasking with GPU resource sharing for the PC. Amiga chipset may need equivalent middleware/hardware functions to enable multitasking for the Amiga chipset design path instead of WHDLoad's single task.

The poster who mentioned virtualized WHDLoad effectively wanted VirtualBox with Direct3D or VMware Workstation with Direct3D acceleration like features for Amiga's design evolution instead of PC's.

Vampire's improved SAGA performance is still a single task with hit-the-metal games while Xbox One/Series S/X's close-to-metal lightweight middleware is multitasking capable. DirectX12/Vulkan lower-level APIs for the PCs are design improvements to bring the PC graphics ecosystem closer to the modern game consoles. Mainstream game developers and PC stakeholders are aware of the game console's superior efficiencies and R&D efforts are applied to narrow the gap.


Quote:
Originally Posted by Bruce Abbott View Post
Audio Device - are those programs not using it? tsk tsk.
Bars and Pipes and Deluxe Music 2 need the Paula device to enable the play button. Bars and Pipes' source code is available, hence I can modify it.

Quote:
Originally Posted by Bruce Abbott View Post
What have your issues with Soft Synth/GMPlay got to do with getting AGA games to run on an OCS Amiga?
If you follow the thread, the argument is about sharing Amiga chipset resources in a multitasking situation instead of WHDLoad's single task.

Last edited by hammer; 24 September 2022 at 01:57.
hammer is offline  
Old 24 September 2022, 03:36   #39
Bruce Abbott
Registered User

Bruce Abbott's Avatar
 
Join Date: Mar 2018
Location: Hastings, New Zealand
Posts: 1,151
Quote:
Originally Posted by hammer View Post
Run WinUAE or EUAE on RPi.
OP asked about running AGA games on the A500/A600/A2000, not on a PC or RPi.

Quote:
If you follow the thread, the argument is about sharing Amiga chipset resources in a multitasking situation instead of WHDLoad's single task.
There is no 'instead of'. WHDLoad can't magically make AGA games run on OCS machines - even as a 'single task'.

Most AGA games don't multitask, so any argument about 'sharing Amiga chipset resources in a multitasking situation' is a derail.
Bruce Abbott is offline  
Old 24 September 2022, 04:39   #40
grelbfarlk
Registered User

 
Join Date: Dec 2015
Location: USA
Posts: 2,539
Has anyone run UAE 68K lately?
How does this run on an 060 machine?
http://aminet.net/package/misc/emu/UAE-828-AOS68k
grelbfarlk is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
A600 RGB2HDMI & PiStorm maddoc666 Hardware mods 3 18 February 2022 13:11
[AGA] GFX Bug :- James Pond 2 & Blobz & Bograts & Penguins Octopus66 support.WinUAE 39 11 October 2018 20:53
AGA Emulation AlenK New to Emulation or Amiga scene 2 25 September 2007 16:48
Winuae & CD32 emulation & cdda bug laser support.WinUAE 9 15 June 2007 19:36
probs with Shadow Fighter AGA & Sabre Team AGA Skumball support.WinUAE 1 10 September 2002 22:33

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 02:57.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2022, vBulletin Solutions Inc.
Page generated in 0.09601 seconds with 16 queries