rename JNIEXPORT to AVIAN_EXPORT in common.h, to avoid conflicting with jni.h

This commit is contained in:
Joshua Warner 2013-11-08 08:35:10 -07:00
parent fd81e126ef
commit 2800ffe826
13 changed files with 453 additions and 454 deletions

View File

@ -192,7 +192,7 @@ sysAbort(System* s)
// #endif // not NDEBUG
JNIEXPORT System*
AVIAN_EXPORT System*
makeSystem(const char* crashDumpDirectory);
} // namespace vm

View File

@ -142,12 +142,11 @@ typedef intptr_t __attribute__((__may_alias__)) intptr_alias_t;
#endif // not _MSC_VER
#undef JNIEXPORT
#ifdef PLATFORM_WINDOWS
# define JNIEXPORT __declspec(dllexport)
# define AVIAN_EXPORT __declspec(dllexport)
# define PATH_SEPARATOR ';'
#else // not PLATFORM_WINDOWS
# define JNIEXPORT __attribute__ ((visibility("default"))) \
# define AVIAN_EXPORT __attribute__ ((visibility("default"))) \
__attribute__ ((used))
# define PATH_SEPARATOR ':'
#endif // not PLATFORM_WINDOWS

View File

@ -174,7 +174,7 @@ class Finder {
virtual void dispose() = 0;
};
JNIEXPORT Finder*
AVIAN_EXPORT Finder*
makeFinder(System* s, Allocator* a, const char* path, const char* bootLibrary);
Finder*

View File

@ -2699,10 +2699,10 @@ popResources(Thread* t);
} // namespace vm
JNIEXPORT void
AVIAN_EXPORT void
vmPrintTrace(vm::Thread* t);
JNIEXPORT void
AVIAN_EXPORT void
vmfPrintTrace(vm::Thread* t, FILE* out);
namespace vm {
@ -3971,7 +3971,7 @@ errorLog(Thread* t)
} // namespace vm
JNIEXPORT void*
AVIAN_EXPORT void*
vmAddressFromLine(vm::Thread* t, vm::object m, unsigned line);
#endif//MACHINE_H

View File

