]> git.unchartedbackwaters.co.uk Git - francis/libjit.git/commitdiff
dpas_type_identical: treat "float64" and "nfloat" as identical on
authorRhys Weatherley <rweather@southern-storm.com.au>
Thu, 27 May 2004 01:05:30 +0000 (01:05 +0000)
committerRhys Weatherley <rweather@southern-storm.com.au>
Thu, 27 May 2004 01:05:30 +0000 (01:05 +0000)
platforms whose "long double" type is the same as "double".

ChangeLog
dpas/dpas-types.c

index 278cd42b36ea8b21c1c57243fbeb04f99f297752..5a8147e2884716911bb719c77917c3c92b7a479d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -6,6 +6,10 @@
        the generation of "jit_apply_builder_align_regs" that affected
        ARM and PPC systems.
 
+       * dpas/dpas-types.c (dpas_type_identical): treat "float64" and
+       "nfloat" as identical on platforms whose "long double" type is
+       the same as "double".
+
 2004-05-26  Rhys Weatherley  <rweather@southern-storm.com.au>
 
        * jit/jit-insn.c, jit/jit-rules-x86.c, jit/jit-rules-x86.sel,
index 910c32ae9c3a94d51cfda4f4acdc3c895d1ecd90..696ad6bb5a9ab7deafb5c51a2df24835e01ea040 100644 (file)
@@ -1245,6 +1245,15 @@ int dpas_type_identical(jit_type_t type1, jit_type_t type2, int normalize)
        }
        if(jit_type_get_kind(type1) != jit_type_get_kind(type2))
        {
+#ifdef JIT_NFLOAT_IS_DOUBLE
+               if((jit_type_get_kind(type1) == JIT_TYPE_FLOAT64 ||
+                   jit_type_get_kind(type1) == JIT_TYPE_NFLOAT) &&
+                  (jit_type_get_kind(type2) == JIT_TYPE_FLOAT64 ||
+                   jit_type_get_kind(type2) == JIT_TYPE_NFLOAT))
+               {
+                       return 1;
+               }
+#endif
                return 0;
        }
        switch(jit_type_get_kind(type1))