
water.init.MemoryBandwidth Maven / Gradle / Ivy
package water.init;
import water.util.ArrayUtils;
import water.util.Log;
import water.util.Timer;
public class MemoryBandwidth {
public static void main(String[] args) {
int num_threads = Runtime.getRuntime().availableProcessors();
double membw = run(num_threads);
Log.info("Memory bandwidth (" + num_threads + " cores) : " + membw + " GB/s.");
}
/**
* Compute memory bandwidth in bytes / second
*/
public static double run(int num_threads) {
final double membw[] = new double[num_threads];
Thread[] threads = new Thread[num_threads];
for (int t=0;t=0; --l) {
for (int i=0; i
© 2015 - 2025 Weber Informatics LLC | Privacy Policy