Skip to content

Re-revert D102031366 reland to restore at::Tag pre-headeronly mangling - #181788

Closed
akshaymahesh2 wants to merge 1 commit into
mainfrom
export-D102837723
Closed

akshaymahesh2 wants to merge 1 commit into
mainfrom
export-D102837723

Conversation

@akshaymahesh2

@akshaymahesh2 akshaymahesh2 commented Apr 28, 2026 •

Copy link
Copy Markdown

D102031366 (commit d6a7d7e447b7, landed 2026-04-23 12:57 PDT) re-landed D100546620's move of at::Tag -> torch::headeronly::Tag after D101431332 had reverted the original. The rename re-mangles torch::Library::_def(schema, std::vector<at::Tag>) because C++ name mangling resolves at::Tag to its canonical type at compile time. Out-of-tree libraries linked against _def(... vector<Tag> ...) are pinned to whichever torch ABI they were compiled against — pin them anywhere on the torch timeline and you have a mismatch with anything not-the-same.

@diff-train-skip-merge

Differential Revision: D102837723

…eronly mangling

Summary:
## TL;DR — why this is breaking

D102031366 (commit `d6a7d7e447b7`, landed 2026-04-23 12:57 PDT) re-landed D100546620's move of `at::Tag` -> `torch::headeronly::Tag` after D101431332 had reverted the original. The rename re-mangles `torch::Library::_def(schema, std::vector<at::Tag>)` because C++ name mangling resolves `at::Tag` to its canonical type at compile time. Out-of-tree libraries linked against `_def(... vector<Tag> ...)` are pinned to whichever torch ABI they were compiled against — pin them anywhere on the torch timeline and you have a mismatch with anything not-the-same.

Concretely: every conveyor `fbpkg Build Node (tritoncc_repkg)` after 04-23 12:57 produces a `libhammer.so` requiring `_def(... vector<headeronly::Tag> ...)`. The deployed `sigrid_predictor_gpu.persistent:prod` (5445, built 2026-04-19, pre-reland) only exports `_def(... vector<at::Tag> ...)`. Predictor crashes during startup with `undefined symbol: _ZNR5torch7Library4_def…NS_10headeronly3TagE…` — `silvertorch/ifr_prospector` cogwheel `serving_eval` fails — conveyor blocked since R7244 (third recurrence: S635765 -> S651243 -> S654770).

This re-revert restores trunk to the pre-headeronly state so freshly-built `tritoncc_repkg` is ABI-compatible with the deployed predictor. Long-term proper fix (Hammer team migrates to the stable shim API also added in D102031366): https://www.internalfb.com/intern/paste/P2292623657/.

## Conflict resolution

`torchgen/gen.py` had 2 merge conflicts because a follow-up diff (`935b3c23200e`) extended the `--headeronly-install-dir` argparse option that D102031366 introduced. Resolved by removing the orphaned `--headeronly-install-dir` arg and its install-dir resolution block entirely — the only callers were the BUCK/CMake genrules in this same diff (already cleanly reverted as part of the backout). Verified via repo-wide grep: no other code references `headeronly_install_dir` or `--headeronly-install-dir`.

