'vgg-16', 'vgg-19', 'densenet-121', 'inception_v3',
'mobilenet', 'squeezenet_v1.0', 'squeezenet_v1.1'],
help='The name of neural network')
+ parser.add_argument("--device", type=str,
+ choices=['amd_apu'], default='amd_apu',
+ help="The name of the test device. If your device is not listed in "
+ "the choices list, pick the most similar one as argument.")
parser.add_argument("--model", type=str,
- choices=['1080ti', 'titanx', 'tx2', 'gfx900'], default='1080ti',
+ choices=['1080ti', 'titanx', 'tx2', 'gfx900', 'v1000'], default='1080ti',
help="The model of the test device. If your device is not listed in "
"the choices list, pick the most similar one as argument.")
parser.add_argument("--repeat", type=int, default=600)
parser.add_argument("--target", type=str,
- choices=['cuda', 'opencl', 'rocm', 'nvptx', 'metal'], default='cuda',
+ choices=['cuda', 'opencl', 'rocm', 'nvptx', 'metal', 'vulkan'], default='cuda',
help="The tvm compilation target")
parser.add_argument("--thread", type=int, default=1, help="The number of threads to be run.")
args = parser.parse_args()
else:
networks = [args.network]
- target = tvm.target.create('%s -model=%s' % (args.target, args.model))
+ target = tvm.target.create('%s -device=%s -model=%s' % (args.target, args.device, args.model))
print("--------------------------------------------------")
print("%-20s %-20s" % ("Network Name", "Mean Inference Time (std dev)"))
case kMaxThreadsPerBlock: {
VkPhysicalDeviceProperties phy_prop;
vkGetPhysicalDeviceProperties(vctx.phy_device, &phy_prop);
- int64_t value = phy_prop.limits.maxComputeWorkGroupSize[0];
+ int64_t value = phy_prop.limits.maxComputeWorkGroupInvocations;
*rv = value;
break;
}
return;
case kExist:
break;
- case kMaxThreadDimensions:
+ case kMaxThreadDimensions: {
+ VkPhysicalDeviceProperties phy_prop;
+ vkGetPhysicalDeviceProperties(vctx.phy_device, &phy_prop);
+ int64_t dims[3];
+ dims[0] = phy_prop.limits.maxComputeWorkGroupSize[0];
+ dims[1] = phy_prop.limits.maxComputeWorkGroupSize[1];
+ dims[2] = phy_prop.limits.maxComputeWorkGroupSize[2];
+ std::stringstream ss; // use json string to return multiple int values;
+ ss << "[" << dims[0] << ", " << dims[1] << ", " << dims[2] << "]";
+ *rv = ss.str();
break;
+ }
case kGcnArch:
return;
}