oneapi-src / oneapi-src/oneAPI-samples
OpenMP offload performance is worse than sequential CPU performance
还没有人认领这个 Issue。
- 主要语言
- C++
- 星标
- 1.2k
- 派生
- 745
- PR 合并指标
- 30 天内没有已合并 PR
描述
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.
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
从 openmp reduction sample 开始,使用报告中的 Ubuntu 和 Intel CPU 环境比较顺序 CPU、OpenMP CPU 和 OpenMP GPU 的执行路径。检查 README 以及当前对 num_steps 的处理;完成的标准是默认 sample 不会误导性地显示较差的 offload 性能,并且可调参数和性能背景都已记录。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- cpp
- 领域
- performance
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 35/100