Mercurial > hg > CbC > old > device
view test/bitfield.c @ 342:3e0b1183983d
else if to switch
author | kono |
---|---|
date | Sat, 26 Jun 2004 12:35:35 +0900 |
parents | 7fe7ce0a791f |
children | 5ac17fa9d7e0 |
line wrap: on
line source
typedef union { struct _PTE { unsigned long v:1; unsigned long vsid:24; unsigned long h:1; unsigned long api:6; unsigned long rpn:20; unsigned long :3; unsigned long r:1; unsigned long c:1; unsigned long w:1; unsigned long i:1; unsigned long m:1; unsigned long g:1; unsigned long :1; unsigned long pp:2; long long lpn:40; } pte; struct { unsigned char v:1; signed long vsid:24; unsigned long h:1; signed char api:6; signed long rpn:20; signed long :3; unsigned long r:1; unsigned long c:1; unsigned long w:1; unsigned long i:1; unsigned long m:1; unsigned long g:1; unsigned long :1; signed long pp:2; } sg; unsigned long u[2]; } PTE; PTE g; main() { PTE a,*p; int i = 0; int j = 0; a.pte.rpn = 55; j = a.pte.rpn; printf("% 3d: %d\n",i++,j); a.pte.c = 1; j = a.pte.c; printf("% 3d: %d\n",i++,j); a.pte.pp = -1; j = a.pte.pp; printf("% 3d: %d\n",i++,j); a.sg.pp = -1; j = a.sg.pp; printf("% 3d: %d\n",i++,j); p = &g; g.u[0]=0; g.u[1]=0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. v = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. vsid = -1; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. h = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. api = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. rpn = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. r = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. c = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. w = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. i = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. m = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. g = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. pp = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.u[0]=-1; g.u[1]=-1; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. v = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. vsid = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. h = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. api = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. rpn = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. r = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. c = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. w = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. i = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. m = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. g = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. pp = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.u[0]=-1; g.u[1]=-1; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. v = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. vsid = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. h = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. api = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. rpn = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. r = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. c = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. w = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. i = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. m = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. g = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. pp = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.u[0]=-1; g.u[1]=-1; for(i=0;i<0x200;i++) { printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. v = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. vsid = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. h = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. api = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. rpn = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. r = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. c = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. w = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. i = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. m = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. g = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.pte. pp = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); } g = a; printf("%d %d %d\n",a.pte.pp,g.pte.pp,p->pte.pp); main2(); main5(); main3(); main4(); return 0; } main2() { int i = 0; g.u[0]=0; g.u[1]=0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. v = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. vsid = -1; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. h = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. api = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. rpn = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. r = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. c = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. w = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. i = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. m = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. g = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. pp = 3; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.u[0]=-1; g.u[1]=-1; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. v = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. vsid = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. h = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. api = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. rpn = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. r = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. c = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. w = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. i = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. m = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. g = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. pp = 0; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.u[0]=-1; g.u[1]=-1; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. v = 0x55; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. vsid = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. h = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. api = 0x55; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. rpn = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. r = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. c = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. w = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. i = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. m = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. g = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. pp = 0x5555555; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.u[0]=-1; g.u[1]=-1; for(i=-0x100;i<0x100;i++) { printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. v = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. vsid = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. h = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. api = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. rpn = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. r = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. c = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. w = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. i = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. m = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. g = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); g.sg. pp = i; printf("% 3d: 0x%08x%08x\n",i++,g.u[0],g.u[1]); } // printf("size of %d\n",sizeof(g.sg.pp)); no size of for bit-field } // int :12 bit-field cannot be a return value; // main3( int a:8 ) bit-field cannot be an argument; main3( int a ) { // int b:9; // nor local variable int b,i; i = 7; b = g.pte.rpn = -333; printf("main3-0: %d\n",b); b = g.pte.rpn--; printf("main3-1: %d\n",b); b = g.pte.rpn++; printf("main3-2: %d\n",b); b = --g.pte.rpn; printf("main3-3: %d\n",b); b = ++g.pte.rpn; printf("main3-4: %d\n",b); b = (g.pte.rpn += 3); printf("main3-5: %d\n",b); b = (g.pte.rpn -= 3); printf("main3-6: %d\n",b); b = (g.pte.rpn *= 3); printf("main3-7: %d\n",b); b = (g.pte.rpn /= 3); printf("main3-8: %d\n",b); b = (g.pte.rpn %= 3); printf("main3-9: %d\n",b); b = (g.pte.rpn |= 3); printf("main3-10: %d\n",b); b = (g.pte.rpn &= 3); printf("main3-12: %d\n",b); b = (g.pte.rpn ^= 3); printf("main3-13: %d\n",b); b = (g.pte.rpn <<= 3); printf("main3-14: %d\n",b); b = (g.pte.rpn >>= 3); printf("main3-15: %d\n",b); g.pte.rpn = -333; printf("main3-16: %d\n",b); b = g.pte.rpn--; printf("main3-17: %d\n",b); b = g.pte.rpn++; printf("main3-18: %d\n",b); b = --g.pte.rpn; printf("main3-19: %d\n",b); b = ++g.pte.rpn; printf("main3-20: %d\n",b); b = (g.pte.rpn += i); printf("main3-21: %d\n",b); b = (g.pte.rpn -= i); printf("main3-22: %d\n",b); b = (g.pte.rpn *= i); printf("main3-23: %d\n",b); b = (g.pte.rpn /= i); printf("main3-24: %d\n",b); b = (g.pte.rpn %= i); printf("main3-25: %d\n",b); b = (g.pte.rpn |= i); printf("main3-26: %d\n",b); b = (g.pte.rpn &= i); printf("main3-27: %d\n",b); b = (g.pte.rpn ^= i); printf("main3-28: %d\n",b); b = (g.pte.rpn <<= i); printf("main3-29: %d\n",b); b = (g.pte.rpn >>= i); printf("main3-30: %d\n",b); return --b; } main4( int a ) { // int b:9; // nor local variable int b,i; PTE *pg = &g; i = 7; pg->pte.rpn = -333; printf("main4-0: %d\n",b); b = pg->pte.rpn--; printf("main4-1: %d\n",b); b = pg->pte.rpn++; printf("main4-2: %d\n",b); b = --pg->pte.rpn; printf("main4-3: %d\n",b); b = ++pg->pte.rpn; printf("main4-4: %d\n",b); b = (pg->pte.rpn += 3); printf("main4-5: %d\n",b); b = (pg->pte.rpn -= 3); printf("main4-6: %d\n",b); b = (pg->pte.rpn *= 3); printf("main4-7: %d\n",b); b = (pg->pte.rpn /= 3); printf("main4-8: %d\n",b); b = (pg->pte.rpn %= 3); printf("main4-9: %d\n",b); b = (pg->pte.rpn |= 3); printf("main4-10: %d\n",b); b = (pg->pte.rpn &= 3); printf("main4-12: %d\n",b); b = (pg->pte.rpn ^= 3); printf("main4-13: %d\n",b); b = (pg->pte.rpn <<= 3); printf("main4-14: %d\n",b); b = (pg->pte.rpn >>= 3); printf("main4-15: %d\n",b); pg->pte.rpn = -333; printf("main4-16: %d\n",b); b = pg->pte.rpn--; printf("main4-17: %d\n",b); b = pg->pte.rpn++; printf("main4-18: %d\n",b); b = --pg->pte.rpn; printf("main4-19: %d\n",b); b = ++pg->pte.rpn; printf("main4-20: %d\n",b); b = (pg->pte.rpn += i); printf("main4-21: %d\n",b); b = (pg->pte.rpn -= i); printf("main4-22: %d\n",b); b = (pg->pte.rpn *= i); printf("main4-23: %d\n",b); b = (pg->pte.rpn /= i); printf("main4-24: %d\n",b); b = (pg->pte.rpn %= i); printf("main4-25: %d\n",b); b = (pg->pte.rpn |= i); printf("main4-26: %d\n",b); b = (pg->pte.rpn &= i); printf("main4-27: %d\n",b); b = (pg->pte.rpn ^= i); printf("main4-28: %d\n",b); b = (pg->pte.rpn <<= i); printf("main4-29: %d\n",b); b = (pg->pte.rpn >>= i); printf("main4-30: %d\n",b); return --b; } union ll1 { int a[8]; struct { char a:4; long long v:33; long long w:33; long long x:33; } b; } ll1; union ll0 { int a[8]; struct { char a:4; long long v:48; long long w:48; long long x:48; } b; } ll0; union ll { int a[8]; struct { char a:4; long long v:56; long long w:56; long long x:56; } b; } ll; union cc { int a; struct { char a:1; char b:4; char c:7; char d:4; char e:4; char f:4; } b; } cc; union ii { int a; struct { int a:1; int b:4; int c:4; int d:4; int e:4; int f:4; } b; } ii; int m1 = -1; int p1 = 1; int zero = 0; main5() { ii.b.a = -1; printf("00:%d\n",ii.b.a); ll1.b.v = m1; printf("01:%llx\n",ll1.b.v); printf("02:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll1.a[0],ll1.a[1],ll1.a[2],ll1.a[3], ll1.a[4],ll1.a[5],ll1.a[6],ll1.a[7] ); ll1.b.v = zero; ll1.b.w = m1; printf("02:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll1.a[0],ll1.a[1],ll1.a[2],ll1.a[3], ll1.a[4],ll1.a[5],ll1.a[6],ll1.a[7] ); ll1.b.w = zero; ll1.b.x = m1; printf("02:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll1.a[0],ll1.a[1],ll1.a[2],ll1.a[3], ll1.a[4],ll1.a[5],ll1.a[6],ll1.a[7] ); ll0.b.v = m1; printf("01:%llx\n",ll0.b.v); printf("02:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll0.a[0],ll0.a[1],ll0.a[2],ll0.a[3], ll0.a[4],ll0.a[5],ll0.a[6],ll0.a[7] ); ll0.b.v = zero; ll0.b.w = m1; printf("02:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll0.a[0],ll0.a[1],ll0.a[2],ll0.a[3], ll0.a[4],ll0.a[5],ll0.a[6],ll0.a[7] ); ll0.b.w = zero; ll0.b.x = m1; printf("02:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll0.a[0],ll0.a[1],ll0.a[2],ll0.a[3], ll0.a[4],ll0.a[5],ll0.a[6],ll0.a[7] ); ll.b.v = m1; printf("1:%llx\n",ll.b.v); printf("2:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll.a[0],ll.a[1],ll.a[2],ll.a[3], ll.a[4],ll.a[5],ll.a[6],ll.a[7] ); ll.b.v = zero; ll.b.w = m1; printf("2:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll.a[0],ll.a[1],ll.a[2],ll.a[3], ll.a[4],ll.a[5],ll.a[6],ll.a[7] ); ll.b.w = zero; ll.b.x = m1; printf("2:%08x %08x %08x %08x %08x %08x %08x %08x\n", ll.a[0],ll.a[1],ll.a[2],ll.a[3], ll.a[4],ll.a[5],ll.a[6],ll.a[7] ); printf("char a:1; char b:4; char c:7; char d:4; char e:4; char f:4;\n"); cc.b.a = m1; printf("a:%08x\n",cc.a); cc.b.b = m1; printf("b:%08x\n",cc.a); cc.b.c = m1; printf("c:%08x\n",cc.a); cc.b.d = m1; printf("d:%08x\n",cc.a); cc.b.e = m1; printf("e:%08x\n",cc.a); cc.b.f = m1; printf("f:%08x\n",cc.a); printf("3:%d %d\n",cc.b.c,cc.b.d); cc.a = m1; printf("f:%08x\n",cc.a); cc.b.a = zero; printf("a:%08x\n",cc.a); cc.b.b = zero; printf("b:%08x\n",cc.a); cc.b.c = zero; printf("c:%08x\n",cc.a); cc.b.d = zero; printf("d:%08x\n",cc.a); cc.b.e = zero; printf("e:%08x\n",cc.a); cc.b.f = zero; printf("f:%08x\n",cc.a); printf("3:%d %d\n",cc.b.c,cc.b.d); cc.a = zero; printf("f:%08x\n",cc.a); cc.b.a = p1; printf("a:%08x\n",cc.a); cc.b.b = p1; printf("b:%08x\n",cc.a); cc.b.c = p1; printf("c:%08x\n",cc.a); cc.b.d = p1; printf("d:%08x\n",cc.a); cc.b.e = p1; printf("e:%08x\n",cc.a); cc.b.f = p1; printf("f:%08x\n",cc.a); printf("3:%d %d\n",cc.b.c,cc.b.d); cc.a = m1; printf("f:%08x\n",cc.a); cc.b.a = p1; printf("a:%08x\n",cc.a); cc.b.b = p1; printf("b:%08x\n",cc.a); cc.b.c = p1; printf("c:%08x\n",cc.a); cc.b.d = p1; printf("d:%08x\n",cc.a); cc.b.e = p1; printf("e:%08x\n",cc.a); cc.b.f = p1; printf("f:%08x\n",cc.a); printf("3:%d %d\n",cc.b.c,cc.b.d); ii.b.a = m1; printf("6:%08x\n",ii.a); ii.b.d = m1; printf("6:%08x\n",ii.a); printf("5:%d %d\n",ii.b.a,ii.b.d); } main3l( int a ) { // int b:9; // nor local variable long long b,i; i = 7; g.pte.lpn = -333; printf("main3l-0: %d\n",b); b = g.pte.lpn--; printf("main3l-1: %d\n",b); b = g.pte.lpn++; printf("main3l-2: %d\n",b); b = --g.pte.lpn; printf("main3l-3: %d\n",b); b = ++g.pte.lpn; printf("main3l-4: %d\n",b); b = (g.pte.lpn += 3); printf("main3l-5: %d\n",b); b = (g.pte.lpn -= 3); printf("main3l-6: %d\n",b); b = (g.pte.lpn *= 3); printf("main3l-7: %d\n",b); b = (g.pte.lpn /= 3); printf("main3l-8: %d\n",b); b = (g.pte.lpn %= 3); printf("main3l-9: %d\n",b); b = (g.pte.lpn |= 3); printf("main3l-10: %d\n",b); b = (g.pte.lpn &= 3); printf("main3l-12: %d\n",b); b = (g.pte.lpn ^= 3); printf("main3l-13: %d\n",b); b = (g.pte.lpn <<= 3); printf("main3l-14: %d\n",b); b = (g.pte.lpn >>= 3); printf("main3l-15: %d\n",b); g.pte.lpn = -333; printf("main3l-16: %d\n",b); b = g.pte.lpn--; printf("main3l-17: %d\n",b); b = g.pte.lpn++; printf("main3l-18: %d\n",b); b = --g.pte.lpn; printf("main3l-19: %d\n",b); b = ++g.pte.lpn; printf("main3l-20: %d\n",b); b = (g.pte.lpn += i); printf("main3l-21: %d\n",b); b = (g.pte.lpn -= i); printf("main3l-22: %d\n",b); b = (g.pte.lpn *= i); printf("main3l-23: %d\n",b); b = (g.pte.lpn /= i); printf("main3l-24: %d\n",b); b = (g.pte.lpn %= i); printf("main3l-25: %d\n",b); b = (g.pte.lpn |= i); printf("main3l-26: %d\n",b); b = (g.pte.lpn &= i); printf("main3l-27: %d\n",b); b = (g.pte.lpn ^= i); printf("main3l-28: %d\n",b); b = (g.pte.lpn <<= i); printf("main3l-29: %d\n",b); b = (g.pte.lpn >>= i); printf("main3l-30: %d\n",b); return --b; }