Skip to content

Conversation

@Lunderberg
Copy link
Contributor

Prior to this commit, the well-formed checker verified that the "global_symbol" attribute, if present, matches the name of the GlobalVar. However, this check was only applied for Relax functions. As a result, discrepencies between the "global_symbol" and the gvar->name_hint could result in unexpected bugs. (For example, #17176.)

This commit updates the well-formed checker to verify "global_symbol" on all functions in an IRModule.

@Lunderberg
Copy link
Contributor Author

I expect this PR to fail CI, as #17202 resolves a failure mode that this change is designed to detect. (Though that isn't necessarily the only case that this check will catch.)

Prior to this commit, the well-formed checker verified that the
`"global_symbol"` attribute, if present, matches the name of the
`GlobalVar`.  However, this check was only applied for Relax
functions.  As a result, discrepencies between the `"global_symbol"`
and the `gvar->name_hint` could result in unexpected bugs.  (For
example, apache#17176.)

This commit updates the well-formed checker to verify
`"global_symbol"` on all functions in an `IRModule`.
@Lunderberg Lunderberg force-pushed the well_formed_global_symbol_on_all_ir_types branch from afc68f4 to ed94359 Compare September 16, 2024 20:30
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.

1 participant