CirioDoc.tioga
Theimer, October 15, 1989 4:27:07 pm PDT
Last changed by Theimer on November 3, 1989 11:02:50 am PST
Sturgis, April 17, 1990 2:47 pm PDT
Last tweaked by Mike Spreitzer on July 24, 1992 11:16 pm PDT
Udagawa, January 13, 1991 7:05 pm PST
Laurie Horton, January 26, 1993 10:46 am PST
Philip James, March 6, 1992 4:30 pm PST
Katsuyuki Komatsu January 7, 1993 1:21 pm PST
Jas, January 6, 1993 1:58 pm PST
CIRIO DEBUGGER
CEDAR 7.0 — FOR INTERNAL XEROX USE ONLY
The Cirio Debugger
a multi-language, multi-target-world debugger
Howard Sturgis and Marvin Theimer
© Copyright 1989, 1990, 1991, 1992 Xerox Corporation. All rights reserved.
Abstract: Cirio is a debugger intended to support the debugging of systems written in multiple programming languages and running on multiple target machines. Currently Cirio understands the Cedar and C programming languages and understands about programs run on D-machines or in PCR-based systems. The current version is still very much a prototype, with much of its functionality missing.
Created by: Howard Sturgis and Marvin Theimer
Maintained by: Howard Sturgis <Sturgis.pa> and Marvin Theimer <Theimer.pa>
Keywords: debugging
XEROX  Xerox Corporation
   Palo Alto Research Center
   3333 Coyote Hill Road
   Palo Alto, California 94304

For Internal Xerox Use Only
Cirio News
January 26, 1993
(December 30, 1992?)
User Interface Changes:
(1) [Viewers]
Added Disassemble button to CirioRemote Viewers interface.
[changes in RemoteDriver3, StackCirio, StackCirioImpl]
A disassembler of RS6000 and MIPS has not been implemented yet.
(2) [CommandLine]
Added RemoteDisassemble command correspond to Disassemble command of CirioRemote Viewers. The syntax is:

RemoteDisassemble [CProcName | PC]

[change in CommandLineCirioImpl, StackCirio, StackCirioImpl]
(3) [CommandLine]
Added BreakAtAddress command correspond to SetBreakAtAddress command of CirioRemote Viewers. The syntax is:

BreakAtAddress Address

