Gave me a warm feeling to know that someone would actually still bother to do this by hand. I'm not the only one!
Show HN: Building a web server in assembly to give my life (a lack of) meaning
11–20 of 246 posts
Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#12I'm wanting to read this repository as a learning tool, so it'd also be nice to include docs—even AI-generated docs, but obvious I'd prefer docs with your own design notes and decisions—about the architecture of the code. Really cool project though!
Thanks, I appreciate it a lot! I tried to comment my code pretty heavily (~3000 lines of code, ~1000 lines of comments all together), since this was a learning project for myself in the first place. Hopefully those will be of some use. But separate in-depth documentation is definitely a good idea, I'll work on adding that. In the meantime I'm always down to answer any questions about it!
Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#13Earlier quoted context omitted.
Thanks, I appreciate it a lot! I tried to comment my code pretty heavily (~3000 lines of code, ~1000 lines of comments all together), since this was a learning project for myself in the first place. Hopefully those will be of some use. But separate in-depth documentation is definitely a good idea, I'll work on adding that. In the meantime I'm always down to answer any questions about it!
My first question would be where should I start reading? It seems like you modularized it into multiple assembly files (how does that even work?)
Modularizing it into multiple files was easier than I expected it to be, you basically have other functions/labels in other files, and mark them as .global at the top. The Makefile compiles each file into their own .o, which you then link all together. You can "b" or "bl" to any label from any other file, as long as it's global and linked together. Same with data in .bss or .data, mark them as .global and they can be accessed from elsewhere.
Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#14This post seems to now link to the writeup rather than the repository, sorry! The repo can be found at the top of that page, or directly here: https://github.com/imtomt/ymawky
Whoops that was my fault. Fixed now. (I emailed you, btw, that we'd changed your title, but I forgot to switch the URL back to the repo. Both links are cool.) I'm sure I'm not the only one who has fantasized about doing something like this as a self-soothing enterprise. Kudos to you for actually doing it!
Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#15Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#16I feel the guy’s suspicion towards any high level language. I exclusively programmed in assembly on C64, Amiga and the recognized that this ain’t sustainable on PC because there are more and more edge cases or different machine configurations. I had a very hard time simply using and even utilizing C++ or Java. C and Turbo Pascal especially was easier because the compiled code was very much resembling to hand written…
Higher level languages are more convenient for 99% of things, but the directness of Assembly gives me a rush unlike any other. I didn't live through the C64/Amiga, but I was obsessed with old C64/ZX emulators growing up.
Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#17Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#18Re: Show HN: Building a web server in assembly to give my life (a lack of) meaning
#19An agentic LLM should be pretty good at Arm64 assembly generation, but maintainability of large code could become an issue. Why would it not run on Linux?