1 2004-06-17 Raja R Harinath <rharinath@novell.com>
3 * Makefile.am (PLATFORM_LIB): New. Possibly refer to ../os/libmonoos.la.
4 (bundle_obj): New conditional define.
5 (BUILT_SOURCES): Remove.
6 ($(bundle_srcs)): Make parallel-make safe.
7 (libmonoruntime_la_LIBADD): Make unconditional.
8 (libmetadata_la_LIBADD): Make unconditional. Refer to $(bundle_obj).
9 (libmetadata_la_SOURCES): Don't refer to $(bundle_srcs).
11 2004-06-17 Atsushi Enomoto <atsushi@ximian.com>
13 * culture-info-tables.h: It was inconsistent with the latest
16 2004-06-17 Zoltan Varga <vargaz@freemail.hu>
18 * assembly.c (mono_assembly_open): Fix crash when the assembly can't
21 * threads.c (ves_icall_System_Threading_Thread_Resume): Fix compilation
24 Wed Jun 16 18:23:45 CEST 2004 Paolo Molaro <lupus@ximian.com>
26 * threads.h, icall.c, object.c, threadpool.c, threads-types.h:
27 cleaned up public header threads.h.
29 Wed Jun 16 18:11:41 CEST 2004 Paolo Molaro <lupus@ximian.com>
31 * Makefile.am, *.c, *.h: more API cleanups.
33 Wed Jun 16 14:33:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
35 * Makefile.am: removed monosn from compilation.
36 * appdomain.c, assembly.c, assembly.h, blob.h, class.c,
37 debug-helpers.c, debug-mono-symfile.c, domain.c, icall.c,
38 image.c, image.h, loader.c, marshal.c, metadata-internals.h,
39 metadata.c, metadata.h, mono-config.c, mono-debug-debugger.c,
40 mono-debug.c, object.c, opcodes.c, opcodes.h, pedump.c, process.c,
41 reflection.c, reflection.h, verify.c: more API cleanups and fixes.
43 2004-06-15 Jackson Harper <jackson@ximian.com>
45 * assembly.c: Make locales lower case when searching the GAC for
46 assemblies. gacutil will always make locales lowercase when
47 installing so this effectively makes them case insensitive.
49 2004-06-15 Lluis Sanchez Gual <lluis@ximian.com>
51 * locales.c, threadpool.c: use mono_monitor_enter instead of mono_monitor_try_enter.
52 * monitor.c: New method mono_monitor_try_enter_internal, which takes a new
53 parameter which allows to choose whether the wait can be interrupted or
54 not. Also added the method mono_monitor_enter(), which locks the monitor
55 using an infinite wait and without allowing interruption.
56 In the Monitor.Enter and Wait icalls, retry the lock if the wait is
58 * object.h: Added new fields in MonoThread. suspend_event holds the event
59 used to susped/resume the thread. synch_lock is the lock object to use for
60 modifying the thread state.
61 * threads.c: Use the new synch_lock object for locking, instead of "this",
62 which can generate deadlocks.
63 Moved thread state change in Thread.Sleep and Thread.Join from managed
64 to unmanaged code. This avoids a deadlock when the thread was suspended
65 just after acquiring the thread lock.
66 In general, use mono_monitor_enter instead of mono_monitor_try_enter.
67 Implemented Thread.Suspend using an event instead of ThreadSuspend,
68 which is not fully implemented in the io-layer.
69 * socket-io.c: Only try IPv6 DNS lookup if IPv4 fails.
71 Tue Jun 15 18:34:21 CEST 2004 Paolo Molaro <lupus@ximian.com>
73 * Makefile.am, monitor.h, object.h, threadpool.c, threadpool.h,
74 threads-types.h: more API cleanups.
76 Tue Jun 15 16:40:19 CEST 2004 Paolo Molaro <lupus@ximian.com>
78 * domain-internals.h, Makefile.am, appdomain.c, appdomain.h,
79 domain.c, gc.c, icall.c, mono-debug.c, object.c, reflection.c,
80 threadpool.c, threads.c: first pass at the exported API cleanup.
82 Tue Jun 15 15:29:47 CEST 2004 Paolo Molaro <lupus@ximian.com>
84 * icall.c: fix signatures of some VolatileRead and VolatileWrite icalls.
86 2004-06-15 Gonzalo Paniagua Javier <gonzalo@ximian.com>
88 * icall.c: added internalGetHome.
90 2004-06-14 Dick Porter <dick@ximian.com>
92 * file-io.c (ves_icall_System_IO_MonoIO_FindFirstFile): It was
93 possible to return successfully when '.' or '..' were the only
94 entries in a directory, but were skipped. The MonoIOStat was not
95 filled in in that case. Now return ERROR_NO_MORE_FILES instead.
98 Mon Jun 14 00:27:15 CEST 2004 Paolo Molaro <lupus@ximian.com>
100 * reflection.c: make binaries run on .Net 1.1 by default.
102 Sun Jun 13 18:22:40 CEST 2004 Paolo Molaro <lupus@ximian.com>
104 * threadpool.c, threadpool.h: use the correct return type in SetMinThreads ().
106 Sun Jun 13 16:44:39 CEST 2004 Paolo Molaro <lupus@ximian.com>
108 * marshal.c: keep track of struct size with explicit layout
111 2004-06-12 Martin Baulig <martin@ximian.com>
113 * mono-debug-debugger.c: Comment out a debugging g_message().
115 Sat Jun 12 14:15:02 CEST 2004 Paolo Molaro <lupus@ximian.com>
117 * reflection.c, reflection.h: do not free custom attrs that are cached.
118 * icall.c: use braces to make code clearer.
120 2004-06-11 Martin Baulig <martin@ximian.com>
122 * class.h (MonoInflatedField): New type.
123 (MonoClassField): Replaced `MonoType *generic_type' with
124 `MonoInflatedField *generic_info'.
127 (ves_icall_MonoField_Mono_GetGenericFieldDefinition): New icall.
129 2004-06-11 Martin Baulig <martin@ximian.com>
131 * reflection.c (mono_image_create_method_token): Correctly encode
134 2004-06-11 Martin Baulig <martin@ximian.com>
136 * metadata.c (mono_metadata_parse_method_signature): When parsing
137 a MethodDef which has VarArgs, also set sentinelpos if we don't
140 2004-06-11 Martin Baulig <martin@ximian.com>
142 * verify.c (mono_method_verify): In CEE_CALL, use
143 mono_method_get_signature() to get the method's signature, unless
144 we're a PInvoke method.
146 2004-06-10 Jackson Harper <jackson@ximian.com>
148 * assembly.c: Use <path>/lib/mono/gac for the extra paths
149 lookup. Rename MONO_GAC_PATH to MONO_GAC_PREFIX, this is a more
150 logical name as the supplied path is just a prefix to the gac not
151 the direct path to it.
153 Thu Jun 10 20:10:16 CEST 2004 Paolo Molaro <lupus@ximian.com>
155 * reflection.c: make the token for a created method match
156 the token of the MethodBuilder it was created from
157 (IKVM requires this behaviour now).
159 Thu Jun 10 16:02:27 CEST 2004 Paolo Molaro <lupus@ximian.com>
161 * image.c, image.h, appdomain.c, assembly.c, loader.c, metadata.c,
162 reflection.c, socket-io.c: leak fixes.
164 Wed Jun 9 18:23:59 CEST 2004 Paolo Molaro <lupus@ximian.com>
166 * icall.c: handle sentinel pos in vararg methods in position different
169 2004-06-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
171 * culture-info-tables.h: freshly generated.
173 2004-06-09 Martin Baulig <martin@ximian.com>
175 * loader.c (mono_get_method_constrained): Call `mono_class_init
176 (constrained_class)'.
178 2004-06-08 Gert Driesen <drieseng@users.sourceforge.net>
180 * icall.c (ves_icall_MonoType_GetEvent): Handle events without
181 any methods. Fixes #59629.
183 2004-06-08 Atsushi Enomoto <atsushi@ximian.com>
185 * culture-info-tables.h: reflecting locale-builder updates.
187 2004-06-08 Dick Porter <dick@ximian.com>
190 * locales.c: Fixed compile warnings, including a real bug in
191 CompareInfo_internal_compare.
193 2004-06-08 Dick Porter <dick@ximian.com>
196 (ves_icall_System_Globalization_CompareInfo_internal_index):
197 (ves_icall_System_Globalization_CompareInfo_internal_index_char):
198 Double-check the resuls of usearches, because ICU currently
199 ignores most of the collator settings here. Fixes bug 59720.
201 2004-06-08 Dick Porter <dick@ximian.com>
204 (ves_icall_System_Globalization_CompareInfo_internal_index_char):
205 Fix memory leak and segfault-causing typo. No idea how this one
206 lasted so long without being noticed.
208 2004-06-09 Zoltan Varga <vargaz@freemail.hu>
210 * icall.c (ves_icall_Type_GetEvents_internal): Handle events without
211 any methods. Fixes #59629.
213 2004-06-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
216 (mono_assembly_load): search_loaded -> mono_assembly_loaded (we didn't
217 own the critical section before). Removed dead code (that's done
218 in the preload hook).
220 (mono_assembly_load_with_partial_name): call the preload hook.
222 2004-06-08 Martin Baulig <martin@ximian.com>
224 * metadata.c (mono_metadata_signature_alloc): Default
227 * reflection.c (mono_image_get_array_token): Likewise.
229 2004-06-08 Martin Baulig <martin@ximian.com>
231 * icall.c (ves_icall_ModuleBuilder_getMethodToken): New icall.
233 * metadata.c (mono_metadata_parse_method_signature): When parsing
234 a MethodDef which has VarArgs, set sentinelpos.
236 * metadata.h (MonoMethodSignature): Make `sentinalpos' a signed
237 `gint16' since we're using -1 for non-varargs methods.
240 (ReflectionMethodBuilder): Added `MonoArray *opt_types'.
241 (method_encode_signature): Added varargs support.
242 (method_builder_encode_signature): Likewise.
243 (mono_image_get_varargs_method_token): New static method.
244 (mono_image_create_method_token): New public method; this is
245 called via an icall instead of mono_image_create_token() when
246 calling a varargs method.
248 2004-06-08 Lluis Sanchez Gual <lluis@ximian.com>
250 * locales.c: Fixed memory leak in Char.ToLower/ToUpper.
252 2004-06-08 Atsushi Enomoto <atsushi@ximian.com>
254 * culture-info-tables.h : Reflecting the latest locale-builder that
255 fixed empty array representation ({} to {0}).
257 2004-06-07 Jackson Harper <jackson@ximian.com>
259 * assembly.c: It should be <MONO_GAC_PATH>/lib/mono/gac when
260 looking up extra gac paths. This allows MONO_GAC_PATH to act
261 exactly like a prefix.
263 2004-06-08 Zoltan Varga <vargaz@freemail.hu>
265 * reflection.c (mono_reflection_type_from_name): Make a copy of the
266 type name before modifying it. Fixes #59405.
268 2004-06-08 Atsushi Enomoto <atsushi@ximian.com>
270 * culture-info.h: added fields for "all datetime patterns".
271 * locales.c: ( ves_icall_System_Globalization_CultureInfo
272 _construct_datetime_format ()): fill xxx_patterns fields.
273 * object.h: added fields for "all datetime patterns" to
274 MonoDateTimeFormatInfo.
275 * culture-info-tables.h: reflecting locale-builder updates.
277 2004-06-08 Zoltan Varga <vargaz@freemail.hu>
279 * icall.c (ves_icall_Type_GetEvents_internal): Handle the case when
280 the event has no add and remove methods. Fixes #59629.
282 2004-06-05 Sebastien Pouliot <sebastien@ximian.com>
284 * object.c: Fixed possible integer overflow when allocating large
287 2004-06-05 Atsushi Enomoto <atsushi@ximian.com>
289 * culture-info-tables.h: reflecting locale-builder updates.
291 2004-06-05 Atsushi Enomoto <atsushi@ximian.com>
293 * culture-info-tables.h: reflecting locale-builder updates.
295 2004-06-03 Atsushi Enomoto <atsushi@ximian.com>
297 * culture-info-tables.h: reflecting locale-builder updates.
299 2004-06-03 Lluis Sanchez Gual <lluis@ximian.com>
301 * threads.c: Made Thread.Sleep abortable.
303 2004-06-02 Martin Baulig <martin@ximian.com>
305 * mono-debug.h (MONO_DEBUGGER_VERSION): Bumped version to 41.
307 * debug-mono-symfile.h: Bumped symbol file version number to 37.
309 2004-05-31 Zoltan Varga <vargaz@freemail.hu>
311 * marshal.c (mono_marshal_get_runtime_invoke): Fix CR/LFs.
313 2004-05-30 Jackson Harper <jackson@ximian.com>
315 * reflection.c: Do not hardcode assembly versions or public key
316 tokens anymore. All of this except the corlib section was dead
319 2004-05-29 Zoltan Varga <vargaz@freemail.hu>
321 * object.c (mono_runtime_invoke_array): Automatically create boxed
322 objects for byref valuetypes if needed. Fixes #59300.
324 * object.c (mono_method_return_message_restore): Handle
325 MONO_TYPE_OBJECT as well.
327 2004-05-28 Jackson Harper <jackson@ximian.com>
329 * reflection.c: The modified type encoding was causing build
330 problems. Reverted for now.
332 2004-05-28 Jackson Harper <jackson@ximian.com>
334 * reflection.c/h: Take an assembly ref so that we dont create
335 fully qualified names when encoding types in the same assembly as
336 the custom attribute being emitted.
337 * appdomain.c: Increment version number.
339 2004-05-26 Duncan Mak <duncan@ximian.com>
342 (ves_icall_System_Reflection_Assembly_GetReferencedAssemblies):
343 Set the full version number (major, minor, build, revision).
345 2004-05-28 Vladimir Vukicevic <vladimir@pobox.com>
347 * marshal.c (emit_struct_conv): increment src/dst after blit
348 (mono_marshal_get_managed_wrapper,
349 mono_marshal_get_native_wrapper): make sure we have marshalling
350 info before marshalling params (info computation affects
353 * class.c (class_compute_field_layout): correctly deal with
355 (mono_class_layout_fields): Don't do gc_aware_layout for AUTO
356 value types (as per what windows dows by default)
357 (mono_class_setup_mono_type): System.ValueType is blittable
358 (mono_ptr_class_get, mono_fnptr_class_get): Pointer classes are
361 * marshal.c (mono_marshal_load_type_info): flag types as
362 non-blittable if the native layout doesn't match the managed
365 2004-05-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
367 * appdomain.c: don't add stuff in the private search path that is
368 above the application base. If application base is not set, there's
369 no private search path.
371 2004-05-28 Zoltan Varga <vargaz@freemail.hu>
373 * marshal.c (mono_marshal_get_managed_wrapper): Add proper support for
374 byref struct arguments in native->managed marshalling.
376 2004-05-28 Patrik Torstensson <totte@hiddenpeaks.com>
378 * marshal.c (mono_marshal_get_runtime_invoke): correctly
379 cache methods using signature (special case for methods
380 that are value type or string class)
382 * image.c (mono_image_close): clean up allocated GSList's
383 in runtime_invoke_cache.
385 2004-05-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
387 * mono-config.c: set the correct path for mono_cfg_dir on windows when
388 there's no MONO_CFG_DIR environment variable defined.
390 2004-05-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
392 * threads.c: windows version must be >= 0x0500 to include OpenThread.
394 2004-05-28 Lluis Sanchez Gual <lluis@ximian.com>
396 * threadpool.c: Really wait for 500ms after the async call, even if the wait
398 * threads.c: In mono_thread_manage, call OpenThread to ref each handle
399 before waiting for it, and call CloseHandle after the wait to unref it.
400 This will make sure that handles are not disposed too early.
402 2004-05-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
406 * process.c: Use WaitForSingleObjectEx.
407 * threadpool.c: Use WaitForSingleObjectEx. Added some interruption
409 * threads.c, threads.h: Make use of new Ex wait methods. Improved
410 implementation of Thread.Abort and Thread.ResetAbort icalls. Added icalls
411 for Suspend and Resume. Added new mono_thread_stop, used for stoping
412 background threads. Added basic support for Abort in Windows.
413 Start new threads using a managed delegate invoke wrapper. This wrapper
414 has an interruption checkpoint that is needed since an interruption
415 can be requested before the thread leaves the unmanaged code that starts
417 * marshal.c: Added interruption checkpoint after every native call, and
418 also before managed calls for wrappers called from unmanaged code to
419 go into managed code.
420 * object.h: Added new field in MonoThread to keep track of interruption
423 2004-05-20 Zoltan Varga <vargaz@freemail.hu>
425 * marshal.c: Insert SAVE_LMF and RESTORE_LMF opcodes around native
428 2004-05-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
435 * rand.c: getenv -> g_getenv (windows!)
437 * process.c: complete_path is also used on non-windows platforms.
439 2004-05-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
441 * icall.c: new signature for Process_Start.
443 * process.[ch]: new signature for Process_Start. If we're on windows
444 and UseShellExecute is false, we have to search for the program by
445 ourselves if we don't get a full path.
447 2004-05-18 Zoltan Varga <vargaz@freemail.hu>
449 * marshal.c (mono_marshal_get_native_wrapper): Fix up custom
450 marshalling and call CleanUpNativeData if needed. Fixes #58646.
452 2004-05-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
454 * socket-io.c: field value changed for Int32 from 'value' to 'm_value'.
457 2004-05-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
459 * process.c: use double quotes to quote program name and arguments on
460 windows. Fixes bug #58575.
462 2004-05-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
464 * file-io.c: don't return "." and ".." when using windows Find*File.
466 2003-05-17 Patrik Torstensson <totte@hiddenpeaks.com>
468 * marshal.c: Don't pass wrappers to message init because method
469 addressed used to lookup metadata. part of remoting[2|3] fix.
471 2004-05-15 Jackson Harper <jackson@ximian.com>
473 * assembly.c: Remove user gac and implement MONO_GAC_PATH, this
474 path is essentially the same as MONO_PATH except that it points to
475 GACs instead of lib directories.
476 * loader.h: The user gac is gone so we dont need function to
478 * mono-config.c: user gac option is now gone.
480 2004-05-15 Jackson Harper <jackson@ximian.com>
482 * culture-info.h: Make defines more consistent, add calendar data
483 to the culture info table.
484 * culture-info-tables.h: Add basic calendar data. Basically
485 everyone gets default gregorian until all the data is
487 * locales.c: Use the new consistent defines. Set calendar data for
488 culture info objects.
489 * object.h: add a field for calendar data to CultureInfo
491 2004-05-14 Ben Maurer <bmaurer@users.sourceforge.net>
493 * image.c: image->runtime_invoke_cache is keyed on signatures now.
494 * marshal.c (mono_mb_emit_calli): new helper to emit a CEE_CALLI with
496 (mono_mb_emit_managed_call, mono_mb_emit_native_call): use the above.
497 (mono_marshal_get_runtime_invoke): The runtime invoke method now takes
498 an extra param that is the pointer of the method to invoke. The IL for
499 the invoke method is no longer specific to the method, but to the
500 signature of the method. Thus, we can share the same code for multiple
501 methods. This reduces the number of methods that have to be compiled.
503 2004-05-14 Zoltan Varga <vargaz@freemail.hu>
505 * icall.c (ves_icall_System_Reflection_Assembly_load_with_partial_name): Fix warning.
507 * appdomain.c (MONO_CORLIB_VERSION): Bump corlib version.
509 * icall.c: Optimize Buffer.BlockCopy.
511 2004-05-14 Gonzalo Paniagua Javier <gonzalo@ximian.com>
513 * culture-info-tables.h: seems like Spanish and Portuguese cultures had
514 DateTimeFormatInfo.YearMonthPattern like "MMMM' yyyy" (note the single
515 quote). Changed them to "MMMM yyyy".
517 2004-05-12 Miguel de Icaza <miguel@ximian.com>
520 (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_InternalGetBytes): Always close the file.
522 2004-05-13 Zoltan Varga <vargaz@freemail.hu>
524 * reflection.h: Updated after changes to managed structures.
526 * appdomain.c: Bump corlib version.
528 2004-05-12 Gonzalo Paniagua Javier <gonzalo@ximian.com>
530 * Makefile.am: also add libmonoos to libmetadata. Fixes the build on
533 2004-05-12 Gonzalo Paniagua Javier <gonzalo@ximian.com>
535 * Makefile.am: link to ../os/libmonoos.la on windows.
538 -If MONO_DEBUG, warn about non-existing directories in
540 -Added mono_assembly_getrootdir() that replaces MONO_ASSEMBLIES
541 compile time variable.
542 -Removed init_default_path and call mono_set_rootdir from
543 libmonoos.a instead (windows only).
545 * assembly.h: declare mono_assembly_getrootdir().
548 * icall.c: use mono_assembly_getrootdir() instead of MONO_ASSEMBLIES.
550 * loader.c: s/getenv/g_getenv/
552 2004-05-11 Zoltan Varga <vargaz@freemail.hu>
554 * marshal.{h,c}: Add support for UnmanagedType.AsAny.
556 * marshal.c: Use mono_metadata_signature_{alloc,dup} where appropriate.
558 * metadata.h: Add new marshalling conversions.
560 * metadata.h metadata.c (mono_metadata_signature_dup): New helper
563 * reflection.c (mono_reflection_get_type): Lookup the type in all
564 modules of a multi-module assembly. Fixes #58291.
566 2004-05-11 Lluis Sanchez Gual <lluis@ximian.com>
568 * threads.c: Before aborting a background, set the StopRequested
569 state. This avoids throwing the Abort exception.
570 In mono_thread_manage, don't continue with the shutdown until all
571 aborted threads have actually stopped.
573 2004-05-10 Jackson Harper <jackson@ximian.com>
575 * locales.c: Remove the modifier from culture names.
577 2004-05-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
579 * Makefile.am: monosn is not installed any more. It has been deprecated
582 2004-05-07 Jackson Harper <jackson@ximian.com>
585 (ves_icall_System_Globalization_CultureInfo_internal_get_cultures):
586 Fix array construction, add bailout if the length is 0.
588 2004-05-07 Dick Porter <dick@ximian.com>
590 * socket-io.c (addrinfo_to_IPHostEntry): Don't crash if the
591 machine doesn't have a DNS entry. Patch by Urs Muff
592 (umuff@quark.com), fixes bug 57928.
594 2004-05-06 Jackson Harper <jackson@ximian.com>
596 * reflection.c: Handle null PublicTokens properly. alloc mem for
597 assembly names culture so we dont crash when freeing it.
599 2004-05-06 Jackson Harper <jackson@ximian.com>
601 * assembly.c: Check the usergac when loading with partial names.
603 2004-05-05 Sebastien Pouliot <sebastien@ximian.com>
605 * rand.c|h: Added new icall for (optionally) seeding the PRNG. This
606 does nothing for now (not required for Linux/Windows) but the class
607 library can call it (and a newer or modified runtime could need it).
608 * icall.c: Registred icall.
610 2004-05-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
612 * loader.c: prints a message on module loading error we set MONO_DEBUG
613 environment variable.
615 2004-05-05 Jackson Harper <jackson@ximian.com>
617 * appdomain.c: Handle PublicKeyToken=null properly.
619 2004-05-05 Sebastien Pouliot <sebastien@ximian.com>
621 * environment.c|h: Added icall ves_icall_System_Environment_
622 GetOSVersionString to get the current OS version as a string.
623 * icall.c: Registred icall.
625 2004-05-05 Lluis Sanchez Gual <lluis@ximian.com>
627 * object.c: in mono_object_get_virtual_method(), take into account that
628 non-virtual methods don't have a slot in the vtable. Check needed when
629 the object is a proxy.
631 2004-05-05 Zoltan Varga <vargaz@freemail.hu>
633 * marshal.h marshal.c icall.c: Applied patch from vladimir@pobox.com
634 (Vladimir Vukicevic). Implement UnsafeAddrOfPinnedArrayElement.
636 * object.c (mono_class_compute_gc_descriptor): Fix warning.
638 * object.c (mono_runtime_invoke_array): Add an assert so null cannot be
639 passed when a valuetype is expected.
641 * object.c (mono_unhandled_exception): Only set the exit code if the
642 exception happens in the main thread. Fixes thread5.exe.
644 * appdomain.c (get_info_from_assembly_name): Fix infinite loop on
645 invalid names. Fixes #58047.
647 2004-05-03 Jackson Harper <jackson@ximian.com>
649 * assembly.c: This line was committed accidently and is unneeded.
651 2004-05-03 Jackson Harper <jackson@ximian.com>
653 * icall.c: Add new icall for Assembly::LoadWithPartialName
654 * assembly.c/.h: new function that probes the GAC to load partial
655 assembly names by Paolo Molaro.
657 2004-05-03 Gonzalo Paniagua Javier <gonzalo@ximian.com>
659 * appdomain.c: use g_strncasecmp when looking for 'Culture=' et al.
660 * reflection.c: use g_strncasecmp when looking for 'Culture=' et al.
661 (type_get_fully_qualified_name): Added PublicKeyToken when building a
664 2004-05-03 Gonzalo Paniagua Javier <gonzalo@ximian.com>
666 * appdomain.c: fixed check for 'neutral' culture and removed warning.
667 * reflection.c: fix bug when parsing a full type name and Version is not
668 the last thing in the string.
670 2004-05-03 Zoltan Varga <vargaz@freemail.hu>
672 * appdomain.c (get_info_from_assembly_name): Strdup "" to prevent
673 crashes when it is freed.
675 2004-05-03 Gonzalo Paniagua Javier <gonzalo@ximian.com>
677 * assembly.c: print the compat warning to stderr.
679 2004-05-01 Miguel de Icaza <miguel@ximian.com>
681 * assembly.c (mono_assembly_load_references): Add a compatibility
682 hack to run old applications that might be still referencing the
683 3300-based assemblies, only do this for System.xxx.
685 2004-05-01 Jackson Harper <jackson@ximian.com>
687 * appdomain.c: If the culture is neutral we set it to "".
689 2004-04-29 Jackson Harper <jackson@ximian.com>
691 * locales.c: Add some missing MONO_ARCH_SAVE_REGS'.
693 2004-04-29 Andreas Nahr <ClassDevelopment@A-SoftTech.com>
695 * string-icalls.c: added low overhead function for copying chars
696 * icall.c: added needed icall for the above function
698 2004-04-29 Gonzalo Paniagua Javier <gonzalo@ximian.com>
700 * icall.c: fix return value of get_global_assembly_cache. Implemented
701 Environment.GetLogicalDrives.
703 2004-04-28 Bernie Solomon <bernard@ugsolutions.com>
705 * rand.c: try and talk to egd or prngd
706 for random bytes if opening devices fail.
708 2004-04-28 Zoltan Varga <vargaz@freemail.hu>
710 * marshal.c (mono_marshal_load_type_info): Calculate the minimum
711 alignment for the type using the native alignment of its members
712 instead of using klass->min_align.
714 * metadata.c (mono_type_stack_size): Fix size of TYPEDBYREF.
716 2004-04-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
719 * socket-io.c: added check for sys/aio.h.
721 2004-04-28 Dick Porter <dick@ximian.com>
723 * threads.c: Don't abort a thread thats already aborting, when
724 terminating everything.
726 2004-04-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
728 * icall.c: added 2 new async calls for Socket.
730 * socket-io.[ch]: fixed some warnings. Added support for asynchronous
733 * threadpool.c: removed unused variable.
735 2004-04-27 Zoltan Varga <vargaz@freemail.hu>
737 * marshal.c: Handle null properly in PtrToString* icalls. Fixes #57706.
739 Tue Apr 27 15:55:17 CEST 2004 Paolo Molaro <lupus@ximian.com>
741 * locales.c: put back string_invariant_tolower () and
742 string_invariant_toupper ().
744 2004-04-26 David Waite <mass@akuma.org>
749 * unicode.h: remove comma from end of enumeration declarations
751 2004-04-26 David Waite <mass@akuma.org>
753 * debug-mono-symfile.h:
756 * sysmath.c: Define 64 bit constants as long long types (i.e. 10ULL)
759 2004-04-26 Jackson Harper <jackson@ximian.com>
761 * appdomain.c: Increment version number.
763 2004-04-26 Jackson Harper <jackson@ximian.com>
765 * appdomain.c: Set assembly references public token value when
766 PublicKeyToken is specified, not the hash_value. Free public token
767 values when free assembly name data. Previously the public key
768 token was hex decoded, however we are using hex encoded public key
769 tokens, so this is not neccasary.
770 * assembly.c: Lookup assemblies in the gac if their public token
771 value is set. Add function to allow enabling user gac
772 lookups. Specify whether or not the assembly was loaded from the
773 GAC. Compare full assembly names when checking the cache for
774 assemblies (Temporarily disabled see comment in code). Remove
775 mscorlib -> corlib mapping cruft. Add trace-loading. When a user
776 specifies trace-loader they get extra info to stdout on the
777 loading of assemblies.
778 * image.h: Add a field for an assembly references public token
779 value to MonoAssemblyname. Add a field to MonoAssembly to specifiy
780 whether an assembly has been loaded from the GAC.
781 * image.c: Remove a corlib -> mscorlib name mapping.
782 * loader.h: Add function to enable/disable the user gac.
783 * mono-config.c: Check if the usergac is enabled in the config
785 * icall.c: New icall to determine whether or not an assembly has
786 been loaded from the GAC. Remove some mscorlib -> corlib mappings.
787 * tabldefs.h: Add constant for assemblyref flag that specifies a
788 full public key is used instead of a public token.
789 * reflection.c: Remove mscorlib -> corlib mappings. Set
790 PublicTokenValue instead of hash value. This value is a hex
791 string so it does not need to be expanded.
793 2004-04-26 Martin Baulig <martin@ximian.com>
795 * mono-debug-debugger.c (mono_debugger_initialize): Set
796 `mono_debugger_initialized' before calling mono_debug_lock().
798 2004-04-42 Robert Shade <rshade@dvsconsulting.com>
800 * icall.c: icalls for Char.ToUpper/ToLower are now hooked to
801 InternalToUpper/InternalToLower.
802 * locales.c: (ves_icall_System_{Char,String}_InternalTo{Upper,Lower}_Comp)
803 removed invariant culture shortcut. This is now done in managed code.
804 * locales.c: (string_invariant_toupper/tolower) removed.
806 2004-04-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
808 * icall.c: added GetSupportsAsync for Socket (same as MonoIO).
809 Added Poll internal call.
811 * socket-io.[ch]: _wapi_socket == WSASocket. Added internal
812 call for Poll. Select was too heavy for polling a single socket.
814 * threadpool.[ch]: added mono_threadpool_cleanup.
815 * threads.c: use it. Don't use Thread_Abort on windows.
817 2004-04-23 Martin Baulig <martin@ximian.com>
819 * mono-debug-debugger.c (mono_debugger_lookup_assembly): New function.
821 2004-04-23 Sebastien Pouliot <sebastien@ximian.com>
823 * icall.c: Registred new icalls for key pair protection and added an
824 icall for Environment.GetFolderPath on Windows.
825 * security.c|h: Added new icalls for key pair protection.
827 2004-04-22 Gonzalo Paniagua Javier <gonzalo@ximian.com>
829 * socket-io.c: don't display the non-supported family warning for known
830 families. Now this is not displayed on windows when checking support
833 2004-04-22 Gonzalo Paniagua Javier <gonzalo@ximian.com>
835 * class.c: don't display the layout warning for static fields.
837 2004-04-21 Lluis Sanchez Gual <lluis@ximian.com>
839 * icall.cs: Registered new icalls for Char.ToLower and Char.ToUpper.
840 * locales.c, locales.h: Added new icalls for culture-specific
841 Char.ToLower and Char.ToUpper.
843 2004-04-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
845 * threads.c: the 2nd argument when aborting a thread is NULL now. Patch
848 2004-04-20 Martin Baulig <martin@ximian.com>
850 * mono-debug-debugger.c (mono_debugger_lookup_type): Make a copy
851 of the type name before passing it to mono_reflection_type_from_name().
853 2004-04-19 Zoltan Varga <vargaz@freemail.hu>
855 * marshal.c (mono_marshal_get_managed_wrapper): Handle different string
856 encodings here. Fixes #56965.
858 2004-04-18 Bernie Solomon <bernard@ugsolutions.com>
860 * icall.c (ves_icall_System_Text_Encoding_InternalCodePage):
861 fix test on strstr result not that I can see anything that
862 relies on the result.
864 2004-04-18 Zoltan Varga <vargaz@freemail.hu>
866 * metadata.c (mono_type_to_unmanaged): Handle MONO_NATIVE_FUNC as well.
869 * marshal.c (mono_marshal_get_string_encoding): New helper function.
871 * marshal.c (mono_marshal_get_native_wrapper): Use the new helper
872 function to determine which marshalling to use for strings. Fixes
875 * marshal.c (mono_marshal_string_array_to_unicode): Fix warning.
877 * reflection.c (encode_marshal_blob): Add support for LPARRAY.
879 2004-04-15 Bernie Solomon <bernard@ugsolutions.com>
881 * icall.c: #include mono-config.h
883 2004-04-15 Jackson Harper <jackson@ximian.com>
885 * culture-info-tables.h: Fix date formats for en-US culture.
887 2004-04-15 Lluis Sanchez Gual <lluis@ximian.com>
889 * icall.c: Registered icalls for ThreadPool.GetMinThreads and
890 ThreadPool.SetMinThreads.
891 * threadpool.c: Implemented ThreadPool.GetMinThreads and
892 ThreadPool.SetMinThreads.
894 Thu Apr 15 15:36:40 CEST 2004 Paolo Molaro <lupus@ximian.com>
896 * mono-config.c: also load the .config file in the directory
897 where the assembly was found.
899 Thu Apr 15 14:24:49 CEST 2004 Paolo Molaro <lupus@ximian.com>
901 * assembly.c: load per-assembly config files.
902 * icall.c: decrapified code to get the config dir and moved to
904 * image.h, loader.c, loader.h, mono-config.c, mono-config.h: allow
905 per-assembly config files. When doing a dll map lookup give precedence
906 to the per-assembly data.
908 2004-04-14 Martin Baulig <martin@ximian.com>
910 * mono-debug-debugger.h (MonoDebuggerEvent): Removed
911 MONO_DEBUGGER_EVENT_TYPE_ADDED and MONO_DEBUGGER_EVENT_METHOD_ADDED
912 and added MONO_DEBUGGER_EVENT_RELOAD_SYMTABS.
914 * mono-debugger-debugger.c: While the debugger is locked, remember
915 whether the symbol tables have changes and send one single
916 MONO_DEBUGGER_EVENT_RELOAD_SYMTABS when releasing the lock.
918 2004-04-14 Zoltan Varga <vargaz@freemail.hu>
920 * metadata.h: Add STRARRAY_STRWLPARRAY marshalling convention.
922 * marshal.h marshal.c (mono_marshal_string_array_to_unicode): New
925 * marshal.c (mono_marshal_get_native_wrapper): Take CharSet into
926 account when marshalling string arrays. Fixes #56965.
928 2004-04-13 Sebastien Pouliot <sebastien@ximian.com>
930 * icall.c: Add new icalls mapping for security.
931 * security.c|h: Add internal calls for WindowsIdentity,
932 WindowsImpersonationContext and WindowsPrincipal.
934 2004-04-13 Gert Driesen (drieseng@users.sourceforge.net)
936 * class.c: Added comment to ensure the System.MonoDummy class
937 is removed when no longer necessary
939 2004-04-13 Miguel de Icaza <miguel@ximian.com>
941 * appdomain.c: Pass arguments to the bootstraping exceptions to
942 minimize JITed methods at boot
944 * metadata.c (mono_exception_from_name_two_strings): Allow for the
945 second string to be null.
947 * icall.c (ves_icall_System_Text_Encoding_InternalCodePage):
948 Change the protocol to minimize the JIT methods at startup. Now
949 it Returns the internal codepage, if the value of "int_code_page"
950 is 1 at entry, and we can not compute a suitable code page
951 number, returns the code page as a string.
953 2004-04-13 Jackson Harper <jackson@ximian.com>
955 * culture-info-tables.h: Fix number of decimal digits for all
958 2004-04-13 Jackson Harper <jackson@ximian.com>
960 * icall.c: Clairfy out of sync error message. It is not always
961 your corlib that is out of sync.
963 2004-04-13 Zoltan Varga <vargaz@freemail.hu>
965 * icall.c (ves_icall_Type_GetPropertiesByName): Avoid duplicate
966 properties when only the set accessor is overriden. Fixes #55874.
968 2004-04-09 Zoltan Varga <vargaz@freemail.hu>
970 * assembly.c (mono_assembly_load_references): Make this thread safe.
973 2004-04-08 Zoltan Varga <vargaz@freemail.hu>
975 * monosn.c: Add missing initialization calls.
977 2004-04-08 Bernie Solomon <bernard@ugsolutions.com>
980 ves_icall_System_Globalization_CultureInfo_construct_number_format
981 Fix g_assert so it compiles on fussier compilers re int/ptr
984 2004-04-08 Dick Porter <dick@ximian.com>
987 * socket-io.c: Don't set SO_REUSEADDR on windows. Fixes bug
988 53992. Also rearrange the code so that the internal calls return
989 an error value and exceptions are thrown from managed code.
991 * icall.c: Add type info to the socket icalls.
993 2004-04-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
995 * object.h: synchronize MonoCompareInfo with CompareInfo class. Someone
998 2004-04-07 Martin Baulig <martin@ximian.com>
1000 * class.c (mono_class_from_generic_parameter): Don't default
1001 `klass->parent' to `mono_defaults.object_type'.
1003 2004-04-07 Martin Baulig <martin@ximian.com>
1005 * reflection.c (mono_reflection_initialize_generic_parameter): Set
1006 `param->pklass->reflection_info'.
1008 2004-04-07 Jackson Harper <jackson@ximian.com>
1010 * culture-info-tables.h: Fix date separator symbol.
1012 2004-04-07 Martin Baulig <martin@ximian.com>
1014 * icall.c (ves_icall_Type_GetGenericArguments): Moved this icall
1015 from System.Type to System.MonoType.
1017 2004-04-07 Martin Baulig <martin@ximian.com>
1020 (MonoReflectionGenericParam): Added `has_reference_type' and
1021 `has_value_type' fields.
1023 * reflection.c (mono_image_get_generic_param_info): Encode the
1024 correct flags if we have the `class' or `struct' constraint.
1026 2004-04-07 Martin Baulig <martin@ximian.com>
1029 (MonoReflectionGenericParam): Added `MonoBoolean has_ctor_constraint'.
1031 2004-04-07 Jackson Harper <jackson@ximian.com>
1033 * appdomain.c: Revert extra patches, just wanted to bump the
1036 2004-04-07 Jackson Harper <jackson@ximian.com>
1038 * Makefile.am: Add culture-info private headers.
1039 * icall.c: Add new icalls for contructing locales.
1040 * locales.c: Construct CultureInfo objects from lookup tables instead of using ICU.
1041 * locales.h: Declare new culture info construction methods.
1042 * object.h: Add new fields used to avoid the CultureMap to
1044 * culture-info.h: Definition of structs used in the culture info
1046 * culture-info-tables.h: Autogenerated tables that contain culture
1047 info data. This file was generated with the locale-builder tool.
1048 * appdomain.c: Incement corlib version number.
1050 2004-04-07 Bernie Solomon <bernard@ugsolutions.com>
1052 * appdomain.c: (mono_runtime_init) move mono_thread_init
1053 to before mono_object_new calls so critical sections
1054 are initialized before use.
1056 2004-04-07 Martin Baulig <martin@ximian.com>
1059 (ves_icall_TypeBuilder_define_generic_parameter): Removed.
1060 (ves_icall_MethodBuilder_define_generic_parameter): Removed.
1061 (ves_icall_MonoGenericParam_initialize): Removed.
1062 (monogenericparam_icalls): Removed.
1063 (generictypeparambuilder_icalls): Added new table for
1064 System.Reflection.Emit.GenericTypeParameterBuilder.
1067 (mono_reflection_define_generic_parameter): Removed.
1068 (mono_reflection_initialize_generic_parameter): This is now called
1069 from GenericTypeParameterBuilder's .ctor.
1071 2004-04-06 Martin Baulig <martin@ximian.com>
1073 * class.c (mono_class_init): Don't inflate nested classes in a
1075 (mono_type_get_name_recurse): Include the generic arguments for
1076 generic instances and generic type declarations.
1077 (inflate_generic_type): Correctly inflate MONO_TYPE_SZARRAY.
1078 (_mono_class_get_instantiation_name): Removed.
1079 (mono_class_create_generic): Always use `gklass->name' as our name.
1081 * class.h (MonoGenericInst): Removed `nested_in', and `nested'.
1083 * icall.c (ves_icall_MonoGenericInst_GetDeclaringType): Removed.
1084 (ves_icall_MonoGenericInst_GetNestedTypes): Removed.
1085 (ves_icall_MonoMethod_GetGenericParameters): Renamed to
1086 ves_icall_MonoMethod_GetGenericArguments() and correctly handle
1087 closed generic methods here.
1090 (mono_reflection_generic_inst_get_nested_types): Removed.
1091 (inflate_mono_method): Copy the generic parameters from the
1092 MonoMethodHeader into out MonoGenericMethod.
1094 2004-04-06 Martin Baulig <martin@ximian.com>
1097 (MONO_GENERICPARAM_DEPRECATED_CONSTRAINT): Removed.
1099 * metadata.c (GenericParamSchema): Removed "DeprecatedConstraint".
1101 * reflection.c (build_compressed_metadata): If we have any entries
1102 in the GenericParam, MethodSpec or GenericParamConstraint tables,
1103 set the header version to 1.1.
1105 2004-04-06 Martin Baulig <martin@ximian.com>
1107 * class.c (mono_class_init): If we're a generic instance,
1108 initialize our nested classes, too.
1109 (_mono_class_get_instantiation_name): Deal with the new `!%d'
1112 2004-04-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1114 * process.c: quote the argument passed to the shell on windows.
1116 2004-04-05 Zoltan Varga <vargaz@freemail.hu>
1118 * threads.c (mono_alloc_special_static_data): Allow this to be
1119 called during startup.
1121 2004-04-02 Martin Baulig <martin@ximian.com>
1124 (ves_icall_MonoGenericInst_GetDeclaringType): New icall.
1126 2004-04-02 Zoltan Varga <vargaz@freemail.hu>
1128 * icall.c: Fix build.
1130 2004-04-02 Sebastien Pouliot <sebastien@ximian.com>
1132 * Makefile.am: Added security.c|h.
1133 * icall.c: Added icall for get_UserName;
1134 * security.c: New file for security related icalls. Added function
1135 get_UserName for System.Environment (fix #56144).
1136 * security.h: New. Header file for security.c
1138 2004-04-02 Dick Porter <dick@ximian.com>
1140 * icall.c: Deleted the icalls that were obsoleted some time ago
1141 by the ICU string code, and which were mixed into the icall
1142 rearranging. Fixes bug 55969.
1145 * string-icalls.c: Deleted the code that those icalls reference.
1147 2004-04-01 Martin Baulig <martin@ximian.com>
1149 * metadata.h (MONO_CLASS_IS_INTERFACE): New macro.
1151 * class.c (mono_class_from_generic_parameter): Don't set
1152 TYPE_ATTRIBUTE_INTERFACE.
1153 (my_mono_class_from_generic_parameter): Likewise.
1155 2004-04-01 Martin Baulig <martin@ximian.com>
1157 * loader.c (find_method): Added an optional `MonoClass *ic'
1158 argument to search in a specific interface.
1159 (mono_get_method_constrained): New public function.
1161 2004-04-01 Martin Baulig <martin@ximian.com>
1163 * reflection.c (mono_image_get_generic_field_token): Use the
1164 `handleref' cache here.
1166 2004-04-01 Martin Baulig <martin@ximian.com>
1168 * reflection.h (MonoDynamicImage): Added `GHashTable *typespec'.
1170 * reflection.c (create_generic_typespec): Use the `typespec' hash
1171 here, not the `typeref' one.
1173 2004-04-01 Martin Baulig <martin@ximian.com>
1175 * class.c (mono_class_inflate_generic_type): Moved the
1176 functionality into a new static inflate_generic_type() which
1177 returns NULL if it didn't do anything. Only increment the
1178 `mono_stats.inflated_type_count' if we actually inflated
1180 (mono_class_get_full): Check the classes type to see whether we
1181 need to inflate it; also inflate MONO_TYPE_(M)VAR.
1183 2004-04-01 Jackson Harper <jackson@ximian.com>
1185 * reflection.c: Set culture for assembly references.
1187 2004-04-01 Ben Maurer <bmaurer@users.sourceforge.net>
1189 * reflection.[ch], icall.[ch], Fix support for pinning variables.
1191 2004-04-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1194 (do_mono_assembly_open): the critical section also covers
1195 mono_image_open and mono_image_open_from_data. Fixes bug #56327.
1197 2004-03-31 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1200 (mono_manage_threads): abort the background threads when finishing.
1203 2004-03-31 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1205 * gc.c: only close the done_event handle if there was no timeout.
1208 2004-03-30 Martin Baulig <martin@ximian.com>
1210 * icall.c (icall_entries): It's called "System.Activator", not
1211 "System.Activation".
1213 2004-03-30 Martin Baulig <martin@ximian.com>
1215 * class.c (mono_ldtoken): Added `MonoGenericContext *' argument.
1216 (mono_class_create_from_typespec): Likewise.
1218 2004-03-30 Martin Baulig <martin@ximian.com>
1220 * reflection.h (MonoReflectionGenericParam): Use MonoBoolean for
1221 `has_ctor_constraint' and `initialized'.
1223 2004-03-30 Martin Baulig <martin@ximian.com>
1225 * reflection.c (encode_new_constraint): New static function to add
1226 the constructor constraint attribute to a type parameter.
1227 (encode_constraints): Call encode_new_constraint() if necessary.
1230 (MonoReflectionGenericParam): Added `guint32 has_ctor_constraint'.
1232 * row-indexes.h: Added CUSTOM_ATTR_GENERICPAR.
1234 2004-03-29 Ben Maurer <bmaurer@users.sourceforge.net>
1236 * reflection.c, icall.c: add support for pinning variables.
1238 2004-03-29 Bernie Solomon <bernard@ugsolutions.com>
1240 * marshal.c (mono_marshal_get_managed_wrapper):
1241 init bool local with zero rather than null.
1243 2004-03-29 Martin Baulig <martin@ximian.com>
1245 * icall.c (ves_icall_MonoMethod_get_HasGenericParameters): Show
1246 the "official" behavior here.
1247 (ves_icall_MonoMethod_get_Mono_IsInflatedMethod): New interncall.
1249 2004-03-29 Martin Baulig <martin@ximian.com>
1251 * icall.c: Reflect latest API changes.
1253 2004-03-29 Martin Baulig <martin@ximian.com>
1255 * loader.c (mono_get_method_from_token): Also call
1256 mono_metadata_load_generic_params () for abstract and interface
1257 methods; replace the type arguments in the method signature with
1258 the ones which are loaded from the metadata.
1260 2004-03-29 Lluis Sanchez Gual <lluis@ximian.com>
1262 * monitor.c: In mono_monitor_exit(), don't throw an exception if the owner
1263 of the lock is not the current thread. MS.NET don't do it, in spite of
1264 what the documentation says. See bug #56157.
1266 2004-03-28 Martin Baulig <martin@ximian.com>
1268 * class.c (mono_class_init): Don't call init_properties() and
1269 init_events() for generic instances; set `prop->parent' when
1270 inflating properties.
1272 * reflection.c (mono_generic_inst_get_object): Call
1273 `mono_class_init (ginst->klass)'.
1274 (mono_type_get_object): Only create a MonoGenericInst if your
1275 generic type is a TypeBuilder.
1276 (do_mono_reflection_bind_generic_parameters): Only set
1277 `ginst->is_dynamic' if our generic type is a TypeBuilder.
1279 2004-03-28 Zoltan Varga <vargaz@freemail.hu>
1281 * appdomain.c (unload_thread_main): Do not clear proxy_vtable_hash.
1284 2004-03-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1286 * icall.c: added Kill_internal icall.
1287 * process.[ch]: added Kill_internal icall.
1289 2004-03-25 Martin Baulig <martin@ximian.com>
1291 * class.h (MonoStats): Added `generic_instance_count',
1292 `inflated_method_count', `inflated_type_count' and
1293 `generics_metadata_size'.
1295 2004-03-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1297 * reflection.c: no warnings now.
1299 2004-03-25 Martin Baulig <martin@ximian.com>
1301 * class.c (mono_class_get_full): New public function; does a
1302 mono_class_get(), but also takes a `MonoGenericContext *'.
1304 * loader.c (mono_field_from_memberref): Renamed to
1305 `field_from_memberref', made static and added `MonoGenericContext *'
1307 (mono_field_from_token): Added `MonoGenericInst *' argument.
1308 (method_from_memberef): Likewise.
1309 (mono_get_method_from_token): Likewise.
1310 (mono_get_method_full): New public function; does a
1311 mono_get_method(), but also takes a `MonoGenericContext *'.
1313 * verify.c (mono_method_verify): Get the method's generic context
1314 and pass it to mono_field_from_token(), mono_get_method_full() and
1315 mono_class_get_full().
1317 2004-03-25 Martin Baulig <martin@ximian.com>
1319 * class.c (mono_class_inflate_generic_type): Take a
1320 `MonoGenericContext *' instead of a `MonoGenericInst *' and a
1321 `MonoGenericMethod *'.
1323 2004-03-25 Martin Baulig <martin@ximian.com>
1325 * loader.h (MonoMethodInflated): Store the MonoGenericContext
1326 instead of the MonoGenericMethod here.
1328 2004-03-25 Martin Baulig <martin@ximian.com>
1330 * class.h (MonoGenericInst): Added `MonoGenericContext *context';
1331 each time we create a new MonoGenericInst, we also create a new
1332 context which points back to us.
1334 * class.c (inflate_method): Use `ginst->context' instead of
1335 creating a new context.
1337 * loader.c (method_from_memberref): Use
1338 `klass->generic_inst->context' instead of creating a new context.
1340 2004-03-25 Martin Baulig <martin@ximian.com>
1342 * class.h (MonoGenericContext): New struct.
1343 (MonoGenericMethod): Removed `generic_inst'.
1345 * class.c (mono_class_inflate_generic_method): Take a
1346 `MonoGenericContext *' instead of a `MonoGenericMethod *'.
1348 2004-03-25 Martin Baulig <martin@ximian.com>
1350 * loader.h (MonoMethodInflated): New typedef.
1352 * metadata.h (MonoMethodSignature): Removed `gen_method', make
1353 `generic_param_count' consume just 30 bits, added `is_inflated'
1354 and `has_type_parameters' flags (one bit each).
1356 * class.c (mono_class_inflate_generic_method): Create a
1357 MonoMethodInflated instead of a MonoMethodNormal and set
1358 `is_inflated' in the method signature.
1360 * class.h (MonoGenericMethod): Removed `generic_method'.
1362 2004-03-25 Lluis Sanchez Gual <lluis@ximian.com>
1365 properties and events, that's what caused the regressions.
1367 2004-02-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1370 (mono_async_result_new): the handle can be NULL.
1372 * threadpool.c: Use an event instead of a semaphore, don't initialize
1373 it until needed. This saves quite a few semaphores from being created
1374 when using the threadpool.
1376 2004-02-18 Zoltan Varga <vargaz@freemail.hu>
1378 * object.c (mono_string_is_interned_lookup): Fix interning of long
1379 strings. Fixes #54473.
1381 * domain.c (ldstr_equal): Optimize if the two strings are equal.
1383 * icall.c: Revert the klass->refclass changes since they introduce
1384 regressions (bug #54518).
1386 2004-02-18 Martin Baulig <martin@ximian.com>
1388 * class.c (mono_class_init): If we're a generic instance and don't
1389 come from a TypeBuilder, inflate our members here.
1390 (mono_class_from_generic): Removed; just use `ginst->klass' instead.
1391 (mono_class_create_generic): New public method.
1392 (mono_class_initialize_generic): Removed.
1393 (get_instantiation_name): Renamed to
1394 _mono_class_get_instantiation_name() and made it public.
1396 2004-02-18 Martin Baulig <martin@ximian.com>
1398 * class.c (mono_class_inflate_generic_type): Clear the new
1399 instance's `nginst->klass' when inflating a generic instance.
1400 (mono_class_is_subclass_of): Added (basic) support for generic
1403 Tue Feb 17 21:40:16 CET 2004 Paolo Molaro <lupus@ximian.com>
1405 * appdomain.h, domain.c: use a MonoCodeManager instead of a
1406 MonoMempool to hold compiled native code.
1408 2004-02-17 Martin Baulig <martin@ximian.com>
1410 * class.h (MonoDynamicGenericInst): Added `count_properties' and
1413 * reflection.c (mono_reflection_generic_inst_initialize): Added
1414 `MonoArray *properties' argument.
1416 * icall.c (ves_icall_MonoGenericInst_GetProperties): New interncall.
1418 2004-02-17 Martin Baulig <martin@ximian.com>
1420 * icall.c (ves_icall_Type_GetFields): Renamed to
1421 ves_icall_Type_GetFields_internal() and added a
1422 `MonoReflectionType *rtype' argument; pass it to
1423 mono_field_get_object() to set the field's "reflected" type.
1424 (ves_icall_Type_GetConstructors): Likewise.
1425 (ves_icall_Type_GetEvents): Likewise.
1426 (ves_icall_Type_GetMethodsByName): Added `MonoReflectionType *rtype'
1427 argument; pass it to mono_method_get_object() to set the method's
1430 2004-02-17 Martin Baulig <martin@ximian.com>
1432 * class.h (MonoDynamicGenericInst): New type.
1433 (MonoGenericInst): Added `dynamic_info' and `is_dynamic' fields.
1435 * icall.c (ves_icall_MonoGenericInst_GetMethods): New interncall.
1436 (ves_icall_MonoGenericInst_GetConstructors): New interncall.
1437 (ves_icall_MonoGenericInst_GetFields): New interncall.
1439 * class.c (mono_class_from_generic): Don't call
1440 mono_class_initialize_generic() if this is a dynamic instance;
1441 ie. it's being created from a TypeBuilder.
1442 Use MONO_TYPE_GENERICINST for `class->this_arg.type' and
1443 `class->byval_arg.type'.
1445 * reflection.c (mono_reflection_inflate_method_or_ctor): Renamed
1446 to `inflate_method' and made static.
1447 (mono_reflection_inflate_field): Removed.
1448 (mono_reflection_generic_inst_initialize): New public method.
1450 * reflection.h (MonoReflectionGenericInst): Removed `methods',
1451 `ctors' and `fields'; added `initialized'.
1453 2004-02-14 Zoltan Varga <vargaz@freemail.hu>
1455 * debug-helpers.c (mono_method_full_name): Fix output for empty
1458 2004-02-12 Martin Baulig <martin@ximian.com>
1460 * class.h (MonoClassField): Added `MonoType *generic_type'.
1462 * reflection.c (mono_image_get_fieldref_token): Added support for
1463 instantiated generic types.
1464 (field_encode_inflated_field): Removed.
1465 (mono_image_get_inflated_field_token): Removed.
1466 (mono_reflection_inflate_field): Return a `MonoReflectionField *'.
1468 * reflection.h (MonoReflectionInflatedField): Removed.
1470 2004-02-12 Martin Baulig <martin@ximian.com>
1472 * metadata.h (MonoMethodHeader, MonoMethodSignature): Moved the
1473 `gen_method' field from MonoMethodHeader to MonoMethodSignature.
1475 * reflection.c (mono_image_get_methodspec_token): Take a
1476 `MonoMethod *' instead of a `MonoReflectionInflatedMethod *'.
1477 (mono_image_create_token): Check whether we have a
1478 `method->signature->gen_method' and call
1479 mono_image_get_methodspec_token() if appropriate.
1480 (inflated_method_get_object): Removed.
1481 (mono_reflection_bind_generic_method_parameters): Return a
1482 `MonoReflectionMethod *', not a `MonoReflectionInflatedMethod *'.
1483 (mono_reflection_inflate_method_or_ctor): Likewise.
1485 * reflection.h (MonoReflectionInflatedMethod): Removed.
1487 2004-02-12 Zoltan Varga <vargaz@freemail.hu>
1489 * marshal.c (mono_marshal_get_native_wrapper): Implement proper support
1490 for custom valuetype marshalling.
1492 * icall.c (icall_entries): Diagnostic -> Diagnostics. Fixes #54261.
1494 2004-02-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1496 * icall.c: fixed WSAGetLastError_internal name.
1498 2004-02-11 Zoltan Varga <vargaz@freemail.hu>
1500 * threads.c (mono_thread_attach): Allow this to be called multiple
1503 * threads.c (build_wait_tids): Do not wait for ourselves.
1505 * threads.c (mono_thread_pop_appdomain_ref): Avoid crash if the
1506 appdomain list is empty.
1508 * marshal.c (mono_marshal_get_native_wrapper): Do not free the
1509 memory returned by mono_string_builder_to_utf16, since it points into
1510 managed memory. Thanks to Bernie Solomon for noticing this.
1512 * icall.c: Add AppDomainSetup icalls.
1514 * reflection.h (MonoReflectionMethodAux): Add 'param_cattr' field.
1516 * reflection.c (mono_custom_attrs_from_param): Add support for dynamic
1519 * reflection.c (reflection_methodbuilder_to_mono_method): Save
1520 custom attributes to the method_aux struct. Also fix array indexes etc.
1522 * loader.c (mono_method_get_param_names): Make dynamic case work again.
1524 Tue Feb 10 17:03:04 CET 2004 Paolo Molaro <lupus@ximian.com>
1526 * icall.c, loader.c: icall cleanup: we save quite a bit of memory
1527 (both static and runtime) and reduce startup time.
1529 2004-02-10 Zoltan Varga <vargaz@freemail.hu>
1531 * marshal.c (mono_marshal_get_native_wrapper): Throw an exception on
1532 AsAny marshalling conversion instead of crashing.
1534 * marshal.c: Fix warnings.
1536 2004-02-09 Martin Baulig <martin@ximian.com>
1538 * class.h (MonoGenericMethod): Added `MonoMethod *declaring'.
1540 * reflection.h (MonoReflectionInflatedMethod): Removed the
1541 `declaring' field, it's now in the unmanaged MonoGenericMethod.
1543 * reflection.c (method_encode_methodspec): Removed the `method'
1544 argument; we get it from `gmethod->declaring'.
1545 (inflated_method_get_object): Removed the `declaring' argument.
1547 2004-02-09 Martin Baulig <martin@ximian.com>
1549 * class.h (MonoGenericMethod): New type.
1550 (MonoGenericInst): Remove `mtype_argc', `mtype_argv' and
1553 * metadata.h (MonoMethodHeader): Replaced the `geninst' field with
1554 a `MonoGenericMethod *gen_method' one.
1556 * class.c (mono_class_inflate_generic_type): Take an additional
1557 `MonoGenericMethod * argument. This is only non-NULL if we're
1558 inflating types for a generic method.
1559 (mono_class_inflate_generic_signature): Renamed to
1560 inflate_generic_signature() and made static; take a
1561 `MonoGenericMethod *' argument instead of a `MonoGenericInst *'.
1562 (inflate_generic_header): Take a `MonoGenericMethod *' argument
1563 instead of a `MonoGenericInst *' one.
1564 (mono_class_inflate_generic_method): Likewise.
1566 * reflection.c (encode_generic_method_sig): Take a
1567 `MonoGenericMethod *' argument instead of a `MonoGenericInst *'.
1568 (method_encode_methodspec): Likewise.
1569 (inflated_method_get_object): Likewise.
1571 * reflection.h (MonoReflectionGenericInst): Replaced the `ginst'
1572 field with a `MonoGenericMethod *gmethod' one.
1574 2004-02-08 Bernie Solomon <bernard@ugsolutions.com>
1576 * class.h (mono_class_has_parent): add parens to expansion
1579 2004-02-08 Martin Baulig <martin@ximian.com>
1581 * image.h (MonoImage): Removed `generics_cache'.
1583 * class.c (mono_class_from_generic): Take a `MonoGenericInst *'
1584 instead of a `MonoType *' argument; removed the `inflate_methods'
1585 argument. Don't inflate methods here.
1587 * loader.c (find_method): If it's a generic instance, call
1588 mono_class_init() on the `sclass->generic_inst->generic_type'.
1590 * metadata.c (mono_type_size): Make this work on uninitial
1593 * reflection.c (mono_reflection_create_runtime_class): Remove
1594 errorneous assignment to klass->element_class, since it is already
1595 done in mono_reflection_setup_internal_class.
1597 2004-01-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1599 * gc.c: added missing LeaveCriticalSection.
1600 * icall.c: indented a couple of lines.
1601 * threadpool.c: remove dangling LeaveCriticalSection. Don't wait forever
1602 if we call EndInvoke inside a callback. Fixes bug #52601.
1604 2004-01-07 Martin Baulig <martin@ximian.com>
1606 * mono-debug-debugger.h
1607 (MonoDebuggerIOLayer): Added `GetCurrentThreadID'.
1609 2004-01-06 Miguel de Icaza <miguel@ximian.com>
1611 * appdomain.c: Use messages in NotImplementedException.
1613 * exception.c (mono_get_exception_not_implemented): Now this takes
1616 * marshal.c (emit_str_to_ptr_conv): g_warning and throw an
1617 exception instead of g_asserting an aborting when something is not
1620 Add some inline docs.
1622 2004-01-05 Zoltan Varga <vargaz@freemail.hu>
1624 * reflection.h: Update after changes to object layout.
1626 * reflection.c: Implement saving of unmanaged aka win32 resources.
1628 * appdomain.c: Bump version number.
1630 * appdomain.c (ves_icall_System_AppDomain_InternalSetDomainByID):
1631 Handle missing domains gracefully.
1633 2004-01-05 Atsushi Enomoto <atsushi@ximian.com>
1635 * file-io.c : On Windows, there are much more invalid_path_chars.
1637 Fri Jan 2 13:35:48 CET 2004 Paolo Molaro <lupus@ximian.com>
1639 * class.h, object.c: prepare for GetType () speedup.
1641 2003-12-24 Atsushi Enomoto <atsushi@ximian.com>
1643 * profiler.c: workaround for --profile null reference exception on
1644 cygwin. Patch by Patrik Torstensson.
1646 2003-12-22 Bernie Solomon <bernard@ugsolutions.com>
1648 * marshal.c: (ves_icall_System_Runtime_InteropServices_Marshal_Read/WriteXXX)
1649 make work for unaligned access.
1651 Mon Dec 22 18:37:02 CET 2003 Paolo Molaro <lupus@ximian.com>
1653 * class.c: small cleanup (class->fields [i] -> field).
1654 * image.c: check address of metadata is valid.
1656 2003-12-22 Zoltan Varga <vargaz@freemail.hu>
1658 * assembly.h assembly.c (mono_assembly_loaded): New public function to
1659 search the list of loaded assemblies.
1661 * reflection.c (mono_reflection_type_from_name): Use
1662 mono_assembly_loaded instead of mono_image_loaded.
1664 * reflection.c: Fix warnings.
1666 2003-12-20 Zoltan Varga <vargaz@freemail.hu>
1668 * image.h (MonoImage): Add a new 'dynamic' field to denote that the image
1669 is dynamic. This is needed since an assembly can contain both dynamic and
1672 * class.c loader.c metadata.c object.c: Use image->dynamic instead of
1675 * icall.c reflection.c: Add new AssemblyBuilder:AddModule icall.
1677 * reflection.h (MonoReflectionAssemblyBuilder): Add 'loaded_modules' field
1678 to store modules loaded using AddModule.
1680 * reflection.c (mono_image_fill_file_table): Generalize this so it works
1683 * reflection.c (mono_image_fill_export_table_from_class): New helper function.
1685 * reflection.c (mono_image_fill_export_table_from_module): New function to
1686 fill out the EXPORTEDTYPES table from a module.
1688 * reflection.c (mono_image_emit_manifest): Refactor manifest creation code
1689 into a separate function. Also handle loaded non-dynamic modules.
1691 * reflection.c (mono_image_basic_init): Fix memory allocation.
1693 * appdomain.c (MONO_CORLIB_VERSION): Bump corlib version.
1695 * assembly.c (mono_assembly_load_references): Make this public.
1697 2003-12-19 Martin Baulig <martin@ximian.com>
1699 * class.c (mono_class_initialize_generic): Made this static, take
1700 a `MonoGenericInst *' instead of a `MonoClass *'.
1701 (mono_class_from_generic): Call mono_class_initialize_generic()
1702 unless we're already initialized or being called from
1703 do_mono_metadata_parse_generic_inst().
1705 * class.h (MonoGenericInst): Added `initialized' and
1706 `init_pending' flags.
1708 * metadata.c (do_mono_metadata_parse_generic_inst): Don't call
1709 `mono_class_init (gklass)' or mono_class_initialize_generic()
1710 here; set `generic_inst->init_pending' while parsing the
1713 2003-12-19 Bernie Solomon <bernard@ugsolutions.com>
1715 * locales.c: include string.h for memxxx prototypes
1717 2003-12-19 Zoltan Varga <vargaz@freemail.hu>
1719 * icall.c (ves_icall_MonoField_GetValueInternal): Do not run the class
1720 constructor when accessing literal fields.
1722 2003-12-17 Zoltan Varga <vargaz@freemail.hu>
1724 * appdomain.c (MONO_CORLIB_VERSION): Bump corlib version.
1726 * reflection.c (assembly_add_resource_manifest): New function to fill
1727 the MANIFESTRESOURCE table.
1729 * reflection.c (mono_image_build_metadata): Emit MANIFESTRESOURCE table.
1731 * reflection.h: Update to changes in class layout.
1733 * icall.c (ves_icall_System_Environment_get_HasShutdownStarted):
1734 Reenable call to mono_runtime_is_shutting_down ().
1736 * appdomain.c (mono_runtime_is_shutting_down): New helper function to
1737 determine if the runtime is shutting down.
1739 2003-12-16 Jackson Harper <jackson@ximian.com>
1741 * icall.c: comment out call to mono_runtime_is_shutting_down to
1744 2003-12-16 Zoltan Varga <vargaz@freemail.hu>
1746 * icall.c (ves_icall_System_Reflection_Assembly_GetManifestResourceInternal): Add support for loading resources from modules.
1747 (ves_icall_System_Environment_get_HasShutdownStarted): New icall.
1749 2003-12-15 Bernie Solomon <bernard@ugsolutions.com>
1751 * reflection.c: move definition of swap_with_size
1752 to before its first call
1754 2003-12-15 Zoltan Varga <vargaz@freemail.hu>
1756 * appdomain.c (mono_runtime_is_shutting_down): New public function.
1758 * icall.c (ves_icall_System_Environment_get_HasShutdownStarted): New
1761 * object.c: Fix warnings.
1763 * icall.c (ves_icall_Type_Get...): Only consider inherited static
1764 members if FlattenHierarchy is set.
1766 * reflection.c (mono_image_add_decl_security): New function to emit
1767 declarative security.
1769 * reflection.h reflection.c: Add support for declarative security.
1771 * appdomain.c (MONO_CORLIB_VERSION): Bump version number.
1773 2003-12-13 Zoltan Varga <vargaz@freemail.hu>
1775 appdomain.c (MONO_CORLIB_VERSION): Bump version number.
1777 * appdomain.c verify.c: Moved corlib version checking into its own
1778 function in appdomain.c since it needs to create vtables etc.
1780 2003-12-13 Patrik Torstensson <p@rxc.se>
1782 * marshal.c (mono_remoting_wrapper): Fix bug 48015, using TP as this
1783 instead of unwrapped server.
1785 2003-12-12 Zoltan Varga <vargaz@freemail.hu>
1787 * verify.c (check_corlib): Fix field index.
1789 2003-12-10 Zoltan Varga <vargaz@freemail.hu>
1791 * icall.c: Applied patch from Todd Berman (tbermann@gentoo.org). New
1794 2003-12-10 Bernie Solomon <bernard@ugsolutions.com>
1796 * process.c: (ves_icall_System_Diagnostics_Process_GetWorkingSet_internal
1797 ves_icall_System_Diagnostics_Process_SetWorkingSet_internal):
1798 cope with sizeof(size_t) != sizeof(guint32).
1800 2003-12-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1802 * process.[ch]: the 'pid' field in MonoProcInfo stores GetLastError
1805 2003-12-10 Mark Crichton <crichton@gimp.org>
1807 * icall.c: removed the GetNonZeroBytes. We now handle this case
1810 * rand.c, rand.h: Same here. Also cleaned up the clode slightly.
1812 Tue Dec 9 15:36:18 CET 2003 Paolo Molaro <lupus@ximian.com>
1814 * class.h, class.c, icall.c, marshal.c, object.c: ignore fields
1817 2003-12-09 Zoltan Varga <vargaz@freemail.hu>
1819 * verify.c (check_corlib): Handle the case when the version field is
1820 initialized by a static constructor.
1822 2003-12-08 Patrik Torstensson <p@rxc.se>
1824 * rand.c (InternalGetBytes): Implemented win32 version with cryptapi
1826 2003-12-08 Martin Baulig <martin@ximian.com>
1828 * icall.c (ves_icall_TypeBuilder_define_generic_parameter): Return
1829 a MonoReflectionGenericParameter, also take the parameter index
1830 and name as arguments.
1831 (ves_icall_MethodBuilder_define_generic_parameter): Likewise.
1832 (ves_icall_MonoGenericParam_initialize): New interncall.
1833 (ves_icall_Type_make_byref_type): New interncall.
1835 * reflection.h (MonoReflectionGenericParam): Derive from
1836 MonoReflectionType, not just from MonoObject. Added `refobj' and
1839 * reflection.c (mono_reflection_define_generic_parameter): Create
1840 and return a new MonoRefl
1841 from all modules inside the assembly.
1843 2003-11-11 Martin Baulig <martin@ximian.com>
1845 * reflection.c (mono_reflection_bind_generic_parameters): Make
1846 this work for interfaces.
1848 2003-11-11 Martin Baulig <martin@ximian.com>
1850 * mono-debug.c (mono_debug_add_type): Ignore unknown modules.
1852 2003-11-11 Martin Baulig <martin@ximian.com>
1854 * reflection.c (mono_reflection_inflate_method_or_ctor): Allow
1855 "MonoInflatedMethod" and "MonoInflatedCtor".
1857 2003-11-11 Zoltan Varga <vargaz@freemail.hu>
1859 * reflection.c (resolution_scope_from_image): Use the assembly table
1860 from the manifest module, since other modules don't have it.
1862 * debug-helpers.c (mono_type_full_name): New helper function.
1864 * image.h (MonoAssembly): Change 'dynamic' to a boolean.
1866 * image.c (mono_image_load_file_for_image): New public function which
1867 is a replacement for the load_file_for_image in class.c.
1869 * assembly.c (mono_assembly_load_module): A wrapper for the function
1870 above which does assembly association and reference loading too.
1872 * class.c (mono_class_from_name): Call mono_assembly_load_module.
1874 2003-11-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1876 * appdomain.c: not all of the attributes for the full assembly name
1877 are required and the order doesn't matter. Fixes bug #50787.
1879 2003-11-10 Dick Porter <dick@ximian.com>
1881 * locales.c: Use platform-endian UTF16
1883 2003-11-10 Zoltan Varga <vargaz@freemail.hu>
1885 * reflection.c: Emit FILE and EXPORTEDTYPE tables.
1887 2003-11-10 Martin Baulig <martin@ximian.com>
1890 (mono_metadata_load_generic_params): Make this actually work.
1892 * reflection.c (mono_reflection_bind_generic_parameters): If our
1893 parent is a generic instance, pass all the `types' to it, no
1894 matter whether it has the same number of type parameters or not.
1896 2003-11-10 Zoltan Varga <vargaz@freemail.hu>
1898 * reflection.c: Emit FILE and EXPORTEDTYPE tables.
1900 * assembly.c (mono_assembly_load_references): Move the image<->assembly
1901 assignment code to this function so it gets called recursively for all
1904 * image.c (load_modules): Remove the assembly assignment since it is
1905 now done by mono_assembly_load_references.
1907 * icall.c (ves_icall_System_Reflection_Assembly_InternalGetType):
1908 Add 'module' argument.
1909 (mono_module_get_types): New helper function.
1910 (ves_icall_System_Reflection_Module_InternalGetTypes): New icall.
1912 2003-11-08 Martin Baulig <martin@ximian.com>
1914 * class.c (mono_class_inflate_generic_method): Interface method
1915 don't have a header.
1917 * reflection.c (mono_image_get_methodspec_token): Take an
1918 additional `MonoGenericInst *' argument instead of reading it from
1919 the header; this is necessary to support interfaces.
1920 (mono_image_create_token): Pass the `MonoGenericInst *' from the
1921 MonoReflectionInflatedMethod to mono_image_get_methodspec_token().
1922 (inflated_method_get_object): Take an additional `MonoGenericInst *'
1925 * reflection.h (MonoReflectionInflatedMethod): Added
1926 `MonoGenericInst *ginst'.
1928 2003-11-07 Zoltan Varga <vargaz@freemail.hu>
1930 * gc.c (mono_domain_finalize): Fix compilation for no GC case.
1932 2003-11-06 Zoltan Varga <zovarga@ws-zovarga2>
1934 * appdomain.c (mono_domain_unload): Add a workaround for bug #27663.
1936 2003-11-06 Zoltan Varga <vargaz@freemail.hu>
1939 (reflection_methodbuilder_from_method_builder):
1940 (reflection_methodbuilder_from_ctor_builder): New helper functions to
1941 initialize a ReflectionMethodBuilder structure.
1942 (mono_image_get_methodbuilder_token):
1943 (mono_image_get_ctorbuilder_token): New functions to emit memberref
1944 tokens which point to types in another module inside the same assembly.
1946 * reflection.c: Use the new helper functions.
1948 * reflection.c (mono_image_basic_init): Initialize basedir and culture.
1950 * icall.c loader.c reflection.c: Use ModuleBuilder->dynamic_image
1951 instead of AssemblyBuilder->dynamic_assembly in the appropriate places.
1953 * reflection.c (resolution_scope_from_image): Emit a moduleref if
1956 * reflection.c (mono_image_build_metadata): Emit metadata only for the
1957 current module. Emit the manifest only for the main module.
1959 * reflection.c (mono_image_create_token): Add assertion when a
1960 memberref needs to be created.
1962 * reflection.c reflection.h (MonoDynamicAssembly): Remove unused fields.
1964 * reflection.c (mono_reflection_get_custom_attrs_blob): Allocate a
1965 larger buffer for the custom attribute blob. Fixes #50637.
1967 2003-11-03 Gonzalo Paniagua Javier <gonzalo@ximian.com>
1969 * threadpool.c: notify listener on async processing handles after
1970 invoking the async callback. Thanks to Zoltan.
1972 2003-11-03 Zoltan Varga <vargaz@freemail.hu>
1974 * reflection.c (create_dynamic_mono_image): Call mono_image_init to
1975 avoid code duplication.
1977 * reflection.h (MonoDynamicImage): New type which is currently unused,
1978 but will be used through the ref.emit code in place of
1979 MonoDynamicAssembly.
1981 * reflection.h (MonoReflectionAssemblyBuilder): Track changes to the
1984 * reflection.c (create_dynamic_mono_image): Rewrote so it now creates
1985 a MonoDynamicImage instead of just a MonoImage.
1987 * reflection.h reflection.c icall.c: Move nearly all AssemblyBuilder
1988 icalls to ModuleBuilder but keep their semantics, so they will work
1989 with moduleb->assemblyb. This will change later.
1991 2003-11-03 Zoltan Varga <vargaz@freemail.hu>
1993 * reflection.h (MonoReflectionAssemblyBuilder): Track changes to the
1996 * reflection.c (mono_image_build_metadata): Avoid creation of a default
1997 main module, since it is now done by the managed code.
1999 2003-11-03 Martin Baulig <martin@ximian.com>
2001 * reflection.c (mono_reflection_inflate_method_or_ctor): Set
2002 `ginst->klass' here.
2003 (method_encode_methodspec): Don't use the `ginst->generic_method's
2004 klass if it's a generic instance, use `ginst->klass' in this case.
2006 2003-11-03 Martin Baulig <martin@ximian.com>
2008 * reflection.c (mono_image_get_generic_method_param_info):
2009 Removed, use mono_image_get_generic_param_info() instead.
2010 (mono_image_get_type_info): Write the GenericParam table before
2011 the Method table. This is neccessary because in the GenericParam
2012 table, type parameters of the class (ie. '!0' etc.) must come
2013 before the ones from its generic methods (ie. '!!0' etc).
2015 2003-11-03 Zoltan Varga <vargaz@freemail.hu>
2017 * icall.c (ves_icall_System_Reflection_Assembly_FillName): Fill out AssemblyName->codebase. Fixes #50469.
2019 2003-11-02 Martin Baulig <martin@ximian.com>
2021 * reflection.c (create_generic_typespec): Take a
2022 `MonoReflectionTypeBuilder *' instead of a `MonoType *' and get
2023 the generic parameters from it.
2025 2003-11-02 Martin Baulig <martin@ximian.com>
2027 * reflection.c (fieldref_encode_signature): Take a `MonoType *'
2028 instead of a `MonoClassField *' since we just need the type.
2029 (create_generic_typespec): New static function. Creates a
2030 TypeSpec token for a generic type declaration.
2031 (mono_image_get_generic_field_token): New static function.
2032 (mono_image_create_token): If we're a FieldBuilder in a generic
2033 type declaration, call mono_image_get_generic_field_token() to get
2036 2003-11-02 Martin Baulig <martin@ximian.com>
2039 (MonoReflectionInflatedMethod, MonoReflectionInflatedField): Added
2040 `MonoReflectionGenericInst *declaring_type' and
2041 `MonoReflectionGenericInst *reflected_type' fields.
2043 * reflection.c (mono_reflection_inflate_method_or_ctor): Take a
2044 `MonoReflectionGenericInst *declaring_type' and a
2045 `MonoReflectionGenericInst *reflected_type' argument instead of a
2046 single `MonoReflectionGenericInst *type' one. Set
2047 `res->declaring_type' and `res->reflected_type' from them.
2048 (mono_reflection_inflate_field): Likewise.
2050 2003-11-02 Martin Baulig <martin@ximian.com>
2052 * class.c (mono_class_setup_vtable): Don't store generic methods
2055 2003-11-02 Martin Baulig <martin@ximian.com>
2057 * reflection.h (MonoReflectionGenericInst): Added
2058 `MonoReflectionType *declaring_type'.
2060 * reflection.c (mono_reflection_bind_generic_parameters): Use
2061 `if (tb->parent)' instead of `klass->parent'.
2063 2003-11-01 Zoltan Varga <vargaz@freemail.hu>
2065 * assembly.c (mono_assembly_open): Avoid crash if a module is loaded
2066 with an empty ASSEMBLY table.
2068 * reflection.c (mono_image_build_metadata): Avoid using the same loop
2069 variable in the inner and outer loops.
2071 2003-10-31 Zoltan Varga <vargaz@freemail.hu>
2073 * metadata.h (mono_metadata_make_token): Put parentheses around macro
2076 * appdomain.h appdomain.c (ves_icall_System_AppDomain_InternalPushDomainRef): Fix signature.
2078 * appdomain.c appdomain.h icall.c: Get rid of the InvokeInDomain
2079 icalls. Instead, do everything in managed code. This is needed since
2080 it is hard to restore the original domain etc. in unmanaged code in the
2081 presence of undeniable exceptions.
2083 * appdomain.c (ves_icall_System_AppDomain_InternalPushDomainRef):
2084 New icalls to push and pop appdomain refs.
2086 2003-10-31 Martin Baulig <martin@ximian.com>
2088 * class.c (inflate_generic_type): Renamed to
2089 mono_class_inflate_generic_type() and made it public.
2091 * icall.c ("System.Reflection.MonoGenericInst::inflate_field"):
2094 * loader.c (mono_field_from_memberref): Also set the retklass for
2097 * fielder.c (mono_image_get_inflated_field_token): New static
2098 method; creates a metadata token for an inflated field.
2099 (mono_image_create_token, fixup_method): Added support for
2100 "MonoInflatedField".
2101 (fieldbuilder_to_mono_class_field): New static function.
2102 (mono_reflection_inflate_field): New public function.
2105 (MonoReflectionGenericInst): Added `MonoArray *fields'.
2106 (MonoReflectionInflatedField): New typedef.
2108 2003-10-30 Bernie Solomon <bernard@ugsolutions.com>
2110 * socket-io.c (in6_addr ipaddress_to_struct_in6_addr): fix
2111 for Solaris and other platforms without s6_addr16
2113 2003-10-30 Martin Baulig <martin@ximian.com>
2115 * class.c (inflate_generic_type): Take just one `MonoGenericInst *'
2116 argument instead of two.
2117 (mono_class_inflate_generic_signature): Likewise.
2118 (inflate_generic_header): Likewise.
2119 (mono_class_inflate_generic_method): Likewise. In addition, if
2120 `ginst->klass' is set, it becomes the new `method->klass'.
2122 * class.h (MonoGenericInst): Removed the `gpointer mbuilder'
2125 * reflection.c (encode_generic_method_sig): Write a 0xa as the
2127 (method_encode_methodspec): If we have generic parameters, create
2128 a MethodSpec instead of a MethodRef.
2129 (fixup_method): Added support for "MonoInflatedMethod" and
2131 (mono_image_create_token): Added support for "MonoInflatedMethod"
2132 and "MonoInflatedCtor".
2133 (inflated_method_get_object): New static function; returns a
2134 managed "System.Reflection.MonoInflatedMethod" object.
2135 (mono_reflection_bind_generic_method_parameters): Return a
2136 `MonoReflectionInflatedMethod' instead of a `MonoReflectionMethod'.
2137 (mono_reflection_inflate_method_or_ctor): Likewise.
2138 (mono_image_get_generic_method_param_info): Initialize unused
2140 (mono_image_get_generic_param_info): Likewise.
2142 * reflection.h (MonoReflectionInflatedMethod): New public
2143 typedef. Corresponds to the managed "S.R.MonoInflatedMethod" and
2144 "S.R.MonoInflatedCtor" classes.
2146 * loader.c (method_from_memberref): If we're a TypeSpec and it
2147 resolves to a generic instance, inflate the method.
2149 2003-10-28 Dick Porter <dick@ximian.com>
2151 * object.c (mono_runtime_run_main): Convert command-line arguments
2152 into utf8, falling back to the user's locale encoding to do so.
2154 2003-10-27 Zoltan Varga <vargaz@freemail.hu>
2156 * loader.c (mono_get_method_from_token): Avoid looking up the icalls
2159 * marshal.c (mono_marshal_get_native_wrapper): Lookup icalls here.
2161 * reflection.c (reflection_methodbuilder_to_mono_method): Avoid looking
2162 up icalls at method definition time. Partially fixes #33569.
2164 2003-10-25 Zoltan Varga <vargaz@freemail.hu>
2166 * marshal.c (mono_marshal_get_native_wrapper): Add support for [Out]
2167 marshalling of arrays. Fixes #50116.
2169 * appdomain.c (ves_icall_System_AppDomain_InternalIsFinalizingForUnload): New icall.
2171 * appdomain.c (unload_thread_main): Clear class->cached_vtable if it
2172 points to a vtable in the dying appdomain.
2174 * appdomain.c (mono_domain_unload): Move the notification of OnUnload
2175 listeners into unmanaged code inside the lock.
2177 * object.c (mono_class_vtable): Turn off typed allocation in non-root
2178 domains and add some comments.
2180 2003-10-25 Martin Baulig <martin@ximian.com>
2182 * class.h (MonoGenericInst): Added `MonoClass *klass' field.
2184 * image.h (MonoImage): Added `GHashTable *typespec_cache'.
2186 * metadata.c (mono_metadata_parse_generic_inst): Renamed to
2187 `do_mono_metadata_parse_generic_inst'; pass it the MonoType we're
2188 currently parsing. Create the generic class and store it in
2189 `generic_inst->klass' before parsing the type arguments. This is
2190 required to support "recursive" definitions; see mcs/tests/gen-23.cs
2192 (mono_type_create_from_typespec): Use a new `image->typespec_cache'
2193 to support recursive typespec entries.
2195 * class.c (mono_class_setup_parent): If our parent is a generic
2196 instance, we may get called before it has its name set.
2197 (mono_class_from_generic): Splitted into
2198 mono_class_create_from_generic() and mono_class_initialize_generic().
2200 2003-10-25 Martin Baulig <martin@ximian.com>
2202 * icall.c (ves_icall_Type_BindGenericParameters): Return a
2203 `MonoReflectionGenericInst *' instead of a `MonoReflectionType *'.
2204 ("System.Reflection.MonoGenericInst::inflate_method"): New interncall.
2205 ("System.Reflection.MonoGenericInst::inflate_ctor"): New interncall.
2207 * reflection.c (my_mono_class_from_mono_type): Added MONO_TYPE_GENERICINST.
2208 (create_typespec): Likewise.
2209 (mono_reflection_bind_generic_parameters): Return a
2210 `MonoReflectionGenericInst *' instead of a `MonoClass *'.
2211 (mono_reflection_inflate_method_or_ctor): New public function.
2213 * reflection.h (MonoReflectionGenericInst): New typedef.
2215 2003-10-24 Zoltan Varga <vargaz@freemail.hu>
2217 * object.c (mono_class_proxy_vtable): Run the whole vtable construction
2218 inside the domain lock. Fixes #49993.
2220 * object.c (mono_class_vtable): When typed allocation is used,
2221 allocate vtables in the GC heap instead of in the mempool, since the
2222 vtables contain GC descriptors which are used by the collector even
2223 after the domain owning the mempool is unloaded.
2225 * domain.c (mono_domain_set): Rename to mono_domain_set_internal.
2227 * domain.c (mono_domain_unload): Rename to mono_domain_free to better
2228 reflect what it does. Also invalidate mempools instead of freeing
2229 them if a define is set.
2231 * appdomain.h (MonoAppDomainState): New enumeration to hold the state
2234 * appdomain.h (_MonoDomain): New field 'finalizable_object_hash' to
2235 hold the finalizable objects in this domain.
2237 * appdomain.h (_MonoDomain): New field 'state' to hold the state of the
2240 * appdomain.c (mono_domain_set): New function to set the current
2241 appdomain, but only if it is not being unloaded.
2243 * appdomain.c threads.c threadpool.c object.c: Avoid entering an
2244 appdomain which is being unloaded.
2246 * appdomain.c (ves_icall_System_AppDomain_InternalUnload): Prevent
2247 unloading of the root appdomain.
2249 * appdomain.c (ves_icall_System_AppDomain_InternalInvokeInDomain): New
2250 icall to execute a method in another appdomain. Intended as a
2251 replacement for InternalSetDomain, which can confuse the code
2252 generation in the JIT.
2254 * appdomain.c (mono_domain_is_unloading): New function to determine
2255 whenever an appdomain is unloading.
2257 * appdomain.c (mono_domain_unload): New function to correctly unload
2260 * assembly.c (mono_assembly_load_references): Check that an assembly
2261 does not references itself.
2263 * gc.c (mono_domain_finalize): Rewrote so instead of finalizing a
2264 domain manually, it asks the finalizer thread to do it, then waits for
2265 the result. Also added a timeout.
2267 * icall.c: Register the new icalls.
2269 * threads.h threads.c: Export the mono_gc_stop_world and
2270 mono_gc_start_world functions.
2272 * mempool.h mempool.c (mono_mempool_invalidate): New debugging
2273 function to fill out the mempool with 0x2a.
2275 2003-10-22 Zoltan Varga <vargaz@freemail.hu>
2277 * reflection.h (MonoReflectionMethodAux): New structure to store
2278 information which is rarely used, thus is not in the MonoMethod
2281 * reflection.h (MonoDynamicAssembly): New field 'method_
2282 culture, hash_alg and public_key. Fixes #49555.
2284 2003-10-17 Martin Baulig <martin@ximian.com>
2286 * class.h (MonoGenericInst): Moved this declaration here and added
2287 `MonoMethod *generic_method'.
2290 (ves_icall_MethodInfo_GetGenericArguments): New interncall.
2291 (ves_icall_MethodInfo_BindGenericParameters): New interncall.
2293 * metadata.c (mono_metadata_type_equal): Two types of
2294 MONO_TYPE_VAR or MONO_TYPE_MVAR equals if they have the same
2295 index; ie. don't compare the address of the `MonoGenericParam'
2297 (mono_metadata_load_generic_params): Removed the `MonoMethod
2300 * metadata.h (MonoGenericInst): Moved declaration to class.h.
2301 (MonoMethodHeader): Added `MonoGenericInst *geninst'.
2303 * reflection.c (method_encode_signature): Encode the number of
2305 (encode_generic_method_sig): New static function.
2306 (method_encode_methodspec): New static function; creates an entry
2307 in the MethodSpec table for a generic method.
2308 (mono_image_get_methodspec_token): New static function.
2309 (mono_image_create_token): Call mono_image_get_methodspec_token()
2310 for generic methods.
2311 (mono_reflection_bind_generic_method_parameters): New public
2312 function. Instantiates a generic method.
2314 2003-10-16 Martin Baulig <martin@ximian.com>
2316 * metadata.h (MonoMethodSignature): Moved `MonoGenericParam
2317 *gen_params' here from MonoMethodHeader.
2319 * metadata.c (mono_metadata_parse_method_signature): If we have
2320 generic parameters, initialize `method->gen_params' and then set
2321 the correct `type->data.generic_param' in all the parameters.
2323 2003-10-16 Zoltan Varga <vargaz@freemail.hu>
2325 * threads.c (mono_threads_get_default_stacksize): New function to
2326 return the default stacksize.
2328 * gc.c (mono_gc_cleanup): Use a separate event for waiting for the
2329 termination of the finalizer thread, since the previous method had
2330 race conditions. Fixes #49628.
2332 * gc.c (mono_gc_init): Use the same stacksize for the finalizer thread
2333 as for the other managed threads.
2335 2003-10-16 Martin Baulig <martin@ximian.com>
2337 * class.c (inflate_generic_signature): Copy `generic_param_count'
2340 * icall.c (ves_icall_MethodInfo_get_IsGenericMethodDefinition):
2343 * metadata.c (mono_metadata_parse_method_signature): Actually set
2344 the `method->generic_param_count' here.
2345 (mono_metadata_load_generic_params): Initialize `pklass' to NULL.
2347 2003-10-15 Zoltan Varga <vargaz@freemail.hu>
2349 * object.h: Add a new field to TypedRef to simplify the implementation
2350 of the REFANY opcodes in the JIT.
2352 * icall.c: Make use of the new field.
2354 * metadata.c (mono_type_size): Compute the size of TYPEDBYREF types
2357 2003-10-15 Martin Baulig <martin@ximian.com>
2359 * class.c (mono_class_from_gen_param): Renamed to
2360 mono_class_from_generic_parameter() and moved most of the
2361 functionality from mono_reflection_define_generic_parameter()
2362 here; ie. we create a "real" class here.
2363 (mono_class_from_mono_type): Only allow MONO_TYPE_VAR and
2364 MONO_TYPE_MVAR if mono_class_from_generic_parameter() has
2365 previously been called.
2367 * class.h (MonoGenericParam): Moved the declaration of this struct
2368 here from metadata.h and added `MonoMethod *method'.
2370 * icall.c (ves_icall_MonoType_get_DeclaringMethod): New
2373 * loader.c (mono_get_method_from_token): If we have any generic
2374 parameters, call mono_metadata_load_generic_params() to read them
2375 from the MONO_TABLE_GENERICPAR.
2377 * metadata.c (mono_metadata_load_generic_params): Added
2378 `MonoMethod *method' argument which is used MONO_TYPE_MVAR.
2380 * metadata.h (MonoMethodSignature): Replaced
2381 `MonoGenericInst *geninst' with `guint16 generic_param_count'.
2382 (MonoMethodHeader): Added `MonoGenericParam *gen_params'.
2384 * reflection.c (mono_reflection_define_generic_parameter): Moved
2385 most of the functionality into the new
2386 mono_class_from_generic_parameter(); set the `method' field if
2387 we're a method parameter.
2389 2003-10-13 Bernie Solomon <bernard@ugsolutions.com>
2391 * marshal.c (emit_struct_conv): if native size is 0
2394 2003-10-14 Martin Baulig <martin@ximia
2396 * object.c (mono_object_isinst): Synchronize this with the code
2397 generated by the JIT for casts.
2399 2003-09-29 Zoltan Varga <vargaz@freemail.hu>
2401 * reflection.c (encode_type): Fix #38332.
2403 2003-09-26 Zoltan Varga <vargaz@freemail.hu>
2405 * marshal.c (mono_marshal_method_from_wrapper): New function to return
2406 the original method from the wrapper method.
2408 2003-09-25 Martin Baulig <martin@ximian.com>
2410 * icall.c (ves_icall_Type_IsGenericTypeDefinition): Removed this
2411 interncall since it was identical to `Type.GetGenericTypeDefinition()'.
2412 (ves_icall_Type_get_IsGenericInstance): New interncall.
2414 2003-09-24 Bernie Solomon <bernard@ugsolutions.com>
2416 * object.c: fix cast warning in big endian code.
2418 2003-09-19 Jackson Harper <jackson@latitudegeo.com>
2420 * icall.c: Timezone patch from Zoltan Varga (vargaz@freemail.hu)
2422 2003-09-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2424 * assembly.c: don't call check_env from mono_assembly_load. It's
2425 already done once in mono_assemblies_init and may cause headaches when
2426 multiple threads are loading assemblies.
2428 2003-09-19 Martin Baulig <martin@ximian.com>
2430 * reflection.c (mono_reflection_define_generic_parameter): Don't
2431 allocate `klass->methods', set `klass->flags' to
2432 TYPE_ATTRIBUTE_INTERFACE, not TYPE_ATTRIBUTE_ABSTRACT.
2434 2003-09-18 Martin Baulig <martin@ximian.com>
2436 * class.c (mono_class_init): Don't create `class->methods' if it's
2437 already initialized.
2439 * metadata.c (mono_metadata_load_generic_params): Make this
2442 * reflection.c (mono_reflection_define_generic_parameter): Set
2443 parent class and interfaces from the constraints.
2445 * reflection.h (MonoReflectionGenericParam): Added `guint32 flags'
2446 to keep this struct in sync with the declaration in TypeBuilder.cs.
2448 2003-09-17 Martin Baulig <martin@ximian.com>
2450 * metadata.h (MonoType): Replaced the data's `int type_param'
2451 field with `MonoGenericParam *generic_param'.
2452 (MonoGenericParam): Added `MonoClass *klass'.
2454 * class.c (mono_class_from_gen_param): Removed the
2455 `MonoImage *image' and `int type_num' arguments.
2457 * metadata.c (mono_metadata_parse_generic_param): New static
2458 method; creates a MonoGenericParam which just contains the index.
2459 (do_mono_metadata_parse_type): Call
2460 mono_metadata_parse_generic_param() for MONO_TYPE_VAR and
2463 * reflection.c (mono_image_typedef_or_ref): Generic type
2464 parameters may be in the same assembly, but never use a typedef
2466 (mono_reflection_define_generic_parameter): We're now creating a
2467 "real" class for the type parameter; it's now safe to call
2468 mono_class_from_mono_type() on the class'es type, it'll do the
2471 2003-09-16 Martin Baulig <martin@ximian.com>
2473 * mono-debug-debugger.c (allocate_symbol_file_entry): Initialize
2474 `symfile->range_entry_size' and `symfile->class_entry_size' here;
2475 the `symfile' data structure must be fully initialized before it
2476 gets added to the table.
2478 2003-09-15 Zoltan Varga <vargaz@freemail.hu>
2480 * icall.c (ves_icall_Type_IsArrayImpl): Added MONO_ARCH_SAVE_REGS.
2482 * appdomain.h domain.c (MonoDomain): Added new hashtable to store the
2483 class init trampolines.
2485 2003-09-11 Zoltan Varga <vargaz@freemail.hu>
2487 * profiler.c (mono_profiler_load): Added '-time' and '-alloc' options
2488 to the built-in profiler to turn off time and allocation profiling
2491 2003-09-10 Zoltan Varga <vargaz@freemail.hu>
2493 * profiler.c (mono_profiler_coverage_alloc): Use NULL instead of
2496 * debug-helpers.c (mono_method_full_name): Print the wrapper type
2497 in human readable form.
2499 2003-09-08 Zoltan Varga <vargaz@freemail.hu>
2501 * reflection.c icall.c: Fixed warnings.
2503 * image.c (load_class_names): Use a temporary hash table to hold the
2504 namespaces in order to avoid doing many string comparisons.
2506 * image.h: Fix typo.
2508 * image.c class.c rawbuffer.c reflection.c threads.c verify.c domain.c:
2509 Pass NULL instead of g_direct_equal to the GHashTable constructor
2510 since the NULL case is short-circuited inside g_hash_table_lookup,
2511 leading to better performance.
2513 * metadata.c (mono_metadata_custom_attrs_from_index): New function to
2514 obtain the first custom attribute for a given index. Depends on the
2515 CustomAttribute table being sorted by the parent field.
2517 * reflection.c (mono_custom_attrs_from_index): Use the new function
2518 for better performance.
2520 2003-09-07 Martin Baulig <martin@ximian.com>
2522 * class.c (mono_class_init): If we're a generic instance, inflate
2523 all our methods instead of loading them from the image.
2524 (mono_class_from_generic): Set `class->methods = gklass->methods'.
2526 2003-09-07 Martin Baulig <martin@ximian.com>
2528 * mono-debug-debugger.c: Added support for constructors.
2530 2003-09-06 Martin Baulig <martin@ximian.com>
2532 * icall.c (ves_icall_TypeBuilder_get_IsUnboundGenericParameter):
2535 * reflection.c (mono_reflection_setup_generic_class): Call
2536 ensure_runtime_vtable() to create the vtable.
2538 2003-09-05 Martin Baulig <martin@ximian.com>
2540 * class.c (mono_class_array_element_size): Added MONO_TYPE_VAR and
2543 2003-09-04 Martin Baulig <martin@ximian.com>
2545 * reflection.c (mono_reflection_define_generic_parameter): Generic
2546 parameters start with zero.
2548 2003-09-04 Martin Baulig <martin@ximian.com>
2550 * metadata.c (mono_type_size): Added MONO_TYPE_VAR and MONO_TYPE_MVAR.
2552 * reflection.h (MonoReflectionGenericParam): New typedef.
2553 (MonoReflectionTypeBuilder): Added `generic_params' fields to get
2554 the generic parameters from the managed TypeBuilder.
2556 * reflection.c (mono_reflection_define_generic_parameter): New function.
2557 (mono_reflection_create_runtime_class): Encode generic parameters.
2558 (mono_reflection_setup_generic_class): New function; this is
2559 called after adding adding all generic params to the TypeBuilder.
2560 (encode_type): Added MONO_TYPE_VAR.
2562 2003-09-04 Zoltan Varga <vargaz@freemail.hu>
2564 * class.h class.c (mono_class_needs_cctor_run): Moved this method
2567 * assembly.h assembly.c: Moved the AOT loading code into an assembly
2570 2003-09-03 Zoltan Varga <vargaz@freemail.hu>
2572 * reflection.h reflection.c class.h class.c: Delete duplicate
2573 definition of mono_type_get_name () from reflection.c and export the
2576 * class.c: Class loading fixes from Bernie Solomon
2577 (bernard@ugsolutions.com).
2579 * reflection.c: Endianness fixes from Bernie Solomon
2580 (bernard@ugsolutions.com).
2582 2003-09-01 Zoltan Varga <vargaz@freemail.hu>
2584 * assembly.h assembly.c: Define a file format version for AOT
2587 * assembly.c (mono_assembly_open): Fix leaking of MonoImage-s.
2589 * appdomain.h (MonoJitInfo): New field to determine whenever the
2590 code is domain neutral.
2592 2003-08-31 Miguel de Icaza <miguel@ximian.com>
2594 * marshal.c (emit_struct_conv): Add MONO_TYPE_CHAR
2596 2003-08-30 Zoltan Varga <vargaz@freemail.hu>
2598 * icall.c (ves_icall_System_Web_Util_ICalls_get_machine_install_dir):
2599 (ves_icall_System_Configuration_DefaultConfig_get_machine_config_path):
2600 Avoid caching the result since strings must be domain specific. Fixes
2603 2003-08-29 Zoltan Varga <vargaz@freemail.hu>
2605 * marshal.c (mono_marshal_init): Make this callable multiple times
2606 since it is hard to find a correct place to call it.
2608 * object.c (mono_runtime_class_init): Execute static constructors in
2609 the correct appdomain.
2611 * image.c (build_guid_table): Handle the case when multiple images have
2614 2003-08-29 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2616 * icall.c: added a couple of icalls for System.Web.
2618 2003-08-28 Martin Baulig <martin@ximian.com>
2620 * icall.c (ves_icall_Type_BindGenericParameters): Use
2621 `klass->generic_inst' instead of `&klass->byval_arg' in the
2622 mono_type_get_object() call. The returned type must be
2623 MONO_TYPE_GENERICINST and not MONO_TYPE_CLASS.
2625 2003-08-27 Zoltan Varga <vargaz@freemail.hu>
2629 * object.c (mono_class_proxy_vtable): Make it thread safe.
2631 * pedump.c: Fix warning.
2633 * object.c appdomain.h: Get rid of metadata_section.
2634 It is no longer needed and it was causing deadlocks with domain->lock.
2636 * appdomain.c (add_assemblies_to_domain): Make it thread safe.
2638 2003-08-26 Martin Baulig <martin@ximian.com>
2640 * pedump.c (main): Don't call mono_image_close() if `verify_pe'.
2642 2003-08-26 Martin Baulig <martin@ximian.com>
2644 * pedump.c (main): Call mono_metadata_init(),
2645 mono_raw_buffer_init(), mono_images_init(), mono_assemblies_init()
2646 and mono_loader_init().
2648 2003-08-26 Zoltan Varga <vargaz@freemail.hu>
2650 * loader.h: Add missing include to fix build.
2652 * image.h: mono_image_load_references is no more.
2654 * assembly.c: Reworked assembly loading to make it really thread safe.
2655 After these changes, the assembly returned by mono_assembly_open is
2656 fully initialized, i.e. all its references assemblies are loaded.
2658 * assembly.c (mono_image_load_references): Renamed to
2659 mono_assembly_load_references, and made private, since clients no
2660 longer need to call it.
2662 * class.c: Removed calls to mono_assembly_load_references, since it was
2663 a source of deadlocks.
2665 * loader.h loader.c class.h class.c: Protect data structures using a
2666 new lock, the loader lock.
2668 * class.c (mono_class_setup_vtable): Create temporary hash tables and
2669 GPtrArrays only when needed.
2671 * class.c (mono_class_layout_fields): Ignore the dummy field inserted
2672 into empty structures by mcs. Fixes pinvoke7.cs.
2674 * domain.c (mono_init): Call a new initialization function.
2676 * appdomain.c (mono_runtime_init): Call the new initializer function
2677 of the marshal module.
2679 * marshal.c (mono_marshal_load_type_info): Ignore the dummy field
2680 inserted into empty structures by mcs. Fixes pinvoke7.cs.
2682 * marshal.h marshal.c: Added locks around the wrapper caches to make
2683 this module thread safe.
2685 * icall.c (ves_icall_InternalInvoke): Method wrappers doesn't require a
2686 this argument. Fixes pinvoke1.exe.
2688 2003-08-25 Lluis Sanchez <lluis@ximian.com>
2690 * object.h: Added call_type field to MonoMethodMessage and the corresponding
2691 enumeration of values. Removed fields to store remote call output values in
2692 MonoAsyncResult. Not needed any more.
2693 * object.c: Initialize call_type and async_result fields in mono_message_init.
2694 * marshal.c: mono_delegate_begin_invoke(): for proxies, set call_type before
2695 dispatching the message.
2696 mono_delegate_end_invoke (): delegate to the proxy the work of waiting for the
2697 async call to finish. To do it use a message with EndInvoke call type.
2699 2003-08-25 Zoltan Varga <vargaz@freemail.hu>
2701 * loader.h loader.c (mono_method_hash_marhal_info): New function which
2702 determines whenever a method has marshalling info.
2704 2003-08-23 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2706 * assembly.c: fix the build on windows.
2708 2003-08-22 Lluis Sanchez <lluis@ximian.com>
2710 * object.cs: Fixed bug #47785.
2712 2003-08-22 Jackson Harper <jackson@latitudegeo.com>
2714 * string-icalls.c (StringReplace): If their are no occurances of
2715 the old string found return a reference to the supplied
2716 string. This saves some memory and matches MS behavoir.
2718 2003-08-22 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2720 * socket-io.c: fixed compilation for systems that define AF_INET6
2721 and don't define SOL_IP/SOL_IPV6.
2723 2003-08-21 Zoltan Varga <vargaz@freemail.hu>
2725 * object.c (mono_object_isinst): Fix casts to TransparentProxy in
2726 the interpreter. Patch by Bernie Solomon (bernard@ugsolutions.com).
2728 * rawbuffer.c rawbuffer.h: Make this module thread safe.
2730 * domain.c: Make this module thread safe.
2732 * domain.c (mono_init): Call new initialization function.
2734 * icall.c (ves_icall_System_Array_SetValueImpl): Check types for
2735 reference types too. Fixes #38812.
2737 * image.c (mono_image_init): Fixed warnings.
2739 * class.c (mono_class_from_typeref): Handle assembly load failure
2742 * appdomain.c (add_assemblies_to_domain): Handle the case when
2743 the references of an assembly are not yet loaded.
2745 * metadata.c image.c assembly.c: Moved initialization of global
2746 variables to a separate function called at startup since lazy
2747 initialization of these variables is not thread safe.
2749 * image.c assembly.c: Made this module thread safe by adding locks in
2750 the appropriate places.
2752 * domain.c (mono_init): Call the new initialization functions of the
2755 2003-08-20 Lluis Sanchez Gual <lluis@ximian.com>
2757 * marshal.c: mono_delegate_begin_invoke(): If the target is a proxy,
2758 make a direct call. It is proxy's work to make the call asynchronous.
2759 mono_delegate_end_invoke(): If the targe is a proxy, just collect
2761 * object.cs: mono_method_call_message_new(): read AsyncResult and
2762 state object from parameters list, if this info is requested.
2763 * object.h: Added fields to store remote call output values in
2764 MonoAsyncResult. Added AsyncResult field in MonoMethodMessage.
2766 Wed Aug 20 12:57:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
2768 * object.h: add needed fields to MonoThread.
2769 * threads.c, threads.h: allow registering a function to cleanup data
2770 allocated per thread by the JIT.
2772 Tue Aug 19 18:22:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
2774 * loader.h: portability fix by Bernie Solomon
2775 * <bernard@ugsolutions.com>.
2777 2003-08-16 Zoltan Varga <vargaz@freemail.hu>
2779 * reflection.h reflection.c (mono_param_get_objects): Changed this to
2780 return a MonoArray. This simplifies the code and also ensures that
2781 the cache allways contains an object reference as a value.
2783 * icall.c (ves_icall_get_parameter_info): Simplified using the new
2786 2003-08-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2788 * socket-io.c: patch by Bernie Solomon <bernard@ugsolutions.com> that
2789 fixes a problem with byte ordering when getting the address family for
2792 2003-08-15 Zoltan Varga <vargaz@freemail.hu>
2794 * .cvsignore: Added monosn.
2796 * reflection.h reflection.c loader.c: Added support for parameter
2797 marshalling to dynamically created types. Fixes #47295.
2799 Fri Aug 15 11:42:46 CEST 2003 Paolo Molaro <lupus@ximian.com>
2801 * rand.c: remove useless warnings.
2803 Wed Aug 13 15:49:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
2805 * class.c: implemented ldtoken for methods and fieldrefs.
2807 2003-08-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2809 * threadpool.c: when mono_async_invoke was called, no one took care of
2810 monitoring the queue. So if the method invoked took some time and we
2811 got new async invoke requests after 500 ms (the thread created waited
2812 that long in WaitForSingleObject), the new async invoke was not called
2813 until the previous one finished.
2815 This is fixed now. Thanks to Totte for helping with it.
2817 2003-08-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2819 * threadpool.c: set threadpool_thread to TRUE. Patch by totte.
2821 2003-08-11 Martin Baulig <martin@ximian.com>
2823 * mono-debug-debugger.c (mono_debugger_lookup_type): New function.
2825 2003-08-06 Martin Baulig <martin@ximian.com>
2827 * mono-debug-debugger.c: Added support for static fields,
2828 properties and methods.
2830 2003-08-06 Martin Baulig <martin@ximian.com>
2832 * mono-debug-debugger.c: Don't store the MonoString's vtable to
2833 make this work for applications with multiple application domains.
2835 2003-08-04 Martin Baulig <martin@ximian.com>
2837 * mono-debug-debugger.c: Completely reworked the type support; the
2838 most important thing is that we're now just using one single
2839 `MonoType' instance per type.
2841 Sat Aug 2 13:05:27 BST 2003 Malte Hildingson <malte@amy.udd.htu.se>
2843 * mono-endian.h, mono-endian.c, icall.c: Added icall
2844 ves_icall_System_Double_AssertEndianity to assert double word endianity
2845 on ARM (FPA). The icall uses a macro defined in mono-endian.h.
2847 Fri Aug 1 16:51:13 CEST 2003 Paolo Molaro <lupus@ximian.com>
2849 * class.c, class.h, reflection.c, metadata.c, icall.c: more generics
2850 support, icalls and fixes.
2852 2003-07-31 Miguel de Icaza <miguel@ximian.com>
2854 * unicode.c (ves_icall_System_Char_IsPunctuation): The set of
2855 classes that are a punctuation character in .NET is not the same a
2858 Tue Jul 29 18:07:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
2860 * socket-io.c: ipv6 portability fixes from Felix Ortga (guile@lared.es).
2862 2003-07-29 Miguel de Icaza <miguel@ximian.com>
2864 * icall.c: Add new MemCopy internalcall.
2865 (ves_icall_System_Reflection_Assembly_GetManifestResourceInternal):
2866 Simplified code; It is not necessary to handle all the cases here,
2867 as the C# code takes care of it.
2868 ALLOC_ATOMIC (GC_realloc uses plain GC_malloc otherwise).
2870 Sat Jun 14 13:13:20 CEST 2003 Paolo Molaro <lupus@ximian.com>
2872 * icall.c: fixed GetElementType for byrefs (bug# 44792).
2874 2003-06-13 Zoltan Varga <vargaz@freemail.hu>
2876 * reflection.c (mono_reflection_create_runtime_class): Add support for
2877 properties to dynamically created classes.
2878 * reflection.c: Fix a few places where non-MonoObjects were inserted
2879 into the tokens hashtable.
2881 Fri Jun 13 19:10:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
2883 * object.c: some support to handle out of memory exceptions.
2885 2003-06-12 Dietmar Maurer <dietmar@ximian.com>
2887 * marshal.c (mono_marshal_get_native_wrapper): support reference
2890 Wed Jun 11 18:32:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
2892 * object.h, object.c: more portability stuff from Bernie Solomon.
2893 Unexport mono_object_allocate(). Added mono_object_unbox ().
2894 Set exitcode when an unhandled exception is thrown.
2896 2003-06-11 Dietmar Maurer <dietmar@ximian.com>
2898 * marshal.c (mono_marshal_get_native_wrapper): use custom
2899 marshaler for return types.
2901 2003-06-10 Dick Porter <dick@ximian.com>
2903 * socket-io.c: Don't assume that one of struct ip_mreqn or struct
2904 ip_mreq is available
2906 Tue Jun 10 17:35:03 CEST 2003 Paolo Molaro <lupus@ximian.com>
2908 * debug-mono-symfile.c, marshal.c, metadata.c, monitor.c,
2909 mono-debug-debugger.c, mono-debug.c, process.c: portability fixes
2910 by Bernie Solomon <bernard@ugsolutions.com>.
2912 2003-06-10 Zoltan Varga <vargaz@freemail.hu>
2914 * gc.c (mono_gc_init): Avoid error message on shutdown when
2915 GC_DONT_GC=1 is used.
2917 * icall.c (ves_icall_System_Reflection_Module_GetGuidInternal):
2918 New icall to return the GUID of a module.
2920 Mon Jun 9 19:33:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
2922 * class.c: ensure instance size always includes the parent's size
2923 even whem class size is set explicitly (fixes bug#44294).
2925 Thu Jun 5 19:51:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
2927 * profiler.h, profiler.c: made the simple profiler thread-safe,
2928 get more accurate timing info. Allow the loading of an
2929 externally-developed profiler module.
2931 2003-06-05 Dietmar Maurer <dietmar@ximian.com>
2933 * marshal.c (mono_marshal_get_native_wrapper): improved
2934 class/byref arguments.
2935 (mono_marshal_get_native_wrapper): better string marshaling support.
2937 Wed Jun 4 18:01:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
2939 * class.c: ensure .pack and .size are handled correctly and
2940 simplified layout of static fields.
2942 2003-06-04 Dietmar Maurer <dietmar@ximian.com>
2945 (ves_icall_System_AppDomainSetup_InitAppDomainSetup): fix for bug 42934
2947 * loader.c (mono_lookup_pinvoke_call): look for modules in the
2948 current directory (fix bug 44008)
2950 2003-06-03 Dietmar Maurer <dietmar@ximian.com>
2952 * marshal.c (mono_marshal_get_native_wrapper): started support for
2954 (mono_delegate_to_ftnptr): consider marshalling specifications
2956 Tue Jun 3 11:17:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
2958 * reflection.c, reflection.h: emit custom marshal info.
2960 2003-06-02 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2962 * object.c: free the GError.
2963 * icall.c: added CloseEvent_internal.
2965 (ves_icall_System_Threading_Events_CloseEvent_internal): new internal
2968 2003-06-01 Zoltan Varga <vargaz@freemail.hu>
2970 * loader.c (mono_method_get_signature): Add support for dynamic
2973 Sat May 31 15:22:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
2975 * reflection.c: fixed bug #43905.
2977 Fri May 30 12:56:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
2979 * class.c, domain.c, icall.c, metadata.h, object.h: support for
2980 handling TypedReference and ArgIterator.
2981 * loader.c, loader.h: added function to get signature at call site.
2983 Thu May 29 11:34:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
2985 * metadata.c, metadata.h, private.h, tokentype.h, loader.c: make more
2986 data readonly. Buglets and warning fixes. Some MethodSpec support.
2988 Tue May 27 16:34:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
2990 * class.h, class.c, object.c: remove relative numbering support.
2992 2003-05-26 Miguel de Icaza <miguel@ximian.com>
2994 * marshal.c (mono_marshal_get_native_wrapper): For now, do not
2995 free the string, until we get a chance to fix Gtk#
2997 2003-05-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
2999 * marshal.c: revert last patch.
3001 Mon May 26 20:21:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
3003 * icall.c: updates for new mono_class_vtable() not calling
3004 the type constructor anymore.
3006 Mon May 26 12:10:35 CEST 2003 Paolo Molaro <lupus@ximian.com>
3008 * object.h, object.c: separate vtable creation from type
3009 initialization. Make running the .cctor thread safe.
3011 2003-05-26 Dietmar Maurer <dietmar@ximian.com>
3013 * marshal.c (mono_marshal_get_native_wrapper): free string return values.
3015 2003-05-21 Dietmar Maurer <dietmar@ximian.com>
3017 * loader.c (mono_get_method): consider calling convention
3019 2003-05-21 Zoltan Varga <vargaz@freemail.hu>
3021 * icall.c (ves_icall_System_Reflection_Module_GetGlobalType): New icall
3022 to return the invisible global type for a module.
3024 * reflection.c (mono_image_build_metadata): Emit global fields too.
3026 2003-05-20 Peter Williams <peterw@ximian.com>
3028 * loader.c (mono_lookup_internal_call): Add a few newlines.
3030 2003-05-20 Zoltan Varga <vargaz@freemail.hu>
3032 * reflection.c (mono_reflection_lookup_dynamic_token): Intern dynamic
3035 * appdomain.c (set_domain_search_path): Recalculate search path when
3036 AppDomainSetup.PrivateBinPath changes.
3038 * object.c (mono_class_compute_gc_descriptor): It turns out some
3039 parts of the class libs (like System.Thread) holds pointers to
3040 GC_MALLOC()-d memory in IntPtrs, which is wrong. The workaround is
3041 to treat native int a pointer type here.
3043 Tue May 20 17:18:16 CEST 2003 Paolo Molaro <lupus@ximian.com>
3045 * appdomain.h, domain.c: add hashtable for jump target resolution.
3047 2003-05-19 Zoltan Varga <vargaz@freemail.hu>
3049 * reflection.h reflection.c icall.c: Added new icalls
3050 GetManifestResourceInfoInternal, GetModulesInternal and support
3053 2003-05-16 Dick Porter <dick@ximian.com>
3057 * file-io.c: Implement System.IO.MonoIO::GetTempPath
3059 2003-05-14 Lluis Sanchez Gual <lluis@ideary.com>
3061 * object.c: mono_store_remote_field: little fix to previous patch.
3063 Wed May 14 18:10:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
3065 * class.c: add constructors to array classes.
3066 * icall.c: special case array construction for InternalInvoke (),
3068 2003-05-14 Zoltan Varga <vargaz@freemail.hu>
3070 * class.h class.c reflection.c object.c: Added support for field
3071 defaults in dynamically generated classes.
3073 Wed May 14 13:35:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
3075 * reflection.c: properly encode charset for ddlimport.
3077 Wed May 14 11:14:54 CEST 2003 Paolo Molaro <lupus@ximian.com>
3079 * threads.c: allow compiling without GC.
3081 Tue May 13 16:41:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
3083 * appdomain.h, object.c, object.h, threads.c, threads.h: added
3084 handling of thread static data.
3086 Tue May 13 16:36:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
3088 * reflection.h, reflection.c: added mono_custom_attrs_free ().
3090 2003-05-13 Dietmar Maurer <dietmar@ximian.com>
3092 * class.c (mono_array_class_get): always set the serializable flags
3093 (mono_array_class_get): always set the SEALED attribute for array types
3095 2003-05-12 Dietmar Maurer <dietmar@ximian.com>
3097 * loader.c (mono_lookup_pinvoke_call): consider Ansi/Unicode
3098 attributes (fix for bug 42021).
3100 2003-05-12 Dick Porter <dick@ximian.com>
3102 * gc.c: Don't run finalizers when the finalizer thread is
3103 finishing up, because the default domain has already been
3106 2003-05-11 Miguel de Icaza <miguel@ximian.com>
3108 * string-icalls.c (ves_icall_System_String_ctor_chara_int_int): if
3109 value is null, we should throw an exception. This is slightly
3110 different than the other conventions used for the constructor.
3112 2003-05-12 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3114 * socket-io.c: fixed windows build.
3116 2003-05-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3118 * socket-io.c: patch by Jerome Laban that fixes bug #42393.
3120 2003-05-10 Zoltan Varga <vargaz@freemail.hu>
3122 * object.c (mono_string_new_wrapper): Compatibility fix for MS
3125 2003-05-09 Zoltan Varga <vargaz@freemail.hu>
3127 * class.c (mono_class_layout_fields): Add experimental GC aware
3128 auto layout facility. Requires class library changes to work correctly.
3130 (mono_class_setup_vtable): Avoid overriding explicit interface
3131 method implementations. Fixes iface3.exe test.
3133 * object.c (mono_class_compute_gc_descriptor): Type I can't hold an
3135 (mono_array_new_specific): Add MONO_ARCH_SAVE_REGS.
3136 (mono_string_new_wrapper): Add MONO_ARCH_SAVE_REGS.
3138 * metadata.h: Add new type classification macro which determines
3139 whenever the type holds an object reference.
3141 2003-05-08 Dietmar Maurer <dietmar@ximian.com>
3143 * marshal.c (mono_marshal_get_native_wrapper): cleanups
3145 2003-05-07 Zoltan Varga <vargaz@freemail.hu>
3147 * gc.c (finalizer_thread): Work around a GC bug.
3149 2003-05-07 Dietmar Maurer <dietmar@ximian.com>
3151 * marshal.c (emit_struct_conv): allow unions
3153 * class.c (class_compute_field_layout): added patches from Jerome Laban <jlaban@wanadoo.fr>
3155 2003-05-06 Dietmar Maurer <dietmar@ximian.com>
3157 * marshal.c (mono_marshal_get_native_wrapper): free strings after pinvoke
3159 2003-05-06 Martin Baulig <martin@ximian.com>
3161 * mono-debug-debugger.h: #include <mono/io-layer/io-layer.h>.
3163 2003-05-05 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3166 (Select_internal): allow NULLs, don't create arrays if not needed.
3167 Coupled with Socket.cs changes.
3170 (mono_thread_pool_add): use GC_MALLOC to allocate the ASyncCall and
3171 register a finalizer for it that will close the semaphore handle. This
3172 fixes the leak and make Lupus' test run with > 4080 loops.
3174 2003-05-05 Dietmar Maurer <dietmar@ximian.com>
3176 * marshal.c (mono_marshal_get_struct_to_ptr): added fixes from
3177 Jerome Laban (bug #42287)
3179 2003-05-02 Martin Baulig <martin@ximian.com>
3181 * debug-mono-symfile.h
3182 (MonoSymbolFile): Moved declaration into mono-debug.h.
3183 (MonoDebugMethodJitInfo): Likewise.
3184 (mono_debug_open_mono_symbol_file): Take the MonoDebugHandle as
3186 (_mono_debug_address_from_il_offset): Take a
3187 MonoDebugMethodJitInfo instead of a MonoDebugMethodInfo.
3190 (MonoDebugDomainData): New struct.
3191 (mono_debug_get_domain_data): New function.
3192 (mono_debug_add_method): Take an additional `MonoDomain *'
3194 (mono_debug_source_location_from_address): Likewise.
3195 (mono_debug_il_offset_from_address): Likewise.
3196 (mono_debug_address_from_il_offset): Likewise.
3198 Thu May 1 19:40:37 CEST 2003 Paolo Molaro <lupus@ximian.com>
3200 * reflection.c: one more check for null type in custom attrs.
3202 2003-05-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3204 * reflection.c: avoid warning (comparison is always false due to limited
3205 range of data type).
3207 2003-05-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3209 * icall.c: throw an exception in Type.GetField if the argument 'name'
3212 Wed Apr 30 10:53:09 CEST 2003 Paolo Molaro <lupus@ximian.com>
3214 * reflection.c: fixed handling of enums in named arguments to custom
3215 attributes (bug #42123).
3217 Tue Apr 29 19:15:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
3219 * reflection.c: use the right array element type and handle
3220 a null for a Type argument, too.
3222 Tue Apr 29 15:46:00 CEST 2003 Paolo Molaro <lupus@ximian.com>
3224 * reflection.c: handle arrays as arguments to custom attributes.
3226 Tue Apr 29 11:43:01 CEST 2003 Paolo Molaro <lupus@ximian.com>
3228 * reflection.c: handle a string value in a custom attr
3229 ctor that takes an object.
3231 2003-04-29 Dietmar Maurer <dietmar@ximian.com>
3233 * marshal.c (mono_mb_emit_restore_result): support MONO_TYPE_PTR
3236 2003-04-28 Zoltan Varga <vargaz@freemail.hu>
3238 * icall.c (ves_icall_Type_GetNestedType): Fixed warnings.
3240 2003-04-27 Martin Baulig <martin@ximian.com>
3242 * mono-debug-debugger.h (MonoDebuggerEvent): Renamed
3243 MONO_DEBUGGER_EVENT_BREAKPOINT_TRAMPOLINE to
3244 MONO_DEBUGGER_EVENT_BREAKPOINT.
3245 (mono_breakpoint_trampoline_code): Removed.
3246 (mono_debugger_event_handler): The last argument is now a
3248 (mono_debugger_insert_breakpoint_full): Removed the
3249 `use_trampoline' argument.
3250 (mono_debugger_method_has_breakpoint): Likewise.
3251 (mono_debugger_trampoline_breakpoint_callback): Renamed to
3252 mono_debugger_breakpoint_callback(); take the method and
3253 breakpoint number as arguments.
3255 Sat Apr 26 19:25:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
3257 * metadata.c: fix off by one when loading parameters attributes.
3259 2003-04-24 Martin Baulig <martin@ximian.com>
3261 * mono-debug-debugger.c (mono_debugger_io_layer): Put this back.
3263 2003-04-24 Martin Baulig <martin@ximian.com>
3265 * mono-debug-debugger.c: Moved all code which interacts with the
3268 * debug-mono-symfile.c: This code now just deals with the symbol
3269 file itself, the debugger code is now in mono-debug-debugger.c.
3271 2003-04-23 Martin Baulig <martin@ximian.com>
3273 * mono-debug.c (mono_debug_source_location_from_il_offset):
3274 New method; like mono_debug_source_location_from_address(), but
3275 takes an IL offset instead of a machine address.
3277 2003-04-23 Martin Baulig <martin@ximian.com>
3279 * debug-mono-symfile.h (MonoDebugLineNumberEntry): Removed the
3280 `line' field; this is now computed by the debugger.
3282 2003-04-23 Martin Baulig <martin@ximian.com>
3284 * mono-debug.[ch]: New files. This is the new debugging interface.
3286 * mono-debug-debugger.[ch]: New files. Moved all code which
3287 interacts with the Mono Debugger here.
3289 2003-04-22 Dietmar Maurer <dietmar@ximian.com>
3291 * domain.c (mono_init): initialize mono_defaults.monitor_class
3293 2003-04-21 Miguel de Icaza <miguel@ximian.com>
3295 * reflection.c (method_encode_code): Add a spicy exception to help
3296 future compiler authors.
3298 2003-04-21 Martin Baulig <martin@ximian.com>
3301 (ves_icall_System_Reflection_Assembly_GetReferencedAssemblies):
3302 Make this work with relative pathnames; g_filename_to_uri() needs
3303 an absolute filename.
3305 2003-04-18 Zoltan Varga <vargaz@freemail.hu>
3307 * icall.c: Track name changes in Object and ValueType.
3309 2003-04-18 Dietmar Maurer <dietmar@ximian.com>
3311 * metadata.c (mono_type_stack_size): size should be a multiple of
3314 2003-04-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3317 (internal_domain_finalize): moved into mono_domain_finalize. No need
3318 to create another thread because the finalizers will be run in the
3321 (ves_icall_System_GC_WaitForPendingFinalizers): implemented.
3322 (finalizer_notify): if shutting down, wait 2 seconds for the finalizers
3323 to be run (MS does this too).
3325 2003-04-17 Zoltan Varga <vargaz@freemail.hu>
3327 * object.c (mono_class_compute_gc_descriptor): Update comment.
3329 * loader.h marshal.h marshal.c: Added synchronized method wrappers.
3331 * image.h: Add synchronized wrapper cache.
3333 * image.c (do_mono_image_open): Initialize cache.
3335 * reflection.c (create_dynamic_mono_image): Initialize cache.
3337 2003-04-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3339 * icall.c: patch by Jerome Laban <jlaban@wanadoo.fr> that fixes
3340 ves_icall_System_Buffer_ByteLengthInternal.
3342 Tue Apr 15 13:56:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
3344 * reflection.c: setup klass->nested_in earlier. Allow
3345 a dash in the assembly name.
3347 2003-04-15 Dietmar Maurer <dietmar@ximian.com>
3349 * metadata.c (mono_type_to_unmanaged): dont access
3350 type->data.klass for MONO_TYPE_OBJECT
3351 (mono_type_to_unmanaged): consider System.Delegate class
3353 Tue Apr 15 11:16:05 CEST 2003 Paolo Molaro <lupus@ximian.com>
3355 * class.c: just setup supertypes in the proper place instead of
3356 initializing the full element class for arrays.
3358 Tue Apr 15 11:03:25 CEST 2003 Paolo Molaro <lupus@ximian.com>
3360 * class.c: ensure the element class of arrays is initialized.
3361 Setup the supertype info for array classes, too.
3363 2003-04-14 Miguel de Icaza <miguel@ximian.com>
3365 * icall.c (ves_icall_Type_GetNestedType): Add new internal call.
3367 2003-04-12 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3369 * Makefile.am: re-added -m option when running cygpath. This way,
3370 MONO_ASSEMBLIES and MONO_CFG_DIR will contain '/' as directory
3372 * mono-config.c: same codepath for locating mono config file for WIN32
3375 * reflection.c, reflection.h: implemented and exported functions
3376 to retrieve info about custom attributes.
3378 2003-03-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3380 * appdomain.c: moved Uri handling to assembly.c
3381 * assembly.c: use g_filename_from_uri (). This makes assembly.LoadFrom
3382 work when using a file Uri in *nix and windows.
3384 * icall.c: fixed Assembly.CodeBase to return a valid Uri. The same for
3385 GetReferencedAssemblies.
3387 2003-03-18 Dick Porter <dick@ximian.com>
3389 * icall.c: Rename a couple of internal calls
3391 * threads.c: Set the thread state to Stopped when a thread exits.
3394 2003-03-17 Zoltan Varga <vargaz@freemail.hu>
3396 * icall.c (ves_icall_System_Reflection_FieldInfo_internal_from_handle):
3399 * object.c (mono_class_vtable): fix warning.
3401 2003-03-17 Zoltan Varga <vargaz@freemail.hu>
3403 * icall.c (ves_icall_type_is_subtype_of): Avoid vtable creation.
3405 * reflection.c (mono_blob_entry_hash): Avoid reading uninitialized
3407 (method_encode_clauses): Create exception info structures in the right
3409 (mono_reflection_setup_internal_class): Initialize supertypes field.
3411 * class.c object.c: Handle interfaces which implement other interfaces
3414 * class.h class.c: Move the supertypes array initialization code into
3415 a separate function so it can be used for dynamic types too. Also call
3416 it earlier, in mono_class_init(), since it can be used before the
3417 type is initialized.
3419 2003-03-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3423 * icall.c: make MONO_ASSEMBLIES and MONO_CFG_DIR work on windows.
3428 * object.c: remove warnings.
3430 2003-03-13 Martin Baulig <martin@ximian.com>
3432 * debug-mono-symfile.h (MonoSymbolFileLexicalBlockEntry): New type.
3433 (MonoDebugLexicalBlockEntry): New types.
3435 * debug-mono-symfile.c
3436 (_mono_debug_address_from_il_offset): Moved here from ../jit/debug.c.
3438 2003-03-13 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3440 * process.c: ret can be any non-zero value accroding to MS doc.
3442 2003-03-07 Miguel de Icaza <miguel@ximian.com>
3444 * class.c (mono_marshal_load_type_info): Fix buglet: Noticed when
3445 fixing a warning for a miss-used prototype, would have cause
3446 random memory corruption.
3448 2003-03-07 Martin Baulig <martin@ximian.com>
3450 * marshal.c (mono_marshal_free_array): That "TESTFREE %p" was
3451 getting really annoying ....
3453 2003-03-07 Zoltan Varga <vargaz@freemail.hu>
3455 * reflection.c (fixup_method): added support for array methods.
3457 Tue Mar 4 18:03:27 CET 2003 Paolo Molaro <lupus@ximian.com>
3459 * socket-io.c: handle case when AF_INET6 and AF_IPX are not defined
3460 (pointed out by Michael Adams).
3462 2003-03-04 Dick Porter <dick@ximian.com>
3464 * icall.c: Temporarily reverted the Double and Single ToString()
3465 change, because it broke nunit.
3467 Tue Mar 4 12:40:58 CET 2003 Paolo Molaro <lupus@ximian.com>
3469 * object.h, threads.h: make include files compatible with C++
3470 (patch by Jerome Laban <jlaban@wanadoo.fr>).
3472 2003-03-04 Pedro MartÃnez Juliá <yoros@wanadoo.es>
3474 * icall.c: Erased ToString helper functions for Double and Single.
3475 Now, that implementations ar all in managed code (Double and Single
3478 2003-03-03 Lluis Sanchez Gual <lluis@ideary.com>
3480 * appdomain.c: Added method for initializing the default context of
3481 a domain. Added internal call for getting the default context.
3482 * appdomain.h: Added context variable in MonoDomain struct.
3483 * domain.c: mono_domain_set also sets the default context of the domain
3484 * icall.c: Mapped internal method InternalGetDefaultContext.
3485 * object.c: mono_object_get_virtual_method returns always a remoting
3486 wrapper if the object is a transparent proxy.
3487 mono_runtime_invoke_array: when creating an object by calling the
3488 constructor, if the created object is a proxy, then the constructor should
3489 be called using the a remoting wrapper.
3491 2003-03-03 Dick Porter <dick@ximian.com>
3493 * socket-io.c (create_sockaddr_from_object): Rename sockaddr_un
3494 variable so it compiles on solaris. Problem spotted by
3495 Christopher Taylor <ct@cs.clemson.edu>
3497 2003-03-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3500 (get_info_from_assembly_name): don't leak value.
3503 (ves_icall_System_Reflection_Assembly_GetFilesInternal): initialize
3506 Sat Mar 1 15:32:56 CET 2003 Paolo Molaro <lupus@ximian.com>
3508 * assembly.c: export mono_image_load_references ().
3509 * class.c: handle function pointers. mono_class_from_name() now
3510 supports nested type names directly.
3512 2003-02-28 Zoltan Varga <vargaz@freemail.hu>
3514 * reflection.h reflection.c: Encode already created dynamic methods
3515 and fields correctly as a DEF instead of a REF.
3517 * reflection.c: Get rid of the force_ref argument to
3518 mono_image_typedef_or_ref since it was wrong in the first place.
3520 * string-icalls.c: add error checking to string constructors according
3523 * reflection.c: Emit types in the order their TypeBuilders were
3524 created. Previously, a new table index was assigned to each type before
3525 the tables were emitted. This was wrong because the signature blob
3526 might already refer to a type by its original table index.
3528 2003-02-27 Zoltan Varga <vargaz@freemail.hu>
3530 * metadata.c (mono_metadata_nesting_typedef): fix bug in previous
3533 2003-02-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3535 * Makefile.am: make assemblies dir have \ instead of / on windows.
3537 2003-02-27 Zoltan Varga <vargaz@freemail.hu>
3539 * metadata.c metadata.h (mono_metadata_nesting_typedef): changed to
3540 iterate over the NESTEDCLASS table using a linear search since the
3541 table is not guaranteed to be sorted by the secondary key.
3543 * class.c (mono_class_create_from_typedef): fixed up call to
3544 mono_metadata_nesting_typedef.
3546 2003-02-27 Dietmar Maurer <dietmar@ximian.com>
3548 * marshal.c (mono_string_to_byvalstr): clear the memory as
3549 suggested by Jerome Laban <jlaban@wanadoo.fr>
3551 2003-02-26 Dick Porter <dick@ximian.com>
3553 * process.c: Cope with padding in .rsrc blocks
3555 2003-02-26 Dietmar Maurer <dietmar@ximian.com>
3557 * metadata.h: reverted the filter_len change, it breaks reflection
3559 2003-02-26 Dietmar Maurer <dietmar@ximian.com>
3561 * metadata.h: added a new field to store the filter_len
3564 Tue Feb 25 10:56:16 CET 2003 Paolo Molaro <lupus@ximian.com>
3566 * reflection.c: handle custom attributes for types and members
3567 created with Reflection.Emit (bug#38422).
3569 2003-02-22 Zoltan Varga <vargaz@freemail.hu>
3571 * reflection.c: define RTSpecialName automatically for constructors for
3572 compatibility with MS.NET.
3574 * reflection.c (mono_reflection_create_runtime_class): initialize
3575 nested_in field of dynamically created classes.
3577 2003-02-22 Martin Baulig <martin@ximian.com>
3579 * debug-mono-symfile.h: Incremented version number.
3581 2003-02-21 Zoltan Varga <vargaz@freemail.hu>
3583 * object.h icall.c process.c: fix warnings.
3585 2003-02-21 Zoltan Varga <vargaz@freemail.hu>
3587 * appdomain.h appdomain.c:
3588 (mono_domain_try_type_resolve): split the
3589 name_or_tb argument into a name and a tb argument.
3590 (mono_domain_has_type_resolve): new function to check whenever the
3591 application has registered a TypeResolve event handler.
3593 * icall.c reflection.h reflection.c: move the type resolve logic into
3594 mono_reflection_get_type () so it will be invoked when
3595 Assembly::GetType () is called.
3598 (mono_reflection_get_type): renamed to get_type_internal.
3599 (mono_reflection_get_type): fixed type name generation so it works
3600 for nested types too.
3601 (mono_reflection_get_type): call has_type_resolve () to avoid the
3602 costly type name generation if there is no resolve event handler.
3604 Fri Feb 21 11:36:57 CET 2003 Paolo Molaro <lupus@ximian.com>
3606 * class.c, image.c: load exported types from file references.
3608 2003-02-19 Lluis Sanchez Gual <lluis@ideary.com>
3610 * appdomain.h: Added in MonoDomain a couple of MonoMethod* variables
3611 used to cache the managed methods used to create proxies and make
3612 remote invocation of methods.
3613 * class.h: Added in MonoVTable a flag to indicate that a class needs
3614 to be remotely created.
3615 * object.c: Modified the method mono_class_vtable(). It now initializes
3616 the remote flag of the vtable. Modified mono_object_new_specific(),
3617 so now it checks the remote flag.
3618 * icall.c: Added a couple of internal methods, one for enabling instance
3619 creation interception for a type, and one for creating objects bypassing
3622 2003-02-18 Martin Baulig <martin@ximian.com>
3624 * debug-mono-symfile.c (ves_icall_MonoDebugger_GetMethodToken):
3625 New interncall to get a method's metadata token.
3627 * icall.c ("System.Reflection.Assembly::MonoDebugger_GetMethodToken"):
3628 New interncall for the debugger.
3630 2003-02-18 Dietmar Maurer <dietmar@ximian.com>
3632 * class.c (mono_class_setup_vtable): allocate supertype array
3634 2003-02-18 Martin Baulig <martin@ximian.com>
3636 * debug-mono-symfile.h (MonoSymbolFileMethodAddress): Added `has_this'.
3638 2003-02-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3641 (assembly_name_to_aname): jump over unknown properties (i've found
3642 something like: 'type, assembly, version=xxx, custom=null, public...',
3643 so now will ignore custom=null and still get the rest of the values).
3645 2003-02-17 Dick Porter <dick@ximian.com>
3647 * threads.c: Have Thread.Start() wait for a semaphore to signal
3648 that the thread has set up all its local data. This fixes bug
3649 34323, where Abort() raced the new thread's TLS data.
3651 Also removes the handle_store() call from start_wrapper, because
3652 threads are now always created suspended and there is no longer a
3653 race between the parent and child threads to store the info.
3655 Mon Feb 17 13:13:31 CET 2003 Paolo Molaro <lupus@ximian.com>
3657 * image.c: explain the #- heap issue in a message, hopefully
3658 avoiding FAQs on mono-list.
3660 2003-02-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3663 (GetEntryAssembly): if the domain has not invoked
3664 AppDomain.ExecuteAssembly yet, return the assembly of the default
3667 2003-02-16 Zoltan Varga <vargaz@freemail.hu>
3669 * class.c (mono_ldtoken): make it work in dynamic assemblies.
3671 Sun Feb 16 13:10:06 CET 2003 Paolo Molaro <lupus@ximian.com>
3673 * metadata.c, reflection.c: simple speedup to type hash
3676 Sat Feb 15 15:15:03 CET 2003 Paolo Molaro <lupus@ximian.com>
3678 * image.c, image.h, class.c, assembly.c: move module loading
3679 to MonoImage. When loading metadata, consider alignemnet from
3680 the start of metadata, not from the metadata address in memory.
3682 2003-02-13 Zoltan Varga <vargaz@freemail.hu>
3684 * reflection.c (mono_reflection_get_custom_attrs): Added support for
3685 AssemblyBuilder objects. Factored out custom attribute creation into
3686 a separate function.
3687 (create_custom_attr): new function to create custom attributes.
3689 2003-02-12 Miguel de Icaza <miguel@ximian.com>
3691 * Makefile.am: Got tired of typing the full pathname to pedump.
3692 Until there is another option, am installing this.
3694 2003-02-12 Dietmar Maurer <dietmar@ximian.com>
3696 * class.c (class_compute_field_layout): always set field->parent
3697 (mono_ldtoken): use mono_defaults.fieldhandle_class;
3699 2003-02-11 Dick Porter <dick@ximian.com>
3702 * monitor.c: Rewrote Monitor, making lock much faster and
3703 Pulse/Wait work as specified. Also uses much fewer handles, and only
3704 creates them as needed.
3706 * exception.c: Added SynchronizationLockException
3708 * threads.c: Deleted old Monitor implementation. The new one is
3711 Mon Feb 10 17:54:10 CET 2003 Paolo Molaro <lupus@ximian.com>
3713 * class.c: handled TypedReference type code. Set the correct size for
3714 class data. Setup interface_offsets for interface classes, too.
3716 2003-02-09 Martin Baulig <martin@ximian.com>
3718 * debug-mono-symfile.h: Reflect latest symbol writer changes.
3720 Sun Feb 9 18:37:01 CET 2003 Paolo Molaro <lupus@ximian.com>
3722 * loader.c: implemented MEMBERREF_PARENT_TYPEDEF.
3723 * metadata.c, reflection.c: missing MONO_TYPE_TYPEDBYREF handling.
3724 * object.c: fixed mono_object_get_virtual_method () for interfaces.
3725 * verify.c: check for code that runs after the end of the method.
3727 2003-02-08 Pedro MartÃnez Juliá <yoros@wanadoo.es>
3729 * icall.c: Added "System.Math::Floor", "System.Math::Round" and
3732 2003-01-08 Dietmar Maurer <dietmar@ximian.com>
3734 * marshal.c (mono_marshal_get_icall_wrapper): like
3735 mono_marshal_get_native_wrapper, but simpler and use a MonoMethodSignature
3736 instead of a MonoMethod.
3738 2003-01-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3740 * decimal.c: fixed bug #36537.
3742 Mon Jan 6 19:37:59 CET 2003 Paolo Molaro <lupus@ximian.com>
3744 * marshal.c: throw a missing method exception if a
3745 P/Invoke method is not found.
3747 Sun Jan 5 11:57:09 CET 2003 Paolo Molaro <lupus@ximian.com>
3749 * icall.c: allow a null this for constructors.
3751 Sat Jan 4 18:28:42 CET 2003 Paolo Molaro <lupus@ximian.com>
3753 * icall.c: raise the proper exceptions if the arguments to the
3754 internal Invoke are incorrect.
3756 2003-01-03 Dietmar Maurer <dietmar@ximian.com>
3758 * marshal.c (mono_marshal_get_ptr_to_struct): code cleanups
3760 2003-01-03 Martin Baulig <martin@ximian.com>
3762 * debug-mono-symfile.h: Increment MONO_SYMBOL_FILE_DYNAMIC_VERSION.
3764 2002-12-31 Martin Baulig <martin@ximian.com>
3766 * debug-mono-symfile.c: Completely rewrote the type section.
3767 Instead of using individual malloc()ed fields, we use one big
3768 continuous memory area and offsets into this area.
3769 See the comments in the source code for details.
3771 2002-12-30 Martin Baulig <martin@ximian.com>
3773 * debug-mono-symfile.h (MonoDebugTypeInfo): Renamed to MonoDebugClassInfo.
3775 2002-12-30 Martin Baulig <martin@ximian.com>
3777 * debug-mono-symfile.h (MonoSymbolFileMethodAddress): Include the
3778 line number table in this data blob instead of using an external
3781 2002-12-28 Martin Baulig <martin@ximian.com>
3783 * debug-mono-symfile.h: Increment MONO_SYMBOL_FILE_DYNAMIC_VERSION.
3785 2002-12-22 Rachel Hestilow <hestilow@ximian.com>
3787 * marshal.c (mono_marshal_get_runtime_invoke): Support MONO_TYPE_CHAR
3788 as a boxed return type.
3790 2002-12-21 Miguel de Icaza <miguel@ximian.com>
3793 (ves_icall_System_AppDomainSetup_InitAppDomainSetup): Use
3794 g_build_filename to properly get separators on the filename created.
3796 * object.h: Small change, introduce MonoMarshalByRefObject to
3797 track the layout of that structure in the C# universe as we make
3800 Thu Dec 19 16:23:19 CET 2002 Paolo Molaro <lupus@ximian.com>
3802 * object.c: removed assert to allow static fields on interfaces.
3803 * loader.c: a TypeSpec may be used for any type, not just arrays.
3805 Thu Dec 19 14:19:42 CET 2002 Paolo Molaro <lupus@ximian.com>
3807 * class.c, class.h: added mono_class_array_element_size ().
3808 Ignore static methods in interfaces.
3810 2002-12-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3812 * threads.c: fixed the build under cygwin.
3814 Wed Dec 18 18:43:47 CET 2002 Paolo Molaro <lupus@ximian.com>
3816 * reflection.c: handle nullref constants. Allocate keys for
3817 reflection handles with the GC.
3819 Wed Dec 18 11:34:18 CET 2002 Paolo Molaro <lupus@ximian.com>
3821 * threads.c, threads.h: added mono_thread_get_abort_signal()
3822 to get a suitable signal for thread abort.
3824 Wed Dec 18 11:26:18 CET 2002 Paolo Molaro <lupus@ximian.com>
3826 * metadata.c: fix handling of ExportedType table.
3828 2002-12-15 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3830 * icall.c: added WriteWindowsDebugString internal call.
3832 2002-12-15 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3834 * reflection.h: added fields to match C# implementation.
3836 2002-12-14 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3838 * icall.c: patch from Jaroslaw Kowalski to fix Environment.MachineName.
3840 2002-12-12 Juli Mallett <jmallett@FreeBSD.org>
3842 * gc.h, gc-internal.h: Rename header for GC internal calls to
3843 gc-internal.h from gc.h as to not clash with Boehm GC having its
3844 header installed as <gc.h> in outside include paths.
3845 * appdomain.c, gc.c, icall.c, object.c: Account for aforementioned.
3846 * threads.c: If SIGRTMIN is not defined, fall back to SIGUSR1.
3848 2002-12-12 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3850 * icall.c: assign minor, build and revision in FillName.
3852 2002-12-11 Zoltan Varga <vargaz@freemail.hu>
3854 * image.h reflection.h reflection.c class.h class.c loader.c object.c:
3855 Added support for running code generated by Reflection.Emit.
3857 2002-12-11 Gonzalo P
3858 mono_mempool_stats().
3860 2002-10-23 Dick Porter <dick@ximian.com>
3864 * icall.c: Added MonoIO.GetFileType internal call
3866 2002-10-17 Dick Porter <dick@ximian.com>
3868 * appdomain.c (mono_runtime_cleanup): Don't signal the async
3869 delegate semaphore before waiting for all threads to finish,
3870 because new threads can also call async delegates. Fixes bug
3873 * threadpool.c (async_invoke_thread): Only wait for 500ms instead
3874 of 3 seconds, in case another async job is queued. (This part is
3875 needed because the bug fix reintroduced the 3s exit lag.) This
3876 makes the mono_runtime_shutdown flag superfluous.
3878 Thu Oct 17 13:11:39 CEST 2002 Paolo Molaro <lupus@ximian.com>
3880 * reflection.c: include ehader size in method section headers.
3881 Really check for suplicated modules entries.
3883 2002-10-17 Martin Baulig <martin@gnome.org>
3885 * debug-mono-symfile.c: Added back support for locals.
3887 2002-10-14 Martin Baulig <martin@gnome.org>
3889 * debug-mono-symfile.c: Added MONO_TYPE_I, MONO_TYPE_U and
3892 2002-10-14 Martin Baulig <martin@gnome.org>
3894 * debug-mono-symfile.c (ves_icall_MonoDebugger_GetType): Use
3895 mono_class_get() instead of looking in the class cache.
3897 2002-10-13 Martin Baulig <martin@gnome.org>
3899 * debug-mono-symfile.c: Set version number to 28, include the
3900 signature in method names.
3902 2002-10-13 Martin Baulig <martin@gnome.org>
3904 * debug-mono-symfile.h: Set version number to 27.
3906 2002-10-11 Martin Baulig <martin@gnome.org>
3908 * gc.c: Don't register/unregister NULL pointers as disappearing links.
3910 Thu Oct 10 14:56:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
3912 * metadata.c, metadata.h: added helper function to allocate signatures.
3914 2002-10-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3916 * icall.c: added internal call to get the location of machine.config.
3918 2002-10-08 Martin Baulig <martin@gnome.org>
3920 * debug-mono-symfile.c: Ignore classes with a pending init for the
3923 2002-10-03 Dick Porter <dick@ximian.com>
3925 * threads.c: Freebsd pthread_t is a pointer
3927 2002-10-03 Dick Porter <dick@ximian.com>
3929 * socket-io.c: Implemented GetHostName_internal
3931 2002-10-02 Gonzalo Paniagua Javier <gonzalo@ximian.com>
3934 (mono_config_parse_file): don't leak the text.
3936 2002-10-02 Martin Baulig <martin@gnome.org>
3938 * debug-mono-symfile.c: Added support for methods.
3940 2002-10-01 Martin Baulig <martin@gnome.org>
3942 * debug-mono-symfile.c: Don't emit methods and line numbers for
3943 the dynamic symbol file, just write the type table. We can easily
3944 have an external helper program which creates a symbol file for an
3947 2002-10-01 Dick Porter <dick@ximian.com>
3949 * threads.c (ves_icall_System_Threading_Thread_Start_internal):
3950 Only add the handle to the cleanup array when we're about to
3951 launch the thread. Bug 31425 deadlocked when the test was run on
3954 2002-10-01 Martin Baulig <martin@gnome.org>
3956 * debug-mono-symfile.c: Added support for properties.
3958 Fri Sep 27 18:55:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
3960 * reflection.c: unaligned store fix from Mark Crichton
3961 <crichton@gimp.org>.
3963 2002-09-27 Martin Baulig <martin@gnome.org>
3965 * icall.c ("System.Reflection.Assembly::GetReferencedAssemblies"):
3968 Fri Sep 27 15:38:31 CEST 2002 Paolo Molaro <lupus@ximian.com>
3970 * assembly.h, assembly.c: use a sane API to hook into the assembly
3971 loading process instead of a useless special-purpouse hack
3972 (ngen needs a hook, too, for example).
3974 2002-09-27 Dick Porter <dick@ximian.com>
3976 * threads.c (mono_thread_init): Call GetCurrentProcess() so
3977 io-layer can set up some process handle info. Not needed on w32,
3978 but doesn't hurt either.
3980 * process.c: Pass the program name in the second parameter to
3981 CreateProcess, so the path is searched. Include the working
3982 directory. Implemented process name, process enumeration, and some
3983 process detail internal calls.
3985 * icall.c: Added internal calls for process lookup, and some
3988 2002-09-26 Martin Baulig <martin@gnome.org>
3990 * assembly.c (mono_install_open_assembly_hoo
3992 Mon Aug 26 16:47:37 CEST 2002 Paolo Molaro <lupus@ximian.com>
3994 * object.c: added a define for a good string and array
3995 creation speedup (not enabled by default because we need to deal with
3998 2002-08-26 Martin Baulig <martin@gnome.org>
4000 * debug-mono-symfile.c (mono_debug_create_mono_symbol_file): New
4001 function to create a dynamic symbol file. This is used by the
4002 debugger to create a symbol file for IL code on-the-fly.
4004 2002-08-26 Martin Baulig <martin@gnome.org>
4006 * loader.c (mono_lookup_pinvoke_call): Include the error message
4007 from g_module_error() in the error message.
4009 2002-08-24 Martin Baulig <martin@gnome.org>
4011 * debug-mono-symfile.c (mono_debug_update_mono_symbol_file): New
4012 function to update the symbol file. The symbol file is mmap()ed
4013 writable, but private. This allows us to install the symbol file
4014 together with the assembly.
4016 2002-08-24 Martin Baulig <martin@gnome.org>
4018 * debug-mono-symfile.[ch]: New files. Similar to debug-symfile.[ch]
4019 but they can read the new symbol file format which mcs is now creating.
4021 * debug-symfile.c (mono_debug_find_source_location): Moved to
4022 debug-mono-symfile.c; this is now operating on the new symbol file.
4024 2002-08-23 Martin Baulig <martin@gnome.org>
4026 * debug-helpers.c (mono_method_desc_from_method): New function to get
4027 a MonoMethodDesc from a MonoMethod.
4029 Fri Aug 23 15:54:09 CEST 2002 Paolo Molaro <lupus@ximian.com>
4031 * object.c: fixes assertion failure caused by multiple ExecuteAssembly
4032 calls for same domain (patch by Tomi Pakarinen <Tomi.Pakarinen@iki.fi>).
4034 Fri Aug 23 12:14:45 CEST 2002 Paolo Molaro <lupus@ximian.com>
4036 * string-icalls.[ch]: make helper methods static.
4038 2002-08-23 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4040 * icall.c: re-applied patch to GetValueInternal. Also added R4 and R8
4041 types to it and to SetValueInternal.
4043 * object.c: Moved handle_enum label to its proper place. This was the
4046 This time i compiled mcs and gtk-sharp and they both work.
4048 2002-08-23 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4050 * icall.c: reverted partially my previous patch until
4051 object.c:set_value handles enums correcly.
4053 2002-08-22 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4056 (ves_icall_MonoField_GetValue): changed to use mono_field_get_value.
4057 (ves_icall_System_Environment_get_MachineName): removed warning when
4058 compiling under cygwin.
4060 Thu Aug 22 18:49:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
4062 * object.c: fixed field_get_value() for reference types.
4064 2002-08-22 Dick Porter <dick@ximian.com>
4066 * socket-io.c (ves_icall_System_Net_Sockets_Socket_RecvFrom_internal):
4067 Don't free a buffer while it's still needed. Patch from Jonathan
4068 Liger <Jonathan.liger@wanadoo.fr>
4070 2002-08-21 Miguel de Icaza <miguel@ximian.com>
4072 * icall.c (ves_icall_System_Environment_get_Platform): Add new
4075 2002-08-21 Dietmar Maurer <dietmar@ximian.com>
4077 * icall.c (ves_icall_get_method_info): s/MonoMethod/MonoReflectionMethod/
4078 (ves_icall_get_parameter_info): s/MonoMethod/MonoReflectionMethod/
4080 * marshal.c (mono_marshal_get_remoting_invoke): save lmf, because
4081 we call unmanaged code which throws exceptions.
4083 Wed Aug 21 12:56:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
4085 * appdomain.h: added per-domain entry_assembly.
4086 * appdomain.c: ensure mono_runtime_exec_main () gets non-null
4088 * icall.c: Assembly::GetEntryAssembly icall.
4089 * object.c: set domain->entry_assembly in mono_runtime_exec_main().
4090 Changes above from a patch by Tomi Pakarinen <tomi.pakarinen@welho.com>.
4092 Tue Aug 20 15:42:15 CEST 2002 Paolo Molaro <lupus@ximian.com>
4094 * appdomain.h, gc.c: added mono_domain_finalize ().
4096 2002-08-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4099 (mono_print_unhandled_exception): changed g_warning by g_printerr
4100 because g_log has a 1024 characters limit (yeah, i got a big stack
4101 trace). Don't print exception name, that should be in ToString
4104 2002-08-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4106 * icall.c: added ves_icall_FieldInfo_SetValueInternal.
4107 * object.c: added missing MONO_TYPE_ARRAY in mono_runtime_invoke_array.
4109 2002-08-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4112 (mono_print_unhandled_exception): after previous commit, i realized
4113 that MS calls ToString on the exception. I changed this function to
4114 do that. This way we get stack_trace for free.
4116 2002-08-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4119 (mono_print_unhandled_exception): invoke Message property instead of
4120 getting 'message' field from Exception. Don't allocate memory for
4121 'trace' and 'message' if not needed.
4123 2002-08-18 Dick Porter <dick@ximian.com>
4125 * unicode.c: Fix asserts to match Encoder.cs checks
4127 Fri Aug 16 21:42:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
4129 * marshal.c: fix unaligned store issue and a few wrong
4130 opcode argument types.
4132 2002-08-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4134 * icall.c: added GetUninitializedObjectInternal internal call.
4136 2002-08-16 Dietmar Maurer <dietmar@ximian.com>
4138 * appdomain.c (mono_runtime_invoke_in_domain): transfer Exception
4139 to the right domain.
4141 2002-08-14 Dietmar Maurer <dietmar@ximian.com>
4143 * marshal.c (mono_marshal_get_runtime_invoke): unbox value types
4145 * class.c (class_compute_field_layout): set blittable to false for Strings
4147 * appdomain.c (mono_domain_transfer_object): added support for ISerializable
4149 Wed Aug 14 17:26:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
4151 * appdomain.h, reflection.c, icall.c, object.c, reflection.h:
4152 first chunk of code to create types at runtime. Code to
4153 handle ReflectedType/DeclaringType. Make reflection handles
4156 Wed Aug 14 17:24:21 CEST 2002 Paolo Molaro <lupus@ximian.com>
4158 * class.c: set correct name in arrays.
4160 2002-08-13 Dietmar Maurer <dietmar@ximian.com>
4162 * appdomain.c (mono_domain_transfer_object): make it work with
4163 valuetypes. bug fixes.
4165 2002-08-12 Dick Porter <dick@ximian.com>
4167 * object.h: Rename some parameters to avoid c++ keywords (Patch
4168 from Joseph Wenninger <kde@jowenn.at>)
4170 Thu Aug 8 13:04:18 CEST 2002 Paolo Molaro <lupus@ximian.com>
4172 * icall.c: added icall to implement Assembly.GetFile*.
4174 Thu Aug 8 10:18:17 CEST 2002 Paolo Molaro <lupus@ximian.com>
4176 * reflection.h, reflection.c: code to embed managed resources.
4178 Tue Aug 6 17:59:44 CEST 2002 Paolo Molaro <lupus@ximian.com>
4180 * class.c: move all the type size stuff into
4181 class_compute_field_layout().
4183 Tue Aug 6 11:20:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
4185 * class.c: ensure enums have always the correct instance size.
4186 * unicode.c: remove wrong assert.
4188 Mon Aug 5 19:30:04 CEST 2002 Paolo Molaro <lupus@ximian.com>
4190 * assembly.c: fix mem corruption issue.
4191 * image.h, image.c: added mono_image_get_resource () to access
4193 * icall.c: implemented Assembly.EntryPoint property and some
4194 Managed Resources related internalcalls.
4197 Mon Aug 5 18:18:03 CEST 2002 Paolo Molaro <lupus@ximian.com>
4199 * image.c, image.h: impemented mono_image_get_entry_point ().
4200 * appdomain.c: use mono_image_get_entry_point.
4202 Mon Aug 5 13:08:15 CEST 2002 Paolo Molaro <lupus@ximian.com>
4204 * reflection.c: support the object type argument when loading
4207 2002-08-05 Dietmar Maurer <dietmar@ximian.com>
4209 * marshal.c (mono_marshal_get_managed_wrapper): add suppport for
4210 String as return type.
4212 Fri Aug 2 21:15:42 CEST 2002 Paolo Molaro <lupus@ximian.com>
4214 * reflection.c: fix encoding of named args for custom attrs to match
4215 the ms implementation. Read them back when instantiating custom
4218 2002-08-02 Radek Doulik <rodo@ximian.com>
4220 * marshal.c (mono_mb_add_data): convert ret value to LE, suggested
4221 by Dietmar as quick fix
4222 (mono_marshal_get_delegate_begin_invoke): use sig->param_count +
4223 16 as stack size, used on more places as quick fix before Dietmar
4224 will fix it properly
4226 Fri Aug 2 17:48:17 CEST 2002 Paolo Molaro <lupus@ximian.com>
4228 * object.h, object.c: added accessors for fields and properties.
4230 Fri Aug 2 17:45:15 CEST 2002 Paolo Molaro <lupus@ximian.com>
4232 * class.c, class.h: made mono_class_get_field_from_name ()
4233 loop on parent types.
4236 * debug-helpers.c (mono_method_full_name): this can now generate
4237 method names with signatures
4239 * marshal.c (mono_marshal_get_managed_wrapper): bug fix: unmanaged
4240 method dont have this pointers.
4242 Fri Jul 12 11:35:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
4244 * reflection.c: fixup typebuilder tokens.
4245 * image.c: fix buglet.
4246 * marshal.h: remove whitespace.
4247 * metadata.h, metadata.c: reinstate code that was removed.
4248 * verify.c: handle catch directives and fix another couple of bugs.
4250 2002-07-11 Dietmar Maurer <dietmar@ximian.com>
4252 * marshal.c (mono_marshal_get_native_wrapper): support BOOLEAN
4253 (mono_marshal_get_native_wrapper): make it comp. with the old code
4254 (mono_marshal_get_native_wrapper): support boolean
4255 (mono_marshal_get_managed_wrapper): support more types
4257 2002-06-25 Dietmar Maurer <dietmar@ximian.com>
4259 * class.c (class_compute_field_layout): compute class->blittable attribute.
4261 2002-07-09 Dick Porter <dick@ximian.com>
4263 * threads.c: Make the thread cleaning up cope with threads that
4266 2002-07-08 Radek Doulik <rodo@ximian.com>
4268 * reflection.c (method_encode_code): use non-translated values to
4269 compute finally_start, this fixes exception handling on ppc, yay!
4271 * decimal.h (struct signscale): fix endianess
4273 2002-07-07 Radek Doulik <rodo@ximian.com>
4275 * reflection.c: swap box_val and not val
4277 Mon Jul 8 15:18:59 CEST 2002 Paolo Molaro <lupus@ximian.com>
4279 * reflection.c, reflection.h: handle full assembly info in type name.
4280 Handle Type arguments when loading custom attributes.
4281 * icall.c: updated to use new mono_reflection_type_from_name () method.
4283 2002-07-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4286 (method_from_memberref): also print assembly name when method not found.
4288 2002-07-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4291 (ves_icall_TypeGetProperties): fixed bug #27473.
4293 2002-07-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4295 * reflection.c: display image name and token when cannot find the
4296 .ctor for an attribute.
4298 2002-07-05 Martin Baulig <martin@gnome.org>
4300 * debug-symfile.c: Reflect latest MonoDwarfFileWriter changes.
4302 2002-07-04 Dick Porter <dick@ximian.com>
4304 * threads.c (mono_thread_cleanup): Nasty kludge to get this to
4305 compile on mingw. This will cause mingw builds to not wait for
4306 subthreads to terminate after the main thread does. I've lodged a
4307 bug with the mingw developers for them to wrap OpenThread().
4309 2002-07-03 Dick Porter <dick@ximian.com>
4311 * threads.c: Store thread IDs instead of handles, because
4312 GetCurrentThread() returns a pseudohandle and therefore stores
4313 useless values. mono_thread_cleanup() continues checking the
4314 array of threads until it is empty, to cope with subthreads
4315 spawning new threads after the main thread has finished.
4319 * profiler-private.h: Pass the thread ID to thread profiler
4320 functions, instead of a handle
4322 Wed Jul 3 17:43:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
4324 * verify.c: fixes to make it more usable.
4325 * pedump.c: added --verify code to verify IL code in an assembly.
4327 Tue Jul 2 20:40:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
4329 * reflection.c: turn errors into warnings to allow compiling corlib.
4331 Tue Jul 2 19:33:20 CEST 2002 Paolo Molaro <lupus@ximian.com>
4333 * reflection.c: add special cases to compile corlib.
4335 Mon Jul 1 18:00:40 CEST 2002 Paolo Molaro <lupus@ximian.com>
4337 * reflection.c: handle properties with only a set method.
4339 Mon Jul 1 17:11:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
4341 * opcodes.h: add enum with opcodes in opval order.
4343 2002-07-01 Dick Porter <dick@ximian.com>
4346 * object.c (mono_runtime_run_main): Removed unneeded argument
4348 2002-06-28 Martin Baulig <martin@gnome.org>
4350 * debug-symfile.c: Reflect latest MonoDwarfFileWriter changes.
4352 2002-06-27 Dick Porter <dick@ximian.com>
4354 * threads.c: Store the handle in both the parent thread and in the
4355 subthread, to minimise the time between starting a new thread and
4358 2002-06-26 Dick Porter <dick@ximian.com>
4360 * appdomain.c (mono_runtime_cleanup): Close the socket library
4361 after all the threads have finished, not before
4363 2002-06-26 Martin Baulig <martin@gnome.org>
4365 * debug-symfile.c (mono_debug_find_source_location): Added
4366 `guint32 *line_number' argument. If it's not NULL, store the line number
4367 there and return the file name without the line number.
4369 2002-06-25 Dick Porter <dick@ximian.com>
4373 * process.c: Process forking and other support functions
4375 2002-06-25 Dick Porter <dick@ximian.com>
4377 * image.c (do_mono_image_open): Set ref_count to 1, so that bad
4378 things dont happen when the image is closed.
4379 (mono_image_lookup_resource): Walk the resource section looking
4380 for a particular entry
4382 * cil-coff.h: PE resource section decoding
4384 2002-06-25 Dick Porter <dick@ximian.com>
4388 (mono_assembly_foreach): Accessor functions to walk the list of
4390 (mono_assembly_set_main):
4391 (mono_assembly_get_main): Process methods need to know which
4392 assembly is the "main" one
4394 * object.c (mono_runtime_run_main): Record the main assembly
4396 * debug-helpers.c: Fix typo
4398 2002-06-24 Dietmar Maurer <dietmar@ximian.com>
4400 * icall.c (ves_icall_System_Runtime_InteropServices_Marshal_copy_to_unmanaged): impl.
4401 (ves_icall_System_Runtime_InteropServices_Marshal_copy_from_unmanaged): impl.
4403 Sat Jun 22 11:37:25 CEST 2002 Paolo Molaro <lupus@ximian.com>
4405 * icall.c: fix off-by-one in Assembly.GetTypes() reported by bob@karr.ath.cx.
4407 2002-06-21 Miguel de Icaza <miguel@ximian.com>
4409 * image.c (do_mono_image_open): Initialize reference count,
4410 otherwise we leak the MonoImage.
4412 Fri Jun 21 19:16:47 CEST 2002 Paolo Molaro <lupus@ximian.com>
4414 * reflection.c: small tweak to handle self-hosting.
4416 Thu Jun 20 23:28:13 CEST 2002 Paolo Molaro <lupus@ximian.com>
4418 * reflection.c: fix type name parse code.
4420 Thu Jun 20 19:24:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
4422 * reflection.c: break out of the loop.
4423 * image.c: special case corlib.
4425 Thu Jun 20 16:43:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
4427 * reflection.c: add all the custom attrs at the end to ensure the
4428 ctors have been properly initialized when the attributes are defined
4429 in the current assembly.
4431 Thu Jun 20 13:46:40 CEST 2002 Paolo Molaro <lupus@ximian.com>
4433 * reflection.c: handle correctly multiple-nested types.
4435 Thu Jun 20 11:49:00 CEST 2002 Paolo Molaro <lupus@ximian.com>
4437 * row-indexes.h: fix typos.
4438 * reflection.c: adjust for typos and fix method_def_or_ref
4439 encoding in MethodImpl table.
4441 Wed Jun 19 21:57:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
4443 * reflection.c: fix entry point patching (thanks Serge!).
4445 2002-06-18 Dietmar Maurer <dietmar@ximian.com>
4447 * verify.c: add check for System.Exception
4449 Mon Jun 17 20:23:23 CEST 2002 Paolo Molaro <lupus@ximian.com>
4451 * image.c, class.c: minifix for code just c&p'ed.
4452 * reflection.c: warning fix.
4453 * object.h, loader.h, domain.c: load also StringBuilder.
4455 Mon Jun 17 17:29:40 CEST 2002 Paolo Molaro <lupus@ximian.com>
4457 * marshal.h, marshal.c: some support code to handle complex marshaling.
4459 Mon Jun 17 16:32:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
4461 * class.h, class.c, reflection.c: handle ignorecase in GetType ().
4462 Better signatures with vtable error dump.
4464 Mon Jun 17 16:13:35 CEST 2002 Paolo Molaro <lupus@ximian.com>
4466 * reflection.c, reflection.h, icall.c: fixes for multiple-nested types.
4468 2002-06-17 Dietmar Maurer <dietmar@ximian.com>
4470 * icall.c (ves_icall_Type_GetField): impl.
4472 Mon Jun 17 16:08:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
4474 * metadata.h, metadata.c: added mono_metadata_get_marshal_info()
4475 to retrieve a marshal description blob for a field or param.
4477 Mon Jun 17 14:57:03 CEST 2002 Paolo Molaro <lupus@ximian.com>
4479 * reflection.h, reflection.c: change order of nested type emission
4480 to avoid table corruption. The NestedTypes table is sorted.
4481 * icall.c: change order of GetConstructor results to workaround mcs bug.
4483 Fri Jun 14 16:24:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
4485 * reflection.h, reflection.c: handle field and param marshal
4488 Wed Jun 12 16:30:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
4490 * icall.c, marshal.c marshal.h: more Marshal class implementation.
4492 Tue Jun 11 17:29:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
4494 * reflection.c: fix call convention.
4496 Tue Jun 11 16:52:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
4498 * reflection.h, reflection.c: mono_image_get_memberref_token()
4499 takes a type instead of a class, now. Added
4500 mono_image_get_array_token() to create tokens for the special
4501 multi-dim array methods.
4503 Tue Jun 11 13:21:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
4505 * assembly.c: handle modules (no assembly table). Split
4506 loading references in its own function.
4507 * class.c: handle moduleref resolution scope.
4508 * image.c, image.h: cache module name in image.
4510 2002-06-07 Martin Baulig <martin@gnome.org>
4512 * reflection.c (mono_image_get_type_info): Only add a class layout entry
4513 if we actually have a `tb->class_size' (ie. it's not UnspecifiedTypeSize).
4515 Fri Jun 7 22:07:25 CEST 2002 Paolo Molaro <lupus@ximian.com>
4517 * icall.c: more signature fixes that used uint instead of int.
4519 Fri Jun 7 20:41:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
4521 * reflection.c: fixed signature of field refs.
4523 Fri Jun 7 19:41:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
4525 * class.c, reflection.c: handle typerefs of nested types
4526 (both on read and when writing files).
4528 Fri Jun 7 17:46:50 CEST 2002 Paolo Molaro <lupus@ximian.com>
4530 * icall.c: fix method signatures that tried to workaround the previous
4533 Fri Jun 7 17:36:33 CEST 2002 Paolo Molaro <lupus@ximian.com>
4535 * debug-helpers.c: fix typo.
4537 Fri Jun 7 17:00:04 CEST 2002 Paolo Molaro <lupus@ximian.com>
4539 * cil-coff.h, icall.c, image.c, reflection.c, reflection.h:
4540 rewrote the PE/COFF writing code (our programs are understood by the
4543 Tue Jun 4 18:10:47 CEST 2002 Paolo Molaro <lupus@ximian.com>
4545 * gc.c, gc.h, icall.c: weakreference support.
4547 Tue Jun 4 16:06:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
4549 * Makefile.am, mono-config.c: use $(sysconfdir).
4551 Mon Jun 3 13:13:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
4553 * icall.c: changed default precision of Double.ToString() to 15.
4554 Fixed memory leak. Unified with Single.ToString.
4556 Sat Jun 1 14:26:45 CEST 2002 Paolo Molaro <lupus@ximian.com>
4558 * sysmath.c: workaround systems missing NAN and/or HUGE_VAL.
4560 Sat Jun 1 13:46:54 CEST 2002 Paolo Molaro <lupus@ximian.com>
4562 * pedump.c, appdomain.c, appdomain.h, assembly.c, domain.c,
4563 gc.c, icall.c, image.c, mono-config.c, reflection.c: killed
4564 warnings and compilation fixes from Dennis Haney (davh@davh.dk)
4567 Fri May 31 16:58:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
4569 * debug-symfile.c, sysmath.c: yet more compilation fixes.
4571 Fri May 31 16:35:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
4573 * reflection.c, socket-io.c: more compilation fixes.
4575 Fri May 31 15:58:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
4577 * appdomain.c, class.c, class.h, debug-symfile.c, decimal.c,
4578 domain.c, loader.c, object.c, object.h, reflection.c, string-icalls.h,
4579 unicode.c: warning and compiler compatibility fixes.
4581 Fri May 31 15:36:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
4583 * class.h, metadata.c: fixed warnings/compilation errors.
4585 Fri May 31 13:08:25 CEST 2002 Paolo Molaro <lupus@ximian.com>
4587 * Makefile.am, mono-config.c, mono-config.h: configuration file
4589 * loader.c, loader.h: make Dll mapping configurable at runtime in the
4590 config file. Export methods to insert and lookup mappings.
4592 Fri May 31 12:45:38 CEST 2002 Paolo Molaro <lupus@ximian.com>
4594 * reflection.c: handle types and boxed objects in custom attr
4597 2002-05-30 Martin Baulig <martin@gnome.org>
4600 (ves_icall_Debugger_MonoSymbolWriter_method_builder_from_token): Removed.
4602 Thu May 30 14:15:02 CEST 2002 Paolo Molaro <lupus@ximian.com>
4604 * metadata.c, metadata.h: added mono_metadata_implmap_from_method()
4605 to lookup the implmap row for a P/Invoke method.
4606 * loader.c: added mono_lookup_pinvoke_call(): we only lookup a
4607 P/Invoke method from the runtime on an as needed basis.
4609 2002-05-28 Dietmar Maurer <dietmar@ximian.com>
4611 * metadata.c (mono_metadata_parse_signature): impl.
4613 Tue May 28 16:02:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
4615 * class.c: handle .pack directive.
4617 Tue May 28 11:04:46 CEST 2002 Paolo Molaro <lupus@ximian.com>
4619 * object.c: initialize static fields with RVA data.
4621 2002-05-25 Martin Baulig <martin@gnome.org>
4624 (ves_icall_Debugger_DwarfFileWriter_get_type_token): Removed.
4626 2002-05-24 Martin Baulig <martin@gnome.org>
4629 (ves_icall_Debugger_MonoSymbolWriter_get_local_type_from_sig): Removed.
4630 (ves_icall_Debugger_MonoSymbolWriter_method_from_token): Renamed to
4631 `ves_icall_Debugger_MonoSymbolWriter_method_builder_from_token'.
4633 Thu May 23 18:44:37 CEST 2002 Paolo Molaro <lupus@ximian.com>
4635 * object.c: special case string ctros in invoke.
4636 * gc.c: silly whitespace changes.
4638 2002-05-23 Dietmar Maurer <dietmar@ximian.com>
4640 * threadpool.[ch]: impl. a threadpool that can
4641 be used by mint and mono.
4643 2002-05-22 Martin Baulig <martin@gnome.org>
4645 * debug-symfile.c (ves_icall_Debugger_MonoSymbolWriter_method_from_token):
4646 The first argument is now a `MonoReflectionModuleBuilder *', the return
4647 value is a `MonoReflectionModuleBuilder *'. Use the AssemblyBuilder's
4648 `methods' field to get the method builder. The `token' argument is the
4651 * unicode.c (iconv_get_length, iconv_convert): Silently ignore all
4652 invalid characters instead of g_assert_not_reached()ing. This seems
4653 to be the behaviour of mscorlib.
4655 2002-05-22 Dietmar Maurer <dietmar@ximian.com>
4657 * object.c (mono_runtime_invoke_array): applied patch from Rachel
4658 Hestilow to fix bug #25104
4660 2002-05-21 Martin Baulig <martin@gnome.org>
4662 * debug-symfile.c (mono_debug_find_source_location): New function.
4663 Looks up an IL offset in the line number table and returns the source
4664 location as a string.
4666 2002-05-21 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4669 (mono_double_ToStringImpl): changed %f by %g until we have something
4672 2002-05-21 Nick Drochak <ndrochak@gol.com>
4674 * icall.c : Use different name for Math.Pow's icall. Needed to check
4675 parameters first in C#.
4677 Mon May 20 17:36:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
4679 * icall.c, reflection.h: added icall to get info about an event.
4681 2002-05-20 Radek Doulik <rodo@ximian.com>
4683 * object.c (mono_value_box): don't use memcpy for boxing on BIG
4685 (mono_value_box): don't use memcpy for small sizes on
4686 architectures with unaligned access
4688 2002-05-20 Martin Baulig <martin@gnome.org>
4690 * reflection.c (mono_reflection_setup_internal_class): Don't crash
4691 if `tb->parent == NULL'.
4692 (mono_reflection_create_internal_class): New function. This is
4693 called from TypeBuilder.CreateType() and sets `klass->enum_basetype'
4696 * icall.c ("System.Reflection.Emit.TypeBuilder::create_internal_class"):
4699 2002-05-19 Martin Baulig <martin@gnome.org>
4701 * unicode.c (ves_icall_iconv_get_bytes): Actually use the `charCount'
4702 argument to get the length, don't default to the array length.
4704 2002-05-18 Miguel de Icaza <miguel@ximian.com>
4706 * assembly.c (mono_assembly_setrootdir): New function used to
4707 override the MONO_ASSEMBLIES directory.
4709 Fri May 17 20:39:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
4711 * icall.c: ValueType_GetHashCode() initialize local var.
4713 Thu May 16 17:20:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
4715 * reflection.c: sort custom attributes table.
4717 Thu May 16 16:08:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
4719 * reflection.c: support named args in custom attributes (write support).
4721 Thu May 16 13:04:59 CEST 2002 Paolo Molaro <lupus@ximian.com>
4723 * reflection.c: fix finally position calculation.
4725 2002-05-15 Radek Doulik <rodo@ximian.com>
4727 * reflection.c: fixed endianess at many places
4729 * icall.c (ves_icall_InitializeArray): comment out debug msg
4731 2002-05-15 Dietmar Maurer <dietmar@ximian.com>
4733 * object.c (mono_unhandled_exception): new function to handle
4734 unhandled exceptions.
4735 (mono_unhandled_exception): call the UnhandledException event.
4736 (mono_runtime_delegate_invoke): impl.
4739 * object.c (mono_runtime_invoke_array) : handle null in params
4741 2002-04-23 Patrik Torstensson <patrik.torstensson@labs2.com>
4743 * string-icalls.c: fixed bug in split (one off bug)
4745 2002-04-23 Patrik Torstensson <patrik.torstensson@labs2.com>
4747 * string-icalls.c: fixed bug in remove and lastindexofany, add equals icall.
4748 * icalls.c: added String::Equals as internal method
4750 2002-04-23 Patrik Torstensson <patrik.torstensson@labs2.com>
4752 * threads.c: fixed bug in the double interlocked functions
4754 2002-04-22 Patrik Torstensson <patrik.torstensson@labs2.com>
4756 * threads.c: implemented all of the new interlocked icalls.
4757 * string-icalls.c: fix a bug in insert.
4758 * icalls.c: added the icalls for interlocked, removed old string functions.
4760 Mon Apr 22 19:44:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
4762 * loader.c: fix off-by-one error when reading argument names.
4764 Mon Apr 22 19:28:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
4766 * profiler.c: win32 counter implementation (untested).
4767 * icall.cs: win32 GetNow() and GetTimeZoneData() implementations
4768 (the latter needs testing and more complete impl. from win32 folks).
4770 2002-04-21 Dan Lewis <dihlewis@yahoo.co.uk>
4772 * object.c: mono_array_new_full workaround mono_array_class_get
4775 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
4777 * string-icalls.c (mono_string_InternalRemove): Fixed overwrite bug.
4778 * object.h (mono_string_chars): Changed casting type.
4780 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
4782 * string-icalls.c: Fixed trim method, added the constructors done by Duncan, fixed
4783 method signatures to use gunichar2 instead of gint16.
4785 2002-04-20 Dan Lewis <dihlewis@yahoo.co.uk>
4787 * object.h, object.c: domain-specific versions of mono_object_new and
4790 2002-04-20 Dietmar Maurer <dietmar@ximian.com>
4792 * object.c: changed String layout
4794 * string-icalls.c (mono_string_Internal_ctor_chara): added
4795 internal string constructors.
4797 Sat Apr 20 13:33:07 CEST 2002 Paolo Molaro <lupus@ximian.com>
4799 * threads.c: pass 'this' to the thread start routine.
4801 2002-04-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
4803 * string-icalls.c: fix IndexOf and LastIndexOf. Now
4804 InternalCompareStr don't call twice mono_string_cmp_char for the last
4805 character. Improved performance in mono_string_cmp_char.
4807 Fri Apr 19 19:26:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
4809 * Makefile.am, appdomain.c, class.c, object.c: split runtime-depended
4810 code into its own library: libmonoruntime.
4812 2002-04-19 Dan Lewis <dihlewis@yahoo.co.uk>
4814 * object.h, object.c: changed array format so that szarrays do not
4815 require a bounds structure.
4816 * icall.c, appdomain.c: support for new szarray format.
4818 Fri Apr 19 18:04:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
4820 * metadata.c: compare also the retuns type when comparing signatures:
4821 we didn't do this as an optimization since really overloaded methods
4822 must differ also in the arguments, but this doesn't work with
4823 low-level IL code (or when using explicit conversion operators: see
4824 bug#23498 for an example).
4826 Fri Apr 19 16:14:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
4828 * loader.c: SZARRAY types can be saved as TYPESPEC, too.
4830 Thu Apr 18 17:15:09 CEST 2002 Paolo Molaro <lupus@ximian.com>
4832 * icall.c: make MonoType::GetElementType its own icall.
4834 Thu Apr 18 16:41:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
4836 * icall.c: remove MonoMethod_get_Name().
4837 * reflection.c, reflection.h, verify: cache the method name in the MonoMethod
4840 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
4842 * string-icalls.c: optimized a few methods.
4844 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
4846 * icall.c: added all new string internal calls
4847 * string-icalls.c: added, new string internal call implementation.
4848 * object.c: added mono_string_new_size for allocating a string a size
4850 2002-04-17 Dietmar Maurer <dietmar@ximian.com>
4852 * object.c (mono_object_isinst): use the same code as in the
4853 optimized x86 version.
4855 Wed Apr 17 14:14:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
4857 * profiler.c: TSC-based timer code (f
4859 Thu Mar 28 15:58:43 CET 2002 Paolo Molaro <lupus@ximian.com>
4861 * assembly.c, debug-helpers.c, image.c, image.h, metadata.c, pedump.c,
4862 rawbuffer.c, reflection.c, verify.c: mare warning cleanups.
4864 Thu Mar 28 15:20:39 CET 2002 Paolo Molaro <lupus@ximian.com>
4866 * assembly.h: fix function prototype.
4867 * metadata.h, metadata.c, object.h, private.h: get rid of warnings.
4868 * mono-endian.h: use const cast.
4870 2002-03-28 Dietmar Maurer <dietmar@ximian.com>
4872 * icall.c (ves_icall_MonoMethodMessage_InitMessage): moved from message.c
4874 Thu Mar 28 12:32:00 CET 2002 Paolo Molaro <lupus@ximian.com>
4876 * loader.c: don't assert when a typeref can't be loaded, give
4877 a chance to the runtime to trow an exception instead.
4878 * loader.h: fix warning.
4880 2002-03-28 Dietmar Maurer <dietmar@ximian.com>
4882 * class.c (mono_class_proxy_vtable): added proxy support
4884 2002-03-27 Dan Lewis <dihlewis@yahoo.co.uk>
4886 * icall.c: removed last of PAL calls, added System.Environment
4887 * file-io.h, file-io.c: MonoIO implementation
4888 * object.h, object.c: mono_string_to_utf16() now returns gunichar2*
4890 Tue Mar 26 19:56:10 CET 2002 Paolo Molaro <lupus@ximian.com>
4892 * appdomain.c: do not use the byte marker in ldstr table lookup.
4893 * debug-helpers.c: allow two ':' to separate class and method name.
4894 * object.c: allocate arrays bounds with the GC, too.
4895 * verify: add a few more checks.
4897 Tue Mar 26 18:45:46 CET 2002 Paolo Molaro <lupus@ximian.com>
4899 * reflection.c: output also literal strings. Allocate parameter data
4900 with GC_malloc() (thanks, Martin, for catching this!).
4902 2002-03-26 Martin Baulig <martin@gnome.org>
4904 * debug-symfile.h (MonoDebugMethodInfo): Added `this_offset', don't
4905 include the `this' offset in the `param_offsets'.
4907 2002-03-25 Martin Baulig <martin@gnome.org>
4909 * debug-symfile.c (mono_debug_update_symbol_file): Use a new
4910 mono_debug_get_class() function to get the classes. Added new
4911 relocation types for arrays and strings.
4912 (mono_debug_get_class): New static function to search in all
4913 referenced assemblies for a metadata token.
4915 * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 7.
4917 Mon Mar 25 13:08:18 CET 2002 Paolo Molaro <lupus@ximian.com>
4919 * reflection.h, reflection.c: use a gc-safe hash for hash tables that
4920 hold gc-allocated objects. Make the string heap a stream like the
4921 others. Removed duplicated code when writing stream info.
4922 Added asserts to catch possible buffer overflows. Set the sorted map
4923 for tables that need sorting. Added some documentation.
4925 Mon Mar 25 13:04:56 CET 2002 Paolo Molaro <lupus@ximian.com>
4927 * appdomain.h, appdomain.c, class.c, object.c: use a GC-safe hash table
4928 for interned strings and vtables.
4930 2002-03-24 Martin Baulig <martin@gnome.org>
4932 * icall.c (ves_icall_Type_GetFields): Reverse the list before storing
4933 it in the array since it was created with g_slist_prepend().
4935 2002-03-24 Martin Baulig <martin@gnome.org>
4937 * debug-symfile.c (mono_debug_local_type_from_signature): Renamed
4938 to ves_icall_Debugger_MonoSymbolWriter_get_local_type_from_sig().
4939 (mono_debug_method_from_token): Renamed to
4940 ves_icall_Debugger_MonoSymbolWriter_method_from_token().
4941 (ves_icall_Debugger_DwarfFileWriter_get_type_token): New interncall.
4943 * debug-symfile.c (MRT_type_sizeof, MRT_type_field_offset): New
4946 * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 6.
4948 2002-03-24 Martin Baulig <martin@gnome.org>
4950 * debug-symfile.c (mono_debug_local_type_from_signature): New func.
4951 (mono_debug_method_from_token): New func.
4953 * icall.c (Mono.CSharp.Debugger.MonoSymbolWriter::get_local_type_from_sig):
4954 New interncall, calls mono_debug_local_type_from_signature().
4955 (Mono.CSharp.Debugger.MonoSymbolWriter::get_method): New interncall,
4956 calls mono_debug_method_from_token().
4958 2002-03-23 Martin Baulig <martin@gnome.org>
4960 * unicode.c (ves_icall_iconv_get_char_count): The `count' argument
4961 specifies the number of bytes to be converted, not the array size.
4962 Return the number of chars, not the number of bytes.
4963 (ves_icall_iconv_get_chars): The `byteCount' argument
4964 specifies the number of bytes to be converted, not the array size.
4966 2002-03-23 Martin Baulig <martin@gnome.org>
4968 * reflection.h (MonoReflectionSigHelper): New type.
4970 * reflection.c (mono_reflection_sighelper_get_signature_local),
4971 (mono_reflection_sighelper_get_signature_local): New functions.
4973 * icall.c (System.Reflection.Emit.SignatureHelper::get_signature_local),
4974 (System.Reflection.Emit.SignatureHelper::get_signature_field): New
4977 2002-03-23 Martin Baulig <martin@gnome.org>
4979 * rawbuffer.c (mono_raw_buffer_load_mmap): Use MAP_SHARED when
4980 is_writeable is set.
4981 (mono_raw_buffer_update): New function to write the modified map
4984 * debug-symfile.h (MonoDebugSymbolFile): Added `raw_contents_size'.
4986 * debug-symfile.c (mono_debug_update_symbol_file): Call
4987 mono_raw_buffer_update() when done writing.
4989 2002-03-23 Martin Baulig <martin@gnome.org>
4991 * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 5.
4993 * debug-symfile.c: Added support for arguments and local variables.
4995 2002-03-23 Dick Porter <dick@ximian.com>
4997 * debug-symfile.c: Remove extraneous 'include <elf.h>' that wasn't
4998 protected by ifdefs, hence breaking the w32 build.
5000 Thu Mar 21 17:35:01 CET 2002 Paolo Molaro <lupus@ximian.com>
5002 * object.c: implement is_interned() the right way.
5004 2002-03-21 Martin Baulig <martin@gnome.org>
5006 * debug-symfile.[ch]: New files to handle debugging information
5007 files. There's also support to dynamically update these symbol
5008 files to include machine dependent information.
5010 2002-03-20 Dietmar Maurer <dietmar@ximian.com>
5012 * threads.c (mono_thread_create): new function to create thread
5015 2002-03-20 Martin Baulig <martin@gnome.org>
5017 * icall.c (ves_icall_InternalInvoke): Create a new object if the
5018 method is a constructor.
5019 (icall_map): Added "System.Reflection.MonoCMethod::InternalInvoke",
5020 points to ves_icall_InternalInvoke().
5022 2002-03-20 Dan Lewis <dihlewis@yahoo.co.uk>
5024 * file-io.c: Flush shouldn't throw exceptions.
5026 2002-03-19 Dan Lewis <dihlewis@yahoo.co.uk>
5028 * file-io.c: FileStream flush support; FileSetLength now
5029 restores file pointer.
5031 Tue Mar 19 18:17:21 CET 2002 Paolo Molaro <lupus@ximian.com>
5033 * class.c: set image for pointer classes.
5035 2002/03/19 Nick Drochak <ndrochak@gol.com>
5037 * sysmath.c: Forgot one.
5039 2002-03-18 Miguel de Icaza <miguel@ximian.com>
5041 * sysmath.c: Avoid redefining existing names.
5043 2002-03-18 Dan Lewis <dihlewis@yahoo.co.uk>
5045 * sysmath.c, sysmath.h, icall.c, Makefile.am: math routines now
5046 handled by runtime as icall rather than dllimport from libm.so
5047 * file-io.c, file-io.h: fixed handle argument type.
5049 2002-03-18 Dick Porter <dick@ximian.com>
5051 * reflection.c (mono_image_get_type_info): rename interface to
5052 iface, because of "#define interface struct" on windows.
5054 Sat Mar 16 19:18:38 CET 2002 Paolo Molaro <lupus@ximian.com>
5056 * class.c, class.h: rename and export mono_ptr_class_get().
5057 * metadata.c: support MONO_TYPE_ARRAY in MonoType compare.
5058 * reflection.c, reflection.h, icall.c: better/saner type name
5059 parsing and MonoType creation. Handle MONO_TYPE_ARRAY in
5062 2002-03-14 Dietmar Maurer <dietmar@ximian.com>
5064 * class.c (mono_class_init): removed hardcoded GHC_SLOT
5066 * icall.c (ves_icall_InternalInvoke): impl.
5068 Wed Mar 13 00:27:30 CET 2002 Paolo Molaro <lupus@ximian.com>
5070 * reflection.c: output the interface map table, too.
5072 2002-03-12 Dietmar Maurer <dietmar@ximian.com>
5074 * class.c (class_compute_field_layout): separate computation of
5077 2002-03-12 Dan Lewis <dihlewis@yahoo.co.uk>
5079 * icall.c: added System.Buffer support.
5080 * file-io.c: moved file icalls from PAL to FileStream.
5082 2002-03-12 Dietmar Maurer <dietmar@ximian.com>
5084 * icall.c (ves_icall_System_Object_GetHashCode): impl.
5086 2002-03-11 Dietmar Maurer <dietmar@ximian.com>
5088 * icall.c (ves_icall_System_ValueType_GetHashCode): impl.
5090 Mon Mar 11 14:45:42 CET 2002 Paolo Molaro <lupus@ximian.com>
5092 * verify.c, verify.h: moved here the corlib/runtime consistency checks.
5094 Mon Mar 11 11:12:23 CET 2002 Paolo Molaro <lupus@ximian.com>
5096 * debug-helpers.{c,h}: moved here from monograph some useful functions
5097 to locate a method by name/signature in a class or image. Included
5098 also a small and flexible IL disassembler.
5100 Fri Mar 8 16:29:29 CET 2002 Paolo Molaro <lupus@ximian.com>
5102 * reflection.c: fixup tokens in methods with small header size, too.
5104 2002-03-08 Dietmar Maurer <dietmar@ximian.com>
5106 * object.c (mono_string_to_utf8): remove assert(!error), instead
5109 Thu Mar 7 18:55:15 CET 2002 Paolo Molaro <lupus@ximian.com>
5111 * icall.c: update to the new mono_Array_class_get interface.
5113 Thu Mar 7 17:23:26 CET 2002 Paolo Molaro <lupus@ximian.com>
5115 * appdomain.c, object.c: Boehm-GC enable.
5116 * icall.c: make get_data_chunk() support split data requests.
5117 Ensure a class is initialized in more cases. Return only the first
5118 property found in GetProperties() or the compiler gets confused.
5119 Implemented GetEvents(). Temporary fix to GetType(), needs rewriting.
5120 * reflection.h, reflection.c: add fixup mechanism for field and method
5121 tokens. Initialize assembly->typeref in a single place. Output
5122 properties after events. Support custom attributes for events, too.
5123 Typo fix for paramter custom attrs.
5125 2002-03-07 Martin Baulig <martin@gnome.org>
5127 * icall.c (ves_icall_System_Array_FastCopy): Small fix.
5129 2002-03-07 Dietmar Maurer <dietmar@ximian.com>
5131 * class.c (mono_array_class_get): fix. for multi. dim. arrays
5133 2002-03-06 Martin Baulig <martin@gnome.org>
5135 * icall.c (ves_icall_System_Array_CreateInstanceImpl): Make this work with
5136 non-zero lower bounds. See testcases #F10-#F13.
5138 2002-03-05 Martin Baulig <martin@gnome.org>
5140 * exception.c (mono_get_exception_argument_out_of_range): New exception.
5142 * icall.c (ves_icall_System_Array_GetValue): Moved actual implementation to
5143 ves_icall_System_Array_GetValue(), only calculate the absolute array position
5145 (ves_icall_System_Array_SetValue): Likewise.
5146 (ves_icall_System_Array_GetValueImpl): New interncall. Takes an array position
5147 as argument and does the actual work. This function is used when copying a
5148 multi-dimensional array.
5149 (ves_icall_System_Array_SetValueImpl): Almost completely rewrote this. It can
5150 now do all the widening conversions of value types.
5151 (ves_icall_System_Array_CreateInstanceImpl): Implemented.
5153 Tue Mar 5 18:14:01 CET 2002 Paolo Molaro <lupus@ximian.com>
5155 * class.c: remove some magic numbers and use the smbolic names,
5156 instead. Added init_events() to load event info at class init time.
5157 * metadata.h, metadata.c: added mono_metadata_events_from_typedef()
5158 and mono_metadata_methods_from_event().
5159 * reflection.h, reflection.c: added support for writing out the evnets
5160 related information.
5162 Mon Mar 4 20:32:43 CET 2002 Paolo Molaro <lupus@ximian.com>
5164 * reflection.h, icall.c: use a different method (GetInterfaces)
5165 to gather interface info and add isbyref, isprimitive and
5166 ispointer to the ves_icall_get_type_info() return value.
5168 Mon Mar 4 11:22:26 CET 2002 Paolo Molaro <lupus@ximian.com>
5170 * class.h: stared adding support for events.
5171 * icall.c: split find_members implementation. Added debug icall to get
5172 the address of an object.
5173 * reflection.c: handle TypeBuilders in mono_type_get_object().
5175 2002-03-01 Martin Baulig <martin@gnome.org>
5177 * icall.c (ves_icall_System_Array_GetLength): This must throw an
5178 ArgumentOutOfRangeException(), not an ArgumentException().
5179 (ves_icall_System_Array_GetLowerBound): Likewise.
5180 (ves_icall_System_Array_GetValue): Improved argument checking.
5181 (ves_icall_System_Array_SetValue): Improved argument checking.
5183 2002-03-01 Martin Baulig <martin@gnome.org>
5185 * icall.c (ves_icall_System_Array_GetValue): Raise an exception when
5186 called with invalid arguments rather than just dying with g_assert().
5187 (ves_icall_System_Array_SetValue): Likewise.
5188 (ves_icall_System_Array_CreateInstanceImpl): Don't g_assert_not_reached(),
5189 raise a NotImplementedException instead.
5190 (ves_icall_System_Array_GetLength): Added argument checking.
5191 (ves_icall_System_Array_GetLowerBound): Added argument checking.
5193 2002-03-01 Dietmar Maurer <dietmar@ximian.com>
5195 * object.h (mono_assert): new macros mono_assert and
5196 mono_assert_not_reached
5198 2002-02-28 Martin Baulig <martin@gnome.org>
5200 * icall.c: Rename "System::String::Intern" to "System::String::_Intern"
5201 and "System::String::IsInterned" to "System::String::_IsInterned".
5203 Thu Feb 28 19:19:35 CET 2002 Paolo Molaro <lupus@ximian.com>
5205 * icall.c: remove hacks for typebuilder. Added icall to create a
5206 modified type from a tybebuilder.
5207 * reflection.c: removed hacks for TypeBuilder. Create also a MonoImage
5208 in mono_image_basic_init (). Added mono_reflection_setup_internal_class ()
5209 to create a backing MonoClass for a TypeBuilder.
5211 Thu Feb 28 15:35:51 CET 2002 Paolo Molaro <lupus@ximian.com>
5213 * class.c, class.h: more refactoring of class init.
5214 Export mono_class_setup_mono_type() and mono_class_setup_parent().
5216 Thu Feb 28 12:33:41 CET 2002 Paolo Molaro <lupus@ximian.com>
5218 * marshal.c, marshal.h: start of marshaling interface.
5220 Wed Feb 27 22:15:17 CET 2002 Paolo Molaro <lupus@ximian.com>
5222 * icall.c: fix order in assembly qualified name icall.
5224 Wed Feb 27 18:45:03 CET 2002 Paolo Molaro <lupus@ximian.com>
5226 * class.c: do not free str, since we store it in the hash table.
5227 * reflection.h: add label field to MonoILExceptionInfo.
5228 * reflection.c: handle references to more than one assembly. Handle
5229 case when there isn't a module created in the assembly.
5231 Wed Feb 27 12:35:10 CET 2002 Paolo Molaro <lupus@ximian.com>
5233 * class.c: Fix typo. Start refactoring of class init code.
5235 Wed Feb 27 12:23:00 CET 2002 Paolo Molaro <lupus@ximian.com>
5237 * appdomain.c: exit with 1 on error.
5238 * class.c: we already have the name in MonoClassField.
5239 * image.c, image.h, metadata.c, pedump.c: use directly a pointer in
5240 MonoStreamHeader instead of an offset of image->raw_metadata.
5242 2002-02-26 Miguel de Icaza <miguel@ximian.com>
5244 * appdomain.c (mono_init): Be even more descriptive about the error.
5246 Tue Feb 26 16:18:07 CET 2002 Paolo Molaro <lupus@ximian.com>
5248 * appdomain.c: give the user an informative message when corlib can't
5251 2002-02-26 Martin Baulig <martin@gnome.org>
5253 * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData):
5254 New icall to get the time zone data.
5256 Mon Feb 25 15:51:51 CET 2002 Paolo Molaro <lupus@ximian.com>
5258 * reflection.c: set virtual and raw size of section correctly.
5259 * threads.c: transfer domain information to newly created threads.
5261 Fri Feb 22 18:55:57 CET 2002 Paolo Molaro <lupus@ximian.com>
5263 * class.c: when instancing a class in a domain, load the default
5264 vaules for static fields from the constant table. Fix System.Enum to
5266 * icall.c: implement Object::GetType() internalcall. Implemented
5267 MonoField::GetValue() internalcall. Avoid SEGV in search_method().
5268 Fixed checking of binding flags in find_members().
5269 * metadata.c, metadata.h: introduce mono_metadata_type_hash().
5270 * reflection.c: handle enumerations when writing to the constant
5271 table. Use a different object cache for types.
5274 2002-02-22 Dietmar Maurer <dietmar@ximian.com>
5276 * object.c (mono_object_isinst): fix for arrays
5278 * icall.c (ves_icall_type_is_subtype_of): fix for 2 interfaces
5280 Thu Feb 21 21:00:13 CET 2002 Paolo Molaro <lupus@ximian.com>
5282 * object.c: don't use mprotect () and fix intern pool hash table
5283 lookup for big endian systems.
5285 Thu Feb 21 19:30:29 CET 2002 Paolo Molaro <lupus@ximian.com>
5287 * icall.c: change type_is_subtype_of () signature.
5289 2002-02-21 Mark Crichton <crichton@gimp.org>
5291 * rand.c, rand.h: Added random number generator for
5292 System.Security.Cryptography classes.
5294 * exception.c, exception.h: Added mono_get_exception_not_implemeted.
5296 * icall.c: Added System.Security.Cryptography calls.
5298 Thu Feb 21 16:45:34 CET 2002 Paolo Molaro <lupus@ximian.com>
5300 * class.c, icall.c, metadata.c: better support for pointer types.
5301 Create a class for them as suggested by dietmar. Fix TYPE_ARRAY class.
5302 * reflection.c: Add support for getting custom attrs for properties
5303 and simplify some code.
5305 Wed Feb 20 22:20:29 CET 2002 Paolo Molaro <lupus@ximian.com>
5307 * icall.c: change getToken () and add custom attribute GetBlob()helper
5309 * reflection.h: add custom attrs array to the reflection builder structures.
5310 * reflection.c: encode and emit custom attributes for all the relevant
5311 reflection objects. Cache fieldref and methodref tokens. Change
5312 mono_image_create_token() interface to take a MonoDynamicAssembly.
5313 More complete custom attributes decoder. Load custom attributes for
5314 Assembly, Field, Method and Constructor objects, too. Make the
5315 returned array an Attribute[] one, not object[]. Added
5316 mono_reflection_get_custom_attrs_blob() to encode the arguments of a
5317 custom attribute constructor.
5319 2002-02-20 Dick Porter <dick@ximian.com>
5323 * socket-io.c: Windows portability fixes (sometimes just ifdeffing
5324 problem code out for now).
5326 2002-02-19 Radek Doulik <rodo@ximian.com>
5328 * object.c (mono_ldstr): use hash table to avoid multiple swapping
5330 Tue Feb 19 20:23:11 CET 2002 Paolo Molaro <lupus@ximian.com>
5332 * icall.c: register the GetCustomAttributes method.
5333 * object.c, object.h: add mono_string_new_len ().
5334 * reflection.h, reflection.c: added mono_runtime_invoke(),
5335 mono_install_runtime_invoke(). Added
5336 mono_reflection_get_custom_attrs () to load custom attributes and
5337 create the attribute objects.
5339 2002-02-19 Dick Porter <dick@ximian.com>
5340 * threads-dummy-types.c:
5341 * threads-dummy-types.h:
5344 * threads-pthread-types.c:
5345 * threads-pthread-types.h:
5346 * threads-pthread.c:
5347 * threads-pthread.h: Deleted obsolete files
5349 2002-02-19 Dietmar Maurer <dietmar@ximian.com>
5351 * class.c (mono_class_vtable): runtime init the class when we
5352 allocate static class data.
5354 * icall.c (ves_icall_System_Array_SetValue): check for null values.
5356 * appdomain.c (mono_domain_transfer_object): impl. hack for Arrays
5357 and String - but we will need generic marshalling support in the
5359 (mono_init): set the domain name in a ms compatible way
5361 * object.c (mono_string_new_utf16): bug fix: use char[] instead of
5364 2002-02-18 Dietmar Maurer <dietmar@ximian.com>
5366 * object.c (mono_array_clone): use alloca() instead of g_malloc
5369 * appdomain.c (mono_domain_unload): impl.
5371 Mon Feb 18 15:52:20 CET 2002 Paolo Molaro <lupus@ximian.com>
5373 * appdomain.c, object.c: fix intern pool implementation.
5374 * class.c: fix alignment code.
5376 2002-02-16 Radek Doulik <rodo@ximian.com>
5378 * icall.c (ves_icall_System_Enum_ToObject): in case of big endian
5379 and s2 > s1, just copy lower bytes to be compatible with little
5380 endian (i.e. 64bit value & 0xffffffff --> 32bit value)
5381 (ves_icall_System_Enum_ToObject): and likewise for s1 > s2
5383 * unicode.c (ves_icall_iconv_new_encoder): decide on big_endian,
5384 force big_endian to be 1 for big endian machines
5385 (ves_icall_iconv_new_decoder): ditto
5387 2002-02-16 Jeffrey Stedfast <fejj@ximian.com>
5389 * socket-io.c (convert_sockopt_level_and_name): If the system
5390 doesn't define SOL_IP or SOL_TCP, get them by hand using
5391 getprotobyname() and caching the values (because this could be a
5393 (ves_icall_System_Net_Sockets_Socket_SetSocketOption_internal):
5394 Use the appropriate struct when the system does support it. Ie,
5395 not all systems have struct ip_mreqn so use struct ip_mreq when
5398 Fri Feb 15 18:15:44 CET 2002 Paolo Molaro <lupus@ximian.com>
5400 * reflection.c: handle finally clauses.
5402 Fri Feb 15 15:06:33 CET 2002 Paolo Molaro <lupus@ximian.com>
5404 * socket-io.c: use g_snprintf() instead of snprintf.
5406 2002-02-14 Jeffrey Stedfast <fejj@ximian.com>
5408 * reflection.c (mono_param_get_objects): Cast second argument to
5409 mono_method_get_param_names to a const char** to silence the
5412 * appdomain.c (mono_domain_assembly_open): Put parens around the
5413 truth statement in the for-loop.
5415 * unicode.c (iconv_convert): Got rid of a compiler warning about
5416 int i being unused when the system has a new iconv.
5417 (iconv_get_length): Same.
5419 * image.c (load_class_names): Cast the second argument to
5420 g_hash_table_insert() to char* to hush compiler warnings about the
5422 (mono_image_open): Same here.
5424 * socket-io.c: Don't conditionally include sys/filio.h or
5425 sys/sockio.h here anymore since we now get them from
5427 (inet_pton): If the system doesn't support inet_aton, implement
5428 using inet_addr and also #define INADDR_NONE if it isn't defined
5431 Thu Feb 14 19:01:06 CET 2002 Paolo Molaro <lupus@ximian.com>
5433 * metadata.c, metadata.h: added function to get packing and size info
5435 * reflection.h, reflection.c: handle field RVA data. Save info about
5436 the table layout if needed. Assign typedef indexes to all the types
5437 before dumping the info about them to avoid forward reference problems.
5439 2002-02-14 Dietmar Maurer <dietmar@ximian.com>
5441 * socket-io.c (convert_sockopt_level_and_name): ifdef
5442 SO_ACCEPTCONN because it is not defined on my system (old debian)
5444 Thu Feb 14 11:49:30 CET 2002 Paolo Molaro <lupus@ximian.com>
5446 * opcode.c: use stddef.h to get NULL.
5448 2002-02-14 Jeffrey Stedfast <fejj@ximian.com>
5450 * socket-io.c: conditionally include sys/filio.h and sys/sockio.h
5451 for FIONBIO, FIONREAD and SIOCATMARK.
5452 (ves_icall_System_Net_Dns_GetHostByAddr_internal): SunOS doesn't
5453 define INADDR_NONE and besides, inet_addr() is deprecated and
5454 should not be used. Use inet_pton() instead - it also has the
5455 added bonus that it can easily handle IPv6 addresses as well.
5456 (inet_pton): Implement using inet_aton() ifndef HAVE_INET_PTON.
5458 Wed Feb 13 23:00:21 CET 2002 Paolo Molaro <lupus@ximian.com>
5460 * decimal.c: remove _MSC_VER conditional.
5462 2002-02-13 Dick Porter <dick@ximian.com>
5465 * icall.c: Internal calls for Blocking, Select, Shutdown,
5466 GetSocketOption and SetSocketOption
5468 Wed Feb 13 19:20:01 CET 2002 Paolo Molaro <lupus@ximian.com>
5470 * assembly.cs: better resolver: use it instead of some kludgy
5473 Wed Feb 13 18:25:55 CET 2002 Paolo Molaro <lupus@ximian.com>
5475 * reflection.c: the best way to speed-up the compiler is to avoid
5478 2002-02-13 Dietmar Maurer <dietmar@ximian.com>
5480 * class.c (mono_class_vtable): changed the object layout
5481 (obj->vtable->class).
5482 (mono_class_create_from_typespec): consider MONO_TYPE_PTR
5484 Tue Feb 12 20:06:01 CET 2002 Paolo Molaro <lupus@ximian.com>
5486 * assembly.c: look for assemblies in the assembly dir, too.
5488 Tue Feb 12 14:03:42 CET 2002 Paolo Molaro <lupus@ximian.com>
5490 * class.c: fix thinko in mono_class_from_type().
5492 Mon Feb 11 19:43:51 CET 2002 Paolo Molaro <lupus@ximian.com>
5494 * exception.h, exception.c: added TypeLoadException.
5495 * object.h, object.c: added mono_array_clone ().
5496 * icall.c: handle throwOnError in AssemblyGetType().
5497 Added Array.Clone().
5498 * opcode.h, opcode.c: use a single value for the opcode val.
5499 Compile fix for non-gcc compilers.
5501 Fri Feb 8 12:26:37 CET 2002 Paolo Molaro <lupus@ximian.com>
5503 * opcodes.c, opcodes.h: export interesting info about opcodes.
5505 2002-02-05 Dietmar Maurer <dietmar@ximian.com>
5507 * object.h (MONO_CHECK_ARG, MONO_CHECK_ARG_NULL): new macro for
5510 * class.c (class_compute_field_layout): set element_class for enums
5511 (mono_class_create_from_typedef): set element_class for normal classes
5513 * icall.c (ves_icall_System_Enum_get_value): impl.
5515 * class.c (mono_class_create_from_typedef): do not set valuetype
5516 flag for System.ValueType and System.Enum
5518 2002-02-04 Dietmar Maurer <dietmar@ximian.com>
5520 * unicode.c (iconv_convert): fix big endian problem.
5522 Fri Feb 1 16:13:20 CET 2002 Paolo Molaro <lupus@ximian.com>
5524 * class.c: add asserts if we are ever going to scribble over memory.
5525 * socket-io.c: not all systems have AF_IRDA defined.
5527 2002-01-31 Dietmar Maurer <dietmar@ximian.com>
5529 * class.c (class_compute_field_layout): do not consider static
5530 fields to compute alignment
5532 2002-01-25 Dietmar Maurer <dietmar@ximian.com>
5534 * appdomain.c (mono_appdomain_get): impl.
5535 (ves_icall_System_AppDomain_ExecuteAssembly): impl.
5537 Thu Jan 24 12:59:23 CET 2002 Paolo Molaro <lupus@ximian.com>
5539 * icall.c: ignore "file://" prefix when loading an assembly.
5541 2002-01-23 Dick Porter <dick@ximian.com>
5545 * Makefile.am: Added socket support
5547 2002-01-23 Miguel de Icaza <miguel@ximian.com>
5549 * icall.c (ves_icall_appdomain_get_default_assemblies): put this
5550 code back. This should return the assemblies that are loaded by
5551 the runtime on behalf of an application domain.
5553 The current implementation is still broken, it just returns every
5554 assembly loaded, but until we get real applications domain this
5557 2002-01-23 Dietmar Maurer <dietmar@ximian.com>
5559 * icall.c (ves_icall_appdomain_get_cur_domain): runtime_init the
5562 2002-01-23 Miguel de Icaza <miguel@ximian.com>
5564 * icall.c (ves_icall_appdomain_get_cur_domain): Cache the value of
5565 the mono_class_from_name lookup.
5566 (ves_icall_get_parameter_info): ditto.
5567 (ves_icall_appdomain_get_assemblies, add_assembly): Implement new internal
5569 (ves_icall_System_Reflection_Assembly_get_code_base): Another new call.
5571 Tue Jan 22 22:43:47 CET 2002 Paolo Molaro <lupus@ximian.com>
5573 * class.c: load also nested classes on class init.
5574 System.ValueType instance methods gets passed boxed
5575 values, unless methods in derived classed that get a pointer to the
5577 * icall.c: use better name parsing code in GetType().
5578 * image.c, image.h: add mono_image_loaded ().
5579 * metadata.c, metadata.h: add mono_metadata_nesting_typedef ().
5580 * reflection.c, reflection.h: added mono_reflection_parse_type().
5582 2002-01-22 Veronica De Santis <veron78@interfree.it>
5584 * icall.c : Added mapping of internal calls for Manual and Auto reset events
5585 * threads.c : Added the implementation of internal calls for events
5586 * threads.h : Added prototypes of internal calls for events
5588 2002-01-21 Radek Doulik <rodo@ximian.com>
5590 * icall.c (ves_icall_InitializeArray): swap bytes on big endians
5592 2002-01-21 Dietmar Maurer <dietmar@ximian.com>
5594 * class.c (mono_class_init): set min_align to 1 (instead of 0)
5595 (mono_class_value_size): use min_align
5597 2002-01-20 Dick Porter <dick@ximian.com>
5600 * threads.c: Replaced all instances of WapiHandle * with HANDLE,
5601 so it compiles on w32.
5603 2002-01-17 Dietmar Maurer <dietmar@ximian.com>
5605 * metadata.c (mono_type_stack_size): impl.
5607 * class.c (mono_class_get_field): impl. memberref token
5609 2002-01-16 Veronica De Santis <veron78@@interfree.it>
5611 * icall.h : Added the internal calls mapping for CreateMutex_internal
5612 and ReleaseMutex_internal.
5613 * threads.h : Added the prototype of mutexes internal calls.
5614 * threads.c : Added the implementations of mutexes internal calls.
5616 Tue Jan 15 22:47:57 CET 2002 Paolo Molaro <lupus@ximian.com>
5618 * metaparse.h: removed unused file.
5619 * reflection.c, reflection.h: added stream_data_align () function
5620 to align data in streams and keep stream aligned. Add support for
5621 exception support in method headers.
5623 Tue Jan 15 19:42:50 CET 2002 Paolo Molaro <lupus@ximian.com>
5625 * unicode.c: make iconv_convert () return the number of bytess written
5626 in the output buffer.
5628 2002-01-15 Dick Porter <dick@ximian.com>
5629 * threads.c: Make the runtime's idea of infinite timeouts coincide
5630 with the class library's
5632 Fix a particularly egregious bug in mono_thread_cleanup(). That
5633 code was so utterly bogus it must have been written on a Monday.
5635 Mon Jan 14 17:01:03 CET 2002 Paolo Molaro <lupus@ximian.com>
5637 * reflection.h: add subtypes field to TypeBuilder.
5638 * reflection.c: encode constants for literal fields.
5639 Handle subtypes. Fix user string token (and add a zero byte)
5642 2002-01-14 Dietmar Maurer <dietmar@ximian.com>
5644 * class.c (mono_class_init): bug fix: assign slot numbers for
5647 Fri Jan 11 18:54:42 CET 2002 Paolo Molaro <lupus@ximian.com>
5649 * reflection.c: don't try to output a code RVA for abstract methods.
5650 Small fixes for method header format. Output parameter info to the
5651 ParamDef table. Save method overriding info to MethodImpl table.
5652 Fix property support. Allow typedef.extends to be a type in the
5654 * verify.c: fix off-by-one error.
5656 Thu Jan 10 19:36:27 CET 2002 Paolo Molaro <lupus@ximian.com>
5658 * class.c: fix mono_class_from_mono_type () for szarray types.
5659 Remove unused cache check in mono_class_from_type_spec().
5661 mono_method_get_object(), mono_field_get_object(): methods to return
5662 objects that parallel the C representation of assemblies, types,
5665 2001-12-11 Dick Porter <dick@ximian.com>
5668 * file-io.c: Internal calls for file IO.
5670 Thu Dec 6 16:21:30 CET 2001 Paolo Molaro <lupus@ximian.com>
5672 * tabledefs.h: missing FileAttributes.
5673 * verify.h, verify.c: use is_valid_string () to simplify and check for
5674 valid strings more correctly. Fix warnings and speeling.
5675 Check more tables: Filed, File, ModuleRef, StandAloneSig.
5676 Check code: branches, maxstack, method calls.
5678 2001-12-04 Dietmar Maurer <dietmar@ximian.com>
5680 * object.c (mono_object_allocate): removed static, so that the jit
5681 can allocate value types.
5683 * icall.c (ves_icall_System_DateTime_GetNow): impl.
5685 Mon Dec 3 17:02:01 CET 2001 Paolo Molaro <lupus@ximian.com>
5687 * class.c: init enum types right away and register the
5688 token->MonoClass map in mono_class_create_from_typedef ().
5689 * verify.h, verify.c: first cut of the verifier.
5690 * pedump.c: add --verify switch to verify metadata tables.
5691 * tabledefs.h: add some missing enums.
5693 2001-11-30 Dietmar Maurer <dietmar@ximian.com>
5695 * class.c (mono_install_runtime_class_init): impl.
5696 (mono_class_init): renamed mono_class_metadata_init to
5697 mono_class_init, also removed the metadata_inited flag
5699 * object.c (mono_object_isinst): use faster algorithm
5701 2001-11-30 Radek Doulik <rodo@ximian.com>
5703 * mono-endian.h: reverted last change
5704 added function prototypes
5706 * Makefile.am (libmetadata_a_SOURCES): reverted my last change and
5707 add mono-endian.c back
5709 * mono-endian.c: returned back, as Paolo pointed out, it's needed
5710 for unaligned access, I've mistaked it with endianess. I am
5712 (mono_read16): fix reverted endianess
5713 (mono_read64): ditto
5714 (mono_read32): ditto
5716 2001-11-30 Dick Porter <dick@ximian.com>
5718 * exception.c: Implement mono_exception_from_name()
5720 Fri Nov 30 12:01:02 CET 2001 Paolo Molaro <lupus@ximian.com>
5722 * metadata.h, metadata.c: remove params_size and locals_size and their
5723 calculation from the metadata code: they are only usefult to the
5726 2001-11-29 Radek Doulik <rodo@ximian.com>
5728 * object.c (mono_ldstr): swap bytes here, it's probably not the
5729 best place, but works for me now, I'll redo it once I know mono
5730 better, also note that I add PROT_WRITE and don't reset back, also
5731 note that it's only affects big endians, so x86 should be OK
5733 * mono-endian.h (read16): use just glib macros for both endians
5735 * mono-endian.c: removed as glib macros are used in in
5736 mono-endian.h so we don't need to care about endianess for read
5737 macros as glib does that for us already
5739 Thu Nov 29 18:20:58 CET 2001 Paolo Molaro <lupus@ximian.com>
5741 * class.h, class.h: take minimum alignment into consideration so
5742 that the fields of a class remain aligned also when in an array.
5744 Tue Nov 27 16:39:01 CET 2001 Paolo Molaro <lupus@ximian.com>
5746 * loader.h, loader.c: add mono_method_get_param_names().
5747 * class.c: 0-init class fields.
5749 2001-11-26 Dick Porter <dick@ximian.com>
5753 * threads.c: New file that handles System.Threading on all platforms
5756 * object.h: Remove the synchronisation struct from MonoObject,
5757 replace it with a pointer that gets initialised on demand
5759 * Makefile.am: Replace all the system-specific threading code with
5760 a single file that uses the new wrapper library
5762 Mon Nov 19 11:37:14 CET 2001 Paolo Molaro <lupus@ximian.com>
5764 * class.c, class.h: add mono_install_trampoline() so that the runtime
5765 can register a function to create a trampoline: removes the ugly
5766 requirement that a runtime needed to export arch_create_jit_trampoline.
5767 * object.h, object.c: added mono_install_handler() so that the runtime
5768 can install an handler for exceptions generated in C code (with
5769 mono_raise_exception()). Added C struct for System.Delegate.
5770 * pedump.c: removed arch_create_jit_trampoline.
5771 * reflection.c: some cleanups to allow registering user strings and
5772 later getting a token for methodrefs and fieldrefs before the assembly
5775 ves_icall_set_method_body (), ves_icall_type_from_handle ().
5776 * image.c: properly skip unknown streams.
5777 * loader.h, loader.c: add type_class to mono_defaults.
5778 * metadata.c, metadata.h: export compute_size () as
5779 mono_metadata_compute_size () with a better interface.
5781 * pedump.c: don't try to print the entry point RVA if there is no entry point.
5782 * reflection.c, reflection.h: many cleanups, fixes, output method
5783 signatures and headers, typedef and typeref info, compress the metadata
5784 tables, output all the heap streams, cli header etc.
5785 * row-indexes.h: typo fixes.
5787 2001-10-04 Dick Porter <dick@ximian.com>
5789 * object.h: Add a synchronisation mutex struct to MonoObject
5791 * object.c (mono_new_object): Initialise the object
5792 synchronisation mutexes
5794 * icall.c: System.Threading.Monitor internal calls
5796 * threads-pthread.h:
5797 * threads-pthread.c: System.Threading.Monitor internal calls
5799 * threads-types.h: New file, includes the system-specific thread
5802 * threads-pthread-types.h:
5803 * threads-pthread-types.c: New files, handle pthread-specific
5804 synchronisation types
5806 * threads-dummy-types.h:
5807 * threads-dummy-types.c: New files of dummy support for
5808 thread-specific types
5812 * pedump.c: include mono-endian.h not endian.h
5814 * Makefile.am: More threads files.
5815 Name mono-endian.h not endian.h
5817 Tue Oct 2 20:33:48 CEST 2001 Paolo Molaro <lupus@ximian.com>
5819 * Makefile.am, reflection.h, reflection.c: move here the reflection related
5820 stuff and implement a few more bits.
5821 * icall.c: a field needs to be dereferenced twice. Do not use the same
5822 name for two variables in the same scope.
5823 * image.c, image.h: cleanups.
5825 2001-10-02 Dietmar Maurer <dietmar@ximian.com>
5827 * class.c (mono_class_metadata_init): bug fix: compute the right size
5829 Mon Oct 1 20:43:57 CEST 2001 Paolo Molaro <lupus@ximian.com>
5831 * icall.c: implemented some of the Reflection internalcalls.
5832 * image.c, image.h: start writing out the PE/COFF image.
5833 * metadata.h, metadata.c: implement mono_metadata_encode_value ()
5834 that does the reverse than decode_blob_size ().
5835 * object.c: use mono_metadata_encode_value (). Move here
5836 temporary implementation of mono_string_to_utf8 ().
5837 * rawbuffer.c: make malloc_map static.
5839 Fri Sep 28 19:26:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
5841 * metadata.c: fix type comparison for arrays.
5842 * loader.h, loader.c: half-assed fix to get more tests work in cygwin.
5843 Added a couple of new classes to monodefaults.
5844 * icall.c: added a couple of Reflection-related internalcalls.
5845 * class.h, class.c: implemented mono_ldtoken () for RuntimeTypeHandles.
5846 Added a byval_arg MonoType to MonoClass.
5848 2001-09-28 Dick Porter <dick@ximian.com>
5851 * threads-pthread.h:
5852 * threads-pthread.c: Implemented internal calls for
5853 LocalDataStoreSlot operations. Applied mutexes around all shared
5854 data. Reworked the thread creation and Start() operations to
5855 avoid a race condition.
5858 * threads-dummy.c: Dummy calls for the LocalDataStoreSlot operations
5860 Thu Sep 27 21:45:55 CEST 2001 Paolo Molaro <lupus@ximian.com>
5862 * rawbuffer.c: disable mmap on cygwin since it seems to be broken there.
5864 Thu Sep 27 19:52:11 CEST 2001 Paolo Molaro <lupus@ximian.com>
5866 * class.c, loader.c: warn and return NULL instead of erroring out.
5867 * icall.c: added System.AppDomain::getCurDomain().
5868 * loader.c: we don't need to lookup the typedef again for p/invoke calls.
5870 2001-09-25 Dick Porter <dick@ximian.com>
5872 * threads-pthread.h:
5873 * threads-pthread.c: Implemented timed thread joining and added
5874 System.Threading.Thread::Join_internal internal call
5876 * icall.c: Added System.Threading.Thread::Join_internal internal call
5879 * threads-dummy.c: Dummy calls for System.Thread.Thread::Join_internal
5881 Mon Sep 24 18:56:59 CEST 2001 Paolo Molaro <lupus@ximian.com>
5883 * object.c, object.h: added mono_ldstr (), mono_string_is_interned () and
5884 mono_string_intern () to implement the semantics of the ldstr opcode
5885 and the interning of System.Strings.
5886 * icall.c: provide hooks to make String::IsIntern and String::Intern
5889 2001-09-23 Dick Porter <dick@ximian.com>
5892 * threads-dummy.h: New files of dummy threading routines
5894 * Makefile.am (THREAD_SOURCE): Arrange to compile different thread
5895 support code based on system specifics
5897 Rename PTHREAD_LIBS to THREAD_LIBS
5899 2001-09-23 Dick Porter <dick@ximian.com>
5901 * threads-pthread.c: Implement the System.Threading.Thread::Sleep,
5902 Schedule (called when asked to Sleep for 0 ms) and CurrentThread
5904 (mono_thread_init): Set up a Thread object instance to return when
5905 the main thread calls Thread.CurrentThread
5906 (mono_thread_cleanup): Wait for all subthreads to exit
5908 * icall.c: New internal calls for System.Threading.Thread::Sleep
5909 (including Schedule) and CurrentThread
5911 * threads.h: New file, to insulate thread-specific stuff from the
5914 2001-09-21 Dick Porter <dick@ximian.com>
5916 * threads-pthread.h:
5917 * threads-pthread.c: New file, for handling pthreads-style
5918 threading support. Start() now starts a new thread and executes
5919 the ThreadStart delegate instance.
5921 * icall.c: Added the internalcall for
5922 System.Threading.Thread::Start_internal
5924 * Makefile.am: Added new files, and PTHREADS_LIBS to the link line
5926 Thu Sep 20 19:37:39 CEST 2001 Paolo Molaro <lupus@ximian.com>
5928 * loader.c: work around the different signatures for delegates
5929 constructors csc generates in compiled code vs the ones compiled in mscorlib.
5931 Tue Sep 18 13:16:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
5933 * class.h, class.c: add mono_class_get_field_from_name ().
5934 * *: Fix C comments and other ANSI C issues.
5936 Mon Sep 10 20:21:34 CEST 2001 Paolo Molaro <lupus@ximian.com>
5938 * endian.h, assembly.c: fix some endianness issues.
5940 Fri Sep 7 18:40:40 CEST 2001 Paolo Molaro <lupus@ximian.com>
5942 * loader.h, load.c: add delegate_class to mono_defaults.
5943 Handle runtime provided methods in mono_get_method ().
5945 2001-08-29 Dietmar Maurer <dietmar@ximian.com>
5947 * loader.c (mono_get_method): use pinvoke for internal call
5949 * icall.c: use pinvoke for internal call
5951 * loader.c (method_from_memberref): set the method name
5953 Wed Aug 29 12:43:41 CEST 2001 Paolo Molaro <lupus@ximian.com>
5955 * metadata.c: help the compiler generate better code for
5956 mono_class_from_mono_type ().
5958 2001-08-28 Dietmar Maurer <dietmar@ximian.com>
5960 * class.c (mono_class_metadata_init): delayed computing of the
5961 class size to mono_class_metadata_init ()
5963 Tue Aug 28 15:47:15 CEST 2001 Paolo Molaro <lupus@ximian.com>
5965 * class.c, class.h: add an interfaces member to MonoClass.
5966 * image.c, image.h: add assembly_name field to MonoImage
5967 from the assembly table.
5968 * metadata.c, metadata.h: add mono_metadata_interfaces_from_typedef ().
5970 Mon Aug 27 20:12:01 CEST 2001 Paolo Molaro <lupus@ximian.com>
5972 * class.c: Handle Array in mono_class_from_mono_type ().
5973 * metadata.c, pedump.c: some endian fixes.
5975 Mon Aug 27 15:23:23 CEST 2001 Paolo Molaro <lupus@ximian.com>
5977 * class.c, loader.c, loader.h: More types handled in mono_class_from_mono_type ().
5978 * metadata.c: fix small problem introduced with the latest commit.
5980 Mon Aug 27 12:17:17 CEST 2001 Paolo Molaro <lupus@ximian.com>
5982 * loader.c, metadata.c, metadata.h: Export mono_metadata_type_equal().
5983 We don't need a MonoMetadata pointer anymore to compare signatures in
5984 mono_metadata_signature_equal (), update callers.
5985 Reduced memory usage an number of allocations for MonoMethodHeader and
5986 MonoMethodSignature.
5988 Sun Aug 26 23:03:09 CEST 2001 Paolo Molaro <lupus@ximian.com>
5990 * metadata.c: added compare for szarray.
5992 Sun Aug 26 11:34:24 CEST 2001 Paolo Molaro <lupus@ximian.com>
5994 * class.h, class.c, loader.h, loader.c: export mono_class_from_mono_type ()
5995 and add a couple more types to it and mono_defaults. Give an hint on
5996 classes that need implementing in our corlib and are referenced
5999 Sat Aug 25 12:52:54 CEST 2001 Paolo Molaro <lupus@ximian.com>
6001 * class.h, class.c: keep track if a class is also an Enum.
6002 * loader.c: Implement a couple more types for use in libffi
6003 marshalling. Gives better diagnostics when failing to dlopen
6004 a library. Set method->klass for P/Invoke methods, too.
6006 Fri Aug 24 19:30:25 CEST 2001 Paolo Molaro <lupus@ximian.com>
6008 * class.c, class.h: add a MonoType this_arg to MonoClass that
6009 represents a pointer to an object of the class' type that
6010 can be used by the interpreter and later the type cache.
6011 Add best guess alignment info for valuetype objects.
6013 Fri Aug 24 15:50:31 CEST 2001 Paolo Molaro <lupus@ximian.com>
6015 * metadata.h, metadata.c, class.h, class.c: squeezed MonoParam
6016 into MonoType: one less level of indirection and allocation and
6017 simplifies quite a bit of code. Added cache for MonoTypes that are
6018 used frequently, so that we don't need to allocate them all the time.
6020 2001-08-24 Dietmar Maurer <dietmar@ximian.com>
6022 * class.c (mono_class_create_from_typedef): System.Enum is also a
6023 value type, although it does not derive from System.ValueType
6024 (maybe a bug in the ms compiler?)
6026 * metadata.c (mono_type_size): return the right size for value types
6028 * loader.c (mono_get_method): only initialize method header if not abstract
6030 * class.c (mono_class_from_mono_type): use mono_default values.
6032 2001-08-23 Dietmar Maurer <dietmar@ximian.com>
6034 * *: use MonoClass pointers instead of <type_tokens>
6036 * class.h: new flag: metadata_inited.
6038 * class.c (mono_class_metadata_init): impl.
6039 (mono_class_instance_size): impl.
6040 (mono_class_data_size): impl.
6042 Wed Aug 22 16:27:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
6044 * metadata.c, loader.h, loader.c, image.h, image.c, class.h, class.c:
6045 MonoClass now has the name and name_space fields.
6046 MonoMethod has a pointer to its MonoClass, instead of MonoImage.
6047 mono_get_method () takes and optional MonoClass as argument.
6048 Removed mono_typedef_from_name() and added mono_class_token_from_name()
6049 instead that takes advantage of a map from class names to typedef
6050 tokens in MonoImage.
6052 Tue Aug 21 18:54:58 CEST 2001 Paolo Molaro <lupus@ximian.com>
6054 * metadata.c: zero is not a valid alignment boundary.
6055 Merge MONO_TYPE_VOID in default decoding code.
6057 2001-08-21 Dietmar Maurer <dietmar@ximian.com>
6059 * image.h: merged MonoMetadata into MonoImage
6061 * class.h: cleanup of MonoArrayClass, use a MonoClass pointer to
6062 identify the type of elements.
6064 Mon Aug 20 19:39:00 CEST 2001 Paolo Molaro <lupus@ximian.com>
6066 * blob.h: fix MONO_TYPE_TYPEDBYREF value.
6067 * cil-coff.h: split MonoMSDOSHeader and add size info.
6068 * image.c: add some consistency checks.
6069 * metadata.c: fix row size computation: one programmer
6070 error and one LAMESPEC. Handle MONO_TYPE_TYPEDBYREF.
6071 add explanation for the locator routine.
6072 Fix decoding of size in method header.
6074 2001-08-20 Miguel de Icaza <miguel@ximian.com>
6076 * assembly.c (g_concat_dir_and_file): Use _S for string concat.
6077 (g_concat_dir_and_file): Bring g_concat_dir_and_file
6078 function from gnome-libs. This uses the right path separator
6079 based on the OS, and also works around a bug in some systems where
6080 a double slash is not allowed.
6081 (default_assembly_name_resolver): Use g_concat_dir_and_file
6082 (mono_assembly_open): ditto.
6084 2001-08-20 Dietmar Maurer <dietmar@ximian.com>
6086 * metadata.c (mono_metadata_signature_equal): impl.
6088 * *: void is now a realy MonoType (instead of using NULL)
6090 * metadata.c (do_mono_metadata_parse_type): use
6091 mono_metadata_parse_type to parse void value.
6093 Sat Aug 18 12:51:28 CEST 2001 Paolo Molaro <lupus@ximian.com>
6095 * metadata.c, metadata.h: in the signature and method header store
6096 only the space required for holding the loca vars and incoming arguments.
6098 2001-08-15 Dietmar Maurer <dietmar@ximian.com>
6100 * metadata.c (do_mono_metadata_parse_type): treat void like any
6101 other type (instead of assigning NULL);
6103 2001-08-14 Dietmar Maurer <dietmar@ximian.com>
6105 * metadata.c (mono_metadata_parse_mh): fixxed pinned/byref value
6107 2001-08-09 Dietmar Maurer <dietmar@ximian.com>
6109 * image.c (do_mono_image_open): added a cache for arrays.
6111 Sat Aug 4 12:46:02 CEST 2001 Paolo Molaro <lupus@ximian.com>
6113 * metadata.h, metadata.c: add mono_metadata_decode_row_col () to
6114 decode a single column from a row in a metadata table and change
6115 index in mono_metadata_locate(). Implement mono_get_method () to retreive
6116 all the info about a method signature and invocation. Remove check on
6117 uninitialized local var in parse_mh() and fix memory leak.
6119 2001-07-12 Miguel de Icaza <miguel@ximian.com>
6121 * metadata.h: More macros.
6123 * tokentype.h: New file.
6125 Fri Jul 6 11:30:53 CEST 2001 Paolo Molaro <lupus@ximian.com>
6127 * assembly.c: added a consistency check and initialize
6128 some structures with g_new0().
6129 * metadata.c: fixed a couple more bugs in table size computation
6130 and add other checks for out-of bound access to metadata.
6132 Thu Jul 5 22:34:21 CEST 2001 Paolo Molaro <lupus@ximian.com>
6134 * metatada.c: fix bugs computing table sizes. Spew a
6135 warning when index in string heap is out of bounds.
6137 2001-07-04 Miguel de Icaza <miguel@ximian.com>
6139 * metadata.h: Add a couple of macros to manipulate tokens.
6141 Tue Jul 3 18:33:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
6143 * assembly.c: g_free(ii->cli_sections) (and avoid double free of
6144 cli_section_tables).
6146 2001-07-01 Miguel de Icaza <miguel@ximian.com>
6148 * metadata.c (mono_metadata_user_string): New function, provides
6149 access to the UserString heap.
6151 2001-06-27 Miguel de Icaza <miguel@ximian.com>
6153 * metadata.c: Add inline documentation.
6155 2001-06-26 Miguel de Icaza <miguel@ximian.com>
6157 * propertyattr.h, paramattr.h, methodsem.h, methodattr.h: New
6160 2001-06-22 Miguel de Icaza <miguel@ximian.com>
6162 * typeattr.h: New file, TypeAttribute flags.
6164 2001-06-21 Miguel de Icaza <miguel@ximian.com>
6166 * mono/metadata/assembly.c (mono_assembly_ensure_section_idx,
6167 mono_assembly_ensure_section): Section loading code.
6168 (load_section_tables): Load the sections.
6170 * mono/metadata/metadata.c (mono_metadata_locate_token,
6171 mono_metadata_locate): Functions to locate the information
6172 definition given a token or a table and an index.
6173 (mono_metadata_compute_table_bases): New.
6174 (compute_size): New function to compute the sizes of the various
6177 * mono/metadata/metadata.h: Finish listing the different index
6180 * mono/metadata/pedump.c: Improve to dump new information.
6182 2001-06-19 Miguel de Icaza <miguel@ximian.com>
6184 * mono/metadata/metadata.c: Entered all the tables matching
6187 * mono/metadata/assembly.c (load_metadata_ptrs): Fix for Beta2