diff options
author | Eli Friedman <eli.friedman@gmail.com> | 2009-12-27 07:02:50 +0000 |
---|---|---|
committer | Eli Friedman <eli.friedman@gmail.com> | 2009-12-27 07:02:50 +0000 |
commit | 8f5d7404da36f689b0005fc0fb5bba398c3919a9 (patch) | |
tree | ec2a58093bc1379a5d839fa4d16b33b732279b1f /lib/CodeGen/CGCXX.cpp | |
parent | 190ccccdc481602e518a06d699156b1d203d09db (diff) |
Add a sanity assertion so that we don't silently generate bad code; I'll file
a bug with a testcase hitting this assertion in a moment.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92175 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGCXX.cpp')
-rw-r--r-- | lib/CodeGen/CGCXX.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/CodeGen/CGCXX.cpp b/lib/CodeGen/CGCXX.cpp index 81dd534ba6..cc006d9dd6 100644 --- a/lib/CodeGen/CGCXX.cpp +++ b/lib/CodeGen/CGCXX.cpp @@ -1108,6 +1108,8 @@ void CodeGenFunction::InitializeVtablePtrsRecursive( } // Compute the address point + assert(AddressPoints.count(std::make_pair(ClassDecl, Offset)) && + "Missing address point for class"); uint64_t AddressPoint = AddressPoints[std::make_pair(ClassDecl, Offset)]; llvm::Value *VtableAddressPoint = Builder.CreateConstInBoundsGEP2_64(Vtable, 0, AddressPoint); |