[PATCH] D76097: improve performance of getSDKName()
Adrian Prantl via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Mar 20 16:51:19 PDT 2020
This revision was automatically updated to reflect the committed changes.
Closed by commit rG0e916bf9f5e4: Driver: Improve performance of getSDKName() (authored by aprantl).
Herald added a project: clang.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D76097/new/
https://reviews.llvm.org/D76097
Files:
clang/lib/Driver/ToolChains/Darwin.cpp
Index: clang/lib/Driver/ToolChains/Darwin.cpp
===================================================================
--- clang/lib/Driver/ToolChains/Darwin.cpp
+++ clang/lib/Driver/ToolChains/Darwin.cpp
@@ -1068,8 +1068,8 @@
StringRef Darwin::getSDKName(StringRef isysroot) {
// Assume SDK has path: SOME_PATH/SDKs/PlatformXX.YY.sdk
- auto BeginSDK = llvm::sys::path::begin(isysroot);
- auto EndSDK = llvm::sys::path::end(isysroot);
+ auto BeginSDK = llvm::sys::path::rbegin(isysroot);
+ auto EndSDK = llvm::sys::path::rend(isysroot);
for (auto IT = BeginSDK; IT != EndSDK; ++IT) {
StringRef SDK = *IT;
if (SDK.endswith(".sdk"))
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D76097.251803.patch
Type: text/x-patch
Size: 649 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200320/f5ae73e7/attachment-0001.bin>
More information about the cfe-commits
mailing list