Skip to content

Commit 4975d5a

Browse files
committed
Fix some typos about MemoryMode
1 parent 3f80071 commit 4975d5a

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

common/unsafe/src/main/java/org/apache/spark/unsafe/array/LongArray.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
/**
2424
* An array of long values. Compared with native JVM arrays, this:
2525
* <ul>
26-
* <li>supports using both in-heap and off-heap memory</li>
26+
* <li>supports using both on-heap and off-heap memory</li>
2727
* <li>has no bound checking, and thus can crash the JVM process when assert is turned off</li>
2828
* </ul>
2929
*/

common/unsafe/src/main/java/org/apache/spark/unsafe/memory/MemoryLocation.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
/**
2323
* A memory location. Tracked either by a memory address (with off-heap allocation),
24-
* or by an offset from a JVM object (in-heap allocation).
24+
* or by an offset from a JVM object (on-heap allocation).
2525
*/
2626
public class MemoryLocation {
2727

core/src/main/java/org/apache/spark/memory/TaskMemoryManager.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,9 @@ public class TaskMemoryManager {
8585
/**
8686
* Similar to an operating system's page table, this array maps page numbers into base object
8787
* pointers, allowing us to translate between the hashtable's internal 64-bit address
88-
* representation and the baseObject+offset representation which we use to support both in- and
88+
* representation and the baseObject+offset representation which we use to support both on- and
8989
* off-heap addresses. When using an off-heap allocator, every entry in this map will be `null`.
90-
* When using an in-heap allocator, the entries in this map will point to pages' base objects.
90+
* When using an on-heap allocator, the entries in this map will point to pages' base objects.
9191
* Entries are added to this map as new data pages are allocated.
9292
*/
9393
private final MemoryBlock[] pageTable = new MemoryBlock[PAGE_TABLE_SIZE];
@@ -102,7 +102,7 @@ public class TaskMemoryManager {
102102
private final long taskAttemptId;
103103

104104
/**
105-
* Tracks whether we're in-heap or off-heap. For off-heap, we short-circuit most of these methods
105+
* Tracks whether we're on-heap or off-heap. For off-heap, we short-circuit most of these methods
106106
* without doing any masking or lookups. Since this branching should be well-predicted by the JIT,
107107
* this extra layer of indirection / abstraction hopefully shouldn't be too expensive.
108108
*/

0 commit comments

Comments
 (0)