[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-06 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. (The first line of 0ffaffcaac97de31e1b0e7e80c4f7cab724eda20 should have mentioned `Lazyly initialize uncommon toolchain detector`. You can add `Reland` prefix or add the message in the body of the

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-06 Thread serge via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was automatically updated to reflect the committed changes. Closed by commit rG0ffaffcaac97: Reapply 6fa2abf90886f18472c87bc9bffbcdf4f73c465e (authored by serge-sans-paille). Repository: rG LLVM

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-06 Thread Jonas Hahnfeld via Phabricator via cfe-commits
Hahnfeld reopened this revision. Hahnfeld added a comment. This broke `clang/test/Driver/rocm-detect.hip` on a number of platforms (including the pre-merge checks on this PR), I've reverted for now in b5ee4f755fcff56243f6ff0cea9e7a722259304a

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-06 Thread Tom Weaver via Phabricator via cfe-commits
TWeaver added a comment. Hello all, sorry to be a bother, but I believe this patch has caused a failure in this buildbot (and potentially others). https://lab.llvm.org/buildbot/#/builders/109/builds/57277 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-06 Thread serge via Phabricator via cfe-commits
This revision was not accepted when it landed; it landed in state "Needs Review". This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rG6fa2abf90886: Lazyly initialize uncommon toolchain detector

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-05 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. LGTM Comment at: clang/lib/Driver/ToolChains/LazyDetector.h:36 +} +return (); + } tbaeder wrote: > Is the `.value()` here permitted? AFAIK the convention is to always use > `operator*`. > > And I think @aaron.ballman would

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-05 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 494927. serge-sans-paille added a comment. Address @tbader's comment CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142606/new/ https://reviews.llvm.org/D142606 Files: clang/lib/Driver/ToolChains/AMDGPU.cpp

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-05 Thread Timm Bäder via Phabricator via cfe-commits
tbaeder added inline comments. Comment at: clang/lib/Driver/ToolChains/LazyDetector.h:36 +} +return (); + } Is the `.value()` here permitted? AFAIK the convention is to always use `operator*`. And I think @aaron.ballman would tell you to drop the `{}`

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-05 Thread serge via Phabricator via cfe-commits
serge-sans-paille added inline comments. Comment at: clang/lib/Driver/ToolChains/LazyDetector.h:26 + + mutable std::optional Detector; + zero9178 wrote: > serge-sans-paille wrote: > > zero9178 wrote: > > > Any reason this is `mutable`? I don't see it being used

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-05 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 494877. serge-sans-paille added a comment. remove mutable qualifier CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142606/new/ https://reviews.llvm.org/D142606 Files: clang/lib/Driver/ToolChains/AMDGPU.cpp

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-02 Thread Markus Böck via Phabricator via cfe-commits
zero9178 added inline comments. Comment at: clang/lib/Driver/ToolChains/LazyDetector.h:26 + + mutable std::optional Detector; + serge-sans-paille wrote: > zero9178 wrote: > > Any reason this is `mutable`? I don't see it being used a non-const way in > > a

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-02-02 Thread serge via Phabricator via cfe-commits
serge-sans-paille added inline comments. Comment at: clang/lib/Driver/ToolChains/LazyDetector.h:26 + + mutable std::optional Detector; + zero9178 wrote: > Any reason this is `mutable`? I don't see it being used a non-const way in a > const method yeah, `T

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-01-26 Thread Markus Böck via Phabricator via cfe-commits
zero9178 added inline comments. Comment at: clang/lib/Driver/ToolChains/LazyDetector.h:26 + + mutable std::optional Detector; + Any reason this is `mutable`? I don't see it being used a non-const way in a const method Repository: rG LLVM Github Monorepo

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-01-26 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added a comment. In D142606#4082783 , @serge-sans-paille wrote: > In D142606#4082753 , @tstellar > wrote: > >> Does this mean that clang will no longer search for the ROCM and CUDA >> library paths

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-01-26 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. In D142606#4082753 , @tstellar wrote: > Does this mean that clang will no longer search for the ROCM and CUDA library > paths for every C compile? That's the goal, yes. Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-01-26 Thread Tom Stellard via Phabricator via cfe-commits
tstellar added a comment. Does this mean that clang will no longer search for the ROCM and CUDA library paths for every C compile? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D142606/new/ https://reviews.llvm.org/D142606

[PATCH] D142606: Lazyly initialize uncommon toolchain detector

2023-01-26 Thread serge via Phabricator via cfe-commits
serge-sans-paille created this revision. Herald added subscribers: kosarev, kerbowa, jvesely, emaste. Herald added a project: All. serge-sans-paille requested review of this revision. Herald added subscribers: cfe-commits, MaskRay. Herald added a project: clang. Cuda and rocm toolchain detectors