python: Use the print function
In Python 2, `print` was a statement, but it became a function in Python 3. Using print functions everywhere makes the script compatible with Python versions >= 2.6, including Python 3. Signed-off-by: Mathieu Bridon <bochecha@daitauha.fr> Acked-by: Eric Engestrom <eric.engestrom@intel.com> Acked-by: Dylan Baker <dylan@pnwbakers.com>
This commit is contained in:

committed by
Dylan Baker

parent
b3a42fa066
commit
0f7b18fa0d
@@ -31,6 +31,8 @@
|
||||
# amplitude slightly. Apparently this also minimizes the error function,
|
||||
# reducing the maximum error from 0.00006 to about 0.00003.
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
import argparse
|
||||
import sys
|
||||
|
||||
@@ -51,9 +53,9 @@ def main():
|
||||
def run():
|
||||
import nir_algebraic # pylint: disable=import-error
|
||||
|
||||
print '#include "brw_nir.h"'
|
||||
print nir_algebraic.AlgebraicPass("brw_nir_apply_trig_workarounds",
|
||||
TRIG_WORKAROUNDS).render()
|
||||
print('#include "brw_nir.h"')
|
||||
print(nir_algebraic.AlgebraicPass("brw_nir_apply_trig_workarounds",
|
||||
TRIG_WORKAROUNDS).render())
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
Reference in New Issue
Block a user