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

814 Коммитов

Автор SHA1 Сообщение Дата
jfrijters cb136e677f Fix for #2829717. Constructing java.lang.String instances should redirect to static helper method. 2009-07-30 16:34:30 +00:00
jfrijters 8a9fc7420b Implemented automatically enabling .NET serialization support for Java classes that are trivially serializable. 2009-07-30 13:14:14 +00:00
jfrijters 43fd0daf07 Implemented support for .NET serialization of Java enums.
(The CreateEnumEnum move in FakeTypes.cs is because java.lang.Enum now has a dependency on custom attribute annotations.)
2009-07-29 09:36:56 +00:00
jfrijters 568cff8e34 - Make IsFastClassLiteralSafe return true for various fake annotation types.
- Pass Type to java.lang.Class for "forbidden" and reflection-only types. This is now needed for Class serialization.
2009-07-29 07:06:44 +00:00
jfrijters 2c2388d152 Implemented .NET serialization support for java.lang.Class objects. 2009-07-29 07:04:42 +00:00
jfrijters fd4ee83c14 Handle Annotation.__ReturnValue and Annotation.__Multiple fake types. 2009-07-29 07:02:50 +00:00
jfrijters 9482b52bff Remove compilation warning. In ikvmc (with IKVM_REF_EMIT defined) an Assembly can never be an AssemblyBuilder. 2009-07-28 13:02:30 +00:00
jfrijters d592720c9c Added App.config setting (ikvm-emit-symbols) to force emitting debug symbols on or off. 2009-07-27 08:06:41 +00:00
jfrijters 9c28395a5a Fix NRE when getting annotations on delegate constructor for delegates defined in Java (because these constructors don't really exist). 2009-07-27 08:04:30 +00:00
jfrijters 0335cd0ef2 Fixed detection of dynamic assemblies. Previous manifest module name based hack didn't work on localized versions. 2009-07-20 06:51:28 +00:00
jfrijters 88729b4059 Optimized primitive class literals. 2009-07-16 06:29:32 +00:00
jfrijters 28e5b235d7 Implemented optimization to remove .cctor when it is empty (and the class isn't serializable or has a serialVersionUID). 2009-07-16 06:26:47 +00:00
jfrijters 1e003bbb98 Made callerID initialization lazy. 2009-07-14 08:25:04 +00:00
jfrijters 46811ce9ec Use LazyEmitPop() to annihilate constants. 2009-07-14 07:59:42 +00:00
jfrijters 213965367e Optimized the reading of unsigned bytes from a byte array (buf[i] & 0xFF or buf[i] 0x0FFL). 2009-07-14 07:25:46 +00:00
jfrijters 64e5615aaa Moved responsibility for creating java.lang.Class instances for "fast literal" enable types into ClassLiteral<T>, this allows class literals to be really cheap, because non of the underlying reflection is needed, the class will cache the Type and lazily resolve it to its TypeWrapper. 2009-07-14 06:27:41 +00:00
jfrijters 4e3c9e505f Made ikvm.runtime.Util.getInstanceTypeFromClass() into an instrinsic, when used with a class literal. 2009-07-14 06:20:23 +00:00
jfrijters d76b454d72 Made some classes sealed. 2009-07-13 13:34:41 +00:00
jfrijters 04ca4a71f9 Moved class literal emit code to TypeWrapper and added checks to prevent types that are illegal in type instantations from being used with ClassLiteral<T>. 2009-07-13 08:34:37 +00:00
jfrijters 90f389b530 Fixed dynamic assembly saving (debug option). 2009-07-13 08:00:18 +00:00
jfrijters 2cfd7fad78 Added workaround for the fact that mcs doesn't support the -baseaddress option and that NAnt supplies this option when targetting Mono. 2009-07-08 09:02:18 +00:00
jfrijters d4d302c40c Last checkin broke the build. 2009-07-07 11:58:46 +00:00
jfrijters 6dee819903 Removed ByteCodeHelperMethods.GetClassFromTypeHandle usage from static compiler. 2009-07-07 08:02:18 +00:00
jfrijters ba363faf74 Replaced last usage of ByteCodeHelperMethods.GetClassFromTypeHandle in runtime with LazyEmitLoadClass. 2009-07-07 07:44:30 +00:00
jfrijters aad67feea4 Split off Beans and Media from Misc. 2009-07-03 14:12:03 +00:00
jfrijters 2f2e69613c - Set runtime version during build, instead of computing it a runtime.
- Set OpenJDK version in openjdk.build instead of VMSystemProperty source.
2009-07-03 06:57:06 +00:00
jfrijters 0e0dd9b037 - Consolidated system property initialization in VMSystemProperties.
- Fixed bug that caused startup properties set with ikvm.runtime.Startup.setProperties() to be forgotten when doing a System.setProperties(null).
2009-07-03 06:40:51 +00:00
jfrijters 7a856abc0a Moved VMSystemProperties from gnu.classpath to java.lang. 2009-07-03 05:55:58 +00:00
jfrijters f6cbd1dd50 Specify -baseaddress:<address> option for all runtime assemblies. This should make ngen images more efficient. 2009-06-29 08:53:33 +00:00
smallsql b6ef7dab19 implements getIcon() in ShellFolder 2009-06-27 20:43:42 +00:00
smallsql ab09f25798 Complete the native part of the WinShellFolder 2009-06-27 15:42:17 +00:00
jfrijters bc47380664 Removed unncessary usage of reflection. 2009-06-25 09:18:45 +00:00
jfrijters 53953bd7e7 When unsharing the localstoresite array, mark each individual entry as shared. I don't think this was actually a bug due to the specifics of how sharing work, but it definitely was a bug waiting to happen. 2009-06-18 06:29:05 +00:00
jfrijters 1dc4224163 Removed code that is no longer used (because of the jsr/ret split off) from instruction state merging. 2009-06-18 06:27:11 +00:00
jfrijters 5b9bcb49e1 Fixed bug in local variable store site merging. 2009-06-18 06:22:29 +00:00
jfrijters fe3d744e76 Removed unnecessary IsEmpty property from LocalStoreSites. 2009-06-18 06:21:11 +00:00
jfrijters 3f930aa828 Second part of "Fixed jsr/ret handling bug." 2009-06-18 06:16:54 +00:00
jfrijters 99c7df5de9 Added "RuntimeCompatibilityAttribute(WrapNonExceptionThrows = true)" to generated assemblies. 2009-06-18 06:14:55 +00:00
jfrijters f6a22f068f Added ikvmc warnings for VerificationError and ClassFormatError. 2009-06-18 06:13:21 +00:00
jfrijters cf0ab3a93e Fixed jsr/ret handling bug. 2009-06-18 05:55:47 +00:00
jfrijters bcf61486ab Fixed build break. 2009-06-10 04:40:00 +00:00
smallsql 39d81eb0c8 Native code of Win32ShellFolder2 Step 1 2009-06-06 12:32:47 +00:00
jfrijters b75fb48ee8 Implemented class gc (available only when compiling on .NET 4.0). 2009-06-02 07:38:21 +00:00
jfrijters 3a5b9d9480 Made java.lang.reflect.Field exception messages the same as JDK 6. 2009-06-02 06:26:42 +00:00
jfrijters 75e635dc2b Doing a Demand probably makes a little more sense, although not a whole lot. An alternative could be to change the Create() method to distinguish between public, private and internal access and when internal access is requested explicitly look for the InternalsVisibleToAttribute on the target assembly to see if it grants us access, but that seems like a lot of complexity for what is essentially a special case (internal access). 2009-05-31 07:54:26 +00:00
jfrijters 6c87412e66 Improved partial trust support. 2009-05-31 05:41:14 +00:00
jfrijters b8dd6a689f Added OpenFlags.OpenExistingOnly to X509Store.Open() to reduce required permissions. 2009-05-29 12:34:30 +00:00
jfrijters cd7ccd8417 Made serialization getters verifiable, to allow OutputOutputStream to be used from partial trust. 2009-05-29 08:57:33 +00:00
jfrijters 7b120d5942 Added JavaModuleAttribute to dynamic module to make detection of Java types more straightforward. 2009-05-29 07:47:20 +00:00
jfrijters 25586ad542 Removed unused method. 2009-05-28 06:11:09 +00:00
jfrijters 6dd2495ad8 Made dynamic assembly detection more reliable and moved the utility method to ReflectUtil. 2009-05-28 05:58:35 +00:00
jfrijters 2250bf14c1 Changed DynamicClassLoader API to make it easier to move from global AssemblyBuilder to per ClassLoader. 2009-05-26 10:17:57 +00:00
jfrijters 6a5ce00091 - When building for .NET 4.0, don't use DefineDynamicAssembly() overload that takes assembly permission sets, because .NET 4.0 ignores them anyway.
- Fixed BakedTypeCleanupHack to work for .NET 2.0 SP2.
- Changes to remove warnings when building on .NET 4.0
2009-05-26 05:00:38 +00:00
jfrijters 7d0d8be096 When building for .NET 4.0 we can derived ModuleBuilder from Module and AssemblyBuilder from Assembly. 2009-05-25 13:42:15 +00:00
jfrijters a9751b487e Define NET_4_0 when building for .NET 4.0. 2009-05-25 13:40:44 +00:00
jfrijters 529a473511 Preparing for .NET 4.0:
- moved RuntimeMethodHandle from unmanaged to managed data.
- moved all managed data into a managed data holder, so that we only have to use a single GCHandle.
2009-05-25 04:01:35 +00:00
jfrijters 68c9172600 Preparing for .NET 4.0:
- Added SecurityRules(Level1) attribute to IKVM.Runtime.dll to (temporarily) opt out of new .NET 4.0 security model.
- Changed compiler/runtime to automatically add SecurityRules(Level1) attribute when running on .NET 4.0 beta 1 to work around bug in the handling of MethodImpls in beta 1.
2009-05-24 06:54:24 +00:00
jfrijters 1ba8f67f51 Removed support for .NET 2.0 RTM (we now require at least SP1). Formally, 0.40 already doesn't support RTM, but it still worked, now it no longer works. 2009-05-24 05:42:20 +00:00
jfrijters 9b4f8d0c0e ClassFile versions 51 and up don't allow the jsr instruction. 2009-05-24 05:05:34 +00:00
smallsql 66da5fffd2 closeSplashScreen changed 2009-05-22 19:59:24 +00:00
jfrijters 1442ab7841 - Moved unsafe operations into Java and added link demand for unmanaged code to them.
- Added some deprecated unsafe methods that are apparantly still being used (or at least referenced) by JRuby.
2009-05-17 06:16:34 +00:00
jfrijters d33c145753 Added support for declarative security pseudo custom attribute annotations. 2009-05-17 06:05:52 +00:00
jfrijters b8e96f6bd1 Some vfs restructuring to make VFS a true hierarchy and added support for File.list(). 2009-05-12 05:54:07 +00:00
jfrijters 1a909c4b7c Moved Virtual File System into a separate source file. 2009-05-12 04:30:10 +00:00
jfrijters da7552b32c - Added hook to allow subclass of DynamicTypeWrapper to inject a different base class.
- Added support to CompiledTypeWrapper.GetBaseTypeWrapper() to skip base classes that aren't visible to Java.
2009-05-12 04:03:48 +00:00
jfrijters c1553b7f1a Refactored method call replacement to allow it to be used by others than xml mapping stuff. 2009-05-12 04:00:01 +00:00
jfrijters 7cb468fbec Don't let System.NotSupportedException escape from list() if the path is invalid. 2009-05-11 08:31:59 +00:00
smallsql 6cec7f2d70 Add additional empty native methods for AWT and Swing (mostly initIDs) 2009-05-03 18:44:22 +00:00
smallsql 5079ec4983 More Sun classes (SwingUtilities2) 2009-04-30 19:52:43 +00:00
jfrijters 95ddd4293c Fix for bug #2777171.
- Use custom enum value decoding because Enum.Parse() doesn't work for ReflectionOnly types.
- Handle enums that use unsigned integer underlying type properly.
2009-04-22 04:34:06 +00:00
jfrijters 4ec50d326a AttributeTargets.Interface wasn't mapped correctly to @Target(TYPE).
Fixes bug #2777128.
2009-04-21 07:26:29 +00:00
jfrijters bbd714c2cc Integrated OpenJDK java/awt/image and java/awt/image/renderable packages. 2009-04-17 06:36:01 +00:00
jfrijters 62e4bc8b12 Removed jsr/ret support. 2009-04-16 05:44:48 +00:00
jfrijters 7902330d0c Subroutine inlining exposed a pre-existing codegen bug that caused exception handlers to be dropped after an unreachable exception block was encountered. 2009-04-16 05:37:53 +00:00
jfrijters 937d2e6568 Added support for inlining subroutines (jsr/ret) to allow the verifier and compiler to be simplified and to hopefully pave the way for future codegen optimizations. 2009-04-16 05:34:20 +00:00
jfrijters 70b04e174e Changed bytecode stream and exception tables to use instruction indexes instead of PC. 2009-04-07 04:53:56 +00:00
jfrijters 145b8020ff Changed LoadLocal/StoreLocal to take an instruction index, instead of an instruction. 2009-04-06 10:26:37 +00:00
jfrijters d94191faa1 Removed local variable scoping (from debug info) because it doesn't add much value and conflicts with future optimizations. 2009-04-06 10:19:51 +00:00
jfrijters d3fbd5588d Store our CodeEmitterLabel object in label check dictionary, instead of the underlying Label. 2009-04-06 10:14:47 +00:00
jfrijters d20098ec2a Renamed CodeEmitter.Finish() to CheckLabels() and moved invocation to the right place. 2009-04-06 10:10:17 +00:00
jfrijters 0743299862 Handle case were there is no user class loader. 2009-04-06 05:23:04 +00:00
jfrijters f00d50ed0f Workaround for https://bugzilla.novell.com/show_bug.cgi?id=486307 2009-03-18 08:56:15 +00:00
jfrijters fbf4d5167a Rewrote exception handling to store Java exception state in our java.lang.Throwable class, instead of an additional object in a weak keyed map. 2009-03-16 05:50:59 +00:00
jfrijters 7ed63e8d01 Added (limited) support for defining instance fields on remapped types. The fields will only be available on the actual implementation types, not the types they shadow (accessing the field on a shadow instance is undefined, but for reflection we'll at least guarantee that an exception is thrown (current java.lang.IllegalArgumentException)). 2009-03-16 05:28:11 +00:00
jfrijters 546cc4fdba Implemented native library unloading to support evil trick that com.sun.jna.Native$DeleteNativeLibrary uses (it uses reflection to call ClassLoader$NativeLibrary.finalize() to force the native library to be unloaded, even though the class loader isn't garbage collected.) 2009-03-09 09:01:36 +00:00
jfrijters d4dc5a6479 Resolve ConstructorBuilder before invoking. 2009-03-08 06:21:14 +00:00
jfrijters 1157440aaa Fixed TypeBuilder check. 2009-03-08 06:20:35 +00:00
jfrijters 629416833c Delegate fixes. 2009-03-07 08:33:33 +00:00
jfrijters f780844c1c Fixed regression introduced in 0.38 that caused LinkageError to be thrown instead of ClassCircularyError. 2009-03-07 08:11:28 +00:00
jfrijters 14a67e3bb4 - Added virtual method to MethodWrapper to do custom linking (i.e. defining the method).
- Added the notion of Java methods that don't have a corresponding CLR method (currently only for delegate constructors).
2009-03-06 06:43:40 +00:00
jfrijters dd73250d49 Added support for defining delegates in Java. 2009-03-06 05:33:08 +00:00
jfrijters 4464f2e374 Fix. If we don't run the class initializer, we shouldn't still report its presence. 2009-03-04 13:52:05 +00:00
jfrijters 729e27537b Fixed first-pass compilation. 2009-03-04 10:57:42 +00:00
jfrijters 00908792ae Switched java.awt.event package from GNU Classpath to OpenJDK. 2009-03-04 08:18:36 +00:00
jfrijters 0f04e782c6 Added hack to skip running the static initializer when computing the serialVersionUID when running in ikvmstub. 2009-03-04 06:49:16 +00:00
jfrijters 3ebf554517 Implemented ikvm.internal.ClassLiteral<T> to allow for more efficient class literals. 2009-03-04 05:47:18 +00:00
jfrijters e417a92a37 - Moved class literal TypeWrapper -> Type step into expression emitter.
- Fixed Class.desiredAssertionStatus() instrinsic to use the RemoveAsserts flag from the right class loader.
2009-03-02 06:31:55 +00:00
jfrijters f4991c7bd4 Made Mono compilation workarounds conditional on __MonoCS__. 2009-03-02 06:30:13 +00:00
jfrijters 05d0c7a5c6 Fixed bug introduced in recent changes. When the first entry on the stack contains a partial expression, it cannot be popped. 2009-03-02 04:52:05 +00:00
jfrijters f7f3ad1c6c Added hack to fail fast if we encounter (a particular kind of) corrupt assembly generated by some obfuscator. 2009-03-02 04:51:05 +00:00