[llvm] [clang] [AMDGPU] Introduce GFX9/10.1/10.3/11 Generic Targets (PR #76955)
via cfe-commits
cfe-commits at lists.llvm.org
Tue Feb 6 05:47:21 PST 2024
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff 500846d2f542c93e349161a39a1baae0f1f6fad0 eb8bd3422c24604af788e21d06958154631adc81 -- clang/lib/Basic/Targets/AMDGPU.cpp clang/test/Misc/target-invalid-cpu-note.c llvm/include/llvm/BinaryFormat/ELF.h llvm/include/llvm/TargetParser/TargetParser.h llvm/lib/Object/ELFObjectFile.cpp llvm/lib/ObjectYAML/ELFYAML.cpp llvm/lib/Target/AMDGPU/AMDGPUAsmPrinter.cpp llvm/lib/Target/AMDGPU/AMDGPURemoveIncompatibleFunctions.cpp llvm/lib/Target/AMDGPU/GCNSubtarget.h llvm/lib/Target/AMDGPU/MCTargetDesc/AMDGPUTargetStreamer.cpp llvm/lib/Target/AMDGPU/Utils/AMDGPUBaseInfo.h llvm/lib/TargetParser/TargetParser.cpp llvm/tools/llvm-readobj/ELFDumper.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/clang/lib/Basic/Targets/AMDGPU.cpp b/clang/lib/Basic/Targets/AMDGPU.cpp
index 7cfae129a6..10cba6b7ea 100644
--- a/clang/lib/Basic/Targets/AMDGPU.cpp
+++ b/clang/lib/Basic/Targets/AMDGPU.cpp
@@ -280,8 +280,9 @@ void AMDGPUTargetInfo::getTargetDefines(const LangOptions &Opts,
if (GPUKind == llvm::AMDGPU::GK_NONE && !IsHIPHost)
return;
- llvm::SmallString<16> CanonName = (isAMDGCN(getTriple()) ? getArchNameAMDGCN(GPUKind)
- : getArchNameR600(GPUKind));
+ llvm::SmallString<16> CanonName =
+ (isAMDGCN(getTriple()) ? getArchNameAMDGCN(GPUKind)
+ : getArchNameR600(GPUKind));
// Sanitize the name of generic targets.
// e.g. gfx10.1-generic -> gfx10_1_generic
``````````
</details>
https://github.com/llvm/llvm-project/pull/76955
More information about the cfe-commits
mailing list