Results 11 -
12 of
12
Considerations for a Generic SAC Library
, 1995
"... Moving the SACLIB from C to C ++ poses the question which language features of C ++ a new library can take advantage of. We argue by considering an algebraic algorithm in detail that generic algebraic programming using the Standard Template Library for C ++ is an attractive way both from a ..."
Abstract
-
Cited by 2 (1 self)
- Add to MetaCart
Moving the SACLIB from C to C ++ poses the question which language features of C ++ a new library can take advantage of. We argue by considering an algebraic algorithm in detail that generic algebraic programming using the Standard Template Library for C ++ is an attractive way both from a computer science and algebra point of view. Contents 1 Introduction 3 2 Some programming language terminology 4 2.1 Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 2.2 Application to C ++ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 3 A strongly typed SAC library 5 3.1 Types in the SACLIB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 3.2 A monomorphic SAC library . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 4 A polymorphic SAC library 8 4.1 The characteristic-0 case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 4.2 The prime characteristic case . . . . . . . . . . . . . . . . . . . . . . ...
Comparing Two Garbage Collectors for C++
, 1992
"... Our research is concerned with compiler-independent, tag-free garbage collection for the C++ programming language. This paper presents a mark-and-sweep collector, and explains how it ameliorates shortcomings of a previous copy collector. The new collector, like the old, uses C++'s facilities for cre ..."
Abstract
-
Cited by 1 (0 self)
- Add to MetaCart
Our research is concerned with compiler-independent, tag-free garbage collection for the C++ programming language. This paper presents a mark-and-sweep collector, and explains how it ameliorates shortcomings of a previous copy collector. The new collector, like the old, uses C++'s facilities for creating abstract data types to define a tracked reference type, called roots, at the level of the application program. A programmer wishing to utilize the garbage collection service uses these roots in place of normal, raw pointers. We present a detailed study of the cost of using roots, as compared to both normal pointers and reference counted pointers, in terms of instruction counts. We examine the efficiency of a small C++ application using roots, reference counting, manual reclamation, and conservative collection. Coding the application to use garbage collection, and analyzing the resulting efficiency, helped us identify a number of memory leaks and inefficiencies in the original, m...

