[fpc-pascal] What's in Hello World

tsiegel at softcon.com tsiegel at softcon.com
Sun Jan 7 16:09:25 CET 2024


On 1/7/2024 1:09 PM, Florian Klämpfl via fpc-pascal wrote:
>
>
>> Am 07.01.2024 um 13:21 schrieb Ingemar Ragnemalm via fpc-pascal 
>> <fpc-pascal at lists.freepascal.org>:
>>
>> Just for comparison, I fired up Think Pascal and made Hello world!
>>
>> Plain Hello world, closes so quickly that you don't have time to see 
>> it: 4625 bytes.
>>
>> Including ShowText and while not Button do; 4639 bytes.
>>
>> Yes, less than 5k! Progress?
>>
> https://github.com/chainq/amiga-tiny-hello-p
>
> 244 bytes with FPC.
>
> Not that it's 100 percent relevant, but I always use powerbasic 
> (https://www.powerbasic.com) when it's a matter of size, since 
> powerbasic and it's console compiler produces a hello world program of 
> just 7,168 bytes which is still a windows executable, and works on 
> just about any version of windows.

I've never found any windows compiler that produces smaller executables 
by default.

Even their powerbasic windows compilers do an admirable job of keeping 
the executable sizes down to amazing numbers.

I have an epub reader I've been working off and on for the last couple 
years, and even with a complete gui and significant functionality, my 
epub reader clocks in at a whooping 75,776 bytes.

I've never gotten such results from any other windows compiler, and 
indeed, a great deal of linux compilers can't match that.

Of course, I *always* use FPC when a I need the program on multiple 
platforms, though I do tend to use java when I need a gui on multiple 
platforms, as I can just throw up the grid format, then not have to 
worry about how the gui looks, which is great for me, because it's 
either that, or have a sighted individual pour over the gui with me 
until I get it right.  It's just easier to use grid mode on java. :)

For what it's worth though, generally, I find FPC to be considerably 
better than anything cross platform except of course for GCC.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20240107/310d4fce/attachment.htm>


More information about the fpc-pascal mailing list