diff options
author | Anton Hansson <hansson@google.com> | 2018-02-14 13:50:56 +0000 |
---|---|---|
committer | Anton Hansson <hansson@google.com> | 2018-02-14 16:22:11 +0000 |
commit | f055b94e2bf6ea4696b6bac932f9ae4f542e91a8 (patch) | |
tree | ce00fc12655b7af13bf983be33db8fbca76fb8a4 /benchmarks | |
parent | 526cd9137d3ac3b03f8045442ea39d970bda7e88 (diff) |
Remove cachedLocaleData from DecimalFormat.
This cache was removed upstream in
http://hg.openjdk.java.net/jdk8u/jdk8u/jdk/rev/1d7a6adf499f,
and doesn't appear to be making a meaningful difference to
performance.
Benchmark results (product: hikey):
Before:
Experiment {instrument=runtime, benchmarkMethod=time_instantiation, vm=default, parameters={}}
Results:
runtime(ns): min=198214.70, 1st qu.=198214.70, median=198214.70, mean=198214.70, 3rd qu.=198214.70, max=198214.70
After:
Experiment {instrument=runtime, benchmarkMethod=time_instantiation, vm=default, parameters={}}
Results:
runtime(ns): min=197940.89, 1st qu.=197940.89, median=197940.89, mean=197940.89, 3rd qu.=197940.89, max=197940.89
Bug: 31930415
Test: m -j droid & ran benchmark
Change-Id: I83deaead58b7f79d2016fc68add2ec8b861414c7
Diffstat (limited to 'benchmarks')
-rw-r--r-- | benchmarks/src/benchmarks/regression/DecimalFormatBenchmark.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/benchmarks/src/benchmarks/regression/DecimalFormatBenchmark.java b/benchmarks/src/benchmarks/regression/DecimalFormatBenchmark.java index 0c4aa77874..2436379094 100644 --- a/benchmarks/src/benchmarks/regression/DecimalFormatBenchmark.java +++ b/benchmarks/src/benchmarks/regression/DecimalFormatBenchmark.java @@ -153,4 +153,10 @@ public class DecimalFormatBenchmark { public void time_formatToCharacterIterator10e1000(int reps) { formatToCharacterIterator(BD10E1000, reps); } + + public void time_instantiation(int reps) { + for (int i = 0; i < reps; i++) { + new DecimalFormat(); + } + } } |