diff options
-rw-r--r-- | lib/VMCore/AsmWriter.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/VMCore/AsmWriter.cpp b/lib/VMCore/AsmWriter.cpp index 296cc25..2a25841 100644 --- a/lib/VMCore/AsmWriter.cpp +++ b/lib/VMCore/AsmWriter.cpp @@ -1060,6 +1060,15 @@ static void WriteConstantInt(raw_ostream &Out, const Constant *CV, Out << "zeroinitializer"; return; } + + if (const BlockAddress *BA = dyn_cast<BlockAddress>(CV)) { + Out << "blockaddress("; + WriteAsOperandInternal(Out, BA->getFunction(), &TypePrinter, Machine); + Out << ", "; + WriteAsOperandInternal(Out, BA->getBasicBlock(), &TypePrinter, Machine); + Out << ")"; + return; + } if (const ConstantArray *CA = dyn_cast<ConstantArray>(CV)) { // As a special case, print the array as a string if it is an array of |