| 361 | |
| 362 | |
| 363 | void print_device_bdf(const std::vector<cl::Device>& devices) { |
| 364 | char device_bdf[20]; |
| 365 | cl_int err; |
| 366 | cl::Device device; |
| 367 | for (uint32_t i = 0; i < devices.size(); i++) { |
| 368 | OCL_CHECK(err, err = devices[i].getInfo(CL_DEVICE_PCIE_BDF, &device_bdf)); |
| 369 | std::cout << device_bdf << std::endl; |
| 370 | } |
| 371 | } |
| 372 | |
| 373 | int main(int argc, char* argv[]) { |
| 374 |