[M68k] Use ISD::getSetCCInverse instead of ISD::GlobalISel::getSetCCInverse. NFCI - #216871
Open
topperc wants to merge 1 commit into
Open
[M68k] Use ISD::getSetCCInverse instead of ISD::GlobalISel::getSetCCInverse. NFCI#216871topperc wants to merge 1 commit into
topperc wants to merge 1 commit into
Conversation
…nverse. NFCI It's odd to use a GlobalISel named function in SelectionDAG code. This code path isn't exercised by lit, but I think this should be equivalent.
|
@llvm/pr-subscribers-backend-m68k Author: Craig Topper (topperc) ChangesIt's odd to use a GlobalISel named function in SelectionDAG code. This code path isn't exercised by lit, but I think this should be equivalent. Full diff: https://github.com/llvm/llvm-project/pull/216871.diff 1 Files Affected:
diff --git a/llvm/lib/Target/M68k/M68kISelLowering.cpp b/llvm/lib/Target/M68k/M68kISelLowering.cpp
index 18e974e6f7383..465c4dfb8fbc0 100644
--- a/llvm/lib/Target/M68k/M68kISelLowering.cpp
+++ b/llvm/lib/Target/M68k/M68kISelLowering.cpp
@@ -2207,7 +2207,7 @@ SDValue M68kTargetLowering::LowerSETCC(SDValue Op, SelectionDAG &DAG) const {
}
if (Op0.getValueType() == MVT::i1 && (CC == ISD::SETEQ || CC == ISD::SETNE)) {
if (isOneConstant(Op1)) {
- ISD::CondCode NewCC = ISD::GlobalISel::getSetCCInverse(CC, true);
+ ISD::CondCode NewCC = ISD::getSetCCInverse(CC, Op0.getValueType());
return DAG.getSetCC(DL, VT, Op0, DAG.getConstant(0, DL, MVT::i1), NewCC);
}
if (!isNullConstant(Op1)) {
|
🪟 Windows x64 Test Results
Failed Tests(click on a test name to see its output) lldlld.ELF/lto/thinlto.llIf these failures are unrelated to your changes (for example tests are broken or flaky at HEAD), please open an issue at https://github.com/llvm/llvm-project/issues and add the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
It's odd to use a GlobalISel named function in SelectionDAG code. This code path isn't exercised by lit, but I think this should be equivalent.