mozilla-gcc-internal-compiler-error.patch
branchfirefox68
changeset 1099 8a3c73e74e65
parent 1098 538cbf0bbdca
child 1100 e1c5065a014f
child 1103 54482415d6bd
equal deleted inserted replaced
1098:538cbf0bbdca 1099:8a3c73e74e65
     1 # HG changeset patch
       
     2 # User Wolfgang Rosenauer <wr@rosenauer.org>
       
     3 # Parent  88217eaa8804fc699c02411b1b5377ef7eb5d2db
       
     4 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90756
       
     5 https://bugzilla.mozilla.org/show_bug.cgi?id=1562886
       
     6 
       
     7 diff --git a/gfx/skia/skia/third_party/skcms/src/Transform_inl.h b/gfx/skia/skia/third_party/skcms/src/Transform_inl.h
       
     8 --- a/gfx/skia/skia/third_party/skcms/src/Transform_inl.h
       
     9 +++ b/gfx/skia/skia/third_party/skcms/src/Transform_inl.h
       
    10 @@ -554,17 +554,18 @@ SI void sample_clut_16(const skcms_A2B* 
       
    11      *r = cast<F>((rgb >>  0) & 0xffff) * (1/65535.0f);
       
    12      *g = cast<F>((rgb >> 16) & 0xffff) * (1/65535.0f);
       
    13      *b = cast<F>((rgb >> 32) & 0xffff) * (1/65535.0f);
       
    14  #endif
       
    15  }
       
    16  
       
    17  // GCC 7.2.0 hits an internal compiler error with -finline-functions (or -O3)
       
    18  // when targeting MIPS 64,  I think attempting to inline clut() into exec_ops().
       
    19 -#if 1 && defined(__GNUC__) && !defined(__clang__) && defined(__mips64)
       
    20 +// s390x and i*86 also hit this with GCC 7.4 and -O2
       
    21 +#if 1 && defined(__GNUC__) && !defined(__clang__) && ( defined(__mips64) || defined(__s390x__) || defined( __i586__ ) || defined( __i486__ ) || defined( __i386__ ))
       
    22      #define MAYBE_NOINLINE __attribute__((noinline))
       
    23  #else
       
    24      #define MAYBE_NOINLINE
       
    25  #endif
       
    26  
       
    27  MAYBE_NOINLINE
       
    28  static void clut(const skcms_A2B* a2b, F* r, F* g, F* b, F a) {
       
    29      const int dim = (int)a2b->input_channels;