dev@jaxb.java.net

String Interning

From: Matthias Ernst <matthias_at_mernst.org>
Date: Sun, 1 Jul 2007 22:29:58 +0200

Hi,

in a low-level benchmark with JAXB, XmlInterningVisitor turned up. Why
exactly are interned symbols required?

To try, I patched UnmarshallerImpl to not require interning and +
QNameMap to do .equals-comparsion. Result: 190000 unmarshalled objects
per second instead of 100000.

So Interning cost almost 50% performance in my case.

Do you have other results? Was interning a premature optimization?

Cheers
Matthias