Compare commits

..
236 Commits
Author SHA1 Message Date
Zoltan Varga 852c512d41 2009-03-11 Zoltan Varga <[email protected]>
* mini-amd64.c (mono_arch_output_basic_block): Fix % 1. Fixes #484323.

	* basic.cs: Add a test.

svn path=/branches/mono-2-2/mono/; revision=129067
2009-03-11 14:30:17 +00:00
Zoltan Varga 1b70679e3e 2009-03-06 Zoltan Varga <[email protected]>
Backport of r128749.
	
	* method-to-ir.c (mini_emit_memset): Fix the handling of size '3'. Fixes
	#481458.

	* iltests.il.in: Add a test.

svn path=/branches/mono-2-2/mono/; revision=128750
2009-03-06 02:39:49 +00:00
Zoltan Varga 73d9bb32a6 2009-02-14 Zoltan Varga <[email protected]>
Backport of r126897.

	* method-to-ir.c (mini_emit_ldelema_1_ins): If the array index is a long,
	convert it to an in32. Fixes #475859.

	* arrays.cs: Add a test.

svn path=/branches/mono-2-2/mono/; revision=126899
2009-02-14 00:05:50 +00:00
Zoltan Varga c67ee64dbc 2009-02-11 Zoltan Varga <[email protected]>
Backport of 126604.

	* branch-opts.c (mono_if_conversion): Handle the case where the merged 
	basic block fell through to its successor bblock without a branch. Fixes
	#474718.

	* iltests.il.in: Add a test.

svn path=/branches/mono-2-2/mono/; revision=126605
2009-02-11 14:35:29 +00:00
Mark Probst 86356a38e9 2009-02-10 Mark Probst <[email protected]>
Backport of r126467.

	* mini-x86.c (mono_arch_context_get_int_reg): Handle all registers
	individually.  Fixes #473482.

2009-02-10  Mark Probst  <[email protected]>

	Backport of r126467.

	* bug-473482.2.cs: New test.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=126468
2009-02-10 15:13:38 +00:00
Mark Probst 32221b04b3 2009-02-05 Mark Probst <[email protected]>
Backport of r125887.

	* object.c (mono_object_get_virtual_method): Properly inflate
	generic methods.  Fixes #472692.

2009-02-05  Mark Probst  <[email protected]>

	Backport of r125887.

	* jit-icalls.c (mono_helper_compile_generic_method): Don't inflate
	the method we get from mono_object_get_virtual_method() because
	that function does it properly, now.

2009-02-05  Mark Probst  <[email protected]>

	Backport of r125887.

	* bug-472692.2.cs: New test.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=125892
2009-02-05 17:39:37 +00:00
Mark Probst 356450cc39 2009-02-05 Mark Probst <[email protected]>
Backport of r125839.

	* mini-exceptions.c (ves_icall_get_frame_info): Account for the
	fact that mono_find_jit_info() sometimes returns the context
	corresponding to the jit info in new_ctx.  Fixes #472600.

2009-02-05  Mark Probst  <[email protected]>

	Backport of r125839.

	* bug-472600.2.cs: New test.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=125846
2009-02-05 11:25:02 +00:00
Marek Habersack a0c3015347 Backport of r125663
svn path=/branches/mono-2-2/mcs/; revision=125665
2009-02-04 10:46:24 +00:00
Mark Probst 537966c822 2009-02-03 Mark Probst <[email protected]>
Backport of r125565.

	* generic-sharing.c: Don't hold domain lock when calling
	instantiate_other_info().  Fixes #471958.

	* domain-internals.h, loader.c: Describe locking policy of domain
	lock vs loader lock.

svn path=/branches/mono-2-2/mono/; revision=125567
2009-02-03 18:32:01 +00:00
Mark Probst abb91fa21b 2009-02-02 Mark Probst <[email protected]>
Backport of r125388.

	* generic-sharing.c (lookup_or_register_other_info): Make sure the
	loader lock is not taken while the templates lock is held.  Fixes
	#471089.

svn path=/branches/mono-2-2/mono/; revision=125389
2009-02-02 18:44:43 +00:00
Mark Probst 963ad4c4e6 2009-02-02 Mark Probst <[email protected]>
Backport or r125371.

	* metadata.c (type_in_image): Added a check to fix a monodis
	crash.

svn path=/branches/mono-2-2/mono/; revision=125374
2009-02-02 16:55:46 +00:00
Rodrigo Kumpera ef98b2ea25 2009-02-01 Rodrigo Kumpera <[email protected]>
Backport of r125205.

	* cpu-arm.md: Increase the size of storer8_membase_reg and
	loadr8_membase_reg to 24 bytes to accomodate the extra add.

	* mini-arm.c (mono_arch_output_basic_block): Under FPA, when emitting
	OP_STORER8_MEMBASE_REG and OP_LOADR8_MEMBASE_REG, add the original
	reg to LR otherwise we'll be loading/storing from just the offset.


svn path=/branches/mono-2-2/mono/; revision=125340
2009-02-02 11:55:03 +00:00
Marek Habersack 93fcd7a7f4 Backport of r125111.
svn path=/branches/mono-2-2/mcs/; revision=125113
2009-01-30 16:54:08 +00:00
Mark Probst ea1e9c57b3 2009-01-27 Mark Probst <[email protected]>
Backport of r124712.

	* method-to-ir.c (emit_stloc_ir): Only apply the reg-reg move
	optimization if the top of stack is the last instruction in the
	bblock.  Otherwise it might have been used after its definition.
	Fixes #469742.

2009-01-27  Mark Probst  <[email protected]>

	Backport of r124712.

	* bug469742.2.il: New test.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=124713
2009-01-27 21:22:47 +00:00
Jeffrey Stedfast 94b968af6d 2009-01-26 Jeffrey Stedfast <[email protected]>
* mono-mutex.[c,h]: Removed GPLv2 copyright notice which should
	not have been there.


svn path=/branches/mono-2-2/mono/; revision=124698
2009-01-27 19:05:03 +00:00
Zoltan Varga 3d34404a43 2009-01-26 Zoltan Varga <[email protected]>
Backport of r124456.

	* exceptions-amd64.c (mono_arch_exceptions_init): Call 
	get_throw_pending_exception () to avoid initialization races.

	* mini-exceptions.c (mono_exceptions_init): Call an arch specific
	mono_arch_exceptions_init () function.

svn path=/branches/mono-2-2/mono/; revision=124461
2009-01-26 06:51:37 +00:00
Gonzalo Paniagua Javier 86d332be05 Backported fixes from HEAD
svn path=/branches/mono-2-2/mcs/; revision=124454
2009-01-26 05:06:30 +00:00
Zoltan Varga ecb00b219a 2009-01-25 Zoltan Varga <[email protected]>
* Backport of r123987.

	* method-to-ir.c (method-to-ir.c): Add support for the constrained prefix
	on type variables in AOTed code.

svn path=/branches/mono-2-2/mono/; revision=124425
2009-01-25 13:10:46 +00:00
Mark Probst 6a6444c9c9 2009-01-23 Mark Probst <[email protected]>
Backport of r124022 and r124301.

	* metadata.c (mono_metadata_generic_param_equal): Owner as well as
	image must match.  Only compare the image if the owner is NULL.
	Fixes the AOT failures.

svn path=/branches/mono-2-2/mono/; revision=124304
2009-01-23 09:25:56 +00:00
Zoltan Varga e737e00b1a 2009-01-23 Zoltan Varga <[email protected]>
Backport of r124268.
	
	* metadata.c (mono_metadata_load_generic_params): Initialize the 
	MonoGenericParam structure using memset so the image field is initialized
	as well.

svn path=/branches/mono-2-2/mono/; revision=124269
2009-01-22 23:46:48 +00:00
Mark Probst bcf8b5091d 2009-01-22 Mark Probst <[email protected]>
Backport of r124246.

	* mini-exceptions.c (ves_icall_get_frame_info): Fetch the generic
	info from the (correct) context.

2009-01-22  Mark Probst  <[email protected]>

	Backport of r124246.

	* generic-stack-traces2.2.cs: Another generic sharing test for
	stack traces.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=124247
2009-01-22 21:02:07 +00:00
Zoltan Varga 053c79514a Revert r124024 as it is breaking AOT.
svn path=/branches/mono-2-2/mono/; revision=124100
2009-01-21 20:14:12 +00:00
Rodrigo Kumpera 9d06cece5e Forgot to add the file.
svn path=/branches/mono-2-2/mono/; revision=124099
2009-01-21 20:09:38 +00:00
Zoltan Varga 096ffd7c34 2009-01-21 Zoltan Varga <[email protected]>
Backport of r124092.
	
	* method-to-ir.c (handle_alloc): Avoid generic instances in the
	out_of_line optimization.

svn path=/branches/mono-2-2/mono/; revision=124094
2009-01-21 19:34:01 +00:00
Rodrigo Kumpera 6696bf386c 2009-01-21 Rodrigo Kumpera <[email protected]>
Backport of r124059.

	* appdomain-unload-callback.cs: New test for the AppDomain::DomainUnload
	deadlock.

	* Makefile.am: Test added.


svn path=/branches/mono-2-2/mono/; revision=124078
2009-01-21 18:13:53 +00:00
Rodrigo Kumpera 70748269a9 2009-01-21 Rodrigo Kumpera <[email protected]>
Backport of r124068.

	* appdomain.c (mono_domain_unload): Change the InterlockedIncrement to
	a plain store.

2009-01-21 Rodrigo Kumpera  <[email protected]>

	Backport of r124058.

	* domain-internals.h: Add new appdomain state MONO_APPDOMAIN_UNLOADING_START
	which signals that the unloading has started but all appdomain services must
	remain operational.

	* appdomain.c (mono_domain_unload): The initial state for unloading now
	is unloading_start and we switch to unloading after the managed call to
	AppDomain::DomainUnload has finished.

	The new unloading state has to be created because managed code in the
	DomainUnload event can depend on things like the threadpool still working.
	The domain must remain fully functional while the event executes.

	This shown as an issue due to Process::WaitForExit, which waits for
	async reads of stdout and stderr to complete. Since those are processed
	in the threadpool the code deadlocks because the DomainUnload callback 
	waits for the async read finished event, which should have been set by a
	threadpool job but has been discarded due to the domain been in unload
	state.


svn path=/branches/mono-2-2/mono/; revision=124074
2009-01-21 18:06:36 +00:00
Zoltan Varga 30032b29cd 2009-01-21 Zoltan Varga <[email protected]>
Backport of r124065.
	
	* class.c (mono_class_setup_vtable_general): In the generic instance
	optimization, set method->slot for abstract virtual methods. Fixes part of
	#467834.

svn path=/branches/mono-2-2/mono/; revision=124066
2009-01-21 17:40:10 +00:00
Mark Probst 933e43a263 2009-01-21 Mark Probst <[email protected]>
Backport of r124028.

	* method-to-ir.c: Only apply exception constructor optimization if
	the the method actually belongs to an exception class.  Fixes
	#467456.

2009-01-21  Mark Probst  <[email protected]>

	Backport of r124028.

	* bug-467456.cs: New test case.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=124030
2009-01-21 12:28:42 +00:00
Mark Probst 6492b054d6 2009-01-21 Mark Probst <[email protected]>
Backport of r124022.

	* metadata.c (mono_metadata_generic_param_equal): Owner as well as
	image must match.

2009-01-21  Mark Probst  <[email protected]>

	Backport of r124022.

	* generic-unloading.2.cs, generic-unloading-sub.2.cs: Test case
	for unloading images whose MonoGenericInst's are still in use.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=124024
2009-01-21 10:54:12 +00:00
Zoltan Varga 25af8d5d73 2008-11-24 Zoltan Varga <[email protected]>
Backport of r123968.
	
	* freebsd-elf_common.h (struct): Use uint32_t instead of 
	u_int32_t to fix the build on opensolaris.

svn path=/branches/mono-2-2/mono/; revision=123970
2009-01-21 00:24:09 +00:00
Mark Probst 85c4ae8316 2009-01-21 Mark Probst <[email protected]>
Backport of r123959.

	* TypeBuilderTest.cs: Add test for fields in dynamic generic
	classes.

svn path=/branches/mono-2-2/mcs/; revision=123961
2009-01-20 23:36:27 +00:00
Mark Probst 3cb0fc7f4d 2009-01-21 Mark Probst <[email protected]>
Backport of r123958.

	* reflection.c (resolve_object): For fields, inflate the class and
	then get the field in the inflated class.

svn path=/branches/mono-2-2/mono/; revision=123960
2009-01-20 23:36:01 +00:00
Mark Probst c63dbe44a0 2009-01-20 Mark Probst <[email protected]>
Backport of r123917.

	* method-to-ir.c: Force the vtable variable in shared generic code
	for the case that they might show up on a stack trace where they
	are needed.

	* mini-exceptions.c: Save and use generic sharing info as well as
	IP in stack traces to resolve shared generic instantiations.

2009-01-20  Mark Probst  <[email protected]>

	Backport of r123917.

	* class.c (mono_class_has_parent_and_ignore_generics),
	class-internals.h: Made non-static.

	* object-internals.h (struct _MonoException): Added a comment
	explaining the new use of trace_ips.

2009-01-20  Mark Probst  <[email protected]>

	Backport of r123917.

	* generic-stack-traces.2.cs: Generic sharing test for stack
	traces.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=123920
2009-01-20 20:43:04 +00:00
Gonzalo Paniagua Javier 68603e532d 2009-01-20 Gonzalo Paniagua Javier <[email protected]>
* IPAddress.cs: handle sign extension for the high byte when using the
	byte[] ctor for an IPv4 address.
	Fixes bug #467472.


svn path=/branches/mono-2-2/mcs/; revision=123857
2009-01-20 06:32:22 +00:00
Gonzalo Paniagua Javier 7b5c17946a 2009-01-19 Gonzalo Paniagua Javier <[email protected]>
* Socket.cs: don't throw when there's no ipv6 configuration.


svn path=/branches/mono-2-2/mcs/; revision=123833
2009-01-19 22:26:39 +00:00
Zoltan Varga e0a84ddbdb 2009-01-19 Zoltan Varga <[email protected]>
Backport of r123812.
	
	* loader.c (search_in_array_class): Call mono_class_setup_methods () before
	accessing klass->methods. Fixes #467385.

svn path=/branches/mono-2-2/mono/; revision=123814
2009-01-19 16:22:21 +00:00
Zoltan Varga 846a52cd5c 2009-01-18 Zoltan Varga <[email protected]>
* marshal9.cs: Change a test to be compatible with MS.NET.

svn path=/branches/mono-2-2/mono/; revision=123804
2009-01-19 15:23:31 +00:00
Zoltan Varga 68e00cea15 2009-01-18 Zoltan Varga <[email protected]>
Backport of r123756.
	
	* marshal.c (emit_marshal_custom): Avoid calling MarshalNativeToManaged
	for byval arguments without an [Out] attribute. Fixes #467212.

svn path=/branches/mono-2-2/mono/; revision=123803
2009-01-19 15:21:41 +00:00
Rodrigo Kumpera 54da54bb00 2009-01-19 Rodrigo Kumpera <[email protected]>
Backport of r123754.

	* mini.c (mini_thread_cleanup): Don't cleanup TLS storage if the
	thread been cleaned up is not the same currently in execution.

	Fixes appdomain-unload crashes on windows, osx and linux variants
	without the __thread keyword.


svn path=/branches/mono-2-2/mono/; revision=123785
2009-01-19 12:04:29 +00:00
Zoltan Varga 32663e9c0e 2009-01-13 Zoltan Varga <[email protected]>
Backport of r123258.
	
	* mini.c (SIG_HANDLER_SIGNATURE): Avoid crashes when the current thread or
	domain is not set. Fixes #465864.

svn path=/branches/mono-2-2/mono/; revision=123725
2009-01-18 01:49:23 +00:00
Zoltan Varga b8610e3e69 2009-01-16 Zoltan Varga <[email protected]>
Backport of r123642.
	
	* threads.c (mono_threads_abort_appdomain_threads): Abort threads outside the
	threads_lock () to prevent deadlocks.

svn path=/branches/mono-2-2/mono/; revision=123723
2009-01-18 01:35:54 +00:00
Gonzalo Paniagua Javier e7cedf88ca 2009-01-16 Gonzalo Paniagua Javier <[email protected]>
* FtpWebRequest.cs: adjust to the correct directory when listing too.
	Fixes bug #466530.


svn path=/branches/mono-2-2/mcs/; revision=123615
2009-01-16 15:39:32 +00:00
Zoltan Varga d97de79bed 2009-01-16 Zoltan Varga <[email protected]>
Backport of r123612.
	
	* configure.in: Avoid error messages in the quiet code if libgc/Makefile
	does not exist yet. Fixes #466814.

svn path=/branches/mono-2-2/mono/; revision=123613
2009-01-16 15:30:14 +00:00
Gonzalo Paniagua Javier 5f5755c06d 2009-01-15 Gonzalo Paniagua Javier <[email protected]>
* HttpListenerRequest.cs: always initialize 'version'.
	* HttpConnection.cs: the socket might already be disconnected when
	shutting down.


svn path=/branches/mono-2-2/mcs/; revision=123454
2009-01-15 06:08:10 +00:00
Gonzalo Paniagua Javier ed9b8414df 2009-01-14 Gonzalo Paniagua Javier <[email protected]>
* WebConnectionStream.cs: if the buffer has been killed, return -1 for
	its length. Fixes regression in System.Runtime.Remoting.


svn path=/branches/mono-2-2/mcs/; revision=123450
2009-01-15 04:56:55 +00:00
Zoltan Varga 8d47eeeaa1 2009-01-14 Zoltan Varga <[email protected]>
Backport of r123417.
	
	* CILCompiler.cs: Avoid throwing exceptions for a few more unhandled opcodes.
	Implement the reverse/ignorecase versions of Reference. Fix the reverse
	version of Bitmap. Error out if a Jump opcode jumps outside the current
	pc range. This works around #466151.

svn path=/branches/mono-2-2/mcs/; revision=123420
2009-01-14 21:37:31 +00:00
Mark Probst d8a160b7a4 2009-01-14 Mark Probst <[email protected]>
Backport of r123349.

	* method-to-ir.c: Handle delegate invocation optimization earlier,
	otherwise it would be handled (much more slowly) by the
	final/sealed optimization.

svn path=/branches/mono-2-2/mono/; revision=123351
2009-01-14 13:33:25 +00:00
Dean Brettle 6e8c67a141 ++ System.Web/ChangeLog (working copy)
* HttpApplicationFactory.cs: if there are any *.browser files in
	App_Data/Mono_Machine_Browsers/, use those instead of the default
	machine browser files.  This allows app developers to workaround
	limitations with Mono's default browser files without causing
	incompatibilities with MS's implementation.

++ System.Web.Configuration_2.0/ChangeLog	(working copy)

	* nBrowser/Node.cs: Fixed compatibility bug where <identification> sections were required
	in browser defs.  


svn path=/branches/mono-2-2/mcs/; revision=123257
2009-01-13 21:17:11 +00:00
Gonzalo Paniagua Javier 3c838b72eb 2009-01-13 Gonzalo Paniagua Javier <[email protected]>
* HttpWebRequest.cs: keepAlive is of no use here.
	Fixes bug #465613.


svn path=/branches/mono-2-2/mcs/; revision=123253
2009-01-13 20:51:59 +00:00
Gonzalo Paniagua Javier a21f9bf1d7 2009-01-13 Gonzalo Paniagua Javier <[email protected]>
* HttpConnection.cs: we were not writing the headers for 0-length
	responses.
	* WebConnectionStream.cs: for 204/304 responses with an explicit
	content-length of 0, release the socket only once.
	Fixes bug #465638.


svn path=/branches/mono-2-2/mcs/; revision=123251
2009-01-13 20:34:15 +00:00
Zoltan Varga bc979a3e55 2009-01-13 Zoltan Varga <[email protected]>
Backport of r123201.
	
	* marshal.c: Avoid setting the exception clauses after a method has been entered 
	into the wrapper caches. Fixes #465700.

	* method-builder.c (mono_mb_set_clauses): New function to set the clauses of the
	method builder.
	(mono_mb_create_method): Set the clauses from the method builder.

svn path=/branches/mono-2-2/mono/; revision=123203
2009-01-13 16:03:49 +00:00
Gonzalo Paniagua Javier 74a8df7e80 applied patch from bug #260588
svn path=/branches/mono-2-2/mcs/; revision=123175
2009-01-13 05:30:27 +00:00
Gonzalo Paniagua Javier 9daea760e4 applied patch from bug #260588
svn path=/branches/mono-2-2/mcs/; revision=123174
2009-01-13 05:28:08 +00:00
Gonzalo Paniagua Javier 6caf03c5f6 2009-01-12 Gonzalo Paniagua Javier <[email protected]>
* FtpWebRequestTest.cs: test deleting a file.


svn path=/branches/mono-2-2/mcs/; revision=123138
2009-01-12 22:06:14 +00:00
Gonzalo Paniagua Javier 47a9b8fe75 2009-01-12 Gonzalo Paniagua Javier <[email protected]>
* FtpWebRequest.cs: now deleting a file works when we're not in the
	root directory.


svn path=/branches/mono-2-2/mcs/; revision=123137
2009-01-12 22:05:25 +00:00
Zoltan Varga e6a5c4fec1 2008-12-16 Zoltan Varga <[email protected]>
Backport of r123092.
	
	* marshal.c (mono_marshal_get_synchronized_wrapper): Make the 
	initialization of the various _method variables thread safe. Fixes
	#465377.

svn path=/branches/mono-2-2/mono/; revision=123095
2009-01-12 17:03:23 +00:00
Marek Habersack 4462c4c8cf Backport of r123084.
svn path=/branches/mono-2-2/mcs/; revision=123086
2009-01-12 16:08:39 +00:00
Zoltan Varga 208db37519 2009-01-08 Zoltan Varga <[email protected]>
Backport of r122804.
	
	* method-to-ir.c (mono_method_to_ir): Fix the check for the mscorlib ldstr 
	optimization. Fixes #464520.

svn path=/branches/mono-2-2/mono/; revision=122920
2009-01-09 17:03:52 +00:00
Zoltan Varga 470791b186 2009-01-09 Zoltan Varga <[email protected]>
Backport of r122907.
	
	* CustomAttributeData.cs (ToString): Applied patch from Leszek Ciesielski
	<[email protected]>. Use DeclaringType.FullName instead of DeclaringType.Name.
	Fixes #464830.

svn path=/branches/mono-2-2/mcs/; revision=122909
2009-01-09 16:05:52 +00:00
Marek Habersack 3887d81f8e Backport of r122891.
svn path=/branches/mono-2-2/mcs/; revision=122892
2009-01-09 14:38:26 +00:00
Geoff Norton 11072be5ed 2009-01-08 Geoff Norton <[email protected]>
* processes.c: Fix the osx version check to properly detect 10.5 v 10.4

svn path=/branches/mono-2-2/mono/; revision=122853
2009-01-09 02:32:27 +00:00
Marek Habersack 4291f2a73b Backport of r122839.
svn path=/branches/mono-2-2/mcs/; revision=122841
2009-01-08 23:51:36 +00:00
Rusty Howell 5b8bf83ccd simple checkin to trigger build
svn path=/branches/mono-2-2/mono/; revision=122733
2009-01-08 02:15:25 +00:00
Zoltan Varga 1fd0386f87 2008-12-16 Zoltan Varga <[email protected]>
* class.c (mono_class_get_fields): Handle loading errors.

svn path=/branches/mono-2-2/mono/; revision=122714
2009-01-07 21:00:16 +00:00
Zoltan Varga 9de1e8b272 2009-01-07 Zoltan Varga <[email protected]>
Backport of 122702.
	
	* mini-arm.c (mono_arch_flush_icache): Use __GNUC_PREREQ instead of checking
	__GNUC_MINOR__ which can break when the major version changes.

svn path=/branches/mono-2-2/mono/; revision=122704
2009-01-07 20:10:21 +00:00
Zoltan Varga c02bd27e8f 2009-01-07 Zoltan Varga <[email protected]>
Backport of r122700.
	
	* RxInterpreter.cs: Add support for constant strings in anchors. Fixes
	#464135.

svn path=/branches/mono-2-2/mcs/; revision=122701
2009-01-07 19:51:33 +00:00
Rodrigo Kumpera c146e4e4fd In metadata:
Backport of r122672 - r122675.

	* file-io.c (ves_icall_System_IO_MonoIO_GetCurrentDirectory): Double check the
	return value of GetCurrentDirectory to never access unitialized memory.

	* file-io.c (ves_icall_System_IO_MonoIO_GetCurrentDirectory): Properly check the
	return value of GetCurrentDirectory and expand the buffer if needed.

	Fixes #459094.

2009-01-07 Rodrigo Kumpera  <[email protected]>

In io-layer:
2009-01-07 Rodrigo Kumpera  <[email protected]>

	Backport of r122672 - r122675.

	* io.c (GetCurrentDirectory): Avoid calling g_get_current_dir straight
	away as it doesn't handle ENAMETOOLONG correctly. As a bonus we avoid
	allocating memory in the common path.

In tests:
2009-01-07 Rodrigo Kumpera  <[email protected]>

	Backport of r122672 - r122675.

	* bug-459094	.cs: New regression test.

	* Makefile.am: Test added.


svn path=/branches/mono-2-2/mono/; revision=122678
2009-01-07 17:18:06 +00:00
Rodrigo Kumpera 331427f067 In metadata:
2009-01-07 Rodrigo Kumpera  <[email protected]>

	Backport of r122579 - r122585.

	* verify.c (mono_class_interface_implements_interface): Verify parents as we can't rely on
	interfaces_packed here.

	Fixes part of #463294.

	* verify.c (is_array_type_compatible): Ignore bounds and sizes when checking array compatibility.

	Fixes part of #463294.

	* verify.c (stack_slot_is_complex_type_not_reference_type): Check if the type
	is a boxed complex as well.

	Fixes part of #463294.

In tests/verifier:
2009-01-07 Rodrigo Kumpera <[email protected]>

	Backport of r122579 - r122585.

	* valid_iface_constant_with_parent_implementing_it.il:
	Regression test for #461200.

	* valid_array_compat_with_bonds_and_sizes.il:
	* valid_array_compat_with_bounds.il:
	* valid_array_compat_with_sizes.il: Regression tests for 
	#461200.

	* valid_ceq_with_boxed_vt.il: Regression test for #461200.


svn path=/branches/mono-2-2/mono/; revision=122650
2009-01-07 12:48:50 +00:00
Geoff Norton 37bbac467f 2009-01-07 Geoff Norton <[email protected]>
* processes.c: Only use open -W on OSX 10.5+.  Patch from
        Miguel

svn path=/branches/mono-2-2/mono/; revision=122619
2009-01-07 06:32:03 +00:00
Rodrigo Kumpera 5161c62e10 2009-01-07 Rodrigo Kumpera <[email protected]>
* Vector*.cs: Use explicit layout to avoid the runtime
	miscalculating the size of vector types.

	Backported from trunk.


