Skip to content

Commit 0a51bdd

Browse files
committed
Mark helper functions as inline
Mark the new intrinsic helper functions as inline to avoid linker issues.
1 parent 216709f commit 0a51bdd

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

llvm/include/llvm/IR/NVVMIntrinsicUtils.h

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ enum class TMAReductionOp : uint8_t {
3838
XOR = 7,
3939
};
4040

41-
bool IntrinsicShouldFTZ(Intrinsic::ID IntrinsicID) {
41+
inline bool IntrinsicShouldFTZ(Intrinsic::ID IntrinsicID) {
4242
switch (IntrinsicID) {
4343
// Float to i32 / i64 conversion intrinsics:
4444
case Intrinsic::nvvm_f2i_rm_ftz:
@@ -65,7 +65,7 @@ bool IntrinsicShouldFTZ(Intrinsic::ID IntrinsicID) {
6565
return false;
6666
}
6767

68-
bool IntrinsicConvertsToSignedInteger(Intrinsic::ID IntrinsicID) {
68+
inline bool IntrinsicConvertsToSignedInteger(Intrinsic::ID IntrinsicID) {
6969
switch (IntrinsicID) {
7070
// f2i
7171
case Intrinsic::nvvm_f2i_rm:
@@ -100,7 +100,8 @@ bool IntrinsicConvertsToSignedInteger(Intrinsic::ID IntrinsicID) {
100100
return false;
101101
}
102102

103-
APFloat::roundingMode IntrinsicGetRoundingMode(Intrinsic::ID IntrinsicID) {
103+
inline APFloat::roundingMode
104+
IntrinsicGetRoundingMode(Intrinsic::ID IntrinsicID) {
104105
switch (IntrinsicID) {
105106
// RM:
106107
case Intrinsic::nvvm_f2i_rm:

0 commit comments

Comments
 (0)