How to play with a RiscV version of Haiku in TinyEMU or QEMU?

Hmm… I know at one time we were using Mesa3D with Softpipe, not LLVM. Softpipe uses Gallium (or the other way around). As Haiku (RiscV) doesn’t have ANY version of Mesa3D right now, it wouldn’t matter which revision of Mesa3D we used… including an absolutely obsolete version. As it is, the ATI Rage 128 chipset is no longer supported in Mesa3D, so we HAVE to go to an older version, just to be able to have Mesa3D at all, in the RiscV version (at least, in the QEMU environment, which only supports the ATI Rage 128 chipset).

How hard would it be to get an OLD (ATI Rage 128 supporting) version of Mesa3D (that uses Softpipe/Gallium) for Haiku (RiscV) compiled? I’m assuming we still can get it. But not sure how or where.

Well, I finally found this:

This thing use LLVM.

“This thing…” being what I just found or what is currently being worked on for Haiku (RiscV)? As I understand it, if LLVM is not specified in the build, it defaults to softpipe (or swpipe, in a worst case?), but…

softpipe and llvmpipe are the same thing and it use LLVM.

So, you’re saying that EVERY version of Mesa3D that has EVER existed for Haiku, has ALWAYS used LLVM?

I find this hard to believe. However, I also just found this… seems to clearly mention swrast, not softpipe or LLVM:

Now, versions more recent, also in that repository, DO mention LLVM… but not this one.

Which means, at some point in the past, Haiku was NOT using LLVM to build Mesa3D. The performance may have stunk, but it ran. I assume.

In my “Learning Adventure”, I’m wondering what other apps or code can be compiled that would run in Haiku (RiscV) in QEMU. What, exactly, is required to make an app build… jam. Or make. Or… whatever. :rofl:

Does the compiler (Jam or whatever) do all the “rearranging”, to make an app work in Haiku (RiscV) or do you actually have to change a portion of the source code in an app, to make it compile for Haiku (RiscV)?

I would be very interested to see if you could compile Digger (the old SDL1 version from digger.org or the SDL2 version from GitHub - sobomax/digger: Classical game of Digger, digitally remastered and enhanced) on RiscV.
Here’s hoping for a Risc-V PC revolution, with Haiku as the most popular OS :rofl:

Just found this… fascinating:

Continuing the discussion from How to play with a RiscV version of Haiku in TinyEMU or QEMU?:

No. Only in reference to Gallium LLVMpipe > Mesa 7.9.2 (<= OpenGL 2.1).

“The Gallium LLVMpipe (i.e. softpipe) driver is a software rasterizer that uses LLVM to do runtime code generation. Shaders, point/line/triangle rasterization and vertex processing are implemented with LLVM IR which is translated to x86, x86-64, or ppc64le machine code. Also, the driver is multithreaded to take advantage of multiple CPU cores (up to 32 at this time).” - LLVMpipe — The Mesa 3D Graphics Library latest documentation

Otherwise, look for GL implementations not using LLVM (or just wait until someone/you do the additional porting work for Haiku RISCV…

Remember, you are in control of your own implementation work…

I wonder what it would take to get SDL2 working for Haiku (RiscV). That “game” I just found would be fun to play. More Googly diggin’, I guess! Or something… :rofl:

1 Like

Other than running Haiku (RISCV) in RVVM, what am I looking at? I see you have Pulse running. I was just about to ask about getting Mandelbrot running in RISCV, but you may already have done that! Where can I get the compiled version of Pulse or how to Jam it myself? I assume RVVM is more robust (capable of more cores/threads) than QEMU? Should I see about switching to it? Is the command line similar?

RVVM run faster than QEMU, but Haiku upstream currently do not fully support RVVM (no keyboard/mouse). It need my Device Manager v2 branch: GitHub - X547/haiku at device_manager2.

1 Like

Can you summarise/give instructions on how to set up a Risc-V Haiku virtual machine?

Well, first, do you want to set it up on a Windows system or a Haiku x86_64 system?

On a macOS arm64 system.

You mean an M1 or greater Mac? If an Apple Silicon (M1 or greater)-native version of QEMU is available for macOS, then you would download/install that. Then download a RiscV revision of Haiku. Then follow the proper guide to place u-boot and the revision of Haiku where they need to go. Then execute the proper command line for macOS Terminal to then start up QEMU and load/execute Haiku (RiscV) in it.

It just says: Guest has not initialised the display (yet)
When I look at serial0 it has KDLed.

Yeah, the Terminal is your serial display. Which revision of Haiku are you using? You are making sure it is from the RiscV page, right?