-
Notifications
You must be signed in to change notification settings - Fork 405
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
[SR-11287] memory leak in code completion #417
Comments
Interestingly, a lot of the other completion tests (`test/IDE/complete_*`) have leaks detected by LSAN even at commit 482d062. So maybe there were already some completion-related leaks, and then PR26403 added even more? |
@rintaro have you made any progress on this? It's currently blocking some work on a Google-internal SourceKit deployment that I'm working on. Would it maybe be possible to roll back the PR? |
@marcrasi Sorry for being late.
Right. I'm still fixing existing leaks. |
Awesome, I just verified that swiftlang/swift#26664 fixes the issue in the Google-internal SourceKit too! Thanks 🙂 |
Do you think it would be possible to configure the LSAN CI job to run some SourceKit completion tests, to catch regressions earlier? Looks like that job currently doesn't run any tests (https://github.com/apple/swift/blob/1afd0f7cf757ba6b12d2af0d151eafb022acf439/utils/build-presets.ini#L1084), I guess because a lot of them leak so the job would just fail. Maybe we could configure it to run a whitelisted subset of tests under LSAN and slowly whitelist more tests as more leaks get fixed. I'd be happy to look into this if you think it's a good idea. |
I think that's great idea. Could you file another JIRA issue for that? |
Merged swiftlang/swift#26664 |
Improve `XCTest` import detection logic.
Additional Detail from JIRA
md5: c6d1c2bd64fda68f9aeb152794a9724e
Issue Description:
On Ubuntu 18.04, at commit c43eb9b (~noon Aug 9 HEAD), I'm getting memory leaks when doing code completion. To reproduce,
swift/utils/build-script --release --enable-lsan --debug-swift-stdlib
llvm/utils/lit/lit.py build/Ninja-ReleaseAssert+stdlib-DebugAssert/swift-linux-x86_64/test-linux-x86_64/IDE/complete_repl_identifier_prefix_1.swift -a
LSAN should print out leaks. Here's what I get: https://gist.github.com/marcrasi/7d1f5e5766833c605b92873687eb49ca
This does not occur at commit 482d062 and does occur at commit 1a211e6, so I suspect that swiftlang/swift#26403 caused it.
The text was updated successfully, but these errors were encountered: