]> granicus.if.org Git - gc/commitdiff
Fix more typos in comments
authorOndrej Bilka <neleai@seznam.cz>
Tue, 30 Jul 2013 22:23:14 +0000 (02:23 +0400)
committerIvan Maidanski <ivmai@mail.ru>
Tue, 30 Jul 2013 22:23:14 +0000 (02:23 +0400)
* darwin_stop_world.c (GC_use_threads_discovery): Fix a typo in
comment ("stopped").
* doc/porting.html: Fix typos in comment ("defining", "support").
* include/gc.h (GC_get_prof_stats): Fix a typo in comment ("entries").
* include/private/gc_priv.h (GC_have_errors): Fix a typo in comment
("OK").
* include/private/gcconfig.h: Fix a typo in comment ("SPARC).
* ChangeLog: Likewise.
* os_dep.c (GC_linux_main_stack_base): Likewise.
* include/private/gcconfig.h: Fix a typo in comment ("release").
* mallocx.c (GC_generic_malloc_many): Fix a typo in comment
("reacquiring").
* mallocx.c (GC_memalign): Fix a typo in comment ("OK").
* os_dep.c (GC_win32_free_heap): Likewise.
* pthread_support.c (GC_remove_all_threads_but_me): Likewise.
* win32_threads.c (GC_remove_all_threads_but_me): Likewise.
* doc/README.Mac: Likewise.
* mark.c (GC_push_unconditionally): Fix a typo in comment ("pointers").
* pthread_support.c: Fix a typo in comment ("which").
* win32_threads.c: Fix a typo in comment ("losing").

12 files changed:
ChangeLog
darwin_stop_world.c
doc/README.Mac
doc/porting.html
include/gc.h
include/private/gc_priv.h
include/private/gcconfig.h
mallocx.c
mark.c
os_dep.c
pthread_support.c
win32_threads.c

index 599f54fd76c22fd05f6f38a70b7089ecfeee9636..61d3af3ae24c48f3dee59a1a3269bbd6a69a4a2e 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -789,7 +789,7 @@ variable.
 
 * configure.ac (THREADDLLIBS): Use alternate thread library on
 Solaris 8.
-* configure.ac (need_atomic_ops_asm): Set to true only for Sparc
+* configure.ac (need_atomic_ops_asm): Set to true only for SPARC
 Solaris.
 * configure.ac: Don't use libdl on mips-sgi-irix6.
 
index 11813d2e90b3af233dbab864385063272ca50e13..14aa1d366c503c4a83c398b7409b57a6d083d199 100644 (file)
@@ -101,7 +101,7 @@ GC_INNER ptr_t GC_FindTopOfStack(unsigned long stack_start)
 #endif /* !GC_NO_THREADS_DISCOVERY */
 
 /* Use implicit threads registration (all task threads excluding the GC */
-/* special ones are stoped and scanned).  Should be called before       */
+/* special ones are stopped and scanned).  Should be called before      */
 /* GC_INIT() (or, at least, before going multi-threaded).  Deprecated.  */
 GC_API void GC_CALL GC_use_threads_discovery(void)
 {
index bcd430aa51f0cf82dc3336b2dd7a0b2571ecfba6..55906697d20e190bdb74084013fd056099acbf16 100644 (file)
@@ -92,7 +92,7 @@ o C/C++ language
 o PPC Processor
   - Struct Alignment: PowerPC
   - uncheck "Store Static Data in TOC" -- important!
-    I don't think the others matter, I use full optimization and its ok
+    I don't think the others matter, I use full optimization and it is OK
 o PPC Linker
   - Factory Settings (SYM file with full paths, faster linking, dead-strip
     static init, Main: __start)
@@ -261,7 +261,7 @@ same as for test.c
 
 For convenience I used one test-project with several targets so that all
 test apps are build at once. Two for each library to test: test.c and
-gc_app.cc. When I was satisfied that the libraries were ok. I put the
+gc_app.cc. When I was satisfied that the libraries were OK. I put the
 libraries + gc.h + the c++ interface-file in a folder that I then put into
 the MSL hierarchy so that I don't have to alter access-paths in projects
 that use the GC.
index 1208f16e21239949d2e8ef34c01ac1f7d3f99c9f..f22f654e9b078126a75774bea24ee673111589bd 100644 (file)
@@ -212,7 +212,7 @@ from are copied to the stack.  Typically this can be done portably,
 but on some platforms it may require assembly code, or just
 tweaking of conditional compilation tests.
 <P>
-For GC7, if your platform supports <TT>getcontext()</tt>, then definining
+For GC7, if your platform supports <TT>getcontext()</tt>, then defining
 the macro <TT>UNIX_LIKE</tt> for your OS in <TT>gcconfig.h</tt>
 (if it isn't defined there already) is likely to solve the problem.
 otherwise, if you are using gcc, <TT>_builtin_unwind_init()</tt>
@@ -272,7 +272,7 @@ perform adequately as the allocation lock, you will probably need to
 ensure that a sufficient <TT>atomic_ops</tt> port
 exists for the platform to provided an atomic test and set
 operation.  (Current GC7 versions require more<TT>atomic_ops</tt>
-asupport than necessary.  This is a bug.)  For earlier versions define
+support than necessary.  This is a bug.)  For earlier versions define
 <TT>GC_test_and_set</tt> in <TT>gc_locks.h</tt>.
 <LI>Making any needed adjustments to <TT>pthread_stop_world.c</tt> and
 <TT>pthread_support.c</tt>.  Ideally none should be needed.  In fact,
index 5b7dae3d73ceca619bd178d15c900ff59e82def2..a3a13b908e733b9a121b30902e17e29cf83f2a22 100644 (file)
@@ -664,7 +664,7 @@ struct GC_prof_stats_s {
 /* should pass the size of the buffer (of GC_prof_stats_s type) to fill */
 /* in the values - this is for interoperability between different GC    */
 /* versions, an old client could have fewer fields, and vice versa,     */
-/* client could use newer gc.h (with more entires declared in the       */
+/* client could use newer gc.h (with more entries declared in the       */
 /* structure) than that of the linked libgc binary; in the latter case, */
 /* unsupported (unknown) fields are filled in with -1.  Return the size */
 /* (in bytes) of the filled in part of the structure (excluding all     */
index 097522e204214f11b2f415de1b19ca2b9d21e529..a6c660941a57d0330686c628fc217cb90af04240 100644 (file)
@@ -1894,7 +1894,7 @@ GC_EXTERN void (*GC_print_heap_obj)(ptr_t p);
 
 GC_EXTERN GC_bool GC_have_errors; /* We saw a smashed or leaked object. */
                                   /* Call error printing routine        */
-                                  /* occasionally.  It is ok to read it */
+                                  /* occasionally.  It is OK to read it */
                                   /* without acquiring the lock.        */
 
 #define VERBOSE 2
index bc4c8dff6811496f1454a37673551961a40d0c9c..d2488d5c0895ad082f858f144d814fddcc955e9c 100644 (file)
 #     ifdef __ELF__
 #       define DYNAMIC_LOADING
 #     else
-          Linux Sparc/a.out not supported
+#       error --> Linux SPARC a.out not supported
 #     endif
       extern int _end[];
       extern int _etext[];
 #            define DATASTART ((ptr_t)((((word) (etext)) + 0xfff) & ~0xfff))
 #       endif
 #       ifdef USE_I686_PREFETCH
-          /* FIXME: Thus should use __builtin_prefetch, but we'll leave that */
-          /* for the next rtelease.                                          */
+          /* FIXME: Thus should use __builtin_prefetch, but we'll leave */
+          /* that for the next release.                                 */
 #         define PREFETCH(x) \
             __asm__ __volatile__ ("prefetchnta %0" : : "m"(*(char *)(x)))
             /* Empirically prefetcht0 is much more effective at reducing     */
index 5cb41a9b885e7fc8121effe5d611d03bf08a5881..d3fbed271f59fb68d844ff7150d9c51253de9008 100644 (file)
--- a/mallocx.c
+++ b/mallocx.c
@@ -367,8 +367,8 @@ GC_API void GC_CALL GC_generic_malloc_many(size_t lb, int k, void **result)
                 GC_release_mark_lock();
                 LOCK();
                 /* GC lock is needed for reclaim list access.   We      */
-                /* must decrement fl_builder_count before reaquiring GC */
-                /* lock.  Hopefully this path is rare.                  */
+                /* must decrement fl_builder_count before reacquiring   */
+                /* the lock.  Hopefully this path is rare.              */
               }
 #           endif
         }
@@ -465,7 +465,7 @@ GC_API void * GC_CALL GC_memalign(size_t align, size_t lb)
     /* is a multiple of align.  That would be correct up to HBLKSIZE.      */
     new_lb = lb + align - 1;
     result = GC_malloc(new_lb);
-            /* It is ok not to check result for NULL as in that case    */
+            /* It is OK not to check result for NULL as in that case    */
             /* GC_memalign returns NULL too since (0 + 0 % align) is 0. */
     offset = (word)result % align;
     if (offset != 0) {
diff --git a/mark.c b/mark.c
index 16ea2366cadef3a601afaea6ef8d834af4330ba1..94c9519d9356c79fd03dce829f85af26d0a9cb5f 100644 (file)
--- a/mark.c
+++ b/mark.c
@@ -1768,7 +1768,7 @@ STATIC void GC_push_marked(struct hblk *h, hdr *hhdr)
 
 #ifdef ENABLE_DISCLAIM
 /* Unconditionally mark from all objects which have not been reclaimed. */
-/* This is useful in order to retain pointes which are reachable from   */
+/* This is useful in order to retain pointers which are reachable from  */
 /* the disclaim notifiers.                                              */
 /*                                                                      */
 /* To determine whether an object has been reclaimed, we require that   */
index 738ca254b66584f4772191ebea9fef8b4610c672..adf407a8870bf7e74554f7c4aa17f13803a87c35 100644 (file)
--- a/os_dep.c
+++ b/os_dep.c
@@ -1083,10 +1083,8 @@ GC_INNER word GC_page_size = 0;
           } /* Otherwise it's not safe to add 16 bytes and we fall      */
             /* back to using /proc.                                     */
 #       elif defined(SPARC)
-          /* Older versions of glibc for 64-bit Sparc do not set
-           * this variable correctly, it gets set to either zero
-           * or one.
-           */
+          /* Older versions of glibc for 64-bit SPARC do not set this   */
+          /* variable correctly, it gets set to either zero or one.     */
           if (__libc_stack_end != (ptr_t) (unsigned long)0x1)
             return __libc_stack_end;
 #       else
@@ -2308,7 +2306,7 @@ void * os2_alloc(size_t bytes)
     {
       while (GC_n_heap_bases-- > 0) {
 #       ifdef CYGWIN32
-          /* FIXME: Is it ok to use non-GC free() here? */
+          /* FIXME: Is it OK to use non-GC free() here? */
 #       else
           GlobalFree(GC_heap_bases[GC_n_heap_bases]);
 #       endif
@@ -3912,9 +3910,8 @@ typedef enum {
 } GC_mprotect_state_t;
 
 #ifdef THREADS
-  /* FIXME: 1 and 2 seem to be safe to use in the msgh_id field,        */
-  /* but it isn't documented. Use the source and see if they            */
-  /* should be ok.                                                      */
+  /* FIXME: 1 and 2 seem to be safe to use in the msgh_id field, but it */
+  /* is not documented.  Use the source and see if they should be OK.   */
 # define ID_STOP 1
 # define ID_RESUME 2
 
index 876c2a66bac85e5a725eb7dbd7ecafd0fc5d9549..957408d8c5abbbcb7d16c1045836eda1d5a0e0ef 100644 (file)
 #     define REAL_FUNC(f) GC_real_##f
       /* We define both GC_f and plain f to be the wrapped function.    */
       /* In that way plain calls work, as do calls from files that      */
-      /* included gc.h, wich redefined f to GC_f.                       */
+      /* included gc.h, which redefined f to GC_f.                      */
       /* FIXME: Needs work for DARWIN and True64 (OSF1) */
       typedef int (* GC_pthread_create_t)(pthread_t *,
                                     GC_PTHREAD_CREATE_CONST pthread_attr_t *,
@@ -675,7 +675,7 @@ STATIC void GC_remove_all_threads_but_me(void)
           me = p;
           p -> next = 0;
 #         ifdef GC_DARWIN_THREADS
-            /* Update thread Id after fork (it is ok to call    */
+            /* Update thread Id after fork (it is OK to call    */
             /* GC_destroy_thread_local and GC_free_internal     */
             /* before update).                                  */
             me -> stop_info.mach_thread = mach_thread_self();
@@ -685,7 +685,7 @@ STATIC void GC_remove_all_threads_but_me(void)
 #         if defined(THREAD_LOCAL_ALLOC) && !defined(USE_CUSTOM_SPECIFIC)
             /* Some TLS implementations might be not fork-friendly, so  */
             /* we re-assign thread-local pointer to 'tlfs' for safety   */
-            /* instead of the assertion check (again, it is ok to call  */
+            /* instead of the assertion check (again, it is OK to call  */
             /* GC_destroy_thread_local and GC_free_internal before).    */
             if (GC_setspecific(GC_thread_key, &me->tlfs) != 0)
               ABORT("GC_setspecific failed (in child)");
index 8439178333a007a2684a18571cb069d386f35689..4d57bc5e084d23d7674ab372e1f137db81b2228d 100644 (file)
@@ -1047,7 +1047,7 @@ GC_API void * GC_CALL GC_call_with_gc_active(GC_fn_type fn,
 
 #     if defined(THREAD_LOCAL_ALLOC) && !defined(USE_CUSTOM_SPECIFIC)
         /* For Cygwin, we need to re-assign thread-local pointer to     */
-        /* 'tlfs' (it is ok to call GC_destroy_thread_local and         */
+        /* 'tlfs' (it is OK to call GC_destroy_thread_local and         */
         /* GC_free_internal before this action).                        */
         if (GC_setspecific(GC_thread_key, &me->tlfs) != 0)
           ABORT("GC_setspecific failed (in child)");
@@ -2110,7 +2110,7 @@ GC_INNER void GC_get_next_stack(char *start, char *limit,
       /* does not work because they are used with different checked     */
       /* conditions in different places (and, in addition, notifying is */
       /* done after leaving critical section) and this could result in  */
-      /* a signal loosing between checking for a particular condition   */
+      /* a signal losing between checking for a particular condition    */
       /* and calling WaitForSingleObject.  So, we use PulseEvent() and  */
       /* NT SignalObjectAndWait() (which atomically sets mutex event to */
       /* signaled state and starts waiting on condvar).  A special      */