HN user

calebwin

72 karma

CS PhD student at Stanford researching video analytics

Posts20
Comments8
View on HN
github.com 6y ago

Show HN: Standard Graphics – command-line tool for universal 2D graphics

calebwin
2pts0
github.com 6y ago

Show HN: A universal command-line tool for printing 2D graphics

calebwin
1pts0
github.com 7y ago

Show HN: Stdg – Print 2D graphics from any language to any screen

calebwin
2pts0
dev.to 7y ago

Pipelines – A language for data flow and analysis

calebwin
1pts0
www.reddit.com 7y ago

Emu 0.2.0 – a framework for programming GPUs in Rust

calebwin
2pts0
dev.to 7y ago

Show HN: A Language for Programming GPUs

calebwin
12pts2
github.com 7y ago

Show HN: Emu – Language for Gpgpu Scripting from Rust

calebwin
3pts0
github.com 7y ago

Show HN: Emu – Language for Gpgpu from Rust

calebwin
3pts0
calebwin.github.io 7y ago

Show HN: Emu – language for numerical computing embedded in Rust

calebwin
1pts0
github.com 7y ago

Raster – Simple Grid System

calebwin
2pts0
main.cc 7y ago

Main.cc

calebwin
4pts1
github.com 7y ago

GitHub Linguist Golang Color Change

calebwin
1pts0
en.wikipedia.org 7y ago

Hypocorisms

calebwin
1pts0
en.wikipedia.org 7y ago

English nicknames

calebwin
2pts0
news.ycombinator.com 7y ago

Ask HN: Why build compilers in Rust instead of C?

calebwin
1pts4
craftinginterpreters.com 7y ago

Crafting Interpreters: Global Variables

calebwin
2pts0
github.com 7y ago

Show HN: The Wu Programming Language

calebwin
3pts0
github.com 7y ago

Show HN: Pipelines – Language for scripting parrallel pipelines with Python

calebwin
69pts16
github.com 7y ago

Show HN: 24-hour digital tower defense simulator

calebwin
1pts0
github.com 7y ago

Show HN: Pipelines: framework and language for crafting data pipelines

calebwin
5pts0

- Maybe there is a component of RLSL that could be useful. I have to think more about what I want that component to be.

- I want Emu to support general Rust code but still use stable Rust and provide really nice compile-time errors. Maybe Emu could do AST-level checking to (1) ensure that only legal transpilable-to-SPIR-V subset is used, (2) infer the kernel parameters, (3) infer global work size, local work size and then do MIR-level compilation to OpenCL or SPIR-V?

- At the moment, I want to focus on AST-level compilation because I think many applications (AI, ML, simulations, etc.) can still technically be implemented without a huge subset of Rust.

I've been working on a project with similar goal to RLSL, called Emu. It's a procedural macro that automatically off-loads portions of code to run on a GPU. Here's a quick example...

  #[gpu_use]
  fn main() {
      let mut a = vec![0.2; 1000];
      let mut b = vec![0.3; 1000];
      let c = vec![0.0; 1000];

      gpu_do!(load(a));
      gpu_do!(load(b));
      gpu_do!(load(c));
      gpu_do!(launch());
      for i in 0..1000 {
          c[i] = a[i] + b[i];
      }
      gpu_do!(read(c));
      
      println!("{:?}", c);
  }
Emu is currently open-sourced as a 100% stable Rust library and while it only supports a tiny subset of Rust, that subset is well-defined with useful compile-time errors and a comprehensive test suite.

So if you're looking for a way to contribute to single-source GPGPU for Rust, please consider helping expand Emu's supported subset of Rust. The repository is at https://www.github.com/calebwin/emu

I will say that since Emu works at the AST/syntax level, RLSL is of great interest to me because it works instead at the MIR level which allows it to more easily support a large subset of Rust.