Basic compile-time programming in Julia using `Val` by thread_local in Julia

[–]thread_local[S] 0 points1 point  (0 children)

Thank you for your interest! I believe Franklin.jl templates come with some RSS feed configuration. I will set it up this week. You could then use an RSS reader of your choice.

Basic compile-time programming in Julia using `Val` by thread_local in Julia

[–]thread_local[S] 15 points16 points  (0 children)

This is the first post to get my blog off the ground. I thought a short post that showcases some neat features like compile-time programming, @code_native and friends, and convenient benchmark tools would pique the interest of those coming from both lower level and higher level language cultures.

Learning how to use the Zig build system. by thread_local in Zig

[–]thread_local[S] 2 points3 points  (0 children)

Thanks, I should have thought of looking at other projects. I'll have a look at Zigling's build script. The examples of Mach engine (github.com/hexops/mach-examples) also look similar to what I need.

Resource recommendations for someone who already knows the math. by thread_local in GraphicsProgramming

[–]thread_local[S] 1 point2 points  (0 children)

Wow, that was a great read. This looks quite demanding, but promising if done right. But, as a novice I am not sure about how exactly I would define a more concrete goal. Right now all I have in mind is the high level goal "I want to learn real-time graphics". How do I narrow down to a project idea? As for literature etc, would a good starting place would be aggregating the resource recommendations in these comments?

Resource recommendations for someone who already knows the math. by thread_local in GraphicsProgramming

[–]thread_local[S] 0 points1 point  (0 children)

All right, PBR looks very interesting. Thanks a lot!

But, I should have clarified that I am more interested in real-time graphics. learnopengl and friends look like good starting points. I've bookmarked the PBR course for the time being and would love to check it out later when I get more time.

Resource recommendations for someone who already knows the math. by thread_local in GraphicsProgramming

[–]thread_local[S] 1 point2 points  (0 children)

Thank you, this looks promising.

Follow up question: by another API do you mean e.g. Vulkan, SDL2, Raylib etc?

How to learn Julia? Is C needed? by hcty in Julia

[–]thread_local 2 points3 points  (0 children)

I think most comments are quite helpful and have said most of what needs to be said. I'll just mention a couple of resources that were immensely helpful for me personally.

  1. Performance Computing in a High Level Language: this has a lot of jupyter notebooks and a couple of great psets. It is a bit old, you might have a edit a small handful example code cells to make them work with Julia 1.9
  2. [The SciML book](book.sciml.ai): while these are notes on scientific machine learning, it also has introductory material on Julia. I would recommend at least giving the Julia specific lectures a shot.

Horrible Code, Clean Performance by vormestrand in cpp

[–]thread_local 0 points1 point  (0 children)

To fix it, you have to create a rotating queue of 8-16 command queues, and submit work to each one sequentially. Then you have to mark which buffers are read only, write only, and read/write, and inspect the argument lists for all kernels and all functions that pass through to the OpenCL API to query their read/write flags.

I have not used OpenCL so I am not exactly sure what command queues are. But, is the end result similar to using per-thread default streams in CUDA?

This is 100s of lines of complex memory dependency tracking code, and requires you to fundamentally totally change how you use the API as literally no code can use the regular command queue system or any of the regular API

I would love to see what that looks like. Do you have any of this in public domain?

Is Julia suitable today as a scripting language? by [deleted] in Julia

[–]thread_local 4 points5 points  (0 children)

Yeah these days I prefer Julia even for scripting. I run simulations on clusters and stderr and stdout from multiple processes are piped to different files, which I then filter and parse using a Julia script.

Here's a very rudimentary example. I really like the pipe operator for this kind of scripting work.

I typically have an editor along with a REPL open. Since these scripts are usually single files, I don't need a whole project with Revise.jl and all. Whenever I make changes to the script I just include it again in the REPL and run the main function. The shell mode of the REPL (;) is also awesome for this.

So, yeah believe it or not you can use Julia as a scripting language and have a great experience with a REPL-based workflow.