Recent

Author Topic: EXEcutable sizes  (Read 16928 times)

6ar453v3n

  • New member
  • *
  • Posts: 8
Re: EXEcutable sizes
« Reply #30 on: July 04, 2014, 07:06:43 pm »
I just wanted to find out about program sizes.

I would have just stayed with Fortran and TP.

I used floppy disks as a reference.
Sombody just had to criticize floppies.

The size was given to me as 170kb with mention
of 25kb caused by a malfunctioning strip function.

Possibly there is a little language issue causing
mis-understanding but not a large amount.

The large RTL was cited as a big factor which
sounds about right.

There are bottom-to-top and top-to-bottom
solutions to this situation.

Dead code elimination is a top-to-bottom solution
that will not cause any compiler changes.

Remember remember that I am relying on you
people ton tell me about your system. I do not
have it installed nor have I read a manual. What
you people tell me will help me decide if I should
try out FP.

There has been a large effort to explain that
size isn't important. I don't sign up to this.
There is nothing wrong with selecting small
size software where the programmer made
the effort.

Replace my floppies with a large USB stick.
Not necessary if I pay attention to how I do
things.

And there is a lot of current day minimalistic
people and software out there.

How I feel is not wrong.

I will continue to monitor but likely I will
make no further posts/

67

FPK

  • Jr. Member
  • **
  • Posts: 59
Re: EXEcutable sizes
« Reply #31 on: July 04, 2014, 08:33:50 pm »
BP is 16-bit, 16-bit code is always tighter than 32-bit and of course there is the extender binary on top of that. TP also supported no exceptions, internationalization, translation, descriptive errormessages etc etc. All that is supported by the FPC RTL, also in the very core of it.

That is no excuse

Indeed, there is no excuse that you didn't provide any patches so far to improve the situation, if you really care about it. FPC is OSS. Go ahead.

Leledumbo

  • Hero Member
  • *****
  • Posts: 8111
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: EXEcutable sizes
« Reply #32 on: July 05, 2014, 08:19:09 am »
Code: [Select]
Z:\tmp>dir Project1.exe
  7/4/2014   5:48 PM        15,872  Project1.exe

Delphi 32-bit, no special compiler settings
Just to be fair: Standalone? Not linking dynamically to any .bpl? Recent Delphi (XE family, at least XE2)?

korba812

  • Full Member
  • ***
  • Posts: 106
Re: EXEcutable sizes
« Reply #33 on: July 05, 2014, 12:26:00 pm »
What about RTTI information? What is its size?

marcov

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 7501
Re: EXEcutable sizes
« Reply #34 on: July 05, 2014, 01:04:04 pm »
What about RTTI information? What is its size?

RTTI can be smartlinked out if the class is not referenced (because then it _could_ be constructed).

See also http://stackoverflow.com/questions/4519726/delphi-which-are-the-downsides-of-having-unused-units-listed-in-the-uses-clause/4519894#4519894

BeniBela

  • Hero Member
  • *****
  • Posts: 683
    • homepage
Re: EXEcutable sizes
« Reply #35 on: July 05, 2014, 11:33:06 pm »

Indeed, there is no excuse that you didn't provide any patches so far to improve the situation

How about getting astigmatism and therefore being not able to read at reasonable speed anymore as excuse?


Just to be fair: Standalone? Not linking dynamically to any .bpl?

Standalone, just linked to the Windows API



 Recent Delphi (XE family, at least XE2)?

Delphi 4.

The other versions failed to start in WINE, so I use Delphi 4 for all my Delphi projects.


Blaazen

  • Hero Member
  • *****
  • Posts: 2782
  • POKE 54296,15
    • Eye-Candy Controls
Re: EXEcutable sizes
« Reply #36 on: July 05, 2014, 11:48:29 pm »
Quote
The other versions failed to start in WINE, so I use Delphi 4 for all my Delphi projects.

Delphi 7 Personal Edition works well in Wine 1.7.16 .. 1.7.21
Lazarus 2.1.0 r61214:62238 FPC 3.3.1 r40507 x86_64-linux-qt Chakra, Qt 4.8.7/5.13.2, Plasma 5.17.3
Lazarus 1.8.2 r57369 FPC 3.0.4 i386-win32-win32/win64 Wine 3.21

