On 12/10/11 9:39 AM, Bane wrote:
Short term and long term suggestions ? Anything we can do ? I heard it
is some problem with linking dead code?
import std.stdio;
int main(){
writefln("Hello Bloat!");
return 0;
}
dmd -release -O hello.d
On Windows:
v1.071 = 339 Kb
v2.056 = 1017 Kb
It looks very ugly and might distract some people.
In fact there was a low-hanging fruit, and I'm sure there are some more.
This diff reduces the size of hello, world (compiled with -O -release
-inline and after strip) from 700KB to 220 KB:
https://github.com/D-Programming-Language/phobos/commit/b7f42ec925fb1d64564d48ea419e201bfc65ed53
Right now an executable starts at around 218KB, which includes druntime
(gc, type info, the works). Importing std.stdio and using writeln() only
adds a couple of KBs.
Andrei