Test Plan:
This re-revert is validated by [chronos gp/99079202212040184](https://www.internalfb.com/chronos/job_instance/gp/99079202212040184), which ran R7365's exact fbpkgs + `tritoncc_repkg:196` (the last pre-D102031366-reland tagged build, equivalent to what `tritoncc_repkg` would produce off this re-revert). All 4 step MAST jobs SUCCEEDED:

- publish: [fire-mrs_ml_release_oncall-mrs_cog-test-8014f3](https://www.internalfb.com/mast/job/fire-mrs_ml_release_oncall-mrs_cog-test-8014f3)
- st_update_service_publish_delta_only: [mvai-training-online-2125932658-mrs_cog-test-7b6830](https://www.internalfb.com/mast/job/mvai-training-online-2125932658-mrs_cog-test-7b6830)
- online_train_publish_delta_only: [mvai-training-online-2125932663-mrs_cog-test-a58a78](https://www.internalfb.com/mast/job/mvai-training-online-2125932663-mrs_cog-test-a58a78)
- **serving_eval: [fire-mrs_ml_release_oncall-mrs_cog-test-b892a3](https://www.internalfb.com/mast/job/fire-mrs_ml_release_oncall-mrs_cog-test-b892a3)** — predictor started, loaded `libhammer:196` with no symbol error, ran eval to completion.

The validation cogwheel only failed at metric-verify because we'd skipped `online_train` and reused stub model IDs; on a real conveyor cogwheel that includes `online_train`, metrics are real (a parallel conveyor hotfix at https://fburl.com/conveyor/5051bpe0 is end-to-end validating that variant).

## Related

- SEV: https://www.internalfb.com/sevmanager/view/654770
- Long-term fix options: https://www.internalfb.com/intern/paste/P2292623657/
- Prior recurrences: S635765 (2026-04-01), S651243 (2026-04-17)
- Breaking diffs: D100546620 (original), D101431332 (revert), D102031366 (reland on 2026-04-23 12:57 PDT)

Differential Revision: D102837723
@pytorch-bot

pytorch-bot Bot commented Apr 28, 2026 •

Copy link
Copy Markdown

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/181788

Note: Links to docs will display an error until the docs builds have been completed.

❗ 1 Active SEVs

There are 1 currently active SEVs. If your PR is affected, please view them below:

❌ 3 New Failures, 8 Unrelated Failures

As of commit 348be7c with merge base 631f95d (image):

NEW FAILURES - The following jobs have failed:

FLAKY - The following job failed but was likely due to flakiness present on trunk:

UNSTABLE - The following jobs are marked as unstable, possibly due to flakiness on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@pytorch-bot pytorch-bot Bot added the ci-no-td Do not run TD on this PR label Apr 28, 2026
@pytorch-bot

pytorch-bot Bot commented Apr 28, 2026

Copy link
Copy Markdown

This PR needs a release notes: label

If your changes are user facing and intended to be a part of release notes, please use a label starting with release notes:.

If not, please add the topic: not user facing label.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "topic: not user facing"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

@linux-foundation-easycla

Copy link
Copy Markdown

CLA Not Signed

@meta-codesync

meta-codesync Bot commented Apr 28, 2026

Copy link
Copy Markdown

@akshaymahesh2 has exported this pull request. If you are a Meta employee, you can view the originating Diff in D102837723.

@github-actions

Copy link
Copy Markdown
Contributor

Attention! PyTorch one of the C-stable API file was changed

You MUST NOT change existing function declarations in this, as this header defines a stable C ABI. If you need to change the signature for a function, introduce a new v2 version of the function and modify code generation to target the new version of the function.


Caused by:

@akshaymahesh2 akshaymahesh2 changed the title [SEV S654770] Re-revert D102031366 reland to restore at::Tag pre-headeronly mangling Re-revert D102031366 reland to restore at::Tag pre-headeronly mangling Apr 28, 2026
@pytorch-bot pytorch-bot Bot added the ciflow/trunk Trigger trunk jobs on your pull request label Apr 28, 2026
@wdvr wdvr added topic: not user facing topic category suppress-bc-linter Suppresses the failures of API backward-compatibility linter (Lint/bc_linter) labels Apr 28, 2026
@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented Apr 28, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented Apr 29, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented Apr 29, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented Apr 29, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented Apr 29, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented Apr 29, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented Apr 29, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 3, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 3, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 3, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 3, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 3, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 3, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 4, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 4, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 4, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 4, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 4, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 4, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@facebook-github-tools

Copy link
Copy Markdown

@pytorchbot merge -i

(Initiating merge automatically since Phabricator Diff has merged, merging with -i because oss signals were bypassed internally)

@pytorch-bot

pytorch-bot Bot commented May 4, 2026

Copy link
Copy Markdown

This PR needs to be approved by an authorized maintainer before merge.

@wdvr

wdvr commented May 4, 2026

Copy link
Copy Markdown
Contributor

relanding it internally

@wdvr wdvr closed this May 4, 2026
@github-actions
github-actions Bot deleted the export-D102837723 branch June 4, 2026 02:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-no-td Do not run TD on this PR ciflow/trunk Trigger trunk jobs on your pull request fb-exported meta-exported suppress-bc-linter Suppresses the failures of API backward-compatibility linter (Lint/bc_linter) topic: not user facing topic category

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants