kill allow_complex_guards_as_runtime_asserts (#160198)

Summary: Since `allow_complex_guards_as_runtime_asserts` is now sync'd with `prefer_deferred_runtime_asserts_over_guards`, we can kill the former (especially since it was a export-only concept).

Test Plan:
updated tests

Rollback Plan:

Differential Revision: D79903317

Pull Request resolved: https://github.com/pytorch/pytorch/pull/160198
Approved by: https://github.com/ezyang
This commit is contained in:
Avik Chaudhuri
2025-08-28 07:59:29 +00:00
committed by PyTorch MergeBot
parent fa76256603
commit 196232bb93
9 changed files with 47 additions and 67 deletions

View File

@ -158,7 +158,7 @@ def export_for_training(
dynamic_shapes,
strict=strict,
preserve_module_call_signature=preserve_module_call_signature,
allow_complex_guards_as_runtime_asserts=prefer_deferred_runtime_asserts_over_guards,
prefer_deferred_runtime_asserts_over_guards=prefer_deferred_runtime_asserts_over_guards,
)
@ -282,7 +282,7 @@ def export(
strict=strict,
preserve_module_call_signature=preserve_module_call_signature,
pre_dispatch=True,
allow_complex_guards_as_runtime_asserts=prefer_deferred_runtime_asserts_over_guards,
prefer_deferred_runtime_asserts_over_guards=prefer_deferred_runtime_asserts_over_guards,
)
except Exception as e:
draft_export_msg = (