Add a "colocated" flag to symbol references. (#298)
This adds a "colocated" flag to function and symbolic global variables which indicates that they are defined along with the current function, so they can use PC-relative addressing. This also changes the function decl syntax; the name now always precedes the signature, and the "function" keyword is no longer included.
This commit is contained in:
@@ -182,7 +182,11 @@ impl<'dummy_environment> FuncEnvironment for DummyFuncEnvironment<'dummy_environ
|
||||
// And maybe attempt some signature de-duplication.
|
||||
let signature = func.import_signature(self.vmctx_sig(sigidx));
|
||||
let name = get_func_name(index);
|
||||
func.import_function(ir::ExtFuncData { name, signature })
|
||||
func.import_function(ir::ExtFuncData {
|
||||
name,
|
||||
signature,
|
||||
colocated: false,
|
||||
})
|
||||
}
|
||||
|
||||
fn translate_call_indirect(
|
||||
|
||||
Reference in New Issue
Block a user