Reword some comments to be more inclusive

Also corrects a typo s/He/We/.

Bug: 161336379
Bug: 161850439
Bug: 161896447
Test: m
Change-Id: Ie8e37310eb777b7ee41a13f8894e99795c29a98a
diff --git a/compiler/optimizing/reference_type_propagation.cc b/compiler/optimizing/reference_type_propagation.cc
index 8576943..c7ed61a 100644
--- a/compiler/optimizing/reference_type_propagation.cc
+++ b/compiler/optimizing/reference_type_propagation.cc
@@ -481,7 +481,7 @@
 
   ReferenceTypeInfo class_rti = instanceOf->GetTargetClassRTI();
   if (!class_rti.IsValid()) {
-    // He have loaded an unresolved class. Don't bother bounding the type.
+    // We have loaded an unresolved class. Don't bother bounding the type.
     return;
   }
 
diff --git a/openjdkjvmti/events-inl.h b/openjdkjvmti/events-inl.h
index 883a4cc..92cfbc9 100644
--- a/openjdkjvmti/events-inl.h
+++ b/openjdkjvmti/events-inl.h
@@ -49,10 +49,10 @@
 
 namespace impl {
 
-// Helper for ensuring that the dispatch environment is sane. Events with JNIEnvs need to stash
-// pending exceptions since they can cause new ones to be thrown. In accordance with the JVMTI
-// specification we allow exceptions originating from events to overwrite the current exception,
-// including exceptions originating from earlier events.
+// Helper for ensuring that the dispatch environment is suitably provisioned. Events with JNIEnvs
+// need to stash pending exceptions since they can cause new ones to be thrown. In accordance with
+// the JVMTI specification we allow exceptions originating from events to overwrite the current
+// exception, including exceptions originating from earlier events.
 class ScopedEventDispatchEnvironment final : public art::ValueObject {
  public:
   ScopedEventDispatchEnvironment() : env_(nullptr), throw_(nullptr, nullptr) {
diff --git a/openjdkjvmti/ti_redefine.cc b/openjdkjvmti/ti_redefine.cc
index deba134..d442799 100644
--- a/openjdkjvmti/ti_redefine.cc
+++ b/openjdkjvmti/ti_redefine.cc
@@ -186,7 +186,7 @@
       DCHECK(obsolete_dex_caches_->Get(next_free_slot_) != nullptr);
       next_free_slot_++;
     }
-    // Sanity check that the same slot in obsolete_dex_caches_ is free.
+    // Check that the same slot in obsolete_dex_caches_ is free.
     DCHECK(obsolete_dex_caches_->Get(next_free_slot_) == nullptr);
   }
 
@@ -260,7 +260,7 @@
 };
 
 // This visitor walks thread stacks and allocates and sets up the obsolete methods. It also does
