Add support for sample profiling in traceview.

Instead of method instrumentation, allow traceview to periodically
sample stack traces of threads. Disabled by default until we add
gui support for this new mode.

(cherry picked from commit 676f8a527fb62abd39663d55c7d9208f5ca03093)

Change-Id: Id8942d4186fc628ee7bd8d809d7239dec310054b
6 files changed