[OpenAFS-devel] 1.3.79 on AIX 5.2, system dump when using token
chas williams - CONTRACTOR
chas@cmf.nrl.navy.mil
Fri, 25 Feb 2005 09:40:23 -0500
In message <421F30BA.9020407@rzg.mpg.de>,Hartmut Reuter writes:
>1) klog does not work unless you compiled it without -O (I think
>specially the des libraries, but better if you do it for all). This is
>obviously a bug of the IBM compiler.
can you try this patch? it seems this bit is often managed by
optimizers.
Index: src/rxkad/domestic/fcrypt.c
===================================================================
RCS file: /cvs/openafs/src/rxkad/domestic/fcrypt.c,v
retrieving revision 1.14
diff -u -u -r1.14 fcrypt.c
--- src/rxkad/domestic/fcrypt.c 13 Oct 2004 01:28:27 -0000 1.14
+++ src/rxkad/domestic/fcrypt.c 25 Feb 2005 14:37:30 -0000
@@ -114,9 +114,9 @@
fc_KeySchedule schedule, int encrypt)
{
afs_uint32 L, R;
- afs_uint32 S, P;
- unsigned char *Pchar = (unsigned char *)&P;
- unsigned char *Schar = (unsigned char *)&S;
+ volatile afs_uint32 S, P;
+ volatile unsigned char *Pchar = (unsigned char *)&P;
+ volatile unsigned char *Schar = (unsigned char *)&S;
int i;
#if defined(vax) || (defined(mips) && defined(MIPSEL)) || defined(AFSLITTLE_ENDIAN)
Index: src/des/des.c
===================================================================
RCS file: /cvs/openafs/src/des/des.c,v
retrieving revision 1.16
diff -u -u -r1.16 des.c
--- src/des/des.c 16 Oct 2004 22:41:18 -0000 1.16
+++ src/des/des.c 25 Feb 2005 14:37:30 -0000
@@ -96,7 +96,7 @@
#endif
#endif
afs_uint32 P_temp;
- register unsigned char *P_temp_p = (unsigned char *)&P_temp;
+ volatile unsigned char *P_temp_p = (unsigned char *)&P_temp;
#ifdef BITS16
sbox_out S_out;
afs_uint32 *S_out_p = (afs_uint32 *) & S_out;