NextPrevTopIndex

Contents

1 Introduction

1.1 About this manual

1.2 The LispWorks manuals

1.3 Other documentation

1.4 Notation and conventions

2 Starting LispWorks

2.1 The usual way to start LispWorks

2.2 Passing arguments to LispWorks

2.2.1 Saving a new image

2.2.2 Saving a console mode image

2.2.3 Bypassing initialization files

2.3 Other command line options

2.4 Starting the Common LispWorks Graphical IDE

2.5 Quitting LispWorks

3 The Debugger

3.1 Entering the TTY debugger

3.2 Simple use of the TTY debugger

3.3 The stack in the debugger

3.4 TTY debugger commands

3.4.1 Backtracing

3.4.2 Moving around the stack

3.4.3 Miscellaneous commands

3.4.4 Leaving the debugger

3.4.5 Example TTY session

3.5 Debugger control variables

4 The TTY Inspector

4.1 Describe

4.2 Inspect

4.3 Inspection modes

4.3.1 Hash table inspection modes

5 The Trace Facility

5.1 Simple tracing

5.2 Tracing options

5.2.1 Evaluating forms on entry to and exit from a traced function

5.2.2 Evaluating forms without printing results

5.2.3 Using the debugger when tracing

5.2.4 Entering stepping mode

5.2.5 Configuring function entry and exit information

5.2.6 Directing trace output

5.2.7 Restricting tracing

5.2.8 Storing the memory allocation made during a function call

5.2.9 Tracing functions from inside other functions

5.3 Example

5.4 Tracing methods

5.5 Trace variables

6 The Advice Facility

6.1 Combining the advice

6.2 Removing advice

6.3 Advice for macros and methods

6.4 Example

6.5 Advice functions and macros

7 Dspecs: Tools for Handling Definitions

7.1 Dspecs

7.2 Forms of dspecs

7.2.1 Canonical dspecs

7.3 Dspec namespaces

7.3.1 Dspec handlers

7.3.2 Dspec aliases

7.4 Types of relations between definitions

7.4.1 Functionally equivalent definers

7.4.2 Grouping subdefinitions together

7.4.3 Distributed definitions

7.5 Details of dspec classes and aliases

7.5.1 CLOS dspec classes

7.5.2 Part Classes

7.5.3 Foreign callable dspecs

7.6 Subfunction dspecs

7.7 Tracking definitions

7.7.1 Locations

7.7.2 Recording definitions and redefinition checking

7.8 Finding locations

7.9 Users of location information

7.9.1 Finding definitions in the LispWorks editor

7.9.2 The editor's implicit form parser

7.9.3 Reusing form parsers

8 Action Lists

8.1 Defining and undefining action lists

8.2 Exception handling variables

8.3 Other variables

8.4 Diagnostic utilities

8.5 Examples

8.6 Standard Action Lists

9 The Compiler

9.1 Compiling a function

9.2 Compiling a source file

9.3 How the compiler works

9.4 Compiler control

9.5 Declare, proclaim, and declaim

9.5.1 Naming conventions

9.6 Optimizing your code

9.6.1 Fast 32-bit arithmetic

9.6.1.1 Optimized and unoptimized INT32 code

9.6.1.2 The INT32 API

9.6.1.3 INT32 Optimization

9.6.2 Floating point optimization

9.6.3 Tail call optimization

9.6.4 Inlining foreign slot access

9.7 Compiler parameters affecting LispWorks

10 Storage Management

10.1 Introduction

10.2 Generations and segments

10.3 Memory Management in 32-bit LispWorks

10.3.1 Generations

10.3.2 Allocation of objects

10.3.2.1 Allocation of static objects

10.3.2.2 Allocation in different generations

10.3.3 Mark and sweep

10.3.4 Promotion

10.3.5 Garbage collection strategy

10.3.6 Overflow

10.3.7 Behavior of generation 1

10.3.8 Behavior of generation 2

10.3.9 Forcing expansion

10.3.10 Controlling Fragmentation

10.3.11 Summary of garbage collection symbols

10.3.11.1 Determining storage usage

10.3.11.2 Allocating in specific generations

10.3.11.3 Controlling a specific generation

10.3.11.4 Controlling the garbage collector

10.4 Memory Management in 64-bit LispWorks

10.4.1 General organization of memory

10.4.2 Segments and Allocation Types

10.4.3 Garbage Collection Operations

10.4.4 Generation Management

10.4.5 Tuning the GC

10.4.5.1 Interface for tuning the GC

10.5 Common Memory Management Features

10.5.1 Timing the garbage collector

10.5.2 Reducing image size

10.5.3 Allocation of interned symbols and packages

10.5.4 Allocation of stacks

10.5.5 Mapping across all objects

10.5.6 Special actions

10.5.7 Garbage collection of foreign objects

10.5.8 Freeing of objects by the GC

11 The Profiler

11.1 What the profiler does

11.2 Setting up the profiler

11.3 Running the profiler

11.4 Interpretation of profiling results

11.5 Profiling pitfalls

11.6 Profiling and garbage collection

12 Simple Customization of LispWorks

12.1 Configuration and initialization files

12.2 Customizing the editor

12.2.1 Controlling appearance of found definitions

12.2.2 Specifying the number of editor windows

12.2.3 Binding commands to keystrokes

12.3 Finding source code

12.4 Using ! for :redo

12.5 Customizing LispWorks for use with your own code

12.5.1 Preloading selected modules

12.5.2 Creating packages

12.6 Structure printing

12.7 Configuring the printer

12.7.1 PPD file details

13 The Metaobject Protocol

13.1 Metaobject features incompatible with AMOP

13.1.1 Instance Structure Protocol

13.1.2 Method Metaobjects

13.1.3 Method Lambdas

13.1.4 Method Functions

13.1.5 EQL specializers

13.1.6 Generic Function Invocation Protocol

13.1.7 Method combinations

13.1.8 Inheritance Structure of Metaobject Classes

13.2 Common problems when using the MOP

13.2.1 Inheritance across metaclasses

13.2.2 Accessors not using structure instance protocol

13.2.3 The MOP in delivered images

13.3 Implementation of virtual slots

14 Multiprocessing

14.1 Introduction to processes

14.2 The process programming interface

14.2.1 Creating a process

14.2.2 Finding out about processes

14.2.3 Process Priorities

14.2.4 Interrupting a process

14.2.5 Multiprocessing

14.2.5.1 Starting multiprocessing interactively

14.2.5.2 Multiprocessing on startup

14.2.5.3 Running your own process on startup

14.2.6 Returning a value from another process

14.2.7 Example

14.3 Locks

14.4 Timers

14.4.1 Timers and multiprocessing

14.4.2 Input and output for timer functions

14.5 Native threads and foreign code

14.5.1 Native threads on Windows, Mac OS X, Linux and FreeBSD

14.5.2 Native threads on other platforms

14.6 Example

15 Common Defsystem

15.1 Introduction

15.2 Defining a system

15.2.1 DEFSYSTEM syntax

15.2.2 DEFSYSTEM options

15.2.3 DEFSYSTEM members

15.2.4 DEFSYSTEM rules

15.2.5 Examples

16 The Parser Generator

16.1 Introduction

16.2 Grammar rules

16.2.1 Example

16.2.2 Resolving ambiguities

16.3 Functions defined by defparser

16.4 Error handling

16.5 Interface to lexical analyzer

16.6 Example

17 Dynamic Data Exchange

17.1 Introduction

17.1.1 Types of transaction

17.1.2 Conversations, servers, topics, and items

17.1.3 Advise loops

17.1.4 Execute transactions

17.2 Client interface

17.2.1 Opening and closing conversations

17.2.2 Automatically managed conversations

17.2.3 Advise loops

17.2.4 Request and poke transactions

17.2.5 Execute transactions

17.3 Server interface

17.3.1 Starting a DDE server

17.3.2 Handling poke and request transactions

17.3.3 Topics

17.3.3.1 General topics

17.3.3.2 Dispatching topics

17.3.3.3 The system topic

18 Common SQL

18.1 Introduction

18.1.1 Overview

18.1.2 Supported databases

18.2 Initialization

18.2.1 SQL interface

18.2.2 Database classes

18.2.3 Initialization functions and variables

18.2.4 Database libraries

18.2.5 General database connection and disconnection

18.2.5.1 Connection example

18.2.6 Connecting to Oracle

18.2.7 Connecting to ODBC

18.2.7.1 Connecting to ODBC using a string

18.2.7.2 Connecting to ODBC using a plist

18.2.8 Connecting to MySQL

18.2.8.1 Connecting to MySQL using a string

18.2.8.2 Connecting to MySQL using a plist

18.2.8.3 Locating the MySQL client library

18.2.8.4 Special instructions for MySQL on Mac OS X

18.2.9 Connecting to PostgreSQL

18.2.9.1 Connecting to PostgreSQL using a string

18.2.9.2 Connecting to PostgreSQL using a plist

18.3 Functional interface

18.3.1 Functional Data Manipulation Language (FDML)

18.3.1.1 Querying

18.3.1.2 Modification

18.3.1.3 Caching of table queries

18.3.1.4 Transaction handling

18.3.1.5 Iteration

18.3.1.6 Specifying SQL directly

18.3.1.7 Building vendor-specific SQL

18.3.1.8 Working with date fields

