Align TBE fake batch shape with its operator contract (#4481) - #4481
Open
kaanbaloglu wants to merge 1 commit into
Open
Align TBE fake batch shape with its operator contract (#4481)#4481kaanbaloglu wants to merge 1 commit into
kaanbaloglu wants to merge 1 commit into
Conversation
Contributor
|
@kaanbaloglu has exported this pull request. If you are a Meta employee, you can view the originating Diff in D114760345. |
) Summary: `ir_tbe_lookup_impl` returns output tensors using the supplied `batch_size`, but its fake registration discarded that value and invented an unbacked dimension. This change makes the fake use the supplied `batch_size`, matching the real implementation and the sibling `ir_emb_lookup` and `ir_kt_regroup` fakes. This is a shape-contract consistency cleanup, not a claim of new runtime batch polymorphism. For static exports, it makes the lookup interior batch dimension input-derived instead of unbacked. Dynamic exports may prove the same relation through downstream constraints. `ir_dynamic_batch_emb_lookup` remains the dedicated operator for cases that intentionally require an unbacked batch dimension. The BUCK target-label updates are AUTODEPS2-required normalization for the two touched Python targets; no dependency behavior change is intended. Differential Revision: D114760345
kaanbaloglu
force-pushed
the
export-D114760345
branch
from
August 5, 2026 03:12
7111001 to
0b43032
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
ir_tbe_lookup_implreturns output tensors using the suppliedbatch_size, but its fake registration discarded that value and invented an unbacked dimension. This change makes the fake use the suppliedbatch_size, matching the real implementation and the siblingir_emb_lookupandir_kt_regroupfakes.This is a shape-contract consistency cleanup, not a claim of new runtime batch polymorphism. For static exports, it makes the lookup interior batch dimension input-derived instead of unbacked. Dynamic exports may prove the same relation through downstream constraints.
ir_dynamic_batch_emb_lookupremains the dedicated operator for cases that intentionally require an unbacked batch dimension.The BUCK target-label updates are AUTODEPS2-required normalization for the two touched Python targets; no dependency behavior change is intended.
Differential Revision: D114760345