Skip to content

Conversation

@JDevlieghere
Copy link

dsymutil is using an excessive amount of memory because it's holding on to the DWARF Context, even after it's done processing the corresponding object file. This patch releases the input DWARF after cloning, at which point it is no longer needed. This has always been the intended behavior, though I didn't bisect to figure out when this regressed.

When linking swift, this reduces peak (dirty) memory usage from 25 to 15 gigabytes.

rdar://111525100

dsymutil is using an excessive amount of memory because it's holding on
to the DWARF Context, even after it's done processing the corresponding
object file. This patch releases the input DWARF after cloning, at which
point it is no longer needed. This has always been the intended
behavior, though I didn't bisect to figure out when this regressed.

When linking swift, this reduces peak (dirty) memory usage from 25 to 15
gigabytes.

rdar://111525100
@JDevlieghere
Copy link
Author

@swift-ci please test

@JDevlieghere
Copy link
Author

@swift-ci please test windows

@JDevlieghere JDevlieghere merged commit 75e11a6 into swift/release/5.10 Oct 9, 2023
@JDevlieghere JDevlieghere deleted the jdevlieghere/rdar/111525100 branch October 9, 2023 21:51
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