[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] GNU Guile branch, wip-nested-futures, created. v2.0.6-87

From: Ludovic Courtès
Subject: [Guile-commits] GNU Guile branch, wip-nested-futures, created. v2.0.6-87-gabf0347
Date: Fri, 16 Nov 2012 23:21:40 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Guile".

The branch, wip-nested-futures has been created
        at  abf034745e5b99131dcf53058829ea878c2bc064 (commit)

- Log -----------------------------------------------------------------
commit abf034745e5b99131dcf53058829ea878c2bc064
Author: Ludovic Courtès <address@hidden>
Date:   Sat Nov 17 00:11:23 2012 +0100

    Update `par-map' to use nested futures.
    This allows it to actually use all CPU cores, instead of having the main
    thread stuck on a `wait-condition-variable'.
    * module/ice-9/threads.scm (par-mapper): Add a `cons' argument; update
      callers accordingly.  Rewrite using nested futures.

commit b314a8120b87467eb48dbaddb89c364e06a6d44f
Author: Ludovic Courtès <address@hidden>
Date:   Sat Nov 17 00:20:21 2012 +0100

    futures: Allow nested futures; put the main thread to work.
    * module/ice-9/futures.scm (%futures-waiting, %within-future?,
      %future-prompt): New variables.
      (let/ec): New macro.
      (process-future!): Run FUTURE's thunk in a prompt; capture FUTURE's
      continuation when it aborts, and add it to %FUTURES-WAITING.  Set
      %WITHIN-FUTURE? in the dynamic extent of the call FUTURE's thunk.
      (process-futures): Move loop body to...
      (process-one-future): ... here.  New procedure.
      (notify-completion): New procedure.
      (touch)[work, loop]: New procedures.
      When %WITHIN-FUTURE? and FUTURE is started, abort; if not
      %WITHIN-FUTURE, call `work' while waiting.
      When FUTURE is queued, call `work' too.
    * test-suite/tests/future.test ("nested futures"): New tests.

commit b5f92a2fcceb6cd303615d52657b2dc0b13d1bb5
Author: Ludovic Courtès <address@hidden>
Date:   Fri Nov 16 23:51:59 2012 +0100

    futures: Add a record printer.
    * module/ice-9/futures.scm: Add a record printer for <future>.

commit c4064ab22dd5a3a9a8d01f6fbd2ee9506843fdf9
Author: Ludovic Courtès <address@hidden>
Date:   Wed Nov 7 15:16:03 2012 +0100

    futures: Keep futures unlocked while they are processing.
    * module/ice-9/futures.scm (<future>)[completion]: New field.
      [done?]: Rename to...
      [state]: ... this.  Change `set-future-done?!' to
      `set-future-state!', and `future-done?' to `future-state'.
      (make-future): Initialize the `completion' field to 'queued.
      (with-mutex): New macro.
      (process-future!): Remove `set-future-done?!' call.
      (process-futures): Check `future-state'.  Unlock FUTURE's mutex before
      processing it.  Broadcast FUTURE's `completion' cond. var. when done.
      (touch): Likewise.


GNU Guile

reply via email to

[Prev in Thread] Current Thread [Next in Thread]