Page MenuHomePhabricator

[SLPVectorizer]Migrate getTreeCost() to use InstructionCost

Authored by CarolineConcatto on Dec 10 2020, 9:10 AM.



This patch changes the type of cost variables (for instance: Cost, ExtractCost,
SpillCost) to use InstructionCost.
This patch also changes the type of cost variables to InstructionCost in other
functions that use the result of getTreeCost()
This patch is part of a series of patches to use InstructionCost instead of
unsigned/int for the cost model functions.

See this thread for context:

Depends on D91174

Diff Detail

Unit TestsFailed

250 msx64 windows > LLVM.CodeGen/XCore::threads.ll
Script: -- : 'RUN: at line 1'; c:\ws\w32-1\llvm-project\premerge-checks\build\bin\llc.exe -march=xcore < C:\ws\w32-1\llvm-project\premerge-checks\llvm\test\CodeGen\XCore\threads.ll | c:\ws\w32-1\llvm-project\premerge-checks\build\bin\filecheck.exe C:\ws\w32-1\llvm-project\premerge-checks\llvm\test\CodeGen\XCore\threads.ll

Event Timeline

CarolineConcatto requested review of this revision.Dec 10 2020, 9:10 AM
Herald added a project: Restricted Project. · View Herald TranscriptDec 10 2020, 9:10 AM
CarolineConcatto retitled this revision from [CostModel]Migrate getTreeCost() to use InstructionCost to [SLPVectorizer]Migrate getTreeCost() to use InstructionCost.Dec 10 2020, 9:15 AM
sdesmalen added inline comments.Dec 10 2020, 9:20 AM

Where does the - come from in front of SLPCostThreshold?

  • fix SLPCostThreshold to use getValue()
CarolineConcatto marked an inline comment as done.Dec 14 2020, 1:12 AM
This revision is now accepted and ready to land.Dec 14 2020, 1:32 AM
This revision was landed with ongoing or failed builds.Dec 16 2020, 5:10 AM
This revision was automatically updated to reflect the committed changes.