renderer: Start tile-worker threads asynchronously.

According to the sampling profiler, starting these threads take up
10% of the non-idle startup time on Win10 and Win8 (~5% on Win7).
Try starting these threads asynchronously instead.

To allow for this, turn Start() and Join() on base::SimpleThread into
non-virtual methods. Introduce BeforeStart() and BeforeJoin() virtual
methods so that tests can still do additional work as needed. Then,
introduce base::SimepleThread::StartAsync(), and use that for starting
the raster threads. Also introduce a BeforeRun() virtual method, so
that it is still possible to trigger some tasks after the thread has
been started and initialized asynchronously.

BUG=835316

Change-Id: I107c5cc5cf1dd579d2866a1feca6fd583b8f5577
Reviewed-on: https://chromium-review.googlesource.com/1015236
Commit-Queue: Sadrul Chowdhury <sadrul@chromium.org>
Reviewed-by: danakj <danakj@chromium.org>
Reviewed-by: Antoine Labour <piman@chromium.org>
Cr-Commit-Position: refs/heads/master@{#552344}

CrOS-Libchrome-Original-Commit: 6928fde34e9a06b3079d0e5fcc4593bce2f466e1
2 files changed
tree: e6a5fb756a59cd837b6930dbdcf1b5b6276dff1a
  1. base/
  2. build/
  3. components/
  4. dbus/
  5. device/
  6. ipc/
  7. mojo/
  8. testing/
  9. third_party/
  10. ui/