Skip to content

Commit

Permalink
clarify 'memory address'
Browse files Browse the repository at this point in the history
  • Loading branch information
RalfJung committed Sep 28, 2023
1 parent ac65bc2 commit e8e5765
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion reference/src/glossary.md
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,12 @@ In this document, *layout* and [*representation*][representation relation] are n
### Memory Address
[memory address]: #memory-address

A *memory address* is an integer value that identifies where in the physical machine memory some data is stored.
A *memory address* is an integer value that identifies where in the process' memory some data is stored.
This will typically be a virtual address, if the Rust process runs as a regular user-space program.
It can also be a physical address for bare-level / kernel code. Rust doesn't really care either way, the point is:
it's an address as understood by the CPU, it's what the load/store instructions need to identify where in memory to perform the load/store.

Note that a pointer in Rust is *not* just a memory address.
A pointer value consists of a memory address and [provenance][pointer-provenance].

### Niche
Expand Down

0 comments on commit e8e5765

Please sign in to comment.