Try Eye-Candy Controls: https://sourceforge.net/projects/eccontrols/files/

BeniBela

  • Hero Member
  • *****
  • Posts: 683
    • homepage
Re: EXEcutable sizes
« Reply #37 on: July 06, 2014, 12:05:22 am »
Delphi 7 Personal Edition

But I probably do not have Delphi 7.

I only remember having D1, D3, D4, and XE                             

Wine 1.7.16 .. 1.7.21

But I only have Wine 1.6.2

Leledumbo

  • Hero Member
  • *****
  • Posts: 8111
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: EXEcutable sizes
« Reply #38 on: July 06, 2014, 12:46:02 am »
Standalone, just linked to the Windows API
Can you confirm by running on a system without Delphi installed? Or at least with dependency walker? Because AFAIR, 15K Delphi (7?) program is the result of linking it with rtl100.bpl.
Delphi 4.

The other versions failed to start in WINE, so I use Delphi 4 for all my Delphi projects.
That's an unfair comparison then. Delphi 7 and below isn't multiplatform in anyway, they don't have platform independent layer. If you manage to compare with Delphi XE and above, now that's fair since at least there's another platform to support, and on different architecture. I believe EC is not stupid enough to maintain different source code for each platform and therefore will use the similar architecture as FPC does.

BeniBela

  • Hero Member
  • *****
  • Posts: 683
    • homepage
Re: EXEcutable sizes
« Reply #39 on: July 06, 2014, 01:11:48 am »
Can you confirm by running on a system without Delphi installed? Or at least with dependency walker? Because AFAIR, 15K Delphi (7?) program is the result of linking it with rtl100.bpl.

I do not really have Delphi installed. I do not even know where the installation cd is

I just copy the entire Delphi directory from computer to computer

There does not even  exist a rtl100.bpl anywhere

I grepped the file for bpl and there was nothing

That's an unfair comparison then. Delphi 7 and below isn't multiplatform in anyway, they don't have platform independent layer. If you manage to compare with Delphi XE and above, now that's fair since at least there's another platform to support, and on different architecture.

Stable FPC seems to be more similar to D4 than to XE. XE has all the new unicode strings

Leledumbo

  • Hero Member
  • *****
  • Posts: 8111
  • Programming + Glam Metal + Tae Kwon Do = Me
Re: EXEcutable sizes
« Reply #40 on: July 06, 2014, 02:17:24 am »
I do not really have Delphi installed. I do not even know where the installation cd is

I just copy the entire Delphi directory from computer to computer

There does not even  exist a rtl100.bpl anywhere

I grepped the file for bpl and there was nothing
A screenshot of dependency walker will be the possible proof
Stable FPC seems to be more similar to D4 than to XE. XE has all the new unicode strings
Unicode strings don't contribute to the size as much as platform independent layer does. And no, Delphi 4 is waaaay different from current FPC.

BeniBela

  • Hero Member
  • *****
  • Posts: 683
    • homepage
Re: EXEcutable sizes
« Reply #41 on: July 06, 2014, 08:23:46 pm »

A screenshot of dependency walker will be the possible proof

If you say so...


And no, Delphi 4 is waaaay different from current FPC.

Well, then it is better (except for  the missing c style operators and no exit(..))

And fpc really needs to catch up to that 15 year old software...
« Last Edit: July 06, 2014, 08:27:30 pm by BeniBela »

FPK

  • Jr. Member
  • **
  • Posts: 59
Re: EXEcutable sizes
« Reply #42 on: July 06, 2014, 09:33:42 pm »
And fpc really needs to catch up to that 15 year old software...

Upgrading to the newest fastmove code is still on my todo list so we will get ahead another x kB of 15 years old software.

skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2280
    • havefunsoft.com
Re: EXEcutable sizes
« Reply #43 on: July 07, 2014, 04:37:03 am »
so, here's "hello world"-RTL. The RTL that does nothing but "hello world" program and it's win32 only.

Compiled hello world project (test.pas) - the final executable size: 3072 bytes. (I guess, that's PE format limit here. And a bunch of empty space still available in the executable).

anyone to beat this size with TP or Delphi 4 ?  :D
« Last Edit: July 07, 2014, 03:35:18 pm by skalogryz »
Patron Cocoa Widgetset development https://www.patreon.com/skalogryz