[MS ABI] Reuse getVFPtrOffsets instead of using getClassAtVTableLocation
authorDavid Majnemer <david.majnemer@gmail.com>
Thu, 27 Oct 2016 17:11:51 +0000 (17:11 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Thu, 27 Oct 2016 17:11:51 +0000 (17:11 +0000)
commit07c915e1d59f981b6fc2e7f7529ca6d4f57018cb
tree8e00e15fe68ab087f2e9d3c4016b4d8ba687d570
parent28c4f18bfecd596645c67eb818634f55653e0300
[MS ABI] Reuse getVFPtrOffsets instead of using getClassAtVTableLocation

getClassAtVTableLocation hunts through virtual bases without using the
MDC layout which is indicative of a bug.

Instead, reuse the getVFPtrOffsets machinery to calculate which
subobject within the MDC is responsible for the vfptr.

Differential Revision: https://reviews.llvm.org/D25895

llvm-svn: 285315
clang/lib/CodeGen/MicrosoftCXXABI.cpp