The chanl Reference Manual

Table of Contents

Next: , Previous: , Up: (dir)   [Contents][Index]

The chanl Reference Manual

This is the chanl Reference Manual, generated automatically by Declt version 2.3 "Robert April" on Wed Mar 14 03:05:10 2018 GMT+0.


Next: , Previous: , Up: Top   [Contents][Index]

1 Introduction

What is ChanL?

"Wh-what you have to understand is that-that ChanL is not a big blob of state. When you have a lot of global state with lots of threads, you need to, you need to lock it down. It's like a truck, and if too many people try to use that truck, you, you get problems. ChanL is not a big truck. It's a series--it's a series of tubes."

In a nutshell, you create various threads sequentially executing tasks you need done, and use channel objects to communicate and synchronize the state of these threads.

You can read more about what that means here:

Loading ChanL

ChanL uses asdf for compiling/loading, so in order to load it, you must first make chanl.asd visible to your lisp, then simply

   (asdf:oos 'asdf:load-op 'chanl)

The included examples can be loaded by doing

   (asdf:oos 'asdf:load-op 'chanl.examples)

at the REPL after the main .asd has been loaded.

Compatibility Build Status

ChanL uses a subset of Bordeaux-threads for all its operations. All other code is written in ANSI CL, so any lisp with a BT-compatible thread library should be able to use this library.

ChanL is mainly developed on Clozure CL and SBCL, although it's been casually tested on other lisps.

You can run the test suite to see how well it works on yours:

   (asdf:oos 'asdf:test-op 'chanl)

Note that the test-suite depends on 5AM, which can be found at http://github.com/sionescu/fiveam

Channel API

[generic function] make-instance class &rest initargs &key &allow-other-keys

[method] make-instance (class channel) &rest initargs

Returns a new channel object.

[method] make-instance (class unbounded-channel) &rest initargs

Returns a new buffered channel with a FIFO buffer with no maximum length.

[method] make-instance (class bounded-channel) &key (size 1) &rest initargs

Creates a new buffered channel object with a limited buffer size. The buffer has a maximum size of SIZE. Bounded channel buffers are FIFO. When the buffer is full, SEND will block until something is RECVd from the channel.

SIZE must be positive and less than +maximum-buffer-size+, and defaults to 1.

[method] make-instance (class stack-channel) &rest initargs

Returns a new buffered channel with a LIFO buffer with no maximum length.

[constant] +maximum-buffer-size+

This constant has an implementation-dependant value, fixed when ChanL is loaded. It is the exclusive upper bound to the size of a bounded-channel's buffer.

Note that this value might be further limited by memory constraints.

[generic function] send channel value &key

[method] send (channel channel) value &key (blockp t)

Tries to send VALUE into CHANNEL. If the channel is unbufferd or buffered but full, this operation will block until RECV is called on the channel. Returns the channel that the value was sent into. If blockp is NIL, NIL is returned immediately instead of a channel if attempting to send would block.

[method] send (channels sequence) value &key (blockp t)

SEND may be used on a sequence of channels. SEND will linearly attempt to send VALUE into one of the channels in the sequence. It will return immediately as soon as it is able to send VALUE into one channel. If BLOCKP is T (default), SEND will continue to block until one operation succeeds, otherwise, it will return NIL when the sequence has been exhausted.

[generic function] recv channel &key

[method] recv (channel channel) &key (blockp t)

Tries to receive a value from CHANNEL. If the channel is unbuffered, or buffered but empty, this operation will block until SEND is called on the channel. Returns two values: 1. The value received through the channel, and 2. The channel the value was sent into. If BLOCKP is nil, this operation will not block, and will return (values NIL NIL) if attempting it would block.

[method] recv (channel sequence) &key (blockp t)

RECV may be used on a sequence of channels. RECV will linearly attempt to receive a value from one of the channels in teh sequence. It will return immediately as soon as one channel has a value available. As with the method for CHANNEL, this will return the value received, as well as the channel the value was received from. If BLOCKP is NIL, and operating on all channels in sequence would block, (values NIL NIL) is returned instead of blocking.

[macro] select &body clauses* Non-deterministically select a non-blocking clause to execute.

The syntax is:

  select clause*
      clause ::= (op form*)
      op ::= (recv c &optional variable channel-var) | (send c value &optional channel-var)
             | else | otherwise | t
      c ::= An evaluated form representing a channel, or a sequence of channels.
      variable ::= an unevaluated symbol RECV's return value is to be bound to.
      value ::= An evaluated form representing a value to send into the channel.
      channel-var ::= An unevaluated symbol that will be bound to the channel the SEND/RECV
                      operation succeeded on.

SELECT will first attempt to find a clause with a non-blocking op, and execute it. Execution of the check-if-blocks-and-do-it part is atomic, but execution of the clause's body once the SEND/RECV clause executes is NOT atomic. If all channel clauses would block, and no else clause is provided, SELECT will block until one of the clauses is available for execution.

SELECT's non-determinism is, in fact, very non-deterministic. Clauses are chosen at random, not in the order they are written. It's worth noting that SEND/RECV, when used on sequences of channels, are still linear in the way they go through the sequence -- the random selection is reserved for individual SELECT clauses.

Please note that currently, the form for the channel in the RECV and SEND clauses and for the value in the SEND clause might be evaluated multiple times in an unspecified order. It is thus undesirable to place forms with side-effects in these places. This is a bug and will be fixed in a future version of ChanL.

Thread API

[special variable] *default-special-bindings*

