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

D #26

Open
Imperatorn opened this issue May 23, 2021 · 2 comments
Open

D #26

Imperatorn opened this issue May 23, 2021 · 2 comments

Comments

@Imperatorn
Copy link

Hi! Interesting benchmarks 👍

But I see you are using some deprecated switches for D.

For example "noboundscheck" should be "boundscheck=off".

You're also using a lot of classes instead of structs (compared to the C++ version). If you don't want (don't have time) to change it to structs, consider adding the final keyword before class to make the comparison a bit fairer (vtable) :)

Thanks!

@edin
Copy link
Owner

edin commented May 25, 2021

Hi, thanks, I think I've tried to apply the same optimisation to D lang but at the time there was no difference in perfromance.

For C and C++ I've spend some extra time trying different aproaches similar to what is done in ADA port, eg. tagged unions, inhertiance, reducing virtual functions etc. and then I've tried to keep idomatic implementation in each language as much as i could.

For now I've added final modifier to classes and I'll check what else can be improved.

I have not tried GCC D lang version but i belive it should have the same performance as C++.

@Imperatorn
Copy link
Author

Tbh I didn't spend so much time looking at it 😁, I just noticed there was a lot of classes with public stuff etc. I can take a real look later and report back ☀️

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

No branches or pull requests

2 participants