Skip to content

Conversation

@Akeit0
Copy link
Collaborator

@Akeit0 Akeit0 commented Oct 19, 2024

This PR is a large optimization.
NBodyBenchmark
.NET8 12ms -> 6.2ms
IL2CPP 81ms ->15ms

@Akeit0
Copy link
Collaborator Author

Akeit0 commented Oct 19, 2024

All changes are internal, so I think nothing is broken.

Copy link
Owner

@nuskey8 nuskey8 left a comment

Choose a reason for hiding this comment

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

I have made some comments about the implementation that I am concerned about. I would appreciate it if you could check them.

@Akeit0
Copy link
Collaborator Author

Akeit0 commented Oct 22, 2024

I think I've finished revising them according to your comment.

@nuskey8
Copy link
Owner

nuskey8 commented Oct 22, 2024

I haven't looked into the implementation of LuaVirtualMachine in detail yet, so I'll merge it in as soon as I've checked it.

@nuskey8
Copy link
Owner

nuskey8 commented Oct 25, 2024

I have checked the VM implementation. It looks very good. The only thing that bothers me is that SetOperations is separated into a separate Operators class. Is there a reason for this?

Also, I would also be grateful if you could let me know if you have any references for this optimization.

@nuskey8
Copy link
Owner

nuskey8 commented Oct 25, 2024

There is a conflict due to the merge of #47, could I resolve this on my end?

@Akeit0
Copy link
Collaborator Author

Akeit0 commented Oct 25, 2024

Of course!

@Akeit0
Copy link
Collaborator Author

Akeit0 commented Nov 4, 2024

I have checked the VM implementation. It looks very good. The only thing that bothers me is that SetOperations is separated into a separate Operators class. Is there a reason for this?

Also, I would also be grateful if you could let me know if you have any references for this optimization.

Considering that LuaVirtualMachine is a static class, and that using lambda expressions reduces readability and the visibility of exceptions, I use nested class.

@Akeit0
Copy link
Collaborator Author

Akeit0 commented Nov 4, 2024

Also, I would also be grateful if you could let me know if you have any references for this optimization.

No references available. I looked at the generated code and found that it was less efficient, so I adjusted it to generate the optimal code

@nuskey8
Copy link
Owner

nuskey8 commented Nov 5, 2024

I've resolved the conflicts and formatted the code.

If possible, could you please add comments to each step of the code? This will help me and other contributors understand the code properly.

@Akeit0
Copy link
Collaborator Author

Akeit0 commented Nov 5, 2024

@annulusgames
OK! Shall I leave the original async code in the comments?

@Akeit0
Copy link
Collaborator Author

Akeit0 commented Nov 5, 2024

Are these comments sufficient?

@Akeit0 Akeit0 closed this Nov 14, 2024
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.

2 participants