digitalmars.D - How to reduce executable size
- Anonymous (5/5) Jan 21 2005 Hi there,
- huang yicheng (4/9) Jan 21 2005 maybe use some tools like upx?:)
- =?ISO-8859-1?Q?Anders_F_Bj=F6rklund?= (9/16) Jan 21 2005 The main reason a C++ program is smaller is that it uses a
- Kris (3/8) Jan 21 2005 Yes; convince Walter to remove printf() from Object.d ... it drags along...
Hi there, Even the simplest D program "void main(){}" is compiled into 80+ kilobytes by dmd (win32) in release mode. Is there some way to reduce the code size? Thanks in advance.
Jan 21 2005
maybe use some tools like upx?:) Yicheng "Anonymous" <Anonymous_member pathlink.com> wrote in message news:csraoo$9q9$1 digitaldaemon.com...Hi there, Even the simplest D program "void main(){}" is compiled into 80+ kilobytes by dmd (win32) in release mode. Is there some way to reduce the code size? Thanks in advance.
Jan 21 2005
Anonymous wrote:Even the simplest D program "void main(){}" is compiled into 80+ kilobytes by dmd (win32) in release mode. Is there some way to reduce the code size?The main reason a C++ program is smaller is that it uses a dynamic run-time library. D uses a static "phobos" library. If C++ is compiled with a static runtime as well, I find the executables it generates to be a lot larger than the D ones ? But C is still a lot smaller. Not that 80 KB is anything... --anders PS. Here are my sizes:12K hello_c 368K hello_cpp 100K hello_d 4.0K hello.jarFor "Hello, World!"...
Jan 21 2005
In article <csraoo$9q9$1 digitaldaemon.com>, Anonymous says...Hi there, Even the simplest D program "void main(){}" is compiled into 80+ kilobytes by dmd (win32) in release mode. Is there some way to reduce the code size? Thanks in advance.Yes; convince Walter to remove printf() from Object.d ... it drags along all the floating point library support, just for jollies.
Jan 21 2005