SUMMARY: [TRU64] Endian-ness of Alpha

From: Nikola Milutinovic (Nikola.Milutinovic@ev.co.yu)
Date: Tue Oct 19 2004 - 03:15:30 EDT


J.A. Gutierrez wrote:
> On Tue, Oct 19, 2004 at 08:01:22AM +0200, Nikola Milutinovic wrote:
>
>>Hi all.
>>
>>One quck question: Is Alpha Big or Little Endian machine?
>
> little endian

As I suspected..

>>I tested it a bit and found out that compiler, on it's own believes the
>>Alpha to be Big Endian.
>
> are you sure?

This is the test.c:

#if BYTE_ORDER != BIG_ENDIAN
# error It is not big endian
#endif

#if BYTE_ORDER == BIG_ENDIAN
# error It is big endian
#endif

#include <sys/types.h>
#include <sys/param.h>
int
main ()
{

#if BYTE_ORDER != BIG_ENDIAN
   not big endian;
#endif
#if BYTE_ORDER == BIG_ENDIAN
   is big endian;
#endif

#if BYTE_ORDER != BIG_ENDIAN
# error It is not big endian - AFTER
#endif

#if BYTE_ORDER == BIG_ENDIAN
# error It is big endian - AFTER
#endif
   return 0;
}

cc: Error: test.c, line 8: #error It is big endian
#error It is big endian
-^
cc: Error: test.c, line 20: In this declaration, "not" must specify a type.
   not big endian;
--^
cc: Error: test.c, line 27: #error It is not big endian - AFTER
#error It is not big endian - AFTER

In any case, endian-ness is OK in Heimdal, then. I'll package it and
wait for a reply from Heimdal bugs.

Nix.



This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 10:50:10 EDT