MCPcopy Create free account
hub / github.com/LPC4/Full-Stack / pcrel_offsets

Function pcrel_offsets

crates/asm-to-binary/src/assembler/encode.rs:338–340  ·  view source on GitHub ↗

Compute PC-relative (hi20, lo12) for a target address relative to `current_addr`.

(target_addr: u64, current_addr: u64)

Source from the content-addressed store, hash-verified

336
337fn encode_jal(
338 rd: u8,
339 target: &str,
340 site_local: u64,
341 section_name: &str,
342 symbols: &super::symbol_table::SymbolTable,
343) -> Result<u32, AssemblerError> {

Callers 3

encode_callFunction · 0.85
encode_tailFunction · 0.85
encode_laFunction · 0.85

Calls 1

pcrel_splitFunction · 0.70

Tested by

no test coverage detected