davs2-1.6-gcc8-fix.patch 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181
  1. From 00ef2c8062a7f7d7265d933676fb5cc60f1ea659 Mon Sep 17 00:00:00 2001
  2. From: Daniel Bermond <danielbermond@yahoo.com>
  3. Date: Tue, 20 Nov 2018 16:54:25 +0000
  4. Subject: [PATCH] Make AVX symbols to be strictly visible (fix build with gcc8)
  5. _mm256_insertf128_si256 and _mm256_castsi128_si256 are undeclared
  6. in the scope of source/common/vec/intrinsic.h, which seems to be
  7. strictly not permitted by gcc8.
  8. Fixes #9
  9. ---
  10. source/common/vec/intrinsic_deblock_avx2.cc | 5 ++---
  11. source/common/vec/intrinsic_idct_avx2.cc | 6 +++---
  12. source/common/vec/intrinsic_inter_pred.cc | 6 +++---
  13. source/common/vec/intrinsic_inter_pred_avx2.cc | 7 ++++---
  14. source/common/vec/intrinsic_intra-pred_avx2.cc | 6 +++---
  15. source/common/vec/intrinsic_pixel_avx.cc | 6 +++---
  16. source/common/vec/intrinsic_sao_avx2.cc | 6 +++---
  17. 7 files changed, 21 insertions(+), 21 deletions(-)
  18. diff --git a/source/common/vec/intrinsic_deblock_avx2.cc b/source/common/vec/intrinsic_deblock_avx2.cc
  19. index b87e472..ca9534e 100644
  20. --- a/source/common/vec/intrinsic_deblock_avx2.cc
  21. +++ b/source/common/vec/intrinsic_deblock_avx2.cc
  22. @@ -30,15 +30,14 @@
  23. * For more information, contact us at sswang @ pku.edu.cn.
  24. */
  25. -#include "../common.h"
  26. -#include "intrinsic.h"
  27. -
  28. #include <mmintrin.h>
  29. #include <emmintrin.h>
  30. #include <tmmintrin.h>
  31. #include <smmintrin.h>
  32. #include <immintrin.h>
  33. +#include "../common.h"
  34. +#include "intrinsic.h"
  35. #if !HIGH_BIT_DEPTH
  36. __m128i c_0_128;
  37. diff --git a/source/common/vec/intrinsic_idct_avx2.cc b/source/common/vec/intrinsic_idct_avx2.cc
  38. index 0b40fde..ee5384d 100644
  39. --- a/source/common/vec/intrinsic_idct_avx2.cc
  40. +++ b/source/common/vec/intrinsic_idct_avx2.cc
  41. @@ -30,15 +30,15 @@
  42. * For more information, contact us at sswang @ pku.edu.cn.
  43. */
  44. -#include "../common.h"
  45. -#include "intrinsic.h"
  46. -
  47. #include <mmintrin.h>
  48. #include <emmintrin.h>
  49. #include <tmmintrin.h>
  50. #include <smmintrin.h>
  51. #include <immintrin.h>
  52. +#include "../common.h"
  53. +#include "intrinsic.h"
  54. +
  55. /* disable warnings */
  56. #pragma warning(disable:4127) // warning C4127: 条件表达式是常量
  57. diff --git a/source/common/vec/intrinsic_inter_pred.cc b/source/common/vec/intrinsic_inter_pred.cc
  58. index 46c0da8..55ff6a0 100644
  59. --- a/source/common/vec/intrinsic_inter_pred.cc
  60. +++ b/source/common/vec/intrinsic_inter_pred.cc
  61. @@ -30,15 +30,15 @@
  62. * For more information, contact us at sswang @ pku.edu.cn.
  63. */
  64. -#include "../common.h"
  65. -#include "intrinsic.h"
  66. -
  67. #include <mmintrin.h>
  68. #include <emmintrin.h>
  69. #include <tmmintrin.h>
  70. #include <smmintrin.h>
  71. #include <immintrin.h>
  72. +#include "../common.h"
  73. +#include "intrinsic.h"
  74. +
  75. #if !HIGH_BIT_DEPTH
  76. /* ---------------------------------------------------------------------------
  77. */
  78. diff --git a/source/common/vec/intrinsic_inter_pred_avx2.cc b/source/common/vec/intrinsic_inter_pred_avx2.cc
  79. index 6f35771..05f6957 100644
  80. --- a/source/common/vec/intrinsic_inter_pred_avx2.cc
  81. +++ b/source/common/vec/intrinsic_inter_pred_avx2.cc
  82. @@ -30,14 +30,15 @@
  83. * For more information, contact us at sswang @ pku.edu.cn.
  84. */
  85. -#include "../common.h"
  86. -#include "intrinsic.h"
  87. -
  88. #include <mmintrin.h>
  89. #include <emmintrin.h>
  90. #include <tmmintrin.h>
  91. #include <smmintrin.h>
  92. #include <immintrin.h>
  93. +
  94. +#include "../common.h"
  95. +#include "intrinsic.h"
  96. +
  97. #pragma warning(disable:4127) // warning C4127: 条件表达式是常量
  98. #if !HIGH_BIT_DEPTH
  99. diff --git a/source/common/vec/intrinsic_intra-pred_avx2.cc b/source/common/vec/intrinsic_intra-pred_avx2.cc
  100. index 6440929..1357bdb 100644
  101. --- a/source/common/vec/intrinsic_intra-pred_avx2.cc
  102. +++ b/source/common/vec/intrinsic_intra-pred_avx2.cc
  103. @@ -30,15 +30,15 @@
  104. * For more information, contact us at sswang @ pku.edu.cn.
  105. */
  106. -#include "../common.h"
  107. -#include "intrinsic.h"
  108. -
  109. #include <mmintrin.h>
  110. #include <emmintrin.h>
  111. #include <tmmintrin.h>
  112. #include <smmintrin.h>
  113. #include <immintrin.h>
  114. +#include "../common.h"
  115. +#include "intrinsic.h"
  116. +
  117. #if !HIGH_BIT_DEPTH
  118. void intra_pred_ver_avx(pel_t *src, pel_t *dst, int i_dst, int dir_mode, int bsx, int bsy)
  119. diff --git a/source/common/vec/intrinsic_pixel_avx.cc b/source/common/vec/intrinsic_pixel_avx.cc
  120. index 813a36f..fba7e46 100644
  121. --- a/source/common/vec/intrinsic_pixel_avx.cc
  122. +++ b/source/common/vec/intrinsic_pixel_avx.cc
  123. @@ -30,15 +30,15 @@
  124. * For more information, contact us at sswang @ pku.edu.cn.
  125. */
  126. -#include "../common.h"
  127. -#include "intrinsic.h"
  128. -
  129. #include <mmintrin.h>
  130. #include <emmintrin.h>
  131. #include <tmmintrin.h>
  132. #include <smmintrin.h>
  133. #include <immintrin.h>
  134. +#include "../common.h"
  135. +#include "intrinsic.h"
  136. +
  137. /* ---------------------------------------------------------------------------
  138. */
  139. void *davs2_memzero_aligned_c_avx(void *dst, size_t n)
  140. diff --git a/source/common/vec/intrinsic_sao_avx2.cc b/source/common/vec/intrinsic_sao_avx2.cc
  141. index 11be4d3..bb0c4aa 100644
  142. --- a/source/common/vec/intrinsic_sao_avx2.cc
  143. +++ b/source/common/vec/intrinsic_sao_avx2.cc
  144. @@ -30,15 +30,15 @@
  145. * For more information, contact us at sswang @ pku.edu.cn.
  146. */
  147. -#include "../common.h"
  148. -#include "intrinsic.h"
  149. -
  150. #include <mmintrin.h>
  151. #include <emmintrin.h>
  152. #include <tmmintrin.h>
  153. #include <smmintrin.h>
  154. #include <immintrin.h>
  155. +#include "../common.h"
  156. +#include "intrinsic.h"
  157. +
  158. #if !HIGH_BIT_DEPTH
  159. #ifdef _MSC_VER
  160. #pragma warning(disable:4244) // TODO: 修正编译warning