Skip to content

Fix CSA core.NullDereference in grid_sample_bilinear_program_factory#38828

Closed
Copilot wants to merge 2 commits intomainfrom
copilot/fix-null-dereference-issue-another-one
Closed

Fix CSA core.NullDereference in grid_sample_bilinear_program_factory#38828
Copilot wants to merge 2 commits intomainfrom
copilot/fix-null-dereference-issue-another-one

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 28, 2026

Ticket

N/A

Problem description

Clang Static Analyzer flagged core.NullDereference at line 171. Multi-variable declaration KernelHandle reader0_kernel_id, reader1_kernel_id = 0; only initialized the second variable, leaving reader0_kernel_id uninitialized.

What's changed

Changed line 171 to value-initialize both variables:

tt::tt_metal::KernelHandle reader0_kernel_id{}, reader1_kernel_id{};

Follows pattern used in layernorm ops (tt-train) and throughout codebase for handle types.

Checklist

  • All post-commit tests
  • Blackhole Post commit
  • cpp-unit-tests
  • New/Existing tests provide coverage for changes
  • (Optional) Ran clang-tidy code analysis on the PR branch to catch linting errors early

Model tests

If your changes cover model-related code, you should run tests corresponding to affected models and platforms (Single card, T3K, Galaxy). "Choose your pipeline" workflows facilitate running multiple kinds of tests in a single run. Each offers models-mandatory and models-extended presets.
The former includes a minimal set of tests, to be run always. The latter extends that with additional ones - use your best judgement in deciding which is the most appropriate for your PR.

Original prompt

Fix this Clang Static Analyzer issue:

  • core.NullDereference in ttnn/cpp/ttnn/operations/pool/grid_sample/device/grid_sample_bilinear_program_factory.cpp:224 — Dereference of undefined pointer value

Verify it's a real issue, apply minimal fix, follow coding standards.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI changed the title [WIP] Fix null dereference issue in grid sample program Fix CSA core.NullDereference in grid_sample_bilinear_program_factory Feb 28, 2026
blozano-tt added a commit that referenced this pull request Mar 1, 2026
The workflow has been reporting failures since Feb 26 when the GitHub
Actions runner image updated from gh CLI 2.86.0 to 2.87.3.

gh CLI v2.87.0 introduced API version pinning (X-GitHub-Api-Version:
2022-11-28) which broke the Copilot API (CAPI) log streaming endpoint
(cli/cli#12729, cli/cli#12730). The fix in cli/cli#12731 corrected the
API version for CAPI requests, but the --follow flag still exits
non-zero with 'not found' when streaming session logs.

Crucially, the agent task itself succeeds — every 'failing' run since
Feb 26 actually created a PR:
  Feb 26 06:20 → #38614
  Feb 26 08:18 → #38615
  Feb 27 06:16 → #38710
  Feb 27 08:17 → #38723
  Feb 28 08:09 → #38828

But because of 'set -euo pipefail', the non-zero --follow exit code
killed the script before the PR labeling code could run.

Fix: tolerate --follow failures with '|| echo warning', allowing the
script to continue to extract the PR number and apply labels.
@blozano-tt
Copy link
Copy Markdown
Contributor

Closing, because null dereference is not the same as an uninitalized value. I think the agent didn’t have enough context. We can circle back to this violation in the future.

@blozano-tt blozano-tt closed this Mar 1, 2026
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