@@ -5,28 +5,14 @@ libgc is a garbage collector for Rust. It works by providing a garbage-collected
5
5
6
6
# Structure
7
7
8
- There are three repositories which make up the gc infrastructure:
9
- - ** libgc** the main library which provides the ` Gc<T> ` smart pointer and its
8
+ There are two repositories which make up the gc infrastructure:
9
+
10
+ * ** libgc** the main library which provides the ` Gc<T> ` smart pointer and its
10
11
API.
11
- - ** libgc_internal** contains the gc allocation and collector logic. This is
12
- collector specific, and can be conditionally compiled to support different
13
- implementations. At the moment, it only supports a single collector
14
- implementation: the Boehm-Demers-Weiser GC. Users should never interact
15
- directly with this crate. Instead, any relevant APIs are re-exported
16
- through libgc.
17
- - ** rustgc** a fork of rustc with GC-aware optimisations. This can be used to
12
+ * ** rustgc** a fork of rustc with GC-aware optimisations. This can be used to
18
13
compile user programs which use ` libgc ` , giving them better GC
19
14
performance. Use of rustgc is not mandated, but it enables further
20
15
optimisations for programs which use ` libgc ` .
21
16
22
17
This seperation between libgc and rustgc exists so that a stripped-down form of
23
- garbage collection can be used without compiler support. The further split
24
- between libgc and libgc_core exists to make linkage easier when the rustgc
25
- compiler is used.
26
-
27
- rustgc needs access to the GC's ` Allocator ` implementation. This exists in the
28
- libgc_internal crate so that it can be linked to the target binary either as
29
- part of libgc, or as part of the rust standard library (if compiled with
30
- rustgc). libgc contains code which would not compile if it was packaged as part
31
- of rustgc. To prevent duplication, the libgc_interal crate will link correctly
32
- as either a standard cargo crate, or as part of the rust core library.
18
+ garbage collection can be used without compiler support.
0 commit comments