1 /* src/vm/builtintable.inc - tables of builtin functions
3 Copyright (C) 1996-2005, 2006, 2007 R. Grafl, A. Krall, C. Kruegel,
4 C. Oates, R. Obermaisser, M. Platter, M. Probst, S. Ring,
5 E. Steiner, C. Thalinger, D. Thuernbeck, P. Tomsich, C. Ullrich,
6 J. Wenninger, Institut f. Computersprachen - TU Wien
8 This file is part of CACAO.
10 This program is free software; you can redistribute it and/or
11 modify it under the terms of the GNU General Public License as
12 published by the Free Software Foundation; either version 2, or (at
13 your option) any later version.
15 This program is distributed in the hope that it will be useful, but
16 WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 General Public License for more details.
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
25 $Id: builtintable.inc 8210 2007-07-18 12:51:00Z twisti $
34 #if defined(ENABLE_THREADS)
35 # include "threads/native/lock.h"
38 #include "vm/builtin.h"
39 #include "vm/jit/jit.h"
42 /* internal and not automatically replaced functions **************************/
44 static builtintable_entry builtintable_internal[] = {
46 #if defined(__ALPHA__) || defined(DISABLE_GC)
97 #if !SUPPORT_DIVISION || defined(DISABLE_GC)
124 #if !(SUPPORT_DIVISION && SUPPORT_LONG && SUPPORT_LONG_DIV) || defined(DISABLE_GC)
177 /* internal functions *****************************************************/
184 "(Ljava/lang/Class;)Ljava/lang/Object;",
196 "(ILjava/lang/Class;)[Ljava/lang/Object;",
205 BUILTIN_newarray_boolean,
217 BUILTIN_newarray_byte,
229 BUILTIN_newarray_char,
241 BUILTIN_newarray_short,
253 BUILTIN_newarray_int,
265 BUILTIN_newarray_long,
277 BUILTIN_newarray_float,
289 BUILTIN_newarray_double,
301 BUILTIN_arraycheckcast,
304 "([Ljava/lang/Object;[Ljava/lang/Object;)[Ljava/lang/Object;",
313 BUILTIN_arrayinstanceof,
316 "([Ljava/lang/Object;[Ljava/lang/Object;)I",
328 "([Ljava/lang/Object;Ljava/lang/Object;)I",
336 #if defined(ENABLE_THREADS)
342 "(Ljava/lang/Object;)V",
354 "(Ljava/lang/Object;)V",
381 /* automatically replaced functions *******************************************/
383 static builtintable_entry builtintable_automatic[] = {
385 #if !(SUPPORT_LONG && SUPPORT_LONG_CMP)
400 #if !(SUPPORT_LONG && SUPPORT_LONG_LOGICAL)
437 #endif /* !(SUPPORT_LONG && SUPPORT_LONG_LOGICAL) */
439 #if !(SUPPORT_LONG && SUPPORT_LONG_SHIFT)
476 #endif /* !(SUPPORT_LONG && SUPPORT_LONG_SHIFT) */
478 #if !(SUPPORT_LONG && SUPPORT_LONG_ADD)
515 #endif /* !(SUPPORT_LONG && SUPPORT_LONG_ADD) */
517 #if !(SUPPORT_LONG && SUPPORT_LONG_MUL)
532 #if !(SUPPORT_FLOAT && SUPPORT_I2F)
547 #if !(SUPPORT_DOUBLE && SUPPORT_I2D)
562 #if !(SUPPORT_LONG && SUPPORT_FLOAT && SUPPORT_L2F)
577 #if !(SUPPORT_LONG && SUPPORT_DOUBLE && SUPPORT_L2D)
592 #if !(SUPPORT_FLOAT && SUPPORT_F2I)
607 #if !(SUPPORT_FLOAT && SUPPORT_LONG && SUPPORT_F2L)
622 #if !(SUPPORT_DOUBLE && SUPPORT_D2I)
637 #if !(SUPPORT_DOUBLE && SUPPORT_LONG && SUPPORT_D2L)
653 /* float functions ********************************************************/
716 #endif /* !SUPPORT_FLOAT */
718 #if !SUPPORT_FLOAT || !SUPPORT_FLOAT_CMP
743 #endif /* !SUPPORT_FLOAT || !SUPPORT_FLOAT_CMP */
746 /* double functions *******************************************************/
809 #endif /* !SUPPORT_DOUBLE */
811 #if !SUPPORT_DOUBLE || !SUPPORT_DOUBLE_CMP
836 #endif /* !SUPPORT_DOUBLE || !SUPPORT_DOUBLE_CMP */
839 /* float/double functions *************************************************/
841 #if !(SUPPORT_FLOAT && SUPPORT_DOUBLE)
866 #endif /* !(SUPPORT_FLOAT && SUPPORT_DOUBLE) */
869 /* prevent a compiler warning if everything is supported (e.g. i386) */
886 /* automatically replaced functions *******************************************/
888 static builtintable_entry builtintable_function[] = {
889 #if defined(ENABLE_JIT)
891 /* java.lang.VMSystem.arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V STATIC NATIVE */
896 "java/lang/VMSystem",
898 "(Ljava/lang/Object;ILjava/lang/Object;II)V",
906 /* java.lang.System.arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V PUBLIC STATIC */
909 /* We disable this one until we have a fix for the stacktrace
917 "(Ljava/lang/Object;ILjava/lang/Object;II)V",
926 /* java.lang.VMSystem.currentTimeMillis()J PUBLIC STATIC */
930 BUILTIN_currenttimemillis,
931 "java/lang/VMSystem",
941 /* java.lang.System.currentTimeMillis()J PUBLIC STATIC */
945 BUILTIN_currenttimemillis,
956 #endif /* defined(ENABLE_JIT) */
976 * These are local overrides for various environment variables in Emacs.
977 * Please do not remove this and leave it at the end of the file, where
978 * Emacs will automagically detect them.
979 * ---------------------------------------------------------------------
982 * indent-tabs-mode: t