When re-using a vtable slot for the nearest overridden method, just because
authorJohn McCall <rjmccall@apple.com>
Tue, 9 Nov 2010 01:18:05 +0000 (01:18 +0000)
committerJohn McCall <rjmccall@apple.com>
Tue, 9 Nov 2010 01:18:05 +0000 (01:18 +0000)
commit4e3b17c9ce4a198eaeac4355b12e4b523185ecb5
tree078c1fee9603ca3fcdce03c5b98171abeb1dc812
parent43328e91627382870d51b5d84e08873cc0c970eb
When re-using a vtable slot for the nearest overridden method, just because
there's no return adjustment from the overridden to the overrider doesn't
mean there isn't a return adjustment from the overrider to the final
overrider.  This matters if we're emitting a virtual this-adjustment thunk
because the overrider virtually inherits from the class providing the
nearest overridden method.  Do the appropriate return adjustment in this case.

Fixes PR7611.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118466 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/CGVTables.cpp
test/CodeGenCXX/thunks.cpp