18.3.2 Functional Data Definition Language (FDDL)

18.3.2.1 Querying the schema

18.3.2.2 FDDL Querying example

18.3.2.3 Modification

18.4 Object oriented interface

18.4.1 Object oriented/relational model

18.4.2 Object-Oriented Data Definition Language (OODDL)

18.4.2.1 Example View Class definition

18.4.3 Object-Oriented Data Manipulation Language (OODML)

18.4.3.1 Examples

18.4.3.2 Iteration

18.4.3.3 Garbage collection of view instances

18.5 Symbolic SQL syntax

18.5.1 The "[...]" Syntax

18.5.1.1 Enclosing database identifiers

18.5.1.2 SQL strings representing symbolic expressions

18.5.1.3 Calling database functions

18.5.1.4 Enclosing literal SQL

18.5.2 Programmatic interface

18.5.2.1 Examples

18.5.3 Utilities

18.6 SQL I/O recording

18.7 Error handling in Common SQL

18.7.1 SQL condition classes

18.7.2 Database error accessors

18.8 Using MySQL

18.8.1 Connection specification

18.8.2 Case of table names and and database names

18.8.3 Encoding (character sets in MySQL).

18.8.4 SQL mode

18.8.5 Meaning of the :owner argument to select

18.8.6 Special considerations for iteration functions and macros

18.8.6.1 Fetching multiple records

18.8.6.2 Aborting queries which fetch many records

18.8.7 Table types

18.8.8 Rollback errors

18.8.9 Types of values returned from queries

18.8.10 Autocommit

18.9 Oracle LOB interface

18.9.1 Introduction

18.9.1.1 Retrieving LOB locators

18.9.1.2 Operating on LOB locators

18.9.1.3 Inserting empty LOBs

18.9.2 Retrieving Lob Locators

18.9.3 Locking

18.9.4 Retrieving LOB Locators as streams

18.9.5 Attaching a stream to a LOB locator

18.9.6 Interactions with foreign calls

18.9.7 Determining the type of a LOB

18.9.8 Reading and writing from and to LOBs

18.9.9 The LOB functions

18.9.9.1 Querying functions

18.9.9.2 LOB management functions

18.9.9.3 Modifying LOBs

18.9.9.4 File operations

18.9.9.5 Direct I/O

18.9.9.6 Temporary LOBs

18.9.9.7 Control of buffering

19 User Defined Streams

19.1 Introduction

19.2 An illustrative example of user defined streams

19.2.1 Defining a new stream class

19.2.2 Recognizing the stream element type

19.2.3 Stream directionality

19.2.4 Stream input

19.2.5 Stream output

19.2.6 Instantiating the stream

20 Socket Stream SSL interface

20.1 Creating a stream with SSL

20.2 SSL-CTX and SSL objects

20.3 OpenSSL interface

20.3.1 OpenSSL constants

20.3.2 Naming conventions for direct OpenSSL calls

20.3.2.1 Mapping C names to Lisp names

20.3.2.2 Mapping Lisp names to C names

20.3.3 Direct calls to OpenSSL

20.4 Socket Stream SSL keyword arguments

20.5 Attaching SSL to an existing socket-stream

20.6 Using SSL objects directly

20.7 Initialization

20.8 Obtaining and installing the OpenSSL library

20.8.1 Installing the OpenSSL library on Solaris

20.8.2 Loading the OpenSSL libraries

20.9 Errors in SSL

21 Internationalization

21.1 Introduction

21.2 Character and String types

21.2.1 Character types

21.2.2 Character Syntax

21.2.3 String types

21.3 String accessors

21.4 String Construction

21.4.1 Default string construction

21.4.2 String construction with known type

21.4.3 Controlling string construction

21.4.4 String construction on Windows systems

21.5 External Formats

21.6 External Formats and File Streams

21.6.1 Using complete external formats

21.6.2 Guessing the external format

21.6.3 External formats and stream-element-type

21.6.4 External formats and the LispWorks Editor

21.7 External Formats and the Foreign Language Interface

22 LispWorks' Operating Environment

22.1 The Operating System

22.2 Site Name

22.3 The Lisp Image

22.4 The Command Line

22.4.1 Command Line Arguments

22.5 Address Space and Image Size

22.5.1 Size of real memory

22.5.2 Layout of memory

22.5.3 Reporting current allocation

22.6 Exit status

22.7 Creating a new executable with code preloaded

22.8 Universal binaries on Mac OS X

22.9 User Preferences

22.9.1 Location of persistant settings

22.9.2 Accessing persistant settings

22.9.3 Example using user preferences

22.10 The home directory

22.11 Special Folders

Index

 


LispWorks User Guide - 21 Jul 2006

NextPrevTopIndex