TraceOutputter::Create creates a global instance in a thread-unsafe way, and TraceOutputter itself is RefCounted and not thread safe. I did any further for more thread unsafe behavior.
This is a problem on android webview which runs gpu service on two different threads in the same process.
It's not clear to me if the right fix is to make TraceOutputter thread safe, or make it one-per-thread rather than global.
TraceOutputter does seem like a heavy object with a base::Thread so maybe sharing is better, but then that thread is started and immediately stopped in the constructor so maybe not?
Comment 1 by piman@chromium.org
, Aug 4 2017