- enhanced warnings patch; release 13
[packages/framewave.git] / framewave-warnings.patch
1 --- FRAMEWAVE_1.3.1_SRC/Framewave/sdk/cbl/cbl_common_primitives.h.orig  2009-07-09 11:14:37.000000000 +0200
2 +++ FRAMEWAVE_1.3.1_SRC/Framewave/sdk/cbl/cbl_common_primitives.h       2017-04-15 11:28:42.272853562 +0200
3 @@ -152,6 +152,11 @@ union CBL_FORCEALIGN_16 XMM128
4      S8      s8 [16];  
5  };
6  
7 +#if defined(__GNUC__) && (__GNUC__ >= 6)
8 +#pragma GCC diagnostic push
9 +#pragma GCC diagnostic ignored "-Wnarrowing"
10 +#endif
11 +
12  #if defined( CBL_MSVC )
13  
14  namespace CBL_LIBRARY
15 @@ -648,4 +653,8 @@ namespace CBL_LIBRARY
16  
17  } // namespace CBL_LIBRARY
18  
19 +#if defined(__GNUC__) && (__GNUC__ >= 6)
20 +#pragma GCC diagnostic pop
21 +#endif
22 +
23  #endif // __CBL_COMMON_PRIMITIVES_H__
24 --- FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwImage/include/color.h.orig   2009-07-09 11:15:30.000000000 +0200
25 +++ FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwImage/include/color.h        2017-04-15 12:22:56.753144791 +0200
26 @@ -266,12 +266,19 @@ namespace OPT_LEVEL
27  //Cb 38        74      112      9 19 28
28  //Cr 112 94 18   28 24 4 
29  
30 +#if defined(__GNUC__) && (__GNUC__ >= 6)
31 +#pragma GCC diagnostic push
32 +#pragma GCC diagnostic ignored "-Wnarrowing"
33 +#endif
34          static const __m128i rgbtoYcbcr_Y = CONST_SET_16I(25,129,66,0,0,25,129,66);
35          static const __m128i rgbtoYcbcr_crcb = CONST_SET_16I(-4,-24,28,0,0,28,-19,-9);
36          static const __m128i const128 = CONST_SET_16I(0,0,0,128,128,0,0,0);
37          static const __m128i const16 = CONST_SET_16I(0,16,0,16,0,16,0,16);
38          static const __m128i addconst128 = CONST_SET_16I(0,0,0,128,0,0,0,128);
39          static const __m128i zero = CONST_SET1_32I(0);
40 +#if defined(__GNUC__) && (__GNUC__ >= 6)
41 +#pragma GCC diagnostic pop
42 +#endif
43  
44          if (row > 1) // Condition: 1) # of rows = 2
45          {
46 --- FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwImage/include/colorModelConvSpecial.h.orig   2009-07-09 11:15:30.000000000 +0200
47 +++ FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwImage/include/colorModelConvSpecial.h        2017-04-15 13:21:50.183726931 +0200
48 @@ -214,9 +214,9 @@ namespace OPT_LEVEL
49                      pfn( ptrSrc    , C1, ((A8U *)pDst + 1), C1 ); // A0
50                      pfn( ptrSrc + 3, C1, ((A8U *)pDst + 3), C1 ); // A1
51                      // Calculate the average of the two pixel values for 422 compression
52 -                    TS srcData[3] = { (*ptrSrc       + *(ptrSrc + 3))>>1,   // R
53 -                                      (*(ptrSrc + 1) + *(ptrSrc + 4))>>1,   // G
54 -                                      (*(ptrSrc + 2) + *(ptrSrc + 5))>>1 }; // B
55 +                    TS srcData[3] = { static_cast<TS>((*ptrSrc       + *(ptrSrc + 3))>>1),   // R
56 +                                      static_cast<TS>((*(ptrSrc + 1) + *(ptrSrc + 4))>>1),   // G
57 +                                      static_cast<TS>((*(ptrSrc + 2) + *(ptrSrc + 5))>>1) }; // B
58                      pfn( srcData, C3, tempDst, C3 );
59                      *(A8U *)pDst       = tempDst[1]; // B0
60                      *(A8U *)(pDst + 2) = tempDst[2]; // C0
61 @@ -280,9 +280,9 @@ namespace OPT_LEVEL
62                      pfn( ptrSrc    , C1, (pDst + 1 ), C1 );  // A0
63                      pfn( ptrSrc + 4, C1, (pDst + 3 ), C1 );  // A1
64                      // Calculate the average of the two pixel values for 422 compression
65 -                    TS srcData[3] = { (*ptrSrc     + *(ptrSrc + 4))>>1,   // R
66 -                                      (*(ptrSrc+1) + *(ptrSrc + 5))>>1,   // G
67 -                                      (*(ptrSrc+2) + *(ptrSrc + 6))>>1 }; // B
68 +                    TS srcData[3] = { static_cast<TS>((*ptrSrc     + *(ptrSrc + 4))>>1),   // R
69 +                                      static_cast<TS>((*(ptrSrc+1) + *(ptrSrc + 5))>>1),   // G
70 +                                      static_cast<TS>((*(ptrSrc+2) + *(ptrSrc + 6))>>1) }; // B
71  
72                      pfn( srcData, C3, tempDst, C3 );
73  
74 @@ -350,9 +350,9 @@ namespace OPT_LEVEL
75                      pfn( ptrSrc  , C1, pDst       , C1 );    // A0
76                      pfn( ptrSrc+3, C1, (pDst + 2 ), C1 );    // A1
77                      // Calculate the average of the two pixel values for 422 compression
78 -                    TS srcData[3] = { (*ptrSrc       + *(ptrSrc + 3))>>1, 
79 -                                      (*(ptrSrc + 1) + *(ptrSrc + 4))>>1,
80 -                                      (*(ptrSrc + 2) + *(ptrSrc + 5))>>1 };
81 +                    TS srcData[3] = { static_cast<TS>((*ptrSrc       + *(ptrSrc + 3))>>1), 
82 +                                      static_cast<TS>((*(ptrSrc + 1) + *(ptrSrc + 4))>>1),
83 +                                      static_cast<TS>((*(ptrSrc + 2) + *(ptrSrc + 5))>>1) };
84  
85                      pfn( srcData , C3, tempDst, C3 );
86  
87 @@ -569,9 +569,9 @@ namespace OPT_LEVEL
88                      pfn( ptrSrc+3, C1, pDst[0] + 1, C1 ); // A1
89  
90                      // Calculate the average of the two pixel values for 422 compression
91 -                    TS srcData[3] = { (*ptrSrc     + *(ptrSrc+3))>>1, 
92 -                                      (*(ptrSrc+1) + *(ptrSrc+4))>>1,
93 -                                      (*(ptrSrc+2) + *(ptrSrc+5))>>1 };
94 +                    TS srcData[3] = { static_cast<TS>((*ptrSrc     + *(ptrSrc+3))>>1), 
95 +                                      static_cast<TS>((*(ptrSrc+1) + *(ptrSrc+4))>>1),
96 +                                      static_cast<TS>((*(ptrSrc+2) + *(ptrSrc+5))>>1) };
97                      
98                      pfn (srcData, C3, tempDst, C3);
99                      *(pDst[1]) = tempDst[1]; // B0
100 --- FRAMEWAVE_1.3.1_SRC/Framewave/sdk/cbl/cbl_pack_unpack_primitives_sse2.h.orig        2009-07-09 11:14:37.000000000 +0200
101 +++ FRAMEWAVE_1.3.1_SRC/Framewave/sdk/cbl/cbl_pack_unpack_primitives_sse2.h     2017-04-15 11:31:37.638153156 +0200
102 @@ -358,8 +358,16 @@ CBL_INLINE  __m128i CBL_SSE2::Pack64STo3
103         __m128i  h2= _mm_unpackhi_epi32(srcLo,srcHi);
104         __m128i hBytes  = _mm_unpackhi_epi32(h1,h2);
105         __m128i lBytes  = _mm_unpacklo_epi32(h1,h2);
106 +
107 +#if defined(__GNUC__) && (__GNUC__ >= 6)
108 +#pragma GCC diagnostic push
109 +#pragma GCC diagnostic ignored "-Wnarrowing"
110 +#endif
111          const __m128i zero =  CONST_SETZERO_32I();
112          const __m128i nOne =  CONST_SET1_32I(0xFFFFFFFF);
113 +#if defined(__GNUC__) && (__GNUC__ >= 6)
114 +#pragma GCC diagnostic pop
115 +#endif
116  
117         __m128i x = _mm_cmplt_epi32(hBytes,nOne);
118                         h1 = _mm_slli_epi32(x,31);
119 --- FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/arithmetic/SSEPlus_arithmetic_SSE2.h.orig 2009-07-09 11:15:28.000000000 +0200
120 +++ FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/arithmetic/SSEPlus_arithmetic_SSE2.h      2017-04-15 13:05:16.648171534 +0200
121 @@ -90,7 +90,14 @@ __m128i ssp_arithmetic_hadd4_epi16_SSE2(
122  SSP_FORCEINLINE
123  __m128 ssp_round_ps_neg_zero_SSE2( __m128  a, int iRoundMode )
124  {
125 +#if defined(__GNUC__) && (__GNUC__ >= 6)
126 +#pragma GCC diagnostic push
127 +#pragma GCC diagnostic ignored "-Wnarrowing"
128 +#endif
129      const static __m128i SIGN_BIT = SSP_CONST_SET_32I( 0x80000000, 0x80000000, 0x80000000,0x80000000 );
130 +#if defined(__GNUC__) && (__GNUC__ >= 6)
131 +#pragma GCC diagnostic pop
132 +#endif
133      ssp_m128 A, sign;
134      A.f = a;
135      
136 --- FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/convert/SSEPlus_convert_SSE2.h.orig       2009-07-09 11:15:28.000000000 +0200
137 +++ FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/convert/SSEPlus_convert_SSE2.h    2017-04-15 13:20:25.736238223 +0200
138 @@ -149,11 +149,18 @@ void ssp_convert_reverse_transpose_SSE2(
139  SSP_FORCEINLINE
140  void ssp_convert_3p_3c_epi8_SSE2( __m128i *r, __m128i *g, __m128i *b )
141  {
142 +#if defined(__GNUC__) && (__GNUC__ >= 6)
143 +#pragma GCC diagnostic push
144 +#pragma GCC diagnostic ignored "-Wnarrowing"
145 +#endif
146      const static __m128i odd_8  = SSP_CONST_SET_8I(   0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF,0 );
147      const static __m128i even_8 = SSP_CONST_SET_8I( 0,0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF,0,0xFF   );
148  
149      const static __m128i odd_16  = SSP_CONST_SET_16I(   0xFFFF,0,0xFFFF,0,0xFFFF,0,0xFFFF,0 );
150      const static __m128i even_16 = SSP_CONST_SET_16I( 0,0xFFFF,0,0xFFFF,0,0xFFFF,0,0xFFFF   );    
151 +#if defined(__GNUC__) && (__GNUC__ >= 6)
152 +#pragma GCC diagnostic pop
153 +#endif
154  
155     ssp_m128 T, RG, GB, BR, RGBR, GBRG, BRGB;
156      
157 --- FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/emulation/SSEPlus_emulation_comps_REF.h.orig      2009-07-09 11:15:28.000000000 +0200
158 +++ FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/emulation/SSEPlus_emulation_comps_REF.h   2017-04-15 12:22:09.457482384 +0200
159 @@ -1598,7 +1598,14 @@ SSP_FORCEINLINE __m128 ssp_comgt_ss_REF(
160  SSP_FORCEINLINE __m128i ssp_comtrue_epi16_REF(__m128i a, __m128i b)
161  {
162      a; b;
163 +#if defined(__GNUC__) && (__GNUC__ >= 6)
164 +#pragma GCC diagnostic push
165 +#pragma GCC diagnostic ignored "-Wnarrowing"
166 +#endif
167         const static __m128i tmp = SSP_CONST_SET_64I( 0xFFFFFFFFFFFFFFFFULL, 0xFFFFFFFFFFFFFFFFULL );  
168 +#if defined(__GNUC__) && (__GNUC__ >= 6)
169 +#pragma GCC diagnostic pop
170 +#endif
171      return tmp;
172  }
173  
174 @@ -1648,7 +1655,14 @@ SSP_FORCEINLINE __m128i ssp_comtrue_epu8
175  SSP_FORCEINLINE __m128d ssp_comtrue_pd_REF(__m128d a, __m128d b)
176  {   
177      a; b;
178 +#if defined(__GNUC__) && (__GNUC__ >= 6)
179 +#pragma GCC diagnostic push
180 +#pragma GCC diagnostic ignored "-Wnarrowing"
181 +#endif
182      const static __m128i tmp = SSP_CONST_SET_64I( 0xFFFFFFFFFFFFFFFFULL, 0xFFFFFFFFFFFFFFFFULL );
183 +#if defined(__GNUC__) && (__GNUC__ >= 6)
184 +#pragma GCC diagnostic pop
185 +#endif
186      ssp_m128 A;  
187      A.i = tmp;
188      return A.d;
189 @@ -1658,7 +1672,14 @@ SSP_FORCEINLINE __m128d ssp_comtrue_pd_R
190  SSP_FORCEINLINE __m128 ssp_comtrue_ps_REF(__m128 a, __m128 b)
191  {   
192      a; b;
193 +#if defined(__GNUC__) && (__GNUC__ >= 6)
194 +#pragma GCC diagnostic push
195 +#pragma GCC diagnostic ignored "-Wnarrowing"
196 +#endif
197      const static __m128i tmp = SSP_CONST_SET_64I( 0xFFFFFFFFFFFFFFFFULL, 0xFFFFFFFFFFFFFFFFULL );
198 +#if defined(__GNUC__) && (__GNUC__ >= 6)
199 +#pragma GCC diagnostic pop
200 +#endif
201      ssp_m128 A;  
202      A.i = tmp;
203      return A.f;
204 --- FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/emulation/SSEPlus_emulation_SSE2.h.orig   2009-07-09 11:15:28.000000000 +0200
205 +++ FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/emulation/SSEPlus_emulation_SSE2.h        2017-04-15 13:03:50.600603842 +0200
206 @@ -13,6 +13,11 @@
207  #include "SSEPlus_emulation_comps_SSE2.h"
208  
209  
210 +#if defined(__GNUC__) && (__GNUC__ >= 6)
211 +#pragma GCC diagnostic push
212 +#pragma GCC diagnostic ignored "-Wnarrowing"
213 +#endif
214 +
215  /** @addtogroup emulated_SSE2   
216   *  @{ 
217   *  @name SSE[3,4A,...,5] implemented in SSE2
218 @@ -2185,4 +2190,8 @@ SSP_FORCEINLINE __m128i ssp_shl_epi64_SS
219   */
220  
221  
222 +#if defined(__GNUC__) && (__GNUC__ >= 6)
223 +#pragma GCC diagnostic pop
224 +#endif
225 +
226  #endif // __SSEPLUS_EMULATION_SSE2_H__
227 --- FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/logical/SSEPlus_logical_SSE2.h.orig       2009-07-09 11:15:29.000000000 +0200
228 +++ FRAMEWAVE_1.3.1_SRC/Framewave/sdk/SSEPlus/include/logical/SSEPlus_logical_SSE2.h    2017-04-15 12:44:16.222807366 +0200
229 @@ -7,6 +7,11 @@
230  
231  #include "../native/SSEPlus_native_SSE2.h"
232  
233 +#if defined(__GNUC__) && (__GNUC__ >= 6)
234 +#pragma GCC diagnostic push
235 +#pragma GCC diagnostic ignored "-Wnarrowing"
236 +#endif
237 +
238  /** @addtogroup supplimental_SSE2
239   *  @{ 
240   *  @name Logical Operations
241 @@ -148,4 +153,8 @@ SSP_FORCEINLINE __m128i ssp_srli_epi8_SS
242   *  @}
243   */
244  
245 +#if defined(__GNUC__) && (__GNUC__ >= 6)
246 +#pragma GCC diagnostic pop
247 +#endif
248 +
249  #endif // __SSEPLUS_LOGICAL_SSE2_H__
250 --- FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwJPEG/src/JPEGColor.cpp.orig  2009-07-09 11:15:35.000000000 +0200
251 +++ FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwJPEG/src/JPEGColor.cpp       2017-04-15 17:58:22.256551161 +0200
252 @@ -71,11 +71,18 @@
253  static SYS_INLINE void YCbCrToRGBConv(__m128i &y,__m128i &cb,__m128i &cr)
254  {
255                      __m128i r, g, b;
256 +#if defined(__GNUC__) && (__GNUC__ >= 6)
257 +#pragma GCC diagnostic push
258 +#pragma GCC diagnostic ignored "-Wnarrowing"
259 +#endif
260                      static const __m128i constant = CONST_SET1_32I((S16)(128*64.0));
261                      static const __m128i val90 = CONST_SET1_16I                ( (S16)90               );              // R = ( 1.402*2^6 )
262                      static const __m128i val46 = CONST_SET1_16I                ( (S16)(-46)    );              // G = ( -.71414*2^6 )
263                      static const __m128i val22 = CONST_SET1_16I                ( (S16)(-22)    );              // cr= ( -0.34414*(2^6) )
264                      static const __m128i val113 = CONST_SET1_16I( (S16)(113)   );              // B = ( 1.772*(2^6) )
265 +#if defined(__GNUC__) && (__GNUC__ >= 6)
266 +#pragma GCC diagnostic pop
267 +#endif
268  
269  
270                      // RED
271 --- FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwJPEG/include/JPEGColorConv.h.orig    2009-07-09 11:15:34.000000000 +0200
272 +++ FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwJPEG/include/JPEGColorConv.h 2017-04-15 18:10:42.566324738 +0200
273 @@ -8,6 +8,11 @@
274  
275  #include "fe.h"
276  
277 +#if defined(__GNUC__) && (__GNUC__ >= 6)
278 +#pragma GCC diagnostic push
279 +#pragma GCC diagnostic ignored "-Wnarrowing"
280 +#endif
281 +
282  namespace OPT_LEVEL
283  {
284  SYS_INLINE static void  Mul_16s(__m128i const &s1,__m128i const &s2,__m128i &d1,__m128i &d2)
285 @@ -1304,4 +1309,8 @@
286  /////////
287  }
288  
289 +#if defined(__GNUC__) && (__GNUC__ >= 6)
290 +#pragma GCC diagnostic pop
291 +#endif
292 +
293  #endif // __JPEGCOLORCONV_H__
294 --- FRAMEWAVE_1.3.1_SRC/Framewave/domain/common/include/SSE2Intrinsic.h.orig    2009-07-09 11:15:40.000000000 +0200
295 +++ FRAMEWAVE_1.3.1_SRC/Framewave/domain/common/include/SSE2Intrinsic.h 2017-04-15 18:22:32.157931524 +0200
296 @@ -309,6 +309,11 @@
297  }
298  
299  
300 +#if defined(__GNUC__) && (__GNUC__ >= 6)
301 +#pragma GCC diagnostic push
302 +#pragma GCC diagnostic ignored "-Wnarrowing"
303 +#endif
304 +
305  // these variants don't check for the magnitude to be 0, since if magnitude
306  // is 0, it WILL NOT be less than level (since only gtzero levels are passed into
307  // the LT functions) hence these values will be cleared out anyway
308 @@ -348,6 +353,10 @@
309      return        ret.d;
310  }
311  
312 +#if defined(__GNUC__) && (__GNUC__ >= 6)
313 +#pragma GCC diagnostic pop
314 +#endif
315 +
316  SYS_INLINE STATIC __m128i _fw_threshval_16sc(const XMM128& complex, const XMM128 &level)
317  {
318      XMM128 ret = complex, rethi, mag, maghi, temp;
319 --- FRAMEWAVE_1.3.1_SRC/Framewave/domain/common/include/shuffle.h.orig  2009-07-09 11:15:40.000000000 +0200
320 +++ FRAMEWAVE_1.3.1_SRC/Framewave/domain/common/include/shuffle.h       2017-04-15 18:23:39.564585726 +0200
321 @@ -106,6 +106,11 @@
322  // --- </epi16> ---
323  
324  
325 +#if defined(__GNUC__) && (__GNUC__ >= 6)
326 +#pragma GCC diagnostic push
327 +#pragma GCC diagnostic ignored "-Wnarrowing"
328 +#endif
329 +
330  // --- <epi8> ---
331  SYS_INLINE STATIC __m128i _mm_rlli_epi8(const __m128i &reg, const  int &by)
332  {
333 @@ -140,6 +145,10 @@
334  }
335  // --- </epi8> ---
336  
337 +#if defined(__GNUC__) && (__GNUC__ >= 6)
338 +#pragma GCC diagnostic pop
339 +#endif
340 +
341  
342  } // namespace OPT_LEVEL
343  
344 --- FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwImage/include/colorModelConversion.h.orig    2009-07-09 11:15:30.000000000 +0200
345 +++ FRAMEWAVE_1.3.1_SRC/Framewave/domain/fwImage/include/colorModelConversion.h 2019-04-26 17:54:35.318411314 +0200
346 @@ -1631,7 +1631,7 @@
347          template <ConvFunc fn, PixelID pid, ProcID prc, MathPattern mp>
348          struct Pixel
349          {
350 -            static SYS_INLINE __m128i Process( XMM128 &pX, XMM128 &pY, XMM128 &pZ ) { STATIC_ASSERT(false); }
351 +            static SYS_INLINE __m128i Process( XMM128 &pX, XMM128 &pY, XMM128 &pZ ) { STATIC_ASSERT(false); return __m128i(); }
352          };
353  
354          template <ConvFunc fn, PixelID pid, ProcID prc>
355 @@ -2177,7 +2177,7 @@
356              static FwStatus ConvertREF( const Fw8u *const pSrc[3], int srcStep, 
357                                           Fw8u *pDst[3],             int dstStep, FwiSize roiSize ) 
358              { 
359 -                STATIC_ASSERT(false); 
360 +                STATIC_ASSERT(false); return FwStatus();
361              }
362          };
363  
364 @@ -2222,7 +2222,7 @@
365              template <pixel_fn pfn>
366              static FwStatus ConvertREF( const Fw8u *pSrc, int srcStep, Fw8u *pDst[3], int dstStep, FwiSize roiSize ) 
367              { 
368 -                STATIC_ASSERT(false); 
369 +                STATIC_ASSERT(false); return FwStatus();
370              }
371          };
372  
373 @@ -2302,12 +2302,12 @@
374              static FwStatus ConvertREF( const Fw8u *const pSrc[3], int srcStep, 
375                                           Fw8u *pDst,                int dstStep, FwiSize roiSize ) 
376              { 
377 -                STATIC_ASSERT(false); 
378 +                STATIC_ASSERT(false); return FwStatus();
379              }
380              static FwStatus ConvertREF( const Fw8u *const pSrc[3], int srcStep[3], 
381                                           Fw8u *pDst,                int dstStep, FwiSize roiSize ) 
382              { 
383 -                STATIC_ASSERT(false); 
384 +                STATIC_ASSERT(false); return FwStatus();
385              }
386          };
387  
This page took 0.100818 seconds and 3 git commands to generate.