]> git.ipfire.org Git - thirdparty/gcc.git/commit
amdgcn: add fmin/fmax patterns
authorAndrew Stubbs <ams@codesourcery.com>
Fri, 28 Oct 2022 12:09:20 +0000 (13:09 +0100)
committerAndrew Stubbs <ams@codesourcery.com>
Mon, 31 Oct 2022 12:20:53 +0000 (12:20 +0000)
commit10aa0356118f44e5f4d720a2a4c731b173baa298
tree9a8b2cf6fb04ddeb95e943bff6ef4f77501d91df
parentf539029c1ce6fb9163422d1a8b6ac12a2554eaa2
amdgcn: add fmin/fmax patterns

Add fmin/fmax for scalar, vector, and reductions.  The smin/smax patterns are
already using the IEEE compliant hardware instructions anyway, so we can just
expand to use those insns.

gcc/ChangeLog:

* config/gcn/gcn-valu.md (fminmaxop): New iterator.
(<fexpander><mode>3): New define_expand.
(<fexpander><mode>3<exec>): Likewise.
(reduc_<fexpander>_scal_<mode>): Likewise.
* config/gcn/gcn.md (fexpander): New attribute.
gcc/config/gcn/gcn-valu.md
gcc/config/gcn/gcn.md