@ -50,7 +50,7 @@ resolveSystemClassThrow(Thread* t, object loader, object spec)
} // namespace
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Classes_initialize
(Thread* t, object, uintptr_t* arguments)
{
@ -59,21 +59,21 @@ Avian_avian_Classes_initialize
initClass(t, this_);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Classes_acquireClassLock
(Thread* t, object, uintptr_t*)
{
acquire(t, t->m->classLock);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Classes_releaseClassLock
(Thread* t, object, uintptr_t*)
{
release(t, t->m->classLock);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_resolveVMClass
(Thread* t, object, uintptr_t* arguments)
{
@ -84,7 +84,7 @@ Avian_avian_Classes_resolveVMClass
(resolveClass(t, loader, spec, true, Machine::ClassNotFoundExceptionType));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_defineVMClass
(Thread* t, object, uintptr_t* arguments)
{
@ -104,7 +104,7 @@ Avian_avian_Classes_defineVMClass
return reinterpret_cast<int64_t>(defineClass(t, loader, buffer, length));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_SystemClassLoader_findLoadedVMClass
(Thread* t, object, uintptr_t* arguments)
{
@ -114,7 +114,7 @@ Avian_avian_SystemClassLoader_findLoadedVMClass
return search(t, loader, name, findLoadedClass, true);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_SystemClassLoader_vmClass
(Thread* t, object, uintptr_t* arguments)
{
@ -122,7 +122,7 @@ Avian_avian_SystemClassLoader_vmClass
(jclassVmClass(t, reinterpret_cast<object>(arguments[0])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_SystemClassLoader_findVMClass
(Thread* t, object, uintptr_t* arguments)
{
@ -132,7 +132,7 @@ Avian_avian_SystemClassLoader_findVMClass
return search(t, loader, name, resolveSystemClassThrow, true);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_SystemClassLoader_resourceURLPrefix
(Thread* t, object, uintptr_t* arguments)
{
@ -152,7 +152,7 @@ Avian_avian_SystemClassLoader_resourceURLPrefix
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_SystemClassLoader_00024ResourceEnumeration_nextResourceURLPrefix
(Thread* t, object, uintptr_t* arguments)
{
@ -176,7 +176,7 @@ Avian_avian_SystemClassLoader_00024ResourceEnumeration_nextResourceURLPrefix
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_SystemClassLoader_getClass
(Thread* t, object, uintptr_t* arguments)
{
@ -186,7 +186,7 @@ Avian_avian_SystemClassLoader_getClass
#ifdef AVIAN_HEAPDUMP
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Machine_dumpHeap
(Thread* t, object, uintptr_t* arguments)
{
@ -209,7 +209,7 @@ Avian_avian_Machine_dumpHeap
#endif//AVIAN_HEAPDUMP
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Runtime_exit
(Thread* t, object, uintptr_t* arguments)
{
@ -218,7 +218,7 @@ Avian_java_lang_Runtime_exit
t->m->system->exit(arguments[1]);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_avianvmresource_Handler_00024ResourceInputStream_getContentLength
(Thread* t, object, uintptr_t* arguments)
{
@ -242,7 +242,7 @@ Avian_avian_avianvmresource_Handler_00024ResourceInputStream_getContentLength
return -1;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_avianvmresource_Handler_00024ResourceInputStream_open
(Thread* t, object, uintptr_t* arguments)
{
@ -263,7 +263,7 @@ Avian_avian_avianvmresource_Handler_00024ResourceInputStream_open
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_avianvmresource_Handler_00024ResourceInputStream_available
(Thread*, object, uintptr_t* arguments)
{
@ -274,7 +274,7 @@ Avian_avian_avianvmresource_Handler_00024ResourceInputStream_available
return static_cast<jint>(region->length()) - position;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_avianvmresource_Handler_00024ResourceInputStream_read__JI
(Thread*, object, uintptr_t* arguments)
{
@ -289,7 +289,7 @@ Avian_avian_avianvmresource_Handler_00024ResourceInputStream_read__JI
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_avianvmresource_Handler_00024ResourceInputStream_read__JI_3BII
(Thread* t, object, uintptr_t* arguments)
{
@ -314,7 +314,7 @@ Avian_avian_avianvmresource_Handler_00024ResourceInputStream_read__JI_3BII
}
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_avianvmresource_Handler_00024ResourceInputStream_close
(Thread*, object, uintptr_t* arguments)
{
@ -322,7 +322,7 @@ Avian_avian_avianvmresource_Handler_00024ResourceInputStream_close
reinterpret_cast<System::Region*>(peer)->dispose();
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Continuations_callWithCurrentContinuation
(Thread* t, object, uintptr_t* arguments)
{
@ -332,7 +332,7 @@ Avian_avian_Continuations_callWithCurrentContinuation
abort(t);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Continuations_dynamicWind2
(Thread* t, object, uintptr_t* arguments)
{
@ -344,7 +344,7 @@ Avian_avian_Continuations_dynamicWind2
abort(t);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Continuations_00024Continuation_handleResult
(Thread* t, object, uintptr_t* arguments)
{
@ -355,7 +355,7 @@ Avian_avian_Continuations_00024Continuation_handleResult
abort(t);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_avian_Continuations_00024Continuation_handleException
(Thread* t, object, uintptr_t* arguments)
{
@ -366,7 +366,7 @@ Avian_avian_Continuations_00024Continuation_handleException
abort(t);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Singleton_getObject
(Thread* t, object, uintptr_t* arguments)
{
@ -374,7 +374,7 @@ Avian_avian_Singleton_getObject
(singletonObject(t, reinterpret_cast<object>(arguments[0]), arguments[1]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Singleton_getInt
(Thread* t, object, uintptr_t* arguments)
{
@ -382,7 +382,7 @@ Avian_avian_Singleton_getInt
(t, reinterpret_cast<object>(arguments[0]), arguments[1]);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Singleton_getLong
(Thread* t, object, uintptr_t* arguments)
{
@ -392,7 +392,7 @@ Avian_avian_Singleton_getLong
return v;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_allocateMemory
(Thread* t, object, uintptr_t* arguments)
{
@ -405,7 +405,7 @@ Avian_sun_misc_Unsafe_allocateMemory
}
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_freeMemory
(Thread*, object, uintptr_t* arguments)
{
@ -415,7 +415,7 @@ Avian_sun_misc_Unsafe_freeMemory
}
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_setMemory
(Thread* t, object, uintptr_t* arguments)
{
@ -439,7 +439,7 @@ Avian_sun_misc_Unsafe_setMemory
// interpreter. The JIT/AOT compiler implements them as intrinsics,
// so these versions will be ignored.
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putByte__JB
(Thread*, object, uintptr_t* arguments)
{
@ -449,7 +449,7 @@ Avian_sun_misc_Unsafe_putByte__JB
*reinterpret_cast<int8_t*>(p) = v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putShort__JS
(Thread*, object, uintptr_t* arguments)
{
@ -459,14 +459,14 @@ Avian_sun_misc_Unsafe_putShort__JS
*reinterpret_cast<int16_t*>(p) = v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putChar__JC
(Thread* t, object method, uintptr_t* arguments)
{
Avian_sun_misc_Unsafe_putShort__JS(t, method, arguments);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putInt__JI
(Thread*, object, uintptr_t* arguments)
{
@ -476,14 +476,14 @@ Avian_sun_misc_Unsafe_putInt__JI
*reinterpret_cast<int32_t*>(p) = v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putFloat__JF
(Thread* t, object method, uintptr_t* arguments)
{
Avian_sun_misc_Unsafe_putInt__JI(t, method, arguments);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putLong__JJ
(Thread*, object, uintptr_t* arguments)
{
@ -493,14 +493,14 @@ Avian_sun_misc_Unsafe_putLong__JJ
*reinterpret_cast<int64_t*>(p) = v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putDouble__JD
(Thread* t, object method, uintptr_t* arguments)
{
Avian_sun_misc_Unsafe_putLong__JJ(t, method, arguments);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putAddress__JJ
(Thread*, object, uintptr_t* arguments)
{
@ -510,7 +510,7 @@ Avian_sun_misc_Unsafe_putAddress__JJ
*reinterpret_cast<intptr_t*>(p) = v;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getByte__J
(Thread*, object, uintptr_t* arguments)
{
@ -519,7 +519,7 @@ Avian_sun_misc_Unsafe_getByte__J
return *reinterpret_cast<int8_t*>(p);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getShort__J
(Thread*, object, uintptr_t* arguments)
{
@ -528,14 +528,14 @@ Avian_sun_misc_Unsafe_getShort__J
return *reinterpret_cast<int16_t*>(p);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getChar__J
(Thread* t, object method, uintptr_t* arguments)
{
return Avian_sun_misc_Unsafe_getShort__J(t, method, arguments);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getInt__J
(Thread*, object, uintptr_t* arguments)
{
@ -544,14 +544,14 @@ Avian_sun_misc_Unsafe_getInt__J
return *reinterpret_cast<int32_t*>(p);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getFloat__J
(Thread* t, object method, uintptr_t* arguments)
{
return Avian_sun_misc_Unsafe_getInt__J(t, method, arguments);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getLong__J
(Thread*, object, uintptr_t* arguments)
{
@ -560,14 +560,14 @@ Avian_sun_misc_Unsafe_getLong__J
return *reinterpret_cast<int64_t*>(p);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getDouble__J
(Thread* t, object method, uintptr_t* arguments)
{
return Avian_sun_misc_Unsafe_getLong__J(t, method, arguments);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getAddress__J
(Thread*, object, uintptr_t* arguments)
{
@ -576,7 +576,7 @@ Avian_sun_misc_Unsafe_getAddress__J
return *reinterpret_cast<intptr_t*>(p);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_copyMemory
(Thread* t, object, uintptr_t* arguments)
{
@ -602,14 +602,14 @@ Avian_sun_misc_Unsafe_copyMemory
memcpy(dst, src, count);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_arrayBaseOffset
(Thread*, object, uintptr_t*)
{
return ArrayBody;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_nio_FixedArrayByteBuffer_allocateFixed
(Thread* t, object, uintptr_t* arguments)
{
@ -628,7 +628,7 @@ Avian_java_nio_FixedArrayByteBuffer_allocateFixed
return reinterpret_cast<intptr_t>(array);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_getObject
(Thread*, object, uintptr_t* arguments)
{
@ -638,7 +638,7 @@ Avian_sun_misc_Unsafe_getObject
return fieldAtOffset<uintptr_t>(o, offset);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putObject
(Thread* t, object, uintptr_t* arguments)
{
@ -649,7 +649,7 @@ Avian_sun_misc_Unsafe_putObject
set(t, o, offset, reinterpret_cast<object>(value));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_compareAndSwapObject
(Thread* t, object, uintptr_t* arguments)
{
@ -668,7 +668,7 @@ Avian_sun_misc_Unsafe_compareAndSwapObject
return success;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_compareAndSwapInt
(Thread*, object, uintptr_t* arguments)
{
@ -681,7 +681,7 @@ Avian_sun_misc_Unsafe_compareAndSwapInt
(&fieldAtOffset<uint32_t>(target, offset), expect, update);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_unpark
(Thread* t, object, uintptr_t* arguments)
{
@ -693,7 +693,7 @@ Avian_sun_misc_Unsafe_unpark
monitorRelease(t, interruptLock(t, thread));
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_park
(Thread* t, object, uintptr_t* arguments)
{
@ -737,7 +737,7 @@ Avian_sun_misc_Unsafe_park
monitorRelease(t, interruptLock(t, t->javaThread));
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putIntVolatile
(Thread*, object, uintptr_t* arguments)
{
@ -750,14 +750,14 @@ Avian_sun_misc_Unsafe_putIntVolatile
storeLoadMemoryBarrier();
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_sun_misc_Unsafe_putOrderedInt
(Thread* t, object method, uintptr_t* arguments)
{
Avian_sun_misc_Unsafe_putIntVolatile(t, method, arguments);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_primitiveClass
(Thread* t, object, uintptr_t* arguments)
{

View File

@ -25,7 +25,7 @@ extern "C" int JNI_OnLoad(JavaVM*, void*);
using namespace vm;
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_defineVMClass
(Thread*, object, uintptr_t*);
@ -752,7 +752,7 @@ register_org_apache_harmony_dalvik_NativeTestTarget(_JNIEnv*)
return 0;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_String_compareTo
(Thread* t, object, uintptr_t* arguments)
{
@ -774,28 +774,28 @@ Avian_java_lang_String_compareTo
return stringLength(t, a) - stringLength(t, b);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_String_isEmpty
(Thread* t, object, uintptr_t* arguments)
{
return stringLength(t, reinterpret_cast<object>(arguments[0])) == 0;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_String_length
(Thread* t, object, uintptr_t* arguments)
{
return stringLength(t, reinterpret_cast<object>(arguments[0]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_String_charAt
(Thread* t, object, uintptr_t* arguments)
{
return stringCharAt(t, reinterpret_cast<object>(arguments[0]), arguments[1]);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_String_equals
(Thread* t, object, uintptr_t* arguments)
{
@ -804,7 +804,7 @@ Avian_java_lang_String_equals
reinterpret_cast<object>(arguments[1]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_String_fastIndexOf
(Thread* t, object, uintptr_t* arguments)
{
@ -821,7 +821,7 @@ Avian_java_lang_String_fastIndexOf
return -1;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getInterfaces
(Thread* t, object, uintptr_t* arguments)
{
@ -849,7 +849,7 @@ Avian_java_lang_Class_getInterfaces
(makeObjectArray(t, type(t, Machine::JclassType), 0));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_newInstanceImpl
(Thread* t, object, uintptr_t* arguments)
{
@ -866,7 +866,7 @@ Avian_java_lang_Class_newInstanceImpl
return reinterpret_cast<uintptr_t>(instance);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getComponentType
(Thread* t, object, uintptr_t* arguments)
{
@ -886,7 +886,7 @@ Avian_java_lang_Class_getComponentType
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_classForName
(Thread* t, object, uintptr_t* arguments)
{
@ -905,7 +905,7 @@ Avian_java_lang_Class_classForName
(t, method, 0, name, static_cast<int>(arguments[1]), loader));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getDeclaredField
(Thread* t, object, uintptr_t* arguments)
{
@ -930,7 +930,7 @@ Avian_java_lang_Class_getDeclaredField
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getDeclaredConstructorOrMethod
(Thread* t, object, uintptr_t* arguments)
{
@ -959,11 +959,11 @@ Avian_java_lang_Class_getDeclaredConstructorOrMethod
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_SystemClassLoader_findLoadedVMClass
(Thread*, object, uintptr_t*);
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_VMClassLoader_findLoadedClass
(Thread* t, object method, uintptr_t* arguments)
{
@ -978,7 +978,7 @@ Avian_java_lang_VMClassLoader_findLoadedClass
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_VMClassLoader_defineClass__Ljava_lang_ClassLoader_2Ljava_lang_String_2_3BII
(Thread* t, object method, uintptr_t* arguments)
{
@ -995,28 +995,28 @@ Avian_java_lang_VMClassLoader_defineClass__Ljava_lang_ClassLoader_2Ljava_lang_St
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMRuntime_bootClassPath
(Thread* t, object, uintptr_t*)
{
return reinterpret_cast<uintptr_t>(root(t, Machine::BootLoader));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMRuntime_classPath
(Thread* t, object, uintptr_t*)
{
return reinterpret_cast<uintptr_t>(root(t, Machine::AppLoader));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMRuntime_vmVersion
(Thread* t, object, uintptr_t*)
{
return reinterpret_cast<uintptr_t>(makeString(t, "%s", AVIAN_VERSION));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMRuntime_properties
(Thread* t, object, uintptr_t*)
{
@ -1030,14 +1030,14 @@ Avian_dalvik_system_VMRuntime_properties
return reinterpret_cast<uintptr_t>(array);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Runtime_gc
(Thread* t, object, uintptr_t*)
{
collect(t, Heap::MajorCollection);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Runtime_nativeLoad
(Thread* t, object, uintptr_t* arguments)
{
@ -1055,7 +1055,7 @@ Avian_java_lang_Runtime_nativeLoad
}
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_System_arraycopy
(Thread* t, object, uintptr_t* arguments)
{
@ -1066,7 +1066,7 @@ Avian_java_lang_System_arraycopy
arguments[4]);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_sun_misc_Unsafe_objectFieldOffset
(Thread* t, object, uintptr_t* arguments)
{
@ -1078,7 +1078,7 @@ Avian_sun_misc_Unsafe_objectFieldOffset
jfieldSlot(t, jfield)));
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_VMThread_interrupt
(Thread* t, object, uintptr_t* arguments)
{
@ -1093,14 +1093,14 @@ Avian_java_lang_VMThread_interrupt
(threadPeer(t, fieldAtOffset<object>(vmThread, fieldOffset(t, field)))));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_VMThread_interrupted
(Thread* t, object, uintptr_t*)
{
return getAndClearInterrupted(t, t);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_VMThread_isInterrupted
(Thread* t, object, uintptr_t* arguments)
{
@ -1114,7 +1114,7 @@ Avian_java_lang_VMThread_isInterrupted
(t, fieldAtOffset<object>(vmThread, fieldOffset(t, field)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_VMThread_getStatus
(Thread*, object, uintptr_t*)
{
@ -1122,14 +1122,14 @@ Avian_java_lang_VMThread_getStatus
return 1;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_VMThread_currentThread
(Thread* t, object, uintptr_t*)
{
return reinterpret_cast<uintptr_t>(t->javaThread);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_VMThread_create
(Thread* t, object, uintptr_t* arguments)
{
@ -1140,7 +1140,7 @@ Avian_java_lang_VMThread_create
startThread(t, thread);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_VMThread_sleep
(Thread* t, object, uintptr_t* arguments)
{
@ -1158,7 +1158,7 @@ Avian_java_lang_VMThread_sleep
release(t, threadSleepLock(t, t->javaThread));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMStack_getThreadStackTrace
(Thread* t, object, uintptr_t* arguments)
{
@ -1172,7 +1172,7 @@ Avian_dalvik_system_VMStack_getThreadStackTrace
: t->m->processor->getStackTrace(t, p)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMStack_getCallingClassLoader
(Thread* t, object, uintptr_t*)
{
@ -1201,21 +1201,21 @@ Avian_dalvik_system_VMStack_getCallingClassLoader
return reinterpret_cast<uintptr_t>(v.loader);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_min
(Thread*, object, uintptr_t* arguments)
{
return min(static_cast<int>(arguments[0]), static_cast<int>(arguments[1]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_max
(Thread*, object, uintptr_t* arguments)
{
return max(static_cast<int>(arguments[0]), static_cast<int>(arguments[1]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_cos
(Thread*, object, uintptr_t* arguments)
{
@ -1223,7 +1223,7 @@ Avian_java_lang_Math_cos
return doubleToBits(cos(bitsToDouble(v)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_sin
(Thread*, object, uintptr_t* arguments)
{
@ -1231,7 +1231,7 @@ Avian_java_lang_Math_sin
return doubleToBits(sin(bitsToDouble(v)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_sqrt
(Thread*, object, uintptr_t* arguments)
{
@ -1239,35 +1239,35 @@ Avian_java_lang_Math_sqrt
return doubleToBits(sqrt(bitsToDouble(v)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_abs__I
(Thread*, object, uintptr_t* arguments)
{
return abs(static_cast<int32_t>(arguments[0]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_abs__J
(Thread*, object, uintptr_t* arguments)
{
return llabs(arguments[0]);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_abs__F
(Thread*, object, uintptr_t* arguments)
{
return floatToBits(abs(bitsToFloat(arguments[0])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Float_intBitsToFloat
(Thread*, object, uintptr_t* arguments)
{
return arguments[0];
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Float_floatToIntBits
(Thread*, object, uintptr_t* arguments)
{
@ -1280,7 +1280,7 @@ Avian_java_lang_Float_floatToIntBits
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Double_doubleToRawLongBits
(Thread*, object, uintptr_t* arguments)
{
@ -1291,7 +1291,7 @@ Avian_java_lang_Double_doubleToRawLongBits
return v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Object_wait
(Thread* t, object, uintptr_t* arguments)
{
@ -1300,14 +1300,14 @@ Avian_java_lang_Object_wait
wait(t, reinterpret_cast<object>(arguments[0]), milliseconds);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Object_notifyAll
(Thread* t, object, uintptr_t* arguments)
{
notifyAll(t, reinterpret_cast<object>(arguments[0]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Object_getClass
(Thread* t, object, uintptr_t* arguments)
{
@ -1315,14 +1315,14 @@ Avian_java_lang_Object_getClass
(getJClass(t, objectClass(t, reinterpret_cast<object>(arguments[0]))));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Object_hashCode
(Thread* t, object, uintptr_t* arguments)
{
return objectHash(t, reinterpret_cast<object>(arguments[0]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Object_internalClone
(Thread* t, object, uintptr_t* arguments)
{
@ -1330,7 +1330,7 @@ Avian_java_lang_Object_internalClone
(clone(t, reinterpret_cast<object>(arguments[1])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getModifiers
(Thread* t, object, uintptr_t* arguments)
{
@ -1338,7 +1338,7 @@ Avian_java_lang_Class_getModifiers
(t, jclassVmClass(t, reinterpret_cast<object>(arguments[0])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getSuperclass
(Thread* t, object, uintptr_t* arguments)
{
@ -1351,14 +1351,14 @@ Avian_java_lang_Class_getSuperclass
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_desiredAssertionStatus
(Thread*, object, uintptr_t*)
{
return 1;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getNameNative
(Thread* t, object, uintptr_t* arguments)
{
@ -1373,7 +1373,7 @@ Avian_java_lang_Class_getNameNative
(makeString(t, "%s", RUNTIME_ARRAY_BODY(s)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_isInterface
(Thread* t, object, uintptr_t* arguments)
{
@ -1382,7 +1382,7 @@ Avian_java_lang_Class_isInterface
& ACC_INTERFACE) != 0;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_isPrimitive
(Thread* t, object, uintptr_t* arguments)
{
@ -1391,7 +1391,7 @@ Avian_java_lang_Class_isPrimitive
& PrimitiveFlag) != 0;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getClassLoader
(Thread* t, object, uintptr_t* arguments)
{
@ -1400,7 +1400,7 @@ Avian_java_lang_Class_getClassLoader
(t, jclassVmClass(t, reinterpret_cast<object>(arguments[0]))));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_isAssignableFrom
(Thread* t, object, uintptr_t* arguments)
{
@ -1415,7 +1415,7 @@ Avian_java_lang_Class_isAssignableFrom
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_isInstance
(Thread* t, object, uintptr_t* arguments)
{
@ -1429,7 +1429,7 @@ Avian_java_lang_Class_isInstance
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Class_getDeclaredMethods
(Thread* t, object, uintptr_t* arguments)
{
@ -1446,7 +1446,7 @@ Avian_java_lang_Class_getDeclaredMethods
(t->m->processor->invoke(t, get, 0, jclassVmClass(t, c), publicOnly));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Method_invokeNative
(Thread* t, object, uintptr_t* arguments)
{
@ -1460,7 +1460,7 @@ Avian_java_lang_reflect_Method_invokeNative
return reinterpret_cast<uintptr_t>(invoke(t, method, instance, args));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Method_getMethodModifiers
(Thread* t, object, uintptr_t* arguments)
{
@ -1471,7 +1471,7 @@ Avian_java_lang_reflect_Method_getMethodModifiers
arguments[1]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Method_isAnnotationPresent
(Thread* t, object, uintptr_t* arguments)
{
@ -1497,7 +1497,7 @@ Avian_java_lang_reflect_Method_isAnnotationPresent
return false;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Method_getAnnotation
(Thread* t, object, uintptr_t* arguments)
{
@ -1534,7 +1534,7 @@ Avian_java_lang_reflect_Method_getAnnotation
return false;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Method_getDeclaredAnnotations
(Thread* t, object, uintptr_t* arguments)
{
@ -1581,7 +1581,7 @@ Avian_java_lang_reflect_Method_getDeclaredAnnotations
0));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Constructor_constructNative
(Thread* t, object, uintptr_t* arguments)
{
@ -1601,7 +1601,7 @@ Avian_java_lang_reflect_Constructor_constructNative
return reinterpret_cast<uintptr_t>(instance);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Field_getField
(Thread* t, object, uintptr_t* arguments)
{
@ -1621,7 +1621,7 @@ Avian_java_lang_reflect_Field_getField
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Field_getFieldModifiers
(Thread* t, object, uintptr_t* arguments)
{
@ -1632,14 +1632,14 @@ Avian_java_lang_reflect_Field_getFieldModifiers
arguments[2]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Throwable_nativeFillInStackTrace
(Thread* t, object, uintptr_t*)
{
return reinterpret_cast<uintptr_t>(getTrace(t, 2));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Throwable_nativeGetStackTrace
(Thread* t, object, uintptr_t* arguments)
{
@ -1647,7 +1647,7 @@ Avian_java_lang_Throwable_nativeGetStackTrace
(local::translateStackTrace(t, reinterpret_cast<object>(arguments[0])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_makeMethod
(Thread* t, object, uintptr_t* arguments)
{
@ -1656,7 +1656,7 @@ Avian_avian_Classes_makeMethod
(t, reinterpret_cast<object>(arguments[0]), arguments[1]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Array_createObjectArray
(Thread* t, object, uintptr_t* arguments)
{
@ -1666,7 +1666,7 @@ Avian_java_lang_reflect_Array_createObjectArray
arguments[1]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_nio_ByteOrder_isLittleEndian
(Thread*, object, uintptr_t*)
{
@ -1677,7 +1677,7 @@ Avian_java_nio_ByteOrder_isLittleEndian
#endif
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMRuntime_newNonMovableArray
(Thread* t, object, uintptr_t* arguments)
{
@ -1698,14 +1698,14 @@ Avian_dalvik_system_VMRuntime_newNonMovableArray
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_dalvik_system_VMRuntime_addressOf
(Thread*, object, uintptr_t* arguments)
{
return arguments[1] + ArrayBody;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_libcore_io_Memory_pokeLong
(Thread*, object, uintptr_t* arguments)
{
@ -1717,7 +1717,7 @@ Avian_libcore_io_Memory_pokeLong
memcpy(reinterpret_cast<void*>(address), &v, 8);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_libcore_io_Memory_peekLong
(Thread*, object, uintptr_t* arguments)
{
@ -1726,7 +1726,7 @@ Avian_libcore_io_Memory_peekLong
return arguments[2] ? swapV8(v) : v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_libcore_io_Memory_pokeInt
(Thread*, object, uintptr_t* arguments)
{
@ -1735,7 +1735,7 @@ Avian_libcore_io_Memory_pokeInt
memcpy(reinterpret_cast<void*>(address), &v, 4);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_libcore_io_Memory_peekInt
(Thread*, object, uintptr_t* arguments)
{
@ -1744,7 +1744,7 @@ Avian_libcore_io_Memory_peekInt
return arguments[2] ? swapV4(v) : v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_libcore_io_Memory_pokeShort
(Thread*, object, uintptr_t* arguments)
{
@ -1753,7 +1753,7 @@ Avian_libcore_io_Memory_pokeShort
memcpy(reinterpret_cast<void*>(address), &v, 2);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_libcore_io_Memory_peekShort
(Thread*, object, uintptr_t* arguments)
{
@ -1762,7 +1762,7 @@ Avian_libcore_io_Memory_peekShort
return arguments[2] ? swapV2(v) : v;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_libcore_io_Memory_pokeByte
(Thread*, object, uintptr_t* arguments)
{
@ -1770,7 +1770,7 @@ Avian_libcore_io_Memory_pokeByte
*reinterpret_cast<int8_t*>(address) = arguments[2];
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_libcore_io_Memory_peekByte
(Thread*, object, uintptr_t* arguments)
{
@ -1778,28 +1778,28 @@ Avian_libcore_io_Memory_peekByte
return *reinterpret_cast<int8_t*>(address);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_System_nanoTime
(Thread* t, object, uintptr_t*)
{
return t->m->system->now() * 1000 * 1000;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_System_currentTimeMillis
(Thread* t, object, uintptr_t*)
{
return t->m->system->now();
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_System_identityHashCode
(Thread* t, object, uintptr_t* arguments)
{
return objectHash(t, reinterpret_cast<object>(arguments[0]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_System_mapLibraryName
(Thread* t, object, uintptr_t* arguments)
{
@ -1827,7 +1827,7 @@ void register_libcore_io_Posix(_JNIEnv*) { }
void register_libcore_net_RawSocket(_JNIEnv*) { }
void register_org_apache_harmony_xnet_provider_jsse_NativeCrypto(_JNIEnv*) { }
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_libcore_io_OsConstants_initConstants
(Thread* t, object method, uintptr_t*)
{
@ -1847,7 +1847,7 @@ Avian_libcore_io_OsConstants_initConstants
fieldAtOffset<jint>(table, fieldOffset(t, field)) = 2;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_libcore_io_Posix_getenv(Thread* t, object, uintptr_t* arguments)
{
object name = reinterpret_cast<object>(arguments[1]);
@ -1873,7 +1873,7 @@ Avian_libcore_io_Posix_getenv(Thread* t, object, uintptr_t* arguments)
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_libcore_io_Posix_uname(Thread* t, object, uintptr_t*)
{
object c = resolveClass
@ -1911,7 +1911,7 @@ Avian_libcore_io_Posix_uname(Thread* t, object, uintptr_t*)
return reinterpret_cast<uintptr_t>(instance);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_libcore_io_Posix_writeBytes(Thread* t, object, uintptr_t* arguments)
{
object fd = reinterpret_cast<object>(arguments[1]);

View File

@ -230,7 +230,7 @@ makeClasspath(System*, Allocator* allocator, const char*, const char*)
} // namespace vm
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Object_toString
(Thread* t, object, uintptr_t* arguments)
{
@ -245,7 +245,7 @@ Avian_java_lang_Object_toString
return reinterpret_cast<int64_t>(s);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Object_getVMClass
(Thread* t, object, uintptr_t* arguments)
{
@ -253,7 +253,7 @@ Avian_java_lang_Object_getVMClass
(objectClass(t, reinterpret_cast<object>(arguments[0])));
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Object_wait
(Thread* t, object, uintptr_t* arguments)
{
@ -263,7 +263,7 @@ Avian_java_lang_Object_wait
vm::wait(t, this_, milliseconds);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Object_notify
(Thread* t, object, uintptr_t* arguments)
{
@ -272,7 +272,7 @@ Avian_java_lang_Object_notify
notify(t, this_);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Object_notifyAll
(Thread* t, object, uintptr_t* arguments)
{
@ -281,7 +281,7 @@ Avian_java_lang_Object_notifyAll
notifyAll(t, this_);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Object_hashCode
(Thread* t, object, uintptr_t* arguments)
{
@ -290,7 +290,7 @@ Avian_java_lang_Object_hashCode
return objectHash(t, this_);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Object_clone
(Thread* t, object, uintptr_t* arguments)
{
@ -298,7 +298,7 @@ Avian_java_lang_Object_clone
(clone(t, reinterpret_cast<object>(arguments[0])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_io_ObjectInputStream_makeInstance
(Thread* t, object, uintptr_t* arguments)
{
@ -307,14 +307,14 @@ Avian_java_io_ObjectInputStream_makeInstance
return reinterpret_cast<int64_t>(make(t, c));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_LegacyObjectInputStream_makeInstance
(Thread* t, object, uintptr_t* arguments)
{
return Avian_java_io_ObjectInputStream_makeInstance(t, NULL, arguments);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Field_getPrimitive
(Thread* t, object, uintptr_t* arguments)
{
@ -344,7 +344,7 @@ Avian_java_lang_reflect_Field_getPrimitive
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Field_getObject
(Thread*, object, uintptr_t* arguments)
{
@ -354,7 +354,7 @@ Avian_java_lang_reflect_Field_getObject
return reinterpret_cast<int64_t>(fieldAtOffset<object>(instance, offset));
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_reflect_Field_setPrimitive
(Thread* t, object, uintptr_t* arguments)
{
@ -393,7 +393,7 @@ Avian_java_lang_reflect_Field_setPrimitive
}
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_reflect_Field_setObject
(Thread* t, object, uintptr_t* arguments)
{
@ -404,7 +404,7 @@ Avian_java_lang_reflect_Field_setObject
set(t, instance, offset, value);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Constructor_make
(Thread* t, object, uintptr_t* arguments)
{
@ -413,14 +413,14 @@ Avian_java_lang_reflect_Constructor_make
return reinterpret_cast<int64_t>(make(t, c));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Method_getCaller
(Thread* t, object, uintptr_t*)
{
return reinterpret_cast<int64_t>(getCaller(t, 2));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Method_invoke
(Thread* t, object, uintptr_t* arguments)
{
@ -443,7 +443,7 @@ Avian_java_lang_reflect_Method_invoke
(t, returnCode, t->m->processor->invokeArray(t, method, instance, args)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Array_getLength
(Thread* t, object, uintptr_t* arguments)
{
@ -462,7 +462,7 @@ Avian_java_lang_reflect_Array_getLength
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_reflect_Array_makeObjectArray
(Thread* t, object, uintptr_t* arguments)
{
@ -473,21 +473,21 @@ Avian_java_lang_reflect_Array_makeObjectArray
(makeObjectArray(t, jclassVmClass(t, elementType), length));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Float_floatToRawIntBits
(Thread*, object, uintptr_t* arguments)
{
return static_cast<int32_t>(*arguments);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Float_intBitsToFloat
(Thread*, object, uintptr_t* arguments)
{
return static_cast<int32_t>(*arguments);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Double_doubleToRawLongBits
(Thread*, object, uintptr_t* arguments)
{
@ -495,7 +495,7 @@ Avian_java_lang_Double_doubleToRawLongBits
return v;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Double_longBitsToDouble
(Thread*, object, uintptr_t* arguments)
{
@ -503,7 +503,7 @@ Avian_java_lang_Double_longBitsToDouble
return v;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_String_intern
(Thread* t, object, uintptr_t* arguments)
{
@ -512,7 +512,7 @@ Avian_java_lang_String_intern
return reinterpret_cast<int64_t>(intern(t, this_));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_System_getVMProperty
(Thread* t, object, uintptr_t* arguments)
{
@ -546,7 +546,7 @@ Avian_java_lang_System_getVMProperty
return r;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_System_arraycopy
(Thread* t, object, uintptr_t* arguments)
{
@ -557,7 +557,7 @@ Avian_java_lang_System_arraycopy
arguments[4]);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_System_identityHashCode
(Thread* t, object, uintptr_t* arguments)
{
@ -570,7 +570,7 @@ Avian_java_lang_System_identityHashCode
}
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Runtime_load
(Thread* t, object, uintptr_t* arguments)
{
@ -584,14 +584,14 @@ Avian_java_lang_Runtime_load
loadLibrary(t, "", RUNTIME_ARRAY_BODY(n), mapName, true);
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Runtime_gc
(Thread* t, object, uintptr_t*)
{
collect(t, Heap::MajorCollection);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Runtime_freeMemory
(Thread*, object, uintptr_t*)
{
@ -599,7 +599,7 @@ Avian_java_lang_Runtime_freeMemory
return 0;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Runtime_totalMemory
(Thread*, object, uintptr_t*)
{
@ -607,7 +607,7 @@ Avian_java_lang_Runtime_totalMemory
return 0;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Runtime_addShutdownHook
(Thread* t, object, uintptr_t* arguments)
{
@ -620,14 +620,14 @@ Avian_java_lang_Runtime_addShutdownHook
makePair(t, hook, root(t, Machine::ShutdownHooks)));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Throwable_trace
(Thread* t, object, uintptr_t* arguments)
{
return reinterpret_cast<int64_t>(getTrace(t, arguments[0]));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Throwable_resolveTrace
(Thread* t, object, uintptr_t* arguments)
{
@ -647,14 +647,14 @@ Avian_java_lang_Throwable_resolveTrace
return reinterpret_cast<int64_t>(array);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Thread_currentThread
(Thread* t, object, uintptr_t*)
{
return reinterpret_cast<int64_t>(t->javaThread);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Thread_doStart
(Thread* t, object, uintptr_t* arguments)
{
@ -662,7 +662,7 @@ Avian_java_lang_Thread_doStart
(startThread(t, reinterpret_cast<object>(*arguments)));
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Thread_interrupt
(Thread* t, object, uintptr_t* arguments)
{
@ -671,7 +671,7 @@ Avian_java_lang_Thread_interrupt
threadInterrupt(t, reinterpret_cast<Thread*>(peer)->javaThread);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Thread_interrupted
(Thread* t, object, uintptr_t* arguments)
{
@ -681,7 +681,7 @@ Avian_java_lang_Thread_interrupted
(t, reinterpret_cast<Thread*>(peer)->javaThread, true);
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Thread_getStackTrace
(Thread* t, object, uintptr_t* arguments)
{
@ -695,14 +695,14 @@ Avian_java_lang_Thread_getStackTrace
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Thread_activeCount
(Thread* t, object, uintptr_t*)
{
return t->m->liveCount;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Thread_enumerate
(Thread* t, object, uintptr_t* arguments)
{
@ -716,14 +716,14 @@ Avian_java_lang_Thread_enumerate
return count;
}
extern "C" JNIEXPORT void JNICALL
extern "C" AVIAN_EXPORT void JNICALL
Avian_java_lang_Thread_yield
(Thread* t, object, uintptr_t*)
{
t->m->system->yield();
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Atomic_getOffset
(Thread* t, object, uintptr_t* arguments)
{
@ -731,7 +731,7 @@ Avian_avian_Atomic_getOffset
(t, jfieldVmField(t, reinterpret_cast<object>(arguments[0])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Atomic_compareAndSwapObject
(Thread* t, object, uintptr_t* arguments)
{
@ -750,7 +750,7 @@ Avian_avian_Atomic_compareAndSwapObject
return success;
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_isAssignableFrom
(Thread* t, object, uintptr_t* arguments)
{
@ -764,7 +764,7 @@ Avian_avian_Classes_isAssignableFrom
}
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_getVMClass
(Thread* t, object, uintptr_t* arguments)
{
@ -772,7 +772,7 @@ Avian_avian_Classes_getVMClass
(objectClass(t, reinterpret_cast<object>(arguments[0])));
}
extern "C" JNIEXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_avian_Classes_makeMethod
(Thread* t, object, uintptr_t* arguments)
{

File diff suppressed because it is too large Load Diff

View File

@ -966,7 +966,7 @@ class MyFinder: public Finder {
namespace vm {
JNIEXPORT Finder*
AVIAN_EXPORT Finder*
makeFinder(System* s, Allocator* a, const char* path, const char* bootLibrary)
{
return new (a->allocate(sizeof(MyFinder))) MyFinder(s, a, path, bootLibrary);

View File

@ -3785,20 +3785,20 @@ populateJNITables(JavaVMVTable* vmTable, JNIEnvVTable* envTable)
} // namespace vm
extern "C" JNIEXPORT jint JNICALL
extern "C" AVIAN_EXPORT jint JNICALL
JNI_GetDefaultJavaVMInitArgs(void*)
{
return 0;
}
extern "C" JNIEXPORT jint JNICALL
extern "C" AVIAN_EXPORT jint JNICALL
JNI_GetCreatedJavaVMs(Machine**, jsize, jsize*)
{
// todo
return -1;
}
extern "C" JNIEXPORT jint JNICALL
extern "C" AVIAN_EXPORT jint JNICALL
JNI_CreateJavaVM(Machine** m, Thread** t, void* args)
{
local::JavaVMInitArgs* a = static_cast<local::JavaVMInitArgs*>(args);

View File

@ -5272,7 +5272,7 @@ noop()
} // namespace vm
// for debugging
JNIEXPORT void
AVIAN_EXPORT void
vmfPrintTrace(Thread* t, FILE* out)
{
class Visitor: public Processor::StackVisitor {
@ -5314,14 +5314,14 @@ vmfPrintTrace(Thread* t, FILE* out)
fflush(out);
}
JNIEXPORT void
AVIAN_EXPORT void
vmPrintTrace(Thread* t)
{
vmfPrintTrace(t, stderr);
}
// also for debugging
JNIEXPORT void*
AVIAN_EXPORT void*
vmAddressFromLine(Thread* t, object m, unsigned line)
{
object code = methodCode(t, m);

View File

@ -1051,7 +1051,7 @@ handleSignal(int signal, siginfo_t*, void* context)
namespace vm {
JNIEXPORT System*
AVIAN_EXPORT System*
makeSystem(const char*)
{
return new (malloc(sizeof(MySystem))) MySystem();

View File

@ -1149,7 +1149,7 @@ handleException(LPEXCEPTION_POINTERS e)
namespace vm {
JNIEXPORT System*
AVIAN_EXPORT System*
makeSystem(const char* crashDumpDirectory)
{
return new (malloc(sizeof(MySystem))) MySystem(crashDumpDirectory);