oneapi-src / oneapi-src/oneAPI-samples

OpenMP offload performance is worse than sequential CPU performance

Đang mở
#756 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

bug
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

Mô tả

Summary

Provide a short summary of the issue. Sections below provide guidance on what
factors are considered important to reproduce an issue.
The time taken to complete calculation of pi using sequential CPU execution is better than OpenMP CPU and OpenMP GPU

Version

Report oneAPI Toolkit version and oneAPI Sample version or hash.
Samples commit id: 4bed52e76ceb17243a0bc4ce24e9aed52aaa6e49

Environment

Provide OS information and hardware information if applicable.
Ubuntu 20.04
11th Gen Intel(R) Core(TM) i7-1185GRE @ 2.80GHz

Steps to reproduce

Please check that the issue is reproducible with the latest revision on
master. Include all the steps to reproduce the issue.
build and run the openmp reduction sample.

Observed behavior

Document behavior you observe. For performance defects, like performance
regressions or a function being slow, provide a log if possible.
observe the time taken by each and notice that openmp offload performs the worst.

Expected behavior

Document behavior you expect.
OpenMP offload should perform better.

Verified Fix

Increase the number of steps by a factor of 100 and the time taken for each lines up according to expectations. OpenMP offload better than OpenMP CPU better than Seq CPU. We do not want developers to be presented with a poorly performing offload to begin with. The alternative is mention this in the README or perhaps do both. Increase num_steps and add some detail to the README. It will also be good to add the num_steps as a tunable parameter with a default value so developer can play with it.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu với openmp reduction sample và so sánh các đường dẫn thực thi CPU tuần tự, CPU OpenMP và GPU OpenMP bằng môi trường Ubuntu và CPU Intel đã được báo cáo. Xem xét README và cách xử lý num_steps hiện tại; công việc được xem là hoàn tất khi sample mặc định không hiển thị một cách gây hiểu lầm rằng hiệu năng offload kém, đồng thời tham số có thể điều chỉnh và bối cảnh hiệu năng được ghi chép.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
cpp
Lĩnh vực
performance
Loại issue
Lỗi
Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.