diff --git a/Cargo.toml b/Cargo.toml index f8fdf5a300..525247fb50 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -189,7 +189,8 @@ no_mmap_annotation = [] # However, in rare cases, a binding may want to directly access and manipulate VO bit. For example, a binding cannot cooperate # with MMTk to identify each object for setting the VO bit. This is usually due to the limitation of the VM. # In such cases, a binding may use this feature and manipulate the VO bit to their needs. The binding's manipulation on VO bit -# may violate MMTk's semantics, and may result in undefined behaviors for VO bit related APIs. +# may violate MMTk's semantics, and may result in undefined behaviors for VO bit related APIs. This feature should +# only be used if you understand how VO bit works internally. Use at your own risk. vo_bit_access = [] # Do not modify the following line - ci-common.sh matches it diff --git a/src/util/metadata/side_metadata/constants.rs b/src/util/metadata/side_metadata/constants.rs index 6a8bbdcca5..f04c94d9d1 100644 --- a/src/util/metadata/side_metadata/constants.rs +++ b/src/util/metadata/side_metadata/constants.rs @@ -30,6 +30,7 @@ pub(crate) const GLOBAL_SIDE_METADATA_BASE_OFFSET: SideMetadataOffset = SideMetadataOffset::addr(GLOBAL_SIDE_METADATA_BASE_ADDRESS); /// Base address of VO bit, public to VM bindings which may need to use this. +#[cfg(target_pointer_width = "64")] pub const VO_BIT_SIDE_METADATA_ADDR: Address = crate::util::metadata::vo_bit::VO_BIT_SIDE_METADATA_ADDR; diff --git a/src/util/metadata/vo_bit/mod.rs b/src/util/metadata/vo_bit/mod.rs index 6ab720b817..80be56ea26 100644 --- a/src/util/metadata/vo_bit/mod.rs +++ b/src/util/metadata/vo_bit/mod.rs @@ -58,6 +58,7 @@ use crate::vm::VMBinding; pub(crate) const VO_BIT_SIDE_METADATA_SPEC: SideMetadataSpec = crate::util::metadata::side_metadata::spec_defs::VO_BIT; +#[cfg(target_pointer_width = "64")] pub const VO_BIT_SIDE_METADATA_ADDR: Address = VO_BIT_SIDE_METADATA_SPEC.get_absolute_offset(); /// Atomically set the VO bit for an object.