Genera Concepts

Copyright Symbolics Inc. 1990
Cambridge, Massachusetts

Used with permission.

Genera - The Best Software Environment Available

To all our new users: Welcome.

This conceptual introduction explains what your Symbolics computer is all about. We urge you to at least skim it before you start daily work with the system. We try here to summarize some of the "big picture" concepts in your new software environment; knowing about this framework will help you in learning its details more efficiently.

Most new users of Symbolics machines have worked on traditional time-sharing systems, such as VAX/VMS, or on microcomputers or conventional UNIX workstations. ("Genera Comparison Charts" shows some equivalents between these systems and Genera.) If you feel somewhat uneasy about learning how to use the most advanced software environment around, relax!

You don't have to learn everything at once in order to do anything - look at this as a long-term, incremental learning project. You don't have to learn everything by yourself. Our documentation and Genera itself are here to help you.

Genera and Symbolics Common Lisp dramatically increase your productivity and efficiency by providing many built-in software facilities (similar to library routines) that you would otherwise have to write yourself. Our edit-compile-debug cycle happens so fast that you are virtually editing, compiling, and debugging simultaneously. The editor, compiler and debugger are all resident utilities, available anytime, anywhere.

Figure 1
Figure 1. Your view of Genera's command level.

Genera has no "command levels" or separate "command environments" - you can get there from here. You can move directly from any application to any other application, usually with just two keystrokes. You do not have to close one application to enter another. (See Figure 1.)

Many different activities, such as the editor and electronic mail, run at the same time in separate processes. That means you can move around the system from one application to another without affecting the state of other applications. For example, you can move directly from editing a file to reading online documentation to sending mail and back to editing the file.

To illustrate the basic environmental concept, suppose for a moment the house you live in were like a conventional software environment. The electricity would be in one room, the telephone in another, the heat in another, and the tap water in another. To access one facility, you would have to leave the other behind, moving back to a central access hallway that opened onto all the other rooms.

Suppose you were talking on the telephone in the telephone room. If you wanted to turn on the light in order to write something down, you would have to leave the telephone room, and go to the electricity room. If you then wanted to wash your hands, you would have to leave the electricity room and go to the water room. It would be unthinkable to use the heat, light, or telephone in the water room.

Figure 2
Figure 2. House as Operating System. This house design has central heating, electricity in every room, and so on. That is, basic services are available or accessible in every context.

Continuing this analogy, with a house designed like Genera, you could access electricity, heat, water, telephone, vacuuming, and so forth, from every room (Figure 2)! As you will see when you learn more about Genera, you can access a Genera activity in many different ways as well.

In a conventional computer system, the operating system is the foundation and other separate software application programs are layered on top of the operating system. The command level (exec, monitor, or shell) controls access to the operating system's facilities as well as access to (invoking and terminating) the application programs (Figure 3).

Figure 3
Figure 3. Traditional operating systems require the user to interact with a command monitor in order to access applications and the facilities of the operating system.

Genera is your whole environment; it encompasses what you normally think of as an operating system as well as everything else - system commands and all other activities. From where you look at it, there is no "top-level" controller or exec.

All Genera activities are themselves Lisp functions, based on a pool of thousands of Lisp functions, all implemented in Lisp. Below those, it's just the hardware - you never need to deal with a lower-level internal implementation language.

Figure 4
Figure 4. The Lisp Environment, consisting of all the function and data objects in virtual memory. Activities are just collections of functions and data.

Genera is intelligent. Its many processes can communicate with each other, and they all automatically share data. Genera keeps an internal record of the history of almost everything that happens in the system - command history, output history, process history, window history, and so on.

Histories make it possible to use previous output on a window as input to a command. The mouse can select a relevant piece of output anywhere on the screen because the history mechanism keeps track of the data object types of all the output. As a result, the reusable output is completely context-sensitive.

For example, clicking on a filename in a directory listing displays the contents of the file. When a command needs a filename argument, clicking on that same filename gives the file to the command as an argument. The meaning of the clicks is both context-sensitive and intuitive. You can scoop up a piece of output in one activity and enter it as input to another activity in a matter of seconds. With just a few keystrokes, you can find, modify, and reuse a command that you entered earlier in the day.

The key to Genera's intelligence is the sharing of knowledge and information among all activities. At any time, the collection of all the state of all the processes is called the environment (Figure 4). Any function running in any process can use any piece of data in the environment directly. You do not need laborious special-purpose protocols or intermediate files.

The entire software environment, in its pristine unused state, ready for booting, is saved on disk as a world. A world consists of all the Lisp objects (functions, variables, windows, processes, and so on) that make up the software environment. The world contains the fully initialized environment, ready to boot and use.

Genera doesn't draw any boundaries around itself. It is customizable and extensible by design. Unlike most software, it has an open architecture; you can change anything that is part of Genera. In fact, we encourage you to take advantage of this and to build your applications as extensions of Genera.

The extensibility of the system is possible thanks to both its modular design and its implementation, using highly flexible, object-oriented data structures called flavors. Any data object defined by a flavor or class can be customized or extended cleanly.

