Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: d58affa65ff32ab6d43d0abcaeb92dccad0105fa
Ticket: 1202052fffffffffffffffffffffffffffffffff
Darwin: CFRunLoop based notifier
User & Date: das on 2005-05-14 18:28:19
Changes

  1. assignee changed to: "das"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    This patch implements a new CFRunLoop based notifier on Darwin to 
    allow easy integration with other event loops on Mac OS X, in particular 
    the TkAqua Carbon event loop can now be integrated via a standard tcl 
    event source (instead of TkAqua upon loading having to finalize the 
    exsting notifier and  replace it with its custom version, which has bad 
    consequences for any fileevent handlers already established).
    
    The new tclMacOSXNotify.c is very similar to the threaded tclUnixNotfy.c, 
    except that the notifier thread uses a CFRunLoopSource to wake up tcl 
    threads waiting for events in CFRunLoopRun. To allow use of this notifier 
    in an untreaded core, we use pthread API directly and don't rely on tcl 
    thread API. To reduce complexity only the minimal amount of pthread API 
    necessary is used; for locking, we  use the low overhead OSSpinLockLock 
    API (or the commpage _spin_lock SPI). The need for condition variables is 
    removed by creating the trigger pipe from the main thread and using 
    pthread_join to wait for notifier thread termination. Use of the tcl thread 
    specific data API can remain because it is only used in threads with interps 
    (i.e. not the notifier thread) and in the unthreaded case, there is only one 
    such thread.
    
    
  4. foundin changed to: "None"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "das"
  9. subsystem changed to: "01. Notifier"
  10. title changed to: "Darwin: CFRunLoop based notifier"
  11. type changed to: "Patch"