-
Bug
-
Resolution: Fixed
-
P3
-
1.4.2
-
tiger
-
generic
-
generic
-
Verified
On an Ultra 10, the following performance number was generated for ISO2022KR:
1.3.1_04 1.4.2 Result
-------- ------ ------
26488 557651 -2005%
This program is based on the program from 4752992. This problem may or may not be similar to that reported in said bug.
Use the following program to reproduce the problem:
---------------------------- Cut Here -------------------------------
import java.io.*;
import java.util.*;
public class CharsetTest {
private int iterations = 100000;
private ByteArrayOutputStream baos;
private OutputStreamWriter osw;
public static void main(String[] arg) {
new CharsetTest();
}
public CharsetTest() {
try {
baos = new ByteArrayOutputStream();
long start = System.currentTimeMillis();
for (int i = 0; i < iterations; i++) {
osw = new OutputStreamWriter(baos, "ISO2022KR");
}
long end = System.currentTimeMillis();
long t = end - start;
System.out.println("Time: " + t);
} catch (Exception e) {
e.printStackTrace();
}
}
}
---------------------------- Cut Here -------------------------------
###@###.### 2003-02-03
1.3.1_04 1.4.2 Result
-------- ------ ------
26488 557651 -2005%
This program is based on the program from 4752992. This problem may or may not be similar to that reported in said bug.
Use the following program to reproduce the problem:
---------------------------- Cut Here -------------------------------
import java.io.*;
import java.util.*;
public class CharsetTest {
private int iterations = 100000;
private ByteArrayOutputStream baos;
private OutputStreamWriter osw;
public static void main(String[] arg) {
new CharsetTest();
}
public CharsetTest() {
try {
baos = new ByteArrayOutputStream();
long start = System.currentTimeMillis();
for (int i = 0; i < iterations; i++) {
osw = new OutputStreamWriter(baos, "ISO2022KR");
}
long end = System.currentTimeMillis();
long t = end - start;
System.out.println("Time: " + t);
} catch (Exception e) {
e.printStackTrace();
}
}
}
---------------------------- Cut Here -------------------------------
###@###.### 2003-02-03
- relates to
-
JDK-4752992 (cs) Looking up non-NIO charsets is very slow
- Resolved