]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Correct typos and spelling mistakes
authorPaul Floyd <pjfloyd@wanadoo.fr>
Sun, 3 Nov 2024 09:55:57 +0000 (10:55 +0100)
committerPaul Floyd <pjfloyd@wanadoo.fr>
Sun, 3 Nov 2024 09:55:57 +0000 (10:55 +0100)
18 files changed:
NEWS.old
VEX/priv/guest_ppc_toIR.c
VEX/priv/host_generic_reg_alloc2.c
VEX/pub/libvex_ir.h
coregrind/m_hashtable.c
coregrind/m_replacemalloc/vg_replace_malloc.c
coregrind/m_syswrap/syswrap-freebsd.c
coregrind/m_syswrap/syswrap-linux.c
coregrind/vgdb.c
docs/internals/Darwin-debug.txt
docs/internals/threads-syscalls-signals.txt
helgrind/hg_main.c
include/pub_tool_libcproc.h
memcheck/docs/mc-manual.xml
memcheck/mc_main.c
memcheck/tests/realloc_size_zero.supp
none/tests/s390x/vector.h
none/tests/solaris/coredump_many_segments.c

index 2b43c91fadbc11db469f92f9a6f0187cea8386ea..919b85c39a4316eb0b40f67bd21557701dd2288b 100644 (file)
--- a/NEWS.old
+++ b/NEWS.old
@@ -14,7 +14,7 @@ AMD64/macOS 10.13 and nanoMIPS/Linux.
   Rust v0 name demangling. [Update: alas, due to a bug, this support
   isn't working in 3.18.0.]
 
-* __libc_freeres isn't called anymore after the program recieves a
+* __libc_freeres isn't called anymore after the program receives a
   fatal signal. Causing some internal glibc resources to hang around,
   but preventing any crashes after the program has ended.
 
index 94930aa1c9a9ae086a0d70a8174d872f70b9e220..18716dd04c4154fca704672c4cda29109ce009ca 100644 (file)
@@ -6149,13 +6149,13 @@ static IRExpr* dnorm_adj_Vector ( IRExpr* src )
  *------------------------------------------------------------*/
 
 static ULong generate_TMreason( UInt failure_code,
-                                             UInt persistant,
+                                             UInt persistent,
                                              UInt nest_overflow,
                                              UInt tm_exact )
 {
    ULong tm_err_code =
      ( (ULong) 0) << (63-6)   /* Failure code */
-     | ( (ULong) persistant) << (63-7)     /* Failure persistant */
+     | ( (ULong) persistent) << (63-7)     /* Failure persistent */
      | ( (ULong) 0) << (63-8)   /* Disallowed */
      | ( (ULong) nest_overflow) << (63-9)   /* Nesting Overflow */
      | ( (ULong) 0) << (63-10)  /* Footprint Overflow */
@@ -7691,7 +7691,7 @@ static Bool dis_int_misc ( UInt prefix, UInt theInstr )
        *
        *    0b00   Resume instruction fetching and execution when an
        *           exception or an event-based branch exception occurs,
-       *           or a resume signal from the platform is recieved.
+       *           or a resume signal from the platform is received.
        *
        *    0b01   Reserved.
        *
@@ -33735,7 +33735,7 @@ static Bool dis_transactional_memory ( UInt prefix, UInt theInstr, UInt nextInst
       UInt failure_code = 0;  /* Forcing failure, will not be due to tabort
                                * or treclaim.
                                */
-      UInt persistant = 1;    /* set persistant since we are always failing
+      UInt persistent = 1;    /* set persistent since we are always failing
                                * the tbegin.
                                */
       UInt nest_overflow = 1; /* Alowed nesting depth overflow, we use this
@@ -33759,7 +33759,7 @@ static Bool dis_transactional_memory ( UInt prefix, UInt theInstr, UInt nextInst
        */
       putCR321( 0, mkU8( 0x2 ) );
 
-      tm_reason = generate_TMreason( failure_code, persistant,
+      tm_reason = generate_TMreason( failure_code, persistent,
                                      nest_overflow, tm_exact );
 
       storeTMfailure( guest_CIA_curr_instr, tm_reason,
index d94d2c92a72831103d7861369234b1c1875984e6..b731720f22effac7c9773d072164724f09ef4f0b 100644 (file)
@@ -494,7 +494,7 @@ HInstrArray* doRegisterAllocation_v2 (
    rreg_lrs_la = LibVEX_Alloc_inline(rreg_lrs_size * sizeof(RRegLR));
    rreg_lrs_db = NULL; /* we'll create this later */
 
-   /* We'll need to track live range start/end points seperately for
+   /* We'll need to track live range start/end points separately for
       each rreg.  Sigh. */
    vassert(n_rregs > 0);
    rreg_live_after  = LibVEX_Alloc_inline(n_rregs * sizeof(Int));
index f6f347a052ea223ea6388550fe0134f6f2dfb6c3..2d09e37cbcd7f7759de52f9d4fc89d2fd8a0c765 100644 (file)
@@ -2198,7 +2198,7 @@ struct _IRExpr {
 
          It is important to get the array size/type exactly correct
          since IR optimisation looks closely at such info in order to
-         establish aliasing/non-aliasing between seperate GetI and
+         establish aliasing/non-aliasing between separate GetI and
          PutI events, which is used to establish when they can be
          reordered, etc.  Putting incorrect info in will lead to
          obscure IR optimisation bugs.
index 586cfcc4f3eb591cbcf19878bf908b10f6370fd6..6fa07c29f1cc62d5ebb06885868eaf441d475c14 100644 (file)
@@ -234,21 +234,21 @@ void* VG_(HT_gen_remove) ( VgHashTable *table, const void* node, HT_Cmp_t cmp  )
 void VG_(HT_print_stats) ( const VgHashTable *table, HT_Cmp_t cmp )
 {
    #define MAXOCCUR 20
-   UInt elt_occurences[MAXOCCUR+1];
-   UInt key_occurences[MAXOCCUR+1];
-   UInt cno_occurences[MAXOCCUR+1];
-   /* Key occurence  : how many ht elements have the same key.
-      elt_occurences : how many elements are inserted multiple time.
-      cno_occurences : how many chains have that length.
-      The last entry in these arrays collects all occurences >= MAXOCCUR. */
+   UInt elt_occurrences[MAXOCCUR+1];
+   UInt key_occurrences[MAXOCCUR+1];
+   UInt cno_occurrences[MAXOCCUR+1];
+   /* Key occurrence  : how many ht elements have the same key.
+      elt_occurrences : how many elements are inserted multiple time.
+      cno_occurrences : how many chains have that length.
+      The last entry in these arrays collects all occurrences >= MAXOCCUR. */
    #define INCOCCUR(occur,n) (n >= MAXOCCUR ? occur[MAXOCCUR]++ : occur[n]++)
    UInt i;
    UInt nkey, nelt, ncno;
    VgHashNode *cnode, *node;
 
-   VG_(memset)(key_occurences, 0, sizeof(key_occurences));
-   VG_(memset)(elt_occurences, 0, sizeof(elt_occurences));
-   VG_(memset)(cno_occurences, 0, sizeof(cno_occurences));
+   VG_(memset)(key_occurrences, 0, sizeof(key_occurrences));
+   VG_(memset)(elt_occurrences, 0, sizeof(elt_occurrences));
+   VG_(memset)(cno_occurrences, 0, sizeof(cno_occurrences));
 
    // Note that the below algorithm is quadractic in nr of elements in a chain
    // but if that happens, the hash table/function is really bad and that
@@ -264,13 +264,13 @@ void VG_(HT_print_stats) ( const VgHashTable *table, HT_Cmp_t cmp )
             if (node->key == cnode->key)
                nkey++;
          }
-         // If cnode->key not in a previous node, count occurences of key.
+         // If cnode->key not in a previous node, count occurrences of key.
          if (nkey == 0) {
             for (node = cnode; node != NULL; node = node->next) {
                if (node->key == cnode->key)
                   nkey++;
             }
-            INCOCCUR(key_occurences, nkey);
+            INCOCCUR(key_occurrences, nkey);
          }
 
          nelt = 0;
@@ -281,7 +281,7 @@ void VG_(HT_print_stats) ( const VgHashTable *table, HT_Cmp_t cmp )
                nelt++;
             }
          }
-         // If cnode element not in a previous node, count occurences of elt.
+         // If cnode element not in a previous node, count occurrences of elt.
          if (nelt == 0) {
             for (node = cnode; node != NULL; node = node->next) {
                if (node->key == cnode->key
@@ -289,10 +289,10 @@ void VG_(HT_print_stats) ( const VgHashTable *table, HT_Cmp_t cmp )
                   nelt++;
                }
             }
-            INCOCCUR(elt_occurences, nelt);
+            INCOCCUR(elt_occurrences, nelt);
          }
       }
-      INCOCCUR(cno_occurences, ncno);
+      INCOCCUR(cno_occurrences, ncno);
    }
 
    VG_(message)(Vg_DebugMsg, 
@@ -302,23 +302,23 @@ void VG_(HT_print_stats) ( const VgHashTable *table, HT_Cmp_t cmp )
                 " N-plicated elts\n");
    nkey = nelt = ncno = 0;
    for (i = 0; i <= MAXOCCUR; i++) {
-      if (elt_occurences[i] > 0 
-          || key_occurences[i] > 0 
-          || cno_occurences[i] > 0)
+      if (elt_occurrences[i] > 0 
+          || key_occurrences[i] > 0 
+          || cno_occurrences[i] > 0)
          VG_(message)(Vg_DebugMsg,
                       "%s=%2u : nr chain %6u, nr keys %6u, nr elts %6u\n",
                       i == MAXOCCUR ? ">" : "N", i,
-                      cno_occurences[i], key_occurences[i], elt_occurences[i]);
-      nkey += key_occurences[i];
-      nelt += elt_occurences[i];
-      ncno += cno_occurences[i];
+                      cno_occurrences[i], key_occurrences[i], elt_occurrences[i]);
+      nkey += key_occurrences[i];
+      nelt += elt_occurrences[i];
+      ncno += cno_occurrences[i];
    }
    VG_(message)(Vg_DebugMsg, 
                 "total nr of unique   slots: %6u, keys %6u, elts %6u."
                 " Avg chain len %3.1f\n",
                 ncno, nkey, nelt,
-                (Double)nelt/(Double)(ncno == cno_occurences[0] ?
-                                      1 : ncno - cno_occurences[0]));
+                (Double)nelt/(Double)(ncno == cno_occurrences[0] ?
+                                      1 : ncno - cno_occurrences[0]));
 }
 
 
