-
Notifications
You must be signed in to change notification settings - Fork 3
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
adding initial support for malloc/empty node #62
Conversation
sycl/source/detail/graph_impl.cpp
Outdated
@@ -23,6 +25,14 @@ namespace experimental { | |||
namespace detail { | |||
|
|||
void graph_impl::exec(sycl::detail::queue_ptr q) { | |||
for(auto i:MAllocs) { |
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.
Preference for a more descriptive name here than i
.
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.
only minor comments
@@ -23,6 +25,12 @@ namespace experimental { | |||
namespace detail { | |||
|
|||
void graph_impl::exec(sycl::detail::queue_ptr q) { | |||
for(auto alloc:MAllocs) { |
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.
PR could use a clang-format, need some whitespace here (and other places) and some code added later is using 4-space indentation rather than 2.
sycl/test/graph/graph-memory.cpp
Outdated
x[0] = v; | ||
auto result = x[0]; | ||
|
||
//sycl::free(x, q); |
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.
what happens if we try to call free
here? I'd have thought if x
was allocated on the execution of executable_graph
that would still work. Might need a q.wait()
after the submission.
sycl/test/graph/graph-memory.cpp
Outdated
|
||
const size_t n = 1000; | ||
float *x; | ||
//void*& x = vec; |
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.
can remove commented out code
sycl/test/graph/graph-memory.cpp
Outdated
q.submit([&](sycl::handler &h) { h.exec_graph(executable_graph); }); | ||
|
||
float v = 2.0f; | ||
//auto vec = static_cast<float*>(x); |
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.
can remove commented out code
Obsolete and superseded by #106 |
Seeing some issues with the tests, have to track them down.