Cleanup and feature gate instruction processing (#12359)

This commit is contained in:
sakridge
2020-09-20 10:58:12 -07:00
committed by GitHub
parent 65b247a922
commit 22d8b3c3f8
5 changed files with 43 additions and 19 deletions

View File

@ -47,7 +47,7 @@ fn bench_manual_instruction_deserialize(b: &mut Bencher) {
let serialized = message.serialize_instructions();
b.iter(|| {
for i in 0..instructions.len() {
test::black_box(instructions::get_instruction(i, &serialized).unwrap());
test::black_box(instructions::load_instruction_at(i, &serialized).unwrap());
}
});
}
@ -58,6 +58,6 @@ fn bench_manual_instruction_deserialize_single(b: &mut Bencher) {
let message = Message::new(&instructions, None);
let serialized = message.serialize_instructions();
b.iter(|| {
test::black_box(instructions::get_instruction(3, &serialized).unwrap());
test::black_box(instructions::load_instruction_at(3, &serialized).unwrap());
});
}