From da563edb8db98e9dd0ba2576f924e1415d7702fe Mon Sep 17 00:00:00 2001
From: Mathieu Faverge <mathieu.faverge@inria.fr>
Date: Tue, 11 Jul 2023 15:10:25 +0200
Subject: [PATCH] openmp/codelets: add missing gerst/gered kernels

---
 runtime/openmp/codelets/codelet_zgered.c   | 34 ++++++++++++++++++++++
 runtime/openmp/codelets/codelet_zgerst.c   | 32 ++++++++++++++++++++
 runtime/openmp/codelets/codelet_zgersum.c  |  2 +-
 runtime/openmp/control/runtime_async.c     |  2 +-
 runtime/openmp/control/runtime_context.c   |  2 +-
 runtime/openmp/control/runtime_control.c   |  2 +-
 runtime/openmp/control/runtime_options.c   |  2 +-
 runtime/openmp/control/runtime_profiling.c |  2 +-
 8 files changed, 72 insertions(+), 6 deletions(-)
 create mode 100644 runtime/openmp/codelets/codelet_zgered.c
 create mode 100644 runtime/openmp/codelets/codelet_zgerst.c

diff --git a/runtime/openmp/codelets/codelet_zgered.c b/runtime/openmp/codelets/codelet_zgered.c
new file mode 100644
index 000000000..4ccc67ba8
--- /dev/null
+++ b/runtime/openmp/codelets/codelet_zgered.c
@@ -0,0 +1,34 @@
+/**
+ *
+ * @file openmp/codelet_zgered.c
+ *
+ * @copyright 2023-2023 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria,
+ *                      Univ. Bordeaux. All rights reserved.
+ *
+ ***
+ *
+ * @brief Chameleon zgered OpenMP codelet
+ *
+ * @version 1.3.0
+ * @author Mathieu Faverge
+ * @date 2023-07-06
+ * @precisions normal z -> d
+ *
+ */
+#include "chameleon_openmp.h"
+
+void INSERT_TASK_zgered( const RUNTIME_option_t *options,
+                         double threshold, double Anorm, int m, int n,
+                         const CHAM_desc_t *A, int Am, int An )
+{
+    fprintf( stderr, "WARNING: gered kernel is not available with OpenMP\n" );
+
+    (void)options;
+    (void)threshold;
+    (void)Anorm;
+    (void)m;
+    (void)n;
+    (void)A;
+    (void)Am;
+    (void)An;
+}
diff --git a/runtime/openmp/codelets/codelet_zgerst.c b/runtime/openmp/codelets/codelet_zgerst.c
new file mode 100644
index 000000000..97a9d6571
--- /dev/null
+++ b/runtime/openmp/codelets/codelet_zgerst.c
@@ -0,0 +1,32 @@
+/**
+ *
+ * @file openmp/codelet_zgerst.c
+ *
+ * @copyright 2023-2023 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria,
+ *                      Univ. Bordeaux. All rights reserved.
+ *
+ ***
+ *
+ * @brief Chameleon zgerst OpenMP codelet
+ *
+ * @version 1.3.0
+ * @author Mathieu Faverge
+ * @date 2023-07-06
+ * @precisions normal z -> d
+ *
+ */
+#include "chameleon_openmp.h"
+
+void INSERT_TASK_zgerst( const RUNTIME_option_t *options,
+                         int m, int n,
+                         const CHAM_desc_t *A, int Am, int An )
+{
+    fprintf( stderr, "WARNING: gerst kernel is not available with OpenMP\n" );
+
+    (void)options;
+    (void)m;
+    (void)n;
+    (void)A;
+    (void)Am;
+    (void)An;
+}
diff --git a/runtime/openmp/codelets/codelet_zgersum.c b/runtime/openmp/codelets/codelet_zgersum.c
index 3ce42080a..83c479a39 100644
--- a/runtime/openmp/codelets/codelet_zgersum.c
+++ b/runtime/openmp/codelets/codelet_zgersum.c
@@ -1,6 +1,6 @@
 /**
  *
- * @file starpu/codelet_zgersum.c
+ * @file openmp/codelet_zgersum.c
  *
  * @copyright 2009-2014 The University of Tennessee and The University of
  *                      Tennessee Research Foundation. All rights reserved.
diff --git a/runtime/openmp/control/runtime_async.c b/runtime/openmp/control/runtime_async.c
index 64cccaa4b..764612d4b 100644
--- a/runtime/openmp/control/runtime_async.c
+++ b/runtime/openmp/control/runtime_async.c
@@ -9,7 +9,7 @@
  *
  ***
  *
- * @brief Chameleon StarPU asynchronous routines
+ * @brief Chameleon OpenMP asynchronous routines
  *
  * @version 1.2.0
  * @author Mathieu Faverge
diff --git a/runtime/openmp/control/runtime_context.c b/runtime/openmp/control/runtime_context.c
index 05743743c..5a1a1f917 100644
--- a/runtime/openmp/control/runtime_context.c
+++ b/runtime/openmp/control/runtime_context.c
@@ -9,7 +9,7 @@
  *
  ***
  *
- * @brief Chameleon StarPU context routines
+ * @brief Chameleon OpenMP context routines
  *
  * @version 1.2.0
  * @author Cedric Augonnet
diff --git a/runtime/openmp/control/runtime_control.c b/runtime/openmp/control/runtime_control.c
index 08830268f..8aa704f33 100644
--- a/runtime/openmp/control/runtime_control.c
+++ b/runtime/openmp/control/runtime_control.c
@@ -9,7 +9,7 @@
  *
  ***
  *
- * @brief Chameleon StarPU control routines
+ * @brief Chameleon OpenMP control routines
  *
  * @version 1.2.0
  * @author Mathieu Faverge
diff --git a/runtime/openmp/control/runtime_options.c b/runtime/openmp/control/runtime_options.c
index 3c10e5801..3f52b6933 100644
--- a/runtime/openmp/control/runtime_options.c
+++ b/runtime/openmp/control/runtime_options.c
@@ -9,7 +9,7 @@
  *
  ***
  *
- * @brief Chameleon StarPU options routines
+ * @brief Chameleon OpenMP options routines
  *
  * @version 1.2.0
  * @author Cedric Augonnet
diff --git a/runtime/openmp/control/runtime_profiling.c b/runtime/openmp/control/runtime_profiling.c
index e1c15de64..f632fbe9c 100644
--- a/runtime/openmp/control/runtime_profiling.c
+++ b/runtime/openmp/control/runtime_profiling.c
@@ -9,7 +9,7 @@
  *
  ***
  *
- * @brief Chameleon StarPU profiling routines
+ * @brief Chameleon OpenMP profiling routines
  *
  * @version 1.2.0
  * @author Cedric Augonnet
-- 
GitLab