summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/AsmPrinter/DwarfExpression.cpp
diff options
context:
space:
mode:
authorGuozhi Wei <carrot@google.com>2017-10-10 20:31:27 +0000
committerGuozhi Wei <carrot@google.com>2017-10-10 20:31:27 +0000
commit3625f3efad53bd9f18d57d54573e62eb6cbfebc5 (patch)
tree06e8f0e4b30b0bb50d980cb7d4e31e7ab5d720cd /llvm/lib/CodeGen/AsmPrinter/DwarfExpression.cpp
parentcc85223f8743e7df6fc6a943926881a372e1c045 (diff)
downloadbcm5719-llvm-3625f3efad53bd9f18d57d54573e62eb6cbfebc5.tar.gz
bcm5719-llvm-3625f3efad53bd9f18d57d54573e62eb6cbfebc5.zip
[CGExprScalar] In EmitCompare trunc the result if it has different type as E->getType()
Usually compare expression should return i1 type, so EmitScalarConversion is called before return return EmitScalarConversion(Result, CGF.getContext().BoolTy, E->getType(), E->getExprLoc()); But when ppc intrinsic is called to compare vectors, the ppc intrinsic can return i32 even E->getType() is BoolTy, in this case EmitScalarConversion does nothing, an i32 type result is returned and causes crash later. This patch detects this case and truncates the result before return. Differential Revision: https://reviews.llvm.org/D38656 llvm-svn: 315358
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfExpression.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud