diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2020-01-24 22:00:03 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2020-01-24 22:00:03 +0000 |
commit | 480093f4440d54b30b3025afeac24b48f2ba7a2e (patch) | |
tree | 162e72994062888647caf0d875428db9445491a8 /contrib/llvm-project/llvm/lib/Support/TargetParser.cpp | |
parent | 489b1cf2ecf5b9b4a394857987014bfb09067726 (diff) | |
parent | 706b4fc47bbc608932d3b491ae19a3b9cde9497b (diff) |
Notes
Diffstat (limited to 'contrib/llvm-project/llvm/lib/Support/TargetParser.cpp')
-rw-r--r-- | contrib/llvm-project/llvm/lib/Support/TargetParser.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/contrib/llvm-project/llvm/lib/Support/TargetParser.cpp b/contrib/llvm-project/llvm/lib/Support/TargetParser.cpp index d213b9a8c6af..84ead58b98cd 100644 --- a/contrib/llvm-project/llvm/lib/Support/TargetParser.cpp +++ b/contrib/llvm-project/llvm/lib/Support/TargetParser.cpp @@ -132,7 +132,7 @@ StringRef llvm::AMDGPU::getArchNameR600(GPUKind AK) { } AMDGPU::GPUKind llvm::AMDGPU::parseArchAMDGCN(StringRef CPU) { - for (const auto C : AMDGCNGPUs) { + for (const auto &C : AMDGCNGPUs) { if (CPU == C.Name) return C.Kind; } @@ -141,7 +141,7 @@ AMDGPU::GPUKind llvm::AMDGPU::parseArchAMDGCN(StringRef CPU) { } AMDGPU::GPUKind llvm::AMDGPU::parseArchR600(StringRef CPU) { - for (const auto C : R600GPUs) { + for (const auto &C : R600GPUs) { if (CPU == C.Name) return C.Kind; } @@ -163,12 +163,12 @@ unsigned AMDGPU::getArchAttrR600(GPUKind AK) { void AMDGPU::fillValidArchListAMDGCN(SmallVectorImpl<StringRef> &Values) { // XXX: Should this only report unique canonical names? - for (const auto C : AMDGCNGPUs) + for (const auto &C : AMDGCNGPUs) Values.push_back(C.Name); } void AMDGPU::fillValidArchListR600(SmallVectorImpl<StringRef> &Values) { - for (const auto C : R600GPUs) + for (const auto &C : R600GPUs) Values.push_back(C.Name); } |