Skip to content

Conversation

@vinx13
Copy link
Member

@vinx13 vinx13 commented Sep 21, 2023

Copy link
Member

@junrushao junrushao left a comment

Choose a reason for hiding this comment

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

Thanks!

@tqchen
Copy link
Member

tqchen commented Sep 21, 2023

@vinx13 we might need to think about possible needs to remap the use site of the buffer, either in the pass, or in followups

@Lunderberg
Copy link
Contributor

How large is the performance benefit of StmtMutator::CopyOnWrite overall? Since we only construct new objects if there's a change, and all internal state is held by pointer, my initial guess would be that the performance impact would be minimal. If so, then we may want to avoid this entire category of bugs by disabling it altogether.

This would also minimize surprises for developers, as currently the StmtMutator::VisitStmt_ functions may mutate their argument, even though the arguments were provided through const Node* and contain no member variables that were defined as mutable.

@vinx13
Copy link
Member Author

vinx13 commented Sep 26, 2023

superseded by #15816

@vinx13 vinx13 closed this Sep 26, 2023
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.

4 participants