[macruby-changes] [2552] MacRuby/trunk/gcd.c

source_changes at macosforge.org source_changes at macosforge.org
Wed Sep 16 19:15:00 PDT 2009


Revision: 2552
          http://trac.macosforge.org/projects/ruby/changeset/2552
Author:   mattaimonetti at gmail.com
Date:     2009-09-16 19:14:59 -0700 (Wed, 16 Sep 2009)
Log Message:
-----------
GCD documentation provided by Ernest Prabhakar

Modified Paths:
--------------
    MacRuby/trunk/gcd.c

Modified: MacRuby/trunk/gcd.c
===================================================================
--- MacRuby/trunk/gcd.c	2009-09-14 17:15:13 UTC (rev 2551)
+++ MacRuby/trunk/gcd.c	2009-09-17 02:14:59 UTC (rev 2552)
@@ -22,8 +22,28 @@
 // otherwise there are crashes when one tries to add an instance
 // variable to a queue. (Not that that is a good idea.)
 
-// TODO: Add a top-level rdoc for the module explaining what GCD
-// is good for (and pointing them to the dispatch(3) manpage).
+/*
+ *
+ *  Grand Central Dispatch (GCD) is a novel approach to multicore computing
+ *  that is built into Mac OS X version 10.6 Snow Leopard. In particular, GCD
+ *  shifts responsibility for managing threads and their execution from
+ *  applications to the operating system. This allows programmers to easily
+ *  refactor their programs into small chunks of independent work, which GCD
+ *  then schedules onto per-process thread pools.  Because GCD knows the load
+ *  across the entire system, it ensures the resulting programs perform
+ *  optimally on a wide range of hardware.
+ * 
+ *  GCD is built on a highly-efficient multicore engine accessed via a C API
+ *  providing four primary abstractions, which are wrapped in this MacRuby
+ *  implementation:
+ *    ▪ block objects
+ *    ▪ dispatch queues
+ *    ▪ synchronization services
+ *    ▪ event sources
+ * 
+ *  For more information, see the dispatch(3) man page.  
+ *
+*/
 
 typedef struct {
     struct RBasic basic;
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20090916/18260767/attachment.html>


More information about the macruby-changes mailing list