Skip to content

Fix RepeatedKernelRetrieval warning in cl_hash_iterations#718

Open
MasterGerhard wants to merge 1 commit into
3rdIteration:masterfrom
MasterGerhard:fix-hash-iterations-kernel-cache
Open

Fix RepeatedKernelRetrieval warning in cl_hash_iterations#718
MasterGerhard wants to merge 1 commit into
3rdIteration:masterfrom
MasterGerhard:fix-hash-iterations-kernel-cache

Conversation

@MasterGerhard
Copy link
Copy Markdown

Cache the hash_iterations OpenCL kernel on the program object using getattr/setattr, matching the existing pattern used in cl_pbkdf2 and cl_pbkdf2_saltlist. This avoids repeated expensive kernel instantiation and eliminates the pyopencl RepeatedKernelRetrieval warning on Apple Silicon (and other platforms).

Tested on Apple M series.

Cache the hash_iterations OpenCL kernel on the program object using
getattr/setattr, matching the existing pattern used in cl_pbkdf2 and
cl_pbkdf2_saltlist. This avoids repeated expensive kernel instantiation
and eliminates the pyopencl RepeatedKernelRetrieval warning on Apple
Silicon (and other platforms).
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.

1 participant