futhark
MandelbrotSSE
Our great sponsors
futhark | MandelbrotSSE | |
---|---|---|
52 | 4 | |
2,251 | 84 | |
0.9% | - | |
9.8 | 2.0 | |
4 days ago | 10 months ago | |
Haskell | C++ | |
ISC License | GNU General Public License v3.0 only |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
futhark
-
GPU Programming: When, Why and How?
There is no on-going work to support Metal apart from the work done by Miles. There's an old issue about it: https://github.com/diku-dk/futhark/issues/853#issuecomment-5...
We actually have a long-standing issue regarding WebGPU[0]. Long story short, we want to support it, and Athas did some exploratory work a couple of years ago and decided that WebGPU wasn't mature enough yet. We already have a WebAssembly backend, so as soon as it is possible to access WebGPU from WebAssembly it should be relatively straightforward.
-
Is Parallel Programming Hard, and, If So, What Can You Do About It? v2023.06.11a
Functional programming can be a great way to handle parallel programming in a sane way. See the Futhark language [1], for example, that accepts high-level constructs like map and convert them to the appropriate machine code, either on the CPU or the GPU.
-
Is there a programming language that will blow my mind?
Futhark - use a functional language to program the gpu
-
Does This Language Exist?
You might want to look into Futhark, although it's mainly designed for writing GPU code.
-
Learn WebGPU
I recently became aware of a high-level language called Futhark [1] that fits well in that space. It is statically-typed and functional.
Maybe some other array languages work in the GPU as well, I don't know.
-
Two-tier programming language
Futhark https://futhark-lang.org/
- Best book on writing an optimizing compiler (inlining, types, abstract interpretation)?
- APL: An Array Oriented Programming Language (2018)
MandelbrotSSE
-
1000x speedup on interactive Mandelbrot zooms: from C, to inline SSE assembly, to OpenMP for multiple cores, to CUDA, to pixel-reuse from previous frames, to inline AVX assembly...
Complete story and open-source code in my GitHub repo: https://github.com/ttsiodras/MandelbrotSSE
I confirmed my theory with an experiment on a machine with 64 cores, 52 of which were allocated to me. I made a nice plot to demonstrate it; have a look /u/JanneJM !
I just committed your recommendations. I don't see a speed difference in my i5-3427U, but they may help in newer CPUs. Thanks!
I verified that the limiting factor is memory bandwidth - and that once we switch to a fully CPU-bound mode (with option -p 100) the computation speed scales linearly with more cores.
What are some alternatives?
dex-lang - Research language for array processing in the Haskell/ML family
arrayfire-rust - Rust wrapper for ArrayFire
Halide - a language for fast, portable data-parallel computation
julia - The Julia Programming Language
BQN - An APL-like programming language. Self-hosted!
kompute - General purpose GPU compute framework built on Vulkan to support 1000s of cross vendor graphics cards (AMD, Qualcomm, NVIDIA & friends). Blazing fast, mobile-enabled, asynchronous and optimized for advanced GPU data processing usecases. Backed by the Linux Foundation.
UwUpp - The next generation esoteric language
haskell-to-elm - Generate Elm types, encoders, and decoders from Haskell types
arrayfire-python - Python bindings for ArrayFire: A general purpose GPU library.
zig - General-purpose programming language and toolchain for maintaining robust, optimal, and reusable software.
HIP - HIP: C++ Heterogeneous-Compute Interface for Portability
hasktorch - Tensors and neural networks in Haskell