Boost logo

Boost :

Subject: Re: [boost] Overload resolution speed
From: Dave Abrahams (dave_at_[hidden])
Date: 2011-09-22 12:00:50

on Wed Sep 21 2011, Mathias Gaunard <> wrote:

> As part of the Boost.SIMD effort, another library was developed,
> Boost.Dispatch, which relies heavily on overload resolution.
> Before submitting this library for review, however, I did some
> compile-time benchmarking, and it's not looking very good.
> I'm therefore asking the Boost community if 1) this is expected, 2) if
> there is a workaround to this problem and 3) if compilers should be
> made to deal with this better.

1) In a sense, yes. Matt Calabrese and Zach Laine demonstrated that at
least there's no reason to expect metaprogramming with overload
resolution to be faster than metaprogramming with direct class template
instantiation. Google "instantiations must go".

2) None that I know of

3) Always ;-)

Dave Abrahams
BoostPro Computing

Boost list run by bdawes at, gregod at, cpdaniel at, john at