mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-12 13:30:51 +00:00
Get right cost for addrspacecast in cost model
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@199833 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ff16685a80
commit
4bcb85658d
@ -439,7 +439,8 @@ unsigned CostModelAnalysis::getInstructionCost(const Instruction *I) const {
|
||||
case Instruction::UIToFP:
|
||||
case Instruction::Trunc:
|
||||
case Instruction::FPTrunc:
|
||||
case Instruction::BitCast: {
|
||||
case Instruction::BitCast:
|
||||
case Instruction::AddrSpaceCast: {
|
||||
Type *SrcTy = I->getOperand(0)->getType();
|
||||
return TTI->getCastInstrCost(I->getOpcode(), I->getType(), SrcTy);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user