Avoid suspending heap task thread for getting stack traces

Instead of suspending the heap task thread, GetThreadStack (called by
VMStack_fillStackTraceElements and VMStack_getThreadStackTrace) will
return an empty thread stack. This fixes possible deadlocks caused by
suspending the GC thread and doing allocations for the stack trace.

Bug: 28261069

Test: test-art-host

Change-Id: I45a0b8ac94a99d6bbcfcdc2b41afadf941ec0138
3 files changed