Define the affinity for riscv64
authorLLVM Packaging Team <pkg-llvm-team@lists.alioth.debian.org>
Mon, 16 Oct 2023 13:14:10 +0000 (13:14 +0000)
committerAndres Salomon <dilinger@debian.org>
Mon, 16 Oct 2023 13:14:10 +0000 (13:14 +0000)
Last-Update: 2021-08-27

Gbp-Pq: Name omp-riscv64.patch

openmp/runtime/src/kmp_affinity.h

index e685e2cee7a2d7cba738581ea574229293d4a8ba..0a307488637dcd1dfc78a82581238791f667df9f 100644 (file)
@@ -212,6 +212,17 @@ public:
 #elif __NR_sched_getaffinity != 123
 #error Wrong code for getaffinity system call.
 #endif /* __NR_sched_getaffinity */
+#elif KMP_ARCH_RISCV64
+#ifndef __NR_sched_setaffinity
+#define __NR_sched_setaffinity 122
+#elif __NR_sched_setaffinity != 122
+#error Wrong code for setaffinity system call.
+#endif /* __NR_sched_setaffinity */
+#ifndef __NR_sched_getaffinity
+#define __NR_sched_getaffinity 123
+#elif __NR_sched_getaffinity != 123
+#error Wrong code for getaffinity system call.
+#endif /* __NR_sched_getaffinity */
 #elif KMP_ARCH_X86_64
 #ifndef __NR_sched_setaffinity
 #define __NR_sched_setaffinity 203