-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pathfinder SYCL and numba-dpex implementation. #303
Conversation
08452c3
to
b75b8cf
Compare
cols=10 | ||
pyramid_height=1 | ||
|
||
[benchmark.parameters.M16Gb] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one should be almost the same as M, but memory should fit in 16Gb. You can refer how much memory was used in report. If memory is not a bottle neck, then it should be the same as M
dpbench/console/run.py
Outdated
parser.add_argument( | ||
"--rodinia", | ||
action=argparse.BooleanOptionalAction, | ||
default=False, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess, we can include rodinia benchmarks to be executed by default. @diptorupd , what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was thinking about it, and I guess it is better leave it disabled for now. In this case we need to update CI to test this code. You need to check it in two places:
- conda-package.yml , use npbench as reference:
https://github.com/IntelPython/dpbench/blob/main/.github/workflows/conda-package.yml#L193-L196 - build-and-run.yml , you just need to run it along with all other benchmarks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ZzEeKkAa Sure we can do it as a later step, but we should enable the rodhinia benchmark running in GitHub CI at some point in near future.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As discussed, I have added it as a part of the CI and is run using the build_and_run.yml inside the workflow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. Just left minor comments. Please add description to PR and we are ready to go. Once it is ready - make sure to rebase and mark PR as ready to review.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The numba_dpex_k impl does not seem to match the SYCL impl. I notice that the SYCL impl is using barriers and the numba-dpex impl does not have any calls to a barrier.
LOW, HIGH, (rows * cols), dtype=np.int64 | ||
), np.empty(cols, dtype=np.int64) | ||
|
||
return (data, rows, cols, pyramid_height, result) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rows, cols and pyramid_height need not be returned from initialize.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed unnecessary returns from initialize.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The numba_dpex implementation had to modified as the multiplication of range elements wasn't allowed. Even though the sycl implementation had "iteration" inside the loop, for pyramid height as 1, it will always run once so we can compare them. Also as we are only dealing with independent elements, we won't be needing any barriers in this case.
dpbench/benchmarks/rodinia/pathfinder/pathfinder_numba_dpex_k.py
Outdated
Show resolved
Hide resolved
dpbench/benchmarks/rodinia/pathfinder/pathfinder_numba_dpex_k.py
Outdated
Show resolved
Hide resolved
dpbench/benchmarks/rodinia/pathfinder/pathfinder_numba_dpex_k.py
Outdated
Show resolved
Hide resolved
SEED = 9 | ||
|
||
|
||
def initialize(rows, cols, pyramid_height, types_dict=None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pyramid_height
is not being used in initialization.
device_dest[current_element] += shortest | ||
|
||
|
||
def pathfinder(data, rows, cols, pyramid_height, result): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pyramid_height
not being used?
5a3d1ce
to
01b6bc9
Compare
53de4a8
to
bcd2a25
Compare
bcd2a25
to
2cb62ed
Compare
2cb62ed
to
cf602e1
Compare
Closing this PR. Please reopen if there are further updates. |
Added the rodinia benchmark suite for dpbench/benchmarks. Also includes the native sycl, numba_dpex and python implementation for all algorithms.
Blocked by: IntelPython/numba-dpex#1106