Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zzha zzha
OpenXG-RAN
Commits
31b51b28
Commit
31b51b28
authored
Oct 11, 2022
by
Bruno Mongazon-Cazavet
Committed by
Robert Schmidt
Oct 18, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix build on centos 7 and centos 8, fix non-avx2 host support using simde
parent
3bc86d69
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
11 deletions
+13
-11
CMakeLists.txt
CMakeLists.txt
+4
-2
cmake_targets/tools/build_helper
cmake_targets/tools/build_helper
+1
-1
sdr/ETHERNET/USERSPACE/LIB/eth_udp.c
sdr/ETHERNET/USERSPACE/LIB/eth_udp.c
+8
-8
No files found.
CMakeLists.txt
View file @
31b51b28
...
...
@@ -204,10 +204,12 @@ if(EXISTS "/proc/cpuinfo")
file
(
STRINGS
"/proc/cpuinfo"
CPUINFO REGEX flags LIMIT_COUNT 1
)
message
(
"AVX512 is
${
AVX512
}
"
)
message
(
"AVX2 is
${
AVX2
}
"
)
# The following intrinsics are assumed to be available on any x86 system used to build the software (avx, f16c, fma, gnfi, mmx, pclmul, sse, sse2, sse3, xop)
set
(
C_FLAGS_PROCESSOR
"
${
C_FLAGS_PROCESSOR
}
-DSIMDE_X86_AVX_NATIVE -DSIMDE_X86_AVX_NATIVE -DSIMDE_X86_F16C_NATIVE -DSIMDE_X86_FMA_NATIVE -DSIMDE_X86_GFNI_NATIVE -DSIMDE_X86_MMX_NATIVE -DSIMDE_X86_PCLMUL_NATIVE -DSIMDE_X86_SSE2_NATIVE -DSIMDE_X86_SSE3_NATIVE -DSIMDE_X86_SSE_NATIVE -DSIMDE_X86_XOP_HAVE_COM_ -DSIMDE_X86_XOP_NATIVE"
)
if
(
"
${
AVX512
}
"
STREQUAL
"False"
)
set
(
C_FLAGS_PROCESSOR
"
${
C_FLAGS_PROCESSOR
}
-mno-avx512f -march=native
-DSIMDE_X86_AVX2_NATIVE -DSIMDE_X86_AVX2_NATIVE -DSIMDE_X86_AVX512BW_NATIVE -DSIMDE_X86_AVX512F_NATIVE -DSIMDE_X86_AVX512VL_NATIVE -DSIMDE_X86_AVX_NATIVE -DSIMDE_X86_AVX_NATIVE -DSIMDE_X86_F16C_NATIVE -DSIMDE_X86_FMA_NATIVE -DSIMDE_X86_GFNI_NATIVE -DSIMDE_X86_MMX_NATIVE -DSIMDE_X86_PCLMUL_NATIVE -DSIMDE_X86_SSE2_NATIVE -DSIMDE_X86_SSE3_NATIVE -DSIMDE_X86_SSE4_1_NATIVE -DSIMDE_X86_SSE4_2_NATIVE -DSIMDE_X86_SSE_NATIVE -DSIMDE_X86_SSSE3_NATIVE -DSIMDE_X86_VPCLMULQDQ_NATIVE -DSIMDE_X86_XOP_HAVE_COM_ -DSIMDE_X86_XOP_NATIVE
"
)
set
(
C_FLAGS_PROCESSOR
"
${
C_FLAGS_PROCESSOR
}
-mno-avx512f -march=native"
)
else
()
set
(
C_FLAGS_PROCESSOR
"
${
C_FLAGS_PROCESSOR
}
-mavx512bw -march=skylake-avx512 -mtune=skylake-avx512"
)
set
(
C_FLAGS_PROCESSOR
"
${
C_FLAGS_PROCESSOR
}
-
DSIMDE_X86_AVX512BW_NATIVE -DSIMDE_X86_AVX512F_NATIVE -DSIMDE_X86_AVX512VL_NATIVE -
mavx512bw -march=skylake-avx512 -mtune=skylake-avx512"
)
endif
()
if
(
CPUINFO MATCHES
"avx2"
AND
"
${
AVX2
}
"
STREQUAL
"True"
)
set
(
C_FLAGS_PROCESSOR
"
${
C_FLAGS_PROCESSOR
}
-DSIMDE_X86_AVX2_NATIVE -DSIMDE_X86_VPCLMULQDQ_NATIVE"
)
...
...
cmake_targets/tools/build_helper
View file @
31b51b28
...
...
@@ -33,7 +33,7 @@ OS_RELEASE=$(grep "^VERSION_ID=" /etc/os-release | sed "s/VERSION_ID=//" | sed "
case "$OS_DISTRO" in
fedora) OS_BASEDISTRO="fedora"; INSTALLER="dnf"; CMAKE="cmake" ;;
rhel) OS_BASEDISTRO="fedora"; INSTALLER="yum --skip-broken"; CMAKE="cmake3" ;;
centos) OS_BASEDISTRO="
fedora
"; INSTALLER="yum --skip-broken"; CMAKE="cmake3" ;;
centos) OS_BASEDISTRO="
centos
"; INSTALLER="yum --skip-broken"; CMAKE="cmake3" ;;
debian) OS_BASEDISTRO="debian"; INSTALLER="apt-get"; CMAKE="cmake" ;;
ubuntu) OS_BASEDISTRO="debian"; INSTALLER="apt-get"; CMAKE="cmake" ;;
esac
...
...
sdr/ETHERNET/USERSPACE/LIB/eth_udp.c
View file @
31b51b28
...
...
@@ -359,14 +359,14 @@ void *trx_eth_write_udp_cmd(udpTXelem_t *udpTXelem) {
#if defined(__x86_64__) || defined(__i386__)
__m256i
*
buff256
=
(
__m256i
*
)
&
(((
int32_t
*
)
buff
[
aid
])[
offset
]);
for
(
int
j
=
0
;
j
<
32
;
j
+=
8
)
{
buff_tx
[
1
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
],
4
);
buff_tx
[
2
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
+
1
],
4
);
buff_tx
[
3
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
+
2
],
4
);
buff_tx
[
4
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
+
3
],
4
);
buff_tx
[
5
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
+
4
],
4
);
buff_tx
[
6
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
+
5
],
4
);
buff_tx
[
7
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
+
6
],
4
);
buff_tx
[
8
+
j
]
=
_mm256_slli_epi16
(
buff256
[
j
+
7
],
4
);
buff_tx
[
1
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
],
4
);
buff_tx
[
2
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
+
1
],
4
);
buff_tx
[
3
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
+
2
],
4
);
buff_tx
[
4
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
+
3
],
4
);
buff_tx
[
5
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
+
4
],
4
);
buff_tx
[
6
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
+
5
],
4
);
buff_tx
[
7
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
+
6
],
4
);
buff_tx
[
8
+
j
]
=
simde
_mm256_slli_epi16
(
buff256
[
j
+
7
],
4
);
}
#elif defined(__arm__)
int16x8_t
*
buff128
=
(
__int16x8_t
*
)
&
buff
[
aid
][
offset
];
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment