https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83114

James Greenhalgh <jgreenhalgh at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |amker.cheng at gmail dot com,
                   |                            |jgreenhalgh at gcc dot gnu.org,
                   |                            |sudi.das at arm dot com
      Known to work|6.4.1                       |4.8.1
      Known to fail|                            |4.9.1, 5.1.1

--- Comment #3 from James Greenhalgh <jgreenhalgh at gcc dot gnu.org> ---
Looks like we're missing handling for LTGT in our vcmp/vcond handlers.

  /* This is an ordered NE, ie !UNEQ, ie false for NaN.  */
  DEF_RTL_EXPR(LTGT, "ltgt", "ee", RTX_COMM_COMPARE)

I bet this would fail even further back with a modified testcase (this one is
somewhat undefined behaviour).

  void *a;
  void b(double *in) {
    char c;
    long d = -1024;
    char *e = a;
    for (; d; d++) {
      double f = in[d], g = in[d+1];
      c = g < f || g > f;
      e[d] = c;
    }
  }

Is broken back to at least GCC 4.9.

Well... I implemented the original version of this code in GCC 4.9 and today is
the first time I heard of LTGT, so not surprising I missed it!

Reply via email to