<body>

Prashant Deva's blog

Talks on technology and the latest developments in Placid Systems.

Wonder why your Java IO is slow?

Saturday, January 20, 2007

During one of my debugging sessions, I came across the following piece of code inside the java.io.PrintStream class from jdk 5.

protected void setError() {
trouble = true;

try { throw new IOException();} catch (IOException x) {}

}


No wonder java IO is so slow!

Labels: , ,

posted by Prashant Deva, 2:19 AM | link | 2 comments |