Object-oriented data structures are at the heart of symbolic processing because they allow abstract descriptions of data and operations in terms that fit well with the application. The data objects are essentially models of the real-world objects they are implementing. Thus programming uses a problem-solving vocabulary that matches the terminology of the problem domain.

Genera itself was designed to be extended in a number of different ways. You can set customizing variables and create simple files of personal initializations (called init files), or you can extend or replace parts of Genera itself in order to create your own special application.

When you write a program, it becomes an extension of Genera itself (Figure 5). What you do becomes part of the world and enriches the software environment. Because you have loaded a world into your own standalone machine, you can customize and extend the system without affecting the work of others. To get a fresh world, simply boot your machine again.

Figure 5
Figure 5. Your Programs Become an Extension of Genera.

To sum things up, its built-in features, open architecture, intelligence, and extensibility make Genera a new breed of software environment. Genera can help you perform tough software development tasks more quickly than you ever imagined possible.

As you delve deeper into the conceptual material in the next chapters, and then begin to get hands-on practice with Genera in the workbook, do not feel overwhelmed. You shouldn't put pressure on yourself to learn all about a revolutionary new software environment in a day or two. Take it easy. Try things out. Master a little at a time. Genera fosters an incremental approach in all things, including its own mastery.

Genera has amazing functionality and flexibility - often you can perform any task in any application in several different ways. But do not equate high flexibility and functionality with low usability! Genera is also ultimately the most usable software environment available. We want you to explore our functionality at your own pace. There is virtually no limit to the capabilities you will discover in Genera. And Genera will not place artificial upper limits on your creativity.

Genera - A Short Conceptual Tour

The Road to Symbolic Computing

What's the central philosophy behind the evolution of computing in general and Genera in particular?

Free programmers from thinking about unnecessary details and they can accomplish more. The more abstractly they are allowed to think, the bigger and harder the problems they can solve.

Some major advances in the history of conventional computing were motivated by this philosophy:

Genera takes this philosophy of supporting programmers much farther, providing the ideals of abstraction and generality in a number of ways. Maybe you can't move the world with a computer, but Genera running on a Symbolics machine makes it easier to try.

Genera Does It Better

Symbolics Genera is an advanced software development environment that integrates the features normally found in an operating system, its utilities, and the applications running under it. Genera is written in Lisp and supports program development in Lisp and in a number of other languages, including conventional algorithmic ones such as Pascal and C.

Genera has evolved expressly for providing full life-cycle support for major development projects. It includes facilities for the following classes of activities:

Genera was designed for advanced, complex applications. By their very nature, this kind of program is not well understood by its designers; understanding grows incrementally with time and experience. Genera provides the support necessary for this kind of evolutionary growth of a complex program.

With the rich substrate of reusable functions, you can create a working prototype in a fraction of the time you were accustomed to needing. With the modular design encouraged by object-oriented methodology, you can replace parts of the prototype cleanly whenever new understanding permits. As the application grows, configuration management tools keep the complexity under control.

Genera was designed specifically to support the evolutionary software methodology. Both the basic architecture and the software itself were built for managing the details of program structure and compilation.

Data-level Integration

In Genera, all functions and data share the same virtual memory. This shared memory is treated by the software as containing a set of data objects, not uninterpreted bits or bytes. Data objects are both simple (lke characters) and structured (like arrays). In addition, you can have data types defined by applications, containing both state information and operations.

Each data object contains knowledge of its own type. For simple objects, some of this type knowledge is captured in hardware tag bits. Data objects in the object-oriented Flavors and CLOS languages also know their own types and the generic operations that apply to them.

All functions running on the machine can access a common pool of data structures; your functions and data are indistinguishable internally from those provided by the system. Integration in the environment is at the level of the data. A number of different programs can operate on the same data and programs can communicate with each other via shared data. In conventional systems, programs usually have to communicate with each other through the medium of files (see Figure 6).

Figure 6
Figure 6. The Value of Integration

Open Architecture

Most conventional operating systems have a core or kernel that is protected from modification or even use by appliction programs. Genera has no such barriers; everything is open for use or modification. Figure 7 diagrams the fundamental difference between open and closed systems.

Figure 7
Figure 7. A closed system erects barriers to application programs. Its facilities are available only through specific restricted interfaces and most of the internals are invisible. Genera instead offers layers of functionality to its application programs. The layers are "permeable", so all the internal facilities are available to any application.

How can a system work reliably without a protected kernel? Why don't multiple programs sharing the single virtual address space interfere with each other? This means you can change everything, opening up a rich environment and permitting you to go far beyond the usual notions of customizing. The modifications you can make are limited only by your imagination and programming ability.

Nothing up Our Sleeve - Information is Out in the Open

Along with the open software architecture, Genera was designed to let you know what is going on. This has led to a principle of "maximally informative interfaces", with commitment to supporting exploration and investigation and to supplying feedback and documentation.

Right on the keyboard you'll find a HELP key. Pressing this key causes help information, appropriate to your current context, to be displayed. As a programmer, you can write specialized help within your own application or simply depend on the system-supplied facilities, which provide many kinds of help information automatically.

