Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@jaykrell
Copy link
Contributor

[Tailcall] Cleanup is_supported_tail_call, put more logic in it, and be sure not to tailcall_mem_base if not supported (i.e. virtual_ not just CALLVIRT)

@jaykrell jaykrell merged commit a856f8d into mono:master Mar 14, 2018
g_assertf (call_opcode == CEE_CALL || call_opcode == CEE_CALLVIRT || call_opcode == CEE_CALLI, "%s (%d)", mono_opcode_name (call_opcode), (int)call_opcode);

if ( (fsig->hasthis && cmethod->klass->valuetype) // This might point to the current method's stack. Emit range check?
|| (cmethod->flags & METHOD_ATTRIBUTE_PINVOKE_IMPL)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a much harder to read than the previous code, and it's shuffling around the code for no benefits.

picenka21 pushed a commit to picenka21/runtime that referenced this pull request Feb 18, 2022
…be sure not to tailcall_mem_base if not supported (i.e. virtual_ not just CALLVIRT) (mono/mono#7608)

* [Tailcall] Cleanup is_supported_tail_call to use language-base short circuit.

* [Tailcall] Move more of the logic into is_supported_tail_call.

* [Tailcall] Be sure not to use TAILCALL_MEM_BASE if not supported.
i.e. not if virtual_, besides CALLVIRT -- they are not quite the same.


Commit migrated from mono/mono@a856f8d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants