Tag: ICU

libidn vs. ICU benchmark in string prepping

Due to Waqas's asking for months now I've finally got around and made some benchmarks on two string prepping libraries. The one being libidn, as far as I know most XMPP servers use this and the other being ICU by IBM.

libidn is LGPL licensed and ICU is MIT licensed.

Current XMPP standard says that every JID must be string prepped so if you don't want to cache because of memory reasons your string prepping routines are called quite often. It turns out ICU is much faster than libidn. For this benchmark I tested a couple of strings and let them go through nameprep, resourceprep and nodeprep profiles via string prepping.

The result is that ICU is about 60 times faster in string prepping. Version of libidn being 1.15 and of ICU being

The source code package of the benchmark is attached to this node. It falls under GPLv3 license.

Posted with tags , , ,