public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH 0/2] Rework adding Power10 IEEE 128-bit min, max, and conditional move
@ 2020-09-22  3:39 Michael Meissner
  2020-09-22  3:41 ` [PATCH 1/2] Power10: Add IEEE 128-bit xsmaxcqp and xsmincqp support Michael Meissner
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Michael Meissner @ 2020-09-22  3:39 UTC (permalink / raw)
  To: gcc-patches, Michael Meissner, Segher Boessenkool,
	David Edelsohn, Bill Schmidt, Peter Bergner

These patches are my latest versions of the patches to add IEEE 128-bit min,
max, and conditional move to GCC.  They correspond to the earlier patches #3
and #4 (patches #1 and #2 have been installed).

The first patch just adds support for the xsmincqp and xsmaxcqp instructions.
Due to the NaN rules, this patch will only generate the minc/maxc instructions
if -ffast-math is used.  Unlike the previous patch, I did not try to combine
min/max for IEEE 128-bit with the existing power9 min/max for SF/DF mode.
Instead, I just created a new insn (without a generator for it).

The second patch adds the support for doing a conditional move, where the
comparison is one of the 4 binary floating point scalar types.  The types being
moved do not have to be the same as the types for comparison.  Unlike the
previous patches, I did not try to combine the normal comparison and the
reversed comparison into one insn.  Instead, I kept the two insns.

After using it for awhile, I did not like using SFDFKFTF as the mode for all 4
floating point types.  Instead, I used FPMASK and FPMASK2 for the cases that we
generate the compare and set mask instruction to do the conditional move.

As with power9, the conditional move allows some forms of min/max to be
generated without using -ffast-math, assuming the tests give the right results
for NaN's.

I have built bootstrapped compilers with/without these patches, and there were
no regressions in the test suite.  Can I check these patches into the master
branch?

I do not anticipate needing to back port these changes to GCC 10.

-- 
Michael Meissner, IBM
IBM, M/S 2506R, 550 King Street, Littleton, MA 01460-6245, USA
email: meissner@linux.ibm.com, phone: +1 (978) 899-4797

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2020-10-12 23:02 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-22  3:39 [PATCH 0/2] Rework adding Power10 IEEE 128-bit min, max, and conditional move Michael Meissner
2020-09-22  3:41 ` [PATCH 1/2] Power10: Add IEEE 128-bit xsmaxcqp and xsmincqp support Michael Meissner
2020-09-22  3:42 ` [PATCH 2/2] Power10: Add IEEE 128-bit fp conditional move Michael Meissner
2020-09-24  8:24 ` [PATCH 0/2] Rework adding Power10 IEEE 128-bit min, max, and " Florian Weimer
2020-09-24 20:56   ` Michael Meissner
2020-09-25 18:52     ` Segher Boessenkool
2020-10-12 23:02 ` Ping: " Michael Meissner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).