Skip to content

OpenCL: Disable unsupported allocation of Adreno large buffers to fix compilation failure in OpenCL 2.x#25897

Closed
mgroeber9110 wants to merge 1 commit into
ggml-org:masterfrom
mgroeber9110:fix-opencl-2-compilation
Closed

OpenCL: Disable unsupported allocation of Adreno large buffers to fix compilation failure in OpenCL 2.x#25897
mgroeber9110 wants to merge 1 commit into
ggml-org:masterfrom
mgroeber9110:fix-opencl-2-compilation

Conversation

@mgroeber9110

Copy link
Copy Markdown
Contributor

Overview

This change disables the Adreno large buffer fallback when targeting OpenCL 2.x and older. This is necessary because the clCreateBufferWithProperties API is not available in OpenCL earlier than 3.0.

Additional information

This restores the ability to compile with GGML_OPENCL_TARGET_VERSION set to 210 or less, which failed because of undefined symbols before. I do not expect this to negatively affect Adreno support, because this was only usable with OpenCL 3.0 so far anyway. As this is the only failure currently preventing OpenCL 2.x compilation, I believe this is still worth fixing (even if few people are using this variant).

Requirements

@mgroeber9110
mgroeber9110 requested a review from a team as a code owner July 19, 2026 15:14
@github-actions github-actions Bot added ggml changes relating to the ggml tensor library for machine learning OpenCL Issues specific to the OpenCL backend labels Jul 19, 2026
@lhez

lhez commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

I think this has already been fixed. Can you try again with the latest master?

@mgroeber9110

Copy link
Copy Markdown
Contributor Author

I don't have my dev machine with me this week, but I see now that 12127de indeed fixed this already a few days ago.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ggml changes relating to the ggml tensor library for machine learning OpenCL Issues specific to the OpenCL backend

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants