Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix gcc warnings #426

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Fix gcc warnings #426

wants to merge 2 commits into from

Conversation

rouault
Copy link

@rouault rouault commented Jun 13, 2021

This fixes warnings that would otherwise be emitted by ``gcc -Wall test.c -c -Iinclude -mavx2 -O2 -mfma -ffp-contract=off" on the below test.c

#include <stdio.h>
#include <stdint.h>
#include <string.h>
#include <x86intrin.h>

#include <sleefinline_sse4.h>
#include <sleefinline_sse2.h>
#include <sleefinline_avx.h>
#include <sleefinline_avx2.h>
#include <sleefinline_avx2128.h>

Warnings emitted before this pull request:

In file included from test.c:6:
include/sleefinline_sse4.h:23: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas]
   23 | #pragma STDC FP_CONTRACT OFF
      | 
In file included from test.c:7:
include/sleefinline_sse2.h:23: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas]
   23 | #pragma STDC FP_CONTRACT OFF
      | 
In file included from test.c:8:
include/sleefinline_avx.h:23: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas]
   23 | #pragma STDC FP_CONTRACT OFF
      | 
In file included from test.c:9:
include/sleefinline_avx2.h:23: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas]
   23 | #pragma STDC FP_CONTRACT OFF
      | 
In file included from test.c:10:
include/sleefinline_avx2128.h:23: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas]
   23 | #pragma STDC FP_CONTRACT OFF
      | 
In file included from test.c:10:
include/sleefinline_avx2128.h:1452:13: warning: ‘vstoreu_v_p_vq’ defined but not used [-Wunused-function]
 1452 | static void vstoreu_v_p_vq(void *p, vquad_avx2128_sleef vq) {
      |             ^~~~~~~~~~~~~~
include/sleefinline_avx2128.h:1432:28: warning: ‘loadu_vq_p_avx2128_sleef’ defined but not used [-Wunused-function]
 1432 | static vquad_avx2128_sleef loadu_vq_p_avx2128_sleef(void *p) {
      |                            ^~~~~~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx2128.h:1170:13: warning: ‘vstoreu_v_p_vi_avx2128_sleef’ defined but not used [-Wunused-function]
 1170 | static void vstoreu_v_p_vi_avx2128_sleef(int32_t *p, vint_avx2128_sleef v) { _mm_storeu_si128((__m128i *)p, v); }
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx2128.h:1169:27: warning: ‘vloadu_vi_p_avx2128_sleef’ defined but not used [-Wunused-function]
 1169 | static vint_avx2128_sleef vloadu_vi_p_avx2128_sleef(int32_t *p) { return _mm_loadu_si128((__m128i *)p); }
      |                           ^~~~~~~~~~~~~~~~~~~~~~~~~
In file included from test.c:9:
include/sleefinline_avx2.h:1457:25: warning: ‘loadu_vq_p_avx2_sleef’ defined but not used [-Wunused-function]
 1457 | static vquad_avx2_sleef loadu_vq_p_avx2_sleef(void *p) {
      |                         ^~~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx2.h:1175:13: warning: ‘vstoreu_v_p_vi_avx2_sleef’ defined but not used [-Wunused-function]
 1175 | static void vstoreu_v_p_vi_avx2_sleef(int32_t *p, vint_avx2_sleef v) { _mm_storeu_si128((__m128i *)p, v); }
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx2.h:1174:24: warning: ‘vloadu_vi_p_avx2_sleef’ defined but not used [-Wunused-function]
 1174 | static vint_avx2_sleef vloadu_vi_p_avx2_sleef(int32_t *p) { return _mm_loadu_si128((__m128i *)p); }
      |                        ^~~~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx2.h:1173:13: warning: ‘vstoreu_v_p_vi2_avx2_sleef’ defined but not used [-Wunused-function]
 1173 | static void vstoreu_v_p_vi2_avx2_sleef(int32_t *p, vint2_avx2_sleef v) { _mm256_storeu_si256((__m256i *)p, v); }
      |             ^~~~~~~~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx2.h:1172:25: warning: ‘vloadu_vi2_p_avx2_sleef’ defined but not used [-Wunused-function]
 1172 | static vint2_avx2_sleef vloadu_vi2_p_avx2_sleef(int32_t *p) { return _mm256_loadu_si256((__m256i const *)p); }
      |                         ^~~~~~~~~~~~~~~~~~~~~~~
In file included from test.c:8:
include/sleefinline_avx.h:1546:24: warning: ‘loadu_vq_p_avx_sleef’ defined but not used [-Wunused-function]
 1546 | static vquad_avx_sleef loadu_vq_p_avx_sleef(void *p) {
      |                        ^~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx.h:1184:23: warning: ‘vloadu_vi_p_avx_sleef’ defined but not used [-Wunused-function]
 1184 | static vint_avx_sleef vloadu_vi_p_avx_sleef(int32_t *p) { return _mm_loadu_si128((__m128i *)p); }
      |                       ^~~~~~~~~~~~~~~~~~~~~
include/sleefinline_avx.h:1172:24: warning: ‘vloadu_vi2_p_avx_sleef’ defined but not used [-Wunused-function]
 1172 | static vint2_avx_sleef vloadu_vi2_p_avx_sleef(int32_t *p) {
      |                        ^~~~~~~~~~~~~~~~~~~~~~
In file included from test.c:7:
include/sleefinline_sse2.h:1447:25: warning: ‘loadu_vq_p_sse2_sleef’ defined but not used [-Wunused-function]
 1447 | static vquad_sse2_sleef loadu_vq_p_sse2_sleef(void *p) {
      |                         ^~~~~~~~~~~~~~~~~~~~~
include/sleefinline_sse2.h:1166:24: warning: ‘vloadu_vi_p_sse2_sleef’ defined but not used [-Wunused-function]
 1166 | static vint_sse2_sleef vloadu_vi_p_sse2_sleef(int32_t *p) { return _mm_loadu_si128((__m128i *)p); }
      |                        ^~~~~~~~~~~~~~~~~~~~~~
include/sleefinline_sse2.h:1163:25: warning: ‘vloadu_vi2_p_sse2_sleef’ defined but not used [-Wunused-function]
 1163 | static vint2_sse2_sleef vloadu_vi2_p_sse2_sleef(int32_t *p) { return _mm_loadu_si128((__m128i *)p); }
      |                         ^~~~~~~~~~~~~~~~~~~~~~~
In file included from test.c:6:
include/sleefinline_sse4.h:1437:25: warning: ‘loadu_vq_p_sse4_sleef’ defined but not used [-Wunused-function]
 1437 | static vquad_sse4_sleef loadu_vq_p_sse4_sleef(void *p) {
      |                         ^~~~~~~~~~~~~~~~~~~~~
include/sleefinline_sse4.h:1166:24: warning: ‘vloadu_vi_p_sse4_sleef’ defined but not used [-Wunused-function]
 1166 | static vint_sse4_sleef vloadu_vi_p_sse4_sleef(int32_t *p) { return _mm_loadu_si128((__m128i *)p); }
      |                        ^~~~~~~~~~~~~~~~~~~~~~
include/sleefinline_sse4.h:1163:25: warning: ‘vloadu_vi2_p_sse4_sleef’ defined but not used [-Wunused-function]
 1163 | static vint2_sse4_sleef vloadu_vi2_p_sse4_sleef(int32_t *p) { return _mm_loadu_si128((__m128i *)p); }
      |                         ^~~~~~~~~~~~~~~~~~~~~~~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants