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
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
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
Hi,
I'm interested in implement a Pascal JIT linker so I implement a COFF 64bit
linker and link object files generated by FPC trunk then link them with DLL
dependencies like "kernel32.dll" and "user32.dll".
Project source code is available at https://github.com/tihorygit/TheLinker.
Now I hav
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
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,
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
Looking through some code in unit TypInfo
in relation to https://bugs.freepascal.org/view.php?id=38915
RTTI for a set, only specifies the size in bytes. (TTypeDate.SetSize)
GetSetProp / SetToString
iterate over all bits on the given byte size.
Since in many cases this is more than the actual amou
On 20/05/2021 19:00, Martin Frb via fpc-devel wrote:
I would therefore expect (target depended) that "u8inttype" may be
aligned?
Sorry, forget that part of my previous post.
I somehow got to u8 => 8byte => qword, instead of 8bit => Byte
___
fpc