Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NFC] Remove unused functions in ExecutionTest.cpp and assert.cpp #7129

Merged
merged 3 commits into from
Feb 7, 2025

Conversation

bob80905
Copy link
Collaborator

@bob80905 bob80905 commented Feb 7, 2025

Some functions need to be removed / changed to unblock some internal pipelines. They are emitting warnings that they are unused.
Specifically, CompareOutputWithExpectedValueFloat, CompareOutputWithExpectedValueHalf, and CompareOutputWithExpectedValueFloat need to be removed because they are unused.
Additionally, there is a case in assert.cpp where llvm_assert_trap is left unused depending on what's been defined and how the preprocessor directives execute. This needs to be remedied so that the function is only defined when it is used.

@bob80905 bob80905 requested a review from a team as a code owner February 7, 2025 02:15
Copy link
Member

@hekota hekota left a comment

Choose a reason for hiding this comment

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

LGTM!

@alsepkow
Copy link
Contributor

alsepkow commented Feb 7, 2025

LGTM

@bob80905 bob80905 enabled auto-merge (squash) February 7, 2025 02:27
@bob80905 bob80905 changed the title [NFC] Remove unused functions [NFC] Remove unused functions in ExecutionTest.cpp Feb 7, 2025
@bob80905 bob80905 disabled auto-merge February 7, 2025 03:00
@bob80905 bob80905 changed the title [NFC] Remove unused functions in ExecutionTest.cpp [NFC] Remove unused functions in ExecutionTest.cpp and assert.cpp Feb 7, 2025
@bob80905 bob80905 enabled auto-merge (squash) February 7, 2025 04:10
@bob80905 bob80905 disabled auto-merge February 7, 2025 09:43
Copy link
Contributor

@tex3d tex3d left a comment

Choose a reason for hiding this comment

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

Can we more clearly describe the changes in the change description, rather than just the justification? Doesn't have to be long, but naming the functions removed from ExecutionTest.cpp, and clarifying that llvm_assert_trap is placed under the preprocessor condition, rather than removed, would be better when reading the description to know what changes are being made.

I also don't really like that these two are being changed in the same PR, and I think the ExecutionTest functions are potentially useful for upcoming testing work, so maybe these can be made non-static?

Copy link
Member

@hekota hekota left a comment

Choose a reason for hiding this comment

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

LGTM!

@bob80905
Copy link
Collaborator Author

bob80905 commented Feb 7, 2025

Can we more clearly describe the changes in the change description, rather than just the justification? Doesn't have to be long, but naming the functions removed from ExecutionTest.cpp, and clarifying that llvm_assert_trap is placed under the preprocessor condition, rather than removed, would be better when reading the description to know what changes are being made.

I also don't really like that these two are being changed in the same PR, and I think the ExecutionTest functions are potentially useful for upcoming testing work, so maybe these can be made non-static?

I've improved the description.
Unsure if making them non-static will solve the problem, if somehow it doesn't this will delay release. I know for certain deleting them will. In agreement with Helena, we can add it back if needed later.

@bob80905 bob80905 merged commit 20950d6 into microsoft:main Feb 7, 2025
15 checks passed
bob80905 added a commit to bob80905/DirectXShaderCompiler that referenced this pull request Feb 7, 2025
…crosoft#7129)

Some functions need to be removed / changed to unblock some internal
pipelines. They are emitting warnings that they are unused.
Specifically, `CompareOutputWithExpectedValueFloat`,
`CompareOutputWithExpectedValueHalf`, and
`CompareOutputWithExpectedValueFloat` need to be removed because they
are unused.
Additionally, there is a case in assert.cpp where `llvm_assert_trap` is
left unused depending on what's been defined and how the preprocessor
directives execute. This needs to be remedied so that the function is
only defined when it is used.
bob80905 added a commit that referenced this pull request Feb 7, 2025
) (#7132)

Some functions need to be removed / changed to unblock some internal
pipelines. They are emitting warnings that they are unused.
Specifically, `CompareOutputWithExpectedValueFloat`,
`CompareOutputWithExpectedValueHalf`, and
`CompareOutputWithExpectedValueFloat` need to be removed because they
are unused.
Additionally, there is a case in assert.cpp where `llvm_assert_trap` is
left unused depending on what's been defined and how the preprocessor
directives execute. This needs to be remedied so that the function is
only defined when it is used.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants