Marc B. Reynolds's Avatar

Marc B. Reynolds

@marc-b-reynolds.bsky.social

https://marc-b-reynolds.github.io/ https://mastodon.gamedev.place/@mbr

114 Followers  |  50 Following  |  70 Posts  |  Joined: 19.10.2024  |  2.467

Latest posts by marc-b-reynolds.bsky.social on Bluesky

Mask for zero/non-zero bytes

FWIW: this comments on: 0x80.pl/notesen/2014...

11.07.2025 15:42 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
Preview
Oodle 2.9.14 and Intel 13th/14th gen CPUs There’s a hardware problem affecting Intel 13th/14th gen CPUs, mostly desktop ones. This made the rounds through the press last year and has been on forums etc. for much longer than that. For…

fgiesen.wordpress.com/2025/05/21/o...

22.05.2025 07:34 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

I'll just note that assuming voters are rational is a bad assumption.

09.05.2025 19:02 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Noise is Beautiful: Part 1: Procedural textures

Stefan Gustavson has put out an open access book on procgen textures.

liu.diva-portal.org/smash/record...

github.com/stegu/noisei...

09.05.2025 18:07 β€” πŸ‘ 4    πŸ” 3    πŸ’¬ 0    πŸ“Œ 0
Preview
test driver that demos "xoroshiro128+" failing PractRand test driver that demos "xoroshiro128+" failing PractRand - test.c

A test driver that demos "xoroshiro128+" failing PractRand in under 10 seconds.

Nothing special here so this is a bit surprising to me.

gist.github.com/Marc-B-Reyno...

31.03.2025 18:36 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

As a member of the commonwealth it seems like it isn't even farfetched.

18.02.2025 06:47 β€” πŸ‘ 2    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Gary Numan - Metal (Live at The Current)
YouTube video by The Current Gary Numan - Metal (Live at The Current)

The original version of Numan's Metal is good...but the post fame version is extra. Just an example if you haven't hit it before.

www.youtube.com/watch?v=tJaY...

09.02.2025 22:09 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Post image

Just sayin'

09.02.2025 10:18 β€” πŸ‘ 2    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Plus it's in the same vein as "broken clock". RKF is right about healthy diets and exercise. He's just batshit crazy about everything else. Likewise Musk's zoomers might accidently kill a few termites while they burn down the neighborhood.

08.02.2025 22:56 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

In these cases sollya would fail to converge without the seed. Other examples are using some other tool (say multiprecision or CAS) to get a first pass.

08.02.2025 18:51 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Preview
Using sollya to "repeat" Cecil Hastings' 1955 approximations for atan. Works as an example of using a 'seed' approximation & using sollya to refine. Using sollya to "repeat" Cecil Hastings' 1955 approximations for atan. Works as an example of using a 'seed' approximation & using sollya to refine. - hastings_atan.sollya

Previously mentioned Hastings 1955 #approximation and remembered I have #sollya files for some. This is the first few atan approximations.

I'm sharing because it's an example of using a "seed" approximation to refine the coefficients using sollya.

gist.github.com/Marc-B-Reyno...

08.02.2025 18:50 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
Preview
On the robustness of double-word addition algorithms We demonstrate that, even when there are moderate overlaps in the inputs of sloppy or accurate double-word addition algorithms in the QD library, these algorithms still guarantee error bounds of $O(u^...

Another #FloatingPoint refinement of pair arithmetic. This time on the so-called "sloppy add"
arxiv.org/abs/2404.05948

AFIK: latest refinement of the accurate building blocks are in this: hal.science/hal-02972245

& weakened constraint versions by Rump & Lang www.tuhh.de/ti3/paper/ru...

08.02.2025 13:19 β€” πŸ‘ 2    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

together the so-call Lie space and group (to be nerdy) or angle & axis vs. smooth space representations (to be rotation specific).

08.02.2025 11:16 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Euler's is nice because it connects dots. In 2D we have a single basis 'i' and exactly 2 unit bivectors (0,1) & (0,-1). Extending complex to 3D to get quaternions we replace 'i' with the set of all unit bivectors which is a 3D unit sphere & call a specific one 'u' and off we go. log and exp tie

08.02.2025 11:10 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
FastTwoSum revisited The FastTwoSum algorithm is a classical way to evaluate the rounding error that occurs when adding two numbers in finite precision arithmetic. Starting with Dekker in the early 1970s, numerous floatin...

A couple of #FloatingPoint papers that I caught my eye for future reading:

1) A tightening of FastTwoSum knowledge
2) Attempting to generate approximations which account for runtime evaluation errors (w source 4 external proc for Sollya)

