Boost logo

Boost :

Subject: [boost] [metaparse] performance comparisons?
From: Peter Dimov (lists_at_[hidden])
Date: 2015-06-01 12:06:37


Abel,

After looking at Metaparse, I inquired on the c++std-ext list as to whether
user-defined operators can create char packs from integer or floating point
literals, but not from string literals, as this would have made the
MPLLIBS_STRING macro unnecessary.

As it turns out, there has been such a proposal, N3599:

http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3599.html

later referenced by two competing proposals for compile-time string
literals, N4121 and N4236:

https://isocpp.org/files/papers/n4121.pdf
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n4236.html

N3599 has been however rejected, as the committee apparently feels that
representing compile-time strings as char packs is inefficient and
impractical, and prefers constexpr char arrays.

I cited Metaparse as an argument that char packs are quite obviously
practical if they work in practice, and was asked whether measurement data
has been presented as part of the formal review, perhaps compared to
alternatives.

I'm not aware of any alternatives to Metaparse though, so this question may
be hard to answer. :-)

Either way, the only performance data I see is

http://abel.web.elte.hu/mpllibs/metaparse/performance.html

which seems rather slim. Is there any other?

(On an unrelated note, the cpp-next.com link is dead, but archive.org still
has it at
http://web.archive.org/web/20140217173026/http://cpp-next.com/archive/2012/10/using-strings-in-c-template-metaprograms).


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk