[Lazarus] FPC on Rpi3 executable module sizes
Ken Kashmarek
kashken at csteldridge.com
Sun Oct 30 18:32:03 CET 2016
FCP on Rapsberry Pi3
On my Window 7 node, a null program produces this output when compiled from
the command line:
10/30/2016 11:36 AM 31,744 nullpgm.exe
10/30/2016 11:36 AM 3,141 nullpgm.o
10/30/2016 09:19 AM 574 nullpgm.pas
When the Build menu item is selected under Lazurus on RPi3:
-rwxr-xr-x 1 pi pi 200548 Oct 30 09:19 nullpgm
-rw-r--r-- 1 pi pi 3356 Oct 30 09:19 nullpgm.o
-rw-rw---- 1 pi pi 574 Oct 30 09:19 nullpgm.pas
While the object code generated (nullpgm.o) is relatively the same, the
executable is out of sight on the RPi3. What is being included here?
When one uses item (uses sysutils;) is added, the Window 7 executable goes
up to over 80K in size.
On the RPi3, goes up to over 400K in size. If 3 items are in the uses line,
the RPi3 executable exceeds 800K.
This is clearly an error where each addition adds 200k (or more) the the
executable file. I do note however, that all 3 uses entries on Windows 7,
brings the executable up to more than 240K (significantly smaller than the
RPi3 install of FCP produces).
Here is the program listing:
program nullpgm(input,output);
{$SMARTLINK ON}
{$DEBUGINFO OFF}
uses sysutils; // , variants, classes;
type ptr2Byte = ^Byte;
comp = int64;
var i,j: integer;
begin
writeln;
i := 4096;
writeln('Value of i = ',i:8);
writeln('--> Execution of (nearly) null program ended.');
writeln;
end.
--
View this message in context: http://free-pascal-lazarus.989080.n3.nabble.com/FPC-on-Rpi3-executable-module-sizes-tp4050126p4050129.html
Sent from the Free Pascal - Lazarus mailing list archive at Nabble.com.
More information about the Lazarus
mailing list