Append link and sret arguments in legalize_signature.
These special-purpose arguments and return values are only relevant for the function being compiled, so add a `current` flag to legalize_signature(). - Add the necessary argument values to the entry block to represent the special-purpose arguments. - Propagate the link and sret arguments to return instructions if the legalized signature asks for it.
This commit is contained in:
@@ -78,9 +78,9 @@ impl TargetIsa for Isa {
|
||||
})
|
||||
}
|
||||
|
||||
fn legalize_signature(&self, sig: &mut Signature) {
|
||||
fn legalize_signature(&self, sig: &mut Signature, current: bool) {
|
||||
// We can pass in `self.isa_flags` too, if we need it.
|
||||
abi::legalize_signature(sig, &self.shared_flags)
|
||||
abi::legalize_signature(sig, &self.shared_flags, current)
|
||||
}
|
||||
|
||||
fn emit_inst(&self, func: &Function, inst: Inst, sink: &mut CodeSink) {
|
||||
|
||||
Reference in New Issue
Block a user