aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/skyframe/serialization/CodecScanner.java
diff options
context:
space:
mode:
authorGravatar michajlo <michajlo@google.com>2018-02-26 12:29:37 -0800
committerGravatar Copybara-Service <copybara-piper@google.com>2018-02-26 12:31:52 -0800
commite5118c5da8255662caefd4a5e1cb5c37d9a19466 (patch)
treedab95883f2fa28c03647e20aa7315c5a4ebfe4e9 /src/main/java/com/google/devtools/build/lib/skyframe/serialization/CodecScanner.java
parentd4f954a1f9a47ef06369d0bd767891ca0378c2d8 (diff)
Optimize SkylarkNestedSet construction
Only check/update type if the types of elements that we're adding changes. In particular, the "is DICT/LIST" check can get expensive when run on every single inserted element. According to a hacky unit test (create 10M element SkylarkNestedSet 10x over) this is ~60% faster (~18s -> ~7s). This change is intended to be a quick fix, there's surely a more principled way to make skylark's type checking more efficient... PiperOrigin-RevId: 187062547
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/skyframe/serialization/CodecScanner.java')
0 files changed, 0 insertions, 0 deletions