[Mono-dev] svn compilation - test error? (Local error?)
Hi there I have a script that builds us a new mono svn every night. This script has been failing for the last 3-4 days - with something that looks to me as an error in the tests: --- positive 'test-*.cs' ../class/lib/default/mcs.exe known-issues-mcs mcs.log Testing: ../class/lib/default/mcs.exe test-562.cs... KNOWN ISSUE (Execution error) test-587.cs... KNOWN ISSUE (Execution error) test-anon-73.cs... REGRESSION (SUCCESS - COMPILATION ERROR) test-anon-73.cs(6,29): error CS1593: Delegate `System.Threading.ThreadStart' does not take `1' arguments test-anon-73.cs(6,29): error CS1661: Cannot convert `anonymous method' to delegate type `System.Threading.ThreadStart' since there is a parameter mismatch test-xml-027.cs... KNOWN ISSUE (Xml comparision error) Done 772 test cases passed (99.48%) 3 known issue(s) The latest changes caused regression in 1 file(s) test-anon-73.cs make: *** [run-test-local] Error 1 Could not run mcs compiler tests --- Is this a problem in my end, or is there a problem with current svn? Regards, Mads -- Med venlig hilsen/Regards Systemudvikler/Systemsdeveloper cand.scient.dat, Ph.d., Mads Bondo Dydensborg Dansk BiblioteksCenter A/S, Tempovej 7-11, 2750 Ballerup, Tlf. +45 44 86 77 34 ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] [Patch] NameObjectCollectionBase, HttpCookieCollection
Hello, Attached are three small patches for NameObjectCollectionBase.cs, NameObjectCollectionBaseTest.cs and HttpCookieCollection.cs. All unit tests pass on Mono. Could someone verify that the new unit tests work on MS.NET? May I commit? - Juraj Index: System.Web/System.Web/ChangeLog === --- System.Web/System.Web/ChangeLog (revision 91583) +++ System.Web/System.Web/ChangeLog (working copy) @@ -1,3 +1,7 @@ +2007-12-19 Juraj Skripsky [EMAIL PROTECTED] + + * HttpCookieCollection.cs (AllKeys): Use Keys.CopyTo(). + 2007-12-18 Miguel de Icaza [EMAIL PROTECTED] * HttpCookieCollection.cs (Get): implement using the indexer to Index: System.Web/System.Web/HttpCookieCollection.cs === --- System.Web/System.Web/HttpCookieCollection.cs (revision 91583) +++ System.Web/System.Web/HttpCookieCollection.cs (working copy) @@ -28,6 +28,7 @@ // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. // +using System.Collections; using System.Collections.Specialized; using System.Security.Permissions; @@ -161,13 +162,8 @@ public string[] AllKeys { get { -/* XXX another inefficient copy due to - * lack of exposure from the base - * class */ string[] keys = new string [Keys.Count]; -for (int i = 0; i Keys.Count; i ++) - keys[i] = Keys[i]; - +((ICollection)Keys).CopyTo (keys, 0); return keys; } } Index: System/System.Collections.Specialized/NameObjectCollectionBase.cs === --- System/System.Collections.Specialized/NameObjectCollectionBase.cs (revision 91583) +++ System/System.Collections.Specialized/NameObjectCollectionBase.cs (working copy) @@ -101,7 +101,7 @@ } public bool MoveNext() { -return ((++m_position)m_collection.Count)?true:false; +return ((++m_position) m_collection.Count); } public void Reset() { @@ -128,17 +128,26 @@ } // ICollection methods --- - void ICollection.CopyTo(Array arr, int index) + void ICollection.CopyTo (Array array, int arrayIndex) { -if (arr==null) - throw new ArgumentNullException(array can't be null); -IEnumerator en = this.GetEnumerator(); -int i = index; -while (en.MoveNext()) -{ - arr.SetValue(en.Current,i); - i++; -} +if (null == array) + throw new ArgumentNullException (array); + +if (arrayIndex 0) + throw new ArgumentOutOfRangeException (arrayIndex); + +if (array.Rank 1) + throw new ArgumentException (array is multidimensional); + +if ((array.Length 0) (arrayIndex = array.Length)) + throw new ArgumentException (arrayIndex is equal to or greater than array.Length); + +ArrayList items = m_collection.m_ItemsArray; +if (arrayIndex + items.Count array.Length) + throw new ArgumentException (Not enough room from arrayIndex to end of array for this KeysCollection); + +for (int i = arrayIndex; i items.Count; i++) + array.SetValue (((_Item)items [i]).key, i); } bool ICollection.IsSynchronized @@ -360,7 +369,7 @@ void ICollection.CopyTo (Array array, int index) { - (Keys as ICollection).CopyTo (array, index); + ((ICollection)Keys).CopyTo (array, index); } // IDeserializationCallback Index: System/System.Collections.Specialized/ChangeLog === --- System/System.Collections.Specialized/ChangeLog (revision 91583) +++ System/System.Collections.Specialized/ChangeLog (working copy) @@ -1,3 +1,8 @@ +2007-12-19 Juraj Skripsky [EMAIL PROTECTED] + + * NameObjectCollectionBase.cs (CopyTo): Add argument checking, + replace use of enumerator by for-loop. + 2007-04-29 Ilya Kharmatsky [EMAIL PROTECTED] * NameValueCollection.cs: Proper exception handling in several Index: System/Test/System.Collections.Specialized/NameObjectCollectionBaseTest.cs === --- System/Test/System.Collections.Specialized/NameObjectCollectionBaseTest.cs (revision 91583) +++ System/Test/System.Collections.Specialized/NameObjectCollectionBaseTest.cs (working copy) @@ -452,5 +452,47 @@ Assert.AreEqual (string1, array[0], [0]); Assert.AreEqual (string2, array[1], [1]); } + + [Test] + [ExpectedException (typeof (ArgumentNullException))] + public void CopyTo_Null () + { + UnitTestNameObjectCollectionBase c = new UnitTestNameObjectCollectionBase (); + ((ICollection)c).CopyTo (null, 0); + } + + [Test] + [ExpectedException (typeof (ArgumentOutOfRangeException))] + public void CopyTo_NegativeIndex () + { + string [] array = new string [1]; + UnitTestNameObjectCollectionBase c = new UnitTestNameObjectCollectionBase (); + c.Add (1, mono); + ((ICollection)c).CopyTo (array, -1); + } + + [Test] +
[Mono-dev] 1.2.6 on mac
Hi, I'm trying a simple winforms app on macosx (tiger), just a form with a picture box inside, with the latest 1.2.6 installer. It keeps saying that it can't open display (X-Server required...). I understand there is a new native driver for winforms on mac on 1.2.6, is there any setting to activate it? I previously had an older mono version, maybe it is getting settings from that? Cheers, David www.plasticscm.com ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] mono rpms for RHEL 3
Hi List, We dont see packages for RHEL3 and RHEL4 rpms do not install on RHEL 3 Any reason for not publishing the rpms for RHEL 3 ? Thanks, Vadiraj ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] RichTextBox and SeletionColor
I have tried to use SelectionColor (and SelectionFont) in a RichText Box. the SelectionFont works, but the SelectionColor doesn't. I have tried under 1.2.4 and 1.2.6 and no Color modification in either. Also, the code runs in MS .net2.0 and the Color modification DOES works correctly using the mono generated exe run in MS XP .Net2.0 Now it could just be that SelectionColor isn't implemented in Mono yet? but that seems odd, and I do seem to see code for it in the build, and you would think SelectionFont and SelectionColor would implement together closely. So I am baffed. And again, it does work when running under MS .Net2.0 (the same exe). If SelectionColor is supposed to work in Mono, can someone point me (or supply) an working example? Thanks, -- ted leslie [EMAIL PROTECTED] ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Static Bundling
On 12/18/07 Avery Pennarun wrote: I've been looking at using mkbundle myself for my own work. It's network stuff, not graphical, so I wouldn't expect gdiplus to be a problem for me. But what exactly is that case that it can't cope with? Dynamically-linked elf libraries? Could I just rebuild with static libs instead? mkbundle solves the needs of 99% of the people that need it's capabilities. It doesn't solve all the worlds problems, so you can't expect it to. From the manpage: mkbundle generates an executable program that will contain static copies of the assemblies listed on the command line. And it does exactly what it's documented to do. If you need additional capabilities you can roll your own, like linking the libs to your program yourself and redirecting the p/invoke calls as explained in man mono-config. Also, let me take this occasion to remind everyone that statically bundling the libmono library and any other LGPL library requires (if you distribute the binary) that you also distribute all the stuff that is needed by the user to relink your code to a different version of the library (this is just one of the ways to comply with the license, see the LGPL for more details). lupus -- - [EMAIL PROTECTED] debian/rules [EMAIL PROTECTED] Monkeys do it better ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] BSTR Marshalling in Mono
Hello, COM Interop support in mono works pretty well for most basic uses, but has some limitations when it comes to strings. Mainly, BSTR marshalling on non-Windows platforms is just a default implementation. The problem is that most COM systems (both Mainsoft's COM and Mozilla's XPCOM) have specific requirements on strings. They need to follow a certain format (usually a length prefixed string), use special allocators/deallocators, and use the correct byte size (2-byte vs. 4-byte encoding). Note, I did try to go down the road of using a custom marshaller, but ran into some issues. First, any assemblies that worked on Windows now need extensively modified to work on non-Windows platforms. This is more of an issue for COM, since MS has nice tools to generate COM Interop assemblies. Almost no one generates COM Interop code by hand. Second, even if the user tries to use a custom marshaller, there are places in the runtime that perform BSTR marshalling as well that the user cannot modify (without modifying mono and rebuilding). Examples include BSTR util methods in the Marshal class, VARIANT marshalling, etc. In order to better support this on non-Windows platforms, I'd like to make the BSTR marshalling in mono extensible. I have thought of a few ways to do this that I'll list, and hopefully get some feedback on as to which is best. 1. Expose some methods in the runtime so users could embed mono and adjust the BSTR marshalling behavior with callbacks. Something like mono_set_bstr_to_string_marshal, mono_set_bstr_from_string_marshal, mono_set_bstr_free. This would require users to embed mono. 2. Use the dll map in the config file to let the user specify entry points to perform BSTR marshalling. This seems a better choice than the first. There is then a technical question as to how to implement this. a. Right now all BSTR marshalling occurs in an icall. The current icall could lookup the info in the config map, and call the entry point itself. This would require no changes to any other code, but would require logic to parse the config file, load a library, and get an entry point. I know this logic exists, but I am not sure how much of it exists outside of the pinvoke framework and whether we would want to put that logic in the icalls anyway. b. I could also change all BTSR related routines to go through the Marshal class. This would intern pinvoke into the runtime. We could then use the config file and the current pinvoke redirection logic to simply redirect those pinvokes to a user supplied library. The downside to this would be having to modify all the icalls/logic in the runtime marshalling code for BSTRs. It would also make the string marshalling code a bit uglier, as currently all string marshalling occurs in icalls. This would require a check for BSTRs to call a managed method rather than an icall. Thanks, Jonathan ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] [Mono-list] RichTextBox and SeletionColor (Bug file?)
You have the Rich Text Box set as readonly? https://bugzilla.novell.com/show_bug.cgi?id=324354 I posted the work-around the set the back colour earlier today... On Dec 19, 2007 3:15 PM, ted leslie [EMAIL PROTECTED] wrote: by setting the BackColor in the RichTextBox before doing SelectionColor got it to work, but to be compatible with the MS .Net, selecting (what would be a default anyways) BackColor isn't required, so I think this should probably be looked at in the Mono distribution? -tl On Wed, 19 Dec 2007 09:35:49 -0500 ted leslie [EMAIL PROTECTED] wrote: I have tried to use SelectionColor (and SelectionFont) in a RichText Box. the SelectionFont works, but the SelectionColor doesn't. I have tried under 1.2.4 and 1.2.6 and no Color modification in either. Also, the code runs in MS .net2.0 and the Color modification DOES works correctly using the mono generated exe run in MS XP .Net2.0 Now it could just be that SelectionColor isn't implemented in Mono yet? but that seems odd, and I do seem to see code for it in the build, and you would think SelectionFont and SelectionColor would implement together closely. So I am baffed. And again, it does work when running under MS .Net2.0 (the same exe). If SelectionColor is supposed to work in Mono, can someone point me (or supply) an working example? Thanks, -- ted leslie [EMAIL PROTECTED] ___ Mono-list maillist - [EMAIL PROTECTED] http://lists.ximian.com/mailman/listinfo/mono-list -- ted leslie [EMAIL PROTECTED] ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list -- Luke Page - 07790587889 - Ex Libris Records www.exlibrisrecords.co.uk - a creative challenging independent record label, with wolves. ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] Is it possible to run ASP.NET from a CD?
Hi All, Was wondering if its theoretically possible to run xsp2 directly from a cd. I've seen some posts about embedding mono but don't really know what is involved. If anyone can confirm whether its possible or point me to any information that might help I'd appreciate it. What I'm thinking about is being able to run mojoportal directly from a cd probably with SQLite. Obviously it would be read only but I can see if it could be done it would be great for making demos and also maybe I could make a utility to import export from other db platforms so a site could be backed up and archived to cd in a way that you can see the site as it was at the time of backup. Is this possible? Thanks, Joe -- Joe Audette Software Solutions Architect Source Tree Solutions, LLC [EMAIL PROTECTED] http://www.sourcetreesolutions.com http://www.mojoportal.com ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] Remoting performance between two appdomains( plugins) in same process/application
Hi, I have a question on the performance of remoting between two appdomains running in the same process. We have developed a dynamic dll loading program (plugins) using appdomains and assemblies and need to pass a lot of data between the two plugins. We are passing image data between the two plugins. The size of the data is around 250K Bytes and the transfer happens 15-30 times a second. Question: Is remoting optimized when the appdomains are created in the same process / application ? ( We are passing the objects using MarshalByRefObject) Are the transfers the same as accessing shared memory or is the data still accessed via proxies ? Is there a big performance hit doing this in Mono ? Is there a better solution ? Thanks, Shawn Schaerer Director of Research and Development Cogmation Robotics Inc www.cogmation.com ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] [Mono-list] RichTextBox and SeletionColor (Bug file?)
by setting the BackColor in the RichTextBox before doing SelectionColor got it to work, but to be compatible with the MS .Net, selecting (what would be a default anyways) BackColor isn't required, so I think this should probably be looked at in the Mono distribution? -tl On Wed, 19 Dec 2007 09:35:49 -0500 ted leslie [EMAIL PROTECTED] wrote: I have tried to use SelectionColor (and SelectionFont) in a RichText Box. the SelectionFont works, but the SelectionColor doesn't. I have tried under 1.2.4 and 1.2.6 and no Color modification in either. Also, the code runs in MS .net2.0 and the Color modification DOES works correctly using the mono generated exe run in MS XP .Net2.0 Now it could just be that SelectionColor isn't implemented in Mono yet? but that seems odd, and I do seem to see code for it in the build, and you would think SelectionFont and SelectionColor would implement together closely. So I am baffed. And again, it does work when running under MS .Net2.0 (the same exe). If SelectionColor is supposed to work in Mono, can someone point me (or supply) an working example? Thanks, -- ted leslie [EMAIL PROTECTED] ___ Mono-list maillist - [EMAIL PROTECTED] http://lists.ximian.com/mailman/listinfo/mono-list -- ted leslie [EMAIL PROTECTED] ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Static Bundling
On 19/12/2007, Paolo Molaro [EMAIL PROTECTED] wrote: From the manpage: mkbundle generates an executable program that will contain static copies of the assemblies listed on the command line. And it does exactly what it's documented to do. It also does more than just that, since it has options like --static. It seems to solve quite a lot of the world's problems, actually. :) If you need additional capabilities you can roll your own, like linking the libs to your program yourself and redirecting the p/invoke calls as explained in man mono-config. This is the part that confused me: reading man mkbundle doesn't explain the limitations. Thanks for the explanation. The p/invoke stuff seems like it might be easy enough to fake by linking to a static library instead of a dynamic one, and then looking for dynamic symbols in dlopen(NULL) (ie. the executable file). The executable would have to be linked with -rdynamic in that case so that it exports its own symbols. All a bit tricky to get right, though. Have fun, Avery ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Remoting performance between two appdomains( plugins) in same process/application
El dc 19 de 12 del 2007 a les 09:03 -0600, en/na Shawn Schaerer va escriure: Hi, I have a question on the performance of remoting between two appdomains running in the same process. We have developed a dynamic dll loading program (plugins) using appdomains and assemblies and need to pass a lot of data between the two plugins. We are passing image data between the two plugins. The size of the data is around 250K Bytes and the transfer happens 15-30 times a second. Question: Is remoting optimized when the appdomains are created in the same process / application ? ( We are passing the objects using MarshalByRefObject) Yes. The cross-app domain channel can send information to the target domain by just copying memory. That's faster than any other IPC method. Also, if the remote methods you call use only primitive types or arrays of primitive types, the cross-app domain channel can avoid the serialization of parameters and can make a direct copy of data, which is much faster. Are the transfers the same as accessing shared memory or is the data still accessed via proxies ? Data is still accessed via proxies, because it is not possible to share managed objects between domains. If you send a MarshalByRef object you'll get a proxy to the object in the source domain. If you send a byte array of 250Kb, the target domain will get a copy of that array. Is there a big performance hit doing this in Mono ? Is there a better solution ? A solution for what? for sending information between appdomains? I don't think there isn't a better solution than remoting. Lluis. ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] ArgumentNullException Param
When I pass something into ArgumentNullException I was expecting it to show up as part of the error message. I assumed because when using NotSupportedException I know it does. What am I missing? When I call: --- throw new ArgumentNullException (Add This Message); --- I get: --- Exception System.ArgumentNullException was thrown in debuggee: Value cannot be null. BtnExceptionClick() ... --- When I call: --- throw new NotSupportedException (Add This Message); --- I get: --- Exception System.NotSupportedException was thrown in debuggee: Add This Message BtnExceptionClick() ... --- ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Is it possible to run ASP.NET from a CD?
On Wed, 19 Dec 2007 10:18:36 -0500, Joe Audette [EMAIL PROTECTED] scribbled: Hi All, Hey Joe, Was wondering if its theoretically possible to run xsp2 directly from a cd. I've seen some posts about embedding mono but don't really know what is involved. If anyone can confirm whether its possible or point me to any information that might help I'd appreciate it. What I'm thinking about is being able to run mojoportal directly from a cd probably with SQLite. Obviously it would be read only but I can see if it could be done it would be great for making demos and also maybe I could make a utility to import export from other db platforms so a site could be backed up and archived to cd in a way that you can see the site as it was at the time of backup. Is this possible? It is doable and doesn't need to be read-only (to an extent). Your live CD system would need to have a writable tmpfs mounted on the temp directory (that is, usually on /tmp), so that ASP.NET can generate and compile assemblies on the fly. Additionally, the user you would be running xsp under would need their home directory writable, so that the .wapi directory can be created and written to. You could create a user whose home would be set to /tmp, and reuse the same tmpfs for both purposes. Other than those two requirements - it should work. best regards, marek signature.asc Description: PGP signature ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] ArgumentNullException Param
On Dec 19, 2007 5:14 PM, Gavin Landon [EMAIL PROTECTED] wrote: When I pass something into ArgumentNullException I was expecting it to show up as part of the error message. I assumed because when using NotSupportedException I know it does. What am I missing? ArgumentNullException first argument must be the name of the null parameter. If you want to show up a specific error message then you must use ArgumentNullException(paramName, Your message) ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Is it possible to run ASP.NET from a CD?
On 12/19/07 Joe Audette wrote: Was wondering if its theoretically possible to run xsp2 directly from a cd. I've seen some posts about embedding mono but don't really know what is involved. If anyone can confirm whether its possible or point me to any information that might help I'd appreciate it. What I'm thinking about is being able to run mojoportal directly from a cd probably with SQLite. Obviously it would be read only but I can see if it could be done it would be great for making demos and also maybe I could make a utility to import export from other db platforms so a site could be backed up and archived to cd in a way that you can see the site as it was at the time of backup. You basically always need a ram disk, so if you setup the proper links (or mount points: there is a filesystem that allows you to view a ro filesystem as rw) you can easily do it. lupus -- - [EMAIL PROTECTED] debian/rules [EMAIL PROTECTED] Monkeys do it better ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] BSTR Marshalling in Mono
On 12/19/07 Jonathan Chambers wrote: COM Interop support in mono works pretty well for most basic uses, but has some limitations when it comes to strings. Mainly, BSTR marshalling on non-Windows platforms is just a default implementation. The problem is that most COM systems (both Mainsoft's COM and Mozilla's XPCOM) have specific requirements on strings. They need to follow a certain format (usually a length prefixed string), use special allocators/deallocators, and use the correct byte size (2-byte vs. 4-byte encoding). [...] 1. Expose some methods in the runtime so users could embed mono and adjust the BSTR marshalling behavior with callbacks. Something like mono_set_bstr_to_string_marshal, mono_set_bstr_from_string_marshal, mono_set_bstr_free. This would require users to embed mono. 2. Use the dll map in the config file to let the user specify entry points to perform BSTR marshalling. This seems a better choice than the first. There is then a technical question as to how to implement this. The second solution would be better as it doesn't force embedding mono. For this new feature, though, we'd need to be able to handle both xpcom and COM at the same time, so a global setting wouldn't be enough. Is there a way we could use to distinguish the two cases at the time we're emitting the marshaling code? As for the implementation, we could load a shared library that implements the needed bstr methods (this is indeed how I planned at the time the COM support would work), but these shared libs would need to be separate from mono, as we don't want the mono build to have to depend on xulrunner or com dev libs to be installed. Or we could see if it's possible to access the stuff we need with dlopen/dlsym directly on the xpcom/com libs and use that inside the runtime: this ahs the advantage that there is no build or runtime dependency (unless the feature is actually used at runtime) and the small drawback that the two systems are hardcoded (though we'd hope few other com-like systems will be developed). lupus -- - [EMAIL PROTECTED] debian/rules [EMAIL PROTECTED] Monkeys do it better ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Remoting performance between two appdomains( plugins) in same process/application
Hi, Thanks for the information. I assume that the CrossAppDomainChannel is setup automatically and there is nothing to do to set it up ? When we pass objects between domains it is faster to pass primitive types instead of objects that hold primitives ( image class that holds image data in a byte array) ? If so, is it a big speed up ? Thanks for your time and answers. Shawn On 19-Dec-07, at 9:47 AM, Lluis Sanchez wrote: El dc 19 de 12 del 2007 a les 09:03 -0600, en/na Shawn Schaerer va escriure: Hi, I have a question on the performance of remoting between two appdomains running in the same process. We have developed a dynamic dll loading program (plugins) using appdomains and assemblies and need to pass a lot of data between the two plugins. We are passing image data between the two plugins. The size of the data is around 250K Bytes and the transfer happens 15-30 times a second. Question: Is remoting optimized when the appdomains are created in the same process / application ? ( We are passing the objects using MarshalByRefObject) Yes. The cross-app domain channel can send information to the target domain by just copying memory. That's faster than any other IPC method. Also, if the remote methods you call use only primitive types or arrays of primitive types, the cross-app domain channel can avoid the serialization of parameters and can make a direct copy of data, which is much faster. Are the transfers the same as accessing shared memory or is the data still accessed via proxies ? Data is still accessed via proxies, because it is not possible to share managed objects between domains. If you send a MarshalByRef object you'll get a proxy to the object in the source domain. If you send a byte array of 250Kb, the target domain will get a copy of that array. Is there a big performance hit doing this in Mono ? Is there a better solution ? A solution for what? for sending information between appdomains? I don't think there isn't a better solution than remoting. Lluis. Shawn Schaerer Director of Research and Development Cogmation Robotics Inc www.cogmation.com ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Is it possible to run ASP.NET from a CD?
It is doable and doesn't need to be read-only (to an extent). Your live CD system would need to have a writable tmpfs mounted on the temp directory (that is, usually on /tmp), so that ASP.NET can generate and compile assemblies on the fly. Additionally, the user you would be running xsp under would need their home directory writable, so that the .wapi directory can be created and written to. You could create a user whose home would be set to /tmp, and reuse the same tmpfs for both purposes. Other than those two requirements - it should work. best regards, marek You basically always need a ram disk, so if you setup the proper links (or mount points: there is a filesystem that allows you to view a ro filesystem as rw) you can easily do it. lupus Thanks for the responses. By using a ram disk is it possible to run from any desktop? ie win, nix, mac? Are we talking about a bootable disk or an executable launched from disk (across platforms)? Would be great if a kit could be created that allows dropping in the web files and SQLite db file, burn to disk and go. This would be an awesome web site backup solution. Does this seem doable? Know of anyone else working on this type of project? Best, Joe On Dec 19, 2007 10:18 AM, Joe Audette [EMAIL PROTECTED] wrote: Hi All, Was wondering if its theoretically possible to run xsp2 directly from a cd. I've seen some posts about embedding mono but don't really know what is involved. If anyone can confirm whether its possible or point me to any information that might help I'd appreciate it. What I'm thinking about is being able to run mojoportal directly from a cd probably with SQLite. Obviously it would be read only but I can see if it could be done it would be great for making demos and also maybe I could make a utility to import export from other db platforms so a site could be backed up and archived to cd in a way that you can see the site as it was at the time of backup. Is this possible? Thanks, Joe -- Joe Audette Software Solutions Architect Source Tree Solutions, LLC [EMAIL PROTECTED] http://www.sourcetreesolutions.com http://www.mojoportal.com -- Joe Audette Software Solutions Architect Source Tree Solutions, LLC [EMAIL PROTECTED] http://www.sourcetreesolutions.com http://www.mojoportal.com ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Remoting performance between two appdomains( plugins) in same process/application
El dc 19 de 12 del 2007 a les 10:29 -0600, en/na Shawn Schaerer va escriure: Hi, Thanks for the information. I assume that the CrossAppDomainChannel is setup automatically and there is nothing to do to set it up ? Yes, it is setup automatically. When we pass objects between domains it is faster to pass primitive types instead of objects that hold primitives ( image class that holds image data in a byte array) ? Yes. If so, is it a big speed up ? Yes, because the whole object serialization process can be bypassed. Lluis. ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Mono.Addins in Monodoc
* Editing in the ECMA provider is hard, but Mike has a plan for that. Is there any doc or something we could review? No, we only spoke on the phone about it. The idea is that Mike wants to switch to use GtkTextView to render the documentation, and at the same time, this would allow us to implement editing very easily. Am not sure how you can block certain sections from being edited, but am sure it can be done. This is in some way (maybe not much, I dont have the numbers but just an impression) affected by the fact that in monodoc is hard to see how the contribution gets back to the contributor. The process is slow. I mean, the user cannot install new documentation (only installing a new monodoc and that is slow specially if it comes packaged in the distro) and the process to review/approve/publish new doc is also slow, making at the end that the contributor feels his contributions gets lost in the limbo (well, at least, that was what I was told several times). The way we have it now discourages contributions. Correct, there are many things that we could do to improve the pipeline for new documentation. Some of those ideas are also required for the Web edition of Monodoc. Having a hammer does not mean that everything is a nail, and for the case of documentation updating we should not start with We have Mono.Addins, now how do we do updates with it. Instead we should be thinking about creating the proper pipeline for documentation: what does it look like, what is the process, and then implement it. If the implementation would benefit from Mono.Addins, that is fine, but it should not be the driving force for it. Miguel ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] Is it possible to run ASP.NET from a CD?
Hi, Joe Audette wrote: Hi All, Was wondering if its theoretically possible to run xsp2 directly from a cd. I've seen some posts about embedding mono but don't really know what is involved. If anyone can confirm whether its possible or point me to any information that might help I'd appreciate it. What I'm thinking about is being able to run mojoportal directly from a cd probably with SQLite. Obviously it would be read only but I can see if it could be done it would be great for making demos and also maybe I could make a utility to import export from other db platforms so a site could be backed up and archived to cd in a way that you can see the site as it was at the time of backup. Is this possible? It is, but I'd rather consider employing a virtual machine for this purpose. Too much trouble for the gain. If you're still interested: see mkbundle. Robert ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] BSTR Marshalling in Mono
On Dec 19, 2007 11:05 AM, Paolo Molaro [EMAIL PROTECTED] wrote: On 12/19/07 Jonathan Chambers wrote: COM Interop support in mono works pretty well for most basic uses, but has some limitations when it comes to strings. Mainly, BSTR marshalling on non-Windows platforms is just a default implementation. The problem is that most COM systems (both Mainsoft's COM and Mozilla's XPCOM) have specific requirements on strings. They need to follow a certain format (usually a length prefixed string), use special allocators/deallocators, and use the correct byte size (2-byte vs. 4-byte encoding). [...] 1. Expose some methods in the runtime so users could embed mono and adjust the BSTR marshalling behavior with callbacks. Something like mono_set_bstr_to_string_marshal, mono_set_bstr_from_string_marshal, mono_set_bstr_free. This would require users to embed mono. 2. Use the dll map in the config file to let the user specify entry points to perform BSTR marshalling. This seems a better choice than the first. There is then a technical question as to how to implement this. The second solution would be better as it doesn't force embedding mono. For this new feature, though, we'd need to be able to handle both xpcom and COM at the same time, so a global setting wouldn't be enough. Is there a way we could use to distinguish the two cases at the time we're emitting the marshaling code? Only by flagging the types (at the class/interface level) with some sort of attribute. [ComSystem(XPCOM)] or something like that. As for the implementation, we could load a shared library that implements the needed bstr methods (this is indeed how I planned at the time the COM support would work), but these shared libs would need to be separate from mono, as we don't want the mono build to have to depend on xulrunner or com dev libs to be installed. Or we could see if it's possible to access the stuff we need with dlopen/dlsym directly on the xpcom/com libs and use that inside the runtime: this ahs the advantage that there is no build or runtime dependency (unless the feature is actually used at runtime) and the small drawback that the two systems are hardcoded (though we'd hope few other com-like systems will be developed). This would work, as I think we would only need a few entry points. COM strings are well defined, but I am not so sure about XPCOM. I think they have a variety of strings, and least historically. Some are not simple strings, but C++ classes AFAIK. I'll work up a patch and send something in. Thanks, Jonathan lupus -- - [EMAIL PROTECTED] debian/rules [EMAIL PROTECTED] Monkeys do it better ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] FW: [Bug 349875] DictionaryTKey, TValue stores values out of order.
Hi Josh, Mono is support to follow the MS .net _design_ not the _implementation_. If the docs don't state that you can depend on the order of the elements, you shouldn't do so. I consider an app relying on this order to be buggy. - Juraj PS: please always send a copy of such mails to the mailing lists. Others might be interested. On Wed, 2007-12-19 at 14:09 -0500, Josh Mouch wrote: Isn't mono supposed to mimic MS .Net behavior? Josh -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 19, 2007 2:07 PM To: [EMAIL PROTECTED] Subject: [Bug 349875] DictionaryTKey, TValue stores values out of order. https://bugzilla.novell.com/show_bug.cgi?id=349875 User [EMAIL PROTECTED] added comment https://bugzilla.novell.com/show_bug.cgi?id=349875#c1 Juraj Skripsky [EMAIL PROTECTED] changed: What|Removed |Added CC||[EMAIL PROTECTED] Status|NEW |RESOLVED Resolution||INVALID --- Comment #1 from Juraj Skripsky [EMAIL PROTECTED] 2007-12-19 12:06:33 MST --- According to MS.NET docs, this behavior is perfectly fine for the Values property (see http://msdn2.microsoft.com/en-us/library/ekcfxy3x.aspx): The order of the values in the Dictionary(Of (TKey, TValue))..::.ValueCollection is unspecified, but it is the same order as the associated keys in the Dictionary(Of (TKey, TValue))..::.KeyCollection returned by the Keys property. As for the enumeration of the Dictionary'2 itself, the documentation does not state a required ordering of the returned elements. Setting to resolved/fixed. Please reopen if the docs support your claim. ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] 1.2.6 on mac
David, http://lists.ximian.com/pipermail/mono-list/2007-December/037244.html -g On 19-Dec-07, at 9:04 AM, David Suarez wrote: Hi, I'm trying a simple winforms app on macosx (tiger), just a form with a picture box inside, with the latest 1.2.6 installer. It keeps saying that it can't open display (X-Server required...). I understand there is a new native driver for winforms on mac on 1.2.6, is there any setting to activate it? I previously had an older mono version, maybe it is getting settings from that? Cheers, David www.plasticscm.com ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] FW: [Bug 349875] DictionaryTKey, TValue stores values out of order.
You're right, it's just the definition of (specified) behavior that we don't agree on. MS left out any ordering guarantees for Dictionary'2 on purpose. Specifying an order would have opened a very nasty can of worms. What would be the expected order after adding the keys 1, 2, 3, then removing 2 and then adding 4? 1-3-4 or 1-4-3? Thanks anyway for filling the bug report! Even if it wasn't really a bug, it's good to have as many people as possible testing and questioning the correctness of Mono. - Juraj On Wed, 2007-12-19 at 14:40 -0500, Josh Mouch wrote: I recall reading somewhere that when possible, mono will try to mimic the behavior of .Net, to make it easier for people to migrate from the later to the former. I can't find that reference now, so maybe it's all in my head. :) -Original Message- From: Juraj Skripsky [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 19, 2007 2:17 PM To: Josh Mouch Cc: mono-devel-list@lists.ximian.com Subject: Re: FW: [Bug 349875] DictionaryTKey, TValue stores values out of order. Hi Josh, Mono is support to follow the MS .net _design_ not the _implementation_. If the docs don't state that you can depend on the order of the elements, you shouldn't do so. I consider an app relying on this order to be buggy. - Juraj PS: please always send a copy of such mails to the mailing lists. Others might be interested. On Wed, 2007-12-19 at 14:09 -0500, Josh Mouch wrote: Isn't mono supposed to mimic MS .Net behavior? Josh -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 19, 2007 2:07 PM To: [EMAIL PROTECTED] Subject: [Bug 349875] DictionaryTKey, TValue stores values out of order. https://bugzilla.novell.com/show_bug.cgi?id=349875 User [EMAIL PROTECTED] added comment https://bugzilla.novell.com/show_bug.cgi?id=349875#c1 Juraj Skripsky [EMAIL PROTECTED] changed: What|Removed |Added CC| |[EMAIL PROTECTED] Status|NEW |RESOLVED Resolution| |INVALID --- Comment #1 from Juraj Skripsky [EMAIL PROTECTED] 2007-12-19 12:06:33 MST --- According to MS.NET docs, this behavior is perfectly fine for the Values property (see http://msdn2.microsoft.com/en-us/library/ekcfxy3x.aspx): The order of the values in the Dictionary(Of (TKey, TValue))..::.ValueCollection is unspecified, but it is the same order as the associated keys in the Dictionary(Of (TKey, TValue))..::.KeyCollection returned by the Keys property. As for the enumeration of the Dictionary'2 itself, the documentation does not state a required ordering of the returned elements. Setting to resolved/fixed. Please reopen if the docs support your claim. ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] r91443 broke Windows build
Thank. As far as I know Windows signals a thread only when it is terminated. So the code should be implemented on Windows by terminating the thread if that is possible. Kornél - Original Message - From: Mark Probst [EMAIL PROTECTED] To: Kornél Pál [EMAIL PROTECTED] Cc: mono-devel-list@lists.ximian.com Sent: Tuesday, December 18, 2007 3:27 PM Subject: Re: [Mono-dev] r91443 broke Windows build Hey Kornél! r91443 broke Windows build: /mono/mono/mono/metadata/threads.c:2526: undefined reference to `__wapi_thread_signal_self' /mono/mono/mono/metadata/threads.c:2543: undefined reference to `__wapi_thread_signal_self' http://lists.ximian.com/pipermail/mono-patches/2007-December/106312.html I don't know whether this code is required on Windows but __wapi_thread_signal_self shoul not be used on Windows as it is an io-layer helper function. I've disabled this in SVN for Win32 for the time to fix the build. Mark ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] ArgumentNullException Param
Ok, thank, I guess I don't understand why there is a string param that doesn't seem to do anything. Every site I went too, said nothing about a second param. Not really a mono issue though. I see it works too, thanks again. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Cedric Vivier Sent: Wednesday, December 19, 2007 10:20 AM To: Gavin Landon Cc: mono-devel-list@lists.ximian.com Subject: Re: [Mono-dev] ArgumentNullException Param On Dec 19, 2007 5:14 PM, Gavin Landon [EMAIL PROTECTED] wrote: When I pass something into ArgumentNullException I was expecting it to show up as part of the error message. I assumed because when using NotSupportedException I know it does. What am I missing? ArgumentNullException first argument must be the name of the null parameter. If you want to show up a specific error message then you must use ArgumentNullException(paramName, Your message) ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] FW: [Bug 349875] DictionaryTKey, TValue stores values out of order.
Shouldn't the stack order always be first in first out? So with your example 1-2-3, remove 2, add 4, you would end up with 1-3-4. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Juraj Skripsky Sent: Wednesday, December 19, 2007 1:54 PM To: Josh Mouch Cc: mono-devel-list@lists.ximian.com Subject: Re: [Mono-dev] FW: [Bug 349875] DictionaryTKey,TValue stores values out of order. You're right, it's just the definition of (specified) behavior that we don't agree on. MS left out any ordering guarantees for Dictionary'2 on purpose. Specifying an order would have opened a very nasty can of worms. What would be the expected order after adding the keys 1, 2, 3, then removing 2 and then adding 4? 1-3-4 or 1-4-3? Thanks anyway for filling the bug report! Even if it wasn't really a bug, it's good to have as many people as possible testing and questioning the correctness of Mono. - Juraj On Wed, 2007-12-19 at 14:40 -0500, Josh Mouch wrote: I recall reading somewhere that when possible, mono will try to mimic the behavior of .Net, to make it easier for people to migrate from the later to the former. I can't find that reference now, so maybe it's all in my head. :) -Original Message- From: Juraj Skripsky [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 19, 2007 2:17 PM To: Josh Mouch Cc: mono-devel-list@lists.ximian.com Subject: Re: FW: [Bug 349875] DictionaryTKey, TValue stores values out of order. Hi Josh, Mono is support to follow the MS .net _design_ not the _implementation_. If the docs don't state that you can depend on the order of the elements, you shouldn't do so. I consider an app relying on this order to be buggy. - Juraj PS: please always send a copy of such mails to the mailing lists. Others might be interested. On Wed, 2007-12-19 at 14:09 -0500, Josh Mouch wrote: Isn't mono supposed to mimic MS .Net behavior? Josh -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 19, 2007 2:07 PM To: [EMAIL PROTECTED] Subject: [Bug 349875] DictionaryTKey, TValue stores values out of order. https://bugzilla.novell.com/show_bug.cgi?id=349875 User [EMAIL PROTECTED] added comment https://bugzilla.novell.com/show_bug.cgi?id=349875#c1 Juraj Skripsky [EMAIL PROTECTED] changed: What|Removed |Added -- -- CC| |[EMAIL PROTECTED] Status|NEW |RESOLVED Resolution| |INVALID --- Comment #1 from Juraj Skripsky [EMAIL PROTECTED] 2007-12-19 12:06:33 MST --- According to MS.NET docs, this behavior is perfectly fine for the Values property (see http://msdn2.microsoft.com/en-us/library/ekcfxy3x.aspx): The order of the values in the Dictionary(Of (TKey, TValue))..::.ValueCollection is unspecified, but it is the same TValueorder as the associated keys in the Dictionary(Of (TKey, TValue))..::.KeyCollection returned by the Keys property. As for the enumeration of the Dictionary'2 itself, the documentation does not state a required ordering of the returned elements. Setting to resolved/fixed. Please reopen if the docs support your claim. ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
[Mono-dev] Config file w/ mkbundle
I wish to use a config file with a bundled app... how is that done? How is the config file named? Can the config file be bundled? For example, if the original app is original.exe and the bundled app is bundled.exe, what should the config file be named? Thanks!! Ricardo Ruiz, Development Ignite Technologies 3211 Internet Blvd., Suite 300 Frisco, Texas 75034 Phone - 972.348.6429 [EMAIL PROTECTED] ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list
Re: [Mono-dev] mono/mini/driver.c patch for RHEL3 compatability
--- mono/mini/driver.c 2007-12-19 15:04:53.0 -0800 +++ mono/mini/patched-driver.c 2007-12-19 15:05:20.0 -0800 @@ -706,8 +706,16 @@ #if HAVE_SCHED_SETAFFINITY if (getenv (MONO_NO_SMP)) { +# ifdef GLIBC_RHEL3_SCHED_SETAFFINITY +cpu_set_t proc_mask; +CPU_ZERO(proc_mask); +CPU_SET(0, proc_mask); + +sched_setaffinity (getpid(), proc_mask); You sure sched_setaffinity takes only two parameters. I feel the issue is not in here but in glibc. Man page point to 3 parameters and /usr/include/sched.h has a wrong declaration. Thanks, Vadiraj ___ Mono-devel-list mailing list Mono-devel-list@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-devel-list