Clarify the meaning of the symbol_value instruction.
This commit is contained in:
@@ -502,15 +502,15 @@ global_value = Instruction(
|
||||
'global_value', r"""
|
||||
Compute the value of global GV.
|
||||
""",
|
||||
ins=GV, outs=addr)
|
||||
ins=GV, outs=a)
|
||||
|
||||
# A specialized form of global_value instructions that only handles
|
||||
# symbolic names.
|
||||
symbol_value = Instruction(
|
||||
'symbol_value', r"""
|
||||
Compute the value of global GV, which is a symbolic address.
|
||||
Compute the value of global GV, which is a symbolic value.
|
||||
""",
|
||||
ins=GV, outs=addr)
|
||||
ins=GV, outs=a)
|
||||
|
||||
#
|
||||
# WebAssembly bounds-checked heap accesses.
|
||||
|
||||
@@ -39,8 +39,13 @@ pub enum GlobalValueData {
|
||||
global_type: Type,
|
||||
},
|
||||
|
||||
/// Value is a symbolic address. Cranelift itself does not interpret this name;
|
||||
/// it's used by embedders to link with other data structures.
|
||||
/// Value is symbolic, meaning it's a name which will be resolved to an
|
||||
/// actual value later (eg. by linking). Cranelift itself does not interpret
|
||||
/// this name; it's used by embedders to link with other data structures.
|
||||
///
|
||||
/// For now, symbolic values always have pointer type, and represent
|
||||
/// addresses, however in the future they could be used to represent other
|
||||
/// things as well.
|
||||
Symbol {
|
||||
/// The symbolic name.
|
||||
name: ExternalName,
|
||||
|
||||
Reference in New Issue
Block a user