An alist of bindings new threads should have. The format is: '((var1 'value) (var2 'value2)).

[function] pcall function &key initial-bindings name

PCALL, a mnemonic for Parallel Call, calls FUNCTION in a new thread. FUNCTION must be a function of zero arguments. INITIAL-BINDINGS, if provided, should be an alist with the same format as default-special-bindings representing dynamic variable bindings that FUNCTION is to be executed with. The default value for INITIAL-BINDINGS is DEFAULT-SPECIAL-BINDINGS.

PCALL returns a task object representing this task. This object is intended for interactive use (ie for debugging), and contains a bit of metadata about the execution. The NAME argument can be used to initialize the name slot of the task object.

[macro] pexec (&key (initial-bindings *default-special-bindings*)) &body body

Executes BODY in parallel. INITIAL-BINDINGS, if provided, should be an alist representing dynamic variable bindings that BODY is to be executed with, as if with default-special-bindings. NAME can be used to initialize the name slot of the returned task object. PEXEC also returns a task.

Thread Introspection

ChanL includes portable support for lisp threads through bordeaux-threads, and adds some sugar on top, such as a built-in thread pool. None of the thread functions here should be used in user code, since they are meant exclusively for development purposes. Most thread-related matters are automatically handled by the thread pool already. In fact, not a single one of these should be expected to work properly when you use them, so do so at your own risk.

[class] task

Tasks represent the bits of work carried out by threads. Task objects should be treated as read- only debugging aids. The functions TASK-NAME, TASK-THREAD, and TASK-STATUS return metadata about the task. Since this is an experimental feature, its API is likely to change -- the current behavior can be checked in src/threads.lisp.

[function] current-thread

Returns the current thread

[function] thread-alive-p thread

T if THREAD is still alive

[function] threadp maybe-thread

T if maybe-thread is, in fact, a thread.

[function] thread-name thread

Returns the name of the thread.

[function] kill thread

Kills thread dead.

[function] all-threads

Returns a list of all threads currently running in the lisp image.

[function] pooled-threads

Returns a list of all threads currently managed by ChanL's thread pool.

[function] pooled-tasks

Returns a list of all tasks pending or live in ChanL's thread pool.

[symbol-macro] %thread-pool-soft-limit

This is a SETFable place. It may be used to inspect and change the soft limit for how many threads the thread pool keeps around. Note that the total number of threads will exceed this limit if threads continue to be spawned while others are still running. This only refers to the number of threads kept alive for later use. The default value is 1000.

Writing your own channels

Currently, ChanL provides a very early API for writing your own channels easily.

[class] abstract-channel

This class is the ancestral superclass of all channels. CHANNELP returns T for any instances of this class or its subclasses.

Direct subclasses of abstract-channel will have to define their own SEND/RECV methods, which should meet the API requirements in order to be compatible with ChanL.

[class] channel

This is the main unbuffered class used in ChanL. Unless you wish to write a new synchronization algorithm for your custom channels, you should subclass CHANNEL, since you then get to reuse ChanL's build-in algorithm (which relies on locks and condition variables).

Subclasses of the CHANNEL class are able to extend behavior in a fairly flexible way by simply writing methods for the following 4 generic functions:

[generic function] send-blocks-p channel

This function returns, as a generalized boolean, whether SEND should block on this channel.

[generic function] recv-blocks-p channel

Like send-blocks-p, but for RECV.

Please note that the consequences of calling send-blocks-p and recv-blocks-p in user code are undefined -- these functions are called from specific points within the carefully instrumented algorithms of the SEND and RECV methods specialized on the CHANNEL class.

[generic function] channel-insert-value channel value

Methods on this function define what actions are taken to insert a value into a channel. Methods should be specialized only on the first argument. This function's return values are ignored.

[generic function] channel-grab-value channel

Methods on this function define how to retrieve a value from a channel. This function must return at least one value, the object retrieved from the channel, which will then be returned by RECV.

Additionally, ChanL uses and exports a number of abstract and concrete classes to implement its buffered channels:

[abstract class] buffered-channel

Abstract class for channels using various buffering styles.

[abstract class] queue-channel

Abstract class for channels whose buffer works like a queue.

[class] bounded-channel

Class used by ChanL's bounded channels (queue channels that block when the queue reaches a certain length).

[class] unbounded-channel

Class used by ChanL's unbounded channels, which are queues of unlimited length (SEND never blocks)

[class] stack-channel

Class used by ChanL's stack channels. These channels' buffers are unbounded LIFO stack structures.

Examples

Create a channel:

 (defvar *c* (make-instance 'channel))

Create a buffered channel with a buffer size of 5. Buffered channels do not block on send until their buffer is full, or on recv until their buffer is empty.

 (defvar *c* (make-instance 'bounded-channel :size 5))

Read a value from a channel (blocks if channel is empty)

 (recv *c*)

Write a value to a channel (blocks if channel is full, always blocks on unbuffered channels)

 (send *c* 99)

Wait for any of a number of things to occur:

 (select
   ((recv c d)
    (format t "got ~a from c~%" d))
   ((send e val)
    (print "sent val on e~%"))
   ((recv *lots-of-channels* value channel)
    (format t "Got ~A from ~C~%" value channel))
   (otherwise
    (print "would have blocked~%")))

Create a new thread continually reading values and printing them:

 (pexec ()
   (loop (format t "~a~%" (recv *c*))))

Create a new thread that runs a function:

 (pcall #'my-function)

Please refer to the examples/ directory for examples of how ChanL can be used, including a parallel prime sieve algorithm translated from Newsqueak and an implementation of future-based concurrency.


Next: , Previous: , Up: Top   [Contents][Index]

2 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

2.1 chanl

Maintainer

Adlai Chandrasekhar

Author

Kat Marchan

Description

Communicating Sequential Process support for Common Lisp

Dependency

bordeaux-threads

Source

chanl.asd (file)

Component

src (module)


Next: , Previous: , Up: Top   [Contents][Index]

3 Modules

Modules are listed depth-first from the system components tree.


Previous: , Up: Modules   [Contents][Index]

3.1 chanl/src

Parent

chanl (system)

Location

src/

Components

Next: , Previous: , Up: Top   [Contents][Index]

4 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

4.1 Lisp


Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.1 chanl.asd

Location

chanl.asd

Systems

chanl (system)


Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.2 chanl/src/trivial-cas.lisp

Parent

src (module)

Location

src/trivial-cas.lisp

Packages

trivial-compare-and-swap

Exported Definitions

atomic-incf (macro)


Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.3 chanl/src/package.lisp

Dependency

trivial-cas.lisp (file)

Parent

src (module)

Location

src/package.lisp

Packages

chanl


Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.4 chanl/src/utils.lisp

Dependency

package.lisp (file)

Parent

src (module)

Location

src/utils.lisp

Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.5 chanl/src/threads.lisp

Dependency

utils.lisp (file)

Parent

src (module)

Location

src/threads.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.6 chanl/src/queues.lisp

Dependency

threads.lisp (file)

Parent

src (module)

Location

src/queues.lisp

Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.7 chanl/src/channels.lisp

Dependency

queues.lisp (file)

Parent

src (module)

Location

src/channels.lisp

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Lisp files   [Contents][Index]

4.1.8 chanl/src/select.lisp

Dependency

channels.lisp (file)

Parent

src (module)

Location

src/select.lisp

Exported Definitions

select (macro)

Internal Definitions

Previous: , Up: Lisp files   [Contents][Index]

4.1.9 chanl/src/actors.lisp

Dependency

select.lisp (file)

Parent

src (module)

Location

src/actors.lisp

Packages

chanl.actors

Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

5 Packages

Packages are listed by definition order.


Next: , Previous: , Up: Packages   [Contents][Index]

5.1 trivial-compare-and-swap

Source

trivial-cas.lisp (file)

Nickname

trivial-cas

Use List

common-lisp

Used By List

chanl

Exported Definitions

atomic-incf (macro)


Next: , Previous: , Up: Packages   [Contents][Index]

5.2 chanl

Source

package.lisp (file)

Use List
Used By List

chanl.actors

Exported Definitions
Internal Definitions

Previous: , Up: Packages   [Contents][Index]

5.3 chanl.actors

Source

actors.lisp (file)

Use List
Exported Definitions
Internal Definitions

Next: , Previous: , Up: Top   [Contents][Index]

6 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

6.1 Exported definitions


Next: , Previous: , Up: Exported definitions   [Contents][Index]

6.1.1 Constants

Constant: +maximum-buffer-size+

The exclusive upper bound on the size of a channel’s buffer.

Package

chanl

Source

channels.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

6.1.2 Special variables

Special Variable: *boss*
Package

chanl.actors

Source

actors.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

6.1.3 Symbol macros

Symbol Macro: %thread-pool-soft-limit
Package

chanl

Source

threads.lisp (file)

Expansion

(chanl::pool-soft-limit chanl::*thread-pool*)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

6.1.4 Macros

Macro: atomic-incf PLACE &optional DELTA
Package

trivial-compare-and-swap

Source

trivial-cas.lisp (file)

Macro: pexec (&key INITIAL-BINDINGS NAME) &body BODY

Executes BODY in parallel. INITIAL-BINDINGS, if provided, should be an alist representing dynamic variable bindings that BODY is to be executed with. The format is: ’((*var* value)).

Package

chanl

Source

threads.lisp (file)

Macro: select &body CLAUSES

Non-deterministically select a non-blocking clause to execute.

The syntax is:

select clause*
clause ::= (op form*)
op ::= (recv c &optional variable channel-var) | (send c value &optional channel-var)
| else | otherwise | t
c ::= An evaluated form representing a channel, or a sequence of channels.
variable ::= an unevaluated symbol RECV’s return value is to be bound to. Made available to form*. value ::= An evaluated form representing a value to send into the channel.
channel-var ::= An unevaluated symbol that will be bound to the channel the SEND/RECV operation succeeded on.

SELECT will first attempt to find a clause with a non-blocking op, and execute it. Execution of the check-if-blocks-and-do-it part is atomic, but execution of the clause’s body once the SEND/RECV clause executes is NOT atomic. If all channel clauses would block, and no else clause is provided, SELECT will thrash-idle (an undesirable state!) until one of the clauses is available for execution.

SELECT’s non-determinism is, in fact, very non-deterministic. Clauses are chosen at random, not in the order they are written. It’s worth noting that SEND/RECV, when used on sequences of channels, are still linear in the way they go through the sequence – the random selection is reserved for individual SELECT clauses.

Package

chanl

Source

select.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

6.1.5 Functions

Function: all-threads ()
Package

chanl

Source

threads.lisp (file)

Function: current-thread ()
Package

chanl

Source

threads.lisp (file)

Function: fire ACTOR
Package

chanl.actors

Source

actors.lisp (file)

Function: halt ACTOR
Package

chanl.actors

Source

actors.lisp (file)

Function: kill PROC
Package

chanl

Source

threads.lisp (file)

Function: pcall FUNCTION &key INITIAL-BINDINGS NAME

PCALL -> Parallel Call; calls FUNCTION in a new thread. FUNCTION must be a no-argument function. INITIAL-BINDINGS, if provided, should be an alist representing dynamic variable bindings that BODY is to be executed with. The format is: ’((*var* value)).

Package

chanl

Source

threads.lisp (file)

Function: pooled-tasks ()
Package

chanl

Source

threads.lisp (file)

Function: pooled-threads ()
Package

chanl

Source

threads.lisp (file)

Function: slot-channel ACTOR SLOT

Returns the channel associated with ‘slot’ in ‘actor’

Package

chanl.actors

Source

actors.lisp (file)

Function: thread-alive-p PROC
Package

chanl

Source

threads.lisp (file)

Function: thread-name PROC
Package

chanl

Source

threads.lisp (file)

Function: threadp PROC
Package

chanl

Source

threads.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

6.1.6 Generic functions

Generic Function: boss OBJECT
Package

chanl.actors

Methods
Method: boss (ACTOR actor)

For whom[’s benefit] the bell tolls

Source

actors.lisp (file)

Generic Function: channel-grab-value CHANNEL
Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-grab-value (CHANNEL cas-channel)
Method: channel-grab-value (CHANNEL queue-channel)
Method: channel-grab-value (CHANNEL stack-channel)
Method: channel-grab-value (CHANNEL channel)
Generic Function: channel-insert-value CHANNEL VALUE
Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-insert-value (CHANNEL cas-channel) VALUE
Method: channel-insert-value (CHANNEL queue-channel) VALUE
Method: channel-insert-value (CHANNEL stack-channel) VALUE
Method: channel-insert-value (CHANNEL channel) VALUE
Generic Function: channelp CHANNEL
Package

chanl

Source

channels.lisp (file)

Methods
Method: channelp ANYTHING-ELSE
Method: channelp (CHANNEL abstract-channel)
Generic Function: christen ACTOR
Package

chanl.actors

Source

actors.lisp (file)

Methods
Method: christen (ACTOR actor)
Method: christen (ACTOR actor) around
Generic Function: compute-tubes ACTOR

Calculates the list of communication slots for ‘actor’.
Methods should return a list of specifications (or a single one as an atom)

Package

chanl.actors

Source

actors.lisp (file)

Method Combination

list (short method combination)

Options: :most-specific-last

Methods
Method: compute-tubes (BOSS boss) list
Method: compute-tubes (ACTOR actor) around

Combines the specifications, creating channels if necessary

Method: compute-tubes (ACTOR actor) list
Generic Function: ensure-running ACTOR
Package

chanl.actors

Source

actors.lisp (file)

Methods
Method: ensure-running (BOSS boss) after
Method: ensure-running (ACTOR actor)
Generic Function: execute ACTOR COMMAND
Package

chanl.actors

Source

actors.lisp (file)

Methods
Method: execute (BOSS boss) (COMMAND (eql die)) before
Method: execute (ACTOR actor) (COMMAND function)
Method: execute (ACTOR actor) (COMMAND (eql die))
Generic Function: name OBJECT
Package

chanl.actors

Methods
Method: name (ACTOR actor)

Name for identifying this actor and its tasks

Source

actors.lisp (file)

Generic Function: perform ACTOR

Implement actor’s behavior, executing commands by default

Package

chanl.actors

Source

actors.lisp (file)

Method Combination

select (long method combination)

Methods
Method: perform (BOSS boss) recv to-fire
Method: perform (BOSS boss) recv to-halt
Method: perform (BOSS boss) recv to-run
Method: perform (ACTOR actor) recv command
Generic Function: recv CHAN &key BLOCKP

Tries to receive from either a single channel, or a sequence of channels. If
BLOCKP is true, RECV will block until it’s possible to receive something. Returns two values: The first is the actual value received through the channel. The second is the channel the value was received from. When BLOCKP is NIL, RECV will immediately return (values NIL NIL) instead of blocking (if it would block)

Package

chanl

Source

channels.lisp (file)

Methods
Method: recv (CHANNEL cas-channel) &key BLOCKP
Method: recv (CHANNEL channel) &key BLOCKP
Method: recv (CHANNELS null) &key
Method: recv (CHANNELS sequence) &key BLOCKP
Generic Function: recv-blocks-p CHANNEL
Package

chanl

Source

channels.lisp (file)

Methods
Method: recv-blocks-p (CHANNEL cas-channel)
Method: recv-blocks-p (CHANNEL unbounded-channel)
Method: recv-blocks-p (CHANNEL bounded-channel)
Method: recv-blocks-p (CHANNEL stack-channel)
Method: recv-blocks-p (CHANNEL channel)
Generic Function: send CHAN VALUE &key BLOCKP

Tries to send VALUE into CHAN. If a sequence of channels is provided
instead of a single channel, SEND will send the value into the first channel that doesn’t block. If BLOCKP is true, SEND will continue to block until it’s able to actually send a value. If BLOCKP is NIL, SEND will immediately return NIL instead of blocking, if there’s no channel available to send input into. When SEND succeeds, it returns the channel the value was sent into.

Package

chanl

Source

channels.lisp (file)

Methods
Method: send (CHANNEL cas-channel) VALUE &key BLOCKP
Method: send (CHANNEL channel) VALUE &key BLOCKP
Method: send (CHANNELS null) VALUE &key
Method: send (CHANNELS sequence) VALUE &key BLOCKP
Generic Function: send-blocks-p CHANNEL

Returns T if trying to SEND to CHANNEL would block. Note that this is not an atomic operation, and should not be relied on in production. It’s mostly meant for interactive/debugging purposes.

Package

chanl

Source

channels.lisp (file)

Methods
Method: send-blocks-p (CHANNEL cas-channel)
Method: send-blocks-p (CHANNEL unbounded-channel)
Method: send-blocks-p (CHANNEL bounded-channel)
Method: send-blocks-p (CHANNEL stack-channel)
Method: send-blocks-p (CHANNEL channel)
Generic Function: task-name OBJECT
Generic Function: (setf task-name) NEW-VALUE OBJECT
Package

chanl

Methods
Method: task-name (TASK task)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf task-name) NEW-VALUE (TASK task)

automatically generated writer method

Source

threads.lisp (file)

Generic Function: task-status OBJECT
Generic Function: (setf task-status) NEW-VALUE OBJECT
Package

chanl

Methods
Method: task-status (TASK task)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf task-status) NEW-VALUE (TASK task)

automatically generated writer method

Source

threads.lisp (file)

Generic Function: task-thread OBJECT
Generic Function: (setf task-thread) NEW-VALUE OBJECT
Package

chanl

Methods
Method: task-thread (TASK task)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf task-thread) NEW-VALUE (TASK task)

automatically generated writer method

Source

threads.lisp (file)


Next: , Previous: , Up: Exported definitions   [Contents][Index]

6.1.7 Method combinations

Long Method Combination: select ()
Package

chanl

Source

actors.lisp (file)

Users

perform (generic function)


Previous: , Up: Exported definitions   [Contents][Index]

6.1.8 Classes

Class: abstract-channel ()
Package

chanl

Source

channels.lisp (file)

Direct superclasses

standard-object (class)

Direct subclasses
Direct methods

channelp (method)

Class: actor ()
Package

chanl.actors

Source

actors.lisp (file)

Direct superclasses

standard-object (class)

Direct subclasses

boss (class)

Direct methods
Direct slots
Slot: name

Name for identifying this actor and its tasks

Initargs

:name

Readers

name (generic function)

Slot: abbrev
Allocation

:class

Slot: state

Represents/performs actor’s state

Initform

(quote chanl.actors:perform)

Slot: tubes

Channels used for communication

Slot: boss

For whom[’s benefit] the bell tolls

Type

(or null bordeaux-threads:thread chanl.actors:boss)

Initargs

:boss

Initform

chanl.actors:*boss*

Readers

boss (generic function)

Slot: command

Command being executed by the actor

Class: boss ()
Package

chanl.actors

Source

actors.lisp (file)

Direct superclasses

actor (class)

Direct methods
Direct slots
Slot: workers

Workers managed by this boss

Slot: to-run

New actor to manage

Slot: to-halt

Actor to halt, but keep its link

Slot: to-fire

Actor to both halt and unlink

Class: bounded-channel ()
Package

chanl

Source

channels.lisp (file)

Direct superclasses

queue-channel (class)

Direct methods
Class: buffered-channel ()

Abstract class for channels using various buffering styles.

Package

chanl

Source

channels.lisp (file)

Direct superclasses

channel (class)

Direct subclasses
Direct methods

channel-buffered-p (method)

Class: cas-channel ()

These channels use COMPARE-AND-SWAP to do their thing, instead of locks+condition-vars. Ideally, these would be faster than regular channels. In reality, they’re not. It’s possible there might be a way to speed these guys up while keeping the same behavior in the interface, but for now, they’re about 100x slower, not to mention non-portable.

Package

chanl

Source

channels.lisp (file)

Direct superclasses

abstract-channel (class)

Direct methods
Direct slots
Slot: vector
Initform

(vector chanl::*secret-unbound-value* 0 0 nil)

Readers

channel-vector (generic function)

Writers

(setf channel-vector) (generic function)

Class: channel ()
Package

chanl

Source

channels.lisp (file)

Direct superclasses

abstract-channel (class)

Direct subclasses

buffered-channel (class)

Direct methods
Direct slots
Slot: value
Initform

chanl::*secret-unbound-value*

Readers

channel-value (generic function)

Writers

(setf channel-value) (generic function)

Slot: readers
Initform

0

Readers

channel-readers (generic function)

Writers

(setf channel-readers) (generic function)

Slot: writers
Initform

0

Readers

channel-writers (generic function)

Writers

(setf channel-writers) (generic function)

Slot: lock
Initform

(bordeaux-threads:make-recursive-lock)

Readers

channel-lock (generic function)

Writers

(setf channel-lock) (generic function)

Slot: send-ok
Initform

(bordeaux-threads:make-condition-variable)

Readers

channel-send-ok (generic function)

Writers

(setf channel-send-ok) (generic function)

Slot: recv-ok
Initform

(bordeaux-threads:make-condition-variable)

Readers

channel-recv-ok (generic function)

Writers

(setf channel-recv-ok) (generic function)

Slot: send-return-wait
Initform

(bordeaux-threads:make-condition-variable)

Readers

channel-send-return-wait (generic function)

Writers

(setf channel-send-return-wait) (generic function)

Slot: recv-grabbed-value-p
Readers

recv-grabbed-value-p (generic function)

Writers

(setf recv-grabbed-value-p) (generic function)

Class: queue-channel ()

These channels buffer objects in some sort of queue.

Package

chanl

Source

channels.lisp (file)

Direct superclasses

buffered-channel (class)

Direct subclasses
Direct methods
Class: stack-channel ()
Package

chanl

Source

channels.lisp (file)

Direct superclasses

buffered-channel (class)

Direct methods
Class: task ()
Package

chanl

Source

threads.lisp (file)

Direct superclasses

standard-object (class)

Direct methods
Direct slots
Slot: name
Initargs

:name

Initform

"anonymous task"

Readers

task-name (generic function)

Writers

(setf task-name) (generic function)

Slot: function
Initargs

:function

Initform

(error "must supply a task-function")

Readers

task-function (generic function)

Slot: status
Initform

:pending

Readers

task-status (generic function)

Writers

(setf task-status) (generic function)

Slot: thread
Readers

task-thread (generic function)

Writers

(setf task-thread) (generic function)

Class: unbounded-channel ()
Package

chanl

Source

channels.lisp (file)

Direct superclasses

queue-channel (class)

Direct methods

Previous: , Up: Definitions   [Contents][Index]

6.2 Internal definitions


Next: , Previous: , Up: Internal definitions   [Contents][Index]

6.2.1 Special variables

Special Variable: *secret-unbound-value*

This value is used as a sentinel in channels.

Package

chanl

Source

channels.lisp (file)

Special Variable: *thread-pool*
Package

chanl

Source

threads.lisp (file)

Special Variable: queue-sentinel
Package

chanl

Source

queues.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

6.2.2 Macros

Macro: aif TEST THEN &optional ELSE
Package

chanl

Source

utils.lisp (file)

Macro: awhen TEST &body BODY
Package

chanl

Source

utils.lisp (file)

Macro: define-print-object ((OBJECT CLASS) &key IDENTITY TYPE) &body BODY
Package

chanl

Source

utils.lisp (file)

Macro: define-speedy-function NAME ARGS &body BODY
Package

chanl

Source

utils.lisp (file)

Macro: econd &body COND-CLAUSES

Like ‘ecase’, but for ‘cond’. An optional initial string is used as the error message.

Package

chanl

Source

utils.lisp (file)

Macro: fun &body BODY

This macro puts the FUN back in FUNCTION.

Package

chanl

Source

utils.lisp (file)

Macro: pop-declarations PLACE

Returns and removes all leading declarations from PLACE, which should be a setf-able form. NOTE: Does not support docstrings.

Package

chanl

Source

utils.lisp (file)

Macro: pushend NEW-ITEM LIST LIST-END
Package

chanl

Source

utils.lisp (file)

Macro: when-bind VARIABLE TEST &body BODY
Package

chanl

Source

utils.lisp (file)

Macro: with-cas-read-state CHANNEL &body BODY
Package

chanl

Source

channels.lisp (file)

Macro: with-cas-write-state CHANNEL &body BODY
Package

chanl

Source

channels.lisp (file)

Macro: with-gensyms NAMES &body BODY
Package

chanl

Source

utils.lisp (file)

Macro: with-read-state CHANNEL &body BODY
Package

chanl

Source

channels.lisp (file)

Macro: with-write-state CHANNEL &body BODY
Package

chanl

Source

channels.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

6.2.3 Functions

Function: %dequeue ()

Sets QUEUE’s tail to QUEUE, increments QUEUE’s tail pointer, and returns the previous tail ref

Package

chanl

Source

queues.lisp (file)

Function: %enqueue ()

Enqueue OBJECT and increment QUEUE’s entry pointer

Package

chanl

Source

queues.lisp (file)

Function: %kill ACTOR
Package

chanl.actors

Source

actors.lisp (file)

Function: %make-queue ()

Creates a new queue of maximum size LENGTH

Package

chanl

Source

queues.lisp (file)

Function: %next-index ()
Package

chanl

Source

queues.lisp (file)

Function: %queue-count ()

Returns QUEUE’s effective length

Package

chanl

Source

queues.lisp (file)

Function: %queue-empty-p ()

Checks whether QUEUE is effectively empty

Package

chanl

Source

queues.lisp (file)

Function: %queue-full-p ()

Checks whether QUEUE is effectively full

Package

chanl

Source

queues.lisp (file)

Function: %queue-in ()

QUEUE’s entry pointer

Package

chanl

Source

queues.lisp (file)

Function: %queue-length ()

Returns QUEUE’s maximum length

Package

chanl

Source

queues.lisp (file)

Function: %queue-out ()

QUEUE’s exit pointer

Package

chanl

Source

queues.lisp (file)

Function: %queue-peek ()

Dereference QUEUE’s exit pointer

Package

chanl

Source

queues.lisp (file)

Function: %queue-zero-p ()

Checks whether QUEUE’s theoretical length is zero

Package

chanl

Source

queues.lisp (file)

Function: cas-channel-set SLOT-NAME CHANNEL VALUE
Package

chanl

Source

channels.lisp (file)

Function: channel-being-read-p CHANNEL
Package

chanl

Source

channels.lisp (file)

Function: channel-being-written-p CHANNEL
Package

chanl

Source

channels.lisp (file)

Function: clause-type CLAUSE
Package

chanl

Source

select.lisp (file)

Function: dequeue QUEUE

Dequeues QUEUE

Package

chanl

Source

queues.lisp (file)

Function: enqueue OBJECT QUEUE

Enqueues OBJECT in QUEUE

Package

chanl

Source

queues.lisp (file)

Function: ensure-list X
Package

chanl

Source

utils.lisp (file)

Function: launch ACTOR
Package

chanl.actors

Source

actors.lisp (file)

Function: make-queue SIZE

Makes a queue of maximum size SIZE

Package

chanl

Source

queues.lisp (file)

Function: map-workers BOSS FUNCTION
Package

chanl.actors

Source

actors.lisp (file)

Function: new-worker-thread THREAD-POOL &optional TASK
Package

chanl

Source

threads.lisp (file)

Function: nunzip-alist ALIST &aux KEYS VALS

Destructive, non-consing version of ‘unzip-alist’.

Package

chanl

Source

utils.lisp (file)

Function: queue-count QUEUE

Returns the current size of QUEUE

Package

chanl

Source

queues.lisp (file)

Function: queue-empty-p QUEUE

Tests whether QUEUE is empty

Package

chanl

Source

queues.lisp (file)

Function: queue-full-p QUEUE

Tests whether QUEUE is full

Package

chanl

Source

queues.lisp (file)

Function: queue-length QUEUE

Returns the maximum size of QUEUE

Package

chanl

Source

queues.lisp (file)

Function: queue-peek QUEUE
Package

chanl

Source

queues.lisp (file)

Function: queuep ()

If this returns NIL, X is not a queue

Package

chanl

Source

queues.lisp (file)

Function: strftime &optional DATEP &aux BITS
Package

chanl.actors

Source

actors.lisp (file)

Function: unzip-alist ALIST

Returns two fresh lists containing the keys and values of ALIST

Package

chanl

Source

utils.lisp (file)

Function: wrap-select-clause CLAUSE
Package

chanl

Source

select.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

6.2.4 Generic functions

Generic Function: act CLASS &key
Package

chanl.actors

Source

actors.lisp (file)

Methods
Method: act (CLASS symbol) &rest INITARGS
Generic Function: assign-task THREAD-POOL TASK
Package

chanl

Source

threads.lisp (file)

Methods
Method: assign-task (THREAD-POOL thread-pool) (TASK task)
Generic Function: channel-buffered-p CHANNEL
Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-buffered-p ANYTHING-ELSE
Method: channel-buffered-p (CHANNEL buffered-channel)
Generic Function: channel-dequeue CHANNEL

Dequeue a value from CHANNEL’s buffer queue.

Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-dequeue (CHANNEL unbounded-channel)
Method: channel-dequeue (CHANNEL bounded-channel)
Generic Function: channel-enqueue VALUE CHANNEL

Enqueue VALUE in CHANNEL’s buffer queue.

Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-enqueue VALUE (CHANNEL unbounded-channel)
Method: channel-enqueue VALUE (CHANNEL bounded-channel)
Generic Function: channel-lock OBJECT
Generic Function: (setf channel-lock) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-lock (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-lock) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: channel-peek CHANNEL

Peek at the next value CHANNEL would dequeue. Note that this cannot
be used atomically. Returns two values: The first is the value of interest or NIL, the second is a generalized boolean that is NIL when there is no available value in the queue.

Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-peek (CHANNEL unbounded-channel)
Method: channel-peek (CHANNEL bounded-channel)
Method: channel-peek (CHANNEL stack-channel)
Generic Function: channel-pop CHANNEL
Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-pop (CHANNEL stack-channel)
Generic Function: channel-push VALUE CHANNEL
Package

chanl

Source

channels.lisp (file)

Methods
Method: channel-push VALUE (CHANNEL stack-channel)
Generic Function: channel-readers OBJECT
Generic Function: (setf channel-readers) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-readers (CHANNEL cas-channel)
Source

channels.lisp (file)

Method: channel-readers (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-readers) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: channel-recv-ok OBJECT
Generic Function: (setf channel-recv-ok) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-recv-ok (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-recv-ok) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: channel-send-ok OBJECT
Generic Function: (setf channel-send-ok) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-send-ok (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-send-ok) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: channel-send-return-wait OBJECT
Generic Function: (setf channel-send-return-wait) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-send-return-wait (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-send-return-wait) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: channel-value OBJECT
Generic Function: (setf channel-value) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-value (CHANNEL cas-channel)
Source

channels.lisp (file)

Method: channel-value (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-value) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: channel-vector OBJECT
Generic Function: (setf channel-vector) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-vector (CAS-CHANNEL cas-channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-vector) NEW-VALUE (CAS-CHANNEL cas-channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: channel-writers OBJECT
Generic Function: (setf channel-writers) NEW-VALUE OBJECT
Package

chanl

Methods
Method: channel-writers (CHANNEL cas-channel)
Source

channels.lisp (file)

Method: channel-writers (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf channel-writers) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: free-thread-counter OBJECT
Generic Function: (setf free-thread-counter) NEW-VALUE OBJECT
Package

chanl

Methods
Method: free-thread-counter (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf free-thread-counter) NEW-VALUE (THREAD-POOL thread-pool)

automatically generated writer method

Source

threads.lisp (file)

Generic Function: pool-leader-lock OBJECT
Package

chanl

Methods
Method: pool-leader-lock (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Generic Function: pool-leader-notifier OBJECT
Package

chanl

Methods
Method: pool-leader-notifier (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Generic Function: pool-lock OBJECT
Package

chanl

Methods
Method: pool-lock (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Generic Function: pool-pending-tasks OBJECT
Generic Function: (setf pool-pending-tasks) NEW-VALUE OBJECT
Package

chanl

Methods
Method: pool-pending-tasks (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf pool-pending-tasks) NEW-VALUE (THREAD-POOL thread-pool)

automatically generated writer method

Source

threads.lisp (file)

Generic Function: pool-soft-limit OBJECT
Generic Function: (setf pool-soft-limit) NEW-VALUE OBJECT
Package

chanl

Methods
Method: pool-soft-limit (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf pool-soft-limit) NEW-VALUE (THREAD-POOL thread-pool)

automatically generated writer method

Source

threads.lisp (file)

Generic Function: pool-tasks OBJECT
Generic Function: (setf pool-tasks) NEW-VALUE OBJECT
Package

chanl

Methods
Method: pool-tasks (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf pool-tasks) NEW-VALUE (THREAD-POOL thread-pool)

automatically generated writer method

Source

threads.lisp (file)

Generic Function: pool-threads OBJECT
Generic Function: (setf pool-threads) NEW-VALUE OBJECT
Package

chanl

Methods
Method: pool-threads (THREAD-POOL thread-pool)

automatically generated reader method

Source

threads.lisp (file)

Method: (setf pool-threads) NEW-VALUE (THREAD-POOL thread-pool)

automatically generated writer method

Source

threads.lisp (file)

Generic Function: queue-condition-queue CONDITION
Package

chanl

Methods
Method: queue-condition-queue (CONDITION queue-condition)
Source

queues.lisp (file)

Generic Function: queue-error-attempted-length CONDITION
Package

chanl

Methods
Method: queue-error-attempted-length (CONDITION queue-length-error)
Source

queues.lisp (file)

Generic Function: queue-overflow-extra-item CONDITION
Package

chanl

Methods
Method: queue-overflow-extra-item (CONDITION queue-overflow-error)
Source

queues.lisp (file)

Generic Function: recv-grabbed-value-p OBJECT
Generic Function: (setf recv-grabbed-value-p) NEW-VALUE OBJECT
Package

chanl

Methods
Method: recv-grabbed-value-p (CHANNEL cas-channel)
Source

channels.lisp (file)

Method: recv-grabbed-value-p (CHANNEL channel)

automatically generated reader method

Source

channels.lisp (file)

Method: (setf recv-grabbed-value-p) NEW-VALUE (CHANNEL channel)

automatically generated writer method

Source

channels.lisp (file)

Generic Function: task-function OBJECT
Package

chanl

Methods
Method: task-function (TASK task)

automatically generated reader method

Source

threads.lisp (file)


Next: , Previous: , Up: Internal definitions   [Contents][Index]

6.2.5 Conditions

Condition: queue-condition ()
Package

chanl

Source

queues.lisp (file)

Direct superclasses

error (condition)

Direct subclasses
Direct methods

queue-condition-queue (method)

Direct slots
Slot: queue
Initargs

:queue

Readers

queue-condition-queue (generic function)

Condition: queue-length-error ()
Package

chanl

Source

queues.lisp (file)

Direct superclasses

queue-condition (condition)

Direct methods

queue-error-attempted-length (method)

Direct slots
Slot: attempted-length
Initargs

:attempted-length

Readers

queue-error-attempted-length (generic function)

Condition: queue-overflow-error ()
Package

chanl

Source

queues.lisp (file)

Direct superclasses

queue-condition (condition)

Direct methods

queue-overflow-extra-item (method)

Direct slots
Slot: item
Initargs

:item

Readers

queue-overflow-extra-item (generic function)

Condition: queue-underflow-error ()
Package

chanl

Source

queues.lisp (file)

Direct superclasses

queue-condition (condition)


Previous: , Up: Internal definitions   [Contents][Index]

6.2.6 Classes

Class: thread-pool ()
Package

chanl

Source

threads.lisp (file)

Direct superclasses

standard-object (class)

Direct methods
Direct slots
Slot: threads
Readers

pool-threads (generic function)

Writers

(setf pool-threads) (generic function)

Slot: free-thread-counter
Initform

0

Readers

free-thread-counter (generic function)

Writers

(setf free-thread-counter) (generic function)

Slot: soft-limit
Initform

1000

Readers

pool-soft-limit (generic function)

Writers

(setf pool-soft-limit) (generic function)

Slot: lock
Initform

(bordeaux-threads:make-lock "thread pool lock")

Readers

pool-lock (generic function)

Slot: leader-lock
Initform

(bordeaux-threads:make-lock "thread leader lock")

Readers

pool-leader-lock (generic function)

Slot: leader-notifier
Initform

(bordeaux-threads:make-condition-variable)

Readers

pool-leader-notifier (generic function)

Slot: pending-tasks
Readers

pool-pending-tasks (generic function)

Writers

(setf pool-pending-tasks) (generic function)

Slot: tasks
Readers

pool-tasks (generic function)

Writers

(setf pool-tasks) (generic function)


Previous: , Up: Top   [Contents][Index]

Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts

Jump to:   C   F   L   M  
Index Entry  Section

C
chanl.asd: The chanl<dot>asd file
chanl/src: The chanl/src module
chanl/src/actors.lisp: The chanl/src/actors<dot>lisp file
chanl/src/channels.lisp: The chanl/src/channels<dot>lisp file
chanl/src/package.lisp: The chanl/src/package<dot>lisp file
chanl/src/queues.lisp: The chanl/src/queues<dot>lisp file
chanl/src/select.lisp: The chanl/src/select<dot>lisp file
chanl/src/threads.lisp: The chanl/src/threads<dot>lisp file
chanl/src/trivial-cas.lisp: The chanl/src/trivial-cas<dot>lisp file
chanl/src/utils.lisp: The chanl/src/utils<dot>lisp file

F
File, Lisp, chanl.asd: The chanl<dot>asd file
File, Lisp, chanl/src/actors.lisp: The chanl/src/actors<dot>lisp file
File, Lisp, chanl/src/channels.lisp: The chanl/src/channels<dot>lisp file
File, Lisp, chanl/src/package.lisp: The chanl/src/package<dot>lisp file
File, Lisp, chanl/src/queues.lisp: The chanl/src/queues<dot>lisp file
File, Lisp, chanl/src/select.lisp: The chanl/src/select<dot>lisp file
File, Lisp, chanl/src/threads.lisp: The chanl/src/threads<dot>lisp file
File, Lisp, chanl/src/trivial-cas.lisp: The chanl/src/trivial-cas<dot>lisp file
File, Lisp, chanl/src/utils.lisp: The chanl/src/utils<dot>lisp file

L
Lisp File, chanl.asd: The chanl<dot>asd file
Lisp File, chanl/src/actors.lisp: The chanl/src/actors<dot>lisp file
Lisp File, chanl/src/channels.lisp: The chanl/src/channels<dot>lisp file
Lisp File, chanl/src/package.lisp: The chanl/src/package<dot>lisp file
Lisp File, chanl/src/queues.lisp: The chanl/src/queues<dot>lisp file
Lisp File, chanl/src/select.lisp: The chanl/src/select<dot>lisp file
Lisp File, chanl/src/threads.lisp: The chanl/src/threads<dot>lisp file
Lisp File, chanl/src/trivial-cas.lisp: The chanl/src/trivial-cas<dot>lisp file
Lisp File, chanl/src/utils.lisp: The chanl/src/utils<dot>lisp file

M
Module, chanl/src: The chanl/src module

Jump to:   C   F   L   M  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   %   (  
A   B   C   D   E   F   G   H   K   L   M   N   P   Q   R   S   T   U   W  
Index Entry  Section

%
%dequeue: Internal functions
%enqueue: Internal functions
%kill: Internal functions
%make-queue: Internal functions
%next-index: Internal functions
%queue-count: Internal functions
%queue-empty-p: Internal functions
%queue-full-p: Internal functions
%queue-in: Internal functions
%queue-length: Internal functions
%queue-out: Internal functions
%queue-peek: Internal functions
%queue-zero-p: Internal functions

(
(setf channel-lock): Internal generic functions
(setf channel-lock): Internal generic functions
(setf channel-readers): Internal generic functions
(setf channel-readers): Internal generic functions
(setf channel-recv-ok): Internal generic functions
(setf channel-recv-ok): Internal generic functions
(setf channel-send-ok): Internal generic functions
(setf channel-send-ok): Internal generic functions
(setf channel-send-return-wait): Internal generic functions
(setf channel-send-return-wait): Internal generic functions
(setf channel-value): Internal generic functions
(setf channel-value): Internal generic functions
(setf channel-vector): Internal generic functions
(setf channel-vector): Internal generic functions
(setf channel-writers): Internal generic functions
(setf channel-writers): Internal generic functions
(setf free-thread-counter): Internal generic functions
(setf free-thread-counter): Internal generic functions
(setf pool-pending-tasks): Internal generic functions
(setf pool-pending-tasks): Internal generic functions
(setf pool-soft-limit): Internal generic functions
(setf pool-soft-limit): Internal generic functions
(setf pool-tasks): Internal generic functions
(setf pool-tasks): Internal generic functions
(setf pool-threads): Internal generic functions
(setf pool-threads): Internal generic functions
(setf recv-grabbed-value-p): Internal generic functions
(setf recv-grabbed-value-p): Internal generic functions
(setf task-name): Exported generic functions
(setf task-name): Exported generic functions
(setf task-status): Exported generic functions
(setf task-status): Exported generic functions
(setf task-thread): Exported generic functions
(setf task-thread): Exported generic functions

A
act: Internal generic functions
act: Internal generic functions
aif: Internal macros
all-threads: Exported functions
assign-task: Internal generic functions
assign-task: Internal generic functions
atomic-incf: Exported macros
awhen: Internal macros

B
boss: Exported generic functions
boss: Exported generic functions

C
cas-channel-set: Internal functions
channel-being-read-p: Internal functions
channel-being-written-p: Internal functions
channel-buffered-p: Internal generic functions
channel-buffered-p: Internal generic functions
channel-buffered-p: Internal generic functions
channel-dequeue: Internal generic functions
channel-dequeue: Internal generic functions
channel-dequeue: Internal generic functions
channel-enqueue: Internal generic functions
channel-enqueue: Internal generic functions
channel-enqueue: Internal generic functions
channel-grab-value: Exported generic functions
channel-grab-value: Exported generic functions
channel-grab-value: Exported generic functions
channel-grab-value: Exported generic functions
channel-grab-value: Exported generic functions
channel-insert-value: Exported generic functions
channel-insert-value: Exported generic functions
channel-insert-value: Exported generic functions
channel-insert-value: Exported generic functions
channel-insert-value: Exported generic functions
channel-lock: Internal generic functions
channel-lock: Internal generic functions
channel-peek: Internal generic functions
channel-peek: Internal generic functions
channel-peek: Internal generic functions
channel-peek: Internal generic functions
channel-pop: Internal generic functions
channel-pop: Internal generic functions
channel-push: Internal generic functions
channel-push: Internal generic functions
channel-readers: Internal generic functions
channel-readers: Internal generic functions
channel-readers: Internal generic functions
channel-recv-ok: Internal generic functions
channel-recv-ok: Internal generic functions
channel-send-ok: Internal generic functions
channel-send-ok: Internal generic functions
channel-send-return-wait: Internal generic functions
channel-send-return-wait: Internal generic functions
channel-value: Internal generic functions
channel-value: Internal generic functions
channel-value: Internal generic functions
channel-vector: Internal generic functions
channel-vector: Internal generic functions
channel-writers: Internal generic functions
channel-writers: Internal generic functions
channel-writers: Internal generic functions
channelp: Exported generic functions
channelp: Exported generic functions
channelp: Exported generic functions
christen: Exported generic functions
christen: Exported generic functions
christen: Exported generic functions
clause-type: Internal functions
compute-tubes: Exported generic functions
compute-tubes: Exported generic functions
compute-tubes: Exported generic functions
compute-tubes: Exported generic functions
current-thread: Exported functions

D
define-print-object: Internal macros
define-speedy-function: Internal macros
dequeue: Internal functions

E
econd: Internal macros
enqueue: Internal functions
ensure-list: Internal functions
ensure-running: Exported generic functions
ensure-running: Exported generic functions
ensure-running: Exported generic functions
execute: Exported generic functions
execute: Exported generic functions
execute: Exported generic functions
execute: Exported generic functions

F
fire: Exported functions
free-thread-counter: Internal generic functions
free-thread-counter: Internal generic functions
fun: Internal macros
Function, %dequeue: Internal functions
Function, %enqueue: Internal functions
Function, %kill: Internal functions
Function, %make-queue: Internal functions
Function, %next-index: Internal functions
Function, %queue-count: Internal functions
Function, %queue-empty-p: Internal functions
Function, %queue-full-p: Internal functions
Function, %queue-in: Internal functions
Function, %queue-length: Internal functions
Function, %queue-out: Internal functions
Function, %queue-peek: Internal functions
Function, %queue-zero-p: Internal functions
Function, all-threads: Exported functions
Function, cas-channel-set: Internal functions
Function, channel-being-read-p: Internal functions
Function, channel-being-written-p: Internal functions
Function, clause-type: Internal functions
Function, current-thread: Exported functions
Function, dequeue: Internal functions
Function, enqueue: Internal functions
Function, ensure-list: Internal functions
Function, fire: Exported functions
Function, halt: Exported functions
Function, kill: Exported functions
Function, launch: Internal functions
Function, make-queue: Internal functions
Function, map-workers: Internal functions
Function, new-worker-thread: Internal functions
Function, nunzip-alist: Internal functions
Function, pcall: Exported functions
Function, pooled-tasks: Exported functions
Function, pooled-threads: Exported functions
Function, queue-count: Internal functions
Function, queue-empty-p: Internal functions
Function, queue-full-p: Internal functions
Function, queue-length: Internal functions
Function, queue-peek: Internal functions
Function, queuep: Internal functions
Function, slot-channel: Exported functions
Function, strftime: Internal functions
Function, thread-alive-p: Exported functions
Function, thread-name: Exported functions
Function, threadp: Exported functions
Function, unzip-alist: Internal functions
Function, wrap-select-clause: Internal functions

G
Generic Function, (setf channel-lock): Internal generic functions
Generic Function, (setf channel-readers): Internal generic functions
Generic Function, (setf channel-recv-ok): Internal generic functions
Generic Function, (setf channel-send-ok): Internal generic functions
Generic Function, (setf channel-send-return-wait): Internal generic functions
Generic Function, (setf channel-value): Internal generic functions
Generic Function, (setf channel-vector): Internal generic functions
Generic Function, (setf channel-writers): Internal generic functions
Generic Function, (setf free-thread-counter): Internal generic functions
Generic Function, (setf pool-pending-tasks): Internal generic functions
Generic Function, (setf pool-soft-limit): Internal generic functions
Generic Function, (setf pool-tasks): Internal generic functions
Generic Function, (setf pool-threads): Internal generic functions
Generic Function, (setf recv-grabbed-value-p): Internal generic functions
Generic Function, (setf task-name): Exported generic functions
Generic Function, (setf task-status): Exported generic functions
Generic Function, (setf task-thread): Exported generic functions
Generic Function, act: Internal generic functions
Generic Function, assign-task: Internal generic functions
Generic Function, boss: Exported generic functions
Generic Function, channel-buffered-p: Internal generic functions
Generic Function, channel-dequeue: Internal generic functions
Generic Function, channel-enqueue: Internal generic functions
Generic Function, channel-grab-value: Exported generic functions
Generic Function, channel-insert-value: Exported generic functions
Generic Function, channel-lock: Internal generic functions
Generic Function, channel-peek: Internal generic functions
Generic Function, channel-pop: Internal generic functions
Generic Function, channel-push: Internal generic functions
Generic Function, channel-readers: Internal generic functions
Generic Function, channel-recv-ok: Internal generic functions
Generic Function, channel-send-ok: Internal generic functions
Generic Function, channel-send-return-wait: Internal generic functions
Generic Function, channel-value: Internal generic functions
Generic Function, channel-vector: Internal generic functions
Generic Function, channel-writers: Internal generic functions
Generic Function, channelp: Exported generic functions
Generic Function, christen: Exported generic functions
Generic Function, compute-tubes: Exported generic functions
Generic Function, ensure-running: Exported generic functions
Generic Function, execute: Exported generic functions
Generic Function, free-thread-counter: Internal generic functions
Generic Function, name: Exported generic functions
Generic Function, perform: Exported generic functions
Generic Function, pool-leader-lock: Internal generic functions
Generic Function, pool-leader-notifier: Internal generic functions
Generic Function, pool-lock: Internal generic functions
Generic Function, pool-pending-tasks: Internal generic functions
Generic Function, pool-soft-limit: Internal generic functions
Generic Function, pool-tasks: Internal generic functions
Generic Function, pool-threads: Internal generic functions
Generic Function, queue-condition-queue: Internal generic functions
Generic Function, queue-error-attempted-length: Internal generic functions
Generic Function, queue-overflow-extra-item: Internal generic functions
Generic Function, recv: Exported generic functions
Generic Function, recv-blocks-p: Exported generic functions
Generic Function, recv-grabbed-value-p: Internal generic functions
Generic Function, send: Exported generic functions
Generic Function, send-blocks-p: Exported generic functions
Generic Function, task-function: Internal generic functions
Generic Function, task-name: Exported generic functions
Generic Function, task-status: Exported generic functions
Generic Function, task-thread: Exported generic functions

H
halt: Exported functions

K
kill: Exported functions

L
launch: Internal functions

M
Macro, aif: Internal macros
Macro, atomic-incf: Exported macros
Macro, awhen: Internal macros
Macro, define-print-object: Internal macros
Macro, define-speedy-function: Internal macros
Macro, econd: Internal macros
Macro, fun: Internal macros
Macro, pexec: Exported macros
Macro, pop-declarations: Internal macros
Macro, pushend: Internal macros
Macro, select: Exported macros
Macro, when-bind: Internal macros
Macro, with-cas-read-state: Internal macros
Macro, with-cas-write-state: Internal macros
Macro, with-gensyms: Internal macros
Macro, with-read-state: Internal macros
Macro, with-write-state: Internal macros
make-queue: Internal functions
map-workers: Internal functions
Method, (setf channel-lock): Internal generic functions
Method, (setf channel-readers): Internal generic functions
Method, (setf channel-recv-ok): Internal generic functions
Method, (setf channel-send-ok): Internal generic functions
Method, (setf channel-send-return-wait): Internal generic functions
Method, (setf channel-value): Internal generic functions
Method, (setf channel-vector): Internal generic functions
Method, (setf channel-writers): Internal generic functions
Method, (setf free-thread-counter): Internal generic functions
Method, (setf pool-pending-tasks): Internal generic functions
Method, (setf pool-soft-limit): Internal generic functions
Method, (setf pool-tasks): Internal generic functions
Method, (setf pool-threads): Internal generic functions
Method, (setf recv-grabbed-value-p): Internal generic functions
Method, (setf task-name): Exported generic functions
Method, (setf task-status): Exported generic functions
Method, (setf task-thread): Exported generic functions
Method, act: Internal generic functions
Method, assign-task: Internal generic functions
Method, boss: Exported generic functions
Method, channel-buffered-p: Internal generic functions
Method, channel-buffered-p: Internal generic functions
Method, channel-dequeue: Internal generic functions
Method, channel-dequeue: Internal generic functions
Method, channel-enqueue: Internal generic functions
Method, channel-enqueue: Internal generic functions
Method, channel-grab-value: Exported generic functions
Method, channel-grab-value: Exported generic functions
Method, channel-grab-value: Exported generic functions
Method, channel-grab-value: Exported generic functions
Method, channel-insert-value: Exported generic functions
Method, channel-insert-value: Exported generic functions
Method, channel-insert-value: Exported generic functions
Method, channel-insert-value: Exported generic functions
Method, channel-lock: Internal generic functions
Method, channel-peek: Internal generic functions
Method, channel-peek: Internal generic functions
Method, channel-peek: Internal generic functions
Method, channel-pop: Internal generic functions
Method, channel-push: Internal generic functions
Method, channel-readers: Internal generic functions
Method, channel-readers: Internal generic functions
Method, channel-recv-ok: Internal generic functions
Method, channel-send-ok: Internal generic functions
Method, channel-send-return-wait: Internal generic functions
Method, channel-value: Internal generic functions
Method, channel-value: Internal generic functions
Method, channel-vector: Internal generic functions
Method, channel-writers: Internal generic functions
Method, channel-writers: Internal generic functions
Method, channelp: Exported generic functions
Method, channelp: Exported generic functions
Method, christen: Exported generic functions
Method, christen: Exported generic functions
Method, compute-tubes: Exported generic functions
Method, compute-tubes: Exported generic functions
Method, compute-tubes: Exported generic functions
Method, ensure-running: Exported generic functions
Method, ensure-running: Exported generic functions
Method, execute: Exported generic functions
Method, execute: Exported generic functions
Method, execute: Exported generic functions
Method, free-thread-counter: Internal generic functions
Method, name: Exported generic functions
Method, perform: Exported generic functions
Method, perform: Exported generic functions
Method, perform: Exported generic functions
Method, perform: Exported generic functions
Method, pool-leader-lock: Internal generic functions
Method, pool-leader-notifier: Internal generic functions
Method, pool-lock: Internal generic functions
Method, pool-pending-tasks: Internal generic functions
Method, pool-soft-limit: Internal generic functions
Method, pool-tasks: Internal generic functions
Method, pool-threads: Internal generic functions
Method, queue-condition-queue: Internal generic functions
Method, queue-error-attempted-length: Internal generic functions
Method, queue-overflow-extra-item: Internal generic functions
Method, recv: Exported generic functions
Method, recv: Exported generic functions
Method, recv: Exported generic functions
Method, recv: Exported generic functions
Method, recv-blocks-p: Exported generic functions
Method, recv-blocks-p: Exported generic functions
Method, recv-blocks-p: Exported generic functions
Method, recv-blocks-p: Exported generic functions
Method, recv-blocks-p: Exported generic functions
Method, recv-grabbed-value-p: Internal generic functions
Method, recv-grabbed-value-p: Internal generic functions
Method, send: Exported generic functions
Method, send: Exported generic functions
Method, send: Exported generic functions
Method, send: Exported generic functions
Method, send-blocks-p: Exported generic functions
Method, send-blocks-p: Exported generic functions
Method, send-blocks-p: Exported generic functions
Method, send-blocks-p: Exported generic functions
Method, send-blocks-p: Exported generic functions
Method, task-function: Internal generic functions
Method, task-name: Exported generic functions
Method, task-status: Exported generic functions
Method, task-thread: Exported generic functions

N
name: Exported generic functions
name: Exported generic functions
new-worker-thread: Internal functions
nunzip-alist: Internal functions

P
pcall: Exported functions
perform: Exported generic functions
perform: Exported generic functions
perform: Exported generic functions
perform: Exported generic functions
perform: Exported generic functions
pexec: Exported macros
pool-leader-lock: Internal generic functions
pool-leader-lock: Internal generic functions
pool-leader-notifier: Internal generic functions
pool-leader-notifier: Internal generic functions
pool-lock: Internal generic functions
pool-lock: Internal generic functions
pool-pending-tasks: Internal generic functions
pool-pending-tasks: Internal generic functions
pool-soft-limit: Internal generic functions
pool-soft-limit: Internal generic functions
pool-tasks: Internal generic functions
pool-tasks: Internal generic functions
pool-threads: Internal generic functions
pool-threads: Internal generic functions
pooled-tasks: Exported functions
pooled-threads: Exported functions
pop-declarations: Internal macros
pushend: Internal macros

Q
queue-condition-queue: Internal generic functions
queue-condition-queue: Internal generic functions
queue-count: Internal functions
queue-empty-p: Internal functions
queue-error-attempted-length: Internal generic functions
queue-error-attempted-length: Internal generic functions
queue-full-p: Internal functions
queue-length: Internal functions
queue-overflow-extra-item: Internal generic functions
queue-overflow-extra-item: Internal generic functions
queue-peek: Internal functions
queuep: Internal functions

R
recv: Exported generic functions
recv: Exported generic functions
recv: Exported generic functions
recv: Exported generic functions
recv: Exported generic functions
recv-blocks-p: Exported generic functions
recv-blocks-p: Exported generic functions
recv-blocks-p: Exported generic functions
recv-blocks-p: Exported generic functions
recv-blocks-p: Exported generic functions
recv-blocks-p: Exported generic functions
recv-grabbed-value-p: Internal generic functions
recv-grabbed-value-p: Internal generic functions
recv-grabbed-value-p: Internal generic functions

S
select: Exported macros
send: Exported generic functions
send: Exported generic functions
send: Exported generic functions
send: Exported generic functions
send: Exported generic functions
send-blocks-p: Exported generic functions
send-blocks-p: Exported generic functions
send-blocks-p: Exported generic functions
send-blocks-p: Exported generic functions
send-blocks-p: Exported generic functions
send-blocks-p: Exported generic functions
slot-channel: Exported functions
strftime: Internal functions

T
task-function: Internal generic functions
task-function: Internal generic functions
task-name: Exported generic functions
task-name: Exported generic functions
task-status: Exported generic functions
task-status: Exported generic functions
task-thread: Exported generic functions
task-thread: Exported generic functions
thread-alive-p: Exported functions
thread-name: Exported functions
threadp: Exported functions

U
unzip-alist: Internal functions

W
when-bind: Internal macros
with-cas-read-state: Internal macros
with-cas-write-state: Internal macros
with-gensyms: Internal macros
with-read-state: Internal macros
with-write-state: Internal macros
wrap-select-clause: Internal functions

Jump to:   %   (  
A   B   C   D   E   F   G   H   K   L   M   N   P   Q   R   S   T   U   W  

Next: , Previous: , Up: Indexes   [Contents][Index]

A.3 Variables

Jump to:   %   *   +  
A   B   C   F   I   L   N   P   Q   R   S   T   V   W  
Index Entry  Section

%
%thread-pool-soft-limit: Exported symbol macros

*
*boss*: Exported special variables
*secret-unbound-value*: Internal special variables
*thread-pool*: Internal special variables

+
+maximum-buffer-size+: Exported constants

A
abbrev: Exported classes
attempted-length: Internal conditions

B
boss: Exported classes

C
command: Exported classes
Constant, +maximum-buffer-size+: Exported constants

F
free-thread-counter: Internal classes
function: Exported classes

I
item: Internal conditions

L
leader-lock: Internal classes
leader-notifier: Internal classes
lock: Exported classes
lock: Internal classes

N
name: Exported classes
name: Exported classes

P
pending-tasks: Internal classes

Q
queue: Internal conditions
queue-sentinel: Internal special variables

R
readers: Exported classes
recv-grabbed-value-p: Exported classes
recv-ok: Exported classes

S
send-ok: Exported classes
send-return-wait: Exported classes
Slot, abbrev: Exported classes
Slot, attempted-length: Internal conditions
Slot, boss: Exported classes
Slot, command: Exported classes
Slot, free-thread-counter: Internal classes
Slot, function: Exported classes
Slot, item: Internal conditions
Slot, leader-lock: Internal classes
Slot, leader-notifier: Internal classes
Slot, lock: Exported classes
Slot, lock: Internal classes
Slot, name: Exported classes
Slot, name: Exported classes
Slot, pending-tasks: Internal classes
Slot, queue: Internal conditions
Slot, readers: Exported classes
Slot, recv-grabbed-value-p: Exported classes
Slot, recv-ok: Exported classes
Slot, send-ok: Exported classes
Slot, send-return-wait: Exported classes
Slot, soft-limit: Internal classes
Slot, state: Exported classes
Slot, status: Exported classes
Slot, tasks: Internal classes
Slot, thread: Exported classes
Slot, threads: Internal classes
Slot, to-fire: Exported classes
Slot, to-halt: Exported classes
Slot, to-run: Exported classes
Slot, tubes: Exported classes
Slot, value: Exported classes
Slot, vector: Exported classes
Slot, workers: Exported classes
Slot, writers: Exported classes
soft-limit: Internal classes
Special Variable, *boss*: Exported special variables
Special Variable, *secret-unbound-value*: Internal special variables
Special Variable, *thread-pool*: Internal special variables
Special Variable, queue-sentinel: Internal special variables
state: Exported classes
status: Exported classes
Symbol Macro, %thread-pool-soft-limit: Exported symbol macros

T
tasks: Internal classes
thread: Exported classes
threads: Internal classes
to-fire: Exported classes
to-halt: Exported classes
to-run: Exported classes
tubes: Exported classes

V
value: Exported classes
vector: Exported classes

W
workers: Exported classes
writers: Exported classes

Jump to:   %   *   +  
A   B   C   F   I   L   N   P   Q   R   S   T   V   W  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   A   B   C   L   M   P   Q   S   T   U  
Index Entry  Section

A
abstract-channel: Exported classes
actor: Exported classes

B
boss: Exported classes
bounded-channel: Exported classes
buffered-channel: Exported classes

C
cas-channel: Exported classes
chanl: The chanl system
chanl: The chanl package
chanl.actors: The chanl<dot>actors package
channel: Exported classes
Class, abstract-channel: Exported classes
Class, actor: Exported classes
Class, boss: Exported classes
Class, bounded-channel: Exported classes
Class, buffered-channel: Exported classes
Class, cas-channel: Exported classes
Class, channel: Exported classes
Class, queue-channel: Exported classes
Class, stack-channel: Exported classes
Class, task: Exported classes
Class, thread-pool: Internal classes
Class, unbounded-channel: Exported classes
Condition, queue-condition: Internal conditions
Condition, queue-length-error: Internal conditions
Condition, queue-overflow-error: Internal conditions
Condition, queue-underflow-error: Internal conditions

L
Long Method Combination, select: Exported method combinations

M
Method Combination, Long, select: Exported method combinations

P
Package, chanl: The chanl package
Package, chanl.actors: The chanl<dot>actors package
Package, trivial-compare-and-swap: The trivial-compare-and-swap package

Q
queue-channel: Exported classes
queue-condition: Internal conditions
queue-length-error: Internal conditions
queue-overflow-error: Internal conditions
queue-underflow-error: Internal conditions

S
select: Exported method combinations
stack-channel: Exported classes
System, chanl: The chanl system

T
task: Exported classes
thread-pool: Internal classes
trivial-compare-and-swap: The trivial-compare-and-swap package

U
unbounded-channel: Exported classes

Jump to:   A   B   C   L   M   P   Q   S   T   U