MacsBug is a low-level (
assembly language
In computing, assembly language (alternatively assembler language or symbolic machine code), often referred to simply as assembly and commonly abbreviated as ASM or asm, is any low-level programming language with a very strong correspondence bet ...
/machine-level)
debugger
A debugger is a computer program used to test and debug other programs (the "target" programs). Common features of debuggers include the ability to run or halt the target program using breakpoints, step through code line by line, and display ...
for the
classic Mac OS
Mac OS (originally System Software; retronym: Classic Mac OS) is the series of operating systems developed for the Mac (computer), Macintosh family of personal computers by Apple Computer, Inc. from 1984 to 2001, starting with System 1 and end ...
operating system. MacsBug is an acronym for ''Motorola Advanced Computer Systems Debugger'', as opposed to ''Macintosh debugger'' (The Motorola 68000 Microprocessor is imprinted with the MACSS acronym
). The original version was developed by Motorola as a general debugger for its
68000
The Motorola 68000 (sometimes shortened to Motorola 68k or m68k and usually pronounced "sixty-eight-thousand") is a 16/32-bit complex instruction set computer (CISC) microprocessor, introduced in 1979 by Motorola Semiconductor Products Sector ...
systems.
[MACSbug 68000 Debugger User's Manual]
Catalog entry, Computer History Museum
The Computer History Museum (CHM) is a computer museum in Mountain View, California. The museum presents stories and artifacts of Silicon Valley and the Information Age, and explores the Digital Revolution, computing revolution and its impact ...
— it was ported to the Mac as a programmer's tool early in the project's development.
MacsBug is invoked by hitting the Macintosh's "
Programmer's Key" or, as it became later known, the "Interrupt Key" or by pressing "Command-Power". MacsBug offers many commands for
disassembling, searching, and viewing data as well as control over
processor register
A processor register is a quickly accessible location available to a computer's processor. Registers usually consist of a small amount of fast storage, although some registers have specific hardware functions, and may be read-only or write-onl ...
s. MacsBug is not installed by default with Mac OS, although every Macintosh since the Macintosh Plus includes a debugger in ROM known as MicroBug.
Users who stumble into MacsBug by accident need only to enter G and press return to escape from MacsBug; however, MacsBug is not installed by default, requiring a system extension, so a typical user environment does not include it. However, it was occasionally installed by end users to provide very basic error recovery. As the classic Mac OS lacked
memory protection
Memory protection is a way to control memory access rights on a computer, and is a part of most modern instruction set architectures and operating systems. The main purpose of memory protection is to prevent a process from accessing memory that h ...
, "hard crashes" where an application crash simply froze the entire system weren't uncommon. With MacsBug installed, instead of an unresponsive system, the user would be dumped into MacsBug, where they could type ES to Exit to Shell (force quit the crashed application and return to the
Finder) or RB for ReBoot, which restarted the system.
Such recovery efforts were often not successful, with the only alternative a
hard reset
In a computer or data transmission system, a reset clears any pending errors or events and brings a system to normal condition or an initial state, usually in a controlled manner. It is usually done in response to an error condition when it is ...
.
In Mac OS versions 7.5 and later, the presence of MacsBug is indicated at startup; it is present if the user sees the text ''Debugger installed'' (although, occasionally, this may indicate the presence of another piece of software loaded into the area of memory reserved for the debugger, instead).
MacsBug was originally for the Motorola 68000 series of processors only. When Apple introduced the
Power Macintosh
The Power Macintosh, later Power Mac, is a family of personal computers designed, manufactured, and sold by Apple Inc., Apple Computer, Inc as the core of the Mac (computer), Macintosh brand from March 1994 until August 2006.
Described by ''Mac ...
in 1994, it was followed by an updated MacsBug that supported the
PowerPC
PowerPC (with the backronym Performance Optimization With Enhanced RISC – Performance Computing, sometimes abbreviated as PPC) is a reduced instruction set computer (RISC) instruction set architecture (ISA) created by the 1991 Apple Inc., App ...
instruction set and architecture.
The last version of MacsBug was 6.6.3, released September 14, 2000. This final version works with all of the machines released in the July–September timeframe of 2000, including the
Power Mac G4 (uni- and multi-processor),
Power Mac G4 Cube
The Power Mac G4 Cube is a Mac personal computer sold by Apple Computer, Inc. between July 2000 and 2001. The Cube was conceived as a miniaturized but powerful computer by Apple chief executive officer ( CEO) Steve Jobs and designed by Jony ...
, the
iMac
The iMac is a series of all-in-one computers from Apple Inc., sold as part of the company's Mac (computer), Mac family of computers. First introduced in 1998, it has remained a primary part of Apple's consumer desktop offerings since and evol ...
family (Ruby, Indigo, Sage, Graphite, and Snow), and the
iBook
iBook is a line of laptop computers designed, manufactured, and sold by Apple Computer from 1999 to 2006. The line targeted entry-level, consumer and education markets, with lower specifications and prices than the PowerBook, Apple's higher- ...
family (Indigo, Key Lime, and Graphite).
6.6.3 includes better support for debugging MP tasks, and fixes some serious bugs in the memory setting commands when used in
PCI
PCI may refer to:
Business and economics
* Payment card industry, businesses associated with debit, credit, and other payment cards
** Payment Card Industry Data Security Standard, a set of security requirements for credit card processors
* Prov ...
I/O space. It can also be used in
Classic
A classic is an outstanding example of a particular style; something of Masterpiece, lasting worth or with a timeless quality; of the first or Literary merit, highest quality, class, or rank – something that Exemplification, exemplifies its ...
when running under Mac OS X, where it is invoked by pressing "⌘-⏏" (or "⌘-F12" on systems without an Eject key).
Mac OS X allows programmers to use familiar MacsBug commands in
gdb. This gdb plugin is included with the OS X Developer Tools, located in the directory /usr/libexec/gdb/plugins/MacsBug/.
Third party alternatives to MacsBug included
ICOM Simulations
ICOM Simulations, Inc. (later known as Rabid Entertainment) was a software company based in Wheeling, Illinois. It is best known for creating the MacVenture series of adventure games including '' Shadowgate''.
Following the foundation in 1981 ...
' TMON which came with the
Darin Adler Extended User Area & Trap Discipline (allowing all documented Mac API parameters to be verified) and the fully symbolic
Jasik debugger, which was much more powerful, but harder to use due to the intricate and non-standard user interface.
Versions
* 1979 Motorola 68000 Design Module debugger
[
* January 25, 1982 - Adapted by Rich Page for Lisa & Mac.
* November 1, 1984 - Enhanced by Steve Capps.
* May 13, 1985 - Version IV+ by Ken Krugler.
* May, 1986 - Version 5.1 by Dan Allen.
* November 21, 1986 - Disassembler upgraded by Ira Reuben.
* June 15, 1987 - Version 5.4 by Dan Allen.
* March 31, 1988 - Version 5.6.1 by Dan Allen.
* June 29, 1988 - Version 6.0 by Michael Tibbott.
* April 20, 1989 - Version 6.1 by Michael Tibbott.
* September 14, 2000 - Version 6.6.3.
]
References
External links
Apple's MacsBug page
{{DEFAULTSORT:Macsbug
Apple Inc. software
Debuggers
Macintosh operating systems development
Discontinued development tools
Classic Mac OS programming tools