[Bug rtl-optimization/33796] valgrind error with -O2 for linux kernel code

bergner at gcc dot gnu dot org gcc-bugzilla@gcc.gnu.org
Thu Oct 25 18:46:00 GMT 2007



------- Comment #7 from bergner at gcc dot gnu dot org  2007-10-25 18:46 -------
>> So yes we do some uninitialized accesses to the sparse array, but that's 
>> ok.  
>
> So absolutely *any* value is fine ?

Yes, absolutely *any* value is fine.  If you look at the code, you'll see that
the result of the uninitialized read is used to index into the dense array, but
only after guaranteeing that it is within bounds of the dense array. 
Therefore, we're not just widely accessing random memory locations.


> Aren't there some machines where unaligned accesses to words fail ?

These are uninitialized reads, not unaligned reads.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33796



More information about the Gcc-bugs mailing list