File: get_threading_model.c

package info (click to toggle)
openblas 0.3.29%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 62,984 kB
  • sloc: asm: 1,264,442; ansic: 412,266; fortran: 74,453; makefile: 13,665; sh: 4,892; perl: 4,468; python: 1,555; cpp: 244
file content (18 lines) | stat: -rw-r--r-- 391 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include "../cblas.h"

int main() {
	int th_model = openblas_get_parallel();
	switch(th_model) {
		case OPENBLAS_SEQUENTIAL:
			printf("OpenBLAS is compiled sequentially.\n");
			break;
		case OPENBLAS_THREAD:
			printf("OpenBLAS is compiled using the normal threading model\n");
			break;
		case OPENBLAS_OPENMP:
			printf("OpenBLAS is compiled using OpenMP\n");
			break;
	}
	return 0;
}