-// some basic sanity checks that the obsolete method is sane.
+// some basic soundness checks that the obsolete method is valid.
 class ObsoleteMethodStackVisitor : public art::StackVisitor {
  protected:
   ObsoleteMethodStackVisitor(
@@ -1173,7 +1173,7 @@
 class RedefinitionDataIter;
 
 // A wrapper that lets us hold onto the arbitrary sized data needed for redefinitions in a
-// reasonably sane way. This adds no fields to the normal ObjectArray. By doing this we can avoid
+// reasonable way. This adds no fields to the normal ObjectArray. By doing this we can avoid
 // having to deal with the fact that we need to hold an arbitrary number of references live.
 class RedefinitionDataHolder {
  public:
diff --git a/runtime/arch/x86/asm_support_x86.S b/runtime/arch/x86/asm_support_x86.S
index 1a75cbc..370eea1 100644
--- a/runtime/arch/x86/asm_support_x86.S
+++ b/runtime/arch/x86/asm_support_x86.S
@@ -156,7 +156,7 @@
     ALIGN_FUNCTION_ENTRY
 CALLVAR(c_name):
     CFI_STARTPROC
-    // Ensure we get a sane starting CFA.
+    // Ensure we get an appropriate starting CFA.
     CFI_DEF_CFA(esp, RAW_VAR(cfa_offset))
 END_MACRO
 
diff --git a/runtime/arch/x86_64/asm_support_x86_64.S b/runtime/arch/x86_64/asm_support_x86_64.S
index be9f59a..b87c707 100644
--- a/runtime/arch/x86_64/asm_support_x86_64.S
+++ b/runtime/arch/x86_64/asm_support_x86_64.S
@@ -165,7 +165,7 @@
     ALIGN_FUNCTION_ENTRY
 CALLVAR(c_name):
     CFI_STARTPROC
-    // Ensure we get a sane starting CFA.
+    // Ensure we get an appropriate starting CFA.
     CFI_DEF_CFA(rsp, RAW_VAR(cfa_offset))
 END_MACRO
 
diff --git a/runtime/base/timing_logger_test.cc b/runtime/base/timing_logger_test.cc
index 770d2c0..6f8d8cd 100644
--- a/runtime/base/timing_logger_test.cc
+++ b/runtime/base/timing_logger_test.cc
@@ -46,7 +46,7 @@
   logger.NewTiming(split2name);
   logger.NewTiming(split3name);
   logger.EndTiming();
-  // Get the timings and verify that they are sane.
+  // Get the timings and verify that they are appropriate.
   const auto& timings = logger.GetTimings();
   // 6 timings in the timing logger at this point.
   EXPECT_EQ(6U, timings.size());
diff --git a/runtime/gc/accounting/mod_union_table_test.cc b/runtime/gc/accounting/mod_union_table_test.cc
index 2fc9ee8..1cd719d 100644
--- a/runtime/gc/accounting/mod_union_table_test.cc
+++ b/runtime/gc/accounting/mod_union_table_test.cc
@@ -248,7 +248,7 @@
       ptr += CardTable::kCardSize) {
     ASSERT_TRUE(table->ContainsCardFor(reinterpret_cast<uintptr_t>(ptr)));
   }
-  // Visit again and make sure the cards got cleared back to their sane state.
+  // Visit again and make sure the cards got cleared back to their expected state.
   std::set<mirror::Object*> visited_after;
   CollectVisitedVisitor collector_after(&visited_after);
   table->UpdateAndMarkReferences(&collector_after);
diff --git a/runtime/gc/heap.h b/runtime/gc/heap.h
index 7dcd5e3..57ae7c9 100644
--- a/runtime/gc/heap.h
+++ b/runtime/gc/heap.h
@@ -510,7 +510,7 @@
     verify_object_mode_ = kVerifyObjectModeDisabled;
   }
 
-  // Other checks may be performed if we know the heap should be in a sane state.
+  // Other checks may be performed if we know the heap should be in a healthy state.
   bool IsObjectValidationEnabled() const {
     return verify_object_mode_ > kVerifyObjectModeDisabled;
   }
diff --git a/runtime/interpreter/interpreter_common.cc b/runtime/interpreter/interpreter_common.cc
index 726de6e..00e79b3 100644
--- a/runtime/interpreter/interpreter_common.cc
+++ b/runtime/interpreter/interpreter_common.cc
@@ -342,7 +342,7 @@
 
   // Initialize |result| to 0 as this is the default return value for
   // polymorphic invocations of method handle types with void return
-  // and provides sane return result in error cases.
+  // and provides a sensible return result in error cases.
   result->SetJ(0);
 
   // The invoke_method_idx here is the name of the signature polymorphic method that
diff --git a/runtime/mirror/array-inl.h b/runtime/mirror/array-inl.h
index 6d52d44..b0e77b4 100644
--- a/runtime/mirror/array-inl.h
+++ b/runtime/mirror/array-inl.h
@@ -45,7 +45,7 @@
   // Don't need to check this since we already check this in GetClass.
   int32_t component_count =
       GetLength<static_cast<VerifyObjectFlags>(kVerifyFlags & ~kVerifyThis)>();
-  // This is safe from overflow because the array was already allocated, so we know it's sane.
+  // This is safe from overflow because the array was already allocated.
   size_t header_size = DataOffset(1U << component_size_shift).SizeValue();
   size_t data_size = component_count << component_size_shift;
   return header_size + data_size;
diff --git a/runtime/reference_table_test.cc b/runtime/reference_table_test.cc
index e5c1e6a..7a1e668 100644
--- a/runtime/reference_table_test.cc
+++ b/runtime/reference_table_test.cc
@@ -109,7 +109,7 @@
     EXPECT_EQ(oss.str().find("short[]"), std::string::npos) << oss.str();
   }
 