svn path=/branches/mono-2-2/mcs/; revision=122608
2009-01-07 04:10:17 +00:00
Gonzalo Paniagua Javier 9458c03da1 ignore test. Bug 464013
svn path=/branches/mono-2-2/mcs/; revision=122603
2009-01-07 02:54:15 +00:00
Zoltan Varga 6179d4a924 2009-01-07 Zoltan Varga <[email protected]>
* AsyncTest.cs: Disable these tests, they fail randomly (bug #463999).

svn path=/branches/mono-2-2/mcs/; revision=122600
2009-01-07 01:21:25 +00:00
Marek Safar 58216b41fb Put back temporary disabled fix.
svn path=/branches/mono-2-2/mcs/; revision=122578
2009-01-06 21:32:06 +00:00
Marek Safar 30a744498e Try to revert major Banshee bug fix.
svn path=/branches/mono-2-2/mcs/; revision=122501
2009-01-05 23:23:19 +00:00
Marek Safar c253f26bc3 Update.
svn path=/branches/mono-2-2/mcs/; revision=122473
2009-01-05 17:58:21 +00:00
Zoltan Varga 6017bcd4ae 2009-01-05 Zoltan Varga <[email protected]>
* branch-opts.c (mono_if_conversion): Fix another assert introduced by
	the last change.

svn path=/branches/mono-2-2/mono/; revision=122472
2009-01-05 17:32:03 +00:00
Zoltan Varga 561cb241d9 2009-01-05 Zoltan Varga <[email protected]>
Backport of r122452.
	
	* mini.c (mono_allocate_stack_slots_full2): Use mono_class_from_mono_type
	instead of directly accessing type->data.klass. Fixes #462016.
	(mono_allocate_stack_slots_full): Ditto.

svn path=/branches/mono-2-2/mono/; revision=122453
2009-01-05 13:22:31 +00:00
Federico Di Gregorio 1fcf34271b Added missing property Extend to Mono.Cairo.Pattern
svn path=/branches/mono-2-2/mcs/; revision=122441
2009-01-05 12:09:40 +00:00
Marek Safar f2de867101 2009-01-05 Marek Safar <[email protected]>
A fix for bug #457257
	* decl.cs: Fixed incorrect member declaring type comparison.


svn path=/branches/mono-2-2/mcs/; revision=122439
2009-01-05 11:49:57 +00:00
Zoltan Varga 992e22f306 2009-01-05 Zoltan Varga <[email protected]>
* configure.in: Disable sigaltstack on freebsd as it doesn't seem to work.

svn path=/branches/mono-2-2/mono/; revision=122422
2009-01-05 09:12:31 +00:00
Zoltan Varga 0c65fe81ed 2009-01-05 Zoltan Varga <[email protected]>
Backport of r122416.
	
	* mini-arm.c (mono_arch_flush_icache): Applied patch from Riku Voipio 
	<[email protected]>. Fix cache flush on kernels without OLDABI compat option.

svn path=/branches/mono-2-2/mono/; revision=122417
2009-01-05 09:00:19 +00:00
Zoltan Varga 6887168dc2 2009-01-04 Zoltan Varga <[email protected]>
Backport of r122392.
	
	* branch-opts.c (mono_if_conversion): Fix an assert introduced by the last
	change.

svn path=/branches/mono-2-2/mono/; revision=122393
2009-01-04 18:48:29 +00:00
Zoltan Varga 87b0e91eff 2009-01-04 Zoltan Varga <[email protected]>
Backport of r122386.
	
	* branch-opts.c (mono_if_conversion): Use branch->inst_true_bb/inst_false_bb
	instead of bblock->out_bb [0]/[1], the two might not be the same. Fixes
	#463357.

	* iltests.il.in: Add a regression test.

svn path=/branches/mono-2-2/mono/; revision=122387
2009-01-04 01:54:44 +00:00
Zoltan Varga 883c60f9a9 2008-11-27 Mark Probst <[email protected]>
Backport of r120164.
	
	* marshal.c (mono_string_builder_to_utf8): Fixed a wrong
	invocation to g_utf16_to_utf8().

svn path=/branches/mono-2-2/mono/; revision=122373
2009-01-03 18:38:36 +00:00
Rodrigo Kumpera 1fc3eea4d1 2009-01-04 Rodrigo Kumpera <[email protected]>
Backport of r122364.

	* basic-simd.cs: Add a regression test for #462457.




svn path=/branches/mono-2-2/mono/; revision=122367
2009-01-03 15:16:52 +00:00
Rodrigo Kumpera ce5e64372c 2009-01-04 Rodrigo Kumpera <[email protected]>
Backport of r122363.

	* mini-ops.h: Add a definition of XPHI.

	* mini.h (MONO_IS_PHI): Make is aware of simd instrincs. 

	* ssa.c (op_phi_to_move): Handle XPHI.

	* ssa.c (mono_ssa_compute): Generate a XPHI for simd intrinsics instead of VPHI.

	Fixes #462457


svn path=/branches/mono-2-2/mono/; revision=122366
2009-01-03 15:16:21 +00:00
Marek Safar eb766b843d 2009-01-02 Marek Safar <[email protected]>
A fix for bug #463121
	* nullable.cs: Fixed nullable user quality operator comparison.


svn path=/branches/mono-2-2/mcs/; revision=122346
2009-01-02 17:48:33 +00:00
Marek Safar dbb88b930b 2009-01-02 Marek Safar <[email protected]>
A fix for bug #462592
	* pending.cs: Emit type arguments for generic proxy method.


svn path=/branches/mono-2-2/mcs/; revision=122331
2009-01-02 12:58:07 +00:00
Massimiliano Mantione 701ec25f87 Merged the profiler documentation from trunk (r122288).
svn path=/branches/mono-2-2/mono/; revision=122290
2008-12-31 11:19:53 +00:00
Massimiliano Mantione 56157b091b Make the profiler like r122287 on trunk.
svn path=/branches/mono-2-2/mono/; revision=122289
2008-12-31 11:19:08 +00:00
Marek Safar 91506c541c 2008-12-30 Marek Safar <[email protected]>
* expression.cs (As): Mutate all type arguments.


svn path=/branches/mono-2-2/mcs/; revision=122233
2008-12-30 11:41:14 +00:00
Marek Safar 5deb2e0f97 2008-12-29 Marek Safar <[email protected]>
A fix for bug #462622
	* anonymous.cs: Resolve anonymous type GetHashCode in unchecked
	context.


svn path=/branches/mono-2-2/mcs/; revision=122179
2008-12-29 11:24:29 +00:00
Marek Safar f0bac9e0b7 2008-12-29 Marek Safar <[email protected]>
A fix for bug #450782
	* ecore.cs: Consider more variables of form V.I to be fixed.


svn path=/branches/mono-2-2/mcs/; revision=122178
2008-12-29 09:34:02 +00:00
Zoltan Varga 6d9fa806ea 2008-12-29 Zoltan Varga <[email protected]>
Backport of r122170.

	* mini.c (mono_jit_compile_method_inner): Avoid holding the domain lock
	while loading AOT methods.

svn path=/branches/mono-2-2/mono/; revision=122171
2008-12-29 01:14:57 +00:00
Zoltan Varga 2ee594eee6 2008-12-29 Zoltan Varga <[email protected]>
Backport of r122168.
	
	* mini-exceptions.c: Check jit_tls->class_cast_from instead of class_cast_to
	since only the former is nulled out after a successful cast. This prevents
	crashes with rethrown exceptions when using --debug=casts.

svn path=/branches/mono-2-2/mono/; revision=122169
2008-12-29 00:57:10 +00:00
Rodrigo Kumpera fd92d87ed0 2008-12-26 Rodrigo Kumpera <[email protected]>
Backport of r122134.

	* bug-461261.cs: New regression test.

	* Makefile.am: Test added.


svn path=/branches/mono-2-2/mono/; revision=122137
2008-12-26 19:44:13 +00:00
Rodrigo Kumpera 2bc209f4f4 2008-12-26 Rodrigo Kumpera <[email protected]>
Backport of r122133.

	* class.c (get_implicit_generic_array_interfaces): If the internal
	enumerator is an interface inflate System.Object instead of itself.

	Fixes #461261.


svn path=/branches/mono-2-2/mono/; revision=122136
2008-12-26 19:36:34 +00:00
Mark Probst f73e839351 2008-12-24 Mark Probst <[email protected]>
Backport of r122086.

	* mini.h: New macro for checking whether a method is final,
	i.e. whether the method or its class is marked final.

	* method-to-ir.c: Use the new macro for all final-checks
	consistently.  Fixes the crash in the System.ServiceModel tests.

2008-12-24  Mark Probst  <[email protected]>

	Backport of r122086.

	* generic-sealed-virtual.2.cs: Test case for final generic
	methods.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=122087
2008-12-24 11:43:01 +00:00
Mark Probst f6e12de276 2008-12-24 Mark Probst <[email protected]>
* mini-ppc.c (mono_arch_build_imt_thunk): Fix the build.

svn path=/branches/mono-2-2/mono/; revision=122079
2008-12-24 09:19:42 +00:00
Rodrigo Kumpera e5af45cdb3 2008-12-24 Rodrigo Kumpera <[email protected]>
Backport of r122071.

	* bug-461941.cs: New regression test.

	* Makefile.am: Test added.


svn path=/branches/mono-2-2/mono/; revision=122076
2008-12-24 05:00:44 +00:00
Rodrigo Kumpera 2491b3dbb2 2008-12-24 Rodrigo Kumpera <[email protected]>
Backport of r122070.

	* object.c (mono_runtime_invoke_array): Don't assert with
	byref nullable types.

	* marshal.c (mono_marshal_get_runtime_invoke): To handle
	byref nullables we unbox the object and store it on the
	stack. 
	We can't use the boxed object since it is the T of Nullable<T>
	and the boxed representation of a nullable it's underlying type
	or null.
	We could cheat and create a boxed nullable and use the same
	machinery of other byref VTs but this feels like a hack and
	using the stack has the bonus of reducing heap pressure.

	Fixes #461941.


svn path=/branches/mono-2-2/mono/; revision=122075
2008-12-24 04:58:24 +00:00
Mark Probst ef11247772 2008-12-23 Mark Probst <[email protected]>
Backport of r122034.

	* mini-ppc.c (mono_arch_build_imt_thunk): Save and restore r11.
	Clobbering it is not allowed because the caller might use it as
	the vtable register in the interface call.

svn path=/branches/mono-2-2/mono/; revision=122058
2008-12-23 20:54:22 +00:00
Mark Probst 370bf41989 2008-12-23 Mark Probst <[email protected]>
* mini-exceptions.c (get_exception_catch_class): Removed another
	overly strict assertion.  Fixes #461198.

2008-12-23  Mark Probst  <[email protected]>

	* bug-461198.2.cs: New generic sharing test.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=122040
2008-12-23 16:10:40 +00:00
Rodrigo Kumpera 9e79a22008 2008-12-23 Rodrigo Kumpera <[email protected]>
Backport of r122036.

	* bug-461867.cs: New regression test.

	* Makefile.am: Test added.


svn path=/branches/mono-2-2/mono/; revision=122039
2008-12-23 15:37:32 +00:00
Rodrigo Kumpera da54730380 2008-12-23 Rodrigo Kumpera <[email protected]>
Backport of r122035.

 	* marshal.c (mono_marshal_emit_managed_wrapper): Handle char
 	return value.
 
 	Fixes #461867.


svn path=/branches/mono-2-2/mono/; revision=122038
2008-12-23 15:37:02 +00:00
Ivan Zlatev 3a433af16e 2008-12-22 Ivan N. Zlatev <[email protected]>
* ReferenceConverter.cs: Implemented.
	* ReferenceConverterTest.cs: Added.
	[Fixes bug #381435]

svn path=/branches/mono-2-2/mcs/; revision=122033
2008-12-23 10:52:51 +00:00
Veerapuram Varadhan 6fdda55b42 * SqlXmlTest.cs: Available only in 2.0 and above
svn path=/branches/mono-2-2/mcs/; revision=122008
2008-12-22 20:50:59 +00:00
Jonathan Pobst cdc69e8e9e Backport Ivan's patch to 2.2.
2008-11-30  Ivan N. Zlatev  <[email protected]>

	* GroupBoxRenderer.cs: Fix when VisualStyles disabled:
	   - No caption text is drawn because Color.Empty is used.
	   - Fix top and height off by 1.
	[Fixes bug #448764]

svn path=/branches/mono-2-2/mcs/; revision=121993
2008-12-22 18:30:50 +00:00
Veerapuram Varadhan d67fd7ce3a Add new SqlXmlTest
svn path=/branches/mono-2-2/mcs/; revision=121960
2008-12-21 03:45:53 +00:00
Veerapuram Varadhan d195b62b9d * SqlXml.cs (CreateReader): Better use
ConformanceLevel.Fragment while creating the reader as column
        values are not really Xml documents.  Also, throw
        SqlNullValueException when data is null.
        (.ctor): Take good care of empty XmlReaders.



svn path=/branches/mono-2-2/mcs/; revision=121959
2008-12-21 03:41:39 +00:00
Miguel de Icaza 3e90298aa1 Backport
svn path=/branches/mono-2-2/mcs/; revision=121935
2008-12-20 19:19:00 +00:00
Miguel de Icaza 8ae9f4eace Backport to 2.2
svn path=/branches/mono-2-2/mcs/; revision=121933
2008-12-20 19:15:12 +00:00
Mark Probst 08038cbf3b 2008-12-19 Mark Probst <[email protected]>
* mini-exceptions.c (get_exception_catch_class): Removed overly
	strict assertion.

2008-12-19  Mark Probst  <[email protected]>

	* bug-459285.2.cs: New generic sharing test.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=121840
2008-12-19 12:42:38 +00:00
Mark Probst 7e7c65d58f 2008-12-19 Mark Probst <[email protected]>
Backport of r121292.

        * method-to-ir.c: Removed an unnecessary assertion.

2008-12-19  Mark Probst  <[email protected]>

        Backport of r121292.

        * metadata/generic-sharing.c: Look for constraints in all type
        arguments, not just the first one.

2008-12-19  Mark Probst  <[email protected]>

        Backport of r121292.

        * generic-marshalbyref.2.cs: Test for calls to marshal-by-ref
        objects.

        * Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=121836
2008-12-19 10:39:22 +00:00
Gonzalo Paniagua Javier 4bf06608d3 2008-11-18 Gonzalo Paniagua Javier <[email protected]>
* HttpConnection.cs: remove CWL. When reusing, BeginReadRequest might
	throw if the client closes.
	* HttpListenerResponse.cs: close the connection for 1.0 clients.

	Backported from HEAD. Fixes bug #459432.

svn path=/branches/mono-2-2/mcs/; revision=121830
2008-12-19 04:38:03 +00:00
Marek Habersack 3aad6c2f07 Backport of r121819.
svn path=/branches/mono-2-2/mcs/; revision=121820
2008-12-18 23:39:41 +00:00
Marek Safar 26f04c283d 2008-12-18 Marek Safar <[email protected]>
A fix for bug #457087
	* generic.cs: Don't crash when constraint comes from type
	declaration.


svn path=/branches/mono-2-2/mcs/; revision=121769
2008-12-18 10:57:12 +00:00
Marek Habersack e03981495b Backport of r121752.
svn path=/branches/mono-2-2/mcs/; revision=121753
2008-12-18 01:19:10 +00:00
Veerapuram Varadhan 0f766fceaf * OciDefineHandle.cs (GetValue): Use connection's environment
handle instead of Parent handle.


svn path=/branches/mono-2-2/mcs/; revision=121734
2008-12-17 23:09:58 +00:00
Geoff Norton cd51852dd8 2008-12-17 Geoff Norton <[email protected]>
* threadpool.c: Ensure that the io_queue_lock is initialized
        in all circumstances, as we always attempt to cleanup against it.

svn path=/branches/mono-2-2/mono/; revision=121724
2008-12-17 20:10:09 +00:00
Miguel de Icaza 0a5a292db4 Backport 2008-12-17 Miguel de Icaza <[email protected]>
* icall.c (ves_icall_System_Environment_get_Platform): For
	compatibility reasons for existing client code we will keep
	returning 4 for a while.   

	For how long will depend on the documentation being updated, and
	for us to give client code a chance to be updated.

	This reverts the original decison on #433108 since we did not
	catch roughly 33 instances of the broken code in our own source
	code base, we did not catch failures on the buildbots, and QA did
	not bring this as a problem.

	Only today I found some customer's code breaking due to our own
	class libraries not being fully updated and tracked it down to
	this change.  I am reverting it because if we could not even get
	our story straight in our own code base, how can we hope that our
	end user code be fixed?

	As of this morning, our Wiki page that documents how to detect
	Unix had not been fixed.    

svn path=/branches/mono-2-2/mono/; revision=121716
2008-12-17 18:14:40 +00:00
Rolf Bjarne Kvinge b3c5bdfa7f 2008-12-12 Rolf Bjarne Kvinge <[email protected]>
* Makefile.am, vbnc.1: Remove vbnc.1. It's living in the
	  mono-basic module now.

	  [Backport of r121406.]


svn path=/branches/mono-2-2/mono/; revision=121678
2008-12-17 12:08:43 +00:00
Martin Baulig fc77b903af 2008-12-16 Martin Baulig <[email protected]>
Backport of r120438.

	* method-to-ir.c (mono_method_to_ir): Disable debugging
	information for the init locals block to make the debugger stop
	after all locals have been initalized.


svn path=/branches/mono-2-2/mono/; revision=121640
2008-12-16 22:08:59 +00:00
Martin Baulig ff74079dc1 2008-12-02 Martin Baulig <[email protected]>
Backport of r120419.

	* mini.c (mini_method_compile): Disable MONO_OPT_DEADCE when
	running inside the debugger.


svn path=/branches/mono-2-2/mono/; revision=121639
2008-12-16 22:06:18 +00:00
Martin Baulig ed3174a8b7 2008-12-16 Martin Baulig <[email protected]>
Backport of r120407 from Zoltan Varga.

	* mini.c (mini_method_compile): Only run local deadce if MONO_OPT_DEADCE
	is enabled.

	* method-to-ir.c (mono_method_to_ir): Fix invalid code generated by the 
	alu->alu imm optimization which only shows if deadce is disabled.


svn path=/branches/mono-2-2/mono/; revision=121638
2008-12-16 22:03:08 +00:00
Marek Habersack 4485172658 Backport of r121636.
svn path=/branches/mono-2-2/mcs/; revision=121637
2008-12-16 22:01:42 +00:00
Martin Baulig 7ca53d801a 2008-11-29 Martin Baulig <[email protected]>
Backport of r120260.

	* mini-exceptions.c (mono_handle_native_sigsegv): Check
	mono_debug_using_mono_debugger() in addition to the
	`no_gdb_backtrace' flag in the `MonoDebugOptions'.


svn path=/branches/mono-2-2/mono/; revision=121635
2008-12-16 21:51:34 +00:00
Marek Habersack b34dcd83c4 Backport of r121629.
svn path=/branches/mono-2-2/mono/; revision=121630
2008-12-16 21:06:06 +00:00
Gonzalo Paniagua Javier 07d8da1481 revert
svn path=/branches/mono-2-2/mcs/; revision=121628
2008-12-16 20:38:58 +00:00
Marek Habersack ae5b023940 Backport of r121621.
svn path=/branches/mono-2-2/mcs/; revision=121622
2008-12-16 19:00:52 +00:00
Zoltan Varga 9fa4d42782 2008-12-14 Zoltan Varga <[email protected]>
Backport of r120389.
	
	* method-to-ir.c (mono_method_to_ir): Set the type of the value pushed on
	the stack in CEE_LDFLDA. Fixes #450542.

	* generics.cs: Add a new test.

svn path=/branches/mono-2-2/mono/; revision=121564
2008-12-16 00:11:01 +00:00
Marek Habersack 98bcd46dd1 Backport of r121557.
svn path=/branches/mono-2-2/mono/; revision=121560
2008-12-15 22:44:51 +00:00
Zoltan Varga c373ddd111 2008-12-14 Zoltan Varga <[email protected]>
Backport of r121496.
	
	* liveness.c (mono_analyze_liveness): Avoid eliminating the 'this' var in
	gshared code. Fixes #458947.

	* generics.cs: Add a test.

svn path=/branches/mono-2-2/mono/; revision=121497
2008-12-14 09:50:57 +00:00
Zoltan Varga b93c12250d 2008-12-12 Zoltan Varga <[email protected]>
Backport of r121457.
	
	* mini-arm.c tramp-arm.c: Fix calls to mono_arch_flush_icache.

svn path=/branches/mono-2-2/mono/; revision=121458
2008-12-12 19:51:40 +00:00
Dean Brettle 67a9b038c5 Changes approved via private email from Marek Habersack <[email protected]> on 2008-10-05.
In System.Web.Configuration_2.0:
2008-12-11  Owen Brady <[email protected]>
	* nBrowser/File.cs, nBrowser/Identification.cs, nBrowser/Node.cs, nBrowser/NodeTypes.cs,
	nBrowser/Result.cs, nBrowser/Build.cs, nBrowser/Exception.cs, CapabilitiesBuild.cs, 
	CapabilitiesResult.cs: Updated Copyright information to include updated contact information.
	
	* nBrowser/Build.cs: Removed LoadDefaultEmbeddedResource function, the embeded resource
	it is referring too was never included in Mono. And was designed for a free standing 
	browser identification libary.

	* nBrowser/Exception.cs: Removed Compile Attributes and related comments which were left
	in from the original free standing browser libary.
	
	* CapabilitiesBuild.cs: Removed Header Checksum related coding since it is not required
	for the Mono implementation.

	* CapabilitiesResult.cs: Updated Copyright information to include updated contact information. 
	Removed functions which were designed to make use of features of a embeded browser file which
	is not present in Mono.
	
	* CapabilitiesChecksum.cs, RandomRoboBotKeywords.txt: Deleted

In .:
2008-12-11  Dean Brettle  <[email protected]>

	* System.Web.dll.sources: deleted
	System.Web.Configuration_2.0/CapabilitiesChecksum.cs
	
	* Makefile (RESOURCE_FILES_2): deleted
	System.Web.Configuration_2.0/RandomRoboBotKeywords.txt


svn path=/branches/mono-2-2/mcs/; revision=121384
2008-12-12 00:52:06 +00:00
Rodrigo Kumpera dc330f3d57 In tests:
2008-12-08  Rodrigo Kumpera  <[email protected]>

	* bug457574.il: New regression test.

	* Makefile.am: Test added.

	Backported from trunk r121174.

In mini:
2008-12-10  Rodrigo Kumpera  <[email protected]>

	* ssa.c (fold_ins): branch opt can kill dummy switch ops so we can't
	expect that an OP_BR_REG will be there.

	* branch-opts.c (remove_block_if_useless): Use MONO_IS_BRANCH_OP instead of checking
	for the many branch ops. The original check miss OP_BR_REG.

	Fixes #457574.

	Backported from trunk r121173 and r121175


svn path=/branches/mono-2-2/mono/; revision=121210
2008-12-10 13:09:08 +00:00
Zoltan Varga 9fe47f55e3 2008-12-09 Zoltan Varga <[email protected]>
Backport of r121150.
	
	* aot-runtime.c (load_method): Avoid calling decode_exception_debug_info
	while holding the aot lock.

svn path=/branches/mono-2-2/mono/; revision=121152
2008-12-09 20:14:00 +00:00
Andrés G. Aragoneses 657e5df419 fix changelog
svn path=/branches/mono-2-2/mcs/; revision=121118
2008-12-09 17:08:37 +00:00
Zoltan Varga 1511ce89c6 2008-12-09 Zoltan Varga <[email protected]>
Backport of r121103.
	
	* aot-runtime.c (decode_exception_debug_info): Acquire the domain
	lock when calling mono_domain_alloc (). Hopefully fixes #415608.

svn path=/branches/mono-2-2/mono/; revision=121104
2008-12-09 16:07:01 +00:00
Marek Habersack 05e0f11430 Backport of r121064.
svn path=/branches/mono-2-2/mcs/; revision=121065
2008-12-08 23:44:55 +00:00
Zoltan Varga 06cddce9b0 2008-12-08 Zoltan Varga <[email protected]>
Backport of r120999.
	
	* mini-exceptions.c (mono_print_thread_dump): Mark threadpool threads
	as such. Fixes #456669.

svn path=/branches/mono-2-2/mono/; revision=121000
2008-12-08 15:03:39 +00:00
Zoltan Varga 3e3c9edc91 2008-12-08 Zoltan Varga <[email protected]>
Backport of r120995.
	
	* SQLite3.cs: Avoid IntPtr.ToInt32 () to convert between IntPtr's and integers
	since it is not 64 bit safe. Fixes #457038.

svn path=/branches/mono-2-2/mcs/; revision=120996
2008-12-08 14:50:59 +00:00
Marek Habersack 24d7fea4ca Backport of r120988.
svn path=/branches/mono-2-2/mcs/; revision=120989
2008-12-08 12:04:01 +00:00
Marek Habersack 691a2cf225 Backport of r120880
svn path=/branches/mono-2-2/mono/; revision=120883
2008-12-05 20:37:26 +00:00
Marek Habersack 296607e9b1 Fix a test run issue for 1.1
svn path=/branches/mono-2-2/mcs/; revision=120860
2008-12-05 18:05:44 +00:00
Gonzalo Paniagua Javier ee79b6f908 2008-12-05 Gonzalo Paniagua Javier <[email protected]>
* Tds70.cs: support parameter names with or without a leading '@'.


svn path=/branches/mono-2-2/mcs/; revision=120855
2008-12-05 17:18:56 +00:00
Marek Habersack 9844a237ea Backport of r120823.
svn path=/branches/mono-2-2/mcs/; revision=120825
2008-12-05 12:01:37 +00:00
Marek Habersack 9a817effa9 Backport of r120822.
svn path=/branches/mono-2-2/mcs/; revision=120824
2008-12-05 12:00:14 +00:00
Miguel de Icaza 9a2e1ccef4 Backport ReaderWriterLockSlim for MEF
svn path=/branches/mono-2-2/mcs/; revision=120768
2008-12-04 22:03:09 +00:00
Zoltan Varga fbfb1742ed 2008-12-04 Zoltan Varga <[email protected]>
Backport of r120756.
	
	* aot-compiler.c (add_wrappers): Add pinvoke wrappers.

	* mini.c (mono_resolve_patch_target): Allow pinvoke methods in 
	MONO_PATCH_INFO_ICALL_ADDR.

svn path=/branches/mono-2-2/mono/; revision=120757
2008-12-04 21:04:20 +00:00
Zoltan Varga 547f83ca27 2008-12-04 Zoltan Varga <[email protected]>
* marshal.c (mono_marshal_emit_native_wrapper): Add AOT support for pinvoke
	wrappers by emitting the function address using a CEE_MONO_ICALL_ADDR 
	instruction instead of a pointer constant.

svn path=/branches/mono-2-2/mono/; revision=120750
2008-12-04 20:48:32 +00:00
Marek Safar 73bd2d2941 2008-12-03 Marek Safar <[email protected]>
* typemanager.cs, namespace.cs, driver.cs: Allow ExtensionAttribute
	to be imported from any assembly.


svn path=/branches/mono-2-2/mcs/; revision=120629
2008-12-03 19:49:33 +00:00
Gonzalo Paniagua Javier e6a317bc40 2008-12-03 Gonzalo Paniagua Javier <[email protected]>
* UdpClientTest.cs: test closing a UDP socket while receiving.


svn path=/branches/mono-2-2/mcs/; revision=120605
2008-12-03 15:35:50 +00:00
Gonzalo Paniagua Javier bfdcf61509 2008-12-03 Gonzalo Paniagua Javier <[email protected]>
* UdpClient.cs: don't Poll() in Receive(), the call to ReceiveFrom
	will block anyway. Fixes bug #455894.

2008-11-12 Gonzalo Paniagua Javier <[email protected]>

	* Socket.cs: mark the socket as not connected when there is a pending
	error or exception about to be thrown.
	Bug #443346 fixed.


svn path=/branches/mono-2-2/mcs/; revision=120602
2008-12-03 15:33:28 +00:00
Mark Probst a1f8c0800d 2008-12-03 Mark Probst <[email protected]>
Backport of r120589.

	* method-to-ir.c (mono_method_to_ir): Handle ldtoken of an open
	generic type (via a typedef or typeref) correctly.

2008-12-03  Mark Probst  <[email protected]>

	Backport of r120589.

	* generic-typedef.2.cs: New test for ldtoken of open generic
	types.

	* Makefile.am: Test added.

svn path=/branches/mono-2-2/mono/; revision=120595
2008-12-03 14:22:24 +00:00
Marek Habersack 861c4f8f12 Backport of r120592.
svn path=/branches/mono-2-2/mcs/; revision=120593
2008-12-03 13:55:22 +00:00
Marek Habersack 7af8c9351d Backport of r120590.
svn path=/branches/mono-2-2/mcs/; revision=120591
2008-12-03 13:33:22 +00:00
Rodrigo Kumpera 7155c65bfd 2008-12-03 Rodrigo Kumpera <[email protected]>
* mono-property-hash.c (mono_property_hash_destroy): Release
	the root hashtable as well.

	Backported from trunk.


svn path=/branches/mono-2-2/mono/; revision=120587
2008-12-03 12:31:09 +00:00
Gonzalo Paniagua Javier f20c4ece0c 2008-12-02 Gonzalo Paniagua Javier <[email protected]>
* AspParser.cs: reset to the next character in a partial match in case
	of failure. Fixes bug #314688.

svn path=/branches/mono-2-2/mcs/; revision=120552
2008-12-03 00:17:54 +00:00
Gonzalo Paniagua Javier 45efaf51b3 2008-12-02 Gonzalo Paniagua Javier <[email protected]>
* Page.cs: make sure we don't return null in Title.


svn path=/branches/mono-2-2/mcs/; revision=120551
2008-12-03 00:17:25 +00:00
Marek Habersack de0321f109 Backport of r120545.
svn path=/branches/mono-2-2/mono/; revision=120546
2008-12-02 23:13:43 +00:00
Zoltan Varga 71864e55c4 2008-12-03 Zoltan Varga <[email protected]>
Backport of r120543.
	
	* mini-trampolines.c (mono_magic_trampoline): Add some debugging code to help
	diagnose an assertion failure.

svn path=/branches/mono-2-2/mono/; revision=120544
2008-12-02 23:04:35 +00:00
Miguel de Icaza 92aa367629 backport the fix for erase/delete for OSX
svn path=/branches/mono-2-2/mcs/; revision=120539
2008-12-02 21:57:01 +00:00
Marek Habersack a7e3109c66 Backport of r120485.
svn path=/branches/mono-2-2/mcs/; revision=120486
2008-12-02 14:28:23 +00:00
Marek Habersack 0c68cd806a Backport of r120442.
svn path=/branches/mono-2-2/mcs/; revision=120444
2008-12-02 01:36:46 +00:00
Marek Habersack 8098dbe758 Backport of r120436.
svn path=/branches/mono-2-2/mcs/; revision=120437
2008-12-02 01:08:01 +00:00
Rodrigo Kumpera 50619fe4f4 2008-12-01 Rodrigo Kumpera <[email protected]>
* main.c (get_uninitialized_data_type): Make crappy static analyzers happy.

	Backported from trunk.


svn path=/branches/mono-2-2/mono/; revision=120417
2008-12-01 23:28:37 +00:00
Marek Habersack b4c5181a77 Backport of r120376.
svn path=/branches/mono-2-2/mcs/; revision=120377
2008-12-01 19:33:50 +00:00
Marek Habersack f20b93ecf7 Backport of r120353.
svn path=/branches/mono-2-2/mcs/; revision=120354
2008-12-01 14:45:31 +00:00
Marek Habersack 2023460027 Backport of r120345.
svn path=/branches/mono-2-2/mcs/; revision=120346
2008-12-01 12:35:03 +00:00
Zoltan Varga d44a27c9e1 2008-11-29 Zoltan Varga <[email protected]>
Backport of r120273.
	
	* mini.h aot-runtime.c: Fix building with DISABLE_AOT.

svn path=/branches/mono-2-2/mono/; revision=120283
2008-11-29 20:28:25 +00:00
Zoltan Varga cf1ccdc254 2008-11-29 Zoltan Varga <[email protected]>
Backport of r120273.
	
	* mini.h aot-runtime.c: Fix building with DISABLE_AOT.

svn path=/branches/mono-2-2/mono/; revision=120274
2008-11-29 17:00:46 +00:00
Marek Habersack ce427d5af1 Backport of r120199
svn path=/branches/mono-2-2/mcs/; revision=120200
2008-11-28 01:44:16 +00:00
Marek Habersack a78027248b Backport of r120047
svn path=/branches/mono-2-2/mcs/; revision=120107
2008-11-27 02:04:58 +00:00
Gonzalo Paniagua Javier 7d3335da20 2008-11-25 Gonzalo Paniagua Javier <[email protected]>
* pedump.c: initialize perf. counters. Fixes a segv.


svn path=/branches/mono-2-2/mono/; revision=119980
2008-11-25 17:41:38 +00:00
Marek Safar a21f8151eb 2008-11-25 Marek Safar <[email protected]>
A fix for bug #447027
	* anonymous.cs (HoistedVariable): Cache also outer access to deal
	with context variables stored as expression instances.


svn path=/branches/mono-2-2/mcs/; revision=119967
2008-11-25 16:29:53 +00:00
Gonzalo Paniagua Javier ddb21259f1 2008-11-13 Gonzalo Paniagua Javier <[email protected]>
* FtpWebRequestTest.cs: the upload test now passes with the MS
	runtime. Added another test for download.



svn path=/branches/mono-2-2/mcs/; revision=119913
2008-11-25 02:13:22 +00:00
Gonzalo Paniagua Javier 2664cc24dc 2008-11-13 Gonzalo Paniagua Javier <[email protected]>
* FtpDataStream.cs: use the socket for reading until the end of a
	stream that wasn't read entirely. Remove unused ManualResetEvent.
	* FtpWebRequest.cs: set the file_name when downloading. Update the
	response status after every SendCommand. Send a "OPTS utf8 on" as MS
	does (the control cnc reader should do something with UTF8)


svn path=/branches/mono-2-2/mcs/; revision=119912
2008-11-25 02:10:49 +00:00
Marek Habersack f445544ba8 those need to be in there as well
svn path=/branches/mono-2-2/mcs/; revision=119911
2008-11-25 01:47:27 +00:00
Marek Habersack fe7bbc9da1 This needs to be here too :P
svn path=/branches/mono-2-2/mcs/; revision=119910
2008-11-25 01:46:30 +00:00
Marek Habersack 1b3d62f26e This needs to be here too :P
svn path=/branches/mono-2-2/mcs/; revision=119909
2008-11-25 01:44:55 +00:00
Marek Habersack 1b578615c6 Backport of r119699
svn path=/branches/mono-2-2/mcs/; revision=119908
2008-11-25 01:28:55 +00:00
Marek Habersack 54c0e1e47f Backport of r119893
svn path=/branches/mono-2-2/mcs/; revision=119906
2008-11-25 01:27:45 +00:00
Marek Habersack cd105f51c1 Backport of r119800
svn path=/branches/mono-2-2/mcs/; revision=119905
2008-11-25 01:27:24 +00:00
Marek Habersack af1e7f3096 Backport of r119673
svn path=/branches/mono-2-2/mcs/; revision=119904
2008-11-25 01:26:37 +00:00
Marek Habersack 544c381f9f Backport of r119661
svn path=/branches/mono-2-2/mcs/; revision=119902
2008-11-25 01:23:35 +00:00
Marek Habersack 64c2b9fea8 Backport of r119126
svn path=/branches/mono-2-2/mcs/; revision=119901
2008-11-25 01:22:48 +00:00
Marek Habersack ad443c3edf Backport of r119378
svn path=/branches/mono-2-2/mcs/; revision=119898
2008-11-25 01:10:41 +00:00
Marek Habersack f83478e9f0 Backport of r119269
svn path=/branches/mono-2-2/mcs/; revision=119897
2008-11-25 01:10:13 +00:00
Marek Habersack 6ff666ba9f Backport of r119233
svn path=/branches/mono-2-2/mcs/; revision=119896
2008-11-25 01:09:43 +00:00
Marek Habersack 5a4faa0dbe Backport of r119130
svn path=/branches/mono-2-2/mcs/; revision=119895
2008-11-25 01:09:06 +00:00
Marek Habersack 560afb2c8c Backport of r118917
svn path=/branches/mono-2-2/mcs/; revision=119894
2008-11-25 01:08:29 +00:00
Marek Habersack df6dcb4bc3 Backport of r119827
svn path=/branches/mono-2-2/mcs/; revision=119829
2008-11-24 18:48:26 +00:00
Jonathan Pobst ae55ffa9b3 2008-11-24 Jonathan Pobst <[email protected]>
* Form.cs: Don't change min/max size if it is empty.
	[Fixes bug #447873]

2008-11-23  Jonathan Pobst  <[email protected]>

	* FormTest.cs: Add test for bug #447873.

svn path=/branches/mono-2-2/mcs/; revision=119813
2008-11-24 17:05:25 +00:00
Jonathan Pobst 3fd6b5713d 2008-11-21 Jonathan Pobst <[email protected]>
* XPlatUI.cs: Take new Platform.MacOSX into account.
	[Fixes bug #447663]

svn path=/branches/mono-2-2/mcs/; revision=119638
2008-11-21 17:07:43 +00:00
Rodrigo Kumpera 71fbfc7a0a 2008-11-21 Rodrigo Kumpera <[email protected]>
* icall.c (mono_method_get_equivalent_method): Make sure
	method->klass->methods is inited before looping over it.

	Backported from trunk.


svn path=/branches/mono-2-2/mono/; revision=119613
2008-11-21 14:15:07 +00:00
Andreia Gaita 2d97201acc * Mono.Mozilla/DOM/ContentListener.cs: Added (oops)
2008-11-21  Andreia Gaita <[email protected]>

svn path=/branches/mono-2-2/mcs/; revision=119612
2008-11-21 14:06:56 +00:00
Andreia Gaita d6717fd548 * System.Drawing/Image.cs: On win32, when cloning images initialized from
resources, also clone the underlying stream, since it needs to stay
  around for the life of the image (gdi doesn't clone the underlying
  stream when cloning images, so when the gc disposes the original, it
  will also dispose the stream, which invalidates the clone).

* System.Drawing/Bitmap.cs: Save the underlying stream when creating bitmaps from a
  clone under win32

* System.Drawing.Imaging/Metafile.cs: Save the underlying stream when creating from a
  clone under win32

[fixes #438886, Backported from r119580]

2008-11-21  Andreia Gaita  <[email protected]>

svn path=/branches/mono-2-2/mcs/; revision=119581
2008-11-21 05:50:55 +00:00
Jonathan Pobst 4e17e21b2a 2008-11-20 Jonathan Pobst <[email protected]>
* ComboBox.cs: Call HideWindow instead of Hide when closing the dropdown
	through DroppedDown so the proper events get called and state gets reset.
	[Fixes bug #446805]

svn path=/branches/mono-2-2/mcs/; revision=119561
2008-11-21 00:23:09 +00:00
Andreia Gaita 3dc556e23b * Mono.WebBrowser/IWebBrowser.cs, Mono.Mozilla/WebBrowser.cs: Support script
execution directly in the browser object
  [Backported, r118685]

2008-11-20  Andreia Gaita <[email protected]>

svn path=/branches/mono-2-2/mcs/; revision=119494
2008-11-20 19:19:56 +00:00
Andreia Gaita 24b03dbeb3 * Mono.Mozilla/DOM/Node.cs, Mono.Mozilla/DOM/Window.cs: Fix equality
operators
  [Backported, r118684, r119336]

2008-11-20  Andreia Gaita <[email protected]>

svn path=/branches/mono-2-2/mcs/; revision=119493
2008-11-20 19:19:51 +00:00
Andreia Gaita ce37fb5dfb * Mono.WebBrowser.dll.sources, Mono.WebBrowser2K5.csproj,
Mono.Mozilla/interfaces/nsIURIContentListener.cs,
  Mono.Mozilla/DOM/ContentListener.cs: New class added to listen for load
  requests and handle content types
* Mono.WebBrowser/IWebBrowser.cs, Mono.Mozilla/WebBrowser.cs: New
  NavigationRequested event to catch load requests

[Backported, r118617]

2008-11-20  Andreia Gaita <[email protected]>

svn path=/branches/mono-2-2/mcs/; revision=119492
2008-11-20 19:19:47 +00:00
Zoltan Varga f4bb6280cd 2008-11-20 Zoltan Varga <[email protected]>
Backport of r119444.
	
	* arm/Makefile.am (libmonoarch_arm_la_SOURCES): Don't build tramp.c, it is only
	used by the interpreter.

svn path=/branches/mono-2-2/mono/; revision=119445
2008-11-20 14:30:04 +00:00
Zoltan Varga bc76b7d785 2008-11-20 Zoltan Varga <[email protected]>
Backport of r119398.
	
	* pinvoke2.cs: Add a test for passing/receiving generic struct instances.

svn path=/branches/mono-2-2/mono/; revision=119400
2008-11-20 00:22:29 +00:00
Zoltan Varga e538bc771d 2008-11-20 Zoltan Varga <[email protected]>
Backport of r119397.
	
	* marshal.c: Add support for MONO_TYPE_GENERICINST to some functions.
	Fixes #444715. Fix a warning.

svn path=/branches/mono-2-2/mono/; revision=119399
2008-11-20 00:21:27 +00:00
Jonathan Pryor 5334d00d47 * Makefile.am (EXTRA_DIST): Add mono-file-formats{.config,.source} and
mono-tools{.config,.source} (fixes the build).

svn path=/branches/mono-2-2/mono/; revision=119304
2008-11-19 13:09:00 +00:00
Jonathan Pryor e43c207e12 * docs.make, Makefile.am: Build mono-file-formats{.tree,.zip},
mono-tool{.tree,.zip} files.
	* mono-file-formats.config, mono-tools.config: Alter paths to man
	  pages so that they're valid for building from mono/docs.
	* monoapi.make: Rename to docs.make.

svn path=/branches/mono-2-2/mono/; revision=119260
2008-11-19 02:27:54 +00:00
Jonathan Pryor ea6508481f * docs/Makefile: Don't build mono-file-formats.*, mono-tools.*
* docs/mono-file-formats.config, docs/mono-file-formats.source, 
	  docs/mono-tools.config, docs/mono-tools.source: Removed (now located 
	  in mono/docs).

svn path=/branches/mono-2-2/mcs/; revision=119259
2008-11-19 02:27:31 +00:00
Jonathan Pryor 6ed0b0bd5d These files need to move into mono/docs to fix
https://bugzilla.novell.com/show_bug.cgi?id=445156

svn path=/branches/mono-2-2/mono/; revision=119256
2008-11-19 02:22:52 +00:00
Bill Holmes 2514e975c3 2008-11-17 Bill Holmes <[email protected]>
Backport of 119064 and 119081.

	* marshal.h : cominterop_ccw_getfreethreadedmarshaler added to return the
	  free threaded marshaler when QueryInterface is called on a COM callable
	  wrapper requesting the IMarshal interface.

	Code is contributed under MIT/X11 license.

svn path=/branches/mono-2-2/mono/; revision=119088
2008-11-17 21:05:37 +00:00
Rodrigo Kumpera 882ffb10b4 2008-11-17 Rodrigo Kumpera <[email protected]>
* FieldInfoTest.cs: Test FieldInfo::GetValue on a constant of an open
	generic type.

	Backported from trunk.


svn path=/branches/mono-2-2/mcs/; revision=119079
2008-11-17 18:55:56 +00:00
Rodrigo Kumpera a1a664dbcd 2008-11-17 Rodrigo Kumpera <[email protected]>
* MonoField.cs (GetValue): Don't check for open generic types if the field
	is a constant.

	Backported from trunk.


svn path=/branches/mono-2-2/mcs/; revision=119078
2008-11-17 18:55:16 +00:00
Rodrigo Kumpera 9ff5304841 2008-11-17 Rodrigo Kumpera <[email protected]>
* simd-intrinsics.c (vector2l_intrinsics): CompareGreaterThan requires sse 4.2
	and not 4.1. 

	Backported from trunk.


svn path=/branches/mono-2-2/mono/; revision=119065
2008-11-17 18:00:08 +00:00
Rodrigo Kumpera bac3152d94 2008-11-17 Rodrigo Kumpera <[email protected]>
* Vector2l.cs (CompareGreaterThan): This method requires sse 4.2
	and 4.1.

	Backported from trunk.


svn path=/branches/mono-2-2/mcs/; revision=119062
2008-11-17 17:22:18 +00:00
Marek Safar 02f76440bb 2008-11-17 Marek Safar <[email protected]>
A fix for bug #445303
	* location.cs (IsConditionalDefined): Handle undefined global
	defines.


svn path=/branches/mono-2-2/mcs/; revision=119040
2008-11-17 15:39:41 +00:00
Marek Safar bb0e7fc708 2008-11-17 Marek Safar <[email protected]>
A fix for bug #444678
	* expression.cs (TryReduceConstant): Always create new constant
	instance.


svn path=/branches/mono-2-2/mcs/; revision=119028
2008-11-17 14:45:40 +00:00
Marek Safar 800ae747f2 2008-11-17 Marek Safar <[email protected]>
A fix for bug #444673
	* ecore.cs: Ignore open generic types when used as generic type
	instance fields.


svn path=/branches/mono-2-2/mcs/; revision=119016
2008-11-17 13:19:46 +00:00
Zoltan Varga 6d986cfd7a 2008-11-17 Zoltan Varga <[email protected]>
Merge r118977 from HEAD.

	* mini-amd64.h: Change the monitor fastpath defines to check for
	!PLATFORM_WIN32 so they work on *bsd too.

svn path=/branches/mono-2-2/mono/; revision=118978
2008-11-17 00:39:13 +00:00
Gonzalo Paniagua Javier 88068708ab 2008-11-14 Gonzalo Paniagua Javier <[email protected]>
* DefaultWsdlHelpGenerator.aspx: use javascript instead of
	HttpWebRequest to avoid a deadlock if the web service uses Session.
	Bug #444343 fixed.
	re: miguel


svn path=/branches/mono-2-2/mono/; revision=118834
2008-11-14 06:31:29 +00:00
Marek Habersack 7a9e96f166 Backport of r118813
svn path=/branches/mono-2-2/mcs/; revision=118815
2008-11-14 02:09:17 +00:00
Marek Habersack e7ec701595 Backport of r118799
svn path=/branches/mono-2-2/mcs/; revision=118800
2008-11-14 00:41:19 +00:00
Veerapuram Varadhan eed1a21d6d reset the connection on timeout exception from TDS
svn path=/branches/mono-2-2/mcs/; revision=118762
2008-11-13 20:22:23 +00:00
Veerapuram Varadhan 7246c849af instead of executing sp_reset_connection, set reset connection bit.
svn path=/branches/mono-2-2/mcs/; revision=118760
2008-11-13 20:17:48 +00:00
Veerapuram Varadhan d39d766bf9 Tests ported from trunk.
svn path=/branches/mono-2-2/mcs/; revision=118759
2008-11-13 20:15:34 +00:00
Bill Holmes 3a2bd00f10 2008-11-13 Bill Holmes <[email protected]>
Backport of r118724.

	* process.h : Adding method declaration for
	  ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* process.c : Adding implementation for
	  ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* icall-def.h : Registering ICALL Processs.WaitForInputIdle_internal
	  to ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* wait.h : Adding method declaration for WaitForInputIdle.

	* wait.c : Adding implementation for WaitForInputIdle.

	* Process.cs : Adding an implementation for WaitForInputIdle
	  to call the an internal call.  The internal call is only
	  implemented properly on Windows.

	Code is contributed under MIT/X11 license.   


svn path=/branches/mono-2-2/mcs/; revision=118743
2008-11-13 18:00:06 +00:00
Bill Holmes 9341400101 2008-11-13 Bill Holmes <[email protected]>
Backport of r118724.

	* process.h : Adding method declaration for
	  ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* process.c : Adding implementation for
	  ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* icall-def.h : Registering ICALL Processs.WaitForInputIdle_internal
	  to ves_icall_System_Diagnostics_Process_WaitForInputIdle_internal.

	* wait.h : Adding method declaration for WaitForInputIdle.

	* wait.c : Adding implementation for WaitForInputIdle.

	* Process.cs : Adding an implementation for WaitForInputIdle
	  to call the an internal call.  The internal call is only
	  implemented properly on Windows.

	Code is contributed under MIT/X11 license.   


svn path=/branches/mono-2-2/mono/; revision=118743
2008-11-13 18:00:06 +00:00
Veerapuram Varadhan 42b1712b66 Backported fix for bug#428139 from trunk
svn path=/branches/mono-2-2/mcs/; revision=118738
2008-11-13 17:31:07 +00:00
Zoltan Varga 1f16a62cf9 2008-11-13 Zoltan Varga <[email protected]>
Backport r118729 from HEAD.
	
	* RxInterpreter.cs: Fix pc computation in various opcodes. Fixes #443841.

svn path=/branches/mono-2-2/mcs/; revision=118732
2008-11-13 17:15:35 +00:00
Marek Safar 7f4be72fcc 2008-11-13 Marek Safar <[email protected]>
A fix for bug #444271
	* anonymous.cs: Rescan parent storeys when best candidate was
	undone.


svn path=/branches/mono-2-2/mcs/; revision=118720
2008-11-13 15:30:22 +00:00
Rodrigo Kumpera e521732831 2008-11-11 Rodrigo Kumpera <[email protected]>
* ModuleTest.cs : Add test for ResolveMethod with a methodspec
	token.

	Backported from trunk.


svn path=/branches/mono-2-2/mcs/; revision=118545
2008-11-11 20:18:38 +00:00
Rodrigo Kumpera fc81aabdab 2008-11-11 Rodrigo Kumpera <[email protected]>
* Module.cs (ResolveMethod): Use internal method 
	GetMethodFromHandleNoGenericCheck to avoid the generic type
	limitation of GetMethodFromHandle.

	Fixes #443763.

	Backported from trunk.


svn path=/branches/mono-2-2/mcs/; revision=118544
2008-11-11 20:18:13 +00:00
Rodrigo Kumpera fcfc9108ba 2008-11-11 Rodrigo Kumpera <[email protected]>
* ConstructorOnTypeBuilderInstTest.cs: Add test for
	MetadataToken under compilation context.

	Backported from trunk.


svn path=/branches/mono-2-2/mcs/; revision=118519
2008-11-11 17:15:57 +00:00
Rodrigo Kumpera b462d915a2 Wrong date in the changelog
svn path=/branches/mono-2-2/mcs/; revision=118518
2008-11-11 17:15:29 +00:00
Rodrigo Kumpera e8d73281a2 2008-11-12 Rodrigo Kumpera <[email protected]>
* ConstructorOnTypeBuilderInst.cs (MetadataToken): Make this
        * property
        work under compiler context. Same hack as the one applied to
        MethodOnTypeBuilderInst.

        Fixes #442610.

        Backported from trunk.



svn path=/branches/mono-2-2/mcs/; revision=118517
2008-11-11 17:14:31 +00:00
Zoltan Varga ff0399cfbe 2008-11-11 Zoltan Varga <[email protected]>
Backport r118484 from HEAD.
	
	* CILCompiler.cs: Implement Reference opcode.

svn path=/branches/mono-2-2/mcs/; revision=118485
2008-11-11 11:21:15 +00:00
Andrew Jorgensen a30aa5462d Bump versions to 2.2
svn path=/branches/mono-2-2/mono/; revision=118446
2008-11-11 00:24:15 +00:00
3589 changed files with 122652 additions and 278219 deletions

No files matched your search

+3 -140
View File
@@ -1,100 +1,14 @@
2009-02-07 Gonzalo Paniagua Javier <[email protected]>
* configure.in: include stdio so that NULL is defined when checking
for ifreq.
2009-02-06 Miguel De Icaza <[email protected]>
* Disable parallel marking on OSX as it hangs during collections
in the bootstrap stage of Mono.
As we find more platforms that hang, we should disable it there as
well.
2009-02-03 Miguel de Icaza <[email protected]>
* configure.in (PLATFORM_NO_SYMLINKS): New define that replaces
PLATFORM_WIN32.
2009-02-02 Rodrigo Kumpera <[email protected]>
* configure.in: Add --with-mcs-docs to make it possible to disable building of documentation under mcs.
2009-01-29 Zoltan Varga <[email protected]>
* configure.in: Remove -Wcast-align from the warning list, it leads to a lot of
useless warnings which can only be fixed by casting a pointer to (void*).
2009-01-29 Miguel de Icaza <[email protected]>
* configure.in: Add a couple of new AM conditionals for POSIX and
DARWIN, these are used to conditionally include some files in
mono/mini.
2009-01-27 Jb Evain <[email protected]>
* configure.in: bump Mono's version to 2.5 now that 2.4
has been branched.
2009-01-25 Zoltan Varga <[email protected]>
* acinclude.m4 (dolt_supported): Handle ARM as well.
2009-01-23 Zoltan Varga <[email protected]>
* configure.in: Make --enable-parallel-mark=yes the default.
2009-01-17 Zoltan Varga <[email protected]>
* configure.in: Complete the OPROFILE checks.
2009-01-16 Zoltan Varga <[email protected]>
Backport of r123612.
* configure.in: Avoid error messages in the quiet code if libgc/Makefile
does not exist yet. Fixes #466814.
2009-01-09 Zoltan Varga <[email protected]>
* configure.in: Check for the existence of the gettext executables.
2008-01-08 Christian Prochnow <[email protected]>
* configure.in: Check for sys/statfs.h and sys/mount.h
2009-01-07 Geoff Norton <[email protected]>
* configure.in: Provide platform information to the mcs build tree
2009-01-06 Jb Evain <[email protected]>
* scripts/Makefile.am: don't generate a script for the now
dead mono-api-diff.
2008-12-05 Jonathan Pryor <[email protected]>
* man/mdoc-update.1: Document -fno-assembly-versions.
2009-01-05 Zoltan Varga <[email protected]>
* configure.in: Disable sigaltstack on freebsd as it doesn't seem to work.
2008-12-16 Marek Habersack <[email protected]>
* data/system.web.extensions.design_1.0.pc.in: added
* data/Makefile.am (EXTRA_DIST): added
system.web.extensions.design_1.0.pc.in. Also added to
pkgconfig_DATA
* configure.in: added data/system.web.extensions_1.0.pc to
AC_OUTPUT
2008-12-16 Bill Holmes <[email protected]>
* winconfig.h : Defining the SIZEOF_REGISTER variable for the MSVC builds.
Code is contributed under MIT/X11 license.
2008-12-15 Marek Habersack <[email protected]>
* data/Makefile.am (EXTRA_DIST): added
@@ -109,62 +23,11 @@
* configure.in: added data/system.web.extensions_1.0.pc to AC_OUTPUT
2008-12-11 Mark Mason <[email protected]>
* configure.in: introduce SIZEOF_REGISTER - usually ==SIZEOF_VOID_P, except on mips/n32
2008-12-05 Marek Habersack <[email protected]>
* configure.in: check whether round (3) and rint (3) are present
in the C library.
2008-12-05 Jonathan Pryor <[email protected]>
* man/mdoc-update.1: Document new parameters such as --exceptions.
2008-12-04 Mark Probst <[email protected]>
* configure.in: Disabling the sibling call optimization doesn't
work, so we're using -mminimal-toc.
2008-12-03 Mark Probst <[email protected]>
* configure.in: Disable sibling call optimization on PPC64 as it
seems to trip up GCC on the build bot.
2008-11-28 Atsushi Enomoto <[email protected]>
* data/mono-nunit.pc.in : add new 2.4.8 files.
2008-11-21 Jb Evain <[email protected]>
* scripts/Makefile.am: use only one mono-api-info pointing to the cecil one
which is mscorlib agnostic.
2008-11-21 Zoltan Varga <[email protected]>
* configure.in: Only enable AOT on linux. Fixes #447265.
2008-11-19 Jonathan Pryor <[email protected]>
* configure.in: Remove mono/monoburg/Makefile; fixes the build.
2008-11-14 Andreas Färber <[email protected]>
* configure.in: Add preprocessor defines for ppc(64).
Suggested by Paolo and Mark.
Contributed under MIT/X11 license.
2008-11-12 Zoltan Varga <[email protected]>
* configure.in: Add an ENABLE_AOT variable to config.make, currently only
enabled for AMD64.
2008-11-11 Zoltan Varga <[email protected]>
* configure.in: Bump version to 2.3.
Mon Nov 10 17:37:08 CET 2008 Paolo Molaro <[email protected]>
* configure.in: check for sys/user.h and struct kinfo_proc members.
+2 -2
View File
@@ -37,8 +37,8 @@ For comments, corrections and updates, please contact [email protected]
We consider non-LGPL use instances where you use this on an
embedded system where the end user is not able to upgrade the
Mono VM or Moonlight installation or distribution that is part
of your product (Section 6 and 7), you would have to obtain a
Moonlight installation or distribution that is part of your
product (Section 6 and 7), you would have to obtain a
commercial license from Novell (consider software burned into
a ROM, systems where end users would not be able to upgrade,
an embedded console, a game console that imposes limitations
+1 -1
View File
@@ -7,7 +7,7 @@ SUBDIRS = po $(libgc_dir) $(eglib_dir) mono $(ikvm_native_dir) support data runt
## 'tools' is not normally built
DIST_SUBDIRS = po libgc $(eglib_dir) mono ikvm-native support data runtime scripts man samples web tools msvc docs
EXTRA_DIST= nls.m4 po.m4 progtest.m4 mono-uninstalled.pc.in build-mingw32.sh LICENSE mkinstalldirs
EXTRA_DIST= nls.m4 po.m4 progtest.m4 mono-uninstalled.pc.in dtrace-prelink.sh build-mingw32.sh LICENSE mkinstalldirs
DISTCHECK_CONFIGURE_FLAGS = EXTERNAL_MCS=false EXTERNAL_RUNTIME=false
+2 -1
View File
@@ -500,4 +500,5 @@ This is Mono.
If the directory ../olive is present (as an
independent checkout) from the Mono module, that
directory is automatically configured to share the
same prefix than this module gets.
same prefix than this module gets
+1 -1
View File
@@ -23,7 +23,7 @@ if test x$GCC != xyes; then
fi
case $host in
i?86-*-linux*|x86_64-*-linux*|powerpc-*-linux* \
|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*|arm*-*-linux*)
|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*)
pic_options='-fPIC'
;;
i?86-apple-darwin*)
+25 -102
View File
@@ -6,7 +6,7 @@ AC_CANONICAL_SYSTEM
m4_ifdef([_A][M_PROG_TAR],[_A][M_SET_OPTION([tar-ustar])])
AM_CONFIG_HEADER(config.h)
AM_INIT_AUTOMAKE(mono,2.5)
AM_INIT_AUTOMAKE(mono,2.2)
AM_MAINTAINER_MODE
API_VER=1.0
@@ -64,13 +64,10 @@ need_link_unlink=no
AC_MSG_CHECKING([host platform characteristics])
libgc_threads=no
has_dtrace=no
parallel_mark=yes
case "$host" in
*-*-mingw*|*-*-cygwin*)
platform_win32=yes
AC_DEFINE(PLATFORM_WIN32,1,[Platform is Win32])
AC_DEFINE(DISABLE_PORTABILITY,1,[Disable the io-portability layer])
AC_DEFINE(PLATFORM_NO_SYMLINKS,1,[This platform does not support symlinks])
if test "x$cross_compiling" = "xno"; then
CC="gcc -mno-cygwin -g"
# So libgc configure gets -mno-cygwin
@@ -100,7 +97,6 @@ case "$host" in
libdl="-ldl"
libgc_threads=pthreads
with_sigaltstack=no
use_sigposix=yes
;;
*-*-*freebsd*)
platform_win32=no
@@ -129,11 +125,10 @@ case "$host" in
# but NOT library support)
#
with_tls=pthread
use_sigposix=yes
;;
*-*-*openbsd*)
platform_win32=no
CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE -DGC_FREEBSD_THREADS -DPLATFORM_BSD"
CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE -DGC_FREEBSD_THREADS"
libmono_cflags="-D_THREAD_SAFE"
LDFLAGS="$LDFLAGS -pthread"
libmono_ldflags="-pthread"
@@ -141,7 +136,6 @@ case "$host" in
AC_DEFINE(PTHREAD_POINTER_ID)
libdl=
libgc_threads=pthreads
use_sigposix=yes
;;
*-*-linux*)
platform_win32=no
@@ -150,11 +144,9 @@ case "$host" in
libmono_ldflags="-lpthread"
libdl="-ldl"
libgc_threads=pthreads
AOT_SUPPORTED="yes"
use_sigposix=yes
;;
*-*-hpux*)
platform_win32=no
platform_win32=no
CPPFLAGS="$CPPFLAGS -DGC_HPUX_THREADS -D_HPUX_SOURCE -D_XOPEN_SOURCE_EXTENDED -D_REENTRANT"
# +ESdbgasm only valid on bundled cc on RISC
# silently ignored for ia64
@@ -170,7 +162,6 @@ case "$host" in
libmono_ldflags="-lpthread"
libgc_threads=pthreads
need_link_unlink=yes
use_sigposix=yes
;;
*-*-solaris*)
platform_win32=no
@@ -181,12 +172,9 @@ case "$host" in
# This doesn't seem to work on solaris/x86, but the configure test runs
with_tls=pthread
has_dtrace=yes
use_sigposix=yes
;;
*-*-darwin*)
parallel_mark="Disabled_Currently_Hangs_On_MacOSX"
platform_win32=no
platform_darwin=yes
CPPFLAGS="$CPPFLAGS -no-cpp-precomp -D_THREAD_SAFE -DGC_MACOSX_THREADS -DPLATFORM_MACOSX -DUSE_MMAP -DUSE_MUNMAP"
CPPFLAGS="$CPPFLAGS -DGetCurrentProcess=MonoGetCurrentProcess -DGetCurrentThread=MonoGetCurrentThread -DCreateEvent=MonoCreateEvent"
libmono_cflags="-D_THREAD_SAFE"
@@ -217,8 +205,6 @@ fi
AM_CONDITIONAL(PLATFORM_WIN32, test x$platform_win32 = xyes)
AM_CONDITIONAL(PLATFORM_LINUX, echo x$target_os | grep -q linux)
AM_CONDITIONAL(PLATFORM_DARWIN, test x$platform_darwin = xyes)
AM_CONDITIONAL(PLATFORM_SIGPOSIX, test x$use_sigposix = xyes)
AC_CHECK_TOOL(CC, gcc, gcc)
AC_PROG_CC
@@ -280,7 +266,7 @@ fi
AM_CONDITIONAL(NO_VERSION_SCRIPT, test x$no_version_script = xyes)
AC_CHECK_HEADERS(sys/filio.h sys/sockio.h netdb.h utime.h sys/utime.h semaphore.h sys/un.h linux/rtc.h sys/syscall.h sys/mkdev.h)
AC_CHECK_HEADERS(sys/user.h sys/socket.h sys/ipc.h sys/sem.h sys/utsname.h alloca.h ucontext.h pwd.h)
AC_CHECK_HEADERS(sys/user.h)
AC_CHECK_HEADER(zlib.h, [have_zlib=yes], [have_zlib=no])
if test x$have_zlib = xyes; then
@@ -334,7 +320,7 @@ AC_CHECK_SIZEOF(void *, 4)
WARN=''
if test x"$GCC" = xyes; then
WARN='-Wall -Wunused -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wno-cast-qual -Wwrite-strings'
WARN='-Wall -Wunused -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wpointer-arith -Wno-cast-qual -Wcast-align -Wwrite-strings'
# The runtime code does not respect ANSI C strict aliasing rules
CFLAGS="$CFLAGS -fno-strict-aliasing"
@@ -405,14 +391,6 @@ fi
# we do not configure the full gettext, as we consume it dynamically from C#
AM_PO_SUBDIRS
if test "x$USE_NLS" = "xyes"; then
AC_CHECK_PROG(HAVE_MSGFMT, msgfmt,yes,no)
if test "x$HAVE_MSGFMT" = "xno"; then
AC_MSG_ERROR([msgfmt not found. You need to install the 'gettext' package, or pass --enable-nls=no to configure.])
fi
fi
AC_ARG_WITH([libgdiplus],
[ --with-libgdiplus=installed|sibling|<path> Override the libgdiplus used for System.Drawing tests (defaults to NO)],
[], [with_libgdiplus=installed])
@@ -652,7 +630,7 @@ AC_TRY_COMPILE([], [
AC_MSG_RESULT(no)
])
AC_ARG_ENABLE(parallel-mark, [ --enable-parallel-mark Enables GC Parallel Marking], enable_parallel_mark=$enableval, enable_parallel_mark=$parallel_mark)
AC_ARG_ENABLE(parallel-mark, [ --enable-parallel-mark Enables GC Parallel Marking])
if test x$enable_parallel_mark = xyes; then
libgc_configure_args="$libgc_configure_args --enable-parallel-mark"
fi
@@ -1373,7 +1351,6 @@ if test x$platform_win32 = xno; then
AC_CHECK_HEADERS(net/if.h)
AC_MSG_CHECKING(for ifreq)
AC_TRY_COMPILE([
#include <stdio.h>
#include <sys/ioctl.h>
#include <net/if.h>
], [
@@ -1428,12 +1405,9 @@ if test x$platform_win32 = xno; then
AC_CHECK_HEADERS(sys/extattr.h)
AC_CHECK_HEADERS(sys/sendfile.h)
AC_CHECK_HEADERS(sys/statvfs.h)
AC_CHECK_HEADERS(sys/statfs.h)
AC_CHECK_HEADERS(sys/vfstab.h)
AC_CHECK_HEADERS(sys/xattr.h)
AC_CHECK_HEADERS(sys/mman.h)
AC_CHECK_HEADERS(sys/param.h)
AC_CHECK_HEADERS(sys/mount.h)
AC_CHECK_FUNCS(getdomainname)
AC_CHECK_FUNCS(setdomainname)
AC_CHECK_FUNCS(fgetgrent)
@@ -1774,8 +1748,6 @@ SQLITE="libsqlite.so.0"
SQLITE3="libsqlite3.so.0"
X11="libX11.so"
sizeof_register="SIZEOF_VOID_P"
jit_wanted=false
interp_wanted=false
case "$host" in
@@ -1789,20 +1761,6 @@ case "$host" in
ACCESS_UNALIGNED="no"
JIT_SUPPORTED=yes
jit_wanted=true
AC_MSG_CHECKING(for mips n32)
AC_TRY_COMPILE([], [
void main () {
#if _MIPS_SIM != _ABIN32
#error Not mips n32
#endif
}
],[
AC_MSG_RESULT(yes)
sizeof_register=8
],[
AC_MSG_RESULT(no)
])
;;
i*86-*-*)
TARGET=X86;
@@ -1911,11 +1869,8 @@ case "$host" in
powerpc-*-sysv* | powerpc-*-darwin* | powerpc-*-netbsd* )
if test "x$ac_cv_sizeof_void_p" = "x8"; then
TARGET=POWERPC64;
CPPFLAGS="$CPPFLAGS -D__mono_ppc__ -D__mono_ppc64__"
CFLAGS="$CFLAGS -mminimal-toc"
else
TARGET=POWERPC;
CPPFLAGS="$CPPFLAGS -D__mono_ppc__"
fi
AC_DEFINE(MONO_ARCH_REGPARMS,1,[Architecture uses registers for Parameters])
arch_target=ppc;
@@ -1958,14 +1913,6 @@ case "$host" in
;;
esac
if test "x$sizeof_register" = "x4"; then
AC_DEFINE(SIZEOF_REGISTER,4,[size of machine integer registers])
elif test "x$sizeof_register" = "x8"; then
AC_DEFINE(SIZEOF_REGISTER,8,[size of machine integer registers])
else
AC_DEFINE(SIZEOF_REGISTER,SIZEOF_VOID_P,[size of machine integer registers])
fi
if test "x$have_visibility_hidden" = "xyes"; then
AC_DEFINE(HAVE_VISIBILITY_HIDDEN, 1, [Support for the visibility ("hidden") attribute])
fi
@@ -2162,16 +2109,12 @@ AC_ARG_WITH(moonlight,[ --with-moonlight=yes,no If you want to build the Moonl
])
OPROFILE=no
AC_ARG_WITH(oprofile,[ --with-oprofile=no,<oprofile install dir> Enable oprofile support (defaults to NO)],[
AC_ARG_WITH(oprofile,[ --with-oprofile=no,<path> Enable oprofile support (defaults to NO)],[
if test x$with_oprofile != xno; then
oprofile_include=$with_oprofile/include
if test ! -f $oprofile_include/opagent.h; then
AC_MSG_ERROR([oprofile include file not found at $oprofile_include/opagent.h])
fi
OPROFILE=yes
OPROFILE_CFLAGS="-I$oprofile_include"
OPROFILE_LIBS="-L$with_oprofile/lib/oprofile -lopagent"
AC_DEFINE(HAVE_OPROFILE,1,[Have oprofile support])
OPROFILE=yes
OPROFILE_CFLAGS="-I$with_oprofile/include"
OPROFILE_LIBS=
AC_DEFINE(HAVE_OPROFILE,1,[Have oprofile support])
fi
])
@@ -2183,14 +2126,6 @@ AC_ARG_WITH(malloc_mempools,[ --with-malloc-mempools=yes,no Use malloc for each
fi
])
DISABLE_MCS_DOCS=no
AC_ARG_WITH(mcs_docs,[ --with-mcs-docs=yes,no If you want to build the documentation under mcs (defaults to YES)],[
if test x$with_mcs_docs != xyes; then
DISABLE_MCS_DOCS=yes
fi
])
AM_CONDITIONAL(HAVE_OPROFILE, test x$OPROFILE = xyes)
AC_SUBST(OPROFILE_CFLAGS)
AC_SUBST(OPROFILE_LIBS)
@@ -2368,6 +2303,7 @@ mono/tests/cas/inheritance/Makefile
mono/tests/cas/linkdemand/Makefile
mono/tests/cas/threads/Makefile
mono/benchmark/Makefile
mono/monoburg/Makefile
mono/monograph/Makefile
mono/io-layer/Makefile
mono/mini/Makefile
@@ -2457,14 +2393,6 @@ fi
echo "MONO_VERSION = $myver" >> $srcdir/$mcsdir/build/config.make
fi
if test x$platform_darwin = xyes; then
echo "PLATFORM = darwin" >> $srcdir/$mcsdir/build/config.make
fi
if test x$TARGET = xAMD64 -a x$platform_win32 = xno -a "x$AOT_SUPPORTED" = "xyes"; then
echo "ENABLE_AOT = 1" >> $srcdir/$mcsdir/build/config.make
fi
# if we have an olive folder, override the default settings
if test -d $olivedir; then
@@ -2482,10 +2410,6 @@ fi
fi
fi
fi
if test x$DISABLE_MCS_DOCS = xyes; then
echo "DISABLE_MCS_DOCS = yes" >> $srcdir/$mcsdir/build/config.make
fi
)
libgdiplus_msg=${libgdiplus_loc:-assumed to be installed}
@@ -2494,24 +2418,23 @@ echo "
mcs source: $mcs_topdir
olive source: $olive_topdir
GC: $gc
TLS: $with_tls
SIGALTSTACK: $with_sigaltstack
Engine: $jit_status
2.0 Beta: $PREVIEW
2.1 Alpha: $MOONLIGHT
JNI support: $jdk_headers_found
libgdiplus: $libgdiplus_msg
zlib: $zlib_msg
oprofile: $OPROFILE
BigArrays: $enable_big_arrays
DTrace: $enable_dtrace
Parallel Mark: $enable_parallel_mark
GC: $gc
TLS: $with_tls
SIGALTSTACK: $with_sigaltstack
Engine: $jit_status
2.0 Beta: $PREVIEW
2.1 Alpha: $MOONLIGHT
JNI support: $jdk_headers_found
libgdiplus: $libgdiplus_msg
zlib: $zlib_msg
oprofile: $OPROFILE
BigArrays: $enable_big_arrays
DTrace: $enable_dtrace
$disabled
"
if test x$with_static_mono = xno -a "x$platform_win32" != "xyes"; then
AC_MSG_WARN(Turning off static Mono is a risk, you might run into unexpected bugs)
AC_MSG_WARN(Turning off static Mono is a risk, you might run into unexepcted bugs)
fi
if test x$gc = xsgen; then
+1 -2
View File
@@ -7,8 +7,7 @@ EXTRA_DIST = \
browscap.ini mono.supp mono.d README \
mono.pc.in mint.pc.in dotnet.pc.in dotnet35.pc.in wcf.pc.in monodoc.pc.in \
mono-nunit.pc.in mono-cairo.pc.in mono-options.pc.in cecil.pc.in smcs.pc.in \
mono-lineeditor.pc.in system.web.extensions_1.0.pc.in system.web.extensions.design_1.0.pc.in\
dtrace-prelink.sh
mono-lineeditor.pc.in system.web.extensions_1.0.pc.in system.web.extensions.design_1.0.pc.in
pkgconfigdir = $(libdir)/pkgconfig
-22
View File
@@ -1,22 +0,0 @@
2009-02-03 Zoltan Varga <[email protected]>
* mono-gdb.py: Remove the --64 argument to as, it is not needed.
* mono-gdb.py (stringify_class_name): Helper function to print base types
using their short name. Also add a prototype implementation of registering
the hooks from python code instead of needing the mono-gdbinit file.
* gdb-python.diff: Changes against the gdb archer branch at
http://sourceware.org/gdb/wiki/PythonGdb to fix some problems/add functionality.
2009-02-03 Geoff Norton <[email protected]>
* mono-gdbinit: Hook into backtrace as hook-stop seems to crash gdb
* mono-gdb.py: Find the gdbinit name from the executable name instead of
hardcoding mono
2009-01-29 Zoltan Varga <[email protected]>
* mono-gdb.py mono-gdbinit: Support files to help debugging mono/mono apps
using a python enabled gdb.
-163
View File
@@ -1,163 +0,0 @@
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 640998b..fb73e9d 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,10 @@
+2009-02-03 Zoltan Varga <[email protected]>
+
+ * cil-script.c python/python-cmd.c: Allow registration of pre/post hooks from
+ python.
+
+ * symfile.c (add_symbol_file_command): Comment out verbose messages.
+
2009-02-03 Thiago Jung Bauermann <[email protected]>
* gdb/c-lang.c (c_get_string): Remove superfluous parenthesis from
diff --git a/gdb/cli/cli-script.c b/gdb/cli/cli-script.c
index 835d29c..3941aa5 100644
--- a/gdb/cli/cli-script.c
+++ b/gdb/cli/cli-script.c
@@ -299,6 +299,13 @@ execute_user_command (struct cmd_list_element *c, char *args)
static int user_call_depth = 0;
extern int max_user_call_depth;
+ /* Might be a user defined command implemented in Python */
+ if (!c->user_commands && c->func)
+ {
+ (*c->func) (c, args, FALSE);
+ return;
+ }
+
old_chain = setup_user_args (args);
cmdlines = c->user_commands;
diff --git a/gdb/python/python-cmd.c b/gdb/python/python-cmd.c
index 61d5e5d..a3fbc08 100644
--- a/gdb/python/python-cmd.c
+++ b/gdb/python/python-cmd.c
@@ -339,7 +339,8 @@ gdbpy_parse_command_name (char *text, struct cmd_list_element ***base_list,
/* Object initializer; sets up gdb-side structures for command.
- Use: __init__(NAME, CMDCLASS, [COMPLETERCLASS, [PREFIX]]).
+ Use: __init__(NAME, CMDCLASS, [completerclass=COMPLETERCLASS, prefix=PREFIX,
+ pre_hook_of=PREHOOK_OF, post_hook_of=POSTHOOK_OF]).
NAME is the name of the command. It may consist of multiple words,
in which case the final word is the name of the new command, and
@@ -354,6 +355,11 @@ gdbpy_parse_command_name (char *text, struct cmd_list_element ***base_list,
If PREFIX is True, then this command is a prefix command.
+ PREHOOK_OF is the name of a gdb command this command becomes a
+ pre-execution hook of, same as if this command was defined using
+ "define hook-<cmdname>"
+ POSTHOOK_OF is the same for post-execution hooks.
+
The documentation for the command is taken from the doc string for
the python class.
@@ -362,15 +368,18 @@ static int
cmdpy_init (PyObject *self, PyObject *args, PyObject *kwds)
{
cmdpy_object *obj = (cmdpy_object *) self;
- char *name;
+ char *name, *pre_hook_of = NULL, *post_hook_of = NULL;
int cmdtype;
int completetype = -1;
char *docstring = NULL;
volatile struct gdb_exception except;
struct cmd_list_element **cmd_list;
+ struct cmd_list_element *pre_hookc = NULL, *post_hookc = NULL;
char *cmd_name, *pfx_name;
PyObject *is_prefix = NULL;
int cmp;
+ static char *kwlist[] = {"name", "cmdclass", "completerclass", "prefix",
+ "pre_hook_of", "post_hook_of", NULL};
if (obj->command)
{
@@ -381,8 +390,9 @@ cmdpy_init (PyObject *self, PyObject *args, PyObject *kwds)
return -1;
}
- if (! PyArg_ParseTuple (args, "si|iO", &name, &cmdtype,
- &completetype, &is_prefix))
+ if (! PyArg_ParseTupleAndKeywords (args, kwds, "si|iOss", kwlist, &name, &cmdtype,
+ &completetype, &is_prefix, &pre_hook_of,
+ &post_hook_of))
return -1;
if (cmdtype != no_class && cmdtype != class_run
@@ -402,6 +412,30 @@ cmdpy_init (PyObject *self, PyObject *args, PyObject *kwds)
return -1;
}
+ if (pre_hook_of)
+ {
+ char *text = pre_hook_of;
+
+ pre_hookc = lookup_cmd_1 (&text, cmdlist, NULL, 1);
+ if (! pre_hookc)
+ {
+ PyErr_Format (PyExc_RuntimeError, _("command name given by pre_hook argument not found"));
+ return -1;
+ }
+ }
+
+ if (post_hook_of)
+ {
+ char *text = post_hook_of;
+
+ post_hookc = lookup_cmd_1 (&text, cmdlist, NULL, 1);
+ if (! post_hookc)
+ {
+ PyErr_Format (PyExc_RuntimeError, _("command name given by post_hook argument not found"));
+ return -1;
+ }
+ }
+
cmd_name = gdbpy_parse_command_name (name, &cmd_list, &cmdlist);
if (! cmd_name)
return -1;
@@ -470,6 +504,18 @@ cmdpy_init (PyObject *self, PyObject *args, PyObject *kwds)
cmd->func = cmdpy_function;
cmd->destroyer = cmdpy_destroyer;
+ if (pre_hookc)
+ {
+ pre_hookc->hook_pre = cmd;
+ cmd->hookee_pre = pre_hookc;
+ }
+
+ if (post_hookc)
+ {
+ post_hookc->hook_post = cmd;
+ cmd->hookee_post = post_hookc;
+ }
+
obj->command = cmd;
set_cmd_context (cmd, self);
set_cmd_completer (cmd, ((completetype == -1) ? cmdpy_completer
diff --git a/gdb/symfile.c b/gdb/symfile.c
index 14cb7b8..6d0bb40 100644
--- a/gdb/symfile.c
+++ b/gdb/symfile.c
@@ -2196,7 +2196,7 @@ add_symbol_file_command (char *args, int from_tty)
statements because hex_string returns a local static
string. */
- printf_unfiltered (_("add symbol table from file \"%s\" at\n"), filename);
+ /* printf_unfiltered (_("add symbol table from file \"%s\" at\n"), filename); */
section_addrs = alloc_section_addr_info (section_index);
make_cleanup (xfree, section_addrs);
for (i = 0; i < section_index; i++)
@@ -2211,7 +2211,7 @@ add_symbol_file_command (char *args, int from_tty)
entered on the command line. */
section_addrs->other[sec_num].name = sec;
section_addrs->other[sec_num].addr = addr;
- printf_unfiltered ("\t%s_addr = %s\n", sec, paddress (addr));
+ /* printf_unfiltered ("\t%s_addr = %s\n", sec, paddress (addr)); */
sec_num++;
/* The object's sections are initialized when a
-181
View File
@@ -1,181 +0,0 @@
#
# Author: Zoltan Varga ([email protected])
# License: MIT/X11
#
#
# This is a mono support mode for a python-enabled gdb:
# http://sourceware.org/gdb/wiki/PythonGdb
# Usage:
# - copy/symlink this file, plus mono-gdbinit to the directory where the mono
# executable lives.
# - run mono under gdb, or attach to a mono process using gdb
# - Type 'xdb' in gdb to load/reload the debugging info emitted by the runtime.
# - The debug info is emitted to a file called xdb.s in the current working directory.
# When attaching to a mono process, make sure you are in the same directory.
#
import os
class StringPrinter:
"Print a C# string"
def __init__(self, val):
self.val = val
def to_string(self):
if int(self.val.cast (gdb.Type ("guint64"))) == 0:
return "null"
obj = self.val.cast (gdb.Type ("MonoString").pointer ()).dereference ()
len = obj ['length']
chars = obj ['chars']
i = 0
res = ['"']
while i < len:
c = chr ((chars.cast(gdb.Type ("gint64")) + (i * 2)).cast(gdb.Type ("gunichar2").pointer ()).dereference ())
res.append (c)
i = i + 1
res.append ('"')
return ''.join (res)
def stringify_class_name(ns, name):
if ns == "System":
if name == "Byte":
return "byte"
if name == "String":
return "string"
return "%s.%s" % (ns, name)
class ArrayPrinter:
"Print a C# array"
def __init__(self, val, class_ns, class_name):
self.val = val
self.class_ns = class_ns
self.class_name = class_name
def to_string(self):
obj = self.val.cast (gdb.Type ("MonoArray").pointer ()).dereference ()
length = obj ['max_length']
return "%s [%d]" % (stringify_class_name (self.class_ns, self.class_name [0:len(self.class_name) - 2]), int(length))
class ObjectPrinter:
"Print a C# object"
def __init__(self, val):
self.val = val
class _iterator:
def __init__(self,obj):
self.obj = obj
self.iter = self.obj.type ().fields ().__iter__ ()
pass
def __iter__(self):
return self
def next(self):
field = self.iter.next ()
return (field.name, self.obj [field.name])
def children(self):
# FIXME: It would be easier if gdb.Value would support iteration itself
# It would also be better if we could return None
if int(self.val.cast (gdb.Type ("guint64"))) == 0:
return {}.__iter__ ()
try:
obj = self.val.cast (gdb.Type ("MonoObject").pointer ()).dereference ()
class_ns = obj ['vtable'].dereference ()['klass'].dereference ()['name_space'].string ()
class_name = obj ['vtable'].dereference ()['klass'].dereference ()['name'].string ()
gdb_type = gdb.Type ("struct %s.%s" % (class_ns, class_name))
return self._iterator(obj.cast (gdb_type))
except:
return {}.__iter__ ()
def to_string(self):
if int(self.val.cast (gdb.Type ("guint64"))) == 0:
return "null"
try:
obj = self.val.cast (gdb.Type ("MonoObject").pointer ()).dereference ()
class_ns = obj ['vtable'].dereference ()['klass'].dereference ()['name_space'].string ()
class_name = obj ['vtable'].dereference ()['klass'].dereference ()['name'].string ()
if class_ns == "System" and class_name == "String":
return StringPrinter (self.val).to_string ()
if class_name [-2:len(class_name)] == "[]":
return ArrayPrinter (self.val,class_ns,class_name).to_string ()
if class_ns != "":
try:
gdb_type = gdb.Type ("struct %s.%s" % (class_ns, class_name))
except:
# Maybe there is no debug info for that type
return "%s.%s" % (class_ns, class_name)
#return obj.cast (gdb_type)
return "%s.%s" % (class_ns, class_name)
return class_name
except:
print sys.exc_info ()[0]
print sys.exc_info ()[1]
# FIXME: This can happen because we don't have liveness information
return self.val.cast (gdb.Type ("guint64"))
def register_csharp_printers(obj):
"Register C# pretty-printers with objfile Obj."
if obj == None:
obj = gdb
obj.pretty_printers['object'] = ObjectPrinter
obj.pretty_printers['string'] = StringPrinter
register_csharp_printers (gdb.current_objfile())
class MonoSupport(object):
def __init__(self):
self.s_size = 0
def run_hook(self):
if os.access ("xdb.s", os.F_OK):
os.remove ("xdb.s")
gdb.execute ("set environment MONO_XDEBUG 1")
def stop_hook(self):
# Called when the program is stopped
# Need to recompile+reload the xdb.s file if needed
# FIXME: Need to detect half-written files created when the child is
# interrupted while executing the xdb.s writing code
# FIXME: Handle appdomain unload
if os.access ("xdb.s", os.F_OK):
new_size = os.stat ("xdb.s").st_size
if new_size > self.s_size:
sofile = "xdb.so"
gdb.execute ("shell as -o xdb.o xdb.s && ld -shared -o %s xdb.o" % sofile)
# FIXME: This prints messages which couldn't be turned off
gdb.execute ("add-symbol-file %s 0" % sofile)
self.s_size = new_size
class RunHook (gdb.Command):
def __init__ (self):
super (RunHook, self).__init__ ("hook-run", gdb.COMMAND_NONE,
gdb.COMPLETE_COMMAND, pre_hook_of="run")
def invoke(self, arg, from_tty):
mono_support.run_hook ()
print "Mono support loaded."
mono_support = MonoSupport ()
# This depends on the changes in gdb-python.diff to work
#RunHook ()
# Register our hooks
# This currently cannot be done from python code
exec_file = gdb.current_objfile ().filename
# FIXME: Is there a way to detect symbolic links ?
if os.stat (exec_file).st_size != os.lstat (exec_file).st_size:
exec_file = os.readlink (exec_file)
exec_dir = os.path.dirname (exec_file)
gdb.execute ("source %s/%s-gdbinit" % (exec_dir, os.path.basename (exec_file)))
-20
View File
@@ -1,20 +0,0 @@
# Loaded by mono-gdb.py
# FIXME: According to gdb docs, this is called _before_ anything is printed
# Got broken by this patch:
# http://sourceware.org/ml/gdb-patches/2008-09/msg00193.html
# FIXME: This seems to cause crashes inside gdb
#define hook-stop
# python mono_support.stop_hook ()
#end
define hook-backtrace
python mono_support.stop_hook ()
end
define hook-run
python mono_support.run_hook ()
end
define xdb
python mono_support.stop_hook ()
end
+1 -1
View File
@@ -6,4 +6,4 @@ libdir=${exec_prefix}/lib
Name: Mono NUnit
Description: Mono's version of NUnit
Version: @VERSION@
Libs: -r:${libdir}/mono/1.0/nunit.core.dll -r:${libdir}/mono/1.0/nunit.core.interfaces.dll -r:${libdir}/mono/1.0/nunit.core.extensions.dll -r:${libdir}/mono/1.0/nunit.framework.dll -r:${libdir}/mono/1.0/nunit.framework.extensions.dll -r:${libdir}/mono/1.0/nunit.mocks.dll -r:${libdir}/mono/1.0/nunit.util.dll -r:${libdir}/mono/1.0/nunit-console-runner.dll
Libs: -r:${libdir}/mono/1.0/nunit.core.dll -r:${libdir}/mono/1.0/nunit.framework.dll -r:${libdir}/mono/1.0/nunit.util.dll
+1 -16
View File
@@ -1,29 +1,14 @@
2009-01-23 Atsushi Enomoto <[email protected]>
* web.config : added .svc handler.
2009-01-07 Kornél Pál <[email protected]>
* DefaultWsdlHelpGenerator.aspx: Move <script> at the end of <head> that
will make Visual Studio recognize the web service disco reference.
Contributed under MIT/X11 license.
2008-12-03 Marek Habersack <[email protected]>
* machine.config: rename serviceModelHostingEnvironment to
serviceHostingEnvironment.
2008-11-20 Gonzalo Paniagua Javier <[email protected]>
* machine.config: in 2.0, there's no <connectionManagement> section
here. Bug #445991 fixed.
2008-11-14 Gonzalo Paniagua Javier <[email protected]>
* DefaultWsdlHelpGenerator.aspx: use javascript instead of
HttpWebRequest to avoid a deadlock if the web service uses Session.
Bug #444343 fixed.
re: miguel
2008-10-09 Gonzalo Paniagua Javier <[email protected]>
+68 -67
View File
@@ -34,6 +34,73 @@
<%@ Page debug="true" %>
<html>
<script language="javascript" type="text/javascript">
var req;
function getXML (command, url, qs) {
if (url == "" || url.substring (0, 4) != "http")
return;
var post_data = null;
req = getReq ();
req.onreadystatechange = stateChange;
if (command == "GET") {
url = url + "?" + qs;
} else {
post_data = qs;
}
req.open (command, url, true);
if (command == "POST")
req.setRequestHeader ("Content-Type", "application/x-www-form-urlencoded");
req.send (post_data);
}
function stateChange () {
if (req.readyState == 4) {
var node = document.getElementById("testresult_div");
var text = "";
if (req.status == 200) {
node.innerHTML = "<div class='code-xml'>" + formatXml (req.responseText) + "</div>";
} else {
var ht = "<b style='color: red'>" + formatXml (req.status + " - " + req.statusText) + "</b>";
if (req.responseText != "")
ht = ht + "\n<div class='code-xml'>" + formatXml (req.responseText) + "</div>";
node.innerHTML = ht;
}
}
}
function formatXml (text)
{
var re = / /g;
text = text.replace (re, "&nbsp;");
re = /\t/g;
text = text.replace (re, "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;");
re = /\<\s*(\/?)\s*(.*?)\s*(\/?)\s*\>/g;
text = text.replace (re,"{blue:&lt;$1}{maroon:$2}{blue:$3&gt;}");
re = /{(\w*):(.*?)}/g;
text = text.replace (re,"<span style='color:$1'>$2</span>");
re = /"(.*?)"/g;
text = text.replace (re,"\"<span style='color:purple'>$1</span>\"");
re = /\r\n|\r|\n/g;
text = text.replace (re, "<br/>");
return text;
}
function getReq () {
if (window.XMLHttpRequest) {
return new XMLHttpRequest(); // Firefox, Safari, ...
} else if (window.ActiveXObject) {
return new ActiveXObject("Microsoft.XMLHTTP");
}
}
</script>
<script language="C#" runat="server">
ServiceDescriptionCollection descriptions;
@@ -1548,73 +1615,7 @@ public class HtmlSampleGenerator: SampleGenerator
A:hover { color: blue }
</style>
<script language="javascript" type="text/javascript">
var req;
function getXML (command, url, qs) {
if (url == "" || url.substring (0, 4) != "http")
return;
var post_data = null;
req = getReq ();
req.onreadystatechange = stateChange;
if (command == "GET") {
url = url + "?" + qs;
} else {
post_data = qs;
}
req.open (command, url, true);
if (command == "POST")
req.setRequestHeader ("Content-Type", "application/x-www-form-urlencoded");
req.send (post_data);
}
function stateChange () {
if (req.readyState == 4) {
var node = document.getElementById("testresult_div");
var text = "";
if (req.status == 200) {
node.innerHTML = "<div class='code-xml'>" + formatXml (req.responseText) + "</div>";
} else {
var ht = "<b style='color: red'>" + formatXml (req.status + " - " + req.statusText) + "</b>";
if (req.responseText != "")
ht = ht + "\n<div class='code-xml'>" + formatXml (req.responseText) + "</div>";
node.innerHTML = ht;
}
}
}
function formatXml (text)
{
var re = / /g;
text = text.replace (re, "&nbsp;");
re = /\t/g;
text = text.replace (re, "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;");
re = /\<\s*(\/?)\s*(.*?)\s*(\/?)\s*\>/g;
text = text.replace (re,"{blue:&lt;$1}{maroon:$2}{blue:$3&gt;}");
re = /{(\w*):(.*?)}/g;
text = text.replace (re,"<span style='color:$1'>$2</span>");
re = /"(.*?)"/g;
text = text.replace (re,"\"<span style='color:purple'>$1</span>\"");
re = /\r\n|\r|\n/g;
text = text.replace (re, "<br/>");
return text;
}
function getReq () {
if (window.XMLHttpRequest) {
return new XMLHttpRequest(); // Firefox, Safari, ...
} else if (window.ActiveXObject) {
return new ActiveXObject("Microsoft.XMLHTTP");
}
}
<script>
function clearForm ()
{
document.getElementById("testFormResult").style.display="none";
+3
View File
@@ -102,6 +102,9 @@
</configProtectedData>
<system.net>
<connectionManagement>
<add address="*" maxconnection="2" />
</connectionManagement>
<authenticationModules>
<add type="System.Net.BasicClient, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add type="System.Net.DigestClient, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
+2 -3
View File
@@ -37,9 +37,8 @@
<add verb="*" path="*.vbproj" type="System.Web.HttpForbiddenHandler, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<add verb="*" path="*.licx" type="System.Web.HttpForbiddenHandler, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<add verb="*" path="*.dll" type="System.Web.HttpForbiddenHandler, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<add verb="*" path="*.rem" type="System.Runtime.Remoting.Channels.Http.HttpRemotingHandlerFactory, System.Runtime.Remoting, Culture=neutral, PublicKeyToken=b77a5c561934e089" validate="false" />
<add verb="*" path="*.soap" type="System.Runtime.Remoting.Channels.Http.HttpRemotingHandlerFactory, System.Runtime.Remoting, Culture=neutral, PublicKeyToken=b77a5c561934e089" validate="false" />
<add verb="*" path="*.svc" type="System.ServiceModel.Channels.SvcHttpHandlerFactory, System.ServiceModel, Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<add verb="*" path="*.rem" type="System.Runtime.Remoting.Channels.Http.HttpRemotingHandlerFactory, System.Runtime.Remoting, Culture=neutral, PublicKeyToken=b77a5c561934e089" validate="false" />
<add verb="*" path="*.soap" type="System.Runtime.Remoting.Channels.Http.HttpRemotingHandlerFactory, System.Runtime.Remoting, Culture=neutral, PublicKeyToken=b77a5c561934e089" validate="false" />
<add verb="GET,HEAD" path="*" type="System.Web.StaticFileHandler, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<add verb="*" path="*" type="System.Web.HttpMethodNotAllowedHandler, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
</httpHandlers>
+8 -56
View File
@@ -1,59 +1,3 @@
2009-02-12 Zoltan Varga <[email protected]>
* Makefile.am (EXTRA_DIST): Remove removed files.
* README: Point to the documentation on the wiki.
* call-sites.txt: Remove this, its contents is in jit-trampolines.
* memory-management.txt thread-safety.txt aot-compiler.txt jit-regalloc
exception-handling.txt: Remove documents which are now on the wiki.
2009-02-11 Rodrigo Kumpera <[email protected]>
* thread-safety.txt: Improve the docs about image lock.
2009-02-11 Rodrigo Kumpera <[email protected]>
* thread-safety.txt: Document the new image lock.
2008-12-12 Mark Probst <[email protected]>
* mini-porting.txt: Added some details about function descriptors
and emulated opcodes.
2008-12-08 Jonathan Pryor <[email protected]>
* mono-file-formats.source, mono-tools.source: Place these under the
new "Commands and Files" node, and remove nay intermediate nodes.
2008-11-20 Jonathan Pryor <[email protected]>
* Makefile.am (sources_DATA): Add mono-file-formats.source,
mono-tools.source.
2008-11-20 Raja R Harinath <[email protected]>
Remove unnecessary rebuilds of the html directory
* docs.make (monoapi.zip): Make slightly more unforgiving, by
using '&&' instead of ';' to sequence commands.
(mono-tools.zip, mono-file-formats.zip): Likewise.
* Makefile.am (monoapi.zip, mono-tools.zip, mono-fileformats.zip):
Likewise.
(convert.exe): Don't depend on Makefile.am or docs.make.
2008-11-19 Raja R Harinath <[email protected]>
Fix srcdir != builddir, and add idiom for multi-output commands
* docs.make (monoapi.zip): Handle the case where 'monoapi.tree'
exists but 'monoapi.zip' doesn't. IOW, we should rebuild
monoapi.zip with 'rm monoapi.zip; make'.
(mono-tools.zip, mono-file-formats.zip): Likewise.
* Makefile.am (monoapi.zip, mono-tools.zip, mono-fileformats.zip):
Likewise.
(monoapi.tree): Don't use $< in an explicit rule.
(mono-tools.tree, mono-file-formats.tree): Likewise.
2008-11-18 Jonathan Pryor <[email protected]>
* Makefile.am (EXTRA_DIST): Add mono-file-formats{.config,.source} and
@@ -67,6 +11,14 @@
pages so that they're valid for building from mono/docs.
* monoapi.make: Rename to docs.make.
2008-11-18 Jonathan Pryor <[email protected]>
* docs.make, Makefile.am: Build mono-file-formats{.tree,.zip},
mono-tool{.tree,.zip} files.
* mono-file-formats.config, mono-tools.config: Alter paths to man
pages so that they're valid for building from mono/docs.
* monoapi.make: Rename to docs.make.
2008-11-01 Raja R Harinath <[email protected]>
* Makefile.am: Clean up for srcdir != builddir.
+15 -16
View File
@@ -1,8 +1,6 @@
sourcesdir = $(prefix)/lib/monodoc/sources
sources_DATA = \
mono-file-formats.source \
mono-tools.source \
monoapi.source \
$(ASSEMBLED_DOCS)
@@ -14,6 +12,7 @@ ASSEMBLED_DOCS = \
EXTRA_DIST = \
abc-removal.txt \
AgilityPack.dll \
aot-compiler.txt \
api-style.css \
assembly-bundle \
check-exports \
@@ -24,6 +23,7 @@ EXTRA_DIST = \
docs.make \
documented \
embedded-api \
exception-handling.txt \
exceptions \
exdoc \
file-share-modes \
@@ -34,6 +34,7 @@ EXTRA_DIST = \
internal-calls \
ir-desc \
jit-imt \
jit-regalloc \
jit-thoughts \
jit-trampolines \
local-regalloc.txt \
@@ -60,6 +61,7 @@ EXTRA_DIST = \
ssapre.txt \
stack-alignment \
stack-overflow.txt \
thread-safety.txt \
threading \
toc.xml \
TODO \
@@ -77,21 +79,18 @@ clean-local:
-rm -f $(srcdir)/deploy/* $(srcdir)/convert.exe*
-cd $(srcdir) && rm -f $(ASSEMBLED_DOCS)
monoapi.zip: monoapi.tree
@test -f $@ || { rm -f $(srcdir)/monoapi.tree && $(MAKE) monoapi.tree; }
monoapi.tree: docs.make Makefile.am toc.xml $(srcdir)/deploy/.stamp
cd $(srcdir) && cp api-style.css deploy
cd $(srcdir) && $(MAKE) -f docs.make topdir=$(mcs_topdir_from_srcdir) $@
monoapi.zip : monoapi.tree
monoapi.tree: docs.make Makefile.am toc.xml deploy/.stamp
cp api-style.css deploy
cd $(srcdir) && $(MAKE) -f $< topdir=$(mcs_topdir_from_srcdir) $@
mono-tools.zip: mono-tools.tree
@test -f $@ || { rm -f $(srcdir)/mono-tools.tree && $(MAKE) mono-tools.tree; }
mono-tools.tree: docs.make Makefile.am $(srcdir)/deploy/.stamp
cd $(srcdir) && $(MAKE) -f docs.make topdir=$(mcs_topdir_from_srcdir) $@
mono-tools.zip : mono-tools.tree
mono-tools.tree: docs.make Makefile.am deploy/.stamp
cd $(srcdir) && $(MAKE) -f $< topdir=$(mcs_topdir_from_srcdir) $@
mono-file-formats.zip: mono-file-formats.tree
@test -f $@ || { rm -f $(srcdir)/mono-file-formats.tree && $(MAKE) mono-file-formats.tree; }
mono-file-formats.tree: docs.make Makefile.am $(srcdir)/deploy/.stamp
cd $(srcdir) && $(MAKE) -f docs.make topdir=$(mcs_topdir_from_srcdir) $@
mono-file-formats.zip : mono-file-formats.tree
mono-file-formats.tree: docs.make Makefile.am deploy/.stamp
cd $(srcdir) && $(MAKE) -f $< topdir=$(mcs_topdir_from_srcdir) $@
$(srcdir)/deploy/.stamp: convert.exe Makefile.am
$(mkdir_p) $(srcdir)/html
@@ -101,6 +100,6 @@ $(srcdir)/deploy/.stamp: convert.exe Makefile.am
extract: $(srcdir)/deploy/.stamp
convert.exe: convert.cs AgilityPack.dll
convert.exe: docs.make convert.cs Makefile.am
cd $(srcdir) && $(MAKE) -f docs.make topdir=$(mcs_topdir_from_srcdir) convert.exe
-6
View File
@@ -1,9 +1,3 @@
Documentation is now maintained on the mono wiki:
http://www.mono-project.com/Mono:Runtime:Documentation
Older documents or documents which were not yet migrated to the wiki are kept here.
* Scripts to maintain the Mono VM internal API
Layout
+393
View File
@@ -0,0 +1,393 @@
Mono Ahead Of Time Compiler
===========================
The Ahead of Time compilation feature in Mono allows Mono to
precompile assemblies to minimize JIT time, reduce memory
usage at runtime and increase the code sharing across multiple
running Mono application.
To precompile an assembly use the following command:
mono --aot -O=all assembly.exe
The `--aot' flag instructs Mono to ahead-of-time compile your
assembly, while the -O=all flag instructs Mono to use all the
available optimizations.
* Caching metadata
------------------
Besides code, the AOT file also contains cached metadata information which allows
the runtime to avoid certain computations at runtime, like the computation of
generic vtables. This reduces both startup time, and memory usage. It is possible
to create an AOT image which contains only this cached information and no code by
using the 'metadata-only' option during compilation:
mono --aot=metadata-only assembly.exe
This works even on platforms where AOT is not normally supported.
* Position Independent Code
---------------------------
On x86 and x86-64 the code generated by Ahead-of-Time compiled
images is position-independent code. This allows the same
precompiled image to be reused across multiple applications
without having different copies: this is the same way in which
ELF shared libraries work: the code produced can be relocated
to any address.
The implementation of Position Independent Code had a
performance impact on Ahead-of-Time compiled images but
compiler bootstraps are still faster than JIT-compiled images,
specially with all the new optimizations provided by the Mono
engine.
* How to support Position Independent Code in new Mono Ports
------------------------------------------------------------
Generated native code needs to reference various runtime
structures/functions whose address is only known at run
time. JITted code can simple embed the address into the native
code, but AOT code needs to do an indirection. This
indirection is done through a table called the Global Offset
Table (GOT), which is similar to the GOT table in the Elf
spec. When the runtime saves the AOT image, it saves some
information for each method describing the GOT table entries
used by that method. When loading a method from an AOT image,
the runtime will fill out the GOT entries needed by the
method.
* Computing the address of the GOT
Methods which need to access the GOT first need to compute its
address. On the x86 it is done by code like this:
call <IP + 5>
pop ebx
add <OFFSET TO GOT>, ebx
<save got addr to a register>
The variable representing the got is stored in
cfg->got_var. It is allways allocated to a global register to
prevent some problems with branches + basic blocks.
* Referencing GOT entries
Any time the native code needs to access some other runtime
structure/function (i.e. any time the backend calls
mono_add_patch_info ()), the code pointed by the patch needs
to load the value from the got. For example, instead of:
call <ABSOLUTE ADDR>
it needs to do:
call *<OFFSET>(<GOT REG>)
Here, the <OFFSET> can be 0, it will be fixed up by the AOT compiler.
For more examples on the changes required, see
svn diff -r 37739:38213 mini-x86.c
* The Program Linkage Table
As in ELF, calls made from AOT code do not go through the GOT. Instead, a direct call is
made to an entry in the Program Linkage Table (PLT). This is based on the fact that on
most architectures, call instructions use a displacement instead of an absolute address, so
they are already position independent. An PLT entry is usually a jump instruction, which
initially points to some trampoline code which transfers control to the AOT loader, which
will compile the called method, and patch the PLT entry so that further calls are made
directly to the called method.
If the called method is in the same assembly, and does not need initialization (i.e. it
doesn't have GOT slots etc), then the call is made directly, bypassing the PLT.
* Implementation
----------------
** The Precompiled File Format
-----------------------------
We use the native object format of the platform. That way it
is possible to reuse existing tools like objdump and the
dynamic loader. All we need is a working assembler, i.e. we
write out a text file which is then passed to gas (the gnu
assembler) to generate the object file.
The precompiled image is stored in a file next to the original
assembly that is precompiled with the native extension for a shared
library (on Linux its ".so" to the generated file).
For example: basic.exe -> basic.exe.so; corlib.dll -> corlib.dll.so
To avoid symbol lookup overhead and to save space, some things like the
compiled code of the individual methods are not identified by specific symbols
like method_code_1234. Instead, they are stored in one big array and the
offsets inside this array are stored in another array, requiring just two
symbols. The offsets array is usually named 'FOO_offsets', where FOO is the
array the offsets refer to, like 'methods', and 'method_offsets'.
Generating code using an assembler and linker has some disadvantages:
- it requires GNU binutils or an equivalent package to be installed on the
machine running the aot compilation.
- it is slow.
There is some support in the aot compiler for directly emitting elf files, but
its not complete (yet).
The following things are saved in the object file and can be
looked up using the equivalent to dlsym:
mono_assembly_guid
A copy of the assembly GUID.
mono_aot_version
The format of the AOT file format.
mono_aot_opt_flags
The optimizations flags used to build this
precompiled image.
method_infos
Contains additional information needed by the runtime for using the
precompiled method, like the GOT entries it uses.
method_info_offsets
Maps method indexes to offsets in the method_infos array.
mono_icall_table
A table that lists all the internal calls
references by the precompiled image.
mono_image_table
A list of assemblies referenced by this AOT
module.
methods
The precompiled code itself.
method_offsets
Maps method indexes to offsets in the methods array.
ex_info
Contains information about methods which is rarely used during normal execution,
like exception and debug info.
ex_info_offsets
Maps method indexes to offsets in the ex_info array.
class_info
Contains precomputed metadata used to speed up various runtime functions.
class_info_offsets
Maps class indexes to offsets in the class_info array.
class_name_table
A hash table mapping class names to class indexes. Used to speed up
mono_class_from_name ().
plt
The Program Linkage Table
plt_info
Contains information needed to find the method belonging to a given PLT entry.
** Source file structure
-----------------------------
The AOT infrastructure is split into two files, aot-compiler.c and
aot-runtime.c. aot-compiler.c contains the AOT compiler which is invoked by
--aot, while aot-runtime.c contains the runtime support needed for loading
code and other things from the aot files.
** Compilation process
----------------------------
AOT compilation consists of the following stages:
- collecting the methods to be compiled.
- compiling them using the JIT.
- emitting the JITted code and other information into an assembly file (.s).
- assembling the file using the system assembler.
- linking the resulting object file into a shared library using the system
linker.
** Handling compiled code
----------------------------
Each method is identified by a method index. For normal methods, this is
equivalent to its index in the METHOD metadata table. For runtime generated
methods (wrappers), it is an arbitrary number.
Compiled code is created by invoking the JIT, requesting it to created AOT
code instead of normal code. This is done by the compile_method () function.
The output of the JIT is compiled code and a set of patches (relocations). Each
relocation specifies an offset inside the compiled code, and a runtime object
whose address is accessed at that offset.
Patches are described by a MonoJumpInfo structure. From the perspective
of the AOT compiler, there are two kinds of patches:
- calls, which require an entry in the PLT table.
- everything else, which require an entry in the GOT table.
How patches is handled is described in the next section.
After all the method are compiled, they are emitted into the output file into
a byte array called 'methods', The emission
is done by the emit_method_code () and emit_and_reloc_code () functions. Each
piece of compiled code is identified by the local symbol .Lm_<method index>.
While compiled code is emitted, all the locations which have an associated patch
are rewritten using a platform specific process so the final generated code will
refer to the plt and got entries belonging to the patches.
The compiled code array
can be accessed using the 'methods' global symbol.
** Handling patches
----------------------------
Before a piece of AOTed code can be used, the GOT entries used by it must be
filled out with the addresses of runtime objects. Those objects are identified
by MonoJumpInfo structures. These stuctures are saved in a serialized form in
the AOT file, so the AOT loader can deconstruct them. The serialization is done
by the encode_patch () function, while the deserialization is done by the
decode_patch_info () function.
Every method has an associated method info blob inside the 'method_info' byte
array in the AOT file. This contains all the information required to load the
method at runtime:
- the first got entry used by the method.
- the number of got entries used by the method.
- the serialized patch info for the got entries.
Some patches, like vtables, icalls are very common, so instead of emitting their
info every time they are used by a method, we emit the info only once into a
byte array named 'got_info', and only emit an index into this array for every
access.
** The Procedure Linkage Table (PLT)
------------------------------------
Our PLT is similar to the elf PLT, it is used to handle calls between methods.
If method A needs to call method B, then an entry is allocated in the PLT for
method B, and A calls that entry instead of B directly. This is useful because
in some cases the runtime needs to do some processing the first time B is
called.
There are two cases:
- if B is in another assembly, then it needs to be looked up, then JITted or the
corresponding AOT code needs to be found.
- if B is in the same assembly, but has got slots, then the got slots need to be
initialized.
If none of these cases is true, then the PLT is not used, and the call is made
directly to the native code of the target method.
A PLT entry is usually implemented by a jump though a jump table, where the
jump table entries are initially filled up with the address of a trampoline so
the runtime can get control, and after the native code of the called method is
created/found, the jump table entry is changed to point to the native code.
All PLT entries also embed a integer offset after the jump which indexes into
the 'plt_info' table, which stores the information required to find the called
method. The PLT is emitted by the emit_plt () function.
** Exception/Debug info
----------------------------
Each compiled method has some additional info generated by the JIT, usable
for debugging (IL offset-native offset maps) and exception handling
(saved registers, native offsets of try/catch clauses). Since this info is
rarely needed, it is saved into a separate byte array called 'ex_info'.
** Cached metadata
---------------------------
When the runtime loads a class, it needs to compute a variety of information
which is not readily available in the metadata, like the instance size,
vtable, whenever the class has a finalizer/type initializer etc. Computing this
information requires a lot of time, causes the loading of lots of metadata,
and it usually involves the creation of many runtime data structures
(MonoMethod/MonoMethodSignature etc), which are long living, and usually persist
for the lifetime of the app. To avoid this, we compute the required information
at aot compilation time, and save it into the aot image, into an array called
'class_info'. The runtime can query this information using the
mono_aot_get_cached_class_info () function, and if the information is available,
it can avoid computing it.
** Full AOT mode
-------------------------
Some platforms like the iphone prohibit JITted code, using technical and/or
legal means. This is a significant problem for the mono runtime, since it
generates a lot of code dynamically, using either the JIT or more low-level
code generation macros. To solve this, the AOT compiler is able to function in
full-aot or aot-only mode, where it generates and saves all the neccesary code
in the aot image, so at runtime, no code needs to be generated.
There are two kinds of code which needs to be considered:
- wrapper methods, that is methods whose IL is generated dynamically by the
runtime. They are handled by generating them in the add_wrappers () function,
then emitting them the same way as the 'normal' methods. The only problem is
that these methods do not have a methoddef token, so we need a separate table
in the aot image ('wrapper_info') to find their method index.
- trampolines and other small hand generated pieces of code. They are handled
in an ad-hoc way in the emit_trampolines () function.
* Performance considerations
----------------------------
Using AOT code is a trade-off which might lead to higher or
slower performance, depending on a lot of circumstances. Some
of these are:
- AOT code needs to be loaded from disk before being used, so
cold startup of an application using AOT code MIGHT be
slower than using JITed code. Warm startup (when the code is
already in the machines cache) should be faster. Also,
JITing code takes time, and the JIT compiler also need to
load additional metadata for the method from the disk, so
startup can be faster even in the cold startup case.
- AOT code is usually compiled with all optimizations turned
on, while JITted code is usually compiled with default
optimizations, so the generated code in the AOT case should
be faster.
- JITted code can directly access runtime data structures and
helper functions, while AOT code needs to go through an
indirection (the GOT) to access them, so it will be slower
and somewhat bigger as well.
- When JITting code, the JIT compiler needs to load a lot of
metadata about methods and types into memory.
- JITted code has better locality, meaning that if A method
calls B, then the native code for A and B is usually quite
close in memory, leading to better cache behaviour thus
improved performance. In contrast, the native code of
methods inside the AOT file is in a somewhat random order.
* Future Work
-------------
- Currently, when an AOT module is loaded, all of its
dependent assemblies are also loaded eagerly, and these
assemblies need to be exactly the same as the ones loaded
when the AOT module was created ('hard binding'). Non-hard
binding should be allowed.
- On x86, the generated code uses call 0, pop REG, add
GOTOFFSET, REG to materialize the GOT address. Newer
versions of gcc use a separate function to do this, maybe we
need to do the same.
- Currently, we get vtable addresses from the GOT. Another
solution would be to store the data from the vtables in the
.bss section, so accessing them would involve less
indirection.
+27
View File
@@ -0,0 +1,27 @@
Call Sites
Extracted from emails from Paolo Molaro
There are 3 basic different kinds of call sites:
1) normal calls:
call relative_displacement
2) virtual calls:
call *positive_offset(%register)
3) interface calls:
mov constant, %imt_register
call *negative_offset(%register)
The above is what happens on x86 and amd64, with different values of
%imt_register for each arch (this register is a constant, but it could
change with different mono builds, it should be likely one of
constants the runtime comunicates to the debugger). %register can
change depending on the callsite based on the register allocator
choices. Note that the constant for the interface calls won't
necessarily be a MonoMethod address: this could change in the future
to a simple number.
In all the 3 cases the JIT trampolines will need to inspect the call
site, but only in the first case the call site will be changed.
+4 -7
View File
@@ -10,20 +10,17 @@ ASSEMBLED_DOCS = \
convert.exe: convert.cs AgilityPack.dll
$(CSCOMPILE) -out:$@ $< -r:AgilityPack.dll
monoapi.zip: monoapi.tree
@test -f $@ || { rm -f $< && $(MAKE) $<; }
monoapi.zip : monoapi.tree
monoapi.tree: toc.xml docs.make
$(MDOC) assemble -o monoapi -f hb $<
mono-tools.zip: mono-tools.tree
@test -f $@ || { rm -f $< && $(MAKE) $<; }
mono-tools.zip : mono-tools.tree
mono-tools.tree: mono-tools.config docs.make
$(MDOC) assemble -o mono-tools -f man $<
mono-file-formats.zip: mono-file-formats.tree
@test -f $@ || { rm -f $< && $(MAKE) $<; }
mono-file-formats.zip : mono-file-formats.tree
mono-file-formats.tree: mono-file-formats.config docs.make
$(MDOC) assemble -o mono-file-formats -f man $<
.doc-stamp:
+330
View File
@@ -0,0 +1,330 @@
Exception Handling In the Mono Runtime
--------------------------------------
* Introduction
--------------
There are many types of exceptions which the runtime needs to
handle. These are:
- exceptions thrown from managed code using the 'throw' or 'rethrow' CIL
instructions.
- exceptions thrown by some IL instructions like InvalidCastException thrown
by the 'castclass' CIL instruction.
- exceptions thrown by runtime code
- synchronous signals received while in managed code
- synchronous signals received while in native code
- asynchronous signals
Since exception handling is very arch dependent, parts of the
exception handling code reside in the arch specific
exceptions-<ARCH>.c files. The architecture independent parts
are in mini-exceptions.c. The different exception types listed
above are generated in different parts of the runtime, but
ultimately, they all end up in the mono_handle_exception ()
function in mini-exceptions.c.
* Exceptions throw programmatically from managed code
-----------------------------------------------------
These exceptions are thrown from managed code using 'throw' or
'rethrow' CIL instructions. The JIT compiler will translate
them to a call to a helper function called
'mono_arch_throw/rethrow_exception'.
These helper functions do not exist at compile time, they are
created dynamically at run time by the code in the
exceptions-<ARCH>.c files.
They perform various stack manipulation magic, then call a
helper function usually named throw_exception (), which does
further processing in C code, then calls
mono_handle_exception() to do the rest.
* Exceptions thrown implicitly from managed code
------------------------------------------------
These exceptions are thrown by some IL instructions when
something goes wrong. When the JIT needs to throw such an
exception, it emits a forward conditional branch and remembers
its position, along with the exception which needs to be
emitted. This is usually done in macros named
EMIT_COND_SYSTEM_EXCEPTION in the mini-<ARCH>.c files.
After the machine code for the method is emitted, the JIT
calls the arch dependent mono_arch_emit_exceptions () function
which will add the exception throwing code to the end of the
method, and patches up the previous forward branches so they
will point to this code.
This has the advantage that the rarely-executed exception
throwing code is kept separate from the method body, leading
to better icache performance.
The exception throwing code braches to the dynamically
generated mono_arch_throw_corlib_exception helper function,
which will create the proper exception object, does some stack
manipulation, then calls throw_exception ().
* Exceptions thrown by runtime code
-----------------------------------
These exceptions are usually thrown by the implementations of
InternalCalls (icalls). First an appropriate exception object
is created with the help of various helper functions in
metadata/exception.c, which has a separate helper function for
allocating each kind of exception object used by the runtime
code. Then the mono_raise_exception () function is called to
actually throw the exception. That function never returns.
An example:
if (something_is_wrong)
mono_raise_exception (mono_get_exception_index_out_of_range ());
mono_raise_exception () simply passes the exception to the JIT
side through an API, where it will be received by helper
created by mono_arch_throw_exception (). From now on, it is
treated as an exception thrown from managed code.
* Synchronous signals
---------------------
For performance reasons, the runtime does not do same checks
required by the CLI spec. Instead, it relies on the CPU to do
them. The two main checks which are omitted are null-pointer
checks, and arithmetic checks. When a null pointer is
dereferenced by JITted code, the CPU will notify the kernel
through an interrupt, and the kernel will send a SIGSEGV
signal to the process. The runtime installs a signal handler
for SIGSEGV, which is sigsegv_signal_handler () in mini.c. The
signal handler creates the appropriate exception object and
calls mono_handle_exception () with it. Arithmetic exceptions
like division by zero are handled similarly.
* Synchronous signals in native code
------------------------------------
Receiving a signal such as SIGSEGV while in native code means
something very bad has happened. Because of this, the runtime
will abort after trying to print a managed plus a native stack
trace. The logic is in the mono_handle_native_sigsegv ()
function.
Note that there are two kinds of native code which can be the
source of the signal:
- code inside the runtime
- code inside a native library loaded by an application, ie. libgtk+
* Stack overflow checking
-------------------------
Stack overflow exceptions need special handling. When a thread
overflows its stack, the kernel sends it a normal SIGSEGV
signal, but the signal handler tries to execute on the same as
the thread leading to a further SIGSEGV which will terminate
the thread. A solution is to use an alternative signal stack
supported by UNIX operating systems through the sigaltstack
(2) system call. When a thread starts up, the runtime will
install an altstack using the mono_setup_altstack () function
in mini-exceptions.c. When a SIGSEGV is received, the signal
handler checks whenever the fault address is near the bottom
of the threads normal stack. If it is, a
StackOverflowException is created instead of a
NullPointerException. This exception is handled like any other
exception, with some minor differences.
There are two reasons why sigaltstack is disabled by default:
* The main problem with sigaltstack() is that the stack
employed by it is not visible to the GC and it is possible
that the GC will miss it.
* Working sigaltstack support is very much os/kernel/libc
dependent, so it is disabled by default.
* Asynchronous signals
----------------------
Async signals are used by the runtime to notify a thread that
it needs to change its state somehow. Currently, it is used
for implementing thread abort/suspend/resume.
Handling async signals correctly is a very hard problem,
since the receiving thread can be in basically any state upon
receipt of the signal. It can execute managed code, native
code, it can hold various managed/native locks, or it can be
in a process of acquiring them, it can be starting up,
shutting down etc. Most of the C APIs used by the runtime are
not asynch-signal safe, meaning it is not safe to call them
from an async signal handler. In particular, the pthread
locking functions are not async-safe, so if a signal handler
interrupted code which was in the process of acquiring a lock,
and the signal handler tries to acquire a lock, the thread
will deadlock. Unfortunately, the current signal handling
code does acquire locks, so sometimes it does deadlock.
When receiving an async signal, the signal handler first tries
to determine whenever the thread was executing managed code
when it was interrupted. If it did, then it is safe to
interrupt it, so a ThreadAbortException is constructed and
thrown. If the thread was executing native code, then it is
generally not safe to interrupt it. In this case, the runtime
sets a flag then returns from the signal handler. That flag is
checked every time the runtime returns from native code to
managed code, and the exception is thrown then. Also, a
platform specific mechanism is used to cause the thread to
interrupt any blocking operation it might be doing.
The async signal handler is in sigusr1_signal_handler () in
mini.c, while the logic which determines whenever an exception
is safe to be thrown is in mono_thread_request_interruption
().
* Stack unwinding during exception handling
-------------------------------------------
The execution state of a thread during exception handling is
stored in an arch-specific structure called MonoContext. This
structure contains the values of all the CPU registers
relevant during exception handling, which usually means:
- IP (instruction pointer)
- SP (stack pointer)
- FP (frame pointer)
- callee saved registers
Callee saved registers are the registers which are required by
any procedure to be saved/restored before/after using
them. They are usually defined by each platforms ABI
(Application Binary Interface). For example, on x86, they are
EBX, ESI and EDI.
The code which calls mono_handle_exception () is required to
construct the initial MonoContext. How this is done depends on
the caller. For exceptions thrown from managed code, the
mono_arch_throw_exception helper function saves the values of
the required registers and passes them to throw_exception (),
which will save them in the MonoContext structure. For
exceptions thrown from signal handlers, the MonoContext
stucture is initialized from the signal info received from the
kernel.
During exception handling, the runtime needs to 'unwind' the
stack, i.e. given the state of the thread at a stack frame,
construct the state at its callers. Since this is platform
specific, it is done by a platform specific function called
mono_arch_find_jit_info ().
Two kinds of stack frames need handling:
- Managed frames are easier. The JIT will store some
information about each managed method, like which
callee-saved registers it uses. Based on this information,
mono_arch_find_jit_info () can find the values of the
registers on the thread stack, and restore them.
- Native frames are problematic, since we have no information
about how to unwind through them. Some compilers generate
unwind information for code, some don't. Also, there is no
general purpose library to obtain and decode this unwind
information. So the runtime uses a different solution. When
managed code needs to call into native code, it does through
a managed->native wrapper function, which is generated by
the JIT. This function is responsible for saving the machine
state into a per-thread structure called MonoLMF (Last
Managed Frame). These LMF structures are stored on the
threads stack, and are linked together using one of their
fields. When the unwinder encounters a native frame, it
simply pops one entry of the LMF 'stack', and uses it to
restore the frame state to the moment before control passed
to native code. In effect, all successive native frames are
skipped together.
Problems/future work
--------------------
1. Async signal safety
----------------------
The current async signal handling code is not async safe, so
it can and does deadlock in practice. It needs to be rewritten
to avoid taking locks at least until it can determine that it
was interrupting managed code.
Another problem is the managed stack frame unwinding code. It
blindly assumes that if the IP points into a managed frame,
then all the callee saved registers + the stack pointer are
saved on the stack. This is not true if the thread was
interrupted while executing the method prolog/epilog.
2. Raising exceptions from native code
--------------------------------------
Currently, exceptions are raised by calling
mono_raise_exception () in the middle of runtime code. This
has two problems:
- No cleanup is done, ie. if the caller of the function which
throws an exception has taken locks, or allocated memory,
that is not cleaned up. For this reason, it is only safe to
call mono_raise_exception () 'very close' to managed code,
ie. in the icall functions themselves.
- To allow mono_raise_exception () to unwind through native
code, we need to save the LMF structures which can add a lot
of overhead even in the common case when no exception is
thrown. So this is not zero-cost exception handling.
An alternative might be to use a JNI style
set-pending-exception API. Runtime code could call
mono_set_pending_exception (), then return to its caller with
an error indication allowing the caller to clean up. When
execution returns to managed code, then managed->native
wrapper could check whenever there is a pending exception and
throw it if neccesary. Since we already check for pending
thread interruption, this would have no overhead, allowing us
to drop the LMF saving/restoring code, or significant parts of
it.
4. libunwind
------------
There is an OSS project called libunwind which is a standalone
stack unwinding library. It is currently in development, but
it is used by default by gcc on ia64 for its stack
unwinding. The mono runtime also uses it on ia64. It has
several advantages in relation to our current unwinding code:
- it has a platform independent API, i.e. the same unwinding
code can be used on multiple platforms.
- it can generate unwind tables which are correct at every
instruction, i.e. can be used for unwinding from async
signals.
- given sufficient unwind info generated by a C compiler, it
can unwind through C code.
- most of its API is async-safe
- it implements the gcc C++ exception handling API, so in
theory it can be used to implement mixed-language exception
handling (i.e. C++ exception caught in mono, mono exception
caught in C++).
- it is MIT licensed
The biggest problem with libuwind is its platform support. ia64 support is
complete/well tested, while support for other platforms is missing/incomplete.
http://www.hpl.hp.com/research/linux/libunwind/
+283
View File
@@ -0,0 +1,283 @@
Register Allocation
===================
The current JIT implementation uses a tree matcher to generate code. We use a
simple algorithm to allocate registers in trees, and limit the number of used
temporary register to 4 when evaluating trees. So we can use 2 registers for
global register allocation.
Register Allocation for Trees
=============================
We always evaluate trees from left to right. When there are no more registers
available we need to spill values to memory. Here is the simplified algorithm.
gboolean
tree_allocate_regs (tree, exclude_reg)
{
if (!tree_allocate_regs (tree->left, -1))
return FALSE;
if (!tree_allocate_regs (tree->right, -1)) {
tree->left->spilled == TRUE;
free_used_regs (tree->left);
if (!tree_allocate_regs (tree->right, tree->left->reg))
return FALSE;
}
free_used_regs (tree->left);
free_used_regs (tree->right);
/* try to allocate a register (reg != exclude_reg) */
if ((tree->reg = next_free_reg (exclude_reg)) != -1)
return TRUE;
return FALSE;
}
The emit routing actually spills the registers:
tree_emit (tree)
{
tree_emit (tree->left);
if (tree->left->spilled)
save_reg (tree->left->reg);
tree_emit (tree->right);
if (tree->left->spilled)
restore_reg (tree->left->reg);
emit_code (tree);
}
Global Register Allocation
==========================
TODO.
Local Register Allocation
=========================
This section describes the cross-platform local register allocator which is
in the file mini-codegen.c.
The input to the allocator is a basic block which contains linear IL, ie.
instructions of the form:
DEST <- SRC1 OP SRC2
where DEST, SRC1, and SRC2 are virtual registers (vregs). The job of the
allocator is to assign hard or physical registers (hregs) to each virtual
registers so the vreg references in the instructions can be replaced with their
assigned hreg, allowing machine code to be generated later.
The allocator needs information about the number and types of arguments of
instructions. It takes this information from the machine description files. It
also needs arch specific information, like the number and type of the hard
registers. It gets this information from arch-specific macros.
Currently, the vregs and hregs are partitioned into two classes: integer and
floating point.
The allocator consists of two phases: In the first phase, a forward pass is
made over the instructions, collecting liveness information for vregs. In the
second phase, a backward pass is made over the instructions, assigning
registers. This backward mode of operation makes understanding the allocator
somewhat difficult to understand, but leads to better code in most cases.
Allocator state
===============
The state of the allocator is stored in two arrays: iassign and isymbolic.
iassign maps vregs to hregs, while isymbolic is the opposite.
For a vreg, iassign [vreg] can contain the following values:
* -1 vreg has no assigned hreg
* hreg index (>= 0) vreg is assigned to the given hreg. This means
later instructions (which we have already
processed due to the backward direction) expect
the value of vreg to be found in hreg.
* spill slot index (< -1) vreg is spilled to the given spill slot. This
means later instructions expect the value of
vreg to be found on the stack in the given
spill slot.
Also, the allocator keeps track of which hregs are free and which are used.
This information is stored in a bitmask called ifree_mask.
There is a similar set of data structures for floating point registers.
Spilling
========
When an allocator needs a free hreg, but all of them are assigned, it needs to
free up one of them. It does this by spilling the contents of the vreg which
is currently assigned to the selected hreg. Since later instructions expect
the vreg to be found in the selected hreg, the allocator emits a spill-load
instruction to load the value from the spill slot into the hreg after the
currently processed instruction. When the vreg which is spilled is a
destination in an instruction, the allocator will emit a spill-store to store
the value into the spill slot.
Fixed registers
===============
Some architectures, notably x86/amd64 require that the arguments/results of
some instructions be assigned to specific hregs. An example is the shift
opcodes on x86, where the second argument must be in ECX. The allocator
has support for this. It tries to allocate the vreg to the required hreg. If
thats not possible, then it will emit compensation code which moves values to
the correct registers before/after the instruction.
Fixed registers are mainly used on x86, but they are useful on more regular
architectures on well, for example to model that after a call instruction, the
return of the call is in a specific register.
A special case of fixed registers is two address architectures, like the x86,
where the instructions place their results into their first argument. This is
modelled in the allocator by allocating SRC1 and DEST to the same hreg.
Global registers
================
Some variables might already be allocated to hardware registers during the
global allocation phase. In this case, SRC1, SRC2 and DEST might already be
a hardware register. The allocator needs to do nothing in this case, except
when the architecture uses fixed registers, in which case it needs to emit
compensation code.
Register pairs
==============
64 bit arithmetic on 32 bit machines requires instructions whose arguments are
not registers, but register pairs. The allocator has support for this, both
for freely allocatable register pairs, and for register pairs which are
constrained to specific hregs (EDX:EAX on x86).
Floating point stack
====================
The x86 architecture uses a floating point register stack instead of a set of
fp registers. The allocator supports this by keeping track of the height of the
fp stack, and spilling/loading values from the stack as neccesary.
Calls
=====
Calls need special handling for two reasons: first, they will clobber all
caller-save registers, meaning their contents will need to be spilled. Also,
some architectures pass arguments in registers. The registers used for
passing arguments are usually the same as the ones used for local allocation,
so the allocator needs to handle them specially. This is done as follows:
the MonoInst for the call instruction contains a map mapping vregs which
contain the argument values to hregs where the argument needs to be placed,
like this (on amd64):
R33 -> RDI
R34 -> RSI
...
When the allocator processes the call instruction, it allocates the vregs
in the map to their associated hregs. So the call instruction is processed as
if having a variable number of arguments which fixed register assignments.
An example:
R33 <- 1
R34 <- 2
call
When the call instruction is processed, R33 is assigned to RDI, and R34 is
assigned to RSI. Later, when the two assignment instructions are processed,
R33 and R34 are already assigned to a hreg, so they are replaced with the
associated hreg leading to the following final code:
RDI <- 1
RSI <- 1
call
Machine description files
=========================
A typical entry in the machine description files looks like this:
shl: dest:i src1:i src2:s clob:1 len:2
The allocator is only interested in the dest,src1,src2 and clob fields.
It understands the following values for the dest, src1, src2 fields:
i - integer register
f - fp register
b - base register (same as i, but the instruction does not modify the reg)
m - fp register, even if an fp stack is used (no fp stack tracking)
It understands the following values for the clob field:
1 - sreg1 needs to be the same as dreg
c - instruction clobbers the caller-save registers
Beside these values, an architecture can define additional values (like the 's'
in the example). The allocator depends on a set of arch-specific macros to
convert these values to information it needs during allocation.
Arch specific macros
====================
These macros usually receive a value from the machine description file (like
the 's' in the example). The examples below are for x86.
/*
* A bitmask selecting the caller-save registers (these are used for local
* allocation).
*/
#define MONO_ARCH_CALLEE_REGS X86_CALLEE_REGS
/*
* A bitmask selecting the callee-saved registers (these are usually used for
* global allocation).
*/
#define MONO_ARCH_CALLEE_SAVED_REGS X86_CALLER_REGS
/* Same for the floating point registers */
#define MONO_ARCH_CALLEE_FREGS 0
#define MONO_ARCH_CALLEE_SAVED_FREGS 0
/* Whenever the target uses a floating point stack */
#define MONO_ARCH_USE_FPSTACK TRUE
/* The size of the floating point stack */
#define MONO_ARCH_FPSTACK_SIZE 6
/*
* Given a descriptor value from the machine description file, return the fixed
* hard reg corresponding to that value.
*/
#define MONO_ARCH_INST_FIXED_REG(desc) ((desc == 's') ? X86_ECX : ((desc == 'a') ? X86_EAX : ((desc == 'd') ? X86_EDX : ((desc == 'y') ? X86_EAX : ((desc == 'l') ? X86_EAX : -1)))))
/*
* A bitmask selecting the hregs which can be used for allocating sreg2 for
* a given instruction.
*/
#define MONO_ARCH_INST_SREG2_MASK(ins) (((ins [MONO_INST_CLOB] == 'a') || (ins [MONO_INST_CLOB] == 'd')) ? (1 << X86_EDX) : 0)
/*
* Given a descriptor value, return whenever it denotes a register pair.
*/
#define MONO_ARCH_INST_IS_REGPAIR(desc) (desc == 'l' || desc == 'L')
/*
* Given a descriptor value, and the first register of a regpair, return a
* bitmask selecting the hregs which can be used for allocating the second
* register of the regpair.
*/
#define MONO_ARCH_INST_REGPAIR_REG2(desc,hreg1) (desc == 'l' ? X86_EDX : -1)
+32
View File
@@ -0,0 +1,32 @@
Metadata memory management
--------------------------
Most metadata structures have a lifetime which is equal to the MonoImage where they are
loaded from. These structures should be allocated from the memory pool of the
corresponding MonoImage. The memory pool is protected by the loader lock.
Examples of metadata structures in this category:
- MonoClass
- MonoMethod
- MonoType
Memory owned by these structures should be allocated from the image mempool as well.
Examples include: klass->methods, klass->fields, method->signature etc.
Generics complicates things. A generic class could have many instantinations where the
generic arguments are from different assemblies. Where should we allocate memory for
instantinations ? We can allocate from the mempool of the image which contains the
generic type definition, but that would mean that the instantinations would remain in
memory even after the assemblies containing their type arguments are unloaded, leading
to a memory leak. Therefore, we do the following:
- data structures representing the generic definitions are allocated from the image
mempool as usual. These include:
- generic class definition (MonoGenericClass->container_class)
- generic method definitions
- type parameters (MonoGenericParam)
- data structures representing inflated classes/images are allocated from the heap. These
structures are kept in a cache, indexed by type arguments of the instantinations. When
an assembly is unloaded, this cache is searched and all instantinations referencing
types from the assembly are freed. This is done by mono_metadata_clean_for_image ()
in metadata.c. The structures handled this way include:
- MonoGenericClass
- MonoGenericInst
- inflated MonoMethods
+6 -59
View File
@@ -417,19 +417,12 @@
* Testing the port
The JIT has a set of regression tests in *.cs files inside the
mini directory.
The usual method of testing a port is by compiling these tests on
another machine with a working runtime by typing 'make rcheck',
then copying TestDriver.dll and *.exe to the mini directory. The
tests can be run by typing:
The JIT has a set of regression tests in *.cs files inside the mini directory.
The usual method of testing a port is by compiling these tests on another machine
with a working runtime by typing 'make rcheck', then copying TestDriver.dll and
*.exe to the mini directory. The tests can be run by typing:
./mono --regression <exe file name>
The suggested order for working through these tests is the
following:
The suggested order for working through these tests is the following:
- basic.exe
- basic-long.exe
- basic-float.exe
@@ -480,52 +473,6 @@
at this point, so the only parts which require changing are
the arch dependent files.
* Function descriptors
Some ABIs, like those for IA64 and PPC64, don't use direct
function pointers, but so called function descriptors. A
function descriptor is a short data structure which contains
at least a pointer to the code of the function and a pointer
to a GOT/TOC, which needs to be loaded into a specific
register prior to jumping to the function. Global variables
and large constants are accessed through that register.
Mono does not need function descriptors for the JITted code,
but we need to handle them when calling unmanaged code and we
need to create them when passing managed code to unmanaged
code.
mono_create_ftnptr() creates a function descriptor for a piece
of generated code within a specific domain.
mono_get_addr_from_ftnptr() returns the pointer to the native
code in a function descriptor. Never use this function to
generate a jump to a function without loading the GOT/TOC
register unless the function descriptor was created by
mono_create_ftnptr().
See the sources for IA64 and PPC64 on when to create and when
to dereference function descriptors. On PPC64 function
descriptors for various generated helper functions (in
exceptions-ppc.c and tramp-ppc.c) are generated in front of
the code they refer to (see ppc_create_pre_code_ftnptr()). On
IA64 they are created separately.
* Emulated opcodes
Mini has code for emulating quite a few opcodes, most notably
operations on longs, int/float conversions and atomic
operations. If an architecture wishes such an opcode to be
emulated, mini produces icalls instead of those opcodes. This
should only be considered when the operation cannot be
implemented efficiently and thus the overhead occured by the
icall is not relatively large. Emulation of operations is
controlled by #defines in the arch header, but the naming is
not consistent. They usually start with MONO_ARCH_EMULATE_,
MONO_ARCH_NO_EMULATE_ and MONO_ARCH_HAVE_.
* Generic code sharing
Generic code sharing is optional. See the file
"generic-sharing" for information on how to support it on an
architecture.
+2 -1
View File
@@ -1,4 +1,5 @@
<?xml version="1.0"?>
<monodoc>
<source provider="man" basefile="mono-file-formats" path="man"/>
<node label="Mono File Formats" name="mono-formats" parent="formats" />
<source provider="man" basefile="mono-file-formats" path="mono-formats"/>
</monodoc>
+2 -1
View File
@@ -1,4 +1,5 @@
<?xml version="1.0"?>
<monodoc>
<source provider="man" basefile="mono-tools" path="man"/>
<node label="Mono Development Tools" name="dev-tools" parent="tools" />
<source provider="man" basefile="mono-tools" path="dev-tools"/>
</monodoc>
+1 -2
View File
@@ -23,8 +23,7 @@ typedef struct {
@API_IDX@
</div>
<a name="cil_assembly_load"/>
<h3>Assembly Loading</h3>
<h4><a name="api:mono_assembly_open">mono_assembly_open</a></h4>
+2 -4
View File
@@ -1,8 +1,7 @@
<h2>Image Manipulation</h2>
<p>Images are the component of assemblies that actually hold
the CIL code and <a href="mono-api-metadata.html">metadata</a>
in the extended PE/COFF file.
the CIL code in the extended PE/COFF file.
<h3>Synopsis</h3>
@@ -24,8 +23,7 @@ typedef enum {
<p>Images are the actual elements in the runtime that contain
the actual code being executed.
<a name="cil_image_open"/>
<h3>Opening and closing MonoImages</h3>
<h4><a name="api:mono_image_open">mono_image_open</a></h4>
+53 -656
View File
@@ -1,650 +1,47 @@
<h1>Metadata Reading</h1>
<h3>Metadata Loader Locking</h3>
<p>The Metadata API gives developers low-level access to the
information encoded in CLI modules: type and
methods definitions encoded in metadata as well as access to
the CIL code and embedded resources.
<p>Managed developers access this information using either the
System.Reflection API or a library
like <a href="http://www.mono-project.com/Cecil">Cecil</a>.
<p>To start using the Metadata API it is necessary
to <a href="mono-api-assembly.html#cil_assembly_load">open an
assembly</a> or a CIL image (a .dll or .exe file) using one of
the
<a href="mono-api-image.html#cil_image_open">CIL image
opening</a> API calls.
<h2>Metadata Heaps</h2>
<p>ECMA CLI images contain four heaps that store different
kinds of information, these are:
<ul>
<li>GUID heap (called #GUID) contains 128-bit GUIDs,
you can get pointer to a GUID value by
calling <a href="#api:mono_metadata_guid_heap">mono_metadata_guid_heap</a>.
<li>User string heap (called #US), it contains user
visible strings, you can fetch a string from this heap
by calling
<a href="#api:mono_metadata_user_string">mono_metadata_user_string</a>.
<li>Blob heap (called #blob), it contains binary
blobs of data, you can get a blob
by <a href="#api:mono_metadata_blob_heap">mono_metadata_blob_heap</a>.
You can determine the size of the blob using
the <a href="#api:mono_metadata_decode_blob_size">mono_metadata_decode_blob_size</a>.
<p>The locking functions here are used by code in class.c and
metadata.c to lock access to the shared hashtables inside the
MonoImage
</ul>
<h4><a name="api:mono_loader_lock">mono_loader_lock</a></h4>
<h4><a name="api:mono_loader_unlock">mono_loader_unlock</a></h4>
<p>The ECMA file format also has an extra section called the
"#~" stream, this stream is the one that holds the metadata
tables. There is a high-level API to get access to the
contents of this API, described in the
section <a href="#metadata-tables">Metadata Tables</a>.
<h4><a name="api:mono_metadata_guid_heap">mono_metadata_guid_heap</a></h4>
<h4><a name="api:mono_metadata_string_heap">mono_metadata_string_heap</a></h4>
<h4><a name="api:mono_metadata_blob_heap">mono_metadata_blob_heap</a></h4>
<h4><a name="api:mono_metadata_user_string">mono_metadata_user_string</a></h4>
<h4><a name="api:mono_metadata_decode_blob_size">mono_metadata_decode_blob_size</a></h4>
<a name="metadata-tables"/>
<h2>Metadata Tables</h2>
<p>Metadata is encoded in a number of tables included on every
CIL image. These tables contain type definitions, member
definitions and so on, these constants are defined in the ECMA 335
specification Partition II section 22. The following table
shows the C constants defined in the Mono runtime and how they
map to the equivalent ECMA CLI metadata table:
<center>
<table border=1>
<thead>
<td>
<b>ECMA CLI Table Name</b>
</td>
<td>
<b>C Constant Name</b>
</td>
<td>
<b>Table Schema (Array Size + Columns Constants)</b>
</td>
</thead>
<td>Assembly</td><td>MONO_TABLE_ASSEMBLY</td><td>
Array size:
MONO_ASSEMBLY_SIZE
<ul>
<li>MONO_ASSEMBLY_HASH_ALG
<li>MONO_ASSEMBLY_MAJOR_VERSION
<li>MONO_ASSEMBLY_MINOR_VERSION
<li>MONO_ASSEMBLY_BUILD_NUMBER
<li>MONO_ASSEMBLY_REV_NUMBER
<li>MONO_ASSEMBLY_FLAGS
<li>MONO_ASSEMBLY_PUBLIC_KEY
<li>MONO_ASSEMBLY_NAME
<li>MONO_ASSEMBLY_CULTURE
</ul>
</td>
</tr>
<td>AssemblyOS</td><td>MONO_TABLE_ASSEMBLYOS</td><td>
Array size:
MONO_ASSEMBLYOS_SIZE
<ul>
<li>MONO_ASSEMBLYOS_PLATFORM
<li>MONO_ASSEMBLYOS_MAJOR_VERSION
<li>MONO_ASSEMBLYOS_MINOR_VERSION
</ul>
</td>
</tr>
<td>AssemblyProcessor</td><td>MONO_TABLE_ASSEMBLYPROCESSOR</td><td>Array
size: MONO_ASSEMBLYPROCESSOR_SIZE
<ul>
<li>MONO_ASSEMBLY_PROCESSOR
</ul>
</td>
</tr>
<td>AssemblyRef</td><td>MONO_TABLE_ASSEMBLYREF</td><td>
Array size:
MONO_ASSEMBLYREF_SIZE
<ul>
<li>MONO_ASSEMBLYREF_MAJOR_VERSION
<li>MONO_ASSEMBLYREF_MINOR_VERSION
<li>MONO_ASSEMBLYREF_BUILD_NUMBER
<li>MONO_ASSEMBLYREF_REV_NUMBER
<li>MONO_ASSEMBLYREF_FLAGS
<li>MONO_ASSEMBLYREF_PUBLIC_KEY
<li>MONO_ASSEMBLYREF_NAME
<li>MONO_ASSEMBLYREF_CULTURE
<li>MONO_ASSEMBLYREF_HASH_VALUE
</ul>
</td>
</tr>
<td>AssemblyRefProcessor</td><td>MONO_TABLE_ASSEMBLYREFPROCESSOR</td><td>Array
size: MONO_ASSEMBLYREFPROC_SIZE
<ul>
<li>MONO_ASSEMBLYREFPROC_PROCESSOR
<li>MONO_ASSEMBLYREFPROC_ASSEMBLYREF
</ul>
</td>
</tr>
<td>AssemblyRefOS</td><td>MONO_TABLE_ASSEMBLYREFOS</td><td>
Array size:
<li>MONO_ASSEMBLYREFOS_SIZE
<ul>
<li>MONO_ASSEMBLYREFOS_PLATFORM
<li>MONO_ASSEMBLYREFOS_MAJOR_VERSION
<li>MONO_ASSEMBLYREFOS_MINOR_VERSION
<li>MONO_ASSEMBLYREFOS_ASSEMBLYREF
</ul>
</td>
</tr>
<td>ClassLayout</td><td>MONO_TABLE_CLASSLAYOUT</td><td>
Array size:
MONO_CLASSLAYOUT_SIZE
<ul>
<li>MONO_CLASS_LAYOUT_PACKING_SIZE
<li>MONO_CLASS_LAYOUT_CLASS_SIZE
<li>MONO_CLASS_LAYOUT_PARENT
</ul>
</td>
</tr>
<td>Constant</td><td>MONO_TABLE_CONSTANT</td><td>
Array size:
MONO_CONSTANT_SIZE
<ul>
<li>MONO_CONSTANT_TYPE
<li>MONO_CONSTANT_PADDING
<li>MONO_CONSTANT_PARENT
<li>MONO_CONSTANT_VALUE
</ul>
</td>
</tr>
<td>CustomAttribute</td><td>MONO_TABLE_CUSTOMATTRIBUTE</td><td>
Array size:
MONO_CUSTOM_ATTR_SIZE
<ul>
<li>MONO_CUSTOM_ATTR_PARENT
<li>MONO_CUSTOM_ATTR_TYPE
<li>MONO_CUSTOM_ATTR_VALUE
</ul>
</td>
</tr>
<td>DeclSecurity</td><td>MONO_TABLE_DECLSECURITY</td><td>
Array size:
MONO_DECL_SECURITY_SIZE
<ul>
<li>MONO_DECL_SECURITY_ACTION
<li>MONO_DECL_SECURITY_PARENT
<li>MONO_DECL_SECURITY_PERMISSIONSET
</ul>
</td>
</tr>
<td>EventMap</td><td>MONO_TABLE_EVENTMAP</td><td>
Array size:
MONO_EVENT_MAP_SIZE
<ul>
<li>MONO_EVENT_MAP_PARENT
<li>MONO_EVENT_MAP_EVENTLIST
</ul>
</td>
</tr>
<td>EventPtr</td><td>MONO_TABLE_EVENT_POINTER</td><td>
Array size:
MONO_EVENT_POINTER_SIZE
<ul>
<li>MONO_EVENT_POINTER_EVENT
</ul>
</td>
</tr>
<td>Event</td><td>MONO_TABLE_EVENT</td><td>
Array size: MONO_EVENT_SIZE
<ul>
<li>MONO_EVENT_FLAGS
<li>MONO_EVENT_NAME
<li>MONO_EVENT_TYPE
</ul>
</td>
</tr>
<td>ExportedType</td><td>MONO_TABLE_EXPORTEDTYPE</td><td>
Array size:
MONO_EXPORTEDTYPE_SIZE
<ul>
<li>MONO_EXP_TYPE_FLAGS
<li>MONO_EXP_TYPE_TYPEDEF
<li>MONO_EXP_TYPE_NAME
<li>MONO_EXP_TYPE_NAMESPACE
<li>MONO_EXP_TYPE_IMPLEMENTATION
</ul>
</td>
</tr>
<td>Field</td><td>MONO_TABLE_FIELD</td><td>
Array size: MONO_FIELD_SIZE
<ul>
<li>MONO_FIELD_FLAGS
<li>MONO_FIELD_NAME
<li>MONO_FIELD_SIGNATURE
</ul>
</td>
</tr>
<td>FieldLayoutt</td><td>MONO_TABLE_FIELDLAYOUT</td><td>
Array size:
MONO_FIELDLAYOUT_SIZE
<ul>
<li>MONO_FIELD_LAYOUT_OFFSET
<li>MONO_FIELD_LAYOUT_FIELD
</ul>
</td>
</tr>
<td>FieldMarshal</td><td>MONO_TABLE_FIELDMARSHAL</td><td>
Array size:
MONO_FIELD_MARSHAL_SIZE
<ul>
<li>MONO_FIELD_MARSHAL_PARENT
<li>MONO_FIELD_MARSHAL_NATIVE_TYPE
</ul>
</td>
</tr>
<td>FieldPtr</td><td>MONO_TABLE_FIELD_POINTER</td><td>
Array size:
MONO_FIELD_POINTER_SIZE
<ul>
<li>MONO_FIELD_POINTER_FIELD
</ul>
</td>
</tr>
<td>FieldRVA</td><td>MONO_TABLE_FIELDRVA</td><td>
Array size:
MONO_FIELDRVA_SIZE
<ul>
<li>MONO_FIELD_RVA_RVA
<li>MONO_FIELD_RVA_FIELD
</ul>
</td>
</tr>
<td>File</td><td>MONO_TABLE_FILE</td><td>
Array size: MONO_FILE_SIZE
<ul>
<li>MONO_FILE_FLAGS
<li>MONO_FILE_NAME
<li>MONO_FILE_HASH_VALUE
</ul>
</td>
</tr>
<td>GenericParam</td><td>MONO_TABLE_GENERICPARAM</td><td>
Array size:
MONO_GENERICPARAM_SIZE
<ul>
<li>MONO_GENERICPARAM_NUMBER
<li>MONO_GENERICPARAM_FLAGS
<li>MONO_GENERICPARAM_OWNER
<li>MONO_GENERICPARAM_NAME
</ul>
</td>
</tr>
<td>GenericParamConstraint</td><td>MONO_TABLE_GENERICPARAMCONSTRAINT</td><td>Array
size: MONO_GENERICPARAMCONSTRAINT_SIZE
<ul>
<li>MONO_GENPARCONSTRAINT_GENERICPAR
<li>MONO_GENPARCONSTRAINT_CONSTRAINT
</ul>
</td>
<tr>
<td>ImplMap</td><td>MONO_TABLE_IMPLMAP</td><td>
Array size:
MONO_IMPLMAP_SIZE
<ul>
<li>MONO_IMPLMAP_FLAGS
<li>MONO_IMPLMAP_MEMBER
<li>MONO_IMPLMAP_NAME
<li>MONO_IMPLMAP_SCOPE
</ul>
</td>
</tr>
<td>InterfaceImpl</td><td>MONO_TABLE_INTERFACEIMPL</td><td>
Array size:
<li>MONO_INTERFACEIMPL_SIZE
<ul>
<li>MONO_INTERFACEIMPL_CLASS
<li>MONO_INTERFACEIMPL_INTERFACE
</ul>
</td>
</tr>
<td>ManifestResource</td><td>MONO_TABLE_MANIFESTRESOURCE</td><td>Array
size: MONO_MANIFESTRESOURCE_SIZE
<ul>
<li>MONO_MANIFEST_OFFSET
<li>MONO_MANIFEST_FLAGS
<li>MONO_MANIFEST_NAME
<li>MONO_MANIFEST_IMPLEMENTATION
</ul>
</td>
</tr>
<tr>
<td>MemberRef</td><td>MONO_TABLE_MEMBERREF</td><td>
Array size:
MONO_MEMBERREF_SIZE
<ul>
<li>MONO_MEMBERREF_CLASS
<li>MONO_MEMBERREF_NAME
<li>MONO_MEMBERREF_SIGNATURE
</ul>
</td>
</tr>
<td>MethodImpl</td><td>MONO_TABLE_METHODIMPL</td><td>
Array size:
MONO_METHODIMPL_SIZE
<ul>
<li>MONO_METHODIMPL_CLASS
<li>MONO_METHODIMPL_BODY
<li>MONO_METHODIMPL_DECLARATION
</ul>
</td>
</tr>
<td>MethodSpec</td><td>MONO_TABLE_METHODSPEC</td><td>
Array size:
MONO_METHODSPEC_SIZE
<ul>
<li>MONO_METHODSPEC_METHOD
<li>MONO_METHODSPEC_SIGNATURE
</ul>
</td>
</tr>
<tr>
<td>MethodSemantics</td><td>MONO_TABLE_METHODSEMANTICS</td><td>Array
size: MONO_METHOD_SEMA_SIZE
<ul>
<li>MONO_METHOD_SEMA_SEMANTICS
<li>MONO_METHOD_SEMA_METHOD
<li>MONO_METHOD_SEMA_ASSOCIATION
</ul>
</td>
</tr>
<td>Moduleref</td><td>MONO_TABLE_MODULEREF</td><td>
Array size:
MONO_MODULEREF_SIZE
<ul>
<li>MONO_MODULEREF_NAME
</ul>
</td>
</tr>
<tr>
<td>Module</td><td>MONO_TABLE_MODULE</td><td>
Array size:
MONO_MODULE_SIZE
<br>
Columns:
<ul>
<li>MONO_MODULE_GENERATION
<li>MONO_MODULE_NAME
<li>MONO_MODULE_MVID
<li>MONO_MODULE_ENC
<li>MONO_MODULE_ENCBASE
</ul>
</td>
</tr>
<td>TypeRef</td><td>MONO_TABLE_TYPEREF</td><td>
Array size:
MONO_TYPEREF_SIZE
<ul>
<li>MONO_TYPEREF_SCOPE
<li>MONO_TYPEREF_NAME
<li>MONO_TYPEREF_NAMESPACE
</ul>
</td>
</tr>
<tr>
<td>MethodPtr</td><td>MONO_TABLE_METHOD_POINTER</td><td>
Array size:
MONO_METHOD_POINTER_SIZE
<ul>
<li>MONO_METHOD_POINTER_METHOD
</ul>
</td>
</tr>
<td>Method</td><td>MONO_TABLE_METHOD</td><td>
Array size:
MONO_METHOD_SIZE
<ul>
<li>MONO_METHOD_RVA
<li>MONO_METHOD_IMPLFLAGS
<li>MONO_METHOD_FLAGS
<li>MONO_METHOD_NAME
<li>MONO_METHOD_SIGNATURE
<li>MONO_METHOD_PARAMLIST
</ul>
</td>
</tr>
<tr>
<td>NestedClass</td><td>MONO_TABLE_NESTEDCLASS</td><td>
Array size:
MONO_NESTEDCLASS_SIZE
<ul>
<li>MONO_NESTED_CLASS_NESTED
<li>MONO_NESTED_CLASS_ENCLOSING
</ul>
</td>
</tr>
<tr>
<td>ParamPtr</td><td>MONO_TABLE_PARAM_POINTER</td><td>
Array size:
MONO_PARAM_POINTER_SIZE
<ul>
<li>MONO_PARAM_POINTER_PARAM
</ul>
</td>
</tr>
<td>Param</td><td>MONO_TABLE_PARAM</td><td>
Array size: MONO_PARAM_SIZE
<ul>
<li>MONO_PARAM_FLAGS
<li>MONO_PARAM_SEQUENCE
<li>MONO_PARAM_NAME
</ul>
</td>
</tr>
<td>PropertyMap</td><td>MONO_TABLE_PROPERTYMAP</td><td>
Array size:
MONO_PROPERTY_MAP_SIZE
<ul>
<li>MONO_PROPERTY_MAP_PARENT
<li>MONO_PROPERTY_MAP_PROPERTY_LIST
</ul>
</td>
</tr>
<td>PropertyPtr</td><td>MONO_TABLE_PROPERTY_POINTER</td><td>Array
size: MONO_PROPERTY_POINTER_SIZE
<ul>
<li>MONO_PROPERTY_POINTER_PROPERTY
</ul>
</td>
</tr>
<td>Property</td><td>MONO_TABLE_PROPERTY</td><td>
Array size:
MONO_PROPERTY_SIZE
<ul>
<li>MONO_PROPERTY_FLAGS
<li>MONO_PROPERTY_NAME
<li>MONO_PROPERTY_TYPE
</ul>
</td>
</tr>
<tr>
<td>StandaloneSig</td><td>MONO_TABLE_STANDALONESIG</td><td>
Array size:
<li>MONO_STAND_ALONE_SIGNATURE_SIZE
<ul>
<li>MONO_STAND_ALONE_SIGNATURE
</ul>
</td>
</tr>
<tr>
<td>TypeDef</td><td>MONO_TABLE_TYPEDEF</td><td>
Array size:
MONO_TYPEDEF_SIZE
<ul>
<li>MONO_TYPEDEF_FLAGS
<li>MONO_TYPEDEF_NAME
<li>MONO_TYPEDEF_NAMESPACE
<li>MONO_TYPEDEF_EXTENDS
<li>MONO_TYPEDEF_FIELD_LIST
<li>MONO_TYPEDEF_METHOD_LIST
</ul>
</td>
</tr>
<tr>
<td>TypeSpec</td><td>MONO_TABLE_TYPESPEC</td><td>
Array size:
MONO_TYPESPEC_SIZE
<ul>
<li>MONO_TYPESPEC_SIGNATURE
</ul>
</td>
</tr>
</table>
</center>
<p>Each table can contain zero or more rows, you must call the
<a href="#api:mono_metadata_table_rows">mono_metadata_table_rows</a>
to obtain the number of rows in a table, and then you can
extract individual row values by using
the <a href="#api:mono_metadata_decode_row">mono_metadata_decode_row</a>
or
the <a href="#api:mono_metadata_decode_row_col">mono_metadata_decode_row_col</a>.
When decoding rows you must provide an guint32 array large
enough to hold as many columns as the table contains.
<p>The metadata tables are stored in the MonoImage, you obtain
a pointer to the MonoTableInfo by calling
the <a href="#api:mono_image_get_table_info">mono_image_get_table_info</a>
and then you can scan those tables, for example:
<pre class="prettyprint">
/*
* Dumps a few fields from the AssemblyRef table
*/
void DumpAssemblyRefs (MonoImage *image)
{
/* Get a pointer to the AssemblyRef metadata table */
MonoTableInfo *t = mono_image_get_table_info (image, MONO_TABLE_ASSEMBLYREF);
/* Fetch the number of rows available in the table */
int rows = mono_table_info_get_rows (t);
int i;
/* For each row, print some of its values */
for (i = 0; i &lt; rows; i++){
/* Space where we extract one row from the metadata table */
guint32 cols [MONO_ASSEMBLYREF_SIZE];
/* Extract the row into the array cols */
mono_metadata_decode_row (t, i, cols, MONO_ASSEMBLYREF_SIZE);
fprintf (output, "%d: Version=%d.%d.%d.%d\n\tName=%s\n", i + 1,
cols [MONO_ASSEMBLYREF_MAJOR_VERSION],
cols [MONO_ASSEMBLYREF_MINOR_VERSION],
cols [MONO_ASSEMBLYREF_BUILD_NUMBER],
cols [MONO_ASSEMBLYREF_REV_NUMBER],
mono_metadata_string_heap (image, cols [MONO_ASSEMBLYREF_NAME]));
}
}
</pre>
<p>The above program shows the following output when ran on
the C# compiler:
<pre>
1: Version=1.0.5000.0
Name=mscorlib
2: Version=1.0.5000.0
Name=System
3: Version=1.0.5000.0
Name=System.Xml
</pre>
<p>
<h3>Metadata Tables API</h3>
<p>These are the APIs for dealing with tables:
<h4><a name="api:mono_image_get_table_info">mono_image_get_table_info</a></h4>
<h4><a name="api:mono_image_get_table_rows">mono_image_get_table_rows</a></h4>
<h4><a name="api:mono_metadata_get_table">mono_metadata_get_table</a></h4>
<h4><a name="api:mono_meta_table_name">mono_meta_table_name</a></h4>
<h4><a name="api:mono_metadata_decode_row_col">mono_metadata_decode_row_col</a></h4>
<h4><a name="api:mono_metadata_decode_row">mono_metadata_decode_row</a></h4>
<h4><a name="api:mono_metadata_compute_size">mono_metadata_compute_size</a></h4>
<h4><a name="api:mono_metadata_custom_attrs_from_index">mono_metadata_custom_attrs_from_index</a></h4>
<h4><a name="api:mono_metadata_decode_signed_value">mono_metadata_decode_signed_value</a></h4>
<h4><a name="api:mono_metadata_decode_value">mono_metadata_decode_value</a></h4>
<h4><a name="api:mono_metadata_encode_value">mono_metadata_encode_value</a></h4>
<h2>Metadata access API</h2>
<h3>Metadata access API</h3>
<p>This is the low-level API for accessing the metadata
images.
<h4><a name="api:mono_cli_rva_image_map">mono_cli_rva_image_map</a></h4>
<h4><a name="api:mono_pe_file_open">mono_pe_file_open</a></h4>
<h4><a name="api:mono_meta_table_name">mono_meta_table_name</a></h4>
<h4><a name="api:mono_metadata_blob_heap">mono_metadata_blob_heap</a></h4>
<h4><a name="api:mono_metadata_compute_size">mono_metadata_compute_size</a></h4>
<h4><a name="api:mono_metadata_custom_attrs_from_index">mono_metadata_custom_attrs_from_index</a></h4>
<h4><a name="api:mono_metadata_decode_blob_size">mono_metadata_decode_blob_size</a></h4>
<h4><a name="api:mono_metadata_decode_row_col">mono_metadata_decode_row_col</a></h4>
<h4><a name="api:mono_metadata_decode_row">mono_metadata_decode_row</a></h4>
<h4><a name="api:mono_metadata_decode_signed_value">mono_metadata_decode_signed_value</a></h4>
<h4><a name="api:mono_metadata_decode_value">mono_metadata_decode_value</a></h4>
<h4><a name="api:mono_metadata_encode_value">mono_metadata_encode_value</a></h4>
<h4><a name="api:mono_metadata_events_from_typedef">mono_metadata_events_from_typedef</a></h4>
<h4><a name="api:mono_metadata_field_info">mono_metadata_field_info</a></h4>
<h4><a name="api:mono_metadata_free_array">mono_metadata_free_array</a></h4>
<h4><a name="api:mono_metadata_free_marshal_spec">mono_metadata_free_marshal_spec</a></h4>
<h4><a name="api:mono_metadata_free_mh">mono_metadata_free_mh</a></h4>
<h4><a name="api:mono_metadata_free_type">mono_metadata_free_type</a></h4>
<h4><a name="api:mono_metadata_generic_inst_equal">mono_metadata_generic_inst_equal</a></h4>
<h4><a name="api:mono_metadata_generic_inst_hash">mono_metadata_generic_inst_hash</a></h4>
<h4><a name="api:mono_metadata_generic_inst_is_valuetype">mono_metadata_generic_inst_is_valuetype</a></h4>
<h4><a name="api:mono_metadata_generic_method_equal">mono_metadata_generic_method_equal</a></h4>
<h4><a name="api:mono_metadata_get_constant_index">mono_metadata_get_constant_index</a></h4>
<h4><a name="api:mono_metadata_get_marshal_info">mono_metadata_get_marshal_info</a></h4>
<h4><a name="api:mono_metadata_get_table">mono_metadata_get_table</a></h4>
<h4><a name="api:mono_metadata_guid_heap">mono_metadata_guid_heap</a></h4>
<h4><a name="api:mono_metadata_implmap_from_method">mono_metadata_implmap_from_method</a></h4>
<h4><a name="api:mono_metadata_interfaces_from_typedef_full">mono_metadata_interfaces_from_typedef_full</a></h4>
<h4><a name="api:mono_metadata_interfaces_from_typedef">mono_metadata_interfaces_from_typedef</a></h4>
<h4><a name="api:mono_metadata_load_generic_params">mono_metadata_load_generic_params</a></h4>
<h4><a name="api:mono_metadata_locate">mono_metadata_locate</a></h4>
<h4><a name="api:mono_metadata_locate_token">mono_metadata_locate_token</a></h4>
<h4><a name="api:mono_metadata_methods_from_event">mono_metadata_methods_from_event</a></h4>
@@ -652,17 +49,8 @@ MONO_TYPESPEC_SIZE
<h4><a name="api:mono_metadata_nested_in_typedef">mono_metadata_nested_in_typedef</a></h4>
<h4><a name="api:mono_metadata_nesting_typedef">mono_metadata_nesting_typedef</a></h4>
<h4><a name="api:mono_metadata_packing_from_typedef">mono_metadata_packing_from_typedef</a></h4>
<h4><a name="api:mono_metadata_properties_from_typedef">mono_metadata_properties_from_typedef</a></h4>
<h4><a name="api:mono_metadata_token_from_dor">mono_metadata_token_from_dor</a></h4>
<h4><a name="api:mono_metadata_typedef_from_field">mono_metadata_typedef_from_field</a></h4>
<h4><a name="api:mono_metadata_typedef_from_method">mono_metadata_typedef_from_method</a></h4>
<h4><a name="api:mono_metadata_type_equal">mono_metadata_type_equal</a></h4>
<h4><a name="api:mono_metadata_type_hash">mono_metadata_type_hash</a></h4>
<h4><a name="api:mono_metadata_declsec_from_index">mono_metadata_declsec_from_index</a></h4>
<h4><a name="api:mono_metadata_free_method_signature">mono_metadata_free_method_signature</a></h4>
<h3>Retrieving Objects from Tokens</h3>
<h4><a name="api:mono_metadata_parse_array_full">mono_metadata_parse_array_full</a></h4>
<h4><a name="api:mono_metadata_parse_array">mono_metadata_parse_array</a></h4>
<h4><a name="api:mono_metadata_parse_custom_mod">mono_metadata_parse_custom_mod</a></h4>
<h4><a name="api:mono_metadata_parse_field_type">mono_metadata_parse_field_type</a></h4>
<h4><a name="api:mono_metadata_parse_marshal_spec">mono_metadata_parse_marshal_spec</a></h4>
@@ -676,29 +64,25 @@ MONO_TYPESPEC_SIZE
<h4><a name="api:mono_metadata_parse_typedef_or_ref">mono_metadata_parse_typedef_or_ref</a></h4>
<h4><a name="api:mono_metadata_parse_type_full">mono_metadata_parse_type_full</a></h4>
<h4><a name="api:mono_metadata_parse_type">mono_metadata_parse_type</a></h4>
<h4><a name="api:mono_metadata_properties_from_typedef">mono_metadata_properties_from_typedef</a></h4>
<h4><a name="api:mono_metadata_string_heap">mono_metadata_string_heap</a></h4>
<h4><a name="api:mono_metadata_token_from_dor">mono_metadata_token_from_dor</a></h4>
<h4><a name="api:mono_metadata_typedef_from_field">mono_metadata_typedef_from_field</a></h4>
<h4><a name="api:mono_metadata_typedef_from_method">mono_metadata_typedef_from_method</a></h4>
<h4><a name="api:mono_metadata_type_equal">mono_metadata_type_equal</a></h4>
<h4><a name="api:mono_metadata_type_hash">mono_metadata_type_hash</a></h4>
<h4><a name="api:mono_metadata_user_string">mono_metadata_user_string</a></h4>
<h4><a name="api:mono_metadata_declsec_from_index">mono_metadata_declsec_from_index</a></h4>
<h4><a name="api:mono_metadata_free_method_signature">mono_metadata_free_method_signature</a></h4>
<h2>Metadata Loader Locking</h2>
<p>The locking functions here are used by code in class.c and
metadata.c to lock access to the shared hashtables inside the
MonoImage.
<h4><a name="api:mono_loader_lock">mono_loader_lock</a></h4>
<h4><a name="api:mono_loader_unlock">mono_loader_unlock</a></h4>
<h2>Generics Support</h2>
<h3>Generics Support</h3>
<h4><a name="api:mono_metadata_generic_class_is_valuetype">mono_metadata_generic_class_is_valuetype</a></h4>
<h4><a name="api:mono_metadata_has_generic_params">mono_metadata_has_generic_params</a></h4>
<h4><a name="api:mono_metadata_inflate_generic_inst">mono_metadata_inflate_generic_inst</a></h4>
<h4><a name="api:mono_metadata_parse_generic_inst">mono_metadata_parse_generic_inst</a></h4>
<h4><a name="api:mono_metadata_generic_inst_equal">mono_metadata_generic_inst_equal</a></h4>
<h4><a name="api:mono_metadata_generic_inst_hash">mono_metadata_generic_inst_hash</a></h4>
<h4><a name="api:mono_metadata_load_generic_params">mono_metadata_load_generic_params</a></h4>
<h4><a name="api:mono_metadata_generic_inst_is_valuetype">mono_metadata_generic_inst_is_valuetype</a></h4>
<h4><a name="api:mono_metadata_generic_method_equal">mono_metadata_generic_method_equal</a></h4>
<h2>Tokens</h2>
<h3>Tokens</h3>
<h4><a name="api:mono_ldtoken">mono_ldtoken</a></h4>
<h4><a name="api:mono_lookup_dynamic_token">mono_lookup_dynamic_token</a></h4>
@@ -706,12 +90,25 @@ MONO_TYPESPEC_SIZE
<h4><a name="api:mono_exception_from_token">mono_exception_from_token</a></h4>
<h4><a name="api:mono_create_jit_trampoline_from_token">mono_create_jit_trampoline_from_token</a></h4>
<h2>OpCodes</h2>
<h3>Working with signatures</h3>
<h4><a name="api:mono_signature_explicit_this">mono_signature_explicit_this</a></h4>
<h4><a name="api:mono_signature_get_call_conv">mono_signature_get_call_conv</a></h4>
<h4><a name="api:mono_signature_get_desc">mono_signature_get_desc</a></h4>
<h4><a name="api:mono_signature_get_param_count">mono_signature_get_param_count</a></h4>
<h4><a name="api:mono_signature_get_params">mono_signature_get_params</a></h4>
<h4><a name="api:mono_signature_get_return_type">mono_signature_get_return_type</a></h4>
<h4><a name="api:mono_signature_hash">mono_signature_hash</a></h4>
<h4><a name="api:mono_signature_is_instance">mono_signature_is_instance</a></h4>
<h4><a name="api:mono_signature_vararg_start">mono_signature_vararg_start</a></h4>
<h3>OpCodes</h3>
<h4><a name="api:mono_opcode_name">mono_opcode_name</a></h4>
<h4><a name="api:mono_opcode_value">mono_opcode_value</a></h4>
<h2>Metadata Loading Errors</h2>
<h3>Metadata Loading Errors</h3>
<p>The routines in this section are used to cope with errors
during metadata loading. Errors in metadata handling can
+1 -13
View File
@@ -54,20 +54,8 @@ mono_runtime_invoke (method, obj, args, &amp;exception);
<h4><a name="api:mono_method_has_marshal_info">mono_method_has_marshal_info</a></h4>
<h4><a name="api:mono_method_return_message_restore">mono_method_return_message_restore</a></h4>
<h4><a name="api:mono_method_same_domain">mono_method_same_domain</a></h4>
<h4><a name="api:mono_method_verify">mono_method_verify</a></h4>
<h3>Method Signatures</h3>
<h4><a name="api:mono_method_signature">mono_method_signature</a></h4>
<h4><a name="api:mono_signature_explicit_this">mono_signature_explicit_this</a></h4>
<h4><a name="api:mono_signature_get_call_conv">mono_signature_get_call_conv</a></h4>
<h4><a name="api:mono_signature_get_desc">mono_signature_get_desc</a></h4>
<h4><a name="api:mono_signature_get_param_count">mono_signature_get_param_count</a></h4>
<h4><a name="api:mono_signature_get_params">mono_signature_get_params</a></h4>
<h4><a name="api:mono_signature_get_return_type">mono_signature_get_return_type</a></h4>
<h4><a name="api:mono_signature_hash">mono_signature_hash</a></h4>
<h4><a name="api:mono_signature_is_instance">mono_signature_is_instance</a></h4>
<h4><a name="api:mono_signature_vararg_start">mono_signature_vararg_start</a></h4>
<h4><a name="api:mono_method_verify">mono_method_verify</a></h4>
<h3>Methods Header Operations</h3>
+113
View File
@@ -0,0 +1,113 @@
1. Thread safety of metadata structures
----------------------------------------
1.1 Synchronization of read-only data
-------------------------------------
Read-only data is data which is not modified after creation, like the
actual binary metadata in the metadata tables.
There are three kinds of threads with regards to read-only data:
- readers
- the creator of the data
- the destroyer of the data
Most threads are readers.
- synchronization between readers is not neccesary
- synchronization between the writers is done using locks.
- synchronization between the readers and the creator is done by not exposing
the data to readers before it is fully constructed.
- synchronization between the readers and the destroyer: TBD.
1.2 Deadlock prevention plan
----------------------------
Hold locks for the shortest time possible. Avoid calling functions inside
locks which might obtain global locks (i.e. locks known outside this module).
1.3 Locks
----------
1.3.1 Simple locks
------------------
There are a lot of global data structures which can be protected by a 'simple' lock. Simple means:
- the lock protects only this data structure or it only protects the data structures in a given C module.
An example would be the appdomains list in domain.c
- the lock is only held for a short amount of time, and no other lock is acquired inside this simple lock. Thus there is
no possibility of deadlock.
1.3.2 The class loader lock
---------------------------
This locks is held by the class loading routines in class.c and loader.c. It
protects the various caches inside MonoImage which are used by these modules.
1.3.3 The domain lock
---------------------
Each appdomain has a lock which protects the per-domain data structures.
1.3.4 The locking hierarchy
---------------------------
It is useful to model locks by a locking hierarchy, which is a relation between locks, which is reflexive, transitive,
and antisymmetric, in other words, a lattice. If a thread wants to acquire a lock B, while already holding A, it can only
do it if A < B. If all threads work this way, then no deadlocks can occur.
Our locking hierarchy so far looks like this:
<DOMAIN LOCK>
\
<CLASS LOADER LOCK>
\ \
<SIMPLE LOCK 1> <SIMPLE LOCK 2>
1.4 Notes
----------
Some common scenarios:
- if a function needs to access a data structure, then it should lock it itself, and do not count on its caller locking it.
So for example, the image->class_cache hash table would be locked by mono_class_get().
- there are lots of places where a runtime data structure is created and stored in a cache. In these places, care must be
taken to avoid multiple threads creating the same runtime structure, for example, two threads might call mono_class_get ()
with the same class name. There are two choices here:
<enter mutex>
<check that item is created>
if (created) {
<leave mutex>
return item
}
<create item>
<store it in cache>
<leave mutex>
This is the easiest solution, but it requires holding the lock for the whole time which might create a scalability problem, and could also lead to deadlock.
<enter mutex>
<check that item is created>
<leave mutex>
if (created) {
return item
}
<create item>
<enter mutex>
<check that item is created>
if (created) {
/* Another thread already created and stored the same item */
<free our item>
<leave mutex>
return orig item
}
else {
<store item in cache>
<leave mutex>
return item
}
This solution does not present scalability problems, but the created item might be hard to destroy (like a MonoClass).
- lazy initialization of hashtables etc. is not thread safe
File renamed without changes.
-35
View File
@@ -1,38 +1,3 @@
2009-02-05 Miguel de Icaza <[email protected]>
* src/gstr.c: Add g_strnfill
* src/glib.h: Add g_list_previous
2009-01-19 Bill Holmes <[email protected]>
* gmisc-win32.c (g_path_is_absolute): Adding support for UNC
paths on Windows.
Contributed under MIT/X11 license.
2009-01-08 Bill Holmes <[email protected]>
* winconfig.h, src/gfile-posix.c :
Fixing the MSVC builds.
Contributed under MIT/X11 license.
2009-01-07 Miguel de Icaza <[email protected]>
* src/gfile-posix.c: Move g_get_current_dir, as it is a
POSIX-esque feature, and some other systems do not have current
directories.
* src/glib.h (G_LOCK_DEFINE, G_LOCK_DEFINE_STATIC):
Embedded support from Paolo's work on quack.
* configure.ac: check for strtok_r, langinfo.h and iconv.h
* src/gpath.c (strtok_r): Add a strtok_r implementation if it is
not available on the target system.
2008-11-05 Bill Holmes <[email protected]>
* src/gutf8.c, src/unicode-data.h, src/gunicode.c :
+3 -3
View File
@@ -2,7 +2,7 @@ AC_INIT(README)
AC_CANONICAL_SYSTEM
AM_CONFIG_HEADER(config.h)
AM_INIT_AUTOMAKE(eglib,0.3)
AM_INIT_AUTOMAKE(eglib,0.2)
AM_MAINTAINER_MODE
AC_PROG_CC
@@ -55,7 +55,7 @@ AM_CONDITIONAL(PLATFORM_WIN32, test x$OS = xWIN32)
AC_CHECK_SIZEOF(int)
AC_CHECK_SIZEOF(void *)
AC_CHECK_FUNCS(strndup strlcpy getpwent_r strtok_r)
AC_CHECK_FUNCS(strndup strlcpy getpwent_r)
AC_CHECK_LIB(iconv, libiconv_open, LIBS="$LIBS -liconv")
old_ldflags="${LDFLAGS}"
LDFLAGS="${LDFLAGS} -Wl,-export-dynamic"
@@ -64,7 +64,7 @@ if test $found_export_dynamic = no; then
LDFLAGS="${old_ldflags}"
fi
AC_CHECK_HEADERS(getopt.h sys/time.h sys/wait.h pwd.h langinfo.h iconv.h)
AC_CHECK_HEADERS(getopt.h sys/time.h sys/wait.h pwd.h)
if test $ac_cv_sizeof_void_p != $ac_cv_sizeof_int; then
GPOINTER_TO_INT="((gint)(long) (ptr))"
-1
View File
@@ -39,7 +39,6 @@ libeglib_la_SOURCES = \
gmarkup.c \
gutf8.c \
gunicode.c \
unicode-data.h \
$(os_files)
libeglib_la_CFLAGS = -Wall -D_FORTIFY_SOURCE=2
-21
View File
@@ -35,7 +35,6 @@
#include <sys/types.h>
#ifdef _MSC_VER
#include <direct.h>
int mkstemp (char *tmp_template);
#endif
@@ -145,23 +144,3 @@ g_file_open_tmp (const gchar *tmpl, gchar **name_used, GError **error)
}
return fd;
}
gchar *
g_get_current_dir (void)
{
int s = 32;
char *buffer = NULL, *r;
gboolean fail;
do {
buffer = g_realloc (buffer, s);
r = getcwd (buffer, s);
fail = (r == NULL && errno == ERANGE);
if (fail) {
s <<= 1;
}
} while (fail);
return r;
}
+2 -6
View File
@@ -234,7 +234,6 @@ gchar *g_strjoinv (const gchar *separator, gchar **str_array);
gchar *g_strchug (gchar *str);
gchar *g_strchomp (gchar *str);
void g_strdown (gchar *string);
gchar *g_strnfill (gsize length, gchar fill_char);
gchar *g_strdelimit (gchar *string, const gchar *delimiters, gchar new_delimiter);
gchar *g_strescape (const gchar *source, const gchar *exceptions);
@@ -367,7 +366,6 @@ struct _GList {
};
#define g_list_next(list) ((list) ? (((GList *) (list))->next) : NULL)
#define g_list_previous(list) ((list) ? (((GList *) (list))->prev) : NULL)
GList *g_list_alloc (void);
GList *g_list_append (GList *list,
@@ -834,15 +832,13 @@ glong g_utf8_strlen (const gchar *str, gssize max);
#define g_thread_supported() TRUE
#define g_thread_init(x) G_STMT_START { if (x != NULL) { g_error ("No vtable supported in g_thread_init"); } } G_STMT_END
#define G_LOCK_DEFINE(name) int name;
#define G_LOCK_DEFINE_STATIC(name) static int name;
#define G_LOCK_DEFINE(name)
#define G_LOCK_DEFINE_STATIC(name)
#define G_LOCK_EXTERN(name)
#define G_LOCK(name)
#define G_TRYLOCK(name)
#define G_UNLOCK(name)
#define GUINT16_SWAP_LE_BE_CONSTANT(x) ((((guint16) x) >> 8) | ((((guint16) x) << 8)))
#define GUINT16_SWAP_LE_BE(x) ((guint16) (((guint16) x) >> 8) | ((((guint16)(x)) & 0xff) << 8))
#define GUINT32_SWAP_LE_BE(x) ((guint32) \
( (((guint32) (x)) << 24)| \
+6 -34
View File
@@ -40,7 +40,6 @@
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
#include <stdio.h>
#include <ctype.h>
#include <glib.h>
#define set_error(msg, ...) do { if (error != NULL) *error = g_error_new (GINT_TO_POINTER (1), 1, msg, __VA_ARGS__); } while (0);
@@ -100,37 +99,10 @@ g_markup_parse_context_free (GMarkupParseContext *context)
g_free (context);
}
static gboolean
my_isspace (char c)
{
if (c == ' ' || c == '\t' || c == '\r' || c == '\n' || c == '\v')
return TRUE;
return FALSE;
}
static gboolean
my_isalnum (char c)
{
if ((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z'))
return TRUE;
if (c >= '0' && c <= '9')
return TRUE;
return FALSE;
}
static gboolean
my_isalpha (char c)
{
if ((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z'))
return TRUE;
return FALSE;
}
static const char *
skip_space (const char *p, const char *end)
{
for (; p < end && my_isspace (*p); p++)
for (; p < end && isspace (*p); p++)
;
return p;
}
@@ -166,7 +138,7 @@ parse_name (const char *p, const char *end, char **value)
const char *start = p;
int l;
for (; p < end && my_isalnum (*p); p++)
for (; p < end && isalnum (*p); p++)
;
if (p == end)
return end;
@@ -296,7 +268,7 @@ g_markup_parse_context_parse (GMarkupParseContext *context,
int full_stop = 0, l;
gchar **names = NULL, **values = NULL;
for (; p < end && my_isspace (*p); p++)
for (; p < end && isspace (*p); p++)
;
if (p == end){
set_error ("%s", "Unfinished element");
@@ -309,12 +281,12 @@ g_markup_parse_context_parse (GMarkupParseContext *context,
break;
}
if (!my_isalpha (*p)){
if (!(isascii (*p) && isalpha (*p))){
set_error ("%s", "Expected an element name");
goto fail;
}
for (++p; p < end && (my_isalnum (*p) || (*p == '.')); p++)
for (++p; p < end && (isalnum (*p) || (*p == '.')); p++)
;
if (p == end){
set_error ("%s", "Expected an element");
@@ -322,7 +294,7 @@ g_markup_parse_context_parse (GMarkupParseContext *context,
}
element_end = p;
for (; p < end && my_isspace (*p); p++)
for (; p < end && isspace (*p); p++)
;
if (p == end){
set_error ("%s", "Unfinished element");
+5 -10
View File
@@ -93,16 +93,11 @@ g_path_is_absolute (const char *filename)
{
g_return_val_if_fail (filename != NULL, FALSE);
if (filename[0] != '\0' && filename[1] != '\0')
if (filename[1] == ':' && filename[2] != '\0' &&
(filename[2] == '\\' || filename[2] == '/'))
return TRUE;
/* UNC paths */
else if (filename[0] == '\\' && filename[1] == '\\' &&
filename[2] != '\0')
return TRUE;
return FALSE;
if (filename[0] != '\0' && filename[1] != '\0' && filename[1] == ':' &&
filename[2] != '\0' && (filename[2] == '\\' || filename[2] == '/'))
return TRUE;
else
return FALSE;
}
const gchar *
+21 -59
View File
@@ -47,9 +47,7 @@ g_build_path (const gchar *separator, const gchar *first_element, ...)
va_list args;
g_return_val_if_fail (separator != NULL, NULL);
if (first_element == NULL)
return g_strdup ("");
g_return_val_if_fail (first_element != NULL, NULL);
result = g_string_sized_new (48);
@@ -68,8 +66,7 @@ g_build_path (const gchar *separator, const gchar *first_element, ...)
g_string_append_len (result, s, p - s);
if (next && *next){
if (strncmp (separator, result->str + strlen (result->str) - slen, slen))
g_string_append (result, separator);
g_string_append (result, separator);
for (; strncmp (next, separator, slen) == 0; )
next += slen;
@@ -134,60 +131,6 @@ g_path_get_basename (const char *filename)
return g_strdup (&r[1]);
}
#ifndef HAVE_STRTOK_R
// This is from BSD's strtok_r
char *
strtok_r(char *s, const char *delim, char **last)
{
char *spanp;
int c, sc;
char *tok;
if (s == NULL && (s = *last) == NULL)
return NULL;
/*
* Skip (span) leading delimiters (s += strspn(s, delim), sort of).
*/
cont:
c = *s++;
for (spanp = (char *)delim; (sc = *spanp++) != 0; ){
if (c == sc)
goto cont;
}
if (c == 0){ /* no non-delimiter characters */
*last = NULL;
return NULL;
}
tok = s - 1;
/*
* Scan token (scan for delimiters: s += strcspn(s, delim), sort of).
* Note that delim must have one NUL; we stop if we see that, too.
*/
for (;;){
c = *s++;
spanp = (char *)delim;
do {
if ((sc = *spanp++) == c) {
if (c == 0)
s = NULL;
else {
char *w = s - 1;
*w = '\0';
}
*last = s;
return tok;
}
}
while (sc != 0);
}
/* NOTREACHED */
}
#endif
gchar *
g_find_program_in_path (const gchar *program)
{
@@ -220,6 +163,25 @@ g_find_program_in_path (const gchar *program)
return NULL;
}
gchar *
g_get_current_dir (void)
{
int s = 32;
char *buffer = NULL, *r;
gboolean fail;
do {
buffer = g_realloc (buffer, s);
r = getcwd (buffer, s);
fail = (r == NULL && errno == ERANGE);
if (fail) {
s <<= 1;
}
} while (fail);
return r;
}
static char *name;
void
+2 -11
View File
@@ -826,15 +826,6 @@ g_ascii_xdigit_value (gchar c)
(c - 'A' + 10))));
}
gchar *
g_strnfill (gsize length, gchar fill_char)
{
gchar *ret = g_new (gchar, length + 1);
int i;
for (i = 0; i < length; i++)
ret [i] = fill_char;
ret [length] = 0;
return ret;
}
+1 -10
View File
@@ -33,7 +33,6 @@
* WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
*/
#include <config.h>
#include <stdio.h>
#include <glib.h>
#include <unicode-data.h>
@@ -45,13 +44,9 @@
typedef int iconv_t;
#else
#ifdef HAVE_LANGINFO_H
#include <langinfo.h>
#endif
#ifdef HAVE_ICONV_H
#include <iconv.h>
#endif
#endif
static char *my_charset;
static gboolean is_utf8;
@@ -205,7 +200,7 @@ g_convert (const gchar *str, gssize len,
{
char *result = NULL;
#ifdef G_OS_WIN32
#elif HAVE_ICONV_H
#else
iconv_t convertor;
char *buffer, *output;
const char *strptr = (const char *) str;
@@ -300,11 +295,7 @@ g_get_charset (G_CONST_RETURN char **charset)
is_utf8 = FALSE;
#else
if (my_charset == NULL){
#if HAVE_LANGINFO_H
my_charset = g_strdup (nl_langinfo (CODESET));
#else
my_charset = g_strdup ("UTF-8");
#endif
is_utf8 = strcmp (my_charset, "UTF-8") == 0;
}
+1 -1
View File
@@ -238,7 +238,7 @@ gint main(gint argc, gchar **argv)
string_array_free(tests_to_run);
}
return global_tests - global_passed;
return 0;
}
+2 -23
View File
@@ -92,14 +92,7 @@ test_buildpath ()
if (strcmp (s, "/a/c/") != 0)
return FAILED ("14 Got wrong result, got: %s", s);
g_free (s);
/* Null */
s = g_build_path ("/", NULL);
if (s == NULL)
return FAILED ("must get a non-NULL return");
if (s [0] != 0)
return FAILED ("must get an empty string");
g_free (s);
return OK;
}
@@ -116,20 +109,6 @@ test_buildfname ()
#endif
return FAILED ("1 Got wrong result, got: %s", s);
g_free (s);
s = g_build_filename ("/", "a", NULL);
#ifdef G_OS_WIN32
if (strcmp (s, "\\a") != 0)
#else
if (strcmp (s, "/a") != 0)
#endif
return FAILED ("1 Got wrong result, got: %s", s);
#ifndef OS_WIN32
s = g_build_filename ("/", "foo", "/bar", "tolo/", "/meo/", NULL);
if (strcmp (s, "/foo/bar/tolo/meo/") != 0)
return FAILED ("1 Got wrong result, got: %s", s);
#endif
return OK;
}
@@ -305,8 +284,8 @@ test_misc ()
}
static Test path_tests [] = {
{"g_build_filename", test_buildfname},
{"g_buildpath", test_buildpath},
{"g_build_filename", test_buildfname},
{"g_path_get_dirname", test_dirname},
{"g_path_get_basename", test_basename},
{"g_find_program_in_path", test_ppath},
-2
View File
@@ -72,5 +72,3 @@
/* Version number of package */
#define VERSION "0.1"
#define HAVE_STRTOK_R 1
+1 -1
View File
@@ -28,7 +28,7 @@
#include <malloc.h>
#define ALLOCA _alloca
#else
#if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__)
#if defined(__FreeBSD__) || defined(__NetBSD__)
#include <stdlib.h>
#else
#include <alloca.h>
-11
View File
@@ -1,14 +1,3 @@
2009-01-18 Zoltan Varga <[email protected]>
* include/private/gcconfig.h: Applied patch from Koushik Dutta
([email protected]). Define SEARCH_FOR_DATA_START for android.
2008-11-18 Mark Probst <[email protected]>
* include/private/gc_locks.h (test_and_set): The PPC64 case is
wrong, as it operates on 64 bit values, not on 32 bit ones as the
function requires. The PPC32 case is sufficient.
2008-09-29 Geoff Norton <[email protected]>
* include/private/gcconfig.h: Make Darwin/ARM use mmap() instead of
+20
View File
@@ -155,6 +155,25 @@
# define GC_TEST_AND_SET_DEFINED
# endif
# if defined(POWERPC)
# if CPP_WORDSZ == 64
inline static int GC_test_and_set(volatile unsigned int *addr) {
unsigned long oldval;
unsigned long temp = 1; /* locked value */
__asm__ __volatile__(
"1:\tldarx %0,0,%3\n" /* load and reserve */
"\tcmpdi %0, 0\n" /* if load is */
"\tbne 2f\n" /* non-zero, return already set */
"\tstdcx. %2,0,%1\n" /* else store conditional */
"\tbne- 1b\n" /* retry if lost reservation */
"\tsync\n" /* import barrier */
"2:\t\n" /* oldval is zero if we set */
: "=&r"(oldval), "=p"(addr)
: "r"(temp), "1"(addr)
: "cr0","memory");
return (int)oldval;
}
# else
inline static int GC_test_and_set(volatile unsigned int *addr) {
int oldval;
int temp = 1; /* locked value */
@@ -172,6 +191,7 @@
: "cr0","memory");
return oldval;
}
# endif
# define GC_TEST_AND_SET_DEFINED
inline static void GC_clear(volatile unsigned int *addr) {
__asm__ __volatile__("lwsync" : : : "memory");
-2
View File
@@ -1868,8 +1868,6 @@
# include <features.h>
# if defined(__GLIBC__) && __GLIBC__ >= 2
# define SEARCH_FOR_DATA_START
# elif defined(PLATFORM_ANDROID)
# define SEARCH_FOR_DATA_START
# else
extern char **__environ;
# define DATASTART ((ptr_t)(&__environ))
+4 -6
View File
@@ -1,17 +1,15 @@
2008-12-31 Massimiliano Mantione <[email protected]>
* mono.1: Updated the profiler documentation, removing the "ts"
option (it does not exist anymore) and explaining the defaults for
allocation and heap profiling.
* mono.1: Merged the profiler documentation from trunk (r122288),
removing the "ts" option (it does not exist anymore) and explaining
the defaults for allocation and heap profiling.
2008-12-12 Rolf Bjarne Kvinge <[email protected]>
* Makefile.am, vbnc.1: Remove vbnc.1. It's living in the
mono-basic module now.
2008-11-20 Rodrigo Kumpera <[email protected]>
* mono.1: Document env vars MONO_XDEBUG and MONO_VERBOSE_METHOD.
[Backport of r121406.]
2008-10-18 Jonathan Pryor <[email protected]>
-124
View File
@@ -51,121 +51,6 @@ are no \fI//AssemblyVersion\fR elements for a given \fI<Type>\fR or
\fI<Member/>\fR, then the \fI<Type>\fR will be renamed and/or the
\fI<Member/>\fR will be removed.
.TP
\fB\-\-exceptions\fR[=\fISOURCES\fR]
EXPERIMENTAL. This is not 100% reliable, but is intended to serve as an aid
for documentation writers.
.Sp
Inspect member bodies to determine what exceptions can be generated from the
member.
.Sp
\fISOURCES\fR is an optional comma-separated list of the following sources
that should be searched for exceptions:
.Sp
.nf
all Find exceptions created in the member itself,
references to members in the same assembly,
and references to members in dependent
assemblies.
asm Find exceptions created in the member itself and
references to members within the same assembly
as the member.
depasm Find exceptions created in the member itself and
references to members within dependent
assemblies.
.fi
.Sp
If \fISOURCES\fR isn't provided (the default), then only exceptions created
within the member itself will be documented.
.Sp
LIMITATIONS: Exception searching is currently implemented by looking for the
exception types that are explicitly created based on the known compile-time
types. This has the following limitations:
.RS
.ne 8
.TP
.B *
This will not find exceptions which are implicit to the IL, such as
NullReferenceException and IndexOutOfRangeException.
.TP
.B *
This will find exceptions which are \fInot\fR thrown, e.g.
.nf
public void CreateAnException ()
{
Exception e = new Exception ();
}
.fi
.TP
.B *
This will not "follow" delegate and interface calls:
.nf
public void UsesDelegates ()
{
Func<int, int> a = x => {throw new Exception ();};
a (4);
}
.fi
The function \fIUsesDelegates()\fR won't have any exceptions documented.
.TP
.B *
This will find exceptions which "cannot happen", such as
ArgumentNullExceptions for arguments which are "known" to be non-null:
.nf
public void A ()
{
B ("this parameter isn't null");
}
public void B (string s)
{
if (s == null)
throw new ArgumentNullException ("s");
}
.fi
For the above, if \fB--exceptions=asm\fR is provided then \fIA()\fR will be
documented as throwing an ArgumentNullException, which cannot happen.
.ne
.RE
.TP
\fB\-f\fR=\fIFLAG\fR
Specify a flag to alter behavior. Valid flags include:
.RS
.ne 8
.TP
.B no-assembly-versions
See the \fB-fno-assembly-versions\fR documentation, below.
.ne
.RE
.TP
\fB\-fno-assembly-versions\fR
Do not generate \fI/Type/AssemblyInfo/AssemblyVersion\fR and
\fI/Type/Members/Member/AssemblyInfo\fR elements.
.Sp
This is useful to prevent "churn" during updates. Normally, if a type or
member hasn't changed but the assembly version has changed, then all types and
members will be updated to include a new \fI//AssemblyVersion\fR element, thus
increasing the amount of changes that need review before committing (assuming
all changes are actually reviewed before commit).
.Sp
WARNING: This \fIwill\fR interact badly with the \fB--delete\fR option, as
\fB--delete\fR uses the \fI//AssemblyVersion\fR elements to track version
changes. Thus, if you have a member which is present in an early assembly
version and is removed in a subsequent assembly version, such as
\fISystem.Text.UTF8Encoding.GetBytes(string)\fR (which is present in .NET 1.0
but not in .NET 2.0), then the member will be removed when the
\fB--delete -fno-assembly-versions\fR options are specified, the member was
present in an earlier version of the assembly, and the current version of the
assembly does not contain the member.
.Sp
Consequently, this option should \fIonly\fR be specified if types and members
will \fInever\fR be removed from an assembly.
.TP
\fB\-i\fR, \fB\-\-import\fR=\fIFILE\fR
Import documentation found within \fIFILE\fR.
.Sp
@@ -175,15 +60,6 @@ Import documentation found within \fIFILE\fR.
Place the generated stubs into \fIDIRECTORY\fR.
.Sp
When updating documentation, \fIDIRECTORY\fR is also the source directory.
.TP
\fB\-\-since\fR=\fIVERSION\fR
When \fIupdating\fR documentation for an assembly, if a type or member is
encountered which didn't exist in the previous version of the assembly a
\fB<since version="\fR\fIVERSION\fR\fB"/>\fR element will be inserted.
.TP
\fB\-\-type\fR=\fITYPE\fR
Only update documentation for the type \fITYPE\fR.
.TP
.B \-h, \-?, \-\-help
Display a help message and exit.
.SH SEE ALSO
+5 -10
View File
@@ -642,6 +642,11 @@ This can be a time consuming operation.
\fIjit\fR, \fIj\fR
Collect information about time spent by the JIT engine compiling
methods.
.TP
\fItrack-stack\fR, \fIts\fR
Track the execution stack. By itself this option does nothing, but it
enables more detailed reporting in other options (because the profiler
will use the stack data).
.ne
.RE
.PP
@@ -1399,16 +1404,6 @@ No generic code sharing will be performed.
.Sp
Generic code sharing by default only applies to collections. The
Mono JIT by default turns this on.
.TP
\fBMONO_XDEBUG\fR
When the the MONO_XDEBUG env var is set, debugging info for JITted
code is emitted into a shared library, loadable into gdb. This enables,
for example, to see managed frame names on gdb backtraces.
.TP
\fBMONO_VERBOSE_METHOD\fR
Enables the maximum JIT verbosity for the specified method. This is
very helpfull to diagnose a miscompilation problems of a specific
method.
.SH VALGRIND
If you want to use Valgrind, you will find the file `mono.supp'
useful, it contains the suppressions for the GC which trigger
-48
View File
@@ -1,51 +1,3 @@
2009-02-03 Rodrigo Kumpera <[email protected]>
* docs/Makefile: Fix install-local and uninstall-local if
DISABLE_MCS_DOCS is defined.
2009-02-02 Rodrigo Kumpera <[email protected]>
* docs/Makefile: Don't build build-documentation if DISABLE_MCS_DOCS
is defined.
2009-01-31 Rodrigo Kumpera <[email protected]>
* docs/Makefile: use -f with rm on the clean target so
rm doesn't complain about missing files.
2008-12-10 Atsushi Enomoto <[email protected]>
* Makefile : remove sys.messaging from CENTUM_TESTS. It has never
been supported, and now, it's heavily developed.
2008-12-08 Jonathan Pryor <[email protected]>
* docs/monodoc.xml: Rename the "File Formats" node to "Commands and
Files", so that ~all man pages can be under the same node.
* docs/lang-csharp.source: Since C# is the only current language, move
the child nodes "up" a node so we have "Languages/C# Compiler Error
Reference" and "Languages/C# Language Specification" nodes.
2008-12-02 Jonathan Pryor <[email protected]>
* docs/Makefile: Build additional directories (Npgsql,
System.Configuration.Install, System.Design, System.Runtime.Remoting,
System.Runtime.Serialization.Formatters.Soap); shorten entries.
2008-11-26 Atsushi Enomoto <[email protected]>
* docs/Makefile: remove nunit docs that do not exist (and I don't
think such docs for private mono use should be provided).
2008-11-26 Atsushi Enomoto <[email protected]>
* Makefile : I happened to remove errors and docs which
used to be broken.
2008-11-25 Atsushi Enomoto <[email protected]>
* Makefile : replace nunit20 with nunit24.
2008-11-18 Jonathan Pryor <[email protected]>
* docs/Makefile: Don't build mono-file-formats.*, mono-tools.*
+3 -2
View File
@@ -1,11 +1,11 @@
thisdir := .
SUBDIRS := build jay mcs class nunit24 ilasm tools tests errors docs
SUBDIRS := build jay mcs class nunit20 ilasm tools tests errors docs
basic_SUBDIRS := build jay mcs class
net_1_1_bootstrap_SUBDIRS := build jay mcs class ilasm tools
net_2_0_bootstrap_SUBDIRS := build jay mcs class ilasm tools
net_2_0_SUBDIRS := build jay mcs class nunit24 ilasm tools tests errors docs
net_2_0_SUBDIRS := build jay mcs class nunit20 ilasm tools tests errors docs
net_2_1_bootstrap_SUBDIRS := build mcs class
net_2_1_raw_SUBDIRS := build mcs class tools
net_2_1_SUBDIRS := tools tests errors
@@ -24,6 +24,7 @@ centum_tests := \
class/System.Design \
class/System.DirectoryServices \
class/System.Drawing \
class/System.Messaging \
class/System.Runtime.Remoting \
class/System.Runtime.Serialization.Formatters.Soap \
class/System.Security \
-60
View File
@@ -1,63 +1,3 @@
2009-01-08 Geoff Norton <[email protected]>
* Makefile: Add darwin.make to the make dist target as well
2009-01-07 Geoff Norton <[email protected]>
* library.make: Allow platform specific exclude tags from the
test harness suite.
* darwin.make: Add to the build and add a new NotOnMac test
category
2008-12-30 Ankit Jain <[email protected]>
* library.make (TEST_HARNESS_OUTPUT*): Fix /labels switch.
2008-12-12 Raja R Harinath <[email protected]>
* rules.make (topdir): Don't use $(shell ...).
Reported by Jonathan Chambers.
2008-12-10 Atsushi Enomoto <[email protected]>
* library.make : enable FIXTURE and TESTNAME on run-test-ondotnet.
2008-11-28 Atsushi Enomoto <[email protected]>
* Makefile : ugh, ok another dist pain.
2008-11-28 Atsushi Enomoto <[email protected]>
* nunit-summary.xsl : copied from nunit resource (summary.xslt)
* library.make : put transformation result from TestResult-*.xml
into TestResult-*.log as we used to do.
2008-11-28 Marek Habersack <[email protected]>
* library.make (FIXTURE_ARG): /parameter:value syntax is not
supported in nunit 2.4
(TESTNAME_ARG): added support for the nunit-console -run
parameter, so that individual tests can be ran.
2008-11-26 Atsushi Enomoto <[email protected]>
* library.make : another nunit20 to kill :(
2008-11-25 Atsushi Enomoto <[email protected]>
* library.make : update nunit options that break upgrade to 2.4.
2008-11-18 Raja R Harinath <[email protected]>
* library.make (TEST_FILES): Notice filenames with ../ in the test
sources file, and handle them in a way suitable for the 'make
dist' handling of such files.
2008-11-12 Zoltan Varga <[email protected]>
* library.make: AOT the library after compilation if the AOT_IN_PROFILES
variable is defined and it contains the current profile.
2008-10-18 Jonathan Pryor <[email protected]>
* rules.make (dist-default): Distribute the Documentation directory,
+1 -2
View File
@@ -14,7 +14,7 @@ common/Consts.cs: common/Consts.cs.in $(wildcard config.make)
test -n '$(MONO_VERSION)'
sed -e 's,@''MONO_VERSION@,$(MONO_VERSION),' $< > $@
PLATFORMS = darwin linux win32
PLATFORMS = linux win32
PROFILES = \
basic \
net_1_1_bootstrap \
@@ -41,7 +41,6 @@ DISTFILES = \
corcompare-api.xsl \
executable.make \
library.make \
nunit-summary.xsl \
rules.make \
$(COMMON_SRCS:%=common/%) \
$(PLATFORMS:%=platforms/%.make) $(PROFILES:%=profiles/%.make)
-5
View File
@@ -1,8 +1,3 @@
2008-11-25 Rolf Bjarne Kvinge <[email protected]>
* Consts.cs.in: Update Silverlight's FxFileVersion to final
version number of Silverlight 2.
2008-08-20 Jb Evain <[email protected]>
* Consts.cs.in: add NET_3_0 case for wcf.
+1 -1
View File
@@ -66,7 +66,7 @@ internal
// Versions of .NET Framework for SilverLight
public const string FxVersion = "2.0.5.0";
public const string VsVersion = "9.0.0.0"; // TODO:
public const string FxFileVersion = "2.0.31005.0";
public const string FxFileVersion = "2.0.30226.2";
public const string VsFileVersion = "9.0.50727.42"; // TODO:
#elif NET_2_0 || BOOTSTRAP_NET_2_0
// Versions of .NET Framework 2.0 RTM
+15 -26
View File
@@ -49,7 +49,7 @@ the_libdir = $(topdir)/class/$(lib_dir)/$(PROFILE)/
the_lib = $(the_libdir)$(LIBRARY_NAME)
the_pdb = $(the_lib:.dll=.pdb)
the_mdb = $(the_lib).mdb
library_CLEAN_FILES += $(makefrag) $(the_lib) $(the_lib).so $(the_pdb) $(the_mdb)
library_CLEAN_FILES += $(makefrag) $(the_lib) $(the_pdb) $(the_mdb)
ifdef LIBRARY_NEEDS_POSTPROCESSING
build_libdir = fixup/$(PROFILE)/
@@ -174,7 +174,7 @@ ifndef NO_TEST
$(test_nunit_dep): $(topdir)/build/deps/nunit-$(PROFILE).stamp
@if test -f $@; then :; else rm -f $<; $(MAKE) $<; fi
$(topdir)/build/deps/nunit-$(PROFILE).stamp:
cd ${topdir}/nunit24 && $(MAKE)
cd ${topdir}/nunit20 && $(MAKE)
echo "stamp" >$@
library_CLEAN_FILES += $(topdir)/build/deps/nunit-$(PROFILE).stamp
endif
@@ -195,38 +195,34 @@ test-local: $(test_assemblies)
run-test-local: run-test-lib
run-test-ondotnet-local: run-test-ondotnet-lib
TEST_HARNESS_EXCLUDES = -exclude=$(PLATFORM_TEST_HARNESS_EXCLUDES)NotWorking,ValueAdd,CAS,InetAccess
TEST_HARNESS_EXCLUDES_ONDOTNET = /exclude:$(PLATFORM_TEST_HARNESS_EXCLUDES)NotDotNet,CAS
TEST_HARNESS_EXCLUDES = /exclude:NotWorking,ValueAdd,CAS,InetAccess
TEST_HARNESS_EXCLUDES_ONDOTNET = /exclude:NotDotNet,CAS
ifdef TEST_HARNESS_VERBOSE
TEST_HARNESS_OUTPUT = -labels
TEST_HARNESS_OUTPUT_ONDOTNET = -labels
TEST_HARNESS_OUTPUT = /labels
TEST_HARNESS_OUTPUT_ONDOTNET = /labels
TEST_HARNESS_POSTPROC = :
TEST_HARNESS_POSTPROC_ONDOTNET = :
else
TEST_HARNESS_OUTPUT = -output=TestResult-$(PROFILE).log
TEST_HARNESS_OUTPUT_ONDOTNET = -output=TestResult-ondotnet-$(PROFILE).log
TEST_HARNESS_POSTPROC = (echo ''; cat TestResult-$(PROFILE).log) | sed '1,/^Tests run: /d'; xsltproc $(topdir)/build/nunit-summary.xsl TestResult-$(PROFILE).xml >> TestResult-$(PROFILE).log
TEST_HARNESS_POSTPROC_ONDOTNET = (echo ''; cat TestResult-ondotnet-$(PROFILE).log) | sed '1,/^Tests run: /d'; xsltproc $(topdir)/build/nunit-summary.xsl TestResult-ondotnet-$(PROFILE).xml >> TestResult-ondotnet-$(PROFILE).log
TEST_HARNESS_OUTPUT = /output:TestResult-$(PROFILE).log
TEST_HARNESS_OUTPUT_ONDOTNET = /output:TestResult-ondotnet-$(PROFILE).log
TEST_HARNESS_POSTPROC = (echo ''; cat TestResult-$(PROFILE).log) | sed '1,/^Tests run: /d'
TEST_HARNESS_POSTPROC_ONDOTNET = (echo ''; cat TestResult-ondotnet-$(PROFILE).log) | sed '1,/^Tests run: /d'
endif
ifdef FIXTURE
FIXTURE_ARG = -fixture=MonoTests.$(FIXTURE)
endif
ifdef TESTNAME
TESTNAME_ARG = -run=MonoTests.$(TESTNAME)
FIXTURE_ARG = /fixture:MonoTests.$(FIXTURE)
endif
## FIXME: i18n problem in the 'sed' command below
run-test-lib: test-local
ok=:; \
MONO_REGISTRY_PATH="$(HOME)/.mono/registry" $(TEST_RUNTIME) $(RUNTIME_FLAGS) $(TEST_HARNESS) $(test_assemblies) -noshadow $(TEST_HARNESS_FLAGS) $(LOCAL_TEST_HARNESS_FLAGS) $(TEST_HARNESS_EXCLUDES) $(TEST_HARNESS_OUTPUT) -xml=TestResult-$(PROFILE).xml $(FIXTURE_ARG) $(TESTNAME_ARG)|| ok=false; \
MONO_REGISTRY_PATH="$(HOME)/.mono/registry" $(TEST_RUNTIME) $(RUNTIME_FLAGS) $(TEST_HARNESS) $(TEST_HARNESS_FLAGS) $(LOCAL_TEST_HARNESS_FLAGS) $(TEST_HARNESS_EXCLUDES) $(TEST_HARNESS_OUTPUT) /xml:TestResult-$(PROFILE).xml $(test_assemblies) $(FIXTURE_ARG) || ok=false; \
$(TEST_HARNESS_POSTPROC) ; $$ok
run-test-ondotnet-lib: test-local
ok=:; \
$(TEST_HARNESS) $(test_assemblies) -noshadow $(TEST_HARNESS_FLAGS) $(LOCAL_TEST_HARNESS_ONDOTNET_FLAGS) $(TEST_HARNESS_EXCLUDES_ONDOTNET) $(TEST_HARNESS_OUTPUT_ONDOTNET) -xml=TestResult-ondotnet-$(PROFILE).xml $(FIXTURE_ARG) $(TESTNAME_ARG) || ok=false; \
$(TEST_HARNESS) $(TEST_HARNESS_FLAGS) $(LOCAL_TEST_HARNESS_ONDOTNET_FLAGS) $(TEST_HARNESS_EXCLUDES_ONDOTNET) $(TEST_HARNESS_OUTPUT_ONDOTNET) /xml:TestResult-ondotnet-$(PROFILE).xml $(test_assemblies) || ok=false; \
$(TEST_HARNESS_POSTPROC_ONDOTNET) ; $$ok
endif
@@ -235,11 +231,11 @@ DISTFILES = $(wildcard *$(LIBRARY)*.sources) $(EXTRA_DISTFILES)
TEST_FILES =
ifdef HAVE_CS_TESTS
TEST_FILES += `sed -e '/^$$/d' -e 's,^../,,' -et -e 's,^,Test/,' $(test_sourcefile)`
TEST_FILES += `sed -e '/^$$/d' -e 's,^,Test/,' $(test_sourcefile)`
DISTFILES += $(test_sourcefile)
endif
ifdef HAVE_VB_TESTS
TEST_FILES += `sed -e '/^$$/d' -e 's,^../,,' -et -e 's,^,Test/,' $(btest_sourcefile)`
TEST_FILES += `sed -e '/^$$/d' -e 's,^,Test/,' $(btest_sourcefile)`
DISTFILES += $(btest_sourcefile)
endif
@@ -297,8 +293,6 @@ BUILT_SOURCES_cmdline = `echo $(BUILT_SOURCES) | $(PLATFORM_CHANGE_SEPARATOR_CMD
endif
endif
Q_AOT=$(if $(V),,@echo "AOT [$(PROFILE)] $(notdir $(@))";)
# The library
$(the_lib): $(the_libdir)/.stamp
@@ -314,11 +308,6 @@ else
$(LIBRARY_COMPILE) $(LIBRARY_FLAGS) $(LIB_MCS_FLAGS) -target:library -out:$@ $(BUILT_SOURCES_cmdline) @$(response)
$(SN) $(SNFLAGS) $@ $(LIBRARY_SNK)
endif
ifdef ENABLE_AOT
ifneq (,$(filter $(AOT_IN_PROFILES), $(PROFILE)))
$(Q_AOT) MONO_PATH=$(the_libdir) $(RUNTIME) --aot=bind-to-runtime-version $@ > $(PROFILE)_aot.log 2>&1
endif
endif
$(makefrag): $(sourcefile)
@echo Creating $@ ...
-48
View File
@@ -1,48 +0,0 @@
<?xml version="1.0" encoding="UTF-8" ?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method='text'/>
<xsl:template match="/">
<xsl:apply-templates/>
</xsl:template>
<xsl:template match="test-results">
<xsl:text>Tests run: </xsl:text>
<xsl:value-of select="@total"/>
<xsl:text>, Failures: </xsl:text>
<xsl:value-of select="@failures"/>
<xsl:text>, Not run: </xsl:text>
<xsl:value-of select="@not-run"/>
<xsl:text>, Time: </xsl:text>
<xsl:value-of select="test-suite/@time"/>
<xsl:text> seconds
</xsl:text>
<xsl:text>
</xsl:text>
<xsl:if test="//test-suite[failure]"><xsl:text>Test Fixture SetUp Failures:
</xsl:text></xsl:if>
<xsl:apply-templates select="//test-suite[failure]"/>
<xsl:if test="//test-case[failure]"><xsl:text>Test Case Failures:
</xsl:text></xsl:if>
<xsl:apply-templates select="//test-case[failure]"/>
<xsl:if test="//test-case[@executed='False']"><xsl:text>Tests not run:
</xsl:text></xsl:if>
<xsl:apply-templates select="//test-case[@executed='False']"/>
<xsl:text disable-output-escaping='yes'>&#xD;&#xA;</xsl:text>
</xsl:template>
<xsl:template match="test-case|test-suite">
<xsl:value-of select="position()"/><xsl:text>) </xsl:text>
<xsl:value-of select="@name"/>
<xsl:text> : </xsl:text>
<xsl:value-of select="child::node()/message"/>
<xsl:text disable-output-escaping='yes'>&#xD;&#xA;</xsl:text>
<xsl:if test="failure">
<xsl:value-of select="failure/stack-trace"/>
<xsl:text>
</xsl:text>
</xsl:if>
</xsl:template>
</xsl:stylesheet>
-38
View File
@@ -1,38 +0,0 @@
# -*- makefile -*-
#
# Platform-specific makefile rules. This one's for linux.
#
PLATFORM_DEBUG_FLAGS = -debug
PLATFORM_MCS_FLAGS = -optimize
PLATFORM_RUNTIME = $(RUNTIME)
PLATFORM_CORLIB = mscorlib.dll
PLATFORM_TEST_HARNESS_EXCLUDES = NotOnMac,
EXTERNAL_MCS = mcs
EXTERNAL_MBAS = mbas
EXTERNAL_RUNTIME = mono
RESGEN = MONO_PATH="$(topdir)/class/lib/$(PROFILE)$(PLATFORM_PATH_SEPARATOR)$$MONO_PATH" $(INTERNAL_RESGEN)
#ILDISASM = monodis
ILDISASM = false
PLATFORM_PATH_SEPARATOR = :
# Define this if this ever will work on Linux
# PLATFORM_MAKE_CORLIB_CMP = yes
# This is for changing / to \ on windows
PLATFORM_CHANGE_SEPARATOR_CMD = cat
hidden_prefix = .
hidden_suffix =
platform-check:
@:
# I tried this but apparently Make's version strings aren't that
# ... consistent between releases. Whatever.
#
# @if ! $(MAKE) --version |grep '^GNU Make version 3' 1>/dev/null 2>&1 ; then \
# echo "*** You need to build MCS with GNU make. Try \`gmake'" ; \
# exit 1 ; \
# fi
-1
View File
@@ -7,7 +7,6 @@ PLATFORM_DEBUG_FLAGS = -debug
PLATFORM_MCS_FLAGS = -optimize
PLATFORM_RUNTIME = $(RUNTIME)
PLATFORM_CORLIB = mscorlib.dll
PLATFORM_TEST_HARNESS_EXCLUDES =
EXTERNAL_MCS = mcs
EXTERNAL_MBAS = mbas
-1
View File
@@ -7,7 +7,6 @@ PLATFORM_DEBUG_FLAGS = /debug+ /debug:full
PLATFORM_MCS_FLAGS = /nologo /optimize
PLATFORM_RUNTIME =
PLATFORM_CORLIB = mscorlib.dll
PLATFORM_TEST_HARNESS_EXCLUDES =
EXTERNAL_MCS = mcs
EXTERNAL_MBAS = vbc.exe
+4 -9
View File
@@ -7,16 +7,11 @@
# If you need to edit this file, that's a bug; email
# [email protected] about it.
empty :=
space := $(empty) $(empty)
# Some more variables. The leading period in the sed expression prevents
# thisdir = . from being changed into '..' for the toplevel directory.
# given $(thisdir), we compute the path to the top directory
#
# split_path = $(filter-out .,$(subst /,$(space),$(1)))
# make_path = ./$(subst $(space),/,$(1))
# dotdottify = $(patsubst %,..,$(1))
# topdir = $(call make_path,$(call dotdottify,$(call split_path,$(thisdir))))
topdir := ./$(subst $(space),/,$(patsubst %,..,$(filter-out .,$(subst /,$(space),$(thisdir)))))
dots := $(shell echo $(thisdir) |sed -e 's,[^./][^/]*,..,g')
topdir := $(dots)
VERSION = 0.93
-22
View File
@@ -1,25 +1,3 @@
2009-01-22 Marek Habersack <[email protected]>
* Makefile (net_2_0_dirs): added System.Web - it now depends on
System.Core, so it needs to be recompiled one more time after
System.Core is done.
2008-12-08 Atsushi Enomoto <[email protected]>
* Makefile : revert previous one and retry before I revert everything.
2008-12-08 Atsushi Enomoto <[email protected]>
* Makefile : actually RabbitMQ.Client is under wrong build practice :(
2008-12-08 Atsushi Enomoto <[email protected]>
* Makefile : add new sys.messaging implementation.
2008-11-20 Jb Evain <[email protected]>
* Makefile: add System.Xml.Linq to the net_2_1 build.
2008-11-05 Marek Habersack <[email protected]>
* Makefile (net_2_0_dirs): Npgsql requires .NET 2.0+ now.
-9
View File
@@ -1,12 +1,3 @@
2009-01-20 Atsushi Enomoto <[email protected]>
* Commons.Xml.Relaxng_test.dll.sources : forgot to add
RelaxngDatatypeProviderTests.cs.
2008-11-11 Atsushi Enomoto <[email protected]>
* Makefile: what a messy EXTRA_DISTFILES.
2007-04-18 Atsushi Enomoto <[email protected]>
* Makefile (EXTRA_DISTFILES) :
@@ -1,8 +1,3 @@
2008-11-11 Atsushi Enomoto <[email protected]>
* RncParser.jay : handle inherited default namespace as expected.
This should fix HTML5 compact syntax grammar.
2007-12-27 Atsushi Enomoto <[email protected]>
* RncParser.jay, RncTokenizer.cs : some changes to fill element
@@ -56,17 +56,12 @@ namespace Commons.Xml.Relaxng.Rnc
public static RelaxngPattern ParseRnc (TextReader reader, XmlNameTable nameTable, string baseUri)
{
return ParseRnc (reader, nameTable, baseUri, null);
}
public static RelaxngPattern ParseRnc (TextReader reader, XmlNameTable nameTable, string baseUri, string defaultNamespace)
{
return new RncParser (nameTable).Parse (reader, baseUri, defaultNamespace);
return new RncParser (nameTable).Parse (reader, baseUri);
}
XmlNamespaceManager nsmgr;
XmlNamespaceManager dtnsmgr;
string defaultNamespace;
string defaultNamespace = String.Empty;
static int yacc_verbose_flag;
RncTokenizer tokenizer;
@@ -94,6 +89,9 @@ namespace Commons.Xml.Relaxng.Rnc
}
// note that this is different notion than that of xmlns.
public string DefaultNamespace {
get { return defaultNamespace; }
}
public RelaxngPattern Parse (TextReader source)
{
@@ -102,14 +100,6 @@ namespace Commons.Xml.Relaxng.Rnc
public RelaxngPattern Parse (TextReader source, string baseUri)
{
return Parse (source, baseUri, null);
}
public RelaxngPattern Parse (TextReader source, string baseUri, string defaultNamespace)
{
this.defaultNamespace = defaultNamespace;
if (defaultNamespace != null && defaultNamespace.Length != 0)
nsmgr.AddNamespace (String.Empty, defaultNamespace);
try {
if (Environment.GetEnvironmentVariable ("MONO_RELAXNG_COMPACT_DEBUG") == "yes")
debug = new yydebug.yyDebugSimple ();
@@ -161,7 +151,7 @@ namespace Commons.Xml.Relaxng.Rnc
RelaxngName name = nc as RelaxngName;
if (name != null) {
if (name.Namespace == null)
name.Namespace = defaultNamespace;
name.Namespace = this.DefaultNamespace;
return;
}
RelaxngNameChoice choice = nc as RelaxngNameChoice;
@@ -282,7 +272,6 @@ Decl /* returns null */
// TODO: constraints
string ns = (string) $4;
defaultNamespace = ns;
nsmgr.AddNamespace (String.Empty, ns);
$$ = null;
}
| KeywordDefault KeywordNamespace NamespacePrefix Equal NamespaceURILiteral
@@ -291,7 +280,6 @@ Decl /* returns null */
string prefix = (string) $3;
string ns = (string) $5;
defaultNamespace = ns;
nsmgr.AddNamespace (String.Empty, ns);
nsmgr.AddNamespace (prefix, ns);
$$ = null;
}
@@ -326,7 +314,7 @@ NamespaceURILiteral /* returns string */
}
| KeywordInherit
{
$$ = defaultNamespace;
$$ = (string) $1;
}
;
@@ -344,8 +332,8 @@ TopLevelBody /* returns RelaxngPattern */
{
RelaxngGrammar g = new RelaxngGrammar ();
FillLocation (g);
if (defaultNamespace != null)
g.DefaultNamespace = defaultNamespace;
if (nsmgr.DefaultNamespace != String.Empty)
g.DefaultNamespace = nsmgr.DefaultNamespace;
RelaxngGrammarContentList list = (RelaxngGrammarContentList) $1;
FillGrammarContent (list, g.Starts, g.Defines, g.Divs, g.Includes);
$$ = g;
@@ -464,11 +452,11 @@ AnyURILiteral /* returns string */
;
OptInherit /* returns string */
/* The empty value will be handled at Compile() time. */
/* FIXME: It is not handled properly. */
: /* empty */
{
// MakeNsAttribute (LookupDefault (environment));
$$ = defaultNamespace;
$$ = nsmgr.DefaultNamespace;
}
| KeywordInherit Equal IdentifierOrKeyword
{
@@ -1,23 +1,3 @@
2009-02-17 Atsushi Enomoto <[email protected]>
* XsdDatatypeProvider.cs : workaround .NET/Mono Regex bug that
does not handle \p{Latin-1Supplement} to work with OOXML grammar.
2009-01-20 Atsushi Enomoto <[email protected]>
* RelaxngReader.cs : fixed wrong text skip and ns/datatypeLibrary
stack pop. Fixed bug #463267.
2009-01-20 Atsushi Enomoto <[email protected]>
* RelaxngGrammar.cs : fix confused use of datatype provider property.
Fixed bug #463264. Based on the patch by Mark Junker.
2008-11-11 Atsushi Enomoto <[email protected]>
* RelaxngPattern.cs : handle inherited default namespace in compact
syntax as expected.
2008-08-25 Atsushi Enomoto <[email protected]>
* RelaxngPattern.cs : unlike "include" element, "external" element
@@ -56,6 +56,8 @@ namespace Commons.Xml.Relaxng
RelaxngGrammarContentList includes = new RelaxngGrammarContentList ();
RelaxngGrammarContentList divs = new RelaxngGrammarContentList ();
RelaxngDatatypeProvider provider;
// compiled fields.
RdpPattern startPattern;
@@ -112,8 +114,8 @@ namespace Commons.Xml.Relaxng
}
internal RelaxngDatatypeProvider Provider {
get { return (base.DataProvider == null) ? (parentGrammar != null ? parentGrammar.Provider : base.DataProvider) : base.DataProvider; }
set { base.DataProvider = value; }
get { return parentGrammar != null ? parentGrammar.Provider : provider; }
set { provider = value; }
}
public override RelaxngPatternType PatternType {
@@ -83,7 +83,7 @@ namespace Commons.Xml.Relaxng
RelaxngGrammar g = null;
try {
if (grammar.IsSourceCompactSyntax) {
return RncParser.ParseRnc (new StreamReader ((Stream) grammar.Resolver.GetEntity (uri, null, typeof (Stream))), null, BaseUri, nsContext);
return RncParser.ParseRnc (new StreamReader ((Stream) grammar.Resolver.GetEntity (uri, null, typeof (Stream))), null, BaseUri);
} else {
xtr = new XmlTextReader (uri.AbsoluteUri, (Stream) grammar.Resolver.GetEntity (uri, null, typeof (Stream)));
RelaxngReader r = new RelaxngReader (xtr, nsContext, grammar.Resolver);
@@ -343,16 +343,15 @@ namespace Commons.Xml.Relaxng
if (BaseUri != null && BaseUri != String.Empty)
baseUri = new Uri (BaseUri);
} catch (UriFormatException) {
if (File.Exists (BaseUri))
if (Path.IsPathRooted (BaseUri))
baseUri = new Uri (Path.GetFullPath (BaseUri));
}
Uri uri = grammar.Resolver.ResolveUri (baseUri, Href);
RelaxngGrammar g = ReadExternalResource (grammar, uri, (ns != null && ns.Length != 0) || !grammar.IsSourceCompactSyntax ? ns : grammar.DefaultNamespace) as RelaxngGrammar;
RelaxngGrammar g = ReadExternalResource (grammar, uri, ns) as RelaxngGrammar;
if (g == null)
throw new RelaxngException (this, "Included syntax must start with \"grammar\" element.");
g.DataProvider = grammar.Provider;
g.IsSourceCompactSyntax = grammar.IsSourceCompactSyntax;
// process recursive inclusions.
foreach (RelaxngInclude inc in g.Includes)
@@ -60,7 +60,6 @@ namespace Commons.Xml.Relaxng
Stack nsStack = new Stack ();
Stack datatypeLibraryStack = new Stack ();
XmlResolver resolver;
bool skipExternal = true;
// ArrayList annotationNamespaces = new ArrayList ();
// ctor
@@ -121,14 +120,13 @@ namespace Commons.Xml.Relaxng
bool skipRead = false;
bool b = false;
bool loop = true;
MoveToElement ();
if (IsEmptyElement || NodeType == XmlNodeType.EndElement) { // this should be done here
if (IsEmptyElement) { // this should be done here
nsStack.Pop ();
datatypeLibraryStack.Pop ();
}
do {
if (!skipRead)
b = Reader.Read ();
Reader.Read ();
else
skipRead = false;
switch (NodeType) {
@@ -145,10 +143,7 @@ namespace Commons.Xml.Relaxng
else
loop = false;
break;
case XmlNodeType.Element:
case XmlNodeType.EndElement:
if (!skipExternal)
goto default;
default:
if (NamespaceURI != RelaxngGrammar.NamespaceURI) {
Reader.Skip ();
skipRead = true;
@@ -156,9 +151,6 @@ namespace Commons.Xml.Relaxng
else
loop = false;
break;
default:
loop = false;
break;
}
} while (!Reader.EOF && loop);
@@ -189,6 +181,11 @@ namespace Commons.Xml.Relaxng
else
datatypeLibraryStack.Push (DatatypeLibrary);
break;
case XmlNodeType.EndElement:
nsStack.Pop ();
datatypeLibraryStack.Pop ();
break;
}
return b;
@@ -960,13 +957,5 @@ namespace Commons.Xml.Relaxng
FillLocation (na);
return na;
}
public override string ReadString ()
{
skipExternal = false;
string s = base.ReadString ();
skipExternal = true;
return s;
}
}
}
@@ -138,7 +138,6 @@ namespace Commons.Xml.Relaxng.XmlSchema
r.BaseTypeName = new XmlQualifiedName (primitive.Name, ns);
foreach (RelaxngParam p in parameters) {
XmlSchemaFacet f = null;
string value = p.Value;
switch (p.Name) {
case "maxExclusive":
f = new XmlSchemaMaxExclusiveFacet ();
@@ -154,9 +153,6 @@ namespace Commons.Xml.Relaxng.XmlSchema
break;
case "pattern":
f = new XmlSchemaPatternFacet ();
// .NET/Mono Regex has a bug that it does not support "IsLatin-1Supplement"
// (it somehow breaks at '-').
value = value.Replace ("\\p{IsLatin-1Supplement}", "[\\x80-\\xFF]");
break;
case "whiteSpace":
f = new XmlSchemaWhiteSpaceFacet ();
@@ -179,7 +175,7 @@ namespace Commons.Xml.Relaxng.XmlSchema
default:
throw new RelaxngException (String.Format ("XML Schema facet {0} is not recognized or not supported.", p.Name));
}
f.Value = value;
f.Value = p.Value;
r.Facets.Add (f);
}
@@ -1,5 +1,4 @@
RdpPatternTests.cs
RelaxngDatatypeProviderTests.cs
RelaxngReaderTests.cs
RelaxngValidatingReaderTests.cs
XsdDatatypeTests.cs
@@ -1,8 +1,3 @@
2009-01-20 Atsushi Enomoto <[email protected]>
* XmlDefaultReader.cs : remove bogus overrides that blocks normal
Read(). It was a design flaw in .NET.
2004-06-25 Atsushi Enomoto <[email protected]>
* XmlDefaultReader.cs : Added novell's license (avoid confusion).
@@ -211,7 +211,6 @@ namespace Commons.Xml
return Reader.Read ();
}
/*
public override string ReadString ()
{
return reader.ReadString ();
@@ -226,7 +225,6 @@ namespace Commons.Xml
{
return reader.ReadOuterXml ();
}
*/
public override string LookupNamespace (string prefix)
{
+12 -4
View File
@@ -14,10 +14,18 @@ EXTRA_DISTFILES = \
Commons.Xml.Relaxng.Rnc/RncParser.jay \
Test/ChangeLog \
Test/XmlFiles/ChangeLog \
$(wildcard Test/XmlFiles/*.rng) \
$(wildcard Test/XmlFiles/*.rnc) \
$(wildcard Test/XmlFiles/*.nvdl) \
$(wildcard Test/XmlFiles/*.xml) \
Test/XmlFiles/SimpleElementPattern1.xml \
Test/XmlFiles/SimpleElementPattern1.rng \
Test/XmlFiles/SimpleElementPattern2.xml \
Test/XmlFiles/SimpleElementPattern2.rng \
Test/XmlFiles/team.xml \
Test/XmlFiles/team.rng \
Test/XmlFiles/relaxng.rng \
Test/XmlFiles/relaxng.rnc \
Test/XmlFiles/atom.rnc \
Test/XmlFiles/schemas-xmlsoap-or-ws-2005-05-identity.rnc \
Test/XmlFiles/nvdl.nvdl \
Test/XmlFiles/nvdl.rng \
$(wildcard Test/standalone_tests/*.cs) \
$(RESOURCE_FILES)
@@ -1,17 +1,3 @@
2009-01-20 Atsushi Enomoto <[email protected]>
* RelaxngDatatypeProviderTests.cs : new test, based on bug #463267
by Mark Junker.
2009-01-20 Atsushi Enomoto <[email protected]>
* RelaxngDatatypeProviderTests.cs : new test, based on bug #463264
by Mark Junker.
2008-11-11 Atsushi Enomoto <[email protected]>
* RncTests.cs : added InheritDefaultNamespace().
2007-12-14 Atsushi Enomoto <[email protected]>
* RelaxngReaderTests.cs : added test for bug #347945.
@@ -1,98 +0,0 @@
//
// RelaxngDatatypeProviderTest.cs
//
// Authors:
// Atsushi Enomoto <[email protected]>
//
using System;
using System.IO;
using System.Xml;
using Commons.Xml.Relaxng;
using Commons.Xml.Relaxng.XmlSchema;
using NUnit.Framework;
namespace MonoTests.Commons.Xml.Relaxng
{
[TestFixture]
public class RelaxngDatatypeProviderTests
{
[Test]
public void CustomTypeProvider ()
{
var datatypeLibrary = SetupMyDataProvider ();
XmlDocument xml = new XmlDocument ();
xml.LoadXml ("<root> <v1>mytype</v1> <v2>1</v2> </root>");
XmlDocument schemaXml = ReadDoc ("Test/XmlFiles/463264.rng");
XmlReader reader = new RelaxngValidatingReader (new XmlNodeReader (xml), new XmlNodeReader (schemaXml), datatypeLibrary);
while (reader.Read ())
;
}
[Test]
public void Bug463267 ()
{
var datatypeLibrary = SetupMyDataProvider ();
XmlDocument xml = new XmlDocument ();
xml.LoadXml ("<root> <v2>1</v2> <v1>mytype</v1> </root>");
XmlDocument schemaXml = ReadDoc ("Test/XmlFiles/463267.rng");
XmlReader reader = new RelaxngValidatingReader (new XmlNodeReader (xml), new XmlNodeReader (schemaXml), datatypeLibrary);
while (reader.Read ())
;
}
RelaxngDatatypeProvider SetupMyDataProvider ()
{
var datatypeLibrary = new RelaxngMergedProvider ();
datatypeLibrary [MyRngTypeProvider.Namespace] = new MyRngTypeProvider();
datatypeLibrary ["http://www.w3.org/2001/XMLSchema-datatypes"] = XsdDatatypeProvider.Instance;
datatypeLibrary [System.Xml.Schema.XmlSchema.Namespace] = XsdDatatypeProvider.Instance;
datatypeLibrary [String.Empty] = RelaxngMergedProvider.DefaultProvider [string.Empty];
return datatypeLibrary;
}
XmlDocument ReadDoc (string s)
{
var d = new XmlDocument ();
d.Load (s);
return d;
}
}
class MyRngTypeProvider : RelaxngDatatypeProvider
{
public static readonly string Namespace = "http://tempuri.org/mytypes";
public override RelaxngDatatype GetDatatype(string name, string ns, RelaxngParamList parameters)
{
switch (name)
{
case "mytype":
return new MyType();
}
return null;
}
}
class MyType : RelaxngDatatype
{
public override string Name {
get { return "mytype"; }
}
public override string NamespaceURI {
get { return MyRngTypeProvider.Namespace; }
}
public override object Parse (string text, System.Xml.XmlReader reader)
{
return text;
}
public override bool IsValid (string text, System.Xml.XmlReader reader)
{
return ((string) Parse (text, reader)) == "mytype";
}
}
}
+4 -24
View File
@@ -20,24 +20,18 @@ namespace MonoTests.Commons.Xml.Relaxng
[TestFixture]
public class RncTests
{
RelaxngPattern Compile (string file)
void Compile (string file)
{
using (StreamReader sr = new StreamReader (file)) {
return Compile (sr, file);
Compile (sr);
}
}
RelaxngPattern Compile (TextReader reader)
{
return Compile (reader, null);
}
RelaxngPattern Compile (TextReader reader, string baseUri)
void Compile (TextReader reader)
{
RncParser parser = new RncParser (new NameTable ());
RelaxngPattern g = parser.Parse (reader, baseUri);
RelaxngPattern g = parser.Parse (reader);
g.Compile ();
return g;
}
[Test]
@@ -81,19 +75,5 @@ start = mine";
{
Compile (new StringReader ("element foo { \"\\x{10FFFF}\" }"));
}
[Test]
public void InheritDefaultNamespace ()
{
RelaxngPattern g = Compile ("Test/XmlFiles/include-default-namespace.rnc");
XmlReader xtr = new XmlTextReader ("Test/XmlFiles/include-default-namespace.xml");
RelaxngValidatingReader r = new RelaxngValidatingReader (xtr, g);
try {
while (!r.EOF)
r.Read ();
} finally {
r.Close ();
}
}
}
}
@@ -1,14 +0,0 @@
<?xml version="1.0" encoding="utf-8" ?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<start>
<element name="root">
<element name="v1">
<data type="mytype" datatypeLibrary="http://tempuri.org/mytypes" />
</element>
<element name="v2">
<data type="int" />
</element>
</element>
</start>
</grammar>
@@ -1,16 +0,0 @@
<?xml version="1.0" encoding="utf-8" ?>
<grammar xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://tempuri.org/mytypes">
<start>
<element name="root">
<element name="v2">
<data type="int" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
<param name="minExclusive">0</param>
<param name="maxExclusive">10</param>
</data>
</element>
<element name="v1">
<data type="mytype" />
</element>
</element>
</start>
</grammar>
@@ -1,17 +1,3 @@
2009-01-20 Atsushi Enomoto <[email protected]>
* 463267.rng : new test file.
2009-01-20 Atsushi Enomoto <[email protected]>
* 463264.rng : new test file.
2008-11-11 Atsushi Enomoto <[email protected]>
* include-default-namespace.rnc,
include-default-namespace-included.rnc,
include-default-namespace.xml : new test files.
2007-04-18 Atsushi Enomoto <[email protected]>
* schemas-xmlsoap-or-ws-2005-05-identity.rnc : new test schema.
@@ -1,5 +0,0 @@
grammar {
start = root
root = element root { empty }
}
@@ -1,4 +0,0 @@
default namespace = "urn:foo"
include "include-default-namespace-included.rnc"
@@ -1 +0,0 @@
<root xmlns="urn:foo" />
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
<!-- RELAX NG for RELAX NG -->
<!-- $Id$ -->
<!-- $Id: relaxng.rng,v 1.1 2004/03/17 19:27:34 atsushi Exp $ -->
<grammar datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes"
ns="http://relaxng.org/ns/structure/1.0"
xmlns="http://relaxng.org/ns/structure/1.0">
-5
View File
@@ -77,10 +77,7 @@ common_dirs := \
Novell.Directory.Ldap \
Mono.Security.Win32 \
System.DirectoryServices \
RabbitMQ.Client \
Mono.Messaging \
System.Messaging \
Mono.Messaging.RabbitMQ \
System.ServiceProcess \
System.Drawing.Design \
System.Design \
@@ -106,7 +103,6 @@ net_2_0_dirs := \
System.Xml.Linq \
System.Data.DataSetExtensions \
System.Data.Linq \
System.Web \
System.Web.Abstractions \
System.Web.Routing \
System.Web.Extensions_1.0 \
@@ -131,7 +127,6 @@ net_2_1_dirs := \
System.Net \
System.XML \
System.Core \
System.Xml.Linq \
System.Runtime.Serialization \
System.ServiceModel \
System.ServiceModel.Web
+4 -17
View File
@@ -1,16 +1,3 @@
2009-01-16 Carlos Alberto Cortez <[email protected]>
* System.Windows.Forms_test.dll.sources: Add ClipboardTest.cs.
2008-11-27 Atsushi Enomoto <[email protected]>
* Makefile: here is another nunit24 option breakage.
2008-11-11 Andrés G. Aragoneses <[email protected]>
* Application.cs: After UIA assembly is successfully loaded,
dump any exception that happens on initialization to stderr.
2008-11-08 Andreia Gaita <[email protected]>
* SWF2k5-tests.csproj: Fix the previous ChangeLog entry (bad merge). Update
@@ -35,7 +22,7 @@
* System.Windows.Forms.dll.resources: Removed unused dialog-*.png images.
2008-09-18 Mike Gorse <<[email protected]>
2008-09-18 Mike Gorse <[email protected]>
* System.Windows.Forms.dll.sources: Added IKeyFilter.cs.
@@ -858,7 +845,7 @@
* resources/, System.Windows.Forms.dll.resources, Makefile:
Add user-home Tango icon in various sizes.
2006-09-05 KornAcl PA!l <[email protected]>
2006-09-05 Kornél Pál <[email protected]>
* Makefile: Removed CODEPAGE as now UTF-8 is the default.
@@ -1021,7 +1008,7 @@
* System.Windows.Forms_test.dll.sources: Added System.Resources/CultureTest.cs
2005-11-12 Pedro MartA-nez JuliA! <[email protected]>
2005-11-12 Pedro Martínez Juliá <[email protected]>
* System.Windows.Forms_test.dll.sources: Added DataGridViewElementTest.cs
DataGridViewBandTest.cs DataGridViewCellTest.cs
@@ -1069,7 +1056,7 @@
* System.Windows.Forms_test.dll.sources : Added Common.cs
2005-09-27 KornAcl PA!l <[email protected]>
2005-09-27 Kornél Pál <[email protected]>
* Makefile: Replaced /codepage with CODEPAGE.
+9 -3
View File
@@ -106,12 +106,18 @@ TEST_MCS_FLAGS = /r:System.Data.dll /r:System.Drawing.dll \
-resource:Test/resources/32x32.ico,32x32.ico \
-nowarn:618,612
SWF.csproj: System.Windows.Forms.dll.sources System.Windows.Forms.dll.resources build-csproj
./build-csproj
SWF2k5.csproj: System.Windows.Forms.dll.sources System.Windows.Forms.dll.resources build-csproj2k5
./build-csproj2k5
include ../../build/library.make
TEST_HARNESS_EXCLUDES = -exclude=Interactive,NotWorking,ValueAdd,CAS,InetAccess
TEST_HARNESS_EXCLUDES_ONDOTNET = -exclude=Interactive,NotDotNet,CAS
TEST_HARNESS_EXCLUDES = /exclude:Interactive,NotWorking,ValueAdd,CAS,InetAccess
TEST_HARNESS_EXCLUDES_ONDOTNET = /exclude:Interactive,NotDotNet,CAS
$(the_lib): $(RESOURCES)
$(the_lib): $(RESOURCES) SWF.csproj SWF2k5.csproj
$(RESX_RESOURCES): %.resources: %.resx
$(RESGEN) $< || cp $@.prebuilt $@
@@ -1,8 +1,3 @@
2009-01-07 Geoff Norton <[email protected]>
* WindowHandler.cs: Don't attempt to activate a disposed Form.
Fixes several of the nunit winforms crashes on Mac.
2008-08-14 Geoff Norton <[email protected]>
* WindowHandler.cs: Revert the change which didn't set ActiveWindow
@@ -119,7 +119,7 @@ namespace System.Windows.Forms.CarbonInternal {
Control c = Control.FromHandle (hwnd.client_window);
if (c != null) {
Form form = c.FindForm ();
if (form != null && !form.IsDisposed) {
if (form != null) {
Driver.SendMessage (form.Handle, Msg.WM_ACTIVATE, (IntPtr) WindowActiveFlags.WA_ACTIVE, IntPtr.Zero);
XplatUICarbon.ActiveWindow = hwnd.client_window;
}
@@ -1,9 +1,3 @@
2009-02-04 Jonathan Pobst <[email protected]>
* FlowLayout.cs: When laying out ToolStripItems, they should be
the height of the ToolStrip, not their preferred height.
[Fixes bug #469196]
2008-11-07 Jonathan Pobst <[email protected]>
* DefaultLayout.cs: Apply patch from Jonathan Anderson that keeps
@@ -358,13 +358,9 @@ namespace System.Windows.Forms.Layout
// Only apply layout to visible controls.
if (!c.Available) { continue; }
// Resize any AutoSize controls to their preferred width
// (the height should fill the ToolStrip)
if (c.AutoSize == true) {
Size preferred_size = c.GetPreferredSize (c.Size);
preferred_size.Height = parentDisplayRectangle.Height;
c.SetBounds (new Rectangle (c.Location, preferred_size));
}
// Resize any AutoSize controls to their preferred size
if (c.AutoSize == true)
c.SetBounds (new Rectangle (c.Location, c.GetPreferredSize (c.Size)));
switch (settings.FlowDirection) {
case FlowDirection.BottomUp:
@@ -1,9 +1,3 @@
2008-12-30 Jonathan Pobst <[email protected]>
* IVisualStyle.cs, VisualStylesGtkPlus.cs, VisualStylesNative.cs:
Add way to get style filename.
[Fixes bug #462766]
2008-09-16 Jonathan Pobst <[email protected]>
* VisualStyleElement.cs: Fixed Header.Item.Normal value.
@@ -71,7 +71,6 @@ namespace System.Windows.Forms.VisualStyles
string VisualStyleInformationCopyright { get; }
string VisualStyleInformationDescription { get; }
string VisualStyleInformationDisplayName { get; }
string VisualStyleInformationFileName { get; }
bool VisualStyleInformationIsSupportedByOS { get; }
int VisualStyleInformationMinimumColorDepth { get; }
string VisualStyleInformationSize { get; }
@@ -1128,13 +1128,7 @@ namespace System.Windows.Forms.VisualStyles
return null;
}
}
public string VisualStyleInformationFileName {
get {
return null;
}
}
public bool VisualStyleInformationIsSupportedByOS
{
public bool VisualStyleInformationIsSupportedByOS {
get {
return true;
}
@@ -343,16 +343,6 @@ namespace System.Windows.Forms.VisualStyles
return GetData ("DISPLAYNAME");
}
}
public string VisualStyleInformationFileName {
get {
Text.StringBuilder ThemeName = new Text.StringBuilder (260);
Text.StringBuilder ColorName = new Text.StringBuilder (260);
Text.StringBuilder SizeName = new Text.StringBuilder (260);
UXTheme.GetCurrentThemeName (ThemeName, ThemeName.Capacity, ColorName, ColorName.Capacity, SizeName, SizeName.Capacity);
return ThemeName.ToString ();
}
}
static string GetData (string propertyName)
{
Text.StringBuilder ThemeName = new Text.StringBuilder (260);
Loaded 100 of 3589 files, more files were not shown because too many files have changed in this diff. Show more