Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename AsyncStateMachineBox #11693

Closed
benaadams opened this issue Dec 20, 2018 · 5 comments
Closed

Rename AsyncStateMachineBox #11693

benaadams opened this issue Dec 20, 2018 · 5 comments

Comments

@benaadams
Copy link
Member

Mostly a preference change for debugging/profiling/examining dumps.

AsyncStateMachineBox is called AsyncTaskMethodBuilder+AsyncStateMachineBox<...> in profiles, dumps etc

image

Would an acceptable change be to rename this to StateMachine so it becomes AsyncTaskMethodBuilder+StateMachine<...>?

/cc @stephentoub @davidfowl

@benaadams
Copy link
Member Author

Would look more like this:

image

@benaadams
Copy link
Member Author

benaadams commented Dec 20, 2018

StateMachineBox would work also; if differentiating that its different heap type (and that there is a non-boxed version) is important?

@stephentoub
Copy link
Member

stephentoub commented Dec 20, 2018

Without the Box suffix I think it's strange, as it's not actually the state machine from the compiler, but rather has the state machine as one field. So the only difference at that point is whether it has an Async prefix. And while dropping the prefix may have been a better name choice initially, I don't think that's a worthwhile change now, e.g. DumpAsync will now have to compare more possible names (or at least do more complicated comparisons), devs in a debugger will have to know about a difference between 2.1/2.2 and 3.0, etc. Just doesn't seem worth it to me.

@davidfowl
Copy link
Member

I agree, I'm not sure it adds much value now since we're essentially just removing the async prefix...

@benaadams
Copy link
Member Author

k

@msftgits msftgits transferred this issue from dotnet/coreclr Jan 31, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 14, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants