Commit c65a9e30 authored by Findit's avatar Findit Committed by Ahmed Fakhry

Revert "Reland "Reland [base] Require task posters to specify an explicit destination""

This reverts commit d7b74986.

Reason for revert:

Findit (https://goo.gl/kROfz5) identified CL at revision 689097 as the
culprit for failures in the build cycles as shown on:
https://analysis.chromium.org/waterfall/culprit?key=ag9zfmZpbmRpdC1mb3ItbWVyRAsSDVdmU3VzcGVjdGVkQ0wiMWNocm9taXVtL2Q3Yjc0OTg2MWUwODE0YzAxODgwNjVmZWUwY2Q2MTcyMTQwZDMzOTMM

Sample Failed Build: https://ci.chromium.org/buildbot/chromium/win32-archive-rel/4058

Sample Failed Step: compile

Original change's description:
> Reland "Reland [base] Require task posters to specify an explicit destination"
> 
> This is a reland of dd34a877
> 
> Rebased on a few more fixes including a local full build of:
>  - Windows + is_chrome_branded
>  - ChromeOS + is_chrome_branded
>    (except for the libassistant portion which is giving weird errors...)
> 
> Original change's description:
> > Reland [base] Require task posters to specify an explicit destination
> >
> > This patch makes it a requirement for all task traits to specify their
> > thread affinity. Previously task traits that did not name a specific
> > thread would implicitly run on the thread pool, which could be
> > surprising. To make this more obvious, thread pool tasks must now use
> > the base::ThreadPool() trait.
> >
> > This is the final reland of
> > https://chromium-review.googlesource.com/c/chromium/src/+/1635827
> > (will attempt to fix errors that caused original revert before
> >  relanding).
> >
> > Bug: 968047
> > Change-Id: Ice339db270a27815b2be68200930e5bc105e8a96
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1759056
> > Commit-Queue: Gabriel Charette <gab@chromium.org>
> > Reviewed-by: François Doray <fdoray@chromium.org>
> > Cr-Commit-Position: refs/heads/master@{#688782}
> 
> Bug: 968047
> Change-Id: Iccd12e0a9f1535cb10b903777c5004a7d1acb34a
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1761362
> Commit-Queue: Gabriel Charette <gab@chromium.org>
> Reviewed-by: François Doray <fdoray@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#689097}


Change-Id: I9e1f30313cc2c3a09a27dda011112f577ba4cbe8
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 968047
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1764428
Cr-Commit-Position: refs/heads/master@{#689141}
parent 7c8375f2
...@@ -255,16 +255,7 @@ class BASE_EXPORT TaskTraits { ...@@ -255,16 +255,7 @@ class BASE_EXPORT TaskTraits {
may_block_(trait_helpers::HasTrait<MayBlock, ArgTypes...>()), may_block_(trait_helpers::HasTrait<MayBlock, ArgTypes...>()),
with_base_sync_primitives_( with_base_sync_primitives_(
trait_helpers::HasTrait<WithBaseSyncPrimitives, ArgTypes...>()), trait_helpers::HasTrait<WithBaseSyncPrimitives, ArgTypes...>()),
use_thread_pool_(trait_helpers::HasTrait<ThreadPool, ArgTypes...>()) { use_thread_pool_(trait_helpers::HasTrait<ThreadPool, ArgTypes...>()) {}
constexpr bool has_thread_pool =
trait_helpers::HasTrait<ThreadPool, ArgTypes...>();
constexpr bool has_extension =
!trait_helpers::AreValidTraits<ValidTrait, ArgTypes...>::value;
static_assert(
has_thread_pool ^ has_extension,
"Traits must explicitly specify a destination (e.g. ThreadPool or a "
"named thread like BrowserThread)");
}
constexpr TaskTraits(const TaskTraits& other) = default; constexpr TaskTraits(const TaskTraits& other) = default;
TaskTraits& operator=(const TaskTraits& other) = default; TaskTraits& operator=(const TaskTraits& other) = default;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment