[GSOC 2025] My interest in the Haiku Mentorship Program & GPU Acceleration Support

Hello to all members of the Haiku community,

I am Howard, currently in my first year of a Master’s program at National Taiwan Normal University (NTNU), in the Computer Graphics Laboratory. My main area of research is real-time ray tracing (ReSTIR), and I am also delving into optimizations for low-level GPU software to enhance performance in cross-platform, high-intensity computing. Since I am currently studying Vulkan, I have broadened my focus to encompass operating systems and driver development (particularly Mesa), aiming for a more comprehensive understanding of and contribution to the GPU acceleration ecosystem.

After reviewing Haiku’s FAQ and relevant GSoC guidelines, I became very interested in Haiku’s community culture, contribution process, and the support it provides to new developers. Although Haiku is not participating in GSoC 2025 this year, I noticed that the project still offers a mentorship program, including a topic on GPU acceleration support. This aligns very well with my research interests.

While this is a broad and challenging undertaking, I hope to genuinely learn how GPU drivers function through the process of porting or optimization from the ground up—rather than simply completing a “GSoC-style” short-term project. This is highly relevant to both my research and long-term development goals, and I look forward to continually participating in and contributing to the Haiku community.

My Skillset

  • Programming Languages: C++, Python
  • Graphics APIs: OpenGL (basic usage), Vulkan (continuously exploring)
  • Fundamental Knowledge: Operating Systems, Advanced Computer Graphics, Compiler Theory (Computer Engineering background)

Current Status & Next Steps

  1. Familiarizing Myself with Haiku
    I am setting up and testing the Haiku development/build environment and plan to read some official documentation and source code to understand the entire development process.

  2. Seeking Guidance and Advice
    If the community or potential mentors have any priority areas, key documents, or research resources related to GPU acceleration, please feel free to share them. I would like to cover the basics first and then discuss more in-depth technical matters.

  3. Long-Term Involvement
    I want to emphasize that my goal is not just to complete a short-term project, but to continually follow and contribute to Haiku’s progress in GPU drivers and hardware acceleration. Being part of taking a GPU driver from “nonexistent” to “implemented” would be profoundly meaningful to my research and practice, and I hope it will bring substantial benefits to the Haiku community as well.

Community Interaction
I have already joined the Haiku Forum, Mailing List, and IRC. I would also like to learn:

  • Which channel is typically used for small questions or quick responses?
  • Which channel is more suitable for in-depth discussions or more complex, formal issues?

I plan to stay active and do my homework before asking questions. If there are any open-source documents, development records, or resources that could help me become more familiar with , please feel free to recommend them.

Thank you very much for taking the time to read my introduction. I have a long-term passion for GPU acceleration and see participation in the Haiku community and mentorship program as an important challenge and learning opportunity beyond academia. I look forward to working together with everyone to bring more possibilities to Haiku’s GPU support!

17 Likes

Hello and welcome!

IRC can be used for quick response if there are people who can help at the same time you are online. So you can try that, and see if it works for you.

People usually won’t read all of the logs and reply with a big delay, it is more meant as a realtime chat.

The mailing lists seem a bit dormant at the moment, and mainly used for important announcements rather than general discussion. The forums seem to have mostly taken over.

GPU acceleration is indeed an interesting topic, and there have been talks about many possible ways to achieve it. But the short version of it is: do we want to add GPU acceleration to our own existing drivers (a lot of work, possibly without results for a very long time, but we can architecture them however we want), or do we want to “simply” port Linux existing drivers? The latter may be easier (possibly, I think we won’t know for sure until we try :smiley: ), but some people take pride in Haiku doing things its own way, and being (a lot) more than a Linux clone.

I think @X512 would be the person to ask about the second approach. They did a lot of work on it already, and have identified things that would need to change in Haiku to support it (this may touch subjects like memory management, custom file descriptor types, and other quirks and seldomly explored parts of UNIX type operating systems design).

For the first approach, I would say the last attempt was by @rudolfc but that was many years ago. Since then, only discussions about it with not much progress made.

You may also study the existing (software) rendering infrastructure and how our Mesa port is different from the code in other operating systems. The interfacing with accelerated applications (currently through the BGLView class) may need a bit of rework as well.

As for a plan for action: do you have a Haiku development environment set up already? Do you plan to run Haiku on real hardware, or in virtual machines? In the latter case, you may need to set up GPU passthrough for testing, or maybe take an indirect way and start with virtio-gpu, where the driver only needs to forward rendering commands to the host machine.

If you want to work on real hardware, it may be a good idea to consider how you are going to build and test your changes. Doing it all on the same machine may mean a lot of rebooting, and a dual-computer setup with network boot may be a way to avoid that (one computer for building, and then booting the resulting system on another computer for testing).

3 Likes

Ahoy @Howard !

Thank you for your strong commitment toward supporting Haiku and the project’s whole community !
… we all hoping in such connection to Haiku and related apps’ development – bonding long term interest with run out of doable contributions …

