ART: Refactor Thread::Init

This refactor allows the parent thread to allocate the JNIEnvExt
for the child (with a fallback in place in Init). This allows to
throw an OOME in CreateNativeThread instead of aborting in the
child.

Bug: 21291279

(cherry picked from commit 520abbd0edcf333f07164539620ce65258c72383)

Change-Id: Iccc1a5c202999f5bfacec706d9833e53135ba2fa
4 files changed