You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
testsuite: Add dg-lto-error directive support to lto.exp.
The LTO test framework lacked support for testing expected link-time
errors. Tests could use dg-lto-warning and dg-lto-message for
diagnostics emitted during compilation, but there was no way to verify
that certain code patterns correctly fail at link time under LTO.
This patch adds dg-lto-error directive support, allowing tests to:
1. Mark expected link failures with dg-lto-error directives
2. Pass when the link fails as expected (no executable created or
linker errors present)
3. Fail when the link succeeds but should have failed
4. Skip execution tests when link failure is expected
The implementation tracks dg-lto-error presence via a global flag and
performs custom link result checking when link failure is expected,
rather than using the standard check_compile reporting.
Signed-off-by: Luis Silva <luiss@synopsys.com>
0 commit comments