Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Christoph Alt
pystencils
Commits
7e6be86e
Commit
7e6be86e
authored
May 06, 2021
by
Michael Kuron
Browse files
Add ARM SVE CI job
parent
5cf6febc
Changes
3
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
7e6be86e
...
...
@@ -151,12 +151,11 @@ ubuntu:
cobertura
:
coverage.xml
junit
:
report.xml
arm64
:
arm64
v8
:
extends
:
.multiarch_template
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/arm64
variables
:
PYSTENCILS_SIMD
:
"
neon"
QEMU_CPU
:
"
cortex-a72"
before_script
:
-
*multiarch_before_script
-
sed -i s/march=native/march=armv8-a/g ~/.config/pystencils/config.json
...
...
@@ -170,6 +169,23 @@ ppc64le:
-
*multiarch_before_script
-
sed -i s/mcpu=native/mcpu=power8/g ~/.config/pystencils/config.json
arm64v9
:
# Compiler support for SVE is still pretty rough: GCC 10+11 produce incorrect code for fixed-width vectors,
# while Clang 12 produces memory-corrupting heisenbugs unless we enable the address sanitizer.
# In the RNG tests, GCC 10+11 produce an internal compiler error.
# The memory corruption seems to only happen with qemu-user, not with qemu-system.
# Once the compilers and QEMU have improved, this job should be cleaned up to match the others.
extends
:
.multiarch_template
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/arm64
variables
:
PYSTENCILS_SIMD
:
"
sve256,sve512"
ASAN_OPTIONS
:
detect_leaks=0
LD_PRELOAD
:
/usr/lib/aarch64-linux-gnu/libasan.so.6
before_script
:
-
*multiarch_before_script
-
sed -i s/march=native/march=armv8-a+sve/g ~/.config/pystencils/config.json
-
sed -i s/g\+\+/clang++/g ~/.config/pystencils/config.json
minimal-conda
:
stage
:
test
except
:
...
...
pystencils/cpu/vectorization.py
View file @
7e6be86e
...
...
@@ -69,6 +69,9 @@ class CachelineSize(ast.Node):
def
__eq__
(
self
,
other
):
return
isinstance
(
other
,
CachelineSize
)
def
__hash__
(
self
):
return
hash
(
self
.
symbol
)
def
vectorize
(
kernel_ast
:
ast
.
KernelFunction
,
instruction_set
:
str
=
'best'
,
assume_aligned
:
bool
=
False
,
nontemporal
:
Union
[
bool
,
Container
[
Union
[
str
,
Field
]]]
=
False
,
...
...
pystencils_tests/test_vectorization_specific.py
View file @
7e6be86e
...
...
@@ -117,7 +117,7 @@ def test_cacheline_size(instruction_set):
# test_vectorization is not parametrized because it is supposed to run without pytest, so we parametrize it here
from
pystencils_tests
import
test_vectorization
@
pytest
.
mark
.
parametrize
(
'instruction_set'
,
set
(
supported_instruction_sets
)
-
set
([
test_vectorization
.
instruction_set
]))
@
pytest
.
mark
.
parametrize
(
'instruction_set'
,
sorted
(
set
(
supported_instruction_sets
)
-
set
([
test_vectorization
.
instruction_set
]))
)
@
pytest
.
mark
.
parametrize
(
'function'
,
[
f
for
f
in
test_vectorization
.
__dict__
if
f
.
startswith
(
'test_'
)
and
f
!=
'test_hardware_query'
])
def
test_vectorization_other
(
instruction_set
,
function
):
test_vectorization
.
__dict__
[
function
](
instruction_set
)
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