[change in CommandLineCirioImpl, StackCirio, StackCirioImpl]
Bug Fixes:
(4) Several bug fix of Solaris2.x debugging.
[change in SunELFFiles]
(5) Support long magic number to distingish ELF files (4 bytes is not enough length to distingish ELF files).
[change in ObjectFilesImpl, ObjectFilesPrivate, SGIFiles, SunELFFiles]
(6) Flush command trigers off the .o search for Solaris 2.x.
[change in StackCirioImpl.NoteFileCacheFlush]
(7) Added "rhome" to the maching list for FX network.
[change in CirioDeltaFaceSunImpl.DebuggeeNameToDebuggerName]
January 7, 1993
New Features:
(1) SGI/IRIX 4.05 (and IRIX 5.0 untested) remote debugging capability.
[changes in CirioBreakAccess, CirioBreakAccessImpl, CirioNubAccessImpl, CirioTargets, CirioTargetsImpl, LoadStateAccessImpl, ObjectFiles, ObjectFilesImpl, ObjectFilesPrivate, RCTW, RCTWFrames, RCTWOrdinaries, StackCirioImpl]
[added SGI, SGIFiles]
December 30, 1992
New Features:
(1) Solaris 2.x remote debugging capability.
[changes in CirioTargetsImpl, LoadStateAccess, LoadStateAccessImpl, ObjectFiles, ObjectFilesImpl, ObjectFilesPrivate, RCTWFrames, RCTWOrdinaries, RMTWFrames, RMTWModules, StackCirioImpl]
[added RMTWBackdoor, SunELFFiles]
Bug Fixes:
(2) Fixed a type query problem with BYTE variables (XDT#130).
[change in CedarNumericTypesImpl.NumericalPrintType]
(3) Fixed a bug in argument parsing that was causing a crash.
[change in RemoteDriver3.Driver]
(4) Fixed a bug in FlushCache (XDT#124).
[change in RMTWAtomics.CheckForSpecialCTX]
(5) Catched MobAccess.MobError (XDT#127).
[change in RMTWModules]
(6) Catched CirioMemory.Error before CirioBackstop.Protect to show the frame of ENABLE clause which has local variable (XDT#128).
[change in RMTWFrames.FinalBuildProcFrameNode]
(7) Fixed a address fault problem when showing a frame which contains a MACHINE CODE procedure (XDT#131).
[change in RMTWCompounds.RecordIndexToNTConstant]
September 28, 1992
(1) Fixed a bug in SunADotOut symbol parsing that was recently introduced. This bug did not affect Mesa debugging - only C debugging.
[change in ObjectFilesImpl.GenSymbolStabs (syntheticOuter)]
September 17, 1992
(1) Fixed a problem with INT16 variables (actually with other numeric subranges as well).
[changes in RMTWAtomics.AnalyzeCedarNumericSEH]
(2) Implemented a workaround for a problem with NetworkName.AddressFromName when NIS is not running (e.g. on home configurations).
[changes in CommandLineCirioImpl, RemoteDriver3]
August 15, 1992
(1) Cirio will now refuse to connect to it's own <Machine> <Port> when remote debugging (Viewers: CirioRemote command or CommandLineCirio: CirioConnectToWorld command).
(2) CommandLineCirio now automatically starts a NetCommander on port (CirioNubLocalGetPort + 10000). It also gives messages to the user explaining why this is good and how to connect to the NetCommander.
(3) Fixed a bug in CirioBreakAccessImpl.UpdateSpacers that was causing a crash.
July 24, 1992
(1) Michael Plass's SPARC disassembler has been integrated. The show-source-position operation in machine language now prints a disassembly of the current procedure.
Sometimes the speculative estimation of register contents goes so wrong that a fetch is attempted from an un-mapped address. Sometimes this causes strange behavior. For example, I've seen a message on the UNIX stdout saying something about the debuggee being stopped due to a signal --- while the debugger continues to successfully interact with the debuggee; asking UNIX to resume the debuggee (eg, with "%" in the C-shell) seems to restore complete normality.
(2) There is now some "expression interpretation" available in machine language. Actually, "expression" is a bit generous. What's done is just a variety of symbol lookups. Every result is a description of a loader symbol (ie, symbol defined in the symbol table that the loader sees). Remember that different operating systems have different relations between the name used in C source and the name given to the loader; SunOS, for example, prepends an underscore. The possible "expressions" are of the form:
<number> (in Mesa syntax, or C's hex syntax) => a symbol whose value the the largest value of any symbol not greater than the given number. For example, an address anywhere within a procedure should "evaluate" to the symbol for the procedure.
<C program name>.<item name> => the most recently defined text (ie, code space) symbol in a compilation unit whose name's last step (ie, the part after the last "/") is the given program name followed by a dot and arbitrary stuff. For example, "RopeImpl.←RopeImpl←P0" will "evaluate" (in SunOS) to the symbol for RopeImpl←P0 in a program named "/foo/bar/RopeImpl.c2c.o".
<item name> => the most recently defined loader symbol of the given name. For example, "←RopeImpl←P0" should evaluate (in SunOS) to the same symbol as in the previous case.
(3) Breakpoints can now be set at arbitrary addresses through the Viewers interfaces, by middle clicking the "SetBreak" button with the desired address selected. The address should be in Mesa, or C's hex, syntax.
(4) Cirio now tries harder to find patch space for breakpoints. Any patch area near enough to the break address will now be usable.
Sadly, Cirio searches only once for a patch area near enough to the breakpoint --- if it's full, you're still out of luck.
(4) The "Interpreter" command now takes an optional list of search directories.
(5) We've recently noticed that the "AddDir" button in a local Cirio tool breaks the tool it's invoked in --- and any others that exist at the time it's used. Giving search directories to the "Interpreter" command breaks previously-existing Cirio tools. The successful way to add a search directory is to first delete all existing local Cirio tools, then issue the "RecreateThisWorldCirioConnection" Cedar command, then issue an "Interpreter" command with the desired directories.
July 20, 1992
(1) Relaxed Cirio's response to double definitions. Now it prints a message and continues (instead of terminating) the type analysis.
When your C source includes something like
typedef struct label←t {
 int val[14];
} label←t;
the result of Sun's cc includes
fffffb05 - 00 0008 LSYM label←t:T(16,4)=s8val:(16,5)=ar(0,1);0;1;(0,1),0,64;;
fffffb05 - 00 0008 LSYM label←t:t(16,4)
the result of gcc includes
00000000 - 00 0000 LSYM label←t:T28=s8val:29=ar1;0;1;1,0,64;;
00000000 - 00 0000 LSYM label←t:t28
and you can't C-debug this module with Cirio because of some problem with redefinition of "label←t". I think this is the reason for certain code that previously mystified Laurie and me; we should now make it allow redefinition where the new and old defintions are = REFs.
June 25, 1992
(1) Bug fix in C-type parsing.
(2) Changed CirioBreakAccessImpl.mesa to use the platform dependent name translation for "SomePatchSpace".
June 2, 1992
(1) Changed Cirio's C type parsing protocol (in RCTW and ObjectFiles) to return a CirioTypes.Type (rather than a "DotOType" string).
(2) This allows Cirio to accomodate different C type grammars.
April 27, 1992
(1) Fixed the bug introduced last time around.
(2) Made another small improvement in the handling of gcc output.
April, 1992
(1) Made some changes to the handling of Sun a.out files so that gcc results as well as Sun cc results can be interpreted. Also improved the handling of Sun cc output. Also introduced a bug.
(2) Added a rudimentary attempt at finding C source files. Adding directories to the global search list helps.
March 30, 1992
(1) Workaround for the following AIX ld bug installed in XCOFFFiles.mesa.

On AIX (both 3.1.5 & 3.2), it seems static symbols are not relocated by ld. This causes Cirio to be unable to find the correct "versionStamp" address for cinded object files. Single object files work fine.
(2) Performance improvement for Cirio's inital connection time found and implemented by Carl Hauser. It seems to be about twice as fast now.
(3) Minor change to hot frame detection. It should now do a better job of predicting the hot frame for uncaught errors. It sure would be nice if PCR could provide this information.
March 6, 1992
RS6000 debugging works.
March 5, 1992
New Features:
(1) Opaque types can now be "seen" remotely. This functionality requires support in CedarCore and new DebugNub functionality.
(2) Some RS6000 remote debugging capability. All of the following functions are working:

Connection manipulation
 connect to /disconnect from an RS6000 pcr world
 stop / resume / kill execution of an RS6000 pcr world

Thread manipulation
 select (add) threads by filter (callingdebugger, ready, all)
 list available threads
 get thread summary
 detail thread
 proceed, abort, etc. thread

Frame manipulation
 walk stack
 show source position
 show frame
 expression evaluation including ampersand procedures, GLOBALVARS and EXPRTYPE

Basically everything except breakpoints is working. Breakpoints should be finished shortly.
  
User Interface Changes:
(3) [Viewers]
Added Find and Word buttons to CirioRemote Viewers interface.
(4) [CommandLine]
Improved CommandLineCirio to give a helpful message when a command is issued out of context.
(5) [CommandLine]
Changed the Walkstack command in CommandLineCirio to accept "Co" for "Cooler" and "W" for "Warmer". The syntax is now:

WalkStack [[Co[oler] | W[armer] [NumberOfFrames]] | AbsoluteFrameNumber] [C | Cedar]
Bug Fixes:
(6) Timeout errors during attempts to StopRemoteWorld now do not cause a Cirio crash.
February 13, 1992
(1) Added another &-proc:
&RdXStringBody: PROC [addr: CARD, char-count: CARD];
&RdXString couldn't be used when only an XStringBody was available.
Also fixed a problem with the implementation.
(2) Fixed memory dump procedures. The last release only printed 3 out of every 4 words.
(3) NIL answers to KillRemoteWorld verification in CommandLineCirio are now handled correctly.
(4) CirioHelp command in CommandLine cirio only displays currently available commands, instead of all CommandLineCirioCommands. If "all" is passed in as an argument, all commands are listed.
(5) New argument ("listed") accepted for Kill, Freeze, Proceed, Abort, and Summary commands in CommandLineCirio. When the new argument is supplied, the invoked command does its operation on all threads that have been added.
(6) XCOFF stab reader now parses stab strings better, and source positions can be determined.
February 3, 1992
(1) Cirio now understands how to do pointer comparisons (=, #, <, >, <=, >=), e.g.
&1 ← @r
105F5588H@
&2 ← @s
105F558CH@
&3 ← @s=@r
FALSE
&4 ← @s=@r+4
TRUE
&5 ← @s#@r+4
FALSE
&6 ← @s<@r+4
FALSE
&7 ← @s>=@r+4
TRUE
(2) Corrected thread id displaying - it sometimes displayed the wrong number even though it did the right operation.
January 29, 1992
(1) Attempts to print unbound variant records now result in an error message - not a crash.
(2) Attempts to print sequences with integer indices now succeed.
(3) Corrected CommandLineCirio's treatment of thread indices which caused confusion when threads numbers were not contiguous.
January 23, 1992
(1) Added three more &-procs:
&RdMem: PROC [addr: CARD, bytes: INTEGER, base: CARD];
&IndirectRdMem: PROC [addr: CARD, bytes: INTEGER, base: CARD];
&RdXString: PROC [XString-var-byte-address: CARD, char-count: CARD];
(2) An error is raised when trying to default variables for AmpersandProcs when no procedure with this functionality exists. This condition was not previously checked for.
January 17, 1992
Moved SameBreakWorld* into CirioBase to eliminate the need to recompile Druid to track Cirio changes.
January 16, 1992
(1) Cirio's file location searching order has been modified. Cirio now searches:
(1) in the user supplied and default working directories
(2) in the version maps
(3) in the locations found in the object files
(4) in other locations it stumbles across.
(2) A new default working directory has been included in Cirio - "-compiled:/CirioCompiledData/". This internal working directory contains the mobs that Cirio needs to make a connection. This makes Cirio startup slightly faster and makes Cirio significantly easier to distribute to sites without PCedar releases.
January 10, 1992
(1) Types and values are now printed on streams, instead of converted to ropes. StructuredStreams are used to format the output nicely with whitespace.
(2) Opaque types are now seen through, in the local case.
(3) Bound COMPUTED and OVERLAID variant record types now work correctly. (Bound non-COMPUTED non-OVERLAID variant record types are now slightly wrong --- the tag is missing).
(4) Most non-understood typestring contructs now produce broken types, rather than invalidating the whole typestring analysis. Array and procedure constructions are now understood.
January 6, 1992
(1) New Command: ChangeCirioMessageLevel
Usage: ChangeCirioMessageLevel [level]
Valid levels: urgent: Only displays necessary messages
   normal: Displays necessary and informative messages
   debug: All messages available are displayed
If no level is supplied, then the current level is displayed.
Profile Entry:
Cirio.MessageLevel urgent | normal | debug

default is "normal"
There are still problems throughout Cirio with using this, because not all output goes through SystemInterface.ShowReport. Not all levels are guaranteed correct.
December 23, 1991
(1) Further internal reoganization in the inexorable march toward righteousness. Type graph cycles are now broken at REFs when analyzing mob data structures. Records from mobs continue to defer analysis of their fields, just for laziness' sake.
(2) Introduced some analysis of typestrings, applied in the case of REF ANYs. A REF ANY value now appears as a REF to the actual type of the referent, when debugging locally and the analysis of the typestring describing that type succeeds. The analysis will fail if an opaque or painted type from a module not in the $Intermediate version map is encountered. The analysis will also fail on various other unimplemented cases.
(3) Added two more &-procs:
&GetTypestring: PROC [code: CARD] RETURNS [string, whyNot: Rope.ROPE];
&GetConcreteTypecode: PROC [opaque: CARD] RETURNS [concrete: CARD, whyNot: Rope.ROPE];
December 13, 1991
(1) Breakpoints can now be set in C code. Because C doesn't have any general way of testing whether a given object file was compiled from a given version of a source file (unlike Mesa, which records the source file's create date in the object file), the breakpoint-setting operation always works on the most recently loaded object code compiled from the indicated source.
(2) Fixed a swarm of bugs introduced in the October upheaval in connection with multi-word procedure parameters.
December 6, 1991
Fixed two bugs:
(1) A small bug in "CirioRemote" argument parsing.
(2) A bug (#2869) in ObjectFile parsing. The problem would show itself with a message like:
 "failure due to internal Cirio error: redefinition of dotOType (0,282)"
November 27, 1991
The CirioRemote command will now accept an initial list of working directories on the command line. This feature is useful if you are trying to debug a world that uses different versions of basic files, e.g. Rope.mob. The syntax is:

CirioRemote <hostname> [<portnumber> [<listOfWorkingDirectories>]]

For example:

CirioRemote swift 4815 /NewCedarFiles /MyTestFiles /MyFriendsTestFiles
October 17, 1991
During the past few months, Cirio has been undergoing some major changes. The goal of these changes is to make Cirio a multi-target debugger - specifically to support XSoft's product goals.

Cirio's treatment of object files, stacks, memory, breakpoints, etc. was revised so that several target-specific implementations could co-exist peacefully.

The SPARC/SunOS4* target should be functionally equivalent to the previous version of Cirio.

The RS6000/XCOFF target is still undergoing changes and is not yet ready for use.
August 17, 1991
(1) Made both local and remote connections start out with this list of directories to search for files: /PCedar2.0/Cirio/, /PCedar2.0/CirioThings/, /PCedar2.0/Atom/, /PCedar2.0/Rope/. This makes the navel-examination done at startup succeed even in the absense of version maps. The files needed are currently: CirioThings/CirioRopeHelper.mob, Cirio/CCTypesImpl.mob, Cirio/CirioTypes.mob, Cirio/NewAmpersandProcs.mob, Cirio/NewAmpersandProcsImpl.mob, Rope/Rope.mob, and Atom/AtomPrivate.mob. For C interpretation, the file /CedarCommon2.0/FamousFiles/c.kipperedParseTables is also needed.
August 9, 1991
(1) `CirioRemote localhost' should now work reasonably on a machine that's not running NIS (nee YP) and an automounter.
August 8, 1991
(1) Added machine language to those barely understood by Cirio. Cirio cannot interpret any machine-language expressions or statements. But it can print machine-language frames. Such a printout lists the PC, SP, and the input, local, and output registers. When used in conjunction with the disassembler in SparcAids, and the memory dumping available in the Cedar language, this might be just enough to do some debugging of optimized code.
(2) Made the `frame banner' (what's printed as you WalkStack into a frame) more informative: if the frame is in optimized code, the code base address and module offset are now printed; they were already being printed when the fram is in unoptimized code. The code base address is where the code of the containing object file starts in memory; the module offset is where the code of the compilation unit responsible for the frame in question starts within all the code of the containing object file.
July 12, 1991
(1) Cirio now catches the error that occurs when it interprets an expression that tries to divide by zero.
(2) When the remote world goes away, Cirio now stores that information so that it doesn't try further interactions. The breakcheckdaemon already noticed when the remote world went away, but didn't record this fact in any data structure, it only stopped its own train of action.
July 3, 1991
(1) New Command added

Usage: ← <expression>
(2) Fixed procedure called after QuitWorld is called so that it wouldn't try outputting to a non-existent viewer.
(3) Increased the intelligence of hot frame detection. Added some cases to the check procedure for finding hot frames.
July 2, 1991
(1) Cirio now prints less information about a procedure when the printing depth is less than 3.
(2) Cirio now prints some symbolic information about a procedure implemented in an optimized module. When the printing depth is deep (>2), such a procedure is printed as "loadedFile.guessedComponent.cProcName"; loadedFile is the UNIX name of a file that UNIX ran (such as "/tmp/CommanderWorldPackage") or the PCR incremental loader loaded (such as "/pseudo/pcedar2.0/crrpc/sun4-o3/crrpcimpl.c2c.o.~4~"); guessedComponent is a guess at the UNIX file name of the compilation unit (such as "IOCommonImpl.c2c.o") within the loaded file; and cProcName is the C-level name of the procedure (such as "�ultEndOf←P960"). When the printing depth is shallow, the loadedFile is omitted.
(3) Added another ampersand procedure to give access to the incremental loader in the debuggee (ie, not for casual users).
&GetFileEntry: PROC [seqNum: CARD] RETURNS [REF FileEntry];
This procedure provides direct access to a CirioNub procedure.
June 8, 1991
(1) Cirio should now find frame extensions and global links (which I think it doesn't use) that are misplaced by Mimosa into the NIL context. In user-ese, that means Cirio is now able to determine the addresses of more local variables than before.
(2) Cirio now knows where Mimosa hides the variables local to an ENABLE scope.
June 5, 1991
(1) Added the `CirioBugTreatment' command, which offers the option to change how Cirio reacts to its own uncaught errors (some of which are due to bugs, and some of which are due to erroneous input). The command takes one optional argument, indicating the new treatment: `catch', the old and default behavior, means to catch and report the error; `reject' means to not catch the error; and `oz' means to first call XR�llDebugger (which punts directly to the debug nub for remote debugging) and then catch and report the error. When invoked with no arguments, `CirioBugTreatment' simply reports the current state.
June 4, 1991
(1) Major internal re-organization. There is no longer a distinction between type-time and structure-time --- at least for the Cedar part; the C part has been left working the old way, so this revision of Cirio can be brought to a timely conclusion.
(2) The static links out of procedures with no local variables now can be seen. The static links out of ENABLE scopes now can be seen.
(3) Data whose size is not a multiple of 32 bits now are correctly extracted from REF targets and local frames.
(4) Variant records now print without crashing.
(5) Broken remote-Cirio tools can now be deleted.
May 5, 1991
(1) Made a few changes to the way Stack Summaries and Frames are presented:
(1.1) Cirio now attempts to determine the first "interesting frame" and begin the summary with that frame. In general, the "interesting frame" will be the one that caused the debugger to be invoked, raised an error, etc. [The "interesting frame" is determined heuristically since pcr doesn't currently save this information. Hopefully the next version of pcr will be able to supply it.]

The "interesting frame" is indicated by the characters "=>" displayed in the left margin. If you select another frame by "walking the stack", the selected frame is indicated by the characters "->" displayed in the left margin. The only way to see a frame "hotter" than the "interesting frame" is to "walk the stack" to select it.

The summary will start with the "hotter" of the selected frame or the "interesting frame". For example:
quick summary for thread with index 1
 debug message = ClientRequest
-> 6: �llDebugger←P60 (pc=88H, from CirioThingsImpl.c2c.o)
LoadStateAccessImpl reports no guessedEmbeddedFile for abs PC = 19326128
 7: unreadable frame
=> 8: ←TestSort←P300 (pc=8C0H, from QuickSortTest.o)
 9: ←NoName←Q576 (pc=EFCH, from QuickSortTest.o)
 10: ←XR𡤎nable (pc=5CH, from SignalsImpl.c2c.o)
 11: ←RunQuickSortTest←P360 (pc=A8CH, from QuickSortTest.o)
 12: ←QuickSortTest←P0 (pc=208H, from QuickSortTest.o)
 13: 𡤍oStartProgram←P3180 (pc=44C0H, from InstallationScopesImpl.c2c.o)
 14: 𡤍oStartConfig←P3120 (pc=4424H, from InstallationScopesImpl.c2c.o)
 15: ←XR←StartCedarModule (pc=4814H, from InstallationScopesImpl.c2c.o)
 16: ←XR←run←QuickSortTestConfig (pc=118H, from QuickSortTestConfig or QuickSortTestConfig.o)
....
(1.2) When detailing a thread, the "interesting frame" is automatically selected - you don't need to "walk the stack" to select it prior to doing operations like SourcePosition, ShowFrame, etc.
(1.3) ShowFrame now includes the address of the frame in the information displayed about the frame. (This address can be used to directly access the frame when Cirio doesn't tell you what you wanted to know.) The new output looks like this:

Showing frame:
(frame address: 1461888)
""
<node of unknown type (frame's procedures not implemented)>
 Arguments--
  ^[min:10, max:19]
 Results--
  ^[]
 Variables--

---Global Frame ommitted---
(2) Changed the "Listed threads:" control buttons interface slightly. The "Listed threads:" buttons now appear only if threads have been added via the "CallingDebugger", "Ready" or "All" threads selection buttons.
April 12, 1991
(1) Added a new set of buttons to the Viewer user interface to provide thread control for a set of "Listed threads:". These buttons are similar to the ones provided for individual thread control, but operate on ALL threads appearing in the threads list.
(2) Some useful (and perhaps previously undocumented) operators for use in expression evaluation:

`@Foo' prints the address of Foo
`Foo?' prints the type of Foo
`Foo!' each `!' increases the print depth (by 1) and width (by 10) of Foo
`Foo$' turns on copious debugging output for the evaluation of Foo - this is not for the faint of heart!
March 20, 1991
(1) Added StackCirio.ClearBreakPointAtPosition to support specifying a "break to clear" by it's source file position (analagous to SetBreak). This functionality is currently only available from the CommandLine or dbxtool user interface - it is not yet available from the Viewers user interface.
(2) Fixed several address faults.
January 13, 1991
(1) Attention for breakpoint is implemented. When PCR world(Debugnub.o) get a SIGINT, an message "SIGINT: debuggee needs attention." will appear in RemoteCirio / CommandLineCirio. Latest PCR(3𡤄, dated Jan 14, 1991) is required.
(2) As the deamon is introduced for WaitSig(), the communication between Cirio and Debunnub.o becomes slow in RemoteWorld Running.(Each WaitSig() takes 2 second) But, usual debugging is done in RemoteWorld stopping. So it will affect only StopRemoteWorld/ResumeRemoteWorld.
December 13, 1990
(1) Atoms will print out (as `$"pname"' for an ATOM with `pname' as its print-name).
(2) Non-understood types will be printed as raw bits, if the length is known.
(3) Broken nodes and types should now include a description of the problem in their printing.
(4) ShowFrame omits the global frame (which is now accessible via GLOBALVARS). Unless the print depth is greater than 3, which is the default - and there's currently no way to override the default.
(5) The stack summaries come in two flavors: (1) with the embedded-module-relative PC, and (2) without. Flavor 1 is under the left mouse button on the summary screen button, and Flavor 2 is under the middle mouse button.
(6) The stack-specific buttons in a remote Cirio tool now include one, named `*', that offers all the functions of the others; these buttons have been PopUpButtons for a while now.
(7) You can now, in principle, take the address of any value with a runtime address. However, the result is always a POINTER TO .., never a POINTER TO READONLY ..! Be careful not to store through such pointers! Some kinds of values, such as procedures in global frames, don't actually support taking their addresses.
(8) Cirio works a little better now when you load multiple copies and versions of a program. The remaining bug I know about is that the SetBreak operations are not sufficiently choosy about matching up a loaded program with the source indicated.
December 7, 1990
(1) `GLOBALVARS[Foo]' denotes the global variables of the most recently loaded instance of module Foo. `GLOBALVARS[Foo, 3]' denotes the global variables of the 4th most recently loaded instance of module Foo. The GLOBALVARS construct may appear on the left side of an assignment.
(2) `EXPRTYPE[e]' denotes the statically apparent type of expression `e'.
September 4, 1990
(1) Fixed PopUpDriver2 to call LocalCirio.ReleaseConnection where it should, resulting in faster creation of new local debug tools. Thanks to Carl Hauser for finding this problem and fix.
August 31, 1990
(1) The user now controls the language being interpreted. When Cirio's attention is focused on a particular stack, there's a `Language' button that is used to control the language used in that stack.
(2) C source line numbers can now be reported; it still will not open a viewer for you.
(3) Conditional expressions (test?ifTrue:ifNot) now work. += and friends now work (but they evaluate the left argument twice).
(4) Procedure values now exist (although you still cannot call them).
(5) Adding integers to pointers now works. The ``ptr[idx]'' syntax works.
August 28, 1990
(1) C debugging gets better.
`Global' variables (static, extern, and common) should work now.
Assignment should work now.
(2) Opaque values should no longer cause address faults.
August 22, 1990
(1) C debugging begins to appear. Not available yet:
Anything involving C source locations (this includes anything involving breakpoints in C code).
`Global' variables (static, extern, and common). Note that this means ShowFrame will always fail.
Assignment.
Procedure values.
`Ampersand-variables' (and -procedures). I think the way to approach these is to make `ampersand' be a logical concept, bound to one of underscore (←) or octothorpe (#) in C.
User control over which language is interpreted.
(2) The prompt tells you the language in which your expressions will be interpreted. A prompt that looks like `&42 ← ' indicates Cedar; a prompt like `/* 47 */ ' indicates C.
(3) Various other kinds of cleanup:
I now believe that variables used inside an ENABLE or ! but declared outside should be visible from frames outside the ENABLE or !. Actually, this has been the case for quite a while, but I was confused by other bugs that appeared when I tried this case.
A ROPE that was NIL used to cause a crash; it no longer does.
It's now possible to see SEQUENCE values.
(4) It's still so impossible to see an opaque value that you'll get an address fault if you try.
July 20, 1990
(1) Cirio now has some more ampersand procs, to make it possible to build ROPE parameters passable to the &Lookup.. procedures. This is an interim solution; there is a deeper bogon that needs to be annihilated. Don't try to get ROPEs made with these procedures into the target world (aka debugee), neither by passing them to target-world procedures nor by storing them into target-world data structures nor by any other method you can think of; I don't know what will happen if you try, but I know it won't be helpful. In just the same way, don't try to pass target-world ROPEs to the &Lookup.. or the ..LocalRope.. procedures. Doing these things could cause memory smashes!
&MakeLocalRope5: PROC [c1, c2, c3, c4, c5: CHAR] RETURNS [ROPE];
Makes a ROPE in the debugger (not debugee, aka target) containing up to 5 characters. The first space an following characters, if any, are not included in the result.
&MakeLocalRope10: PROC [c1, c2, c3, c4, c5, c6, c7, c8, c9, c10: CHAR] RETURNS [ROPE];
Makes a ROPE in the debugger (not debugee, aka target) containing up to 10 characters. The first space an following characters, if any, are not included in the result.
&LocalRopeConcat: PROC [base, rest: ROPE] RETURNS [ROPE];
Like Rope.Concat.
&LocalRopeCat: PROC [r1, r2, r3, r4, r5: ROPE] RETURNS [ROPE];
Like Rope.Cat.
&LocalRopeSubstr: PROC [base: ROPE, start, len: INT] RETURNS [ROPE];
Like Rope.Substr.
Spring 1990
(1) A few &Lookup.. procedures weren't documented. They follow. The &Lookup.. procedures are mainly useful for debugging the debugger; they provide lower-level access to loadstate information in the debuggee.
&LookupFileEntryByStemName: PROC [stemName: ROPE, numToSkip: INT] RETURNS [name: ROPE, type, value, size, fileSeqNum: CARD];
This procedure provides direct access to a CirioNub procedure.
&LookupSymEntryByName: PROC [sym: ROPE, caseSensitive: BOOLEAN, externOnly: BOOLEAN, numToSkip: INT] RETURNS [name: ROPE, type, value, size, fileSeqNum: CARD];
This procedure provides direct access to a CirioNub procedure.

June 8, 1990
(0) Cirio now understands ROPEs as such (and Rope.Texts, too). Don't be discouraged by all the things you can't do with them --- you can't do those things with REFs either.
(1) Cirio now has more ampersand procs.
&MemDump: PROC [addr: CARD, bytes: INTEGER ← 16];
The given address is rounded down to the nearest word boundary. Prints, in hex and as characters, the contents of the indicated bytes in the target world. Until the debugee CirioNub is improved, don't give invalid addresses. Note that when debugging from PCedar, default values don't work (yet).
&IndirectMemDump: PROC [addr: CARD, bytes: INTEGER ← 16];
Like &MemDump, but first reads the address to start dumping from the word at the given address (which is first rounded down to the nearest word boundary).
&PokeCard: PROC [addr, val: CARD, mask: CARD ← 0FFFFFFFFH];
The given address is rounded down to the nearest word boundary. Alters a 32-bit word, or a subset thereof, in the target world. The value and mask are treated as CARDs: the 2i's bit of the val and mask affect the 2i's bit of the word-interpreted-as-a-CARD at the rounded address. Until the debugee CirioNub is improved, don't give invalid addresses.
(2) It is now possible to take the address (with @) of many kinds of varaibles.
(3) It is now possible to assign to the referent of a REF <some numeric type>.
(4) When cross-debugging (from D to P), correct byte orders are now used.
(5) The version map usage has been slightly changed (hopefully for the better). In PCedar, you want the following profile entries:
VersionMap.SourceMaps: [PCedar2.0]<VersionMap>PCedarSource.VersionMap
VersionMap.IntermediateMaps: [PCedar2.0]<VersionMap>PCedarIntermediate.VersionMap
VersionMap.ExecutableMaps: [PCedar2.0]<VersionMap>PCedarSparcExecutable.VersionMap [PCedar2.0]<VersionMap>PCedarSparcOptExecutable.VersionMap
In DCedar, you need the same entries, except that the names are VersionMap.PSourceMaps, VersionMap.PIntermediateMaps, and VersionMap.PExecutableMaps, respectively.
April 17, 1990 2:31:02 pm PDT
(0) When a Cirio tool starts up, it spends an initial period examining its navel" in order to construct the ampersand procedures. This period may include several messages about its activities. The period is completed when the tool prints its date and time, followed by the "&1 ← " prompt.
 WARNING: until certain low level locks are repaired, one should avoid loading any packages into the PCedar world until a tool completes its initial period.
(1) Cirio now has ampersand vars. A Cirio prompt now has the form: "&n ← ", where n starts at 1 and increases for each expression evaluated. After evaluation, &n will continue to hold the result of the evaluation. Further, one can name ones own ampersand vars, e.g., one might type "&foo ← exp".
(2) Cirio now has a small collection of ampersand procs. These are procedures that are part of Cirio which can be invoked through expressions typed into the typescript.
(a) &dr[byte-address, word-count]

Accepts two 32 bit cardinal values. Prints the decimal value of word-count 32-bit words, starting at byte-address.
(b) &RdRope[rope-var-byte-address, char-count]

Accepts two 32 bit cardinal values. The first is the address of a rope variable (not the rope). The second is the number of characters to print. Handles ropes built up from components. (Reads the rope structure and converts to a sequence of characters.)

As an example of use, assume that rope is a visible variable of type Rope.Rope.
 First, evaluate the expression "@rope". This will proceduce a byte-address of the rope variable, for example, 2345678B.

Second, evaluate "&RdRope[2345678B, 100]".
(c) &LookupMatchingSymEntryByValue[symId: CARD, val: CARD, wantedTypes: CARD, ignoreClasses: CARD, numToSkip: INT]

This procedure provides direct access to a CirioNub procedure. It's behavior is a teensy bit complicated. See me or Alan.

A typical call might be:
 &LookupMatchingSymEntryByValue[0, 12345, 37777777777B, 0, 0]
(d) &LookupMatchingSymEntryByName[symId: CARD, pattern: Rope.ROPE, caseSensitive: BOOLEAN, wantedTypes: CARD, ignoreClasses: CARD, numToSkip: INT]

This procedure provides direct access to a CirioNub procedure. It's behavior is a teensy bit complicated. See me or Alan. (This procedure is not usable on the Sun until we get Rope.ROPE procedure parameters working.)
March 21, 1990 11:12:31 am PST
It has become harder to find mobs and other files both remotely from a D-Machine and locally from a Sun. The difficulties have to do with PFS naming conventions.
work-around
Use AddDir to add the full path name of the directory from which the file was executed. BE SURE to use bracket syntax, but DO NOT include "-vux:" or "-ux:". (In order to avoid using "-vux:" or "-ux:", you can make an appropriate prefix map entry.)
Introduction
The Grand and Glorious Goal
To debug anything, anywhere, anytime, anyhow.
In practice, this probably means support for the PCR "world": being able to debug a program running in a PCR world, irrespective of what languages it's parts were written and what machine that world happens to be running on. For example, if a Scheme application has called a Cedar library package, which in turn makes use of a C procedure, then you should be able to look at the call stacks for the application and see the call frame of each procedure shown in a form appropriate to the language it was written in. You should also be able to utter expressions to the debugger for each call frame in the language in which the call frame's procedure was written in.
Specifically, Cirio allows one to examine and modify the current state of some target world, from the point of view of some context in that world. Typically, one does this by evaluating expressions in some language appropriate to the current context. These expressions can include the invocation of procedures which in turn may instigate fairly complex changes in the target world. One may also plant and remove breakpoints in the target world. If execution in a target world thread encounters a breakpoint, that thread will discontinue execution and may be used as a context for debugging.
Cirio has been designed so that (in theory) adding new languages and new target-worlds is easy. This has been done by employing an object-oriented approach for the architecture, so that the details of each language and each target world are hidden to the extent possible.
The Current State of Affairs
Cirio currently only understands the Cedar programming language, although it has handled C in the past and will probably do so again. We will restrict this document to describing the use of Cirio to debug PCR worlds.
Cirio is generally invoked through a tool. Versions of this tool can be used to debug the same world as that in which it is running, other versions can be used to debug a remote world.
(1) There is a same-world version of the tool that runs in PCedar on Suns, providing debugging access to that PCedar world.
(2) There is a remote version of the tool that runs in PCedar on Suns, providing debugging access to other PCR worlds on the same Sun or on remote Suns.
(3) There is a remote version of the tool that runs on D-Machines, providing debugging access to PCR worlds on remote Suns.
What You Need to Know About Cirio
To use Cirio you need to know/do several things. A summary is given here; each item is described in more detail later on.
You need to install and run an appropriate Cirio debug tool.
You need to know how to operate the Cirio debug tools.
You need to ensure that the PCR world you wish to debug remotely includes the necessary Cirio support code as a part of it.
You need to understand the current limitations of the Cirio tools.
Same-World debugging
Obtaining a Same-World Cirio debug tool
Same-World debugging is by far the simplest mode of operation. The same-world Cirio debug tool provides debugging access to a single PCR thread. The tool may be created in response to an unforseen error (uncaught SIGNAL or ERROR) or upon encountering a previously set breakpoint.
To prepare for this mode of operation, one simply executes the following command:
CirioLocal
This will load the necessary support code for Cirio as well as register Cirio as the local debugger. Following this command one may obtain a Cirio tool in either of two ways. (1) If some thread encounters a previously set breakpoint or if some thread not running under the direct control of the CedarCommander generates an uncaught SIGNAL or ERROR, then an instance of the same-world Cirio tool will "pop-up" in the left hand viewer column. This tool will have as its context the thread that encountered the breakpoint or generated the uncaught SIGNAL or ERROR. (2) If a thread running under the direct control of the CedarCommander generates an uncaught SIGNAL or ERROR, then the Commander reports the situation as follows:
*** Uncaught ERROR or SIGNAL: unrecognized error
*** Do you want to try to debug this?
Typing "y" followed by a carriage return will cause an instance of the same-world Cirio tool to "pop-up" in the left hand viewer column. This tool will have as its context the thread that generated the uncaught SIGNAL or ERROR.
In addition, one may also obtain an instance of the same-world Cirio tool by executing the following command:
Interpreter
This version of the tool permits the setting and clearing of breakpoints, but has no thread context to debug. (Executing this command also performs the preparatory functions provided by executing CirioLocal.)
Using a Same-World Cirio debug tool
The same-world Cirio debug tool provides debugging access to a single PCR thread. The tool viewer is divided into two windows. The top window provides a collection of buttons for invoking specific actions and the lower window contains a type script. Cirio uses the typescript to issue reports on actions in progress, as well as accepting expressions from the user for evaluation.
Top row of buttons in the upper window
SetBreak:
If the user left-clicks this button while there is a current selection in some Mesa file, then Cirio will endeavor to find a loaded instance of that file and plant a breakpoint at the beginning of the smallest statement including the first character of the selection.
ListBreaks:
If the user left-clicks this button, then Cirio provides a list (in the typescript window) of the current breakpoints. (Unfortunately, at present time this list does not include the source position of the breakpoints.)
ClearBreak(s):
If the user left-clicks this button while the current stack frame under examination (see the WalkStack button described below) is at a breakpoint, then Cirio will clear that breakpoint.
If the user middle-clicks this button, then Cirio will clear all current breakpoints.
AddDir:
If the user left-clicks this button while there is a current selection containing a directory path name, then Cirio will enter that path name its collection of possible locations for finding files.
FlushCache:
If the user left-clicks this button, then Cirio will forget the fact that it has been unable to find certain files. This is useful if one has just moved a previously unfound file into a directory in which Cirio might look for it.
Stop:
Terminates the Summary list operation. (Perhaps someday it will terminate other operations.)
Second row of buttons in the upper window
frame: n:
This is not a button, but rather a status field showing the index of the current frame in the thread under examination. Hot frames have smaller index numbers than cold frames. The hottest visible frame has index 0.
Summary:
Produces (in the typescript window) a list of the frames in the thread under examination, hottest frame first.
WalkStack:
Moves the focal point within the frame currently under examination. The semantics are a tiny bit complicated, but left click moves one frame colder and right click moves one frame hotter. In more detail, the action depends on which mouse button is clicked, as well as whether the shift or control keys are down, as follows:
(a) the mouse buttons mean:
left: move to cooler frame
middle: move to specified frame
right: move to hotter frame
(b) the shift key means: read current selection for a number 
(c) the control key means: work in terms of Cedar frames
Thus, for example, shift-middle with 5 selected means move to the frame with index 5.
One should be aware that working in terms of Cedar frames is fairly expensive. Further, one should observe that not all combinations of mouse buttons and keys make sense.
ShowFrame:
If the user left-clicks this button, then Cirio displays the contents of the variables visible to the frame currently under examination. This includes the variables in all enclosing blocks, including the global frame.
At the moment this operation is fairly slow. This is due to some injudicious mechanisms used for displaying the value of procedure constants, together with the fact that the global frame typically contains many procedure constants.
SourcePosition:
If the user left-clicks this button, then Cirio attempts to locate the Mesa file containing the procedure executing in the frame currently under examination. If the file can be found, and if various other files can also be found, then Cirio opens a viewer on the Mesa file. After opening the file, Cirio places a feedback selection at the beginning of the smallest statement containing the current pc of the frame.
Proceed:
Cirio returns control to the procedure that invoked the debugger.
Abort:
Cirio raises ABORTED in the thread under examination.
typescript window
Cirio uses this window to report actions to the user and to accept expressions for evaluation from the user. The reports are self explanatory.
It is the intention that if one types an expression (followed by a carriage return) in a language appropriate to the frame currently under examination, then Cirio will attempt to evaluate that expression in the context of that frame. For example, if one types the name of a variable visible to the frame currently under examination, then Cirio will print out the current value of that variable. Since assignments are expressions in Cedar, if Cedar is an appropriate language, then one can change the current values of variables by typing appropriate assignment expressions. Further, procedure invocations are also expressions, so one can invoke (visible) procedures by typing the appropriate expressions.
At the moment, there are numerous limitations on this facility. Cirio understands only Cedar. Cirio does not understand all Cedar value types. (In particular, this includes REF ANY and OPAQUE. Further, Cirio's understanding of Rope.ROPE is very limited.) Cirio is frequently unable to find variables that it knows exist.
If Cirio does not understand a value type, it prints "???". If Cirio does not understand how to find a variable, it prints "Node?".
Using a Cirio Same-World Interpreter tool
The interpreter tool (obtained by executing Interpreter) is very similar to the Same-World debugger tool, except that this tool has no thread under examination. Thus, only the first row of buttons is available, but they behave exactly as described above. The typescript window also behaves exactly as described above; however, there are no visible variables to use in expressions.
Remote Debugging
Preparing a Remote PCR world to be remote debugged
One must anticipate the future desire to remote debug a PCR world at creation time.
(1) The PCR world must contain a Cirio Nub running in a slave IOP.
(2) This nub will be connected to some port.
(3) The PCR world must have certain auxiliary packages loaded.
(4) You must know the port number.
The easy way
Items (1), (2), and (3) will be accomplished automatically if you start the PCR world with the shell command:
CedarCommander
In this case, if there are no other PCR worlds on the same Sun and you have not set the shell envirionment variable: CirioPort, then the port number will be 4815. ("for 815", for those of you who have done remote debugging in the old D-Cedar world. This number is complements of Al Demers.)
If there are other PCR worlds on the same Sun, then the Cirio Nub will select the first unused port number that it finds, trying the numbers 4815, 4816, ... in succession.
temporary problem
At the moment, CedarCommander does not load the neccessary auxiliary packages. These will be loaded if you execute "CirioLocal" in a command tool, or if you include the following in your CommandTool.BootCommands user profile entry:
run /PCedar/CirioThings/CirioThingsImpl
run /PCedar/CirioThings/RegisterSaveRestore.o
Item (4): You must know the port number.
There are four ways to learn your port number:
(a) Know that if you have started the easy way, there are no other PCR worlds on the same Sun, and you have not set the shell envirionment variable: CirioPort, then the port number will be 4815.
(b) It appears in the pcr type script in the following form
pcr: CallAll 𡤌irioNubStart
CirioNubInstall v 6 ... returns 4815
(c) If your are in a viewers world, Execute "CirioPortButton" in some command tool, before you perform any operation that invokes the same-world or remote Cirio debugger (such as Interpreter, CirioLocal, or CirioRemote). This will create a button in the upper right hand region of your Cedar viewers containing the Cirio Port number. If you execute "CirioPortButton" too late, the button will appear, but the number displayed will be (incorrectly) 0. If you execute this command without first have created a Cirio Nub running in a slave IOP, I don't know what will happen.
(d) Execute "ShowCirioPort" in some command tool, before you perform any operation that invokes the same-world Cirio debugger (such as Interpreter CirioLocal, or CirioRemote). This will print the port number in the typescript in which you executed ShowCirioPort. If you execute "CirioPortButton" too late, the number displayed will be (incorrectly) 0. If you execute this command without first have created a Cirio Nub running in a slave IOP, I don't know what will happen.
The hard way
If your prefer to roll your own, here are some helpful hints (your author is NOT an expert in these matters):
(1) The PCR world must contain a Cirio Nub running in a slave IOP.
(a) "-slave 1"
as a threads parameter to your pcr will provide a slave IOP.
(b) UnixLoad /pseudo/xrhome/INSTALLED/LIB/Threads-sparc/DebugNub.o
in your pcr script will load a CirioDebugNub.
(c) CallAll 𡤌irioNubStart
in your pcr script will will start the debug nub.
(2) This nub will be connected to some port; you must know the port number.
 setenv CirioPort num
 as a shell command will specify a specific port number for the debug nub. (If this port is busy, the nub will fail to connect to a port, and will report -2 as its port number.) If you have not set this environment variable, then the debug nub will hunt for a usable port as described above.
 In any case, the chosen port number will be reported as described above.
(3) The PCR world must have certain auxiliary packages loaded.
(a) You can load them with the following commands in your CommandTool.BootCommands user profile entry:
run /PCedar/CirioThings/CirioThingsImpl
run /PCedar/CirioThings/RegisterSaveRestore.o
(b) or you can load them by executing the following in a CommandTool:
CirioLocal
(c) It would be nice if you could load them by commands in your pcr script, then your would would be degbuggable "early on". However, because the auxiliary packages are in a versioned directory, the following DOES NOT work:
LoadAndRun /pseudo/pcedar2.0/CirioThings/CirioThingsImpl
LoadAndRun /pseudo/pcedar2.0/CirioThings/RegisterSaveRestore.o
Obtaining a Remote Cirio debug tool
In PCedar, execute the following command:
CirioRemote machineName [portNumber]
Where machineName is the name of the debuggee (or "localhost" if one intends to debug a different PCedar invocation on the same machine). Where portNumber is the number of the port to which the Cirio nub on the debuggee is connected. This number need not be supplied if it is "4815", the default. [Note Well: Do not attempt to apply a remote Cirio debug tool to the same PCR world in which it is running.]
On a D-machine, execute the following commands:
pushv commands
qbo -p [CedarChest7.0]<top>Cirio.df
pop
CirioRemote machineName [portNumber]
Using a Remote Cirio Debug tool
Killing the World and Killing Cirio
The most important thing to know about the remote Cirio debug tool is how to kill both it and the remote world you are trying to debug. You can kill the tool by clicking on the Destroy button in its viewer banner. This will destroy the debug tool, but will leave the remote PCR world unchanged. That is, if the remote world was stopped by Cirio, then killing Cirio will leave the remote world stopped. (As described below, you can reattach a new debug tool to your PCR world if you so desire.)
To cleanly kill the remote PCR world you can click the guarded button KillRemoteWorld. This will invoke the equivalent of PCedarCleanUp (without asking any questions).
Stopping/Starting the World
When the Cirio debug tool comes up, it has not yet done anything to the remote PCR world. You must click the StopRemoteWorld button to use Cirio's other features. This button is a toggle button the will either stop the entire PCR world or start it running again, depending on what state Cirio thinks it is currently in (the current state is displayed in the top, middle part of the viewer). If Cirio thinks the world is already stopped then the button will read ResumeRemoteWorld instead of StopRemoteWorld.
Reconnecting to the World
As mentioned above, you can destroy your Cirio debug tool while leaving the remote PCR world untouched (and possibly stopped). To reattach a new debug tool, simply reinvoke Cirio (i.e. issue the CirioRemote command) as you did before. This will bring up a new debug tool viewer and you can now continue debugging. Note: you cannot have more than one existing debug tool attached to a particular PCR world. If a debug tool is already attached, then a second tool that attempts to attach will simply hang, waiting for a response from the PCR world's Cirio support code. The response will not be provided until the first debug tool is destroyed.
The new debug tool will not remember the state of the old, destroyed one. Thus, it will come up thinking that the remote world is running and that there are no breakpoints set. The StopRemoteWorld button is idempotent, so you can click on it anyway to tell Cirio that you wish to debug something. Note that any old breakpoints that were set by the old incarnation of the debug tool will be unknown to the new incarnation. I'm not sure what will happen if you try to set a breakpoint on top of an already existing one. Ask Peter Kessler.
Controlling Threads
When Cirio thinks the remote world is stopped, it will display a new line of buttons, which will include CallingDebugger, Ready, and All. If some thread has tried to call the debugger, either by faulting or by hitting a breakpoint, then clicking the CallingDebugger button will show a "button" line that tells the thread number (and some other stuff) and provides a set of buttons to invoke against that thread. Clicking on CallingDebugger when none has called the debugger does nothing. Clicking on the Ready button will display "button" lines for all threads that are either ready or running. Clicking on the All button will display "button" lines for all threads.
Each "button" line contains information about the thread together with thread-specific buttons The information is as follows, from left to right:
The thread index (followed by a colon)
The thread priority
The thread scheduling state (e.g., Run, CVWait, MWWait, etc).
A Debugger message (e.g., None and CallingDebugger).
The buttons displayed for a thread can be used to control it as well as obtain information about it. The most important control button to know about is the Prcd button, which proceeds a thread that has called the debugger. You must click this button to get past a breakpoint (in addition to clicking the ResumeRemoteWorld button to get the whole world running again).
Thread-Specific Button Commands
Each thread button line contains two information buttons: Quick and Detailed. Clicking on Quick will generate a summary of the call stack for the thread, showing each procedure name and the file from which the procedure was loaded. For example,
quick summary for thread with index 0
 debug message = None
 ←XR←Switch (from ThreadsSwitch.o)
 ←XR←Yield (from Threads2.o)
 ←XR←Idle (from Threads2.o)
 ←XR𡤏orkJumpProc (from Threads1.o)
 ←XR←Jumpee (from Threads1.o)
Clicking on Detailed provides access to each individual call frame of the thread's state. A new row of buttons is displayed and information is printed about the top-most call frame on the thread's call stack (designated frame 0).
SetBreak etc
Whenever Cirio believes that the target world is stopped, Cirio displays a row of buttons including SetBreak. The buttons in this row behave exactly as do the corresponding buttons in a same-world Cirio tool.
Thread examination buttons
After clicking Detailed for some thread, Cirio displays a row of buttons including WalkStack. This is an abreviated set of buttons corresponding to those described for a same-world Cirio tool as "Second row of buttons in the upper window". From left to right we have:
frame: t.n
This is not a button, but rather a status field showing the index of the thread under examination together with the index of the current frame.
WalkStack
(Behaves exactly as for a same-world Cirio tool.)
ShowFrame
(Behaves exactly as for a same-world Cirio tool.)
SourcePosition
(Behaves exactly as for a same-world Cirio tool.)
Typescript window
(Behaves exactly as for a same-world Cirio tool.)