https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119687
--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Recuding. Note it seems cache related too. In that if I remove some code before the template instantiation place that is causing the problem, the ICE goes away.