# Stabs

> Mediated Wiki article. Canonical URL: https://mediated.wiki/source/Stabs
> Markdown URL: https://mediated.wiki/source/Stabs.md
> Source: https://en.wikipedia.org/wiki/Stabs
> Source revision: 1310798721
> License: Creative Commons Attribution-ShareAlike 4.0 International (https://creativecommons.org/licenses/by-sa/4.0/)

{{Short description|Debugging data format}}
{{Other uses|Stab (disambiguation)}}
{{lowercase}}
'''stabs''' (sometimes written '''STABS''') is a [debugging data format](/source/debugging_data_format) for storing information about computer programs for use by symbolic and source-level [debugger](/source/debugger)s. The information is stored in [symbol table](/source/symbol_table) [strings](/source/string_(computer_science)) ("stabs").

==History==
[Cygnus Support](/source/Cygnus_Support) attributes the invention of stabs to {{ill|Peter Kessler|qid=Q47482023}} for the Berkeley Pascal pdx debugger,<ref>{{cite web |last1=Menapace |first1=Julia |last2=Kingdon |first2=Jim |last3=MacKenzie |first3=David |date=1993 |title=Overview of Stabs |url=https://sourceware.org/gdb/current/onlinedocs/stabs/Overview.html |work=The "stabs" Debug Format |publisher=[Cygnus Support](/source/Cygnus_Support) |citeseerx=10.1.1.38.1857 |accessdate=2018-01-21}}</ref> however, he claims otherwise, stating stabs came with [adb](/source/Advanced_Debugger) and sdb but could predate those.<ref>{{cite mailing list |url=https://mail.openjdk.java.net/pipermail/build-dev/2014-November/013726.html |title=RFR: 8065656: Use DWARF debug symbols for Solaris |date=2014-11-21 |df=mdy |accessdate=2018-01-21 |mailing-list=build-dev |last=Kessler |first=Peter B.}}</ref> {{ill|Mark Linton|qid=Q47486013}}, who created pdx for his 1981 master's thesis and later developed it into [dbx](/source/dbx_(debugger)), states his doctoral adviser Michael L. Powell "contributed to the stabstrings design, especially
to support [Modula-2](/source/Modula-2)".<ref>{{cite conference |last1=Linton |first1=Mark A. |date=1990 |title=The Evolution of Dbx |url=https://pdfs.semanticscholar.org/95dd/42a7390e62f46e2779023ae77191e461a436.pdf |archive-url=https://web.archive.org/web/20180123131612/https://pdfs.semanticscholar.org/95dd/42a7390e62f46e2779023ae77191e461a436.pdf |url-status=dead |archive-date=2018-01-23 |book-title=USENIX Summer |pages=211–220 |conference=USENIX Summer 1990 Technical Conference |citeseerx=10.1.1.38.5985 |s2cid=15074926 |accessdate=2018-01-21}}</ref>

When stabs was created in the 1980s, the dominant [object file](/source/object_file) format was [a.out](/source/a.out), which, unlike more recent formats such as [Executable and Linkable Format](/source/Executable_and_Linkable_Format) (ELF), makes no provision for storing debugging information. Stabs works around this problem by encoding the information using special entries in the symbol table.

At one stage stabs was widely used on [Unix](/source/Unix) systems, but the newer [DWARF](/source/DWARF) format has largely supplanted it.

==References==
{{reflist}}

==External links==
*[https://sourceware.org/gdb/current/onlinedocs/stabs.html STABS] [GNU Debugger](/source/GNU_Debugger) project documentation

Category:Debugging data formats

---
Adapted from the Wikipedia article [Stabs](https://en.wikipedia.org/wiki/Stabs) by Wikipedia contributors ([contributor history](https://en.wikipedia.org/wiki/Stabs?action=history)). Available under [Creative Commons Attribution-ShareAlike 4.0 International](https://creativecommons.org/licenses/by-sa/4.0/). Changes may have been made.