index 4125479b82df0005a4ba9525b05427d02dada8c4..aff2d27b3c1cc45ea3902c132e6efdff7fa597b9 100644 (file)
    Anything "user-defined" or "class-specific" we can't know
    about and the user needs to use memory pool annotation.
 
-   "non-alocating placement" as the name implies does not
+   "non-allocating placement" as the name implies does not
    allocate. Placement deletes are no-ops.
 */
 
index f5516420fb38d1274aacd72a0c21444d5482e2c3..6058bbe836ee1824d864b146def461dd0225563c 100644 (file)
@@ -2007,7 +2007,7 @@ PRE(sys___sysctl)
     *    downwards). Without any special handling this would return the
     *    address of the host userstack. We have created a stack for the
     *    guest (in aspacemgr) and that is the one that we want the guest
-    *    to see. Aspacemgr is setup in m_main.c with the adresses and sizes
+    *    to see. Aspacemgr is setup in m_main.c with the addresses and sizes
     *    saved to file static variables in that file, so we call
     *    VG_(get_usrstack)() to retrieve them from there.
     */
index eec8388224bae3877ee03b3bfdae4892c61ccb4e..177712117c5689f1d507038b4a1fc4f8c36edc6e 100644 (file)
@@ -560,7 +560,7 @@ static SysRes setup_child_tls (ThreadId ctid, Addr tlsaddr)
 {
    static const Bool debug = False;
    ThreadState* ctst = VG_(get_ThreadState)(ctid);
-   // res is succesful by default, overriden if a real syscall is needed/done.
+   // res is successful by default, overriden if a real syscall is needed/done.
    SysRes res = VG_(mk_SysRes_Success)(0);
 
    if (debug)
index 786ead160d3413a87e1babf7a5d2cdcf3012a4b5..d6740aecd460c094e7c0ae95808283b25c9f8f2d 100644 (file)
@@ -1167,7 +1167,7 @@ static void count_len(char delim, char *buf, size_t *len)
    If speaking with GDB, early_exit will ensure the GDB user sees
    the error messages produced by vgdb:
    early_exit should be used when vgdb exits due to an early error i.e.
-   error during arg processing, before it could succesfully process the
+   error during arg processing, before it could successfully process the
    first packet from GDB.
    early_exit will then read the first packet send by GDB (i.e.
    the qSupported packet) and will reply to it with an error and then exit.
index 5bc9b56633acfa123ddd38f5d8365c389b2f0a3f..705d6d57de5661de709b6b2b099ed8b895afe8a3 100644 (file)
@@ -58,5 +58,5 @@ gets set for core and tool preloads (the equivalent of LD_PRELOAD).
 DYLD_SHARED_REGION gets set to "avoid" (but note that for macOS 11
 Big Sur and later "avoid" is no longer an option).
 
-The Darwin calstack is a bit simpler to synthesise than the ones on
+The Darwin callstack is a bit simpler to synthesise than the ones on
 ELF platforms. There is no auxiliary vector (auxv) to construct.
index 5a083c12226dc6eb5ed9b819247fb5846b5fbee4..9b49135448141598dd84fee33ac4434a99ac3441 100644 (file)
@@ -122,7 +122,7 @@ set of signals while the signal is being delivered.  Valgrind's handlers
 block all signals, so there's no risk of a new signal being delivered to
 the same thread until the old handler has finished.
 
-The other is that if the thread which recieves the signal is not running
+The other is that if the thread which receives the signal is not running
 (ie, doesn't hold the run_sema, which implies it must be waiting for a
 syscall to complete), then the signal handler will grab the run_sema
 before making any global state changes.  Since the only time we can get
index bbf95c0ba0cc563de1738191cd06367b75ab18ad..5cdabb1127dd269dce0c09729edb0891794fc0fc 100644 (file)
@@ -5328,7 +5328,7 @@ Bool hg_handle_client_request ( ThreadId tid, UWord* args, UWord* ret)
 
          gnat_dmmls_INIT();
          /* Similar loop as for master completed hook below, but stops at
-            the first matching occurence, only comparing master and
+            the first matching occurrence, only comparing master and
             dependent. */
          for (n = VG_(sizeXA) (gnat_dmmls) - 1; n >= 0; n--) {
             GNAT_dmml *dmml = (GNAT_dmml*) VG_(indexXA)(gnat_dmmls, n);
index 24f037cce51780bc95603bc86b869b11e2a5021d..49c10dae2e03933cc1f29c68307d3634d019e9a0 100644 (file)
@@ -104,7 +104,7 @@ extern UInt VG_(read_millisecond_timer) ( void );
 extern Int  VG_(gettimeofday)(struct vki_timeval *tv, struct vki_timezone *tz);
 
 #  if defined(VGO_linux) || defined(VGO_solaris) || defined(VGO_freebsd)
-/* Get the clock value as specified by clk_id.  Asserts if unsuccesful.  */
+/* Get the clock value as specified by clk_id.  Asserts if unsuccessful.  */
 extern void VG_(clock_gettime)(struct vki_timespec *ts, vki_clockid_t clk_id);
 #  elif defined(VGO_darwin)
   /* It seems clock_gettime is only available on recent Darwin versions.
index 981ce710fc5c234056f341420f830283fd3417cf..4eee0bd333ca42c0ba5fe7c45a1cb910092ec8a3 100644 (file)
@@ -467,7 +467,7 @@ as "silly arguments" and no back-trace was included.
 
 </sect2>
 
-<sect2 id="mc-manual.realocsizezero"
+<sect2 id="mc-manual.reallocsizezero"
        xreflabel="Realloc size zero">
 <title>Realloc size zero</title>
 
index abd5d6888862fd4a1b127d8c94b03ea06c84d2cd..626d481d2587f1b67cdbbe8d38a1e12a755a59f0 100644 (file)
@@ -6329,7 +6329,7 @@ static void mc_print_usage(void)
 "    --keep-stacktraces=alloc|free|alloc-and-free|alloc-then-free|none\n"
 "        stack trace(s) to keep for malloc'd/free'd areas       [alloc-and-free]\n"
 "    --show-mismatched-frees=no|yes   show frees that don't match the allocator? [yes]\n"
-"    --show-realloc-size-zero=no|yes  show realocs with a size of zero? [yes]\n"
+"    --show-realloc-size-zero=no|yes  show reallocs with a size of zero? [yes]\n"
    );
 }
 
index 42e5f8d811848744f437b3092b9a7a486e2dc531..229e9abd9be2f1261d7f423f157fce77083c7f97 100644 (file)
@@ -1,5 +1,5 @@
 {
-   Test for realoc zero suppression
+   Test for realloc zero suppression
    Memcheck:ReallocZero
    fun:realloc
    fun:main
index b19c3465f57aff28638c32cce2e12b6dfbf87749..23ae1e93844981ac484384d2bc76fb4a75e10778 100644 (file)
@@ -174,7 +174,7 @@ void randomize_memory_pool()
       [{r,m}_arg2]   -- integer arg2
       [{r,m}_arg3]   -- integer arg3
       [{r,m}_result]      -- integer result
-      [{r,m}_memory_pool] -- address of random memory pool. Usefull for some instructions
+      [{r,m}_memory_pool] -- address of random memory pool. Useful for some instructions
 
 */
 
@@ -291,7 +291,7 @@ __attribute__((unused)) static void test_##insn() \
 }
 
 /* Stores CC to %[r_result].
-   Usefull when testing instructions which modify condition code.
+   Useful when testing instructions which modify condition code.
 */
 #define S390_TEST_PUT_CC_TO_RESULT "ipm %[r_result] \n srl %[r_result], 28 \n"
 
index da3f4ae05a8d454db148fb31c99dcf5e2da537c2..6fbe8b028c0566af12f6b51e01baf2ab641ef9d1 100644 (file)
@@ -191,7 +191,7 @@ int main(int argc, const char *argv[])
 
    size_t sum = sum_ranges(ranges);
    if (sum < SEGMENTS * page_size) {
-      fprintf(stderr, "Free (virtual) address space cannot accomodate "
+      fprintf(stderr, "Free (virtual) address space cannot accommodate "
               "%u pages.\n", SEGMENTS);
       return 1;
    }