On 25/05/2021 18:08, Yuriy Sydorov via fpc-devel wrote:
> I've double checked this and the mode change seems to work fine.
> The source of the issue is that specifying -Mfpc enables inlining which
> triggers a bug in the Windows RTL.
> I've fixed the bug in r49400.
Thanks!
Jonas
On 24.05.2021 23:16, Jonas Maebe via fpc-devel wrote:
On 24/05/2021 12:18, Yuriy Sydorov via fpc-devel wrote:
You can't first pass the -Mdelphi switch and then override it with
-Mfpc. -Mdelphi implicitly enables lot of other compiler options which
are not reverted by -Mfpc.
That feels like a b
On 24/05/2021 12:18, Yuriy Sydorov via fpc-devel wrote:
> You can't first pass the -Mdelphi switch and then override it with
> -Mfpc. -Mdelphi implicitly enables lot of other compiler options which
> are not reverted by -Mfpc.
That feels like a bug.
Jonas
> Hello,
>
> You have not read closely what I wrote before:
Sorry, earlier I try your hint - and result was bad.
Perhaps I did something wrong.
But I repeat it now - and it is working. Thank you again.
Finally my working build script look like this:
set UNITS_PATH=.\packages\*
set UNITS_PATH=.\
Hello,
You have not read closely what I wrote before:
"When compiling RTL you should disable reading of options from fpc.cfg using
the -n switch.
When compiling the system unit use the -Us switch.
Additionally specify only CPU/Target and optimization options -O.
No other options are required fo
Unfortunately I tried it and this doesn't work.
Problem only with 'sysinitpas.pp' unit.
He is not depends on other RTL units, but linked into final executable by
compiler.
I suppose, compiler itself depends on internal layout of this unit.
And a solution is to compile 'sysinitpas.pp' with the same
Thank you, i will try this.
> I've take a look at you RTL compile script and found the mess with the
compiler options.
>
> When compiling RTL you should disable reading of options from fpc.cfg
using the -n switch.
> When compiling the system unit use the -Us switch.
> Additionally specify only CPU
Hello,
I've take a look at you RTL compile script and found the mess with the compiler
options.
When compiling RTL you should disable reading of options from fpc.cfg using the
-n switch.
When compiling the system unit use the -Us switch.
Additionally specify only CPU/Target and optimization op
RTL not modified. Just recompilation of 'sysinitpas.pp' unit with some
options causes problem.
Here is another test project that uses your current official FPC
installation with unmodified RTL:
http://dl.free.fr/ePtkQwgJJ
Test project contains source of 'sysinitpas.pp' (and required
'sysinit.inc'
Hello,
Your test program runs fine when compiled with FPC 3.2.0 using the official RTL
compiled with -O2. No memory leak.
I suppose the issue is caused by your modifications to RTL. -O2 (regvars) just triggers the problem in the modified RTL
code which is hidden when regvars are disabled.
You
You can simply compile this file by yourself using your existing FPC
installation.
1) Get 'rtl\win32\sysinitpas.pp' and 'rtl\win32\sysinit.inc' from
repository or sources archive.
2) Create build script ('compile.bat'):
REM Change this path's to your FPC installation, e.g.:
set FPC_DIR=c:\FPC
set
Hmmm, I've seen regvar problems before. Can you provide the assembly
dumps of that file under -O2 and -O2 -OoNOREGVAR respectively? It might
reveal something.
Gareth aka. Kit
On 20/05/2021 09:07, NetSpirit via fpc-devel wrote:
Answer for my previous message
(https://lists.freepascal.org/pipe
Answer for my previous message
(https://lists.freepascal.org/pipermail/fpc-devel/2021-January/043512.html).
Memory leak happens when unit 'rtl\win32\sysinitpas.pp' compiled with
"-O2" or higher.
To eliminate this bug add "-O-" or "-OoNOREGVAR" to command-line when
compile this unit. This disables
I am using custom build of minimal FPC RTL and found possible bug. When
unit 'system' (or some other?) compiled using -O2 (or higher) option in
'fpc.cfg', then application, compiled using this unit, increase memory
usage every time BeginThread() function is called.
This appears on FPC 3.2.0 and not
14 matches
Mail list logo