Skip to content

Conversation

@bob80905
Copy link
Collaborator

@bob80905 bob80905 commented Aug 1, 2023

This PR is one of several more PR's that move diagnostic emission earlier for specific errors, so that the verifier can catch these errors. This PR focuses on the MaxRecord* attributes applied on parameters. Specifically, there are 2 behaviors that this PR will allow DXC to detect earlier:

  1. Prevent more than one of {MaxRecord, MaxRecordsSharedWith} from being applied to a single parameter
  2. Prevent MaxRecordsSharedWith from referencing the same parameter name that the attribute is being applied to.

Some tests have been merged or deleted to consolidate these verifier tests. There is still some behavior that cannot be tested at this time (verifying that MaxRecordsSharedWith doesn't reference an invalid parameter name), which will be addressed in the future. It's likely that this location is too early to properly validate this behavior, and the tests for this behavior may need to be left at the same location.

This PR is one of a few that will help implement this task:
#5368

@bob80905 bob80905 changed the base branch from main to release-preview-1.8.2306 August 1, 2023 22:02
@bob80905 bob80905 changed the title [Verifier] Add verifier tests to catch more behaviors earlier [Verifier] Add verifier tests to catch MaxRecord errors earlier Aug 2, 2023
Copy link
Collaborator

@llvm-beanz llvm-beanz left a comment

Choose a reason for hiding this comment

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

One small change inline

}

TEST_F(VerifierTest, RunMaxRecordsAttribute) {
CheckVerifiesHLSL(L"max_output_records_duplicate.hlsl");
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible to make these tests lit FileCheck test?

Copy link
Collaborator

Choose a reason for hiding this comment

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

No, this is targeting the release branch.

Copy link
Contributor

Choose a reason for hiding this comment

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

Why release branch cannot have lit FileCheck test?

Copy link
Contributor

Choose a reason for hiding this comment

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

Because we won't hide taef for release branch?

Copy link
Collaborator

Choose a reason for hiding this comment

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

The preview branch is over a month old and doesn't have all the changes in main to move to LIT.

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 plan to merge the LIT change to preview branch?

Copy link
Collaborator

Choose a reason for hiding this comment

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

I think that's a question for @pow2clk (#5478)

@bob80905 bob80905 merged commit 48c9d78 into microsoft:release-preview-1.8.2306 Aug 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants