[llvm-commits] patch: partial dse

Duncan Sands baldrick at free.fr
Fri Jan 8 00:26:29 PST 2010


Hi Nick,

> At the moment, it restricts itself to the case where we have TargetData. 
> This seems odd at first, but the problem is that DSE itself doesn't seem 
> to be sure how many bits will be modified by a store without it. 'i32' 
> and 'i16' are clear, but 'i6' less so (and which 2 bits does it leave 
> alone). My opinion is that the only sane behaviour for an i6* store is 
> that it overwrite only the first 6 bits of the pointee and no others, 
> which is the same rule that i16* and i32* have.

no, it will overwrite 8 bits.  The general rule is that an iN store will
overwrite (N+7)/8 bytes, which is the same rule that i16* and i32* have :)
This is currently target independent, but I suppose it is safer to define
it in TD in case we get a target that has 16 bit bytes one day.

Ciao,

Duncan.



More information about the llvm-commits mailing list