View Issue Details

IDProjectCategoryView StatusLast Update
0037527FPCCompilerpublic2020-09-13 22:07
Reporteravk Assigned To 
Status newResolutionopen 
Product Version3.3.1 
Summary0037527: X86_64 code optimization
DescriptionIn some cases, when using optimization level 2 and above, FPC generates a completely inoperable code (seemingly starting with revision 45801). Unfortunately, I have no other example besides the one attached.
TagsNo tags attached.
Fixed in Revision
Attached Files



2020-08-09 13:53

reporter (4,761 bytes)

J. Gareth Moreton

2020-08-09 14:01

developer   ~0124692

What do you mean by 'inoperable' exactly? Does it not run at all or is it dead code etc?


2020-08-09 14:32

reporter   ~0124693

It crashes with AV.

J. Gareth Moreton

2020-08-09 19:35

developer   ~0124704

I'd take a look myself, but my Intel laptop is out of commission until further notice. However, if you can help me a bit, can you add the custom options "-a" and "-al" and supply the generated .s file (assembly dump), and mark where it crashes in your code (Just a line number in the Pascal source will do), I might be able to spot something and help someone else to make a fix... if they haven't found the problem already!


2020-08-10 09:13

reporter   ~0124711

Yes, sure.
According to the debugger, the AV occurs on line 361 of the timsort unit. (15,715 bytes)


2020-09-10 12:25

reporter   ~0125459

Any news?

J. Gareth Moreton

2020-09-13 22:07

developer   ~0125531

My apologies for the delay - my time has been recently focused on a programming contract and also on some events outside of software development. I'll start looking at it soon.

Issue History

Date Modified Username Field Change
2020-08-09 13:53 avk New Issue
2020-08-09 13:53 avk File Added:
2020-08-09 14:01 J. Gareth Moreton Note Added: 0124692
2020-08-09 14:32 avk Note Added: 0124693
2020-08-09 19:31 J. Gareth Moreton Priority normal => high
2020-08-09 19:31 J. Gareth Moreton Severity minor => crash
2020-08-09 19:31 J. Gareth Moreton Platform x84_64 => x86_64
2020-08-09 19:31 J. Gareth Moreton FPCTarget => -
2020-08-09 19:35 J. Gareth Moreton Note Added: 0124704
2020-08-10 09:13 avk Note Added: 0124711
2020-08-10 09:13 avk File Added:
2020-09-10 12:25 avk Note Added: 0125459
2020-09-13 22:07 J. Gareth Moreton Note Added: 0125531