Skip to content

Commit 3afceb6

Browse files
committed
disable NaN checks before BLAS calls deig.R
1 parent 7af8b21 commit 3afceb6

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

benchmark/scripts/R/deig.R

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
argv <- commandArgs(trailingOnly = TRUE)
44

5+
if (!is.null(options("matprod")[[1]])) options(matprod = "blas")
6+
57
nfrom <- 128
68
nto <- 2048
79
nstep <- 128
@@ -19,22 +21,14 @@ if (length(argv) > 0) {
1921
loops <- as.numeric(argv[z])
2022
}
2123
}
22-
2324
}
2425

2526
p <- Sys.getenv("OPENBLAS_LOOPS")
2627
if (p != "") {
2728
loops <- as.numeric(p)
2829
}
2930

30-
31-
cat(sprintf(
32-
"From %.0f To %.0f Step=%.0f Loops=%.0f\n",
33-
nfrom,
34-
nto,
35-
nstep,
36-
loops
37-
))
31+
cat(sprintf("From %.0f To %.0f Step=%.0f Loops=%.0f\n", nfrom, nto, nstep, loops))
3832
cat(sprintf(" SIZE Flops Time\n"))
3933

4034
n <- nfrom
@@ -45,11 +39,10 @@ while (n <= nto) {
4539
ev <- eigen(A)
4640
})
4741

48-
mflops <- (26.66 * n * n * n) * loops / (z[3] * 1.0e6)
42+
mflops <- (26.66 * n * n * n) * loops / (z[3] * 1e+06)
4943

5044
st <- sprintf("%.0fx%.0f :", n, n)
5145
cat(sprintf("%20s %10.2f MFlops %10.6f sec\n", st, mflops, z[3]))
5246

5347
n <- n + nstep
54-
5548
}

0 commit comments

Comments
 (0)