MCPcopy Create free account
hub / github.com/explodingcamera/tinywasm / next_non_nop

Function next_non_nop

crates/parser/src/optimize.rs:785–790  ·  view source on GitHub ↗
(instrs: &[Instruction], mut idx: usize)

Source from the content-addressed store, hash-verified

783}
784
785fn next_non_nop(instrs: &[Instruction], mut idx: usize) -> usize {
786 while idx < instrs.len() && matches!(instrs[idx], Instruction::Nop | Instruction::MergeBarrier) {
787 idx += 1;
788 }
789 idx
790}
791
792fn resolve_jump_target(instrs: &[Instruction], target: u32) -> u32 {
793 let mut idx = next_non_nop(instrs, target as usize);

Callers 3

rewriteFunction · 0.85
resolve_jump_targetFunction · 0.85

Calls 1

lenMethod · 0.45

Tested by

no test coverage detected