5.3 Documentation addenda

5.3.1 Introduction

Finding the source of performance problems is one of the most important steps in optimization. To improve the efficiency of your code, you should first locate the areas where resources are critical by measuring the performance of your code, not by guessing where the problems might lie. The most important problem is frequently the amount of dynamic storage a function uses, or its consing behavior. There is a significant amount of overhead associated with allocating and deallocating storage. In addition, excessive consing can produce a high amount of paging activity, called thrashing, which can greatly reduce the performance of your application program.

You should never attempt to optimize your code until it executes to completion and is generally free of bugs. When your program executes properly, you should then compile the code. The compiled version of the program should run significantly faster than its interpreted counterpart. However, if your program still runs too slowly or requires frequent garbage collections, you should consider rewriting for optimization.

This chapter presents information about two tools for evaluating the performance of applications:

If you do not know the detailed dynamic behavior of your application, you can use the Backtrace Logging Facility to find out what percentage of the overall execution time is spent in each function. You can use this information to determine which functions need further examination by the Performance Monitor.

You can use the Performance Monitor for more specific information about the application's run-time performance and storage requirements. You can use this information to isolate those pieces of your program that might need to be rewritten to improve the overall performance of the code.

Note: You cannot use the Backtrace Logging Facility and the Performance Monitor concurrently.

The following sections present more information about these tools.


Liquid Common Lisp 5.0 Release and Installation Notes - 9 JUN 1997

Generated with Harlequin WebMaker