This is an archive of the discontinued LLVM Phabricator instance.

[NFC][AMDGPU] Split AMDGPUSubtarget.h to R600 and GCN subtargets
ClosedPublic

Authored by dfukalov on Jan 20 2021, 4:59 AM.

Details

Diff Detail

Event Timeline

dfukalov created this revision.Jan 20 2021, 4:59 AM
dfukalov requested review of this revision.Jan 20 2021, 4:59 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 20 2021, 4:59 AM
Herald added a subscriber: wdng. · View Herald Transcript

Is there a specific reason to do this now?

llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.cpp
242–261

This looks like an unrelated change

dfukalov marked an inline comment as done.Jan 20 2021, 7:52 AM

The main reason was reducing include dependencies and so source files re-builds. At the moment both GCN and R600 targets rebuild if one just changes one option in GCN related code. Actually this is the first part of split, I was thinking about splitting AMDGPUSubtarget.cpp then, and following AMDGPUMCTargetDesc.h (it currently contains both GCN+R600 tablegen output).

llvm/lib/Target/AMDGPU/AMDGPUTargetTransformInfo.cpp
242–261

I moved this initialization out from header since otherwise it should include quire heavy AMDGPUMCTargetDesc.h with definitions of AMDGPU::<option>.

dfukalov retitled this revision from [NFC][AMDGPU] Split AMDGPUSubtarget.h to R600 and GCN subtargets. to [NFC][AMDGPU] Split AMDGPUSubtarget.h to R600 and GCN subtargets.Jan 20 2021, 7:55 AM
dfukalov edited the summary of this revision. (Show Details)
arsenm accepted this revision.Jan 20 2021, 8:35 AM
This revision is now accepted and ready to land.Jan 20 2021, 8:35 AM
rampitec accepted this revision.Jan 20 2021, 9:26 AM
This revision was landed with ongoing or failed builds.Jan 20 2021, 11:23 AM
This revision was automatically updated to reflect the committed changes.
dfukalov marked an inline comment as done.