Pull in latest rBPF that includes Rust dependent changes (#2929)

This commit is contained in:
Jack May
2019-02-25 12:42:48 -08:00
committed by GitHub
parent 0b37f530ae
commit 2be7896157
4 changed files with 17 additions and 7 deletions

View File

@@ -80,7 +80,7 @@ pub fn helper_sol_log_u64(arg1: u64, arg2: u64, arg3: u64, arg4: u64, arg5: u64)
pub fn create_vm(prog: &[u8]) -> Result<EbpfVmRaw, Error> {
let mut vm = EbpfVmRaw::new(None)?;
vm.set_verifier(bpf_verifier::check)?;
vm.set_max_instruction_count(36000)?; // 36000 is a wag, need to tune
vm.set_max_instruction_count(36000)?; // TODO 36000 is a wag, need to tune
vm.set_elf(&prog)?;
vm.register_helper_ex("sol_log", Some(helper_sol_log_verify), helper_sol_log)?;
vm.register_helper_ex("sol_log_", Some(helper_sol_log_verify), helper_sol_log)?;