Hacker News new | ask | show | jobs
by pizlonator 30 days ago
It is exactly as inefficient as “passing it around as the first argument” implies

There’s a speedup to be had by either reserving a GPR or using one of the segment registers

Lots of obvious stuff like this hasn’t been done yet! If you want to have the satisfaction of landing speedups then Fil-C is a fun thing you could contribute to :-)

1 comments

From what I understand, on x86 Linux stores a thread-local pointer to its TLS block in %fs. Could that simply be re-used?

https://groups.google.com/g/comp.arch/c/IT2dhS4q2M8?pli=1

Yes it could.

It would require more than zero work. Basically you’d need to unify yolo libc’s internal definition of pthread with libpizlo’s filc_thread