[gambit-list] How can built a small as 5 Kbytes "Hello World" program ?

Bradley Lucier lucier at math.purdue.edu
Mon Jan 19 22:20:04 EST 2015


On 01/19/2015 09:45 PM, Bradley Lucier wrote:
> On 01/19/2015 05:04 PM, Hendrik Boom wrote:
>> On Mon, 19 Jan 2015 15:28:19 +0900, Ryuho Yokoyama wrote:
>>
>>>
>>> This time the size of the "w.exe" is 136KB.  It's very small.
>> How can this possibly be considered "small" for such a trivial task, let
>> along *very* small?
>>
>> That's three times the entire RAM of the first machine I ran a HelloWorld
>> program on!
>>
>> I really wonder what is filling up all those K!
>
> On Ubuntu 14.10, with all updates:
>
>     firefly:~/programs/gambit/norvig-spell/gambit> cat hello.scm
>     (display "Hello World!\n")
>     firefly:~/programs/gambit/norvig-spell/gambit> gsc -exe hello
>     firefly:~/programs/gambit/norvig-spell/gambit> ll hello
>     -rwxrwxr-x 1 lucier lucier 10536 Jan 19 21:44 hello*
>     firefly:~/programs/gambit/norvig-spell/gambit> ./hello
>     Hello World!
>     firefly:~/programs/gambit/norvig-spell/gambit> gsc -v
>     \v4.7.3 20141017031152 x86_64-unknown-linux-gnu "./configure
>     '--enable-single-host' '--enable-shared'
>     '--enable-multiple-versions' '--enable-char-size=1'"
>
>
> Brad
I forgot:

    firefly:~/programs/gambit/norvig-spell/gambit> strip hello
    firefly:~/programs/gambit/norvig-spell/gambit> ll hello
    -rwxrwxr-x 1 lucier lucier 7352 Jan 19 22:18 hello*
    firefly:~/programs/gambit/norvig-spell/gambit> ./hello
    Hello World!


Brad
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.iro.umontreal.ca/pipermail/gambit-list/attachments/20150119/2dc5aec7/attachment.htm>


More information about the Gambit-list mailing list