Skip to content
Snippets Groups Projects
Commit 67b750c2 authored by Jakub Jelinek's avatar Jakub Jelinek Committed by Jakub Jelinek
Browse files

i386: Fix up *minmax<mode>3_2 splitter [PR116925]

While *minmax<mode>3_1 correctly uses
   if (MEM_P (operands[1]))
     operands[1] = force_reg (<MODE>mode, operands[1]);
to ensure operands[1] is not a MEM, *minmax<mode>3_2 does it wrongly
by calling force_reg but ignoring its return value.

The following borderingly obvious patch fixes that.

Didn't find similar other errors in the backend with force_reg calls.

2024-10-04  Jakub Jelinek  <jakub@redhat.com>

	PR target/116925
	* config/i386/sse.md (*minmax<mode>3_2): Assign force_reg result
	back to operands[2] instead of throwing it away.

	* g++.target/i386/avx-pr116925.C: New test.
parent 247643c7
No related branches found
No related tags found
No related merge requests found
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