summaryrefslogtreecommitdiffstats
path: root/lib/CodeGen/CGCXXABI.cpp
diff options
context:
space:
mode:
authorDavid Majnemer <david.majnemer@gmail.com>2015-11-02 09:01:44 +0000
committerDavid Majnemer <david.majnemer@gmail.com>2015-11-02 09:01:44 +0000
commitd010d9ad7e2eb77083e433a2070993f5cc28b555 (patch)
tree73cc6ddd10414cbfb1dc56379af1b070e286cc2e /lib/CodeGen/CGCXXABI.cpp
parent49747fe0fe3344f5e9010fd0d269af9d17e32f28 (diff)
[MS ABI] Don't zero-initialize vbptrs in bases
Certain CXXConstructExpr nodes require zero-initialization before a constructor is called. We had a bug in the case where the constructor is called on a virtual base: we zero-initialized the base's vbptr field. A complementary bug is present in MSVC where no zero-initialization occurs for the subobject at all. This fixes PR25370. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@251783 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGCXXABI.cpp')
-rw-r--r--lib/CodeGen/CGCXXABI.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/CodeGen/CGCXXABI.cpp b/lib/CodeGen/CGCXXABI.cpp
index 51f1b0730b..078b98d40d 100644
--- a/lib/CodeGen/CGCXXABI.cpp
+++ b/lib/CodeGen/CGCXXABI.cpp
@@ -326,3 +326,7 @@ CGCXXABI::emitTerminateForUnexpectedException(CodeGenFunction &CGF,
CatchTypeInfo CGCXXABI::getCatchAllTypeInfo() {
return CatchTypeInfo{nullptr, 0};
}
+
+std::vector<CharUnits> CGCXXABI::getVBPtrOffsets(const CXXRecordDecl *RD) {
+ return std::vector<CharUnits>();
+}