Skip to content

Conversation

Ryo-not-rio
Copy link

conv, matmul and inner product have been converted to being stateless in ACL, thus there is no longer a need for the computation cache. This has been replaced with a dummy cache as the cache is still expected to exist. The dummy cache can be removed once deconv is also converted to stateless.

@@ -35,7 +35,7 @@ struct inner_product_forward_params {
struct inner_product_forward
: public dnnl::inner_product_forward,
#ifdef __aarch64__
Copy link

@nikhil-arm nikhil-arm Aug 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will we ever hit a case when oneDNN is not built with ACL on Arm platform and this code would crash. Same for other instances where this is used

class dummy_computation_cache {
public:
static inline dummy_lru t_store() {
return dummy_lru();

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Returning by value? Can we verify that no code is binding by ref or expects similar semantic to real cache.

Suggested change
return dummy_lru();
static dummy_lru store;
return store;

param.pd = primitive_desc(
aengine, src_desc, weights.get_desc(), dst_desc, op_attr);
}
param.primitive = std::move(super(param.pd));
Copy link

@nikhil-arm nikhil-arm Aug 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is move redundant on temporary data? I am doubtful of my comment and needs suggestions from author

conv, matmul and inner product have been converted to being stateless
in ACL, thus there is no longer a need for the computation cache.
This has been replaced with a placeholder cache as the cache is still expected
to exist. The placeholder cache can be removed once deconv is also converted
to stateless.

No change in performance.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants