.. so that we don't have to create TM in two places in lld. See http://reviews.llvm.org/D18999 for reference.
Hopefully should work, assuming TheTarget is thread-safe. Thanks to Michael Spencer for help with this patch.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
Looks OK, see some inline comments.
| include/llvm/CodeGen/ParallelCG.h | ||
|---|---|---|
| 49 ↗ | (On Diff #53804) | Is there a better name for F? |
| 49 ↗ | (On Diff #53804) | Also: const & |
| lib/CodeGen/ParallelCG.cpp | ||
| 29 ↗ | (On Diff #53804) | Use another name than F, and take a const &. |
| 51 ↗ | (On Diff #53804) | Do you really mean = here? I'd use &. |
| lib/CodeGen/ParallelCG.cpp | ||
|---|---|---|
| 50–54 ↗ | (On Diff #53804) | clang-format. |
Comment Actions
LGTM, with a few more fixes (see inline)
| include/llvm/CodeGen/ParallelCG.h | ||
|---|---|---|
| 49 ↗ | (On Diff #53815) | Add in the documentation the fact that TMFactory needs to be thread safe on the client side. |
| lib/CodeGen/ParallelCG.cpp | ||
| 30 ↗ | (On Diff #53815) | still missing const & here. |
| 99 ↗ | (On Diff #53815) | &TMFactory (avoid copy here). |