Cranelift: make all non-tail, non-indirect calls patchable, and rename patchable ABI to preserve_all.
#12160
+1,581
−639
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
As discussed in this week's Cranelift meeting, we've discovered a need to generalize the
patchable_callmechanism and correspondingpatchableABI slightly. In particular, we will need patchabletry_callcallsites as well in order to allow breakpoint handlers to throw exceptions (desirable functionality eventually) and have this work in the presence of inlining. Also, it's just a nice generalization to say that patchability is an orthogonal dimension to the call ABI and the other restrictions we initially imposed, and works as long as the basic requirement (no return values) is met.This also renames the
patchableABI topreserve_all, to make it clear that its purpose is actually orthogonal, and it can be used independently of patchable callsites. It also deletes thecoldABI, which never actually did anything and is misleading in the presence of an actual cold-ish (subzero temperature, actually) ABI likepreserve_all.