Author: Richard Plangger <[email protected]>
Branch: z196-support
Changeset: r84405:12f1e1b9d5e6
Date: 2016-05-12 17:56 +0200
http://bitbucket.org/pypy/pypy/changeset/12f1e1b9d5e6/

Log:    CFLAGS can be used to overwrite -march=(z10|z196|zEC12), default is
        now z10

diff --git a/rpython/doc/arch/s390x.rst b/rpython/doc/arch/s390x.rst
--- a/rpython/doc/arch/s390x.rst
+++ b/rpython/doc/arch/s390x.rst
@@ -9,6 +9,8 @@
 Currently supported ISAs:
 
 * zEC12 (released September 2012)
+* z196 (released August 2010)
+* z10 (released February 2008)
 
 To check if all the necessary CPU facilities are installed
 on the subject machine, please run the test using a copy of the pypy
diff --git a/rpython/translator/platform/linux.py 
b/rpython/translator/platform/linux.py
--- a/rpython/translator/platform/linux.py
+++ b/rpython/translator/platform/linux.py
@@ -23,7 +23,15 @@
 
     if platform.machine() == 's390x':
         # force the right target arch for s390x
-        cflags = ('-march=z196','-m64','-mzarch') + cflags
+        for cflag in cflags:
+            if cflag.startswith('-march='):
+                break
+        else:
+            # the default cpu architecture that is supported
+            # older versions are not supported
+            cflags += ('-march=z10',)
+        cflags += ('-m64','-mzarch')
+
 
     def _args_for_shared(self, args):
         return ['-shared'] + args
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to