Add missing filter cards to zygote mod union table

Without filtering the cards, every object in the zygote is grayed
during the GC. This was deleted in a PS of previous CL.

GrayAllDirtyImmuneObjects goes from 1.974ms to 376.464us for CC on
N9 maps. This happens during the pause. This CL also fixes regression
in zygote PSS.

Bug: 29516968
Bug: 12687968

Change-Id: I42014e78b1de3ce9b2eefa3bd32f0d24e2ff71c6
diff --git a/runtime/thread-inl.h b/runtime/thread-inl.h
index 3fd66a7..3aa1fc2 100644
--- a/runtime/thread-inl.h
+++ b/runtime/thread-inl.h
@@ -93,6 +93,18 @@
   return static_cast<ThreadState>(old_state_and_flags.as_struct.state);
 }
 
+inline bool Thread::IsThreadSuspensionAllowable() const {
+  if (tls32_.no_thread_suspension != 0) {
+    return false;
+  }
+  for (int i = kLockLevelCount - 1; i >= 0; --i) {
+    if (i != kMutatorLock && GetHeldMutex(static_cast<LockLevel>(i)) != nullptr) {
+      return false;
+    }
+  }
+  return true;
+}
+
 inline void Thread::AssertThreadSuspensionIsAllowable(bool check_locks) const {
   if (kIsDebugBuild) {
     if (gAborting == 0) {