Cranelift backend update to fork of clif version 0.43.1

This commit is contained in:
Brandon Fish
2019-09-21 13:06:54 -05:00
parent 7d9e6d8caa
commit f48d6f6690
13 changed files with 116 additions and 84 deletions

View File

@ -1117,7 +1117,18 @@ impl FunctionCodeGenerator<CodegenError> for CraneliftFunctionCodeGenerator {
fn feed_local(&mut self, ty: WpType, n: usize) -> Result<(), CodegenError> {
let mut next_local = self.next_local;
cranelift_wasm::declare_locals(&mut self.builder(), n as u32, ty, &mut next_local)?;
let mut builder = FunctionBuilder::new(
&mut self.func,
&mut self.func_translator.func_ctx,
&mut self.position,
);
cranelift_wasm::declare_locals(
&mut builder,
n as u32,
ty,
&mut next_local,
&mut self.func_env,
)?;
self.next_local = next_local;
Ok(())
}