Skip to content
Snippets Groups Projects
Commit 0194d92c authored by Richard Biener's avatar Richard Biener
Browse files

tree-optimization/103489 - fix ICE when bool pattern recog fails

bool pattern recog currently does not handle cycles correctly
and when it fails we can ICE later vectorizing PHIs with
mismatched bool and non-bool vector types.  The following avoids
blindly trusting bool pattern recog here and verifies things
more thoroughly in vectorizable_phi.  A bool pattern recog fix
is for GCC 13.

2021-11-30  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/103489
	* tree-vect-loop.c (vectorizable_phi): Verify argument
	vector type compatibility to mitigate bool pattern recog
	bug.

	* gcc.dg/torture/pr103489.c: New testcase.
parent 7e846b0f
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment