* Updated header: Added 2006. Changed address of FSF. Changed email
[cacao.git] / src / vm / builtintable.inc
index 1f4852bd194176c4d0089e6dde2f0e82d15e7a11..e6f4ca829e3f4664069a47ece66839af7eff4dcf 100644 (file)
@@ -1,9 +1,9 @@
 /* src/vm/builtintable.inc - tables of builtin functions
 
-   Copyright (C) 1996-2005 R. Grafl, A. Krall, C. Kruegel, C. Oates,
-   R. Obermaisser, M. Platter, M. Probst, S. Ring, E. Steiner,
-   C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich, J. Wenninger,
-   Institut f. Computersprachen - TU Wien
+   Copyright (C) 1996-2005, 2006 R. Grafl, A. Krall, C. Kruegel,
+   C. Oates, R. Obermaisser, M. Platter, M. Probst, S. Ring,
+   E. Steiner, C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich,
+   J. Wenninger, Institut f. Computersprachen - TU Wien
 
    This file is part of CACAO.
 
 
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
-   Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
-   02111-1307, USA.
+   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+   02110-1301, USA.
 
-   Contact: cacao@complang.tuwien.ac.at
+   Contact: cacao@cacaojvm.org
 
    Authors: Christian Thalinger
 
    Changes:
 
-   $Id: builtintable.inc 2545 2005-06-06 14:35:29Z twisti $
+   $Id: builtintable.inc 4357 2006-01-22 23:33:38Z twisti $
 
 */
 
 
 static builtintable_entry builtintable_internal[] = {
 
-#if defined(__ALPHA__)
+#if defined(__ALPHA__) || defined(DISABLE_GC)
        {
                ICMD_F2L,
                BUILTIN_f2l,
-               "(F)L",
+               "(F)J",
                "f2l",
                NULL
        },
        {
                ICMD_D2L,
                BUILTIN_d2l,
-               "(D)L",
+               "(D)J",
                "d2l",
                NULL
        },
@@ -74,8 +74,7 @@ static builtintable_entry builtintable_internal[] = {
        },
 #endif
 
-
-#if !SUPPORT_DIVISION
+#if !SUPPORT_DIVISION || defined(DISABLE_GC)
        {
                ICMD_IDIV,
                BUILTIN_idiv,
@@ -92,7 +91,7 @@ static builtintable_entry builtintable_internal[] = {
        },
 #endif
 
-#if !(SUPPORT_DIVISION && SUPPORT_LONG && SUPPORT_LONG_DIV)
+#if !(SUPPORT_DIVISION && SUPPORT_LONG && SUPPORT_LONG_DIV) || defined(DISABLE_GC)
        {
                ICMD_LDIV,
                BUILTIN_ldiv,
@@ -213,9 +212,9 @@ static builtintable_entry builtintable_internal[] = {
        },
        {
                ICMD_AASTORE,
-               BUILTIN_aastore,
-               "([Ljava/lang/Object;ILjava/lang/Object;)V",
-               "aastore",
+               BUILTIN_canstore,
+               "([Ljava/lang/Object;Ljava/lang/Object;)I",
+               "canstore",
                NULL
        },
 
@@ -235,38 +234,6 @@ static builtintable_entry builtintable_internal[] = {
                NULL
        },
 #endif
-
-
-       /* assembler code patching functions **************************************/
-
-       {
-               ICMD_NEW,
-               PATCHER_builtin_new,
-               "(Ljava/lang/Class;)Ljava/lang/Object;",
-               "new (NOT RESOLVED)",
-               NULL
-       },
-       {
-               ICMD_ANEWARRAY,
-               PATCHER_builtin_newarray,
-               "(ILjava/lang/Class;)[Ljava/lang/Object;",
-               "newarray (NOT RESOLVED)",
-               NULL
-       },
-       {
-               ICMD_CHECKCAST,
-               PATCHER_builtin_arraycheckcast,
-               "([Ljava/lang/Class;[Ljava/lang/Class;)[Ljava/lang/Object;",
-               "arraycheckcast (NOT RESOLVED)",
-               NULL
-       },
-       {
-               ICMD_INSTANCEOF,
-               PATCHER_builtin_arrayinstanceof,
-               "([Ljava/lang/Class;[Ljava/lang/Class;)I",
-               "arrayinstanceof (NOT RESOLVED)",
-               NULL
-       },
 };
 
 
@@ -366,7 +333,7 @@ static builtintable_entry builtintable_automatic[] = {
        },
 #endif
 
-#if !(SUPPORT_FLOAT && SUPPORT_IFCVT)
+#if !(SUPPORT_FLOAT && SUPPORT_I2F)
        {
                ICMD_I2F,
                BUILTIN_i2f,
@@ -376,7 +343,7 @@ static builtintable_entry builtintable_automatic[] = {
        },
 #endif
 
-#if !(SUPPORT_DOUBLE && SUPPORT_IFCVT)
+#if !(SUPPORT_DOUBLE && SUPPORT_I2D)
        {
                ICMD_I2D,
                BUILTIN_i2d,
@@ -386,27 +353,7 @@ static builtintable_entry builtintable_automatic[] = {
        },
 #endif
 
-#if !(SUPPORT_FLOAT && SUPPORT_FICVT)
-       {
-               ICMD_F2I,
-               BUILTIN_f2i,
-               "(F)I",
-               "f2i",
-               NULL
-       },
-#endif
-
-#if !(SUPPORT_DOUBLE && SUPPORT_FICVT)
-       {
-               ICMD_D2I,
-               BUILTIN_d2i,
-               "(D)I",
-               "d2i",
-               NULL
-       },
-#endif
-
-#if !(SUPPORT_LONG && SUPPORT_FLOAT && SUPPORT_LONG_FCVT)
+#if !(SUPPORT_LONG && SUPPORT_FLOAT && SUPPORT_L2F)
        {
                ICMD_L2F,
                BUILTIN_l2f,
@@ -416,7 +363,7 @@ static builtintable_entry builtintable_automatic[] = {
        },
 #endif
 
-#if !(SUPPORT_LONG && SUPPORT_DOUBLE && SUPPORT_LONG_FCVT)
+#if !(SUPPORT_LONG && SUPPORT_DOUBLE && SUPPORT_L2D)
        {
                ICMD_L2D,
                BUILTIN_l2d,
@@ -426,7 +373,17 @@ static builtintable_entry builtintable_automatic[] = {
        },
 #endif
 
-#if !(SUPPORT_FLOAT && SUPPORT_LONG && SUPPORT_LONG_ICVT)
+#if !(SUPPORT_FLOAT && SUPPORT_F2I)
+       {
+               ICMD_F2I,
+               BUILTIN_f2i,
+               "(F)I",
+               "f2i",
+               NULL
+       },
+#endif
+
+#if !(SUPPORT_FLOAT && SUPPORT_LONG && SUPPORT_F2L)
        {
                ICMD_F2L,
                BUILTIN_f2l,
@@ -436,7 +393,17 @@ static builtintable_entry builtintable_automatic[] = {
        },
 #endif
 
-#if !(SUPPORT_DOUBLE && SUPPORT_LONG && SUPPORT_LONG_ICVT)
+#if !(SUPPORT_DOUBLE && SUPPORT_D2I)
+       {
+               ICMD_D2I,
+               BUILTIN_d2i,
+               "(D)I",
+               "d2i",
+               NULL
+       },
+#endif
+
+#if !(SUPPORT_DOUBLE && SUPPORT_LONG && SUPPORT_D2L)
        {
                ICMD_D2L,
                BUILTIN_d2l,
@@ -575,6 +542,17 @@ static builtintable_entry builtintable_automatic[] = {
                NULL
        },
 #endif /* !(SUPPORT_FLOAT && SUPPORT_DOUBLE) */
+
+
+       /* prevent a compiler warning if everything is supported (e.g. i386) */
+
+       {
+               255,
+               NULL,
+               NULL,
+               NULL,
+               NULL
+       },
 };