[Lazarus] IDE invocation of lhelp, probable endianness issue
Mark Morgan Lloyd
markMLl.lazarus at telemetry.co.uk
Mon Aug 27 09:46:25 CEST 2012
Marco van de Voort wrote:
> On Wed, Aug 22, 2012 at 02:35:47PM +0200, Sven Barth wrote:
>>>> Running lhelp from a shell using gdb gives me
>>>>
>>>> Program received signal SIGBUS, Bus error.
>>>> [Switching to Thread 16384 (LWP 25970)]
>>>> 0x0038c844 in _$CHMREADER$_Ll594 () at src/chmreader.pas:1144
>>>> 1144 ind:=LEToN(plongint(head)^);
>>> I'm not familiar with the chmreader code.
>>> Please create a bug report.
>> At least it's a pointer dereference... so there must indeed be some
>> misalignment going on...
>
> I think a lot of internal records are read that way. Arbitrary pointers are
> pointed to records in buffers (decompressed datastructures), and then
> iterated like this.
>
> So there might be hundreds of such cases. Afaik alignment is hardly tested,
> and endianess only quick.
I'm happy to help with the testing of this on SPARC and PPC, even if my
ability to fix it is limited due to lack of familiarity with the guts.
--
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 Lazarus
mailing list