[Win32-SEH] Internal error 201201143 when dealing with managed locals in subroutine
Original Reporter info from Mantis: Stein2051 @Stein2051
-
Reporter name: Max Nazhalov
Original Reporter info from Mantis: Stein2051 @Stein2051
- Reporter name: Max Nazhalov
Description:
FPC build command [native-Win32]:
make OPT="-Xs -dTEST_WIN32_SEH -gl" INSTALL_PREFIX=%INST% clean all install
Sample program:
procedure ietest( var f: ansistring );
var
x: ansistring;
begin
x :='1234';
f := x;
end;
begin
end.
Sample program build command:
fpc -n -l -vewnhivp -FuD:\Prog\fpc\units\i386-win32\rtl -Cccdecl test3.pp
Sample build output:
Free Pascal Compiler version 3.1.1 [2016/05/28] for i386
Copyright (c) 1993-2016 by Florian Klaempfl and others
Target OS: Win32 for i386
Compiling test3.pp
test3.pp(4,1) Fatal: Internal error 201201143
$004FC4F2 GEN_LOAD_FRAME_FOR_EXCEPTFILTER, line 1932 of ncgutil.pas
$0051AC10 TCGX86__G_PROC_ENTRY, line 3047 of ./x86/cgx86.pas
$005285E1 THLCG2LL__G_PROC_ENTRY, line 978 of hlcg2ll.pas
$004FBA26 GEN_PROC_ENTRY_CODE, line 1415 of ncgutil.pas
$0050246B TCGPROCINFO__GENERATE_CODE, line 1628 of psub.pas
$0050169D TCGPROCINFO__GENERATE_EXCEPTFILTER, line 1161 of psub.pas
$00501609 TCGPROCINFO__GENERATE_CODE_TREE, line 1107 of psub.pas
$0050323A READ_PROC, line 2154 of psub.pas
$005036B3 READ_DECLARATIONS, line 2322 of psub.pas
Fatal: Compilation aborted
Error: D:\Prog\FPC\bin\i386-win32\ppc386.exe returned an error exitcode
Notes:
- FPC revision r33559 slightly modified for obtaining stack backtrace on IE: disabled {$ifdef EXTDEBUG} in .\src\compiler\comphook.pas::def_internalerror()
- ie201201143 triggered only via -Cccdecl command line option; declaring procedure as cdecl does not matter.
Steps to reproduce:
See attached archive for tree.log & fpcdebug.txt
Mantis conversion info:
- Mantis ID: 30205
- Build: r33559
- Platform: Win32
- Version: 3.1.1
- Fixed in version: 3.3.1
- Fixed in revision: 41277 (#b1ee29c8)
- Monitored by: » Cyrax (Cyrax)