TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Computesim, learn compute shaders and control flow

5 pointsby planetis5 months ago
Hey HN, I wrote a compute shader emulator that started as a 50-line script to help me understand reduction shaders. What makes this implementation interesting is its technical approach; I&#x27;ve leveraged Nim&#x27;s macros and closure iterators to simulate lockstep execution of logical threads. The emulator runs GPU compute shaders on CPU, simulating workgroups and subgroups with proper synchronization. It supports GLSL subgroup operations and provides nice debugging messages. The emulator works with Nim code that follows compute shader patterns<p>I&#x27;ve documented some technical aspects here: <a href="https:&#x2F;&#x2F;x.com&#x2F;planetis_m&#x2F;status&#x2F;1873857578931011614" rel="nofollow">https:&#x2F;&#x2F;x.com&#x2F;planetis_m&#x2F;status&#x2F;1873857578931011614</a> Demo&#x2F;Repo: <a href="https:&#x2F;&#x2F;github.com&#x2F;planetis-m&#x2F;compute-sim">https:&#x2F;&#x2F;github.com&#x2F;planetis-m&#x2F;compute-sim</a>

no comments

no comments