From 0a9840593785d337145aaaa8d2cd19fc4b0033b7 Mon Sep 17 00:00:00 2001 From: Ouadie EL FAROUKI Date: Mon, 8 Jan 2024 10:59:54 +0000 Subject: [PATCH] Additional changes/deletions of py_gen related files and documentation --- benchmark/gen_param.py | 4 +++- doc/AddingBlas3Op.md | 5 +++-- python_generator/py_gen_blas_binary.py | 0 python_generator/py_gen_blas_binary_special.py | 0 python_generator/py_gen_blas_gemm_launcher.py | 2 +- python_generator/py_gen_blas_ops.py | 2 +- python_generator/py_gen_blas_reduction.py | 2 +- python_generator/py_gen_blas_rotg_return.py | 0 python_generator/py_gen_blas_rotmg.py | 0 python_generator/py_gen_blas_ternary.py | 0 10 files changed, 9 insertions(+), 6 deletions(-) delete mode 100644 python_generator/py_gen_blas_binary.py delete mode 100644 python_generator/py_gen_blas_binary_special.py delete mode 100644 python_generator/py_gen_blas_rotg_return.py delete mode 100644 python_generator/py_gen_blas_rotmg.py delete mode 100644 python_generator/py_gen_blas_ternary.py diff --git a/benchmark/gen_param.py b/benchmark/gen_param.py index a8d4019bc..aaa6ebafa 100644 --- a/benchmark/gen_param.py +++ b/benchmark/gen_param.py @@ -1,5 +1,5 @@ #!/usr/bin/env python3 -#/*************************************************************************** +# /*************************************************************************** # * # * @license # * Copyright (C) Codeplay Software Limited @@ -32,12 +32,14 @@ import itertools import argparse + def main(args): """Generate the csv file according to the given arguments """ # Match DSL to Python names nd_range = itertools.product value_range = lambda *v: list(v) + def size_range(low, high, mult): val = low while val <= high: diff --git a/doc/AddingBlas3Op.md b/doc/AddingBlas3Op.md index 9791d3f24..147817025 100644 --- a/doc/AddingBlas3Op.md +++ b/doc/AddingBlas3Op.md @@ -178,8 +178,9 @@ binary is linked against portBLAS, the linker will find the definition of the mi To do this, we create the source file that will contain instantiations of the new `_trsm` operation. The file is located at `src/interface/blas3/trsm.cpp.in`. This is not the file that will be -compiled, but a template file that the python script `python_generator/py_gen_blas_binary.py` -will use to generate the actual source file where the instantiation of `_trsm` will happen. +compiled, but a template file that the python script `python_generator/py_gen_blas_ops.py` +will use to generate the actual source file where the instantiation of `_trsm` will happen. The call +to this generator is wrapped within the cmake function `generate_blas_objects`. The file `src/interface/blas3/trsm.cpp.in` must include all files that are necessary to successfully compile `blas::internal::_trsm`, for this particular example, this file looks like the following: diff --git a/python_generator/py_gen_blas_binary.py b/python_generator/py_gen_blas_binary.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python_generator/py_gen_blas_binary_special.py b/python_generator/py_gen_blas_binary_special.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python_generator/py_gen_blas_gemm_launcher.py b/python_generator/py_gen_blas_gemm_launcher.py index c34ab3849..3c4fb6a7e 100644 --- a/python_generator/py_gen_blas_gemm_launcher.py +++ b/python_generator/py_gen_blas_gemm_launcher.py @@ -1,4 +1,4 @@ -#/*************************************************************************** +# /*************************************************************************** # * # * @license # * Copyright (C) Codeplay Software Limited diff --git a/python_generator/py_gen_blas_ops.py b/python_generator/py_gen_blas_ops.py index 68f53eaac..b72c05c07 100644 --- a/python_generator/py_gen_blas_ops.py +++ b/python_generator/py_gen_blas_ops.py @@ -1,4 +1,4 @@ -#/*************************************************************************** +# /*************************************************************************** # * # * @license # * Copyright (C) Codeplay Software Limited diff --git a/python_generator/py_gen_blas_reduction.py b/python_generator/py_gen_blas_reduction.py index 5a80ee10d..be45e5884 100644 --- a/python_generator/py_gen_blas_reduction.py +++ b/python_generator/py_gen_blas_reduction.py @@ -1,4 +1,4 @@ -#/*************************************************************************** +# /*************************************************************************** # * # * @license # * Copyright (C) Codeplay Software Limited diff --git a/python_generator/py_gen_blas_rotg_return.py b/python_generator/py_gen_blas_rotg_return.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python_generator/py_gen_blas_rotmg.py b/python_generator/py_gen_blas_rotmg.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python_generator/py_gen_blas_ternary.py b/python_generator/py_gen_blas_ternary.py deleted file mode 100644 index e69de29bb..000000000