@camel-cdr.bsky.social

🐘 @camelcdr@tech.lgbt

Fuzzing tip: use VLA instead of fixed-size buffers or malloc 1. with fixed-size buffers asan won't catch everything. 2. VLAs are faster than malloc, in my case I get 15% faster fuzzing. If VLAs aren't portable enough, just check __STDC_NO_VLA__ and select between the other options.

TIL you can't do forward compatible syscalls with inline assembly because the kernel can decide to clobber architectural state that was added after you wrote the code. If you use svc with inline assembly, you have to explicitly clobber SVE registers. Good luck doing this back in 2015 when you wrote

oh no > When source and destination registers overlap and have different EEW, the instruction is mask- and tail-agnostic, regardless of the setting of the vta and vma bits in vtype.

When source and destination registers overlap and have different EEW, the instruction is mask- and tail-agnostic, regardless of the setting of the vta and vma bits in vtype.

"Using the Ziggurat Method for Sampling Random Coordinates From a Unit Circle" gist.github.com/camel-cdr/d1... I got inspired yesterday, after I saw the article "When Greedy Algorithms Can Be Faster" (16bpp.net/blog/post/wh...) It ended up about 2x faster then the simple rejection sampling.

Using the Ziggurat Method for Sampling Random Coordinates From a Unit Circle

Using the Ziggurat Method for Sampling Random Coordinates From a Unit Circle - dist_circle.h

gist.github.com

There's been a lot of discourse on fixed-length SIMD (e.g. SSE, AVX512, NEON) vs variable-length/vector (SVE, RVV) ISAs. It's probably too early for a definite answer. But as I've designed SIMD image processing algorithms, I'll share a few results.