Hi Xianwen, On Tue, Oct 11, 2016 at 11:43:40PM +0200, Chen, Xianwen wrote: > I have been very impressed by the size of exe's that TCC produces in > Windows. For the simple hello_world.c, TCC produces an exe of 2 KB, while > mingw-w64 produces an exe of 164 KB. Therefore, I would like to continue to > learn to use TCC.
I'm pretty sure I've used MinGW to generate executables that small, although that was probably 16 years ago. Try to pass -s to GCC and don't use -g to get rid of symbol tables and debugging information. Most of the time TCC generates more code than GCC, especially when GCC is called with -Os. The linker of MinGW might enforce different section alignments than TCC. But that should add less than 10 kB of padding, regardless of the code size. Best regards, Daniel _______________________________________________ Tinycc-devel mailing list Tinycc-devel@nongnu.org https://lists.nongnu.org/mailman/listinfo/tinycc-devel