pcp
[Top] [All Lists]

Re: Solaris port assistance

To: "Corey Cole" <ccole@xxxxxxxxxxxxx>
Subject: Re: Solaris port assistance
From: Max Matveev <makc@xxxxxxx>
Date: Wed, 27 Feb 2002 18:51:12 +1100
Cc: "SGI-PCP" <pcp@xxxxxxxxxxx>
In-reply-to: <PKEIIJJECCEFJOCMCHABOECACAAA.ccole@xxxxxxxxxxxxx>
References: <PKEIIJJECCEFJOCMCHABOECACAAA.ccole@xxxxxxxxxxxxx>
Sender: owner-pcp@xxxxxxxxxxx
>>>>> "CC" == Corey Cole <ccole@xxxxxxxxxxxxx> writes:

 CC> For example, I'll fetch disk.all.write (a fairly static value on
 CC> the target machine).  I get 1261 (4ED) on the linux box, but
 CC> 17078775686895763456 (ED04000000000000) on the Solaris machine.
Welcome to the endianess hell - you might want to write your own
__htonll and __htonf routines to make sure that stuff you put of the wire
and stuff you read from the wire matches internal Solaris
represenation.

Start with stuffing a value like 0x123456789ABCDEF0 into Solaris long
long and print using %llx or some other solaris incation for long long
prints. Repeat on Linux, figure out the differences and write
routines.

max

<Prev in Thread] Current Thread [Next in Thread>