13.07.2015 Views

iAPX 286 Operating System Writers Guide 1983

iAPX 286 Operating System Writers Guide 1983

iAPX 286 Operating System Writers Guide 1983

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

BINDING AND LOADINGNamingThe names by which you reference the components of a system influence the way the system can bebound. Classes of names over which you have some degree of control are• Modules. Builder uses the name of a module to represent all publics or all segments within themodule. Debuggers use module names to qualify identifiers of variables and procedures.• Logical segments. The choice of logical segment names determines the possibilities for segmentcombination. Binder combines logical segments that have the same name as well as compatiblecombine-types.• Physical segments. The names of physical segments give you the ability to assign segment attributesindividually using the Builder.• Publics. Public identifiers must be unique among the modules that are bound together.• Gates. Gate names identify the entry points to procedures. You can use gate names to give entrypoints different public names than those used in the source language.TimingWith respect to time, you can rate bindings on a scale running from early to late. An example of earlybinding is a compiler's assignment of segment-relative locations to procedures and data. The latestbinding is that accomplished by the processor as it adds a segment-relative location to the 24-bit baseaddress of the segment. Between these extremes are other opportunities for binding: .• Post-compile-time. Through Intel's utilities Builder and Binder, you can combine segments, resolveintersegment references, allocate descriptor table slots, and allocate memory.• Load-time. The loader can incorporate various levels of binding.a. If the object module contains fix-up information (as in a linkable module), the loader can bindall references as it loads the segments of a task.b. The call gates of the <strong>iAPX</strong> <strong>286</strong> architecture make it possible for the loader to efficiently resolvereferences to predefined classes of procedures (to operating system primitives, for example) atthe time a program is being loaded. This chapter presents an example of this form of load-timebinding in a later section.• Run-time. Call gates also permit binding to an executable segment at the time it is first referenced.By resetting the present bit in a call gate to an unloaded segment, you ensure that a trap will occurwhen the gate is used. The "not present" trap handler can then load the required segment, allocatea descriptor for it, and fix up the call gate.IMPLEMENTING ACCORDING TO THE MODELWith a binding model in mind, consider how to implement that model during the various stages ofsystem development: in source code, by translators, by binding utilities, by loaders, by the operatingsystem, and finally by the processor itself.11-3 121960-001

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!