aboutsummaryrefslogtreecommitdiffstats
path: root/runtime
diff options
context:
space:
mode:
authorDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-03-20 12:55:03 +0100
committerDavid Monniaux <david.monniaux@univ-grenoble-alpes.fr>2019-03-20 12:55:03 +0100
commit2638a022276c932ed00dc3f64b0e58bc0114a3d7 (patch)
treebc8beeb8f99d55ac3bf7012e858a0fae2d38bc31 /runtime
parent3718f2f520fc9a4dec2e9c1ac6eaf71f36f4f8a1 (diff)
downloadcompcert-kvx-2638a022276c932ed00dc3f64b0e58bc0114a3d7.tar.gz
compcert-kvx-2638a022276c932ed00dc3f64b0e58bc0114a3d7.zip
la division flottante fonctionne
Diffstat (limited to 'runtime')
-rw-r--r--runtime/mppa_k1c/Makefile3
-rw-r--r--runtime/mppa_k1c/i64_sdiv.c10
2 files changed, 12 insertions, 1 deletions
diff --git a/runtime/mppa_k1c/Makefile b/runtime/mppa_k1c/Makefile
index 9f2ba980..4e47f567 100644
--- a/runtime/mppa_k1c/Makefile
+++ b/runtime/mppa_k1c/Makefile
@@ -11,4 +11,5 @@ all: $(SFILES)
.SECONDARY:
%.s: %.c $(CCOMPPATH)
$(CCOMP) $(CFLAGS) -S $< -o $@
- sed -i -e 's/i64_/__compcert_i64_/g' -e 's/i32_/__compcert_i32_/g' $@
+ sed -i -e 's/i64_/__compcert_i64_/g' -e 's/i32_/__compcert_i32_/g' \
+ -e 's/f64_/__compcert_f64_/g' -e 's/f32_/__compcert_f32_/g' $@
diff --git a/runtime/mppa_k1c/i64_sdiv.c b/runtime/mppa_k1c/i64_sdiv.c
index e312f6e8..0b281d3e 100644
--- a/runtime/mppa_k1c/i64_sdiv.c
+++ b/runtime/mppa_k1c/i64_sdiv.c
@@ -40,4 +40,14 @@ int i32_sdiv (int a, int b)
{
return __divdi3 (a, b);
}
+
+extern double __divdf3(double, double);
+double f64_div(double a, double b) {
+ return __divdf3(a, b);
+}
+
+extern float __divsf3(float, float);
+float f32_div(float a, float b) {
+ return __divsf3(a, b);
+}
#endif