Граф коммитов

176 Коммитов

Автор SHA1 Сообщение Дата
jfrijters 843e78ccbe Use JMath functions (where possible and necessary) instead of .NET Math functions. 2009-02-16 05:13:49 +00:00
jfrijters bb7966d7d6 Speed up stack walking. 2009-02-12 06:25:07 +00:00
jfrijters 37356690e2 First pass compilation fix. 2009-02-11 05:27:55 +00:00
jfrijters 070d268277 Added supported for redirecting Runtime.exec("java ...") to ikvm.exe. 2009-02-10 15:21:41 +00:00
jfrijters 288a3fddbd Changed "InternalsVisibleTo" handling to be based on Assembly instead of class loader. 2009-02-10 07:24:30 +00:00
jfrijters 5eebd6f17b Added AssemblyClassLoader.GetAssembly(TypeWrapper) and changed most code that assumed that an AssemblyClassLoader represented a single assembly to use it. 2009-02-04 07:24:44 +00:00
jfrijters a2082be2f5 Use CallerID instead of stack walking. 2009-01-05 06:30:46 +00:00
jfrijters 6c59d613bd Moved AccessController.doPrivileged() to Java and use CallerID to avoid stack walk. 2009-01-02 10:44:05 +00:00
jfrijters d987350ae2 Forked java/util/ResourceBundle.java to remove custom stack walking and use CallerID instead. 2009-01-02 08:49:18 +00:00
jfrijters 1a98f51c37 Removed ResolverConfigurationImpl "native" methods that have been moved to Java side. 2008-12-23 05:33:40 +00:00
jfrijters 20cee82771 Don't load IKVM.Runtime.JNI.dll when "loading" a fake native library. 2008-12-22 07:34:37 +00:00
jfrijters 02e63d6456 Moved .NEt 2.0 SP1 specific constructor invocation into a separate method, to avoid getting a MissingMethodException on .NET 2.0. 2008-11-03 06:59:59 +00:00
jfrijters ae3172cde1 Re-introduced workaround for .NET JIT bug that causes .cctor not to run when a DynamicMethod invokes a method or gets/sets a field. 2008-09-25 05:17:21 +00:00
jfrijters 5cd8a0b5b9 Moved sound factory methods to runtime, to allow for easier experimentation with a sound implementation. 2008-09-21 09:45:00 +00:00
jfrijters ef06673e2d Fixed float/double array (de)serialization endianness. 2008-09-02 04:56:19 +00:00
jfrijters 2381194072 Removed the usage of .NET reflection. 2008-09-01 05:19:04 +00:00
jfrijters 490f744678 Moved all creations of DynamicMethod to util method that uniformly handles the fallback to the new .NET 2.0 SP1 constructor that support partial trust. 2008-09-01 04:01:36 +00:00
jfrijters 590cccc8d2 - Fixed VFS root directory entry.
- Removed no longer needed VM.isBooted() check (VM.isBooted() always returns true now on IKVM).
2008-08-28 06:51:31 +00:00
jfrijters 0f9117126a Removed class init workaround that is no longer required since .NET 2.0 SP1. 2008-08-25 04:51:06 +00:00
jfrijters aaefc51c9b Removed last parts of old-style reflection. 2008-08-25 04:16:59 +00:00
jfrijters 99d296d322 - Removed "slow" reflection.
- Removed MethodWrapper.Invoke().
- Removed FieldWrapper.GetValue()/SetValue().
- Added ICustomInvoke for the few MethodWrappers that still require custom reflection invocation.
2008-08-21 06:53:48 +00:00
jfrijters 6bce58f1bc Changed JNI reflection to be based on Java reflection (where possible). 2008-08-21 06:40:22 +00:00
jfrijters 684cdf651e Generified all collections. 2008-08-15 12:01:06 +00:00
jfrijters 93eaefc31a - Removed Mono workarounds that are no longer needed with Mono 2.0
- Fixed ikvmc build error introduced in previous patch.
2008-08-06 05:48:52 +00:00
jfrijters 379dd8bee3 - Added ghost array tagging to be able to report the instantiated class (instead of object[] which is allocated instead).
- Fixed ldc <class> where <class> is a ghost array.
- Fixed bug in instanceof <class> where <class> is a Serializable[].
2008-08-06 05:25:18 +00:00
jfrijters 05cbf17945 Jar meta entries are case insensitive. 2008-07-04 05:40:54 +00:00
jfrijters 909d78b0f7 - Renamed ClassLoader.NIL_CLASSLOADER to ClassLoader.DUMMY.
- Removed unused ClassLoader.registerNatives().
- Removed unnecessary field initializers in ClassLoader.
- Moved necessary field initializers in ClassLoader to constructor.
- Changed Thread to make use of ClassLoader.DUMMY, instead of having an extra field to keep track of contextClassLoader status.
2008-06-04 05:12:46 +00:00
jfrijters b1b3f8b4f5 - Renamed CountingILGenerator to CodeEmitter.
- Renamed CountingLabel to CodeEmitterLabel.
2008-06-03 12:10:07 +00:00
jfrijters cbeeb20318 Marked all static classes as static. 2008-06-03 07:13:49 +00:00
jfrijters 5e4182edb5 - Implemented CallerID infrastructure.
- Marked various methods with HasCallerID annotation.
- Rewrote some methods to explicitly use CallerID.
2008-05-31 15:20:29 +00:00
jfrijters 018eaf5acb Restructured code to remove (mcs) compiler warnings. 2008-05-20 07:43:42 +00:00
jfrijters c4eb9596af - Use new more efficient float/double to/from int/long bits converters.
- Forward IOHelper.WriteDouble/WriteFloat to java.io.Bits to remove the need to worry about normalizing NaNs or not.
2008-05-09 05:59:59 +00:00
jfrijters 191d045da4 Fix deserialization of double arrays. 2008-05-03 19:00:32 +00:00
jfrijters 1b027efce3 Moved java.lang.Thread "native" methods to Java. 2008-04-25 04:48:57 +00:00
jfrijters ec2228d04a Moved System.nanoTime() to Java. 2008-04-24 06:22:49 +00:00
jfrijters 7d472777de Moved a couple of java.lang.System native methods to the Java side. 2008-04-23 05:24:35 +00:00
jfrijters 6a1c4cea55 Use new .NET 2.0 API to get processor count. 2008-04-23 05:22:31 +00:00
jfrijters cd2ab36b74 Refactored class library initialization. 2008-04-23 04:25:21 +00:00
jfrijters 2bbb4bc9cb Added support for filenames/paths with colons in them (on Win32) to Win32FileSystem.Canonicalize(). 2008-04-14 05:09:38 +00:00
jfrijters 7b24fc61d8 Fixed mapLibraryName to use platform detection instead of os.name property. 2008-04-07 04:30:04 +00:00
jfrijters 36593f183b Set Thread context class loader for threads started from .NET. 2008-03-14 09:17:08 +00:00
jfrijters c591de8029 Ripped out annotation/constant pool support that is no longer needed. 2008-03-03 08:28:22 +00:00
jfrijters 53321c6fe9 Changed System.nanoTime() implementation to use Stopwatch.GetTimestamp(). 2008-03-03 07:27:38 +00:00
jfrijters 828a4de95d Replaced notion of DynamicOnly types with Fake types. Fake types are implemented as generic type instances and can have DynamicOnly methods. 2008-03-03 07:05:19 +00:00
jfrijters 68e4e912ab - Simplified annotation handling.
- Added support to Class.forName() for assembly qualified Java type names.
2008-02-29 08:03:09 +00:00
jfrijters 95ce4405cd - Forked Class, Constructor and Field.
- Made class annotation handling lazy and bypass encode/decode.
2008-02-19 16:52:53 +00:00
jfrijters 957904c9a2 Box/unbox ghost references when (de)serializing. 2008-02-09 17:34:50 +00:00
jfrijters 6fff8e1ac0 Partial Trust fixes:
- Added accessor methods for "slot" to Method & Constructor.
- Implemented System.setIn0, setOut0, setErr0 in map.xml.
- Hacked sun.misc.SharedSecrets to replace Unsafe.ensureClassInitialize() with direct calls.
- Replaced java.nio.Bits.byteOrder() with simple System.BitConver.IsLittleEndian based implementation.
- Disabled DynamicMethodSupport when running in partial trust.
- Ignore SecurityException in CanonicalizePath.
- Don't trigger load of JNI assembly when "loading" a fake system library.
2007-12-28 14:55:33 +00:00
jfrijters e2c7ceb1d5 - Moved some calls to methods with a LinkDemand (that fails in partial trust) to a separate methods.
- Added stuff to map.xml to remove the need for reflection in VM / Library bootstrap.
- Inverted IKVM.Runtime.JNI dependency in stack walking code.
2007-12-27 15:16:49 +00:00
jfrijters 6cd0a9e34b Restructured VM <-> Library interface to take advantage of InternalsVisibleTo to remove public methods and reflection usage. 2007-12-19 11:28:09 +00:00
jfrijters 160d93fc1f Made all "native" method classes internal. 2007-12-18 11:05:30 +00:00
jfrijters f9e7cd31f5 Moved JNI implementation into a separate assembly (IKVM.Runtime.JNI.dll) to make IKVM.Runtime.dll verifiable. 2007-12-18 09:56:11 +00:00
jfrijters 6df053187c Implemented support for InternalsVisibleToAttribute. 2007-12-17 10:59:02 +00:00
jfrijters a7d6edbc5a Implemented native methods of java.io.Console. 2007-12-17 07:44:59 +00:00
jfrijters d118006a7f Don't create DynamicMethod with bogus arg in signature. 2007-12-04 08:08:33 +00:00
jfrijters d6e2cf70f7 Removed more .NET 1.1 workarounds. 2007-11-26 16:00:15 +00:00
jfrijters 9e7cc69997 Oops. Changed vfs.zip path back to resource. 2007-11-26 15:20:10 +00:00
jfrijters 61ccfb3ced - Improved VFS.
- Dynamically generate "lib/security/cacerts" from .NET X509 store.
2007-11-26 15:19:08 +00:00
jfrijters 6bb8fa27d1 - Regenerated mscorlib.jar for .NET 2.0
- Updated FileChannelImpl to use SafeFileHandle and GC.Add|RemoveMemoryPressure
- Added GC.KeepAlive to "native" methods of MappedByteBuffer
2007-11-26 12:51:21 +00:00
jfrijters 7ca97a7541 More .NET 1.1 -> 2.0 work. 2007-11-26 11:01:29 +00:00
jfrijters ab95ffee45 More .NET 1.1 -> 2.0 work. 2007-11-26 09:01:35 +00:00
jfrijters 3072c89696 - Removed .NET 1.1 specific code
- Removed conditional compilation of .NET 2.0 specific code
2007-11-26 08:38:38 +00:00
jfrijters 83c6e5105d - .NET 1.1 is no longer supported
- Removed .NET 2.0 warnings (except for the "unreachable code" ones)
2007-11-26 05:50:57 +00:00
jfrijters 6e2d5abf5f Don't create the default system class loader if the main executable has a custom assembly class loader. 2007-10-25 16:49:30 +00:00
jfrijters 13fff84a96 Fixed Class.getModifiers() to mask out ACC_SUPER bit. 2007-10-22 10:25:54 +00:00
jfrijters 61bc8af572 Added support for custom assembly class loaders. 2007-10-21 07:14:53 +00:00
jfrijters 7a2ffb3019 Regression fix. When getting a static field value, we should convert the value from signature type to stack type (to make sure that non-primitive value types are boxed). 2007-10-10 05:30:04 +00:00
jfrijters 0fc40a8133 Explicitly run <clinit> when calling a static method thru reflection via a DynamicMethod, to work around the .NET 2.0 bug in DynamicMethod that causes it not to call the class constructor in this case. 2007-09-25 12:27:21 +00:00
jfrijters cd1a029440 Make sure that passed in reference arguments are of the correct type. 2007-09-25 06:12:59 +00:00
jfrijters abef13a3d9 Disabled the use of DynamicMethod when running on Mono, because as of Mono 1.2.5.1 its DynamicMethod implementation is too broken for us. 2007-09-25 04:44:28 +00:00
jfrijters d20ce68f75 Implemented optimized reflection/serialization when running on .NET 2.0 (by generating DynamicMethods instead of using .NET reflection). 2007-09-24 11:57:00 +00:00
jfrijters f89e98b7ed Implemented assertions (OpenJDK only). 2007-09-12 06:51:37 +00:00
jfrijters c932cfad42 Made method annotation resolution lazy to support annotations that annotate themselves. 2007-09-10 06:16:49 +00:00
jfrijters fff2c860d3 - Fixed path canonicalization not to throw exceptions that it shouldn't throw.
- Added workaround for .NET 1.1 Directory.Delete() bug.
2007-08-23 09:30:40 +00:00
jfrijters 567e70a44d Implemented sun.net.dns.ResolverConfigurationImpl "native" methods. 2007-08-22 11:49:58 +00:00
jfrijters 23f1449562 Implemented path canonicalization. 2007-08-21 07:16:36 +00:00
jfrijters 02558b63a4 Implemented Inet4Address.isReachable(). 2007-08-17 13:35:51 +00:00
jfrijters 53c2542cb5 Implemented Thread.WaitUntilLastJniThread() (used by JNI method DestroyJavaVM() to wait for all non-daemon threads to end). 2007-08-17 09:58:37 +00:00
jfrijters d5d1f1de1b - Implemented Thread.dumpThreads() and Thread.getThreads().
- Added a couple more fake native libraries to VFS.
2007-08-17 09:12:51 +00:00
jfrijters 14c840cfbd Refactored system properties initialization. 2007-08-16 14:04:59 +00:00
jfrijters 3d0a4c552a Integrated OpenJDK java.nio package. 2007-08-15 12:04:24 +00:00
jfrijters dada58f826 Removed unused code. 2007-08-14 12:08:12 +00:00
jfrijters 85f0e03a43 - Fixed thread creation to use AccessController.doPrivileged() to get ikvm.apartmentstate system property.
- Fixed AccessController.getStackAccessControlContext() to use "native" method as marker on the stack for privileged operation (because the native method stub may get inlined away).
2007-08-10 13:04:21 +00:00
jfrijters 353a628608 - Fixed java.lang.reflect.Array.set() to only unbox primitives when the array is a primitive array
- Fixed java.lang.reflect.Array.multiNewArray() to finish the array type before using it.
2007-08-08 12:52:33 +00:00
jfrijters 81acadd97c - Added fake awt and rmi native libraries to vfs.
- Removed VMStackWalker dependency.
- Several bootstrap issue workarounds.
2007-08-07 07:44:42 +00:00
jfrijters a5caf1ece0 Integrated OpenJDK javax.imageio package (excluding the jpeg support, because OpenJDK uses native code for that). 2007-07-31 06:14:32 +00:00
jfrijters e688e083a7 Added .NET 1.1 implementation of the System.Net.NetworkInformation namespace. 2007-07-25 08:17:53 +00:00
jfrijters c05f8aba77 Remove usage of .NET 2.0 specific API when compiling for .NET 1.1. 2007-07-25 05:33:49 +00:00
jfrijters 3c0afc5d18 Implement java.net.NetworkInterface native methods (for .NET 2.0 builds only ATM). 2007-07-24 14:33:59 +00:00
jfrijters 9e71d1a851 Fixed Inet4AddressImpl.lookupAllHostAddr() to set the queried hostname on returned addresses. 2007-07-24 07:52:24 +00:00
jfrijters faef699b6e Another attempt to fix race conditions in Thread.interrupt(). 2007-07-18 08:37:42 +00:00
jfrijters 027353d367 Clarified comment. 2007-07-18 07:30:38 +00:00
jfrijters 894e32c1b9 - Fixed openjdk.cs compilation error.
- Added OpenJDK derived PlainDatagramSocketImpl implementation.
- Added compilation stubs for jgss.
2007-07-12 14:09:51 +00:00
jfrijters a1ea963895 Fixed some FIRST_PASS compilation errors. 2007-07-12 08:46:25 +00:00
jfrijters 2b50089bcc - Added WINDOWS constant to ikvm.internal.Util to check if we're running on Windows.
- Added a bunch of native methods to openjdk.cs (some real implementations, some stubs)
- Added OpenJDK derived PlainSocketImpl/SocketInputStream/SocketOutputStream implementations.
- Added OpenJDK derived file protocol handler (a single class that supports both Windows and non-Windows)
2007-07-12 08:40:32 +00:00
jfrijters b4154227ea Implemented native methods of OpenJDK's java.security.AccessController (not yet integrated). 2007-07-11 07:11:35 +00:00
jfrijters 619c89079f Added support for "loading" fake native libraries from VFS and removed hack to bypass loadLibrary() call in System.initializeSystemClass(). 2007-07-05 11:53:06 +00:00
jfrijters 8281c28bc0 "Implemented" ClassLoader.retrieveDirectives() by returning empty AssertionStatusDirectives object. Enabling assertions on the ikvm.exe command line is still not implemented. 2007-07-04 09:18:19 +00:00
jfrijters 3c9e581189 - Fixed latestUserDefinedLoader() to ignore mscorlib.
- Added support to VFS for the VFS root directory.
- Fixed FieldAccessorImpl to check the type of the object passed in.
2007-07-02 07:11:48 +00:00
jfrijters 7540ffd915 Changed VFS ZipEntryStream.Read() to always try to read the requested number of bytes, instead of returning earlier. For maximum compatibility with real file i/o. 2007-06-29 11:57:55 +00:00