1) hal.science/hal-04875749v1
2) hal.science/hal-04709615v1

25.01.2025 09:18 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Preview
What is a succinct rank data structure? How does it work? I've heard of a class of data structures called succinct rank data structures. What do these data structures do? What does "succinct" mean here? And how do they work?

I was reminded of this because I ran across a SO answer of his that builds up to using "Four Russians" for the "binary ranking problem"

stackoverflow.com/a/72580831/3...

17.01.2025 10:08 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Darts, Dice, and Coins

An old blog post by Keith Schwarz that builds (in an easy IMHO to follow way) sampling of a discrete distribution using "alias tables" and building via Vose's method.

www.keithschwarz.com/darts-dice-c...

17.01.2025 10:08 β€” πŸ‘ 3    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0

It's a big sadface that we didn't get AVX-512 the 256 bit addition at rollout time for consumer targeted CPUs.

06.01.2025 14:10 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

but anyway the version of isolate lowest & highest bit of each run and merge reduces to the same as the above two in that cases & is more "clear" to my mind.

06.01.2025 08:30 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0

FWIW: I'm failing at giving credit here. Warren also has a snippet for the exact match. The first 'e' expression where 'x' is the result of the sieve. The second is a reduction to make the not-and op more obvious & he notes it's 4 op

e = x & ~(x >> 1) & ~(x << 1)
e = x & ~((x >> 1) | (x << 1))

06.01.2025 08:29 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 2    πŸ“Œ 0

I mostly quit twitter a few years ago but pop in once or twice a month. So anyway toward the end of last year I logged in and saw a post of hers where she was basically normalizing the KKK. The scooby-doo meme popped in my head.

05.01.2025 16:35 β€” πŸ‘ 5    πŸ” 1    πŸ’¬ 1    πŸ“Œ 0

Ah well. Too late. Anyway if a former White Nationalist, Stormfront moderator and member of the Oath Keepers told me I sounded far-right then I'm question myself about what I was saying and maybe ask for clarification.

05.01.2025 16:07 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

FWIW: "What would you call an actually Nazi?" is a very funny question to ask to this person.

05.01.2025 15:58 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
Preview
Compiler Explorer - C (x86-64 clang 19.1.0) //************************************************************************** // mini PRNG (a unparameterized PCG variant) typedef struct { uint64_t state; } prng_t; static inline uint64_t prng_mix_6...

Repeating a respond on twitter. Using the method from hacker's delight: find all matching bit positions + find any exact fits:

gcc.godbolt.org/z/5j81on5Kz

05.01.2025 10:31 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
Item weights vs. the Paradox of Rarity This post describes using item weights to define the relative frequency of drop rates.

A mini "Happy New Year" blog post on a scheme for "drop rates":

marc-b-reynolds.github.io/math/2025/01...

01.01.2025 19:23 β€” πŸ‘ 3    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Item weights vs. the Paradox of Rarity This post describes using item weights to define the relative frequence

completed the thought: marc-b-reynolds.github.io/math/2025/01...

01.01.2025 19:18 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Can't credit but (paraphrased): "...while actually the NYT is written by and for middle managers from New Jersey"

21.12.2024 14:31 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Arseny Kapoulkine reminded me that on Zen2 PDEP is microcoded so to be avoided there. My bad.

21.12.2024 08:43 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0
Preview
Compiler Explorer - C (x86-64 clang (trunk)) // intel specific static inline uint64_t bit_scatter_64(uint64_t x, uint64_t m) { return _pdep_u64(x, m); } static inline uint32_t ctz_64(uint64_t x) { return (uint32_t)_tzcnt_u64(x); } // return x...

Two thoughts:

1) Interesting solution but n^th bit operations on hardware supporting bit-scatter can be performed in a couple of cycles.

gcc.godbolt.org/z/njde5bob6

2) If we can do (1) then is the sideline information worth the data size increase?

I need to digest their no bit-scatter solution.

21.12.2024 08:39 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
Preview
Rope Optimizations, Part 1 - Zed Blog From the Zed Blog: In this episode of Zed Decoded, Thorsten and Antonio walk through the performance optimizations Antonio when working on Zed's Rope data structure before they then pair on adding mor...

A little over a month ago the Zed (editor) team put up a blog post on their text representation

zed.dev/blog/zed-dec...

(A B-tree of 128 byte payloads...interesting) and an optimization related to that which is "find n^th bit set" for precomputed return positions in payload side-line info.

21.12.2024 08:37 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0

@marc-b-reynolds is following 20 prominent accounts