[graphite] Add no-yield option to ContextOptions.

skgpu::graphite::ContextOptions has a new field, fNeverYieldToWebGPU. This new option is only valid with the Dawn backend. It indicates that
skgpu::graphite::Context should never yield to Dawn. In native this
means wgpu::Device::Tick() is never called. In Emscripten it
means Context never yields to the main thread event loop.

When the option is enabled, skgpu::SyncToCpu::kYes is ignored when
passed to Context::submit(). Moreover, it is a fatal error to have
submitted but unfinished GPU work before deleting Context. A new
method, hasUnfinishedGpuWork() is added to Context that can be
used to test this condition.

The intent of this option is to be able to use Graphite in WASM
without Asyncify.

Bug: b/309019344
Change-Id: I95b739f4471920b2bf1bfb60641aa036e97998e5
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/779616
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Brian Salomon <briansalomon@gmail.com>
28 files changed