From: Vincent Penquerc'h <Vin...@ar...> - 2003-06-24 10:17:01
|
> This function does a lot of left shifts, right shifts and other > bit-level stuff. Is it possible that my data accidentally contains the > bit pattern used by valgrind to trace uninitialised data ? AFAIK, Valgrind doesn't rely on any pattern in the actual data to detect uninitialized data, especially as it can detect this at the bit level (you'd have to choose either 0 or 1 to mean "uninitialized" for a bit, which makes it hard to avoid the pattern :)) Valgrind maintains separate validity/addressability bits, but that is outside your program, so you don't see it. It's possible that Valgrind gets confused, if some insn wrongly sets/checks validity flags. Or, maybe you are encoding more than the actual data ? Or do you mean random data, as initialized via a pseudo random number generator, or as whatever happened to lie in memory at the time (in which case you will get undefinedness) ? -- Vincent Penquerc'h |