On Mon, 29 Jan 2018, Kelvin Nilsen wrote: > It was determined that the reported ICE occurs because a NULL value is > passed from vectorizable_call () to > > targetm.vectorize.builtin_md_vectorized_function ( > callee, vectype_out, vectype_in). > > This patch avoids making this call if callee equals NULL. > > After successful bootstrap and regression testing, with preapproval, > this patch has been committed to the trunk. > > It it ok to backport to GCC 7 and GCC 6 (after testing on those > platforms)?
OK. Thanks, Richard. > Thanks. > > > gcc/ChangeLog: > > 2018-01-29 Richard Biener <rguent...@suse.de> > Kelvin Nilsen <kel...@gcc.gnu.org> > > PR bootstrap/80867 > * tree-vect-stmts.c (vectorizable_call): Don't call > targetm.vectorize_builtin_md_vectorized_function if callee is > NULL. > > Index: gcc/tree-vect-stmts.c > =================================================================== > --- gcc/tree-vect-stmts.c (revision 257105) > +++ gcc/tree-vect-stmts.c (working copy) > @@ -3159,7 +3159,7 @@ > if (cfn != CFN_LAST) > fndecl = targetm.vectorize.builtin_vectorized_function > (cfn, vectype_out, vectype_in); > - else > + else if (callee) > fndecl = targetm.vectorize.builtin_md_vectorized_function > (callee, vectype_out, vectype_in); > } > > -- Richard Biener <rguent...@suse.de> SUSE LINUX GmbH, GF: Felix Imendoerffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nuernberg)