HNHacker News
TopNewBestAskShowJobs

aktau

806 karma · joined May 31, 2012

www.aktau.be (warning: I haven't updated this since I joined $BIGCO)
submissionscomments
aktau··on A Walk with LuaJIT
At least if one self-compiles Neovim (which I do), it's statically linked.
aktau··on A Walk with LuaJIT
I'd love to use this to profile Neovim, where (nowadays) user scripts are often written in Lua 5.1. Neovim by default embeds LuaJIT (close to HEAD). Being able to see Lua functions and C functions in the stack would be amazing.

Is there a single-shot mode that I can use from the command-line? Something like:

    $ parca-perf record nvim ...

Or:

    a$ nvim ...
    b$ parca-perf top -p $(pidof nvim)
aktau··on Epic Allows Internet Archive to Distribute Unreal and Unreal Tournament Forever
I bought UT2004 (Editor's Choice Edition) in 2022 on Steam (https://store.steampowered.com/app/13230/Unreal_Tournament_2...). It seems like I can still download it, phew.
aktau··on Playstation Vita Architecture (Part 1)
Objective-C? That seems like an odd choice, did they want to attract iOS developers? (I know someone ported the mobile game Angry Birds to PSP at some point). Do you have more information about this?
aktau··on Ask HN: What's the "best" book you've ever read?
Me too. I still cherish the black hardcover I got on my first trip to the US for $20 (must've been around 2006). This one: "The Ultimate Hitchhiker's Guide: Five Complete Novels and One Story".
aktau··on Porting SBCL to the Nintendo Switch
Related: https://opengoal.dev.

Context: Naughty Dog used a custom Lisp-alike (GOAL) to build the Jak & Daxter series on PS2. They left enough debugging information in that it was possible to reverse engineer. The OpenGOAL project has done so, and these games can now be run on all platforms that their GOAL compiler gets ported to (x86 for now AFAIK). Would be cool to port this to the Switch.

aktau··on AMD's Radeon 890M: Strix Point's Bigger iGPU
> That tool’s RSS is somehow 170KB (vs zero for a self-daemonizing process).

Why is the RSS relevant? I assume it doesn't need to keep on running. Also, even if it kept running, 170KB is not the end of the world.

> Also, it’s incredibly complicated. (I looked at the source.) Here’s a writeup of a simple daemon: https://pavaka.github.io/simple-linux-daemon-tutorial/

Maybe it's complicated, but perhaps it's trying to replicate daemon(3) without bugs, and for different processes. See the BUGS section in the daemon(3) man page.

> Given that it’s typed once (by the daemon author, and not the end user), it seems like a big win vs. daemon(1) to me.

This seems like a false comparison. It's not the case that the end user writes the code to daemonise in the non-included case. The user would just use daemon(1) or systemd(8) or something else that can daemonise. Or perhaps a service manager that doesn't need to daemonise, like runit(8) (https://smarden.org/runit/) and its ilk.

The more I read about this, the more I want to know why it's so important that pipewire is running "daemonized" (whether it does it itself or not). Can you explain the advantages and disadvantages?

aktau··on AMD's Radeon 890M: Strix Point's Bigger iGPU
That doesn't read like taking a dependency on systemd. Rather, Pipewire doesn't have custom code to "daemonize" by itself.

Is there any reason why all individual tools should learn how to daemonize (in addition to or in replacement of running in the foreground)? There's external tools that can take care of that uniformly, and using the latest/greatest syscalls for it. That seems better than every application including this code. As highlighted in the thread, there are other programs that can launch+daemonise another a process (like the aptly named [daemon(1)](https://manpages.debian.org/unstable/daemon/daemon.1.en.html) tool). Seems more like the UNIX way, from the outset.

aktau··on 8cc.vim: Pure Vim script C Compiler
This was tried by ZyX-I when the Neovim project was started. AFAIK they managed to create an alternative parser for Vimscript, but the transpiler was never finished (or productionized?), I think due to incompatibilities that are hard to avoid. Some relevant issues:

- https://github.com/neovim/neovim/issues/170

- https://github.com/neovim/neovim/issues/387

- https://github.com/neovim/neovim/issues/392

- https://github.com/neovim/neovim/issues/801

aktau··on Zed Decoded: Rope and SumTree
What is Vim's internal data structure nowadays? I thought it was essentially a list (array) of strings.
aktau··on On the Costs of Syscalls (2021)
> Unrelated, but what does "open-coded" mean? I never seem to find an obvious answer online.

In my understanding, open-coded means something akin to "manually inlined". Or: written inline while an acceptable alternative exists as a function.

aktau··on PIDs: Creating Stable Control in Games
These videos were fantastic, thanks for linking them. The perfect balance of a little theory with practice and examples for someone who has an immediate need to control something but has never taken a control theory class.
aktau··on Exploring Brazil's Remnant Atlantic Forest
What I found interesting when I visited Brazil was that the Atlantic Forest felt much more like the jungles of animated movies (and even live movies) that I had seen in my childhood, than the actual jungle (Amazonas area, at least around ji-parana and Manaus). I liked it a lot.
aktau··on Go 1.21 Released
Indeed, this is awesome work.
aktau··on The Unum Pattern (2019)
Firefox mobile (Android) has a reader mode (just like the desktop edition). I just tried it and it works very well for this article.
aktau··on Baby cried in his sleep and made movements as if he had a tablet in his hand
Thanks a lot for the exposition. I'll take these to heart. Not sure about Minecraft yet (despite your praise) due to the open-ended nature and the possibility to get addicted, but the NES/SNES Mario games I'm sure to try (I have a RetroArch setup). They should get tired of that by themselves easily, and get improved hand/eye coordination that should help them onboard to Minecraft in a year.
aktau··on The Awk Programming Language, Second Edition
I had no idea about this "keep the pipe open" behaviour. I thought it would spawn the binary on every print statement and thus didn't consider it in the past. But now...
aktau··on Go 1.21 Release Candidate
Arenas are available as an experiment. See (e.g.) https://www.reddit.com/r/golang/comments/ztaxhu/docs_for_the....
aktau··on Baby cried in his sleep and made movements as if he had a tablet in his hand
Thanks for the data point, I'm curious.

We've decided to give them (3, 5, 7) basically no screens except for occasional television. But I'm wondering whether it would be better to give them something creative that they could learn from instead of television. The middle one likes building (with Duplo) a lot [1].

When it comes to screens, have you tried anything apart from Minecraft and Mario Maker? What have they played Minecraft on? Did they start with those games and at what ages if I may ask? Looking at the "what's it" of Mario Maker my first thought was that it would be too complicated for them (starting out with screens), but I'm likely just underestimating them.

[1]: I was wondering about switching to Lego but I don't think these modern pre-made sets are all that good, in comparison to just regular building blocks.

aktau··on Unwinding the Stack the Hard Way
Walking the stack via frame pointers is also faster than some other methods (https://blog.felixge.de/reducing-gos-execution-tracer-overhe...), it appears. This benefits use cases like profilers and tracers. In big deployments, continuous (sampled) profiling and tracing are common, helping not only with continuous performance improvements in fleets but also helping to root cause outages. Reducing the cost of such infrastructure can pay off.
aktau··on Virtual Threads Arrive in JDK 21, Ushering a New Era of Concurrency
Performance increasing when setting `GOMAXPROCS=1` sounds like an (interesting) edge case for the scheduler. If you ever encounter this again, it would be great to file an upstream issue about this. Go has plenty of built in observability tools (I imagine runtime/trace would be good here) so it'd be easy to get the developers the data they'd need.
aktau··on Valve is paying open source developers to keep Steam Deck playable
Valve has earned my money this way. I wasn't on Steam for the longest time (among other reasons because I didn't own HW/OS combinations that could actually run things), but now I am. I'm playing even fairly recent games (Everspace, 2017) on my Dragonfly Chromebook (https://www.chromium.org/chromium-os/steam-on-chromeos).
aktau··on JPEG XL support has officially been removed from Chromium
> Who cares about bit more lossy compression for an already lossy compressed file.

Perhaps for those unaware: "without quality loss". I guess the people who care are those who store a lot of images in jpeg format (at least relative to the storage space they have). In my example, I have >1TiB of photos in JPG format (yes, I know), and it would be nice to get 200GiB back for free without losing quality. For a company offering an image storage product, this would be great cost reductions.

aktau··on Pixel 7, Pixel 7 Pro and Google Pixel Watch
Anything after the Pixel 5 doesn't have unlimited Google Photos storage anymore (but perhaps you knew that and that's the reason you're doing with the series).
aktau··on Generics can make your Go code slower
Not to detract from your general point, but I believe that this specific situation was addressed in Go 1.18's GC pacer rework: https://github.com/golang/proposal/blob/master/design/44167-....
aktau··on Russian forces invade Ukraine after Putin orders attack
Putin would pick another target, if he did start launching nukes. France has nuclear weapons.
aktau··on The Unreasonable Math of Type 1 Diabetes
Thanks for the post! I read http://cureresearch4type1diabetes.blogspot.com from time to time and that author does not give such glimmering summaries of the work that Dr. Faustman is doing (and has been doing for a long while). I don't really know of another voice on this subject. So I'll ask if you've got the time: what do you think about the blog authors evaluation and prospects of this research path?
aktau··on Why are German numbers backwards?
This was cleaned up in the Belgian variant of French: https://en.wikipedia.org/wiki/Belgian_French.

- 70 = septante (versus soixante-dix, which is 60-10)

- 80 = huitante (versus quatre-vingt, which is 40-20), *EDIT*: wrong, see below.

- 90 = nonante (versus quatre-vingt-dix, which is 40-20-10)

The article also mentions something interesting I didn't know:

> The use of septante for "seventy" and nonante for "ninety", in contrast to Standard French soixante-dix (literally "sixty-ten") and quatre-vingt-dix'("four-twenty-ten"). Those former words occur also in Swiss French. Unlike the Swiss, however, Belgians never use huitante for quatre-vingts ("four twenties"), with the use of octante in the local Brussels dialect as being the only exception. Although they are considered Belgian and Swiss words, septante and nonante were common in France until around the 16th century, when the newer forms began to dominate.[4]

*EDIT*: This doesn't appear to be true, Belgian French speakers also say quatre-vingt for 80.

aktau··on Go does not need a Java-style GC
I don't know much about this, but upthread various people say that scalar replacement happens very rarely if at all, currently. E.g.: https://news.ycombinator.com/item?id=29324132.

Could you perhaps comment on that, since you seem to have experience?

aktau··on Fun with Unix domain sockets
UNIX domain sockets also support an abstract namespace, not a part of the filesystem [1].

An excerpt of [2]:

> The abstract namespace socket allows the creation of a socket connection which does not require a path to be created. Abstract namespace sockets disappear as soon as all open instances of the socket are removed. This is in contrast to file-system paths, which need to have the remove API invoked in code so that previous instances of the socket connection are removed.

It worked quite well when I tried it (also in addition to using SO_PEERCRED for checking that the connecting user is the same as the user running the listener in question).

[1]: https://unix.stackexchange.com/a/206395/33652

[2]: https://www.hitchhikersguidetolearning.com/2020/04/25/abstra...

← PreviousPage 4 of 10Next →