Changeset 11543 in vbox for trunk/src/VBox/Runtime
- Timestamp:
- Aug 21, 2008 3:35:28 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/testcase/tstUuid.cpp
r11539 r11543 106 106 CHECK_EXPR(memcmp(&Uuid3, &Uuid, sizeof(Uuid)) == 0); 107 107 108 #if 0 /** @todo make less verbose and print the bits that remain unchanged. */109 108 /* 110 109 * checking the clock seq and time hi and version bits... 111 110 */ 111 RTUUID Uuid4Changes; 112 Uuid4Changes.au64[0] = 0; 113 Uuid4Changes.au64[1] = 0; 114 115 RTUUID Uuid4Prev; 116 RTUuidCreate(&Uuid4Prev); 117 112 118 for (unsigned i = 0; i < 1024; i++) 113 119 { 114 120 RTUUID Uuid4; 115 121 RTUuidCreate(&Uuid4); 122 123 Uuid4Changes.au64[0] |= Uuid4.au64[0] ^ Uuid4Prev.au64[0]; 124 Uuid4Changes.au64[1] |= Uuid4.au64[1] ^ Uuid4Prev.au64[1]; 125 126 #if 0 /** @todo make a bit string/dumper similar to %Rhxs/d. */ 116 127 RTPrintf("tstUuid: %d %d %d %d-%d %d %d %d %d %d %d %d-%d %d %d %d ; %d %d %d %d-%d %d %d %d %d %d %d %d-%d %d %d %d\n", 117 128 !!(Uuid4.Gen.u16ClockSeq & RT_BIT(0)), … … 132 143 !!(Uuid4.Gen.u16ClockSeq & RT_BIT(15)), 133 144 134 135 145 !!(Uuid4.Gen.u16TimeHiAndVersion & RT_BIT(0)), 136 146 !!(Uuid4.Gen.u16TimeHiAndVersion & RT_BIT(1)), … … 150 160 !!(Uuid4.Gen.u16TimeHiAndVersion & RT_BIT(15)) 151 161 ); 162 #endif 163 Uuid4Prev = Uuid4; 152 164 } 153 #endif 165 166 RTUUID Uuid4Fixed; 167 Uuid4Fixed.au64[0] = ~Uuid4Changes.au64[0]; 168 Uuid4Fixed.au64[1] = ~Uuid4Changes.au64[1]; 169 RTPrintf("tstUuid: fixed bits: %RTuuid (mask)\n", &Uuid4Fixed); 170 RTPrintf("tstUuid: raw: %.*Rhxs\n", sizeof(Uuid4Fixed), &Uuid4Fixed); 171 172 Uuid4Prev.au64[0] &= Uuid4Fixed.au64[0]; 173 Uuid4Prev.au64[1] &= Uuid4Fixed.au64[1]; 174 RTPrintf("tstUuid: fixed bits: %RTuuid (value)\n", &Uuid4Prev); 175 RTPrintf("tstUuid: raw: %.*Rhxs\n", sizeof(Uuid4Prev), &Uuid4Prev); 154 176 155 177 /*
Note:
See TracChangeset
for help on using the changeset viewer.