[UTC] Add fallback support for specific metadata, and check their defs
This prevents update_cc_tests.py from emitting hard-coded identifiers for metadata (global variable checkers still check hard-coded identifiers). Instead it emits regex checkers that match even if the identifiers change. Also adds a new mode for --check-globals: instead of simply being on or off, it now has the options 'none', 'smart' and 'all', with 'none' and 'all' corresponding to the previous modes. The 'smart' mode only emits checks for global definitions referenced in the IR or other metadata that itself has a definition checker emitted, making the rule transitive. It does not emit checks for attribute sets, since that is better checked by --check-attributes. This mode is made the new default. To make the change in default mode backwards compatible a version bump is introduced (to v3), and the default remains 'none' in v1 & v2. This will result in metadata checks being emitted more often, so filters are added to not check absolute file paths and compiler version git hashes. rdar://105239218
Loading
Please sign in to comment