# HG changeset patch # User Christian Haeubl # Date 1359969005 -3600 # Node ID aa933ac2a7faa3b22080cf849353344363b7f664 # Parent 37b70037965632df9ad2dfed508b657ab10ead73 removed interpreter api diff -r 37b700379656 -r aa933ac2a7fa graal/com.oracle.graal.api.interpreter/overview.html --- a/graal/com.oracle.graal.api.interpreter/overview.html Mon Feb 04 10:06:08 2013 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,36 +0,0 @@ - - - - - - - - -Documentation for the com.oracle.graal.api.interpreter project. - - - diff -r 37b700379656 -r aa933ac2a7fa graal/com.oracle.graal.api.interpreter/src/com/oracle/graal/api/interpreter/Interpreter.java --- a/graal/com.oracle.graal.api.interpreter/src/com/oracle/graal/api/interpreter/Interpreter.java Mon Feb 04 10:06:08 2013 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,32 +0,0 @@ -/* - * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ -package com.oracle.graal.api.interpreter; - -import com.oracle.graal.api.meta.*; - -public interface Interpreter extends VirtualMachineComponent { - - boolean initialize(String args); - - Object execute(ResolvedJavaMethod method, Object... arguments) throws Throwable; -} diff -r 37b700379656 -r aa933ac2a7fa graal/com.oracle.graal.api.interpreter/src/com/oracle/graal/api/interpreter/RuntimeInterpreterInterface.java --- a/graal/com.oracle.graal.api.interpreter/src/com/oracle/graal/api/interpreter/RuntimeInterpreterInterface.java Mon Feb 04 10:06:08 2013 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,103 +0,0 @@ -/* - * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ -package com.oracle.graal.api.interpreter; - -import com.oracle.graal.api.meta.*; - -/** - * Please note: The parameters of the interface are currently in reversed order since it was derived - * from the java ByteCodeInterpreter implementation. There it was simpler to use the parameters in - * reversed order since they are popped from the stack in reversed order. - */ -public interface RuntimeInterpreterInterface { - - Object invoke(ResolvedJavaMethod method, Object... args); - - void monitorEnter(Object value); - - void monitorExit(Object value); - - Object newObject(ResolvedJavaType type) throws InstantiationException; - - Object getFieldObject(Object base, ResolvedJavaField field); - - boolean getFieldBoolean(Object base, ResolvedJavaField field); - - byte getFieldByte(Object base, ResolvedJavaField field); - - char getFieldChar(Object base, ResolvedJavaField field); - - short getFieldShort(Object base, ResolvedJavaField field); - - int getFieldInt(Object base, ResolvedJavaField field); - - long getFieldLong(Object base, ResolvedJavaField field); - - double getFieldDouble(Object base, ResolvedJavaField field); - - float getFieldFloat(Object base, ResolvedJavaField field); - - void setFieldObject(Object value, Object base, ResolvedJavaField field); - - void setFieldInt(int value, Object base, ResolvedJavaField field); - - void setFieldFloat(float value, Object base, ResolvedJavaField field); - - void setFieldDouble(double value, Object base, ResolvedJavaField field); - - void setFieldLong(long value, Object base, ResolvedJavaField field); - - byte getArrayByte(long index, Object array); - - char getArrayChar(long index, Object array); - - short getArrayShort(long index, Object array); - - int getArrayInt(long index, Object array); - - long getArrayLong(long index, Object array); - - double getArrayDouble(long index, Object array); - - float getArrayFloat(long index, Object array); - - Object getArrayObject(long index, Object array); - - void setArrayByte(byte value, long index, Object array); - - void setArrayChar(char value, long index, Object array); - - void setArrayShort(short value, long index, Object array); - - void setArrayInt(int value, long index, Object array); - - void setArrayLong(long value, long index, Object array); - - void setArrayFloat(float value, long index, Object array); - - void setArrayDouble(double value, long index, Object array); - - void setArrayObject(Object value, long index, Object array); - - Class getMirror(ResolvedJavaType type); -} diff -r 37b700379656 -r aa933ac2a7fa graal/com.oracle.graal.api.interpreter/src/com/oracle/graal/api/interpreter/VirtualMachineComponent.java --- a/graal/com.oracle.graal.api.interpreter/src/com/oracle/graal/api/interpreter/VirtualMachineComponent.java Mon Feb 04 10:06:08 2013 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,28 +0,0 @@ -/* - * Copyright (c) 2012, 2012, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ -package com.oracle.graal.api.interpreter; - -public interface VirtualMachineComponent { - - void setOption(String name, String value); -} diff -r 37b700379656 -r aa933ac2a7fa graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotGraalRuntime.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotGraalRuntime.java Mon Feb 04 10:06:08 2013 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotGraalRuntime.java Mon Feb 04 10:10:05 2013 +0100 @@ -28,7 +28,6 @@ import java.util.*; import com.oracle.graal.api.code.*; -import com.oracle.graal.api.interpreter.*; import com.oracle.graal.api.meta.*; import com.oracle.graal.api.runtime.*; import com.oracle.graal.compiler.*; @@ -265,9 +264,6 @@ if (clazz == GraalCompiler.class) { return (T) getCompiler(); } - if (clazz == RuntimeInterpreterInterface.class) { - return (T) getRuntimeInterpreterInterface(); - } return null; } } diff -r 37b700379656 -r aa933ac2a7fa graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotRuntimeInterpreterInterface.java --- a/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotRuntimeInterpreterInterface.java Mon Feb 04 10:06:08 2013 +0100 +++ b/graal/com.oracle.graal.hotspot/src/com/oracle/graal/hotspot/HotSpotRuntimeInterpreterInterface.java Mon Feb 04 10:10:05 2013 +0100 @@ -28,11 +28,10 @@ import sun.misc.*; -import com.oracle.graal.api.interpreter.*; import com.oracle.graal.api.meta.*; import com.oracle.graal.hotspot.meta.*; -public class HotSpotRuntimeInterpreterInterface implements RuntimeInterpreterInterface { +public class HotSpotRuntimeInterpreterInterface { private final MetaAccessProvider metaProvider;