Computation and Storage of Object Identity Hash Values
Abstract
Techniques for computing and storing object identity hash values are disclosed. In some embodiments, a runtime system generates a value, such as a nonce, that is unique to a particular allocation region within memory. The runtime system may mix the value with one or more seed values that are associated with one or more respective objects stored in the allocation region. The runtime system may obtain object identifiers for the respective objects by applying a hash function to the result of mixing the seed value with at least the value associated with the allocation region. Conditioning operations may also be applied before, during or after the mixing operations to make the values appear more random. The nonce value may be changed from time to time, such as when memory is recycled in the allocation region, to reduce the risk of hash collisions.
Claims
exact text as granted — not AI-modifiedWhat is claimed is:
1 . One or more non-transitory computer-readable media storing instructions which,
when executed by one or more processors, cause: generating a first value that is unique to a particular session of a runtime environment; generating a data object having a second value within the runtime environment; generating a structural hash for the data object as a function of at least the first value and the second value; and storing a mapping between the structural hash and the second value.
2 . The media of claim 1 , wherein the first value is a nonce generated when the particular session is initiated.
3 . The media of claim 2 , wherein the nonce is changed when a new session with the runtime environment is initiated.
4 . The media of claim 1 , wherein generating the structural hash comprises generating an aggregate value by mixing one or more additional values with the first value and the second value; and applying a hash function to the aggregate value.
5 . The media of claim 4 , wherein the one or more additional values includes at least one value extracted from an immutable field of the data object and at least one value derived from a source external to the data object.
6 . The media of claim 1 , wherein generating the structural hash comprises:
generating a hash code by applying a hash function to a particular value that is derived from at least the second value; and mixing one or more salt values with the hash code.
7 . The media of claim 1 , wherein the second value is a first string value, the instructions further causing: comparing the structural hash to another structural hash derived from a second string value included in a second data object; determining, based on said comparing, whether the first string value matches the second string value.
8 . A method comprising:
generating a first value that is unique to a particular session of a runtime environment; generating a data object having a second value within the runtime environment; generating a structural hash for the data object as a function of at least the first value and the second value; and storing a mapping between the structural hash and the second value.
9 . The method of claim 8 , wherein the first value is a nonce generated when the particular session is initiated.
10 . The method of claim 9 , wherein the nonce is changed when a new session with the runtime environment is initiated.
11 . The method of claim 8 , wherein generating the structural hash comprises generating an aggregate value by mixing one or more additional values with the first value and the second value; and applying a hash function to the aggregate value.
12 . The method of claim 11 , wherein the one or more additional values includes at least one value extracted from an immutable field of the data object and at least one value derived from a source external to the data object.
13 . The method of claim 8 , wherein generating the structural hash comprises:
generating a hash code by applying a hash function to a particular value that is derived from at least the second value; and mixing one or more salt values with the hash code.
14 . The method of claim 8 , wherein the second value is a first string value, the method further comprising: comparing the structural hash to another structural hash derived from a second string value included in a second data object; determining, based on said comparing, whether the first string value matches the second string value.
15 . A system comprising:
one or more hardware processors; one or more non-transitory computer-readable media storing instructions which,
when executed by the one or more hardware processors, cause the system to perform operations comprising:
generating a first value that is unique to a particular session of a runtime environment;
generating a data object having a second value within the runtime environment;
generating a structural hash for the data object as a function of at least the first value and the second value; and
storing a mapping between the structural hash and the second value.
16 . The system of claim 15 , wherein the first value is a nonce generated when the particular session is initiated.
17 . The system of claim 16 , wherein the nonce is changed when a new session with the runtime environment is initiated.
18 . The system of claim 15 , wherein generating the structural hash comprises generating an aggregate value by mixing one or more additional values with the first value and the second value; and applying a hash function to the aggregate value.
19 . The system of claim 15 , wherein generating the structural hash comprises:
generating a hash code by applying a hash function to a particular value that is derived from at least the second value; and mixing one or more salt values with the hash code.
20 . The system of claim 15 , wherein the second value is a first string value, the instructions further causing the system to perform operations comprising:
comparing the structural hash to another structural hash derived from a second string value included in a second data object; determining, based on said comparing, whether the first string value matches the second string value.Join the waitlist — get patent alerts
Track US2023367638A1 — get alerts on status changes and closely related new filings.
We store only your email — no account needed. See our privacy policy.