COMPAQ Software Product Description ___________________________________________________________________ PRODUCT NAME: Developers' Toolkit for Tru64(TM) UNIX SPD 44.36.18 Version 4.0F (formerly DIGITAL UNIX) DESCRIPTION The Developers' Toolkit for CompaqTru64 UNIX (formerly DIGITAL UNIX) provides a basic application development tool set for the Tru64 UNIX Operating System. This product combines the previous Developers' Toolkit and C Developers' Extensions products into a single solution. The Developers' Toolkit for Tru64 UNIX[ is a prerequisite for all development tools, languages, and environments. The Developers' Toolkit contains the following components: o DEC C for Tru64 UNIX, an ANSI conformant C Compiler o Debuggers (Ladebug, dbx) o The ATOM API o Program analysis tools (profiling and performance analysis) o Visual Threads (thread-related profiling and debugging) o Porting Assistant o Reordering tools (cord, feedback, runcord) The C Compiler The Developers' Toolkit offers DEC C for Tru64 UNIX, which was specifically developed and optimized for use with Alpha systems. The DEC C compiler is invoked with the cc command. The DEC C compiler offers improved optimization, additional features, and greater compatibility with DIGITAL compilers on other platforms. DEC C is upwardly compatible with the previous compiler and the default flags are consistent. DEC C is also available on the OpenVMS operating system. The DEC C compiler is an ANSI-compliant implementation of the C programming language with extended support for non-ANSI C dialects and performance tuning. It generates optimized position independent code and supports shared libraries. The compiler generates complete debug and traceback records for use with the Ladebug and dbx debuggers, which allow the C programmer to set breakpoints, examine and modify the contents of user variables, and selectively halt or continue program execution. The compiler conforms to the ANSI X3J11/88-159 C language standard (equivalent to ANSI X3.159-1989 and ISO/IEC 9899:1990) and provides IEEE floating point support conformant with IEEE Standard 754 (equivalent to IEC 60559:1989). Features o Separate modes of compilation to support each of several C dialects: - A common mode (K&R), which supports C extensions common to many UNIX platforms. This is the default mode. - A strict ANSI mode, which compiles according to the ANSI standard. - A relaxed ANSI mode, which compiles according to the ANSI standard but accepts additional DIGITAL extensions. - A VAX C mode, which supports a number of VAX C extensions. - A Microsoft(TM) compatibility mode that interprets source programs according to certain language rules followed by the C compiler provided by Microsoft with Visual C++(TM). o Data types for numeric, nonnumeric, and systems programming: - Support for 8, 16, 32, and 64-bit signed and unsigned integers - Support for IEEE 32-bit floating point and 64-bit double floating point data types o Pragmas for controlling storage allocation o An option for running only the preprocessor phase of compilation o Pragmas for controlling compiler options o Compilation options for fine control over compiler behavior: - Particular compiler implementation - Compilation system (driver, output file, and listing options) - C preprocessor behavior - Linker and loader behavior - Optimization levels - Source code debugging - Program profiling in conjunction with pixie, prof, gprof, and hiprof - Portability checking - Data alignment - Data volatility - C programming language semantics - IEEE floating point behavior - Stack and pointer handling - Exception handling o Tru64 UNIX inline-assembly code (asm) is supported giving direct access to all Alpha machine code instructions and privileged architecture library (PAL) calls. Built-in functions generate efficient code sequences for processor interlocked memory access. o Integration with Tru64 UNIX tools - Generation of complete debug and traceback records for the Ladebug and dbx symbolic debuggers - C macro preprocessor (cpp) - Program profiling tools (pixie, prof, gprof, hiprof) - Postlink optimization (cord and om tools) - Support for run-time shareable objects - Support for compressed object file format (objZ) - Run-time feedback optimization - Inter-language calls with other Tru64 UNIX languages - Integration with the DEC FUSE graphical software development environment (see SPD 44.71) o Extensive global and local optimizations of generated code for increased performance under Tru64 UNIX o Extensive control over optimization behavior from the command line and in the source code The DIGITAL Ladebug Debugger for Tru64 UNIX Ladebug is a symbolic source code debugger that helps programmers locate run-time programming errors (bugs) in their code. It includes a customizable Graphical User Interface (GUI). Features o Support multiple process debugging - Attach/detach to one or more running processes - Load/unload one or more programs into the debugger - Debug across fork/exec - Allow process execution in the background o Debug multithreaded DECthreads applications o Attach/detach to a running process and debug a program o Perform remote client/server debugging o Catch/ignore unaligned access o Display a source listing of a program o Support line editing (simple emacs binding) o Use Ladebug within emacs o Debug core files o Set breakpoints and tracepoints to stop program execution when certain conditions are met (for example, a program variable value changes) o Step into a routine o Step through the execution of a program one line at a time o Examine the stack of currently active functions o Watch the reads and/or writes of memory o Examine and change program variable and data structure values o Disassemble and examine machine code and examine machine register values o Debug programs with shared libraries o Customize debugging environment by using scripts and aliases for commands and command sequences o Examine of memory in various formats o Display variables in different scopes o Debug the Kernel Ladebug provides a choice of command-line or graphical user interface. The command-line interface is a dbx-like command syntax. Ladebug provides extensive debugging support for the following languages: C, C++, FORTRAN-77, and FORTRAN-90. Ladebug provides limited support for DEC COBOL, and DEC Ada. Both a standard and an international implementation of Ladebug ship with this version of the Developers' Toolkit. They are two distinct kits, with the standard implementation being the default. See the product documentation for details. The Ladebug GUI supports all Ladebug command-line functionality. The GUI main window includes the basic debugging and convenience features; optional views windows, various pop-up menus and dialog boxes, and a command-entry prompt. Key features of the Ladebug GUI o A complete debugger command set available through the communications view o Logical and easy access to the most common debugging functions o Convenient call stack maneuvering via a call stack menu o Convenient display of program execution through the source, communication, breakpoint, instruction, register, local variable, and monitor displays o Paned windows that minimize the use of screen area o Intelligent word selection o Source navigation through the source browser o A customizable push-button panel to accommodate individual debugging styles o Data views that can be expanded to show their contents or to follow pointers o An I/O window for application terminal I/O o Integration with the DEC FUSE graphical software development environment (see SPD 44.71) o Support for the common desktop environment (CDE) and its own icon in the Developers' Toolkit group. Over time Ladebug will replace the dbx debugger. The dbx Debugger The dbx debugger is a portable, symbolic source code debugger for customers who desire a debugger with a consistent, industry- standard, command-line user interface. The dbx symbolic debugger will be retired in a future release of Tru64 UNIX. The DIGITAL Ladebug debugger will replace it. The DIGITAL Ladebug debugger is a superset of the dbx functionality. Features o Supports the C, FORTRAN, and Pascal languages o Debug multithreaded applications via kernel threads, does NOT support DECthreads o Attach/detach to a running process and debug a program (same or multiple executables) o Perform remote client/server debugging o Display a source listing of a program o Set breakpoints and tracepoints to stop program execution when certain conditions are met (for example, a program variable value changes) o Step through the execution of program one line at a time o Examine the stack of currently active functions o Examine and change program variable and data structure values o Disassemble and examine machine code and examine machine register values o Debug programs with shared libraries o Customize the debugging environment by using scripts and aliases for commands and command sequences o Directly examine memory in various formats o Display values in different scopes o Display variables o Debug the Kernel Program Analysis Tools The ATOM API can be used to create simple or sophisticated tools. ATOM uses the target application program, an instrumentation file and an analysis file to create a new executable, that when run collects analysis data for a wide variety of purposes. Tools are created by writing two sets of C routines, an instrumentation file and an analysis file. In the instrumentation file, the ATOM API is used to specify where calls to analysis routines should be inserted in an application. A single call to an ATOM routine creates a new executable. The analysis routines are called, at run time, by instructions ATOM inserted in the new executable. These routines run in the background of the application and analyze it for attributes like quality and performance. While ATOM greatly expedites tool creation, there is vast flexibility in designing the scope of the tool. Compaq has created several tools with ATOM, including hiprof, pixie and Third Degree. All these tools support shared libraries and threaded programs and are licensed with the Developers' Toolkit. The Third Degree tool profiles heap-memory for programs written in C and C++. It helps you identify three memory bugs: memory leaks, reading un-initialized memory and accessing an invalid memory address. Pixie is a basic block profiler that allows instruction-level execution counts to be obtained. You can then feed this profiling data to either the cord or om reordering tools. Hiprof provides procedure call information on the program that is similar to but more powerful than the gprof (cc -pg) profiler. It shows the amount of CPU time utilized by each primary procedure and the subordinate procedures they call. Graphical Program Analysis Tools The Graphical Program Analysis Tools (GPA) help application developers examine the run-time behavior of their applications on Tru64 UNIX. The Graphical Program Analysis Tools can locate problems in your code, explain the problems using diagnostic messages, and even suggest necessary changes through reports. For example, using these tools you can: o Instrument an application, run the application, and look at the memory usage data in one step or separate steps o Find poorly tested areas in your code o Locate and correct performance bottlenecks o Find and fix memory leaks and memory errors o Find and fix problems with writing past the ends of memory blocks o Get information about all processes, including child processes, running on local or remote systems o Invoke utilities and commands to monitor and manage the remote system o Record all the process information to a file for later review The Graphical Program Analysis Tools are: o Process Viewer: Graphically displays performance information about processes and child processes running on specified (local or remote) Tru64 UNIX systems. o Memory Profiler: Graphically displays how your application uses memory over the course of its execution, for example, showing how much is allocated for various purposes and how frequently your application is allocating and deallocating memory. This tool helps you understand if an application uses memory inefficiently, for example, fragmented memory allocations. o Performance Profiler: Gathers and analyzes, in graphical form, run-time statistics on your application, such as CPU usage by function or line and test coverage. o Heap Analyzer: Finds and displays in graphical form memory errors and memory leaks in your application. o Man Page Browser: used for searching, navigating, and printing manpages in a graphical, scrollable hypertext window. In addition, online help is provided for each tool in a hypertext window. You can use the Process Viewer, Memory Profiler, Performance Profiler, and Heap Analyzer standalone or, if you want to use them from your Windows NT PC, as part of the DIGITAL Enterprise Toolkit for Visual Studio (SPD 70.03.xx). The Graphical Program Analysis Tools require a typical Alpha workstation or server for doing software development, using Common Desktop Environment (CDE) or Motif interface environment software. You can run tools directly from the CDE desktop interface or invoke a tool directly from the command line (for example, pview, mview, dxprof, or dxheap). The Graphical Program Analysis Tools provide full language support for DEC C++, DEC C, and DIGITAL Fortran (both f77 and Fortran 90). Visual Threads Visual Threads lets you debug and analyze multithreaded applications. It can be used to automatically diagnose common problems associated with multithreading including deadlock, protection of shared data, and thread usage errors. It can also be used to monitor the thread-related performance of the application, helping you to identify bottlenecks or locking granularity problems. It is a unique debugging tool because it can be used to identify problem areas even if an application does not show any specific problem symptoms. Visual Threads provides the following: o Event Collection: Collects detailed information about the significant thread state changes that occur during the running of a multithreaded application. o Event Display: At any time, you can view the dynamic display of events as they occur, with options to filter for specific types of events. o Automatic Rule-based Analysis: Detects violation conditions by evaluating the events against a set of enabled rules. Several predefined rules look for data protection errors, deadlock conditions, and programming errors o Rule Customization: Lets you use templates to define your own rules to specify criteria for violation conditions. In particular, you can specify rules to monitor or identify performance problems. o Customized Actions: Suspends execution of the application when it detects violation conditions. You can choose from several options at this point, including invoking the debugger in the appropriate context for the application. o Playback: Records events to a trace file so you can play back and analyze them later. This is especially useful if you want to analyze a trace file iteratively, perhaps using different rules each time as you discover more information. o Statistics: Provides easy access to object-level statistics and current state information, including use of resources (for example, the mutexes held by a particular thread). You can use this information to look for performance problems and to fine tune the application. o Thread and Event Visualization: Graphically and continuously displays the state of the program threads and the frequency of thread-related events. The Porting Assistant The Porting Assistant is an integrated graphical toolset designed to reduce the time and cost of porting applications to Tru64 UNIX. It helps when porting applications written in C, C++, and FORTRAN from other UNIX platforms such as SunOS (TM), HP-UX (R), IBM/AIX (R) and ULTRIX, and from non UNIX platforms such as OpenVMS. The DIGITAL Porting Assistant is a Tru64 UNIX/Motif(R) based toolset. The Porting Assistant guides the developer through the porting process by suggesting a systematic, iterative porting approach. First, the Porting Assistant analyzes source files and locates changes that are potentially needed for the application to run on Tru64 UNIX. Then, through extensive, graphical hyperlinked information, it helps programmers understand what changes are needed and why they need to make them. Finally, it aids in making each change either by using the integrated editor or through its global replace capability. In analyzing software code, the Porting Assistant locates: o 32-bit dependencies o Conditional code that might also need Tru64 UNIX branching o References to files that do not exist on Tru64 UNIX o Calls to library functions that do not match Tru64 UNIX definitions or have different semantics on Tru64 UNIX o Platform-dependent signal handling code o Function/subroutine calls in FORTRAN that are inconsistent with their definitions o Makefile actions that do not exist on Tru64 UNIX o Important command options and arguments that differ between platforms To help developers understand each porting problem, the Porting Assistant graphical hyperlinked information: o Provides porting tips that complement Compaq’s extensive porting guides o Explains the relevance of each of the analysis steps o Explains the semantic differences in functions on different vendor's platforms o Provides detailed help on may individual diagnostics o Provides hyperlinked access to relevant reference pages When making code changes, the Porting Assistant: o Provides developers with a choice of vi, emacs or a Motif(R) editor o Steps developers through the problem areas one at a time, bringing each into the editor to be examined and changed o Provides a global search/replace facility to make changes across files o Filters out unwanted diagnostics o Suggests what sharable libraries and archives to use o Reruns analyzes at users request after changes are made o Provides support for mapping Fortran compile command lines in a makefile to the equivalent Tru64 UNIX command line o Provides the addition of a keyword lookup function for the DXML Library, which includes commonly used Fortran math functions o Provides support for mapping LINPACK and EISPACK routines to LAPACK routines The Porting Assistant requires a minimum of 64 MB of memory and 10 MB of disk space. The Porting Assistant supports CDE and has its own icon in the Developers' Toolkit group. Reordering Tools The reordering tools rearrange procedures in an executable file to facilitate better cache mapping, reducing the instruction cache miss rates. The tools are as follows: o cord-Rearranges procedures in an executable to facilitate better cache mapping o feedback -Generates a feedback file using pixie and execution data analyzer prof o runcord -Invokes cord to rearrange procedures in an executable file to facilitate better cache mapping HARDWARE REQUIREMENTS Please refer to the Tru64 UNIX Operating System Software Product Description (SPD 41.61) for specific hardware supported. SOFTWARE REQUIREMENTS Tru64 UNIX Operating System Version 4.0F GROWTH CONSIDERATIONS The minimum hardware and software requirements for any future version of this product might be different from the requirements for the current version. DISTRIBUTION MEDIA This product is distributed on the Tru64 UNIX Operating System CD-ROMs. ORDERING INFORMATION Developers' Toolkit for Tru64 UNIX Software Licenses: Traditional Licenses: QL-MT5A*-AA Concurrent Use License: QL-MT5AM-3B Software Media/Documentation: QA-MT4AA-H8 Software Documentation (hardcopy): QA-MT5AE-GZ Software Product Services: QT-MT5A*-** * Denotes variant fields. For additional information on available licenses, services, and media, refer to the appropriate price book. SOFTWARE LICENSING This software is furnished only under a license. For more information about Compaq's licensing terms and conditions, contact your local Compaq office. SOFTWARE PRODUCT SERVICES A variety of service options are available from Compaq. For more information, contact your local Compaq office. YEAR 2000 READY This product is Year 2000 Ready. "Year 2000 Ready" products are defined by Compaq as products capable of accurately processing, providing, and/or receiving date data from, into and between the twentieth and the twenty-first centuries, and the years 1999 and 2000, including leap year calculations, when used in accordance with the associated Compaq product documentation and provided that all hardware, firmware and software used in combination with such Compaq products properly exchange accurate date data with the Compaq products. For additional information visit Compaq’s DIGITAL Products Year 2000 Ready web site located at http://ww1.digital.com/year2000/warranty.asp. SOFTWARE WARRANTY This software is provided by Compaq with a 90-day conformance warranty in accordance with the Compaq warranty terms applicable to the license purchase. The above information is valid at time of release. Please contact your local Compaq office for the most up-to-date information. (R) Microsoft is a registered trademark of Microsoft, Inc. (TM) Visual C++ is a trademark of Microsoft Corporation. (TM) SunOS is a trademark of Sun Microsystems, Inc. (R) HP-UX is a registered trademark of Hewlett-Packard Company. (R) AIX is a registered trademark of International Business Machines Corporation. (R) Motif and OSF/1 are registered trademarks of Open Software Foundation, Inc. (R) UNIX is a registered trademark and the Open Group is a trademark of The Open Group in the US and other countries. (TM) The DIGITAL Logo, DEC, and DIGITAL are trademarks of Compaq Computer Corporation. (TM) X Window System is a trademark of Massachusetts Institute of Technology. Copyright (c) 1999 Digital Equipment Corporation. All rights reserved. April 1999