Ok, I committed some mild linker crimes and got the same program down to 800 bytes.
rustc hello.rs -C panic=abort -C opt-level=3 -C link-args="/ENTRY:main /DEBUG:NONE /EMITPOGOPHASEINFO /EMITTOOLVERSIONINFO:NO /ALIGN:16"
Re:Hello World
by archargelod on Tuesday April 09, 2024 @12:26AM
(#39976189)
Cool. That reminded me of this blog post[0], with Hello World Nim binary in just 150 bytes!
Re:Hello World
by themoonisachees on Tuesday April 09, 2024 @04:37AM
(#39977344)
Don't x64 binaries have to be 4k-aligned or something like that? I remember a video about runnable qr codes where this was a major point because they had to do trickery to make windows run binaries that were less than that.
It may be worth noting that the associated pdb (aka debug database) is 208,896 bytes.