Quote Originally Posted by TSLexi
The C++ standard should require compilers to support devirtualization in order to be compliant.
The C++ standard does not require any particular scheme for the implementation of virtual functions, hence it cannot require any particular optimisation pertaining to such implementations. It could require compilers to implement virtual calls as non-virtual calls wherever possible, but that may well be too loose a requirement since "wherever possible" depends on how good the compiler is at the analysis required to determine that such an optimisation can be correctly applied. So, for compilers that lack the implementation of such optimisations, this is not a bug, but rather the lack of a feature.