-
Notifications
You must be signed in to change notification settings - Fork 14.3k
MSP430: Move libcall CC setting to RuntimeLibcallsInfo #146081
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
Open
arsenm
wants to merge
1
commit into
users/arsenm/lanai/use-tablegen-runtime-libcalls
Choose a base branch
from
users/arsenm/msp430/set-libcall-impl-cc-runtime-libcalls
base: users/arsenm/lanai/use-tablegen-runtime-libcalls
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
MSP430: Move libcall CC setting to RuntimeLibcallsInfo #146081
arsenm
wants to merge
1
commit into
users/arsenm/lanai/use-tablegen-runtime-libcalls
from
users/arsenm/msp430/set-libcall-impl-cc-runtime-libcalls
+5
−2
Conversation
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
This was referenced Jun 27, 2025
This was referenced Jun 27, 2025
@llvm/pr-subscribers-backend-msp430 @llvm/pr-subscribers-tablegen Author: Matt Arsenault (arsenm) ChangesAs a temporary step configure the calling convention here. This Full diff: https://github.com/llvm/llvm-project/pull/146081.diff 2 Files Affected:
diff --git a/llvm/lib/IR/RuntimeLibcalls.cpp b/llvm/lib/IR/RuntimeLibcalls.cpp
index 6f1f7014249c7..a5605329c7d28 100644
--- a/llvm/lib/IR/RuntimeLibcalls.cpp
+++ b/llvm/lib/IR/RuntimeLibcalls.cpp
@@ -365,6 +365,11 @@ void RuntimeLibcallsInfo::initLibcalls(const Triple &TT,
RTLIB::HEXAGON_MEMCPY_LIKELY_ALIGNED_MIN32BYTES_MULT8BYTES,
RTLIB::__hexagon_memcpy_likely_aligned_min32bytes_mult8bytes);
}
+
+ if (TT.getArch() == Triple::ArchType::msp430) {
+ setLibcallImplCallingConv(RTLIB::__mspabi_mpyll,
+ CallingConv::MSP430_BUILTIN);
+ }
}
bool RuntimeLibcallsInfo::darwinHasExp10(const Triple &TT) {
diff --git a/llvm/lib/Target/MSP430/MSP430ISelLowering.cpp b/llvm/lib/Target/MSP430/MSP430ISelLowering.cpp
index d558dd253dc46..0d7c7b5c7a813 100644
--- a/llvm/lib/Target/MSP430/MSP430ISelLowering.cpp
+++ b/llvm/lib/Target/MSP430/MSP430ISelLowering.cpp
@@ -208,8 +208,6 @@ MSP430TargetLowering::MSP430TargetLowering(const TargetMachine &TM,
for (const auto &LC : LibraryCalls) {
setLibcallImpl(LC.Op, LC.Impl);
}
- setLibcallImplCallingConv(RTLIB::__mspabi_mpyll,
- CallingConv::MSP430_BUILTIN);
}
setMinFunctionAlignment(Align(2));
|
RKSimon
approved these changes
Jun 27, 2025
As a temporary step configure the calling convention here. This can't be moved into tablegen until RuntimeLibcallsInfo is split into a separate lowering component.
9cbb4db
to
c7f71df
Compare
ff47400
to
78df650
Compare
asl
approved these changes
Jun 28, 2025
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.
As a temporary step configure the calling convention here. This
can't be moved into tablegen until RuntimeLibcallsInfo is split
into a separate lowering component.