MCPcopy Create free account
hub / github.com/IntegralPilot/rustc_codegen_jvm / rewrite_fixed_load

Function rewrite_fixed_load

src/lower2/optimise2.rs:1285–1297  ·  view source on GitHub ↗
(
    kind: LocalKind,
    old_index: u16,
    slot_map: &BTreeMap<u16, u16>,
    touch: &mut F,
)

Source from the content-addressed store, hash-verified

1283 instructions[index + 1] = make_store(store_kind, stored.index);
1284 // The store moves one instruction later, while the duplicate takes
1285 // the place of the original load. Keep source scopes and locations
1286 // attached to those semantic operations, not their old positions.
1287 metadata.swap(index, index + 1);
1288 }
1289
1290 (instructions, metadata)
1291}
1292
1293fn fold_iinc_patterns(
1294 mut instructions: Vec<Instruction>,
1295 source_locations: Vec<BytecodeMetadata>,
1296 exception_table: &mut Vec<ExceptionTableEntry>,
1297) -> jvm::Result<LocatedInstructions> {
1298 if instructions.len() < 4
1299 || !instructions
1300 .windows(4)

Callers 1

Calls 2

local_widthFunction · 0.85
make_loadFunction · 0.85

Tested by

no test coverage detected