Reviewers: pcc, eugenis
Subscribers: hiraditya, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D64052
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@365864
91177308-0d34-0410-b5e6-
96231b3b80d8
if (isa<UndefValue>(V))
return UndefInt8;
+ const uint64_t Size = DL.getTypeStoreSize(V->getType());
+ if (!Size)
+ return UndefInt8;
+
Constant *C = dyn_cast<Constant>(V);
if (!C) {
// Conceptually, we could handle things like:
"i16* inttoptr (i96 -1 to i16*)",
},
{
- "i8 0",
+ "i8 undef",
"[0 x i8] zeroinitializer",
},
{
"[0 x i8] undef",
},
{
- "i8 0",
+ "i8 undef",
"[5 x [0 x i8]] zeroinitializer",
},
{
"[2 x i16] [i16 -21836, i16 -21846]]",
},
{
- "i8 0",
+ "i8 undef",
"{ } zeroinitializer",
},
{
"{ } undef",
},
{
- "i8 0",
+ "i8 undef",
"{ {}, {} } zeroinitializer",
},
{