Skip to content

Commit 206c608

Browse files
authored
Merge pull request #579 from heiher/loongarch64-musl
Add compiler-rt fallbacks on loongarch64-musl
2 parents f8cd410 + 8dc0e28 commit 206c608

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

build.rs

+18
Original file line numberDiff line numberDiff line change
@@ -514,6 +514,24 @@ mod c {
514514
]);
515515
}
516516

517+
if target_arch == "loongarch64" {
518+
sources.extend(&[
519+
("__extenddftf2", "extenddftf2.c"),
520+
("__netf2", "comparetf2.c"),
521+
("__addtf3", "addtf3.c"),
522+
("__multf3", "multf3.c"),
523+
("__subtf3", "subtf3.c"),
524+
("__fixtfsi", "fixtfsi.c"),
525+
("__floatsitf", "floatsitf.c"),
526+
("__fixunstfsi", "fixunstfsi.c"),
527+
("__floatunsitf", "floatunsitf.c"),
528+
("__fe_getround", "fp_mode.c"),
529+
("__divtf3", "divtf3.c"),
530+
("__trunctfdf2", "trunctfdf2.c"),
531+
("__trunctfsf2", "trunctfsf2.c"),
532+
]);
533+
}
534+
517535
// Remove the assembly implementations that won't compile for the target
518536
if llvm_target[0] == "thumbv6m" || llvm_target[0] == "thumbv8m.base" || target_os == "uefi"
519537
{

0 commit comments

Comments
 (0)