Without any action on your part, many kinds of status information are always visible (but unobtrusive) at the bottom of the screen:

In addition to this constant information, you can use an application program designed for displaying system status information. This utility, called Peek, can display the states of all processes, windows, network connections, servers, network hosts, virtual memory areas, and so on.

So much for the status of the environment. What about your programs? You can look at your data structures, either statically or dynamically. The Flavor Examiner shows definitions, inheritance relationships, and methods in the object-oriented programming system. The Inspector lets you see or manipulate any aspect of the current state of a complex data object. Both of these utilities operate symbolically - you are looking at the names of the slots in the data structures not at mysterious, numeric representations of them.

Most important of all, you can always suspend any computation at any time. Stop it just to find out what it is currently doing - use the Debugger to inspect the data objects, call stack, and other aspects of the running program and then resume it from where you left off. Again, data-level integration is the basis for this capability as the Debugger process automatically has access to the objects and state of the suspended process.

Genera offers several kinds of context-sensitive documentation. Any time you are typing a function name, a single key command displays either its arguments or full reference documentation. The argument information comes from information maintained automatically by the compiler. Reference documentation is supplied by Document Examiner, an application that lets you use the whole documentation set online.

As in many systems, the action taken when you click the mouse buttons depends on where the mouse cursor is on the screen. Unique to Genera, however, is the mouse documentation display that is maintained continually by the user interface management system. As you move the mouse across the screen, the mouse documentation line changes continually with the input context and with the nature of the object beneath the mouse.

One Environment, Many Processes

Genera supports multiple, independent processes in a single address space, with an event-driven scheduler. For an appreciation of how Genera itself uses processes, take a look at the Processes subwindow of Peek, the system status window.

After you have used Genera for a while, you will find yourself carrying on many different activities "at the same time". As far as you are concerned, some activities occur in parallel, such as editing a file while compiling another file and loading new mail in the background. You will find yourself time-slicing also, jumping from one activity to another as you think of things to do in each one. There are no penalties for hopping around - when you select a new activity, the one you just left is simply suspended until you next select it. You never lose any aspect of context when moving between activities in Genera.

The software environment supports this mental view by maintaining the state of any number of processes concurrently. You don't exit one and return to command level in order to start or resume another; you simply select the process implementing the next-desired activity. In each case, when you resume an activity, it is in exactly the same state as when you last left it.

This structure of multiple independent processes based on shared data structures is a strong foundation for the activities involved in software development. Debugging is one situation that often requires using a number of different applications during the search for a problem.

When a program running in Genera encounters a problem unanticipated by the programmer, it automatically enters the Debugger. Both the Debugger and the erring program are processes, and the Debugger process has access to all the state information about the erring process.

In debugging a problem, you can move with one keystroke (or at most two) to a number of different utilities:

Figure 8
Figure 8. You can use a number of utilities as you debug a problem.

In debugging a problem, you would normally employ several other processes, from editor to online documentation to mail system, and so on. Finally, you would select the process that had entered the Debugger and decide what to do next. The choices are many:

In the Debugger, you make repairs using the normal source language rather than an error-prone, numeric patch-up technique. In very large computations, you can save a lot of time by carefully repairing the state of the running program rather than having to restart it.

How is Genera Connected?

Genera's programming environment rests on a rich set of information, maintained by a number of agents, as shown in Figure 9.

Figure 9
Figure 9. The Genera Development Environment

Unless you want to know about this, you can remain largely unaware of the complex information structure underlying the commands and facilities you use. This complex information structure has profound implications, however, enabling the following kinds of unique capabilities:

Incremental Change - The Answer to Developing Large Systems

Complex, experimental software systems are too large to work on all at once. In Genera, various strategies help you manage complexity by dividing the work into small steps, each of which is small enough that it is easy to understand it completely. You'll use this "divide and conquer" strategy in three ways:

Configuration Management - The Answer to Managing Large Systems

Keeping track of source code, object code, documentation, test cas- es, and revision levels for a large program is a difficult clerical task. Genera's System Construction Tool (SCT) handles most of the job. All this facilitates many operations that must be performed on a system as it passes through various phases of its development life: At each of these steps it is only necessary for the person performing the operation to know the system name and possibly the desired sys- tem version.

A Few Words to the Wise

The conceptual introduction to Genera is a description of its philosophy and guiding vision. Like any complex, real-world system, the reach sometimes exceeds the grasp; some parts of Genera do not fully implement the vision as we have expressed it. Genera contains some artifacts of its development history that are not exemplary of the design philosophy. We hope that the small failures of the philosophy will not distract you very much in your appreciation of the large successes.

Genera's approach to software development is not without its hazards. Once the initial euphoria has passed, be wary of the temptation to change everything just because you can do it! You'll encounter a number of problematic issues, which are not unique to Genera but which are certainly made more evident by an open software architecture.

People moving from other environments to Genera report gains in both personal productivity and job satisfaction due to the following attributes of the software environment: