Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(131)

Issue 3003753002: Clear StringToken.canonicalizer after each parsing. (Closed)

Created:
3 years, 4 months ago by scheglov
Modified:
3 years, 4 months ago
CC:
reviews_dartlang.org, dart-fe-team+reviews_google.com
Target Ref:
refs/heads/master
Visibility:
Public.

Description

Clear StringToken.canonicalizer after each parsing. Otherwise the canonicalizer grows without limit, and if the user edits files, we constantly parse new strings, so constantly add new entries into the cananonicalizer. Basically, it is not friendly for long running processes. I'm not quite sure why we need to makes it static anyway, if it can be used only for the same file content. Once we're done with a file, that is it, we don't need its entries. Anyway, this fixes a leak in Analysis Server. R=ahe@google.com, brianwilkerson@google.com, danrubel@google.com, paulberry@google.com BUG= Committed: https://github.com/dart-lang/sdk/commit/dab5318fad8e8537300371307bc30a536edef67c

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+8 lines, -0 lines) Patch
M pkg/analyzer/lib/src/dart/analysis/file_state.dart View 2 chunks +6 lines, -0 lines 0 comments Download
M pkg/front_end/lib/src/fasta/scanner/string_canonicalizer.dart View 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 6 (1 generated)
scheglov
3 years, 4 months ago (2017-08-23 16:43:39 UTC) #1
Brian Wilkerson
lgtm
3 years, 4 months ago (2017-08-23 16:47:48 UTC) #2
danrubel
LGTM
3 years, 4 months ago (2017-08-23 17:44:33 UTC) #3
scheglov
Committed patchset #1 (id:1) manually as dab5318fad8e8537300371307bc30a536edef67c (presubmit successful).
3 years, 4 months ago (2017-08-23 17:57:33 UTC) #5
ahe
3 years, 4 months ago (2017-08-24 09:37:42 UTC) #6
Message was sent while issue was closed.
I'm not sure why we need string canonicalization at all. Is this turned on in
Fasta?

Powered by Google App Engine
This is Rietveld 408576698