MCPcopy Create free account
hub / github.com/Dadoum/android-loader / GnuHashTable

Class GnuHashTable

src/android_library.rs:31–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29
30#[repr(C)]
31pub(crate) struct GnuHashTable<'a> {
32 /// Index of the first symbol in the `.dynsym` table which is accessible with
33 /// the hash table
34 symindex: u32,
35 /// Shift count used in the bloom filter
36 shift2: u32,
37 /// 2 bit bloom filter on `chains`
38 // Either 32 or 64-bit depending on the class of object
39 bloom_filter: &'a [usize],
40 /// GNU hash table bucket array; indexes start at 0. This array holds symbol
41 /// table indexes and contains the index of hashes in `chains`
42 buckets: &'a [u32],
43 /// Hash values; indexes start at 0. This array holds symbol table indexes.
44 chains: &'a [u32], // => chains[dynsyms.len() - symindex]
45 dynsyms: &'a [DynEntry],
46}
47
48impl<'a> GnuHashTable<'a> {
49 unsafe fn new(hashtab: &'a [u8], dynsyms: &'a [DynEntry]) -> GnuHashTable<'a> {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected