1 2002-05-13 Dan Lewis <dihlewis@yahoo.co.uk>
3 * icall.c: fix bug in GetNow().
5 2002-05-11 Dietmar Maurer <dietmar@ximian.com>
7 * object.c (mono_runtime_class_init): make sure that we call all
8 static class constructors.
10 Fri May 10 18:14:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
12 * reflection.c: sort methodsemantics table.
14 Fri May 10 16:31:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
16 * reflection.h, reflection.c: honour init locals setting.
18 Thu May 9 18:50:00 EDT 2002 Daniel Morgan <danmorg@sc.rr.com>
20 * icall.c: copied Double ToStringImpl for Single ToStringImpl
22 Wed May 8 12:28:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
24 * reflection.c: support ContructorBuilders in attribute blob creation.
26 Wed May 8 12:06:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
28 * reflection.c: some changes to build a binary that can be run
31 Mon May 6 13:10:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
33 * loader.c: print a big message when an icall can't be found.
35 2002-05-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
37 * string-icalls.c: fix bug 24248.
39 Sat May 4 14:03:21 CEST 2002 Paolo Molaro <lupus@ximian.com>
41 * appdomain.c, appdomain.h, assembly.c, assembly.h, image.h,
42 icall.c, reflection.h: separate assembly loading by pathname and by
43 assembly name. Use the MONO_PATH env var to search for assemblies.
45 Thu May 2 17:56:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
47 * assembly.c, image.h: add some support for assemblies
48 with multiple modules.
49 * class.c, class.h: export mono_class_from_typeref().
50 * loader.c: remove duplicated code and use mono_class_from_typeref(),
53 Thu May 2 15:51:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
55 * unicode.c: Char.IsNumber doesn't include hex digits as the ms
56 documentation says (the ECMA one is correct).
58 2002-05-02 Dick Porter <dick@ximian.com>
60 * threads.c: Use GC_debug_register_finalizer with GC_debug_malloc.
61 Don't name the synchronisation mutex.
63 2002-04-30 Jeffrey Stedfast <fejj@ximian.com>
66 (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_GetBytes):
67 Make the prototypes match.
68 (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_GetNonZeroBytes):
72 (ves_icall_System_CurrentTimeZone_GetTimeZoneData): Fixed for
73 systems that use 'timezone' rather than tm.tm_gmtoff. Also, not
74 all systems have tm.tm_zone, so use strftime() with %Z to print
75 the timezone abreviation into a temp string.
77 * object.c (mono_ldstr): Fixed to use mono_string_chars() macro
78 rather than mono_array_addr() on a MonoString on Big Endian
81 2002-04-30 Dietmar Maurer <dietmar@ximian.com>
83 * string-icalls.c (ves_icall_System_String_InternalReplace_Str):
86 2002-04-30 Dick Porter <dick@ximian.com>
88 * socket-io.c: Cope with SOCKET being an integer rather than a
91 * threads.c: Added Thread_free_internal, to deal with thread
92 handle cleanup. Moved calls to handle_store() and handle_remove()
93 to start_wrapper(), so each can only be called once. Allocate
94 synchronisation blocks with GC_malloc(), and use GC finalisation
97 * icall.c: added System.Threading.Thread::Thread_free_internal
99 Mon Apr 29 15:33:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
101 * icall.c: support Environment.Exit, CommandLineArgs().
103 Mon Apr 29 15:15:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
105 * object.c, object.h: added mono_runtime_run_main () and
106 mono_runtime_get_main_args () for use in System.Environment.
108 Mon Apr 29 13:45:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
110 * gc.c: fix thinko, enable actual finalization since the jit is now
113 Mon Apr 29 12:47:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
115 * gc.c, object.c: take into account that an object may be offset wrt the address
116 returned by GC_malloc().
118 Mon Apr 29 12:14:39 CEST 2002 Paolo Molaro <lupus@ximian.com>
120 * image.c: handle files without entries in the assembly table (modules).
122 2002-04-28 Patrik Torstensson <patrik.torstensson@intel.com>
124 * reflection.c (mono_reflection_setup_internal_class): remove g_assert_not_reached() to allow
125 mcs selfhosting again (build breaker) and did move the check to class instead. parent is
126 allowed to be null when it's System.Object class setup.
128 2002-04-27 Martin Baulig <martin@gnome.org>
130 * reflection.c (mono_reflection_setup_internal_class): g_assert_not_reached()
131 if `tb->parent == NULL' rather than crashing.
133 2002-04-28 Nick Drochak <ndrochak@gol.com>
135 * sysmath.c (ves_icall_System_Math_Asin): Fix copy-paste error. Was
136 calling acos() where asin() should have been called.
138 2002-04-26 Martin Baulig <martin@gnome.org>
140 * assembly.c (default_assembly_name_resolver): Use G_FILE_TEST_IS_REGULAR
141 instead of G_FILE_TEST_EXISTS - if you're in mcs/class/corlib/System/Test,
142 there's a subdirectory called `System', but we don't want to read that
143 subdirectory as an assembly.
145 2002-04-25 Martin Baulig <martin@gnome.org>
147 * debug-symfile.c: Reflect latest MonoString changes.
149 Thu Apr 25 16:38:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
151 * rand.c, rand.h: instance method icalls need to have an explicit
152 this pointer as first argument in the C implementation.
154 2002-04-25 Nick Drochak <ndrochak@gol.com>
156 * icall.c: Fix typo in map for GetNonZeroBytes
158 2002-04-24 Patrik Torstensson <patrik.torstensson@labs2.com>
160 * string-icalls.c : String does now passes unit tests without any
161 errors, the following changes has been made:
163 Implemented replace methods.
164 Renaming of methods to (try) follow the standard.
165 Fixed compare ordinal
166 Made all memory allocated directly to function instead of via icall function.
167 Small performance fix in is_in_array function
169 (2002-04-23) Changes from Duncan Mak <duncan@ximian.com>
171 c (mono_string_Internal_ctor_charp_int_int):
172 (mono_string_Internal_ctor_sbytep_int_int): Removed check for
173 sindex < 0, throw ArgumentOutOfRangeException instead of
174 ArgumentNullException.
176 Added new check for length == 0, however
177 I need to make it return String.Empty from the C code.
179 (mono_string_Internal_ctor_sbytep): Use mono_string_new, and let
180 that calculate the length for us here.
182 (mono_string_Internal_ctor_sbytep_int_int): Replaced
183 mono_string_new_utf16 with mono_string_new, since value is utf8.
185 Wed Apr 24 18:43:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
187 * object.c: register the object for finalization if needed.
188 Allocate one more char in the string for the terminating 0 char.
190 Wed Apr 24 18:22:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
192 * class.c, class.h, image.c: check if a type implemenst a destructor.
193 Use the proper key for array class lookups.
194 * icall.c: register the icalls in the System.GC class.
195 * gc.c, gc.h: GC-related functions and icalls.
197 2002-04-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
201 * unicode.c: free some strings gotten from mono_string_to_utf8 and
202 changed a couple of free () by g_free ().
204 * decimal.c: one-liner in the comments for decimal2string ().
206 2002-04-24 Patrik Torstensson <patrik.torstensson@labs2.com>
208 * object.c (mono_runtime_invoke_array) : Bug because of my incompetence.
210 2002-04-24 Patrik Torstensson <patrik.torstensson@labs2.com>
212 * reflection.c (mono_reflection_get_custom_attrs) : fixed image bug (crash)
213 * object.c (mono_runtime_invoke_array) : handle null in params
215 2002-04-23 Patrik Torstensson <patrik.torstensson@labs2.com>
217 * string-icalls.c: fixed bug in split (one off bug)
219 2002-04-23 Patrik Torstensson <patrik.torstensson@labs2.com>
221 * string-icalls.c: fixed bug in remove and lastindexofany, add equals icall.
222 * icalls.c: added String::Equals as internal method
224 2002-04-23 Patrik Torstensson <patrik.torstensson@labs2.com>
226 * threads.c: fixed bug in the double interlocked functions
228 2002-04-22 Patrik Torstensson <patrik.torstensson@labs2.com>
230 * threads.c: implemented all of the new interlocked icalls.
231 * string-icalls.c: fix a bug in insert.
232 * icalls.c: added the icalls for interlocked, removed old string functions.
234 Mon Apr 22 19:44:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
236 * loader.c: fix off-by-one error when reading argument names.
238 Mon Apr 22 19:28:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
240 * profiler.c: win32 counter implementation (untested).
241 * icall.cs: win32 GetNow() and GetTimeZoneData() implementations
242 (the latter needs testing and more complete impl. from win32 folks).
244 2002-04-21 Dan Lewis <dihlewis@yahoo.co.uk>
246 * object.c: mono_array_new_full workaround mono_array_class_get
249 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
251 * string-icalls.c (mono_string_InternalRemove): Fixed overwrite bug.
252 * object.h (mono_string_chars): Changed casting type.
254 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
256 * string-icalls.c: Fixed trim method, added the constructors done by Duncan, fixed
257 method signatures to use gunichar2 instead of gint16.
259 2002-04-20 Dan Lewis <dihlewis@yahoo.co.uk>
261 * object.h, object.c: domain-specific versions of mono_object_new and
264 2002-04-20 Dietmar Maurer <dietmar@ximian.com>
266 * object.c: changed String layout
268 * string-icalls.c (mono_string_Internal_ctor_chara): added
269 internal string constructors.
271 Sat Apr 20 13:33:07 CEST 2002 Paolo Molaro <lupus@ximian.com>
273 * threads.c: pass 'this' to the thread start routine.
275 2002-04-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
277 * string-icalls.c: fix IndexOf and LastIndexOf. Now
278 InternalCompareStr don't call twice mono_string_cmp_char for the last
279 character. Improved performance in mono_string_cmp_char.
281 Fri Apr 19 19:26:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
283 * Makefile.am, appdomain.c, class.c, object.c: split runtime-depended
284 code into its own library: libmonoruntime.
286 2002-04-19 Dan Lewis <dihlewis@yahoo.co.uk>
288 * object.h, object.c: changed array format so that szarrays do not
289 require a bounds structure.
290 * icall.c, appdomain.c: support for new szarray format.
292 Fri Apr 19 18:04:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
294 * metadata.c: compare also the retuns type when comparing signatures:
295 we didn't do this as an optimization since really overloaded methods
296 must differ also in the arguments, but this doesn't work with
297 low-level IL code (or when using explicit conversion operators: see
298 bug#23498 for an example).
300 Fri Apr 19 16:14:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
302 * loader.c: SZARRAY types can be saved as TYPESPEC, too.
304 Thu Apr 18 17:15:09 CEST 2002 Paolo Molaro <lupus@ximian.com>
306 * icall.c: make MonoType::GetElementType its own icall.
308 Thu Apr 18 16:41:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
310 * icall.c: remove MonoMethod_get_Name().
311 * reflection.c, reflection.h, verify: cache the method name in the MonoMethod
314 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
316 * string-icalls.c: optimized a few methods.
318 2002-04-17 Patrik Torstensson <patrik.torstensson@labs2.com>
320 * icall.c: added all new string internal calls
321 * string-icalls.c: added, new string internal call implementation.
322 * object.c: added mono_string_new_size for allocating a string a size
324 2002-04-17 Dietmar Maurer <dietmar@ximian.com>
326 * object.c (mono_object_isinst): use the same code as in the
327 optimized x86 version.
329 Wed Apr 17 14:14:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
331 * profiler.c: TSC-based timer code (faster and more accurate).
332 Not hooked up in configure, yet (set USE_X86TSC to 1).
334 Wed Apr 17 12:33:10 CEST 2002 Paolo Molaro <lupus@ximian.com>
336 * profiler.c, profiler.h: track time spent compiling methods.
337 * threads.c: track thread creation/destruction.
339 Tue Apr 16 20:08:43 CEST 2002 Paolo Molaro <lupus@ximian.com>
341 * profiler.c, profiler.h, profiler-private.h: profiling interface
342 and sample implementation. Moved here so that it can be used also by
345 Tue Apr 16 12:58:12 CEST 2002 Paolo Molaro <lupus@ximian.com>
347 * reflection.c, reflection.h: keep types and other handles separate in
348 the hash tables for referred tokens. Add guid for modules.
350 Mon Apr 15 11:37:33 CEST 2002 Paolo Molaro <lupus@ximian.com>
352 * assembly.c: fix bugs found with valgrind.
353 * metadata.h, metadata.c: added mono_metadata_guid_heap().
355 2002-04-14 Patrik Torstensson <patrik.torstensson@labs2.com>
357 * threads: added icall support for getting current domain for
360 2002-04-13 Martin Baulig <martin@gnome.org>
362 * debug-symfile.h (MonoDebugLocalInfo): Renamed to MonoDebugVarInfo.
363 (MonoDebugVarInfo): Added `index' field for register based addresses.
364 (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 9.
365 (MonoDebugMethodInfo): Replaced `guint32 *param_offsets' with
366 `MonoDebugVarInfo *params' and `guint32 this_offset' with
367 `MonoDebugVarInfo *this_var'.
369 * debug-symfile.c (relocate_variable): New static function to write
370 a location description for a local variable or method parameter.
372 2002-04-12 Martin Baulig <martin@gnome.org>
374 * debug-symfile.h (MonoDebugLocalInfo): New type. This contains the
375 stack offset and begin/end scope address of a local variable.
376 (MonoDebugMethodInfo): Replaced `guint32 *local_offsets' with
377 'MonoDebugLocalInfo *locals', added `prologue_end' and `epilogue_begin'.
378 (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 8.
380 * debug-symfile.c (MRT_variable_start_scope, MRT_variable_end_scope):
381 Added new relocation types for start/end scope of a local variable.
383 Fri Apr 12 18:30:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
385 * object.h: add mono_object_domain() macro.
386 * reflection.c: handle typespecs.
387 * icall.c: MonoMethod::get_Name() implementation.
389 Thu Apr 11 12:29Ni:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
391 * icall.c: String::GetHashCode() icall implementation.
393 Wed Apr 10 21:16:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
395 * icall.c: String::IndexOfAny icall.
396 * object.c, object.h: make array->max_length more useful.
397 Intrduced mono_object_class() and mono_string_length() macros.
399 2002-04-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
401 * unicode.c (ves_icall_System_Char_IsNumber): use g_unichar_isxdigit
402 instead of g_unichar_isdigit.
404 2002-04-11 Nick Drochak <ndrochak@gol.com>
406 * icall.c: Implement a simple Double.ToString().
408 Tue Apr 9 21:31:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
410 * appdomain.h: only io-layer.h is supposed to be included.
411 * icall.c: explicitly import environ. Fix warning.
413 2002-04-10 Nick Drochak <ndrochak@gol.com>
415 * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData) :
416 return true even if it's not Daylight Savings time.
417 Only return false for the case where the function isn't
418 implemented for a plaform (read Windows).
420 Tue Apr 9 13:05:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
422 * appdomain.h, appdomain.c, class.c, object.c: protect MonoDomain
425 2002-04-09 Dietmar Maurer <dietmar@ximian.com>
427 * mempool.c (mono_mempool_alloc): only use g_malloc when
428 absolutely necessary.
430 2002-04-08 Dietmar Maurer <dietmar@ximian.com>
432 * mempool.c (MEM_ALIGN): hardcode MEM_ALIGN to 8
434 * class.c (mono_class_vtable): use domain mempool to allocate vtable
435 (mono_class_proxy_vtable): use domain mempool
437 Mon Apr 8 17:17:04 CEST 2002 Paolo Molaro <lupus@ximian.com>
439 * appdomain.h, appdomain.c: split initialization that requires the
440 execution engine support into mono_runtime_init().
442 2002-04-08 Dietmar Maurer <dietmar@ximian.com>
444 * class.c (mono_class_init): don't include vtable inside MonoClass
445 to save some memory, gather some statistics.
446 (mono_class_vtable): use g_malloc instead of GC_malloc when possible
448 Sat Apr 6 20:07:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
450 * icall.c: internalcall implementation for ValueType.Equals().
452 2002-04-06 Dietmar Maurer <dietmar@ximian.com>
454 * object.c (mono_message_init): moved
455 (mono_runtime_exec_main): new arch. independent impl.
456 (mono_runtime_invoke_array): new method - like
457 mono_runtime_invoke, but you can pass an array of objects.
458 (mono_remoting_invoke): new arch. independent impl.
459 (mono_message_invoke): new arch. independent impl.
460 (mono_runtime_class_init): new arch. independent impl.
461 (mono_runtime_object_init): new arch. independent impl.
463 Fri Apr 5 18:29:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
465 * metadata.c, object.c, reflection.c: documented the exported
468 Fri Apr 5 15:42:31 CEST 2002 Paolo Molaro <lupus@ximian.com>
470 * icall.c: simpler code to pass the assembly builder data to corlib.
471 Implement GetNestedTypes() internalcall.
473 Thu Apr 4 21:46:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
475 * class.c: warn if a type can't be loaded.
477 2002-04-04 Dietmar Maurer <dietmar@ximian.com>
479 * image.h: typedef MonoImageOpenStatus
480 * types.h: removed unused file
482 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
484 * icall.c: Enum_ToObject accepts enum value arguments.
486 Thu Apr 4 11:35:37 CEST 2002 Paolo Molaro <lupus@ximian.com>
488 * class.c: move initialization of properties, events and nested
489 classes, so that they happen for interfaces, too.
491 Wed Apr 3 20:03:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
493 * icall.c: cleanup some ugly casts in Array_SetValue*.
495 Wed Apr 3 19:49:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
497 * icall.c: the values array fro enums is of the correct type, now.
498 Implement (correctly) getFullName instead of assQualifiedName for
500 * reflection.h, reflection.c: added mono_type_get_name ().
502 Wed Apr 3 17:56:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
504 * assembly.c, image.h: for each MonoImage, record from wich assembly
506 * reflection.h, icall.c: added System_Reflection_Assembly_GetTypes().
507 Make Type.Assembly work.
509 2002-04-03 Dietmar Maurer <dietmar@ximian.com>
511 * debug-symfile.h: use char* instead of gpointer to avoid
514 * appdomain.c (mono_jit_info_table_find): use char* instead of gpointer
516 * icall.c (ves_icall_InternalExecute): impl. FielSetter
517 (ves_icall_System_Array_SetValueImpl): removed strange MonoArray cast
519 2002-03-30 Dietmar Maurer <dietmar@ximian.com>
521 * icall.c (mono_message_init): impl. (code cleanup)
522 (ves_icall_InternalExecute): impl. FieldGetter
524 * class.c (mono_class_init): added exerimental EXT_VTABLE_HACK, if
525 defined we call all (non-static)methods through the vtable.
527 Fri Mar 29 18:09:08 CET 2002 Paolo Molaro <lupus@ximian.com>
529 * class.c: it seems GC_debug_malloc() makes the Boehm GC call the
530 finalizer even though the memory is still referenced (and the chunk of
531 memory is not freed).
533 Fri Mar 29 17:43:04 CET 2002 Paolo Molaro <lupus@ximian.com>
535 * assembly.c: fix brokeness.
537 Fri Mar 29 16:09:54 CET 2002 Paolo Molaro <lupus@ximian.com>
539 * class.c: kill some warnings. Check explicit interface method
540 implementation also without considering the namespace.
541 Load also literal strings in static class data.
543 2002-03-29 Miguel de Icaza <miguel@ximian.com>
545 * assembly.c (default_assembly_name_resolver): Kill memory leak.
546 (default_assembly_name_resolver): Make the resolver take the
547 "base" directory where the assembly was originally defined, so we
548 can load DLLs that are in the same directory as the assembly that
551 2002-03-28 Dick Porter <dick@ximian.com>
557 * unicode.c: Warning cleanups
559 Thu Mar 28 18:06:14 CET 2002 Paolo Molaro <lupus@ximian.com>
561 * object.h, reflection.h: use the correct type instead of MonoObject.
563 2002-03-28 Martin Baulig <martin@gnome.org>
565 * debug-symfile.c (mono_debug_class_get): Don't look in referenced assemblies.
566 (mono_debug_update_symbol_file): Initialize classes if necessary.
568 Thu Mar 28 15:58:43 CET 2002 Paolo Molaro <lupus@ximian.com>
570 * assembly.c, debug-helpers.c, image.c, image.h, metadata.c, pedump.c,
571 rawbuffer.c, reflection.c, verify.c: mare warning cleanups.
573 Thu Mar 28 15:20:39 CET 2002 Paolo Molaro <lupus@ximian.com>
575 * assembly.h: fix function prototype.
576 * metadata.h, metadata.c, object.h, private.h: get rid of warnings.
577 * mono-endian.h: use const cast.
579 2002-03-28 Dietmar Maurer <dietmar@ximian.com>
581 * icall.c (ves_icall_MonoMethodMessage_InitMessage): moved from message.c
583 Thu Mar 28 12:32:00 CET 2002 Paolo Molaro <lupus@ximian.com>
585 * loader.c: don't assert when a typeref can't be loaded, give
586 a chance to the runtime to trow an exception instead.
587 * loader.h: fix warning.
589 2002-03-28 Dietmar Maurer <dietmar@ximian.com>
591 * class.c (mono_class_proxy_vtable): added proxy support
593 2002-03-27 Dan Lewis <dihlewis@yahoo.co.uk>
595 * icall.c: removed last of PAL calls, added System.Environment
596 * file-io.h, file-io.c: MonoIO implementation
597 * object.h, object.c: mono_string_to_utf16() now returns gunichar2*
599 Tue Mar 26 19:56:10 CET 2002 Paolo Molaro <lupus@ximian.com>
601 * appdomain.c: do not use the byte marker in ldstr table lookup.
602 * debug-helpers.c: allow two ':' to separate class and method name.
603 * object.c: allocate arrays bounds with the GC, too.
604 * verify: add a few more checks.
606 Tue Mar 26 18:45:46 CET 2002 Paolo Molaro <lupus@ximian.com>
608 * reflection.c: output also literal strings. Allocate parameter data
609 with GC_malloc() (thanks, Martin, for catching this!).
611 2002-03-26 Martin Baulig <martin@gnome.org>
613 * debug-symfile.h (MonoDebugMethodInfo): Added `this_offset', don't
614 include the `this' offset in the `param_offsets'.
616 2002-03-25 Martin Baulig <martin@gnome.org>
618 * debug-symfile.c (mono_debug_update_symbol_file): Use a new
619 mono_debug_get_class() function to get the classes. Added new
620 relocation types for arrays and strings.
621 (mono_debug_get_class): New static function to search in all
622 referenced assemblies for a metadata token.
624 * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 7.
626 Mon Mar 25 13:08:18 CET 2002 Paolo Molaro <lupus@ximian.com>
628 * reflection.h, reflection.c: use a gc-safe hash for hash tables that
629 hold gc-allocated objects. Make the string heap a stream like the
630 others. Removed duplicated code when writing stream info.
631 Added asserts to catch possible buffer overflows. Set the sorted map
632 for tables that need sorting. Added some documentation.
634 Mon Mar 25 13:04:56 CET 2002 Paolo Molaro <lupus@ximian.com>
636 * appdomain.h, appdomain.c, class.c, object.c: use a GC-safe hash table
637 for interned strings and vtables.
639 2002-03-24 Martin Baulig <martin@gnome.org>
641 * icall.c (ves_icall_Type_GetFields): Reverse the list before storing
642 it in the array since it was created with g_slist_prepend().
644 2002-03-24 Martin Baulig <martin@gnome.org>
646 * debug-symfile.c (mono_debug_local_type_from_signature): Renamed
647 to ves_icall_Debugger_MonoSymbolWriter_get_local_type_from_sig().
648 (mono_debug_method_from_token): Renamed to
649 ves_icall_Debugger_MonoSymbolWriter_method_from_token().
650 (ves_icall_Debugger_DwarfFileWriter_get_type_token): New interncall.
652 * debug-symfile.c (MRT_type_sizeof, MRT_type_field_offset): New
655 * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 6.
657 2002-03-24 Martin Baulig <martin@gnome.org>
659 * debug-symfile.c (mono_debug_local_type_from_signature): New func.
660 (mono_debug_method_from_token): New func.
662 * icall.c (Mono.CSharp.Debugger.MonoSymbolWriter::get_local_type_from_sig):
663 New interncall, calls mono_debug_local_type_from_signature().
664 (Mono.CSharp.Debugger.MonoSymbolWriter::get_method): New interncall,
665 calls mono_debug_method_from_token().
667 2002-03-23 Martin Baulig <martin@gnome.org>
669 * unicode.c (ves_icall_iconv_get_char_count): The `count' argument
670 specifies the number of bytes to be converted, not the array size.
671 Return the number of chars, not the number of bytes.
672 (ves_icall_iconv_get_chars): The `byteCount' argument
673 specifies the number of bytes to be converted, not the array size.
675 2002-03-23 Martin Baulig <martin@gnome.org>
677 * reflection.h (MonoReflectionSigHelper): New type.
679 * reflection.c (mono_reflection_sighelper_get_signature_local),
680 (mono_reflection_sighelper_get_signature_local): New functions.
682 * icall.c (System.Reflection.Emit.SignatureHelper::get_signature_local),
683 (System.Reflection.Emit.SignatureHelper::get_signature_field): New
686 2002-03-23 Martin Baulig <martin@gnome.org>
688 * rawbuffer.c (mono_raw_buffer_load_mmap): Use MAP_SHARED when
690 (mono_raw_buffer_update): New function to write the modified map
693 * debug-symfile.h (MonoDebugSymbolFile): Added `raw_contents_size'.
695 * debug-symfile.c (mono_debug_update_symbol_file): Call
696 mono_raw_buffer_update() when done writing.
698 2002-03-23 Martin Baulig <martin@gnome.org>
700 * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 5.
702 * debug-symfile.c: Added support for arguments and local variables.
704 2002-03-23 Dick Porter <dick@ximian.com>
706 * debug-symfile.c: Remove extraneous 'include <elf.h>' that wasn't
707 protected by ifdefs, hence breaking the w32 build.
709 Thu Mar 21 17:35:01 CET 2002 Paolo Molaro <lupus@ximian.com>
711 * object.c: implement is_interned() the right way.
713 2002-03-21 Martin Baulig <martin@gnome.org>
715 * debug-symfile.[ch]: New files to handle debugging information
716 files. There's also support to dynamically update these symbol
717 files to include machine dependent information.
719 2002-03-20 Dietmar Maurer <dietmar@ximian.com>
721 * threads.c (mono_thread_create): new function to create thread
724 2002-03-20 Martin Baulig <martin@gnome.org>
726 * icall.c (ves_icall_InternalInvoke): Create a new object if the
727 method is a constructor.
728 (icall_map): Added "System.Reflection.MonoCMethod::InternalInvoke",
729 points to ves_icall_InternalInvoke().
731 2002-03-20 Dan Lewis <dihlewis@yahoo.co.uk>
733 * file-io.c: Flush shouldn't throw exceptions.
735 2002-03-19 Dan Lewis <dihlewis@yahoo.co.uk>
737 * file-io.c: FileStream flush support; FileSetLength now
738 restores file pointer.
740 Tue Mar 19 18:17:21 CET 2002 Paolo Molaro <lupus@ximian.com>
742 * class.c: set image for pointer classes.
744 2002/03/19 Nick Drochak <ndrochak@gol.com>
746 * sysmath.c: Forgot one.
748 2002-03-18 Miguel de Icaza <miguel@ximian.com>
750 * sysmath.c: Avoid redefining existing names.
752 2002-03-18 Dan Lewis <dihlewis@yahoo.co.uk>
754 * sysmath.c, sysmath.h, icall.c, Makefile.am: math routines now
755 handled by runtime as icall rather than dllimport from libm.so
756 * file-io.c, file-io.h: fixed handle argument type.
758 2002-03-18 Dick Porter <dick@ximian.com>
760 * reflection.c (mono_image_get_type_info): rename interface to
761 iface, because of "#define interface struct" on windows.
763 Sat Mar 16 19:18:38 CET 2002 Paolo Molaro <lupus@ximian.com>
765 * class.c, class.h: rename and export mono_ptr_class_get().
766 * metadata.c: support MONO_TYPE_ARRAY in MonoType compare.
767 * reflection.c, reflection.h, icall.c: better/saner type name
768 parsing and MonoType creation. Handle MONO_TYPE_ARRAY in
771 2002-03-14 Dietmar Maurer <dietmar@ximian.com>
773 * class.c (mono_class_init): removed hardcoded GHC_SLOT
775 * icall.c (ves_icall_InternalInvoke): impl.
777 Wed Mar 13 00:27:30 CET 2002 Paolo Molaro <lupus@ximian.com>
779 * reflection.c: output the interface map table, too.
781 2002-03-12 Dietmar Maurer <dietmar@ximian.com>
783 * class.c (class_compute_field_layout): separate computation of
786 2002-03-12 Dan Lewis <dihlewis@yahoo.co.uk>
788 * icall.c: added System.Buffer support.
789 * file-io.c: moved file icalls from PAL to FileStream.
791 2002-03-12 Dietmar Maurer <dietmar@ximian.com>
793 * icall.c (ves_icall_System_Object_GetHashCode): impl.
795 2002-03-11 Dietmar Maurer <dietmar@ximian.com>
797 * icall.c (ves_icall_System_ValueType_GetHashCode): impl.
799 Mon Mar 11 14:45:42 CET 2002 Paolo Molaro <lupus@ximian.com>
801 * verify.c, verify.h: moved here the corlib/runtime consistency checks.
803 Mon Mar 11 11:12:23 CET 2002 Paolo Molaro <lupus@ximian.com>
805 * debug-helpers.{c,h}: moved here from monograph some useful functions
806 to locate a method by name/signature in a class or image. Included
807 also a small and flexible IL disassembler.
809 Fri Mar 8 16:29:29 CET 2002 Paolo Molaro <lupus@ximian.com>
811 * reflection.c: fixup tokens in methods with small header size, too.
813 2002-03-08 Dietmar Maurer <dietmar@ximian.com>
815 * object.c (mono_string_to_utf8): remove assert(!error), instead
818 Thu Mar 7 18:55:15 CET 2002 Paolo Molaro <lupus@ximian.com>
820 * icall.c: update to the new mono_Array_class_get interface.
822 Thu Mar 7 17:23:26 CET 2002 Paolo Molaro <lupus@ximian.com>
824 * appdomain.c, object.c: Boehm-GC enable.
825 * icall.c: make get_data_chunk() support split data requests.
826 Ensure a class is initialized in more cases. Return only the first
827 property found in GetProperties() or the compiler gets confused.
828 Implemented GetEvents(). Temporary fix to GetType(), needs rewriting.
829 * reflection.h, reflection.c: add fixup mechanism for field and method
830 tokens. Initialize assembly->typeref in a single place. Output
831 properties after events. Support custom attributes for events, too.
832 Typo fix for paramter custom attrs.
834 2002-03-07 Martin Baulig <martin@gnome.org>
836 * icall.c (ves_icall_System_Array_FastCopy): Small fix.
838 2002-03-07 Dietmar Maurer <dietmar@ximian.com>
840 * class.c (mono_array_class_get): fix. for multi. dim. arrays
842 2002-03-06 Martin Baulig <martin@gnome.org>
844 * icall.c (ves_icall_System_Array_CreateInstanceImpl): Make this work with
845 non-zero lower bounds. See testcases #F10-#F13.
847 2002-03-05 Martin Baulig <martin@gnome.org>
849 * exception.c (mono_get_exception_argument_out_of_range): New exception.
851 * icall.c (ves_icall_System_Array_GetValue): Moved actual implementation to
852 ves_icall_System_Array_GetValue(), only calculate the absolute array position
854 (ves_icall_System_Array_SetValue): Likewise.
855 (ves_icall_System_Array_GetValueImpl): New interncall. Takes an array position
856 as argument and does the actual work. This function is used when copying a
857 multi-dimensional array.
858 (ves_icall_System_Array_SetValueImpl): Almost completely rewrote this. It can
859 now do all the widening conversions of value types.
860 (ves_icall_System_Array_CreateInstanceImpl): Implemented.
862 Tue Mar 5 18:14:01 CET 2002 Paolo Molaro <lupus@ximian.com>
864 * class.c: remove some magic numbers and use the smbolic names,
865 instead. Added init_events() to load event info at class init time.
866 * metadata.h, metadata.c: added mono_metadata_events_from_typedef()
867 and mono_metadata_methods_from_event().
868 * reflection.h, reflection.c: added support for writing out the evnets
871 Mon Mar 4 20:32:43 CET 2002 Paolo Molaro <lupus@ximian.com>
873 * reflection.h, icall.c: use a different method (GetInterfaces)
874 to gather interface info and add isbyref, isprimitive and
875 ispointer to the ves_icall_get_type_info() return value.
877 Mon Mar 4 11:22:26 CET 2002 Paolo Molaro <lupus@ximian.com>
879 * class.h: stared adding support for events.
880 * icall.c: split find_members implementation. Added debug icall to get
881 the address of an object.
882 * reflection.c: handle TypeBuilders in mono_type_get_object().
884 2002-03-01 Martin Baulig <martin@gnome.org>
886 * icall.c (ves_icall_System_Array_GetLength): This must throw an
887 ArgumentOutOfRangeException(), not an ArgumentException().
888 (ves_icall_System_Array_GetLowerBound): Likewise.
889 (ves_icall_System_Array_GetValue): Improved argument checking.
890 (ves_icall_System_Array_SetValue): Improved argument checking.
892 2002-03-01 Martin Baulig <martin@gnome.org>
894 * icall.c (ves_icall_System_Array_GetValue): Raise an exception when
895 called with invalid arguments rather than just dying with g_assert().
896 (ves_icall_System_Array_SetValue): Likewise.
897 (ves_icall_System_Array_CreateInstanceImpl): Don't g_assert_not_reached(),
898 raise a NotImplementedException instead.
899 (ves_icall_System_Array_GetLength): Added argument checking.
900 (ves_icall_System_Array_GetLowerBound): Added argument checking.
902 2002-03-01 Dietmar Maurer <dietmar@ximian.com>
904 * object.h (mono_assert): new macros mono_assert and
905 mono_assert_not_reached
907 2002-02-28 Martin Baulig <martin@gnome.org>
909 * icall.c: Rename "System::String::Intern" to "System::String::_Intern"
910 and "System::String::IsInterned" to "System::String::_IsInterned".
912 Thu Feb 28 19:19:35 CET 2002 Paolo Molaro <lupus@ximian.com>
914 * icall.c: remove hacks for typebuilder. Added icall to create a
915 modified type from a tybebuilder.
916 * reflection.c: removed hacks for TypeBuilder. Create also a MonoImage
917 in mono_image_basic_init (). Added mono_reflection_setup_internal_class ()
918 to create a backing MonoClass for a TypeBuilder.
920 Thu Feb 28 15:35:51 CET 2002 Paolo Molaro <lupus@ximian.com>
922 * class.c, class.h: more refactoring of class init.
923 Export mono_class_setup_mono_type() and mono_class_setup_parent().
925 Thu Feb 28 12:33:41 CET 2002 Paolo Molaro <lupus@ximian.com>
927 * marshal.c, marshal.h: start of marshaling interface.
929 Wed Feb 27 22:15:17 CET 2002 Paolo Molaro <lupus@ximian.com>
931 * icall.c: fix order in assembly qualified name icall.
933 Wed Feb 27 18:45:03 CET 2002 Paolo Molaro <lupus@ximian.com>
935 * class.c: do not free str, since we store it in the hash table.
936 * reflection.h: add label field to MonoILExceptionInfo.
937 * reflection.c: handle references to more than one assembly. Handle
938 case when there isn't a module created in the assembly.
940 Wed Feb 27 12:35:10 CET 2002 Paolo Molaro <lupus@ximian.com>
942 * class.c: Fix typo. Start refactoring of class init code.
944 Wed Feb 27 12:23:00 CET 2002 Paolo Molaro <lupus@ximian.com>
946 * appdomain.c: exit with 1 on error.
947 * class.c: we already have the name in MonoClassField.
948 * image.c, image.h, metadata.c, pedump.c: use directly a pointer in
949 MonoStreamHeader instead of an offset of image->raw_metadata.
951 2002-02-26 Miguel de Icaza <miguel@ximian.com>
953 * appdomain.c (mono_init): Be even more descriptive about the error.
955 Tue Feb 26 16:18:07 CET 2002 Paolo Molaro <lupus@ximian.com>
957 * appdomain.c: give the user an informative message when corlib can't
960 2002-02-26 Martin Baulig <martin@gnome.org>
962 * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData):
963 New icall to get the time zone data.
965 Mon Feb 25 15:51:51 CET 2002 Paolo Molaro <lupus@ximian.com>
967 * reflection.c: set virtual and raw size of section correctly.
968 * threads.c: transfer domain information to newly created threads.
970 Fri Feb 22 18:55:57 CET 2002 Paolo Molaro <lupus@ximian.com>
972 * class.c: when instancing a class in a domain, load the default
973 vaules for static fields from the constant table. Fix System.Enum to
975 * icall.c: implement Object::GetType() internalcall. Implemented
976 MonoField::GetValue() internalcall. Avoid SEGV in search_method().
977 Fixed checking of binding flags in find_members().
978 * metadata.c, metadata.h: introduce mono_metadata_type_hash().
979 * reflection.c: handle enumerations when writing to the constant
980 table. Use a different object cache for types.
983 2002-02-22 Dietmar Maurer <dietmar@ximian.com>
985 * object.c (mono_object_isinst): fix for arrays
987 * icall.c (ves_icall_type_is_subtype_of): fix for 2 interfaces
989 Thu Feb 21 21:00:13 CET 2002 Paolo Molaro <lupus@ximian.com>
991 * object.c: don't use mprotect () and fix intern pool hash table
992 lookup for big endian systems.
994 Thu Feb 21 19:30:29 CET 2002 Paolo Molaro <lupus@ximian.com>
996 * icall.c: change type_is_subtype_of () signature.
998 2002-02-21 Mark Crichton <crichton@gimp.org>
1000 * rand.c, rand.h: Added random number generator for
1001 System.Security.Cryptography classes.
1003 * exception.c, exception.h: Added mono_get_exception_not_implemeted.
1005 * icall.c: Added System.Security.Cryptography calls.
1007 Thu Feb 21 16:45:34 CET 2002 Paolo Molaro <lupus@ximian.com>
1009 * class.c, icall.c, metadata.c: better support for pointer types.
1010 Create a class for them as suggested by dietmar. Fix TYPE_ARRAY class.
1011 * reflection.c: Add support for getting custom attrs for properties
1012 and simplify some code.
1014 Wed Feb 20 22:20:29 CET 2002 Paolo Molaro <lupus@ximian.com>
1016 * icall.c: change getToken () and add custom attribute GetBlob()helper
1018 * reflection.h: add custom attrs array to the reflection builder structures.
1019 * reflection.c: encode and emit custom attributes for all the relevant
1020 reflection objects. Cache fieldref and methodref tokens. Change
1021 mono_image_create_token() interface to take a MonoDynamicAssembly.
1022 More complete custom attributes decoder. Load custom attributes for
1023 Assembly, Field, Method and Constructor objects, too. Make the
1024 returned array an Attribute[] one, not object[]. Added
1025 mono_reflection_get_custom_attrs_blob() to encode the arguments of a
1026 custom attribute constructor.
1028 2002-02-20 Dick Porter <dick@ximian.com>
1032 * socket-io.c: Windows portability fixes (sometimes just ifdeffing
1033 problem code out for now).
1035 2002-02-19 Radek Doulik <rodo@ximian.com>
1037 * object.c (mono_ldstr): use hash table to avoid multiple swapping
1039 Tue Feb 19 20:23:11 CET 2002 Paolo Molaro <lupus@ximian.com>
1041 * icall.c: register the GetCustomAttributes method.
1042 * object.c, object.h: add mono_string_new_len ().
1043 * reflection.h, reflection.c: added mono_runtime_invoke(),
1044 mono_install_runtime_invoke(). Added
1045 mono_reflection_get_custom_attrs () to load custom attributes and
1046 create the attribute objects.
1048 2002-02-19 Dick Porter <dick@ximian.com>
1049 * threads-dummy-types.c:
1050 * threads-dummy-types.h:
1053 * threads-pthread-types.c:
1054 * threads-pthread-types.h:
1055 * threads-pthread.c:
1056 * threads-pthread.h: Deleted obsolete files
1058 2002-02-19 Dietmar Maurer <dietmar@ximian.com>
1060 * class.c (mono_class_vtable): runtime init the class when we
1061 allocate static class data.
1063 * icall.c (ves_icall_System_Array_SetValue): check for null values.
1065 * appdomain.c (mono_domain_transfer_object): impl. hack for Arrays
1066 and String - but we will need generic marshalling support in the
1068 (mono_init): set the domain name in a ms compatible way
1070 * object.c (mono_string_new_utf16): bug fix: use char[] instead of
1073 2002-02-18 Dietmar Maurer <dietmar@ximian.com>
1075 * object.c (mono_array_clone): use alloca() instead of g_malloc
1078 * appdomain.c (mono_domain_unload): impl.
1080 Mon Feb 18 15:52:20 CET 2002 Paolo Molaro <lupus@ximian.com>
1082 * appdomain.c, object.c: fix intern pool implementation.
1083 * class.c: fix alignment code.
1085 2002-02-16 Radek Doulik <rodo@ximian.com>
1087 * icall.c (ves_icall_System_Enum_ToObject): in case of big endian
1088 and s2 > s1, just copy lower bytes to be compatible with little
1089 endian (i.e. 64bit value & 0xffffffff --> 32bit value)
1090 (ves_icall_System_Enum_ToObject): and likewise for s1 > s2
1092 * unicode.c (ves_icall_iconv_new_encoder): decide on big_endian,
1093 force big_endian to be 1 for big endian machines
1094 (ves_icall_iconv_new_decoder): ditto
1096 2002-02-16 Jeffrey Stedfast <fejj@ximian.com>
1098 * socket-io.c (convert_sockopt_level_and_name): If the system
1099 doesn't define SOL_IP or SOL_TCP, get them by hand using
1100 getprotobyname() and caching the values (because this could be a
1102 (ves_icall_System_Net_Sockets_Socket_SetSocketOption_internal):
1103 Use the appropriate struct when the system does support it. Ie,
1104 not all systems have struct ip_mreqn so use struct ip_mreq when
1107 Fri Feb 15 18:15:44 CET 2002 Paolo Molaro <lupus@ximian.com>
1109 * reflection.c: handle finally clauses.
1111 Fri Feb 15 15:06:33 CET 2002 Paolo Molaro <lupus@ximian.com>
1113 * socket-io.c: use g_snprintf() instead of snprintf.
1115 2002-02-14 Jeffrey Stedfast <fejj@ximian.com>
1117 * reflection.c (mono_param_get_objects): Cast second argument to
1118 mono_method_get_param_names to a const char** to silence the
1121 * appdomain.c (mono_domain_assembly_open): Put parens around the
1122 truth statement in the for-loop.
1124 * unicode.c (iconv_convert): Got rid of a compiler warning about
1125 int i being unused when the system has a new iconv.
1126 (iconv_get_length): Same.
1128 * image.c (load_class_names): Cast the second argument to
1129 g_hash_table_insert() to char* to hush compiler warnings about the
1131 (mono_image_open): Same here.
1133 * socket-io.c: Don't conditionally include sys/filio.h or
1134 sys/sockio.h here anymore since we now get them from
1136 (inet_pton): If the system doesn't support inet_aton, implement
1137 using inet_addr and also #define INADDR_NONE if it isn't defined
1140 Thu Feb 14 19:01:06 CET 2002 Paolo Molaro <lupus@ximian.com>
1142 * metadata.c, metadata.h: added function to get packing and size info
1144 * reflection.h, reflection.c: handle field RVA data. Save info about
1145 the table layout if needed. Assign typedef indexes to all the types
1146 before dumping the info about them to avoid forward reference problems.
1148 2002-02-14 Dietmar Maurer <dietmar@ximian.com>
1150 * socket-io.c (convert_sockopt_level_and_name): ifdef
1151 SO_ACCEPTCONN because it is not defined on my system (old debian)
1153 Thu Feb 14 11:49:30 CET 2002 Paolo Molaro <lupus@ximian.com>
1155 * opcode.c: use stddef.h to get NULL.
1157 2002-02-14 Jeffrey Stedfast <fejj@ximian.com>
1159 * socket-io.c: conditionally include sys/filio.h and sys/sockio.h
1160 for FIONBIO, FIONREAD and SIOCATMARK.
1161 (ves_icall_System_Net_Dns_GetHostByAddr_internal): SunOS doesn't
1162 define INADDR_NONE and besides, inet_addr() is deprecated and
1163 should not be used. Use inet_pton() instead - it also has the
1164 added bonus that it can easily handle IPv6 addresses as well.
1165 (inet_pton): Implement using inet_aton() ifndef HAVE_INET_PTON.
1167 Wed Feb 13 23:00:21 CET 2002 Paolo Molaro <lupus@ximian.com>
1169 * decimal.c: remove _MSC_VER conditional.
1171 2002-02-13 Dick Porter <dick@ximian.com>
1174 * icall.c: Internal calls for Blocking, Select, Shutdown,
1175 GetSocketOption and SetSocketOption
1177 Wed Feb 13 19:20:01 CET 2002 Paolo Molaro <lupus@ximian.com>
1179 * assembly.cs: better resolver: use it instead of some kludgy
1182 Wed Feb 13 18:25:55 CET 2002 Paolo Molaro <lupus@ximian.com>
1184 * reflection.c: the best way to speed-up the compiler is to avoid
1187 2002-02-13 Dietmar Maurer <dietmar@ximian.com>
1189 * class.c (mono_class_vtable): changed the object layout
1190 (obj->vtable->class).
1191 (mono_class_create_from_typespec): consider MONO_TYPE_PTR
1193 Tue Feb 12 20:06:01 CET 2002 Paolo Molaro <lupus@ximian.com>
1195 * assembly.c: look for assemblies in the assembly dir, too.
1197 Tue Feb 12 14:03:42 CET 2002 Paolo Molaro <lupus@ximian.com>
1199 * class.c: fix thinko in mono_class_from_type().
1201 Mon Feb 11 19:43:51 CET 2002 Paolo Molaro <lupus@ximian.com>
1203 * exception.h, exception.c: added TypeLoadException.
1204 * object.h, object.c: added mono_array_clone ().
1205 * icall.c: handle throwOnError in AssemblyGetType().
1206 Added Array.Clone().
1207 * opcode.h, opcode.c: use a single value for the opcode val.
1208 Compile fix for non-gcc compilers.
1210 Fri Feb 8 12:26:37 CET 2002 Paolo Molaro <lupus@ximian.com>
1212 * opcodes.c, opcodes.h: export interesting info about opcodes.
1214 2002-02-05 Dietmar Maurer <dietmar@ximian.com>
1216 * object.h (MONO_CHECK_ARG, MONO_CHECK_ARG_NULL): new macro for
1219 * class.c (class_compute_field_layout): set element_class for enums
1220 (mono_class_create_from_typedef): set element_class for normal classes
1222 * icall.c (ves_icall_System_Enum_get_value): impl.
1224 * class.c (mono_class_create_from_typedef): do not set valuetype
1225 flag for System.ValueType and System.Enum
1227 2002-02-04 Dietmar Maurer <dietmar@ximian.com>
1229 * unicode.c (iconv_convert): fix big endian problem.
1231 Fri Feb 1 16:13:20 CET 2002 Paolo Molaro <lupus@ximian.com>
1233 * class.c: add asserts if we are ever going to scribble over memory.
1234 * socket-io.c: not all systems have AF_IRDA defined.
1236 2002-01-31 Dietmar Maurer <dietmar@ximian.com>
1238 * class.c (class_compute_field_layout): do not consider static
1239 fields to compute alignment
1241 2002-01-25 Dietmar Maurer <dietmar@ximian.com>
1243 * appdomain.c (mono_appdomain_get): impl.
1244 (ves_icall_System_AppDomain_ExecuteAssembly): impl.
1246 Thu Jan 24 12:59:23 CET 2002 Paolo Molaro <lupus@ximian.com>
1248 * icall.c: ignore "file://" prefix when loading an assembly.
1250 2002-01-23 Dick Porter <dick@ximian.com>
1254 * Makefile.am: Added socket support
1256 2002-01-23 Miguel de Icaza <miguel@ximian.com>
1258 * icall.c (ves_icall_appdomain_get_default_assemblies): put this
1259 code back. This should return the assemblies that are loaded by
1260 the runtime on behalf of an application domain.
1262 The current implementation is still broken, it just returns every
1263 assembly loaded, but until we get real applications domain this
1266 2002-01-23 Dietmar Maurer <dietmar@ximian.com>
1268 * icall.c (ves_icall_appdomain_get_cur_domain): runtime_init the
1271 2002-01-23 Miguel de Icaza <miguel@ximian.com>
1273 * icall.c (ves_icall_appdomain_get_cur_domain): Cache the value of
1274 the mono_class_from_name lookup.
1275 (ves_icall_get_parameter_info): ditto.
1276 (ves_icall_appdomain_get_assemblies, add_assembly): Implement new internal
1278 (ves_icall_System_Reflection_Assembly_get_code_base): Another new call.
1280 Tue Jan 22 22:43:47 CET 2002 Paolo Molaro <lupus@ximian.com>
1282 * class.c: load also nested classes on class init.
1283 System.ValueType instance methods gets passed boxed
1284 values, unless methods in derived classed that get a pointer to the
1286 * icall.c: use better name parsing code in GetType().
1287 * image.c, image.h: add mono_image_loaded ().
1288 * metadata.c, metadata.h: add mono_metadata_nesting_typedef ().
1289 * reflection.c, reflection.h: added mono_reflection_parse_type().
1291 2002-01-22 Veronica De Santis <veron78@interfree.it>
1293 * icall.c : Added mapping of internal calls for Manual and Auto reset events
1294 * threads.c : Added the implementation of internal calls for events
1295 * threads.h : Added prototypes of internal calls for events
1297 2002-01-21 Radek Doulik <rodo@ximian.com>
1299 * icall.c (ves_icall_InitializeArray): swap bytes on big endians
1301 2002-01-21 Dietmar Maurer <dietmar@ximian.com>
1303 * class.c (mono_class_init): set min_align to 1 (instead of 0)
1304 (mono_class_value_size): use min_align
1306 2002-01-20 Dick Porter <dick@ximian.com>
1309 * threads.c: Replaced all instances of WapiHandle * with HANDLE,
1310 so it compiles on w32.
1312 2002-01-17 Dietmar Maurer <dietmar@ximian.com>
1314 * metadata.c (mono_type_stack_size): impl.
1316 * class.c (mono_class_get_field): impl. memberref token
1318 2002-01-16 Veronica De Santis <veron78@@interfree.it>
1320 * icall.h : Added the internal calls mapping for CreateMutex_internal
1321 and ReleaseMutex_internal.
1322 * threads.h : Added the prototype of mutexes internal calls.
1323 * threads.c : Added the implementations of mutexes internal calls.
1325 Tue Jan 15 22:47:57 CET 2002 Paolo Molaro <lupus@ximian.com>
1327 * metaparse.h: removed unused file.
1328 * reflection.c, reflection.h: added stream_data_align () function
1329 to align data in streams and keep stream aligned. Add support for
1330 exception support in method headers.
1332 Tue Jan 15 19:42:50 CET 2002 Paolo Molaro <lupus@ximian.com>
1334 * unicode.c: make iconv_convert () return the number of bytess written
1335 in the output buffer.
1337 2002-01-15 Dick Porter <dick@ximian.com>
1338 * threads.c: Make the runtime's idea of infinite timeouts coincide
1339 with the class library's
1341 Fix a particularly egregious bug in mono_thread_cleanup(). That
1342 code was so utterly bogus it must have been written on a Monday.
1344 Mon Jan 14 17:01:03 CET 2002 Paolo Molaro <lupus@ximian.com>
1346 * reflection.h: add subtypes field to TypeBuilder.
1347 * reflection.c: encode constants for literal fields.
1348 Handle subtypes. Fix user string token (and add a zero byte)
1351 2002-01-14 Dietmar Maurer <dietmar@ximian.com>
1353 * class.c (mono_class_init): bug fix: assign slot numbers for
1356 Fri Jan 11 18:54:42 CET 2002 Paolo Molaro <lupus@ximian.com>
1358 * reflection.c: don't try to output a code RVA for abstract methods.
1359 Small fixes for method header format. Output parameter info to the
1360 ParamDef table. Save method overriding info to MethodImpl table.
1361 Fix property support. Allow typedef.extends to be a type in the
1363 * verify.c: fix off-by-one error.
1365 Thu Jan 10 19:36:27 CET 2002 Paolo Molaro <lupus@ximian.com>
1367 * class.c: fix mono_class_from_mono_type () for szarray types.
1368 Remove unused cache check in mono_class_from_type_spec().
1369 * icall.c: *type_from_name () functions handle simple arrays and byref.
1370 * reflection.c: handle byref and szarray types. Handle methods without
1371 body (gets P/Invoke compilation working). Handle types and fields in
1373 * reflection.h: add rank to MonoTypeInfo.
1375 2002-01-10 Dick Porter <dick@ximian.com>
1377 * threads.c: Implemented WaitAll(), WaitAny() and WaitOne()
1380 Wed Jan 9 19:27:13 CET 2002 Paolo Molaro <lupus@ximian.com>
1382 * icall.c: initialize class in type_from_handle ().
1383 Loop also in parent classes for get_method ().
1384 * reflection.c: properly encode class and valuetype types.
1385 Start on encoding TypeBuilder types. Handle fieldrefs.
1386 Use correct length when registering a user string.
1387 Handle ConstructorBuilder and MonoMethod in get_token ().
1388 Make mono_type_get_object () aware of cached types.
1389 * object.c: back out change to mono_string_new ().
1391 Tue Jan 8 22:47:44 EST 2002 Matt Kimball <matt@kimball.net>
1392 * object.c: mono_string_new should return a NULL when the string
1393 passed in is NULL -- not try to deference it.
1395 Sat Jan 5 15:48:04 CET 2002 Paolo Molaro <lupus@ximian.com>
1397 * icall.c: hack to make IsSubType work for TypeBuilders.
1398 * reflection.c: emit constructors before methods.
1399 Retrieve param names in mono_param_get_objects().
1401 2002/01/05 Nick Drochak <ndrochak@gol.com>
1403 * Makefile.am: fix list of headers and sources so automake 1.5
1404 doesn't complain. Removed \# at end of list.
1406 Thu Jan 3 23:17:17 CET 2002 Paolo Molaro <lupus@ximian.com>
1408 * reflection.c: get token for a method ref. Set return type of
1409 constructor to void.
1410 * loader.c: debug message.
1411 * class.c: typo fix.
1413 Mon Dec 24 17:18:10 CET 2001 Paolo Molaro <lupus@ximian.com>
1415 * icall.c: fix array init with rank > 1. FindMembers
1416 loops in parent class as well.
1417 * image.c: do not insert nested types in name cache.
1418 * reflection.c: warning fix.
1419 * reflection.h: add override method (for interface impl).
1421 Mon Dec 24 16:16:56 CET 2001 Paolo Molaro <lupus@ximian.com>
1423 * metadata.c: fix customattr decoding.
1425 2001-12-21 Miguel de Icaza <miguel@ximian.com>
1427 * rawbuffer.cs: Added native Win32 implementation, avoids using
1428 mmap on Cygwin. This patch is from Dan Lewis (dihlewis@yahoo.co.uk)
1430 Thu Dec 20 20:11:26 CET 2001 Paolo Molaro <lupus@ximian.com>
1432 * class.c: make the low-level routines handle the cache.
1434 Thu Dec 20 15:20:35 CET 2001 Paolo Molaro <lupus@ximian.com>
1436 * image.c: fopen (file, "rb") ("David Dawkins" <david@dawkins.st>).
1438 Tue Dec 18 18:50:00 CET 2001 Paolo Molaro <lupus@ximian.com>
1440 * class.c: fix mono_array_element_size() for objects.
1441 * class.h, class.c: add properties to MonoClass and load them
1443 * icall.c: check with isinst() when assigning a value to an array
1444 instead of requiring the classes to match exactly.
1445 Implemented icall for System.Type::GetType().
1446 Implemented icalls to get ParameterInfo, ProprtyInfo and info about
1447 enums. Handle bindingflags when looking for methods and fields.
1448 * metadata.h, metadata.c: implemented mono_metadata_properties_from_typedef()
1449 and mono_metadata_methods_from_property().
1450 * reflection.h, reflection.c: added structures for propreties,
1451 parameters and enums. Implemented mono_property_get_object() and
1452 mono_param_get_objects().
1454 2001-12-18 Dick Porter <dick@ximian.com>
1456 * file-io.c: Use mono_string_to_utf16() instead of
1459 * object.c: Added mono_string_to_utf16(), which copies the non
1460 NULL-terminated MonoString into a new double-null-terminated
1463 2001-12-17 Dietmar Maurer <dietmar@ximian.com>
1465 * icall.c (ves_icall_System_DateTime_GetNow): added EPOCH adjustment
1467 2001-12-16 Dietmar Maurer <dietmar@ximian.com>
1469 * file-io.c: raise exceptions if handle is invalid.
1471 Thu Dec 13 20:27:08 CET 2001 Paolo Molaro <lupus@ximian.com>
1473 * assembly.c: yet another check for mscorlib.
1474 * class.c, class.h: load nesting info for classes.
1475 * icall.c: many new functions to support the Reflection classes.
1476 * metadata.c, metadata.h: mono_metadata_nested_in_typedef() added.
1477 * reflection.h, reflection.c: mono_image_create_token(),
1478 mono_assembly_get_object(), mono_type_get_object(),
1479 mono_method_get_object(), mono_field_get_object(): methods to return
1480 objects that parallel the C representation of assemblies, types,
1483 2001-12-11 Dick Porter <dick@ximian.com>
1486 * file-io.c: Internal calls for file IO.
1488 Thu Dec 6 16:21:30 CET 2001 Paolo Molaro <lupus@ximian.com>
1490 * tabledefs.h: missing FileAttributes.
1491 * verify.h, verify.c: use is_valid_string () to simplify and check for
1492 valid strings more correctly. Fix warnings and speeling.
1493 Check more tables: Filed, File, ModuleRef, StandAloneSig.
1494 Check code: branches, maxstack, method calls.
1496 2001-12-04 Dietmar Maurer <dietmar@ximian.com>
1498 * object.c (mono_object_allocate): removed static, so that the jit
1499 can allocate value types.
1501 * icall.c (ves_icall_System_DateTime_GetNow): impl.
1503 Mon Dec 3 17:02:01 CET 2001 Paolo Molaro <lupus@ximian.com>
1505 * class.c: init enum types right away and register the
1506 token->MonoClass map in mono_class_create_from_typedef ().
1507 * verify.h, verify.c: first cut of the verifier.
1508 * pedump.c: add --verify switch to verify metadata tables.
1509 * tabledefs.h: add some missing enums.
1511 2001-11-30 Dietmar Maurer <dietmar@ximian.com>
1513 * class.c (mono_install_runtime_class_init): impl.
1514 (mono_class_init): renamed mono_class_metadata_init to
1515 mono_class_init, also removed the metadata_inited flag
1517 * object.c (mono_object_isinst): use faster algorithm
1519 2001-11-30 Radek Doulik <rodo@ximian.com>
1521 * mono-endian.h: reverted last change
1522 added function prototypes
1524 * Makefile.am (libmetadata_a_SOURCES): reverted my last change and
1525 add mono-endian.c back
1527 * mono-endian.c: returned back, as Paolo pointed out, it's needed
1528 for unaligned access, I've mistaked it with endianess. I am
1530 (mono_read16): fix reverted endianess
1531 (mono_read64): ditto
1532 (mono_read32): ditto
1534 2001-11-30 Dick Porter <dick@ximian.com>
1536 * exception.c: Implement mono_exception_from_name()
1538 Fri Nov 30 12:01:02 CET 2001 Paolo Molaro <lupus@ximian.com>
1540 * metadata.h, metadata.c: remove params_size and locals_size and their
1541 calculation from the metadata code: they are only usefult to the
1544 2001-11-29 Radek Doulik <rodo@ximian.com>
1546 * object.c (mono_ldstr): swap bytes here, it's probably not the
1547 best place, but works for me now, I'll redo it once I know mono
1548 better, also note that I add PROT_WRITE and don't reset back, also
1549 note that it's only affects big endians, so x86 should be OK
1551 * mono-endian.h (read16): use just glib macros for both endians
1553 * mono-endian.c: removed as glib macros are used in in
1554 mono-endian.h so we don't need to care about endianess for read
1555 macros as glib does that for us already
1557 Thu Nov 29 18:20:58 CET 2001 Paolo Molaro <lupus@ximian.com>
1559 * class.h, class.h: take minimum alignment into consideration so
1560 that the fields of a class remain aligned also when in an array.
1562 Tue Nov 27 16:39:01 CET 2001 Paolo Molaro <lupus@ximian.com>
1564 * loader.h, loader.c: add mono_method_get_param_names().
1565 * class.c: 0-init class fields.
1567 2001-11-26 Dick Porter <dick@ximian.com>
1571 * threads.c: New file that handles System.Threading on all platforms
1574 * object.h: Remove the synchronisation struct from MonoObject,
1575 replace it with a pointer that gets initialised on demand
1577 * Makefile.am: Replace all the system-specific threading code with
1578 a single file that uses the new wrapper library
1580 Mon Nov 19 11:37:14 CET 2001 Paolo Molaro <lupus@ximian.com>
1582 * class.c, class.h: add mono_install_trampoline() so that the runtime
1583 can register a function to create a trampoline: removes the ugly
1584 requirement that a runtime needed to export arch_create_jit_trampoline.
1585 * object.h, object.c: added mono_install_handler() so that the runtime
1586 can install an handler for exceptions generated in C code (with
1587 mono_raise_exception()). Added C struct for System.Delegate.
1588 * pedump.c: removed arch_create_jit_trampoline.
1589 * reflection.c: some cleanups to allow registering user strings and
1590 later getting a token for methodrefs and fieldrefs before the assembly
1592 * row-indexes.h: updates and fixes from the new ECMA specs.
1594 Thu Nov 15 17:44:49 CET 2001 Paolo Molaro <lupus@ximian.com>
1596 * class.h, class.c: add enum_basetype field to MonoClass.
1597 * metadata.h, metadata.c: add mono_metadata_get_constant_index()
1598 to get index in the constant table reated to a field, param or
1600 * reflection.h, reflection.c: handle constructors. Set public-key and
1601 version number of the built assembly to 0.
1602 * row-indexes.h: update from new ECMA spec.
1604 Wed Nov 14 19:26:06 CET 2001 Paolo Molaro <lupus@ximian.com>
1606 * class.h, class.c: add a max_interface_id to MonoClass.
1607 * icall.c: rename my_mono_new_object() to my_mono_new_mono_type()
1608 since it's used to do that. Added mono_type_type_from_obj().
1609 Make GetType() return NULL instead of segfaulting if the type was not
1610 found. Handle simple arrays in assQualifiedName.
1611 * object.h: add a struct to represent an Exception.
1612 * reflection.c: output call convention in method signature.
1613 Add code to support P/Invoke methods and fixed offsets for fields.
1615 Mon Nov 12 12:41:32 CET 2001 Paolo Molaro <lupus@ximian.com>
1617 * decimal.c, decimal.h: mono_double2decimal() get the sign bit from
1619 * icall.c: use mono_array_addr instead of array->vector: fixes the
1620 reflection image writing.
1621 * reflection.c: init call convention byte to 0 in method signature.
1622 Encode the property signature. Don't output property-related methods
1623 twice. Really process the properties for a type (don't cast a field to
1624 a property, my mom always told me that).
1625 Fix 64 bit issues in pointer alignment in a different and more
1628 2001-11-10 Sean MacIsaac <macisaac@ximian.com>
1630 * loader.h: Removed type class from MonoDefaults, added monotype
1632 * loader.c: Loaded MonoType, removed loading of Type
1634 * icall.c (my_mono_new_object): Now returns a System.MonoType,
1635 and fills in System.Type._impl with a RuntimeTypeHandle rather
1636 than the actual MonoClass *
1638 (ves_icall_type_from_handle): change from type_class to
1641 (ves_icall_System_Runtime_InteropServices_Marshal_ReadIntPtr):
1644 (ves_icall_System_Runtime_InteropServices_Marshal_PtrToStringAuto):
1647 (ves_icall_System_Reflection_Assembly_LoadFrom): implemented
1649 (ves_icall_System_Reflection_Assembly_GetType): implemented
1651 (ves_icall_System_MonoType_assQualifiedName): implemented
1653 (ves_icall_System_PAL_OpSys_GetCurrentDirecotry): implemented
1655 2001-11-09 Miguel de Icaza <miguel@ximian.com>
1657 * assembly.c (mono_assembly_open): Implement a cache for the
1660 (mono_assembly_close): only destroy the assembly when the last
1663 2001-11-09 Dick Porter <dick@ximian.com>
1665 * Makefile.am (pedump_LDADD): Don't need THREAD_LIBS any more
1667 2001-11-09 Dietmar Maurer <dietmar@ximian.com>
1669 * class.c (mono_class_metadata_init): bug fix: compute the right slot
1671 Fri Nov 9 15:48:02 CET 2001 Paolo Molaro <lupus@ximian.com>
1673 * icall.c, decimal.h, decimal.c: integrated decimal internalcalls
1674 from Martin Weindel.
1675 * object.h: add mono_string_chars ().
1677 2001-11-07 Miguel de Icaza <miguel@ximian.com>
1679 * reflection.c (build_compressed_metadata): Eliminates warnings
1680 and uses 64-bit clean code.
1682 * metadata.c (mono_type_hash): Change signature to eliminate warnings.
1683 (mono_type_equal): Change signature to eliminate warnings.
1685 Wed Nov 7 15:40:01 CET 2001 Paolo Molaro <lupus@ximian.com>
1687 * icall.c, loader.c: remove the internalcall array constructors.
1688 Changes to match the new MonoArray structure.
1689 * object.h, object.c: an array object doesn't allocate an extra
1690 vector. Add mono_array_new_full () to create jagged arrays easily.
1692 Mon Nov 5 19:51:06 CET 2001 Paolo Molaro <lupus@ximian.com>
1694 * metadata.h, metadata.c: add mono_metadata_field_info () to
1695 retreive all the info about a field from vairous tables.
1696 * icall.c: implement S.Runtime.CServices::InitializeArray () icall.
1697 * class.h, class.c: augment MonoClassField with more info.
1698 Implemented mono_ldtoken for fields. Implemented ExplicitLayout
1699 policy and load a field's RVA if needed.
1701 2001-11-05 Dietmar Maurer <dietmar@ximian.com>
1703 * class.c (mono_class_metadata_init): create a trampoline for all
1704 virtual functions instead of actually compiling them.
1706 Fri Nov 2 19:37:51 CET 2001 Paolo Molaro <lupus@ximian.com>
1708 * class.h, class.c: include name in MonoClassField.
1709 * class.c: fix fundamental type of System.Object and System.String.
1710 Set the right fundamental type for SZARRAY, too. Handle TypeSpec
1712 * icall.c: remove internalcalls for the Reflection stuff that is now
1714 * loader.c: mono_field_from_memberref () implementation.
1715 * mono-endian.c: thinko (s/struct/union/g).
1716 * object.c, object.h: make the mono_string_* prototypes actually use
1717 MonoString instead of MonoObject.
1718 * reflection.c, reflection.h: updates for changes in the reflection
1719 code in corlib: we use C structures that map to the actual C# classes.
1720 Handle SZARRAYs when encoding types. Handle locals in methods. Use a
1721 fat method header if needed and use the info from the ILGenerator for
1722 methods. Handle fields in types. Misc fixes.
1724 2001-10-17 Dietmar Maurer <dietmar@ximian.com>
1726 * class.c (mono_class_metadata_init): bug fix: always allocate
1727 space for static class data
1729 2001-10-25 Dietmar Maurer <dietmar@ximian.com>
1731 * class.c (mono_compute_relative_numbering): use relative
1732 numbering to support fast runtime type checks.
1734 2001-10-17 Sean MacIsaac <macisaac@ximian.com>
1736 * class.c (mono_class_create_from_typeref): added debugging output
1737 to print class name when MonoDummy is returned instead of real class
1739 2001-10-15 Dietmar Maurer <dietmar@ximian.com>
1741 * class.c (mono_class_metadata_init): interface offset table now
1742 contains pointers into the vtable - this is more efficient for the jit
1744 2001-10-12 Dietmar Maurer <dietmar@ximian.com>
1746 * class.c (mono_class_metadata_init): use a temporary vtable (the
1747 old algorithm only worked for the interpreter, but not for the jit)
1749 2001-10-11 Dietmar Maurer <dietmar@ximian.com>
1751 * loader.c (method_from_memberref): use mono_class_get to get the
1752 class of an array instead of using System.Array directly.
1753 (mono_get_method): also add MEMBERREF methods to the method cache
1754 which usefull for arrays.
1756 2001-10-10 Dietmar Maurer <dietmar@ximian.com>
1758 * pedump.c (arch_compile_method): added to compute vtable entry
1760 * metadata.c (mono_metadata_interfaces_from_typedef): also return the
1761 number of interfaces.
1763 * class.h: merged MonoArrayClass into MonoClass
1765 * class.c (mono_class_create_from_typedef): compute the vtable size and
1766 allocate space to include the vtable inside MonoClass
1767 (mono_class_metadata_init): initialize the vtable
1769 Mon Oct 8 16:12:38 CEST 2001 Paolo Molaro <lupus@ximian.com>
1771 * metadata.c, metadata.h: use MonoArrayType to describe the shape of an array.
1772 Guard against calling bsearch with a NULL pointer (pointed out by Laurent Rioux, smoux).
1773 * image.c: endian fixes by Laurent Rioux.
1774 * object.h, object.c: rename MonoStringObject to MonoString and
1775 MonoArrayObject to MonoArray. Change some function names to conform to
1776 the style mono_<object>_<action>. mono_string_new_utf16 () takes a
1777 guint16* as first argument, so don't use char*.
1778 Provide macros to do the interesting things on arrays in a portable way.
1779 * threads-pthread.c: updates for the API changes and #include <sched.h>
1780 (required for sched_yield()).
1781 * icall.c: updates for the API changes above.
1782 * Makefile.am, mono-endian.c. mono-endian.h: include unaligned read routines for
1783 platforms that need them.
1785 Mon Oct 8 10:43:23 CEST 2001 Paolo Molaro <lupus@ximian.com>
1787 * class.c: set the correct type for all the fundamental
1788 type when loading the class.
1790 2001-10-05 Dick Porter <dick@ximian.com>
1792 * threads-pthread.c (pthread_mutex_timedlock): Simple
1793 compatibility version for C libraries that lack this call.
1795 Thu Oct 4 19:10:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
1797 * class.c: MonoTypes stored in MonoClass are stored as
1798 fundamental MonoTypes when the class represents a
1799 fundamental type (System.Int32, ...).
1800 The TypeHandle return by ldtoken is a MonoType*.
1801 * icall.c: ves_icall_get_data_chunk () write out all the
1802 PE/COFF stuff. Implement ves_icall_define_method (),
1803 ves_icall_set_method_body (), ves_icall_type_from_handle ().
1804 * image.c: properly skip unknown streams.
1805 * loader.h, loader.c: add type_class to mono_defaults.
1806 * metadata.c, metadata.h: export compute_size () as
1807 mono_metadata_compute_size () with a better interface.
1809 * pedump.c: don't try to print the entry point RVA if there is no entry point.
1810 * reflection.c, reflection.h: many cleanups, fixes, output method
1811 signatures and headers, typedef and typeref info, compress the metadata
1812 tables, output all the heap streams, cli header etc.
1813 * row-indexes.h: typo fixes.
1815 2001-10-04 Dick Porter <dick@ximian.com>
1817 * object.h: Add a synchronisation mutex struct to MonoObject
1819 * object.c (mono_new_object): Initialise the object
1820 synchronisation mutexes
1822 * icall.c: System.Threading.Monitor internal calls
1824 * threads-pthread.h:
1825 * threads-pthread.c: System.Threading.Monitor internal calls
1827 * threads-types.h: New file, includes the system-specific thread
1830 * threads-pthread-types.h:
1831 * threads-pthread-types.c: New files, handle pthread-specific
1832 synchronisation types
1834 * threads-dummy-types.h:
1835 * threads-dummy-types.c: New files of dummy support for
1836 thread-specific types
1840 * pedump.c: include mono-endian.h not endian.h
1842 * Makefile.am: More threads files.
1843 Name mono-endian.h not endian.h
1845 Tue Oct 2 20:33:48 CEST 2001 Paolo Molaro <lupus@ximian.com>
1847 * Makefile.am, reflection.h, reflection.c: move here the reflection related
1848 stuff and implement a few more bits.
1849 * icall.c: a field needs to be dereferenced twice. Do not use the same
1850 name for two variables in the same scope.
1851 * image.c, image.h: cleanups.
1853 2001-10-02 Dietmar Maurer <dietmar@ximian.com>
1855 * class.c (mono_class_metadata_init): bug fix: compute the right size
1857 Mon Oct 1 20:43:57 CEST 2001 Paolo Molaro <lupus@ximian.com>
1859 * icall.c: implemented some of the Reflection internalcalls.
1860 * image.c, image.h: start writing out the PE/COFF image.
1861 * metadata.h, metadata.c: implement mono_metadata_encode_value ()
1862 that does the reverse than decode_blob_size ().
1863 * object.c: use mono_metadata_encode_value (). Move here
1864 temporary implementation of mono_string_to_utf8 ().
1865 * rawbuffer.c: make malloc_map static.
1867 Fri Sep 28 19:26:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
1869 * metadata.c: fix type comparison for arrays.
1870 * loader.h, loader.c: half-assed fix to get more tests work in cygwin.
1871 Added a couple of new classes to monodefaults.
1872 * icall.c: added a couple of Reflection-related internalcalls.
1873 * class.h, class.c: implemented mono_ldtoken () for RuntimeTypeHandles.
1874 Added a byval_arg MonoType to MonoClass.
1876 2001-09-28 Dick Porter <dick@ximian.com>
1879 * threads-pthread.h:
1880 * threads-pthread.c: Implemented internal calls for
1881 LocalDataStoreSlot operations. Applied mutexes around all shared
1882 data. Reworked the thread creation and Start() operations to
1883 avoid a race condition.
1886 * threads-dummy.c: Dummy calls for the LocalDataStoreSlot operations
1888 Thu Sep 27 21:45:55 CEST 2001 Paolo Molaro <lupus@ximian.com>
1890 * rawbuffer.c: disable mmap on cygwin since it seems to be broken there.
1892 Thu Sep 27 19:52:11 CEST 2001 Paolo Molaro <lupus@ximian.com>
1894 * class.c, loader.c: warn and return NULL instead of erroring out.
1895 * icall.c: added System.AppDomain::getCurDomain().
1896 * loader.c: we don't need to lookup the typedef again for p/invoke calls.
1898 2001-09-25 Dick Porter <dick@ximian.com>
1900 * threads-pthread.h:
1901 * threads-pthread.c: Implemented timed thread joining and added
1902 System.Threading.Thread::Join_internal internal call
1904 * icall.c: Added System.Threading.Thread::Join_internal internal call
1907 * threads-dummy.c: Dummy calls for System.Thread.Thread::Join_internal
1909 Mon Sep 24 18:56:59 CEST 2001 Paolo Molaro <lupus@ximian.com>
1911 * object.c, object.h: added mono_ldstr (), mono_string_is_interned () and
1912 mono_string_intern () to implement the semantics of the ldstr opcode
1913 and the interning of System.Strings.
1914 * icall.c: provide hooks to make String::IsIntern and String::Intern
1917 2001-09-23 Dick Porter <dick@ximian.com>
1920 * threads-dummy.h: New files of dummy threading routines
1922 * Makefile.am (THREAD_SOURCE): Arrange to compile different thread
1923 support code based on system specifics
1925 Rename PTHREAD_LIBS to THREAD_LIBS
1927 2001-09-23 Dick Porter <dick@ximian.com>
1929 * threads-pthread.c: Implement the System.Threading.Thread::Sleep,
1930 Schedule (called when asked to Sleep for 0 ms) and CurrentThread
1932 (mono_thread_init): Set up a Thread object instance to return when
1933 the main thread calls Thread.CurrentThread
1934 (mono_thread_cleanup): Wait for all subthreads to exit
1936 * icall.c: New internal calls for System.Threading.Thread::Sleep
1937 (including Schedule) and CurrentThread
1939 * threads.h: New file, to insulate thread-specific stuff from the
1942 2001-09-21 Dick Porter <dick@ximian.com>
1944 * threads-pthread.h:
1945 * threads-pthread.c: New file, for handling pthreads-style
1946 threading support. Start() now starts a new thread and executes
1947 the ThreadStart delegate instance.
1949 * icall.c: Added the internalcall for
1950 System.Threading.Thread::Start_internal
1952 * Makefile.am: Added new files, and PTHREADS_LIBS to the link line
1954 Thu Sep 20 19:37:39 CEST 2001 Paolo Molaro <lupus@ximian.com>
1956 * loader.c: work around the different signatures for delegates
1957 constructors csc generates in compiled code vs the ones compiled in mscorlib.
1959 Tue Sep 18 13:16:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
1961 * class.h, class.c: add mono_class_get_field_from_name ().
1962 * *: Fix C comments and other ANSI C issues.
1964 Mon Sep 10 20:21:34 CEST 2001 Paolo Molaro <lupus@ximian.com>
1966 * endian.h, assembly.c: fix some endianness issues.
1968 Fri Sep 7 18:40:40 CEST 2001 Paolo Molaro <lupus@ximian.com>
1970 * loader.h, load.c: add delegate_class to mono_defaults.
1971 Handle runtime provided methods in mono_get_method ().
1973 2001-08-29 Dietmar Maurer <dietmar@ximian.com>
1975 * loader.c (mono_get_method): use pinvoke for internal call
1977 * icall.c: use pinvoke for internal call
1979 * loader.c (method_from_memberref): set the method name
1981 Wed Aug 29 12:43:41 CEST 2001 Paolo Molaro <lupus@ximian.com>
1983 * metadata.c: help the compiler generate better code for
1984 mono_class_from_mono_type ().
1986 2001-08-28 Dietmar Maurer <dietmar@ximian.com>
1988 * class.c (mono_class_metadata_init): delayed computing of the
1989 class size to mono_class_metadata_init ()
1991 Tue Aug 28 15:47:15 CEST 2001 Paolo Molaro <lupus@ximian.com>
1993 * class.c, class.h: add an interfaces member to MonoClass.
1994 * image.c, image.h: add assembly_name field to MonoImage
1995 from the assembly table.
1996 * metadata.c, metadata.h: add mono_metadata_interfaces_from_typedef ().
1998 Mon Aug 27 20:12:01 CEST 2001 Paolo Molaro <lupus@ximian.com>
2000 * class.c: Handle Array in mono_class_from_mono_type ().
2001 * metadata.c, pedump.c: some endian fixes.
2003 Mon Aug 27 15:23:23 CEST 2001 Paolo Molaro <lupus@ximian.com>
2005 * class.c, loader.c, loader.h: More types handled in mono_class_from_mono_type ().
2006 * metadata.c: fix small problem introduced with the latest commit.
2008 Mon Aug 27 12:17:17 CEST 2001 Paolo Molaro <lupus@ximian.com>
2010 * loader.c, metadata.c, metadata.h: Export mono_metadata_type_equal().
2011 We don't need a MonoMetadata pointer anymore to compare signatures in
2012 mono_metadata_signature_equal (), update callers.
2013 Reduced memory usage an number of allocations for MonoMethodHeader and
2014 MonoMethodSignature.
2016 Sun Aug 26 23:03:09 CEST 2001 Paolo Molaro <lupus@ximian.com>
2018 * metadata.c: added compare for szarray.
2020 Sun Aug 26 11:34:24 CEST 2001 Paolo Molaro <lupus@ximian.com>
2022 * class.h, class.c, loader.h, loader.c: export mono_class_from_mono_type ()
2023 and add a couple more types to it and mono_defaults. Give an hint on
2024 classes that need implementing in our corlib and are referenced
2027 Sat Aug 25 12:52:54 CEST 2001 Paolo Molaro <lupus@ximian.com>
2029 * class.h, class.c: keep track if a class is also an Enum.
2030 * loader.c: Implement a couple more types for use in libffi
2031 marshalling. Gives better diagnostics when failing to dlopen
2032 a library. Set method->klass for P/Invoke methods, too.
2034 Fri Aug 24 19:30:25 CEST 2001 Paolo Molaro <lupus@ximian.com>
2036 * class.c, class.h: add a MonoType this_arg to MonoClass that
2037 represents a pointer to an object of the class' type that
2038 can be used by the interpreter and later the type cache.
2039 Add best guess alignment info for valuetype objects.
2041 Fri Aug 24 15:50:31 CEST 2001 Paolo Molaro <lupus@ximian.com>
2043 * metadata.h, metadata.c, class.h, class.c: squeezed MonoParam
2044 into MonoType: one less level of indirection and allocation and
2045 simplifies quite a bit of code. Added cache for MonoTypes that are
2046 used frequently, so that we don't need to allocate them all the time.
2048 2001-08-24 Dietmar Maurer <dietmar@ximian.com>
2050 * class.c (mono_class_create_from_typedef): System.Enum is also a
2051 value type, although it does not derive from System.ValueType
2052 (maybe a bug in the ms compiler?)
2054 * metadata.c (mono_type_size): return the right size for value types
2056 * loader.c (mono_get_method): only initialize method header if not abstract
2058 * class.c (mono_class_from_mono_type): use mono_default values.
2060 2001-08-23 Dietmar Maurer <dietmar@ximian.com>
2062 * *: use MonoClass pointers instead of <type_tokens>
2064 * class.h: new flag: metadata_inited.
2066 * class.c (mono_class_metadata_init): impl.
2067 (mono_class_instance_size): impl.
2068 (mono_class_data_size): impl.
2070 Wed Aug 22 16:27:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
2072 * metadata.c, loader.h, loader.c, image.h, image.c, class.h, class.c:
2073 MonoClass now has the name and name_space fields.
2074 MonoMethod has a pointer to its MonoClass, instead of MonoImage.
2075 mono_get_method () takes and optional MonoClass as argument.
2076 Removed mono_typedef_from_name() and added mono_class_token_from_name()
2077 instead that takes advantage of a map from class names to typedef
2078 tokens in MonoImage.
2080 Tue Aug 21 18:54:58 CEST 2001 Paolo Molaro <lupus@ximian.com>
2082 * metadata.c: zero is not a valid alignment boundary.
2083 Merge MONO_TYPE_VOID in default decoding code.
2085 2001-08-21 Dietmar Maurer <dietmar@ximian.com>
2087 * image.h: merged MonoMetadata into MonoImage
2089 * class.h: cleanup of MonoArrayClass, use a MonoClass pointer to
2090 identify the type of elements.
2092 Mon Aug 20 19:39:00 CEST 2001 Paolo Molaro <lupus@ximian.com>
2094 * blob.h: fix MONO_TYPE_TYPEDBYREF value.
2095 * cil-coff.h: split MonoMSDOSHeader and add size info.
2096 * image.c: add some consistency checks.
2097 * metadata.c: fix row size computation: one programmer
2098 error and one LAMESPEC. Handle MONO_TYPE_TYPEDBYREF.
2099 add explanation for the locator routine.
2100 Fix decoding of size in method header.
2102 2001-08-20 Miguel de Icaza <miguel@ximian.com>
2104 * assembly.c (g_concat_dir_and_file): Use _S for string concat.
2105 (g_concat_dir_and_file): Bring g_concat_dir_and_file
2106 function from gnome-libs. This uses the right path separator
2107 based on the OS, and also works around a bug in some systems where
2108 a double slash is not allowed.
2109 (default_assembly_name_resolver): Use g_concat_dir_and_file
2110 (mono_assembly_open): ditto.
2112 2001-08-20 Dietmar Maurer <dietmar@ximian.com>
2114 * metadata.c (mono_metadata_signature_equal): impl.
2116 * *: void is now a realy MonoType (instead of using NULL)
2118 * metadata.c (do_mono_metadata_parse_type): use
2119 mono_metadata_parse_type to parse void value.
2121 Sat Aug 18 12:51:28 CEST 2001 Paolo Molaro <lupus@ximian.com>
2123 * metadata.c, metadata.h: in the signature and method header store
2124 only the space required for holding the loca vars and incoming arguments.
2126 2001-08-15 Dietmar Maurer <dietmar@ximian.com>
2128 * metadata.c (do_mono_metadata_parse_type): treat void like any
2129 other type (instead of assigning NULL);
2131 2001-08-14 Dietmar Maurer <dietmar@ximian.com>
2133 * metadata.c (mono_metadata_parse_mh): fixxed pinned/byref value
2135 2001-08-09 Dietmar Maurer <dietmar@ximian.com>
2137 * image.c (do_mono_image_open): added a cache for arrays.
2139 Sat Aug 4 12:46:02 CEST 2001 Paolo Molaro <lupus@ximian.com>
2141 * metadata.h, metadata.c: add mono_metadata_decode_row_col () to
2142 decode a single column from a row in a metadata table and changes
2143 to take advantage of it in the typedef locator (gives a nice speed up).
2144 Store offset info for function params.
2146 2001-08-02 Dietmar Maurer <dietmar@ximian.com>
2148 * image.h (MONO_IMAGE_IS_CORLIB): removed
2150 Wed Aug 1 22:54:08 CEST 2001 Paolo Molaro <lupus@ximian.com>
2152 * assembly.c: how could mono_assembly_close () had ever worked?
2153 * metadata.c, metadata.h: provide offset info for local vars.
2154 Implement mono_type_size () to take care of alignment as well
2155 as size (it was mono_field_type_size in cli/class.c before).
2157 2001-08-01 Dietmar Maurer <dietmar@ximian.com>
2159 * image.h (MONO_IMAGE_IS_CORLIB): new macro to check root image
2161 * assembly.h (CORLIB_NAME): set to corlib.dll
2163 * assembly.c (mono_assembly_open): replaced strcmp() with !strcmp()
2165 Tue Jul 31 17:54:02 CEST 2001 Paolo Molaro <lupus@ximian.com>
2167 * metadata.h, metadata.c, Makefile.am, private.h, assembly.c, blob.h,
2168 cil-coff.h, image.c, image.h, pedump.c, rawbuffer.c, rawbuffer.h, row-indexes.h,
2169 tokentype.h: massive namespace cleanup.
2171 Mon Jul 30 20:11:01 CEST 2001 Paolo Molaro <lupus@ximian.com>
2173 * metadata.h, metadata.c: decode exception clauses when parsing method header.
2175 2001-07-27 Dietmar Maurer <dietmar@ximian.com>
2177 * metadata.c (mono_metadata_free_type): added check for type !=
2178 NULL (void) before calling mono_metadata_free_type()
2180 Thu Jul 26 19:11:19 CEST 2001 Paolo Molaro <lupus@ximian.com>
2182 * metadata.h, row_indexes.h: added header with enumerations to use
2183 to index in the columns from tables in metadata and to decode coded
2184 tokens: we should start using this instead of embedding magic numbers
2187 Thu Jul 26 13:03:27 CEST 2001 Paolo Molaro <lupus@ximian.com>
2189 * assembly.c, cil-coff.h, image.c, image.h, pedump.c, typedef.c:
2190 Move metadata_t info from cli_image_info_t to MonoImage, where
2191 it's easily accessible. Changed all the uses accordingly.
2192 Added the method and class caches to MonoImage.
2193 * metadata.c, metadata.h: Changed mono_metadata_decode_blob_size ()
2194 and mono_metadata_decode_value () signature to be more consistent
2195 with the other parse functions (and simplify code). Taken advantage
2196 of zero-length array allocation with GCC. Removed reduntant (and
2197 wrong) MonoFieldType struct and use MonoParam instead. Changed
2198 mono_metadata_parse_field_type () to use common code for parsing.
2199 Added mono_metadata_typedef_from_field () and
2200 mono_metadata_typedef_from_method () to lookup a typedef index from a
2201 field or method token.
2202 Pack the MonoRetType structure more tightly (fits in 8 bytes now).
2204 2001-07-23 Miguel de Icaza <miguel@ximian.com>
2206 * metadata.c (mono_metadata_parse_field_type): Implement.
2207 (do_mono_metadata_parse_type): Split engine from
2208 mono_metadata_parse_type, so that we can create smaller structures
2209 for things that just have one pointer to the MonoType (look at
2212 2001-07-20 Miguel de Icaza <miguel@ximian.com>
2214 * metadata.c (mono_metadata_parse_mh): Correct the implementation,
2215 as Jan Gray found out, it is incorrect.
2217 2001-07-18 Miguel de Icaza <miguel@ximian.com>
2219 * assembly.c: Implement asssembly loading. This loads an image
2220 and loads all the referenced assemblies. Come to think of it, we
2221 could always do lazy loading of the assemblies.
2223 * image.c (mono_image_open): Keep loaded images in a hashtable.
2225 * image.h (MonoImage): Add reference count.
2227 2001-07-17 Miguel de Icaza <miguel@ximian.com>
2229 * assembly.c (mono_assembly_open): Keep track of the file name in
2230 case the assembly has no ASSEMBLY table.
2232 * metadata.h: Fixed Paolo's quick hack. Put the documnentation
2235 Sun Jul 15 19:39:06 CEST 2001 Paolo Molaro <lupus@ximian.com>
2237 * metadata.c, metadata.h: decode local vars in method header
2238 parse function. Change callers accordingly.
2240 Sun Jul 15 17:40:47 CEST 2001 Paolo Molaro <lupus@ximian.com>
2242 * metadata.h, cil-coff.h: protect against multiple inclusion.
2243 Added some new structures to hold information decoded from metadata:
2244 MonoType, MonoParam, MonoArray, MonoMethod, MonoMethodSignature
2245 and relevant decoding/free functions.
2246 * metadata.c: implement decoding functions. Add warning for out of bounds
2247 index in mono_metadata_locate(). Implement mono_get_method () to retreive
2248 all the info about a method signature and invocation. Remove check on
2249 uninitialized local var in parse_mh() and fix memory leak.
2251 2001-07-12 Miguel de Icaza <miguel@ximian.com>
2253 * metadata.h: More macros.
2255 * tokentype.h: New file.
2257 Fri Jul 6 11:30:53 CEST 2001 Paolo Molaro <lupus@ximian.com>
2259 * assembly.c: added a consistency check and initialize
2260 some structures with g_new0().
2261 * metadata.c: fixed a couple more bugs in table size computation
2262 and add other checks for out-of bound access to metadata.
2264 Thu Jul 5 22:34:21 CEST 2001 Paolo Molaro <lupus@ximian.com>
2266 * metatada.c: fix bugs computing table sizes. Spew a
2267 warning when index in string heap is out of bounds.
2269 2001-07-04 Miguel de Icaza <miguel@ximian.com>
2271 * metadata.h: Add a couple of macros to manipulate tokens.
2273 Tue Jul 3 18:33:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
2275 * assembly.c: g_free(ii->cli_sections) (and avoid double free of
2276 cli_section_tables).
2278 2001-07-01 Miguel de Icaza <miguel@ximian.com>
2280 * metadata.c (mono_metadata_user_string): New function, provides
2281 access to the UserString heap.
2283 2001-06-27 Miguel de Icaza <miguel@ximian.com>
2285 * metadata.c: Add inline documentation.
2287 2001-06-26 Miguel de Icaza <miguel@ximian.com>
2289 * propertyattr.h, paramattr.h, methodsem.h, methodattr.h: New
2292 2001-06-22 Miguel de Icaza <miguel@ximian.com>
2294 * typeattr.h: New file, TypeAttribute flags.
2296 2001-06-21 Miguel de Icaza <miguel@ximian.com>
2298 * mono/metadata/assembly.c (mono_assembly_ensure_section_idx,
2299 mono_assembly_ensure_section): Section loading code.
2300 (load_section_tables): Load the sections.
2302 * mono/metadata/metadata.c (mono_metadata_locate_token,
2303 mono_metadata_locate): Functions to locate the information
2304 definition given a token or a table and an index.
2305 (mono_metadata_compute_table_bases): New.
2306 (compute_size): New function to compute the sizes of the various
2309 * mono/metadata/metadata.h: Finish listing the different index
2312 * mono/metadata/pedump.c: Improve to dump new information.
2314 2001-06-19 Miguel de Icaza <miguel@ximian.com>
2316 * mono/metadata/metadata.c: Entered all the tables matching
2319 * mono/metadata/assembly.c (load_metadata_ptrs): Fix for Beta2