diff options
author | Serge Guelton <sguelton@quarkslab.com> | 2019-01-03 14:11:33 +0000 |
---|---|---|
committer | Serge Guelton <sguelton@quarkslab.com> | 2019-01-03 14:11:33 +0000 |
commit | 4a27478a5b8bd9f13fef65e66b291a352c532371 (patch) | |
tree | a086542fe11fba6d8779ca2fa96036d80af04312 /llvm/test/CodeGen/SystemZ/Large/branch-range-02.py | |
parent | 41f98c834bc62a605ec51032482369cfa128d711 (diff) | |
download | bcm5719-llvm-4a27478a5b8bd9f13fef65e66b291a352c532371.tar.gz bcm5719-llvm-4a27478a5b8bd9f13fef65e66b291a352c532371.zip |
Python compat - print statement
Make sure all print statements are compatible with Python 2 and Python3 using
the `from __future__ import print_function` statement.
Differential Revision: https://reviews.llvm.org/D56249
llvm-svn: 350307
Diffstat (limited to 'llvm/test/CodeGen/SystemZ/Large/branch-range-02.py')
-rw-r--r-- | llvm/test/CodeGen/SystemZ/Large/branch-range-02.py | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py index 7f7b09954a6..4566d9746e8 100644 --- a/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py +++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py @@ -56,12 +56,14 @@ # CHECK: c %r4, 1036(%r3) # CHECK: jge [[LABEL]] +from __future__ import print_function + blocks = 256 + 4 -print 'define void @f1(i8 *%base, i32 *%stop, i32 %limit) {' -print 'entry:' -print ' br label %b0' -print '' +print('define void @f1(i8 *%base, i32 *%stop, i32 %limit) {') +print('entry:') +print(' br label %b0') +print('') a, b = 1, 1 for i in xrange(blocks): @@ -69,14 +71,14 @@ for i in xrange(blocks): value = a % 256 next = 'b%d' % (i + 1) if i + 1 < blocks else 'end' other = 'end' if 2 * i < blocks else 'b0' - print 'b%d:' % i - print ' store volatile i8 %d, i8 *%%base' % value - print ' %%astop%d = getelementptr i32, i32 *%%stop, i64 %d' % (i, i) - print ' %%acur%d = load i32 , i32 *%%astop%d' % (i, i) - print ' %%atest%d = icmp eq i32 %%limit, %%acur%d' % (i, i) - print ' br i1 %%atest%d, label %%%s, label %%%s' % (i, other, next) + print('b%d:' % i) + print(' store volatile i8 %d, i8 *%%base' % value) + print(' %%astop%d = getelementptr i32, i32 *%%stop, i64 %d' % (i, i)) + print(' %%acur%d = load i32 , i32 *%%astop%d' % (i, i)) + print(' %%atest%d = icmp eq i32 %%limit, %%acur%d' % (i, i)) + print(' br i1 %%atest%d, label %%%s, label %%%s' % (i, other, next)) -print '' -print '%s:' % next -print ' ret void' -print '}' +print('') +print('%s:' % next) +print(' ret void') +print('}') |