Runtime tags aren't necessary

Research output: Contribution to journalArticle

28 Scopus citations

Abstract

Many modern programming environments use tag bits at runtime to distinguish objects of different types. This is particularly common in systems with garbage collection, since the garbage collector must be able to distinguish pointers from non-pointers, and to learn the length of records pointed to. The use of tag bits leads to inefficiency. In addition to the obvious space overhead (tag bits and record descriptors occupy memory space), there is a time overhead: tag bits must be stripped off of data before arithmetic operations are performed, and re-attached to the data when it is stored into memory. This takes either extra instructions at runtime, or special tag-handling hardware, or both. This paper shows how the use of tag bits, record descriptor words, explicit type parameters, and the like can be avoided in languages (like ML) with static polymorphic typechecking. Though a form of tag will still be required for user-defined variant records, all other type information can be encoded once-in the program-rather than replicated many times in the data. This can lead to savings both in space and time.

Original languageEnglish (US)
Pages (from-to)153-162
Number of pages10
JournalLisp and Symbolic Computation
Volume2
Issue number2
DOIs
StatePublished - Jun 1 1989

All Science Journal Classification (ASJC) codes

  • Computer Science(all)

Fingerprint Dive into the research topics of 'Runtime tags aren't necessary'. Together they form a unique fingerprint.

  • Cite this