Add gettid.

Change-Id: Ie18095d696ebeb8f056fb7f5b7cfbc452cdf8206
Merge "Add gettid."
Merge branch 'master' of https://android.googlesource.com/platform/libcore into jb-devel