gpsd-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [gpsd-dev] Half the port problems are solved; seeking help with RTCM


From: Eric S. Raymond
Subject: Re: [gpsd-dev] Half the port problems are solved; seeking help with RTCM2 driver
Date: Wed, 25 Apr 2012 07:48:03 -0400
User-agent: Mutt/1.5.21 (2010-09-15)

Bernd Zeimetz <address@hidden>:
> > I agree.  Can you think of a way to test for [ptys] from a shellscript?
> 
> Only something like calling a few lines of Python code...

Yes, I'll probably have to do that.  Ugh.

> > Yes, as I said I'm pretty sure this is down to #pragma pack(1) not being
> > implemented on those machines.
> 
> I'm kinda sure it is implemented, but my guess would be that you hit the
> architectures where aligned access is required for some datatypes.

That's more or less what I mean.  #pragma pack(1) *can't* be implemented
on a machine with aligned-access requirements - well, not without going
to code-generation lengths that most compilers won't, anyway.

> Unaligned access usually throws a sigbus on sparc, but my wild guess is
> that you work around that somehow...

I've done no workaround.  The code generator for SPARC must just be
Doing The Right Thing - copying each unaligned member to an aligned
location before trying to interpret it.

>                                That should at least show where the
> issue resides, but I doubt it is easily fixable without rewriting the
> whole thing into something that splits buf into pieces and fills sane
> (sane as in: ensure there is no unaligned access, do not use #pragma
> pack...) structs manually (actually, looking at the code I think that
> would be easy to do, just a lengthy amount of work).

Yes, I've already discussed this with Gary.  I'm too close to the code;
he's going to take a whack at it when he gets back from the Caymans.
-- 
                <a href="http://www.catb.org/~esr/";>Eric S. Raymond</a>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]