[fpc-devel] FPC 2.2.2 on Linux/SPARC

Mark Morgan Lloyd markMLl.fpc-devel at telemetry.co.uk
Fri Sep 5 12:29:59 CEST 2008


Jonas Maebe wrote:
> On 03 Sep 2008, at 22:23, Jonas Maebe wrote:
> 
>> Yes, you did. Thanks. The bug is indeed in fillchar in generic.inc:
>>
>>      { Align on native pointer size }
>>      aligncount:=(PtrUInt(pdest) and (sizeof(PtrUInt)-1));
>>      dec(count,aligncount);
>>      pend:=pdest+aligncount;
>>
>> That make aligncount equal to the misalign count, rather than to the 
>> number of bytes necessary to align the pointer. It should rather be 
>> something like this:
>>
>>      pend:=align(pdest,sizeof(ptruint));
>>      dec(count,pend-pdest);
>>
>> I'll look at it tomorrow.
> 
> I've committed a fix in 2.3.1. If all goes well in the testsuite run 
> tonight, I'll merge it to 2.2.3 over the weekend. I don't know why this 
> bug didn't cause crashes in the nightly tests I run on sparc/solaris (I 
> have gotten other alignment crashes on this machine in the past).

Thanks Jonas, I'd missed the earlier comment which must have got lost by 
the spam filter. I'll keep an eye for 2.2.3 but if you want to kick me 
into life please note address below.

I really must find a way to put more time into this, but being able to 
produce a useful backtrace is a big step forwards- I'm more used to 
using a logic analyser for this sort of thing.

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]



More information about the fpc-devel mailing list