-  // Add a second object 10 times and check dumping is sane.
+  // Add a second object 10 times so we can then check dumping works as expected.
   Handle<mirror::ShortArray> o2 = hs.NewHandle(mirror::ShortArray::Alloc(soa.Self(), 0));
   for (size_t i = 0; i < 10; ++i) {
     rt.Add(o2.Get());
diff --git a/runtime/verifier/method_verifier.cc b/runtime/verifier/method_verifier.cc
index 59ade97..84f0a7f 100644
--- a/runtime/verifier/method_verifier.cc
+++ b/runtime/verifier/method_verifier.cc
@@ -257,7 +257,7 @@
    * Call this after widths have been set in "insn_flags".
    *
    * Returns "false" if something in the exception table looks fishy, but we're expecting the
-   * exception table to be somewhat sane.
+   * exception table to be valid.
    */
   bool ScanTryCatchBlocks() REQUIRES_SHARED(Locks::mutator_lock_);
 
diff --git a/test/004-ThreadStress/src-art/Main.java b/test/004-ThreadStress/src-art/Main.java
index e717852..d595749 100644
--- a/test/004-ThreadStress/src-art/Main.java
+++ b/test/004-ThreadStress/src-art/Main.java
@@ -638,8 +638,8 @@
                     : new Daemon(lock, t, operations, mainThread, startBarrier);
         }
 
-        // Enable to dump operation counts per thread to make sure its
-        // sane compared to frequencyMap.
+        // Enable to dump operation counts per thread to see that it is
+        // commensurate with the frequencyMap.
         if (DEBUG) {
             for (int t = 0; t < threadStresses.length; t++) {
                 Operation[] operations = threadStresses[t].operations;
diff --git a/test/1003-metadata-section-strings/src-art/Main.java b/test/1003-metadata-section-strings/src-art/Main.java
index 99e1fbd..339d6d6 100644
--- a/test/1003-metadata-section-strings/src-art/Main.java
+++ b/test/1003-metadata-section-strings/src-art/Main.java
@@ -29,7 +29,7 @@
   }
 
   private static void runTest() {
-    // Test that reference equality is sane regarding the cache.
+    // Test that reference equality works regarding the cache.
     System.out.println(Other.getString(1) == "string1");
     System.out.println(Other.getString(2000) == "string2000");
     System.out.println(Other.getString(3000) == "string3000");
diff --git a/test/knownfailures.json b/test/knownfailures.json
index 35d5676..d8436fd 100644
--- a/test/knownfailures.json
+++ b/test/knownfailures.json
@@ -167,7 +167,7 @@
                   "137-cfi",
                   "138-duplicate-classes-check2"],
         "variant": "no-image",
-        "description": ["All these tests check that we have sane behavior if we",
+        "description": ["All these tests check that we have appropriate behavior if we",
                         "don't have a dex2oat. Therefore we",
                         "shouldn't run them in situations where we actually",
                         "don't have these since they explicitly test for them.",
diff --git a/tools/libcore_failures.txt b/tools/libcore_failures.txt
index 4fe2f0e..f121c58 100644
--- a/tools/libcore_failures.txt
+++ b/tools/libcore_failures.txt
@@ -143,7 +143,7 @@
   names: ["org.apache.harmony.tests.java.lang.ClassTest#test_forNameLjava_lang_String"]
 },
 {
-  description: "Lack of IPv6 on some buildbot slaves",
+  description: "Lack of IPv6 on some buildbot workers",
   result: EXEC_FAILED,
   names: ["libcore.libcore.io.OsTest#test_byteBufferPositions_sendto_recvfrom_af_inet6",
           "libcore.libcore.io.OsTest#test_sendtoSocketAddress_af_inet6",