[clang] Remove Address::deprecated() calls in CGVTables.cpp

This commit is contained in:
Arthur Eubanks 2022-02-22 16:54:09 -08:00
parent 7fea963a45
commit cde658fa1f
1 changed files with 6 additions and 2 deletions

View File

@ -91,7 +91,10 @@ static RValue PerformReturnAdjustment(CodeGenFunction &CGF,
auto ClassDecl = ResultType->getPointeeType()->getAsCXXRecordDecl();
auto ClassAlign = CGF.CGM.getClassPointerAlignment(ClassDecl);
ReturnValue = CGF.CGM.getCXXABI().performReturnAdjustment(
CGF, Address::deprecated(ReturnValue, ClassAlign), Thunk.Return);
CGF,
Address(ReturnValue, CGF.ConvertTypeForMem(ResultType->getPointeeType()),
ClassAlign),
Thunk.Return);
if (NullCheckValue) {
CGF.Builder.CreateBr(AdjustEnd);
@ -198,7 +201,8 @@ CodeGenFunction::GenerateVarArgsThunk(llvm::Function *Fn,
// Find the first store of "this", which will be to the alloca associated
// with "this".
Address ThisPtr =
Address::deprecated(&*AI, CGM.getClassPointerAlignment(MD->getParent()));
Address(&*AI, ConvertTypeForMem(MD->getThisType()->getPointeeType()),
CGM.getClassPointerAlignment(MD->getParent()));
llvm::BasicBlock *EntryBB = &Fn->front();
llvm::BasicBlock::iterator ThisStore =
llvm::find_if(*EntryBB, [&](llvm::Instruction &I) {