Skip to content

Micro-optimization: Symbol#denot #3263

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

Merged
merged 2 commits into from
Oct 6, 2017
Merged

Conversation

odersky
Copy link
Contributor

@odersky odersky commented Oct 5, 2017

No description provided.

@odersky
Copy link
Contributor Author

odersky commented Oct 5, 2017

test performance please

@dottybot
Copy link
Member

dottybot commented Oct 5, 2017

performance test scheduled: 7 job(s) in queue, 1 running.

@odersky odersky force-pushed the try-optimize-7 branch 2 times, most recently from c227587 to 5e6278e Compare October 5, 2017 10:35
@odersky
Copy link
Contributor Author

odersky commented Oct 5, 2017

test performance please

@dottybot
Copy link
Member

dottybot commented Oct 5, 2017

performance test scheduled: 5 job(s) in queue, 1 running.

Make the overridden method less frequently called
@liufengyun
Copy link
Contributor

The benchmark test is currently running for this PR, should finish in about 40min.

@dottybot
Copy link
Member

dottybot commented Oct 5, 2017

Performance test finished successfully:

Visit http://dotty-bench.epfl.ch/3263/ to see the changes.

Benchmarks is based on merging with master (c50c164)

@odersky odersky requested a review from smarter October 5, 2017 19:59
if (lastd.validFor contains now) lastd else recomputeDenot(lastd)
}

/** Overridden in NoSymbol */
Copy link
Member

Choose a reason for hiding this comment

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

Not sure if it'll help performance, but have you tried doing if (this eq NoSymbol) NoDenotation else ... to avoid the override?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have not tired it. I don't think we'd see a difference either way. Would be good to know more about tradeoffs like this, though.

@odersky odersky merged commit 223aa2a into scala:master Oct 6, 2017
@allanrenucci allanrenucci deleted the try-optimize-7 branch December 14, 2017 19:25
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