@Override public int getClockFrequency() { return device.getMaxClockFrequency(); }
for (CLDevice device : platform.listCLDevices()) { if (device.getType() == CLDevice.Type.GPU) { int flops = device.getMaxComputeUnits() * device.getMaxClockFrequency(); ConsoleMessages.Info.Opencl.FOUND_DEVICE.log( device, flops int flops = device.getMaxComputeUnits() * device.getMaxClockFrequency(); ConsoleMessages.Info.Opencl.FOUND_DEVICE.log(device, flops); if (flops > maxCpuFlops) {
static CLDevice findMaxFlopsDevice(final CLDevice[] devices, final CLDevice.Type type) { initialize(); CLDevice maxFLOPSDevice = null; int maxflops = -1; for (int i = 0; i < devices.length; i++) { final CLDevice device = devices[i]; if(type == null || type.equals(device.getType())) { final int maxComputeUnits = device.getMaxComputeUnits(); final int maxClockFrequency = device.getMaxClockFrequency(); final int flops = maxComputeUnits*maxClockFrequency; if(flops > maxflops) { maxflops = flops; maxFLOPSDevice = device; } } } return maxFLOPSDevice; }