printf question
@xmnboy đang làm issue này rồi.
Từ ngày 29/10/2021.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
It is not clear why printf is not supported in DPC++. printf is supported in DPC++ with CUDA support.
Addressing Warnings in Migrated Code
Migration generated one warning for code that dpct could not migrate:
warning: DPCT1015:0: Output needs adjustment.
As you have noticed, the migration of this project resulted in one DPCT message that needs to be addressed, DPCT1015. This message is shown because as the Compatibility Tool migrated from the printf-style formatted string in the CUDA code to the output stream supported by DPC++, manual adjustment is needed to generate the equivalent output.
Open result/foo/bar/util.dp.cpp and locate the error DPCT1015. Then make the following changes:
Change:
stream_ct1 << "kernel_util,%d\n";
to
stream_ct1 << "kernel_util," << c << sycl::endl;
You’ll also need to change the stream statement in result/foo/main.dp.cpp.
Change:
stream_ct1 << z"kernel_main!\n";
to
stream_ct1 << "kernel_main!" << sycl::endl;
- Ngôn ngữ chính
- C++
- Star
- 1.2k
- Fork
- 745
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của oneapi-src/oneAPI-samples
-
bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 45/100
oneapi-src/oneAPI-samples#2764 ·
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
oneapi-src/oneAPI-samples#2748 ·
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 10/100
oneapi-src/oneAPI-samples#2746 ·
-
Lenovo Thinkpad T440p Ethernet issue warning sign show install multiple times but same issue face Đang mởquestion
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 15/100
oneapi-src/oneAPI-samples#2739 ·
-
bug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 35/100
oneapi-src/oneAPI-samples#2705 ·
Tất cả issue của oneapi-src/oneAPI-samples
Issue tương tự
-
Website Doc Typo Đang mở
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 92/100
-
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 92/100
autowarefoundation/autoware_universe#13413 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
-
automated-analysis bug memory-safety
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100