IRC channel logs
2025-10-27.log
back to list of logs
<matrix_bridge><Andrius Štikonas> I'll take a look in the evening, should be fine I guess <laurenth>I had to work around a few bugs as the commit messages show, I didn't have enough time to investigate and fix them <laurenth>s/macros expanding to other macros/macros expanding to other macros and ternary operators <laurenth>Great! Let me know if you want me to test again <laurenth>If you want to iterate locally, I use the following command to compile pnut `M2-Planet --architecture x86 -D target_i386_linux -D NO_TERNARY_SUPPORT -D ONE_PASS_GENERATOR -D SMALL_HEAP -I $M2LIB --expand-includes --debug pnut.c > pnut.M1` <Googulator>What's the difference between --expand-includes and M2-Mesoplanet? <matrix_bridge><gtker> laurenth: Try the same branch again for a fix for github.com/udem-dlteam/pnut/pull/208/commits/4f7bf1452d3add8b8ef3fb3b3746fb67ee029641 <matrix_bridge><gtker> Sadly the other issues don't have fixes as easy as those but when the fixes get merged you should be able to drop those two commits at least <laurenth>I can understand wanting to keep M2-Planet simple and I really don't mind keeping some work-arounds in pnut's codebase. And 2 out of 4 work-around commits is a still pretty good :-) <matrix_bridge><gtker> It's not so much wanting to keep it simple as it is needing to do a rather large refactor in order to make information available when it is needed 🙂 <matrix_bridge><cosinusoidally> laurenth: good to see it's a fairly small change to support M2-Planet. Do you plan to add M2-Planet build into your CI? iirc pnut used to allocate its heap with mmap. If that's still the case that might block running pnut under builder-hex0. Could brk syscalls be used instead? <laurenth>cosinusoidally: Yes, I plan to add M2-Planet to pnut's CI so it doesn't bitrot. Have you tried to build pnut-exe with the `USE_STACK_FOR_GLOBALS` option? It places globals on the stack instead of using mmap <laurenth>It should be relatively straightforward to support brk instead of mmap since mmap is only called twice during initialization (once for globals, once for the heap) and with a fixed size <matrix_bridge><gtker> stikonas: Cool. I'll just push the submodule update directly <stikonas>what are the other things that we are missing in M2-Planet? <stikonas>hmm, I guess I'll take a look at that PR...