AmithlonNG? If you start with a minimal Linux distro/live CD that fits on a few megabytes you can have most of the machine for AmgigaOS.
What's missing for a AmithlonNG are - Ability to execute host native code. On Amithlon you could execute x86 code, even if it was very limited and didn't support executing complete x86 binaries/executables (would have required a host native exec kernel and DOS, like for example the PPC ones on AmigaOS 4.x and MorphOS), only single functions could be executed in host native code. The AmigaKit A600GS/A1200NG AROS/m68k guest, Linux/ARM hosted Amiberry (Linux port of WinUAE) systems are similar, no support for ARM native executables, but single functions can use ARM native code. - A big endian X86/X64 GCC (or VBCC, LLVM, etc.) compiler, but a current version, not something as ancient as for example https://aminet.net/package/dev/gcc/x86-ami-gcc and https://aminet.net/package/dev/gcc/x86-ami-bin or the i686be GCC versions on https://www.lysator.liu.se/~lcs/files/gg-cross/
@joerg I think native code execution is not too useful. More useful would be getting virtio drivers for disk and network at least to remove some emulation overhead in those. (Although for network it may not matter much due to limited TCP/IP stack and not sure how much it would help disk but may worth a try.) I don't know how this native code works on the systems you mentioned by I guess it would need kernel support which is not present in AmigaOS4 so it would not work anyway.
This could actually become a real alternative to real hardware. The problem is putting the hardware together and setting it up.
I think the problem here is too much in the threads about qemu. After reading ‘ What the fastest possible x64 emulation way of OS4 today’ I wouldn't know anything. Not even the other threads about QEMU. Actually amigaone emulation overcomes most of the problems that are described there. This can easily be done - a simple HOWO is missing. You can find descriptions on other websites but they are mostly too deveopery The average person can get lost in it.
I wonder if someone could get a single graphics card system working. It's theoretically possible, but you need to get the host OS to leave it alone!
@balaton
Quote:
I think native code execution is not too useful. More useful would be getting virtio drivers for disk and network at least to remove some emulation overhead in those. (Although for network it may not matter much due to limited TCP/IP stack and not sure how much it would help disk but may worth a try.)
The biggest reason I want virtio network drivers, is because networking with the emulated RTL card is currently unreliable. I routinely get networking failures, and failed transfers.
I understand that there's a beta driver that works around the issue, but that isn't officially released. Plus, that driver seems to have trouble with actual hardware.
In the case of "AmithlonNG" Linux does not initialise the Radeon. The Intel card is completely disabled in the BIOS. The computer behaves as if there is only Radeon. I checked to be sure - Linux does not show the Intel card in lspci.
Here is the lspci ‘Kernel driver in use: vfio-pci’ for Radeon.
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Cape Verde PRO [Radeon HD 7750/8740 / R7 250E] (prog-if 00 [VGA controller])
Subsystem: ASUSTeK Computer Inc. Device 0427
Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- SERR- TAbort- <TAbort- SERR- <PERR- INTx-
Latency: 0, Cache Line Size: 32 bytes
Interrupt: pin B routed to IRQ 17
IOMMU group: 12
Region 0: Memory at f7e60000 (64-bit, non-prefetchable) [size=16K]
Capabilities:
Kernel driver in use: vfio-pci
Kernel modules: snd_hda_intel
Qemu restarts the Radeon card on startup and GPU passthrough works.
Returning to the subject of the project. The networking problems that occur by emulating the rtl8139 card in QEMU should not occur.
You can insert the rtl8139 card and pass it to the host. The board itself has rtl8168 built in but I have not checked if it works. You can use the rtl8139 after routing to the host on AOS4 via cable and plugging into a router/swith There are many other combinations. e.g. If you pass this rtl8139 to AOS4 (Linux will not see it) you can use a short rj45 crossover cable to connect it to rtl8168 which is seen by Linux. You can do bridge,NAT with wifi card ....
@smarkusg While I agree documentation could be improved (I plan to update my pages on that) it's hard to write a simple guide that anyone could follow because there are so many options and many ways to fail and every system is different. Maybe you've got lucky to pick a system where everything worked on first try and due to previous experience with QEMU and AmigaOS you did not meet many hurdles. For somebody trying this without prior knowledge it could be harder but it was shown that it's possible if somebody is determined enough and not give up on the first problem. Things have also improved with QEMU 10.0 with amigaone but each machine has its problems when trying pass through: 1. amigaone has no RadeonHD lite driver on the install CD so you need to do an install with sm501, then install updates, then Enhancer, then add pass through card with vfio-pci, then after it freezes on boot go back to sm501 and add INTERRUPT=no to the monitor file (if I followed correctly what you did and this is the simplest method now) or 2. pegasos2 needs to use BBoot and may also need the rom for some cards. It would be much simpler to use if the fixed kernel (which also fixes other issues with SDL as I understand) would be released in an update but that's only available for the chosen ones for now. 3. sam460ex has an issue that its u-boot only finds PCIe cards on the PCIe bus but pcie buses do not work on emulation yet and while you can add a passed through card to PCI it would only work for older Radeon cards not HD or RX on sam460ex. In QEMU 10.0 there were some fixes for passing through older cards so if somebody has one that could be tested too, I don't know if it works but QEMU 9 and before only supported RadeonHD and newer. Older cards were better supported by AmigaOS without needing additional drivers so maybe if that works now could be simpler to do.
The best way to run QEMU should be a GUI to configure all options more friendly, just like WinUae does. It's important to take note of all hardware configurations that lead to right results, just like Hacktintosh experience..
QEMU has a GUI, it's called virt-manager but it's not exactly designed for desktop virtualisation but more for enterprise usage. I've never tried it for qemu-system-ppc, just trying to install it says it would need more than 100 package dependencies and over 200MB space just to have a window to do the same I can do from the command line. You can try it if you want a GUI but I think the experience would be worse than putting the QEMU command you need in a script file once and use that afterwards.
Your result http://ns.hdrlab.org.nz/benchmark/gfx ... 2d/OS/AmigaOS/Result/2931 isn't much slower than geennaam's https://ftp.hdrlab.org.nz/benchmark/gf ... 2d/OS/AmigaOS/Result/2773 He used a faster gfx card (R9 270x), and the CPU he used (i5-10400) should be much faster than the one you are using as well. But your MemCopy results are better than his, and since AmigaOS still does a lot of 2D gfx rendering using the CPU instead of the GPU, which requires very slow reading/writing from/to the gfx card memory, your system may even be be faster for Workbench, etc., and only slower for 3D software like games using OpenGL.
Both geennaam's and your system are much faster than any real AmigaOne SE/XE/µA1, Pegasos2 and Sam4x0, just slower than a 100 times as expensive X5000 with Radeon RX gfx card.
Of course, you are right as usual. The system is very very fast when using Worknech. The working comfort has no comparison with a software driver. I also checked the 3D. @kas1e in ‘Cro-Mag Rally’ posted a link to the test:. Here are the results - range 62-75
I also got such a card today from a person interested in the project
Unfortunately I have no way to check it currently. My PSU is only 350W and even has no 6pin power plugs.
At the moment, my project budget has run out for the purchase of a PSU this month.
I also checked the 3D. @kas1e in ‘Cro-Mag Rally’ posted a link to the test:. Here are the results - range 62-75
You probably mean Irrlicht Engine's Quake3 map demo ? (at least on picture it shown it). If so, then 66 FPS there looks more or less ok. On x5000 with RadeonRX with same 02-Quake3 demo i have 260 FPS if i just run example and do nothing. On my old notebook with AMD e360 1.6ghz + HD 6300m with WinXP running natively, same Irrlicht's example gives 350FPS.
Maybe 66 not that bad for emulated environment then ?
You probably mean Irrlicht Engine's Quake3 map demo ? (at least on picture it shown it). If so, then 66 FPS there looks more or less ok. On x5000 with RadeonRX with same 02-Quake3 demo i have 260 FPS if i just run example and do nothing. On my old notebook with AMD e360 1.6ghz + HD 6300m with WinXP running natively, same Irrlicht's example gives 350FPS.
Maybe 66 not that bad for emulated environment then ?
Could probably be much faster. GART is disabled on the AmigaOne, Pegasos2 and Sam4x0 in the Radeon drivers. If Hans adds an option to enable GART, for example using an U-Boot variable which should now work at least with the AmigaOne emulation, or a check if it's running on QEmu, it should increase 3D performance.
@joerg At least for latest drivers i test from Hans, he add GART support to pegasos2, and it works. Through, i not sure if it was released to the wild, or still waiting this Enhancer 2.3 forever.. Sadly i do not have x86 big boxes (only notebooks), so can't myself setup proper gpu-passthrough setup to test drivers with enabled GART.
@kas1e If you want to get really crazy and any of those notebooks have Thunderbolt or USB-C that can handle PCIe speeds there are external boxes available to connect a GPU to a laptop. If you want to do this on Apple hardware maybe you need Asahi Linux then it should be possible even on an Apple silicon Mac Mini. This may not be very practical but for testing and curiosity it might be doable. Or if the laptop has AMD GPU you can try passing that through, just don't run GUI on the laptop and make a script to unbind card, bind it to vfio-pci, start QEMU. Then you lose output on host but should see output of guest. If the script restores the driver after QEMU exited you may get the output back or make this a boot script so you can boot into AmigaOS without needing output on the host. The only thing you need is an AMD GPU supported by AmigaOS that you can unbind from host driver and pass through to guest. You only need a second graphics card if you want to see host and guest simultaneously.
I understand that there's a beta driver that works around the issue, but that isn't officially released. Plus, that driver seems to have trouble with actual hardware.
AFAIK there were two test driver versions and the latest was said to work with both emulated and real card. The developer reviewed the emulation and said it confirms to the docs so ended up changing the driver, even though with real cards the problem never occured. It's not easy to change the rtl8139 emulation in QEMU as it can be used by all machines so it's easy to break something else that I can't test. The problem with these chips is that there are so many versions with different features and each driver uses different set of those features so not all drivers are affected by small details.
If Hans adds an option to enable GART, for example using an U-Boot variable which should now work at least with the AmigaOne emulation, or a check if it's running on QEmu, it should increase 3D performance.
Don't try to detect QEMU and change behaviour based on that. This will break eventually and create problems like the intelligence in your SFS that identifies hardware by random bits to know what optimisations to enable that then did not work on QEMU first. It's better to make it a config option. NVRAM can be used but won't work on sam460ex and may be hard to set on amigaone as then you need the backing file and cannot just use defaults (although I could change the defaults but then it will work on some QEMU versions and not on others). So best is to use a config file in the guest that is read and where these can be set or if this is just for testing and debugging a debug option may be enough.