[llvm-dev] RFC: Killing undef and spreading poison
Friedman, Eli via llvm-dev
llvm-dev at lists.llvm.org
Tue Oct 18 11:18:26 PDT 2016
On 10/18/2016 5:06 AM, Nuno Lopes via llvm-dev wrote:
> Another use is, for example, to implement bit-fields:
> a.x = 2
> becomes:
> %v = load %a
> %v2 = freeze %v ; %v could be uninitialized data (poison)
> %v3 = ... bitmasking...
> store %a, %v3
It seems like you're saying that an integer load which touches any
uninitialized byte of memory results in poison. Therefore, load %a
simplifies to "poison", and your proposed lowering of a bitfield write
throws away the value of every other adjacent bitfield. Am I missing
something?
-Eli
--
Employee of Qualcomm Innovation Center, Inc.
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project
More information about the llvm-dev
mailing list