@@ -9,7 +9,7 @@ cleared, and associated clean-up operations will be executed. Some VMs also sup
9
9
weak data structures, such as weak hash tables, where keys, values, or both, can be weak references.
10
10
11
11
The concrete semantics of finalizer and weak reference varies from VM to VM, but MMTk provides a
12
- low-level API that allows the VM bindings to implement their flavours of finalizer and weak
12
+ low-level API that allows the VM bindings to implement their flavors of finalizer and weak
13
13
references on top of it.
14
14
15
15
** A note for Java programmers** : In Java, the term "weak reference" often refers to instances of
@@ -49,7 +49,7 @@ operations, including (but not limited to)
49
49
copying GC.
50
50
- ** Clear the field** : It can clear the field if the referent is unreachable.
51
51
52
- Using those primitive operations, the VM binding can support different flavours of finalizers and/or
52
+ Using those primitive operations, the VM binding can support different flavors of finalizers and/or
53
53
weak references. We will discuss common use cases in the following sections.
54
54
55
55
## Supporting finalizers
@@ -163,7 +163,7 @@ for object in objects {
163
163
```
164
164
165
165
Keep in mind that ** tracer_context implements the ` Clone ` trait** . As introduced in the * When to
166
- run finalizers* section, the VM binding can use work packets to parallelise finalizer processing.
166
+ run finalizers* section, the VM binding can use work packets to parallelize finalizer processing.
167
167
If finalizable objects can be resurrected, the VM binding can clone the ` trace_context ` and give
168
168
each work packet a clone of ` tracer_context ` .
169
169
@@ -354,7 +354,7 @@ a minor GC,
354
354
finalizable objects must be old and will not be considered dead.
355
355
- The VM binding only needs to visit ** weak reference slots written since the last GC** . Other
356
356
slots must be pointing to old objects (if not ` null ` ). For weak hash tables, if existing
357
- entries are immutable, it is sufficient to only visit newly added entires .
357
+ entries are immutable, it is sufficient to only visit newly added entries .
358
358
359
359
Implementation-wise, the VM binding can split the lists or hash tables into two parts: one for old
360
360
entries and another for young entries.
0 commit comments