Skip to content

Conversation

oulgen
Copy link
Contributor

@oulgen oulgen commented Aug 22, 2025

Stacked PRs:


Add call function to triton output for easier repros

oulgen added a commit that referenced this pull request Aug 22, 2025
stack-info: PR: #514, branch: oulgen/stack/64
@meta-cla meta-cla bot added the CLA Signed This label is managed by the Meta Open Source bot. label Aug 22, 2025
oulgen added a commit that referenced this pull request Aug 22, 2025
stack-info: PR: #514, branch: oulgen/stack/64
@oulgen oulgen requested review from jansel and yf225 August 22, 2025 17:55
@oulgen oulgen marked this pull request as ready for review August 22, 2025 17:55
@@ -87,6 +87,7 @@ class _Settings:
)
autotune_precompile: bool = sys.platform != "win32"
print_output_code: bool = os.environ.get("HELION_PRINT_OUTPUT_CODE", "0") == "1"
print_triton_repro: bool = os.environ.get("HELION_PRINT_TRITON_REPRO", "0") == "1"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wonder should HELION_PRINT_OUTPUT_CODE=1 just also print the call function? That way we might be able to save one environment variable too.

oulgen added a commit that referenced this pull request Aug 22, 2025
stack-info: PR: #514, branch: oulgen/stack/64
oulgen added a commit that referenced this pull request Aug 22, 2025
stack-info: PR: #514, branch: oulgen/stack/64
stack-info: PR: #514, branch: oulgen/stack/64
Comment on lines +257 to +262
if isinstance(arg, torch.SymInt):
rhs = int(arg)
elif isinstance(arg, torch.SymFloat):
rhs = float(arg)
elif isinstance(arg, torch.SymBool):
rhs = bool(arg)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to be using size hints here? SymInt.__int__ adds a guard implicitly which might create some weirdness in the shape env?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What would be the alternative if I want to convert a symint to a representative integer?

Copy link
Contributor

@jansel jansel Aug 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there is a helper to get the size hint (without adding a guard) in CompileEnvironment/shape env.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Meta Open Source bot.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants