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

Prevent creation of useless URI copies in IO.directoryURI #132

Merged
merged 1 commit into from Feb 19, 2018

Conversation

Projects
None yet
4 participants
@jrudolph
Member

jrudolph commented Feb 18, 2018

Without this change, Scope.resolveBuild will create new identical URI copies
for every call leading to potentially hundreds of thousand of URI copies pointing
to the project path potential using a significant share of the configured heap for
sbt.

In big projects, the wasted memory can be hundreds of MBs leading to increased
memory pressure. With a 2.5GB heap I've seen > 10% better project load
performance on big projects.

Prevent creation of useless URI copies in IO.directoryURI
Without this change, `Scope.resolveBuild` will create new identical URI copies
for every call leading to potentially hundreds of thousand of URI copies pointing
to the project path potential using a significant share of the configured heap for
sbt.

In big projects, the wasted memory can be hundreds of MBs leading to increased
memory pressure. With a 2.5GB heap I've seen > 10% better project load
performance on big projects.

@eed3si9n eed3si9n added the ready label Feb 18, 2018

@typesafe-tools

This comment has been minimized.

typesafe-tools commented Feb 18, 2018

The validator has checked the following projects against Scala 2.12,
tested using dbuild, projects built on top of each other.

Project Reference Commit
sbt 1.x sbt/sbt@bde197f
zinc 1.x sbt/zinc@3c12aba
io pull/132/head 7493bf7
librarymanagement 1.x sbt/librarymanagement@0d21ae6
util 1.x sbt/util@9891f07
website 1.x

The result is: SUCCESS
(restart)

@dwijnand

Very nice! Thanks @jrudolph.

@dwijnand dwijnand merged commit 438474e into sbt:1.x Feb 19, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@dwijnand dwijnand removed the ready label Feb 19, 2018

@jrudolph jrudolph deleted the jrudolph:jr/optimize-directoryURI branch Feb 19, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment