Dungeon Serpent - Necroscope [Melodic Death Metal, 2021]
YouTube Video
Click to view this content.
I created this with a few friends a while ago, though I might share it here
very cool, but you forgot the trunk
Challenge: Function that prints a n
big tree
Write a function that prints an n
big tree, e.g. for n=5:
``` * * *
Here is what I came up with in C:
```c N,i;a(n){for(i=N=N?N:n+2;i--;printf(i?"* "+(N-n-1<i):--n?"\n":"\n%*s",N,"| |"));n&&a(n);}
// the invocation isn't part of the golf: main(){a(5);} ```
PS: Code blocks currently wrap around when they are too long, I've already submitted a patch to make them scroll horizontally instead.
Why are RISC-V Immediates so weird? [Video]
YouTube Video
Click to view this content.
Not mine, I just found it on YouTube.
Korova - Lachrydeus Mittelgard (Slahan Fontagr inn Awethi) [Avant-garde Black Metal, 1995]
YouTube Video
Click to view this content.
Vanaheim - Uit Steen Geslagen [Epic Folk Metal, 2022]
YouTube Video
Click to view this content.
Turns out the Alibaba/T-Head C906 #RISCV core with Vector extension implements an early 0.7 draft revision and is mostly incompatible with the final 1.0 revi...
I think it's fine that rvv 0.7.1 isn't included in the official toolchains anymore.
As fun as it is to play around with rvv on those chips, I see those as development devices and no normal user should enable the vector extension there anyways.
I'd also rather the clang team puts some work into finally eliminating redundant vscale load/stores (this is THE thing that's stopping rvv ports for things like SIMDe), then adding rvv 0.7.1 support.
I'm not a local programming.dev resident, but I'd be interested in a code golf community.
It could be really fun to host/participate in challenge threads, and posts about some fun golfs.
Brimstone - Breaking The Waves [Melodic Death/Power Metal, 1999]
YouTube Video
Click to view this content.
The critical section makes sure that only ever a single thread can execute the section at a time. So when a thread what's to execute the section, it first needs to make sure no other thread is executing it and potentially wait for the other threads to finish executing the section.
Reductions however don't induce this synchronization overhead, instead each thread executes with an independent parent
value, and after the loop is done, the reduction is applied to merge all parent
values. The following, is essentially what the #pragma omp parallel for reduction(min : parent)
is equivalent to:
unsigned int parents[8] = {v, v, v, v, v, v, v, v};
#pragma omp parallel for num_threads(8)
for(unsigned int j = 0; j < G.Out[v]._map.bucket_count(); j++) {
for(auto ite = G.Out[v]._map.begin(j); ite != G.Out[v]._map.end(j); ite++) {
unsigned int w = ite->first;
if(v > w)
parents[omp_get_thread_num()] = min(parents[omp_get_thread_num()],w);
}
}
unsigned int parent = v;
for (unsigned int i = 0; i < 8; ++i) {
parent = min(parent, parents[i]);
}
Osgiliath - L'Ombre Du Passe [Epic Folk/Black Metal, 1998]
YouTube Video
Click to view this content.
Enable rvv on MangoPi MQ-Pro (Allwinner D1) Linux
Enable rvv on MangoPi MQ-Pro (Allwinner D1) linux. Contribute to camel-cdr/rvv-d1 development by creating an account on GitHub.
I mainly use metal-archives and bandcamp. On metal-archives, I mainly use the similar artists feature, and sometimes search for specific genres from specific countries.