Adrien (Pulkomandy) written all about communication ways above. Of course , we - who are not developers - actively follows only the forum among them …
We are not closed out, but
mailing list used mainly by developers - it was new it is not frequently used anymore even by them …
IRC or other chat is a LIVE action, so if we are not present … really not bothering with reading chat logs - especially as topics there really mixed among paricipants.
This way we really happy if we read anything about upcoming development :
status report,
hardships,
achievements,
issues with chosen methods,
compiling errors/difficulties,
etc…
Not because we are all big help, but this way we can part of it,…
and for your reassurance : some of us … of course, really can help you in questionable or next steps or stucking situation, so our general interests :smiley:

About development only one selectable choice had not mentioned by Adrien (Pulkomandy) above … besides develop in a VM or bare metal …

Do you develop

natively on Haiku
or
choose cross-platform development - using a Linux distro ?

:firecracker: :sparkler: Happy building and coding days with Haiku or at least for Haiku ! :chocolate_bar:

:cowboy_hat_face:

2 Likes

There is this topic, there is a lot of material and references:

1 Like

Here you get to meet the strange people on the forum. KitsunePrefecture, who writes two pages of text with no additional information, and marcoapc, who will post links to things you probably already found, and sometimes a bit offtopic. It’s their own way to welcome you :slight_smile:

9 Likes

Welcome! I would just like to state again that I think Vulkan-only is the best approach for a new driver. It’s the approach that X512 has been taking and it also appears to be where the industry is going. There are plenty of 3D API wrappers out there that map to Vulkan, for anything from OpenGL to 3DFX Glide. Since you are more familiar with Vulkan, this also seems like a natural choice.

2 Likes

Köszönöm @PulkoMandy - you wrote what I was thinking…

1 Like

Thank you so much for giving me some direction! I’ve installed Haiku, followed the tutorials, and have been exploring on my own. I’m also digging into the previous work and discussions on this topic, so I can learn from what’s already been done. Thank you for letting me know who I can reach out to if I have any questions—it’s a huge help! :innocent:

I’ve also installed Haiku on VirtualBox, but I’m not sure if that’ll complicate GPU driver development. I’ll be looking into the potential challenges with this setup to keep moving forward. If you have any tips or know of common pitfalls, please let me know—I’d really appreciate it!

1 Like

Currently, I’m using the Element app and have joined the relevant channel to keep track of discussions. Is that a good way to stay informed about what’s going on?

Thank you for the link! I’m looking into what I need to study or work on next. It really helps me plan my next steps.

1 Like

Haha! But they did help reduce my anxiety about posting in the open-source community for the first time. I rewrote that post several times, worrying about every possible scenario that might happen, but I’m glad I finally hit “send”! XD

4 Likes

I’m sure Vulkan will continue to be important down the road, but for begginers, its learning curve can be really steep. I’m not entirely sure how the Khronos Group plans to make it more accessible moving forward, but I’m curious to see what steps they’ll take!

Welcome.Hope you could have some interest in Fcitx port and Traditional Chinese translation.

Here is some update recently…
I’ve been reading up on Haiku’s GPU Acceleration Support initiative and tracing parts of the code to understand the current status. I’m eager to start contributing, but I’m finding it challenging to identify a clear, small-scale entry point.

1 Like

Make sure you use “Linux” / “Other Linux” / “Other Linux (64 bits)” as the OS Type/Subtype/Version settings on your VirtualBox VM, specially if you give it more than just one CPU core. That setting automatically enables x2apic, which Haiku needs to run better on VBox.

You can use the VMware graphics drivers on VBox. Just set the Graphics controller to “VMSVGA”, with at least 32 MB of RAM to be safe. Then you can pkgman install vmware_addons, restart.

The VirtualBox guest-additions are out of date and pretty buggy. I do not recommend using them.

As a long time Haiku-on-a-VBox-VM user: You might be better of just using VMware at this point (it runs a bit faster than VBox anyway).

Like PulkoMandy said in an earlier post, @X512 and/or @rudolfc might be able to help you out here.

1 Like

Where to start contributing probably depends on where you have existing knowledge and expertise. Have you ever worked with Mesa’s codebase before? If you have, contributing changes to it may be easier than diving into driver code directly. The Haiku windowing system code in it could use a refactor; right now it just exports bitmaps, but it really should attach to BViews directly, that might be an interesting change to look into.

Best to draw out the Haiku graphics stack layout and focus on a key area (i.e. KISS principle). Don’t ski the avalanche yet. :wink:

Updating and submitting the Vulkan lib/headers for Haiku support is a great idea.

We already have the Vulkan lib/headers, and IIRC Mesa lavapipe already works.

1 Like

Patches for Haiku support weren’t submitted yet to the Khronos Vulkan github repo yet.

Some work was pending for the current Mesa 25.0.1 release to replace Haiku’s current Mesa 22.0.5 implementation.

There were the updates from @X512 for compiling the AMDgpu driver (i.e. RadeonGfx) and new graphics stack. Needed updates to the app_server for other features (i.e. true multimonitor support). Then, whatever patches to the kernel for HW/GPU management (i.e. ioctl, etc).

3 Likes