Chris Smith wrote:
>[...HP-UX 10...]
>You can't use that -- the old OS cannot handle 64-bit addresses in system 
>calls -- but what's needed is 64-bit longs, not 64-bit pointers.
>
>There is no compile flag for that. But you can change the typedef of u64 
>to be 'long long' and change a bunch of constants and printf formats 
>to use LL instead of L.
Yes, the source code was written so that this could be done easily: in
previous ECDL challenges we did it to get 64-bit operations on Alphas
running VMS and WinNT.
The Irix binary that Thor Lancelot Simon built was also done this way.
The changes required to the 64-bit source are...
  Replace:  typedef unsigned long u64;
  With:     typedef unsigned long long u64;
  Globally replace UL<< by ULL<<.
  Globally replace lX by llX.  This is for format strings containing
  %011lX, %012lX and %016lX in function reportDistinguished().
  Replace %lu with %llu twice in this format string, also in function
  reportDistinguished():
    printf( "Iterations used = %lu.\n"
            "Total iterations = %lu.\n"
          , iters, total
          );
Then fire up your compiler and you're done.
Bye,
  Rob.
PS: You can run the 64-bit source on 32-bit machines with "long long"s
    this way, but it is slower than the 32-bit source.
PPS: You can also compile the 32-bit source out-of-the-box on 64-bit
     machines, but it is slower than the 64-bit source.
This archive was generated by hypermail 2b29 : Fri Feb 25 2000 - 10:02:53 MET