-
Notifications
You must be signed in to change notification settings - Fork 1k
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
graph: backend: dnnl: fix the null pointer issue and remove unused code #2504
base: main
Are you sure you want to change the base?
Conversation
make test |
@@ -142,13 +142,6 @@ void sdp_primitive_kernel_t<quantized>::prepare_args_set( | |||
mem_idx.first.set_data_handle( | |||
outputs[mem_idx.second].get_data_handle()); | |||
} | |||
|
|||
grantor_t var_grantor = memory_planner_.internal_temporary_grantor( |
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.
could you explain why remove these code?
Do we need to check if scratchpad is needed ?
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.
Sdp_primitive doesn't need scratchpad memory, so we set the scratchpad memory size is 0 in L227. So we don't need to set the data handle for the internal memory.
31f1e16
to
fbd6bc0
Compare
make test |
@@ -215,6 +215,7 @@ class grantor_t { | |||
} | |||
|
|||
char *get(const registry_t::key_t &key) const { | |||
if (aligned_base_ptr_ == nullptr) return nullptr; | |||
return aligned_base_ptr_ + registry_.get(key); |
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.
nit:
return aligned_base_ptr_ + registry_.get(key); | |
return aligned_base_ptr_ ? (aligned_base_ptr_ + registry_.get(key)) : nullptr; |
fbd6bc0
to
dc994c8
Compare
make test |
Description
applying non-zero offset 150994944 to null pointer