Compare commits

..
Author SHA1 Message Date
Zoltan Varga 7eabd11bb0 Fix regressions caused by the llvmonly changes so normal aot/full-aot works again. 2015-10-08 22:43:27 -04:00
Zoltan Varga 46c4f4e658 Avoid passing the ex_tag around when throwing exceptions, simply throw a NULL value of the same type caught by the landing pads in the generated code. 2015-10-08 22:43:26 -04:00
Zoltan Varga 631e2f1a00 Avoid installing an unhandled exception handler in every method. 2015-10-08 22:43:26 -04:00
Zoltan Varga 7af3ca709a Disable SIMD when using llvm only. 2015-10-08 22:43:26 -04:00
Zoltan Varga 25cd4c6d28 Emulate ckfinite in llvmonly mode. Implement support for tail calls and wrapped exceptions. 2015-10-08 22:43:26 -04:00
Zoltan Varga b4fbc75c87 Make parts of the jit c++ clean. 2015-10-08 22:43:25 -04:00
Zoltan Varga 6bd9698f90 More nesting issues with EH clauses. Fix stack traces. 2015-10-08 22:43:25 -04:00
Zoltan Varga d0852b5ec9 Fix a crash if an assembly contains no EH. 2015-10-08 22:43:25 -04:00
Zoltan Varga 16da48a5d1 Implement mono_raise_exception () for LLVM. 2015-10-08 22:43:24 -04:00
Zoltan Varga 692cf48e88 Avoid sorting the clauses, they are already sorted in the proper order. 2015-10-08 22:43:24 -04:00
Zoltan Varga 0a9b468aa9 Fix the matching of exceptions in llvmonly mode. Add a new AOT_JIT_INFO patch type which resolves to the MonoJitInfo of the current method, pass that instead of aot_module+method_index to mono_llvm_match_exception (). Save the il clause offsets into the AOT image so they can be accessed from a MonoJitInfo. 2015-10-08 22:43:24 -04:00
Zoltan Varga 07b4db9017 Add a fixme for virtual generic calls. 2015-10-08 22:43:23 -04:00
Zoltan Varga 1a20b681d8 Properly initialize the grouped_clauses array. 2015-10-08 22:43:23 -04:00
Alexander Kyte 6b650a9f1d [runtime] Make sure that the group index is available to the runtime
This commit also partitions the handler groups in a new manner,
in order to allow a fix for nesting and finally clause interaction
2015-10-08 22:43:23 -04:00
Zoltan Varga 378e0abb3b Avoid creating jump trampolines in llvmonly mode. 2015-10-08 22:43:23 -04:00
Zoltan Varga d355acfacb Fix llvmonly support in mono_arch_create_specific_trampoline. 2015-10-08 22:43:22 -04:00
Zoltan Varga c346db8d73 Check for missing methods in llvmonly mode in mini.c, not in aot-runtime.c. 2015-10-08 22:43:22 -04:00
Zoltan Varga b4c97faeb2 Remove empty phi nodes, this can happen if all their inputs are dead. 2015-10-08 22:43:22 -04:00
Zoltan Varga 8fc2188b4f Avoid generating OP_ATOMIC_LOAD/OP_ATOMIC_STORE opcodes in llvm mode. 2015-10-08 22:43:21 -04:00
Zoltan Varga 5622e075d4 Fix the LLVM_FAILURE message on OP_ATOMIC_STORE opcodes. 2015-10-08 22:43:21 -04:00
Zoltan Varga 4f6c751686 Fix the --aot=full support. 2015-10-08 22:43:21 -04:00
Zoltan Varga 8f0ff5cf92 Remove optimization flags from LLVM_CXXFLAGS. 2015-10-08 22:43:21 -04:00
Zoltan Varga 7e36ece329 Avoid an assert when looking up some trampolines. 2015-10-08 22:43:20 -04:00
Alexander Kyte 6c4958bdab [runtime] Don't load exception trampolines if compiling with llvmonly 2015-10-08 22:43:20 -04:00
Alexander Kyte f4fa4d972c [runtime-llvmonly] Added support for SSE instructions 2015-10-08 22:43:20 -04:00
Alexander Kyte 8c00e55a5e [runtime][llvmonlyexceptions] Used correct preprocessor symbol for llvmonly try tracking. 2015-10-08 22:43:20 -04:00
Alexander Kyte a82cb56cee [runtime][llvmonlyexceptions] Fixed whitespace mentioned in code review 2015-10-08 22:43:19 -04:00
Alexander Kyte 401c71a14c [runtime][llvmonlyexceptions] Fixed visibility of unhandled exception handler 2015-10-08 22:43:19 -04:00
Zoltan Varga c447b2d2e2 Implement the throwing of corlib exceptions. 2015-10-08 22:43:19 -04:00
Zoltan Varga d17d480e6e Implement Assembly.GetExecutingAssembly () as an intrinsics so it works even if stack walks are not available. 2015-10-08 22:43:18 -04:00
Zoltan Varga 64a2c9c63e Avoid emitting calls to the llvm.mono.load/store intrinsics in llvmonly mode. 2015-10-08 22:43:18 -04:00
Zoltan Varga 68a5c78530 Avoid disabling llvm for methods with an lmf. 2015-10-08 22:43:18 -04:00
Zoltan Varga 121b785822 Avoid falling back to the jit in llvmonly mode. 2015-10-08 22:43:18 -04:00
Zoltan Varga bc6adcd1e2 [llvm] Emit an unreachable instruction after llvm throws. 2015-10-08 22:43:17 -04:00
Zoltan Varga 51043e862c [runtime] Merge origin/kyte/llvmonly-exceptions-pr. 2015-10-08 22:43:17 -04:00
Zoltan Varga b2a5a4898b Remove the REALLY_LLVONLY flag, enable it by default. Use stock clang for compiling and linking llvm code. 2015-10-08 22:43:17 -04:00
Zoltan Varga 3dd36f41ee Fix a merge problem. 2015-10-08 22:41:37 -04:00
Zoltan Varga 970d5b59be Fix the REALLY_LLVMONY mode. 2015-10-08 22:41:37 -04:00
Zoltan Varga 5d3f7ac859 Fix merge and other problems. 2015-10-08 22:41:37 -04:00
Zoltan Varga 47dab6ad7a Disable REALLY_LLVM_ONLY by default. 2015-10-08 22:41:36 -04:00
Zoltan Varga 725d4085b1 Various hacks to make hello world run with only llvm code. Define REALLY_LLVMONLY_MODE at the top of mini.h to enable it. 2015-10-08 22:41:36 -04:00
Zoltan Varga 10dc97620f Fix support for generic virtual calls. 2015-10-08 22:41:36 -04:00
Zoltan Varga b3e71e7157 Parallelize the generation of aot images for make llvmonlycheck. 2015-10-08 22:41:35 -04:00
Zoltan Varga 77e6d06233 Pass the rgctx argument last, instead of first, because determining its ordering wrt to the 'this' and 'vret' arguments is very complicated. 2015-10-08 22:41:35 -04:00
Zoltan Varga bfbad592d6 Fix interface calls on a null receiver and virtual generic calls. 2015-10-08 22:41:35 -04:00
Zoltan Varga cad4712a63 Enable explicit-null-checks in llvm-only mode by default. 2015-10-08 22:41:35 -04:00
Zoltan Varga 07c5da1a35 Avoid an llvm assertion. 2015-10-08 22:41:34 -04:00
Zoltan Varga 84bd525240 Fix the build. 2015-10-08 22:41:34 -04:00
Zoltan Varga 93ce988348 Fix the build. 2015-10-08 22:41:34 -04:00
Zoltan Varga 6a25edc864 Enable support for more ldvirtftn+delegate creation cases. 2015-10-08 22:41:33 -04:00
Zoltan Varga 75f2c706a3 Fix the case when mono_method_needs_static_rgctx_invoke () returns TRUE, but we're using an instance which doesn't have an rgctx argument. 2015-10-08 22:41:33 -04:00
Zoltan Varga 896d81c44f Fix support for ldvirtftn+delegate creation. 2015-10-08 22:41:33 -04:00
Zoltan Varga 975fae6651 Add support for delegates which call methods which require an rgctx argument. 2015-10-08 22:41:33 -04:00
Zoltan Varga e24df1e3eb Avoid using the mono calling conv in llvm-only mode. Avoid emitting a dummy personality function. 2015-10-08 22:41:32 -04:00
Zoltan Varga 59796ef00a Ad support for iface calls which might go to methods which need an rgctx. 2015-10-08 22:41:32 -04:00
Zoltan Varga 3d163ada67 A bunch of hacks to compile llvm code using clang instead of opt/llc. 2015-10-08 22:41:32 -04:00
Zoltan Varga e989c82094 Pass the rgctx argument to gshared methods explicitly instead of in a non-abi register. Delegates don't yet work. 2015-10-08 22:41:31 -04:00
Zoltan Varga 83ee193357 Add a llvm_only flag to MonoCompile and use that instead of cfg->flags which means something else. 2015-10-08 22:41:31 -04:00
Zoltan Varga 410347c18a Avoid creating jump trampolines and delegate trampolines in llvm-only mode. 2015-10-08 22:41:31 -04:00
Zoltan Varga a857491fc0 Disable stack overflow trampolines in llvm-only mode. 2015-10-08 22:41:30 -04:00
Zoltan Varga 9efa0b678a Avoid creating plt entries for empty plt sections. 2015-10-08 22:41:30 -04:00
Zoltan Varga 32cbaf3638 Disable the dyn call runtime invoke code in llvm-only mode. 2015-10-08 22:41:30 -04:00
Zoltan Varga bab77afcb0 Disable the usage of delegate trampolines in llvm-only mode. 2015-10-08 22:41:30 -04:00
Zoltan Varga 00e784b663 Properly inflate methods called from llvm code without trampolines. 2015-10-08 22:41:29 -04:00
Zoltan Varga 37e4dd280e Avoid emitting symbols for jitted code if all methods were compiled by llvm. 2015-10-08 22:41:29 -04:00
Zoltan Varga 9b4561238f Don't put references to LLVM compiled methods into the method_addresses table, its not needed. 2015-10-08 22:41:29 -04:00
Zoltan Varga 7341e647ac Implement virtual/interface calls by calling a jit icall to resolve the method to be called. 2015-10-08 22:41:29 -04:00
Zoltan Varga 39e1ede78d Implement unbox trampolines for llvm compiled methods in llvm as functions which do a tail call to the real method. 2015-10-08 22:41:28 -04:00
Zoltan Varga 37712cfb74 Move the lookup of llvm compiled methods into a generated llvm function. 2015-10-08 22:41:28 -04:00
Zoltan Varga 09c0f42506 Implement rgctx fetches by calling a JIT icall. 2015-10-08 22:41:28 -04:00
Zoltan Varga 86fc39f790 Implement support for self-initialization in methods, i.e. methods which initialize themselves instead of depending on plt entries to do it. 2015-10-08 22:41:27 -04:00
Zoltan Varga 2a20f3f538 Add a GOT entry pointing to the AOT module. 2015-10-08 22:41:27 -04:00
Zoltan Varga 015afbcc2a Temporarily disable running opt. 2015-10-08 22:41:27 -04:00
Zoltan Varga fd8c505003 Add an 'llvmonlycheck' makefile target to run the jit tests in llvm-only mode. 2015-10-08 22:41:27 -04:00
Zoltan Varga 54c9545765 Add 'llvmonly' aot option and a corresponding --llvmonly runtime option, these are extensions of full-aot. 2015-10-08 22:41:26 -04:00
Ludovic Henry 6f8078df33 [process] Fix race between Exited and OutputDataReceived/ErrorDataReceived
Because the previous implementation of the Exited would not wait on
async_output and async_error to complete before calling the Exited event
that would lead to race condition (observable in the test-runner).

The previous implementation was using the
ThreadPool.RegisterWaitForSingleObject method which, in the case of
Mono, would simply enqueue a work item that would wait on this handle.
So instead of monopolizing a ThreadPool thread for that, we create a
dedicated one that simply call WaitForExit.
2015-10-08 23:23:13 +01:00
Zoltan Varga cbde7a8991 Merge pull request #2116 from cmp-/fix-sdb-trampoline-windows-x64
Fix sdb trampoline on Windows x64
2015-10-08 16:40:53 -04:00
Mark Probst 6de8d43e54 Merge pull request #2114 from cmp-/fix-sgen-gchandle-truncation-windows-x64
Fix sgen gchandle truncating pointers on Windows x64
2015-10-08 12:53:16 -07:00
Alexis Christoforides bc9d5d113a Merge pull request #1949 from lewurm/fixtype
[mono-config] use right type for result of strlen
2015-10-08 15:27:12 -04:00
Marek Safar 820b140a19 Merge pull request #2117 from Numpsy/ObjectSecurity
Add stub implementation of System.DirectoryServices.DirectoryEntry.Ob…
2015-10-08 20:06:49 +02:00
cmp 98ff7adfc7 Fix sdb trampoline on Windows x64
On Windows x64 (and possibly other x64 systems) the offset between code
and the called function can be larger than 32 bits, but amd64_call_code
is just a wrapper around x86_call_code.
2015-10-08 18:49:30 +01:00
Richard Webb d573d5034b Add stub implementation of System.DirectoryServices.DirectoryEntry.ObjectSecurity property
Add stub implementation of
System.DirectoryServices.DirectoryEntry.ObjectSecurity property (throws
on access)
2015-10-08 17:34:47 +01:00
Marek Safar a4c91bbedf [mcs] Resolve target before resolving collection/dictionary initializers. Fixes #34604 2015-10-08 15:04:45 +02:00
Ludovic Henry e45764dbe3 [threadpool-ms] Refactor thread parking
Use a global condition variable as opposed to one per parked thread.
This remove any memory passed to the interrupt token, as this could be
an issue.

The problem comes from the fact that a destroy on a cond variable could
make a wait on this cond variable fail with EINVAL, and this would
trigger an assertion in the mono-mutex code.
2015-10-08 09:57:19 +01:00
Sebastien Pouliot 778adf0769 [linker] Both the TypeSpecification (T) along with the GenericArguments (G) must be preserved from custom attributes, e.g. T<G> 2015-10-07 20:55:27 -04:00
cmp 77f40f0709 Fix sgen gchandle truncating pointers on Windows x64
On Windows x64 sizeof(unsigned long) == 4, so & ~3UL ends up truncating
the upper 32 bits of the pointer.
2015-10-07 20:41:31 +01:00
Ludovic Henry 0205c40d9b [test] The process output/error is finished only when null is passed 2015-10-07 19:40:17 +01:00
Ludovic Henry e3062c86b8 [corlib] Rework some test to avoid unhandled and swallowed exception
These tests could fail randomly (timing issues) and this would lead to
unhandled exceptions. By using Task, instead of the ThreadPool directly,
we avoid these cases. We also ensure to wait for these tasks so we get
the test failing at the right moment and place.
2015-10-07 12:33:05 +01:00
Ludovic Henry 4f38a23473 [threadpool-ms] Remove recursivity of active_threads_lock
There was a recursive lock because of the interaction between
worker_kill and work_wait_interrupt, but as a matter of fact it is not
needed. This is because we cannot have an interrupt token with
worker_wait_interrupt, and the current thread in active_threads at
the same time.
2015-10-07 11:45:00 +01:00
Rodrigo Kumpera a9d0971711 [Facades] Add reflection Facades back to xammac. XM 2.4.0 shipped them so we can't just drop them now. 2015-10-06 18:13:15 -04:00
João Matos 29f78080d7 Merge pull request #2112 from madewokherd/lowercaseinclude
Standardize on lower-case names for Windows include files.
2015-10-06 22:44:16 +01:00
Vincent Povirk b1f39fac1d Standardize on lower-case names for Windows include files.
This is needed for mingw builds on Linux.
2015-10-06 16:41:00 -05:00
Zoltan Varga 60cab7008b [runtime] Fix the handling of large allocation sizes in Marshal.AllocHGlobal/ReAllocHGlobal. Fixes #34382. 2015-10-06 13:41:32 -04:00
triton 020a7c6844 [runtime] Fixed the MSVC build. 2015-10-06 15:59:36 +01:00
Rodrigo Kumpera 4fd923b04b Merge pull request #1978 from ludovic-henry/coop-interrupt
[socket] Enable Thread.Abort on blocking syscall
2015-10-06 10:41:50 -04:00
Rodrigo Kumpera 7aae649458 Merge pull request #2060 from ludovic-henry/socket-rework-async
[socket] Complete refactor of Begin/End and Async
2015-10-06 10:40:47 -04:00
Rodrigo Kumpera e6ad2dc73b Merge pull request #2110 from ludovic-henry/threadpool-exit-worker
[threadpool-ms] Exit worker thread after 5 to 60 seconds
2015-10-06 10:19:19 -04:00
Ludovic Henry 11096e3733 [socket] Enable Thread.Abort on blocking syscall
By installing interrupt token around the blocking syscalls, we make it possible to abort them with signals.

Previously, the only way to interrupt a blocking syscall, would have been to dispose of the SafeSocketHandle associated to the socket. But that make it impossible to abort the following case:
 - thread T1 accept a socket S and launch T2 (as a background thread) to receive on S
 - T2 block on receive
 - T1 (the main thread) quit, and the shutdown code try to abort T2

T2 would never be aborted, because S would never return from its blocking syscall, and that's because T2:
 - would still have a reference to S, making it impossible to call the finalizer on S
 - will not call Dispose on S before returning from the blocking syscall

This fixes the hang observed on System.Net.HttpWebRequestTest.GetRequestStream with the cooperative GC.
2015-10-06 14:48:22 +01:00
Ludovic Henry 388b958c34 [runtime] Cleanup of mono_unhandled_exception 2015-10-06 14:31:42 +01:00
Ludovic Henry 22f0f1596b [threadpool-ms] Exit worker thread after 5 to 60 seconds
The timeout before exiting a worker thread is random to limit the worst case scenario where, if the timeout is set to N seconds, the user would launch a lot of work item simultaneously, at an interval of N + 1 seconds. In this case, we would have to kill all the threads at once, and starts them all over again 1 second later. The randomization makes the creation and destruction more linear in time, and avoid burst.
2015-10-06 14:29:06 +01:00
Ludovic Henry 0056f1ff01 [System] Make process pipe creation exception more verbose 2015-10-06 14:21:43 +01:00
Marek Safar 043651021b [mdoc] Update expected results due to 3156d1b05d 2015-10-06 13:43:36 +02:00
Marek Safar 4164d9fbe1 [xbuild] Make ToolsVersion 14.0 targeting 4.5.* frameworks work 2015-10-06 13:17:50 +02:00
João Matos 7cb8061fa3 Fixed HttpWebRequestTest to compile with mobile NUnit.
Fixes an error in the mono-master-monodroid lane.

[9:24:52] Errors:
[9:24:52] 
[9:24:52] /Users/builder/data/lanes/1845/aa3aab5f/source/monodroid/tests/bcl-test/BclTests.sln (default targets) ->
[9:24:52] (Build target) ->
[9:24:52] /Users/builder/data/lanes/1845/aa3aab5f/source/monodroid/tests/bcl-test/BclTests.csproj (default targets) ->
[9:24:52] /Library/Frameworks/Mono.framework/Versions/4.2.0/lib/mono/4.5/Microsoft.CSharp.Targets (CoreCompile target) ->
[9:24:52] 
[9:24:52] 	src/System/Test/System.Net/HttpWebRequestTest.cs(2336,13): error CS0117: `NUnit.Framework.Assert' does not contain a definition for `Greater'
[9:24:52] 
[9:24:52] 	 13 Warning(s)
[9:24:52] 	 1 Error(s)
2015-10-06 12:05:34 +01:00
Rodrigo Kumpera aa3aab5f1e [tests] Add test for apploading related crashes due to repetitive load/unload of the same assembly.
Right there's a test for the gsharing/image set bad interaction. It doesn't crash, but produces bad pointers when under MONO_DEBUG_ASSEMBLY_UNLOAD=1
2015-10-05 18:56:14 -04:00
Rodrigo Kumpera 65c4ee6243 [runtime/appdomain] Fix a bad interaction between appdomains and generic sharing.
mini-generic-sharing.c (get_shared_gparam): This function is used to produce placeholder types
to be used in the sharing instances that are actually JIT'd.

The problem comes from creating a MonoGenericParam whose image is corlib but it's allocated on
a different image.

This becomes an issue in metadata.c:mono_metadata_get_generic_inst when computing the image set
the generic instance should live in. By setting the generic param image to corlib we effectively
lie to the ImageSet code about what are the images.

So, say we have assembly A and we call get_shared_gparam on a type on this assembly. The returned type
will be allocated on A mempool but say it belongs to corlib.

The image set for such a generic instance will be [corlib].

Now we unload A.

Now we have a MonoGenericInstance in the [corlib] mempool that points to memory in the freed
mempool of A.

The fix is to set owner to the right image whenever possible. This would have changed the image
set to [A] (or more likely, [A, corlib]). Either mempool would be freed when A is unloaded.

Testing this behavior turned out to be incredibly more complicated than expected and even though
I managed to produce a test case which has the bad pointers, I could not trigger a crash even with
MONO_DEBUG_ASSEMBLY_UNLOAD=1.
2015-10-05 18:36:44 -04:00
Ludovic Henry e5e97eafef [socket] Refactor SocketAsyncEventArgs creation 2015-10-05 18:49:19 +01:00
Ludovic Henry 801b3ffcd3 [socket] Move callbacks out of SocketAsyncEventArgs 2015-10-05 18:49:19 +01:00
Ludovic Henry cfc564182d [socket] Remove SocketAsyncCallback dead code 2015-10-05 18:49:19 +01:00
Ludovic Henry 19f7162390 [socket] Remove SocketAsyncWorker
By having the callbacks directly in Socket, we can remove the SocketAsyncWorker class. This also greatly simplify this part of the code, as the callbacks are at the same place as the Begin/End invokes.
2015-10-05 18:49:19 +01:00
Ludovic Henry d088bf0593 [socket] Remove SocketAsyncEventArgs.Dispatcher 2015-10-05 18:49:19 +01:00
Ludovic Henry cdca8cde59 [socket] Remove SocketAsyncEventArgs.Init 2015-10-05 18:49:18 +01:00
Ludovic Henry 92a980a9af [socket] Factor SocketAsyncResult and ProcessAsyncResult common parts into IOAsyncResult + Abstract IO Threadpool jobs with IOSelectorJob
This simplifies greatly the native code, as we do not need to worry anymore about all IAsyncResult related work (call the callback, set completed, etc.), and we only need to care about the handle we are watching, and the callback to call when something happens on this handle.

This is quite a big commit, but unfortunatly, it's very hard to break it down in smaller commits as everything is very interwind.
2015-10-05 18:49:18 +01:00
Marek Safar b2d198fe11 Bump reference sources 2015-10-05 16:08:54 +02:00
Marek Safar 3156d1b05d [mcs] Keep documentation formatting as was written in source code. Fixes #34409 2015-10-05 16:05:51 +02:00
Marek Safar 351eea6b9e [system.web] Expand reference source strings 2015-10-05 10:50:20 +02:00
Marek Safar 05a0da7bb3 Merge pull request #2107 from kasthack/system.web.sr
[System.Web] Generated SR class
2015-10-05 10:22:13 +02:00
Marek Safar fffd5b2221 Merge pull request #2108 from kasthack/patch-1
[System.ComponentModel.DataAnnotations] More resource strings
2015-10-05 09:48:34 +02:00
kasthack 1ce44e625d [System.ComponentModel.DataAnnotations] More resource strings 2015-10-05 00:06:28 +03:00
Rodrigo Kumpera 2a30426356 [docs] Update the man page. Remove dead env var, document a couple of GC options. 2015-10-02 17:04:45 -04:00
João Matos 4bd39a4014 Merge pull request #2103 from xen2/calli_generic
Inflate calli generic method signature even if not a wrapper
2015-10-02 15:55:23 +01:00
Virgile Bello 2a48c1550b Inflate calli generic method signature even if not a wrapper 2015-10-02 23:31:18 +09:00
Miguel de Icaza b26f789020 Merge pull request #1921 from mattzink/master
Allow disabling the mono-find-provides/requires RPM processing scripts
2015-10-01 17:44:17 -04:00
Miguel de Icaza 68d4be032a Merge pull request #2025 from sawachika-kenji/patch-1
Update FormsAuthentication.cs
2015-10-01 17:43:20 -04:00
Miguel de Icaza 7a3dff8be5 Merge pull request #2087 from joelmartinez/mdoc-membername-fixup
[mdoc] Now rewriting incorrect `MemberName`.
2015-10-01 17:40:35 -04:00
Miguel de Icaza a04b9a5d94 Merge pull request #2098 from evincarofautumn/fix-gchandle-assert
Fix assertion in mono_gchandle_get_target.
2015-10-01 17:39:43 -04:00
Miguel de Icaza fe6efaf319 [System/build] Xamarin.Mac's bare/System.dll does not compile with SECURITY_DEP, like the desktop assemblies 2015-10-01 17:31:10 -04:00
João Matos 77beb6adf4 [runtime] Fixed fast TLS detection on WatchOS. 2015-10-01 17:36:43 +01:00
Jo Shields e4cd7c692d Merge pull request #2099 from AdamBurgess/master
[Tools] Add user option to cert-sync, fix a few string formatting errors
2015-10-01 09:00:58 +01:00
Adam Burgess 0d52bb4fa6 [Tools] Add 'user' option to cert-sync
Syncs certificates with the current user's certificate store instead of the local machine's.
To be used when root is not available.
2015-10-01 01:53:08 +10:00
Adam Burgess 599483203c [Tools] Fix formatting in cert-sync 2015-10-01 01:49:18 +10:00
Miguel de Icaza da86534ee4 Move System.IO.Compression and System.IO.Compression.FileSystem from the _parallels directory to the non-parallel ones, hoping that this will fix the issue where Facades that depend on the latter are built only after those are built, currently, we break (see https://wrench.internalx.com/Wrench/WebServices/Download.aspx?workfile_id=9795720) 2015-09-30 11:07:19 -04:00
Radek Doulik d79d932a68 [linker] allow to specify filename for linker dependencies file
- also do not use the timestamp in default filename as it
   can be now done by specifying the filename if needed
2015-09-30 16:51:56 +02:00
Marcos Henrich f5eef79cd8 Merge pull request #2045 from BillSeurer/timezone
[ppc] Fix exception when reading from timezone file.
2015-09-30 15:00:15 +01:00
Marcos Henrich 96e40c5793 [System] Fixes SmtpClientTest.Deliver_Async 2015-09-30 10:44:31 +01:00
Atsushi Eno 1593ba0dce [CJK] fix bug #34059 - reviewed dead code and added some comments. 2015-09-30 10:59:09 +08:00
Alexis Christoforides 1dafd3944f [runtime] Make '--arch' more robust and OS X specific.
Also add missing man page entry.
2015-09-29 19:20:28 -04:00
Zoltan Varga 9eb534dfe9 [amd64] Fix cross compiling to amd64. 2015-09-29 18:07:36 -04:00
João Matos bd67e39f64 [arm] Clean up unused ARMv7s / ARMv7k hwcap checks. 2015-09-29 18:00:05 +01:00
Zoltan Varga 942daca38e [arm] Fix the build. 2015-09-29 12:25:32 -04:00
Alex Rønne Petersen 6ed9e24d22 Merge pull request #2086 from BillSeurer/testcases
[ppc] Updated ELF ABI v2 test cases to include returning structures f…
2015-09-29 18:21:26 +02:00
Ludovic Henry b13ad263cd [corlib] Fix dispose race condition in CancellationTokenSource
The race condition would manifest in the following code:

```
for (int i = 0, total = 100000; i < total; ++i) {
    if (i % 50 == 0)
            Console.WriteLine ("{0}/{1}", i, total);

    var c1 = new CancellationTokenSource ();
    var wh = c1.Token.WaitHandle;
    c1.CancelAfter (1);
    Thread.Sleep (1);
    c1.Dispose ();
}
```

And we would observe the following exception:
```
Unhandled Exception: System.ObjectDisposedException: Cannot access a disposed object.
Object name: 'System.Threading.ManualResetEvent'.
 at System.Threading.WaitHandle.CheckDisposed () [0x00016] in /Users/builder/data/lanes/1196/33e00ac6/source/mono/mcs/class/corlib/System.Threading/WaitHandle.cs:426
 at System.Threading.EventWaitHandle.Set () [0x0000c] in /Users/builder/data/lanes/1196/33e00ac6/source/mono/mcs/class/corlib/System.Threading/EventWaitHandle.cs:205
 at (wrapper remoting-invoke-with-check) System.Threading.EventWaitHandle:Set ()
 at System.Threading.CancellationTokenSource.NotifyCancellation (Boolean throwOnFirstException) [0x00051] in /Users/builder/data/lanes/1196/33e00ac6/source/mono/external/referencesource/mscorlib/system/threading/CancellationTokenSource.cs:723
 at System.Threading.CancellationTokenSource.Cancel (Boolean throwOnFirstException) [0x00006] in /Users/builder/data/lanes/1196/33e00ac6/source/mono/external/referencesource/mscorlib/system/threading/CancellationTokenSource.cs:409
 at System.Threading.CancellationTokenSource.Cancel () <0x7d75ada8 + 0x00017> in <filename unknown>:0
 at System.Threading.CancellationTokenSource.TimerCallbackLogic (System.Object obj) [0x00012] in /Users/builder/data/lanes/1196/33e00ac6/source/mono/external/referencesource/mscorlib/system/threading/CancellationTokenSource.cs:538
```

This would be a race condition between the TimerCallbackLogic call to Cancel and the call to Dispose on another thread. You could trigger it more reliably by putting a Thread.Sleep at CancellationTokenSource.cs:599.

Also fixes ConcurrentCancelLinkedTokenSourceWhileDisposing race condition between Cancel and Dispose, by applying the same pattern as CancellationTokenSource.TimerCallbackLogic.
2015-09-29 16:53:20 +01:00
João Matos d1a87bcac2 [runtime] Fixed opcode emulation logic for ARMv7k. 2015-09-29 15:43:37 +01:00
João Matos a838a0ed57 [runtime] Fixed ARMv7k detection logic. 2015-09-29 15:43:21 +01:00
Marek Safar 24be79b2db Merge pull request #2096 from kasthack/system-web-more-replacements
[System.Web] Reference source import
2015-09-29 08:47:27 +02:00
Zoltan Varga bebeb2346e [arm] Use 16 byte frame alignment on watchos. 2015-09-28 21:57:12 -04:00
kasthack fc0f8a1874 [System.Web] Generated SR class 2015-09-29 04:39:11 +03:00
Zoltan Varga def8ec43d4 [amd64] Fix the msvc build. Fixes #34371. 2015-09-28 19:16:55 -04:00
Zoltan Varga 2c41b2c61a [amd64] Fix the sigctx<->monoctx conversion code to work even if MONO_SIGNAL_USE_SIGACTION is not defined. 2015-09-28 19:12:34 -04:00
kasthack 18b1d72354 [System.Web] 20 attributes from reference source 2015-09-29 02:09:35 +03:00
Zoltan Varga b6dfce621f [amd64] Transition to using trampolines to implement single stepping/breakpoints in JIT mode too. 2015-09-28 18:16:11 -04:00
João Matos ef69e582af Merge pull request #2093 from directhex/fully-qualified-masm-path
Bundle modified masm.props with fully qualified ml.exe call.
2015-09-28 22:57:47 +01:00
Alexis Christoforides a29f5292e6 [runtime] Attempt to resolve DllImport using the installation lib dir. 2015-09-28 16:24:45 -04:00
Jon Purdy c518a3e39a Fix assertion in mono_gchandle_get_target. 2015-09-28 13:18:01 -07:00
Zoltan Varga e839acd2d8 [arm] Fix another bunch of frame alignment problems. 2015-09-28 13:36:47 -04:00
Marek Habersack 95147791a5 [tests] Enable tests for xambug #28777 on Android
The issue was fixed in XA, we can enable the tests now
2015-09-28 16:37:09 +02:00
Zoltan Varga 5885624e89 [arm] Fix the unaligned stack check. 2015-09-28 10:21:40 -04:00
Zoltan Varga 627bc54a55 Revert "[jit] Add a new mono_arch_init_compile () backend function which is used to set various flags in MonoCompile. Use this instead to get rid of some of the #ifdef MONO_ARCH_.. blocks. Add a default implementation which sets the flags based on the MONO_ARCH_.. defines."
This reverts commit bc50c66303.

Revert this as it seems to break the build.
2015-09-27 14:42:56 -04:00
João Matos b7a308f660 Merge pull request #2057 from directhex/monolite-on-jenkins
Move monolite URL to Jenkins, not Boston NAS
2015-09-27 14:11:51 +01:00
Zoltan Varga bc50c66303 [jit] Add a new mono_arch_init_compile () backend function which is used to set various flags in MonoCompile. Use this instead to get rid of some of the #ifdef MONO_ARCH_.. blocks. Add a default implementation which sets the flags based on the MONO_ARCH_.. defines. 2015-09-27 01:51:26 -04:00
Zoltan Varga 90cc18a833 [jit] Remove an unused define. 2015-09-26 22:12:09 -04:00
Zoltan Varga 50d39c613d [jit] Add an arch-stubs.c file to collect the stubs for the arch specific functions not implemented by all backends. Use this to avoid #ifdefs at call sites. 2015-09-26 21:17:15 -04:00
Marek Habersack b4d5016b5e [support] Limit possible values
Value returned from the reader function can be negative and ZStream's
avail_in should not be less than 0 as that value makes no sense and
other parts of code assume it to be equal or higher than 0.
2015-09-25 21:18:22 +02:00
Zoltan Varga 7628e59f49 [jit] Fix opcode emulation registration when DISABLE_JIT is defined. 2015-09-25 13:23:02 -04:00
Zoltan Varga ee0b7ce66e [arm] Fix compilation on arm. 2015-09-25 13:22:45 -04:00
Zoltan Varga 20e909ba88 [arm] Allocate a stack frame in the generic trampoline code before making calls. Also avoid assuming that the frame alignment is 8. 2015-09-25 12:45:10 -04:00
Jo Shields 900552b7d3 Bundle modified masm.props with fully qualified ml.exe call.
In some more esoteric environments (say bash.exe spawned by
jenkins-slave.exe), the _MASM target's attempts to call ml.exe fail
due to ml.exe missing from $PATH (even when it appears to be fine).

The ClCompile target doesn't suffer this issue, since it uses the
full path to CL.exe rather than assuming CL.exe is in $PATH.
Bundle a lightly patched masm.props to duplicate the ClCompile
target behaviour.

This should have no impact on you unless for some reason you're
using a different MASM to the one provided with MSVC.
2015-09-25 09:58:34 +01:00
Marek Safar 2cc07eaa9d Merge pull request #2092 from kasthack/system-web-stuff-import
[System.Web] Reference source import
2015-09-25 08:18:19 +02:00
Zoltan Varga e14c4c70b4 [arm64] Fix MONO_CONTEXT_GET_CURRENT support on arm64. 2015-09-24 21:41:33 -04:00
Zoltan Varga 47a53dff1b Merge pull request #2091 from kumpera/tvos_context_get_current
[tvos] Implement MONO_CONTEXT_GET_CURRENT for tvos
2015-09-24 19:20:07 -04:00
Rodrigo Kumpera fd00eb1cff [coop] Make coop suspend crashes have names that can be correlated to an Apple crash dump.
Use pthread_setname_np on attach to ensure every thread has a name that Apple's crash dump recognize.

The use pthread_getname_np when doing a thread dump to ensure we get the current thread name.

This cosmetic change will allow us to use Apple crash dumps when troubleshooting suspend issues.
2015-09-24 17:59:13 -04:00
Jonathan Pryor 3f3df26945 [Mono.Posix] Fix signal tests to run on OS X, Android.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=33558

Several of the Signal-related tests were disabled when running on OS X
because OS X doesn't provide reliable delivery: it will try to deliver
a signal, but if it's already been delivered it won't continue
delivering them. This results in failures such as:

	1) MonoTests.Mono.Unix.UnixSignalTest.TestWaitAny :   Expected: 23061
	  But was:  100000

(Note that "Expected" and "actual" are reversed. Oops.)

Thus, signals are delivered, just "not enough."

As It Happens™, Android is similar: running these tests on
Xamarin.Android results in test failures because not enough signals
are received. (It's not as bad as OS X -- only ~10% off -- but it's
not *all* of the signals either.)

Fix the tests so that they *don't* require that we receive as many
signals as we raise. Instead, assert that all of the UnixSignal
instances actually have a UnixSignal.Count value greater than 0, i.e.
that they've been signaled AT ALL.

Loosening up the tests in this manner allows the tests to pass on
OS X, and should allow things to work as expected on Android.
2015-09-24 17:15:36 -04:00
Rodrigo Kumpera 118c25ad67 [tvos] Implement MONO_CONTEXT_GET_CURRENT in terms of thread_get_state. 2015-09-24 15:12:02 -04:00
Rodrigo Kumpera aeeb3e87bb [mach] Implement mono_mach_arch_thread_state_to_mono_context. 2015-09-24 15:12:02 -04:00
Rodrigo Kumpera 1f625a0769 [utils] Split the arm64 code from the arm code for the mach support code.
Now those to conform to the convention used for everything else.
2015-09-24 15:12:02 -04:00
Radek Doulik b5c06e6bab [linker] add timestamp to the linker deps filename
- and make sure we create a new stack on each dump
2015-09-24 20:32:56 +02:00
Alexis Christoforides 39fe438f07 [runtime] Add '--arch' argument 2015-09-24 14:28:04 -04:00
Zoltan Varga 359b868038 [arm] Fix the stack alignment in the prolog to work with MONO_ARCH_FRAME_ALIGNMENT values other than 8. 2015-09-24 14:09:59 -04:00
Jonathan Pryor ab2094334d Merge pull request #2084 from joelmartinez/mdoc-deletetestfix
[mdoc] Removed extraneous directory creation.
2015-09-24 13:15:14 -04:00
Jo Shields 3f2355445d Move monolite URL to mono-project.com CDN, not Boston NAS 2015-09-24 14:38:55 +01:00
João Matos 77a900a8ed Fixed Mach abort syscall code to work with Mach targets that do not support it. 2015-09-24 14:15:54 +01:00
Marek Safar 7f306ec7be [mcs] Further improvements to fixed statement changes from 4ea0fbbd44 2015-09-24 14:42:18 +02:00
Ludovic Henry 2c29b8ae21 [coop] Move syscall abort mechanism to dedicated files 2015-09-24 11:17:12 +01:00
Marek Safar 4ea0fbbd44 [mcs] Emit fixed temp variables as managed references 2015-09-24 11:59:59 +02:00
Marek Safar 417cd9eef4 [mcs] Add link to closest parent async storey only if it hold captured this. Fixes #34168 2015-09-24 09:54:57 +02:00
Marek Safar bfe00f83a1 Merge pull request #2088 from kasthack/system-web-ea-import
[System.Web] Reference source import
2015-09-24 08:31:37 +02:00
kasthack d442b89730 System.Web.Routing: RequestContext, RouteTable, RouteValueDictionary and VirtualPathData from reference source 2015-09-24 06:36:41 +03:00
kasthack 5b8a2d206c [System.Web] Public interfaces from reference source 2015-09-24 05:29:04 +03:00
Mark Probst 737ca8b888 [sgen] Fix promoted trace output. Fixes #30479. 2015-09-23 14:55:09 -07:00
Mark Probst 813a668097 Merge pull request #2073 from BrzVlad/fix-sgen
Fix sgen
2015-09-23 14:23:26 -07:00
Joel Martinez 02ddbe8b75 [mdoc] Now rewriting incorrect MemberName.
An error condition in an existing ecma xml doc set was brought to my attention
in which an exception was being raised during an `mdoc update`. The cause of this
error was due to the fact that the `GetTypeParameters` method was getting the
list of type parameters from the `MemberName` string.

This patch fixes the error condition by rewriting `MemberName` if it doesn't
match the value from the reflected member.
2015-09-23 17:15:59 -04:00
Bill Seurer 5013b989ed [ppc] Updated ELF ABI v2 test cases to include returning structures from functions 2015-09-23 15:44:24 -05:00
Rodrigo Kumpera f4255e7a9c [profiler] Add mlpd stats dumping, use --reports=stats.
This add statistical collection of mlpd files. Right now it reports basic statics on number of events
and their overhead, plus general buffer overhead.

This should enable us better understand what a file is made of when figuring out ways to optimize it.

Here's a sample output:

```
Mlpd statistics
    Buffer count 13499  overhead 647952 (48 bytes per header)

Event details:
             TYPE_GC                 TYPE_GC_EVENT  count   6313    min   4 max      8  bytes 35802
             TYPE_GC                  TYPE_GC_MOVE  count  17737    min  12 max    262  bytes 4138055
             TYPE_GC        TYPE_GC_HANDLE_CREATED  count  29833    min   6 max     14  bytes 296379
             TYPE_GC      TYPE_GC_HANDLE_DESTROYED  count   6620    min   5 max     10  bytes 42515
       TYPE_METADATA                 TYPE_END_LOAD  count  15926    min  12 max    271  bytes 1112068
         TYPE_METHOD                      TYPE_JIT  count  10246    min  26 max   1015  bytes 1043018
      TYPE_EXCEPTION                   TYPE_CLAUSE  count      2    min   6 max      6  bytes 12
      TYPE_EXCEPTION             TYPE_EXCEPTION_BT  count      2    min  50 max     50  bytes 100
           TYPE_HEAP               TYPE_HEAP_START  count      1    min   3 max      3  bytes 3
           TYPE_HEAP                 TYPE_HEAP_END  count      1    min   4 max      4  bytes 4
           TYPE_HEAP              TYPE_HEAP_OBJECT  count 284536    min   5 max    654  bytes 4823852
           TYPE_HEAP                TYPE_HEAP_ROOT  count 2508919   min  11 max    355  bytes 750970914
         TYPE_SAMPLE     TYPE_SAMPLE_COUNTERS_DESC  count      3    min 256 max   2835  bytes 3712
         TYPE_SAMPLE          TYPE_SAMPLE_COUNTERS  count   1089    min   3 max    402  bytes 66219
        TYPE_RUNTIME                TYPE_JITHELPER  count  21191    min   6 max     29  bytes 252473
```
2015-09-23 16:43:53 -04:00
Rodrigo Kumpera e2bd97b939 [profiler] Add missing constants for event subtypes. 2015-09-23 16:43:52 -04:00
triton ee28d47ab4 Workaround lack of libunwind in WatchOS.
This is a temporary workaround until get correct fix is properly tested on device.

This makes us be able to compile the runtime with the latest Xcode SDK.
2015-09-23 21:20:12 +01:00
Miguel de Icaza 12461baf50 Merge pull request #1843 from info-lvsys/patch-1
Added sha512 and sha256 ; and defaults to SHA512
2015-09-23 16:09:29 -04:00
Miguel de Icaza b16bcb6332 Merge pull request #1325 from madrang/CryptoToolsCtorCheck
Added null check in constructor of BlockProcessor in CryptoTools.
2015-09-23 16:06:59 -04:00
Miguel de Icaza 468225a247 Merge pull request #757 from mlintner/master
These changes fix 14335. When in getcontractinternal various things can ...

This patch further does not affect mobile.
2015-09-23 16:05:09 -04:00
Miguel de Icaza b34a01e4be Merge pull request #2085 from guerrysemones/master
This is a patch to fix bug 34123. System.Drawing.Printing.PrintingSer…
2015-09-23 15:55:08 -04:00
Miguel de Icaza 226af94a23 Merge pull request #1218 from AndreyAkinshin/master
Suppression of negative Elapsed in Stopwatch, this is the comment from the Reference Source:

                    // When measuring small time periods the StopWatch.Elapsed*
                    // properties can return negative values.  This is due to
                    // bugs in the basic input/output system (BIOS) or the hardware
                    // abstraction layer (HAL) on machines with variable-speed CPUs
                    // (e.g. Intel SpeedStep).
2015-09-23 15:36:55 -04:00
Miguel de Icaza 28f473c41d Merge pull request #1225 from strawd/bug22307
Fix for bug 22307 - Intermittent IndexOutOfRangeException on closing connection
2015-09-23 15:34:55 -04:00
Miguel de Icaza d07e9a199a [mono.data.sqlite] Using sqlite_close_v2 when available
From Matthew Leibowitz (mattleibo)

This is the recommended function for garbage collected languages.
http://sqlite.org/c3ref/close.html

The sqlite3_close_v2() interface is intended for use with host
languages that are garbage collected, and where the order in which
destructors are called is arbitrary.

Falls back to old sqlite3_close if we are on an old system

Useful for ADO.NET where the connection os often closed, but the
commands are re-usable

Mostly visible on Windows operating systems

This snippet should fail with a System.IO.IOException using the
current build of Mono on Windows:

    string filename = "test_" + Guid.NewGuid ().ToString ("N") + ".db";
    SqliteConnection conn = new SqliteConnection ("Data Source=" + filename);
    conn.Open ();
    SqliteCommand cmd = conn.CreateCommand ();
    cmd.CommandText = "PRAGMA legacy_file_format;";
    cmd.ExecuteScalar ();
    // close connection before the command
    conn.Dispose ();
    // then close the command
    cmd.Dispose ();
    // the locks should be released, and we should be able to delete the database
    File.Delete (filename);
2015-09-23 15:34:00 -04:00
Miguel de Icaza bbd8a21934 [API] Add a couple of .NET 4.5 methods, from pull request 641, had to apply manually 2015-09-23 15:31:00 -04:00
Zoltan Varga 0af35dd55e [bcl] Stop distributing Mono.C5, there is an updated nuget package for it, keep it for regression testing purposes. 2015-09-23 15:02:15 -04:00
Miguel de Icaza aea57f09d4 Merge pull request #853 from echampet/onclick
[FIX] correctly handle custom onclick attribute when autopostback = true...
2015-09-23 15:00:41 -04:00
Miguel de Icaza 90c68ad56a Add new test for Bug 15028, it is fixed by our migration to reference source 2015-09-23 14:56:20 -04:00
Miguel de Icaza 22448831bb Merge pull request #704 from jgagnon/master
Fix for #4938.
2015-09-23 14:42:05 -04:00
Miguel de Icaza 559ad5b34b Merge pull request #463 from strawd/concurrent-requests
Handle multiple concurrent calls to BeginTryReceiveRequest
2015-09-23 14:37:01 -04:00
guerrysemones eefcd3b42e This is a patch to fix bug 34123. System.Drawing.Printing.PrintingServicesUnix is failing to print on Mac OSX Yosemite because the CUPS function cupsTempFile now always returns an empty string. This function was deprecated. Now replacing cupsTempFile call with call to cupsTempFd to fix printing. I do not see a clear way to unit test this, and there appear to be no prior unit tests covering this. Essentially we are swapping a function call for another that returns the same type of result. This was tested on my copy of net_4_x master. The same fix could be applied to mono version 3 also. This change is released under the MIT license. 2015-09-23 13:32:46 -05:00
Miguel de Icaza d40a434c60 Merge pull request #1971 from angeloc/master
eglib: checking locale_charset function availability
2015-09-23 14:25:57 -04:00
Miguel de Icaza e2a31b6128 Merge pull request #2023 from juergenhoetzel/master
[runtime] Fix casting error in InternalCodePage.
2015-09-23 14:24:06 -04:00
Zoltan Varga b352aa9751 [arm] Fix aot support for the alignment check code. 2015-09-23 14:23:35 -04:00
Miguel de Icaza fa081c5ecd Obsolete SmtpClient 2015-09-23 14:21:51 -04:00
Joel Martinez 40b89c524d [mdoc] Removed extraneous directory creation.
This was in response to a test failure noticed after this pull request was accepted: https://github.com/mono/mono/pull/2012#commitcomment-13325966

The solution was two-fold, the code removed was unecessary as this directory is created elsewhere right before the file is written (and with the correct name in the case of a unified type). Also a small change was made to the makefile to clean up some files which was causing some targets to be skipped, along with moving some targets to the `check-doc-tools` target.
2015-09-23 14:21:13 -04:00
Miguel de Icaza b711f7731b Merge pull request #2020 from tomjepp/master
Fix bug #33551 - Use a full FQDN for EHLO and HELO in SmtpClient.
2015-09-23 14:18:36 -04:00
Zoltan Varga ae23361079 [arm] Add a stack alignment check to the prolog code, disabled by default. 2015-09-23 12:59:44 -04:00
Miguel de Icaza e976779117 Merge pull request #2059 from ermshiperete/Xamarin-33968
[MWF] Fix problem pasting text (Xamarin-33968)
2015-09-23 11:04:27 -04:00
Miguel de Icaza 6a4ba0dd1e Merge pull request #2072 from AdamBurgess/master
[System] Fix SmtpClient.SendMailAsync never completing
2015-09-23 10:59:51 -04:00
Miguel de Icaza bc06803625 Merge pull request #2080 from upsilon/fix-point-constructor
[System.Drawing] Fix Point constructor with single int parameter to correctly handle negative locations.
2015-09-23 10:59:22 -04:00
kasthack 7df2288d91 [System.Web] Public *EventArgs from reference source 2015-09-23 17:58:53 +03:00
Marek Habersack ced24f4004 [test] Fix dependency on compiler behavior for a couple of tests
A couple of tests for System.Reflection.MethodBody assumed the code generated
by the compiler will be the same as the one generated by Mono's MCS. However,
when the code is built by CSC in release mode (version that comes with VS2015
was tested) the optimizations remove locals required by the old version of the
tests. Also, CSC orders the locals differently to MCS and that breaks one of
the tests which relied on the declaration order.
Another difference is that CSC and MCS type a certain local variable differently.
The variable being a byte* in source code is output in IL as such by MCS, but CSC
outputs an int8& - a by-ref type.
The tests are built by VS but they are executed by Mono on Android and so the
differences come up as errors.
This commit fixes both issues by working around the differences.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=33370 when it is included in XA
2015-09-23 16:24:53 +02:00
João Matos 67ca203ea1 Merge pull request #2082 from akoeplinger/fix-automake
[unit-tests] Fix "parallel-tests" AUTOMAKE_OPTIONS not recognized by old automake
2015-09-23 14:47:50 +01:00
Marek Safar ce70c27a7a Merge pull request #2079 from kasthack/system-web-eh-import
[System.Web] Reference source import
2015-09-23 10:45:28 +02:00
Zoltan Varga 171cba1cee Revert "[llvm] Allow phi instructions where some incoming nodes are not defined because they are defined by dead code."
This reverts commit 1a4e073baf.

Revert this, it can lead to phi instructions with no nodes.
2015-09-22 17:29:54 -04:00
Vlad Brezae 7135e9e03c [sgen] Fix warning 2015-09-22 14:08:52 -07:00
Vlad Brezae e6b5e7d727 [sgen] Make sure we scan aligned memory regions
When we suspend a thread, the stack pointer might not be aligned.
2015-09-22 14:08:50 -07:00
Zoltan Varga 1a4e073baf [llvm] Allow phi instructions where some incoming nodes are not defined because they are defined by dead code. 2015-09-22 17:08:20 -04:00
kasthack 272033f2e2 [System.Web] Public event handlers from reference source 2015-09-22 22:56:26 +03:00
Kimura Youichi a89c01f98e [System.Drawing] Fix Point constructor with single int parameter to correctly handle negative locations. 2015-09-23 04:50:25 +09:00
Rodrigo Kumpera 23e34d77f2 [utils] Fix amd64 version of MONO_CONTEXT_GET_CURRENT.
Registers must be saved in MonoContext in the same order as mono_sigctx_to_monoctx.

This caused crashes on linux when unified suspend was enabled.
2015-09-22 15:38:43 -04:00
Ludovic Henry 4a2599720d [coop-gc] Make Thread.Sleep interruptable signalless 2015-09-22 20:22:36 +01:00
kasthack da7046ee30 [System.Web] HttpApplicationStateWrapper, HttpBrowserCapabilitiesWrapper, HttpCachePolicyWrapper and HttpSessionStateWrapper from reference source 2015-09-22 22:16:36 +03:00
Zoltan Varga fe3d2b7085 [aot] Fix a regression introduced by cc946ea5b9. 2015-09-22 14:08:09 -04:00
Zoltan Varga 6fb7ac2cb2 [jit] Fix the linking of bblocks for switch statements, previously we were linking the bblock containing the range check with the target bblocks as well, causing problems when using llvm. Fixes #34147. 2015-09-22 14:08:09 -04:00
Marek Safar 4e8470cbc0 Merge pull request #2076 from akoeplinger/fix-bootstrap
[System] Remove C#6 expression bodied property to fix bootstrapping with older mcs
2015-09-22 19:32:05 +02:00
Marek Safar 69bd371b03 Merge pull request #2075 from kasthack/system-web-import-enums
[System.Web] Public enums from reference source
2015-09-22 19:31:15 +02:00
Alexander Köplinger 35b648849d [System] Remove C#6 expression bodied property to fix bootstrapping with older mcs 2015-09-22 19:26:57 +02:00
kasthack 31682e6b04 [System.Web] Public enums from reference source 2015-09-22 18:46:35 +03:00
Ludovic Henry 9e59d35315 [socket-io] Cleanup of the code to ease switching to signalless interrupts
Also fixes a bunch of missing MONO_(PREPARE|FINISH)_BLOCKING, or remove returns between MONO_(PREPARE|FINISH)_BLOCKING
2015-09-22 15:53:53 +01:00
Ludovic Henry a710cc7293 [runtime] Fix color formatting on sublime text 2015-09-22 15:53:53 +01:00
Ludovic Henry 2c94aa738a [thread] Remove parameter as we always pass the current one 2015-09-22 15:53:53 +01:00
Ludovic Henry 17f16e120a [thread] Remove duplicate and unused function declaration 2015-09-22 15:53:53 +01:00
Alexander Köplinger 7f74e25826 [unit-tests] Fix "parallel-tests" AUTOMAKE_OPTIONS not recognized by old automake
automake 1.13 introduced the flag as default, in 5ad2890c I explicitly set it via AUTOMAKE_OPTIONS
to ensure Jenkins (which is on automake 1.11 on some builders) has the same behavior.

Turns out that the flag isn't recognized by automake versions below 1.11 and so the build fails there.

To fix the problem, remove AUTOMAKE_OPTIONS from the Makefile.am in unit-tests and introduce some clever
code in configure.ac instead to set the flag only on the automake versions that need it.
2015-09-22 14:03:28 +02:00
David Karlaš ecb87b03f1 Merge pull request #2071 from DavidKarlas/bug25480
Bug 25480 - OutputPath property is not set for this project
2015-09-22 11:20:39 +02:00
Eberhard Beilharz 7381d913a9 [MWF] Fix problem pasting text (Xamarin-33968)
Fix a problem where pasting certain unicode characters from the
clipboard (e.g. "aʼaa") resulted in "a벪".
2015-09-22 10:22:35 +02:00
Vlad Brezae e55e4350bb [sgen] Fix race between block allocation and concurrent sweep.
Adding a new block to the allocated_blocks array is racy with the removal of nulls when sweeping. We wait for sweep to finish to avoid that.

This also handles the problem of allocating degraded objects while sweeping.
2015-09-22 00:38:29 -07:00
Adam Burgess d89373d85e [System] Fix SmtpClient.SendMailAsync never completing 2015-09-22 04:43:12 +10:00
David Karlaš 6c066a6580 [XBuild] Ignoring paths of .csproj, .targets and .sln file paths so in case of missmatch between values in <ProjectReference> or .sln and actual file system continue matching project file path and project 2015-09-21 20:30:22 +02:00
David Karlaš 76c6a08e73 [XBuild] Bug 25480 - OutputPath property is not set for this project
This error was generated when iOS(or any other kind of project, that is referencing other project in solution via <ProjectReference>) wanted to get OutputPath of PCL(or any other referenced project) but it failed in case of IDE because wrong conditions(see .targets files changes). Reason this bug was never discovered before is because PCL project was already loaded before with correct configuration/platform so not having AssignProjectConfiguration target executed had no effect. Reason it appeared in this case(Bug 25480) was that .sln and .csproj<ProjectReference> had folder path defined as XamlSamples but actual file system had xamlsamples(notice different chars casing). So projects.TryGet(filePath, out project) failed, hence project had to be reloaded, and then bug from .targets files showed up...

A bit more details about fix: The AssignProjectConfiguration target assigns configurations to the various @(ProjectReference), and is used from targets like ResolveProjectReferences, which are enabled only while building solution files ( $(BuildingSolutionFile) ) or when invoked from the IDE ( $(BuildingInsideVisualStudio) ). But the AssignProjectConfiguration target ignores the IDE case, which breaks usage of ResolveProjectReferences from the same. Fix up to run for both the cases.
2015-09-21 20:28:43 +02:00
Alexander Köplinger 8719a2a6d2 Revert "System.Web.UI.WebControls.SendMailErrorEvent(Args|Handler) from referencesource"
This reverts commit 7f5413a819.

It caused a test failure in MonoTests.System.Web.UI.WebControls.PasswordRecoveryTest.GetPasswordTest
2015-09-21 14:19:05 +02:00
Marek Safar e9d0f23b45 Bump referencesource 2015-09-21 11:07:20 +02:00
Marek Safar e0f9637ee9 [corlib] Match es-es NumberGroupSeparator with es. Fixes #34047 2015-09-21 09:58:47 +02:00
Marek Safar 5ec3345b79 Merge branch 'pr/2065' 2015-09-21 09:07:46 +02:00
Marek Safar fb088e5502 [System.Net.Http] Set host header directly only 2015-09-21 09:04:34 +02:00
Marek Safar 79bbc68c4f Merge pull request #2068 from kasthack/System.Web-import
System.Web reference source imports
2015-09-21 08:28:44 +02:00
Zoltan Varga 8e37c4b888 Merge pull request #2067 from akoeplinger/unit-tests-nunit
[unit-tests] Emit NUnit xml report of test result
2015-09-21 00:51:23 -04:00
Zoltan Varga 840554bb40 [aot] Remove unused 'autoreg' option. 2015-09-21 00:41:53 -04:00
Zoltan Varga cc946ea5b9 [aot] Remove support for direct object file emission in aot mode, the implementation is not complete. 2015-09-21 00:38:58 -04:00
Zoltan Varga ababe03626 Add an 'rgctx' field to MonoDelegate, not yet used. 2015-09-20 14:56:45 -04:00
kasthack d408da6df2 System.Web.Configuration.(AdapterDictionary,AuthenticationMode,MachineKeyValidation,ProcessModelComAuthenticationLevel,ProcessModelComImpersonationLevel,SystemWebCachingSectionGroup,WebApplicationLevel,XhtmlConformanceMode) from reference source
Added AsyncPreloadModeFlags + some internal classes used by MS's implementation
2015-09-20 09:53:17 +03:00
kasthack e02c9701d7 System.Web.UI.WebControls.WebParts.IWebPartTable+TableCallback from referencesource 2015-09-20 08:36:48 +03:00
kasthack 2028e87d51 System.Web.UI.WebControls.WebParts.IWebActionable from referencesource 2015-09-20 08:34:21 +03:00
kasthack 8663666b4a System.Web.Configuration.CustomErrorsRedirectMode from referencesource 2015-09-20 08:32:56 +03:00
kasthack 57469ce82a System.Web.UI.WebParts.WebPartEvent(Args|Handler) from referencesource 2015-09-20 08:31:45 +03:00
kasthack 6e363f21bf System.Web.Configuration.PagesEnableSessionState referencesource 2015-09-20 08:30:05 +03:00
kasthack 560c1765eb System.Web.UI.WebParts.PartChromeState from referencesource 2015-09-20 08:28:34 +03:00
kasthack 6452c7267c System.Web.UI.WebControls.CreateUserErrorEvent(Args|Handler) from referencesource 2015-09-20 08:26:12 +03:00
kasthack 8942f4add3 +System.Web.Configuration.TicketCompatibilityMode 2015-09-20 08:24:31 +03:00
kasthack 7f5413a819 System.Web.UI.WebControls.SendMailErrorEvent(Args|Handler) from referencesource 2015-09-20 08:23:27 +03:00
kasthack 814331510c System.Web.Configuration.ProcessModelLogLevel from referencesource 2015-09-20 08:21:32 +03:00
kasthack b0cd92127c +System.Web.Configuration.ProfileGuidedOptimizationsFlags.cs 2015-09-20 08:19:40 +03:00
kasthack a27080e9ca System.Web.UI.WebControls.AuthenticateEvent(Args|Handler) from referencesource 2015-09-20 08:18:08 +03:00
kasthack 65b8984a75 +System.Web.UI.ValidateRequestMode 2015-09-20 08:16:12 +03:00
kasthack eaefcc235e System.Web.Configuration.CustomErrorsMode from referencesource 2015-09-20 08:14:52 +03:00
kasthack 8e93f5f7b9 System.Web.UI.WebControls.IPersistedSelector from referencesource 2015-09-20 08:13:31 +03:00
kasthack a1ff605a1e System.Web.Configuration.TraceDisplayMode from referencesource 2015-09-20 08:11:52 +03:00
kasthack d972f553a9 System.Web.Configuration.AuthorizationRuleAction from referencesource 2015-09-20 08:10:32 +03:00
kasthack 84edeade67 System.Web.UI.WebControls.LoginCancelEvent(Handler|Args) from referencesource 2015-09-20 08:08:50 +03:00
kasthack d35f36ae48 +UnobtrusiveValidationMode.cs 2015-09-20 08:06:34 +03:00
kasthack 0caa09ba29 System.Web.UI.WebControls.WebParts.(IWebPartField|IWebPartFieldCallback) from referencesource 2015-09-20 08:05:09 +03:00
kasthack 6c0216dcfa System.Web.UI.WebControls.WebParts.(IWebPartRow|IWebPartRowCallback) from referencesource 2015-09-20 08:00:14 +03:00
kasthack 110bf02eb6 System.Web.TraceContextEvent(Args|Handler) from referencesource 2015-09-20 07:55:49 +03:00
kasthack 86a6207108 System.Web.Routing.IRouteConstraint from referencesource 2015-09-20 07:51:59 +03:00
kasthack 2fc2764373 +System.Web.ModelBinding.(ModelError,ModelErrorCollection) 2015-09-20 07:45:49 +03:00
kasthack 22ca5de1b0 System.Web.UI.IThemeResolutionService from referencesource 2015-09-20 07:40:54 +03:00
kasthack d5a8b20f22 System.Web.UI.WebControls.CallingDataMethodsEvent(Handler|Args) from referencesource 2015-09-20 07:37:08 +03:00
kasthack 1f8deb5a32 System.Web.Routing.IRouteHandler from reference source 2015-09-20 07:33:12 +03:00
kasthack 8559310456 System.Web.UI.WebControls.IDataBoundItemControl from reference source 2015-09-20 07:31:44 +03:00
kasthack 8317ad809e System.Web.Routing.RouteDirection from reference source 2015-09-20 07:29:43 +03:00
kasthack deeea8bdf8 System.Web.UI.WebControls.IFieldControl from reference source 2015-09-20 07:26:39 +03:00
kasthack fb33e443bd System.Web.Caching.ResponseElement from reference source 2015-09-20 07:22:14 +03:00
kasthack 7ed288f715 System.Web.SessionState.SessionStateBehavior from reference source 2015-09-20 07:12:30 +03:00
kasthack be246f4924 System.Web.Compilation.(ImplicitResourceKey,IImplicitResourceProvider) from reference source 2015-09-20 06:50:25 +03:00
kasthack 62cca27e2f System.Web.Compilation.IAssemblyPostProcess from reference source 2015-09-20 06:38:52 +03:00
Alexander Köplinger bec4e96e18 [System] Fix SocketTest.SendAsyncFile test to use dynamic port
The previous hardcoded port 8001 caused "address already in use" errors on Jenkins.
2015-09-20 02:59:19 +02:00
Alexander Köplinger 5ad2890c11 [unit-tests] Emit NUnit xml report of test result
Overrides check-local to output an NUnit report of the test results.

It currently creates a single pass/fail test case as this is the easiest solution,
but the test log is included in the report which should be enough to diagnose errors.

Parallelism is disabled here since we need to ensure check-local happens after check
so we can parse test-suite.log. The tests are quite fast so it doesn't hurt much.

We need AUTOMAKE_OPTIONS=parallel-tests so the test-suite.log gets created on automake 1.11.
2015-09-20 02:44:14 +02:00
Zoltan Varga ba875cb62c Merge pull request #2029 from madewokherd/winformstests
Fix MonoTests.System.Windows.Forms.TrackBarBaseTest on Windows.
2015-09-19 12:48:57 -04:00
Alexander Köplinger ccd2d8b29c Merge pull request #2064 from akoeplinger/profiler-nunit
[profiler] Emit NUnit xml report of test result in ptestrunner.pl
2015-09-19 03:44:51 +02:00
Rodrigo Kumpera 2437b1ea77 [threading] Apparentlty zero is a valid tls key on some systems. 2015-09-18 16:51:12 -04:00
Marek Habersack 6335b96646 [threadpool] Prevent high CPU usage in certain conditions
Threadpool uses poll(2) to watch the file descriptors for activity but
it can sometimes miss that an fd went into error. When that happens the
poll call is interrupted with EAGAIN since the erroneous fd's events have
already been read and there's nothing left in the queue for it. That, in turn,
causes mono to run the loop so quickly that it uses 100% of the CPU. It happens,
for instance, with Xamarin Studio which can utilize two CPU cores to the full while
idling on the opening screen.

This commit makes sure to remove the descriptors with errors from the poll set and
thus preventing the syscall from being interrupted and returning EAGAIN.
2015-09-18 18:26:34 +01:00
Zoltan Varga 66a191c865 [jit] Remove some obsolete code from mini_type_is_hfa (). 2015-09-18 12:56:33 -04:00
Radek Doulik 3a2af04f17 [linker-analyzer] enable build of linker-analyzer tool 2015-09-18 13:09:26 +02:00
Radek Doulik 05b0506669 [linker] add linker dependencies dumping 2015-09-18 12:45:54 +02:00
Radek Doulik 12bdd8ef47 [linker-analyzer] intitial commit of the tool 2015-09-18 12:45:41 +02:00
Adam Burgess b1362f3387 [System.Net.Http] Fix custom Host header not being set on requests. Fixes #34044 2015-09-18 05:48:52 +00:00
Atsushi Eno 2901e91c9d Merge pull request #1899 from saper/resgencond
[resgen] Implement conditional resources (#if/#ifdef)
2015-09-18 10:12:32 +08:00
Zoltan Varga 687eeff24f Revert "[jit] Emit the results of the jit regressions tests in nunit format only when running under jenkins."
This reverts commit 1ef694ae52.

Revert this, JENKINS_URL is not an automake variable.
2015-09-17 17:50:58 -04:00
Alexander Köplinger 0804adab66 [profiler] Emit NUnit xml report of test result in ptestrunner.pl
Currently only emits a single pass/fail testcase as capturing the individual errors
and test counts would be much more invasive.

The bulk of the logic is copied from mono/mini/emitnunit.pl.
2015-09-17 23:46:28 +02:00
Ludovic Henry b3fa096e5e [bcl] Fix System.Net.HttpWebRequestTest.GetRequestStream hang
This hang would manifest when running the System test suite, with a thread waiting on a `recv'. This syscall would never be interrupted because the socket it would listen on would never close, as there would still be references to its SafeSocketHandle, so that it would never release the native handle.

The issue came from the fact that, when closing the SocketResponder (via the Dispose and the using), the listening thread would never be aborted/stopped, and it would consequently never be collected, thus never releasing the current socket on which _requestHandler is called, thus never aborting the above `recv' syscall.

The issue would arise with the cooperative GC as well as the premptive one.
2015-09-17 16:09:25 +01:00
Marcos Henrich 07bae963ae Merge pull request #2047 from esdrubal/socketreuse
[System] Fix TCP socket reuse.
2015-09-17 15:47:31 +01:00
Ludovic Henry ff17686542 [delegate] Fix NRE on GetHashCode 2015-09-17 13:54:03 +01:00
Marcos Henrich 59c72654f2 [System] Updated SocketTest.TcpDoubleBind.
Multiple threads listening to the same address and port are not possible
before linux 3.9 kernel, where the socket option SO_REUSEPORT was
introduced.

This commit makes TcpDoubleBind sensible to this OS capability.
2015-09-17 12:22:24 +01:00
Ludovic Henry cb6cc5e158 [math] Fix corlib/System.MathTest.TestPow test #48 on Linux 32bits 2015-09-17 10:35:45 +01:00
Zoltan Varga 99fddab0a3 [amd64] More gsharedvt/cleanup work. 2015-09-16 13:26:09 -04:00
Zoltan Varga fe43f42bfc Revert "[amd64] More gsharedvt/cleanup work."
This reverts commit c09ca0fd7e.

Revert this as it breaks the build.
2015-09-16 12:50:53 -04:00
Ludovic Henry 8b957a5332 [math] Fix corlib/System.MathTest.TestPow #47 on Linux 32bits 2015-09-16 17:21:27 +01:00
Ludovic Henry 720fc7f7f7 [SafeHandle] Cleanup of the code
This is to avoid code duplication and multiline conditions assignement
2015-09-16 12:32:25 +01:00
Marcos Henrich 6caca3256b Merge pull request #2056 from esdrubal/urilocal
[System] Fixes TimeZoneInfo.ConvertTimeFromUtc.
2015-09-16 07:05:08 +01:00
Zoltan Varga c09ca0fd7e [amd64] More gsharedvt/cleanup work. 2015-09-15 21:27:06 -04:00
Zoltan Varga b96001c435 [sdb] Fix the aborting of multiple invocations. 2015-09-15 19:27:21 -04:00
Zoltan Varga bfbb4b8d88 [sdb] Add a test for aborting invokes. 2015-09-15 16:48:48 -04:00
Juergen Hoetzel c820dda1ce [runtime] Fix casting error in InternalCodePage.
Use gsize instead of gssize when checking the encodings array for
codepage numbers. When a char* is pointing to the upper half of the
address space, it will be otherwise converted to a negative number.
2015-09-15 22:30:25 +02:00
Zoltan Varga 6362bb09e6 [runtime] Fix a potential buffer overflow in mono_network_get_data (). Fixes #33851. 2015-09-15 15:38:11 -04:00
Zoltan Varga 15bee580fd [sdb] Avoid aborting the runtime with a breakpoint signal if Debugger.Break () is called, add a MONO_DEBUG=native-debugger-break option to enable it. Fixes #33952. 2015-09-15 15:04:48 -04:00
Marcos Henrich 65c3a8e821 [corlib] Added fixture ConvertTimeTests_LocalUtc.
ConvertTimeTests_LocalUtc runs ConvertTimeTests fixture with
TimeZoneInfo.Local set to TimeZoneInfo.Utc.

Removed redundant test ConvertFromToUtc_LocalAsUtc.
2015-09-15 17:24:53 +01:00
Marcos Henrich 6cccbbdbd7 [System] Fixes TimeZoneInfo.ConvertTimeFromUtc.
Fixes TimeZoneInfo.ConvertTimeFromUtc and related tests when
TimeZoneInfo.Local is equal to TimeZoneInfo.Utc.

In .NET if we set TimeZoneInfo.Local to TimeZoneInfo.Utc by using
reflection.

```
var cachedDataField = typeof (TimeZoneInfo).GetField ("s_cachedData",
BindingFlags.Static | BindingFlags.GetField | BindingFlags.NonPublic);

var localField = cachedDataField.FieldType.GetField ("m_localTimeZone",
BindingFlags.Instance | BindingFlags.GetField | BindingFlags.NonPublic);

var localFieldObj = cachedDataField.GetValue (null);

localField.SetValue (localFieldObj, DateTimeKind.Utc);
```

We can observe that `TimeZoneInfo.ConvertTimeFromUtc (DateTime.UtcNow,
TimeZoneInfo.Local).Kind` is DateTimeKind.Utc.

By looking at reference source [code](http://referencesource.microsoft.com/#mscorlib/system/timezoneinfo.cs,211)
we can also confirm that while getting a time zone corresponding kind,
Utc is prioritized over Local.

This commit reverts changes introduced by
60d5b39e46 that were prioritizing Local
over Utc and changes tests to expect Utc kinds instead of Local when
TimeZoneInfo.Local is equal to TimeZoneInfo.Utc.
2015-09-15 17:24:53 +01:00
Marcos Henrich 99915fc6c3 Merge pull request #2052 from esdrubal/urilocal
[corlib] Fixes TimeZoneInfo.ConvertTimeFromUtc.
2015-09-15 11:39:34 +01:00
Marcos Henrich 60d5b39e46 [corlib] Fixes TimeZoneInfo.ConvertTimeFromUtc.
TimeZoneInfo.ConvertTimeFromUtc(utcDate, TimeZoneInfo.Local) now returns a date of kind
DateTimeKind.Local when TimeZoneInfo.Local is equal to TimeZoneInfo.Utc.

Fixes #33471.
2015-09-15 09:43:38 +01:00
Marcos Henrich e32e14e9f0 [corlib] Tests TimeZoneInfo.ConvertTimeFromUtc.
Tests that TimeZoneInfo.ConvertTimeFromUtc with TimeZoneInfo.Local set to
TimeZoneInfo.Utc returns a date of kind Local.

Covers #334711.
2015-09-15 09:43:37 +01:00
Zoltan Varga 9ec7d6e007 [amd64] Fix llvm support broken by 751440d321. 2015-09-14 15:37:22 -04:00
Zoltan Varga 7898f36714 [runtime] Change MonoDroid->Xamarin.Android in configure output. 2015-09-14 15:19:39 -04:00
Zoltan Varga cb3def2f71 [llvm] Fix the caching of the callee for mono_threads_state_poll. 2015-09-14 15:18:45 -04:00
Marek Safar 4ff3b279a2 [mcs] Lift result of null operator over dotted expressions only ending with not null operator on value type. Fixes #33797 2015-09-14 17:16:33 +02:00
Ludovic Henry 8245977794 [threadpool-io-poll] Use mono_poll instead of platform specific poll/WSAPoll 2015-09-14 12:01:09 +01:00
Marcos Henrich 79d28a7ba2 [System] Fix TCP socket reuse.
TCP sockets with option SocketOptionName.ReuseAddress were not working on Linux.

Fixes #31557.
2015-09-14 10:45:47 +01:00
Marcos Henrich 66cc0c2949 [System] Test Socket TCP double bind.
Test checks that when setting TCP socket option ReuseAddress, it is
possible to bind other sockets to the same endpoint.

Covers #31557.
2015-09-14 10:45:47 +01:00
Ludovic Henry 53a6492209 [delegate] Fix Equals on Delegate to virtual method
The comparison was failing because we were still using the method field (instead of the Method property), which would then return, in the case of a delegate to a virtual function, the method on the base class, instead of the method on the derived class. Updated the test cases to check that too.
2015-09-14 10:28:18 +01:00
Rolf Bjarne Kvinge d583cc703b Add a monotouch_tv profile. 2015-09-14 10:37:09 +02:00
Rolf Bjarne Kvinge a427d86c1b Merge pull request #2046 from rolfbjarne/profile-simplification
Profile simplification
2015-09-14 10:36:46 +02:00
Zoltan Varga b189c386b5 Fix the build. 2015-09-13 23:06:46 -04:00
Zoltan Varga 751440d321 [amd64] Clean up the handling of returning vtypes by a hidden argument, add beginnings of gsharedvt support. 2015-09-13 21:31:10 -04:00
João Matos 88a166b75c [genproj] Added missing git ignored Mono.Cecil.Mdb MSBuild project. 2015-09-14 00:37:24 +01:00
João Matos a373c3d989 [build] Generated up-to-date net_4_x MSBuild projects. 2015-09-14 00:16:41 +01:00
João Matos a8d6b4abff [genproj] Skip Facades, mcs and Microsoft.Web.Infrastructure. 2015-09-14 00:14:41 +01:00
João Matos 2687866e99 [genproj] Do not overwrite class library inputs with Facades.
Unfortunately the projects in the Facades share the same names as our main class library assembly names which causes us to overwrite their inputs here.
2015-09-14 00:01:41 +01:00
João Matos 44db1f2e8f [genproj] Update the generator to handle the net_4_x profile. 2015-09-14 00:00:15 +01:00
João Matos 26fa5fd9e8 [genproj] Do not define DEBUG in debug mode since it breaks reference sources. 2015-09-13 23:58:39 +01:00
João Matos aab9e03e70 [mcs] Reference System, System.Core and System.Xml when building.
This fixes compile errors in the generated csproj for mcs.
2015-09-13 23:57:24 +01:00
João Matos a982f9f568 [mcs] Write mcs library references when generating csproj order data. 2015-09-13 23:56:34 +01:00
Zoltan Varga 0a97271ff5 Merge pull request #2014 from BillSeurer/master
[ppc] Changes for power for ELF ABI v2 structure parameters
2015-09-11 20:38:53 -04:00
Alexander Köplinger 8ac54a7c68 [System] Bump timeout in ServicePointTest.DnsRefreshTimeout test again
The refresh timeout starts running before the actual DNS request is sent, which means on systems with a
slow DNS server the cached value has already timed out when the response is received, making the test fail.

Bumping the timeout to 2s should fix the test on Jenkins.
2015-09-11 22:48:13 +02:00
Zoltan Varga c91cdcbe68 Revert "[aot] Update the llvm frame decoding code for llvm b757db3a001fcdcab038411708c0f77c6211cba6."
This reverts commit c5e03971ae.

Revert this as the corresponding llvm commit was reverted.
2015-09-11 16:06:46 -04:00
Zoltan Varga c5e03971ae [aot] Update the llvm frame decoding code for llvm b757db3a001fcdcab038411708c0f77c6211cba6. 2015-09-11 15:46:08 -04:00
Rolf Bjarne Kvinge 05ef9eddfe Remove profile-specific logic from makefiles.
Instead use variables defined in each profile's profile-specific makefile.
2015-09-11 18:06:15 +02:00
Rolf Bjarne Kvinge d3e4c19f3f [System.Xaml] Make build logic more logical.
FRAMEWORK_VERSION_MAJOR is 2 for the mobile profiles, so filtering
on the profile name will do nothing at all.

This means listing the mobile profiles here is completely redundant,
so simplify to just building when FRAMEWORK_VERSION_MAJOR=4.
2015-09-11 17:55:56 +02:00
Rolf Bjarne Kvinge bba0486792 Add a dummy implementation for MONO_CONTEXT_GET_CURRENT for the Apple TV. 2015-09-11 17:08:21 +02:00
Alex Rønne Petersen 0c56887d08 Merge pull request #2040 from esdrubal/monoman
Added missing MONO_DEBUG options.
2015-09-11 16:49:24 +02:00
Alex Rønne Petersen 1e752b1d95 Merge pull request #2042 from evincarofautumn/remove-dead-code
Remove dead weak link API.
2015-09-11 16:48:51 +02:00
Rolf Bjarne Kvinge 8356eb2af9 There's no IOKit on the Apple TV. 2015-09-11 15:25:47 +02:00
Rodrigo Kumpera 63ad46198b [threading] Allow mono_thread_info_current_unchecked to be called before the tls key it uses is initialized. 2015-09-10 17:36:50 -04:00
Rodrigo Kumpera d1cff8d601 Fix the build. 2015-09-10 15:08:09 -04:00
Bill Seurer 45c3685e3b [ppc] Fix exception when reading from timezone file.
See https://bugzilla.xamarin.com/show_bug.cgi?id=30360
2015-09-10 14:04:44 -05:00
Rodrigo Kumpera da47e00abd [suspend] Wrap mmap and unmmap around critical sections to better handle library interposing. Fixes #19379
Instruments uses library interposing to record calls to mmap and munmap. It does take lock within the interposers
which means the async suspend could suspend a thread holding such lock while sgen tries to mmap more memory in,
causing a deadlock.

The workaround is to protect our uses of mmap and munmap in the hopes that they are enough to reduce the likelihood
of those hangs happening.
2015-09-10 14:55:37 -04:00
Zoltan Varga d7906b3e5a [aot] Remove some arm special cases which are no longer needed. 2015-09-10 13:52:04 -04:00
Bill Seurer 0d464be2b3 [ppc] Fix passing of structure parameters as per the ELF ABI v2. Add 5 new test cases to test the new ABI changes. 2015-09-10 11:57:02 -05:00
Ludovic Henry f6f48eb672 [threadpool-io-poll] Assert we have sockets to callback on 2015-09-10 17:44:20 +01:00
Ludovic Henry 6f045fee8a [threadpool-io] Log if an error occured on a socket 2015-09-10 17:43:23 +01:00
Ludovic Henry 1f4d44800e [Socket] Duplicate logic of AsyncResult.ExecuteWorkItem to SocketAsyncResult
This consists in executing the callback synchronously and swallowing any exception in this callback.
2015-09-10 16:59:01 +01:00
triton d1f9373441 [eglib] Fixed vasprintf function detection.
Fixes the Cygwin build, see https://github.com/mono/mono/pull/1966.
2015-09-09 22:31:02 +01:00
Ludovic Henry 4bbb9b3421 [delegate] Bump BCL version for field added on Delegate 2015-09-09 18:00:05 +01:00
Ludovic Henry 57be241716 [delegate] Fix bug #33218 "Action ReflectedType differs from Delegate ReflectedType" 2015-09-09 16:11:28 +01:00
Ludovic Henry 18674021a5 [io-layer] Fix segfault on handle dump 2015-09-09 16:11:28 +01:00
Marcos Henrich c7b0e92984 Merge pull request #2041 from esdrubal/uritestfix
Fixes DotNetRelativeOrAbsoluteTest.
2015-09-09 13:50:07 +01:00
Rolf Bjarne Kvinge d935996d88 [mono-api-html] Adding members to an interface is a breaking change, so show it in red. 2015-09-09 11:42:22 +02:00
Rolf Bjarne Kvinge b17301f43f [mono-api-info] Sort constructors using full signature.
So that info files can be compared textually to test for api equality.
2015-09-09 10:44:22 +02:00
Alexander Köplinger 5b16d22774 [System] Make ServicePointTest.DnsRefreshTimeout test more reliable
The previous 2ms timeout was way too short and the test failed frequently.

Also switch to Assert.AreSame/AreNotSame instead of AreEqual/AreNotEqual since
we want to ensure the same object is returned and not just an equal one.
2015-09-09 03:30:11 +02:00
Jon Purdy 2897d7d827 Remove dead weak link API. 2015-09-08 15:51:27 -07:00
Alex Rønne Petersen cf5f99d83a Merge pull request #2028 from alexrp/master
[runtime] Don't allocate domain-level static slots for special static fields.
2015-09-08 23:26:43 +02:00
Mark Probst 277ecfde7b Merge pull request #1457 from evincarofautumn/weak-refs
Refactor weak-reference handling code in SGen
2015-09-08 13:24:14 -07:00
Mark Probst 4d5ffcb9ad Merge pull request #2013 from BrzVlad/feature-concurrent-work
[sgen] Run the concurrent mark concurrent with nursery collections
2015-09-08 13:03:01 -07:00
Marcos Henrich 4d3b8b856b Fixes DotNetRelativeOrAbsoluteTest.
Test was not changing Uri.useDotNetRelativeOrAbsolute back to its
previous value.
2015-09-08 17:43:00 +01:00
Miguel de Icaza 12fcfa3816 [corlib] MulticastDelegate, bring back the HasSingleTarget internal method for public use 2015-09-08 10:34:47 -04:00
Miguel de Icaza e3f6e7a774 Disable warnings about globally disabled warnings, show by ReferenceSource code 2015-09-08 10:34:47 -04:00
Rolf Bjarne Kvinge 739298bd2d [mono-api-html] Fix printing of Obsolete attributes. 2015-09-08 13:55:28 +02:00
Rolf Bjarne Kvinge 09f5f071fb [mono-api-info] Sort nested types.
So that info files can be compared textually to test for api equality.
2015-09-08 13:55:10 +02:00
Rolf Bjarne Kvinge 4d3e34229c [mono-api-info] Minor perf improvements. 2015-09-08 12:06:39 +02:00
Rolf Bjarne Kvinge 26a5164a4d [mono-api-info] Sort methods using full signature.
So that info files can be compared textually to test for api equality.
2015-09-08 12:06:38 +02:00
Marcos Henrich f2bd0dd1cf Added missing MONO_DEBUG options.
The new options were added by the following commits:
align-small-structs f7b9bb3bf0
arm-use-fallback-tls 421fa312a5
debug-domain-unload 3c0c5f8624
gen-compact-seq-points ab392debf4
partial-sharing 1cab7b0535
single-imm-size 9e0d841872
soft-breakpoints a2c629efe2
suspend-on-exception fcbf89d2ad
suspend-on-unhandled eb8be6f651
2015-09-08 11:00:44 +01:00
Marcos Henrich a3ccf9b47e Sorted MONO_DEBUG options alphabetically. 2015-09-08 10:59:55 +01:00
Marek Safar 2817e026df Merge pull request #2039 from simonhartmann/dns_refresh_timeout
[class libs] Implemented DnsRefreshTimeout for ServicePointManager
2015-09-08 11:48:01 +02:00
Simon Hartmann 932359f3d6 implemented DnsRefreshTimeout to ServicePointManager and adjusted behavior of ServicePoint.HostEntry property.
simplified some calls as requested
2015-09-08 11:08:50 +02:00
Marek Safar 6294c96bab [mcs] Null operator on value type extension argument. Fixes #33754 2015-09-08 10:59:52 +02:00
Marek Safar 86c5ca89ac Merge pull request #2032 from directhex/parallel_automake_is_hard
Parallel automake is hard
2015-09-08 10:36:58 +02:00
Marek Safar 8add506fcd [mcs] Improve test from e97227a53d 2015-09-08 08:07:46 +02:00
Marek Safar e97227a53d [mcs] Lift result of binary operation on enum types in more cases. Fixes #33723 2015-09-07 20:29:39 +02:00
Marek Safar aae572095c [mcs] Fixes a typo 2015-09-07 20:29:39 +02:00
João Matos 0083175d5c [runtime] Another fix for fast TLS target checking to work with cross-compilation. 2015-09-07 16:04:13 +01:00
Marek Safar 5e81ed1e03 [mcs] Consider whole hierarchy of inherited type arguments inflated via base type. Fixes #33669 2015-09-07 16:11:59 +02:00
Rolf Bjarne Kvinge 9dd35ce4a5 [mono-api-info] Order interfaces.
So that info files can be compared textually to test for api equality.
2015-09-07 13:06:01 +02:00
Jo Shields c6a312859c [Facades] Fix default profile parallelization
PROFILE_SUBDIRS is built serially, then PROFILE_PARALLEL_SUBDIRS in parallel. Since we want the latter for everything, only define the latter.
2015-09-07 09:37:39 +01:00
Jo Shields 9a8e7c6571 [Facades] Fix profile name error causing non-building
The parallel build infrastructure we're trying to leverage for Facades depends on the profile name when populating the parallel lists - the default profile is now named "net_4_x", so variables with "net_4_5" in them are not considered - causing the whole Facades/ directory to be skipped
2015-09-07 09:37:39 +01:00
Marek Safar a7d0ec44c5 [corlib] Make test reproducible 2015-09-07 09:41:15 +02:00
Marcos Henrich d0b002f000 Merge pull request #2031 from esdrubal/uriworkaround
[System] UriKind.RelativeOrAbsolute workaround.
2015-09-05 11:35:35 +01:00
Angelo Compagnucci 026a8c44d3 eglib: checking for locale_charset function
This patch checks if locale_charset function is availabe in
libiconv or libcharset and changes the linking options accordingly.
2015-09-05 08:57:21 +02:00
Zoltan Varga 8a4b2f74d5 Fix a warning. 2015-09-04 22:04:41 -04:00
Zoltan Varga f4ddc5e113 Merge pull request #2033 from tritao/zip-empty
[System.IO.Compression] Fixed handling of empty Zip archives in Update mode
2015-09-04 21:57:39 -04:00
Miguel de Icaza 2791af63d3 Merge pull request #2035 from joelmartinez/mdoc-memberremoval-fix2
[mdoc] Follow up fix for member and type removal.
2015-09-04 21:41:48 -04:00
Joel Martinez b94920854f [mdoc] Follow up fix for member and type removal.
In supplement of the changes submitted in 09b97cba2e, there were
some additional edge cases that were not originally considered, and so this patch resolves these
additional issues. In particular, there was a bug in the `RemoveApiStyle` method that wasn't
checking the value of the `apistyle` attribute before removing it. This caused members to be
stripped of apistyle inadvertently.

There was an issue in the type removal code that caused
too many files to be removed. This patch adds additional checks to make sure that a file isn't
going to be removed if it contains members in the other style that shoulnd't be removed

Finally, there was an issue that arose after the aforementioned changes in the `OrderTypeAttributes`
method. It was somewhat counterintuitive, but it wasn't allowing the reordering of attributes
with the `.Remove` method (throwing an exception). Not entirely sure why this was happening,
but using the `.RemoveNamedItem` method worked around the issue.
2015-09-04 20:10:24 -04:00
Zoltan Varga 635cc64cf0 [aot] Avoid an assert in mono_aot_jit_info_table_find () when the address is right after the end of the method. Fixes #32955. 2015-09-04 19:22:07 -04:00
Zoltan Varga 81e4e3c447 [jit] Fix crashes in the dwarf writer if the backing field of an enum is not named 'value__'. Fixes #33591. 2015-09-04 17:46:24 -04:00
Rodrigo Kumpera 0e6617b664 [threading] Fix race condition in the suspend account code. 2015-09-04 16:39:16 -04:00
Rodrigo Kumpera f0a2b9c98c Fix another broken test due to OSX oddities. 2015-09-04 15:35:31 -04:00
triton fcd3f2ca21 [runtime] Fixed fast TLS target checking to work with cross-compilation. 2015-09-04 18:01:02 +01:00
Rodrigo Kumpera ffc15afbf5 Fix the DefaultThreadCurrentCulture for real.
This test is very fragile as it depends on appdomain global state.
In this case the current thread culture.

The problem with CurrentCulture is it's behavior that once set, it can't
be unset, IOW, revert to follow DefaultThreadCurrentCulture.

This meant that test ordering played a huge deal here and it took a few
tries to learn what was going on.

The way to fix this is to run the test itself from a thread that we
can ensure that won't have CurrentCulture set. This includes TP threads
or new threads.

I opted to use a TP thread as there probably is one available already
when the test runs.
2015-09-04 12:42:22 -04:00
Rodrigo Kumpera 2a93fc1926 [Mono.Posix] Add ToString to struct Linger to help troubleshoot CI failure. 2015-09-04 11:37:16 -04:00
triton 5a422039ec [System.IO.Compression] Fixed handling of empty Zip archives in Update mode. Fixes bug #32725.
https://bugzilla.xamarin.com/show_bug.cgi?id=32725
2015-09-04 15:17:17 +01:00
Marcos Henrich 3a895d485b [System] UriKind.RelativeOrAbsolute workaround.
In .NET an URI constructor from "/foo" and UriKind.RelativeOrAbsolute is
relative whereas in mono it is assumed as an absolute file path.

This adds another workaround that changes all Uri constructor calls to
behave like .NET when receiving UriKind.RelativeOrAbsolute.

The environment variable workaround consists in setting
MONO_URI_DOTNETRELATIVEORABSOLUTE=true before starting the application:

Reflection workaround:
```
if (Type.GetType ("Mono.Runtime") != null)
    typeof (Uri).GetField ("useDotNetRelativeOrAbsolute",
        BindingFlags.Static | BindingFlags.GetField | BindingFlags.NonPublic).
        SetValue (null, true);
```

WARNING: The workarounds change the behavior of all Uri constructor calls.
Unexpected problems can occur if an used library relies on
UriKind.RelativeOrAbsolute to parse absolute file paths.
2015-09-04 07:23:59 +01:00
Marek Safar a8f85e720e Merge pull request #2030 from esdrubal/urispaces
Fixes Uri.UserInfo with spaces.
2015-09-04 08:11:01 +02:00
Marcos Henrich a1b2783373 Fixes Uri.UserInfo with spaces.
Fixes #31172.
2015-09-04 05:36:27 +01:00
Marcos Henrich 85f33ffe2a Tests Uri.UserInfo with spaces.
Covers #31172.
2015-09-04 05:35:12 +01:00
Marcos Henrich e21d456d0b Merge pull request #2022 from esdrubal/fixes-GetDaylightChanges
Fixes TimeZoneInfo.GetDaylightChanges #32722.
2015-09-04 04:31:50 +01:00
Zoltan Varga ce176fb285 [runtime] Fix the thunks.exe tests when not running with the coop gc. 2015-09-03 20:41:26 -04:00
Jon Purdy 5853defbf4 [sgen] Register GC handle counters & avoid 64-bit CAS.
The GC handle counters were not being registered; probably got lost when
rebasing this code atop the independent SGen. This also avoids 64-bit
CAS on these counters, so that platforms without it still have stats.
2015-09-03 16:25:23 -07:00
Jon Purdy ce9b7f4a58 [sgen] Avoid designated initializer.
Designated-initializer expressions are not considered constant
expressions, so they can't be used to initialize static variables.
2015-09-03 16:25:14 -07:00
Jon Purdy 9f25693314 [sgen] Typedef handle iteration callback. 2015-09-03 16:24:55 -07:00
Jon Purdy 68cf603941 [sgen] Remove outdated comment. 2015-09-03 16:24:46 -07:00
Jon Purdy 08f78da4c6 [sgen] Document assertion. 2015-09-03 16:24:13 -07:00
Jon Purdy 95a5802c1a [sgen] Move & document write barrier. 2015-09-03 16:24:10 -07:00
Jon Purdy c35aa05be5 [sgen] Fix macro parentheses.
This happened not to cause any problems because:

    ((1 | 2) & 3) == (1 | (2 & 3))
2015-09-03 16:22:01 -07:00
Jon Purdy 45ee3241cc [sgen] Avoid redundant handle iteration. 2015-09-03 16:21:48 -07:00
Mark Probst 83fa220c1a [sgen] Fix heavy binary protocol. 2015-09-03 16:21:06 -07:00
Mark Probst 4e27df721c [sgen] Fix binary protocol for weak links. 2015-09-03 16:20:46 -07:00
Mark Probst 6c8c6b0c61 [sgen] Move dummy use function to sgen-gc.h. 2015-09-03 16:18:21 -07:00
Mark Probst 61204cc5a3 [sgen] Move GC handles to their own file. 2015-09-03 16:18:18 -07:00
Mark Probst 7299a70ba8 [sgen] Make the client interface work again. 2015-09-03 16:16:19 -07:00
Mark Probst 648719c5ef [sgen] Move GC handle domain stuff to client code. 2015-09-03 16:14:24 -07:00
Mark Probst cf428ef07f [sgen] Remove superfluous defines. 2015-09-03 16:14:00 -07:00
Mark Probst 197b625b12 [sgen] Do GC handle clearing for domain unloading when world is stopped.
Previously we had two places where GC handles were cleared:

`mono_gchandle_free_domain()`, which was called with the world running.

`mono_gc_clear_domain()`, which ran with the world stopped.

The first one doesn't do anything anymore now.  The reason the callback is
still there is because that's where Boehm clears the GC handles.
2015-09-03 16:13:17 -07:00
Mark Probst 1c6d1f6d17 [sgen] Pass hidden entry to GC handle iteration callback. 2015-09-03 16:13:14 -07:00
Jon Purdy 26a37c1704 [sgen] Add counters for GC handles. 2015-09-03 16:10:43 -07:00
Jon Purdy 21655bfff4 [sgen] Use old GC handle implementation with Boehm. 2015-09-03 16:10:40 -07:00
Jon Purdy 140ec68ddc [sgen] Make GC handles table lock-free.
The previous code was hard to make lock-free because it was trying to
coordinate three separate buffers: one of GC handles, one of a
free-bitmap, and one used to get the domain ID for an expired weak
reference. Now all of this information is stored in a single tagged
pointer per entry.

 * Make the GC lock non-recursive again.

 * Correctly null links for domain unloading.

 * Ensure that non-weak handles are registered as roots using the
   correct descriptors.
2015-09-03 16:07:05 -07:00
Jon Purdy 87fb34d18a [sgen] Remove weak ref hashes.
These hashes were inefficiently duplicating the information in the
common GC handle data tables.

 * Make GC lock recursive. This must be reverted when the GC handles
   table is made lock-free.

 * Refactor handle allocation and handle data manipulation to avoid
   duplication and magic numbers.

 * Use GC handles in refqueue and monitors, because the dislink
   machinery no longer exists.
2015-09-03 16:01:09 -07:00
Alex Rønne Petersen 0686c21358 [runtime] Optimize mono_class_field_is_special_static () a bit.
We can avoid loading custom attributes by checking field->offset == -1. This
won't always be the case for a special static field at all stages during class
loading but it'll speed up the most frequent cases.
2015-09-04 00:34:38 +02:00
Alex Rønne Petersen d2efa789ac [runtime] Don't allocate domain-level static slots for special static fields.
This didn't cause any harm, but resulted in a bit of unnecessary GC work and
memory usage.
2015-09-04 00:34:22 +02:00
Vincent Povirk 958d6c0092 Fix MonoTests.System.Windows.Forms.TrackBarBaseTest on Windows.
This is based on Windows 10 + .NET 4. I'm assuming until told otherwise that
the test was written based on an earlier .NET and the behavior has changed.
2015-09-03 16:22:32 -05:00
Marek Habersack 4fbe8c8836 Fix NREX in Linux network change notification code
Linux code uses a netlink socket to be notified about network interface
changes. The code is a bit racy and for that reson it can happen that
the LinuxNetworkChange.OnDataAvailable handler is called after the
socket is destroyed (from a timer event) and socket stored in an
instance variable is already null. This is a race most probably
introduced by the new threadpool or TPL code as it started to happen in
several places (mostly BCL tests on Android, but it's *not* specific to
Android).
The workaround here serves as a quick band-aid to be able to move on,
but a more thorough review of the socket code will be required.
2015-09-03 23:19:22 +02:00
Rodrigo Kumpera 73e47d3329 [Mono.Posix] Fix a test to accomodate for OSX's getsockopt implementation. 2015-09-03 16:50:09 -04:00
Rodrigo Kumpera 8b33f3a71c [corlib] Fix a test. It was broken in so many ways, but hidden behind a check that disabled it everywhere. :( 2015-09-03 16:03:49 -04:00
Rodrigo Kumpera 1840c4affd [coop] Add coop support to libtest. 2015-09-03 16:03:49 -04:00
Marek Safar 8692db1abd [mcs] Use auto-property backing field for setting only when setter is not available. Fixes #33600 2015-09-03 17:37:20 +02:00
triton 6df3a3d4c0 [windows] Check for WINVER define before re-defining. 2015-09-03 15:59:08 +01:00
triton 3c86642f5d [windows] Fixed some warnings when calling mono_cond_init.
Conflicts:
	mono/metadata/threadpool-ms-io.c
2015-09-03 15:58:59 +01:00
triton 75d43b2de9 [windows] Include missing build headers when defining WIN32_LEAN_AND_MEAN. 2015-09-03 15:58:14 +01:00
Jo Shields e2629c0292 DIST_SUBDIRS is a thing, fixes parallelism broken by previous change
See http://www.gnu.org/software/automake/manual/html_node/SUBDIRS-vs-DIST_005fSUBDIRS.html
2015-09-03 15:12:06 +01:00
Marcos Henrich 097409cdab Merge pull request #2024 from BogdanovKirill/webrequesttest
[HttpWebRequestTest] New test to check that after reading 2 GB of data from web server HttpWebRequest still works
2015-09-03 14:02:57 +01:00
João Matos 30d65675fb Merge pull request #2026 from directhex/fix-missing-tarball-facades
[Facades] fix exclusion from "make dist"
2015-09-03 13:33:59 +01:00
Jo Shields d3f00f08af [Facades] fix exclusion from "make dist"
If SUBDIRS is not set, then no files which aren't explicit Makefile targets will get included - which in this case means the only file in Facades/ in tarballs is the Makefile itself.
2015-09-03 12:47:09 +01:00
Marek Safar ebba1494a2 [mcs] Cache fixed array type expression. Fixes #33573 2015-09-03 13:05:06 +02:00
BogdanovKirill 3445e2cf4e [HttpWebRequestTest] New test to check that after reading 2 GB of data from web server HttpWebRequest still works
When HttpWebRequest is used to download infinite (ContentLength is not set) response from web server, we must be sure that after reading 2 GB (Int32.MaxValue) of data our internal classes are still working correctly

This change is released under the MIT license.
2015-09-03 15:42:41 +05:00
Marcos Henrich 0a67b54a85 [corlib] Fixes TimeZoneInfo.GetDaylightChanges.
Fixes #32722.
2015-09-03 10:05:26 +01:00
Marcos Henrich 9eb969b3a5 [corlib] Test GetSystemTimeZones in all timezones.
Covers #32722.
2015-09-03 09:58:38 +01:00
Marek Safar 74ef8f7504 [mcs] Implements null operator used from both outer and inner expression of the statement. Fixes #33341 2015-09-03 10:58:03 +02:00
Marcos Henrich 7885210529 Merge pull request #2017 from ludovic-henry/master
[math] Fix Math.Pow (1, Double.MaxValue) != 1 on Linux 32bits
2015-09-03 09:47:54 +01:00
sawachika-kenji 7bb5e6f381 Update FormsAuthentication.cs 2015-09-03 16:12:46 +08:00
Zoltan Varga 180c0ed27d [runtime] Remove some dead code. 2015-09-02 17:47:40 -04:00
Zoltan Varga 7efe163dcd [sdb] Fix locals info when two c# level locals are allocated to the same IL local. 2015-09-02 16:40:16 -04:00
Alex Rønne Petersen c838305c8e Merge pull request #2018 from alexrp/profiler-jit-info-removal
[profiler] Emit dummy code start/size info in cases where we can't retrieve it.
2015-09-02 22:39:26 +02:00
Zoltan Varga e4e48793a8 [wcf] Fix a regression introduced by 577d50e2e1. 2015-09-02 15:12:08 -04:00
Zoltan Varga 4fe276883b [runtime] Fix a regression introduced by f5222fe4f8, arguments were not properly passed to threads started from runtime code. 2015-09-02 12:58:01 -04:00
Miguel de Icaza d007a2a4db [Facades] Fix accidental removal of a line 2015-09-02 12:42:49 -04:00
Zoltan Varga ef95a5b018 [runtime] Make mono_type_is_hfa () return TRUE for structs with more than 4 fields. 2015-09-02 11:27:17 -04:00
Ludovic Henry 0fe67275c3 [math] Fix Linux 32bits tests
corlib/System.MathTest.Pow would fail at test #45 because the native pow implementation would return NaN (instead of 1) for pow (-1, Double.MaxValue).

The previous implementation treated this case for exponents bigger than 9007199254740991.0 and smaller than -9007199254740991.0
2015-09-02 15:42:26 +01:00
Marek Safar 39cbd2e2ea Bump reference sources 2015-09-02 11:26:39 +02:00
Marek Safar 19db0ee6f0 [corlib] Construct specific culture using most specific culture name region. Fixes #33400 2015-09-02 10:57:02 +02:00
Zoltan Varga fc420daefb Merge pull request #2010 from buraktamturk/master
Implement SqlDataReader.GetFieldValue<T> in order to fix EF's UpdateException
2015-09-02 01:55:30 -04:00
Zoltan Varga ed3c8ff390 Merge pull request #2021 from delme-imgtec/patch-1
Update SynchronizedCollection.cs
2015-09-02 01:40:33 -04:00
Zoltan Varga 46ff100e00 Remove an obsolete comment. 2015-09-01 23:01:06 -04:00
delme-imgtec 577d50e2e1 Update SynchronizedCollection.cs
Change is to fix following exception. Which suspect is cause by two threads both call remove at same time.

System.ArgumentOutOfRangeException: Index was out of range. Must be non-negative and less than the size of the collection.
Parameter name: index
  at System.ThrowHelper.ThrowArgumentOutOfRangeException () [0x00000] in <filename unknown>:0
  at System.Collections.Generic.List`1[System.ServiceModel.Channels.IDuplexSessionChannel].RemoveAt (Int32 index) [0x00000] in <filename unknown>:0
  at System.Collections.Generic.SynchronizedCollection`1[System.ServiceModel.Channels.IDuplexSessionChannel].RemoveItem (Int32 index) [0x00000] in <filename unknown>:0
  at System.Collections.Generic.SynchronizedCollection`1[System.ServiceModel.Channels.IDuplexSessionChannel].RemoveAt (Int32 index) [0x00000] in <filename unknown>:0
  at System.Collections.Generic.SynchronizedCollection`1[System.ServiceModel.Channels.IDuplexSessionChannel].Remove (IDuplexSessionChannel item) [0x00000] in <filename unknown>:0
2015-09-02 13:55:51 +12:00
Zoltan Varga b4a5bc8246 Revert "[sdb] Disallow nested invokes."
This reverts commit c4db814a44.

Revert this, its supported functionality.
2015-09-01 21:21:02 -04:00
Zoltan Varga 09e2510f34 [runtime] Remove MONO_HASH_CONSERVATIVE_GC, its not used anymore. 2015-09-01 20:41:16 -04:00
Zoltan Varga d24b24da23 Fix a warning. 2015-09-01 20:33:16 -04:00
Zoltan Varga f5222fe4f8 [runtime] Obtain the thread argument directly from MonoThread, avoid storing it in a hash table. 2015-09-01 20:33:15 -04:00
Rodrigo Kumpera 76f6d43931 [coop] Fix the state transition for a pending suspend in reset blocking.
The problematic scenario is the following: [1]

thread A) [DO_BLOCKING] runnable -> blocking (0)                      -- i.e, do a pinvoke
thread B) [ASYNC_SUSPEND_REQUESTED] blocking -> blocking (+1)         -- thread B tries to suspend thread A
thread A) [ABORT_BLOCKING] blocking -> async_suspend_requested (0)    -- i.e, that pinvoke called into a reverse delegate and needs to go back to runnable state
thread A) [STATE_POLL] async_suspend_requested -> self_suspended (0)  -- thread A self suspend due to the request from B

If polling witness async suspend, it must notify the initiator of a successful suspend.
If the initiator witness a thread in blocking, it bumps the suspend count, assumes it suspended and don't wait for a notification.

This means that thread A would post to the suspend semaphore but thread B (the suspend initiator) will not wait on it.

Given the initiator won't wait in this case, it makes no sense for abort blocking to put the thread in async_suspend_requested.
The solution is to put it on self_suspend_requested, which won't trigger state_poll to notify.

[1] Read it as: thread) [TRANSITION NAME] old state -> new state (suspend count delta) -- explanation
2015-09-01 19:35:02 -04:00
Rodrigo Kumpera ef860c3258 [coop] Improve logging and add a pair of suspend related due asserts.
Add asserts to both mono_threads_begin_global_suspend and mono_threads_end_global_suspend to ensure
balanced usage of the suspend semaphore.

The suspend semaphore must end a suspend operation at zero, meaning there must an equal number of
post and wait calls.

This ensure the initiator can't jump the gun when waiting for pending suspends by consuming a
post from a previous suspend/resume op.
2015-09-01 19:35:02 -04:00
Rodrigo Kumpera a17e440193 [coop] Fix debug logging. 2015-09-01 19:35:02 -04:00
Alex Rønne Petersen ee2e7de42e [profiler] Emit dummy code start/size info in cases where we can't retrieve it. 2015-09-02 01:34:38 +02:00
Zoltan Varga ac6131483d [runtime] Remove the usage of the GC aware hash table from the tasklets code. 2015-09-01 18:37:43 -04:00
Mark Probst 54ede58d34 [sgen] Properly synchronize allocated_blocks.
We were missing a memory barrier here.  This might fix the current
intermittent crashes on wrench.
2015-09-01 15:04:30 -07:00
Neale Ferguson 2800e7c0f1 Fix IL_SEQPOINT processing; Add names to trampolines 2015-09-01 17:35:06 -04:00
Alex Rønne Petersen e1849e0707 Merge pull request #2015 from alexrp/profiler-roots-v2
[runtime] Add root type and human-readable description for all GC roots.
2015-09-01 23:06:22 +02:00
Zoltan Varga 92a8ca5c14 [runtime] Throw an exception instead of asserting when trying to call remoting methods linked away. 2015-09-01 16:16:54 -04:00
Zoltan Varga 7781cfb144 [bcl] Disable some tests which rely on fp behavior on mobile. (#33510). 2015-09-01 15:09:04 -04:00
Miguel de Icaza b7a06c6582 [Facades] Fix parallel builds for non-general profiles
Joao reported that the facades build broke with 9022df4421
as it tried to compile monodroid assemblies and this attempt to compile System.IO.Pipes
which in turn needs a type not presented on Android: SafePipeHandle

This should fix that
2015-09-01 15:05:42 -04:00
Zoltan Varga f0e244a33e [ppdb] Fix support for Assembly.LoadFrom(). Fixes #33550. 2015-09-01 15:03:47 -04:00
Jonathan Pryor 91f5a2f30b Merge pull request #2012 from joelmartinez/mdoc-memberremoval-fix
[mdoc] Fixes an issue with member deletion.
2015-09-01 14:57:20 -04:00
Joel Martinez 09b97cba2e [mdoc] Fixes an issue with member and type deletion.
Specifically, when updating classic and unified assemblies, members
that were completely removed from one or both assemblies were not
being removed from the XML. This patch updates mdoc's `DeleteMember`
method to properly handle deletion in all scenarios (normal, classic, unified).

Of course, deletion will still not happen if one of two things is true:

- `--delete` is *not* passed into the `mdoc update` call and the member node
  contains existing documentation.
- `--preserve` *is* passed into the `mdoc update` invocation.

In both of those cases, the member will not be deleted, and a message stating
as such will be written as a warning to the output.
2015-09-01 14:52:54 -04:00
Thomas Jepp 2165b4616a Fix bug #33551 - Use a full FQDN for EHLO and HELO in SmtpClient. 2015-09-01 18:46:15 +01:00
Alex Rønne Petersen 253fbf893b Merge pull request #2019 from directhex/powerpc-fixes
Add move_f_to_i4 and move_i4_to_f to PowerPC
2015-09-01 18:51:20 +02:00
Miguel de Icaza 9022df4421 [Facades] Use Zoltan's parallel build infrastructure 2015-09-01 12:37:41 -04:00
Alex Rønne Petersen 21131f7289 [runtime] Add root type and human-readable description for all GC roots. 2015-09-01 14:55:57 +02:00
Marcos Henrich 7bf4333ed3 Reverted too long to run test.
1abf5baf16 added a tests that was making
jenkins to timeout.
2015-09-01 11:42:12 +01:00
Ludovic Henry 0ca93dfcb4 [threadpool-io] Reduce the value of poll_fds_size on socket removal 2015-09-01 12:30:41 +02:00
Lennart Sorensen e59383fe91 Add move_f_to_i4 and move_i4_to_f to PowerPC 2015-09-01 11:20:15 +01:00
Marek Safar 1b91adbd89 [mcs] Remove not implemented from ambiguous static type lookup. Fixes #33527 2015-09-01 11:16:08 +02:00
Marek Safar 38dd20b4b8 Merge pull request #2016 from tpokorra/patch-1
fixing typo appropiate in WebHeaderCollection.cs
2015-09-01 09:59:53 +02:00
Timotheus Pokorra ab67d07a7d fixing typo appropiate in WebHeaderCollection.cs
as mentioned by FastCode in IRC
2015-09-01 09:56:28 +02:00
Zoltan Varga 092fc2a30f Revert "[llvm] Disable support for nested clauses again, it still causes test failures like #32583."
This reverts commit d48d8e93e0.

Revert this as it breaks the build.
2015-08-31 18:48:00 -04:00
Zoltan Varga d48d8e93e0 [llvm] Disable support for nested clauses again, it still causes test failures like #32583. 2015-08-31 18:35:53 -04:00
Mark Probst aa6bc1a8a5 [sgen] When the idle function runs we know it's supposed to run. 2015-08-31 14:25:04 -07:00
Mark Probst aa7a1915bd [sgen] Remove dead workers code. 2015-08-31 14:24:56 -07:00
Mark Probst ac89c19f0f [sgen] Don't stop concurrent mark during nursery collections. 2015-08-31 14:24:46 -07:00
Ludovic Henry 385c7692be [threadpool-io] Remove sparse-array for poll backend
The sparse-array approach led to better insert/remove performance, by allowing a O(1) access, but led to memory consumption issue. The kernel would, for example, have to parse the whole array, even if it's mostly empty, and that can be an issue for large arrays.
2015-08-31 17:39:06 +02:00
Marek Safar abbac3e73b Remove incorrect warnings 2015-08-31 15:22:30 +02:00
Marek Safar fb11d2b71d [mcs] Don't report error for warnings which are not intended to be compiler warnings. Fixes #33487 2015-08-31 14:14:51 +02:00
Marek Safar 8fbf7f3617 [system] WebUtility from reference sources 2015-08-31 13:31:48 +02:00
Marcos Henrich ba1c3758ff [runtime] Removed duplicated code 2015-08-31 10:23:43 +01:00
Alex Rønne Petersen 802a95c8bf [mcs] 'future' option is now 'experimental' - clarify in man page and help text. 2015-08-30 21:19:10 +02:00
Burak Tamtürk 31a14f7d79 Implement SqlDataReader.GetFieldValue<T> in order to fix EF's UpdateException 2015-08-30 15:53:43 +03:00
Marek Safar dc52c56c5f Revert "Merge pull request #2008 from dlech/CustomAttributeData"
This reverts commit 2775839f66, reversing
changes made to 9cf3500204.
2015-08-29 16:24:06 +02:00
Marcos Henrich bd52e33266 Merge pull request #1936 from esdrubal/DotNetRelativeOrAbsolute
[System] UriKind.RelativeOrAbsolute workaround.
2015-08-29 12:24:02 +01:00
Marcos Henrich 2775839f66 Merge pull request #2008 from dlech/CustomAttributeData
Make CustomAttributeData.AttributeType virtual
2015-08-29 10:55:43 +01:00
Marcos Henrich 9cf3500204 Updated list of available MONO_DEBUG options. 2015-08-29 10:44:48 +01:00
David Lechner 489736eded Make CustomAttributeData.AttributeType virtual
According to https://msdn.microsoft.com/en-us/library/system.reflection.customattributedata.attributetype%28v=vs.110%29.aspx, System.Reflection.CustomAttributeData.AttributeType is a virtual property.
2015-08-28 22:07:53 -05:00
Vlad Brezae a394f6b1eb Merge pull request #2005 from BrzVlad/feature-concurrent-work
Concurrent sgen improvements
2015-08-28 18:04:48 -07:00
Vlad Brezae 759ae7ad82 [sgen] Add missing write barriers for the concurrent collector 2015-08-28 18:00:18 -07:00
Vlad Brezae fcd1e6df02 [sgen] Major allocation should not happen while we sweep 2015-08-28 18:00:17 -07:00
Vlad Brezae 2a3afe6b53 [sgen] Enable cementing for concurrent collector 2015-08-28 18:00:17 -07:00
Vlad Brezae 6f990c368f [sgen] Remove the finishing nursery collection within the concurrent collector 2015-08-28 18:00:16 -07:00
Vlad Brezae 80579cc5b8 [sgen] Clear nursery at gc if we are doing concurrent checks 2015-08-28 18:00:16 -07:00
Vlad Brezae 1c5c532f13 [sgen] Fix scanning of invalid entries within arrays 2015-08-28 18:00:14 -07:00
Zoltan Varga 4f994bc55f Merge pull request #2007 from madewokherd/imagelock
Fix an unlock without a corresponding lock.
2015-08-28 15:55:08 -04:00
Vincent Povirk 6cb67df77d Fix an unlock without a corresponding lock.
8eeb2cef moved the lock into an if statement.

This commit is licensed as MIT/X11.
2015-08-28 14:42:00 -05:00
Zoltan Varga 7f7a7f4d8e [runtime] Remove some dead code. 2015-08-28 15:39:25 -04:00
Vlad Brezae 48f2eaedb1 [sgen] Flush after writing the protocol entry 2015-08-28 11:41:42 -07:00
Marcos Henrich a3e273b98b Merge pull request #2004 from esdrubal/singlestacktrace
[corlib] Changes StackTrace.ToString to use Exception format.
2015-08-28 16:26:28 +01:00
Marcos Henrich 4666301cbf [corlib] Changes StackTrace.ToString to use Exception format.
StackTrace.ToString format was different from Exception.ToString.
StackTrace.ToString had an identation of 3 spaces instead of 2, outputed
"line " before the line number which Exception.ToString does not, and it
did not print offsets.

This change allows StackTrace.ToString output to be used by the mono-symbolicate tool.
2015-08-28 15:29:39 +01:00
Marcos Henrich 5bbc0d3507 Test mono-symbolicate with StackTrace.ToString.
We were testing mono-symbolicate tool with Exception.Tostring stack
traces but now we also test that the tool works with StackTrace.ToString.
2015-08-28 15:29:29 +01:00
Martin Baulig 29caa028e1 Merge pull request #2000 from BogdanovKirill/master
Bug fix: reading of infinite web response can lead to connection loss
2015-08-28 16:06:22 +02:00
Marek Habersack 05cbf82010 Remove stray ifdef 2015-08-28 15:19:12 +02:00
Marcos Henrich 0db4b09607 Merge pull request #2003 from esdrubal/seq_test_fix2
[runtime] Fix test_op_il_seq_point in amd64.
2015-08-28 13:21:00 +01:00
Marcos Henrich d6866aa8dd Target test-local in mono-symbolicate Makefile.
mono-symbolicate tests were not called by recursive test due to not having the
target test-local in its Makefile.
2015-08-28 12:48:17 +01:00
Marcos Henrich 5b2e320c1f [runtime] Fix test_op_il_seq_point in amd64.
In amd64 when possible 32bit instructions and registers are usedi
instead of 64bit ones.

Using MONO_DEBUG=single-imm-size avoids 32bit optimizations thus
maintaining the native code size between compilations.
2015-08-28 11:48:51 +01:00
Marcos Henrich 9e0d841872 [runtime] Added MONO_DEBUG=single-imm-size.
In amd64 when i8const are use with values within the first 32 bits
instructions and registers used can be optimized to their 32 bit
versions.

Setting MONO_DEBUG=single-imm-size variable disables such optimizations
and guarantee that the the generated native code size is independent
of the i8const values.
2015-08-28 11:48:51 +01:00
Marek Safar 252908a7d5 [mcs] Bump ikvm to support up to 4GB output files 2015-08-28 09:30:01 +02:00
Zoltan Varga d60aec02dc [gsharedvt] Disable the box+brtrue optimization for gsharedvt types. Fixes #33324. 2015-08-27 16:15:07 -04:00
Jonathan Pryor 535964dc5f [MonoPosixHelper] Fix compilation for Android.
The Android NDK decalres the `struct timeval` struct in <sys/time.h>.
Update sys-socket.c to #include <sys/time.h> to fix compilation
with the Android NDK.
2015-08-27 16:07:43 -04:00
Zoltan Varga d5f6ee9ee3 Fix the build. 2015-08-27 15:52:10 -04:00
Zoltan Varga 6d394c7b4b [x86] Fix fullaot support. 2015-08-27 15:46:39 -04:00
Rodrigo Kumpera 81c3de0381 [coop] Fix the public coop api. 2015-08-27 15:21:48 -04:00
Rodrigo Kumpera 11367d77ab [coop] Blacklist two more wrappers when generating safepoints.
A GC Safepoint require the thread to be in GC unsafe mode to run properly.

Both mono_threads_finish_blocking and mono_threads_reset_blocking_start are called
in GC Safe mode, which would cause them to assert in checked-build.

mono_threads_finish_blocking is called after a pinvoke finished, which means the thread will
still be in blocking mode.

mono_threads_reset_blocking_start is called by reverse pinvoke wrappers before calling managed
code, so it will be in blocking mode too.

This looks like something checked-build should catch by setting the polling variable more frequently.
2015-08-27 15:21:48 -04:00
Rodrigo Kumpera a6001390bf [JIT] Prefer gdb over lldb on OSX as the later still produces useless output on my system. 2015-08-27 15:21:48 -04:00
Jonathan Pryor d715b3d29e Merge pull request #1993 from steffen-kiess/posix-sockets-1
Add socket-related functions and data structures to Mono.Posix
2015-08-27 14:08:47 -04:00
Marcos Henrich 71b57e58c5 Merge pull request #2002 from mono/revert-1991-seq_test_fix
Revert "[runtime] Fix test_op_il_seq_point in amd64."
2015-08-27 17:20:12 +01:00
Marcos Henrich 48c53152bd Revert "[runtime] Fix test_op_il_seq_point in amd64." 2015-08-27 17:03:27 +01:00
Marcos Henrich b273a6b2b5 Merge pull request #2001 from esdrubal/get_module_filename
Fixes get_module_filename.
2015-08-27 17:03:07 +01:00
Marcos Henrich e6b3de99e9 Fixes get_module_filename. 2015-08-27 15:42:35 +01:00
Marcos Henrich 8ae7b6d6b9 Merge pull request #1991 from esdrubal/seq_test_fix
[runtime] Fix test_op_il_seq_point in amd64.
2015-08-27 14:21:54 +01:00
Rodrigo Kumpera ef227267ec [coop] Initial drop of the supporting public API. 2015-08-26 18:29:40 -04:00
Rodrigo Kumpera 192f5f110b [corlib] Fix the mobile test suite. 2015-08-26 18:29:40 -04:00
triton ffa76054a9 [threadpool-io] Fixed the Windows backend to call the correct polling function. 2015-08-26 23:27:44 +01:00
Mark Probst 6efe1eabbc [sgen] Don't access LOS object size directly because it has to be masked.
We use the lowest bit in the LOS object size to denote whether the object is
marked/pinned, so we can't directly use the size.  Use the getter function
instead.
2015-08-26 13:12:50 -07:00
Zoltan Varga c4db814a44 [sdb] Disallow nested invokes. 2015-08-26 15:56:58 -04:00
Alex Rønne Petersen e45a244845 Merge pull request #1999 from rodrmoya/master
Fix format description for TYPE_CONTEXT
2015-08-26 21:54:04 +02:00
Rodrigo Moya 73897714af Fix format description for TYPE_CONTEXT 2015-08-26 21:05:59 +02:00
Zoltan Varga 3b0b4317a2 [llvm] Implement support for GC_SAFE_POINT. 2015-08-26 14:47:28 -04:00
Marcos Henrich 12ba27e62e [corlib] Fixes test not compiling with older NUnit. 2015-08-26 11:03:28 +01:00
BogdanovKirill 1abf5baf16 [WebConnectionStream] Fix connection loss for >2GB reads
When HttpWebRequest is used to download infinite (ContentLength not set) response from web server, we can see that after reading about 2 GB (Int32.MaxValue) of data, totalRead variable can be equal to contentLength (which is int32.MaxValue). Then WebConnectionStream thinks that all data is received (see soft condition totalRead >= contentLength), but this is not correct.

This change is released under the MIT license.
2015-08-26 11:09:15 +05:00
Rodrigo Kumpera ecba1779a0 Merge pull request #1998 from BillSeurer/master
Fix coding error with ! operator in two places in libtest.c
2015-08-25 17:07:08 -04:00
Bill Seurer 5834ac2260 Fix coding error with ! operator in two places. 2015-08-25 16:00:04 -05:00
Martin Baulig 36e40b06f0 Merge pull request #1992 from BogdanovKirill/ChunkedReading
[ChunkStream] CPU and memory leak fix when writing and reading infinitely
2015-08-25 14:52:31 +02:00
Zoltan Varga 3fbd62c767 Merge pull request #1996 from BillSeurer/master
[ppc] Add MonoContext and asynch callback support
2015-08-24 18:22:10 -04:00
Bill Seurer f05362d9a1 [ppc] Add MonoContext and asynch callback support 2015-08-24 17:10:36 -05:00
Zoltan Varga 1da119b61b [runtime] Remove the is_mb_open field from MonoMethod, it doesn't seem to be needed, inflated MethodBuilders are represented by MethodOnTypeBuilderInst objects. 2015-08-24 16:25:44 -04:00
Zoltan Varga 07003038cc [sdb] Remove the code which stopped single stepping when exiting a runtime invoke, it was only enabled on ios/android, and it doesn't seem to be needed anymore. 2015-08-24 16:20:09 -04:00
Ludovic Henry 91c9997fe2 [threadpool-io] Remove unecessary operation change
These 2 operations are going to be treated the same in managed, so the change is useless
2015-08-24 16:03:53 -04:00
Ludovic Henry a3537be364 [threadpool-io] Add log tracing 2015-08-24 16:03:53 -04:00
Ludovic Henry 716ba68c1b [threadpool-io] Rework backend API
The main change is the fd will not be removed from the backend when there is no event to poll, but only when we close the socket. This also reduce the number of functions of the backend.
2015-08-24 16:03:52 -04:00
Ludovic Henry 2e26dfa8bf [threadpool-io] Move the states table to the selector thread exclusively
This greatly simplify the model of the states as we do not need to worry about modifications in different threads.
2015-08-24 16:03:52 -04:00
Ludovic Henry 2fed08cf0d [threadpool-io] Disable AIO by default 2015-08-24 16:03:52 -04:00
Rodrigo Kumpera 040ec4cba9 [coop] Add some TODOs to the stress test suite. 2015-08-24 16:03:52 -04:00
Steffen Kieß d14254989b Add socket-related functions and data structures to Mono.Posix
This commit adds those socket-related functions which do not require the
sockaddr_* structures or the msghdr structure.
2015-08-24 19:42:54 +02:00
Rodrigo Kumpera 83985b4ab6 Merge pull request #1989 from esdrubal/local_tz_from_link
Local tz id from symbolic link
2015-08-24 12:03:44 -04:00
Marcos Henrich e3a2538f4e [runtime] Fix test_op_il_seq_point in amd64.
In amd64 when possible 32bit instructions and registers are usedi
instead of 64bit ones.

Using MONO_DEBUG=single-imm-size avoids 32bit optimizations thus
maintaining the native code size between compilations.
2015-08-24 16:28:37 +01:00
Marcos Henrich 60799f34d7 [runtime] Added MONO_DEBUG=single-imm-size.
In amd64 when i8const are use with values within the first 32 bits
instructions and registers used can be optimized to their 32 bit
versions.

Setting MONO_DEBUG=single-imm-size variable disables such optimizations
and guarantee that the the generated native code size is independent
of the i8const values.
2015-08-24 16:25:31 +01:00
Zoltan Varga 1309cb1059 [runtime] Fix native backtraces with lldb by closing stdin. 2015-08-21 22:00:49 -04:00
Zoltan Varga 92b7b86342 Fix the build. 2015-08-21 18:04:10 -04:00
Zoltan Varga 362df4cc7b [runtime] Implement support for dynamic methods in stack traces in a different way: instead of constructing the stack trace eagerly when it contains a dynamic method, save the list of dynamic methods into the Exception object so they are kept alive. 2015-08-21 17:48:14 -04:00
Marek Safar c6f6383b5f [runtime] Remove eager exception stack construction when it contains dynamic method. Fixes #33064
We used to construct exception stack traces as string at throw site (for dynamic methods) but
that does not work correctly because exception stack trace can be decomposed via
new StackTrace (exception) or merged via ExceptionDispatchInfo both of them need the exception
stack in raw form and not as a string.

Further the format used by local stack builder was not same as format used by
System.Diagnostics.StackTrace.

The orignal reason for the specialization was that dynamic method can be collected
before stack is rendered which leads to stack frame to be reported as

at <unknown method> instead of
at (wrapper dynamic-method)

That should be addressed by gc-link between dynamic method and exception or
stack-frame.
2015-08-21 21:49:20 +02:00
Zoltan Varga 9aa5b08265 [arm64] Add gc_safe_point to cpu-arm64.md. 2015-08-21 14:15:24 -04:00
Rodrigo Kumpera 8bface12c1 [jit] Enable OP_GC_SAFE_POINT on ARM64 2015-08-21 13:48:47 -04:00
Rodrigo Kumpera 3e5826dcdc [Facades] xammac_net_4_5 needs the reflection facades. 2015-08-21 13:19:17 -04:00
Rodrigo Kumpera 971be95987 [BCL] Fix xammac_4_5 build of the Facades. 2015-08-20 20:07:46 -04:00
Rodrigo Kumpera c86f4125dc [BCL] Partial compilation fix for xammac_4_5. Facades still busted. 2015-08-20 19:48:15 -04:00
Rodrigo Kumpera 192ad58a64 [arm64] Fix MONO_CONTEXT_GET_CURRENT so it can be used multiple times in the same compilation unit. 2015-08-20 17:31:07 -04:00
Marek Safar 8f60a2cc74 Fixes build of xammac new facades 2015-08-20 23:27:11 +02:00
Zoltan Varga 769f08b6e4 [coop] Avoid polling in the mono_thread_interruption_checkpoint () icall wrapper, it could lead to infinite recursion if the polling flag is not cleared fast enough. 2015-08-20 16:46:43 -04:00
Zoltan Varga c2e2a49479 [coop] Avoid taking the gc lock when rehashing mono_g_hash tables, its not needed with the coop gc since the gc cannot preempnt that code. 2015-08-20 14:04:25 -04:00
Zoltan Varga 1efb5b5f3c [coop] Enter blocking mode before waiting on a condvar in the threadpool code. 2015-08-20 13:37:16 -04:00
Marek Safar 0806ff5baf Fixes mobile build 2015-08-20 15:40:26 +02:00
BogdanovKirill bf38b37529 [ChunkStream] CPU and memory leak fix when writing and reading infinitely
The problem is connected with "chunks" field in ChunkStream class. As you can see in "ReadFromChunks" method, the number of elements of this array continuously grows, because array's elements are not removed but just set to null. So, every subsequent call of this method will be slower than previous and will use additional memory more and more infinitely. Yes, we have "ResetBuffer" method than could clear "chunks" array, but nobody call it when the connection is infinite.

This change is released under the MIT license.
2015-08-20 16:16:48 +05:00
Marek Safar 8721a9ccc3 Merge pull request #1990 from akoeplinger/fix-getsystemtimezone-reflection
[corlib] Rename private method in TimeZoneInfo to avoid conflict with public one via reflection
2015-08-20 10:10:05 +02:00
Alexander Köplinger 66372b91ac [corlib] Rename private method in TimeZoneInfo to avoid conflict with public one via reflection
A private overload of the public GetSystemTimeZones() method was added in 4dc9a90d7f.
This broke code that tried to access that method via reflection and expected that there be only one.

Fixing this by renaming the private method to GetSystemTimeZonesCore (which is also more aligned with FindSystemTimeZoneByIdCore).
2015-08-20 04:41:41 +02:00
Rodrigo Kumpera 0de923cb67 [coop] We call into the GC holding the appdomain mutex. Suspend around locking. 2015-08-19 19:22:43 -04:00
João Matos 8332a48ce4 [System] Remove MonoSyncFileStream.cs from mobile sources. 2015-08-20 00:09:34 +01:00
Zoltan Varga a87a08062d Revert "[coop] Disable exception checks in mono_threads_state_poll (), it could lead to infinite recursion."
This reverts commit 2790501f69.

Revert this as it causes corlib tests to hang.
2015-08-19 18:32:40 -04:00
Rodrigo Kumpera d4082dffbd [coop] mono_gc_register_for_finalization does block, so guard against it. 2015-08-19 17:14:45 -04:00
Zoltan Varga 964518e1a1 [coop] Avoid doing polling in native-to-managed wrappers, the poll can trigger before reset_blocking is executed. 2015-08-19 17:03:42 -04:00
Rodrigo Kumpera 85c134c427 [coop] Add stress test. It still beats me. 2015-08-19 15:32:22 -04:00
Rodrigo Kumpera 90883a6c15 [coop] The sgen_interruption mutex can be taken in unsafe mode, so we need to suspend around it. 2015-08-19 15:31:39 -04:00
Marek Safar ce89d264dc [corlib] Add underlying Console stream specialization to FileStream 2015-08-19 17:18:54 +02:00
João Matos 8b51c80715 [runtime] Fixed AArch64 Android cross-compilation build.
This was introduced by https://github.com/mono/mono/commit/5604e0b5940a1df7059d11158b36fbde9a3c056d.

For some reason we were getting duplicate assembly labels, this fixes it.

```[8:45:15] /var/folders/hv/lh9y7pps1vbfsc737h_nl4mh0000gp/T//cczYhnuB.s: Assembler messages:
[8:45:15] /var/folders/hv/lh9y7pps1vbfsc737h_nl4mh0000gp/T//cczYhnuB.s:9012: Error: symbol `L0' is already defined
[8:45:15] make[7]: *** [libmini_la-mini-exceptions.lo] Error 1
[8:45:15] make[7]: *** Waiting for unfinished jobs....```
2015-08-19 14:56:23 +01:00
Marek Safar 2309cc50a9 [corlib] Remove unused icall 2015-08-19 14:13:04 +02:00
Marek Safar 0abfec747e [corlib] Remove unused file 2015-08-19 14:13:03 +02:00
Marek Safar 70a295d1fe [system] Add a workaround for redirected StandardInput writes. Fixes #32905 2015-08-19 14:13:03 +02:00
Marek Safar 0d724812ab [System] Refactor Process start to better control pipes flow 2015-08-19 14:13:03 +02:00
Marek Safar 789808b507 [system] Simplify process redirection initialization 2015-08-19 14:13:03 +02:00
Marek Safar fa51f28613 [corlib] Add FileStream safe handle argument check 2015-08-19 14:13:02 +02:00
Martin Baulig dd40925cbb [WFC]: Fix yesterday's commit.
We actually don't need the length check here.  The only place where
the 'ref parameters' could possibly be replaced is at the end of the
private Request() method - to remove the 'IAsyncResult' argument from
and End*() method.

This fixes commit 0b1360c8e3 and bug #32886.

(cherry picked from commit 1d2c58215f)
2015-08-19 13:20:29 +02:00
Zoltan Varga 957e4e4d22 Fix a crash introduced by e2037b583b. 2015-08-18 20:00:53 -04:00
Rodrigo Kumpera c1e41fa46d [coop] On OSX, set native_handle to the mac port. 2015-08-18 19:08:21 -04:00
Rodrigo Kumpera 2c67cb8996 [jit] Print thread information when doing a gdb crash dump 2015-08-18 19:08:21 -04:00
Rodrigo Kumpera 97bcec124b [build] Add execv to configure.ac, the runtime now needs it. 2015-08-18 19:08:21 -04:00
Zoltan Varga 30a3b9201d [sdb] Fix the handling of strings with embedded null values. Fixes #33066. 2015-08-18 17:18:25 -04:00
Zoltan Varga 1ef694ae52 [jit] Emit the results of the jit regressions tests in nunit format only when running under jenkins. 2015-08-18 14:44:50 -04:00
Zoltan Varga 00562364af Merge pull request #1983 from saper/noeglibstatic
Do not build libeglib-static.a
2015-08-18 14:38:45 -04:00
Zoltan Varga 97f13ae334 [runtime] Use the thread_get_tid () in more places. 2015-08-18 14:38:29 -04:00
Zoltan Varga 6c4e266e75 Revert "[coop] Avoid taking the gc lock when rehashing mono_g_hash tables, its not needed with the coop gc since the gc cannot preempnt that code."
This reverts commit ab7929448c.

Revert this to see if it fixes wrench failures.
2015-08-18 14:30:46 -04:00
Martin Baulig 57ef8f9614 [WCF]: Fix non-byref parameters; bug #32886.
(cherry picked from commit 0b1360c8e3)
2015-08-18 20:02:25 +02:00
Marcos Henrich 06bdf2998e Improved TimeZoneInfo.Local.Id
TimeZoneInfo.Local.Id now returns a Olson id when "/etc/localtime" is a
symbolicate link instead of "Local".

Fixes #24958.
2015-08-18 17:44:00 +01:00
Marcos Henrich 645c77f9b6 Test TimeZoneInfo.Local.Id
Ideally TimeZoneInfo.Local.Id should not be equal to "Local" when
/etc/localtime is a symbolic link. Covers #24958.
2015-08-18 17:39:48 +01:00
Zoltan Varga ab33e42673 Merge pull request #1988 from BillSeurer/master
[ppc] Basic changes to allow mono to build and run on power BE
2015-08-18 11:20:53 -04:00
Bill Seurer 8332185abf [ppc] Basic changes to allow mono to build and run on power BE 2015-08-18 09:36:23 -05:00
Marek Habersack d92ab815ca [tests] Disable a Unix signal test on Android
The test causes the runtime to silently crash in fashion similar to what
real-time signals do to the runtime (a segfault without a single trace
of a crash, causing the process to just hang)
2015-08-18 14:56:55 +02:00
ash-lshift 71f7cda39a [WindowsBase] Fix PackagePart.GetRelationships for readonly files
Do not throw an exception when we are creating the PackageRelationship.
We should only do that if the user tries to add a new one.

Fixes https://bugzilla.novell.com/show_bug.cgi?id=675379
2015-08-18 09:30:42 -03:00
Rodrigo Kumpera 79b2dea837 [test-suite] Enable sgen test that forgot to be added. 2015-08-18 02:49:55 -04:00
Rodrigo Kumpera 03d9b259d1 [coop] Wrap thread initialization start wait code in a GC safe block.
This is needed since the starting thread might block in the threads_lock
waiting for a GC to finish before posting to the completed semaphore.

This will cause the thread creating it to block indefinitely.
2015-08-18 02:49:54 -04:00
Rodrigo Kumpera 835b6b9e51 [coop] Code calls into the GC while holding the handles lock. Wrap it around a MONO_TRY_BLOCKING. 2015-08-18 02:49:02 -04:00
Rodrigo Kumpera 37450eef31 [checked-build] Adjust the assertof mono_runtime_class_init. 2015-08-18 01:24:46 -04:00
Rodrigo Kumpera f15af85b5f [coop] mono_thread_info_suspend_lock is a non-leaf lock so we need to checkpoint around it so it works with coop.
mono_thread_info_suspend_lock is, on first sight, a leaf lock. But since it can suspend a thread that is holding other locks,
it has the same global effect of one.
2015-08-18 01:23:45 -04:00
Rodrigo Kumpera 788b21e581 [checked-build] Add a check in mono-hash for the right GC mode. 2015-08-18 01:19:43 -04:00
Rodrigo Kumpera bcf9ca18bf add some assets to reflection.c 2015-08-18 00:48:41 -04:00
Zoltan Varga 6c10d83b8f [coop] Mark the locking in mono_thread_info_safe_suspend_and_run () as blocking, it can block during an stw. 2015-08-17 19:32:34 -04:00
Zoltan Varga 6945bdb3a9 [coop] Shorten the blocking section in threadpool cleanup. 2015-08-17 18:35:53 -04:00
Zoltan Varga 2790501f69 [coop] Disable exception checks in mono_threads_state_poll (), it could lead to infinite recursion. 2015-08-17 16:45:27 -04:00
Alexis Christoforides e18c1fda5d [lock tracer] Initialize all of frame array 2015-08-17 16:37:29 -04:00
Zoltan Varga ab7929448c [coop] Avoid taking the gc lock when rehashing mono_g_hash tables, its not needed with the coop gc since the gc cannot preempnt that code. 2015-08-17 15:21:45 -04:00
triton 5499df27a1 [msvc] Remove 64-bit/SGen build specific DLL export definition file. 2015-08-17 19:32:33 +01:00
triton 5c74fea481 [msvc] Update the DLL export definition files. 2015-08-17 19:31:04 +01:00
triton 1747c03a06 [runtime] Fixed Valgrind support to compile against Win64. 2015-08-17 19:30:20 +01:00
triton 7c07d1d240 [runtime] Fixed sgen_suspend_thread to work with Win64 MonoContext. 2015-08-17 19:28:44 +01:00
João Matos 714feff880 Merge pull request #1967 from D-POWER/master
Fixed MSVC solution to compile straight out of the box
2015-08-17 18:05:35 +01:00
Marek Safar ac2c41ea09 [system] Keep excluded socket mobile tests in sync 2015-08-17 18:46:45 +02:00
Marek Safar b25feccd11 [corlib] Update incorrect test 2015-08-17 16:30:03 +02:00
Marek Safar b7621d2bb2 [corlib] Propagate captured ExceptionDispatchInfo to user's StackTrace copies. Fixes #32918 2015-08-17 16:27:26 +02:00
Rodrigo Kumpera 3ff51a5d1f Merge pull request #1870 from saper/langinfo_h
[eglib] Prefer <langinfo.h> to <localcharset.h>
2015-08-17 09:39:49 -04:00
Marek Safar 6acc7828e7 [mcs] Reduced statement expressions can still be used as statements. Fixes #33142 2015-08-17 11:43:47 +02:00
Zoltan Varga 5f2004ee16 [jit] Avoid taking the domain lock in mono_icall_get_wrapper_full (), do most work outside the loader lock. 2015-08-16 19:41:04 -04:00
Zoltan Varga 52e117771d [runtime] Remove unused mono_delegate_section variable. 2015-08-16 19:32:07 -04:00
Zoltan Varga 7af939b0cf [runtime] Change a few g_assert (foo != NULL) to g_assert (foo). 2015-08-16 19:22:55 -04:00
Zoltan Varga 3d1a25283d [coop] Make type_initialization_lock () a blocking lock, since some critical sections protected by it can block. Reorganize mono_runtime_class_init_full (), avoid putting the majority of the function inside an if. 2015-08-16 19:22:55 -04:00
Zoltan Varga 8166ed6b71 [coop] Make threadpool->active_threads_lock a blocking lock, since some critical sections protected by it can block. 2015-08-16 19:22:55 -04:00
Zoltan Varga f574556444 Merge pull request #1981 from akoeplinger/ilasm
[ilasm] Add stubs for the "legacy library" and "auto" keywords in .assembly
2015-08-16 16:42:28 -04:00
Marcin Cieslak 27b7c308b3 Do not build libeglib-static.a
1) libeglib.a is already a static library
2) It is not used anywhere, unlike other lib*-static.a
   libraries in the Mono runtime
2015-08-16 20:14:01 +00:00
Alexander Köplinger c7ff3b0829 [ilasm] Add stubs for the "auto" keyword in .assembly
Example IL: ".assembly extern mscorlib {auto}"
2015-08-16 17:59:37 +02:00
Alexander Köplinger c8d474bef3 [ilasm] Add stubs for the "legacy library" keyword in .assembly
Example IL:

".assembly extern legacy library mscorlib {}"
".assembly legacy library test {}"
2015-08-16 17:59:36 +02:00
Zoltan Varga e71bf630bc [bcl] Fix test failures in the System.ServiceModel tests after 9ffb681d06. 2015-08-15 22:26:59 -04:00
Zoltan Varga 537c551991 Merge pull request #1979 from kumpera/conc_fix
[utils] Change mono_conc_hashtable write operations to rely on external locking.
2015-08-15 21:54:56 -04:00
Zoltan Varga da8fbf7e60 Merge pull request #1980 from akoeplinger/fix-monoevent
[corlib] Implement MonoEvent Module property
2015-08-15 14:21:51 -04:00
Alexander Köplinger a7b43b9a35 [corlib] Implement MonoEvent Module property
Add tests for Event-, Method- and ConstructorInfo to verify accessing .Module works (the latter two already worked before this change).
2015-08-15 20:05:11 +02:00
Rodrigo Kumpera d164e49e07 [utils] Change mono_conc_hashtable write operations to rely on external locking.
The original design was to pass a lock to the mono_conc_hashtable constructor and
then the write operations would do locking themselves.

That turned out to be a problem for two reasons:

First, it hidden the fact that locking was happening. Every other data structure in
the runtime rely on the caller to perform locking - thus that design ended up been
a lie.

Second, under coop, taking the lock became a problem as leak locks should be taken
in GC Safe mode and other locks should be taken under GC Unsafe mode. Taking a lock
in the wrong GC mode makes the suspend watchdog bark really loudly.

The runtime, funny enough has 2 usages of the conc hashtable, one with the image lock
and one with the domain lock - and each must be taken in a different GC mode. That
meant that either overcomplicating the design, or just removing locking from it.

This commit does that. It removes the mutex from mono_conc_hashtable and hoist locking
around the calls that used to do it.
2015-08-15 00:46:37 -04:00
Zoltan Varga 321e08e5ee [jit] Reorganize the code in mini.c to reduce the number of DISABLE_JIT blocks. 2015-08-15 00:37:12 -04:00
Zoltan Varga 420925cb1b [jit] Remove some dead code. 2015-08-14 23:12:03 -04:00
Zoltan Varga 0916de42bd [sdb] Document the locks protecting various data structures. 2015-08-14 23:02:53 -04:00
Zoltan Varga f56dbd8bdd [sdb] Simplify the locking in set_breakpoint() a bit. 2015-08-14 22:55:58 -04:00
Zoltan Varga 4ea0323445 [sdb] Revert 6f41607cc3, simplify the code inside the domain lock instead. 2015-08-14 22:50:57 -04:00
Zoltan Varga 6f41607cc3 [sdb] Protect MonoJitDomainInfo->seq_points by the loader lock instead of the domain dock, since accesses to it from sdb are not simple code paths. 2015-08-14 22:24:58 -04:00
Zoltan Varga e2037b583b [sdb] Make the locking simpler and finer grained. 2015-08-14 22:10:21 -04:00
Zoltan Varga 8eeb2cef8f [runtime] Initialize the class name cache using double checked locking. 2015-08-14 19:02:24 -04:00
Zoltan Varga ec96b3ac55 [gsharedvt] Don't pass non-variable size gsharedvt types by ref. Fixes #32931. 2015-08-14 18:50:05 -04:00
Zoltan Varga 8ece42b8e8 [jit] Fix a crash by using mono_field_get_type () instead of accessing field->type directly. Fixes #32907. 2015-08-14 18:36:54 -04:00
Rodrigo Kumpera 4304488359 [coop] Fix ves_icall_System_IO_MonoIO_GetFileSystemEntries.
We were calling mono_string_to_utf8 while in GC safe mode.

It's technically ok'ish to do it as it will probably be pinned by the called, but
we're better off by reducing the surface as much as we can.
2015-08-14 17:17:34 -04:00
Rodrigo Kumpera f820615c29 [coop] Fix crasher during shutdown initialization.
Make it possible to suspend the main thread when starting the shutdown of the thread pool.

The problem is that cleanup can take an unbound amount of time.
2015-08-14 17:17:34 -04:00
Rodrigo Kumpera b684bd32e0 [coop] Add a workaround in mono_marshal_get_thunk_invoke_wrapper.
This is a workaround until we figure out what to do with the embedding API.

We ensure we transition the executed managed code into unsafe mode.

Maybe the right call would be to assert if the caller is not already on it, but that's too soon of a decision to make.
2015-08-14 17:17:33 -04:00
Rodrigo Kumpera ecb3d6a650 [coop] Fix coop support for mono_method_get_unmanaged_thunk.
Ensure we create the wrapper in GC Unsafe mode, which is the default one for runtime code.
2015-08-14 17:17:32 -04:00
Rodrigo Kumpera aaf0c8bced [checked-build] Annotate object.c with GC state asserts. 2015-08-14 17:17:32 -04:00
Rodrigo Kumpera 8f118cb416 [coop] Add performance counters for frequent transitions. 2015-08-14 17:17:31 -04:00
Rodrigo Kumpera fd19481460 [checked-build] Initial implementation of checked build asserts.
To enable checked builds pass --with-checked-build=yes to autogen/configure.

The current set of checked build macros verify the GC state on function entry.
2015-08-14 17:17:24 -04:00
Rodrigo Kumpera 1786498006 [threads] Add function to stringify thread state names. 2015-08-14 16:28:21 -04:00
Rodrigo Kumpera bbfaf5cdbd [coop] Make state-machine asserts print the tid as it's the same used by other parts of the runtime. 2015-08-14 16:28:20 -04:00
Zoltan Varga b76558e80f [arm] Add support for split reg-stack argument passing to the dyn call code. Fixes #33080. 2015-08-14 14:05:28 -04:00
Rolf Bjarne Kvinge c4ab096d90 Fix configure.ac to detect WatchOS and define TARGET_WATCHOS. 2015-08-14 18:57:50 +02:00
Marcos Henrich 6723d1e5cc Merge pull request #1972 from esdrubal/proc_pidpath
[runtime] GetModuleFileNameEx
2015-08-14 10:08:23 +01:00
Alex Rønne Petersen aeccef382b Merge pull request #1975 from alexrp/profiler-gch-bt
[profiler] Add GC handle events with backtraces.
2015-08-14 10:44:56 +02:00
Sebastien Pouliot 7c422578bc [tests] Remove CWL from test catch clause as it can be confused with a real error [#32593] 2015-08-13 16:45:00 -04:00
Ludovic Henry 92a0ac52a7 [referencesource] Import System.Math 2015-08-13 16:44:51 -03:00
Rolf Bjarne Kvinge 7693e3dff3 Add specific configure option to enable the WatchOS BCL libraries. 2015-08-13 18:31:28 +02:00
Rolf Bjarne Kvinge 8058ef2af9 Build an initial version of System.Net.Http.dll for monotouch as part of the regular BCL build.
We have Facade assemblies that depend on System.Net.Http.dll to exist, so
we can't delay building it (at least one version of it).
2015-08-13 18:31:28 +02:00
João Matos a803711c2e Added support for WatchOS's armv7k to configure.ac. 2015-08-13 16:57:19 +01:00
Marek Habersack 7fe7f93188 Posix RTS test fixes and Android compatibility
Android's libc (bionic) defines the _GNU_SOURCE macro but fails to adhere
to the GNU sematics in (at least) one case - the strerror_r function.
The function follows XSI semantics instead of the GNU one which caused our
code to segfault on Android. This patch special-cases Android to use the XSI
semantics for strerror_r. This un-breaks some POSX real-time singals tests.

It also makes provisions for detecting whether the real-time signals are safe
to use on the current platform. They are safe for all platforms desktop Mono
runs on, but they're not safe on most Android platforms.
2015-08-13 11:53:28 +02:00
Marek Safar 5511b94946 [corlib] Remove unused code 2015-08-13 11:17:25 +02:00
Alex Rønne Petersen d055d688d9 [profiler] Add GC handle events with backtraces. 2015-08-12 08:44:57 +02:00
Alex Rønne Petersen a8cb543870 [profiler] Remove CodeAnalyst profiler module.
This product has been discontinued by AMD and we don't even have support for
building this profiler module in the build system anyway; chances are pretty
good that bitrot has set in.
2015-08-12 06:28:16 +02:00
Zoltan Varga af913d7c00 [jit] Add another suspend check to the JIT. 2015-08-11 22:26:56 -04:00
Zoltan Varga 68f9771cee [jit] Avoid asserts during stack walks if the thread is not attached. 2015-08-11 21:49:45 -04:00
Zoltan Varga 534bb6eaa0 [runtime] Make sure Monitor.Enter () is always inlined since it consists only of a call to an icall. 2015-08-11 21:11:40 -04:00
Zoltan Varga 08ed9b94b0 [aot] Fix the calculate of the llvm code range for aot image with only 1 llvm method. 2015-08-11 15:54:14 -04:00
Jo Shields cdb098617a Un-revoke fix in BNC#144655 - mono-find-provides should ONLY work on GAC libraries, and any packages which break on this behaviour should be fixed - rather than generating utterly broken Provides.
(cherry picked from commit 1f4133a06f252ec1b78637dd91e49f50836cf570)
2015-08-11 19:43:34 +01:00
Zoltan Varga bf8f49aa7a [runtime] Move the kevent() calls from KeventWatcher to the runtime, add support for interrupts. 2015-08-11 14:37:59 -04:00
Ludovic Henry 2945191b72 Merge pull request #1973 from rolfbjarne/bug32947
[threadpool-ms-io] Remove unnecessary asserts. Fixes #32947.
2015-08-11 14:20:36 -03:00
Rolf Bjarne Kvinge 880134db57 [threadpool-ms-io] Remove unnecessary asserts. Fixes #32947.
Neither is_socket_async_callback nor is_async_read_handler need to
actually successfully load the classes they're comparing against;
if the classes can't be loaded, then the input class is obviously
not of that class.

This occurs when mscorlib is linked, the classes to compare against
might be linked away.

https://bugzilla.xamarin.com/show_bug.cgi?id=32947
2015-08-11 15:11:56 +02:00
Marcos Henrich 5fd7d17911 [runtime] GetModuleFileNameEx
GetModuleFileNameEx now returns a full path instead of the process name.
Fixes #32579
2015-08-11 13:36:19 +01:00
Marcos Henrich 6fc86ee499 Merge pull request #1952 from esdrubal/proc_name
Fixes process names trimmed to 15 chars.
2015-08-11 13:10:27 +01:00
Zoltan Varga b8d1ccd159 [coop] Handle blocking in parked threads correctly. 2015-08-10 23:20:43 -04:00
Zoltan Varga c2c0008b8d [runtime] Add a missing MONO_FINISH_BLOCKING to ves_icall_System_Net_Dns_GetHostByName_internal. 2015-08-10 22:20:10 -04:00
Zoltan Varga 42456cda16 [jit] Emit the seq point for filter clauses after the op_get_exc instruction. 2015-08-10 20:55:32 -04:00
Zoltan Varga 00ef87ab6d Revert "[runtime] Move the kevent() calls from KeventWatcher to the runtime, add support for interrupts."
This reverts commit 7f44281658.

Revert this as icalls don't marshal kevent structures correctly.
2015-08-10 15:51:39 -04:00
Zoltan Varga 94b3fd4bd4 [runtime] Remove some debug printfs. 2015-08-10 15:25:03 -04:00
Zoltan Varga 80a69d2d61 [coop] Fix a crash introduced by edb4d8f3fa, some wrappers don't have wrapper infos. 2015-08-10 14:33:30 -04:00
Zoltan Varga 7f44281658 [runtime] Move the kevent() calls from KeventWatcher to the runtime, add support for interrupts. 2015-08-10 14:32:37 -04:00
Marcos Henrich 5b7a67e75c Fixes process names trimmed to 15 chars.
Process names were trimmed to 15 characters. proc_name was used to
retrieve the process name, by looking at its implementation we can see
that it returns a buffer which the size is MAXCOMLEN defined as 16.

When the proc_name result length is equal to 15 (MAXCOMLEN - 1) we now check if
proc_pidpath is able to return a longer process name.

Fixes #32539.
2015-08-10 17:53:36 +01:00
Rodrigo Kumpera 86df0d572b [coop] Fix MONO_SUSPEND_CHECK to use the right variable name. 2015-08-10 10:41:24 -04:00
Rodrigo Kumpera fcabe9f8c4 [coop] Cue card now mentions that blocking has a suspend count. 2015-08-10 10:25:22 -04:00
Rodrigo Kumpera edb4d8f3fa [coop] Don't emit safepoints in the wrapper of the polling function.
Otherwise during a collection the wrapper would call itself resulting
in a stack overflow.
2015-08-10 10:25:21 -04:00
Rodrigo Kumpera 1aa908eea8 [coop] Switch from thread_state_init_from_sigctx to thread_state_init.
Suspend needs to work in the intermediate state where the mono-thread
is attached but not the managed thread. This happens in the startup
and cleanup paths and leads to crashes there.

The suspend initiator is now responsible to check if the thread is
attached or not. Which is easy, just check lmf/jit_tls.
2015-08-10 10:25:16 -04:00
Rodrigo Kumpera 5604e0b594 [coop] Add thread_state_init that initializes the thread from the current stack state.
This new function works differently that others in that it always succeed, but might
provide incomplete data in some cases - like when the thread is not attached.
2015-08-10 10:23:18 -04:00
Rodrigo Kumpera 21e9c31515 [coop] Attach mono-thread as early as possible.
This makes early suspend checks work. This makes it easier
to debug suspend errors by asserting on suspend fails.
2015-08-10 10:23:18 -04:00
Rodrigo Kumpera bac9f672d9 [configure] Add checked build configure option. 2015-08-10 10:23:17 -04:00
Marek Safar 1304fc1546 [corlib] Handle Module in RuntimePropertyInfo. Fixes #32815 2015-08-10 13:03:44 +02:00
Marek Safar 87141d4dfc [mcs] Fix string interpolation parsing where inner expression contains { } tokens. Fixes #32832 2015-08-10 11:14:22 +02:00
Zoltan Varga 906ff55485 [runtime] Remove an unused functions. 2015-08-08 22:39:13 -04:00
Zoltan Varga b14fb40983 [runtime] Mark mono_monitor_try_enter_internal () as inline. 2015-08-08 22:39:00 -04:00
Zoltan Varga f68990d7c1 [runtime] Make synchronized methods use the Monitor.Enter(object,bool&) overload. 2015-08-08 22:31:52 -04:00
Zoltan Varga c5d8245246 [runtime] Fix the coop build on posix platforms. 2015-08-08 22:44:06 +00:00
Zoltan Varga 3d265f8dae [arm] Implement support for gc safe points. 2015-08-08 22:43:42 +00:00
Zoltan Varga 02c6b4430c [runtime] Remove mono_g_hash_table_new (), use mono_g_hash_table_new_type () instead. 2015-08-08 18:08:21 -04:00
Zoltan Varga 6bb06993a7 [runtime] Use a GHashTable instead of a MonoGHashTable in mono_class_from_name (), the hash table doesn't need to be GC aware. 2015-08-08 18:00:24 -04:00
Zoltan Varga d4024a4b55 [runtime] Remove the sgen_supported conditional from configure, we don't support architectures which don't have SGEN. 2015-08-08 13:36:00 -04:00
Marek Safar b99720966a Merge pull request #1968 from LogosBible/uribuilder-no-hostname
Fix UriBuilder.ToString() when the host is empty.
2015-08-08 09:00:21 +02:00
Zoltan Varga 46097ccbb1 Fix the build. 2015-08-07 22:22:31 -04:00
Zoltan Varga 83ca9ffc5d [jit] Add a suspect check into the middle of the JIT pipeline. 2015-08-07 20:40:39 -04:00
Zoltan Varga 6caa50dedb [runtime] Revert part of the previous commit to avoid the profiler crashing. 2015-08-07 16:11:16 -04:00
Zoltan Varga 0061a4f02e [runtime] Avoid passing gshared methods to clients of the embedding api. 2015-08-07 16:04:28 -04:00
Ludovic Henry ef760317a2 [runtime] Fix missing method at link time 2015-08-07 09:52:30 -04:00
sdridi 8c455550ab [Windows-VS2013] Added a post-build event to libmono that copies all required header files to a directory named include 2015-08-07 10:05:47 +01:00
Rolf Bjarne Kvinge 427d42aa51 Add a conditional for fork and exec* functions.
They're not available on WatchOS.
2015-08-07 10:56:21 +02:00
Zoltan Varga b22a4c2ffa [runtime] Avoid a memory overflow in Buffer.InternalBlockCopy () if the caller passes in a negative value by mistake. 2015-08-06 22:15:30 -04:00
Zoltan Varga f025dd445c [runtime] Remove some dead code. 2015-08-06 19:18:55 -04:00
Ludovic Henry abad8aaabd [runtime] Fix memory corruption due to incorrect use of MONO_OBJECT_SETREF
MONO_OBJECT_SETREF would use mono_gc_wbarrier_set_field which would write over 8 bytes ( *(void**)field = value ), while we want to write over 1 byte here.
2015-08-06 14:59:59 -04:00
Dave Dunkin b948e9c030 Add UriBuilder test for no hostname. 2015-08-06 11:55:46 -07:00
Martin Potter d3c8479b4e Uri.ShemeDelimiter should not be used when the host is empty. 2015-08-06 11:49:10 -07:00
João Matos 6a49f28fed Merge pull request #1966 from angeloc/master
Better handling of vasprintf checking
2015-08-06 13:22:20 +01:00
sdridi 47bdf35be9 Fixed MSVC solution to compile straight out of the box 2015-08-06 10:29:44 +01:00
Angelo Compagnucci 0bf6490145 Better handling of vasprintf checking
This patch improves the handling of vasprint checking. 
It switches the unneeded have_vasprintf variable with the
AC_CHECK_FUNCS defined ac_cv_func_vasprintf one.
2015-08-06 09:36:36 +02:00
Zoltan Varga 1db071a9e5 Merge pull request #1965 from akoeplinger/fix-flaky-test
[System.ServiceModel] Fix flaky Bug652331_2 test
2015-08-05 19:09:39 -04:00
Alexander Köplinger 66cf5d6247 [System.ServiceModel] Fix flaky Bug652331_2 test
The test sometimes failed on Jenkins with the timeout assert. Running only this single test locally
with `make check TESTNAME=System.ServiceModel.Dispatcher.Bug652331Test.Bug652331_2` however reproduced
this almost every single time.

It seems that WCF takes a bit to initialize until it accepts connections, so putting a little sleep
fixed this for me locally and running it in a loop for half an hour didn't assert even once.
2015-08-05 20:09:32 +02:00
João Matos b4357e8f6e [runtime] Re-enable the soft debugger on x86 without presence of signals.
As of b76665b848 the debugger does not rely on signals anymore for stepping.
2015-08-05 17:49:39 +01:00
João Matos 70b795cfd8 [sgen] Do not use Mach OS initialisation if using coop GC. 2015-08-05 17:47:06 +01:00
Ludovic Henry 435d21f5b1 [runtime] Add testing for unhandled exception 2015-08-05 09:18:51 -04:00
Ludovic Henry 9ffb681d06 [runtime] Refactor AsyncResult.Invoke icall and swallow exception on AsyncCallback
The swallowed exception is the behavior we can observe on .NET and Mono 4.0
2015-08-05 09:18:51 -04:00
João Matos 40c171799b Merge pull request #1963 from angeloc/patch-1
Fixing initialization of have_vasprintf
2015-08-05 12:50:16 +01:00
Angelo Compagnucci 1c3d615d93 Fixing initialization of have_vasprintf
This patch initialize properly have_vasprintf in case vasprint function is found.
Solves multiple definition of `vasprintf' error in case vasprint is not properly detected.
2015-08-05 12:59:45 +02:00
Marek Safar dc7031cabb [system.net.http] Add special handling for chunked transfer-encoding httpwebrequest initialization. Fixes #31877 2015-08-05 10:10:53 +02:00
Zoltan Varga bf325fe42e Fix the build. 2015-08-04 23:01:56 -04:00
Zoltan Varga b76665b848 [sdb] Transition to using sdb trampolines instead of signals for single stepping/breakpoints. 2015-08-04 22:59:12 -04:00
Zoltan Varga f5e1f9d185 [sdb] Improve logging a bit. 2015-08-04 22:37:12 -04:00
Rodrigo Kumpera 5f63f86d45 [runtime] Reenable Frak TLS on OSX 2015-08-04 22:04:36 -04:00
Ludovic Henry 1354dc1044 [bcl] Remove old ThreadPool managed class 2015-08-04 18:36:39 -04:00
Vlad Brezae c77aacb14f [tests] MonoThreadsSync structures are no longer allocated at the first Enter.
Overflow the nest count in order to achieve the same effect.
2015-08-04 15:02:05 -04:00
Vlad Brezae 49905c7b2d Throw exception when trying to unlock unowned lock. 2015-08-04 15:02:01 -04:00
Vlad Brezae 9033c85ce4 Unmanaged thin lock implementation.
This commit avoids allocation of new MonoThreadsSync structures for the typical cases of shallow nesting of uncontended locks. The necessary information (owner, nest and status bits) is embedded in the synchronisation field of a MonoObject. The lock is inflated when the nest overflows or when there is contention on the lock.

This greatly improves performance (over 10 times) for the case of locking a lock only a few times, due to the inflation avoidance. It also improves performance up to 25% for the case of locking a thin lock. A decrease in performance (up to 3 times slower) can happen for the case of repetitive nesting of a lock, due to the need of a CAS at each entry/exit.

Disable native fastpaths for now, until they are updated to the new implementation.

Merge notes from Rodrigo:
Remove the enter fast paths in monitor.c as the new code already has them.
2015-08-04 14:51:43 -04:00
triton f8b3cb3ea2 Added mono_runtime_posix_install_handlers stub for WatchOS. 2015-08-04 19:16:18 +01:00
triton c653f9553b Added SGen OS support code stubs for coop backend. 2015-08-04 19:15:43 +01:00
Ludovic Henry 5d5cca46f2 Revert "[runtime] Refactor AsyncResult.Invoke internal call"
This reverts commit e4ce838cd3.
2015-08-04 09:42:23 -04:00
Ludovic Henry 7f6c03a7d4 Revert "[runtime] Refactor AsyncResult creation with MonoAsyncCall"
This reverts commit 0e27abd93a.
2015-08-04 09:42:22 -04:00
Ludovic Henry fd02c73d71 Revert "[runtime] Move AsyncResult.Invoke to managed"
This reverts commit 29b07ab3ad.
2015-08-04 09:42:22 -04:00
Marek Safar 2fd45289e5 [mcs] Cached labels definite assignment check does not need exact match but anything larger than original set satisfies the condition. Fixes #32732 2015-08-04 15:26:50 +02:00
Marek Safar bdded2d319 [mcs] Special case return expression of Task<Task> in async block. Fixes #32712 2015-08-04 13:01:41 +02:00
Zoltan Varga 5a9d5e09f6 [llvm] Use the default code model on amd64, the 'large' code model leads to problems since the runtime doesn't support thunks on amd64. 2015-08-03 22:07:40 -04:00
Zoltan Varga bf2c1737c3 [jit] Remove monitor enter/exit trampolines, their performance is similar to calling the icalls directly, so its not worth the complexity. 2015-08-03 18:51:54 -04:00
Zoltan Varga 8f385c26c2 [runtime] Add a separate icall for Monitor.Enter(obj,&bool). 2015-08-03 18:35:42 -04:00
Zoltan Varga 064de165cf [runtime] Add fastpaths to the Monitor.Enter () methods. 2015-08-03 18:20:41 -04:00
Rodrigo Kumpera c6590df4fb Merge pull request #1912 from ludovic-henry/threadpool-managed-asyncresult
[runtime] Move AsyncResult.Invoke to managed
2015-08-03 17:37:54 -04:00
Ludovic Henry 29b07ab3ad [runtime] Move AsyncResult.Invoke to managed 2015-08-03 15:57:37 -04:00
Alexander Köplinger 27e667fcaa [System] Increase timeout of a test in SslStreamTest
The AuthenticateClientAndServer_ClientSendsNoData test sometimes failed on Jenkins,
but the 2s timeout is pretty short (it takes about 0.5s on my fast machine as well).

Increasing it to 5s should allow the test to work on the slower Jenkins machines as well.
2015-08-03 21:24:25 +02:00
Ludovic Henry 0e27abd93a [runtime] Refactor AsyncResult creation with MonoAsyncCall 2015-08-03 13:57:22 -04:00
Ludovic Henry e4ce838cd3 [runtime] Refactor AsyncResult.Invoke internal call
Instead of catching the exception and rethrowin it right away, we do not catch it. This simplifies the code, and will give us more insight into the underlying exception.

Also merge mono_async_result_invoke into ves_icall_System_Runtime_Remoting_Messaging_AsyncResult_Invoke as it is the only place we use it.
2015-08-03 12:24:45 -04:00
Zoltan Varga 0058c9cd49 Merge pull request #1959 from alexrp/master
Fix atomic_add_i4 on PPC
2015-08-03 12:20:41 -04:00
Zoltan Varga e6af202f66 Merge pull request #1958 from rolfbjarne/aot-error-reporting
[aot] use g_error instead of fprintf + exit(1).
2015-08-03 12:01:46 -04:00
Alex Rønne Petersen 8f379f0c8f [ppc] Fix atomic_add_i4 support for 32-bit PPC. 2015-08-03 17:32:31 +02:00
Alex Rønne Petersen f967c79926 [ppc] Instruction length of atomic_add_i4 is 28. 2015-08-03 17:32:07 +02:00
Rolf Bjarne Kvinge 2f393535bc [aot] use g_error instead of fprintf + exit(1).
printfs don't always show up in the iOS device log, and exit(1) does
not create a crash report, making these conditions hard to debug
(all you get is "app X exited with code 1", and then you need to
attach a native debugger and break on 'exit' to figure out more).

g_error will end up producing output using NSLog (which always
shows up in the device log), and a crash report as well, making
debugging a lot easier.
2015-08-03 16:06:02 +02:00
Zoltan Varga 6e4b8c89aa [llvm] Reenable the 'handler without invokes' llvm restriction, it causes llvm to eliminate the handler, causing finally_block_ending_in_dead_bb.exe to fail on amd64. 2015-08-03 00:05:12 -04:00
Zoltan Varga 6828387fe0 Revert "[runtime] Disable finally_block_ending_in_dead_bb.exe on wrench, it fails with llvm."
This reverts commit 7b7692a988.

Revert this as its not needed.
2015-08-03 00:04:23 -04:00
Zoltan Varga 7b7692a988 [runtime] Disable finally_block_ending_in_dead_bb.exe on wrench, it fails with llvm. 2015-08-02 23:56:48 -04:00
Zoltan Varga 0416019a35 runtime] Add semicolons after the calls to the coop gc macros to avoid confusing editors. 2015-08-02 00:47:29 -04:00
Zoltan Varga c1ad40586e [runtime] Clean up the mini makefile a bit. 2015-08-02 00:42:01 -04:00
Zoltan Varga d37df4b0c6 [runtime] Clean up configure.ac a bit. 2015-08-02 00:13:49 -04:00
Zoltan Varga a33a8fac8f [arm] Remove usunsed arch/arm/tramp.c file. 2015-08-01 23:27:35 -04:00
Zoltan Varga 12cb465e9e [arm] Avoid running out of thunk space if the same instruction is patched multiple times. Fixes #32179. 2015-08-01 21:25:51 -04:00
Zoltan Varga 06df64e866 [aot] Avoid passing empty quoted arguments to the linker. 2015-08-01 20:42:37 -04:00
Zoltan Varga dc1001166d Fix a warning. 2015-08-01 19:45:14 -04:00
Zoltan Varga 1235e7f07b [llvm] Fix support for returning empty structs from pinvoke methods on amd64. 2015-08-01 19:34:29 -04:00
Zoltan Varga 432095fd3e [jit] Enable direct calls to the monitor icalls. 2015-08-01 19:34:28 -04:00
Zoltan Varga 49b70d288b [runtime] Use mono_set_pending_exception () in the monitor icalls. 2015-08-01 19:34:28 -04:00
Marek Safar 6da0ae8c41 Merge pull request #1955 from LogosBible/servicepoint_nre
Fix NRE in CheckAvailableForRecycling. Fixes #32685
2015-08-01 08:52:31 +02:00
Marek Safar 9c5b494cbe Merge pull request #1956 from akoeplinger/fix-processtest-race
[System] Fix a race in two ProcessTest tests
2015-08-01 07:50:47 +02:00
Alex Rønne Petersen b176c8e166 Merge pull request #1957 from akoeplinger/msbuild-fix
Revert "[Microsoft.Build.Engine] Fix bug with escaped semicolon and spaces"
2015-08-01 06:35:38 +02:00
Alexander Köplinger 9a9e721cd8 Revert "[Microsoft.Build.Engine] Fix bug with escaped semicolon and spaces"
This reverts commit 51297ed7ab.

It caused a regression for escaped quotes (%22) in msbuild properties. See https://github.com/mono/mono/commit/51297ed7ab06480df84520c758639b6cef0790d9#commitcomment-11827605.

Disable test that now fails again after the revert. Add new test that verifies the behavior originally broken by the change.
2015-08-01 04:13:07 +02:00
Alexander Köplinger 2f36c4bdcc [System] Fix a race in two ProcessTest tests
The tests sometimes failed in CI, due to a race condition between
the Exited event and our assertion of whether it was called.
2015-08-01 01:33:04 +02:00
Tom Philpot c90f9a9217 Fix NRE in CheckAvailableForRecycling. Fixes #32685 2015-07-31 15:38:35 -07:00
Jonathan Pryor 7d68d78eee [mkbundle] Add mkbundle --dos2unix parameter.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=25086
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=31875
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=32171

Reverts and reworks commit bcfec743.

The problem is that when Xamarin.Android is running mkbundle, dos2unix
should NEVER be used, because the Android NDK NEVER wants Unix-like
paths, which is what dos2unix creates.

Commit bcfec743 attempted to fix this by removing dos2unix invocation
from the Xamarin.Android codepath.

The problem is that the logic was backwards: it removed dos2unix
invocation when XAMARIN_ANDROID was NOT defined, and PRESERVED
dos2unix invocation when XAMARIN_ANDROID WAS defined.

Meaning commit bcfec743 broke normal/default mkbundle.exe use on
Windows -- it would no longer probe for and use dos2unix if present --
and Xamarin.Android use of mkbundle continued to check for and use
dos2unix if it was present, continuing the buggy behavior.

Doh!

Thus, a reworking: Add a `mkbundle --dos2unix` parameter.
If `mkbundle --dos2unix=false` is specified, dos2unix will NOT be
probed for, and will NOT be used. If `mkbundle --dos2unix` or
`mkbundle --dos2unix=true` is used, then dos2unix WILL be used.

This allows the caller to consistently, ahead of time, control
mkbundle's behavior regarding dos2unix, which will e.g. allow
Xamarin.Android to *always* specify --dos2unix=false, allowing things
to build as desired there.
2015-07-31 15:35:37 -04:00
Alexander Köplinger 832f63035f [System.Runtime.Remoting] Use NotWorking category for test instead of Ignore attribute
The TestFixtureSetUp would sometimes fail in CI, but none of the tests in this class are
actually run since they are all either [Category("NotWorking")] or [Ignore].

Moving the one test from Ignore to NotWorking category allows NUnit to recognize there
are no tests to run and skips the unnecessary TestFixtureSetUp completely.
2015-07-31 21:06:05 +02:00
Marek Safar dd36f93fa5 [mcs] Try to report better error message for file excedding PE/COFF limit. Fixes #32487 2015-07-31 14:36:28 +02:00
Marek Safar 725ed3f824 [runtime] Add 2.0 build assemblies to remapping table. Fixes #32561 2015-07-31 13:50:47 +02:00
Marek Safar d6fe6a6e47 [reflection] Filter out private accessors when queried from derived types. Fixes #32609 2015-07-31 09:45:25 +02:00
Zoltan Varga b4b12052ed Parallelize the generation of aot images for make fullaotcheck. 2015-07-30 22:45:30 -04:00
Zoltan Varga 98dff8f62d [aot] Fix the caching of runtime-invoke wrappers after the wrapper cache changes, two methods with the same signature might have different runtime invoke wrappers now, and the caching would break their lookup. 2015-07-30 17:24:23 -04:00
Marek Safar 13a9e56d8f [runtime] Support quoted assembly names. Fixes #32591 2015-07-30 19:18:18 +02:00
Rodrigo Kumpera 8f7b98b9b2 Merge pull request #1840 from ludovic-henry/iolayer-thread-interrupt
[runtime] Implement wait interrupt in thread info, instead of in the io-layer
2015-07-30 10:48:44 -04:00
Martin Baulig dd6f03681e [System]: Fix WebConnectionStream.SetHeadersAsync() logic for #31830.
This fixes commits 8ccfe0f8ff and
c109f9ca03.

Added new test:
https://github.com/xamarin/web-tests/commit/d60bc3f637ca2bf4aa1379b839d878e224d344c8

(cherry picked from commit c133880bc4)
2015-07-30 15:41:10 +02:00
Neale Ferguson 53f9a3f42a Add missing { 2015-07-30 07:09:37 -04:00
Zoltan Varga 9ed1e37112 [amd64] Allocate stack space for saving argument registers in the sdb trampoline code on winx64. 2015-07-29 23:04:42 -04:00
Zoltan Varga 20d9365516 [amd64] Allocate stack space for saving argument registers in the generic trampoline code on winx64. 2015-07-29 22:43:05 -04:00
Zoltan Varga a6380f15f0 [jit] Avoid emitting the DW_CFA_mono_advance_loc mono extension opcode into the .debug_frame section. 2015-07-29 22:29:14 -04:00
Vlad Brezae 35f7ece0bc Merge pull request #1929 from BrzVlad/feature-unwind4yall
Feature trampoline unwind info
2015-07-29 19:08:18 -07:00
Vlad Brezae 9232606586 [arm] Provide unwind info for tls thunks
We don't try to unwind from the fallback thunks since they call external code anyway.
2015-07-29 15:36:57 -07:00
Vlad Brezae 98c987d465 [arm] Simplify declaration of global symbols in asm 2015-07-29 15:36:57 -07:00
Vlad Brezae 26a6fbb2a3 [arm] Fix unwind info for managed methods
Add unwind information for the epilog.
2015-07-29 15:36:56 -07:00
Vlad Brezae 15a099bce0 [aot] Provide unwind info for plt trampolines 2015-07-29 15:36:56 -07:00
Vlad Brezae d5b0f1b3af [arm] Add unwind info for trampolines 2015-07-29 15:36:56 -07:00
Vlad Brezae 5bf40d382d [x86] Add unwind info for registered trampolines. 2015-07-29 15:36:56 -07:00
Vlad Brezae f84adb14b8 [amd64] Add unwind info for registered trampolines. 2015-07-29 15:36:56 -07:00
Zoltan Varga 0197297ff7 Remove an obsolete comment. 2015-07-29 18:29:24 -04:00
Zoltan Varga 0e5ea3f086 Revert "Report XDG Documents directory for SpecialFolder.MyDocuments"
This reverts commit d6553bc988.

Revert this as it breaks the build.
2015-07-29 18:15:37 -04:00
Vlad Brezae a10d98241e [runtime] Register tramp jit info to the corresponding domain 2015-07-29 15:06:38 -07:00
Vlad Brezae 68b41a000e [x86] Register throw trampolines 2015-07-29 15:06:38 -07:00
Vlad Brezae 93a9cc9418 [runtime] Register unbox trampolines 2015-07-29 15:06:38 -07:00
Vlad Brezae 4718f304a5 [arm] Register and add unwind information for page trampolines. 2015-07-29 15:06:37 -07:00
Vlad Brezae a2d6d4a3ca [runtime] Register imt trampolines 2015-07-29 15:06:37 -07:00
Vlad Brezae c1d688bf7c [runtime] Register get gsharedvt arg trampolines 2015-07-29 15:06:37 -07:00
Vlad Brezae 177f8d37ea [runtime] Register static rgctx trampolines 2015-07-29 15:06:37 -07:00
Vlad Brezae 9ffebc9d4e [runtime] Register tramp infos for delegate invoke trampolines
Also refactor MonoTrampInfo creation, similar to the other trampolines.
2015-07-29 15:06:37 -07:00
Vlad Brezae 582bfd5fcd [x86] Fix usage of virtual delegate invoke tramps for aot
We need to fallback if the vtable slot exceedes the limit.
2015-07-29 15:06:36 -07:00
Vlad Brezae e12e34a69c [runtime] Fix lookup of aot symbol for imt delegate invoke tramps
Offset for calls through imt is negative
2015-07-29 15:06:36 -07:00
Vlad Brezae 281018613f [runtime] Add missing delegate invoke trampolines 2015-07-29 15:06:36 -07:00
Vlad Brezae cc18cd5a87 [amd64] Fix failure to emit imt delegate invoke tramps
The problem was due to implicit casting of the dividend to unsigned (which overflows) when divided by unsigned.
2015-07-29 15:06:36 -07:00
Vlad Brezae 99153cdd59 [aot] Register tramp infos when loading trampolines in aot. 2015-07-29 15:06:36 -07:00
Vlad Brezae 214a610172 [runtime] Expose trampoline jit infos that have unwind info to the runtime
Some trampolines cannot have typical unwind information because they don't get the return address from the stack. Others are called from native code that doesn't have a managed-to-native transition so unwind information would be pointless at this point. We don't include these in the jit info tables for now, not to confuse the runtime further more.
2015-07-29 15:06:35 -07:00
Vlad Brezae 7e53633f99 [runtime] We already checked that the IP is within the clause 2015-07-29 15:06:35 -07:00
Vlad Brezae 6a882003cb [jit] Add different frame type for trampoline frames. 2015-07-29 15:06:35 -07:00
Vlad Brezae 6ac11612f5 [jit] Include the unwind_info into the tramp JitInfos 2015-07-29 15:06:35 -07:00
Zoltan Varga 60a4377b0e [llvm] Avoid emitting a dummy personality function. 2015-07-29 17:51:41 -04:00
Rodrigo Kumpera 3272188fb6 Merge pull request #1951 from akoeplinger/fix-monop
[monop] Set MONO_PATH when running tests so class libs are found
2015-07-29 17:26:06 -04:00
João Matos c50762e882 Merge pull request #1953 from brpocock/master
Report XDG Documents directory for SpecialFolder.MyDocuments
2015-07-29 22:14:46 +01:00
João Matos 85988f4de7 Merge pull request #1954 from kumpera/fix_aot_compilation
Fix OSX aot compilation when there's a space in a file path.
2015-07-29 22:08:48 +01:00
Rodrigo Kumpera 4c486b97b5 Fix aot compilation when the path has spaces. 2015-07-29 17:05:17 -04:00
Sebastien Pouliot be41f60264 [tests] iOS9 (beta) have fixed bug #27864, adjust test 2015-07-29 16:45:15 -04:00
Bruce-Robert Fenn Pocock d6553bc988 Report XDG Documents directory for SpecialFolder.MyDocuments 2015-07-29 16:02:43 -04:00
Rodrigo Kumpera 2ef316dd5c [runtime] Use MONO_SIZEOF_TYPE instead of sizeof (MonoType) and compiler generated copying.
On amd64 MONO_SIZEOF_TYPE is 12 and sizeof(MonoType) is 16. This leads to memory corruption
if one uses sizeof instead of the specific size.

This is one of those oddball behaviors of the runtime that makes easy things very hard. :(
2015-07-29 12:07:35 -04:00
Rodrigo Kumpera 074dccc43a [runtime] Introduce mono_method_get_wrapper_cache to fetch the right wrappers set for a given method.
This removes a ton of duplicated code around the runtime. There are still a few cases that could not be
unified due to the hashtables been initialized differently, which requires further reviewing.
2015-07-29 12:07:35 -04:00
Rodrigo Kumpera b8115d888a [runtime] Use a single function to free the contents of MonoWrapperCaches. Remove duplicated code. 2015-07-29 12:07:34 -04:00
Marek Safar cd77a34181 [corlib] Fix out of range FileStream position error message 2015-07-29 12:14:38 +02:00
Marek Safar 41814abe77 [mcs] Report error for missing win32 icon. 2015-07-29 00:19:09 +02:00
Marek Safar d8e924f72d [xbuild] Use correct property for Win32Icon. Fixes #32499 2015-07-29 00:19:09 +02:00
Zoltan Varga 92af8cc7fc [llvm] Emit the file info struct initializer using the proper types. 2015-07-28 17:03:58 -04:00
Zoltan Varga 68c2d43e65 [amd64] Avoid saving r11 outside the red zone in the generic trampoline code. 2015-07-28 16:50:05 -04:00
Alexander Köplinger a67ab28838 [monop] Set MONO_PATH when running tests so class libs are found
When the monop tests were added in 6c9ad41d85 the MONO_PATH
variable wasn't included. This means that the tests actually ran against the system-provided
Mono class libs instead of the in-tree versions (or failed in case of CI with only monolite).
2015-07-28 22:19:24 +02:00
Martin Baulig bf1e02d4d4 Revert "[System] Don't assume WebConnectionStream of unknown http methods require write stream. Fixes #31830"
This reverts commit 8ccfe0f8ff.

This commit breaks the Content-Type logic for existing HTTP verbs such as for instance
using DELETE with an empty body [1].  Added two new test cases [2] and [3] to the stable
branch of the web-tests (https://github.com/xamarin/web-tests/tree/stable) for the particular
scenario from bug #31830 as well as the default HttpClient.SendAsync() without a Content [4].

The rules are as follows:

1.) HttpWebRequest adds the Content-Length header if and only if you're calling
    GetRequestStream(); a length of 0 will be used if you don't actually write
    any content.

    This is true for POST, PUT, DELETE and "obscute" verbs.

2.) HttpClient.SendAsync() always adds a Content-Length header.

Tests:

[1] https://github.com/xamarin/web-tests/blob/31b8fed0ec1283b8c0693bb14d1ac266792c1020/Xamarin.WebTests/Xamarin.WebTests.Tests/TestPost.cs#L84

[2] https://github.com/xamarin/web-tests/blob/31b8fed0ec1283b8c0693bb14d1ac266792c1020/Xamarin.WebTests/Xamarin.WebTests.Tests/TestPost.cs#L296

[3] https://github.com/xamarin/web-tests/blob/31b8fed0ec1283b8c0693bb14d1ac266792c1020/Xamarin.WebTests/Xamarin.WebTests.Tests/TestHttpClient.cs#L134

[4] https://github.com/xamarin/web-tests/blob/31b8fed0ec1283b8c0693bb14d1ac266792c1020/Xamarin.WebTests/Xamarin.WebTests.Tests/TestHttpClient.cs#L127

(cherry picked from commit 3f1ae72f1b385c3c5e4b5ac2b93d13418c020f02)
2015-07-28 21:14:03 +02:00
Zoltan Varga 355ecbfe98 [runtime] Remove some dead code. 2015-07-28 14:01:23 -04:00
Zoltan Varga d6daf35d82 [runtime] Print an error message instead of asserting when encountering an old corlib. 2015-07-28 13:21:24 -04:00
triton eef135d689 [mini] Fixed void function returning warning. 2015-07-28 14:54:01 +01:00
triton 6528915b1d [msvc] Update Mono DLL export definitions. 2015-07-28 14:53:11 +01:00
triton ff141cf1ee [msvc] Update Visual Studio project files. 2015-07-28 14:52:31 +01:00
Marek Safar 4e5ccd6d98 [mcs] Do member declaration obsolete types references check after all members are defined. Fixes #32451 2015-07-28 15:04:05 +02:00
Alexander Kyte 0ecaf50e1d [runtime] Remove mono_marshal_free_inflated_wrappers because its only call site frees the caches anyways.
Since we now only remove methods from caches in the image set it belong we no longer needs to do it since
they will be gone together with the method itself.
2015-07-28 01:26:20 -04:00
Alexander Kyte 9b163221b5 [runtime] Move caches present in both MonoImage and MonoImageSet into an embedded struct. 2015-07-28 01:26:19 -04:00
Alexander Kyte 680c609219 [runtime] Duplicate some more of the image caches in MonoImageSet
Changes by Rodrigo Kumpera:

Added missing freeing code.
Fixed insertion into runtime_invoke_direct_cache.
Fixed some of the cleanup in mono_marshal_free_inflated_wrappers.
2015-07-28 01:26:19 -04:00
Alexander Kyte 1367c3954c [runtime] Removed confusing/cross-cutting function mono_method_inflated_lookup and inlined at only call site. 2015-07-28 01:26:19 -04:00
Alexander Kyte bd6c263cdc [runtime] Move caches from Images to ImageSets if their keys contain generic types
We currently have a partial ordering of dependencies between ImageSets and images.
If you free an image that an ImageSet depends on, you must free the
ImageSet. The inverse is not true. Freeing the ImageSet does not free
any images.

We had some caches in each Image which used method signatures as keys.
When an image signature refers to a type stored in an ImageSet, and that
ImageSet has been unloaded, the signature will remain in the cache for
the Image.

When we have another object hash to the same slot as this signature, we
must check if the two signatures are actually equal, that is if they are
equal keys or a hash collision. In this check we will refer to the
MonoType in the freed ImageSet.

By moving the caches containing inflated type references into the ImageSets
holding these inflated types, we ensure that the cache items are always safe
to dereference.

Why not simply remove the signatures from all caches they contain on
freeing the signature? This is much more work. A signature with a dozen
type parameters in a dozen images may have been used as a key in any of these
images. We would have to check all caches in all images the signature
refers to. As these caches use open addressing, in the worst time this
can take

```
(# images in signature) x (# caches per image) x (# of slots traversed on average)
```

steps. By placing it on the ImageSet, this takes only the steps required
to free a hash table. It is also easier to reason about.

Changes by Rodrigo Kumpera:

Added locking comments to the new fields in MonoImageSet.

Fixed the selected cache in mono_marshal_get_delegate_begin_invoke, mono_marshal_get_delegate_end_invoke,
mono_marshal_get_delegate_invoke_internal and mono_marshal_get_synchronized_wrapper.

The original code was using the image set of the class instead of the IS of the inflated method. This would
pick the wrong image if the method belonged to a different IS.
2015-07-28 01:26:18 -04:00
Rodrigo Kumpera 12e265cda6 [marsha] Use TRUE instead of 1 for setting a boolean field. 2015-07-28 01:26:18 -04:00
Alexander Kyte c905bcb682 [runtime] Copy signature return type when copying MonoMethodSignature
This commit also removed an extra signature duplicator living in
marshal.c, so that this fix is used consistently
2015-07-28 01:26:18 -04:00
Zoltan Varga 46fae9b2bf [runtime] Make the code more c++ clean by renaming this->this_obj. 2015-07-27 22:35:57 -04:00
Zoltan Varga eef9c63910 [jit] Make the jit code more c++ clean by renaming class->klass and this->this_arg/this_ins. 2015-07-27 22:35:57 -04:00
Zoltan Varga 7f84b17dde Merge pull request #1950 from akoeplinger/fix-responsefile-win
[build] library.make: Avoid collisions in response file name for facades on Windows
2015-07-27 20:59:47 -04:00
Rodrigo Kumpera 187bc41b1a Merge pull request #1943 from alexrp/profiler-improvements
Follow-up to #1926
2015-07-27 19:10:23 -04:00
Alexander Köplinger 173c89af23 [build] library.make: Avoid collisions in response file name for facades on Windows
When additional facades were added in 04114a5e9d, the Windows Cygwin build broke.
Turns out, when building the System.IO.Comporession facade assembly it wanted to use the SharpCompress sources
of the real assembly and couldn't find it (which made no sense since since the facade doesn't even list them in
its .sources file).

After inspecting library.make what happens is this: the response file is defined as $(PROFILE)_$(LIBRARY).response,
but this results in the same value for both the real assembly and the facade assembly.
This means that since the real assembly was compiled first, the response file contained the source list of the real
assembly - which was then used to compile the facade (make happily reused the response file since it already existed).

The fix is to put $(LIBRARY_SUBDIR) into the filename so the facade assembly gets a different response file.
Same for the makefrag.
2015-07-27 15:37:47 -07:00
Alex Rønne Petersen 0329a0f6d4 [runtime] Add docs for new domain and context API functions. 2015-07-28 00:36:22 +02:00
Zoltan Varga 37922e383f [runtime] Make some headers c++ clean. 2015-07-27 18:25:59 -04:00
Marek Safar 2f763d7e69 [mcs] Fix obsolete checks on resolved types when type is inflated generic type with concrete type arguments. 2015-07-27 20:10:21 +02:00
Bernhard Urban 427e3f59fe [mono-config] use right type for result of strlen 2015-07-27 10:38:42 -07:00
João Matos bb4e6d08ef Merge pull request #1923 from lukaszunity/start-managed-process-fix
Process.Start fix for managed program
2015-07-27 16:43:40 +01:00
João Matos d42301073e Merge pull request #1948 from akoeplinger/fix-httplistener-test-race
[System] Fix race condition in HttpListenerTest.ConnectionReuse test
2015-07-27 14:23:28 +01:00
Alexander Köplinger fb3d728e6a [System] Fix race condition in HttpListenerTest.ConnectionReuse test
There was a race so that sometimes ipEndPoint wasn't yet assigned when the method returned,
which resulted in the test failing like this:

 MESSAGE:  reuse1
  Expected: <127.0.0.1:54370>
  But was: null

To fix this the race, we now wait until ipEndPoint is assigned before returning.

The test was actually disabled on Android because of this (see 7cb4cc9c0e),
we can reenable it again as it should now work fine.
2015-07-27 15:17:58 +02:00
Marek Safar 8861e7bed6 [mcs] Reset doc reader state after expression bodied property. Fixes #32456 2015-07-27 14:11:33 +02:00
Marcos Henrich 3360de9221 Merge pull request #1909 from esdrubal/reflection
[SRE] Implemented missing SRE features.
2015-07-27 12:43:38 +01:00
João Matos 5aa729c24c Merge pull request #1947 from directhex/fix-kfreebsd
mono-threads-linux.c also applies to other OSes with GNU userland
2015-07-27 11:34:37 +01:00
Marek Safar 0db4e1775e [build] Remove generated files 2015-07-27 12:31:29 +02:00
Jo Shields 60635f32f8 mono-threads-linux.c also applies to other OSes with GNU userland
Fixes a build failure for GNU/kFreeBSD (which doesn't use mono-threads-freebsd.c, since GNU/kFreeBSD doesn't have pthread_np.h)
2015-07-27 09:20:47 +01:00
Marek Safar e7c058d61d Merge pull request #1941 from kasthack/system.web-fixes
[System.Web] Abstractions from reference source
2015-07-27 09:09:23 +02:00
Zoltan Varga 916766dc5a Merge pull request #1946 from markbeaton/markbeaton-tzaustralia
GetSystemTimeZones() not returning Australia zones
2015-07-26 22:43:30 -04:00
Mark Beaton c4810a3529 GetSystemTimeZones() not returning Australia zones
A call to TimeZoneInfo.GetSystemTimeZones() is not returning any of the timezones for Australia due to the "Australia" string being missing from the array of continents used to look up the zoneinfo data at /usr/share/zoneinfo. This patch adds the "Australia" value to the array.
2015-07-27 11:59:49 +10:00
Alex Rønne Petersen 52d6551c35 [profiler] Describe buffer size arithmetic with comments. 2015-07-26 22:09:45 +02:00
Marek Safar 8f49323033 Merge pull request #1944 from akoeplinger/remove-net40-ifdefs
[bcl] Remove NET_4_0 defines from class libs
2015-07-26 20:23:09 +02:00
Alexander Köplinger 98cf04084a [bcl] Remove NET_4_0 defines from class libs
NET_4_0 is always defined now, so the ifdefs are redundant.
I verified the libs are exactly the same after this change, so this is effectively a no-op.
2015-07-26 15:01:49 +02:00
Zoltan Varga a8990aca6c Merge pull request #1942 from akoeplinger/net4x
[build] Fix a few Makefiles to correctly use net_4_x instead of net_4_5
2015-07-25 15:46:13 -04:00
Alexander Köplinger b833f8b30d [RabbitMQ.Client] Add generated net_4_x-api-*.cs specs files and remove outdated ones 2015-07-25 17:47:29 +02:00
Alexander Köplinger 3a71f84cca [build] Fix a few Makefiles to correctly use net_4_x instead of net_4_5 2015-07-25 17:47:29 +02:00
Alexander Köplinger 4028c58a4c [Microsoft.Build] Fix name of framework directory in xbuild-testing RedistList
Fixes the BuildCommonResolveAssemblyReferences test that failed after the net_4_5 -> net_4_x switch.
2015-07-25 17:11:16 +02:00
Zoltan Varga 0d06636cde Revert "[jit] Allow NEW_AOTCONST () to work in JIT mode too, use this to simplify some code."
This reverts commit bf736f6c59.

Revert this as it seems to break the build.
2015-07-24 22:12:13 -04:00
kasthack 33a77c8635 [System.Web] Abstractions from reference source 2015-07-25 04:38:52 +03:00
Zoltan Varga bf736f6c59 [jit] Allow NEW_AOTCONST () to work in JIT mode too, use this to simplify some code. 2015-07-24 21:25:37 -04:00
Zoltan Varga ee1d6935f6 Fix installing resgen.exe. 2015-07-24 20:38:06 -04:00
Zoltan Varga 3cda046b61 Merge pull request #1940 from lewurm/master
[mono-config] update path to libMonoPosixHelper in runtime/ as well
2015-07-24 17:59:42 -04:00
Bernhard Urban 404f1d36de [mono-config] update path to libMonoPosixHelper in runtime/ as well 2015-07-24 14:33:34 -07:00
Zoltan Varga 51a23d5e2c Merge pull request #1939 from madewokherd/monoconddestroy
Define mono_cond_destroy on non-Windows.
2015-07-24 15:28:11 -04:00
Vincent Povirk bac1253103 Define mono_cond_destroy on non-Windows.
This commit is licensed as MIT/X11.
2015-07-24 14:06:55 -05:00
João Matos e730508206 [runtime] Rewrite MonoContext code to work via libunwind.
The latest Xcode 7 beta 4 SDK disallows usage of getcontext and friends.
2015-07-24 19:58:59 +01:00
João Matos 1b5578850f [runtime] Compile fixes for WatchOS. 2015-07-24 19:58:58 +01:00
João Matos 1bb19880fa [sgen] Adapt Mach OS support code to work with cooperative GC. 2015-07-24 19:58:58 +01:00
João Matos fb5301d74a [runtime] Workaround lack of Mach thread abort / suspend. 2015-07-24 19:58:57 +01:00
João Matos 90972a343b [runtime] Make console code work without HAVE_SIGACTION. 2015-07-24 19:58:57 +01:00
João Matos 0933c09608 [eglib] Workaround lack of raise(). 2015-07-24 19:58:56 +01:00
João Matos d3726dcde9 [runtime] Workaround lack of signal(). 2015-07-24 19:58:55 +01:00
João Matos c7a3b7fb65 [runtime] Workaround lack of pthread_kill(). 2015-07-24 19:58:55 +01:00
João Matos 8228d27d17 [runtime] Workaround lack of kill(). 2015-07-24 19:58:54 +01:00
João Matos 9b02d42462 [runtime] Check for kill function in Autoconf. 2015-07-24 19:56:17 +01:00
João Matos 0b76c6ac8c [runtime] Check for signal function in Autoconf. 2015-07-24 19:56:16 +01:00
Zoltan Varga 223e634cf5 Merge pull request #1938 from saper/updates_signal
[mswin][build] unbreak windows build on 'updates_signal'
2015-07-24 14:53:42 -04:00
Marcin Cieslak d8268196f8 [mswin][build] unbreak windows build on 'updates_signal' 2015-07-24 18:49:53 +00:00
Marek Safar 5acdd41356 [Mono.Debugger.Soft] Exclude invalid C# code 2015-07-24 18:10:11 +02:00
Marek Safar 7d2ce49ae4 [mcs] Fix crash during ambiguous implementation of the query pattern error reporting. Fixes #32060 2015-07-24 17:29:53 +02:00
Marek Safar fe16436401 [build] Use DEFAULT_PROFILE from configure to avoid problems with RUNTIME redefinition 2015-07-24 15:53:10 +02:00
Marek Safar 7eb3fb7aea [mcs] Report error when an expression tree contains a collection initializer with extension method 2015-07-24 15:53:10 +02:00
Marek Safar bbec52b880 [mcs] struct parameterless instance constructor feature was removed from C#6 for compatibility reasons 2015-07-24 15:53:10 +02:00
Marek Safar 8cdfcab598 [mcs] Change used assemblies checks to run on referenced (metadata written) assemblies only. Fixes #31933 2015-07-24 15:53:09 +02:00
Marcos Henrich aab7e2a47d [System] UriKind.RelativeOrAbsolute workaround.
In .NET an URI constructor from "/foo" and UriKind.RelativeOrAbsolute is
relative whereas in mono it is assumed as an absolute file path.

This provides supports for an easy workaround to make mono behave as
.NET.

The workaround consists in defining DotNetRelativeOrAbsolute and using
it instead of UriKind.RelativeOrAbsolute.

DotNetRelativeOrAbsolute should be defined as follows:

static UriKind DotNetRelativeOrAbsolute = (Type.GetType ("Mono.Runtime")
== null)? UriKind.RelativeOrAbsolute : (UriKind) 300;
2015-07-24 09:58:41 +01:00
Zoltan Varga e1101a5eb1 [runtime] Avoid stack overflow when marshalling an out stringbuilder argument in pinvoke callbacks. Fixes #31932. 2015-07-23 23:08:39 -04:00
Zoltan Varga d44657503a [arm] Allocate thunk space for tail calls. Fixes #32179. 2015-07-23 22:09:27 -04:00
Miguel de Icaza e6de431a54 [mono-config] Apply fix from Bernhard Urban 2015-07-23 17:11:56 -05:00
Miguel de Icaza d370e923a9 Undo the previous patch, as it contained an incorrect +3 in the size computation; Use my version instead 2015-07-23 16:53:26 -05:00
Miguel de Icaza 70920b3d66 Merge pull request #1937 from lewurm/master
mono: Use the relocated directory for finding support libraries in data/config
2015-07-23 16:45:35 -05:00
Bernhard Urban 6b5f6dd043 mono: Use the relocated directory for finding support libraries in data/config 2015-07-23 14:32:24 -07:00
Marek Safar 3aa5330d7e Bump reference sources 2015-07-23 15:57:01 +02:00
Marek Safar 366c2882f8 [corlib] ToUpper/ToLower have different rules for invariant culture. Fixes #31900.
Updated missing unicode to-upper/to-lower mappings and move all code to managed.
2015-07-23 15:08:17 +02:00
Zoltan Varga 71945fbdb9 [gsharedvt] Set exception_message when disabling LLVM. 2015-07-22 20:28:30 -04:00
Zoltan Varga b8c3006400 [arm] Enable support for a few more calling conventions for LLVM. 2015-07-22 20:28:30 -04:00
Zoltan Varga 9677d59cca Merge pull request #1935 from alexanderkyte/xdebug-refix
[runtime] Disable functions that call functions which require the bin writer if the bin writer is disabled.
2015-07-22 16:56:49 -04:00
Alexander Kyte 381003dfd4 [runtime] Disable functions that call functions which require the bin writer if the bin writer is disabled. 2015-07-22 16:54:42 -04:00
Marek Safar e2d95bf0a5 [xbuild] Add 14.0 toolsets path 2015-07-22 10:36:07 +02:00
Marek Safar bdf33794f7 [System.Configuration] Update default profile and remove old profiles files 2015-07-22 10:34:08 +02:00
Marek Safar 3a12d84673 [System.Data] Fixes make dist 2015-07-22 10:31:34 +02:00
Marek Safar d1c5a3e90b [System.Web.Extensions] Update default profile and remove old profiles files 2015-07-22 10:20:49 +02:00
Marek Safar aedaab80da [System.Web] Update encoded profile name 2015-07-22 10:06:50 +02:00
Marek Safar 67a198548c [System.Web.DynamicData] Update default profile and remove old profiles 2015-07-22 09:45:38 +02:00
Marek Safar 0779ff1eac [System.Xaml] Update default profile and remove old profiles 2015-07-22 09:01:39 +02:00
Marek Safar 672207f976 [build] Use DEFAULT_PROFILE from configure to avoid problems with RUNTIME redefinition 2015-07-22 08:55:21 +02:00
Marek Safar 825b328d65 [xbuild] Update tests default profile 2015-07-22 07:59:00 +02:00
Zoltan Varga 5911c63d74 [arm64] Add a test for passing HFA arguments on the stack. 2015-07-21 20:47:36 -04:00
Marek Habersack 4e5bf79f74 [tests] Android 4.4.4 doesn't have signal(2) 2015-07-22 00:15:48 +02:00
Marek Habersack 5c75836975 [tests] Fix path used by the test so that it works on Android 4.4.4 2015-07-22 00:15:48 +02:00
Marek Habersack fdc0f08ba9 [tests] Disable on Android, getpwnam_r doesn't exist there 2015-07-22 00:15:47 +02:00
Marek Habersack 6e170a7673 [tests] Don't assume CWD is writable
Use temporary path instead. CWD is / on Android and is not writable
2015-07-22 00:15:47 +02:00
Marek Habersack cfcc767916 [tests] Nunit syntax helpers don't exist in Xamarin.Android 2015-07-22 00:15:46 +02:00
Zoltan Varga 50b427db9d [llvm] Fix a problem introduced by 4a685f44c8, the size of the return type was computed incorrectly. 2015-07-21 18:11:38 -04:00
Rodrigo Kumpera 586b6b67e2 [profiler] Correct the profiler format. 2015-07-21 17:51:25 -04:00
Rodrigo Kumpera 4c066cf265 [profiler] Use version 11 for the 4.2 profiler changes plus fix docs on format. 2015-07-21 17:37:41 -04:00
Rodrigo Kumpera 7151c3c283 Merge pull request #1926 from alexrp/profiler-improvements
More profiler improvements
2015-07-21 16:38:35 -04:00
Zoltan Varga 62d46354b7 [runtime] Avoid including mcs/build/config.make into mini/Makefile.am, it can overwrite all kinds of make variables. Pass DEFAULT_PROFILE normally as an autoconf variable. 2015-07-21 15:59:12 -04:00
Rodrigo Kumpera 9e44c81c60 Merge pull request #1933 from alexrp/master
[runtime] Remove lock in context_adjust_static_data ().
2015-07-21 15:49:58 -04:00
Zoltan Varga b93ba8ceb2 [runtime] Rename mono_arch_find_jit_info () -> mono_arch_unwind_frame (). 2015-07-21 14:22:31 -04:00
João Matos fc79543407 [aot] Rewrite the options parser to properly handle arguments.
Basically our previous behaviour was just splitting strings by "," which did not behave as expected when passing strings.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=31996.
2015-07-21 19:09:30 +01:00
Marek Safar f711ae8624 [xbuild] Adjust tests profile path 2015-07-21 18:10:48 +02:00
Ludovic Henry f2a46d244e [runtime] Make sure EPOLLONESHOT is defined 2015-07-21 12:17:22 -03:00
Marek Safar e6701903ff [System.Web] Update InternalsVisibleTo to active test profiles only 2015-07-21 16:44:31 +02:00
Marek Safar 3f7e239a04 [System.Data] Rename default profile config file 2015-07-21 16:14:29 +02:00
Marek Safar d48c678e89 [corlib] Use better names for predefined encodings. Fixes #32137 2015-07-21 14:44:47 +02:00
Marek Habersack d5bd6b3e5e [test] Fix test on Android
On Android application runs with its CWD set to / and so the path
test modified in this commit expects to find a path of the //one form
which is not what the combine operation returns.
2015-07-21 11:16:19 +02:00
Marek Habersack 401571fa09 [tests] Disable some tests on Android due to missing APIs
bionic doesn't have the following entries:

  setgrent
  getgrnam_r
  setpwent

API 21 in the NDK conditionally declares some of those but they are absent
from either libc.so or libc.a.
2015-07-21 11:16:09 +02:00
Marek Safar e8da614827 [mcs] Set builder for partial method definition attributes. Fixes #31948 2015-07-21 11:11:48 +02:00
Alex Rønne Petersen f6f82dfe0c [runtime] Remove lock in context_adjust_static_data ().
The threads lock is already held when this function is called. Document this
fact and remove the harmless (but pointless) recursive locking.
2015-07-21 05:55:05 +02:00
Zoltan Varga 4e64d3aa69 [jit] Remove usage of MonoGenericSharingContext from most of the JIT. 2015-07-20 20:55:27 -04:00
Zoltan Varga bc4975452a Fix the build. 2015-07-20 20:30:35 -04:00
Rodrigo Kumpera df0bc54f44 [lock-tracer] Small improvements to the decoder. 2015-07-20 18:59:35 -04:00
Rodrigo Kumpera 5b216ba532 [mini] Fix locking order violation in mono_get_seq_points.
mono_get_seq_points takes the domain lock then calls mini_get_shared_method.

mini_get_shared_method then calls into general metadata code that eventually take
the loader lock.

The loader lock has precedence over the domain lock.
2015-07-20 18:59:35 -04:00
Rodrigo Kumpera 7c2e6265be [build] Rename RUNTIME variable to avoid clash with make.config's version
Starting with 62c86e2243 mono/mini/Makefile now includes mcs/build/config.make.
Both files define RUNTIME, but with different values. The mini one requires the usage of MONO_PATH while the one in
mcs don't.

To fix that we rename the mini var to MINI_RUNTIME.
2015-07-20 18:59:35 -04:00
Rodrigo Kumpera d61ccfbc62 [runtime] Fix locking in mono_image_file_for_image. 2015-07-20 18:59:35 -04:00
Zoltan Varga 573251d7f7 Fix the build. 2015-07-20 18:48:55 -04:00
Zoltan Varga 87728b143e [jit] Remove the usage of MonoGenericSharingContext from the back-ends, its no longer needed. 2015-07-20 18:25:26 -04:00
Zoltan Varga d60c514556 [jit] Remove mini_replace_type (), use mini_get_underlying_type () instead. 2015-07-20 17:55:28 -04:00
Zoltan Varga c5c2fecd7d [jit] Remove the MonoGenericContext/MonoCompile arguments from the various mini_type_is/mini_is_gsharedvt etc. functions, the types are now self-describing, i.e. its possible to determine whenever they are gshared, gsharedvt, etc. without consulting a MonoGenericContext. Remove mini_type_get_underlying_type (), use mini_get_underlying_type () instead. 2015-07-20 17:50:00 -04:00
Zoltan Varga bcf4f87ada [jit] Remove class init trampolines, use the same code for generic and non generic class inits, implement the slowpath using a JIT icall. 2015-07-20 15:33:30 -04:00
Ludovic Henry 5fd4126ac5 [threadpool-ms-io] Factor update removing 2015-07-20 16:16:37 -03:00
Ludovic Henry fa26493017 [threadpool-ms-io] Remove socket synchronously from backend when closing socket
To achieve this, we need to wait for the update to be applied to the backend.

This is mainly for the epoll backend, as we do not need to remove the fd from the backend when using kqueue.
2015-07-20 16:16:37 -03:00
Zoltan Varga 5ea5df60f0 [gshared] Fix constrained partial calls to Object:GetType (). 2015-07-20 15:14:50 -04:00
Rodrigo Kumpera c99b83e2f2 [lock-decoder] Update it to include the threads lock. 2015-07-20 14:23:36 -04:00
Rodrigo Kumpera 610f14c247 [runtime] Safe publish MonoImage::name_cache and exploit that around the runtime. Fix ImageLock nested use. 2015-07-20 14:23:36 -04:00
Marek Safar f160bb5ccc [mcs] Add missing interpolated string segmnent clone. Fixes #32135 2015-07-20 19:33:02 +02:00
Marek Safar 2fa37e3e1c [mcs] Parentheses expression can act as conditional access receiver. Fixes #32130 2015-07-20 18:41:06 +02:00
Marek Safar 55b4897568 [build] Clean up cross referenced files 2015-07-20 15:26:07 +02:00
Marek Safar 929c7de580 [mcs] Resolve nullable expression before unwrapping. Fixes #32054 2015-07-20 14:10:31 +02:00
Alexander Köplinger b90bd85f87 [System.ServiceModel.Web] Fix tarball generated by "make dist"
System.Runtime.Serialization.Json/JavaScriptReader.cs is needed by the System.Json assembly, but in
d44898a230 it was removed from net_2_0_System.ServiceModel.Web.dll.sources
which means it wasn't included in the tarball anymore and building it failed.

Fixing the tarball by including the file in EXTRA_DISTFILES.
2015-07-20 13:21:00 +02:00
Marek Safar c65aec96e4 Merge pull request #1931 from kasthack/system.web-fixes
[System.web] Reference source imports + HttpApplication fix
2015-07-20 10:27:49 +02:00
Zoltan Varga 68ad97bc53 [jit] Remove the support for MONO_ARCH_NOTIFY_PENDING_EXC, it only works on amd64, and its not worth the complexity. 2015-07-19 23:26:16 -04:00
Zoltan Varga 1cd9c24be1 [jit] Use mini_type_get_underlying_type () instead of mini_get_basic_type_from_generic (), make the latter static. 2015-07-19 22:24:21 -04:00
Radek Doulik 4d824ec1d4 [linker] Instead of preserving every method with a [Register] attribute...
[merged from monodroid by rodo]

part of

commit 0b9c100b60fc2502a0d6347d50cac444bb82b285
Author: Jonathan Pobst <[email protected]>
Date:   Wed Sep 28 15:50:39 2011 -0500

    Instead of preserving every method with a [Register] attribute on it in Mono.Android.dll, only save the things that the user actually uses.  Reduces HelloWorld release apk by ~1.3MB.
2015-07-19 10:42:43 +02:00
Radek Doulik 85ef32720f [linker] return count of marked methods
[merged from monodroid by rodo]

 - part of

commit 216f75038afee2105182fc6af329f1fc83c4298f
Author: Radek Doulik <[email protected]>
Date:   Sun Nov 23 11:40:42 2014 +0100

    [linker] mark methods (from Register attr) in base type when needed

     - fixes #10268
     - methods from these Register attributes were not marked:

       https://github.com/xamarin/monodroid/blob/master/src/Mono.Android/src/Android.Widget/AdapterView.cs#L132-135

       because the app used class derived from BaseAdapter class and the methods
       existed only in the base class and were not marked
2015-07-19 10:42:24 +02:00
Radek Doulik 9cb1729ada [linker] fix Linking for assemblies with type forwarders (like PCL)
[merged from monodroid by rodo]

commit 840487dd904a5552f77dcc7388b27c37ca09169f
Author: Radek Doulik <[email protected]>
Date:   Thu Oct 16 20:03:58 2014 +0200

     - sometime the assemblies with action set to Copy still might
       contain type references to forwarders and thus point to
       Delete assemblies, which are removed during linking, resulting
       in unresolvable type references

     - fixes https://bugzilla.xamarin.com/show_bug.cgi?id=23617
       XA forms template now builds and works OK
       XA app template builds and works OK
2015-07-19 10:42:03 +02:00
Radek Doulik c0ac993ec5 [linker] process only .xml files, catch xml exceptions
[merged from monodroid by rodo]

commit f51f044e30b822f191777a395563ef9d46f8b69d
Author: Radek Doulik <[email protected]>
Date:   Wed Mar 4 18:28:59 2015 +0100

     - fixes #27620

     - in this case we were trying to process Application.java
       as linker an assembly XML linker description, which led
       to uncaught XmlException
2015-07-19 10:41:36 +02:00
Radek Doulik f8180827a5 [linker] In ResolveFromXmlStep, bail if no <linker> element is found.
[merged from monodroid by rodo]

commit 2edecdc39ca55c65de4f57557e5e31b5d432eaa4
Author: Alex Rønne Petersen <[email protected]>
Date:   Mon Jul 1 15:35:59 2013 +0200

    The BlacklistStep pass will feed the ResolveFromXmlStep pass XML files
    that may not necessarily *be* linker descriptor files. This can happen
    if an embedded file happens to be named "Foo.Bar.xml" and an assembly
    called Foo.Bar is referenced in a project. The chances of this happening
    are probably very low, but better safe than sorry.
2015-07-19 10:40:50 +02:00
Radek Doulik 6685432a97 [linker] Fortify the BlacklistStep.
[merged from monodroid by rodo]

commit 3001f693c52be0da673446179daf498265024867
Author: Alex Rønne Petersen <[email protected]>
Date:   Tue Jul 30 20:06:21 2013 +0200

    1. Catch XmlExceptions in case of broken XML files.
    2. Only process files that actually end in ".xml".
2015-07-19 10:40:28 +02:00
Radek Doulik 7db10d04cb [linker] Support linker descriptor files embedded in the assemblies being linked.
[merged from monodroid by rodo]

commit 3e19b22eb24ff9faeebe1ace7461d8f91f807041
Author: Alex Rønne Petersen <[email protected]>
Date:   Mon Jul 1 15:34:26 2013 +0200

    This is in addition to those files that are already embedded in the linker assembly
    itself (such as mscorlib.xml). People can use this feature to tell the linker that
    certain methods/fields/types must be kept if a particular assembly is being referenced
    by embedding a descriptor file in it.
2015-07-19 10:40:14 +02:00
kasthack 276f80b066 [System.Web] Imported some interfaces, attributes and enums from reference source:
ISubscriptionToken, IModelNameProvider, BindingBehaviorAttribute, BindingBehavior, BindNeverAttribute, BindRequiredAttribute, ExtensibleModelBinderAttribute, ModelBinderProviderOptionsAttribute,  CodeCharts,  WebBrowsableAttribute, WebDescriptionAttribute, WebDisplayNameAttribute, AspNetWebSocketOptions
2015-07-18 18:30:15 +03:00
kasthack 8a5df4cdf1 [System.Web] Made HttpApplication method parameters match reference version 2015-07-18 17:39:05 +03:00
Marek Safar 2467550865 [System.Web] Fixes make dist 2015-07-18 07:37:02 +02:00
Marek Safar 904ca259ce [mcs] Update to latest mscorlib 2015-07-17 22:17:29 +02:00
Marek Safar 51bf97f97a [build] Update facades to mobile profiles 2015-07-17 16:38:40 +02:00
Marek Safar 60c0670022 [Facades] Add partial facades with missing (unknown) types 2015-07-17 14:51:22 +02:00
Marek Safar 8eeb73cd69 [System.Numerics.Vectors] Fixes public key 2015-07-17 09:34:38 +02:00
Zoltan Varga 508147e22d Fix a warning. 2015-07-16 20:12:33 -04:00
Zoltan Varga 4a685f44c8 [llvm] Add support for returning vtypes as a scalar, this is used on arm64. 2015-07-16 17:32:18 -04:00
Mark Probst 179a700b34 [sgen] Don't crash on canaries when called from mono_gc_scan_for_specific_ref().
This function is only ever called from the debugger, and we don't want
it to crash when a canary has been overwritten.
2015-07-16 13:48:28 -07:00
Ludovic Henry 894d4033e9 [threadpool-ms] Use define for monitor thread minimal lifetime 2015-07-16 16:32:18 -03:00
Ludovic Henry 408d052b33 [threadpool-ms] Fix monitor thread starting and ending at a multiple times per second 2015-07-16 16:25:47 -03:00
Marek Safar 70ffb46c6c [Facades] Add missing folder 2015-07-16 21:12:19 +02:00
Marek Safar 34dc31f4cc Remove aggressive filter 2015-07-16 21:11:48 +02:00
Marek Safar ffcba69d63 [build] Add System.Numerics.Vectors skeleton 2015-07-16 20:58:11 +02:00
João Matos 6fd8b69507 [runtime] Implemented MonoContext for WatchOS using ucontext.
We cannot use inline assembly for WatchOS.
2015-07-16 18:55:24 +01:00
Marek Habersack 9b35dc2e9c [tests] Fix tests on OS/X
OS/X, like Android, uses a symlink for the $TMP directory. The tests used to assume
that the link points to the /private/tmp directory (which is the case) but earlier
changes introduced here for Android employed a more generic mechanism to determine the
actual temporary directory.
This commit removes the '/private' prefix assumption from OS/X
2015-07-16 17:56:14 +02:00
Marek Safar 04114a5e9d [Facades] Add v3 facades 2015-07-16 17:32:04 +02:00
Marek Habersack b9cff43b3c [tests] 4.x profiles produce test assembly suffixed with 4_x now 2015-07-15 21:47:34 +02:00
Marek Habersack 9c6a9ea9b4 [tests] corlib tests are in corlib_test_net_4_x.dll now 2015-07-15 21:36:12 +02:00
Marek Habersack 04288920cc [tests] Disable until a server that works is found
This test depends on server behavior. I changed the server to xamarin.com
earlier on, but it stopped behaving as required recently. The test should
not rely on random servers, so until we have a server we can rely on I'm
disabling it.
2015-07-15 20:45:42 +02:00
Marek Habersack 78a9ce5b5c [tests] Crashes on Android 64-bit
Disable for all other architectures as well, as there's not enough
flexibility in this respect :(
2015-07-15 20:45:42 +02:00
Marek Habersack 7d357b299a [tests] Disable on Android due to runtime segfault
The Dispose call in FakeSafeHandle causes the Mono runtime to segfault
when passing the call up the chain. As a consequence of disabling the
base class call, the other tests disabled by this commit fail.
2015-07-15 20:45:41 +02:00
Marek Habersack cf14441d39 [tests] Runtime segfaults on Android, probably due to AppDomain.Unload 2015-07-15 20:45:40 +02:00
Marek Habersack 58060d3703 [tests] Disable tests not working on mobile platforms 2015-07-15 20:45:40 +02:00
Marek Habersack 5fb344b4d3 [tests] Add Xamarin.Android assembly name to list of probes 2015-07-15 20:45:39 +02:00
Marek Habersack 0a6e2a2ca2 [tests] Disable on Android due to environment differences
Assemblies in Xamarin.Android cannot be accessed as FileStream/files directly
2015-07-15 20:45:39 +02:00
Marek Habersack 7dcd6b480f [tests] Adjust the test for Android-specific behavior 2015-07-15 20:45:38 +02:00
Marek Habersack 6013224ecf [tests] Disable on Android due to environment differences
Xamarin.Android doesn't ship with the Mono.Compilerservices.SymbolWriter
assembly that is required by this test.
2015-07-15 20:45:38 +02:00
Marek Habersack 35f885dd2d [tests] Assembly.GetEntryAssembly works differently on Android
There's no entry assembly as such, adjust the test accordingly.
2015-07-15 20:45:37 +02:00
Marek Habersack 7a37a57bb5 [tests] Disable on Android due to environment differences
It's not possible to save the assembly in the current directory on Android and AssemblyBuilder.DefineDynamicModule will not
allow a full path to the assembly to be passed to it. Trying to change the current directory before saving will not work either as
FileStream will then prepend / to the file name (perhaps it's another bug) and write access to the filesystem root is, obviously, denied
2015-07-15 20:45:36 +02:00
Marek Habersack a53f6769cc [tests] Disable on Android due to environment differences
Xamarin.Android doesn't ship with the Mono.Compilerservices.SymbolWriter
assembly that is required by this test.
2015-07-15 20:45:36 +02:00
Marek Habersack 70511efc74 [tests] Disable on Android
Fails with System.MethodAccessException : Method `t17:.ctor ()' is inaccessible from method `t18:.ctor ()'
2015-07-15 20:45:35 +02:00
Marek Habersack 0e59c71dee [tests] Disable parts relying on APIs not in Mobile Profile 2015-07-15 20:45:35 +02:00
Marek Habersack 920da6b14f [tests] The test crashes the runtime 2015-07-15 20:45:34 +02:00
Marek Habersack 69014a0326 [tests] Disable code to prevent Mono runtime crash
AppDomain unloading causes a segfault with the Mono runtime on Android.
Until the cause is found and fixed this code must remain disabled.
2015-07-15 20:45:34 +02:00
Marek Habersack cc34b03b2f [tests] Disable on Android due to environment differences
Xamarin.Android doesn't ship with the Mono.Compilerservices.SymbolWriter
assembly that is required by this test.
2015-07-15 20:45:33 +02:00
Marek Habersack cadd1396cb [tests] Disable on Android due to environment differences
DefineResource doesn't allow path in its fileName parameter and the
test attempts to write to / in effect (which is the default CWD for
Android apps)
2015-07-15 20:45:32 +02:00
Marek Habersack 4bc5192886 [tests] Xamarin.Android works the same way as the desktop Mono 2015-07-15 20:45:32 +02:00
Marek Habersack 947e37c028 [tests] Adjust test to work in unsupported scenarios
On Android (possibly on other systems too) it is possible that no gateway address is available and its lack is NOT an error
Here is a sample of /proc/net/route from Nexus 9 running Android 5.1.1 (IPInterfaceProperties parses that file on Linux)

  Iface	Destination	Gateway 	Flags	RefCnt	Use	Metric	Mask		MTU	Window	IRTT
  wlan0	0001A8C0	00000000	0001	0	0	0	00FFFFFF	0	0	0

Gateway is set to any address and it is explicitly ignored by the route information parser

For comparison, here's route contents from an Android 4.4.4 device:

  Iface	Destination	Gateway 	Flags	RefCnt	Use	Metric	Mask		MTU	Window	IRTT
  wlan0	00000000	0101A8C0	0003	0	0	0	00000000	0	0	0
  wlan0	00000000	0101A8C0	0003	0	0	203	00000000	0	0	0
  wlan0	0001A8C0	00000000	0001	0	0	0	00FFFFFF	0	0	0
  wlan0	0001A8C0	00000000	0001	0	0	0	00FFFFFF	0	0	0
  wlan0	0001A8C0	00000000	0001	0	0	203	00FFFFFF	0	0	0
  wlan0	0101A8C0	00000000	0005	0	0	0	FFFFFFFF	0	0	0

Obviously, this test fails on the first device and succeeds on the second. For this reason the test is modified to succeed
in case of devices like the first one since it's not a real failure but a shortcoming of the .NET API
2015-07-15 20:45:31 +02:00
Marek Habersack 2378ff1a8c [tests] Fix tests which rely on temp dir location being a real dir
Android M (that's where I ran into it) makes the path returned by
Path.GetTempPath () a symlink to the real directory used for temporary
files. When the tests change the directory the symlink is followed and
subsequent reads of the current directory name will return the real dir
name which doesn't match what was constructed using the value returned by
GetTempPath ()
2015-07-15 20:45:31 +02:00
Marek Habersack ce550dff61 [tests] Fails on Android ARM64
The test works on all the other supported architectures but segfaults on
ARM64 (Nexus 9 running Lollipop 5.1.1)
2015-07-15 20:45:30 +02:00
Marek Habersack 497d8fa71e [test] Disable on Android for now
The test throws the following exception

  MonoTests.System.Security.Cryptography.AesCfbTests.Roundtrip=System.Security.Cryptography.CryptographicException : Bad PKCS7 padding. Invalid length 236.
  at Mono.Security.Cryptography.SymmetricTransform.ThrowBadPaddingException (PaddingMode padding, Int32 length, Int32 position) <0x3bf26858 + 0x000bb> in <filename unknown>:0
  at Mono.Security.Cryptography.SymmetricTransform.FinalDecrypt (System.Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount) <0x3bf264f8 + 0x0022f> in <filename unknown>:0
  at Mono.Security.Cryptography.SymmetricTransform.TransformFinalBlock (System.Byte[] inputBuffer, Int32 inputOffset, Int32 inputCount) <0x3bf219b0 + 0x00077> in <filename unknown>:0
  at MonoTests.System.Security.Cryptography.CfbTests.Decryptor (System.Security.Cryptography.SymmetricAlgorithm algo, System.Byte[] encdata) <0x3bf261f8 + 0x00221> in <filename unknown>:0
  at MonoTests.System.Security.Cryptography.CfbTests.CFB (System.Security.Cryptography.SymmetricAlgorithm algo, Int32 feedbackSize) <0x3bf20000 + 0x0011b> in <filename unknown>:0
  at MonoTests.System.Security.Cryptography.AesCfbTests.CFB (System.Security.Cryptography.SymmetricAlgorithm algo) <0x3ca53ef0 + 0x00043> in <filename unknown>:0
  at MonoTests.System.Security.Cryptography.CfbTests.ProcessPadding (System.Security.Cryptography.SymmetricAlgorithm algo) <0x3ca53e80 + 0x0004f> in <filename unknown>:0
  at MonoTests.System.Security.Cryptography.CfbTests.ProcessKeySizes (System.Security.Cryptography.SymmetricAlgorithm algo) <0x3bf3fc20 + 0x000b7> in <filename unknown>:0
  at MonoTests.System.Security.Cryptography.CfbTests.ProcessBlockSizes (System.Security.Cryptography.SymmetricAlgorithm algo) <0x3bf3f910 + 0x0007b> in <filename unknown>:0
  at MonoTests.System.Security.Cryptography.AesCfbTests.Roundtrip () <0x3bf3cf28 + 0x00073> in <filename unknown>:0
  at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
  at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) <0x3bf3cc10 + 0x0008f> in <filename unknown>:0
2015-07-15 20:45:30 +02:00
Marek Habersack a0de21663e [tests] Don't use Assembly.Location on Android
Assembly.Location will contain just the assembly file name without any path, which
is not what the test(s) expect. The reason is that the assemblies on Android live
in the APK, are embedded in the native code or don't exist at all (AOT)
2015-07-15 20:45:29 +02:00
Marek Habersack 4ba51b2d63 [tests] Android behaves the same as desktop Mono
The same exceptions are thrown in Xamarin.Android, unlike in Xamarin.iOS which
behaves differently to desktop Mono
2015-07-15 20:45:29 +02:00
Marek Habersack 7cb4cc9c0e [tests] Disable for Android
The test works when only its fixture is ran, fails when ran as part of the
entire BCL test suite.
2015-07-15 20:45:28 +02:00
Marek Habersack be7f5259eb [tests] Disable because URL is no longer there
The test relies on presence of a specific file that is now gone. Disabled
until a stable URL is found :P
2015-07-15 20:45:27 +02:00
Marek Habersack a34f519919 [tests] Disable for Android
The test works when only its fixture is ran, fails when ran as part of the
entire BCL test suite.
2015-07-15 20:45:27 +02:00
Marek Habersack 278a97c61e [tests] Disable for Android
The test works when only its fixture is ran, fails when ran as part of the
entire BCL test suite.
2015-07-15 20:45:26 +02:00
Marek Habersack 4415d1f58e [tests] Android doesn't have access to Assembly.Location
Attempts to access the test dll which won't work on Android since the
dll is either in the apk or bundled in the native code or not there at
all (AOT)
2015-07-15 20:45:26 +02:00
Marek Habersack 405e9df234 [tests] Disable for Android
The tests work fine if only this fixture is ran, they fail when ran as part
of the entire test suite.
2015-07-15 20:45:25 +02:00
Marek Habersack efb7ced9c9 [tests] Disable for Android
The tests work fine if only this fixture is ran, they fail when ran as part
of the entire test suite.
2015-07-15 20:45:25 +02:00
Marek Habersack 0d8a22b3a0 [tests] System zlib errors out for these on Android 2015-07-15 20:45:24 +02:00
Marek Habersack 7dbce1ad58 [tests] Large locks not supported on Android
While bionic reports it supports 64-bit offsets for locks and exposes the
necessary APIs, attempt to use offsets larger than 32 bits results in
an error.
2015-07-15 20:45:23 +02:00
Marek Habersack f2d39fe696 [tests] The test hangs on Android 2015-07-15 20:45:23 +02:00
Marek Habersack 8948d49fec [tests] The test hangs on Android 2015-07-15 20:45:22 +02:00
Marek Habersack 28daa37f38 [tests] Use xamarin web server
http://elmundo.es/ started to send more than one cookie while
xamarin.com sends just one.
2015-07-15 20:45:22 +02:00
Marek Habersack 36288aca3a [tests] Don't assume specific charset
Don't assume a specific charset in HTTP response from a server. Google
changes response charset based on the country of the client's
IP. There's no point in checking for the specific charset, it's enough
to check whether the response header has correct format.
2015-07-15 20:45:21 +02:00
Marek Habersack 422f02adf2 [tests] Different CPUs have different precision
Fix the test to compare the subtraction result to value more
conservative than Double.Epsilon, to account for differences in
different CPU floating point units on Android.
2015-07-15 20:45:21 +02:00
Marek Habersack 389c66409b [tests] Use correct path in process tests
/bin/ls doesn't exist on Android, it's /system/bin/ls
2015-07-15 20:45:20 +02:00
Marek Habersack 2733407fb6 [test] There is no runtime directory on Android
We return an empty string which is considered to be a valid value in
Android. Adjust the test for that.
2015-07-15 20:45:20 +02:00
Marek Habersack 88160c4094 [tests] Use 2.1 profile assembly names for mobile 2015-07-15 20:45:19 +02:00
Marek Habersack 7cec10193b [tests] Make failures more descriptive and fix XA
The test failures didn't really indicate which of the Fail statements
caused the test failure. Also, the 10k offset turned out to be not
enough for the XA test suite (it's much bigger than that)
2015-07-15 20:45:18 +02:00
Marek Habersack c70e555970 [tests] Assembly.Location doesn't work on XA
Xamarin.Android stores assemblies inside apk (or bundled, or AOT-ed) and
so Assembly.Location will not point to a real path on the
filesystem. It merely contains assembly name.
2015-07-15 20:45:18 +02:00
Marek Habersack 39e0b4b507 [tests] No Mono.CompilerServices.SymbolWriter in XA 2015-07-15 20:45:17 +02:00
Marek Habersack debd0c9e8e [tests] No declarative security in mobile profile 2015-07-15 20:45:17 +02:00
Marek Habersack b28f08e67f [tests] Fix for when CWD is /
The test case doesn't account for the situation when the tests are ran
at the root of the Unix filesystem. This is, admittedly, a rare case on
Desktop but it's precisely what CWD is for Android processes. The test
would fail because it would get a path of the //Form instead of the /Form
2015-07-15 20:45:16 +02:00
Marek Habersack 3b0acf8d40 [tests] Works in stand-alone app, fails in nunit 2015-07-15 20:45:16 +02:00
Marek Habersack 9676c58e47 [tests] Fails on mobile with no details 2015-07-15 20:45:15 +02:00
Marek Habersack edaa4926a4 [tests] Doesn't work on mobile 2015-07-15 20:45:14 +02:00
Marek Habersack 8d71c9c4af [tests] Works in stand-alone app, fails in nunit 2015-07-15 20:45:14 +02:00
Marek Habersack 4a62b23240 [tests] Xamarin.Android has the desktop behavior 2015-07-15 20:45:13 +02:00
Marek Habersack ed03b96c7b [tests] Xamarin.Android already has the namespace 2015-07-15 20:45:13 +02:00
Marek Safar 978d44191a [build] Update missing file 2015-07-15 18:06:11 +02:00
Marek Safar 62c86e2243 [build] Update profiles path 2015-07-15 17:57:01 +02:00
Marek Safar 3d6a5aeada [build] Update profiles path 2015-07-15 17:34:54 +02:00
Marek Safar 7b48f80754 [Facades] More missing types 2015-07-15 17:30:20 +02:00
Marek Safar c9fe374985 [Facades] Update to 4.6 api 2015-07-15 16:35:59 +02:00
Marek Safar 0bc83209a0 [build] Update docs profile paths 2015-07-15 16:34:56 +02:00
Marek Safar d44898a230 [build] Switch to 4.6 profile as default profile 2015-07-15 16:10:19 +02:00
Marek Safar c4f0cacd96 Bump binary-reference-assemblies 2015-07-15 09:39:51 +02:00
Ludovic Henry 5839d38c24 [corlib] Use ManualResetEvent.WaitOne instead of Thread.Sleep to test Thread.Interrupt
This is because Thread.Sleep does not use the thread interrupt mechanism, while WaitHandle.{WaitOne, WaitAll and WaitAny} do
2015-07-14 19:04:15 -03:00
Ludovic Henry 02a15d6cf0 [runtime] Implement wait interrupt in thread info, instead of in the io-layer
This lets us take one more thing out of io-layer, to hopefully reduce it to a bare minimum some day.
2015-07-14 19:04:14 -03:00
Ludovic Henry 087e696c39 [utils] Remove dead code 2015-07-14 19:04:14 -03:00
Ludovic Henry 342f788abf [io-layer] Remove _wapi_handle_wait_signal_handle and _wapi_handle_wait_signal functions 2015-07-14 19:04:14 -03:00
Ludovic Henry 9b5c911edb [io-layer] Remove _wapi_thread_apc_pending function
All calls to _wapi_thread_apc_pending were done with a handle to the current thread. It is better to just use _wapi_thread_cur_apc_pending.
2015-07-14 19:04:13 -03:00
Martin Baulig 4efdd29f70 [xbuild]: Fix ResolveAssemblyReference.ResolveReference() with empty search paths.
When using shared projects, the search path and/or framework paths may sometimes
contain empty elements.

This fixes commit 5b12d9ae37.
2015-07-14 23:38:40 +02:00
Zoltan Varga 3859b12c0e [llvm] Add support for pass/returning vtypes by ref. 2015-07-14 17:19:17 -04:00
Marek Safar d07400cbd4 [system] Add missing APIs 2015-07-14 20:08:12 +02:00
Ludovic Henry 312ad9deef [threadpool-ms-io] Fix epoll socket close/remove race condition
With the previous commit, it fixes a range of bug that happens only with epoll. This is because, contrary to poll and kqueue, epoll keeps an internal state that has to be kept in sync with the threadpool_io->states hash table.

This threadpool_io->states hash table is keeping a list of file descriptor to watch, with the corresponding SocketAsyncResult to callback in case of event on the fd. But epoll also keeps its internal state that needs to me modified with EPOLL_CTL_ADD, EPOLL_CTL_MOD and EPOLL_CTL_DEL.
Contrary to kqueue, EPOLLONESHOT does not force epoll to remove the socket from its internal state once an event have been triggered; but it will just not fire this event again, until this event is reset. Also, epoll will remove a fd from its internal state when this fd is closed.

This will lead to a bunch of out-of-sync states like the following :
 - the user start reading asynchronously the STDOUT of a child process, the child process quit (closing the STDOUT fd), this fd is reused by the OS for something else (like a socket), the IO threadpool call epoll_ctl with EPOLL_CTL_MOD (because the fd is still in the states hashtable), but the OS returns an error because the underlying file is different, even if the fd is the same.
 - the user opens a socket, does some asynchronous operation on it, and close it; removing it from the table but not from epoll (as it does not call epoll_ctl with EPOLL_CTL_DEL). For another reason, the fd has not been closed in the OS (and thus in epoll), because it might, for example, still be open by another process. After that, we receive an event for this fd (as it is still in epoll), and between the time of the epoll_wait and the epoll_ctl with EPOLL_CTL_DEL, the fd is actually closed in the OS, leading to a EBADF error.

The g_warning have also been replaced by g_error, so we do not silently discard this kind of error in testing.
2015-07-14 14:56:06 -03:00
Ludovic Henry a004e31dc7 [bcl] Remove ProcessAsyncReader handle from IO ThreadPool on closing 2015-07-14 14:56:06 -03:00
Ludovic Henry cd777415a8 [threadpool-ms-io] Rework some utility functions 2015-07-14 14:56:06 -03:00
Ludovic Henry 3d92649606 [threadpool-ms-io] Replace the 2 locks by only 1 2015-07-14 14:56:05 -03:00
Zoltan Varga d7ef211929 [runtime] Fix the mono_get_lmf_addr () optimization for x86-ios. Fixes #31921. 2015-07-14 13:42:56 -04:00
Ludovic Henry 7ca32ef62a [utils] Factor lazy initialization of threadpool-ms and threadpool-ms-io for use by other modules 2015-07-14 12:37:40 -03:00
Zoltan Varga f5ce510c9d Disable the test added by 37ad145b2f, it doesn't work on all platforms. 2015-07-14 09:00:40 -04:00
Marek Safar 500c91bfb4 [ilasm] Imlicitly set enums value__ special flags 2015-07-14 11:32:23 +02:00
Rolf Bjarne Kvinge ca42f0f3cb Look for resgen2 where mcs is.
Fixes an issue on El Capitán where resgen2 isn't necessarily in PATH.
2015-07-14 10:24:43 +02:00
Vlad Brezae 8a740078c9 Merge pull request #1730 from BrzVlad/feature-arm-fast-tls
Feature arm fast tls
2015-07-13 19:42:56 -07:00
Ludovic Henry 8789851a63 [threadpool-ms] Add tracing 2015-07-13 22:52:22 -03:00
Marek Safar 9b0b4497fb [ilasm] Make only structs automatically sealed (partially reverts 541a65ddd3) 2015-07-13 23:14:43 +02:00
Marek Safar 541a65ddd3 [ilasm] Don't make enums and structs sealed when sealed modifier is not used 2015-07-13 22:38:04 +02:00
Zoltan Varga 94bb7f194b [jit] Fix float32 support for the interlocked opcodes. 2015-07-13 15:14:24 -04:00
Zoltan Varga 37ad145b2f [amd64] Fix marshalling of empty structures. 2015-07-13 13:57:25 -04:00
Marek Safar 7faba3ca52 [System] Don't assume WebConnectionStream of unknown http methods require write stream. Fixes #31830 2015-07-13 14:11:25 +02:00
Zoltan Varga 92adf9c4af Merge pull request #1927 from borgdylan/x86fix
fix the x86 build
2015-07-13 03:52:18 -04:00
Dylan Borg af6e844ed6 fix the x86 build 2015-07-13 09:18:03 +02:00
Zoltan Varga 03c0dd16c6 [runtime] Add support for portable pdb files without a MODULE table. Fix mono_ppdb_get_seq_points (). 2015-07-12 16:35:01 -04:00
Zoltan Varga cab53b1eb9 [runtime] Make mono_trace_set_printerr_handler () call g_set_printerr_handler (). Fixes #31451. 2015-07-12 12:37:39 -04:00
Zoltan Varga 9fa34b9f1b [runtime] Update portable pdb support for the latest spec. 2015-07-12 00:14:36 -04:00
Alex Rønne Petersen 4683ad4350 [profiler] Do the final sample dump on shutdown in the helper thread.
Reading the various fields on the profiler structure from the shutdown
thread is very racy; for example, we have no guarantee that we will see
a consistent GPtrArray structure for sorted_sample_events. It's better
to just let the helper thread empty the stat buffers when it shuts down.
2015-07-11 11:52:37 +02:00
Alex Rønne Petersen 0ec5cad047 [profiler] Process heapshot requests in all non-GC events. 2015-07-11 11:52:36 +02:00
Alex Rønne Petersen 4ce4b7621a [profiler] Fix a number of potential buffer overflows.
In many cases, we allocated less than we actually needed in the worst case. We
now spell out the size of each field in an event to make it less likely that
such mistakes are made in the future.
2015-07-11 11:52:36 +02:00
Alex Rønne Petersen d3752a5496 [profiler] Report more metadata load/unload information.
We now report:

* Start/stop events for threads, domains, and contexts.
* Friendly name changes for domains (as for threads).
* Assembly load/unload events (as for images).
* Unload events for images and classes.
2015-07-11 11:52:35 +02:00
Alex Rønne Petersen 8a7f7a6187 [profiler] Add a thread ID field to sample events.
Previously, it was impossible to determine which thread a sample came from
because the buffer header thread ID for all sample events is the same (that of
the profiler's helper thread).
2015-07-11 11:48:09 +02:00
Alex Rønne Petersen 7aa0ae71b3 [profiler] Sort sample events by thread ID before outputting them.
This significantly improves overall compression of sample events as successive
sample events for the same thread are highly likely to contain similar method
pointers in managed backtraces.
2015-07-11 11:39:12 +02:00
Zoltan Varga 23453f346d [aot] Emit the got into the bss section on osx too. 2015-07-10 15:01:41 -04:00
Vlad Brezae ce47bfe3f4 [tests] Add tls stress test 2015-07-10 11:43:43 -07:00
Vlad Brezae 421fa312a5 [arm] Add MONO_DEBUG option for using only fallback tls. 2015-07-10 11:43:43 -07:00
Vlad Brezae 377b9f68cc [arm] Add fast tls support on ios. 2015-07-10 11:43:43 -07:00
Vlad Brezae 2fee9bb6fe [sgen] Use the sgen allocator fastpath also when cross compilling.
The platform needs to support tls for it to be generated.
2015-07-10 11:43:42 -07:00
Vlad Brezae 50d960afc6 [sgen] Fix allocator creation when running with jit disabled.
We don't allocate the method header when not jitting.
2015-07-10 11:43:42 -07:00
Vlad Brezae 2c16da1828 [arm] Add fast tls support on android. 2015-07-10 11:43:42 -07:00
Vlad Brezae a1366dccaa [sgen] Allocator defines depend on the target not the host. 2015-07-10 11:43:42 -07:00
Vlad Brezae c28385dfff [arm] Add fast tls support on linux
Add support for OP_TLS operations. The code that implements this is comprised of getter and setter asm thunks, which is either inlined, or it uses external code. At runtime we check the implementation on the system, using the inlined thunks if we can.
2015-07-10 11:43:41 -07:00
Marek Safar 262c53a4ed [mcs] Emit symbol info local variables for compiler generated storey variables. Fixes #31784 2015-07-10 20:07:55 +02:00
Marek Safar 677ef8fe1d [mcs] Remove NET_4_0 ifdefs 2015-07-10 20:07:55 +02:00
Rodrigo Kumpera 0d9c8d1aff [jit] Use a feature macro instead of hardcoding users. 2015-07-10 13:36:15 -04:00
Rodrigo Kumpera e05fde7c23 Remove duplicated code. 2015-07-10 12:26:36 -04:00
Rodrigo Kumpera 7237750b52 [arm] Fixed the max length of seq_point. Fixes #31829. 2015-07-10 12:20:04 -04:00
Rodrigo Kumpera e6f6980b6c [jit] Disable fast tls on osx if MONO_HAVE_FAST_TLS is not defined. 2015-07-10 12:00:17 -04:00
Rodrigo Kumpera f0178aa93e [utils] Disable fast TLS on darwin until we have proper fallbacks in place. 2015-07-10 10:07:34 -04:00
Rodrigo Kumpera 1d0455c5ea [mini] Add some extra asserts around fast tls to ensure we don't mess up. 2015-07-10 10:07:33 -04:00
Rodrigo Kumpera 7cf92e5fd6 [utils] Don't abort at startup if remote TLS reads is not available.
Remote TLS reads is not a required feature for the runtime to work on
mach systems. We still want it available, but can leave the assertion
to happen when someone actually use it.

Usage won't happen today as part of regular code execution, so moving
the assert will make us more robust.
2015-07-10 10:07:33 -04:00
Rodrigo Kumpera 85aa333aa9 [utils] Add fallback TLS offset scanning to X86 and AMD64. 2015-07-10 10:07:33 -04:00
Rodrigo Kumpera 00af1bc367 Merge pull request #1922 from antonmes/master
Add TLS offset for pre-release OS X 10.11 on x86
2015-07-10 09:48:54 -04:00
João Matos 5158c7fd4f Merge pull request #1924 from bosmacs/master
Add TLS offset for pre-release OS X 10.11 x86, as #1919 did for x64
2015-07-10 13:12:46 +01:00
Craig S. Bosma 96a96d2ef0 Add TLS offset for pre-release OS X 10.11 x86, as in #1919 for x64 2015-07-10 06:56:23 -05:00
Lukasz c7159f1def Put quotes around path to mono. Fixes bug where Process.Start will fail for a managed process if the path to mono contains spaces. 2015-07-10 10:27:55 +02:00
Toxa 82091b3332 Add TLS offset for pre-release OS X 10.11 on x86 2015-07-10 08:32:54 +03:00
Matt Zinkevicius 157a580d38 Allow disabling the mono-find-provides/requires RPM processing scripts 2015-07-09 19:52:01 -06:00
Zoltan Varga 0ecac8b111 [llvm] Remove the restriction on handlers without invokes, its not needed any more. 2015-07-09 15:35:30 -04:00
Zoltan Varga 15955fafc5 [jit] Fix a regression introduced by ce567f4026. cfg->flags was initialized with a JitFlags value. 2015-07-09 15:32:53 -04:00
Zoltan Varga eb1f955744 [llvm] Fix the handling of nested clauses. 2015-07-09 15:22:59 -04:00
Jonathan Pryor 46a6b54840 Merge pull request #1888 from joelmartinez/mdoc-flagsbug
[mdoc] Adds custom formatting for the `ObjCRuntime.Platform` enum.
2015-07-09 12:26:26 -04:00
Marek Safar 7e97fdfb22 Bump reference sources 2015-07-09 18:01:17 +02:00
Marek Safar c67fa857b1 [System.Net.Http] Reading ContentLength value actually set header property value. Fixes #30561 2015-07-09 17:48:15 +02:00
João Matos 0f9f44e101 Merge pull request #1919 from bosmacs/master
Add TLS offset for pre-release OS X 10.11 on amd64
2015-07-09 01:19:07 +01:00
Craig S. Bosma c8a3c4fd36 Add TLS offset for pre-release OS X 10.11 on amd64 2015-07-08 19:02:54 -05:00
Zoltan Varga 7e47248076 [sdb] Allow boxed vtypes as this when invoking vtype methods. Fixes #30023. 2015-07-08 17:09:32 -04:00
Joel Martinez 375a9e9277 [mdoc] Adds custom formatting for the ObjCRuntime.Platform enum.
This enum, which can be found in Xamarin's iOS and Mac products use a custom encoding
scheme which resulted in invalid values being shown when processed with mdoc. This patch
adds a special case to watch for this particular enumeration value, and decodes the data
correctly.

Additionally, the code that formats the values for flags enumerations was refactored. Future extensibility of this feature can now be done by simply implementing a new `FlagsFormatter`, and applying the proper logic in the `MakeAttributesValueString` function.
2015-07-08 16:18:16 -04:00
Zoltan Varga 09747fb182 [llvm] Fix a problem introduced by the previous change. 2015-07-07 18:32:21 -04:00
Zoltan Varga 8a290deb65 [llvm] Refactor the aot code a bit. 2015-07-07 18:24:05 -04:00
Zoltan Varga 36623d3cc4 [sdb] Allow invoking of valuetype ctors. 2015-07-07 16:33:09 -04:00
João Matos f3e4d331e7 Merge pull request #1917 from rtollert/bump-nunit-4.5
Bump nunit from mono/2.0 to mono/4.5.
2015-07-07 19:53:50 +01:00
Richard Tollerton 6b76c7e984 Bump nunit from mono/2.0 to mono/4.5. 2015-07-07 12:17:04 -05:00
Marek Safar 093bdec2f3 Merge pull request #1914 from kasthack/master
[System.Web] Added missing HttpRequestBase, HttpRequestWrapper and HttpRequest methods + properties:
2015-07-07 10:54:40 +02:00
Zoltan Varga 3f77fc9ed9 [aot] Fix static linking support when using llvm. 2015-07-06 22:01:31 -04:00
Zoltan Varga 3632699bac [aot] Handle already gsharedvt methods correctly in add_extra_method_with_depth (). 2015-07-06 20:54:33 -04:00
Zoltan Varga 21135083e8 [gsharedvt] Handle gsharedvt methods correctly in check_method_sharing(). We need to pass mrgctx/vtable arguments for them since at runtime, the specific method called could be a non-gsharedvt method. 2015-07-06 19:52:01 -04:00
Ludovic Henry a79507705b [runtime] Remove unused MonoDomain fields 2015-07-06 16:38:38 -03:00
Rodrigo Kumpera 565833e9e9 Merge pull request #1911 from ludovic-henry/threadpool-unhandled-exception
[threadpool-ms] Fix unhandled exception support
2015-07-06 15:36:56 -04:00
Zoltan Varga ddd82672a5 [aot] Mark the data arrays emitted using llvm as constant. 2015-07-06 15:01:13 -04:00
Jonathan Pryor 0bf72ac919 [Mono.Posix] Allow building without [Obsolete] Mono.Posix.
For a future Xamarin.Android release, we'd like to include
Mono.Posix.dll for simple Unix interop support.

That said, since Mono.Posix has never been included with
Xamarin.Andorid before, this makes a perfect opportunity to remove
some [Obsolete] cruft within Mono.Posix.dll, namely the types within
the Mono.Posix namespace.

Unfortunately, simply not compiling the types within the Mono.Posix
directory doesn't result in compilable code, due to references to
types within the Mono.Posix namespace by other types, e.g.
Mono.Unix.PeerCred using Mono.Posix.PeerCredData.

Fix things so that the Mono.Posix sources can be omitted, allowing
compilation of an assembly with fewer [Obsolete] types.

This change shrinks the size of Mono.Posix.dll by ~10.5KB.
2015-07-06 14:03:32 -04:00
Marcos Henrich 76cd0bf2c1 [SRE] Improved token fixups processing.
The runtime requires a MemberInfo from the fixups.
A metadata token needs to be translated into a MemberInfo.
Nontheless Module.ResolveMember only works with loaded assemblies.

Local unbuilded members also needed to be resolved so a new method
ResolveOrGetRegisteredToken was added to retrieve from the runtime the
cached XXXBuilder for a token.
2015-07-06 16:24:36 +01:00
Marcos Henrich 63ee609960 [SRE] Added ModuleBuilder.GetRegisteredToken icall
ModuleBuilder.GetRegisteredToken returns a Builder previously registered
for a token.

This is required when the builded module has not been yet loaded into
memory but we still need to resolve the token into a builder.
2015-07-06 16:24:35 +01:00
Marcos Henrich 770002ecd0 [SRE] Using BitConverter.ToUInt32 to read token. 2015-07-06 16:24:34 +01:00
Marcos Henrich 24ae2cf835 [SRE] Removed GetXXXToken module exception.
The exceptions were removed because GetXXXToken should be able to return
tokens relative to the current module regardless of the XXX module.
2015-07-06 16:24:27 +01:00
Marcos Henrich bb139b85cd [SRE] Fixes GetMethodToken GetConstructorToken.
ModuleBuilder.GetMethodToken and ModuleBuilder.GetConstructorToken. no
longer crash when called with a null optionalParameterTypes.
2015-07-06 16:22:44 +01:00
Marcos Henrich 85343ce2de [SRE] Test ModuleBuilder methods with null params.
Test MethodBuilder.GetMethodToken and MethodBuilder.GetConstructorToken with
options parameter set to null.
2015-07-06 16:20:36 +01:00
Marcos Henrich 58ab14a6a8 [SRE] Added ConstructorBuilder.SetMethodBody. 2015-07-06 16:20:36 +01:00
Marcos Henrich f2a25c1d40 [SRE] Moved SetMethodBody code to ILGenerator. 2015-07-06 16:20:35 +01:00
Marcos Henrich 8d9b007e71 [SRE] Added missing method overloads.
Added GetMethodToken and GetConstructorToken overloads.
2015-07-06 12:36:25 +01:00
Marcos Henrich a4c2f42e06 [SRE] Added TypeBuilder.DefineNestedType overload. 2015-07-06 12:36:25 +01:00
Marcos Henrich b3ced10029 [corlib] Added method MethodBuilder.SetMethodBody. 2015-07-06 12:36:25 +01:00
Marcos Henrich 8987e4a5d6 [corlib] Added tests for MethodBuilder.
Added tests for MethodBuilder.CreateMethodBody and MethodBuilder.SetMethodBody.
2015-07-06 12:36:25 +01:00
Marcos Henrich 7e73eabc52 [corlib] Added referencesource types.
Mono now uses referencesource ExceptionHandlingClauseOptions and
ExceptionHandler.
2015-07-06 12:36:24 +01:00
Marcos Henrich 94e31f159f Merge pull request #1900 from esdrubal/cyclic-ref
[runtime] mono_class_from_name cyclic ref handling
2015-07-06 11:50:16 +01:00
Marcos Henrich a7c3e83d98 Merge pull request #1906 from esdrubal/xbuild-CopyLocal-fix
[xbuild] Fixes copied TargetFramework assemblies.
2015-07-06 11:49:40 +01:00
João Matos f7816d844a Merge pull request #1913 from RavuAlHemio/bug31635
[Mono.Posix] Special-case UTF-32 in PtrToString. Fixes #31635.
2015-07-06 11:10:32 +01:00
kasthack 303d876370 Added missing HttpRequestBase, HttpRequestWrapper and HttpRequest methods + properties:
* HttpRequestBase:GetBufferedInputStream, GetBufferlessInputStream,  InsertEntityBody, MapRawImageCoordinates, CurrentExecutionFilePathExtension, TimedOutToken
* HttpRequestWrapper: GetBufferedInputStream, GetBufferlessInputStream, MapRawImageCoordinates, TimedOutToken,
	* Fixed MapPath parameter name(overridePath -> virtualPath)
* HttpRequest: GetBufferedInputStream, GetBufferlessInputStream(bool), MapRawImageCoordinates, TimedOutToken
2015-07-06 09:23:51 +03:00
Ondřej Hošek 6bfb7e6d14 [Mono.Posix] Special-case UTF-32 in PtrToString. Fixes #31635.
Since UTF32Encoding returns 8 for GetMaxByteCount(1), PtrToString
expects 8 NUL bytes to stop scanning for the end of the string.
Since all the other UTF schemes are special-cased in
GetStringByteLength, do the same for UTF32Encoding.
2015-07-04 02:05:30 +02:00
Rodrigo Kumpera 5d93b2a292 [jit] Add emulation r4 to u8 conversion. Fixes #31582.
Most targets, like arm and amd64 don't support fast float to ulong conversion.
2015-07-03 14:32:04 -04:00
Ludovic Henry e53ccecd1a [threadpool-ms] Fix unhandled exception support 2015-07-03 00:44:01 -03:00
Ludovic Henry f3e35f228c [runtime] Fix cpu usage greater than 100% error
We simply relax the conditions as we do not need a very high precision.
2015-07-02 15:45:40 -03:00
Rodrigo Kumpera 6efe705614 Merge pull request #1907 from alexanderkyte/slow_aot_startup_hash
[runtime] Speed up find_aot_method_in_module
2015-07-02 14:03:15 -04:00
Alexis Christoforides ae2f50e57f [referencesource] Keep Mono's old default provider type value for RSA.
The value isn't used for the managed crypto code and is still validfor CryptoAPI, but if it changes Mono can't find keypairs made with earlier versions. Fixes #31199
2015-07-02 17:10:18 +03:00
Marcos Henrich 73e4bfeac7 Merge pull request #1860 from saper/tz-fix
[corlib] Assume UTC if no $TZ set. Fixes #30698.
2015-07-02 15:06:16 +01:00
Marcos Henrich 4f94e248c4 Bump reference sources 2015-07-02 10:53:40 +01:00
Ludovic Henry b1186d8d87 [threadpool-ms] Fix segfault when using sdb 2015-07-01 22:30:00 -03:00
Ludovic Henry bdfa2a2ef0 [runtime] Ease debugging of cpu_usage out of bound bug 2015-07-01 19:38:35 -03:00
Alexander Kyte 7bb3b98f58 [runtime] Conversion of a printf to string append for performance 2015-07-01 16:33:34 -04:00
Alexander Kyte 3d47daa63d [runtime] Avoid repeated method hashing in find_aot_module 2015-07-01 16:22:35 -04:00
Alexander Kyte e22887717f [runtime/tests] Added a stress test of find_aot_module. 2015-07-01 16:22:28 -04:00
Marcos Henrich 01dcc6c162 [runtime] mono_class_from_name cyclic ref handling
The changes fix stack overflows caused while traversing images with
cyclic references.

Fixes #31396
2015-07-01 17:26:28 +01:00
Sebastien Pouliot 080fc527bd [linker] Fix comparison of methods wrt generic parameters [#30488]
The check from [1] is fine when it's done once _or_ with an identical
target. However there's nothing to ensure (if done more than once) that
it's being used to represent the same thing every time.

That makes the code from [1] match methods like:

> System.IObservable`1<TResult> System.Reactive.Linq.IQueryLanguage::Repeat(TResult)

and

> System.IObservable`1<TSource> System.Reactive.Linq.QueryLanguage::Repeat(System.IObservable`1<TSource>)

where `TResult` is different in both checks.

This patch tracks what is used as the generic parameter (on first check)
and make sure it's identical if it's used again in the same signature.

Note: this is a very old bug (i.e. it's always been that way) but recent
changes to mono started to report such issues (a good thing) and, for AOT
compilation on XI, that resulted in MT3001 errors.

[1] https://github.com/mono/mono/blob/mono-3.10.0/mcs/tools/linker/Mono.Linker.Steps/TypeMapStep.cs#L250
2015-07-01 11:37:00 -04:00
Ludovic Henry 93bb234cea [threadpool] Remove mono threadpool implementation 2015-07-01 12:04:36 -03:00
Marcos Henrich 5b12d9ae37 [xbuild] Fixes copied TargetFramework assemblies.
xbuild was copying TargetFramework assemblies when the builded project
had dependencies in a TargetFramework.

Doing so is not the msbuild behaviour and was causing bugs while
resolving Types at load time.

Fixes #28592 and #31396
2015-07-01 15:49:37 +01:00
Marek Safar 613c2a9182 [system] Don't throw ObjectDisposedException on cancelled async WebConnection. Fixes #31507 2015-07-01 16:41:56 +02:00
Ludovic Henry 8be963e71b [threadpool-ms-io] Fix epoll
The socket would not be deleted with epoll_ctl (via epoll_reset_fd_at) when we would remove the state from threadpool_io.states. So when we would try to add it again, it would mark it as a new socket (as it wouldn't be present in threadpool_io.states), while it has not been deleted from epoll.
2015-07-01 11:20:07 -03:00
Rodrigo Kumpera fbec5a33f5 [utils] Remove a duplicated check that was commited by accident. 2015-06-30 16:45:13 -04:00
Ludovic Henry e2aaf5f1e9 [threadpool-ms-io] Fix compilation warning 2015-06-30 14:23:16 -03:00
Ludovic Henry a437cfa485 [io-layer] Disable shared handles support by default
They are a very fragile part of the runtime, as they are not very well aken care of.

We simply disable it by default for now. If everything still works as expected, we will completely remove the code.
2015-06-30 13:56:03 -03:00
Marek Safar 9b4901ba68 [mcs] Fixes name collision check for generic types within user namespaces. Fixes #30904 2015-06-30 11:50:57 +02:00
João Matos 2221dfc2d4 Merge pull request #1903 from vkargov/master
Fix the MinGW build.
2015-06-29 23:44:19 +01:00
Vladimir Kargov 12218c56e3 [runtime] Fix a crash on Windows during the cleanup phase caused by using a destroyed mutex. 2015-06-30 00:15:11 +03:00
Vladimir Kargov 237e1dd0ae [runtime] Add condition variable definitions that are missing on MinGW. 2015-06-30 00:12:08 +03:00
Zoltan Varga e02e386f22 Fix the build. 2015-06-28 18:53:49 -04:00
Neale Ferguson d78c44eb8c Fix and simplify float conversions 2015-06-28 15:55:12 -04:00
Zoltan Varga e9ee609924 Merge pull request #1901 from oafasting/master
Removed obsolete flag '-no-cpp-precomp' from darwin $CPPFLAGS
2015-06-28 10:31:23 -04:00
Ole A. Sjo Fasting 36eed8bcc2 removed flag -no-cpp-precomp from darwin cppglags, so that build is possible on osx 2015-06-28 13:58:49 +02:00
Zoltan Varga 4c6f366057 Fix the build. 2015-06-27 13:09:53 -04:00
Zoltan Varga f5ae0e5960 [aot] Emit AOT data structures using LLVM when using LLVM. 2015-06-26 15:07:05 -04:00
Miguel de Icaza f709994a7c Coverity: test if this is the way of silencing warnings 2015-06-26 12:41:02 -04:00
Zoltan Varga 80f427f36b Fix the loadable llvm build. 2015-06-26 11:59:07 -04:00
Marek Safar 51a802e889 [corlib] Fixes warning 2015-06-26 16:29:58 +02:00
Marek Safar c67cb401ae [corlib] Chinese (Simplified) and its legacy version are not equal. Fixes #31398 2015-06-26 16:28:07 +02:00
Marcin Cieslak b440b2e765 [resgen] Implement conditional resources (#if/#ifdef)
- Add support for #if, #ifdef, #if !SYMBOL, #else
and #endif directives

- Add /DEFINE: option:

  /D:SYMBOL1 /D:SYMBOL2 or /DEFINE:SYMBOL1,SYMBOL2
2015-06-26 10:30:05 +00:00
Marek Safar 03d3aa5e1d [corlib] Bump WaitAll_TimeoutWithExceptionsAfter timeouts 2015-06-26 12:14:14 +02:00
Marek Safar 4b675b9fbf [corlib] Add test for .net bug 2015-06-26 08:09:16 +02:00
Zoltan Varga a5f77b1997 [aot] Improve support for situations where mono_aot_get_method () etc. is passed an already gshared method. 2015-06-25 23:33:54 -04:00
Zoltan Varga a11552ac96 [aot] Remove an unused field from MonoAotModule. 2015-06-25 23:24:47 -04:00
Zoltan Varga 0450aa5e18 [aot] Encode the various aot tables into binary ourselves instead of relying on the assembler to do it, to make it easier to emit them using LLVM. 2015-06-25 23:08:33 -04:00
Zoltan Varga d1e96ecd29 Fix the DISABLE_JIT build. 2015-06-25 22:48:41 -04:00
Zoltan Varga c470c97f53 [aot] Clean up the naming of global symbols. 2015-06-25 22:24:00 -04:00
Zoltan Varga 493c27fbc4 [aot] Reorganize the emission of the MonoAotFileInfo structure to make it easier to emit it as LLVM data. 2015-06-25 21:47:40 -04:00
Zoltan Varga ce567f4026 [aot] Pass the aot method index to mini_method_compile (). 2015-06-25 20:28:10 -04:00
Zoltan Varga 8d75cf1659 [aot] Get rid of the 'methods' symbol in aot images, its no longer used. 2015-06-25 20:07:11 -04:00
Sebastien Pouliot 928a46005f [mono.sqlite] Provide the full path to the library for iOS 2015-06-25 18:43:12 -04:00
Zoltan Varga 89d7960667 Get rid of the of the usage of code offsets in aot-runtime.c, use method addresses instead. 2015-06-25 18:22:41 -04:00
Zoltan Varga aa8d8c0d04 [aot] Add support for running without a GOT for JITted code. 2015-06-25 17:58:32 -04:00
Zoltan Varga 2a9e0ea28f Fix the leaking of process streams when using RedirectStandardOutput etc., introduced by 3c47caca34. 2015-06-25 16:52:07 -04:00
Zoltan Varga 59e9320e33 Refactor the IMT call handling code into a separate function so it can be called from outside the trampoline code. 2015-06-25 16:40:30 -04:00
Zoltan Varga 79d153320c Clean up the trampoline code a bit. 2015-06-25 16:40:30 -04:00
Zoltan Varga c1aa0d3528 Clean up the imt trampoline code a bit. 2015-06-25 16:40:30 -04:00
Marek Safar f8bfe04f86 [system.net.http] Convert default request headers to string values using correct separator. Fixes #31336 2015-06-25 22:19:28 +02:00
Zoltan Varga 2e203a3f2e Merge pull request #1898 from alexanderkyte/debugger_variable_reflection
Fix TransparentProxy ObjectMirror value queries via debugger
2015-06-25 16:14:34 -04:00
Zoltan Varga dd66efe5bd Fix the compilation of the System tests. 2015-06-25 16:04:24 -04:00
Alexander Kyte 1035a366b0 [runtime] Handle TransparentProxies when getting object field values 2015-06-25 15:31:03 -04:00
Alexander Kyte 278977435c [runtime] Added a test for the repro of being unable to reflect an instance variable. 2015-06-25 15:30:54 -04:00
Miguel de Icaza e13ecbe243 Attempts to locate the C# and VB compilers based on the location of mscorlib, does not assume they are on the path. Fixes #31369 2015-06-25 13:57:04 -04:00
Marek Safar 4f4b324aa2 [system] Disable external process redirect test on mobile 2015-06-25 15:58:35 +02:00
Rolf Bjarne Kvinge 97f919f7b7 Add a monotouch_watch profile. 2015-06-25 13:28:11 +02:00
Rolf Bjarne Kvinge 772ba35faa Support #include directives in external sources files. 2015-06-25 13:27:26 +02:00
Rolf Bjarne Kvinge a9d8378eb4 Remove --with-[monotouch|xammac]=only from configure.
The Xamarin.iOS and Xamarin.Mac builds don't use these options,
so remove them to reduce unnecessary complexity.
2015-06-25 13:27:20 +02:00
Marek Safar ff73b91019 [mcs] Add null operator propagation to probing expressions. Fixes #31289 2015-06-25 09:23:13 +02:00
Zoltan Varga a1eee3c2a1 [runtime] Use MONO_GENERIC_CONTEXT_USED_CLASS/METHOD constants to mini.h. 2015-06-24 21:38:43 -04:00
Zoltan Varga 73c0695baf [runtime] Get rid of the MONO_GENERIC_SHARING env variable, its no longer needed. 2015-06-24 21:36:16 -04:00
Marek Safar 550195c728 [ilasm] Custom attributes syntax with typeref expression 2015-06-24 20:59:16 +02:00
Marek Safar b4d8e1588c [runtime] Update incorrect test (exposed by f2039ff720) 2015-06-24 16:51:13 +02:00
Alex Rønne Petersen ad600a087f Merge pull request #1869 from alexanderkyte/appdomain_parallel
[runtime] Fixed use-after-free in context freeing
2015-06-24 05:29:36 +02:00
Zoltan Varga 5220a7851d [jit] Properly set the klass of the MonoInst pushed on the IL stack by the refanyval opcode. Fixes #31231. 2015-06-23 22:17:13 -04:00
Ludovic Henry 476e5e7eb8 [corlib] Fix NRE in TaskScheduler.GetTaskSchedulersForDebugger
See external/referencesource/mscorlib/system/threading/Tasks/TaskScheduler.cs:582
2015-06-23 19:53:00 -03:00
Marek Safar f2039ff720 [ilasm] Pair methods using their calling convention, this allows to have static and non-static properties with same name 2015-06-23 19:35:59 +02:00
Marek Safar 47f5b69bfb [ilasm] Even more undocumented custom attributes syntax 2015-06-23 19:35:58 +02:00
Sebastien Pouliot eaee29fbd7 [linker] Add Mono.Cecil.*.Has* checks when comparing methods/types
* It reduce memory allocations by avoiding the creation of empty
  collections (only used to tell us there's a Count of 0);

* It also speed up execution, less object creation/GC time;

* Patch also remove some double-casts (is + as/cast)
2015-06-23 13:03:10 -04:00
Zoltan Varga 5c4a0c67a9 Merge pull request #1874 from saper/bug_29679
[msbuild][crash] Enums are classes that can be assigned to value types
2015-06-22 15:54:14 -04:00
Mark Probst 263d3d5065 [sgen] Remove a weird unnecessary cast. 2015-06-22 12:07:01 -07:00
Mark Probst e4b0406c24 [sgen] GCObject* instead of void* 2015-06-22 12:07:00 -07:00
Mark Probst 643854c8cf [runtime] GC descriptor typedef. 2015-06-22 12:07:00 -07:00
Mark Probst 31e37fdc0a [sgen] Typedef for GC descriptors. 2015-06-22 12:07:00 -07:00
Mark Probst 335952335d [sgen] GCObject* instead of char* where appropriate. 2015-06-22 12:06:59 -07:00
Mark Probst ac98a2c9d9 [sgen] Make GCVTable type opaque, not a pointer. 2015-06-22 12:06:59 -07:00
Miguel de Icaza a0f6764ca7 Merge pull request #1887 from debugerr/patch-2
Null reference check before calling delegate
2015-06-22 14:50:59 -04:00
Ludovic Henry a25b2bfcfd [threadpool-ms-io] Rework socket removal job cancellation 2015-06-22 14:29:30 -03:00
Ludovic Henry 8d6a0e814f [threadpool-ms-io] Remove dependency on SocketAsyncResult list in the backends
This reduce the duplication and complexity of the code in the different backends
2015-06-22 14:29:30 -03:00
Ludovic Henry d8cf0dae81 [threadpool-ms-io] Fix race between socket add and remove
The following race could occur and lead to a EBADF error with kevent and epoll :
 1. mono_threadpool_ms_io_add is called with fd 1234
 2. mono_threadpool_ms_io_remove_socket is called when closing fd 1234
 3. selector_thread calls update_add with socket 1234, which will call kevent with this already closed socket

The solution is simply to remove all the SocketAsyncResult from states, as well as updates, for the given socket fd
2015-06-22 14:29:30 -03:00
Ludovic Henry 65692c1aa7 [threadpool-ms-io] Rework AsyncReadHandler detection 2015-06-22 14:29:29 -03:00
Ludovic Henry 10ad5ff1de [threadpool-ms-io] Fix update on epoll 2015-06-22 14:29:29 -03:00
Marek Safar e040f8f8d1 [ilasm] Add another undocumented custom attributes initializer syntax 2015-06-22 17:57:26 +02:00
Chris Hamons b92d706d0c Fix System.Messaging makefile logic issue
- Introduced in b044a27fe0
2015-06-22 10:22:12 -05:00
Marek Safar 52da65ddb5 [ilasm] Fix invalid codegen for method overloads with unique modop/modreq type only 2015-06-22 14:07:05 +02:00
Atsushi Eno cc9ddec7c4 [S.R.Serialization] fix default value comparison.
The fixed code used to invoke null.Equals(other).

The new test (by @alien0ada) shows the failing case.
2015-06-22 20:12:38 +09:00
Marek Safar 0780c58b98 [ilasm] Add emit of custom string attribute using member syntax 2015-06-21 13:21:15 +02:00
Zoltan Varga c55393e99d Merge pull request #1889 from alexanderkyte/debugger_locals_failure
[runtime] Add a missing NOP to the OP_SEQ_POINT arm code
2015-06-20 19:19:59 -04:00
Alexander Kyte 0c604e7175 [runtime] Add a missing NOP to the OP_SEQ_POINT arm code
We were failing MonoTests.DebuggerTests.Locals and
MonoTests.DebuggerTests.SingleStepping because we
stepped forward too far as a side effect of this missing
"padding" NOP.
2015-06-20 22:17:57 +00:00
Zoltan Varga fd2cdf9b9a Fix the build. 2015-06-19 16:28:18 -04:00
Zoltan Varga de7ccb75d5 [runtime] Make multiple -O= flags cumultative instead of negating the effects of the previous ones. 2015-06-19 16:22:26 -04:00
Zoltan Varga bcd9596e17 Merge pull request #1886 from BrzVlad/fix-arm-thread-state
[ios] Fix setting of thread state due to invalid argument
2015-06-19 14:15:04 -04:00
Marek Safar fde3b00fc8 [mcs] Add support for interpolated quoted strings 2015-06-19 18:37:58 +02:00
João Matos 41a41254c1 [aot] Build the LLVM temporary file paths with the temporary base name.
Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=28600.
2015-06-19 16:02:52 +01:00
João Matos 52fdc14c46 [aot] Build the temporary base name with the temporary path when it's present. 2015-06-19 16:02:51 +01:00
João Matos b922409cf4 [aot] Initialize the temporary path to an empty string. 2015-06-19 16:02:51 +01:00
Marek Safar b6e4411df1 [ilasm] Add project file 2015-06-19 11:47:39 +02:00
Marek Safar fe0c96790b [ilasm] Add support for multiple custom type modifiers attached to single type 2015-06-19 11:46:55 +02:00
Marek Safar 106e71e2c8 [mcs] Implements virtual read-only auto-property assignment via derived private field 2015-06-19 11:46:55 +02:00
Marek Safar acd63c6a96 [ilasm] Remove unused files 2015-06-19 11:46:55 +02:00
debugerr f2147a1529 Null reference check before calling delegate
We see a crash in LinuxNetworkChange.OnAvailabilityChanged when dereferencing the AvailabilityChanged delegate (NullReferenceException). There is a race here: the OnAvailabilityChanged is fired by deferring to the ThreadPool, which allows an unregister to come in between, removing the potential registration before we get called back.
2015-06-19 10:09:00 +02:00
Chris Hamons b044a27fe0 Create xammac_net_4_5 profile for XM 4.5 Unified to remove references to unshippable assmblies 2015-06-18 13:31:04 -05:00
Vlad Brezae d86a4f258f [ios] Fix setting of thread state due to invalid argument
This prevented aborts from working.
2015-06-18 11:27:52 -07:00
Marcos Henrich 521291560d [System.Core] Test MemoryMappedFile.CreateFromFile
Test MemoryMappedFile.CreateFromFile with null napName parameter.

Covers #30741 #30825.
2015-06-18 18:41:42 +01:00
Marek Safar 2c9ee7f2d5 [system] Implements IPv4Mask property on mac. Fixes #30880 2015-06-18 17:25:11 +02:00
João Matos 7b6e1158be Merge pull request #1884 from mono/fix-vb
[xbuild] Fix Microsoft.VisualBasic.targets to contain correct VbcToolExe
2015-06-18 14:04:52 +01:00
Alexander Köplinger 14633bda63 [xbuild] Fix Microsoft.VisualBasic.targets to contain correct VbcToolExe
Compiling VB projects was broken since a few releases but apparently went unnoticed.
The VbcToolExe path needs to be set to "vbnc.exe" because vbnc2 and vbnc shell scripts
don't work in this case and we only support building against the reference assemblies anyway
now for different targets.
2015-06-18 14:46:34 +02:00
Zoltan Varga e0872b2fae [jit] Disable passing the rgctx/vtable in some cases, its doesn't seem to be needed. The newobj code doesn't use the same logic, so the same method might end up being called with/without an rgctx, which is an error on LLVM since methods which receive an rgctx have a different signature. 2015-06-17 16:21:26 -04:00
Zoltan Varga d90d27f642 [runtime] Mark some linq tests as GSHAREDVT so they are skipped when running the fullaot tests on amd64. 2015-06-17 16:21:26 -04:00
Zoltan Varga 4e9e6ce33b [amd64] Fix some partial sharing problems. 2015-06-17 16:21:26 -04:00
Marek Safar cd43e81af1 [mcs] Add better logging for ikvm crashes during HasObject loading 2015-06-17 17:52:51 +02:00
Marek Safar cbc862c79c [mcs] Handle null propagation operator inside nested member access expression. Fixes #31092 2015-06-17 17:37:00 +02:00
Marek Safar 05b6b4f970 Merge pull request #1881 from mono/Therzok-patch-1
[mcs] Fix order of parameters for LineNumberEntry
2015-06-17 07:41:43 +02:00
Marius Ungureanu 2a2297b85e [mcs] Fix order of parameters for LineNumberEntry
Discovered by coverity in NRefactory.
2015-06-17 07:56:08 +03:00
Zoltan Varga 55d8296440 Fix a warning. 2015-06-16 22:45:38 -04:00
Zoltan Varga d96aceab70 [runtime] More full-aot+amd64 fixes. 2015-06-16 20:52:15 -04:00
Zoltan Varga c03088c64c [runtime] Fix full aot on amd64. 2015-06-16 20:25:16 -04:00
Alexander Kyte c4e0097c27 [runtime] Fixed use-after-free in context freeing
We had a use-after-free bug in context freeing that creating and freeing AppDomains in parallel exposed.

We called g_hash_table_remove in a callback to g_hash_table_foreach,
which
resulted in freeing the Slot struct that the g_hash_table_foreach was
holding a local reference to.

When it tried to get the chained 'next' element in the table, if
other threads caused enough memory pressure to reuse that memory
between freeing and getting the 'next' pointer, then we try to
dereference a garbage value and get a SIGSEGV.
2015-06-16 20:07:08 -04:00
João Matos 823aa3dd4e [WindowsBase] Fixed potential string overflow bug when getting Zip entry file length. 2015-06-16 19:28:25 +01:00
João Matos 0d5437fc32 [WindowsBase] Fixed string buffer overflow when handling Zip entries.
Fixes NuGet package handling, see https://bugzilla.xamarin.com/show_bug.cgi?id=26205.
2015-06-16 19:28:21 +01:00
Marcos Henrich ba1a809980 Merge pull request #1804 from esdrubal/processmodule
Adds managed assemblies to Process.Modules.
2015-06-16 18:15:29 +01:00
Marek Safar b5a732717e [mcs] Fix accessibility modifiers on accessors logic 2015-06-16 19:09:02 +02:00
Marcos Henrich 96f08f5e14 Updated csproj files. 2015-06-16 17:26:58 +01:00
Marek Safar 659c1cdf33 [mcs] Constraints checker needs to accomodate inflated base type contrained not converted to interfaces. Fixes #30973 2015-06-16 17:56:40 +02:00
Marek Safar f6665e553b [mono] Update swedish months and days to be always lower cased for some reason cldr have them wrong. Fixes #30851 2015-06-16 17:56:40 +02:00
Rolf Bjarne Kvinge fe76409a90 Define HAVE_SYSTEM for Windows. 2015-06-16 17:52:04 +02:00
João Matos 4ce7fd5b48 Merge pull request #1878 from rolfbjarne/have-system
Add a conditional for the system function.
2015-06-16 15:54:07 +01:00
Rolf Bjarne Kvinge 8588a5de19 Add a conditional for the system function.
It's not available in the iOS WatchOS simulator.
2015-06-16 16:51:58 +02:00
Marcos Henrich 92cffc729c [runtime] Fixed get_process_module module name.
Module name was equal to RefEmit_YouForgotToDefineAModule for some
modules in OS other than OSX.
2015-06-16 14:43:05 +01:00
Alex Rønne Petersen 3445ac5f22 Merge pull request #1877 from BrzVlad/fix-finalizer-exception
Fix finalizer exception
2015-06-16 11:23:14 +02:00
Alex Rønne Petersen f2531ff08c Merge pull request #1875 from directhex/use-variable-port-number-for-servicemodel-tests
Use random port numbers for ServiceModel tests.
2015-06-16 11:21:49 +02:00
Marcos Henrich 7f3b76a32f Merge pull request #1876 from esdrubal/mmf-segfault
Fixes MemoryMappedFile related segfault with dnvm
2015-06-16 10:14:14 +01:00
Zoltan Varga d0bc7a136e [jit] Add jit icalls used by the inline rgctx fetch code. 2015-06-15 22:50:32 -04:00
Zoltan Varga dd75eb942f [jit] Remove the 'caller' argument from the generic sharing code, its no longer needed, since we no longer compute its generic sharing context. 2015-06-15 22:19:18 -04:00
Zoltan Varga af178ab16b [gsharedvt] Avoid computing the generic sharing context of callers, its not longer needed. 2015-06-15 22:11:21 -04:00
Zoltan Varga 4468c687cd [jit] Get rid of MonoGenericSharingContext->var_is_vt/mvar_is_vt, they are not needed anymore since the same information is now encoded in the gshared_constraint field of MonoGenericParam. 2015-06-15 21:57:02 -04:00
Zoltan Varga 868f51ee2a [runtime] Disable some fullaot tests on x86, since it has no dyncall code. 2015-06-15 21:40:55 -04:00
Zoltan Varga fcad145fc6 [jit] Use emit_get_gsharedvt_info_klass () in one place. 2015-06-15 19:21:48 -04:00
Zoltan Varga ffde958573 [jit] Add an inline version of the rgctx fetch trampolines, not yet used. 2015-06-15 18:59:41 -04:00
Zoltan Varga a8c943dec8 [jit] Use cfg->cbb to refer to the current bblock, avoid using the 'bblock' variable defined in method_to_ir () for this purpose, since it needs to be updated after every call which changes cfg->cbb. 2015-06-15 18:33:39 -04:00
Vlad Brezae 14b6dcd51c [runtime] Fix mono_sem_timedwait for the case where we get interrupted.
On mach, semaphore_timedwait returns KERN_ABORTED instead of setting the errno variable. The timeout argument is relative so it needs to be updated. We don't need to update the timeout argument on other platforms since it has an absolute value.
2015-06-15 15:10:23 -07:00
Vlad Brezae e9e5bd152b [runtime] Fix failure to wait on semaphore due to invalid argument 2015-06-15 15:09:44 -07:00
Marcos Henrich ae633585df [System.Core] Updated MemoryMappedFileTest
Commented out PointerOffset asserts because its value is always 0.
Unlike .NET mono implementation creates MemoryMappedViews with no
PointerOffset.
2015-06-15 22:26:57 +01:00
Zoltan Varga f29e0b01ef [runtime] Fix another memory leak in the dwarf writer. 2015-06-15 16:06:04 -04:00
Zoltan Varga c973633ef2 [runtime] Fix a memory leak in the dwarf writer. 2015-06-15 16:04:04 -04:00
Zoltan Varga 181401eb9c [jit] Avoid a crash in the dwarf dumper if debug info is not found. 2015-06-15 15:30:07 -04:00
Vlad Brezae d34b0955cd [test] Fix finalizer-exception test
Me might be very unlucky and still have the object pinned in random stack memory. Allocate multiple objects so we are sure that at least one of them is finalized.
2015-06-15 12:16:49 -07:00
Marcos Henrich 2b87ee1f69 [runtime] mono_mmap_open_handle with null arg.
Fixes segmentation fault when mono_mmap_open_handle is called with a null mapName argument.
MemoryMappedFiles.CreateFromFile calls mono_mmap_open_handle, .NET implementation accepts a null mapName and CoreFX uses CreateFromFile with null mapName.

Fixes #30825 and #30741.
2015-06-15 17:33:16 +01:00
Marcos Henrich 4ccc225ba6 [System.Core] Using more reference source files.
Changed MemoryMappedFile related code to use reference source
MemoryMappedViewAccessor and MemoryMappedViewStream.

This change was motivated by segmentations faults while dnmv code was
calling a CoreFX class that uses reflection to call MemoryMappedFile
code.

Now that we are using more code from reference sources there should be
no problem.

Fixes #30741 and #30825.
2015-06-15 16:09:31 +01:00
Zoltan Varga 444d8ada3f [runtime] Fix the arm64 build. 2015-06-15 09:50:05 -04:00
Jo Shields 775ce53a74 Use random port numbers for ServiceModel tests.
This prevents race conditions when running multiple test suites at once on the same computer, as happens on our ARM builders.
2015-06-15 12:39:07 +01:00
Marcin Cieslak 706dc27665 Enums are classes that can be assigned to value types
Fixes:
	https://bugzilla.xamarin.com/show_bug.cgi?id=29679
2015-06-14 23:58:09 +00:00
Marek Habersack 69c0c34721 Merge pull request #1873 from saper/PR_SET_TRACER
Use PR_SET_PTRACER only if defined
2015-06-14 00:41:18 +02:00
Marcin Cieslak 706a6971ac Use PR_SET_PTRACER only if defined
This feature has been introduced in Linux 3.4,
older kernels do have prctl(2) but know
PR_SET_PTRACER not.
2015-06-13 16:37:10 +00:00
João Matos 4713c7e824 Merge pull request #1872 from saper/channeldisp_fix
[WIP] Fix tests breaking due to network ports
2015-06-13 12:31:38 +01:00
Marcin Cieslak c698cd9d23 [tests] Use LocalEphemeralEndPoint in HttpWebRequestTest 2015-06-13 11:02:42 +00:00
Marcin Cieslak 8fc17b0ac7 [tests] fix System.UriFormatException
Follow-up to 05a1144d4d
2015-06-13 09:55:25 +00:00
Marek Habersack 8c65f4b11e [runtime] Fix a typo, should be HAVE_PRCTL 2015-06-13 08:31:13 +02:00
Zoltan Varga cc6ba42012 [runtime] Make sure the interfaces returned by Type:GetInterfaces () are in the consistent order. Fixes #31020. 2015-06-13 00:20:20 -04:00
Zoltan Varga 215519f2f3 Fix a warning. 2015-06-12 23:49:36 -04:00
Zoltan Varga b50fdc594f [runtime] Fix support for MONO_UNWIND_LOOKUP_ACTUAL_METHOD in mono_stack_walk_no_il (). 2015-06-12 23:49:35 -04:00
Zoltan Varga 44f1e14309 Merge pull request #1871 from saper/EADDRINUSE
[tests] Avoid "Address already in use"
2015-06-12 19:12:11 -04:00
Marcin Cieslak 05a1144d4d [tests] Avoid "Address already in use"
Few tests using networking seem to fail due to
"Address already in use"
error that may be caused by opening listening
port too fast - because of some tests running
in parallel or because 2MSL TIME_WAIT period.
2015-06-12 22:33:58 +00:00
Marek Habersack 8564368790 [Linux] Set permission for gdb to attach
Most modern Linux distributions limit the ptrace scope to allow
attaching only to the direct child processes for security reasons. The
user on such machine has to modify sysctl in order to allow non-root
processes to attach to arbitrary processes, which opens up a potential
security issue. The alternative is what's implemented here - when we
crash and ask gdb to dump the stack we can bless the gdb process and allow
it to attach to our process using prctl(2)
2015-06-12 23:51:12 +02:00
Zoltan Varga 729e4c1dc3 [arm] Increase the number of stack args to 10 in the dyn call code. Fixes #31060. 2015-06-12 13:31:52 -04:00
Marcos Henrich dfa1ecaff7 [System] Made ProcessTest.Modules more verbose.
When Process.Modules fails it will now print the list of assemblies it
looked into.
2015-06-12 12:31:45 +01:00
Marcin Cieslak eade1efc77 [eglib] Prefer <langinfo.h> to <localcharset.h>
For platforms that have external libiconv
located in some non-default directory (e.g. /usr/local/lib)
it is very difficult to force libtool to pick
up a static libiconv.a when needed.

We currently build eglib as a static library,
and then we continue to link eglib (with -leglib)
to other binaries and libraries.

As -leglib is a static library, we should either

1) incorporate the contents of libiconv.a into
   libeglib.a (therefore we would _require_
   libiconv.a to be installed).

2) prepare stub libiconv.la file and provide it
   to all libeglib.a consumers as a dependency.

We should not just detect HAVE_LOCALCHARSET_H,
add it to CPPFLAGS and then continue without
linking libiconv properly as a static library;
This manifests with the error message during
linking:

   gunicode.c:223: undefined reference to `locale_charset'

This workaround makes us look for <langinfo.h>
first, which - if available - will be there in
the standard C library. This fixes the gunicode.c
problem for FreeBSD and similar platforms, that
may install GNU iconv as an add-on library.
2015-06-11 22:49:08 +00:00
Alex Rønne Petersen 5129dd43cf Merge pull request #1868 from BillSeurer/ppc-floats
[ppc] Basic powerpc64 little endian enablement
2015-06-11 23:24:26 +02:00
Rodrigo Kumpera 78d1a1dfb9 [eglib] Ensures that home and user name always have a non-null value. 2015-06-11 16:25:55 -04:00
João Matos f4123496fa [System.IO.Compression] Implement support for custom entry name encoding when writing Zip files.
When you write to archive files and entryNameEncoding is set to a value other than null, the specified entryNameEncoding is used to encode the entry names into bytes. The language encoding flag (in the general-purpose bit flag of the local file header) is set only when the specified encoding is a UTF-8 encoding.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=30972.
2015-06-11 18:19:24 +01:00
João Matos 12e2b1d116 [SharpCompress] Add support for custom entry text encoding in Zip writer. 2015-06-11 18:18:51 +01:00
Miguel de Icaza 4da1e26c09 [Lucene] Replace the large 66M dependency to a 4M dependency with the subset that we use 2015-06-11 09:47:54 -07:00
Bill Seurer 4b77d7620f [ppc] Some additional basic ppc64 enablement 2015-06-11 09:26:07 -05:00
Bill Seurer 9be2537b0e [ppc] Fix chkfinite for little endian 2015-06-11 09:25:54 -05:00
Bill Seurer 55bf7bef97 [ppc] Fix floating point issue for little endian. 2015-06-11 09:25:33 -05:00
João Matos 9c3cdff186 Merge pull request #1867 from saper/ucontext_x86
Missing <ucontext.h> for x86
2015-06-11 13:57:38 +01:00
Marcin Cieslak 799643a6f7 Missing <ucontext.h> for x86
Obtained from: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=198404
2015-06-11 12:53:21 +00:00
João Matos ce50124547 Merge pull request #1866 from saper/libc7
Use libc.so.7 for FreeBSD
2015-06-11 13:45:07 +01:00
João Matos 414e7433ac Merge pull request #1865 from saper/shellredir
Use Bourne shell redirect 2>&1
2015-06-11 13:29:48 +01:00
Romain Tartière 4ad59b97e0 Use libc.so.7 for FreeBSD
/usr/lib/libc.so is now an ld script
and to a symbolic link to the
libc.so.7 library.

Obtained from: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=179899
2015-06-11 12:27:57 +00:00
Romain Tartière dd608574db Use Bourne shell redirect 2>&1
Do not assume our shell is C-shell
compatible.

Obtained from: https://svnweb.freebsd.org/ports?view=revision&revision=324730
2015-06-11 12:26:31 +00:00
João Matos e453a6e52b Merge pull request #1864 from saper/procbyid
FreeBSD: sysctl() to get process information
2015-06-11 13:20:36 +01:00
Marcin Cieslak 461fa2c261 FreeBSD: sysctl() to get process information
Use normal sysctl(3) interface (just like
Mac OS X), the OpenBSD way does not seem to work.
2015-06-11 12:11:43 +00:00
João Matos ac1920466e Merge pull request #1863 from saper/sysctlfreebsd
Use sysctl and <link.h> interface for FreeBSD
2015-06-11 12:37:48 +01:00
Marek Safar b001eccaa7 [system] Clear content length when redirecting to get request. Fixes #30604 2015-06-11 11:30:00 +02:00
Marcin Cieslak 54f1fd8a98 Use sysctl and <link.h> interface for FreeBSD 2015-06-11 08:51:04 +00:00
Zoltan Varga 2eb59a67dd [aot] Remove some dead code. 2015-06-10 21:13:53 -04:00
Zoltan Varga 955ed4f62d [aot] Refactor the initialization of aot methods into a separate function. 2015-06-10 21:12:04 -04:00
Zoltan Varga 8b77bd30ba [aot] Remove unused MONO_OPT_SHARED support. 2015-06-10 20:44:37 -04:00
Zoltan Varga 74d6d95af1 [runtime] Work around an ios9 problem where dlopen() cant' find system libraries specified without paths. 2015-06-10 16:30:07 -04:00
Marek Safar ca2f879ce1 [system.net.http] Add special handling for authentication with content (requires content resend) and disabled buffering. Fixes #30869
This is not supported by public HttpWebRequest but HttpClient is running in this mode.
2015-06-10 21:23:11 +02:00
Zoltan Varga 6c7a949cb2 [arm] Fix crashes on ios9 by using 16kb trampoline pages. 2015-06-10 11:23:09 -04:00
Marek Safar 9a151e405b [system.xaml] Add ValueSerializerAttribute type forwarder 2015-06-09 21:51:35 +02:00
Zoltan Varga 5b5f0ab6ab [runtime] Print out some information before asserting when a loader error is not handled. 2015-06-09 15:47:48 -04:00
Zoltan Varga ff847d8b6d [jit] Avoid using class init trampolines in AOT mode, the overhead of plt entries is comparable to the overhead of the inline implementation. 2015-06-09 14:11:22 -04:00
Marcos Henrich 5edec4a9b8 [runtime] MonoClass are now cached. 2015-06-09 16:45:20 +01:00
Marek Habersack 784e8ad29e Merge pull request #1812 from masterofjellyfish/mvc5-missingmethods
[System.Web] Added missing methods for default VS2013 MVC template
2015-06-09 15:58:23 +02:00
Matthias Bogad 58e0608c10 [System.Web] ASP.Net MVC5 missing methods fixed
I have added System.HttpApplication.RegisterModule(), the missing two properties of the System.Web.Routing.RouteCollection as well as the corresponding property in the HttpRuntimeSection to completely turn this off. Microsofts MIT-Licensed counterparts of the official System.Web assembly from github [0] were used as a reference. It is kind-of bolted on, but should be good enough until the whole open-sourced System.Web is incorporated. It should at least get the default MVC5 Template from Visual Studio 2013 up and running, once the async pipeline for the owin stuff is fixed.

[0]: http://github.com/Microsoft/referencesource/

Additionally, the MissingMethodException "get_InClientBuildManager" in System.Web.Hosting.HostingEnvironment was fixed.
In this commit, the following bugs were fixed:
https://bugzilla.xamarin.com/show_bug.cgi?id=21810
https://bugzilla.xamarin.com/show_bug.cgi?id=16475
2015-06-09 14:06:52 +02:00
Zoltan Varga 8b466eca52 [jit] Implement full-aot support for virtual delegate invokes on x86. 2015-06-08 15:25:34 -04:00
Zoltan Varga 7f949fbb95 [aot] Avoid aot-ing partially sharable icalls. 2015-06-08 13:41:02 -04:00
Zoltan Varga af05feb88e [aot] Fix full-aot support for Comparer instances instantiated with enums. 2015-06-08 13:31:38 -04:00
Zoltan Varga bd4a8a07e6 [jit] Implement support for UnsafeMov in gshared code. 2015-06-08 13:22:20 -04:00
Zoltan Varga a385bf0a83 [aot] Add partial shared instances called by partial shared instances. 2015-06-08 13:17:59 -04:00
Zoltan Varga 16f403bca9 [jit] Represent fully-shared method instances the same way as partially shared instances instead of representing them using the generic method declaration. 2015-06-08 13:16:17 -04:00
Zoltan Varga 16c1e4371b [aot] Use normal methods instead of their remoting-invoke-with-check wrappers in full-aot mode. 2015-06-08 13:16:17 -04:00
Zoltan Varga c50809ebd5 [jit] Implement full-aot support for virtual delegate invokes on amd64. 2015-06-08 13:16:17 -04:00
Marek Safar de19957d20 [system.net.http] Apply custom to string formating to parsed values. Fixes #30897 2015-06-08 17:40:31 +02:00
Neale Ferguson bb8d8e475e Add support for -fPIE on s390x 2015-06-08 11:26:51 -04:00
João Matos 273dfb2f09 [runtime] Prefer eglib's g_snprintf as snprintf does not work under all platforms.
Fixes the MSVC build.
2015-06-08 16:05:10 +01:00
Marcos Henrich 33a3716af6 [System] Test ProcessModule managed assemblies. 2015-06-08 14:04:10 +01:00
Marcos Henrich b3069efc32 [runtime] Managed ProcessModule now has versions. 2015-06-08 14:02:08 +01:00
Marcos Henrich 46dc6758c6 [runtime] Process.Modules with managed assemblies.
System.Diagnostics.Process.Modules now also returns managed assemblies.
With this change it is now possible to use Process.Modules to retrieve
the place in memory of any loaded assembly.

ProcessModules relative to a managed assembly have a FileName that
starts with "[In Memory]".
2015-06-08 14:02:08 +01:00
Marek Safar e70972ac0f [windowsbase] Add ValueSerializerAttribute type forwarder. Fixes #30448 2015-06-08 14:23:04 +02:00
Rodrigo Kumpera aac7aed45e Merge pull request #1861 from saper/home-override
Override Environment.SpecialFolder.Personal with $HOME
2015-06-08 06:57:43 -05:00
Marek Safar 3c47caca34 [system] Don't dispose exposed redirected streams. Fixes #30868 2015-06-08 13:29:19 +02:00
Alex Rønne Petersen afd7d742ab Merge pull request #1859 from saper/unit-tests-static
[runtime] Use libtool convenience library for unit tests. Fixes #21520.
2015-06-08 02:42:13 +02:00
Marcin Cieslak cf4e7339e3 [corlib] Assume UTC if no $TZ set. Fixes #30360
Don't throw System.TimeZoneNotFoundException
if no $TZ is set and there is no /etc/localtime
or similar file.
2015-06-07 22:19:56 +00:00
Jan Beich f8d2aeea4a Override Environment.SpecialFolder.Personal with $HOME
Any port that writes to Environment.SpecialFolder.Personal during build
or when running tests may end up with files outside of stage area that
aren't cleaned up by the ports framework. The issue lies with Mono
looking in /etc/passwd first and only if no entry found there in HOME.

Patch based on discussion in

https://github.com/mono/mono/pull/371

Obtained from: https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193426
2015-06-07 22:07:52 +00:00
Marcin Cieslak e0289946b8 [runtime] Use libtool convenience library for unit tests. Fixes #21520.
In order to resolve interdependencies between
static libraries we should create a temporary
throw-away ("convenience") library via libtool.

Should unbreak unit tests on Linux
2015-06-07 21:35:43 +00:00
Zoltan Varga a270f04d9c [runtime] Fix mono_method_get_name () so it prints out type variables using their name when used inside the runtime. 2015-06-06 11:44:23 -04:00
Zoltan Varga 082295bf86 [aot] Add a corresponding instance of EnumEqualityComparer for EqualityComparer instances instantiated with enums. 2015-06-06 11:09:56 -04:00
Zoltan Varga 8d00f23370 Disable a test which can allocate and commit 4gb of memory on 64 bit platforms. 2015-06-05 18:14:43 -04:00
Rodrigo Kumpera 90bb2cdd6e [coop] When inserting safepoints at EH handlers, make sure they don't end up between start_handler and get_ex_obj
The problem is that those two ops are required to be one after the other as there's an implicit register dependency between them.

OP_SAFEPOINT would clobber that register (RAX on amd64) and cause all sorts of issues.
2015-06-05 15:48:24 -04:00
Alex Rønne Petersen 02b7567628 Merge pull request #1856 from alexrp/profiler-improvements
Profiler improvements
2015-06-05 21:22:52 +02:00
Marek Safar 74b5b65701 [mcs] Silently ignore invalid assembly name in InternalsVisibleTo. Fixes #30679 2015-06-05 16:55:57 +02:00
Ankit Jain f03a1b538b Merge pull request #1857 from slluis/fix-assembly-resolver
[MSBuild] Fix assembly resolution issue
2015-06-05 19:41:54 +05:30
Lluis Sanchez dd8aadfd58 [MSBuild] Fix minor assembly resolution issue
When getting the assembly name of a file, don't cache it if the
file has just been deleted.
2015-06-05 14:48:49 +02:00
Lluis Sanchez 31b628c9e7 [MSBuild] Fix assembly resolution issue
The ResolveAssemblyReference task class keeps a reference to an
instance of AssemblyResolver, and AssemblyResolver keeps a cache
of assembly names, indexed by file name. The problem is that
the cache doesn't take into account that files can change between
builds.

For example, if a referenced assembly doesn't exist, the cache
will store that the file doesn't have an assembly name. If after
the build the file is created and a new build operation is started,
the cache will still return that the file doesn't have a name.

This is not a problem when running xbuild from the command line,
since every build starts a new process, but MonoDevelop uses
the MSBuild API to load and build projects, and doesn't start
a new process every time, so the cache is never cleared.

The solution is to keep the last write timestamp in the cache,
so that it can check if the file changed before returning the
cached name. It also needs to do a better handling of non existant
files.
2015-06-05 12:00:34 +02:00
Zoltan Varga 5ccfced37c [sdb] Avoid marking seq points as nonempty-stack if they have a sym seq point. Fix the linking of seq points when an endfinally instruction is in a separate bblock. Fixes #30617. 2015-06-04 16:45:46 -04:00
Rodrigo Kumpera 6de51884fd Merge pull request #1849 from esdrubal/rfix
[corlib] MonoAssembly.LoadWithPartialNameInternal.
2015-06-04 15:16:26 -05:00
Alex Rønne Petersen 406d53e086 [profiler] Add myself as author. 2015-06-04 21:29:53 +02:00
Alex Rønne Petersen ef934f394b [profiler] Start jotting down some format oddities we should eventually fix. 2015-06-04 21:24:57 +02:00
Alex Rønne Petersen 1a22e028e0 [profiler] Fix missing TYPE_JIT events for alloc/exception/monitor backtraces. 2015-06-04 21:24:57 +02:00
Alex Rønne Petersen 6174e9a415 [profiler] Disable the ELF code for now.
This causes strange crashes on some Linux systems. We don't particularly need
the additional information to get useful backtraces (we can just fall back to
`dladdr`) so disable it for now.
2015-06-04 21:24:57 +02:00
Alex Rønne Petersen ab324cadc5 [profiler] Process coverage info regardless of call depth restriction.
Only enter/leave events should be subject to this.
2015-06-04 21:24:57 +02:00
Alex Rønne Petersen 27d2dd2a1a [profiler] Remove outdated compilation instructions. 2015-06-04 21:24:57 +02:00
Zoltan Varga 4f62f3fc57 [llvm] Decrease the basic block size cutoff to 3000 instructions, 5000 still leads to large slowdowns in llc on armv7 (TypeTest.GetProperties_Flags ()). 2015-06-04 15:10:50 -04:00
Zoltan Varga 50afff2db3 [arm] Implement support for nullable arguments in the dyncall code. Fixes #29491. 2015-06-04 12:46:22 -04:00
Zoltan Varga 2062525f96 [aot] Enable the direct emission of llvm object files in asmonly mode if the llvm output file ends with .o. 2015-06-03 22:45:53 -04:00
Zoltan Varga 550a8017ec [jit] Emulate OP_RREM if OP_FREM is emulated. Fixes #30698. 2015-06-03 14:40:24 -04:00
Zoltan Varga 158783843e [sdb] Fix interface/virtual calls to valuetype methods. 2015-06-03 13:52:52 -04:00
João Matos c04f20ba3b Merge pull request #1854 from svedm/master
Fix typo
2015-06-03 18:41:26 +01:00
Svetoslav dcaee6b560 Fix typo 2015-06-03 22:20:18 +05:00
Marek Safar 4692762549 Merge pull request #1851 from esdrubal/mmf
MemoryMappedFile improvements
2015-06-03 18:07:39 +02:00
Marcos Henrich a495f37aeb [corlib] Referencesource UnmanagedMemoryAccessor.
Corlib now uses referencesource System.IO.UnmanagedMemoryAccessor.
2015-06-03 15:41:03 +01:00
Marcos Henrich d527ed4980 [System.Core] Implemented PointerOffset
Implemented MemoryMappedViewAccessor.PointerOffset and
MemoryMappedViewStream.PointerOffset.
2015-06-03 15:41:02 +01:00
Marcos Henrich 978ebdcd47 [System.Core] Test MemoryMappedFile views.
MemoryMappedViewAccessor and MemoryMappedViewStream are now tested with
offsets.
2015-06-03 15:41:02 +01:00
Zoltan Varga 210df1d497 [bcl] Fix a sys.drawing test so it doesn't fail on misconfigured systems. 2015-06-03 08:49:45 -04:00
Marek Safar 7127e2e0a5 [mcs] Recursivelly check for left-hand side of an assignment of a null propagating operator. Fixes #30695 2015-06-03 12:04:51 +02:00
Jo Shields 3f7098683d Fix "make dist" for mono/utils/mono-complex.h 2015-06-03 08:01:24 +01:00
Alexis Christoforides 9820f6e148 [System.IO.KeventWatcher] Fix handling some cases where an item is moved out of the watched path.
If a file or directory are moved out of the watcher's path they are removed from the index, but they might still have events in the kevent() changelist. This would sometimes cause an exception.
2015-06-02 19:10:48 -04:00
Rodrigo Kumpera fb4366374d [jit] Fix the coop amd64 backend. 2015-06-02 14:47:29 -05:00
Marek Safar 3d6135a624 Merge pull request #1847 from alexanderkyte/left_shift_dynamic
[runtime] Emit the necessary left shift anding in the LambdaCompiler
2015-06-02 21:34:53 +02:00
Alexander Kyte c5d5da257e [runtime] Emit the necessary left shift anding in the LambdaCompiler
We were observing dtest-006.exe test failing on armhf. This test
checks that a right shift with a negative shift amount and a
dynamic base is shifted by the right amount.

We were failing it because we were excluding the step that we
do in regular code generation, which is to do a binary and of the shift
amount so it behaves like we are shifting by the original shift
amount modulo 32. The C# spec defines left shift like so.

This commit adds that to the LambdaCompiler.
2015-06-02 19:31:00 +00:00
Marek Safar fe797b7f54 [mcs] Apply explicit property param target to correct parameter index. Fixes #30587 2015-06-02 20:37:32 +02:00
Marek Safar 2fa2380595 [mcs] Add special HostProtection handling to deletes 2015-06-02 20:37:31 +02:00
Marcos Henrich 360f2deff8 [corlib] MonoAssembly.LoadWithPartialNameInternal.
Implemented MonoAssembly.LoadWithPartialNameInternal.
Implementation is not 100% correct without handling stackMark properly.
Improving this would require the generous amount of work of adding
StackCrawlMark support to the runtime.

Fixes #27103.
2015-06-02 14:52:02 +01:00
Alex Rønne Petersen 177f563b6d Merge pull request #1846 from BillSeurer/master
Add tailcall opcode for powerpc64le
2015-06-02 13:59:05 +02:00
João Matos b7af87321a Merge pull request #1848 from tritao/complex_math
Cross-platform complex math / MS Threadpool portability
2015-06-02 12:53:12 +01:00
Rolf Bjarne Kvinge 066d3eb6ba [corlib] Fix test after 5cee52916. 2015-06-02 13:00:38 +02:00
Joao Matos cae5827535 [ms-threadpool] Replaced complex math with portable Mono APIs. 2015-06-02 10:48:33 +01:00
Joao Matos 099ab41745 [runtime] Implemented cross-platform complex math code. 2015-06-02 10:47:53 +01:00
Marek Safar cb9a09b3f0 Bump ikvm & ikdasm 2015-06-02 08:51:37 +02:00
Alexis Christoforides a1828a2aa9 [System.IO.KeventWatcher] Disable the watcher when the root directory is deleted. Fixes #30043
This matches MS.NET behavior.
2015-06-01 23:07:07 -04:00
BrzVlad 24d62be2f7 Merge pull request #1841 from BrzVlad/fix-managed-alloc
Fix managed allocator
2015-06-01 16:41:02 -07:00
Zoltan Varga 21249b6e3b [amd64] Fully initialize the the MonoContext used by the generic trampoline code. 2015-06-01 18:42:32 -04:00
Zoltan Varga 9a8386091e [corlib] Make corlib use the v4 runtime version in mobile profiles. 2015-06-01 17:32:18 -04:00
Zoltan Varga 570c5be49d [jit] Fix the hashing/equals check for MONO_PATCH_INFO_JIT_ICALL_ADDR. 2015-06-01 16:42:35 -04:00
Vlad Brezae c24d753c03 [sgen] The normal managed allocator receives only one argument
Changed in a83f965db0
2015-06-01 12:34:32 -07:00
Zoltan Varga 272bdcaff3 Remove more CAS code. 2015-06-01 15:24:27 -04:00
Zoltan Varga 88b9fd6cc8 Remove more CAS code. 2015-06-01 15:24:27 -04:00
Sebastien Pouliot 6c51f352bd [corlib] Xamarin.Mac to continue default to the OS default codepage
XM 2.0 was the first version to ship the mobile (w/unified) and it used
the OS default codepage.

The previous, system mono, profile was already using the OS default
codepage so it make sense for XM to be consistent across profiles (
including the 4.5 subset)
2015-06-01 15:20:43 -04:00
Rodrigo Kumpera 8b75648151 [BCL] Partial revert of b83af940ff to use the right reference sources. 2015-06-01 14:39:59 -04:00
Rodrigo Kumpera 5af1f7d2f7 [BCL] Fix the mobile_static profile. 2015-06-01 14:39:58 -04:00
Zoltan Varga fa20f3caf9 [aot] Fix thumb support after the separate llvm changes. Fixes #30472. 2015-06-01 14:27:03 -04:00
Zoltan Varga b83af940ff [runtime] Fix the windows build. 2015-06-01 14:21:27 -04:00
Bill Seurer 63bcae6fca Add tailcall opcode for powerpc64le 2015-06-01 13:20:01 -05:00
Zoltan Varga 3beff78094 [runtime] Update object offsets. 2015-06-01 12:01:05 -04:00
Zoltan Varga 13e562a27f Fix make dist. 2015-06-01 11:40:24 -04:00
Marek Safar f37b5da5a7 [corlib] Update failing test 2015-06-01 16:58:20 +02:00
Zoltan Varga 7d400865a3 [amd64] Add fregs to MonoContext, only used by the trampoline code currently. 2015-06-01 10:34:38 -04:00
Marek Safar 50a1e4ce9d Merge pull request #1845 from esdrubal/httpfix
HttpListenerRequest Uri is now unescaped.
2015-06-01 16:25:11 +02:00
Marek Safar 67cd52b1d7 Bump reference sources 2015-06-01 15:47:42 +02:00
Marek Safar 7050ee1ee7 [System.Runtime.Serialization] Update public api 2015-06-01 15:46:38 +02:00
Marcos Henrich 37ff703afc [System] HttpListenerRequest Uri is now unescaped.
Fixes #29927
2015-06-01 14:43:41 +01:00
Marcos Henrich 2441d532e4 [System] Added HttpListenerRequestUriBuilder
Referencesource HttpListenerRequestUriBuilder can now be used.
2015-06-01 14:43:41 +01:00
Marek Safar 3f6b3e46b4 [ilasm] Add support for undocumented modopt/modreq using primitive types 2015-06-01 14:53:16 +02:00
Marcos Henrich 0361fc34a8 [System] Test HttpRequest Uri unescaping
Covers #29927
2015-06-01 11:33:34 +01:00
smirtw 6b146d49f9 Added sha512 and sha256 and defaults to SHA512
SHA1 is deprecated and microsoft won't accept SHA1 into the certificate store after 2016. Defaulting to SHA512 is a good practice to prevent unaware folks from generating weak ssl certs.
2015-05-31 11:11:43 -07:00
Zoltan Varga 54e8010aad [runtime] Fix the locking around the assembly->tokens table. Fixes #30551. 2015-05-31 12:43:21 -04:00
Zoltan Varga 9854b187a2 [amd64] Make the generic trampolines fill out a MonoContext structure on the stack, and put its address into MonoLMFTramp. 2015-05-30 21:04:28 -04:00
Zoltan Varga 984b0e375e [amd64] Compute frame size precisely for the generic trampoline. 2015-05-30 20:42:19 -04:00
Zoltan Varga 09a0763953 [amd64] Simplify the throw trampolines by constructing and passing a MonoContext instead of a reg array. 2015-05-30 18:48:46 -04:00
Zoltan Varga e8e78456dd Revert "[amd64] Simplify the throw trampolines by constructing and passing a MonoContext instead of a reg array."
This reverts commit c409bc9311.

Revert this as it breaks on linux.
2015-05-30 11:18:33 -04:00
Zoltan Varga 4bd2d86add Revert "[amd64] Add back a dummy argument to the throw trampolines to fix unaligned stack problems."
This reverts commit d262c343d1.

Revert this as it breaks on linux.
2015-05-30 11:18:07 -04:00
Zoltan Varga d262c343d1 [amd64] Add back a dummy argument to the throw trampolines to fix unaligned stack problems. 2015-05-30 10:51:24 -04:00
Marek Safar 460ac99d0a Merge pull request #1816 from esdrubal/getdaylight
[corlib] Fixed TimeZoneInfo.GetDaylightChanges.
2015-05-30 10:11:05 +02:00
Zoltan Varga c409bc9311 [amd64] Simplify the throw trampolines by constructing and passing a MonoContext instead of a reg array. 2015-05-29 21:13:23 -04:00
Zoltan Varga 09f8c0d231 [runtime] Update object offsets. 2015-05-29 21:01:38 -04:00
Zoltan Varga 92c36fdbd2 [amd64] Use a register array in MonoContext instead of named fields, this simplifies a lot of code. 2015-05-29 21:00:11 -04:00
Zoltan Varga 31753770c0 [llvm] Use the generic IL code for generic class inits. 2015-05-29 19:16:04 -04:00
Zoltan Varga 39de60515f [jit] Refactor the calls to class init trampolines into a common function. 2015-05-29 19:07:03 -04:00
Zoltan Varga effbf38142 [amd64] Make generic_class_init as clob:c. 2015-05-29 19:05:03 -04:00
Zoltan Varga 1900ab2a05 [sdb] Fix reading/writing locals when not all of the them have associated debug info. Fixes #30529. 2015-05-29 14:21:27 -04:00
Zoltan Varga a87a5cf71e [jit] Remove generic class init trampolines, all architectures either use OP_GENERIC_CLASS_INIT trampoline or an IL fallback. 2015-05-29 13:49:55 -04:00
Zoltan Varga cebe30dedd [jit] Emit a fallback IL version of generic class initialization. 2015-05-29 13:49:55 -04:00
Miguel de Icaza 7f72a2c795 [Version] I am sick of the mono --version showing '((detached/XX)', fixed it 2015-05-29 12:50:19 -04:00
Rodrigo Kumpera 67e92e2a28 Merge pull request #1817 from alexanderkyte/bug30085
[runtime] Fix resolution of a type with an incorrect assembly name.
2015-05-29 11:21:23 -05:00
Marek Safar 1f6d4a75db [PEAPI] Fixes custom attributes with byte array constant 2015-05-29 17:42:14 +02:00
Zoltan Varga 4183c9cbc5 [corlib] Avoid a nullref in CustomAttributeData.ToString () if its called without calling ConstructorArguments/NamedArguments. 2015-05-29 10:07:41 -04:00
Marcos Henrich 99619b55ce Bump referencesource 2015-05-29 14:58:24 +01:00
Marcos Henrich 15e133b791 Updated .csproj files. 2015-05-29 14:12:22 +01:00
Marek Safar 28e4fa0e0f [ilasm] Extend syntax of custom attribute constructor constants 2015-05-29 12:37:25 +02:00
Marek Safar 296f97e38d [corlib] Fixes commit f0bea6966a 2015-05-29 10:56:13 +02:00
Marek Safar f0bea6966a [corlib] Add timeout to NestedLeakingSynchronizationContext 2015-05-29 08:36:52 +02:00
Vlad Brezae 98d7ad4128 [boehm] Use managed allocator only for objects with known jit compile time size.
The allocator always expects to receive two arguments.
2015-05-28 16:08:37 -07:00
Alexander Kyte bba74d6778 [runtime] Fix resolution of a type with an incorrect assembly name. 2015-05-28 21:56:52 +00:00
Marek Safar 280b98a152 [mcs] Double closing parens don't have priority inside interpolated string. Fixes #30469 2015-05-28 17:23:49 +02:00
Zoltan Varga ccb0b35c76 [arm64] Add generic_class_init to cpu-arm64.md. 2015-05-28 10:52:14 -04:00
Marek Safar c2afedbd4e [corlib] Remove unused defines 2015-05-28 15:45:54 +02:00
Marek Safar c4915d7335 [corlib] Add role based security to desktop only 2015-05-28 15:41:33 +02:00
Marek Safar eeac1570ae [mcs] Await in finally clause with user catch block needs additional try scope. Fixes #30478 2015-05-28 15:41:32 +02:00
Alexander Köplinger 3712cf10bd [build] Fix encoding attribute in crash XML to be utf-8
Some tools choke on "utf8", it should be "utf-8" to be standards compliant.
2015-05-28 15:18:16 +02:00
Marek Safar 221d1acb3a Merge pull request #1838 from esdrubal/assemblyname
[corlib] AssemblyName.CultureName now matches .NET
2015-05-28 11:49:48 +02:00
Marcos Henrich ede3018242 [corlib] AssemblyName.CultureName now matches .NET
AssemblyName.CultureName was returning "neutral" for invariant culture
info whereas .NET returns "".

This was causing problems in Roslyn while comparing assemblies with
an empty culture name against references that would have culture name
set to "neutral".

Fixes #30502.
2015-05-28 10:42:17 +01:00
Marcos Henrich cb88bd4ba9 [corlib] Test AssemblyName.CultureName
Test that AssemblyName.CultureName matches .NET behaviour regarding
AssemblyName with invariant culture info.
2015-05-28 10:41:45 +01:00
Zoltan Varga 88d2b9da2a [runtime] Print wrapper methods in the same format as normal methods in stack traces. Fixes #30507. 2015-05-27 17:20:38 -04:00
Rodrigo Kumpera e87716bc7e [mini] Add assert around managed allocator to avoid passing it a zero size. 2015-05-27 16:42:33 -04:00
Zoltan Varga ebc2cd8c8e Revert "[x86] Enable support for OP_GENERIC_CLASS_INIT."
This reverts commit 2575daaacc.

Revert this as it breaks llvm, which passes the vtable argument on the stack.
2015-05-27 16:28:40 -04:00
Zoltan Varga 1ebeb2a47d [arm] Set more information in cinfo for fp returns, gsharedvt depends on it. 2015-05-27 15:34:39 -04:00
Marek Safar 0d65467d5a [corlib] Improve SynchronizationContext test dependency 2015-05-27 21:00:15 +02:00
Sebastien Pouliot d6b6950a77 [corlib] Let XI and XM define their own default encoding [#29928]
605192528d used UTF8Unmarked for MONOTOUCH
and XAMMAC. However it's initialized differently (than the old UTF8) and
caused unit test regressions in System and System.Net.Http unit tests

This new logic moves the default encoding creation into the products
themselves.
2015-05-27 13:35:38 -04:00
Sebastien Pouliot 6d0979a909 Revert "[corlib] Restore UTF8 as the default encoding for XI and XM [#29928]"
This reverts commit 605192528d.

Using EncodingHelper.UTF8Unmarked cause regressions in System and
System.Net.Http unit tests
2015-05-27 13:34:33 -04:00
João Matos 65f9215c22 [System.IO.Compression] Do not swallow inner exceptions in ZipArchive. 2015-05-27 17:27:34 +01:00
Neale Ferguson 8c36d04c87 Add support for OP_GENERIC_CLASS_INIT
Add support for async callback
2015-05-27 11:27:10 -04:00
Zoltan Varga 3b588df630 [llvm] Fix rethrowing exceptions on x86. 2015-05-27 11:23:34 -04:00
Marek Safar 1cd83569da [corlib] Clone all levels of captures ExceptionDispatchInfos 2015-05-27 17:14:01 +02:00
Zoltan Varga 200f157461 Merge pull request #1836 from ludovic-henry/referencesource-safehandle-tests
[corlib] Fix tests for System.Runtime.InteropServices.SafeHandle
2015-05-27 10:15:12 -04:00
Zoltan Varga 3753066849 Merge pull request #1835 from ludovic-henry/referencesource-threadlocal-tests
[corlib] Add test for ThreadLocal finalization
2015-05-27 09:35:35 -04:00
Ludovic Henry bdf0af5e62 [corlib] Fix tests for System.Runtime.InteropServices.SafeHandle
These tests would tend to leave non disposed SafeHandle which would later be finalized, then throwing ObjectDisposedException. They would also crash on .NET.
2015-05-27 10:28:49 -03:00
Ludovic Henry 8785f28ed6 [corlib] Add test for ThreadLocal finalization 2015-05-27 10:20:40 -03:00
Zoltan Varga b13795141d [llvm] Fix the loadable llvm build. 2015-05-27 08:57:46 -04:00
Marek Safar c35541d674 [corlib] Add more obsolete and not working types to MonoDroid 2015-05-27 11:32:33 +02:00
Marek Safar 62345ee9fd [system] Fixes incorrect tests 2015-05-27 10:49:56 +02:00
Zoltan Varga c814a25234 [jit] Properly compute the layout of generic instances created by partial sharing. Fixes #30204. 2015-05-26 20:22:52 -04:00
Zoltan Varga 2575daaacc [x86] Enable support for OP_GENERIC_CLASS_INIT. 2015-05-26 17:15:00 -04:00
Alex Rønne Petersen b67609f056 [mini] Remove MONO_ARCH_HAVE_CREATE_DELEGATE_TRAMPOLINE macro.
All architectures define this.
2015-05-26 16:48:58 -04:00
Zoltan Varga 795ba16c46 [configure] Bump version to 4.3.0. 2015-05-26 15:52:09 -04:00
Zoltan Varga 3b9c97fc90 [sgen] Use mono_class_has_finalizer () instead of klass->has_finalize. 2015-05-26 13:53:33 -04:00
Marek Safar cf766c92a7 [corlib] Clean up thread execution context 2015-05-26 17:42:27 +02:00
Zoltan Varga 58064152f2 [jit] Handle not attached threads in mono_thread_state_init_from_sigctx (). Hopefully fixes #28187. 2015-05-26 11:14:27 -04:00
Zoltan Varga 202b55be9b [System] Disable a test on mobile. 2015-05-26 10:48:06 -04:00
Marek Safar 378455b538 Merge pull request #1832 from Tragetaschen/fix-http-headers
Fix reading back a HTTP Request's Host header
2015-05-26 16:19:55 +02:00
Marek Safar 4bfbc0c75b [mcs] Emit correct binary comparison for useless is operator involving user value type with equality user operators 2015-05-26 14:16:47 +02:00
Rolf Bjarne Kvinge 2b46111528 [corlib] A few XI-internal functions have been renamed; use the new names. 2015-05-26 14:08:54 +02:00
Rolf Bjarne Kvinge 06eaf013eb [mdbrebase] Make sure to use a unique temporary filename.
Otherwise parallel invocations might end up stomping on eachother
(these two files are processed in parallel):

    Processing /work/maccore/master/maccore/builds/install/mac/xammac/bcl/mscorlib.dll.mdb
    Processing /work/maccore/master/maccore/builds/install/mac/net_4_5/bcl/mscorlib.dll.mdb

    Unhandled Exception:
    System.IO.FileNotFoundException: /var/folders/g9/k5kx4z211ld_lwlbfxv5rq040000gn/T/mscorlib.dll.mdb does not exist
    File name: '/var/folders/g9/k5kx4z211ld_lwlbfxv5rq040000gn/T/mscorlib.dll.mdb'
      at System.IO.File.Move (System.String sourceFileName, System.String destFileName) [0x00000] in <filename unknown>:0
      at Mono.MdbRebase.MdbRebase.RewriteMdbFile (System.String inputFile) [0x00000] in <filename unknown>:0
      at Mono.MdbRebase.Driver.Main (System.String[] args) [0x00000] in <filename unknown>:0
    [ERROR] FATAL UNHANDLED EXCEPTION: System.IO.FileNotFoundException: /var/folders/g9/k5kx4z211ld_lwlbfxv5rq040000gn/T/mscorlib.dll.mdb does not exist
    File name: '/var/folders/g9/k5kx4z211ld_lwlbfxv5rq040000gn/T/mscorlib.dll.mdb'
      at System.IO.File.Move (System.String sourceFileName, System.String destFileName) [0x00000] in <filename unknown>:0
      at Mono.MdbRebase.MdbRebase.RewriteMdbFile (System.String inputFile) [0x00000] in <filename unknown>:0
      at Mono.MdbRebase.Driver.Main (System.String[] args) [0x00000] in <filename unknown>:0
2015-05-26 14:08:53 +02:00
Rolf Bjarne Kvinge 43d7dc7e83 [mdbrebase] Add a quiet mode. 2015-05-26 14:08:53 +02:00
Rolf Bjarne Kvinge dbb9f7ae70 [mdbrebase] Indent properly. 2015-05-26 14:08:52 +02:00
Zoltan Varga 9623915cee [llvm] Fix the argument type of specific_trampoline_generic_class_init. 2015-05-26 07:58:38 -04:00
Marek Safar ee621cea34 [corlib] More thread code from reference sources, mostly for argument checks 2015-05-26 12:12:25 +02:00
Atsushi Eno 80093e6a4d [xbuild] make sure to load appropriate Microsoft.Build.Tasks*.dll.
When running MONO_LOG_LEVEL=debug xbuild with previous versions, it showed
that Microsoft.Build.Tasks.v4.0.dll was loaded, while the expected one was
Microsoft.Build.Tasks.v12.0.dll (as current xbuild script loads the one
from xbuild_12 profile). It was because Microsoft.Build.Tasks*.dll was
not referenced by xbuild.exe and thus it was loaded differently.

This hack adds strong reference to some class in Microsoft.Build.Tasks*.dll
of the corresponding version for each profile to resolve that issue.
2015-05-26 15:43:44 +08:00
Zoltan Varga 4bacc38aac Revert "[runtime] Use condvars instead of events for notifying the finalizer thread."
This reverts commit 5d36a53b2e.

Revert this as it causes hangs on wrench.
2015-05-25 22:03:58 -04:00
Zoltan Varga abda50d3ae [arm] Implement support for OP_GENERIC_CLASS_INIT. 2015-05-26 00:29:48 +00:00
Zoltan Varga 7b885bba56 [arm] Remove unused codegen files. 2015-05-26 00:29:47 +00:00
Joao Matos 1c38a07b54 [metadata] Replace non-portable usleep() with g_usleep() in MS threadpool. 2015-05-25 19:40:30 +01:00
Joao Matos 0bac16c486 [metadata] Fixed MSVC union compilation issues in MS threadpool. 2015-05-25 19:40:22 +01:00
Joao Matos dac2365030 [windows] Fixed MSVC config.h to define HAVE_COMPLEX_H. 2015-05-25 19:40:15 +01:00
Joao Matos c8cb145436 [sgen] Fixed compilation of sgen-workers.c under MSVC. 2015-05-25 19:40:07 +01:00
Joao Matos 0dd375255a [metadata] Fixed compilation of gc-stats.c under MSVC. 2015-05-25 19:39:59 +01:00
Joao Matos d09387907b [windows] Update MSVC DLL export definition files. 2015-05-25 19:39:52 +01:00
Joao Matos 6b98370101 [windows] Prepare VS build properties for proper DLL export/import definitions. 2015-05-25 19:39:45 +01:00
Joao Matos 2f97fa4262 [windows] Updated VS project files. 2015-05-25 19:39:38 +01:00
Zoltan Varga 6ae522d4da [llvm] Fix the IR generated for OP_GENERIC_CLASS_INIT. 2015-05-25 11:11:13 -04:00
Zoltan Varga 3e8becd92b [arm] Fix the handling of callee saved fp registers during unwinding, previously they were saved in an 32 bit array. Fixes #29726. 2015-05-25 11:00:37 -04:00
Marek Safar 5361ccb6b3 [corlib] Add TimeZoneInfo support to xammac 2015-05-25 16:34:04 +02:00
Marek Safar 97bfbacd0c [corlib] TimeZoneInfo.GetSystemTimeZones should work as singleton. Fixes #29906 2015-05-25 14:55:29 +02:00
Marek Safar 4dc9a90d7f [corlib] Clean up some of TimeZoneInfo ifdefs 2015-05-25 14:31:13 +02:00
Marek Safar 4cbe442b2e [corlib] SafeHandle from reference sources without code duplication. 2015-05-25 11:21:34 +02:00
Marek Safar b185d5dfa1 [mcs] Emit value type initializers without local reset before member are assigned. Fixes #30349 2015-05-24 16:13:40 +02:00
Kai Ruhnau 8483356376 Fixed parsing the host header field 2015-05-22 23:38:27 +02:00
Kai Ruhnau 1344fbc5fb Added a test for accessing HttpRequestHeader.Host 2015-05-22 23:38:27 +02:00
Marek Safar ac644c907d [corlib] Disable more CAS code 2015-05-22 21:04:52 +02:00
Marek Safar d339472524 [mcs] Emit decimal constant attribute sign using csc compatible format. Fixes #30267 2015-05-22 20:10:58 +02:00
Marek Safar 3fcc658371 [runtime] Check remoting support in mscorlib before wrappers are emitted. 2015-05-22 17:15:43 +02:00
Marek Safar 584056a62b [system.xml] Check different results under disabled cas 2015-05-22 17:15:43 +02:00
Marek Safar d3bda044e0 [corlib] ExecutionContext and other contexts from reference sources. Fixes #28793 and similar nested context switches issues. 2015-05-22 17:15:43 +02:00
João Matos e1c9e02099 [aot] Fixed the strip invocation to correctly handle paths with spaces. 2015-05-22 15:04:59 +01:00
João Matos bef3aa3388 [aot] Added a "temp-path" option to pass a location where to store temporary generation files. 2015-05-22 15:04:59 +01:00
João Matos c60627857c [aot] Document the "llvm-path" option. 2015-05-22 15:04:59 +01:00
João Matos fcb51d4d62 [aot] Refactored path cleaning code into a standalone function. 2015-05-22 15:04:58 +01:00
Sebastien Pouliot 605192528d [corlib] Restore UTF8 as the default encoding for XI and XM [#29928] 2015-05-22 09:55:37 -04:00
João Matos be2491409e Merge pull request #1829 from StephenMcConnel/bug-30325
Prevent DataGridViewTextBoxCell from using Disposed editor object
2015-05-22 11:24:45 +01:00
Marcos Henrich e602b242ff [corlib] Moved ValueType field into another class.
Adding fields to ValueType can mess with sub class layouts.
Fixes #30060.
2015-05-22 09:33:05 +01:00
Zoltan Varga 267812a6ff Merge pull request #1828 from alexanderkyte/jenkins_arm_profiler_crash
[runtime/profiler] Check that coverage hash tables have been initialized before freeing them.
2015-05-22 03:17:40 +02:00
Stephen McConnel 328fc576b3 Prevent DataGridViewTextBoxCell from using Disposed editor object
This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=30325.
2015-05-21 17:48:53 -05:00
Alexander Kyte 3d744d3253 [runtime/profiler] Check that coverage hash tables have been initialized before freeing them. 2015-05-21 16:58:07 -04:00
Atsushi Eno 63a8b865f7 [WCF] bonus, NET_2_1 is blocking set_Timeout. It didn't exist in Moonlight. 2015-05-22 01:23:27 +08:00
Zoltan Varga 0e0c1757fc [aot] Handle partial sharing in mono_aot_get_unbox_trampoline (). 2015-05-21 15:59:26 +02:00
Zoltan Varga b1fafa451c [runtime] Handle generic methods in mono_method_get_vtable_slot (). Fixes #30276. 2015-05-21 15:59:26 +02:00
Atsushi Eno 35fd7cd2b2 [WCF] fix send timeout. Should fix bug #19697. Should fix bug #19697. Should fix bug #19697. Should fix bug #19697.
1. Preserve ChannelFactory so that it can retrieve its ServiceEndpoint's
Binding's Timeout values.
2. Use DefaultCommunicationTimeouts.SendTimeout instead of ReceiveTimeout.
It was either written when I don't understand the API well or might be
different in duplex channel (who cares? nothing supports it now and
we will be switching to referencesource).

It is going to be my final contribution to WCF old codebase. Bye bye forever.
2015-05-21 16:07:27 +08:00
Zoltan Varga d52d3ca580 [runtime] Fix the calculation of the blittable status of System.ValueType after the import of the MS reference source version. 2015-05-21 09:31:26 +02:00
Alex Rønne Petersen 435cc010e1 Merge pull request #1826 from alexanderkyte/remove_all_processes_callback_test
[runtime] Remove a test that leads to excessive heap thrashing and interferes with other tests.
2015-05-21 03:39:02 +02:00
Marek Safar 580062d831 [system.xml] Disable cas in mobile profiles only 2015-05-20 21:20:02 +02:00
Marek Safar 9bf2a3bfa9 Bump reference source 2015-05-20 21:06:43 +02:00
Marek Safar aac0b374df [system.xml] One more mobile serialization incompatibility 2015-05-20 20:32:23 +02:00
Marek Safar d9b9ed5611 [corlib] Remove unused thread field 2015-05-20 16:22:55 +02:00
Ludovic Henry cd5256acb1 [threads] Remove dead code 2015-05-20 10:56:53 -03:00
Marek Safar c6299a9e0b [corlib] Match closer ExecutionContextSwitcher methods 2015-05-20 15:56:01 +02:00
Ludovic Henry 5011172a13 [referencesource] Import System.Threading.ThreadLocal 2015-05-20 10:54:13 -03:00
Ludovic Henry 6e9ee35e54 [referencesource] Import System.Threading.ThreadLocal 2015-05-20 10:40:08 -03:00
Alex Rønne Petersen 134c7aff03 Merge pull request #1823 from iainx/anti-dos
[Profiler] Limit files loaded in the coverage profiler to 128k
2015-05-20 15:17:42 +02:00
Ludovic Henry a17af8c3d0 [referencesource] Import System.ValueType
Instead of importing the source from referencesource, the algorithm has been reimplemented in our version. This is because their implementation uses multiple internal calls that do not need to be.
2015-05-20 09:57:23 -03:00
iain holmes 3d3f410b40 [Profiler] Limit files loaded in the coverage profiler to 128k
Place an upper limit on files loaded in the coverage profiler to 128k. If the
system suppression file exceeds that (it is currently only 3k), then there's
some problem and the profiler will exit. For other user files passed on the
commandline, we print a warning message and ignore them.
2015-05-20 12:56:16 +01:00
Marek Safar 7215f95d58 [bcl] Mobile profiles fixes 2015-05-20 12:56:36 +02:00
Alexander Kyte cb47efb688 [runtime] Remove a test that leads to excessive heap thrashing and interferes with other tests. 2015-05-20 04:16:44 +00:00
Martin Baulig 754395be23 Merge pull request #1822 from mono/work-bug23792
[TLS]: Fix #23792.
2015-05-20 04:46:08 +02:00
Sebastien Pouliot 5910f16f0a Bump referencesource for XI #30205 2015-05-19 21:51:30 -04:00
Martin Baulig bc1966273c [TLS]: Fix #23792.
What happens here is the following:

When using chunked encoding, the ChunkStream sometimes mixes async and sync requests
on the underlying stream.  The async calls work great - just the sync ones create
problems.

In this particular bug, the server returns two ApplicationData records - one big one
and then a smaller one.  The chunk parser requests a sync read of 1024 bytes which
then result in a series of sync reads on the underlying network stream.  The first
two or three network reads don't return enough data to fill the huge ApplicationData
record - the last one then returns so much data that it fills both the remainder of
the first record and the entire second one.

If the caller issued a second sync read, then the implementation would catch this -
but the async code path does not.
2015-05-20 03:12:26 +02:00
Sebastien Pouliot 87a2e8742e Bump referencesource for fixes required by XI 2015-05-19 20:10:53 -04:00
Ludovic Henry ead5d3a420 [referencesource] Import System.Runtime.InteropServices.SafeHandle
Instead of importing the source from referencesource, the algorithm has been reimplemented in our version. This is because their implementation uses multiple internal calls that do not need to be, and they are simple enough to just be reimplemented in managed code.
2015-05-19 19:25:39 -03:00
Marek Safar 7df4375af5 [corlib] Remove unused files 2015-05-19 23:26:48 +02:00
Marek Safar 317c3a8efb [corlib] LocalDataStoreSlot from reference sources 2015-05-19 22:06:58 +02:00
João Matos fd676354d3 Merge pull request #1821 from iainx/replace-getline
[Profiler] Replace getline(3)
2015-05-19 18:14:29 +01:00
Marek Safar 20b83458ef [corlib] CompressedStack in not supported in mobile profile 2015-05-19 19:07:26 +02:00
iain holmes e355216076 [Profiler] Replace getline(3)
getline(3) is not available on Android API < 21, so we use our own custom
functions
2015-05-19 17:36:28 +01:00
Zoltan Varga aa590f8a59 [aot] Fix full aot support. 2015-05-19 16:47:57 +02:00
Marek Safar 02fc6c1433 [corlib] Small part of thread from reference sources 2015-05-19 11:44:30 +02:00
Neale Ferguson ee4ac15ae6 Fix delegate and IMT processing - devirtualization and generics test now pass 2015-05-18 21:49:10 -04:00
Miguel de Icaza bdfb4d590d [mono-proclib] Compile on non Mach-based Unix systems (see pull request 1819) 2015-05-18 21:38:06 -04:00
Miguel de Icaza d6d5106f0e [corlib/Tests] Added test for bug #30171 2015-05-18 18:04:05 -04:00
Zoltan Varga ad8a1ff41f [arm64] Define MONO_ARCH_HAS_MONO_CONTEXT. 2015-05-18 22:30:05 +02:00
Marcos Henrich cb90d1a750 [corlib] Fixed TimeZoneInfo.GetDaylightChanges.
Changed GetDaylightChanges to match .NET behaviour.

GetDaylightChanges now only returns DaylightTime.Start and
DaylightTime.End in the given year.

DaylightTime.Start and DaylightTime.End may not belong to the same DST
period.
2015-05-18 18:18:40 +01:00
Marcos Henrich 396016aa82 [corlib] Test TimeZoneInfo.GetDaylightChanges.
Testing TimeZoneInfo.GetDaylightChanges with Australia/Sydney time zone.
2015-05-18 17:12:30 +01:00
Zoltan Varga c7bf3e8683 [runtime] Add a test for 8 delegate arguments. 2015-05-18 17:25:56 +02:00
Marcos Henrich 6888d8291c [corlib] Fixed make android TZ testing targets.
tzi.exe now builds with new sources.
tzi.exe is now ran and compiled with current mono and mcs which avoids corlib version
problems.
2015-05-18 15:30:09 +01:00
João Matos 29ac7c3839 Merge pull request #1815 from jbevain/clean-mutex-windows
[runtime] Cleanup wrappers for windows cond-vars
2015-05-18 13:18:41 +01:00
Marek Safar 6435c0b688 [mcs] Update unicode categories allowed as Unicode escape sequences within identifiers. Fixes #24968 2015-05-18 14:04:55 +02:00
Jo Shields ecd633f6a5 Add missing mono-profiler-log.suppression to EXTRA_DIST 2015-05-18 10:46:13 +01:00
Jb Evain a6516c0483 [runtime] Cleanup wrappers for windows cond-vars 2015-05-18 11:10:42 +02:00
Alex Rønne Petersen f32cdd40ed Merge pull request #1626 from iainx/add-coverage-to-log-profiler
Add coverage to log profiler
2015-05-18 09:55:43 +02:00
Marek Safar 789eb7e54c Merge pull request #1811 from yann-morin-1998/yem/parallel-install
mcs: fix installation with parallel make
2015-05-18 08:29:32 +02:00
Rodrigo Kumpera 0b45503a1a Merge pull request #1809 from kumpera/double_loading_fix
[runtime] Avoid allocating interface offsets multiple times. Fixes #28398
2015-05-17 13:05:34 -04:00
Yann E. MORIN d755444be0 mcs: fix installation with parallel make
In mcs/ the install of xbuild_12 and xbuild_14 will end-up installing
the same files:
    ${NETFRAMEWORK_DIR}/v2.0/RedistList/FrameworkList.xml
    ${NETFRAMEWORK_DIR}/v3.0/RedistList/FrameworkList.xml
    ${NETFRAMEWORK_DIR}/v3.5/RedistList/FrameworkList.xml
    ${NETFRAMEWORK_DIR}/v4.0/Profile/Client/RedistList/FrameworkList.xml
    ${NETFRAMEWORK_DIR}/v4.0/RedistList/FrameworkList.xml
    ${NETFRAMEWORK_DIR}/v4.5.1/RedistList/FrameworkList.xml
    ${NETFRAMEWORK_DIR}/v4.5/RedistList/FrameworkList.xml

This is because there is no atomicity when installing each file, and
xbuild_12 and xbuild_14 may well run in parallel, each trying to install
each of those files; but the 'install' utility will first check if the
target file exists or not, and there is a race in doing so, thus leading
to build failures like so:
    http://autobuild.buildroot.org/results/c32/c3288c5d1fb94474f14a4a889e76135878d403bc/build-end.log
    http://autobuild.buildroot.org/results/3cb/3cb99e5c5672cbaa2a86020129a05dfde47cdb8f/build-end.log
    and many more:
    http://autobuild.buildroot.net/?reason=host-mono-4.0.0
    http://autobuild.buildroot.net/?reason=host-mono-4.0.1

So, ensure ordering of the install of xbuild_12 and xbuild_14 (the
ordering is completely arbitrary, either way gives the same installed
files).

Signed-off-by: "Yann E. MORIN" <[email protected]>
Cc: Angelo Compagnucci <[email protected]>
2015-05-17 15:15:12 +02:00
Zoltan Varga b42709296a [runtime] Remove the unused method field from MonoLMF on arm64. 2015-05-17 15:05:13 +02:00
Zoltan Varga f828063e89 [runtime] Fix the DISABLE_JIT/DISABLE_REMOTING build. 2015-05-17 15:04:53 +02:00
Zoltan Varga 23fe623c7c Fix the DISABLE_COM build. 2015-05-17 14:46:07 +02:00
Zoltan Varga 6de9c066ad [jit] Remove some unused code when MONO_ARCH_HAVE_OP_GENERIC_CLASS_INIT is defined. 2015-05-17 14:06:11 +02:00
Zoltan Varga 68857c4ba2 [runtime] Remove a few more DISABLE_ ifdefs. 2015-05-16 13:52:01 +02:00
Zoltan Varga e6aee5116c [runtime] Reduce the number of gc ifdefs in gc.c a bit more. 2015-05-16 13:34:30 +02:00
Zoltan Varga 5d36a53b2e [runtime] Use condvars instead of events for notifying the finalizer thread. 2015-05-16 13:23:56 +02:00
Zoltan Varga 0d1f6e84d1 Revert "[runtime] Use condvars instead of events for waiting for domain finalization."
This reverts commit f84084dd79.

Revert this until issues with interrupts can be sorted out.
2015-05-16 11:47:28 +02:00
Zoltan Varga ff16e16d39 Revert "[runtime] Use condvars instead of events for notifying the finalizer thread."
This reverts commit c84508b6f3.

Revert this until issues with interrupts can be sorted out.
2015-05-16 11:46:59 +02:00
Zoltan Varga c84508b6f3 [runtime] Use condvars instead of events for notifying the finalizer thread. 2015-05-16 11:03:49 +02:00
Zoltan Varga 288eae2eda [runtime] Remove compile time null gc dependencies from gc.c. 2015-05-16 10:16:07 +02:00
Zoltan Varga f84084dd79 [runtime] Use condvars instead of events for waiting for domain finalization. 2015-05-16 10:08:01 +02:00
Zoltan Varga 968b337ad9 [jit] Fix OP_GENERIC_CLASS_INIT on amd64 so it doesn't clobber the first arg register. 2015-05-16 09:58:05 +02:00
Zoltan Varga 0a8467536f [jit] Allow the inlining of generic class init trampolines on some platforms. Enable it for amd64. 2015-05-16 08:49:01 +02:00
Alex Rønne Petersen d599fe52d5 [runtime] Fix endianness issue with special static offsets.
On big endian systems, this code would break because we reinterpret the
structure as a `guint32` via memory. Fix this by reversing the order of
the fields on big endian systems.
2015-05-16 02:49:32 +02:00
Zoltan Varga 7895a1b971 [runtime] Disable spawning lldb on a native crash, since it doesn't quit automatically. 2015-05-16 01:50:10 +02:00
Zoltan Varga 88058205f8 [aot] Avoid defining symbols starting with numbers. Fixes #30099. 2015-05-16 01:11:42 +02:00
Miguel de Icaza f1778d1797 Add tests for #3811 2015-05-15 18:27:53 -04:00
Alex Rønne Petersen 75fad022c2 Merge pull request #1801 from alexrp/profiler-allocs
[runtime] Improve profiler allocation reporting
2015-05-15 21:29:48 +02:00
Rodrigo Kumpera 738acc78f1 Merge pull request #1654 from alexanderkyte/xunit-fixes
Fix various bugs causing hangs on Xunit
2015-05-15 15:24:44 -04:00
Miguel de Icaza 1a7719f4e1 Merge pull request #1805 from martincostello/master
Fix typos in man content for sn
2015-05-15 15:08:48 -04:00
Marek Safar 4ba6def9ed [corlib] Fixes mobile tests 2015-05-15 20:52:47 +02:00
Alex Rønne Petersen a83f965db0 [runtime] Use slow path managed allocators when profiling a FullAOT image.
This is needed because the fast paths in managed allocators (by design) don't
report allocations to the profiler. In regular JIT/AOT mode, managed allocators
are simply disabled to work around this when profiling. However, in FullAOT
mode, an image may have been compiled with managed allocators enabled which
results in the managed allocator actually being emitted into the AOT image.

So, when we want to profile a FullAOT image, we need to replace the regular
managed allocator with one that always goes through the slow path (i.e. calls
straight into the runtime). To that end, when we decode a MONO_WRAPPER_ALLOC
method ref, we redirect it to the appropriate slow path allocator if allocation
profiling is enabled.
2015-05-15 20:05:01 +02:00
João Matos 6788b71d65 [aot] Added command-line parsing support for hybrid AOT mode. 2015-05-15 16:52:32 +01:00
João Matos 0d1766729b [aot] Migrate the AOT compiler code to use MonoAotMode.
No behavioural changes intended.
2015-05-15 16:52:32 +01:00
João Matos f3631b5625 [runtime] Introduce new mono_jit_set_aot_mode public AOT API.
We're also deprecating `mono_jit_set_aot_only` which is a strictly on-off API and of limited value in the face of the new AOT modes.
2015-05-15 16:52:31 +01:00
João Matos 18b444a328 [runtime] Introduce MonoAotMode enum to the public API.
This will be used throughout the runtime to bookkeep the selected AOT code model.
2015-05-15 16:52:31 +01:00
iain holmes a5ab6c642e [Profiler] Add coverage information to the log profiler
Store coverage information in the mlpd file. Extend the mprof-report tool to
give a basic coverage summary.
2015-05-15 16:05:21 +01:00
iain holmes 914ecbcfec [Utils] Use g_direct_equal if NULL is passed in as the equals function 2015-05-15 15:32:54 +01:00
iain holmes d59f06bf31 [Utils] Add an iteration function to MonoConcurrentHashTable 2015-05-15 15:32:54 +01:00
Alex Rønne Petersen 1f8da92d47 Merge pull request #1656 from alexanderkyte/webservice_27561
[System.ServiceModel] Fix timeout defaulting to 0 seconds
2015-05-15 16:09:02 +02:00
Alex Rønne Petersen 7cb2c544b4 [runtime] Regenerate opcodef.def.
Note: Don't modify this file by hand.
2015-05-15 15:16:09 +02:00
Alex Rønne Petersen d99605b7ca [mini] Add regressionexitcode.out to .gitignore. 2015-05-15 15:16:09 +02:00
Alex Rønne Petersen 1768346f06 [runtime] Move profiler allocation reporting to GC implementations.
By reporting allocations in the GC implementations, we significantly reduce the
odds of someone forgetting to add a mono_profiler_allocation () call. These
previously had to be placed at all call sites of mono_gc_alloc_* () which was
in some cases forgotten, resulting in the profiler seeing objects in GC events
which appeared to not have been allocated.
2015-05-15 15:16:09 +02:00
Alex Rønne Petersen 1fae7cebda [runtime] Move object allocation into GC implementations.
This was already done for SGen, but Boehm and the null GC still had a bunch of
code in object.c to allocate and prepare objects. This has now been moved into
mono_gc_alloc_* () functions so that all 3 GC backends have the same interface
for allocation.
2015-05-15 15:16:09 +02:00
Alex Rønne Petersen d2986015a2 [runtime] Drop support for external libgc.
This has not been supported for a while, so remove it.
2015-05-15 15:16:08 +02:00
Marek Safar af1f5f88d6 [System.Data.DataSetExtensions] Switch to reference sources 2015-05-15 09:17:12 +02:00
Rodrigo Kumpera 972f726d03 [runtime] Avoid allocating interface offsets multiple times. Fixes #28398
setup_interface_offsets will be called multiple times. The code was originally
designed to avoid setting up this multiple times but a change to avoid making it assert
when used from SRE made it so that the check to avoid multiple initialization would
effectively make it be initialized multiple times.

See 628e025476 for the original change.
2015-05-14 22:02:28 -04:00
Alexander Köplinger eac7d992d8 [System.Data] Fix make dist 2015-05-15 01:24:10 +02:00
martincostello 15b4ee13fa Fix typos in "man sn". 2015-05-14 18:58:50 +01:00
João Matos 75175b2f26 [aot] Fixed linker invocation when cross-compiling to Android.
Fixes an Android AOT regression introduced by https://github.com/mono/mono/commit/b41ed5db82ad82f0540eef70d821318836fba107.
2015-05-14 18:22:09 +01:00
Marek Safar b0a5a112da [System.Data] Remove obsolete files 2015-05-14 19:09:28 +02:00
Marek Safar b9e6d33761 [system.data] More api from reference sources 2015-05-14 19:09:28 +02:00
Marek Safar 839556ab8b [system.data] SqlXml from reference sources 2015-05-14 19:09:28 +02:00
Zoltan Varga e993138227 [runtime] Fix the signature of native-func-aot wrappers. AOT the delegate invoke wrapper which is used to invoke it. Fixes #29970. 2015-05-14 18:38:18 +02:00
Miguel de Icaza 10b80454c8 Merge pull request #1793 from rolfbjarne/subminute-dstoffset-fix
[corlib] Tweak the fix for the reference sources' inability to support sub-minute DST offsets.
2015-05-14 12:29:13 -04:00
Alexander Kyte 90e4b09042 [runtime] Made mono_marshal_get_castclass_with_cache use the isinst fixes, refactored 2015-05-14 12:05:28 -04:00
Marek Safar 2ca1bff97e [corlib] Remove unused code 2015-05-14 14:06:11 +02:00
Marek Safar 3f0aeecfe2 [corlib] More reference code for string class 2015-05-14 13:48:01 +02:00
Marek Safar 19eeecfca1 [corlib] Remove unused code 2015-05-14 13:48:01 +02:00
Ludovic Henry b84deedb6e [corlib] Remove unused code 2015-05-14 10:56:02 +01:00
Ludovic Henry 331c80c2aa [threadpool-ms] Fix compilation warning 2015-05-14 10:24:08 +01:00
Ludovic Henry d8aeecf147 [null-gc] Ensure mono_gc_set_skip_thread is compiled 2015-05-14 10:22:41 +01:00
Ludovic Henry 0127638583 [threads] Revert part of e05ba2a2fb 2015-05-14 09:28:10 +01:00
Zoltan Varga 593338049d [arm64] Increase max length of seq_point instruction. 2015-05-14 09:21:59 +02:00
Zoltan Varga 082de058c3 [aot] Avoid generating instances of AsyncMethodBuilderCore/AsyncVoidMethodBuilder methods, use the gsharedvt versions instead. Fixes part of #29615. 2015-05-14 09:18:04 +02:00
Marek Safar 5eb160d05e [corlib] Remove unused code 2015-05-14 08:40:15 +02:00
Alexander Kyte b52f3de356 [runtime] Do not cache isinstance for TransparentProxies
When using a TransparentProxy, we run into the problem that the cache is
shared between all marshalbyrefobjects. The fix here is to not update
the cache when using a TransparentProxy, so that the correct slow path
is used.
2015-05-13 18:59:58 -04:00
Ludovic Henry 749466e90a [threads] Remove dead code 2015-05-13 23:08:16 +01:00
Ludovic Henry 199da98d9d [threads] Remove thread_exit callback as the logic is redundant between the GCs 2015-05-13 23:08:16 +01:00
Ludovic Henry 3e0d937e6c [threads] Remove dead code 2015-05-13 23:08:16 +01:00
Ludovic Henry 497b2b60d0 [sgen] Remove unnecessary #define 2015-05-13 23:08:16 +01:00
Ludovic Henry e05ba2a2fb [threads] Remove useless indirection for thread creation on Posix platforms 2015-05-13 23:08:15 +01:00
Marek Safar 16a9a3e24c Revert "Fixes a5478121f0215a9d9068931ac7fd2b6ae459b036 reference sources"
This reverts commit c98a779e91.
2015-05-13 20:14:46 +02:00
Alexander Kyte e4d491cdd7 [System.ServiceModel] Fix timeout defaulting to 0 seconds 2015-05-13 13:54:53 -04:00
Marek Safar c98a779e91 Fixes a5478121f0215a9d9068931ac7fd2b6ae459b036 reference sources 2015-05-13 19:46:16 +02:00
Marek Safar f7026bd8e2 [system.web] Add System.Design reference instead of referencing files 2015-05-13 19:45:09 +02:00
Ludovic Henry 1886cdc73f [referencesource] Import System.Double and System.Simple 2015-05-13 18:31:09 +01:00
Alex Rønne Petersen 45d61b6453 Merge pull request #1784 from alexrp/profiler-init
[profiler] Initialize threads in runtime initialization callback
2015-05-13 19:02:50 +02:00
Marek Safar f4f5864fde [system.web.service] desktop version from reference sources 2015-05-13 18:47:08 +02:00
Marek Safar d8c7c68064 [System.Data.Design] Make TypedDataSetSchemaImporterExtension not working instead of throwing NIE 2015-05-13 18:47:07 +02:00
Marek Safar 401a35cd69 [system.xml] Serialization from reference sources for desktop 2015-05-13 18:47:07 +02:00
Alex Rønne Petersen 14317bf8a7 Merge pull request #1797 from schani/feature-pinning-stats
[sgen] Fix pinning statistics
2015-05-13 18:42:52 +02:00
Zoltan Varga 1d83b90fd1 [runtime] Fix the initialization of the pid array in ves_icall_System_Diagnostics_Process_GetProcesses_internal (). 2015-05-13 18:41:26 +02:00
Alex Rønne Petersen df27ba1a5e Merge pull request #1799 from evincarofautumn/fix-heavy-stat-warnings
[sgen] Fix warnings with heavy stats.
2015-05-13 13:48:09 +02:00
Jon Purdy 875606b12b [sgen] Fix warnings with heavy stats.
The types of these counters were changed in 5f33085d, so the atomic
updates (should have) stopped working. We can just mutate them
non-atomically.
2015-05-12 15:41:18 -07:00
Mark Probst 90a43c010b [sgen] Make pinning stats operational again. 2015-05-12 14:41:25 -07:00
Mark Probst 411398cbb2 [sgen] mono_gc_printf should not append newlines. 2015-05-12 14:41:24 -07:00
Mark Probst b8fcbbb302 [sgen] Simplify sgen_conservatively_pin_objects_from().
We're doing essentially the same check twice, and not doing the
pinning stats correctly.
2015-05-12 14:41:24 -07:00
Mark Probst 2994e24415 Merge pull request #1796 from evincarofautumn/fix-heavy-stats-2
[sgen] Actually fix heavy stats.
2015-05-12 14:39:25 -07:00
Jon Purdy fa47efacc3 [sgen] Actually fix heavy stats. 2015-05-12 14:31:29 -07:00
Mark Probst 13a7e83224 Merge pull request #1795 from evincarofautumn/fix-heavy-stats
[sgen] Fix heavy statistics.
2015-05-12 14:18:40 -07:00
Jon Purdy 65b194393b [sgen] Fix heavy statistics. 2015-05-12 14:15:22 -07:00
Rodrigo Kumpera cc40e2e17d Merge pull request #1668 from alexanderkyte/bug1856
[runtime] Overwrite stacktrace for exception on re-throw. Fixes #1856.
2015-05-12 17:11:18 -04:00
Alexis Christoforides a630299893 [runtime] Fixed typo in previous commit, added sleep 2015-05-12 16:07:54 -04:00
Alexis Christoforides ee234e8d70 [runtime] When attaching a tools thread, spin-wait for thread system init. Fixes #29538 2015-05-12 15:30:18 -04:00
Marek Safar 914e2bcf40 [system.xml] System.Xml.Serialization.Advanced from reference sources 2015-05-12 18:43:06 +02:00
Marek Safar bfd7953e86 Merge pull request #1794 from jbevain/monofield_getmodule
[corlib] Implement MonoField Module property
2015-05-12 16:50:07 +02:00
Jb Evain 44b81a65f4 Add unit test for FieldInfo.Module 2015-05-12 16:40:33 +02:00
Marek Safar 7555cf9b30 Bump reference sources 2015-05-12 16:29:51 +02:00
Jb Evain 5744a3d7fa [corlib] Implement MonoField Module property 2015-05-12 16:22:18 +02:00
Zoltan Varga 92a592398c [runtime] Really fix --disable-visibility-hidden. 2015-05-12 16:09:10 +02:00
Marek Safar 226511f0eb Bump reference sources 2015-05-12 16:00:32 +02:00
Marek Safar 9876575398 [corlib] Fix Test attribute name collisiong causing all tests to be ignored 2015-05-12 16:00:03 +02:00
Marek Safar 2a02d63b50 [System.ComponentModel.DataAnnotations] Remove unused types 2015-05-12 14:39:05 +02:00
Marek Safar 3d4ef2cee6 [build] Don't set special library path for monolite boostrap. It causes issue when system and other assemblies during bootrap need to access mscorlib api which is newer than monolite. 2015-05-12 14:10:17 +02:00
Rolf Bjarne Kvinge 926bd9d44c [corlib] Tweak the fix for the reference sources' inability to support sub-minute DST offsets.
It seems the base utc offset can also have a sub-minute resolution
in Unix, which means we need to apply the whole-minute rounding to
the final result (dstDelta) instead of the intermediate ttype.Offset
value.

We need to try to fetch the exact timezone id to expose this bug,
since fetching all system timezones will just not return any
problematic timezones (and there is thus no way to distinguish
inexistent timezones from timezones that failed to load).
2015-05-12 13:17:47 +02:00
Rolf Bjarne Kvinge 764aeb28b6 [corlib] Update SecurityCriticalAttribute test for updated mobile API. 2015-05-12 13:14:32 +02:00
Marek Safar 5f959e7bac [system.xml] Resource string from reference sources 2015-05-12 11:56:27 +02:00
Marek Safar 285c7dd5b7 [mcs] Support multiple string resource files 2015-05-12 11:45:27 +02:00
Atsushi Eno b30a20dd71 bump referencesource for System.Data (remove wrong MDAC ver. check for Odbc) 2015-05-12 14:54:34 +08:00
Atsushi Eno 19487986c5 Fix System.dll mobile builds. 2015-05-12 14:53:05 +08:00
Atsushi Eno b8ee40b9f3 Revert "[system.xml] System.Xml.Serialization.Advanced from reference sources"
This reverts commit e66d448104.
2015-05-12 14:44:59 +08:00
Atsushi Eno ddca46d22b Revert "[system.xml] Serialization from reference sources for desktop"
This reverts commit 6ae517ea65.
2015-05-12 14:42:19 +08:00
Rodrigo Kumpera 093a116f0f Merge pull request #1783 from alexanderkyte/thread_transition_crash
[runtime] Make thread abort synchronous
2015-05-11 14:59:04 -04:00
Ludovic Henry 7bb908bc03 [bcl] Fix Process.OnExited multiple call with the MS ThreadPool 2015-05-11 18:44:49 +01:00
Alexis Christoforides 485a0964ab [runtime] Add a couple of asserts to thread attach methods 2015-05-11 11:56:20 -04:00
Marek Safar 98740abe89 [system] CompilerParameters from reference sources 2015-05-11 16:55:52 +02:00
Marek Safar 6ae517ea65 [system.xml] Serialization from reference sources for desktop 2015-05-11 15:37:01 +02:00
Marek Safar 6454d7b844 [System.Runtime.Caching] Fix warnings 2015-05-11 15:37:01 +02:00
Marek Safar 2aab942e38 Merge pull request #1788 from ermshiperete/master-Xamarin-29935
Unit test that demonstrates Xamarin-29935
2015-05-11 15:33:23 +02:00
Eberhard Beilharz 5afea62a8c Unit test that demonstrates Xamarin-29935
Change-Id: I3510a2ccb897e0a0baf03af3a34bb74d6b700e03
2015-05-11 15:31:04 +02:00
Ludovic Henry 0b2967af2e [threadpool-ms] Remove thread waiting and memory cleanup
This could lead to hangs because threadpool->counter._.active would not be decremented. It means we cannot cleanup memory as the threads may still try to access the threadpool global variable.
2015-05-11 13:37:25 +01:00
Ludovic Henry 89d6cbdd4a [threadpool-ms] Fix assertion error "threadpool-ms.c:731, condition `counter._.working >= 0' not met" 2015-05-11 11:48:32 +01:00
Zoltan Varga f512ea07b2 [runtime] Implement support for locals info for portable pdb files. 2015-05-11 03:24:14 -04:00
Zoltan Varga 79b09ea0cb [runtime] Finish support for sequence point info for the portable pdb format. 2015-05-10 05:43:53 -04:00
Zoltan Varga b2bb9fde0a [runtime] Fix some FIXMEs in mono_ppdb_get_seq_points (). 2015-05-10 04:27:32 -04:00
Zoltan Varga 293a2f1a0d [runtime] Add mono_ppdb_get_seq_points () function, same as mono_debug_symfile_get_seq_points () but for portable pdb files. 2015-05-10 02:55:47 -04:00
Zoltan Varga 566da179cb [runtime] Add a mono_debug_get_seq_points () function which is a wrapper for mono_debug_symfile_get_seq_points (). 2015-05-10 02:43:00 -04:00
Zoltan Varga d94874b3b3 [runtime] Rename mono_debug_symfile_get_line_numbers_full () to mono_debug_symfile_get_seq_points (), return most of the information in an array of MonoSymSeqPoint structures. Remove unused mono_debug_symfile_get_line_numbers () function. 2015-05-10 02:23:11 -04:00
Zoltan Varga 86d55b362f [runtime] Remove more unused debugger code. 2015-05-10 02:23:11 -04:00
Marek Safar ffb5c90e08 [system.runtime.caching] Remove inappropropriate use of Marshal.SizeOf. Fixes #29667 2015-05-09 12:24:20 +02:00
Marek Safar a8e603f055 [system.data] Fix culture specific test 2015-05-09 11:50:11 +02:00
Zoltan Varga a11d525098 [jit] Avoid an assertion in the virtual delegate optimization if the target method is not virtual. 2015-05-09 01:16:05 -04:00
Zoltan Varga 99a5e9eca5 [runtime] Add beginnings of support for Portable PDB symbol files. 2015-05-08 23:26:00 -04:00
Zoltan Varga c5bbe92de6 [runtime] Add support for the new metadata tables used by the Portable PDB file format. 2015-05-08 23:24:00 -04:00
Zoltan Varga df511639ec [runtime] Add support for loading metadata images without a PE wrapper. 2015-05-08 23:21:33 -04:00
Alex Rønne Petersen ac84b9afea [profiler] Initialize threads in runtime initialization callback.
For the helper and writer thread to actually work, we need Mono's threading
subsystem to be initialized (so we can use TLS and hazard pointers). We now
wait with starting these threads until Mono gives us the go-ahead.

This means that a bit more data will be buffered up in the thread-local log
buffers during startup, but it shouldn't really matter in practice.
2015-05-09 04:07:22 +02:00
Zoltan Varga 74be9b6b66 [runtime] Use a condvar for waiting for the finalizer thread to shut down. 2015-05-08 18:28:46 -04:00
Zoltan Varga 6970210c7e [runtime] Add a mono_cond_timedwait_ms () function which takes a timeout argument in milliseconds. 2015-05-08 18:28:12 -04:00
Zoltan Varga de603c9af3 [runtime] Add a FIXME to mono_cond_timedwait () on windows. 2015-05-08 15:24:50 -04:00
Mark Probst b21f2c9560 [sgen] Only flush binary protocol buffers when world is stopped. 2015-05-08 11:32:54 -07:00
Miguel de Icaza 6c9ad41d85 [monop] Band-aid, cope with IKVM's Type.Namespace crashing on generic types
[monop] Add test suite for monop
2015-05-08 13:38:18 -04:00
Alexander Kyte 632ddbf84d [runtime] Make thread abort synchronous
Due to asynchronous abortion a crash is being seen on
posix systems where the abort signal handler is having a
data race and not exiting the suspend signal handler early.

When it tries to make a state transition because of this, it
cannot and it crashes.

This fixes it by making it synchronous.
2015-05-08 13:24:53 -04:00
Ludovic Henry 8f1d53d31b [threadpool-ms] Revert part of fd0ff7bff9 as it causes deadlocks on cleanup 2015-05-08 18:09:23 +01:00
Alex Rønne Petersen 975b1e7c35 Merge pull request #1781 from alexrp/master
[runtime] Improve context static LocalDataStoreSlot support
2015-05-08 18:10:06 +02:00
Alex Rønne Petersen 0bc0b176bc Merge pull request #1782 from alexrp/profiler-symbol-fix
[utils] Export concurrent hash table and lock free queue functions
2015-05-08 15:00:03 +02:00
Marek Safar e66d448104 [system.xml] System.Xml.Serialization.Advanced from reference sources 2015-05-08 14:41:32 +02:00
Marek Safar 69101f50ec [system.xml] serialization handlers from reference sources 2015-05-08 14:41:32 +02:00
Ludovic Henry fd0ff7bff9 [threadpool-ms] Reenable threadpool cleanup 2015-05-08 13:28:27 +01:00
Ludovic Henry 6e58bc0843 [threadpool-ms] Refactor worker creation and domain unloading 2015-05-08 13:28:27 +01:00
Ludovic Henry 02c391f6ba [threadpool-ms] Ensure monitor thread does not start if runtime is shutting down 2015-05-08 13:28:26 +01:00
Ludovic Henry 2af815c0e9 [threadpool-ms] Fix potential bug on monitor thread interuption 2015-05-08 13:28:26 +01:00
Ludovic Henry ded068692d [threadpool-ms] Refactor lock for working and parked threads 2015-05-08 13:28:26 +01:00
Ludovic Henry a8e82f17c4 [threadpool-ms] Guarantee icall parameter size 2015-05-08 13:28:26 +01:00
Alex Rønne Petersen f378198ed0 [utils] Export concurrent hash table and lock free queue functions. 2015-05-08 12:56:20 +02:00
Marek Safar 90d072e8de [system.xml] System.Xml.Serialization.Configuration from reference sources 2015-05-08 11:15:50 +02:00
Alex Rønne Petersen 11521369a8 [runtime] Improve context static LocalDataStoreSlot support.
The context-specific code now mirrors the thread-specific code and uses the
internal NamedDataSlot class. The runtime code now correctly frees context
static data allocated via this class.
2015-05-08 11:05:22 +02:00
Zoltan Varga 3dfbbffadb Fix make dist. 2015-05-08 05:01:04 -04:00
Zoltan Varga 38f95850b1 Fix the build. 2015-05-08 04:59:18 -04:00
Marek Safar 38f4bd1f95 [corlib] Bump reference souces. Fixes #29808 2015-05-08 10:33:50 +02:00
Marek Safar f4c60610b7 [system.data] remove unused files from mobile profile 2015-05-08 08:49:27 +02:00
Zoltan Varga 2d50afe45a [sdb] Remove the usage of WaitForSingleObject (), use cond vars instead on all platforms. 2015-05-07 23:17:27 -04:00
Zoltan Varga d58c00eada [runtime] Implement support for condition variables on windows using the win32 CONDITION_VARIABLE type available from Windows Vista. 2015-05-07 23:06:17 -04:00
Zoltan Varga 64e77296ae [runtime] Fix the windows build. 2015-05-07 23:06:17 -04:00
Alex Rønne Petersen a486d4dd7b [runtime] Update LocalDataStoreSlot code to the new special static offset format. 2015-05-08 04:15:55 +02:00
Atsushi Eno 0137334b6f Merge pull request #1778 from JetBrains/xbuild_do_not_stop_buildnodemanager
xbuild: do not stop BuildNodeManager after one build
2015-05-08 10:58:39 +09:00
Zoltan Varga f7b9bb3bf0 [runtime] Disable the broken code which aligns small structs to 4/8 bytes. Add a MONO_DEBUG option to enable it. 2015-05-07 21:23:26 -04:00
Zoltan Varga 15c1dcf664 Merge pull request #1780 from alexrp/master
[runtime] Initialize contexts after the GC
2015-05-07 21:03:18 -04:00
Alex Rønne Petersen 5595e3de2b [runtime] Initialize contexts after the GC.
This is necessary since they use GC handles. So the handles_section must
be initialized before we try to use it.
2015-05-08 02:53:25 +02:00
Mark Probst 5260a42cd5 [runtime] Fix a few warnings. 2015-05-07 14:45:25 -07:00
Alex Rønne Petersen 736ffe64c5 Merge pull request #1777 from alexrp/sgen-separation
[sgen] Move bridge debugging code out of the independent SGen code
2015-05-07 22:48:30 +02:00
triton 4a9ea9c819 Revert "[genmdesc] Improved unknown specifier error handling for Perl version."
This reverts commit 05ce4f6ee1.

It's giving some problems on Monodroid build:

/Users/builder/data/lanes/1196/012ff355/source/mono/mono/mini/cpu-arm.md
Invalid specifier len:4 at line 51 at /Users/builder/data/lanes/1196/012ff355/source/mono/mono/mini/genmdesc.pl line 153, <DESC> line 51.
2015-05-07 20:32:15 +01:00
Marek Safar 82e5791466 [system.data] SqlConnectionStringBuilder from reference sources. Fixes #29823 2015-05-07 20:57:53 +02:00
Marek Safar 251ee4c04e [mcs] Flow analysis assignment from field expressions is now aware of special cased value types. Fixes #29276 2015-05-07 18:25:01 +02:00
Atsushi Eno 6447b00e9c Remove unused System.Runtime.Serialization code.
System.ServiceModel.Web/System.Runtime.Serialization.Json is left as is
because they seem to be used by System.Json build...
2015-05-08 01:13:32 +09:00
Zoltan Varga b0a4c876f2 [arm] Fix a problem introduced by 3469c138c6. 2015-05-07 11:56:01 -04:00
Atsushi Eno 9f006cd104 remove old System.Data code. 2015-05-08 00:50:27 +09:00
Leonid Shalupov c6f0cef1c5 xbuild: do not stop BuildNodeManager after one build (prevents subsequent builds from executing) 2015-05-07 17:24:36 +02:00
João Matos d105620caa [genmdesc] Fixed generator to allow instructions lengths equal to 0.
I was induced in error because of the following comment in the machine read specs:

`# len:number         describe the maximun length in bytes of the instruction
# number is a positive integer`
2015-05-07 16:11:10 +01:00
Ludovic Henry 443eac8071 [tools] Fix sgen-grep-binprot after sgen code move to mono/sgen 2015-05-07 16:08:13 +01:00
Ludovic Henry fb41850597 [threadpool-ms] Change the meaning of ThreadPoolCounter active and working 2015-05-07 16:08:13 +01:00
João Matos 771027fd03 [arm] Fixed regression related to invalid specifier for vcall2 instruction in ARM machine description.
Introduced in https://github.com/mono/mono/commit/3469c138c67e4b7e0afcc6a31046fcca7931d660.
2015-05-07 15:34:18 +01:00
João Matos 05ce4f6ee1 [genmdesc] Improved unknown specifier error handling for Perl version.
Should help catch regressions like the one introduced in https://github.com/mono/mono/commit/3469c138c67e4b7e0afcc6a31046fcca7931d660#diff-e3dadd3f8246691b408c41c0441d49fcR358 at build time.
2015-05-07 15:34:18 +01:00
João Matos 37ba61388e [genmdesc] Improved instruction length error handling for Perl version.
Should help catch regressions like the one introduced in https://github.com/mono/mono/commit/3469c138c67e4b7e0afcc6a31046fcca7931d660#diff-e3dadd3f8246691b408c41c0441d49fcR358 at build time.
2015-05-07 15:34:17 +01:00
João Matos 8dee94c5b9 [genmdesc] Improved instruction length error handling for C version. 2015-05-07 15:34:17 +01:00
Atsushi Eno 8abe9d21b6 Merge pull request #1773 from ztzg/sql-server-datetime2
Allow transferring datetime2/datetimeoffset to/from SQL Server 2012
2015-05-07 19:03:11 +09:00
Atsushi Eno 371944bed9 Merge pull request #1772 from ztzg/sql-server-variant
Fix SQL Server 2012 variant parameters and return values
2015-05-07 18:54:49 +09:00
Atsushi Eno b661dde23a Merge pull request #1771 from ztzg/sql-server-bulk-insert
Fix SQL Server 2012 bulk insert issues
2015-05-07 18:53:41 +09:00
Atsushi Eno 12a41c8d50 [xbuild] for resolving assemblies from pkg-config, prefer specified version
... even if SpecificVersion is false. There is no reason to prefer any
mismatching version when SpecificVersion=false.

That behavior caused monodevelop build failures because of incorrectly-
resolved gtk# packages. After this fix, this issue goes away.
https://github.com/mono/monodevelop/blob/2436ad1874694ec811871dacf9a659a79b5fad0d/README.md#known-problems
2015-05-07 16:25:32 +09:00
Alex Rønne Petersen 3566b027c8 [sgen] Move bridge debugging code out of the independent SGen code. 2015-05-07 04:52:28 +02:00
Alexander Köplinger 462a293178 [tests] Trim whitespace from testname in dummy unit test XML, Jenkins test display doesn't like it 2015-05-07 03:28:11 +02:00
Alexander Köplinger 6593867feb [tests] Small fixes to the dummy unit test XML output to make it a compliant NUnit file 2015-05-06 23:38:14 +02:00
Zoltan Varga c044dd6524 [jit] Treat MONO_ARCH_IMT_REG as allways defined. 2015-05-06 17:31:23 -04:00
Zoltan Varga 41b8883053 [runtime] Fix configure so it really uses -fvisibility=hidden. 2015-05-06 16:16:00 -04:00
Rodrigo Kumpera fa97bf542c [threading] Fix a race during shutdown where a thread could have a suspend requested after it's too late for it to be served.
During thread shutdown, it gets to a point where the thread can no longer server suspend requests. To fix that
we ensure the thread gets one last suspend opportunity before going down.
2015-05-06 16:11:41 -04:00
Rodrigo Kumpera 1aa0de2e20 [runtime] Don't call managed code when OVF. 2015-05-06 15:43:06 -04:00
Rodrigo Kumpera f13fedfbd5 [coop] Fix marshal code of reset-abort calls to use an IntPtr cookie var instead of int32. 2015-05-06 15:43:06 -04:00
Rodrigo Kumpera b00f1dc96f [coop] Ensure the polling tramp has a wrapper. 2015-05-06 15:43:05 -04:00
Alex Rønne Petersen b54cbfeec4 Merge pull request #1750 from alexrp/precise-ctx-static-scan
Improve thread/context static field scanning
2015-05-06 21:02:04 +02:00
Alex Rønne Petersen 1bc9a1048c Merge pull request #1742 from alexrp/symbol-renaming
Clean up some C symbols polluting the global namespace
2015-05-06 20:56:13 +02:00
João Matos fa03b8ee56 Merge pull request #1776 from evincarofautumn/fix-independent-sgen
[sgen] Fix non-Mono SGen clients.
2015-05-06 19:51:47 +01:00
Jon Purdy fa413dc1be [sgen] Fix non-Mono SGen clients. 2015-05-06 11:39:53 -07:00
Zoltan Varga 172c2aab5f [jit] Print out the numeric opcode name in mono_inst_name () when logging is disabled. 2015-05-06 14:37:43 -04:00
João Matos 0cbee32db0 Merge pull request #1775 from StephenMcConnel/bug-29724A
Fix bug in new SWF.MWFFileView.Dispose method (Xamarin 29724)
2015-05-06 17:37:46 +01:00
Stephen McConnel 2c5b75dc6b Fix bug in new SWF.MWFFileView.Dispose method (Xamarin 29724)
The fix for Xamarin 29724 submitted a day or two ago wasn't quite right.
2015-05-06 11:34:52 -05:00
Alexander Kyte 6b02759d6d [Remoting] Avoid needing to resolve the type by serializing the TypeInfo
This is a better fix for the problem of what type to give an object
when the actual type can't be loaded in the current domain.
2015-05-06 12:15:58 -04:00
Alexander Kyte 2bc8f49dfe [Remoting] Remove X-domain references through marshalling of method attributes 2015-05-06 12:15:57 -04:00
Marek Safar c5fa24e68c [build] Fixes reference sources hash 2015-05-06 17:17:00 +02:00
Marek Safar 1bda13b996 [bcl] Mobile profiles fixes 2015-05-06 17:11:33 +02:00
João Matos 5fbeb4d62e [runtime] Fixed always_inline function might not be inlinable warning on GCC.
This fix was suggested by @schani to the warning spam that we've started to see.
2015-05-06 15:08:17 +01:00
João Matos 8ddca7e6d7 [runtime] Fixed warning by including <winsock2.h> before <windows.h>. 2015-05-06 15:05:04 +01:00
João Matos b7cbb7de5a [runtime] Fixed unused count variable warning by moving some code around. 2015-05-06 15:04:30 +01:00
João Matos 03fa920102 [runtime] Fixed warning by including <winsock2.h> before <windows.h>. 2015-05-06 15:03:58 +01:00
João Matos 44127d6c4c [runtime] Fixed warning by only using #pragma warning on MSVC. 2015-05-06 15:03:45 +01:00
João Matos 750d82f54b [mini] Do not try to set the usermode exception policy unless we're targeting Windows.
Fixes Windows cross-compilation.
2015-05-06 15:01:40 +01:00
João Matos 9602e20595 [mini] Do not use the ELF writer when hosting on Windows. 2015-05-06 15:00:18 +01:00
Zoltan Varga ae495e8bd4 [runtime] Fix support for callvirt delegates with a vtype first argument. Fixes #29665. 2015-05-06 04:57:41 -04:00
Marek Safar b3e7d55dd4 Merge pull request #1774 from akoeplinger/unit-test-reporting-improvements
[RFC] Improve unit test reporting when test runner crashes
2015-05-06 09:28:04 +02:00
Alexander Köplinger 98f32fe96d [RFC] Improve unit test reporting when test runner crashes 2015-05-05 21:39:35 -04:00
Alex Rønne Petersen 7f08218b54 [sgen] Fix an accidental symbol export in sgen-workers.c. 2015-05-06 03:02:54 +02:00
Alex Rønne Petersen 5d683d012e [mini] Rename machine description symbol names to avoid global namespace pollution. 2015-05-06 03:02:11 +02:00
Alex Rønne Petersen 1cab4433d3 [utils] Rename JSON writer symbols to avoid global namespace pollution. 2015-05-06 03:02:11 +02:00
Alex Rønne Petersen f1c12de25e [mini] Rename image writer symbols to avoid global namespace pollution. 2015-05-06 03:02:11 +02:00
Alex Rønne Petersen db5bfbb4cf [runtime] Rename seq point symbols to avoid global namespace pollution. 2015-05-06 03:02:10 +02:00
Alex Rønne Petersen d6cac73af4 [runtime] Remove unused _mono_debug_address_from_il_offset function. 2015-05-06 03:02:10 +02:00
Alex Rønne Petersen 904580023b [utils] Avoid symbol namespace pollution in iomap code. 2015-05-06 03:02:10 +02:00
Alex Rønne Petersen 26d9d14075 [utils] Rename SHA-1 symbols to not pollute the global namespace. 2015-05-06 03:02:10 +02:00
Alex Rønne Petersen cd201807e8 [runtime] Rename GCHandle_CheckCurrentDomain to not pollute the global namespace. 2015-05-06 03:02:10 +02:00
Alex Rønne Petersen 988c429bac [wapi] Fix some symbol names to be remapped the same way as the rest.
This is in the interest of reducing namespace pollution.
2015-05-06 03:02:09 +02:00
Alex Rønne Petersen 3df6f77cba [runtime] Rework special static offset handling.
Special static offsets now have a less magical format:

 [0]   6-bit index into the array of chunks.
 [6]   25-bit offset into the array.
 [31]  Bit indicating thread or context static.

Also wrapped accesses to these fields in macros and a bitfield struct.
2015-05-06 01:30:51 +02:00
Alex Rønne Petersen 7b78fd1f74 [runtime] Unify thread/context static field scanning and management.
Context static data is now scanned precisely in the same way as thread static
data. To facilitate this, the memory management of context static data has been
fixed to work similarly to thread static data. This further required that all
contexts be available for iteration, so contexts are now added to a global hash
table (by GC handle) when they are created.
2015-05-06 01:30:51 +02:00
Alex Rønne Petersen 4ee3df3fdc [remoting] Increment the context ID counter atomically. 2015-05-06 01:30:51 +02:00
Alex Rønne Petersen 72bce87621 [runtime] Rewrite TLS slot marking to use MonoBitSet. 2015-05-06 01:30:51 +02:00
Alex Rønne Petersen e03d67b765 [utils] Add MONO_BITSET_FOREACH macro. 2015-05-06 01:30:50 +02:00
Mark Probst 017dce9f15 [sgen] Fix logging format specifiers. t modifier is not standard. 2015-05-05 15:21:58 -07:00
Damien Diederen 33654c3418 [Mono.Data.Tds] Serialize GUIDs as 16-byte arrays (rather than zero)
Make sure we do not accidentally to encode an object by breaking out for
unknown TypeCode.Object instances (this is where the zero bytes used to
silently come from).
2015-05-05 22:21:13 +02:00
Damien Diederen d7a417a349 [System.Data.SqlClient] Enable bulk insert of DateTime{,Offset} instances
This commit adds the missing mapping from DateTimeOffset to its SqlDbType,
and makes sure they are converted to string 1. in a locale-insensitive
manner, and 2. with maximum precision.
2015-05-05 22:21:13 +02:00
Damien Diederen 1858ce4a94 [System.Data.SqlClient] Avoid "invalid source table" exception in bulk inserts
Mono's implementation of DataTableMappingCollection used not to care,
but MS', merged from the .NET reference sources, throws an exception
if the source table name is empty.
2015-05-05 22:20:19 +02:00
Damien Diederen 85a746c386 [System.Data.SqlClient] Bulk copy: Query metadata in pending transaction
Without this, the bulk copy engine fails with a nested transaction error.

We now just reuse the current transaction to do the work.
2015-05-05 22:07:24 +02:00
Damien Diederen 3a81bfc275 [Mono.Data.Tds] Deserialize variant-wrapped fixed-size integers (1-8 bytes)
Without this, variant output parameters are left unconsumed in the
input stream, and null is returned.

The new code skips the max length uint, and decodes a subset of the
variant types.  What is not recognized is skipped, and we return null
as the previous code used to do.

(Ideally, the subset of GetColumnValue which decodes types which can
be embedded in a variant should be factored out to a different method,
and reused from GetVariantValue.)
2015-05-05 21:20:49 +02:00
Damien Diederen 77ef86e529 [Mono.Data.Tds] Register TdsColumnType.Variant as a "blob" type
On the wire, Variants are preceded by uint-encoded max length and
actual length (not bytes like smaller types).  Without this patch,
SQL Server 2008 SP2 rejects our requests as truncated.
2015-05-05 21:20:28 +02:00
Damien Diederen c6e96ff141 [Mono.Data.Tds] Add "sql_variant" case to TdsMetaParameter.GetMetaType 2015-05-05 21:20:21 +02:00
Damien Diederen 9bcae63da7 [System.Data.SqlClient] Set SqlParameter.SqlDbType even for SqlDbType.Variant
Without this, the TdsMetaParameter.TypeName ends up being null, which
crashes TdsMetaParameter.GetMetaType () when the variant value is
about to be serialized on the wire.
2015-05-05 21:20:08 +02:00
Damien Diederen f055c46a24 [Mono.Data.Tds] Serialize SqlDbType.DateTime{2,Offset} as char(n)
DateTime2 and DateTimeOffset are not directly supported by the TDS 7.1
wire protocol, which is the version implemented by Mono's current TDS
driver.  (Tds80.cs does in fact advertise version 0x00000071.)

Bumping the protocol version to 0x03000a73 or 0x03000b73, for TDS
7.3.A/7.3.B, is not sufficient; the stream generated by the driver
causes SQL Server to kill the connection right after the login packet.
More investigation is needed on that front.

SQL Server is fine, however, with us sending timestamps in
literal (ISO 8601) format down the wire, packed within ASCII char(n)
strings.  Which is what this patch does, which allows client code
perform inserts using, e.g.:

    var param = new SqlParameter("@Value", SqlDbType.DateTime2);
    param.Value = DateTime.Now;
    command.Parameters.Add(param);
2015-05-05 21:05:27 +02:00
Damien Diederen 81a0830d9e [System.Data.SqlClient] Map SqlDbType.DateTime{2,Offset} 2015-05-05 21:05:16 +02:00
Ludovic Henry 19c7dcd8f3 [threadpool-ms] Disable cleanup
The cleanup code would wait for all worker threads to finish, but that could lead to some workload that would block. By disabling the cleanup code, we do not wait on anything to happen, we count on the OS to clean everything up.
2015-05-05 19:32:36 +01:00
Ludovic Henry 611a43ee0f [delegate] Replace multicast delegate implementation
Replace the reversed linked implementation by an array based implementation. This will improve Combine performance, as well as ease delegate to virtual function optimization.
2015-05-05 17:36:53 +01:00
João Matos 690aa51537 Link to the general releases page instead of a specific version in NEWS.
Addresses some feedback from c30887a23e.
2015-05-05 16:15:42 +01:00
João Matos c30887a23e Update release notes URLs in the NEWS file. 2015-05-05 16:00:39 +01:00
Alex Rønne Petersen 5a57d12ffc Merge pull request #1766 from alexrp/sgen-separation
[sgen] Move the independent parts of SGen to a separate library
2015-05-05 16:30:26 +02:00
Marek Safar 46edec071c [runtime] Add more 3.0 fx assemblies to remapping table. Fixes #29459 2015-05-05 15:27:36 +02:00
Marek Safar 8e3e9d8408 [mcs] Use reference from closest storey which holds captured this. Fixes #29506 2015-05-05 15:02:17 +02:00
Zoltan Varga 691f540dd3 [runtime] Remove more unused CAS code. 2015-05-05 07:29:45 -04:00
Marek Safar c3cce27732 [build] Revert part of 036c41714a 2015-05-05 11:42:36 +02:00
Zoltan Varga 1e9b4787b1 [arm] Use the OP_TAILCALL code on ios as well. 2015-05-04 22:21:00 -04:00
Zoltan Varga d7be158c6b [sdb] Substract 1 from the ip in the soft breakpoint handling code to avoid associating the ip with the next seq point if two sequence points are emitted after each other. 2015-05-04 22:21:00 -04:00
Miguel de Icaza 6a2560229d Update, drop ssapre from the man page 2015-05-04 22:02:31 -04:00
Miguel de Icaza aa16c96cbb Update documentation, add float32 section 2015-05-04 21:27:17 -04:00
Zoltan Varga f2339f3ce9 [jit] Disable the binary writer on arm, dlopen () can't read the images it creates on some newer linux versions. 2015-05-04 20:41:22 -04:00
Zoltan Varga e42139d72c Merge pull request #1768 from StephenMcConnel/bug-29724
Fix memory leak in SWF.FileDialog due to thumbnail images
2015-05-04 20:13:38 -04:00
Zoltan Varga b41ed5db82 [arm] Use gcc --shared for linking aot images. 2015-05-04 20:11:47 -04:00
Stephen McConnel bcecb992fc Fix memory leak in SWF.FileDialog due to thumbnail images
This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=29724.
2015-05-04 18:43:38 -05:00
Zoltan Varga 7639eda430 Fix a warning. 2015-05-04 18:20:01 -04:00
Zoltan Varga 036c41714a [arm] Fix the DISABLE_JIT build. 2015-05-04 17:57:48 -04:00
Zoltan Varga eaf00365d1 [jit] Remove unfinished regalloc2. 2015-05-04 17:50:51 -04:00
Zoltan Varga 0e46874631 [runtime] Remove CAS stuff from configure. 2015-05-04 17:40:12 -04:00
Zoltan Varga 02c0bf01a1 [runtime] Remove CAS stuff from configure. 2015-05-04 17:39:56 -04:00
Zoltan Varga 52f8ef5f5c [runtime] Remove CAS tests. 2015-05-04 17:35:29 -04:00
Zoltan Varga 239e9848a4 [corlib] Remove unused CAS icalls. 2015-05-04 17:35:09 -04:00
Zoltan Varga 38e55c77f9 [runtime] Remove --security=smcs-temporary-hack and --security=cas options and the code supporting them. 2015-05-04 17:22:43 -04:00
Alex Rønne Petersen 364677641c Merge pull request #1767 from alexanderkyte/err_namespace_fix
[runtime] Use correct namespace for FileNotFoundException
2015-05-04 21:56:13 +02:00
Alexander Kyte e4fc9c9840 [runtime] Use correct namespace for FileNotFoundException 2015-05-04 15:48:55 -04:00
Alex Rønne Petersen 0c71975bce [sgen] Move the independent parts of SGen to a separate library. 2015-05-04 21:09:29 +02:00
João Matos 22212dcb47 [System.IO.Compression] Fixed reading of Zip archives with malformed extra data entries.
From a ZIP spec:

"Extra field: Used to store additional information.
The field consistes of a sequence of header and data pairs, where the header has a 2 byte identifier and a 2 byte data size field."

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=29625.

Reported upstream: https://github.com/adamhathcock/sharpcompress/issues/54
2015-05-04 18:31:01 +01:00
Marek Safar be577089cc [mcs] Auto-properties can still be assigned from constructor when no setter is specified. Fixes #29691 2015-05-04 18:31:51 +02:00
João Matos 4bbeecf15d [runtime] Fixed SeqPointInfo objects to also work under ARM64. 2015-05-04 17:07:01 +01:00
João Matos 2667205186 [runtime] Re-organized object offsets into shared and architecture-specific sections. 2015-05-04 17:07:01 +01:00
João Matos fd5f1c73e0 [runtime] Improve readability on nested preprocessor defines. 2015-05-04 17:07:01 +01:00
João Matos 8689dc1796 [runtime] Move x86_64 offsets next to the x86 ones. 2015-05-04 17:07:01 +01:00
Marek Safar 0c5e53feec [mcs] Report better error for assignment to readonly properties hiding type name 2015-05-04 17:34:44 +02:00
Marcos Henrich 2c4b3b7f00 [corlib] Fixes DST without AdjustmentRules.
Fixes IsDaylightSavingTime returning false when
SupportsDaylightSavingTime was set to false because TimeZoneInfo was
create with no AdjustmentRules.

Now if TimeZoneInfo uses transitions SupportsDaylightSavingTime will be
set to true regardless of AdjustmentRules.
2015-05-04 15:43:51 +01:00
Marek Safar 99a5ed9399 [corlib] Bump security reference sources 2015-05-04 16:18:29 +02:00
João Matos a2d74adc0e [runtime] Fixed LLVM Windows cross-compilation.
This configuration was broken with https://github.com/mono/mono/commit/4a20119029a0ba36866be8575909085c3742e85b.

Manifested as the following error:
```configure: error: LLVM executable /Users/builder/data/lanes/1196/47be2825/source/monodroid/builds/cross/windows-llvm/usr/bin/llvm-config not found.```
2015-05-04 14:58:49 +01:00
Marcos Henrich ac290a48b7 Merge pull request #1752 from esdrubal/strefactor
[corlib] Deduplicated StackTrace ToString code.
2015-05-04 14:37:25 +01:00
Zoltan Varga c314f9cb4a [jit] Remove the changes to mono-codeman in 62d46b469b, they are not needed anymore with the new approach for handling thunks. 2015-05-04 03:53:35 -04:00
Zoltan Varga 8f04680fc2 [arm] Fix the build. 2015-05-03 19:22:39 -04:00
Zoltan Varga 9df344c69d [x86] Fix the build. 2015-05-03 16:27:12 -04:00
Zoltan Varga a000d0f8f0 Merge pull request #1765 from akoeplinger/fix-sgen-independence-win
[sgen] Fix Windows build
2015-05-03 16:21:42 -04:00
Alexander Köplinger 4306a97a46 [sgen] Fix Windows build
There were some changes in the recent sgen overhaul (https://github.com/mono/mono/pull/1648) that weren't applied to Windows.
2015-05-03 11:42:19 -07:00
Alex Rønne Petersen ac4cf68d87 Merge pull request #1763 from JetBrains/empty_appdomainsetup_configurationfile
Do not fail on empty or too short AppDomainSetup.ConfigurationFile
2015-05-03 15:17:28 +02:00
Zoltan Varga 7e8b4615ee [arm] Implement the mono_arch_patch_code_new () function. 2015-05-03 06:03:31 -04:00
Zoltan Varga 71939f2a05 [x86] Implement the mono_arch_patch_code_new () function. 2015-05-03 05:58:46 -04:00
Zoltan Varga 55e7b84ef3 [jit] Add a new version of the mono_arch_patch_code () function to reduce code duplication between backends. 2015-05-03 05:48:03 -04:00
Zoltan Varga 952fca344e [jit] Remove unused 'dyn_code_mp' argument from mono_arch_patch_code (). 2015-05-03 04:56:52 -04:00
Zoltan Varga de0ae52bc5 [arm] Fix the build. 2015-05-03 02:55:07 -04:00
Zoltan Varga 1f1ec58dcf [arm] Remove some obsolete comments and code. Emit thunks while holding the lock. 2015-05-03 02:48:35 -04:00
Zoltan Varga fe572840a8 [arm] Refactor handle_thunk () to avoid locking and O(n^2) searches during JITting. 2015-05-03 02:02:12 -04:00
Zoltan Varga e73aa80ac3 [arm] Use the thunks area emitted next to method code for resolving thunks, remove the older code which was searching for thunks inside codeman chunks. 2015-05-03 01:33:58 -04:00
Zoltan Varga a129e46fa6 [jit] Pass a MonoCompile argument to mono_arch_patch_code () so it can access the thunks area during JITting. 2015-05-02 23:24:34 -04:00
Zoltan Varga 67bad2fae3 [arm] Use the thunks area after the method code to resolve thunks. 2015-05-02 23:01:54 -04:00
Zoltan Varga 31ff0c0965 [runtime] Add some missing icalls referenced by the reference sources. 2015-05-02 21:26:53 -04:00
Zoltan Varga ea8a04f0c3 [sdb] Fix saving the state in the debugger_agent_breakpoint_from_context () function. 2015-05-02 21:13:24 -04:00
Zoltan Varga f3115c6b62 [arm] Transition the arm backend to use the mini_get_single_step_trampoline()/mini_get_breakpoint_trampoline() functions when using soft breakpoints. 2015-05-02 21:13:24 -04:00
Leonid Shalupov c34ad2beb3 Do not fail on empty or too short AppDomainSetup.ConfigurationFile 2015-05-02 21:23:01 +02:00
Zoltan Varga 4ed1355c1d Merge pull request #1762 from Mailaender/patch-1
Fixed FSF postal address in legacy license
2015-05-02 04:54:14 -04:00
Matthias Mailänder 9e916f54f2 Update COPYING.LIB
from https://www.gnu.org/licenses/old-licenses/lgpl-2.0.txt
2015-05-02 10:24:00 +02:00
Zoltan Varga 3db3fa41d5 [jit] Fix the DISABLE_JIT build. 2015-05-02 02:00:47 -04:00
Zoltan Varga 9b282cbe0d [runtime] Fix the cross compiler build. 2015-05-02 01:02:36 -04:00
Mark Probst e0fd6bdb42 Merge pull request #1760 from evincarofautumn/object-provenances
[sgen] Record object provenances in binary protocol.
2015-05-01 16:29:51 -07:00
Jon Purdy c09bb74207 [sgen] Record object provenances in binary protocol. 2015-05-01 15:37:51 -07:00
Jon Purdy 55a95fc2db [tools] Add help message to sgen-grep-binprot. 2015-05-01 15:27:58 -07:00
Jon Purdy 3b0df7898b [tools] Support Booleans in sgen-grep-binprot. 2015-05-01 13:35:57 -07:00
Ludovic Henry 0b2cd8e035 [runtime] Ensure mono-rand is opened once and only once 2015-05-01 20:58:26 +01:00
Ludovic Henry b1d0f42e1c [threadpool] Refactor begin/end invoke runtime support 2015-05-01 20:56:32 +01:00
Zoltan Varga bd27ef859f [jit] Put back some code removed by d2e184bbf7 by mistake. 2015-05-01 15:45:41 -04:00
Zoltan Varga d2e184bbf7 [jit] Allocate the thunks area next to the method code if the backend can compute its exact size (by setting cfg->thunk_area). Store it in MonoJitInfo so the backend patching code can access it. 2015-05-01 15:44:10 -04:00
Mark Probst 9de07d8eb4 [sgen] Fix heavy binary protocol. 2015-05-01 10:36:40 -07:00
Atsushi Eno f7672d6b4b [WCF] partially revert ServiceModel.Internals InternalsVisibleTo. 2015-05-02 00:08:01 +09:00
Atsushi Eno a6a2877b63 [DurableInstancing] add a handful of [InternalsVisibleTo]s. 2015-05-01 22:28:44 +09:00
Atsushi Eno ae62ea8229 [S.R.Serialization] fix some [InternalsVisibleTo]s. 2015-05-01 22:27:04 +09:00
Atsushi Eno 3f87ade7f0 [DurableInstancing] forgot to add SRCore.cs 2015-05-01 16:02:14 +09:00
Atsushi Eno fd03dbc3bd System.Runtime.DurableInstancing switches to referencesource with revised deps.
This dll has been nothing but stub. The new dll just builds, unverified.
2015-05-01 15:58:16 +09:00
Atsushi Eno cdbf324ac0 add InternalsVisibleTo(DurableInstancing) in ServiceModel.Internals. 2015-05-01 15:50:41 +09:00
Zoltan Varga a30442a7de [jit] Merge regalloc.c into mini-codegen.c. 2015-05-01 01:33:00 -04:00
Zoltan Varga 1038b9de3f [jit] Print out floating point arguments as well in mono_print_ins_index (). 2015-05-01 01:31:19 -04:00
Zoltan Varga 2e5f43d8f7 Revert "[jit] Remove unused regalloc.c file."
This reverts commit 6c17420f98.

Revert this, the file is still used.
2015-05-01 01:29:06 -04:00
Zoltan Varga 5fd256b6e1 [runtime] Remove unused wrapper dir. 2015-05-01 01:24:40 -04:00
Zoltan Varga 6c17420f98 [jit] Remove unused regalloc.c file. 2015-05-01 01:16:55 -04:00
Zoltan Varga f696525f99 [runtime] Remove --wapi option which depends on the unsupported shared handle support. 2015-05-01 01:12:31 -04:00
Zoltan Varga af19ddf4e6 [jit] Remove unmaintained ssapre.c/h file. 2015-05-01 01:07:44 -04:00
Alexander Köplinger d9e2643529 [xbuild] Add missing files to EXTRA_DISTFILES to fix tarball 2015-05-01 04:59:35 +02:00
Zoltan Varga 3469c138c6 [arm] Reorganize the argument passing code, implement support for HFA arguments on armhf. 2015-04-30 18:36:19 -04:00
Alex Rønne Petersen 4a084041be Merge pull request #1753 from schani/feature-yet-more-sgen-improvements
Yet more SGen improvements
2015-04-30 23:07:11 +02:00
Marek Safar 52d9079213 [corlib] Add legacy mobile apis 2015-04-30 15:02:24 +02:00
João Matos 731e2fa6aa [tools] Added the beginnings of a static analysis checking tool for Mono.
This is still a big work-in-progress and not ready to be tested. It might be used in the future for custom AST static analysis of Mono source code.
2015-04-30 13:43:47 +01:00
Alex Rønne Petersen 2fa7ee3fba Revert "[runtime] Introduce versioning of the profiler API."
This reverts commit 138ae5a07f.

After some discussion, I don't think this adds as much value as I
initially thought it would.
2015-04-30 10:50:56 +02:00
Zoltan Varga cde500b508 Merge pull request #1754 from aaronhoffman/nunmber
Fix spelling of number in IOException message
2015-04-30 01:48:37 -04:00
Aaron Hoffman 641f55922f Fix spelling of number in IOException message 2015-04-29 23:18:26 -05:00
Zoltan Varga 2538b0db0a [arm] Use the generic method for passing the IMT argument on ARM. 2015-04-29 21:36:13 -04:00
Alexander Köplinger ffdbf77f41 [System.Runtime.Serialization] Fix "make distcheck"
These files were missing from the tarball.
2015-04-30 00:24:36 +02:00
Mark Probst 0f331fe685 [sgen] Add the stopping thread to the world stopping protocol entry. 2015-04-29 14:54:15 -07:00
Mark Probst da5ebd148f [sgen] Binary protocol entry for stack scanning. 2015-04-29 14:54:15 -07:00
Mark Probst 7560e670ac [sgen] SGEN_UPDATE_REFERENCE was used where it shouldn't be.
This has no implications other than for debugging.
2015-04-29 14:54:14 -07:00
Mark Probst f25348e789 [sgen] For object copies, check whether we can use memmove in the wbarrier. 2015-04-29 14:54:13 -07:00
Mark Probst a2013d84fb [sgen] Make mono_gc_scan_for_specific_ref() also scan thread stacks. 2015-04-29 14:54:08 -07:00
Marek Safar a1a73366db [corlib] Bump reference sources for api tweaks 2015-04-29 22:16:02 +02:00
Mark Probst 4cc3516463 Merge pull request #1648 from schani/sgen-independence
SGen Independence
2015-04-29 10:59:27 -07:00
Mark Probst df66a41d10 [sgen] Always invoke the world restarting protocol call. Fixes heapshot. 2015-04-29 11:00:14 -07:00
Mark Probst b51b7f5ac8 [sgen] Fix warnings on Linux. 2015-04-29 11:00:13 -07:00
Mark Probst 48efb8bf0d [sgen] Missing include for independent compilation. 2015-04-29 11:00:13 -07:00
Mark Probst 5870113e5b [sgen] Fix warnings. 2015-04-29 11:00:12 -07:00
Mark Probst f2a6b675f4 [sgen] Write barrier prototypes in sgen-gc.h. 2015-04-29 11:00:12 -07:00
Mark Probst 26c3a4b377 [sgen] Fix headers for independent compilation. 2015-04-29 11:00:12 -07:00
Mark Probst 977783a344 [sgen] Client debug function for checking whether class is inited. 2015-04-29 11:00:11 -07:00
Mark Probst 561dfc35a0 [sgen] SGEN_TV_ELAPSED returns a long. 2015-04-29 11:00:11 -07:00
Mark Probst ebdb3a608d [sgen] Remove dead code and data and make things static. 2015-04-29 11:00:10 -07:00
Mark Probst 5fc000b22f [sgen] More client interface documentation. 2015-04-29 11:00:10 -07:00
Mark Probst dca2b68be9 [sgen] Call mono_gc_register_thread() from Mono client code. 2015-04-29 11:00:09 -07:00
Mark Probst 8c0cbd6e00 [sgen] Make hazard pointer stuff work without Mono, enabling concurrent M&S. 2015-04-29 11:00:09 -07:00
Mark Probst 3df7a2f569 [sgen] Get rid of sgen_client_vtable_has_references(). 2015-04-29 11:00:08 -07:00
Mark Probst 1abd023390 [sgen] Document the client interface header a bit. 2015-04-29 11:00:08 -07:00
Mark Probst 2b3948572e [sgen] Don't use sgen_client_vtable_get_namespace() to check an object's validity.
Some clients might not have namespaces, so they might return NULL.
2015-04-29 11:00:08 -07:00
Mark Probst 67c74d10cf [sgen] Don't return a pointer from the out-of-memory function.
The pointer the function would have to return would be to a chunk of managed
memory, for the object to be allocated.  It can't do that because it is not in charge
of the managed heap.  The best it could do would be to free some unmanaged
memory and tell the allocator try again.
2015-04-29 11:00:07 -07:00
Mark Probst 80b5c9cdc3 [sgen] Rename the total heap size reporting client function, and pass size as size_t. 2015-04-29 11:00:07 -07:00
Mark Probst 5df196bc68 [sgen] Get rid of sgen_client_object_register_finalizer_if_necessary(). 2015-04-29 11:00:06 -07:00
Mark Probst 3cbd4eca69 [sgen] Get rid of sgen_client_object_is_array_fill(). 2015-04-29 11:00:06 -07:00
Mark Probst c7d3126752 [sgen] Get rid of sgen_client_vtable_get_instance_size(). 2015-04-29 11:00:05 -07:00
Mark Probst f74eca0ce4 [sgen] Put sgen_thread_attach() in Mono client code. 2015-04-29 11:00:05 -07:00
Mark Probst f03cfdb821 [sgen] Don't return unused thread count from stop/start world functions. 2015-04-29 11:00:04 -07:00
Mark Probst 3788fa3f46 [sgen] Remove sgen_client_object_safe_name(). 2015-04-29 11:00:04 -07:00
Mark Probst 32f0e158e6 [sgen] Move POSIX STW thread info stuff to Mono client code. 2015-04-29 11:00:04 -07:00
Mark Probst 74a0b66364 [sgen] Move global stop count variable to Mono client code. 2015-04-29 11:00:03 -07:00
Mark Probst 4a34b1695b [sgen] Fix warnings and remove dead code. 2015-04-29 11:00:03 -07:00
Mark Probst 8c114356ec [sgen] Make client header file name configurable. 2015-04-29 11:00:03 -07:00
Mark Probst 227fe4a7cc [sgen] Make SGen compile without Mono. 2015-04-29 11:00:02 -07:00
Mark Probst 7d7917102f [sgen] Use consistent include paths. 2015-04-29 11:00:02 -07:00
Mark Probst 483ffe64b8 [sgen] Add missing headers for compiling with glib. 2015-04-29 11:00:02 -07:00
Mark Probst 065f6e1068 [sgen] Add a few missing returns when compiling with glib.
`g_error()` isn't marked as not returning in glib.
2015-04-29 11:00:01 -07:00
Mark Probst f99940ca83 [sgen] Get rid of MonoObject and MonoVTable in sgen-debug.c. 2015-04-29 11:00:01 -07:00
Mark Probst 0b4cc9b05e [sgen] sgen_os_init() must be called from Mono client code. 2015-04-29 11:00:01 -07:00
Mark Probst 05fe3f182c [sgen] Client function for registering worker threads. 2015-04-29 11:00:01 -07:00
Mark Probst 030dd8bea8 [sgen] We can't have negative numbers in gc-parse.c.
`size_t` is non-negative.  We catch overflow by checking that shifting right
again produces the original unshifted value.
2015-04-29 11:00:00 -07:00
Mark Probst 09462f7711 [sgen] Do pinning stats based on vtable, not class.
We need to get rid of MonoClass in SGen.
2015-04-29 11:00:00 -07:00
Mark Probst 9741a8e8f7 [sgen] Declare time spans in GGTimingInfo as gint64.
We use `SGEN_TV_DECLARE` for instants of time, not time spans.
2015-04-29 11:00:00 -07:00
Mark Probst 59b51bea0a [sgen] Remove dead code. 2015-04-29 11:00:00 -07:00
Mark Probst 831a8db00b [sgen] Move Mono specific function declarations to sgen-client-mono.h. 2015-04-29 10:59:53 -07:00
Mark Probst 18ecc132c3 [sgen] Do domain-specific finalizer and weak link stuff via predicate callbacks. 2015-04-29 10:59:53 -07:00
Mark Probst 8350ade75f [sgen] Handle no-managed-allocator debug option in Mono client code. 2015-04-29 10:59:53 -07:00
Mark Probst b4f31d0ec6 [sgen] We used the wrong unmask function in sgen-nursery-allocator.c. 2015-04-29 10:59:52 -07:00
Mark Probst d12908781c [sgen] Don't use MonoObject. 2015-04-29 10:59:52 -07:00
Mark Probst 1f7a9b353a [sgen] Move thread info to Mono client code. 2015-04-29 10:59:51 -07:00
Mark Probst 85791ba0ad [sgen] Update mono_perfcounters in Mono client code. 2015-04-29 10:59:51 -07:00
Mark Probst 0636b33979 [sgen] Don't use mono_bool in SGen. 2015-04-29 10:59:51 -07:00
Mark Probst e54c2c4222 [sgen] Have our own aligned address hash function.
Just to get rid of a dependency.
2015-04-29 10:59:50 -07:00
Mark Probst 721d6a6d58 [sgen] Client function sgen_client_vtable_get_instance_size(). 2015-04-29 10:59:50 -07:00
Mark Probst 4df739b9ec [sgen] mono_gc_register_thread() is not Mono specific. 2015-04-29 10:59:49 -07:00
Mark Probst 3d845c71d6 [runtime] Make a variable static. 2015-04-29 10:59:49 -07:00
Mark Probst e4a6b70ab1 [sgen] Remove dependency on gc-internal.h. 2015-04-29 10:59:49 -07:00
Mark Probst 15cf9affa6 [sgen] Make bridge processing a client issue. 2015-04-29 10:59:49 -07:00
Mark Probst ba590456b3 [sgen] Semaphore type defined in client code.
`mono-semaphore.h` depends on io-layer, which we can't expect
anybody to include.
2015-04-29 10:59:48 -07:00
Mark Probst 8ddb33b334 [sgen] sgen-archdep.h is now Mono-specific. 2015-04-29 10:59:48 -07:00
Mark Probst e87255714c [sgen] Remove dependency on mono-gc.h. 2015-04-29 10:59:48 -07:00
Mark Probst 899288fd57 [sgen] Remove superfluous include. 2015-04-29 10:59:47 -07:00
Mark Probst 46045aa5fe [sgen] Move time stuff to client code. 2015-04-29 10:59:47 -07:00
Mark Probst c8f668ab2d [sgen] Move virtual memory allocation to client code. 2015-04-29 10:59:47 -07:00
Mark Probst 864d7b6512 [sgen] Move gc_callbacks to Mono client code. 2015-04-29 10:59:47 -07:00
Mark Probst 21ab98f5bb [sgen] Move runtime_data to Mono client code. 2015-04-29 10:59:46 -07:00
Mark Probst a93d2e8013 [sgen] Move thread context to Mono client code. 2015-04-29 10:59:46 -07:00
Mark Probst 9e7604ce5f [sgen] Move stack limits to client code. 2015-04-29 10:59:46 -07:00
Mark Probst 19b39c42ea [sgen] Move gc_disabled to Mono-specific code. 2015-04-29 10:57:55 -07:00
Mark Probst 9740cde073 [sgen] Move skip and in_critical_region to Mono-specific code. 2015-04-29 10:57:54 -07:00
Mark Probst 22774f38d5 [sgen] Move stack scanning to client code. 2015-04-29 10:57:54 -07:00
Mark Probst 7becb7c5d4 [sgen] Moved stopped_ip and stopped_domain to Mono-specific code. 2015-04-29 10:57:54 -07:00
Mark Probst 30efae36e7 [sgen] Move MonoThreadInfo part of SgenThreadInfo to client code. 2015-04-29 10:57:54 -07:00
Mark Probst 05eb967348 [sgen] Move remaining logging to Mono-specific code. 2015-04-29 10:57:53 -07:00
Mark Probst 5f33085d65 [sgen] Move counters to client code. 2015-04-29 10:57:53 -07:00
Mark Probst bb22ad20a7 [sgen] Move all profiler calls to Mono-specific code. 2015-04-29 10:57:53 -07:00
Mark Probst 60afcfb4af [sgen] Move DTrace stuff into the client header.
This should always be inlined.  We also need this there because we'll put the
profiler calls there.

This introduces fickle dependencies in the order of which things are declared
and inlined.  It would be nice to have a cleaner solution.
2015-04-29 10:57:52 -07:00
Mark Probst 22b6f62f4a [sgen] Use pointer array for pin stats instead of linked list. 2015-04-29 10:57:52 -07:00
Mark Probst 7b8d065369 [sgen] Move moved-object profiler event to Mono-specific code. 2015-04-29 10:57:52 -07:00
Mark Probst e1129cae4c [sgen] Make STW part of the client code. 2015-04-29 10:57:52 -07:00
Mark Probst 4c43884a59 [sgen] Move DTrace support to Mono-specific code.
We use client callbacks from the binary protocol functions.  There are some DTrace probes
which we don't have binary protocol entries for.  Since DTrace isn't properly supported
anyway (and doesn't even work as it should on OSX), we just remove those probes instead
of making new binary protocol entries.
2015-04-29 10:57:51 -07:00
Mark Probst aade9dde44 [sgen] Remove dead declaration. 2015-04-29 10:57:51 -07:00
Mark Probst 7366ebf5bb [sgen] Move nursery debug code to sgen-debug.c. 2015-04-29 10:57:51 -07:00
Mark Probst d6d516dfe0 [sgen] Remove unnecessary includes. 2015-04-29 10:57:50 -07:00
Mark Probst a0646d4701 [sgen] Move some thread stuff to sgen-mono.c. 2015-04-29 10:57:50 -07:00
Mark Probst 225938bb3b [sgen] Move more random small stuff to sgen-mono.c. 2015-04-29 10:57:50 -07:00
Mark Probst d3af0a6fae [sgen] Move managed write barrier to sgen-mono.c. 2015-04-29 10:57:50 -07:00
Mark Probst c4ba94ec01 [sgen] Use macro for object header and minimum object size. 2015-04-29 10:57:49 -07:00
Mark Probst 986f2727a6 [sgen] Move some small callbacks to sgen-mono.c. 2015-04-29 10:57:49 -07:00
Mark Probst ab4449d923 [sgen] Move heap walking into sgen-mono.c. 2015-04-29 10:57:49 -07:00
Mark Probst b575835001 [sgen] Move array fill object check into client code. 2015-04-29 10:57:49 -07:00
Mark Probst 9b5f45fdfe [sgen] Omit unnecessary casts. 2015-04-29 10:57:48 -07:00
Mark Probst 758beb893b [sgen] Typedef GCObject and GCVTable to MonoObject and MonoVTable. 2015-04-29 10:57:48 -07:00
Mark Probst 16524f73f2 [sgen] Move GCObject and GCVTable to client code. 2015-04-29 10:57:48 -07:00
Mark Probst 2b655519c0 [sgen] GCObject and GCVTable instead of MonoObject and MonoVTable. 2015-04-29 10:57:48 -07:00
Mark Probst 7240b497bb [sgen] Move root profiling to sgen-mono.c. 2015-04-29 10:57:47 -07:00
Mark Probst cbb012e983 [sgen] Use pointer queue instead of list for finalize ready objects. 2015-04-29 10:57:47 -07:00
Mark Probst 8bf4f09152 [sgen] Move sgen_safe_name() to client code. 2015-04-29 10:57:47 -07:00
Mark Probst 6c7c2f3071 [sgen] Use write barrier for fields to set array references.
They do the same thing.
2015-04-29 10:57:46 -07:00
Mark Probst d6f7bb62ad [sgen] Moved object size calculation to client code. 2015-04-29 10:57:46 -07:00
Mark Probst 44a9f512e1 [sgen] Move mono_gc_set_string_length() to sgen-mono.c. 2015-04-29 10:57:46 -07:00
Mark Probst d55cab8d55 [sgen] Move array and string allocation to client code. 2015-04-29 10:57:46 -07:00
Mark Probst 876371ebc1 [sgen] Move some array filling stuff into client code. 2015-04-29 10:57:45 -07:00
Mark Probst a376fbcd47 [sgen] Moved Mono-specific cardtable scanning to client code. 2015-04-29 10:57:45 -07:00
Mark Probst e35fe7beaa [sgen] Trivial prettification of sgen-mono.c. 2015-04-29 10:57:45 -07:00
Mark Probst 20eacf086b [sgen] Move TLS emit macros to Mono-specific file. 2015-04-29 10:57:45 -07:00
Mark Probst 04c0445095 [sgen] Make wbarrier_value_copy take the element size, not the class. 2015-04-29 10:57:44 -07:00
Mark Probst c000cc895a [sgen] Move managed allocator to Mono-specific code. 2015-04-29 10:57:44 -07:00
Mark Probst 690e499e3c [sgen] Move has_critical_finalizer() to client code. 2015-04-29 10:57:44 -07:00
Mark Probst dabdc5f3ff [sgen] Move array filling into client code. 2015-04-29 10:57:44 -07:00
Mark Probst 5b1d55ca3a [sgen] Move domain clearing into client code. 2015-04-29 10:57:43 -07:00
Mark Probst 6d8a48f7b9 [sgen] Move ephemerons to client code. 2015-04-29 10:57:43 -07:00
Mark Probst cc43ac1923 [sgen] Move some support functions into sgen-gc.h. 2015-04-29 10:57:43 -07:00
Mark Probst 69f776dc18 [sgen] Move finalization callback stuff to sgen-mono.c.
Also introduce `sgen-client.h` which will eventually contain a spec of the
interface a client of SGen has to implement.
2015-04-29 10:57:43 -07:00
Mark Probst ef4606f5c4 [sgen] Move Mono-specific wbarriers to sgen-mono.c. 2015-04-29 10:57:42 -07:00
Mark Probst 08605a5af3 [sgen] Add FIXME about pinning statistics. 2015-04-29 10:57:42 -07:00
Mark Probst aae49e3fc3 [sgen] Move heap dumping code into sgen-debug.c. 2015-04-29 10:57:42 -07:00
Mark Probst 8dbd690773 [sgen] Move do_pin_stats flag into sgen-pinning-stats.c. 2015-04-29 10:57:42 -07:00
Marcos Henrich 92d14c71c1 [corlib] Deduplicated StackTrace ToString code.
StackStrace.ToString logic was duplicated in System.Exception and
System.Diagnostics.StackTrace.

Exception.StackTrace output was not changed.

StackTrace.ToString's method signature was changed, it is now the same
as Exception.StackTrace, which is more similar to the .NET one. This
affects generics and ref parameters representation.
2015-04-29 16:00:56 +01:00
Rolf Bjarne Kvinge 52a8a9b92d Merge pull request #1748 from rolfbjarne/proclib-fix
[runtime] Don't call mach_port_deallocate on tasks we don't own.
2015-04-29 16:13:49 +02:00
Rolf Bjarne Kvinge 810db09874 [runtime] Don't call mach_port_deallocate on tasks we don't own.
Fixes random/strange hangs/crashes (many native API starts returning
out-of-memory errors when there is plenty of memory available, other
just hang inexplicably) when profiling.
2015-04-29 15:44:48 +02:00
Marek Safar bef9e67deb [corlib] Fixes security tests failures 2015-04-29 13:41:26 +02:00
Zoltan Varga 631a2591ad [jit] Remove #ifdef MONO_ARCH_VTABLE_REG, it is defined on all architectures. 2015-04-29 05:17:10 -04:00
Alexander Köplinger 884675574a [build] Fix "make dist"
A few files didn't get added to EXTRA_DIST when the MS threadpool code was introduced.
2015-04-29 07:08:05 +02:00
Mark Probst 23372959cf [sgen] Check SP on thread suspend correctly. Fixes #29177. 2015-04-28 15:05:11 -07:00
Alex Rønne Petersen c4fba88384 Merge pull request #1747 from alexrp/gc-internal-api
Remove MONO_API from some internal GC APIs
2015-04-28 19:38:51 +02:00
Marek Safar dd3a5900b9 [corlib] Add new test 2015-04-28 19:33:41 +02:00
Marek Safar 11ecdc6b6f [corlib] More cryptography from reference sources 2015-04-28 19:05:32 +02:00
Marcos Henrich a27db5252f Merge pull request #1696 from esdrubal/tzrefactor
TimeZone Refactoring.
2015-04-28 16:36:08 +01:00
João Matos a8747582f3 [runtime] Move mono_error_assert_ok to mono-error-internals.h.
I originally introduced it as a public API but after some discussion we decided it's best as a private API.
2015-04-28 15:58:10 +01:00
Marek Safar 7697bc86fd [corlib] More cryptography from reference sources 2015-04-28 13:38:15 +02:00
Alex Rønne Petersen 456294d907 Merge pull request #1734 from anikilatorbeta/patch-1
Upadate socket and add OSSupportsIPv4 in net 4.0
2015-04-28 10:45:40 +02:00
Alex Rønne Petersen e6c1b789fa Remove MONO_API from some internal GC APIs. 2015-04-28 03:26:24 +02:00
Mark Probst 92e3c59575 [sgen] Fix a card table bug on 64 bits.
When copying value types (like via Array.Copy) it was possible to
encounter a memory region going over the end of the card table array.
In that case we would overwrite data after the card table and fail
to mark cards at the start of the array.

It's hard to do a test case for this because we allocate the shadow card
table directly after the regular one, so the overwrite is benign.  It would
also require allocating very large arrays (>2Gb) and run very slowly.
2015-04-27 17:42:54 -07:00
Alex Rønne Petersen a4ee723a80 Merge pull request #1745 from alexrp/warning-police
Warning police
2015-04-28 02:18:40 +02:00
Rodrigo Kumpera 1dec57e9ee Merge pull request #1743 from alexrp/profiler-versioning
Introduce versioning of the profiler API
2015-04-27 15:25:06 -04:00
Marek Safar d86dc4c41a [system.xml] Fix public api 2015-04-27 20:06:46 +02:00
Marek Safar 7f7b366d68 [build] Fix bootstrap from 2.0 only era mono 2015-04-27 19:04:20 +02:00
Marek Safar 08d0e5a283 [build] Remove 2.0 sdk from monolite when we are 4.0 only 2015-04-27 18:18:28 +02:00
João Matos ef6cf49fd9 Introduce mono_error_assert_ok for checking and asserting that a MonoError is OK.
We're adding this new API call to replace the `g_assert (mono_error_ok (&error));` code pattern so that when there's an error we can print the error message from the MonoError.
2015-04-27 17:10:28 +01:00
Marek Safar 1396b52d96 [corlib] Implement monomethod Module property 2015-04-27 17:24:33 +02:00
Marek Safar db4e52816c [corlib] Add string CompareOrdinal arguments checks 2015-04-27 16:29:27 +02:00
Alex Rønne Petersen 3f992da422 [utils] Fix a bad format specifier. 2015-04-27 16:18:51 +02:00
Alex Rønne Petersen c4d2938593 [mini] Fix some warnings related to co-op suspend code. 2015-04-27 16:18:26 +02:00
Alex Rønne Petersen 1a89e6364b [runtime] Remove some unused functions. 2015-04-27 16:18:11 +02:00
Alex Rønne Petersen 88e0e21979 [threadpool] Fix some prototypes in the MS thread pool code. 2015-04-27 16:17:38 +02:00
Alex Rønne Petersen a9a0721773 [sgen] Add missing return in thread pool's thread_func (). 2015-04-27 16:17:06 +02:00
Marcos Henrich 6d5579d3b8 Merge pull request #1738 from rolfbjarne/dublin-1916-dst
[corlib] Cope with the reference sources' inability to support sub-minute DST offsets
2015-04-27 12:15:25 +01:00
Rolf Bjarne Kvinge 4c206074a7 [corlib] Cope with the reference sources' inability to support sub-minute DST offsets.
The reference sources do not support sub-minute DST offsets as the exception below
shows, while Europe/Dublin has a DST offset of 34:39 in 1916.

There is no equivalent TimeZoneInfo for Europe/Dublin in .NET, so the problem
doesn't show up there.

System.ArgumentException: The TimeSpan parameter cannot be specified more precisely than whole minutes.
	Parameter name: daylightDelta

  at System.TimeZoneInfo/AdjustmentRule.ValidateAdjustmentRule (System.DateTime,System.DateTime,System.TimeSpan,System.TimeZoneInfo/TransitionTime,System.TimeZoneInfo/TransitionTime) [0x0012c] in /work/mono/master/external/referencesource/mscorlib/system/timezoneinfo.cs:3907
  at System.TimeZoneInfo/AdjustmentRule.CreateAdjustmentRule (System.DateTime,System.DateTime,System.TimeSpan,System.TimeZoneInfo/TransitionTime,System.TimeZoneInfo/TransitionTime) [0x00000] in /work/mono/master/external/referencesource/mscorlib/system/timezoneinfo.cs:3836
  at System.TimeZoneInfo.ParseTZBuffer (string,byte[],int) [0x002ca] in /work/mono/master/mcs/class/corlib/System/TimeZoneInfo.cs:1230
  at System.TimeZoneInfo.BuildFromStream (string,System.IO.Stream) [0x00030] in /work/mono/master/mcs/class/corlib/System/TimeZoneInfo.cs:479
  at System.TimeZoneInfo.FindSystemTimeZoneByFileName (string,string) [0x00018] in /work/mono/master/mcs/class/corlib/System/TimeZoneInfo.cs:463
  at System.TimeZoneInfo.FindSystemTimeZoneById (string) [0x00075] in /work/mono/master/mcs/class/corlib/System/TimeZoneInfo.cs:450
  at MonoTests.System.TimeZoneInfoTest/FindSystemTimeZoneByIdTests.Dublin () [0x00015] in /work/mono/master/mcs/class/corlib/Test/System/TimeZoneInfoTest.cs:812
2015-04-27 12:28:40 +02:00
Alex Rønne Petersen 138ae5a07f [runtime] Introduce versioning of the profiler API.
The profiler API needs to evolve with the runtime. By versioning the API we can
at least to some degree let developers know when their modules are out of date
and how to update them.
2015-04-27 07:59:07 +02:00
Zoltan Varga 1a599e241b [aot] Refactor some of the architecture specific functions a little. 2015-04-25 01:10:20 -04:00
Zoltan Varga 98d2528e22 Fix a warning. 2015-04-24 21:44:41 -04:00
Rodrigo Kumpera 4a20119029 [configure] Another attempt at fixing windows cross compilers. 2015-04-24 18:28:36 -04:00
Alex Rønne Petersen 715e6b9ec6 [mini] Remove now-unused InternalSetChar intrinsic. 2015-04-24 23:51:01 +02:00
Alex Rønne Petersen d55dc024fd [mini] Fix intrinsic signature checks to take into account the 'this' parameter. 2015-04-24 23:50:34 +02:00
Mark Probst a6c73d8a56 [sgen] Document a shutdown sequence bug. 2015-04-24 11:21:13 -07:00
Atsushi Eno b839d14fed Merge pull request #1736 from atsushieno/import-wcf
Import System.Runtime.Serialization from referencesource.
2015-04-24 23:53:38 +09:00
Rolf Bjarne Kvinge f0e27b34c6 Include the problematic time zone in the exception message when throwing a TimeZoneNotFoundException. 2015-04-24 12:53:25 +02:00
Atsushi Eno 537fb5cea1 [Sys.Data] fix SqlParameter SystemType lookup after referencesource merge.
This should fix bug #29078, patch by Neale Ferguson.
2015-04-24 15:49:44 +09:00
Atsushi Eno 0fa576b6d3 [S.R.Serialization] fix mobile static build. 2015-04-24 15:08:24 +09:00
Atsushi Eno b3c9247df6 Merge branch 'master' into import-wcf 2015-04-24 15:08:18 +09:00
Atsushi Eno 8556e610a9 bump referencesource for S.R.Serialization import. 2015-04-24 15:07:20 +09:00
Atsushi Eno ad06a4d80a [S.R.Serialization] fill message strings. 2015-04-24 14:37:00 +09:00
Atsushi Eno 09ed3155fa [WCF] disable not working announcement client test.
WS-Discovery never got working, skip cosmetic test to not block porting.
2015-04-24 14:37:00 +09:00
Atsushi Eno c9b71ae6c4 Add System.ServiceModel.Internals and SMDiagnostics to the build. 2015-04-24 14:36:59 +09:00
Atsushi Eno c0451031c6 [WCF] similar to Binary writer fixes, do not close Text writer.
Just like BinaryMessageFormatter needed to use another CreateBinaryWriter()
overload to NOT close the input stream, use CreateTextWriter() overload that
does not close the stream.
2015-04-24 14:36:59 +09:00
Atsushi Eno b58f0e8232 [WCF] fix JSON deserialization test that didn't match .NET behavior.
JSON array is deserialized as Array, not List<T>.
2015-04-24 14:36:59 +09:00
Atsushi Eno 4fab0ddf50 [WCF] fix syndication extension Add() resolution by appropriate accessibility.
I wonder why, but when switched to referencesource, it turned out that
ResourceCollectionInfo calls SyndicationElementExtensionCollection.Add()
which targets a private overload, but (of course) failed and resolved to
another overload that takes object, and thus resulting in invalid code path.

With this fix the call to Add() resolves to the expected one and does not
regress with referencesource import.
2015-04-24 14:36:59 +09:00
Atsushi Eno 365abf5ee5 [WCF] fixed a couple of DateTime related tests that also failed on .NET IN JST.
Those tests were added without considering TimeZone difference. They cause
several kind of errors (SerializationException etc.) in JST (+09:00) or any
timezone that is earlier than UTC.

We likely had some "working" implementation, but was incompatible with .NET.
2015-04-24 14:36:58 +09:00
Atsushi Eno daa2f0b4f5 [WCF] mark JsonReader tests that proves referencesource bugs as [Ignore]d.
.NET WCF JSON serializer has been known to be buggy...
2015-04-24 14:36:58 +09:00
Atsushi Eno d2cdee078d [WCF] XmlReader from GetReaderAtBodyContents() should not be missing xmlns-es.
The namespace declarations existed when the entire Message is read but not
in the partial body contents. They caused regressions when we use
serialization stack from referencesource.

It is possible that more namespaces may be requied, but we will be importing
System.ServiceModel later on and then the issue will go away.
So far we don't want regression as long as they show up in our NUnit tests.
2015-04-24 14:36:58 +09:00
Atsushi Eno b96232d37a [WCF] exclude extra schema by referencesource XsdDataContractExporter.
Unlike our own XsdDataContractExporter, referencesource one generates
an extra schema that targets xs:* (XmlSchema.Namespace).
That should not be generated as part of WSDL, so exclude it.
2015-04-24 14:36:58 +09:00
Atsushi Eno f204f35dfe [WCF] fix another use of XmlBinaryWriter that closes stream and accesses it later. 2015-04-24 14:36:57 +09:00
Atsushi Eno e94bc465ca [WCF] referencesource XmlBinaryWriter closes stream by default, so keep it open.
Otherwise MemoryStream.Position complains that it is already disposed.
2015-04-24 14:36:57 +09:00
Atsushi Eno 5bc665e8c4 [S.R.Serialization] for some use cases we don't expect reflection exception.
We do throw TargetInvocationException because we can only use reflection.
So unwrap those exceptions. It is kind of silly though...
2015-04-24 14:36:57 +09:00
Atsushi Eno 72550114a2 [S.R.Serialization] change all NotDotNet Json reader tests to [Ignore]. 2015-04-24 14:36:57 +09:00
Atsushi Eno 1ca18d222c [S.R.Serialization] fix Json reader member duplicate check index. 2015-04-24 14:36:56 +09:00
Atsushi Eno bad2fdb5e8 [S.R.Serialization] fix condition on simple dictionary output. 2015-04-24 14:36:56 +09:00
Atsushi Eno cda40030b2 [S.R.Serialization] add Json reader/writer interpreters.
They don't pass all the tests in System.ServiceModel.Web yet.
2015-04-24 14:36:55 +09:00
Atsushi Eno 05dc210442 [S.R.Serialization] remove debugging code. 2015-04-24 14:36:55 +09:00
Atsushi Eno bb44512b80 [S.R.Serialization] fix MTOM writer test to match .NET behavior.
WriteStartDocument() can be used with document and document does not accept
more than one element, which basically contradicts MTOM writer usage.

For EOL changes, MTOM writer should not alter content EOL chars.
2015-04-24 14:36:55 +09:00
Atsushi Eno f556bf8d32 [S.R.Serialization] fix XsdDataContractImporter test to match .NET behavior.
It is likely that the second contract conflicts with the existing one and
WCF renames it to avoid that.
2015-04-24 14:36:55 +09:00
Atsushi Eno 924a79ea63 [S.R.Serialization] fix wrong test that doesn't match .NET behavior.
There is no BOM output on Windows either.
2015-04-24 14:36:54 +09:00
Atsushi Eno fc05116b03 [S.R.Serialization] implement XmlDataContract's interpreter method. 2015-04-24 14:36:54 +09:00
Atsushi Eno 2481129c45 [S.R.Serialization] additional type check for collection serialization is also needed. 2015-04-24 14:36:54 +09:00
Atsushi Eno a7051c6365 [S.R.Serialization] additional type check for array serialization is needed. 2015-04-24 14:36:54 +09:00
Atsushi Eno 98c812ee24 [S.R.Serialization] do not update memberType when not expected.
The removed code caused unexpected omission of xsi:type by giving "false"
Type information that is from the actual value (when the expected type is
different, xsi:type should be written).
2015-04-24 14:36:54 +09:00
Atsushi Eno 99a7c698f0 [S.R.Serialization] fix nullable serialization to match referencesource codegen.
The original code is complicated enough that I misinterpreted the logic...

The reulting code should look like this:

	DateTime? expr_94 = timeSubmitted;
	DateTime dateTime;
	bool arg_B5_0;
	if (XmlObjectSerializerWriteContext.GetHasValue<DateTime> (expr_94)) {
		dateTime = XmlObjectSerializerWriteContext.GetNullableValue<DateTime> (expr_94);
		arg_B5_0 = false;
	}
	else {
		dateTime = XmlObjectSerializerWriteContext.GetDefaultValue<DateTime> ();
		arg_B5_0 = true;
	}

The fixed code should be like this now.
2015-04-24 14:36:53 +09:00
Atsushi Eno f6d778c148 [S.R.Serialization] fix deserialization of primitive arrays in reader interpreter.
Basically the primary cause of the problem was that invoked primitive array
reader methods via reflection had 'out' parameter, which needed special care.
2015-04-24 14:36:53 +09:00
Atsushi Eno 1a8b8015a7 [S.R.Serialization] fix member indexing on reading deserialized members. 2015-04-24 14:36:53 +09:00
Atsushi Eno 828b7fb7a0 [S.R.Serialization] fix array element deserialization.
Array elements were not deserialized correctly and causing null (default)
items put into the array.
2015-04-24 14:36:53 +09:00
Atsushi Eno c5d45b2857 [S.R.Serialization] fix writer interpreter on enumerating non-dictionary.
Collection serialization was mostly failing, when it was non-dictionary.

Now it should be closer to referencesource dynamic code behavior.
2015-04-24 14:36:52 +09:00
Atsushi Eno affe15ccff [S.R.Serialization] fix reader interpreter: "required" check was broken.
Now it should match referencesource behavior.
2015-04-24 14:36:52 +09:00
Atsushi Eno d1152054a2 [S.R.Serialization] Fix TryWritePrimitive() parameter assignment.
It was inconsistent with what referencesource codegen does.
2015-04-24 14:36:52 +09:00
Atsushi Eno 51c1b640e7 [S.R.Serialization] add missing ConvertValue on xml reader interpreter. 2015-04-24 14:36:52 +09:00
Atsushi Eno dd19347ef2 [S.R.Serialization] fix broken test (exposed by referencesource import work). 2015-04-24 14:36:51 +09:00
Atsushi Eno 4cd398d756 build System.ServiceModel.Internals everywhere. 2015-04-24 14:36:51 +09:00
Atsushi Eno 9f0d571781 [S.R.Serialization] implement XmlFormatReaderGenerator interpreter.
Though it's still buggy and shows several nunit test failures yet.
2015-04-24 14:36:51 +09:00
Atsushi Eno 02915b9d61 [S.R.Serialization] implemented interpreter-based XmlFormatWriterGenerator. 2015-04-24 14:36:51 +09:00
Atsushi Eno 569890717a [S.R.Serialization] switch to (non-emit) reflection-based implementation stubs.
The new code is to implement reflection (non-emit) based serialization
so that it works on iOS.

Actually I _totally_ switched to this new implementation because dynamic
method based implementation also doesn't work fine, even on desktop
(due to invocation failure on internal methods, it seems that our dynamic
method needs some bugfixes).

The new methods with NotImplementedException in new classes need to be
implemented.
2015-04-24 14:36:51 +09:00
Atsushi Eno 1b419b8975 Fix mobile build (breakage caused by referencesource switch). 2015-04-24 14:36:50 +09:00
Atsushi Eno 548e2be329 [S.R.Serialization] switch to USE_REFEMIT to reduce test failures.
We don't use neither of expression trees nor SRE anyways, but it's easier
to reduce noises in nunit test failures to review the rest.
2015-04-24 14:36:50 +09:00
Atsushi Eno e0ac7695f0 Add system.runtime.serialization config, makes several tests pass. 2015-04-24 14:36:50 +09:00
Atsushi Eno b3a7d0aa00 [S.R.Serialization] switch to referencesources.
It builds on net_4_5 and monodroid so far.

We still need to eliminate dynamic code generation to make it work on iOS.
2015-04-24 14:36:50 +09:00
Atsushi Eno 3059d85b84 [S.Xml] Add [InternalsVisibleTo(S.R.Serialization)]. 2015-04-24 14:36:49 +09:00
Alex Rønne Petersen b00dd292a5 Merge pull request #1735 from akoeplinger/mingw-fix
[io-layer] Fix Windows build on mingw
2015-04-24 04:13:10 +02:00
Alexander Köplinger a7d083456f [io-layer] Fix Windows build on mingw
When we moved to Vista as the minimum build target, the mingw build broke.
The reason is that mingw's mswsock.h has the following code:

    #if (_WIN32_WINNT >= _WIN32_WINNT_VISTA)
    int WSAAPI WSAPoll(WSAPOLLFD, ULONG, INT);
    #endif

Unfortunately, due to a bug mingw 4.0 doesn't define WSAPOLLFD and the compiler
raises an error. See http://sourceforge.net/p/mingw/bugs/1980 for more details.

As a workaround, inline the typedef for WSAPOLLFD from the mentioned bug report.

Also removed an unecessary check for _WIN32_WINNT < 0x0502 from the file.
2015-04-23 19:07:41 -07:00
anikilatorbeta dfb71ad5af Upadate socket and add OSSupportsIPv4 in net 4.0
add OSSupportsIPv4 in net 4.0

https://msdn.microsoft.com/en-us/library/system.net.sockets.socket.ossupportsipv4%28v=vs.110%29.aspx

and ObsoleteAttribute https://msdn.microsoft.com/en-us/library/system.net.sockets.socket.supportsipv4%28v=vs.110%29.aspx
2015-04-23 21:50:11 -03:00
Zoltan Varga 450e1ebe7b [jit] Use mini_get_underlying_type () in mini_type_is_vtype () so it works with partial sharing. 2015-04-23 18:44:29 -04:00
Ludovic Henry 3e4b814879 [threadpool] Remove native call to Socket.(Receive|Send)_internal
This is now done in managed in SocketAsyncWorker.cs since 0c9dcf73c2
2015-04-23 21:45:28 +01:00
Ludovic Henry 0fdf8d387c [threadpool-ms] Fix race condition 2015-04-23 20:47:26 +01:00
Zoltan Varga b0e63a8b1a [runtime] Fix the arm build. 2015-04-23 13:25:32 -04:00
Rolf Bjarne Kvinge 33860f8afd [System.Data] Bring back PropertyAttributes, StrongTypingException and TypedDataSetGeneratorException to the mobile build. 2015-04-23 13:02:46 +02:00
Rolf Bjarne Kvinge 8d876c3d58 [mono-api-html] Use html5-compatible code for colorizing (i.e. css instead of font/s/u). 2015-04-23 12:24:11 +02:00
Rolf Bjarne Kvinge 1ddaf1f4d4 [mono-api-html] Ignore non-important attribute differences and other improvements.
* Properly colorize removed types (as red).
* Print 'NotSerialized' field attribute change (as not breaking).
* Ignore 'HasSecurity' and 'PInvokeImpl' method attribute differences.
* Render property indexers (and detect name change in property indexer parameters).
* Improve debug spew to print proper method/field attributes.
2015-04-23 12:23:21 +02:00
Zoltan Varga 4cf2a9681b Merge pull request #1731 from mono/fix-abort-arm-thumb
[arm] Fix aborting of threads in managed code
2015-04-23 03:05:09 -04:00
Vlad Brezae 212e286e9e [arm] Fix aborting of threads in managed code
When installing the async callback in the context we need to update the thumb bit accordingly.
2015-04-22 23:45:45 +00:00
Radek Doulik facbf81e05 [pdb2mdb] fix decimal values reading
apply patch from monodroid

    Author: Dean Ellis <[email protected]>
    Date:   Thu Apr 17 12:34:00 2014 +0100

        [MSBuild] Error MSB3375 when attempting to debug PCL in VS

        Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=18757

        The code to read the decimal values from
        the pdb did not work in all circumstances.
        This change uses the recommended code for
        reading the bits for a decimal from MSDN

        see http://msdn.microsoft.com/en-us/library/system.decimal.getbits.aspx?cs-save-lang=1&cs-lang=csharp#code-snippet-3

        It also includes an ArgumentException
        handler just in case it fails.
2015-04-22 22:46:49 +02:00
Alex Rønne Petersen 01b874d09f Merge pull request #1728 from akoeplinger/revert-xp
Revert "[msvc] Change target MSVC release from v120 to v120_xp"
2015-04-22 18:54:10 +02:00
Rodrigo Kumpera fa9daf9c7a [threading] Remove dead code that was used only by old suspend. 2015-04-22 12:20:16 -04:00
Alexander Köplinger 1347f7421d Fix comment that still referred to Windows XP in configure.ac 2015-04-22 18:15:25 +02:00
Alexander Köplinger b271f01f24 Revert "[msvc] Change target MSVC release from v120 to v120_xp"
This reverts commit 577482e336.

We dropped XP support (see https://github.com/mono/mono/pull/1723),
so this is no longer necessary.
2015-04-22 18:14:40 +02:00
João Matos bf0d9bb19b Merge pull request #1725 from alexanderkyte/cache_crash
[System.Runtime.Caching] Added missing locking around cache's sortedset.
2015-04-22 15:29:32 +01:00
João Matos 5b64b929f0 Merge pull request #1726 from jaredpar/build-roslyn
Improve Visual Basic build support
2015-04-22 15:27:21 +01:00
Sebastien Pouliot 669572d6c9 [linker] Mark SecurityDeclarations [#28918]
Security declarations looks very similar to custom attributes - but
they are not (e.g. a different metadata table).

They need to be marked, just like other metadata, by the linker because
they can encode types that won't show up in the type (or assembly)
references.

Ignoring this can create an invalid binary (the kind that even Cecil
can't load back for further processing).
2015-04-21 21:42:11 -04:00
Sebastien Pouliot a497d8ad0c [linker] Resolve AssemblyName[Reference] when sweeping [#29211]
The exact name (e.g. version) might differ between the original
AssemblyNameReference and the one being used (e.g. PCL).

To make sure we remove unused references we need to resolve
the AssemblyNameReference into AssemblyDefinition and then
continue the sweep based on the _new_ AssemblyNameReference.
2015-04-21 21:29:56 -04:00
Sebastien Pouliot e5dada307a Bump referencesources to restore compatibility with UnmanagedType enum 2015-04-21 21:26:35 -04:00
Zoltan Varga 717ce03d2d [sdb] Remove more unused code. 2015-04-21 19:07:23 -04:00
Zoltan Varga 551d40cb19 [sdb] Remove more unused interrupt code. 2015-04-21 19:01:51 -04:00
Zoltan Varga 33014196c9 [sdb] Remove unused mono_debugger_agent_thread_interrupt () function. 2015-04-21 18:54:44 -04:00
Zoltan Varga 737bc2e353 [sdb] Remove an osx workaround which isn't needed with the new suspend code. 2015-04-21 18:50:07 -04:00
Zoltan Varga 9dfcb07f16 Fix some warnings. 2015-04-21 18:39:53 -04:00
Rodrigo Kumpera 81a9fcc9c7 Merge pull request #1723 from madewokherd/winvista
Bump Windows requirement to Vista.
2015-04-21 17:03:22 -05:00
Rodrigo Kumpera 9f92e1c7fd [runtime] It's spring cleaning in MonoInternalThread. Remove 8 (yes, eight) unused fields. 2015-04-21 17:50:50 -04:00
Rodrigo Kumpera 43971cdf05 [threading] Remove old suspend code now that all targets support it.
The new suspend code works on all major targets, so it's time to remove old suspend.

This change removes all relevant native code, managed code could see some cleanup.
2015-04-21 17:09:37 -04:00
jaredpar 43af8d475d Improve Visual Basic build support
This fixes a couple of small issues with the Visual Basic build support:

- The VBC task now respects the $(NoStdLib) MSBuild option.
- The field @(ReferencePath) should be used for References in the VBC
target as it is for the CSC target.
- The CreateVisualBasicManifestResourceNames task is compiled and used
in the same manner as CreateCSharpManifestResourceNames hence it should
be loaded via UsingTask in the same manner as well.
- Include the VisualBasic Portable targets files.
2015-04-21 09:47:59 -07:00
Rodrigo Kumpera a801b374ef Merge pull request #1699 from ludovic-henry/threadpool-managed
[threadpool-io] Move (Socket)AsyncResult invocation code to managed + Various improvements
2015-04-21 11:41:01 -05:00
Alexander Köplinger 02e3e46d90 Merge pull request #1721 from jaredpar/fix-attribute-gen
Emit assembly attributes after Import statements
2015-04-21 18:35:24 +02:00
jaredpar 210e351187 Emit assembly attributes after Import statements
The VB language requires that code files have statements in the
following order:

- Option
- Import
- Assembly level attributes
- Namespaces / other declarations

The VBCodeGenerator type when given both import and assembly level
attribute statements was generating the attributes first.  This lead to
compilation errors in the generated file.

This change fixes the generator to emit assembly level attributes in
the proper location in the file (and adds the corresponding unit tests
as well).
2015-04-21 08:15:18 -07:00
Chris Hamons 0723b3a8fb Fix Options.cs warning on mobile builds
- Explictly disable warning CS0618 for Options.cs in Mono.Options
2015-04-21 10:04:06 -05:00
Marcos Henrich 33af6316a2 [System] Replaced System.Process lock(this)
To avoid concurrency problems lock(this) should not be used in public
classes.
2015-04-21 15:54:08 +01:00
Marcos Henrich e94270c456 [System] Process.Exited is now thread safe.
Fixes Exited event triggering multiple times.
2015-04-21 14:09:20 +01:00
Miguel de Icaza c7e9aac84f Merge pull request #1720 from blucz/master
Fix NullReferenceException in timer thread
2015-04-20 22:00:09 -04:00
Alexander Kyte 311e032219 [System.Runtime.Caching] Added missing locking around cache's sortedset. 2015-04-20 19:07:14 -04:00
Rodrigo Kumpera cd10756a3c [threading] Fix coop+windows compilation. 2015-04-20 16:46:13 -04:00
Vincent Povirk 46c5bdd114 Bump Windows version requirement to Vista. 2015-04-20 15:14:22 -05:00
Vincent Povirk d039392b62 Add configure check for inet_pton on Windows. 2015-04-20 15:05:50 -05:00
Rodrigo Kumpera 30f1a70a0b [threading] Just skipping GC is not enough, we need to transition the threadpool to blocking. 2015-04-20 16:01:29 -04:00
Rodrigo Kumpera a95525a65a [threading] Add coop support to sdb. 2015-04-20 15:59:06 -04:00
Miguel de Icaza 53dc56ee39 [Socket] Add DualMode property and adjust to Mono semantics (continuation to #20048)
The new socket constructor that only takes a SocketType and a
ProtocolType defaults to InterNetworkV6 (this was done on a previous patch).

In addition, we explicitly set "DualMode" to true, so that on Windows,
this gets set explicitly (it does not matter on Unix).

We surface the DualMode property to allow servers that want to just
bind to the IPv6 address to do so by creating the socket and then
changing DualMode to false.

This is *not* the same setting that Windows has, but it is the
semantics that Mono applications depend on.  So a test has been added
to ensure that we do not regress.

This also switches to use SocketOptionName from the ReferenceSources.
2015-04-20 15:55:26 -04:00
Ludovic Henry 1cc9973e24 [threadpool-io] Fix epoll init 2015-04-20 16:15:08 +01:00
Ludovic Henry b823208f3f [threadpool-io] Move epoll/kqueue/poll specific code to dedicated files
This is to make the addition of backends easier
2015-04-20 16:15:08 +01:00
Ludovic Henry 0c9dcf73c2 [threadpool-io] Move Mono(Socket)RuntimeWorkItem ExecuteWorkItem code to (Socket)AsyncResult in managed 2015-04-20 16:15:07 +01:00
Marek Safar 63a3a3aed7 [corlib] cryptography from reference sources 2015-04-20 16:50:56 +02:00
Marcos Henrich e097a98f3b Merge pull request #1691 from esdrubal/exitevent
Improved Process.Exited
2015-04-20 15:04:32 +01:00
Marcos Henrich 0b4bc83e79 Merge pull request #1222 from LogosBible/uri-trycreate
Lower-case the host in Uri.TryCreate to match behavior of constructors
2015-04-20 14:06:22 +01:00
Marek Safar a9d48d370f [corlib] Fix mobile tests 2015-04-20 13:46:52 +02:00
Ludovic Henry 551b337e4e [threadpool-io] Make updates non backend specific 2015-04-20 12:23:40 +01:00
Ludovic Henry 71bdba5ad7 [threadpool-io] Do not wait on socket if there are no SocketAsyncResults to call 2015-04-20 12:23:39 +01:00
Zoltan Varga a5f5a4431a [llvm] Refactor the intrinsics registration code a bit. 2015-04-18 23:47:28 -04:00
Miguel de Icaza 3d9c9787ab [Socket] Fix the socket ctor base call, and document the reason; Fixes #20048 2015-04-18 22:01:49 -04:00
Zoltan Varga 25ff41d435 [runtime] Fix a regression in the socket code introduced by 6999fc2677. 2015-04-18 20:17:37 -04:00
Zoltan Varga ce3a0a57ef [runtime] Add a checked version of mono_class_from_name (). 2015-04-18 12:03:15 -04:00
Zoltan Varga a4b4954296 Fix a warning. 2015-04-18 11:43:02 -04:00
Zoltan Varga 621df16d31 Revert "[runtime] Add a _checked version for mono_class_from_name ()."
This reverts commit 652c882f3d84309fdb1b97978871c8aa76916fd2.

Revert this as it breaks tests.
2015-04-18 00:25:29 -04:00
Zoltan Varga 61e5feb6b7 [runtime] Remove unused mono_metadata_parse_signature_full () function. 2015-04-18 00:25:28 -04:00
Zoltan Varga d0ccda58c6 [runtime] Add a _checked version for mono_class_from_name (). 2015-04-18 00:25:28 -04:00
Rodrigo Kumpera 753aa0990d [jit] Fix the build. 2015-04-17 17:01:27 -04:00
Zoltan Varga 0b96691cc6 [jit] Allow the storage of trampolines in the jit info tables. Currently, this is only used by mono_print_method_from_ip (). 2015-04-17 16:49:11 -04:00
Zoltan Varga a1b9eb6a0a [runtime] Enable the managed test runner for the gshared tests as well. 2015-04-17 16:49:11 -04:00
Rodrigo Kumpera 072ab0db83 [threading] [jit] Fix non coop osx build. 2015-04-17 15:27:54 -04:00
Brian Luczkiewicz 8f23006468 Fix NullReferenceException in timer thread
Every once in a while, we run into a NullReferenceException attempting to dispose a null timer. It's very rare and we can't reproduce. However, reading this code, it seems possible that two timer callbacks could pile up, and if they did, the first one might dispose the timer, and then the second one would attempt to dispose null.
2015-04-17 15:22:40 -04:00
Rodrigo Kumpera 6b2e92f179 [coop] Add missing coop checks for WFSO and WFMO. 2015-04-17 15:20:54 -04:00
Rodrigo Kumpera ed046873c5 Revert "[threading] Move the safe pointing of WFSO and WFMO into the io-layer, since it's simpler to have it there."
This reverts commit 0327832893.
2015-04-17 15:20:54 -04:00
Rodrigo Kumpera 6999fc2677 [coop] get_addrinfo_family_hint could call into managed, which is not allowed while in blocking mode. 2015-04-17 15:20:54 -04:00
Rodrigo Kumpera 0e12ff3017 [jit] Rework the managed code suspend polling and add COOP_GC support.
This change enables managed polling to work with both NaCL and coop as they are exactly the same except for the variables used.

We cleanup how safepoints are injects to be done on a separate pass instead of having in spread around the JIT.

We now inject safepoints at EH handler entry as those did not previously have them.

The generated AOT code was greatly optimized by having the polling variable checked before doing the icall. This more
than doubles the performance of the generated code.
2015-04-17 15:20:53 -04:00
Rodrigo Kumpera 79b617f775 [jit] Fix the loop recognition pass to handle single BB loops and enable logging by default. 2015-04-17 15:20:53 -04:00
Rodrigo Kumpera 207b1fa616 [threading] Add a global variable that is set while a global suspend is hapening.
This global var is meant to be used by JIT'd code to efficiently implement polling.
2015-04-17 15:20:53 -04:00
Zoltan Varga 8de00a141d [runtime] Fix the creation of multi-dimensional arrays using ConstructorInfo.Invoke (). Fixes #29183. 2015-04-17 15:05:51 -04:00
Ludovic Henry af7ab54757 [threadpool-ms] Change boolean return type from gboolean to MonoBoolean for icalls 2015-04-17 17:54:17 +01:00
Ludovic Henry 558ca688b7 [threadpool-ms] Fix sgen runtime test crash 2015-04-17 17:42:43 +01:00
João Matos 5e64104c6f [runtime] Revert this change as it strips the volatileness of the load. 2015-04-17 17:35:56 +01:00
Marek Safar 00795ab248 [corlib] Security attributes from reference sources 2015-04-17 16:59:49 +02:00
Marek Safar 8dc7ac94b7 [corlib] Update public api 2015-04-17 16:06:05 +02:00
Marek Safar 0940c74b1e [corlib] Versioning from reference sources 2015-04-17 15:38:37 +02:00
Ludovic Henry b61cfec1f4 [runtime] Fix call to task_for_pid in proclib utils
task_for_pid requires special privileges on osx 10.5+ and ios, so it's better to avoid calling it.
2015-04-17 13:58:54 +01:00
Marek Safar 8da357b3e7 [corlib] SafeHandles from reference sources 2015-04-17 14:32:10 +02:00
João Matos 3b193af24d Merge pull request #1717 from jaredpar/vb-build-props
Expand Visual Basic build support
2015-04-17 12:28:23 +01:00
João Matos 3fa9d4d5c9 Merge pull request #1716 from esdrubal/jsdeserialize
[System.Web.Extension] Fixes JavaScriptSerializer.Deserialize.
2015-04-17 12:10:45 +01:00
Marek Safar 8bbbc63752 [system] Fixes mobile build 2015-04-17 12:09:08 +02:00
Marek Safar a87bf6db67 [corlib] Fixes build 2015-04-17 11:34:57 +02:00
Marek Safar 1d36c68a1e Bump reference sources for build fix 2015-04-17 11:01:59 +02:00
Marek Safar 92da5bc43f [corlib] Mobile build fixes 2015-04-17 10:37:16 +02:00
Marek Safar 6947138c8a [facades] Add missing attributes 2015-04-17 10:37:16 +02:00
Marek Safar ca1c420674 [corlib] More exceptions from reference sources 2015-04-17 10:37:16 +02:00
jaredpar e20ddef0b6 Expand Visual Basic build support
This change adds support for the following MSBuild properties which are specific to VB compilation:

- OptionInfer: controls the /optioninfer switch
- VBRuntime: controls the /vbruntime switch
2015-04-16 13:27:03 -07:00
Neale Ferguson da5795054b Add support for mono_arch_create_monitor_[enter|exit]_trampoline 2015-04-16 16:14:19 -04:00
Zoltan Varga c73363cee4 [runtime] Fix support for delegates with a byref first argument bound to a valuetype method. Fixes #25717. 2015-04-16 15:10:19 -04:00
Marcos Henrich 0ac4c24116 [System.Web.Extension] Fixes js deserialization.
Fixes JavaScriptSerializer.Deserialize of values with trailing spaces.
Fixes #4148.
2015-04-16 19:12:29 +01:00
Marcos Henrich d8e2ec1832 [System.Web.Extension] Added tests.
Tests JavaScriptSerializer.Deserialize with trailing white spaces.
Covers #4148
2015-04-16 19:11:33 +01:00
João Matos 99014074e0 [runtime] While we're here update the code to match the style guide. 2015-04-16 17:56:32 +01:00
João Matos ae44f77a75 [runtime] Fixed extra address-of in lock free code. 2015-04-16 17:49:46 +01:00
Marek Safar f4997d3800 [corlib] Update reference sources com sources 2015-04-16 17:47:31 +02:00
Rodrigo Kumpera a2b07bc25e Merge pull request #1715 from tritao/cpp_fixes
C++ compliance fixes
2015-04-16 10:28:28 -05:00
João Matos 030a43a812 [runtime] C++ compliance fixes. 2015-04-16 16:11:00 +01:00
Marek Safar c6e9591d0c [corlib] Remove useless TypeLib assembly attribute (it's not always available) 2015-04-16 16:31:56 +02:00
Marek Safar fc00dc2324 [mcs] Better error reporting for incorrect implicitly typed local variable declaration. Fixes #28069 2015-04-16 16:31:26 +02:00
Miguel de Icaza 9dd7a04810 [man/certmgr] Update documentation 2015-04-16 09:50:11 -04:00
Marek Safar b98d9dc1c8 [corlib] Claims from reference sources 2015-04-16 11:28:41 +02:00
Mark Probst d55cfe091b [sgen] Fix a concurrent mark bug.
This made `sgen-descriptors.exe` crash with an assertion.
2015-04-15 15:56:28 -07:00
Marek Safar 9faaa72407 [system.xml] Update failing test 2015-04-16 00:08:01 +02:00
Marek Safar 37080045d7 [corlib] Remove duplicate file entry 2015-04-15 22:23:02 +02:00
Marek Safar 6d326f1c90 [mcs] Update failing test 2015-04-15 22:23:02 +02:00
João Matos f34e856519 Merge pull request #1714 from madewokherd/condwait
Release the mutex in mono_cond_[timed]wait on Windows.
2015-04-15 21:15:53 +01:00
Vincent Povirk 81b82a5034 Release the mutex in mono_cond_[timed]wait on Windows.
This commit is licensed as MIT/X11.
2015-04-15 14:57:11 -05:00
Marek Safar 2e559f4ec9 [corlib] Runtime attributes from reference sources 2015-04-15 18:05:07 +02:00
Marek Safar c2344f5135 [corlib] Return custom attributes in order they were compiled. Fixes #28692 2015-04-15 12:47:49 +02:00
Marek Safar 26bb4585a0 [corlib] Update failing test 2015-04-15 11:00:37 +02:00
Marek Safar c750efbb03 Merge pull request #1693 from Garciat/fix-assembly-get-satellite
[corlib] Check for missing/empty Assembly.Location. Fixes #28876
2015-04-15 10:50:56 +02:00
Marek Safar 3a7585be9d [corlib] Add test for in memory assemblies (#28876) 2015-04-15 10:48:40 +02:00
Miguel de Icaza ca4650bf92 Merge pull request #1713 from joelmartinez/docs-monodoc-getassembly
[monodoc] Updated how generators load resource streams.
2015-04-15 00:20:11 -04:00
Atsushi Eno 7a828d5d4f remove unused CodeDom sources. 2015-04-15 12:42:41 +09:00
Atsushi Eno c8c1a778e8 Merge pull request #1709 from atsushieno/import-codedom-core
Import CodeDom types and Compiler.CodeGenerator class from referencesource
2015-04-15 12:21:12 +09:00
Mark Probst 32184f29e6 [sgen] Free mod-union tables for LOS objects. 2015-04-14 16:23:21 -07:00
Mark Probst fdb1eecfb0 [sgen] Use mod-union to add remsets from concurrent collector.
Concurrent mark modified the card table directly, which had two
drawbacks.

First, it meant that nursery collections would also have to scan the
cards marked by the concurrent collector, which was unnecessary work.

Second, because the nursery collector also modified the cardtable, it
meant that the two could not run concurrently, i.e., we had to suspend
concurrent marking work whenever a nursery collection occurred.
2015-04-14 16:23:20 -07:00
Mark Probst 307545d624 [sgen] Separate concurrent M&S object operations into start, concurrent, finish. 2015-04-14 16:23:20 -07:00
Mark Probst 439b643a43 [sgen] Use enum instead of two bools in major_copy_or_mark_from_roots(). 2015-04-14 16:23:20 -07:00
Mark Probst 8c50748e3a [sgen] Get rid of redundant argument to major_copy_or_mark_from_roots(). 2015-04-14 16:23:20 -07:00
Mark Probst 7f9c8960fe [sgen] Get rid of global current_object_ops. 2015-04-14 16:23:20 -07:00
Mark Probst 8fc2f229f2 [sgen] Make scan context have a pointer to object operations.
Instead of copying everything from the object operations into the
context.
2015-04-14 16:23:19 -07:00
Mark Probst d0b5f545d5 [sgen] Replace sgen_get_current_object_ops() by passing a ScanCopyContext.
Getting rid of global state.  The idea is for the context to contain
everything that the mark/scan loop needs to do its work.
2015-04-14 16:23:19 -07:00
Zoltan Varga 2e59e73e24 [jit] Fix an unpatched jump in the monitor exit trampoline on amd64. 2015-04-14 18:58:03 -04:00
Zoltan Varga 3a4f91ffb5 [jit] No need to check for info!=NULL in the trampoline creation functions, the caller always passes in a non-null value. 2015-04-14 18:58:03 -04:00
Mark Probst 4a6cbcfedf [sgen] Fix a race condition in the new worker/threadpool code. 2015-04-14 15:42:09 -07:00
Rodrigo Kumpera 0327832893 [threading] Move the safe pointing of WFSO and WFMO into the io-layer, since it's simpler to have it there. 2015-04-14 18:34:02 -04:00
Rodrigo Kumpera 4025d23682 [threading] Handle more non-trivial locks. 2015-04-14 18:34:02 -04:00
Rodrigo Kumpera 528c373152 [threading] Wrap the threads lock with cooperative coode. 2015-04-14 18:34:01 -04:00
Ludovic Henry 42b52f1506 [threadpool] Make GC skip worker and monitor threads when being parked or sleeping 2015-04-14 23:01:50 +01:00
Joel Martinez 68126fc088 [monodoc] Updated how generators load resource streams.
The issue was discovered when using monodoc in an asp.net application; while the code was developed and worked successfully in the local Visual Studio web server, it failed when deployed and executed in IIS. The reason it seems is because of the use of `.GetCallingAssembly()`, which was returning an unexpected assembly reference. This resulted in the `.GetManifestResourceStream` returning null for resources that are definitely a part of monodoc.dll.

Once the code was changed to get the assembly using a type reference of a type that's definitely in monodoc.dll ... the code resumed working as expected.
2015-04-14 17:56:53 -04:00
João Matos 12615adbdf Merge pull request #1711 from jldgit/jldgit-gdb-script
Corrected mono-gdb.py use of "\u%X".format (val)
2015-04-14 22:05:02 +01:00
Rodrigo Kumpera 3cb0fdabf9 Merge pull request #1710 from alexanderkyte/always_use_imt
[runtime] Further removed code that doubted IMT
2015-04-14 14:36:11 -05:00
Alexander Kyte f4e44e771f [runtime] Further removed code that doubted IMT 2015-04-14 15:20:22 -04:00
Zoltan Varga 94bb27144c [jit] Print out IL clause offsets in verbose mode. 2015-04-14 15:00:47 -04:00
James 63e7f0cee2 Corrected mono-gdb.py use of "\u%X".format (val)
This line of code would cause an error to pop up in gdb when starting.
2015-04-14 14:40:23 -04:00
Atsushi Eno cb58cc98bb [CodeDom] disable wrong test (see [Ignore] comment). 2015-04-15 03:29:06 +09:00
Zoltan Varga e2c8f3727e [jit] Fix the support for filter clauses by avoiding passing in the exception using a register, since call_handler () can't handle it. 2015-04-14 14:27:10 -04:00
Zoltan Varga 0d9df95717 [runtime] Fix freeing invalid memory in CreateProcess () if the executable was not found. Fixes #28209. 2015-04-14 14:26:01 -04:00
Zoltan Varga f22a4cb4c3 [jit] Fix the detection of the Selector.GetHandle intrinsics, and fix the emission of assembly for it so it also works on arm64. 2015-04-14 13:19:52 -04:00
Atsushi Eno 08debfcef3 Import CodeDom types and Compiler.CodeGenerator class from referencesource.
This does not import System.CodeDom.Compiler because some of them depends
on Windows specific stuff.

CodeGenerator is imported because ours depends on our own internal
Visitor implementation and could not build without making changes a lot.
2015-04-15 01:35:04 +09:00
Marek Safar 322af7e074 [mcs] Consider nested types when looking for potential types via using static. Fixes #29044 2015-04-14 17:59:33 +02:00
Zoltan Varga 8fad4b7607 [aot] Avoid saving MonoJitExceptionInfo->exvar_offset for catch clauses on platforms where its not used. 2015-04-14 10:58:52 -04:00
Zoltan Varga c9ef839928 [jit] Remove some dead code from get_shared_class (). 2015-04-14 10:53:40 -04:00
Zoltan Varga bf8c60a47b [jit] Get rid of the MONO_ARCH_HAVE_OP_GET_EX_OBJ define, use MONO_CONTEXT_SET_LLVM_EXC_REG instead. 2015-04-14 10:39:20 -04:00
Zoltan Varga e76860503e [jit] Enable passing the exception object in a register on arm. 2015-04-14 10:22:10 -04:00
Zoltan Varga 5bf9e8eb5b Fix a warning. 2015-04-13 22:51:50 -04:00
Zoltan Varga 7867b0bc0e [jit] Enable passing the exception object in a register on x86. 2015-04-13 22:46:39 -04:00
Zoltan Varga 174ef19852 [jit] Implement support for passing in the exception object to catch clauses in a register instead of storing it into its stack slot. This is identical to the way the c++ ehabi works. Enable it for amd64. 2015-04-13 21:02:47 -04:00
Mark Probst 639dea2b1c [runtime] Spurious wake-ups are not a FIXME. 2015-04-13 16:18:53 -07:00
Rodrigo Kumpera 18e87daaff [threading] Let the GC skip monitor thread while it sleeps. 2015-04-13 19:05:52 -04:00
Rodrigo Kumpera 7a8a42b0ea [threading] The common trampoline must reset the blocking state on entry. 2015-04-13 19:05:52 -04:00
Rodrigo Kumpera 79d6d67f2b [threading] Make all locks use the new try blocking mode. 2015-04-13 19:05:51 -04:00
Rodrigo Kumpera f4da7083e8 [threading] Introduce the notion of try block to be used by recursive locks.
This allows a piece of code to handle the cases where it's called in running and blocker context
and must always be in blocking context.

This probably makes code more modular at the expense of an easy to follow and debug execution model.

Since we don't currently annotate all icalls with blocking sections we do it with locks but they can
nest and recurse which requires this support for try block.
2015-04-13 19:05:51 -04:00
Mark Probst 37e5a38d4c [sgen] Fix a bug when waiting on a condition. 2015-04-13 15:55:58 -07:00
Zoltan Varga 28d16b2c52 [jit] Enable support for partial sharing for generic instances. 2015-04-13 18:04:08 -04:00
Zoltan Varga 1cab7b0535 [jit] Change MonoGenericParam.gshared_constraint to be a full MonoType so it can encode generic instances too. 2015-04-13 15:50:43 -04:00
Zoltan Varga ffd7c42bc9 Fix the build. 2015-04-13 15:44:21 -04:00
Zoltan Varga bc3fda9237 [runtime] Add a utility target to patch libtool to get rid of the the 'file ... has no symbols' warnings. 2015-04-13 15:14:40 -04:00
Zoltan Varga 2ffce7f1bf Merge pull request #1708 from alexanderkyte/always_use_imt
[runtime] Remove checks for mono_use_imt because always true.
2015-04-13 14:48:35 -04:00
Alexander Kyte 4d31a8b43f [runtime] As mono_use_imt is always true, remove dead code paths where it is not. 2015-04-13 14:41:00 -04:00
Marek Safar b2f3a260c7 [corlib] First specific culture returned by enumerator was not fully initialized. Fixes #29039 2015-04-13 19:16:29 +02:00
Marek Safar ff9226422d [corlib] Throw correctly captured ExceptionDispatchInfo exceptions. Fixes #24647 (and many async stacktraces too) 2015-04-13 17:46:06 +02:00
João Matos bd471cb710 Merge pull request #1704 from Therzok/master
Add gitter badge.
2015-04-13 15:19:06 +01:00
Marek Safar b526af0b08 [mcs] Decorate imported constants with static modifier to work with using static. Fixes #28976 2015-04-13 14:19:59 +02:00
Marek Safar eba8a5dd3d [corlib] Fixes mobile tests 2015-04-13 14:19:59 +02:00
Ludovic Henry a12d3732e4 [Socket] Fix SocketTest.TtlChangeOverflow test failing on non Mac platform
This revert behavior to prior to c45161d065
2015-04-13 12:16:20 +01:00
Marek Safar 670fcaf62a Merge pull request #1685 from esdrubal/touint64
ParseNumber.StringToInt now check for overflows.
2015-04-13 12:43:07 +02:00
Zoltan Varga e37594b0ee Revert "[jit] Avoid generating remoting invoke wrappers for icalls."
This reverts commit 4f124705ac.

Revert this as it causes corlib test failures.
2015-04-12 22:43:02 -04:00
Zoltan Varga b6037c6fe3 [jit] Implement support for constrained calls in partially shared methods. 2015-04-12 22:27:33 -04:00
Zoltan Varga 162baf38c7 Merge pull request #1703 from Garciat/ignore-systemdata-gen
[git] Ignore System.Data built sources
2015-04-12 11:20:35 -04:00
Zoltan Varga 4355a73caa [aot] Save/restore the names of the gshared generic params. 2015-04-11 22:23:48 -04:00
Zoltan Varga 4f124705ac [jit] Avoid generating remoting invoke wrappers for icalls. 2015-04-11 22:23:48 -04:00
Zoltan Varga 44b37eb2fd Fix a warning. 2015-04-11 22:23:48 -04:00
Zoltan Varga 6a4644ca9c Merge pull request #1705 from akoeplinger/fix-win-build
[configure] Fix Windows cygwin build broken by 3bc2eb8
2015-04-11 17:49:57 -04:00
Alexander Köplinger 4f14861aca [configure] Fix Windows cygwin build broken by 3bc2eb8cb7
The commit removed the AC_DEFINE for TARGET_WIN32 from configure.ac,
but many parts of the build rely on it so the build broke.

Fixed this by defining TARGET_WIN32 when we detect it is the target
and do the same for HOST_WIN32.
2015-04-11 22:52:30 +02:00
Ungureanu Marius 84fb741d43 Add gitter badge. 2015-04-11 19:25:53 +03:00
Gabriel Garcia 565ddd0150 [git] Ignore built sources 2015-04-11 09:42:52 -04:00
Zoltan Varga 62d46b469b [jit] Add support for computing the size of the branch binding area by backends and passing it to the code manager. Not used yet. 2015-04-10 21:52:39 -04:00
Zoltan Varga 97f3a148e8 [arm64] Increase the amount of memory used to bind branches since the arm64 thunk code is larger (16 bytes). Fixes #28747. 2015-04-10 21:47:33 -04:00
Sebastien Pouliot 5186dea237 [linker] Fix scope resolution of custom attributes (generic/array) argument types that refers to PCL facades [#28823] 2015-04-10 17:33:41 -04:00
Mark Probst d70376bcb6 [sgen] Fix a concurrent sweep bug. 2015-04-10 12:48:02 -07:00
Zoltan Varga 2a96a02351 [aot] Avoid duplicate plt symbols for plt entries for synchronized methods. Fixes #28961. 2015-04-10 11:13:04 -04:00
Marek Safar 7f56d39668 [corlib] ComTypes from reference sources 2015-04-10 17:04:26 +02:00
Marek Safar d0efb29476 [corlib] Remove unused files 2015-04-10 16:50:06 +02:00
Marek Safar 1d0be40a5b [corlib] ConstrainedExecution from reference sources 2015-04-10 16:47:30 +02:00
Marek Safar bc0b1ebcc0 [corlib] Globalization enums from reference sources 2015-04-10 16:38:23 +02:00
Marcos Henrich b378965d2a [System] Added missing files to mobile_System.dll.sources. 2015-04-10 10:16:14 -04:00
João Matos c2407d1379 Merge pull request #1701 from bojanrajkovic/fix-order-of-parameters-to-argumentexception-constructor
Fix order of parameters when creating ArgumentException
2015-04-10 15:13:32 +01:00
Bojan Rajkovic 301b66dd99 Fix order of parameters when creating ArgumentException
ArgumentOutOfRangeException expects the parameter name first, then the message. ArgumentException is precisely the opposite, and expects the message first, and then the parameter name. They were swapped here.
2015-04-10 10:10:55 -04:00
Marek Safar 4fc75b3e72 [corlib] TextInfo from reference sources 2015-04-10 15:07:58 +02:00
Marcos Henrich 11dd761965 [corlib] Adopted .NET TimeZone behavior for UTC DateTime.
In .NET regardless the current time zone, TimeZone.CurrentTimeZone.GetUtcOffset returns TimeSpan.Zero when called with an UTC DateTime.
Similarly IsDaylightSaveTime returns false when called with an UTC DateTime.
2015-04-10 08:45:54 -04:00
Marcos Henrich 3f190d6053 [corlib] Changed TimeZoneTest to be invariant to culture. 2015-04-10 08:34:22 -04:00
Marcos Henrich d6ac996b97 [corlib] Test TimeZone methods with UTC DateTime in DST. 2015-04-10 08:32:27 -04:00
Marcos Henrich f79db678d8 [System] Removed SafeSocketHandle unused code. 2015-04-10 10:57:23 +01:00
Marek Safar 167ea85899 [corlib] Fixes endianess issue in resourcereader 2015-04-10 10:32:35 +02:00
Marek Safar c1bc7890f5 [corlib] comparer fixes 2015-04-10 07:57:02 +02:00
Mark Probst 6e28186845 [sgen] Fix describe_ptr() and make it print namespace, too.
It didn't handle interior pointers correctly.
2015-04-09 17:22:39 -07:00
Mark Probst f6c4a9e42b Merge branch 'feature-concurrent-sweep' 2015-04-09 16:13:32 -07:00
Rodrigo Kumpera a95ec1f5bc Merge pull request #1698 from ludovic-henry/socket-reorg-2
Reorganize Socket code
2015-04-09 17:04:38 -05:00
Ludovic Henry 7cec1dbe8b [threadpool-io] Fix android build 2015-04-09 22:31:34 +01:00
Marek Safar 4eee47c42a [corlib] Equality comparer fixes 2015-04-09 22:55:10 +02:00
Alex Rønne Petersen bf98c077ea Remove Moonlight references from man mcs. 2015-04-09 21:18:22 +02:00
Alex Rønne Petersen 77e66ab8e8 Remove Olive support from the build system.
These libraries are no longer developed.
2015-04-09 21:18:22 +02:00
Zoltan Varga 2cab68d28c [jit] Use the same dwarf<->hw register mapping on x86 for both LLVM and jitted code, the one used by LLVM is the official version. 2015-04-09 15:10:55 -04:00
Zoltan Varga 5601dec49e [sdb] Make a log message less verbose. 2015-04-09 14:54:41 -04:00
Zoltan Varga a759581fef [sdb] Transition from step over to step into when control leaves managed code. Fixes #28557. 2015-04-09 14:37:54 -04:00
Marek Safar 8203b9bca7 [corlib] Fixes mobile build 2015-04-09 20:05:07 +02:00
Jo Shields 00fc3a6307 [RPM] Fix MONO_PATH in RPM dependency generators
Otherwise, RPMs don't have any dependency information

(cherry picked from commit 0dfb848cde)
2015-04-09 15:57:07 +01:00
Ludovic Henry 52d761a1f6 [Socket] Use type specific read and write queue for SocketAsyncWorker 2015-04-09 15:46:18 +01:00
Ludovic Henry 333a93ab7b [Socket] Cleanup of SocketAsyncWorker, SocketAsyncResult and SocketAsyncEventArgs 2015-04-09 15:41:27 +01:00
Marek Safar 0c268383cd [corlib] Buffer from reference sources 2015-04-09 16:01:46 +02:00
Marek Safar d88c018b74 [corlib] new test 2015-04-09 16:01:46 +02:00
Ludovic Henry 1c41e59174 [Socket] Refactor SocketAsyncResult enqueuing 2015-04-09 14:37:34 +01:00
Ludovic Henry 6ab21e3084 [runtime] Remove system from mono_defaults.system as it is a unloadable assembly 2015-04-09 14:37:33 +01:00
Ludovic Henry 0341f06e99 [Socket] Move remaining icalls and struct from Socket_2_1.cs to Socket.cs 2015-04-09 14:37:33 +01:00
Ludovic Henry dfc6fbb157 [Socket] Inline InvalidAsyncOp into ValidateEndIAsyncResult 2015-04-09 14:37:32 +01:00
Ludovic Henry 1c0c785ad9 [Socket] Move Dispose related methods to their region 2015-04-09 14:37:31 +01:00
Ludovic Henry 80445ada38 [Socket] Move Shutdown related methods to their region 2015-04-09 14:37:30 +01:00
Ludovic Henry a9031bfbcb [Socket] Move Close related methods to their region 2015-04-09 14:37:29 +01:00
Ludovic Henry badcf36458 [Socket] Move IOControl related methods to their region 2015-04-09 14:37:28 +01:00
Ludovic Henry 96a51d05d9 [Socket] Move Poll related methods to their region 2015-04-09 14:37:27 +01:00
Ludovic Henry c45161d065 [Socket] Move SetSocketOption related methods to their region 2015-04-09 14:37:26 +01:00
Ludovic Henry 66204d1ce3 [Socket] Move GetSocketOption related methods to their region 2015-04-09 14:37:26 +01:00
Ludovic Henry d9b72bb750 [Socket] Move SendPackets related methods to their region 2015-04-09 14:37:25 +01:00
Ludovic Henry 2250570156 [Socket] Move Listen related methods to their region 2015-04-09 14:37:24 +01:00
Ludovic Henry 1dd589cf59 [Socket] Move DuplicateAndClose related methods to their region 2015-04-09 14:37:23 +01:00
Ludovic Henry 9346cd1aa7 [Socket] Remove unused CheckRange method 2015-04-09 14:37:22 +01:00
Ludovic Henry 54f36e42da [Socket] Move Bind related methods to their region 2015-04-09 14:37:22 +01:00
Ludovic Henry d9249983bc [Socket] Move SendFile related methods to their region 2015-04-09 14:37:21 +01:00
Ludovic Henry abe9bc89b6 [Socket] Move SendTo related methods to their region 2015-04-09 14:37:20 +01:00
Ludovic Henry 4907ad68f0 [Socket] Move Send related methods to their region 2015-04-09 14:37:19 +01:00
Ludovic Henry 7299a2bd89 [Socket] Move ReceiveMessageFrom related methods to their region 2015-04-09 14:37:18 +01:00
Ludovic Henry 5ed347d0e5 [Socket] Move ReceiveFrom related methods to their region 2015-04-09 14:37:17 +01:00
Ludovic Henry 4a358f9a79 [Socket] Move Receive related methods to their region 2015-04-09 14:37:17 +01:00
Ludovic Henry eb4e038553 [Socket] Move Disconnect related methods to their region 2015-04-09 14:37:16 +01:00
Ludovic Henry d82106d2b7 [Socket] Move Connect related methods to their region 2015-04-09 14:37:15 +01:00
Ludovic Henry 3555555dba [Socket] Move Accept related methods to their own region 2015-04-09 14:37:14 +01:00
Ludovic Henry 9103278ddc [Socket] Move properties to their own region 2015-04-09 14:37:13 +01:00
João Matos 458b3269aa [mini] Fixed ifdef warning.
/Users/joao/Dev/droid5.1/mono/mono/mini/unwind.c:71:18: warning: extra tokens at end of #ifdef directive [-Wextra-tokens]
2015-04-09 13:28:24 +01:00
Marek Safar 716adcebde [corlib] Generic comparers from reference sources 2015-04-09 14:26:43 +02:00
Marcos Henrich c9ec78db14 [corlib] Monodroid now uses CurrentSystemTimeZone. 2015-04-09 12:42:12 +01:00
Marcos Henrich e5e406438c [corlib] Removed TimeZone unused methods. 2015-04-09 12:40:04 +01:00
Marcos Henrich bd7e2efe46 [corlib] CurrentSystemTimeZone is now using TimeZoneInfo.Local.
ICall GetTimeZoneData is no longer used and was removed.
2015-04-09 12:37:01 +01:00
Marcos Henrich d73bc81c5f [corlib] Added to TimeZoneInfo method GetDaylightChanges.
TimeZoneInfo.GetDaylightChanges returns DaylightTime from AdjustmentRules but when those are not available it is also able to do it from transitions.
2015-04-09 12:32:37 +01:00
Alex Rønne Petersen 811674bc63 Merge pull request #1695 from gregoryyoung/master
add compilation instructions
2015-04-09 12:09:53 +02:00
Greg Young 5a228a65a0 add compilation instructions 2015-04-09 13:03:26 +03:00
Marek Safar 9965afbe2f [corlib] GetGenericArguments from reference sources 2015-04-09 11:38:20 +02:00
Zoltan Varga 82f567d2e8 [jit] Rename gen_seq_points_debug_data to gen_sdb_seq_points. 2015-04-08 21:18:10 -04:00
Zoltan Varga 0468321ad1 [jit] Correctly disable seq points in wrapper on android. 2015-04-08 21:06:01 -04:00
Neale Ferguson 21399ed40b Correct lengths of move_i4_to_f and move_f_to_i4 2015-04-08 19:00:13 -04:00
Mark Probst b7ca3af3da [aot] Exit with an error message if there's no managed allocator.
This can happen with various SGen debug options, like canaries.
See bug #28857
2015-04-08 14:24:28 -07:00
Alexander Köplinger ff393312ec Fix centos badge and remove ppc badge in readme
The ppc Jenkins workers are offline right now and aren't expected to come back in the near future.
2015-04-08 22:43:43 +02:00
Zoltan Varga b3c69e6659 Fix some warnings. 2015-04-08 15:41:28 -04:00
Ludovic Henry e2e2229460 [Socket] Move Select related methods to their own region 2015-04-08 20:32:22 +01:00
Rodrigo Kumpera 3bc2eb8cb7 [configure] Fix windows cross compilation to generate the proper defines. 2015-04-08 15:25:04 -04:00
Rodrigo Kumpera 2b54e95eb5 [jit] Fix the usage of host/target defines for amd64 and windows. 2015-04-08 15:25:03 -04:00
Rodrigo Kumpera 8771b398cb [runtime] Fix the file mmap api to correctly use the host/target defines. 2015-04-08 15:25:03 -04:00
Zoltan Varga d42770d7de [runtime] Include sys/time.h to get struct timeval definition. 2015-04-08 15:01:35 -04:00
Ludovic Henry 66886a5c63 [Socket] Move CheckProtocolSupport to static constructor 2015-04-08 19:29:51 +01:00
Ludovic Henry 3fed6ef12f [Socket] Move Socket constructors to Socket.cs 2015-04-08 19:26:20 +01:00
Ludovic Henry c049a8b361 [Socket] Move Socket fields out of Socket_2_1.cs to Socket.cs 2015-04-08 19:13:18 +01:00
Marek Safar 7f52573aa2 [corlib] TimeZoneInfo.AdjustmentRule from reference sources 2015-04-08 19:31:59 +02:00
João Matos 64a27123d7 [mini] Fixed stack unwinding / DWARF register numbers when doing x86 cross compilation on OSX.
Eventually we want to add a better fix for this, like for instance adding this behaviour to the LLVM-specific code path
but until we can research more under exactly what conditions we need to do this then implement this simple workaround.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=27055.
2015-04-08 18:28:39 +01:00
Ludovic Henry 0916f916f6 [Socket] Move SocketAsyncCall out of Socket_2_1.cs to SocketAsyncCallback.cs 2015-04-08 18:26:42 +01:00
Ludovic Henry 6c72a6e005 [Socket] Move Worker out of Socket_2_1.cs to SocketAsyncWorker.cs 2015-04-08 18:25:13 +01:00
Ludovic Henry 17df15ecb6 [Socket] Move SocketAsyncResult out of Socket_2_1.cs 2015-04-08 17:46:41 +01:00
Ludovic Henry ecc6abaf6d [Socket] Move SocketOperation out of Socket_2_1.cs 2015-04-08 17:38:44 +01:00
Alexander Köplinger 88b5e5a618 Fix "make dist"
EXTRA_DIST still included files that were removed in 467ca088b6 and 4cd4437b1f.
2015-04-08 17:38:13 +02:00
Marek Safar 97ad68721b [corlib] More System types from reference sources 2015-04-08 17:35:32 +02:00
Marek Safar 0f42d213e1 [corlib] System delegates from reference sources 2015-04-08 17:35:31 +02:00
Marek Safar 23b6557c2e [corlib] System interfaces from reference sources 2015-04-08 17:35:31 +02:00
Marek Safar a80f9db6f6 [corlib] Console keys from reference sources 2015-04-08 17:35:31 +02:00
Gabriel Garcia fcf25bea84 Check for missing Assembly.Location 2015-04-08 10:48:16 -04:00
Alex Rønne Petersen be6b58600a [metadata] Remove old monosn.c (we have a managed sn now). 2015-04-08 16:48:05 +02:00
Marcos Henrich 5a7a7a0620 [System] Process.WaitForExit now triggers event Exited. 2015-04-08 14:44:09 +01:00
Marcos Henrich 287ba33275 [System] Test that Process.WaitForExit triggers the event Exited. 2015-04-08 14:42:03 +01:00
Marcos Henrich 0f48483411 [System] Process no longer calls OnExit if HasExited is false.
Fixes #26362.
2015-04-08 14:40:09 +01:00
Marcos Henrich f9b1cff021 [System] Test Process.Exited. Covers #26362.
Process.Exited should not be called if Process.HasExited is false.
2015-04-08 14:35:01 +01:00
Marek Safar a6b630813a [corlib] System attributes from reference sources 2015-04-08 15:20:57 +02:00
Marek Safar 789421f760 [corlib] IO exceptions from reference sources 2015-04-08 15:05:09 +02:00
Miguel de Icaza e93aa85e62 [mono.1] Document MONO_THREADPOOL 2015-04-08 08:20:03 -04:00
Marek Safar ebb011b871 [corlib] TypeLoadException from reference sources 2015-04-08 13:25:16 +02:00
Marek Safar fa020e965f [corlib] Add System.Object type handling in TypeInfo. Fixes #28369 2015-04-08 09:35:10 +02:00
Zoltan Varga cba42c385e [aot] Enable partial sharing when using full aot. 2015-04-07 23:29:30 -04:00
Zoltan Varga f849ff4ba5 [aot] Fix overflows when printing stats. 2015-04-07 23:29:11 -04:00
Zoltan Varga 9b0c4038ef [llvm] Remove an arm restriction, its no longer needed. 2015-04-07 20:02:53 -04:00
Zoltan Varga f8e392b3ed [llvm] Fix the previous change. 2015-04-07 19:51:40 -04:00
Zoltan Varga 2b792b8d08 [llvm] Avoid generating invalid llvm il for volatile sbyte variables. 2015-04-07 19:47:02 -04:00
Zoltan Varga bbee8d4d5e Revert "[configure] Clean up target name matching for $host != $target case."
This reverts commit 53f55647a5.

Revert this as it breaks the mobile build.
2015-04-07 18:18:42 -04:00
Rodrigo Kumpera 118c3a0c3f [runtime] Update the offsets table for amd64. 2015-04-07 17:03:48 -05:00
Zoltan Varga 947c1bbd9c [jit] Disable deadce in the liveness2 pass as well when compiling for sdb. Fixes #28847. 2015-04-07 17:50:56 -04:00
Rodrigo Kumpera b02523cfd1 [utils] Use open instead of fopen on unix targets. 2015-04-07 16:14:26 -05:00
Rodrigo Kumpera 9206989872 portability fixes. 2015-04-07 16:14:26 -05:00
Marek Safar 5aca5b826a [System.ServiceModel.Internals] Cleanup makefile 2015-04-07 22:57:25 +02:00
Zoltan Varga 1364644d22 [runtime] Make some threadpool icalls non static to fix the mobile build. 2015-04-07 16:29:18 -04:00
Zoltan Varga c94837ac9e [corlib] Add back some helper methods to String which were removed during the transition to reference sources. 2015-04-07 16:29:18 -04:00
Alex Rønne Petersen 53f55647a5 [configure] Clean up target name matching for $host != $target case.
We fully control the $target values here as we don't use canonicalization for
them. So we have no reason or excuse to be using wildcards in them.

E.g. any Linux $target in this case would previously be assumed to be Android.
2015-04-07 22:25:42 +02:00
Rodrigo Kumpera 0ce9e2ceac [jit] Make mono_thread_state_init_from_sigctx work with a coop cross compiler. 2015-04-07 16:03:44 -04:00
Rodrigo Kumpera d759d81c61 [configure] Add new target. 2015-04-07 16:03:43 -04:00
Marcos Henrich 6d778d70bf [corlib] ParseNumber.StringToInt now check for overflows.
The overflow check is only performed when the result is big enough.
The overflow check is done by decomposing 64 bit operations into 32 bit operations.
Fixes #17817.
2015-04-07 19:38:37 +01:00
Marek Safar 1db6ed7fb1 [SMDiagnostics] Fixes mobile build 2015-04-07 20:20:39 +02:00
Marek Safar 9916d42805 [corlib] Fixes mobile build 2015-04-07 19:58:35 +02:00
Marek Safar 58389f3618 [system.data] Fixes mobile build 2015-04-07 19:58:35 +02:00
Alex Rønne Petersen 817ae3d1db [mini] Support MONO_PROFILER_CODE_BUFFER_EXCEPTION_HANDLING on PPC. 2015-04-07 19:20:19 +02:00
Alex Rønne Petersen dc517162d4 [mini] Support MONO_PROFILER_CODE_BUFFER_EXCEPTION_HANDLING on x86. 2015-04-07 19:20:14 +02:00
Alex Rønne Petersen 5729637478 [mini] Support MONO_PROFILER_CODE_BUFFER_EXCEPTION_HANDLING on MIPS. 2015-04-07 19:14:50 +02:00
João Matos bcb651443d Merge pull request #1684 from Garciat/fix-zlib-helper
[System] Fix DeflateStream throw on empty flush, double flush. Fixes #28777
2015-04-07 17:31:12 +01:00
Zoltan Varga 6c38ce4ea4 Merge pull request #1689 from alexrp/remove-cruft
Remove cruft
2015-04-07 12:27:06 -04:00
Marek Safar 00abead41b [mcs] Fix betterness of candidates with optional parameters against unexpanded params parameters. Fixes #28837 2015-04-07 18:26:34 +02:00
Zoltan Varga 06956aac05 Merge pull request #1690 from nealef/master
s390x fixes/enhancements
2015-04-07 12:23:03 -04:00
Martin Baulig 8b33287f89 Merge pull request #1661 from HellBrick/connection-group-deadlock
Fixed deadlock in WebConnectionGroup.Close()
2015-04-07 18:16:26 +02:00
Neale Ferguson f6294778fe decimal-ms.c:
- Fix handling of lo64 on big endian systems (fixes 28672)

mono-endian.h:
- Add optimization for s390x read64/read32/read16 operations

exceptions-s390x.c:
- Add profiling support for exception handler
2015-04-07 12:15:43 -04:00
Zoltan Varga 15a5ae7a01 [runtime] Fix the arm build. 2015-04-07 11:35:15 -04:00
Zoltan Varga 20bd088cbb [runtime] Fix the mobile build. 2015-04-07 10:57:50 -04:00
Marek Safar 4d4b9e652d [mcs] Clone stack-alloc type expression. Fixes #28774 2015-04-07 16:34:28 +02:00
Marek Safar 2b1e2322a0 [mcs] Report missing property accessor for auto-implemented properties only when base has it. Fixes #28772 2015-04-07 16:11:23 +02:00
Alex Rønne Petersen d33c6107b5 Remove old make-bundle stuff.
This has all since been replaced with mkbundle.
2015-04-07 15:05:23 +02:00
Alex Rønne Petersen c6133ee765 Remove outdated TODO files in the mono subdirectory. 2015-04-07 15:05:07 +02:00
Alex Rønne Petersen cea435f68d Remove mono/mini/README.
No real information in this one.
2015-04-07 14:56:38 +02:00
Alex Rønne Petersen 22e2de6529 Remove mono/mini/mini.prj.
This hasn't been updated for ages.
2015-04-07 14:55:25 +02:00
Marek Safar 0d79ff6979 [mcs] Bump ikvm to get fixed known custom attribute handling. Fixes #28014 2015-04-07 14:53:05 +02:00
Alex Rønne Petersen d34f71c4ca [profiler] Remove the old version of the log profiler. 2015-04-07 14:52:22 +02:00
Alex Rønne Petersen 1657026514 [profiler] Remove old mono-cov profiler.
We're replacing this with coverage support in the log profiler.
2015-04-07 14:51:27 +02:00
Alex Rønne Petersen 4cd4437b1f Remove mono/profiler/log-profiler.txt.
This is just the man page.
2015-04-07 14:49:28 +02:00
Alex Rønne Petersen 467ca088b6 Remove outdated documentation from the docs subdirectory. 2015-04-07 14:46:41 +02:00
Alex Rønne Petersen 7fd61974ba Remove old notes subdirectory. 2015-04-07 14:41:23 +02:00
Alex Rønne Petersen 44f87d758e Remove build-mingw32.sh.
This script has not been maintained for a very long time and (as far
as I know) is not used by anyone.
2015-04-07 14:41:22 +02:00
Alex Rønne Petersen b39e7e9d78 Remove AUTHORS file.
We've tried to keep up-to-date files/pages on active maintainers and it's
failed every time. This file is no exception.
2015-04-07 14:41:22 +02:00
Alex Rønne Petersen 4f510a6d02 Remove README.vsnet as it's largely irrelevant now. 2015-04-07 14:41:21 +02:00
Alex Rønne Petersen 455debc3d4 Remove spec file as we don't use it anymore.
See: https://github.com/directhex/mono-snapshot
2015-04-07 14:41:18 +02:00
Gabriel Garcia 2dcdfe76d0 [System] Fix DeflateStream throw on empty flush, double flush. Fixes #28777 2015-04-07 06:22:32 -04:00
Alex Rønne Petersen 54ab50194a [profiler] Update data format version.
ed663c84a6 introduced a new enum value.
2015-04-07 06:21:37 +02:00
Zoltan Varga c1d442bdc5 Merge pull request #1688 from alexanderkyte/handle_changing_processor_num
[runtime] Use _SC_NPROCESSORS_CONF not _SC_NPROCESSORS_ONLN
2015-04-06 22:38:48 -04:00
Zoltan Varga 2477b7e3c9 [runtime] Allocate more space to thunks in dynamic methods. Fixes #28747. 2015-04-06 21:45:07 -04:00
Alexander Köplinger a579b35829 Fix build broken by 4de22ecb21
config.h needs to be included before HAVE_COMPLEX_H is used, or it won't work.
2015-04-07 03:19:28 +02:00
Rodrigo Kumpera 4de22ecb21 [config] Move the complex.h check to autoconf instead of a PLATFORM_ANDROID check. 2015-04-06 18:38:47 -04:00
Rodrigo Kumpera 4732cbd1db Merge pull request #1686 from akoeplinger/integrate-net20_35-reference-assemblies
Integrate binary reference assemblies for v2.0/3.5 into the build system
2015-04-06 17:21:31 -04:00
Zoltan Varga 50b8ab45ef [runtime] Fix a double free when freeing some wrapper caches. 2015-04-06 17:13:19 -04:00
Rodrigo Kumpera d1dc58df4e [mini] Fix DISABLE_JIT support for simd. 2015-04-06 16:01:40 -05:00
Zoltan Varga 0f188ab4c4 [runtime] Remove unused wapi_interrupt_thread () fuction. 2015-04-06 16:05:29 -04:00
Alexander Kyte 76ecc392cd [runtime] Use _SC_NPROCESSORS_CONF not _SC_NPROCESSORS_ONLN
We had a failing arm test which exposed that our caching of the
number of processors was leading to some inconsistencies when
the number of processors increased. TODO: Use the actual number of
online processors when rebalancing threadpool.
2015-04-06 15:42:49 -04:00
Marcos Henrich 24748ce981 Merge pull request #1624 from esdrubal/getprocesstimes
[runtime] GetProcessTimes now works with all processes.
2015-04-06 19:46:31 +01:00
Zoltan Varga 8d5eb9ec60 [runtime] Remove unused io-layer/system.{c,h}. 2015-04-06 14:46:46 -04:00
Alexander Köplinger 25f5d50737 Integrate binary reference assemblies for v2.0/3.5 into the build system
Rename the net_4_0 profile which is already only used to trigger copying of reference assemblies
to binary_reference_assemblies and include the 2.0/3.5 files there. This should make it easier
to add more profiles in the future and doesn't clutter the build system as much as making separate
net_2_0 and net_3_5 profiles that do the same.
2015-04-06 20:37:34 +02:00
Marcos Henrich 9abdfead5c [corlib] Added test for Convert.ToInt64 and ToUInt64 overflows.
Added tests cover #17817.
2015-04-06 19:19:46 +01:00
Rodrigo Kumpera ffd38a0fa4 Merge pull request #1665 from alexanderkyte/sgen-alloc-assert
[runtime] Do not set flag to skip initialization of generic classes. Lea...
2015-04-06 14:14:20 -04:00
Alexander Kyte f985c6809b [runtime] Overwrite stacktrace for exception on re-throw. Fixes #1856.
This fixes a bug where we did not completely mimic .NET's exception handling.

We previously held onto the stacktrace when an exception was thrown if it already had one. This differs from how .NET behaves, which is to always set the stacktrace to the place that it was last thrown.

Ex:

using System;

class C
{
    static Exception e;

    static void Throw ()
    {
        try {
            int.Parse (null);
        } catch (Exception ex) {
            e = ex;
        }
    }

    public static void Main ()
    {
        Throw ();

        try {
            throw e;
        } catch (Exception ex) {
            Console.WriteLine (ex.StackTrace);
        }
    }
}

Would previously output:

  at System.Int32.Parse (System.String s) [0x00000] in <filename unknown>:0
  at C.Throw () [0x00000] in <filename unknown>:0

when

   at C.Main()

is what .NET output. After this commit we output the same stacktrace as .NET.
2015-04-06 13:24:47 -04:00
Rodrigo Kumpera 24a328b83c Update the reference assemblies we ship in mono. 2015-04-06 12:49:27 -04:00
Atsushi Eno 9d9faec5df Fix SMDiagnostics build. 2015-04-07 01:30:56 +09:00
Atsushi Eno 6c5b486073 [wcf] use different public key for mobile builds. 2015-04-07 01:30:32 +09:00
Atsushi Eno 69cbb0fb3c Add another FrameworkPublicKeyFull which is based on silverlight.pub on mobile. 2015-04-07 01:30:11 +09:00
Atsushi Eno 3fcaf601c1 Add System.ServiceModel.Internals and SMDiagnostics to the build.
They build in both desktop and mobile profiles, but the sources are
mostly unchanged i.e. they contain Windows dependent code (DllImports).

The plan here is to import everything essential in WCF as buildable
sources, then remove Windows dependencies, then implement (or bring back)
mobile-ready code. But this commit can be used for different strategies
(like, we import sources from working parts, step by step).
2015-04-07 00:11:11 +09:00
João Matos 6acb0ebc46 Merge pull request #1682 from Garciat/patch-1
[System.IO.Compression] Check for buffer overrun in DeflateStream.Write
2015-04-06 15:54:08 +01:00
Alex Rønne Petersen dbed540b63 Merge pull request #1683 from akoeplinger/fix-make-distcheck
Fix a few "make distcheck" errors
2015-04-06 16:44:30 +02:00
Alexander Köplinger 9ddafb97d0 [bcl] Fix "make distcheck"
Added a missing file to DISTFILES
2015-04-06 04:19:23 +02:00
Alexander Köplinger 26745f5685 [runtime] Fix "make distcheck"
Use $(srcdir) instead of ./ for commands so the path is correct.
Also added missing files to EXTRA_DIST.
2015-04-06 04:19:22 +02:00
Mark Probst b46fca74a1 [runtime] Fix warnings. 2015-04-05 17:42:21 -07:00
Gabriel Garcia 3ea808102c Protect against overflow
https://github.com/mono/mono/pull/1682#commitcomment-10578913
2015-04-05 17:11:01 -04:00
Alexander Köplinger 8223a8a6f2 [Mono.Parallel] Fix "make distcheck"
ConcurrentOrderedList isn't referenced in corlib's .sources file or anywhere else anymore,
so it was missing during "make distcheck".

Mono.Parallel still needs it though (and it is the only place), so move the file there.
2015-04-05 19:35:45 +02:00
Gabriel Garcia 8c3f126e70 Test: Check for buffer overrun 2015-04-05 11:57:43 -04:00
Gabriel Garcia 7e9f2d4563 Check for buffer overrun 2015-04-05 11:41:36 -04:00
Ludovic Henry 199cc80efb [threadpool] Fix FullAOT build (2) 2015-04-05 11:29:08 +02:00
Ludovic Henry bbdf534369 bump reference source 2015-04-04 17:30:26 +02:00
Marcos Henrich ff126751d5 [corlib] TimeZoneInfo.TryAddTicks is now private. 2015-04-04 15:15:57 +01:00
Mark Probst 1a43231534 [sgen] Don't assert in GC.GetTotalMemory. 2015-04-03 14:15:02 -07:00
Mark Probst ae4c1ef4e9 [sgen] Format block iteration macros. 2015-04-03 12:27:29 -07:00
Mark Probst a4e8ad333e [sgen] Remove a debug printf. 2015-04-03 11:42:57 -07:00
Marek Safar 5486ebff0c [mcs] Accessibility of protected internal members in a derived class that is nested inside another class. Fixes #28022 2015-04-03 18:11:36 +02:00
Marek Safar 8069880d39 [mcs] Mutate nested storey initialization only when needed. Fixes #28211 2015-04-03 15:46:13 +02:00
João Matos a362cb7ec4 Merge pull request #1679 from knguyen0928/master
Support more oids: aes128, aes256, sha256, sha512
2015-04-03 11:20:51 +01:00
Marcos Henrich 4614473ae5 Merge pull request #1678 from esdrubal/tzindst
TimeZoneInfo bug fixing.
2015-04-03 05:19:01 -04:00
Marcos Henrich 55e06987d3 [corlib] Refactored TimeZoneInfo DateTime overflow checks.
Added more overflow checks.
Fixed some overflow checks.
2015-04-03 03:58:49 -04:00
Zoltan Varga 50401f5f7c [amd64] Add full-aot support for the sdb trampolines. 2015-04-03 01:08:17 -04:00
Zoltan Varga d86446f8c2 [amd64] Use soft breakpoints in aot mode. 2015-04-02 19:56:25 -04:00
Mark Probst 8278dd36e9 [sgen] Increase assert levels. 2015-04-02 16:41:32 -07:00
Mark Probst d62f8e204f [sgen] Mark a function inline. 2015-04-02 16:41:32 -07:00
Mark Probst 74065cb71f [sgen] Don't CAS when setting block state. 2015-04-02 16:41:32 -07:00
Mark Probst c1385d214e [sgen] Reinstate old M&S section reserve. 2015-04-02 16:41:31 -07:00
Mark Probst 9bcdbf2558 [sgen] Remove some dead code and data. 2015-04-02 16:41:31 -07:00
Mark Probst 01930f5b48 [sgen] Have the worker state just be an integer. 2015-04-02 16:41:31 -07:00
Mark Probst 83dfb12187 [sgen] Workers use thread pool.
So we only have one worker thread that's used both for marking and,
later, for sweeping, too.
2015-04-02 16:41:31 -07:00
Mark Probst 183dc2905b [sgen] Wait for the sweep job properly. 2015-04-02 16:41:31 -07:00
Mark Probst 6fb229abc8 [sgen] Implement a simple thread pool and do concurrent sweep with it.
We cannot start threads during stop-the-world pauses (some thread APIs,
including pthreads, can deadlock), and we want to do marking and sweeping
with the same threads.  This new thread pool facility will allow that.
2015-04-02 16:41:30 -07:00
Mark Probst 8333c2f4e7 [sgen] Fix a comment. 2015-04-02 16:41:30 -07:00
Mark Probst 55a2ff8f48 [sgen] Don't unnecessarily compute object size index. 2015-04-02 16:41:30 -07:00
Mark Probst ec2572d90b [sgen] Only do a debug block iteration on a higher assert level. 2015-04-02 16:41:30 -07:00
Mark Probst 1639beff7c [sgen] Comments. 2015-04-02 16:41:29 -07:00
Mark Probst c4b9b5cbe1 [sgen] Don't repeat code and don't load multiple times. 2015-04-02 16:41:29 -07:00
Mark Probst 75cfa06054 [sgen] Rename a function to better reflect what it does. 2015-04-02 16:41:29 -07:00
Mark Probst 14626e122f [sgen] sweep_block() returns whether it actually swept. 2015-04-02 16:41:29 -07:00
Mark Probst f5f2d2fb96 [sgen] Lock-free block array.
We tag pointers to blocks that are currently being processed.  Those
must not even be dereferenced by other threads because the sweep
thread might free them at any point.
2015-04-02 16:41:28 -07:00
Mark Probst 68ba43ac72 [sgen] Clean up FIXMEs. 2015-04-02 16:41:28 -07:00
Mark Probst 578e66c235 [sgen] Just one iteration over the blocks at start of major collection. 2015-04-02 16:41:28 -07:00
Mark Probst c24e166b3e [sgen] Remove dead macros. 2015-04-02 16:41:28 -07:00
Mark Probst b5b493d2da [sgen] Assert world is stopped and not sweeping when iterating blocks. 2015-04-02 16:41:28 -07:00
Mark Probst dc9f7f0d2c [sgen] Whenever we wait for sweep, help the sweeping thread.
And since we always wait for the sweep now we can do iterations over
the blocks without taking the lock.
2015-04-02 16:41:27 -07:00
Mark Probst b36a81c904 [sgen] Simplify allowance logic.
Don't use the difference to the last collection, but just calculate the maximum heap
size and trigger a collection when it's reached.
2015-04-02 16:41:27 -07:00
Mark Probst f38b8aeccd [sgen] Count major sections before/after sweep correctly. 2015-04-02 16:41:27 -07:00
Mark Probst 216713ebb6 [sgen] num_major_sections must be updated atomically.
It's updated from nursery collections and from the sweep thread concurrently.
2015-04-02 16:41:27 -07:00
Mark Probst 98d93adfde [sgen] Write binary protocol for card scan before scanning the card. 2015-04-02 16:41:26 -07:00
Mark Probst 37068c1915 [sgen] Don't iterate over block array while it's being compacted. 2015-04-02 16:41:26 -07:00
Mark Probst 0a4d98c597 [sgen] Remove dead parameter to sweep_block(). 2015-04-02 16:41:26 -07:00
Mark Probst fcdb3a9111 [sgen] Allow card table scanning to do block checking work. 2015-04-02 16:41:26 -07:00
Mark Probst 7627baae51 [sgen] Fix initial block state.
New blocks need to be swept if they're allocated during a non-concurrent major
collection or while a concurrent major collection is running.
2015-04-02 16:41:26 -07:00
Mark Probst 440ca36610 [sgen] Comments. 2015-04-02 16:41:25 -07:00
Mark Probst 24262e02c1 [sgen] Make function for block checking wait for another potential thread. 2015-04-02 16:41:25 -07:00
Mark Probst 079804f45a [sgen] Fix M&S heap consistency checks. 2015-04-02 16:41:25 -07:00
Mark Probst b5682e3e0d [sgen] Set the block state to CHECKING with the allocated blocks lock held. 2015-04-02 16:41:24 -07:00
Mark Probst 86eb54dddd [sgen] Traverse block array from high to low in sweep thread.
The nursery collector requires that sweeping has finished, and instead
of waiting it will cooperate with the sweep thread to finish more
quickly.  The sweep thread will traverse the block array from high
indexes to low ones while the nursery collector will go from low to
high.  They will contend only very briefly when they meet somewhere in
the middle.
2015-04-02 16:41:24 -07:00
Mark Probst 9cabf9abb2 [sgen] Factor out function that checks individual blocks for sweeping. 2015-04-02 16:41:24 -07:00
Mark Probst 60078aecf6 [sgen] Binary protocol entries for block alloc/free/change state. 2015-04-02 16:41:24 -07:00
Mark Probst 3b1059b824 [sgen] Card clearing and moving to shadow cards don't require sweep. 2015-04-02 16:41:23 -07:00
Mark Probst fdfaade45e [sgen] Concurrent sweep 2015-04-02 16:41:23 -07:00
Mark Probst 7412b449e9 [sgen] Replace swept with more detailed block state. 2015-04-02 16:41:23 -07:00
Mark Probst 8e8efe39dd [sgen] On forced major collections, free blocks. 2015-04-02 16:41:23 -07:00
Mark Probst bfdfbe1206 [sgen] Make memory governor ready for concurrent sweep. 2015-04-02 16:41:22 -07:00
Mark Probst e6699baa6c [sgen] Sweep state instead of have_swept. 2015-04-02 16:41:22 -07:00
Mark Probst 0caf65b147 [sgen] Make slots free list lock-free. 2015-04-02 16:41:22 -07:00
Mark Probst 788b7846f2 [sgen] Guard allocated block array with a mutex.
Both the concurrent sweep thread as well as the nursery collector will
need access to the block array.  Until we've made that lock-free,
we're simply using a lock.
2015-04-02 16:41:22 -07:00
Mark Probst 207f2a7475 [sgen] Function for querying whether world is stopped. 2015-04-02 16:41:21 -07:00
Mark Probst 1fbaf720cf [sgen] Split sweeping into three parts: start, block loop, finish. 2015-04-02 16:41:21 -07:00
Alexander Köplinger 7f97d6fb3c [System.Data] Fix 'make dist' 2015-04-03 00:23:26 +02:00
Zoltan Varga 0551f69b7e Merge pull request #1680 from schani/feature-profiler-exception-handling
[profiler] Add missing code buffers for exception handling.
2015-04-02 17:33:07 -04:00
Mark Probst ed663c84a6 [profiler] Add missing code buffers for exception handling. 2015-04-02 14:12:31 -07:00
Zoltan Varga 9ca4dc118e [llvm] Emit division by zero/overflow checks for div/rem opcodes inside eh clauses, this is needed because llvm is not aware that these instructions can raise exceptions. 2015-04-02 16:34:24 -04:00
Sebastien Pouliot 7934663bb8 [linker] Ensure updated Scope for exported types (e.g. unlinked PCL facade assemblies in a Nuget) [#28617] 2015-04-02 15:43:33 -04:00
Sebastien Pouliot deda3beb52 [tools] Fix mono-cil-strip to return non-zero on failure [#28617] 2015-04-02 15:41:38 -04:00
Khoa Nguyen 921b855093 More test for RSA Oid from FriendlyName 2015-04-02 13:14:55 -05:00
Khoa Nguyen 37a0a011d5 Add tests for supporting more oids: aes128, aes256, sha256, sha512 2015-04-02 13:09:43 -05:00
Zoltan Varga a1db9aed23 Revert "[runtime] Use mono_set_pending_exception () in a few more places."
This reverts commit 0ae611a9eb.

Revert this as it causes crashes in the System.ServiceModel tests.
2015-04-02 12:39:57 -04:00
Khoa Nguyen 2ed62415b6 Support more oids: aes128, aes256, sha256, sha512 2015-04-02 10:50:43 -05:00
Marek Safar ede464c4e0 [mcs] Check best dynamic candidate type parameters constrains only if it's single candidate. Fixes #28653 2015-04-02 17:34:51 +02:00
Marek Safar 759c8dcfa3 [mcs] Contextual var keywork cannot be shadowed by a namespace. Fixes #28648 2015-04-02 17:34:51 +02:00
Marek Safar 72d7a092c5 [mcs] DefaultParameterValue treats dynamic as object. Fixes #28645 2015-04-02 17:34:51 +02:00
Marcos Henrich e427b80122 [corlib] Fixed ParseTZBuffer with DST periods longer than a year.
AdjustmentRule specifies a DST period that starts and ends within a year.
When we have a DST period longer than a year, the generated AdjustmentRule may not be usable.
Thus we fallback to the transitions.
Fixes #24086.
2015-04-02 16:02:23 +01:00
João Matos 1dc9369450 Merge pull request #1677 from ninjarobot/fix-test-again
Fix XmlSerializationTest again.
2015-04-02 15:53:29 +01:00
Marcos Henrich bcc65637da [corlib] Removed referencesource duplicated code. 2015-04-02 15:52:00 +01:00
Dave Curylo bae8fad714 Fix XmlSerializationTest again. 2015-04-02 10:51:31 -04:00
Marcos Henrich 2ea2aa6f7f [corlib] Renamed GetUtcOffset to GetUtcOffsetHelper.
The new name is to avoid using the helper method instead of GetUtcOffset.
2015-04-02 15:47:17 +01:00
Marcos Henrich e1acc28647 [corlib] Changed TimeZoneInfo methods to use GetUtcOffset.
In some cases rules are not available so we use GetUtcOffset instead of GetApplicableRule.
2015-04-02 15:44:45 +01:00
João Matos 8a8e35f8a1 Merge pull request #1676 from ninjarobot/fix-xml-ser-tests
Corrects error in XmlSerializerTests.
2015-04-02 15:43:41 +01:00
Dave Curylo 389008df93 Corrects error in XmlSerializerTests. 2015-04-02 10:38:33 -04:00
Marek Safar ae820d9ea3 [mcs] Handle null operator inside parenthesis expression. Fixes #28172 2015-04-02 15:22:45 +02:00
Marek Safar 31557f8f7b [mcs] Type parameter hidden methods should consider default parameters. Fixes #28651 2015-04-02 14:50:20 +02:00
João Matos 33ff5d8de9 Merge pull request #1672 from ninjarobot/patch-2
XmlSerializer should set *non* readonly {V}Specified fields
2015-04-02 13:05:43 +01:00
Marek Safar 4688209dd2 [corlib] CompareInfo from reference sources 2015-04-02 12:53:25 +02:00
Dave Curylo c58f019266 XmlSerializer should set *non* readonly {V}Specified fields
Addresses an oversight in PR 1257 that caused {V}Specified fields to not be set during XML deserialization in some circumstances.

Adds test for optional value serialization round trip
2015-04-01 21:56:49 -04:00
Zoltan Varga b4b7aee0af Merge pull request #1674 from alexanderkyte/gdb_support
[runtime] Disable XDEBUG on OSX
2015-04-01 19:32:40 -04:00
Zoltan Varga 0ae611a9eb [runtime] Use mono_set_pending_exception () in a few more places. 2015-04-01 19:30:37 -04:00
Zoltan Varga 9c1cc41d97 [jit] Avoid a crash if constrained_gsharedvt_call_setup () fails. 2015-04-01 16:53:58 -04:00
Miguel de Icaza 1562789a15 [doc] Format comment so our tools can process this 2015-04-01 16:18:13 -04:00
Rodrigo Kumpera 301b370f25 [threading] Fix compilation of coop suspend on windows. 2015-04-01 16:12:00 -04:00
Alexander Kyte d6a7e425e8 [Runtime] Disable xdebug on OSX because it does not work and prevents gdb use. 2015-04-01 15:48:38 -04:00
Rodrigo Kumpera 03b7f17ecd [corlib] FEATURE_STRONGNAME_MIGRATION should be used in all profiles to avoid breaking compat. 2015-04-01 14:29:24 -04:00
Rodrigo Kumpera be570e4f3f Merge pull request #1671 from kumpera/mobile_static_fixication
Fix some of the issues with the mobile_static profile.
2015-04-01 13:04:49 -04:00
João Matos df2451caf1 Merge pull request #1673 from alexanderkyte/minor_cpp_fixes
[runtime] Fixed index comparison typo in class.c
2015-04-01 16:48:07 +01:00
Alexander Kyte 4e334d5d6a [runtime] Fixed index comparison typo in class.c 2015-04-01 11:45:11 -04:00
Ludovic Henry 1ee3dc43a9 [threadpool] Fix potential infinite loop 2015-04-01 16:39:19 +01:00
Atsushi Eno 9a9ed94626 bump referencesource to fix Sys.Data mobile_static build. 2015-04-01 23:05:08 +09:00
Rodrigo Kumpera c37e01b48d [mobile] Fix the build order between System.Numerics and System.Data due to dependencies between them. 2015-04-01 09:35:23 -04:00
Rodrigo Kumpera 69f38c0cbe [corlib] Fix the mobile_static profile. 2015-04-01 09:35:18 -04:00
Marek Safar d5be7eb756 [corlib] Update more decimal separators. Further fixes for #17615 2015-04-01 14:22:16 +02:00
Marek Safar 87d259007a [system.net.http] Use correct separator for headers tostring 2015-04-01 10:01:00 +02:00
Sebastien Pouliot e4e6710df1 [tests] ManualResetEventSlim.SpinCount depends on the number of CPU/cores and we can't assume everything as multiple CPU/cores [#28611] 2015-03-31 21:30:15 -04:00
Zoltan Varga c6b25f7f24 [jit] Use mono_error_set_pending_exception () in jit icalls. 2015-03-31 21:26:35 -04:00
Zoltan Varga b80d06dfa0 [runtime] Move mono_error_raise_exception () to metadata/ to fix a layering issue. Add mono_error_set_pending_exception () helper function. 2015-03-31 21:23:36 -04:00
Zoltan Varga acdcee6a43 [jit] Increase some trampoline sizes. 2015-03-31 18:36:11 -04:00
Zoltan Varga 5a049a5573 [llvm] Reenable support for nested clauses. 2015-03-31 18:32:27 -04:00
Zoltan Varga b3037b829b [runtime] Add more caches to mono_marshal_get_native_wrapper () to avoid mixing wrappers with/without exception checks. 2015-03-31 18:32:10 -04:00
Alexander Kyte 90ef0ccc07 [runtime] Don't set flag to skip future initialization on half-baked classes 2015-03-31 17:18:40 -04:00
Zoltan Varga 2868ae13bd [llvm] Disable support for nested clauses for now as it causes regressions in the corlib tests. 2015-03-31 17:01:11 -04:00
Zoltan Varga fda8918ad0 [llvm] Implement support for nested clauses. 2015-03-31 16:31:08 -04:00
Zoltan Varga 2c79fbd566 [amd64] Enable thunk creation when using LLVM as well. 2015-03-31 16:31:08 -04:00
Ludovic Henry e823702a31 [threadpool] Fix typo 2015-03-31 20:34:09 +01:00
Ludovic Henry 36baea1294 [threadpool] Add IO support + Needed refactoring of threadpool 2015-03-31 17:48:02 +01:00
Ludovic Henry 128b1a3e89 [threadpool] Move MonoAsyncResult invocation out of the ThreadPool 2015-03-31 17:48:00 +01:00
Ludovic Henry d7dfccb3a6 [threadpool] Move threadpool-microsoft.{c,h} to threadpool-ms.{c,h}
Avoid having really long filenames when adding threadpool-ms-io.{c,h}
2015-03-31 17:47:59 +01:00
Ludovic Henry 8ab3f6577e [threadpool] Remove RegisteredWaitHandle runtime code, as it is all in managed 2015-03-31 17:47:59 +01:00
Marek Safar 687b8bc0f3 [corlib] NumberFormatInfo from reference sources 2015-03-31 16:06:07 +02:00
Rodrigo Kumpera b65b99d6c2 [socket-io] Fix crasher in System test suite. 2015-03-30 22:52:56 -04:00
Alexander Köplinger ebf68cb708 [readme] Fix monolite instructions
EXTERNAL_MCS is misleading and wrong there, the build uses monolite automatically when appropriate.
2015-03-31 01:13:29 +02:00
Zoltan Varga 85109662c0 Add an --enable-gsharedvt configure option, same as the misnamed --enable-gsharing. 2015-03-30 16:53:48 -04:00
Marek Safar 88f920a7e8 [corlib] More globalization from reference sources 2015-03-30 18:34:40 +02:00
Marek Safar 5b1ee3ae63 [corlib] Fix commonly used encoding names 2015-03-30 18:34:40 +02:00
Marek Safar 54c079ad01 [corlib] Update culture currency separators 2015-03-30 18:34:39 +02:00
João Matos 8e8e3055f3 [runtime] Fixed a warning.
It can happen that THREAD_INFO_TYPE is already defined by a previously included header to just undefine it before re-redefining it.
2015-03-30 17:22:16 +01:00
João Matos 27a2f0ebea [mini] Fixed the build.
LLVM_FAILURE will try to `goto FAILURE` so we need to add a label to the function to make the compiler happy.
2015-03-30 17:22:15 +01:00
João Matos a3a643d447 [runtime] Enable the complex math support code on Android.
Previously I thought these implementations were not needed but dlopen () was complaining when loading libmonosgen.so on Android so we do need them.
2015-03-30 17:22:15 +01:00
João Matos 2608323126 [runtime] Add some complex math support code.
This is adapted from FreeBSD's code.
2015-03-30 17:22:15 +01:00
Zoltan Varga dd258e5f7f Bump referencesource to bcee91f8a0212e687db4d1d1a906f1f97e775051. 2015-03-30 11:32:37 -04:00
Marek Safar 8f07e6c5db Remove old files 2015-03-30 17:12:23 +02:00
Rodrigo Kumpera 7d318ea4fa [runtime] Fix the build. 2015-03-30 11:08:33 -04:00
Zoltan Varga bf271f1a40 [llvm] Fix an uninitialized variable error. 2015-03-30 08:27:57 -04:00
HellBrick 7ee2810f4a Moved WebConnectionGroup.Close() call out of the ServicePoint lock
WebConnectionGroup.Close() calls WebConnection.Close(), which takes connection lock and then takes the service point lock. Calling WebConnectionGroup.Close() leads to taking the service point lock *before* the connection lock, which leads to a deadlock.
2015-03-30 12:45:27 +03:00
Marek Safar f504a2b781 [corlib] Replace more system exceptions from reference sources 2015-03-30 11:04:31 +02:00
Zoltan Varga f9bdc96a15 [llvm] Generate code at the start of exception clauses to branch to the proper nesting clause so the EH code can branch to the innermost landing pad in the future. This is needed because LLVM always expects the innermost landing pad to be called. 2015-03-29 22:26:58 -04:00
Zoltan Varga b387b3be2c [runtime] Fix the passing of arguments to the stringbuilder ctor in mono_string_builder_new (). 2015-03-29 22:26:58 -04:00
Rodrigo Kumpera 8448c00630 [threading] Wrap socket code with coop suspend. 2015-03-29 12:11:12 -04:00
Rodrigo Kumpera 1cf48b8676 [threading] Wrap IO icalls. 2015-03-29 12:11:12 -04:00
Rodrigo Kumpera 050ac7a608 [threading] type init lock is complex enough that needs suspend protection. 2015-03-29 12:11:11 -04:00
Rodrigo Kumpera 50eea7f127 [threading] Make the loader and domain locks coop suspend aware. 2015-03-29 12:11:10 -04:00
Rodrigo Kumpera 1e15bda7da [runtime] When interning strings, allocate without holding the ldstr lock. 2015-03-29 12:11:10 -04:00
Rodrigo Kumpera 3a82ac2a59 [threading] Wrap monitor code with coop suspend. 2015-03-29 12:11:09 -04:00
Rodrigo Kumpera f582a3fbba [threading] Make thread management coop suspend aware. 2015-03-29 12:11:03 -04:00
Rodrigo Kumpera 2800db163f [threading] Make the GC lock coop suspend aware. 2015-03-28 20:46:09 -04:00
Rodrigo Kumpera d74eda461c [threading] Make n2m and m2n wrappers coop suspend aware. 2015-03-28 20:45:45 -04:00
Rodrigo Kumpera e20471ad6b [threading] Make thread start suspend aware 2015-03-28 20:44:09 -04:00
Marek Safar 45c8541ecc Merge pull request #1666 from akoeplinger/fix-mono-options-messages
[Mono.Options] Fix messages in tests that changed after bf66c00bc7
2015-03-28 09:20:05 +01:00
Zoltan Varga fb5f842089 [llvm] Extract some of the eh code into a separate function. 2015-03-27 18:49:08 -04:00
Alexander Köplinger a9230cc258 [Mono.Options] Fix messages in tests that changed after bf66c00bc7 2015-03-27 22:37:11 +01:00
Marcos Henrich c7ba3619f3 [runtime] Updates comments. 2015-03-27 20:36:35 +00:00
Marcos Henrich b27c429878 [runtime] GetProcessTimes now works with all processes.
Fixes 26363.
2015-03-27 20:36:34 +00:00
Zoltan Varga f048e17058 Add a test for the interning of String.Empty. 2015-03-27 15:24:33 -04:00
Zoltan Varga 61ec591084 [runtime] Intern String.Empty. 2015-03-27 15:23:19 -04:00
Miguel de Icaza a22b9fc66b Relicense socket-io.c to MIT 2015-03-27 14:46:05 -04:00
Marek Safar bf66c00bc7 [corlib] System exception from reference sources. Some had broken serialization support 2015-03-27 18:15:46 +01:00
Atsushi Eno 6926b5836c Use common consts in [InternalsVisibleTo] PublicKey specifications. 2015-03-28 01:46:09 +09:00
João Matos 18fe819708 Merge pull request #1664 from jbraswell/master
Fix issue with inserting null values into integer and datetime columns i...
2015-03-27 16:27:32 +00:00
Marek Safar 54b20c425d [mcs] Import of interface member which is hidden by parameterless member. Fixes #28201 2015-03-27 11:27:20 +01:00
Zoltan Varga 2640dbed40 [jit] Avoid emitting seq points in inlined methods. 2015-03-27 06:26:13 -04:00
Marek Safar 71e65a64d8 Fixes System.Design build, the missing file does not apper to be needed 2015-03-27 11:12:50 +01:00
Marek Safar 87a7d20763 Fixes System.Data build 2015-03-27 10:59:15 +01:00
Zoltan Varga 8b3cfb97eb [runtime] Synchronize the overflow checks between mono_string_new_size () and mono_gc_alloc_string (). 2015-03-27 05:51:22 -04:00
Marek Safar 02c0f8cf88 Bump reference sources to fix the build 2015-03-27 07:34:15 +01:00
Marek Safar b1f7fb3d76 [mcs] Reset flowanalysis finally scope per parameters block. Fixes #28196 2015-03-27 07:33:49 +01:00
Jonathan Braswell 7ed9d55b18 Fix issue with inserting null values into integer and datetime columns in Sql Server.
This resolves https://bugzilla.xamarin.com/show_bug.cgi?id=26546.
2015-03-26 23:43:12 -04:00
Atsushi Eno 059538c11a Merge pull request #1662 from atsushieno/import-system-data-partial
Import System.Data from referencesource
2015-03-27 10:37:21 +09:00
Rodrigo Kumpera b4d0381877 [threading] Add a coop backend. This paves the way to introduce cooperativeness into the runtime.
Coop requires the following set of rules:

-blocking code must be wrapped with MONO_PREPARE_BLOCKING / MONO_FINISH_BLOCKING
Must not read managed refs read/writes inside the block
Managed memory (i.e. inside a byte[]) must be previously pinned[1]

-state escaping transitions (lazy thunks and others sneaky n2m transitions) must be wrapped with MONO_PREPARE_RESET_BLOCKING / MONO_FINISH_RESET_BLOCKING
This lands the thread in runnable state, so be careful to keep it suspendable by following the target environment rules.

The set of rules for what runtime code can/can't are still in flux, but here's the tentative list:

== On Wrapping syscall/waits

- Wrap it on the callee. We can't necessarily know in which context the syscall will be called. This will reduce reentrancy issues as blocking is not reentrant.

- Don't go blocking while holding locks as this will certainly deadlock.

- Avoid allocating memory while holding locks.

- Annotate blocking restrictions in the comments in the same way we do it for locking.

== On aborting blocking

- Avoid it as much as possible as it might lead to unbound pauses.

- Make sure you can always restore back to blocking.

[1] Since we conservatively scan the native stack, acquiring the ref outside of the block is enough for now.
2015-03-26 19:44:17 -04:00
Rodrigo Kumpera 084cb4d103 [threading] Improve logging and troubleshooting helpers in coop suspend code.
Make sure all logging include the thread tid to ease correlation.

Add counters to check for proper balance of post/wait on the suspend semaphore.

Massive improvement in the coop suspend wait timeout crasher. It will now print
a cue card on the internal states. This makes finding the offending threads much easier.
2015-03-26 19:44:16 -04:00
Marek Safar 0d8231bb9e [system.net.http] Parse range values using long range. Fixes #26109 2015-03-26 23:46:31 +01:00
Marek Safar 723bccc551 Merge pull request #1663 from JetBrains/valueserializerattribute
Move System.Windows.Markup.ValueSerializerAttribute to System assembly
2015-03-26 23:09:32 +01:00
Marek Safar 169ec6b890 [mcs] The left-hand side of an assignment cannot contain a null propagating operator. Fixes #28435 2015-03-26 22:51:56 +01:00
Leonid Shalupov 830bf66a13 move System.Windows.Markup.ValueSerializerAttribute to System assembly, as Microsoft does in .NET Framework 4.5
See MSDN https://msdn.microsoft.com/en-us/library/system.windows.markup.valueserializerattribute(v=vs.110).aspx
2015-03-26 19:18:26 +01:00
Zoltan Varga 14c5e0e144 [llvm] Avoid registering an exception table handler in jit mode, the same info is already available using another callback. 2015-03-26 12:31:34 -04:00
Marek Safar 7a5ea5244a [mcs] Special case flowanalysis of primitive structs. Fixes #28296 2015-03-26 16:58:22 +01:00
Zoltan Varga cb9586ef9c [runtime] Update some comments. 2015-03-26 11:45:38 -04:00
Zoltan Varga 438e3b5ac3 Merge pull request #1659 from alexanderkyte/stringbuilder-referencesource
Fixed StringBuilder marshaling capacity error, and then the tests broken by fixing it.
2015-03-26 11:29:01 -04:00
Atsushi Eno abd2d59acb [Sys.Data] add InternalsVisibleTo(System.Data.DataSetExtensions). 2015-03-26 23:35:18 +09:00
Zoltan Varga 3a0929e114 Merge pull request #1658 from esdrubal/spgenerics
Improved generics in exception's stack traces and mono-symbolicate.
2015-03-26 09:43:06 -04:00
Atsushi Eno 5f8ad43886 Merge branch 'master' into import-system-data-partial 2015-03-26 22:23:49 +09:00
Atsushi Eno 37778f0cfd [Sys.Data.DSExtensions] add AsEnumerable() test. 2015-03-26 21:54:11 +09:00
Atsushi Eno cf3175c108 [Sys.Data,DSExtensions] fix hacky IsClosed() check.
It didn't work with referencesource.
2015-03-26 21:53:22 +09:00
Atsushi Eno 5e9da44ee0 [Sys.Data,DSExtensions] fix build wrt referencesource updates.
It caused name conflict with internal Sys.Data type (due to InternalsVisibleTo).
2015-03-26 21:52:18 +09:00
Marcos Henrich 84832ef221 [mono-symbolicate] Updated tool test.
Test now checks generic methods, generic classes, methods overloads, ref/out parameters.
2015-03-26 10:45:27 +00:00
Marcos Henrich 2a86ced42f [mono-symbolicate] make check now runs mono with -O=-inline.
Inlining otimization is disabled so the full call stack can be displayed.
2015-03-26 10:45:27 +00:00
Marcos Henrich dece3b4dd7 [mono-symbolicate] Improved tool stack trace handling.
Generics are no longer a problem.
2015-03-26 10:45:26 +00:00
Marcos Henrich 6aa8aa4810 [corlib] Changed Exception.GetFullNameForStackTrace to .NET behavior.
.NET displays the method definition generic argument names instead of types.
2015-03-26 10:45:25 +00:00
Marcos Henrich 4b46084c96 [corlib] Exception stack traces now show method index if needed.
Method index will be set if the method metadata token is shared by multiple generic specializations.
For StackFrame.GetILOffsetFromFile to work with generics methods a method index is required.
2015-03-26 10:45:25 +00:00
Marcos Henrich 93c9e38273 [runtime] .msym now stores method index.
The method index is required to disambiguate between generic methods that share the same metadata token.
2015-03-26 10:45:24 +00:00
Marcos Henrich 8420aef987 [runtime] Added function mono_aot_find_method_index.
Method index will be included in some aot stack traces, when method metadata token is not enough (e.g: generic methods).
2015-03-26 10:28:19 +00:00
João Matos e7042f6321 Merge pull request #1660 from akoeplinger/fix-zone-url-with-at-sign
[corlib] Don't strip @ char in Mono.Security.Uri for absolute path
2015-03-26 10:22:43 +00:00
Zoltan Varga 03503bc020 [runtime] Avoid a crash in mini_thread_cleanup () for attached threads. 2015-03-26 06:06:29 -04:00
Zoltan Varga 861ea992dc [readme] Remove xamcore reference. 2015-03-26 06:04:11 -04:00
Zoltan Varga b9abb7c34b Bump referencesource to pick up 3176b17a2c636dfd5f885435f8449598ecd4197f. 2015-03-26 06:03:16 -04:00
Zoltan Varga 3e14fe5bf3 [runtime] Initialize String.Empty from native code to allow removal of String:.cctor (). 2015-03-26 06:03:15 -04:00
Marek Safar 26a8c65af8 [mcs] Report abstract member hiding only for members which one can override. Fixes #28213 2015-03-26 10:07:55 +01:00
HellBrick 893bacaf9a Fixed deadlock in WebConnectionGroup.Close()
The fix is similar to the one used in the TryRecycle() method: we defer connection closing until after we've left the lock. The original bug: https://bugzilla.xamarin.com/show_bug.cgi?id=27348
2015-03-26 11:48:30 +03:00
Zoltan Varga f8c885d697 [mkbundle] Use mingw assembler on windows. 2015-03-26 04:18:33 -04:00
Atsushi Eno 8b7ad259c5 Fix winforms tests that don't match .NET behavior. 2015-03-26 10:46:11 +09:00
Alexander Köplinger d759188d30 [corlib] Don't strip @ char in Mono.Security.Uri for absolute path
When creating a Mono.Security.Uri with the string "file:///var/lib/jenkins/workspace/test-mono-mainline@2/..."
(happens sometimes in System.Security.Policy.Zone-related unit tests on Jenkins) the current implementation
strips everything up until the @ sign.

Zone thinks the file doesn't exist locally as the Uri.LocalPath doesn't refer to a valid file on disk
anymore and this results in an incorrect zone value, making the tests fail.

Fixing this by treating the @ char differently when it is in an absolute path (as is done for other chars).
2015-03-26 02:35:57 +01:00
Martin Baulig 6808e6a5e6 [System]: Fix the AllowWriteStreamBuffering check. Bugs #26640 and #26936.
Added new tests for this to the web-tests:
https://github.com/xamarin/web-tests/commit/e7b5ac42897e629e9e4107cf6f9ae9e0a9fef45a

and re-enabled this one, which regressed:
https://github.com/xamarin/web-tests/commit/046da02c631c8799c7ab5025cd3b685f4a3e66f6
2015-03-26 01:26:19 +01:00
Martin Baulig a081090e77 Bump referencesource and add test for the problem. 2015-03-25 22:33:02 +01:00
Marek Safar ffd377bb96 Update failing test 2015-03-25 20:28:50 +01:00
Marek Safar eec68d08b1 [System.Runtime.Serialization.Formatters.Soap] A test fix to remove hashtable order dependency 2015-03-25 20:07:42 +01:00
Alexander Kyte dd4a723754 [corlib] Fixed StringBuilder construction bugs in marshalling caused by changes to capacity setting. 2015-03-25 14:19:34 -04:00
Marek Safar df423753f1 Revert "[mcs] Special case flowanalysis of primitive structs only when they are imported. Fixes #28296"
This reverts commit b50e898ece.
2015-03-25 19:17:31 +01:00
Rodrigo Kumpera 579a7b4748 [threading] Reorganize code to work with the coop backend.
This splits the native backend from core functionality it needs to provide. For example,on posix, we want to
use the pthread_create code regardless of the backend enabled.
2015-03-25 13:49:38 -04:00
Rodrigo Kumpera 17896b0902 [threading] Introduce a pair of states to handle native suspend.
Native code should not normally be in runnable state. That's reserved only for managed code. In theory.
In practice any code that can witness the managed heap must be in the runnable state.

This in practice means all runtime code (icalls) and embeders. Right now lets focus on the runtime side.

The solution for this is to wrap all calls that could lead to unbound suspension in code that coordinates
with the GC - most syscalls that can block. This is realized with a pair of additional thread states.

1)Blocking: This the state where the runtime is doing something that can potentially block. The suspend count
will be > 0 if the current thread is suspended. In practice it won't suspend, just wait on resume.

2)Blocking and suspended: When leaving the blocking state, if the thread has a pending suspend, we transition
to this state while waiting for resume.
2015-03-25 13:49:38 -04:00
Rodrigo Kumpera ae58b3085a [threading] Move jit_data from MonoThreadInternal to MonoThreadInfo. Cleanup jit attach code to support earlier attaching.
This move allows us to save the thread state much earlier on. In addition to the move, we now produce thread contexts without
the JIT TLS set. This might end up been an issue in some corner cases, just like with domain, so we'll address those when
they show up.
2015-03-25 13:49:38 -04:00
Rodrigo Kumpera ae8a8fb08d [threading] Surface mono_thread_info_current_unchecked. 2015-03-25 13:49:37 -04:00
Rodrigo Kumpera 98b283714a [threading] Log the thread tid instead of the MonoThreadInfo pointer.
Other places are already logging tid so this makes correlation possible.

TID is a better pick than the MonoThreadInfo pointer as it's easier to find the thread on gdb.
2015-03-25 13:49:37 -04:00
Rodrigo Kumpera b614f16800 [threading] Add configure option to enable cooperative suspend. 2015-03-25 13:49:37 -04:00
Atsushi Eno ba779e83fd [Sys.Data] fix data adapter tests. ByteFx.Data and Npgsql are gone. 2015-03-26 02:22:00 +09:00
Marek Safar b50e898ece [mcs] Special case flowanalysis of primitive structs only when they are imported. Fixes #28296 2015-03-25 17:59:48 +01:00
Zoltan Varga fb08db1765 [jit] Trucate the shift amount in the long shift emulation functions to better mirror the behavior of the processor shift instructions. 2015-03-25 12:39:30 -04:00
Atsushi Eno 2737a5a2f8 bump referencesource. 2015-03-26 01:28:57 +09:00
Marek Safar f46e880311 [corlib] Add missing file 2015-03-25 17:26:47 +01:00
Atsushi Eno 0f1738c6bf System.Design.dll depended on System.Data internals so remove deps.
The old internal types don't exist in new System.Data.dll.
2015-03-26 01:25:04 +09:00
Atsushi Eno f763a00632 [Sys.Data] reuse our SqlClient implementation.
Basically Microsoft SqlClient implementation is full of Windows dependencies
that doesn't work elsewhere. Our implementation has been fully managed
TDS implementation, so we want to bring it back.

This only builds and is not known to "work" yet.
2015-03-26 01:25:04 +09:00
Atsushi Eno 45b00acfd2 [Sys.Data] there are many tests that were unverified on .NET. Fix them. 2015-03-26 01:25:03 +09:00
Atsushi Eno b232392703 [Sys.Data] Fix bogus tests: DataRelation cannot be created for non-dataset cols. 2015-03-26 01:25:02 +09:00
Atsushi Eno 92ca41585b Fix mobile builds with several #if-s in referencesource. 2015-03-26 01:25:02 +09:00
Atsushi Eno bc92f49109 bump referencesource. 2015-03-26 01:25:02 +09:00
Marek Safar d8f53a2d39 Merge pull request #1644 from ztone/eval_class_attr
[eval] Allow class attributes
2015-03-25 17:24:55 +01:00
Atsushi Eno c48e31fa9e [Sys.Data] replace dummy Res.cs messages with real ones.
It uses ../System.XML/genresstrings.sh.
2015-03-26 01:24:24 +09:00
Atsushi Eno 3d46f1d9c7 [System.Data] completely replace sources with referencesource.
Hence, it does NOT work fine due to various win32/native dependencies
that need to be replaced.
2015-03-26 01:24:24 +09:00
Atsushi Eno 2ffd706212 [build/common] Add EcmaFullKey. 2015-03-26 01:24:23 +09:00
Marek Safar de86cb955b [mcs] Resize identifier buffer in all cases. Fixes #28292 2015-03-25 17:17:23 +01:00
Alexander Kyte 828e749949 [corlib] Fixed wrongly changing capacities in stringbuilder marshalling 2015-03-25 12:14:06 -04:00
Marek Safar db2a67f0d5 [mcs] Fix parsing of interpolated strings inside conditional expression. Fixes #28293 2015-03-25 16:34:29 +01:00
Alexander Köplinger 31bc329ddc Fix a typo and code indentation in readme.md 2015-03-25 15:28:24 +01:00
Marek Safar e58097e957 [corlib] String from reference sources, fixes mostly string.format issues 2015-03-25 15:08:06 +01:00
João Matos 2faa7dc28d [runtime] Fixed the build on Android by relying on header checking for system headers. 2015-03-25 14:04:40 +00:00
João Matos df23dc46c6 [runtime] Fixed complex.h usage in MS's thread pool to work in Android.
Android does not provide complex.h in the API levels that we compile against so bundle our own header (based on the one from FreeBSD).

Turns out GCC already provides built-in handling for the complex functions used by the code so there's no need to provide our own implementations.
2015-03-25 14:04:40 +00:00
João Matos 9577c879ee Merge pull request #1657 from alexrp/disable-perf-events
[profiler] Disable `perf` events by default.
2015-03-25 12:59:30 +00:00
Zoltan Varga 5c275e72d7 [io-layer] Fix the freeing of MonoProcess structures. Fixes #28209. 2015-03-25 08:32:14 -04:00
Alex Rønne Petersen ce418756c9 [profiler] Disable perf events by default.
As it turns out, `perf` support crashes/hangs on a lot of Linux
kernels in the wild, and produces no output on some Android devices.
So, given that using a signal + helper thread is more reliable, use
it by default and make `perf` support optional.

The configure flag is now `--enable-perf-events`.
2015-03-25 13:22:39 +01:00
Alex Rønne Petersen 97b59a9741 [profiler] Avoid a slow path in mono_jit_info_table_find (). 2015-03-25 13:13:38 +01:00
Alex Rønne Petersen 7e163fce46 [profiler] Really fix looking up JIT info for AOT'd methods.
mono_aot_get_method () will not necessarily put methods into the
MonoDomain::jit_code_hash table. But it does return an IP that we
can use to look up the JIT info with mono_jit_info_table_find ().
2015-03-25 13:04:43 +01:00
Marek Safar 7ade5f7d7b [mcs] Allow built-in types to have partial declaration 2015-03-25 12:34:26 +01:00
Zoltan Varga fd7f2f07f0 [runtime] Revert eaf200b37b and all fixes to it since it still causes hangs. 2015-03-25 05:14:42 -04:00
Zoltan Varga c8c2d227be [runtime] Avoid returning null from Marshal.AllocCoTaskMem () if size is 0. Fixes #28383. 2015-03-25 01:29:27 -04:00
Zoltan Varga 8e091fd004 [runtime] Fix list removal in eaf200b37b. 2015-03-25 01:07:13 -04:00
Miguel de Icaza 0648b50cdf Add submodule instructions 2015-03-24 22:13:10 -04:00
Alex Soto cdfc2d6b9a [MonoDataSqlite] Add test for Xamarin.iOS specific bug 27864
src: https://bugzilla.xamarin.com/show_bug.cgi?id=27864

As of iOS 8.2 Apple updated Sqlite and broke queries that used to work
pre iOS 8.2 like the select command in this test, The pruppose of this
test is to know when apple fixes this. Expected test behaivour is as follows.

* If iOS 8.2+ Test will pass as long as apple does not fix the bug
* If iOS < 8.2 Test will pass as it does work as expected
* If iOS 8.2+ and apple fixed bug 27864 test will fail and we will need to
  remove the fail check on lines 105 and 106
2015-03-24 17:24:02 -06:00
Zoltan Varga b4fc24bab0 [amd64] Fix OP_SHR_IMM/OP_SHL_IMM. 2015-03-24 17:54:51 -04:00
Zoltan Varga 423cd5280f [runtime] Fix another regression caused by eaf200b37b. 2015-03-24 16:51:31 -04:00
Zoltan Varga d03981860e [arm] Handle OP_SEQ_POINT opcodes during peephole optimizations correctly. 2015-03-24 16:46:44 -04:00
Zoltan Varga afb1de8b7c Merge pull request #1655 from ghuntley/patch-1
corrected spelling mistakes.
2015-03-24 16:44:02 -04:00
Geoffrey Huntley 6cb40b05fd corrected spelling mistakes. 2015-03-25 07:38:58 +11:00
Zoltan Varga e4fc9ed0cd [runtime] Fix an uninitialized memory error added by eaf200b37b. 2015-03-24 14:56:06 -04:00
Zoltan Varga eaf200b37b [io-layer] Fix the freeing of MonoProcess structures. Fixes #28209. 2015-03-24 12:35:41 -04:00
Sebastien Pouliot b07e58ed99 [tests] Tweak MemoryMappedFile test case that fails on iOS/ARM64 [#27667]
Filled with Apple. From bug report:

The problem appears to be caused by a bug in mmap on the arm64 ios.

In this test, we request a page and mmap returns successfully, but when trying
to access the mapped memory, the program crashes after the 4097th byte, meaning
that it only maps us 4kb(???). It should be mentioned that on arm64 ios the
page size is 16kb.
2015-03-24 10:46:33 -04:00
Marek Safar f0e39b7bab [corlib] ngen attributes from reference sources 2015-03-24 14:59:52 +01:00
Marek Safar 3d351a3b9d [corlib] Remove unused files 2015-03-24 14:59:52 +01:00
Marek Safar e16e002a3a [corlib] ExceptionServices from reference sources 2015-03-24 14:59:52 +01:00
Marek Safar 98fce55b7e [corlib] Debugger attributes from reference sources 2015-03-24 14:59:52 +01:00
João Matos 381708c6cd Merge pull request #1634 from StephenMcConnel/bug-28025
Show thumbnail images in SWF.(Open,Save)FileDialog
2015-03-24 11:31:51 +00:00
Ludovic Henry 54be424882 [runtime] Remove unnecessary winbase.h header include on Windows 2015-03-24 11:28:39 +00:00
João Matos 5190434004 Merge pull request #1652 from debuglevel/bugfix-crosscompile
fixed case-sensitive file name for cross compilation
2015-03-24 11:25:08 +00:00
Zoltan Varga 6b4119a8e1 Merge pull request #1588 from BrzVlad/feature-aot-wbarrier
AOT write barrier method
2015-03-24 05:29:29 -04:00
Marek Safar e82dc02e27 Merge pull request #1638 from esdrubal/servicepoint
[System] Fixed RemoveConnectionGroup concurrent issue.
2015-03-24 10:25:57 +01:00
Zoltan Varga fe15af27f1 Merge pull request #1632 from alexanderkyte/bug24118
[corlib] Fixed change in 4b4ddb66b3 that prevented use of remoting fast path
2015-03-24 05:24:58 -04:00
Marek Safar e959cc70a4 [system] FrameworkName from reference sources 2015-03-24 09:30:03 +01:00
Marek Safar 273377896c [mcs] Emit correct assignment to ref pointer 2015-03-24 08:43:54 +01:00
Marek Safar 00da227b09 Fixes build 2015-03-24 07:27:57 +01:00
Marek Safar 5928965bda [system.windows.forms] Add AssemblyNamesTypeResolutionService to correctly fix 78b63f29d5 2015-03-24 07:15:03 +01:00
Alex Rønne Petersen 8ce49aeb39 Typo fix... 2015-03-24 02:44:52 +01:00
Alex Rønne Petersen 8cfe0fb9e8 [arm] Also fix OP_ATOMIC_STORE_R4. 2015-03-24 02:43:15 +01:00
Miguel de Icaza d84ec9f6fd Man page update 2015-03-23 21:31:12 -04:00
Mark Probst 569e0265da Merge pull request #1596 from schani/feature-sgen-improvements
Small SGen fixes and improvements
2015-03-23 15:36:03 -07:00
Mark Probst 8a7aeb7a97 [sgen] Fix slot size calculation.
The way we calculated slot sizes was very brittle when it came to
small slots.  Reducing the size of the block header could trigger it
skipping an important small size class, which would lead to increased
memory usage and slower execution times.

Now we always produce all possible small slot sizes, up to four times
the minimum object size.
2015-03-23 15:34:06 -07:00
Mark Probst 27d742e99c [sgen] Remove stealing.
We only have one worker thread.  There is no point in stealing.
2015-03-23 15:34:06 -07:00
Mark Probst 4ee3709d17 [sgen] Save more space in M&S block infos. 2015-03-23 15:34:06 -07:00
Mark Probst 0078135fe1 [sgen] Do pinning of M&S blocks in one pass. Saves time and memory. 2015-03-23 15:34:05 -07:00
Mark Probst db7f017433 [sgen] Store worker's job names for debugging. 2015-03-23 15:34:05 -07:00
Mark Probst 19dc5a91a0 [sgen] Allow skipping of entries in sgen-grep-binprot. 2015-03-23 15:34:05 -07:00
Mark Probst eb24f1cb56 [sgen] Some clarifying comments and rearrangements. 2015-03-23 15:34:05 -07:00
Mark Probst 9dada5274f [sgen] Remove dead code. 2015-03-23 15:34:05 -07:00
Mark Probst d4c27ef577 [sgen] Binary protocol entry for pin-staging cemented objects. 2015-03-23 15:34:04 -07:00
Mark Probst 43752c07ce [sgen] Only scan mod-union in LOS on marked objects. 2015-03-23 15:34:04 -07:00
Mark Probst db00d189de [sgen] Free lists in blocks must be volatile. 2015-03-23 15:34:04 -07:00
Mark Probst 47fc9ff800 [sgen] Rename a callback for clarity. 2015-03-23 15:34:04 -07:00
Mark Probst 4f546cdcb4 [sgen] Don't scan until jobs done in worker thread.
The jobs must always have priority because the concurrent collector
waits for them to finish before restarting the world.
2015-03-23 15:34:03 -07:00
Mark Probst 5b009431e7 [sgen] Fix names and remove superfluous parameters. 2015-03-23 15:34:03 -07:00
Mark Probst d08417cfe7 [sgen] Move debug code to sgen-debug.c. 2015-03-23 15:34:03 -07:00
Mark Probst a0e7914ef8 [sgen] Rename have_computed_minor_collection_allowance to free_swept_blocks.
Because that's what it actually does.
2015-03-23 15:34:03 -07:00
Mark Probst 3b842277dd [sgen] Remove superfluous function indirection. 2015-03-23 15:34:03 -07:00
Mark Probst d877651ddd [sgen] Replace have_swept pointer with callback.
We want to use a state variable instead of `have_swept`, so we need a callback
to abstract.
2015-03-23 15:34:02 -07:00
Mark Probst f1d0587eca [sgen] Don't pass redundant scan_mod_union to major_finish_collection(). 2015-03-23 15:34:02 -07:00
Mark Probst cb84d02dad [sgen] Disable cementing for concurrent M&S.
The code just worked because it never reset cementing.  It needs to be
completely rewritten.

With cementing enabled, at the start of a major concurrent
collection, we cannot reset it.  That's because if we have
cemented objects, some remsets to them will be missing, and the
major collector does not scan the whole heap immediately, like
the non-concurrent one does.

The proper way to do it seems to be to reset cementing before
finishing a concurrent collection.  All major objects that point
to formerly cemented objects must either be marked in the
mod-union table or the current card table.  When we scan the card
tables, we should be able to just evict objects.

Currently, the finishing collection pause still does some
scanning via the worker thread.  This might be a problem.
2015-03-23 15:34:02 -07:00
Mark Probst af0a841ac1 [sgen] Don't re-check reference after marking in concurrent mark.
If the reference was modified, it was done by the mutator, in which case it will
have marked the card if necessary.
2015-03-23 15:34:02 -07:00
Sebastien Pouliot 298962b7dd [tests] Tweak DateTime.AddMillisecondsOutOfRangeException* tests to work on ARM [#28311] 2015-03-23 18:08:47 -04:00
Neale Ferguson ca5bebb67c Fix decimal comparison by using signed char comparison of signs; Fix size of jmp instruction sequence 2015-03-23 17:43:41 -04:00
Rodrigo Kumpera cee3ef1011 Merge pull request #1631 from alexanderkyte/stringbuilder-referencesource
Switch to using referencesource StringBuilder, with runtime fixes and tests
2015-03-23 17:18:59 -04:00
Rodrigo Kumpera 01d33033b6 Merge pull request #1595 from directhex/randomize-tcp-ports-in-tests
Randomize tcp ports in tests
2015-03-23 17:09:13 -04:00
Rodrigo Kumpera 6e60374fc3 [threading] Use a RT signal for abort when possible. 2015-03-23 16:09:36 -04:00
Zoltan Varga fc846a4acb [arm] Fix OP_ATOMIC_LOAD_R4. 2015-03-23 14:25:17 -04:00
Marek Safar 919684c7af [system] Don't replace CategoryAttribute value with key when not found. Fixes #28331 2015-03-23 17:44:02 +01:00
Zoltan Varga 68106cd2f5 Fix a warning. 2015-03-23 11:51:39 -04:00
Marek Safar 52003dc6f7 [corlib] System.Resources from reference sources 2015-03-23 16:49:15 +01:00
Jo Shields 85c7025f9d Add port randomization to ClientWebSocketTest and HttpListenerTest
These two are consistently failing due to port re-use. Other hard-coded
ports exist, but let's target the *known* issues primarily, and can
handle the others ad-hoc if they demonstrate that they're problematic.
2015-03-23 14:42:16 +00:00
Jo Shields 02981d6bc0 Add a helper class to assign a random port for a test.
This helps in cases where two copies of the test suite are
running simultaneously, and both want to use the same hard-coded
ports in tests.
2015-03-23 14:40:44 +00:00
Marc Kohaupt 9af71e92aa fixed case-sensitive file name for cross compilation 2015-03-23 14:43:14 +01:00
João Matos 2255f5d2b3 Merge pull request #1646 from myrup/master
TimeZoneInfo.Local improvements
2015-03-23 13:02:47 +00:00
Marek Safar 2dd0f1aa0b [corlib] MethodBase from reference sources 2015-03-23 10:59:32 +01:00
Marek Safar c32bc77dba [corlib] Member|TypeInfo from reference sources 2015-03-23 09:25:59 +01:00
Marek Safar 78b63f29d5 [system.windows.forms] Update failing test 2015-03-23 09:25:58 +01:00
Zoltan Varga 6a74b1952f [runtime] Throw an exception on allocation failure from Marshal.AllocHGlobal/ReAllocHGlobal. Fixes #28290. 2015-03-22 03:56:09 -04:00
Zoltan Varga 0e692a4699 [aot] Remove support for non-separate llvm mode. 2015-03-22 01:44:03 -04:00
Zoltan Varga 3b7b1d0ee3 [jit] Remove support for LLVM_API_VERSION < 4. 2015-03-22 01:32:17 -04:00
Jonathan Pryor 44bccacc12 Merge pull request #1641 from joelmartinez/docs-monodoc-mdoc-patches
monodoc/mdoc patches
2015-03-21 08:23:22 -04:00
Zoltan Varga afd07af772 [jit] Enable partial sharing only in full-aot mode. 2015-03-21 05:18:04 -04:00
Zoltan Varga 525132a68b [jit] Unify the handling of the type parameters in generic sharing. Instead of using the generic parameters of the generic definition for reference types, use a generated type parameter with gshared_constraint set to MONO_TYPE_OBJECT. 2015-03-20 21:38:33 -04:00
Sebastien Pouliot 48d64eb82a [tests] Some of the new decimal tests (ported from MS tests) do not work on every culture, this set one that works for them 2015-03-20 15:25:52 -04:00
Marek Safar 93310d9e66 [corlib] Remove unmanaged type IsVisible path. Fixes #28235 2015-03-20 17:38:19 +01:00
Marek Safar 50b27bb659 [corlib] Enable legacy LCID api 2015-03-20 14:50:43 +01:00
Marek Safar b5562aac99 [mcs] Test update 2015-03-20 14:50:43 +01:00
Marek Safar 32f1d4fa07 Revert "Fix more System.Web tests."
This reverts commit 7fa35b58ca.
2015-03-20 14:50:42 +01:00
Marek Safar 97384e4371 [corlib] Pointer from reference sources 2015-03-20 14:50:42 +01:00
João Matos af0be5ce1c [runtime] Check for MSVC instead of non-GCC in mono_threads_core_set_name.
This is just a small cleanup and will also work for Clang since it defines _MSC_VER in MSVC-compatible mode.
2015-03-20 13:03:55 +00:00
Marek Safar 2c95d347b6 [corlib] More simple System.Reflection types from reference sources 2015-03-20 12:25:07 +01:00
Zoltan Varga 7fa35b58ca Fix more System.Web tests. 2015-03-20 07:04:42 -04:00
João Matos c4969d2e1a Merge pull request #1647 from svedm/master
Fix duplicate sub-expressions
2015-03-20 11:02:52 +00:00
Svetoslav Karasev 6bbd7e7c4a Fix duplicate sub-expressions 2015-03-20 15:56:59 +05:00
Marek Safar e373163859 [corlib] Add new test 2015-03-20 11:20:58 +01:00
myrup 2e90ab901d Fixed TimeZoneInfo.Local windows xp issue
Windows xp StandardName property has an exception when system time is UTC.
2015-03-20 10:50:43 +01:00
Marek Safar d7c4554b90 [corlib] MemberInfoSerializationHolder from reference sources. Fixes generics serialization and other issues 2015-03-20 10:39:58 +01:00
Marek Safar 4913b6b537 [system.web] Update failing test 2015-03-20 10:17:55 +01:00
myrup 48bf9b6d29 Added null check
CreateLocal could fail in an unexpected manner. The change re-enables fall back to environment variable "TZ" and allows TimeZoneInfoNotFoundExceptions to be thrown instead of NullReferenceException.
2015-03-20 09:42:34 +01:00
Zoltan Varga ad7370256c Merge pull request #1645 from myrup/master
Fixed TimeZoneInfo.Local on windows xp
2015-03-19 23:51:21 -04:00
Zoltan Varga c43e4dd749 [aot] Fix support for direct icalls in llvm mode. 2015-03-19 23:25:45 -04:00
Zoltan Varga 3fe087c453 [jit] Use unique castclass caches in all cases. Fixes #27787. 2015-03-19 22:45:49 -04:00
Zoltan Varga c3facda138 [runtime] Fix the isinst_with_cache wrapper on 64 bit platforms. 2015-03-19 22:44:43 -04:00
myrup 9abf43e02a Fixed TimeZoneInfo.Local on windows xp
Fall back to “StandardName” subkey when “TimeZoneKeyName” isn’t present.
2015-03-20 00:39:19 +01:00
Zoltan Varga e2614fc56e [sdb] Add support for TypedReferences. Fixes #28181. 2015-03-19 19:33:26 -04:00
Zoltan Varga 9a01841382 [corlib] Implement FieldInfo.SetValueDirect (). 2015-03-19 18:59:52 -04:00
Stone Gislason 12ee824f5f [eval] Allow class attributes 2015-03-19 21:50:20 +00:00
Marek Safar 939a8f904b [corlib] Return top-level parameter custom attributes when no base methods exists. Fixes #28184 2015-03-19 22:43:00 +01:00
Zoltan Varga adccb63177 [io-layer] Avoid closing std file descriptors on shutdown. Fixes #28098. 2015-03-19 17:35:46 -04:00
Marek Safar d437ea4bbc [corlib] TypedReference from reference sources 2015-03-19 22:00:11 +01:00
Marek Safar 840c5b7e41 Merge pull request #1642 from vestild/modulebuilder-definetype
[System.Reflection.Emit] fix typo in ModuleBuilder.DefineType
2015-03-19 21:45:42 +01:00
Vlad Zaitsev bd82bd3689 [System.Reflection.Emit] fix typo in ModuleBuilder.DefineType 2015-03-20 00:42:06 +05:00
João Matos 0ff25ec2d5 [mini] Small code cleanup, check for iOS host instead of Apple/ARM. 2015-03-19 18:44:40 +00:00
João Matos 86093bbe48 [windows] Fixed thread async suspend assert.
This should be asserting for 1 instead of 0, this way we actually assert that the thread was resumed.
2015-03-19 18:44:40 +00:00
João Matos 13a1b2e747 [windows] Remove some cruft used by the old Windows installer. 2015-03-19 18:44:40 +00:00
Marek Safar 375408f92a [runtime] Remove unused icall 2015-03-19 16:28:10 +01:00
Joel Martinez 6a35acd4e1 [monodoc] Added PlatformDocApi to the list of valid related sections.
The use case here is when you are documenting a managed wrapper on top of a native platform API. This related link can be used to link to the original platform documentation for that member. This lets the reader look up the semantics of the native call without you having to duplicate the documentation in the managed reference docs; leaving you to focus your energies on documenting any unique considerations when calling this managed API.

Example:
```xml
<related type="PlatformDocAPI" href="https://msdn.microsoft.com/en-us/library/system.console.writeline">Microsoft documentation for <c>System.Console.WriteLine</c></related>
```
2015-03-19 10:41:50 -04:00
Joel Martinez 1e45f99905 [monodoc] Fixed issue generating EcmaCref URLs.
If you have a URL of the form ``T:System.Collections.Generic.Dictionary`2``, it parses correctly, but the `EcmaDesc` instance returned by the parser will throw an exception if you try to call the `.ToEcmaCref ()` method. This patch resolves this issue and returns a correctly formatted URL in this instance. Unit test included.
2015-03-19 10:41:50 -04:00
Joel Martinez 89882a6776 [mdoc] Fixes an update issue with generic and non-generic members.
The existing update was not doing a good job of matching members that have both generic and non-generic members. So for example, if you had a method, `Foo<T>`, and added a non-generic version in a future update (`Foo`); you could end up with a situation where one of the members was being duplicated.
2015-03-19 10:41:48 -04:00
Sebastien Pouliot d2b1d45390 [mono-api-html] Small simplification when 'breaking' does not apply to the rendering 2015-03-19 08:33:28 -04:00
Sebastien Pouliot fccf4b6345 [mono-api-html] Include base type changes in API diffs 2015-03-19 08:32:36 -04:00
Marek Safar a0f0aa6213 [corlib] Default FieldInfo Get|SetValueDirect should throw NotSupportedException 2015-03-19 12:42:43 +01:00
Marek Safar c1bca01981 [System] Fix SafeSocketHandle race introduced in 9ae88709db.
at System.ThrowHelper.ThrowArgumentOutOfRangeException () [0x00014] in /Users/marek/git/mono/external/referencesource/mscorlib/system/throwhelper.cs:56
  at System.Collections.Generic.List`1[System.Threading.Thread].get_Item (Int32 index) [0x0000e] in /Users/marek/git/mono/external/referencesource/mscorlib/system/collections/generic/list.cs:199
  at System.Net.Sockets.SafeSocketHandle.ReleaseHandle () [0x00052] in /Users/marek/git/mono/mcs/class/System/System.Net.Sockets/SafeSocketHandle.cs:79
  at System.Runtime.InteropServices.SafeHandle.RunRelease () [0x00091] in /Users/marek/git/mono/mcs/class/corlib/System.Runtime.InteropServices/SafeHandle.cs:203
  at System.Runtime.InteropServices.SafeHandle.Dispose (Boolean disposing) [0x00019] in /Users/marek/git/mono/mcs/class/corlib/System.Runtime.InteropServices/SafeHandle.cs:171
  at System.Runtime.InteropServices.SafeHandle.Dispose () [0x00003] in /Users/marek/git/mono/mcs/class/corlib/System.Runtime.InteropServices/SafeHandle.cs:150
  at System.Net.Sockets.Socket.Dispose (Boolean disposing) [0x0004d] in /Users/marek/git/mono/mcs/class/System/System.Net.Sockets/Socket_2_1.cs:1168
  at System.Net.Sockets.Socket.Dispose () [0x00003] in /Users/marek/git/mono/mcs/class/System/System.Net.Sockets/Socket_2_1.cs:1174
  at System.Net.Sockets.Socket.Close () [0x00009] in /Users/marek/git/mono/mcs/class/System/System.Net.Sockets/Socket_2_1.cs:1185
  at System.Net.Sockets.TcpListener.Stop () [0x0000d] in /Users/marek/git/mono/mcs/class/System/System.Net.Sockets/TcpListener.cs:296
  at System.Runtime.Remoting.Channels.Tcp.TcpServerChannel.StopListening (System.Object data) [0x00022] in /Users/marek/git/mono/mcs/class/System.Runtime.Remoting/System.Runtime.Remoting.Channels.Tcp/TcpServerChannel.cs:257
  at System.Runtime.Remoting.Channels.Tcp.TcpChannel.StopListening (System.Object data) [0x00013] in /Users/marek/git/mono/mcs/class/System.Runtime.Remoting/System.Runtime.Remoting.Channels.Tcp/TcpChannel.cs:105
  at System.Runtime.Remoting.Channels.ChannelServices.UnregisterChannel (IChannel chnl) [0x00057] in /Users/marek/git/mono/mcs/class/corlib/System.Runtime.Remoting.Channels/ChannelServices.cs:463
  at MonoTests.Remoting.CallsDomainServer.Stop () [0x00012] in /Users/marek/git/mono/mcs/class/System.Runtime.Remoting/Test/BaseCalls.cs:445
  at (wrapper remoting-invoke-with-check) MonoTests.Remoting.CallsDomainServer:Stop ()
  at (wrapper xdomain-dispatch) MonoTests.Remoting.CallsDomainServer:Stop (object,byte[]&,byte[]&)
2015-03-19 10:16:28 +01:00
Zoltan Varga 29e00446a2 [corlib] Implement TypedReference:MakeTypedReference (). 2015-03-19 04:18:10 -04:00
Zoltan Varga 1361534ce0 Rename TypedReference test file to TypedReferenceTest.cs. 2015-03-19 04:15:35 -04:00
Marek Safar 561b80fb24 [corlib] Add TypedReference test 2015-03-19 09:08:02 +01:00
Zoltan Varga ec0d2d0688 [runtime] Extract mono-config-dirs.c into a separate automake convenience library so only that file depends on the MONO_BINDIR etc. defines given on the command line. This enables ccache to work on build done with different prefixes. 2015-03-19 03:22:04 -04:00
Zoltan Varga f699d17ff5 [runtime] Disable the locking of archives in libtool, it was a workaround around an old darwin bug which got fixed years ago: http://lists.gnu.org/archive/html/bug-libtool/2009-05/msg00062.html. 2015-03-19 03:20:01 -04:00
Zoltan Varga b1f0605dde [runtime] Add a new mono-config-dirs.c file which is the only one depending on the MONO_CFG_DIR etc. defines defined in metadata/Makefile.am. 2015-03-19 02:05:07 -04:00
Alex Rønne Petersen 954ddf4a88 [profiler] Fix finding methods in other domains than the current one.
In certain cross-domain scenarios, the method we're executing
is not necessarily emitted in the current domain. So we need
to scan all domains for it.
2015-03-19 01:34:08 +01:00
Alex Rønne Petersen 73bd556820 Add scripts/mono-symbolicate to .gitignore. 2015-03-19 01:33:43 +01:00
Joel Martinez 252e56b02c [mdoc] Updated csproj to target .NET 4.5 2015-03-18 15:32:38 -04:00
Stephen McConnel 49ecc710a7 Show thumbnail images in SWF.(Open,Save)FileDialog
This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=28025.
2015-03-18 12:55:48 -05:00
João Matos 50b4bff820 Merge pull request #1639 from alexrp/profiler-mingw
[profiler] Don't build the profiler on Windows.
2015-03-18 16:27:28 +00:00
Alex Rønne Petersen 435c2c4467 [profiler] Don't build the profiler on Windows. 2015-03-18 17:25:27 +01:00
Marcos Henrich a769e74c53 [System] Fixed RemoveConnectionGroup concurrent issue.
CloseConnectionGroup can concurrently call RemoveConnectionGroup and remove a group that has added to removeList.
We now check that the group still exists before removing it.
Fixes #19823.
2015-03-18 14:47:42 +00:00
Marcos Henrich 086eff3d60 [System] ServicePoint.CheckAvailableForRecycling is now private. 2015-03-18 14:46:09 +00:00
Marcos Henrich 5740faf124 [System] Test ServicePoint.CloseConnectionGroup concurrent issues.
Covers #19823.
2015-03-18 14:34:26 +00:00
Marek Safar a96ca57f7f [corlib] Update mobile tests 2015-03-18 12:01:10 +01:00
Marek Safar 88a1275377 [corlib] Default Egypt calendar is gregorian. Fixes #27725 2015-03-18 12:01:10 +01:00
João Matos 940732839d Merge pull request #1637 from soimort/fix-build
Fix build on Linux and Windows
2015-03-18 09:26:14 +00:00
Mort Yao 376a9f2d88 [runtime] Fix build for Linux 2015-03-18 17:01:48 +08:00
Mort Yao 00493fa308 [runtime] Add missing semicolon in mono_rand_try_get_bytes () 2015-03-18 17:01:47 +08:00
Marek Safar 81016c43ec [corlib] Disable more remoting code for mobile 2015-03-18 09:58:58 +01:00
Marek Safar 33338af95e Revert "Fixes build"
This reverts commit 0f25e60f9c.
2015-03-18 09:58:24 +01:00
Marek Safar 0f25e60f9c Fixes build 2015-03-18 09:47:09 +01:00
Marek Safar 455dd3867c [System.Runtime.Serialization.Formatters.Soap] Updated to work with reference sources serialization 2015-03-18 09:19:35 +01:00
Zoltan Varga c338de5815 [gsharedvt] Make sure the gsharedvt method we use in class_type_info () is not partially shared. 2015-03-17 21:18:59 -04:00
Alex Rønne Petersen 796f6ccded Merge pull request #1636 from alexrp/profiler-stuff
[profiler] Redesign buffer flushing and method reporting.
2015-03-17 23:02:00 +01:00
Alex Rønne Petersen bcf59453f0 Merge pull request #1635 from alexrp/core-clr-properties
Implement CoreCLR security properties on reflection info types.
2015-03-17 23:01:50 +01:00
Zoltan Varga 6549f7ea7c [runtime] Revert part of 2e3ba21e80. 2015-03-17 17:20:13 -04:00
Atsushi Eno 51ba090596 [xlinq] add test from bug #18171 (partly). 2015-03-18 04:16:25 +08:00
Ludovic Henry 3033429e66 [threadpool] Add licensing header 2015-03-17 19:27:06 +00:00
Ludovic Henry 620c5f5e3d [threadpool] Integrate the microsoft ThreadPool into it's own System.Threading.Microsoft namespace
This will let us have both the Mono and the Microsoft ThreadPool at the same time.
To switch to the Microsoft one, set the MONO_THREADPOOL environment variable to "microsoft". It will default to the Mono one.

Support by the runtime is also implemented.
2015-03-17 19:05:04 +00:00
Ludovic Henry a4e986024f [runtime] Move random generator code out of icall, to utils so it can be used by the runtime 2015-03-17 19:03:19 +00:00
Ludovic Henry 8eda12decf [runtime] Add CPU usage utility function 2015-03-17 19:03:19 +00:00
Zoltan Varga bd22565c26 [jit] Avoid disabling direct calls to icalls on arm64+llvm. 2015-03-17 14:20:25 -04:00
Marek Safar be5a532ce0 [corlib] Bump corlib version for 8d097349b3 (icall added) 2015-03-17 19:18:27 +01:00
Marek Safar a4426f51b6 [System.Runtime.Remoting] Update internal TypeFilter levels 2015-03-17 19:18:27 +01:00
João Matos 8ac788afb3 [genproj] Re-generated the class library projects. 2015-03-17 18:15:58 +00:00
João Matos 7c4825231d [genproj] Remove System.Xml pre-processing file as it's not needed anymore.
We do not rely on jay for this anymore since the switch of System.Xml to reference sources.
2015-03-17 18:15:57 +00:00
João Matos dc1bb8c3d0 [genproj] Ignore temporary project generation inputs. 2015-03-17 18:15:57 +00:00
João Matos 13db9ed7b7 [genproj] Added support for mcs "/-getresourcestrings" switch. 2015-03-17 18:15:57 +00:00
João Matos f339f61965 [genproj] Remove non .NET 4.5 solutions from being generated. 2015-03-17 18:15:57 +00:00
Marek Safar 43065be098 [corlib] Fixes remoting response message arguments assignment 2015-03-17 17:42:11 +01:00
Marek Safar d09e8d10a5 [corlib] Keep only one remoting MessageDictionary, it's special cased in binary serialization 2015-03-17 17:03:42 +01:00
Alex Rønne Petersen ae58dce822 [profiler] Redesign buffer flushing and method reporting.
The main goal of this change is to ensure that all methods have a `TYPE_JIT`
event emitted in the stream before they are referenced in other events. Before
this change, `TYPE_JIT` events could arrive out of order or not be emitted at
all because of generic sharing.

We now use a separate thread for writing log buffers to the output file.
Whenever a method is referenced in a TLS log buffer, we add it to a TLS list of
methods. When we ship the TLS log buffer off to the writer thread, we also send
the TLS list of methods. The writer thread first goes over all the methods and,
if some of them haven't had a `TYPE_JIT` event emitted yet, emits them to a
temporary buffer which is flushed just before flushing the main log buffer.

This approach ensures that `TYPE_JIT` events will *always* come before the
events that reference them.

Bookkeeping of which methods have been emitted to the output stream is done in
a global, concurrent hash table. Before a thread adds a method to its TLS list
of methods, it checks if the method is in the hash table. If it is, we know
that the method has already been emitted to the output stream, so it isn't
added to the list. The writer thread is the only thread that updates the hash
table (which happens when it flushes the temporary method buffer). So,
eventually, all TLS method lists will end up being empty because all methods
have been emitted to the output stream.
2015-03-17 16:35:45 +01:00
Alex Rønne Petersen 481bd0d83d [profiler] Make perf syscall work on ARM64. 2015-03-17 16:35:45 +01:00
Alex Rønne Petersen 95d65503e6 [profiler] Clean up some unused declarations. 2015-03-17 16:35:45 +01:00
Alex Rønne Petersen 45045502b8 [mini] Expose mono_aot_get_method () as an API-unstable function.
This will be used by the profiler.
2015-03-17 16:35:45 +01:00
Alex Rønne Petersen b4ab5e85ac [mini] Expose an API-unstable mono_get_jit_info_from_method () function.
This will be used by the profiler.
2015-03-17 16:35:44 +01:00
Alex Rønne Petersen cdc74e07e2 [mcs] Ignore .dep_dirs-* files. 2015-03-17 16:35:44 +01:00
Alex Rønne Petersen 62e93bfda7 [configure] Add a --disable-perf-events flag to disable perf on Linux. 2015-03-17 16:35:44 +01:00
Alex Rønne Petersen 91a06cb652 [corlib] Implement security properties on FieldInfo/MethodInfo. 2015-03-17 16:32:04 +01:00
Alex Rønne Petersen 69ee842753 [coreclr] Add mono_security_core_clr_field_level () function. 2015-03-17 16:31:31 +01:00
Marcos Henrich 9ae88709db [System] Fixed SafeSocketHandle concurrency problem.
When ReleaseHandle was called by RegisterForBlockingSyscall's DangerousRelease the current thread would be in blocking_threads but there would be no blocking system call to interrupt.
2015-03-17 15:13:09 +00:00
Marcos Henrich 29dc0ae194 [runtime] Assert that thread_resume returns KERN_SUCCESS. 2015-03-17 15:13:09 +00:00
Marcos Henrich 288659611b [runtime] Fixed thread_abort_safely not interrupting accept.
For some reason accept can only be interrupted by thread_abort.
We do not want to use thread_abort by default because it may abort non-atomic operations at an arbitrary point.
The problem was fixed by calling thread_abort_safely, and make sure the target thread was interrupted by calling thread_abort afterwards.
In this change thread_abort is only called if thread_abort_safely returns KERN_SUCCESS, which *should* mean that the target thread has already left the kernel code by the time thread_abort is called.
2015-03-17 15:13:09 +00:00
Neale Ferguson e92937676c s390x-codegen.h : Fix instruction definition and add instruction format variant
mini-s390x.h : Enable profile coverage
suport-s390x.h : Add processor facility definitions
2015-03-17 10:35:21 -04:00
Alexander Kyte 9d6859ddf2 [corlib] Fixed change in 4b4ddb66b3 that prevented use of remoting fast path. 2015-03-17 10:24:47 -04:00
Marek Safar 14370f53dd [system.date] Fix DefaultValue expression serialization 2015-03-17 14:04:39 +01:00
Atsushi Eno 59267a16c4 [xlinq] add test from bug #14856. 2015-03-17 18:56:10 +08:00
Atsushi Eno ee9fd48289 [xml] add test from bug #2917. 2015-03-17 18:55:34 +08:00
Marek Safar b0e3d25ad0 [corlib] Always pass ProxyCheckCast check 2015-03-17 09:37:01 +01:00
Marek Safar 88f4e24f02 [corlib] Add missing public type 2015-03-17 09:36:39 +01:00
Marek Safar 8d097349b3 [corlib] Serialization from reference sources 2015-03-17 08:03:58 +01:00
Zoltan Varga 0605e2d596 [jit] Add exception checks after direct calls to icalls by inlining the wrapper. 2015-03-17 02:32:06 -04:00
Zoltan Varga c6576781c5 [jit] Disable direct icalls for now to fix the build. 2015-03-17 00:55:02 -04:00
Zoltan Varga ce80f5559e [jit] Split the CEE_CALLI conv into a separate switch case to simplify the logic in the CEE_CALL/CEE_CALLVIRT case. 2015-03-17 00:54:15 -04:00
Zoltan Varga 88fadaef9b [amd64] Fix aot support in throw_pending_exception (). 2015-03-17 00:05:46 -04:00
Zoltan Varga b0ad5d776d [runtime] Allocate objects outside the lock in mono_string_is_interned_lookup (). 2015-03-16 22:16:51 -04:00
Zoltan Varga d04e09ac0c Merge pull request #1633 from BrzVlad/fix-w32-pinvoke
[x86] Handle stack pop done by native stdcalls.
2015-03-16 21:34:41 -04:00
Zoltan Varga 0aeaa71f1d [jit] Add support for directly calling normal icalls. Enable it for a few perf-sensitive classes like Math. 2015-03-16 20:34:46 -04:00
Vlad Brezae bba332f502 [x86] Handle stack pop done by native stdcalls.
The problem was caused with the introduction of the pushless backend. We have to compensate for the arguments being popped by native stdcall callees, to keep param_area from shrinking. Fixes #27597
2015-03-16 14:59:32 -07:00
Zoltan Varga f45cb311c1 [aot] Enable direct calls to icalls in aot mode, disable them when the 'direct-calls' aot option is used. 2015-03-16 17:49:01 -04:00
Zoltan Varga 453e3cf5fe [aot] Remove obsolete 'iphone-abi' option. 2015-03-16 17:24:40 -04:00
Zoltan Varga 5d2973e535 [io-layer] Avoid the usage of atexit (), clean up handles normally. 2015-03-16 16:23:00 -04:00
Vlad Brezae 388e3efe0d [sgen] Write barrier nursery checks might be needed
For the case of non-concurrent collector we don't want to mark stores from the heap to the heap, since it would add sgen overhead. When aot compilling we don't know whether the GC will be concurrent or not, so we fallback to the write barrier method.
2015-03-16 12:22:05 -07:00
Vlad Brezae 149534c76c [aot] Add aot support for write barrier.
We emit two write barriers, for the case of the concurrent and non-concurrent collector in the mscorlib image. All calls to the write barrier are made through the plt, calls which are resolved according to the GC configuration at runtime.
2015-03-16 12:22:05 -07:00
Vlad Brezae 18a3d58565 [sgen] Differentiate the concurrent and nonconcurrent method wbarriers 2015-03-16 12:22:04 -07:00
Vlad Brezae f3141cbf45 [aot] Fix allocation over structure size. 2015-03-16 12:22:04 -07:00
Vlad Brezae c8b9d1e04f [jit] Handle pointers for aot separately from CEE_MONO_LDPTR 2015-03-16 12:22:03 -07:00
Vlad Brezae e2875c2180 [sgen] Remove option for unaligned nurseries. 2015-03-16 12:22:03 -07:00
Marek Safar d9dc2f64b0 [system] Update wrong test 2015-03-16 20:09:48 +01:00
Alexander Kyte 62277e8162 Added/modified tests for marshalling and remoting of referencesource StringBuilder implementation. 2015-03-16 11:42:57 -04:00
Alexander Kyte 14ec387555 [Runtime] Altered the marshalling logic for StringBuilders to handle referencesource version. 2015-03-16 11:42:57 -04:00
Alexander Kyte 9a7a39551e Revert "Revert "[corlib] StringBuilder from reference sourcers""
This reverts commit 772c45aaf9.

Conflicts:
	external/binary-reference-assemblies
	mcs/class/corlib/Makefile
	mcs/class/corlib/System.Text/StringBuilder.cs
	mcs/class/corlib/corlib.dll.sources
2015-03-16 11:42:56 -04:00
João Matos 29fc1bb5d6 [mini] Fixed the build.
Missed this one on https://github.com/mono/mono/commit/86155e72da0aa0cc1e546dd2dd5acee0db398c38.
2015-03-16 14:57:38 +00:00
João Matos a807f99a7d [runtime] Fixed thread async suspend on Windows.
Move the ResumeThread () calls out of the assert and check for 0 (which means that the thread was resumed) instead of using the Mach-specific KERN_SUCCESS on Windows.

Fixes the Windows/MSVC build.

Related to https://github.com/mono/mono/commit/296347f.
2015-03-16 13:54:43 +00:00
João Matos a1538d1687 [runtime] Added missing function mono_threads_core_interrupt on Windows. 2015-03-16 13:53:01 +00:00
João Matos 86155e72da [msvc] Renamed ResumeThread since it conflicts with a Windows function. 2015-03-16 13:50:38 +00:00
Andrey Akinshin 45d5332a0a Stopwatch: removed #if NET_4_0 for suppression of negative elapsed 2015-03-16 14:37:45 +02:00
Marcos Henrich 7b558417ac [runtime] Added function mono_process_get_times.
With the new function it is possible to retrieve other processes start, user and kernel times.
In mach start time is available without special privileges but user and kernel times still require privileges.
2015-03-16 11:44:28 +00:00
Marcos Henrich 4c600e1fc5 [runtime] Added function mono_100ns_datetime_from_timeval.
The added function is required to convert timeval to datetime ticks.
2015-03-16 11:44:28 +00:00
Marcos Henrich 6b2bf67ff9 [runtime] Added helper function sysctl_kinfo_proc.
Refactored mono_process_get_name sysctl code to use sysctl_kinfo_proc to retrieve the kinfo_proc data structure.
2015-03-16 11:44:28 +00:00
Marcos Henrich 5f8489c59a [System] Test StartTime of processes returned by GetProcesses.
Covers #26363.
2015-03-16 11:44:28 +00:00
Marek Safar f482b9bd9b [corlib] Attribute from reference sources. Fixes #27982 and similar 2015-03-16 11:01:37 +01:00
Zoltan Varga e31c6d80c6 [aot] Bump aot file format version. 2015-03-16 01:12:36 -04:00
Zoltan Varga 050520a485 [aot] Fix mono_aot_method_hash () to avoid depending on the name of the type arguments used to inflate classes. 2015-03-16 01:06:58 -04:00
Zoltan Varga 43318e0e16 Fix the cross compiler build. 2015-03-15 23:04:31 -04:00
Zoltan Varga de2bfdf78b Bump referencesource to pick up 7ce7271612320b265e3a4a42d96a779b218a9dce. 2015-03-15 22:46:54 -04:00
Miguel de Icaza addc8c1b85 Merge pull request #1617 from keneanung/OdbcCommandExceptionOnNoData
Add NoData as valid return state for Statements with params
2015-03-15 10:54:26 -04:00
Miguel de Icaza 30b99d3271 Merge pull request #1627 from mono/tooltask-fixes
[Microsoft.Build.Utilities] Make properties in ToolTask available in 4.0 xbuild
2015-03-15 10:52:07 -04:00
João Matos 77ee431aa9 Merge pull request #1628 from akoeplinger/resxresourcereader-order
[WinForms] Make ResXResourceReader enumerator return values in same order as resx
2015-03-15 09:16:45 +00:00
Zoltan Varga f2a67e6fc7 [jit] Add support for char/boolean to mini_type_get_underlying_type (). 2015-03-15 03:08:45 -04:00
Zoltan Varga c9a51b2dc6 [aot] Rename the find_extra_method... functions to find_aot_method... 2015-03-15 02:38:55 -04:00
Zoltan Varga 716bcd9e6d [jit] Fix the detection of whenever we are compiling a gsharedvt method in the presence of partial shared methods. 2015-03-15 02:17:40 -04:00
Zoltan Varga 3c0b6b8422 [runtime] Remove ldscript support, its no longer needed with explicit visibility declarations. 2015-03-14 22:08:03 -04:00
Alexander Köplinger 76a01d3500 [WinForms] Make ResXResourceReader enumerator return values in same order as resx
This fixes an issue when building dotnet/corefx and all the SR.cs files are modified
because Mono used a HashTable internally in ResXResourceReader and it returned the
elements in a different order than MS.NET.

Even though this isn't explicitly mentioned in the docs, the MS.NET implementation returns
the elements in the same order as they appear in the resx and we should do the same.
2015-03-15 02:28:56 +01:00
Zoltan Varga 5bd3e2bfc8 [jit] Set the names of the gparams used during generic sharing so it includes the type they are constrained to. 2015-03-14 16:16:46 -04:00
Zoltan Varga 7adfa541a0 Fix the build. 2015-03-14 15:12:49 -04:00
Alexander Köplinger 151383a64d [Microsoft.Build.Utilities] Make properties in ToolTask available in 4.0 xbuild
The properties were introduced with MSBuild 4.0 (e.g. https://msdn.microsoft.com/en-us/library/microsoft.build.utilities.tooltask.logstandarderroraserror(v=vs.100).aspx) and shouldn't be inside a XBUILD_12 ifdef.
2015-03-14 19:10:06 +01:00
Zoltan Varga e9aff0910f Fix the aot compiler. 2015-03-14 02:17:57 -04:00
Rodrigo Kumpera 54be6b1d53 [threading] Fix signal registration on posix. 2015-03-13 12:36:44 -07:00
Rolf Bjarne Kvinge d4490c9763 Fix spelling. 2015-03-13 18:29:55 +01:00
João Matos 5b985a4daa [aot] Wrap the commands we pass to Windows's system() in double quotes.
We need an extra set of quotes around the whole command to properly handle commands
with spaces since internally the command is called through "cmd /c.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=27899.
2015-03-13 17:14:40 +00:00
João Matos 6fc403d545 [aot] Escape the command executables with quotes to deal properly with spaces in paths. 2015-03-13 17:10:54 +00:00
João Matos 925d3844ba [aot] Ensure the LLVM tools path ends with a directory separator appropriate to the system. 2015-03-13 17:09:41 +00:00
Marek Safar 8b3440425d [system] Make httplistener to accept case insensitive protocols. Fixes #26858 2015-03-13 17:42:33 +01:00
Rolf Bjarne Kvinge cbdd18ef89 [mono-api-html] Render generic parameter constraints.
Makes changed constraints show up in diffs.
2015-03-13 16:44:55 +01:00
Marcos Henrich a4c453967e [System] Replaced static constructor with field initialisation. 2015-03-13 12:39:26 +00:00
João Matos 815e7befb3 Merge pull request #1606 from alexanderkyte/debug-finalizers
[Runtime] Added logging around finalizers
2015-03-13 09:42:22 +00:00
João Matos b61747cd90 Merge pull request #1618 from alexanderkyte/remoting-fix
[Runtime] Fixed remoting bug where too specific a type reflected.
2015-03-13 09:39:48 +00:00
Zoltan Varga 37dbebe114 [jit] Use mini_get_underlying_type () in a few places in the amd64 backend. 2015-03-13 02:41:34 -04:00
Zoltan Varga 75e58b9b5f [jit] Finish support for valuetype based sharing in JIT mode, not enabled yet. 2015-03-13 01:28:00 -04:00
Zoltan Varga 061019283b [jit] Add a new MONO_RGCTX_INFO_ELEMENT_KLASS info type and use it instead of MONO_RGCTX_INFO_KLASS on klass->element_class, the latter doesn't work with valuetype sharing. 2015-03-12 19:30:02 -04:00
Rodrigo Kumpera 777dbc17d5 [metadata] Handle denormalized value type encoding of builtins.
All primitive types have a short encoding format that avoid using
a typeref token.

It's possible to encode them in another, longer, form with ELEMENT_TYPE_VALUETYPE + a typeref token.

Up to now, this was never seen in the wild so we never supported it.

This patch allows long form encoding of primitives.
2015-03-12 18:50:22 -04:00
Rodrigo Kumpera 3af402a0d0 [threading] Fix a race condition between managed suspend/abort and GC STW.
STW and managed suspend share a lock to ensure there is only one active suspend initiator.

This originally caused a problem in the managed suspend path as it could be async suspended while it was
in the middle of the suspend protocol (check if top of stack is managed, install abort handlers, etc).

This was worked around by putting that inside a suspend critical section. The resulting code was horrible
as suspend boundaries became unstructured (yeah, pretty stupid idea on my end). Not only that but it had
a race condition.

If a thread doing managed suspend raced with a STW and lost, it would block on the global suspend lock to
finish. That thread would be blocked inside a critical section - the single thing you must not do inside one.

This could be reproduced by stressing mono/tests/sgen-new-threads-dont-join-stw.

The solution is to execute the managed suspend sequence in the same fashion as of a STW. IOW, take locks,
suspend, do stuff, maybe resume and drop locks.

The critical part is the "do stuff" one, which is different for abort and suspend, but everything else
is the same. So we wrap that into a callback and put the common parts in mono-threads. This gives
us structured locking and suspend boundaries.

This won't cause a GC to take longer to init as the critical section would block the  STW from progressing
anyways.
2015-03-12 18:50:22 -04:00
Mark Probst df1e884553 [runtime] Fix warnings. 2015-03-12 15:40:28 -07:00
Zoltan Varga 9fa5a88211 [jit] Throw the proper exception on integer overflow from div/rem if MONO_ARCH_NEED_DIV_CHECK is defined. 2015-03-12 18:19:40 -04:00
Zoltan Varga 63bd1dfcf7 [jit] Add another test for gsharedvt+vtype byref argument passing. 2015-03-12 16:54:54 -04:00
Miguel de Icaza e2f1f5cec6 Add documentation information about IRI parsing 2015-03-12 16:18:54 -04:00
Marcos Henrich 84d573e0b0 [corlib] Added exception to fail tests on non aborted system calls.
While running tests if a socket is closed while blocking system calls are pending an exception is thrown.
A socket should not be closed when a blocking system call is pending.
The purpose of the exception is to inform us when AbortRegisteredThreads is not working.
2015-03-12 18:23:56 +00:00
Marcos Henrich c3f906d975 [runtime] Check that thread_suspend returns KERN_SUCCESS.
mono_threads_core_abort_syscall no longer calls thread_abort_safely in case thread_suspend returns errors.
2015-03-12 18:23:56 +00:00
Marcos Henrich aee6b8f147 [runtime] Updated Socket_to_SOCKET to use SafeSocketHandle.
The type of field of Socket.socket was changed from IntPtr to SafeSocketHandle.
2015-03-12 18:23:55 +00:00
Rodrigo Kumpera afc0d2abe2 [aot] Better report errors when loading methods. 2015-03-12 14:09:48 -04:00
Rodrigo Kumpera 0f212a3fa4 [mono-error] When fetching the error message for native usage, include assembly, type and member fields after the message. 2015-03-12 14:08:14 -04:00
João Matos a678f96f78 [eglib] Fixed file being created without read/write permission on Windows.
This bug manifested itself as files being written to disk with 0 bytes.

Fixes the AOT compiler on Windows not working properly.

https://bugzilla.xamarin.com/show_bug.cgi?id=27900
2015-03-12 16:41:21 +00:00
Marek Safar ec4fed0076 [mcs] Don't crash after reporting missing type in type arguments of generic method run in probing mode. Fixes #27737 2015-03-12 17:24:46 +01:00
Marcos Henrich 8a3ae30450 [corlib] TimeZoneInfo.TryGetTransitionOffset overflow checks. 2015-03-12 13:13:41 +00:00
Marek Safar b736f37cc4 [system] Fixes mobile build 2015-03-12 13:24:36 +01:00
Marcos Henrich 504715b441 [corlib] Fixed DateTime overflow check in TimeZoneInfo. 2015-03-12 09:02:33 +00:00
Zoltan Varga e908e4a6be Revert "[runtime] Fix mono_class_instance_size () to work with dynamically created types."
This reverts commit 501f0aa645.

Revert this as it breaks some corlib tests.
2015-03-12 04:54:03 -04:00
Zoltan Varga 501f0aa645 [runtime] Fix mono_class_instance_size () to work with dynamically created types. 2015-03-11 21:39:25 -04:00
Mark Probst 55f1ac1bb5 [runtime] Remove unused ves_icall_type_is_subtype_of(). 2015-03-11 16:02:00 -07:00
Zoltan Varga f9eea170d1 [jit] Enable the gsharedvt testcase which now works. 2015-03-11 18:47:54 -04:00
Mark Probst adb9681393 Merge pull request #1621 from schani/fix-warnings
[runtime] Fix warnings.
2015-03-11 13:37:31 -07:00
Mark Probst 2e3ba21e80 [runtime] Fix warnings. 2015-03-11 13:28:38 -07:00
Rodrigo Kumpera e7aa80048e [io-layer] When checking if a file is a program check both read and execute permissions. Fixes #27565
The original behavior of only checking for read permission broke sudo on OSX which only have the execute permission set.
2015-03-11 12:27:20 -04:00
Rodrigo Kumpera 518dee1837 [threading] Split unwind state into sync and async.
Having a single unwind state means writes to it must be synchronized between sync and async suspend. We can't
have the state be broken as it could lead to bad unwinding or GC marking.

The original solution was to have an additional state in the self suspend path that signals it's writing to the
thread state and thus any async suspend must give up and let it finish. This ended up been overly complicated
as this requires two additional states instead.

By having a pair of unwind states both can write concurrently without the fear of clashing. This makes fetching the state
a little bit trickier but worth the trouble.

The simplified design has a much smaller state space, which is easier to reason about.
2015-03-11 12:26:37 -04:00
Rodrigo Kumpera fe784fbca9 [threading] Change request async suspend to return 3 states instead of one to account for async racing to the middle of a self suspend.
When begin async suspend lands in STATE_SUSPEND_IN_PROGRESS, the initiator don't need to perform an async suspend, it just needs to wait.

If a self suspend is promoted to an async suspend, it must be added to the pending ops set. This ensure that it will be waited otherwise
the suspend initiator might witness an unfinished self suspend and assert when fetching the thread state.

The alternative would be to change finish async suspend to account for the possibility of witnessing STATE_SUSPEND_PROMOTED_TO_ASYNC.

Solving this way requires less async suspends and doesn't increase the valid state space.
2015-03-11 12:26:37 -04:00
Rodrigo Kumpera 296347fc88 [threading] Rework suspend code to be based on a state machine and eliminate known races in the process.
The new suspend machinery is based around a single word state machine that is manipulated using CAS.

This solves the first set of problems with the current approach, the lack of atomicity and the impossibility of
doing race free manipulation of protected state. This is specially acute when doing a self suspend.
Suspend data must be atomically protected while we prepare to self suspend so a resume request won't race with the current
thread putting itself to sleep. This is a classical problem that calls for a mutex/conditional variable pair. Except that all
locks in the suspend path must be suspend safe. Wait, WHAT?

A Suspend Safe Lock is a primitive that is obstruction free in the face of the kernel suspending a thread either performing a
lock operation or waiting on a lock to become available. This, unfortunately, is not possible with pthread_mutex on OSX. The
only safe primitive are kernel semaphores, for which doesn't exist conditional variables for.

So back to locking and self-suspend. We need a lock because the existing thread state is not atomic but we can't use a
mutex/condvar pair so we're left with racy code. Yay! The fix is using CAS over a single variable.

Another change was the hardening of the suspend/resume code on posix targets. First we replace a semaphore wait with
sigsuspend for async suspend. This is needed since sem_wait is not async-signal safe (yet sem_post is). Second, we now
respect interruption requests by having a pair of suspend signals, one with SA_RESTART and one without.

Onto the design of the suspension system, a few concepts that are useful looking around.

* Self suspend: This is when the thread decides to suspend itself.

* Async suspend: This is when a thread decides to suspend another thread.

* Suspend Initiator: This the name of a thread that decided to suspend one or more other threads. This is important
since all suspending threads will notify it when they are suspended. There can be only one initiator in the system
at a given time.

* Suspension count: Number of resume calls before a thread is back to running state.

There are 7 states that can happen while a thread is runnable:

* Running: just running...

* (Async|Self) Suspended: Suspended, the difference comes into play when resuming.

* (Async|Self) Suspend Requested: Suspend requested, but not completed. See more below for the discussion on why the request state is needed.

* Suspend In Progress: Self suspend started saving its state thus async suspend should not modify it.
* Suspend Promoted to Async: Async tried to suspend a thread in the middle of a self suspend, it wants to be notified.

Now to the suspension protocol and how it happens on a high level view.

Suspension starts with a suspend request, which bumps the suspend count by one. This suspend request can be fulfilled either
by an async or self suspend action. This is confusing as there's only one initiator but any number of threads can be self suspending.

Async suspend then performs a platform specific action such as posix signals that forces a transition on the target. In the case
of self suspend, it depends on the thread polling its state and trigger the transition.

This works fine except that the suspend state is one huge struct with tons of fields. To control concurrent access to it we use a
single initiator in the case of async suspend and we put the thread in a transitional "saving my state" in the case of self suspend.

In the case of async suspend, the initiator must wait for all 1+ threads to notify back that they have suspended. Only after that
it's possible to know if the async suspend request actually worked or not (we might have hit a dying thread).

Together with this, there's an optional implementation of STW in sgen that can use this new machinery. To enable it set the
MONO_ENABLE_UNIFIED_SUSPEND env var for now while it gets more testing.
2015-03-11 12:26:36 -04:00
Marek Safar 0c5357521a [system] Fixes InvalidCastException in OpenReadAsyncCallback 2015-03-11 17:20:28 +01:00
Marcos Henrich 6173a3e162 [runtime] Replaced unsafe thread_abort calls. 2015-03-11 16:06:45 +00:00
Marek Safar a114dcdf75 [corlib] TypeDelegator from reference sources 2015-03-11 16:44:21 +01:00
Jo Shields 577482e336 [msvc] Change target MSVC release from v120 to v120_xp
They're basically the same thing, but v120 has DX10+ capabilities and v120_xp
is DX9 only. Since we're not building against DirectX, the difference is
purely academic - but changing the value to v120_xp means MSVC binaries run
on XP+, not Vista+
2015-03-11 15:23:27 +00:00
Marek Safar 115042a207 [runtime] Make read_enum_value endian aware 2015-03-11 15:52:16 +01:00
Marek Safar db7f9b7be7 [Microsoft.Build.Engine] Fix invocation flags not to contain both CreateInstance and Invoke 2015-03-11 13:33:38 +01:00
Marek Safar 7c260b6c87 [System.ComponentModel.DataAnnotations] Update test as validation attributes needs to be public 2015-03-11 13:25:41 +01:00
Jo Shields 1d33de4a70 [msvc] Refresh .def files 2015-03-11 12:06:16 +00:00
Jo Shields 7b452e2ba9 Bump winconfig.h to 4.1.0 2015-03-11 10:13:44 +00:00
Jo Shields c127ea46a3 Use MSVC2013 for *all* mono.sln dependants 2015-03-11 10:00:11 +00:00
Jo Shields 22fdb9dfb0 Add _WIN32_WINNT to Release definition, not just Debug 2015-03-11 09:48:59 +00:00
Marek Safar 8057adf2e8 [corlib] Fixes build, add missing file 2015-03-11 10:40:06 +01:00
Marek Safar 5ecee9a0c8 [corlib] Type from reference sources 2015-03-11 10:09:11 +01:00
Marek Safar a53e9778b3 [mcs] Check operator parameter types using common declaration type 2015-03-11 10:09:10 +01:00
Zoltan Varga c8ba3e9f48 [runtime] Make the size of the pseudo classes created by make_generic_param_class () the same as a valuetype with one field of the appropriate type. 2015-03-11 00:08:04 -04:00
Zoltan Varga 82fd40573c [jit] Reorganize the gshared code a bit to make it easier to add support for valuetype sharing. 2015-03-10 21:56:16 -04:00
Zoltan Varga ccaf2f6917 [jit] Handle type variables in mini_emit_stobj (). 2015-03-10 21:39:21 -04:00
Zoltan Varga 7a6cf0aceb [jit] Move some gshared related code to mini-generic-sharing.c. 2015-03-10 19:47:47 -04:00
Zoltan Varga f0ba602f11 [jit] Rename 'constrained_call' to 'constrained_class' to better reflect its type. 2015-03-10 19:43:57 -04:00
Zoltan Varga 17cb2cec62 Fix some bugs in 92ca06aa7d. Fixes #26989. 2015-03-10 17:29:14 -04:00
Zoltan Varga 14180ae433 [jit] Fix the handling of byref locals in mono_allocate_stack_slots2 (). 2015-03-10 17:29:14 -04:00
Mark Probst e28cc925ec [tests] Test case for #27147. 2015-03-10 13:55:00 -07:00
Mark Probst cd6e7ba894 [sgen] Fix a bug in 64 bit LOS cardtable scanning. Fixes #27147. 2015-03-10 12:24:30 -07:00
Alexander Köplinger ee307ef1e5 Fix the build broken in 40ba1978bc 2015-03-10 11:53:17 +01:00
Miguel de Icaza 40ba1978bc Merge pull request #977 from jasonleenaylor/bug-18558
Fix for Bug 18558
2015-03-10 14:40:33 -04:00
Marcos Henrich f220c03e04 Merge pull request #1579 from esdrubal/aotsp
Sequence points and symbolicate improvements
2015-03-10 16:33:32 +00:00
Marcos Henrich b7e8000915 Merge pull request #1612 from esdrubal/socketsh
Changed Socket to used SafeHandle instead of IntPtr.
2015-03-10 16:22:12 +00:00
Zoltan Varga 1a67a7820e Fix the build. 2015-03-10 01:28:57 -04:00
Zoltan Varga 8e4f5b9570 Fix a crash introduced by 15c813d8fd. 2015-03-10 00:36:45 -04:00
Zoltan Varga 27a8dc5fc9 [runtime] Add support for generic params with gshared constraints to mono_type_get_basic_type_from_generic (). 2015-03-09 22:07:44 -04:00
Zoltan Varga 15c813d8fd [runtime] Make the image->gsharedvt_types into an array. 2015-03-09 20:57:32 -04:00
Zoltan Varga 6e1386a78a [runtime] Handle gparams constrained to vtypes correctly in mono_class_array_element_size (). 2015-03-09 20:57:31 -04:00
Marek Safar 9df95ccd67 [system] Remove closed connection groups from service point manager. Fixes #25254 2015-03-10 00:26:13 +01:00
João Matos ea36fb88d5 Merge pull request #1620 from alexanderkyte/bug-27755
Fixed early termination of string parsing on non-space whitespace.
2015-03-09 20:39:41 +00:00
Marcos Henrich 5d9a63de3e [mono-symbolicate] make check now tests aot with and w/o .msym. 2015-03-09 19:17:21 +00:00
Marcos Henrich 9e1853076b [runtime] Added --aot option gen-seq-points-file.
.msym file is now only generated if option gen-seq-points-file is used.
2015-03-09 19:17:21 +00:00
Marcos Henrich 748bd496a0 [mono-symbolicate] Updated README to the same content as man page. 2015-03-09 19:17:20 +00:00
Marcos Henrich 06a984fc80 [mono-symbolicate] Added tool man page and script. 2015-03-09 19:17:19 +00:00
Marcos Henrich 05fd9e873c [mono-symbolicate] Replaced mcs --debug flag usage with -debug. 2015-03-09 19:17:19 +00:00
Marcos Henrich 3d96830ae0 [mono-symbolicate] Fixed wrong Directory.Exists check. 2015-03-09 19:17:18 +00:00
Marcos Henrich a9180782f3 [runtime] Updated comment with wrong corlib path. 2015-03-09 19:17:17 +00:00
Marcos Henrich 06377638be [runtime] emit_exception_debug_info no longer adds seq point flag on release. 2015-03-09 19:17:17 +00:00
Marcos Henrich f07bfe9fb3 [runtime] ves_icall_get_trace can now return a -1 IL offset.
This change was made so StackFrame dumps now show a native offset when the IL offset is unknown.
The native offset can be used by mono-symbolicate tool to retrieve an IL offset from a .msym file.
2015-03-09 19:17:16 +00:00
Marcos Henrich c47e3d5962 [mono-symbolicate] make check now also runs test with AOT. 2015-03-09 19:17:15 +00:00
Marcos Henrich f2b8e2a936 [mono-symbolicate] Tool is now using .msym files with AOT.
With AOT sequence points are stored in a .msym file.
As the sequence point data is not avaible at run time, AOT stack traces display a native offset.
mono-symbolicate tool is now able to retrieve an IL offset from a method name, native offset, and the data stored on the .msym file.
The IL offset can then be use to retrieve a filename and line from a .mdb file.
2015-03-09 19:17:15 +00:00
Marcos Henrich 707c481cd0 [corlib] Added icall System.Diagnostic.StackFrame.GetILOffsetFromFile.
This method is required by the tool mono-symbolicate.
2015-03-09 19:17:14 +00:00
Zoltan Varga 1acd65dc65 Disable SecurityFrame, the runtime code in declsec.c creates cross-domain references which cause GC crashes when running the System.Web testsuite. 2015-03-09 15:15:04 -04:00
Marcos Henrich dfaa57f513 [runtime] Moved some seq point code from mono/mini to mono/metadata.
Created files metadata/seq-points-data.c and .h.
Sequence points data structures were moved to metadata so we can perform icalls on them.
2015-03-09 19:03:35 +00:00
Marcos Henrich 345e2f50f0 [runtime] AOT now uses file to store release mode sequence points.
Sequence point data is now stored in a .msym file.
This change removes the sequence points memory overhead from assemblies to be deployed on devices.
2015-03-09 19:03:35 +00:00
Marcos Henrich 91553a5cd1 [runtime] Added SeqPointData used to write/load sequence points. 2015-03-09 19:03:35 +00:00
Marcos Henrich 19b513f9df [runtime] Improved seq_point_info_write/read has_debug_data encode. 2015-03-09 19:03:35 +00:00
Marcos Henrich 56383167fe [mono-symbolicate] Changed files to use new tool name. 2015-03-09 19:03:34 +00:00
Marcos Henrich 7c5b81f99b [symbolicate] Renamed symbolicate to mono-symbolicate.
Renamed the tool to a name that will not conflict with other installed tools.
2015-03-09 19:03:34 +00:00
Marcos Henrich d17b393e11 [runtime] Fixed Process.GetProcesses ().
Process.GetProcesses () was not returning any processes.
2015-03-09 17:40:31 +00:00
Alexander Kyte 4e6a94e2a4 [Remoting] Fixed remoting bug where too specific a type reflected. 2015-03-09 13:07:39 -04:00
Alexander Kyte c49d92bff9 [Remoting] Moved helper methods from CAD call class to parent class to enable remoting fix. 2015-03-09 13:07:27 -04:00
Alexander Kyte 2d0a5da8b4 Fixed early termination of string parsing on non-space whitespace. 2015-03-09 12:41:02 -04:00
João Matos 6397c8da1d Merge pull request #1622 from akoeplinger/fix-datetime-test
[corlib] Fix timezone dependent DateTimeOffset test
2015-03-09 14:23:56 +00:00
João Matos 05c587cb39 [runtime] Fixed Windows mono_threads_core_get_stack_bounds to work with cross-compiled targets. 2015-03-09 14:22:01 +00:00
Alexander Köplinger bb3bc6ddc9 [corlib] Fix timezone dependent DateTimeOffset test
Instead of trying to recreate the date with the current timezone, we should make the date assume UTC and compare against that.
2015-03-09 10:21:49 -04:00
Alexis Christoforides 22d5581e87 [DataContractJsonSerializer] Allow abstract base classes in lists. Fixes #26998
Abstract classes can still have subclasses with KnownType attributes, which are allowed in deserialization.

This used to work as the '__type' hint  was always honored no matter the type, and broke with https://github.com/mono/mono/commit/71e152accc727089faffa6b4fd6bf58cb62636cf which removed that behavior.
2015-03-09 01:23:27 -04:00
Alex Rønne Petersen 98f62a74f8 Merge pull request #1619 from akoeplinger/flaky-dataflow-test
[Dataflow] Disable flaky FaultExecutingConsume () test
2015-03-08 22:05:47 +01:00
Alexander Köplinger 2b5da76670 [Dataflow] Disable flaky FaultExecutingConsume () test
It fails randomly on Jenkins and my own CI. To reproduce, just wrap the body of the test in while(true) and run for a few minutes.
I tested on MS.NET as well and it fails the same way there, so it's not Mono's implementation of Dataflow.

Filed https://bugzilla.xamarin.com/show_bug.cgi?id=27757 for tracking.
2015-03-08 21:51:48 +01:00
Zoltan Varga 03f9477d60 [jit] Rename MonoGenericParam->serial to 'gshared_constraint', use it to calculate object sizes/layouts correctly if a generic param matches a non-reference type during gsharing. 2015-03-07 22:59:34 -05:00
Miguel de Icaza f1ad4d5bee [UnixRegistry] Fix leak (#25559), remove races.
There was a memory leak caused by not having a lookup mechanism for
the RegistryKey.  In addition, the entire code to dispose code was
never used (due to the leak), and it was wrong.

In addition, added locking to the "values" field, which currently was
racy.

No test cases, the repro is to run the above code for about 5 minutes.
2015-03-06 21:18:51 -05:00
João Matos 4f458a4ff7 Enable x86 cross compilation on Windows. 2015-03-06 18:15:37 +00:00
João Matos 8bdbe69fd7 Do not try to use the native GCC linker when targeting Android from Windows. 2015-03-06 17:42:36 +00:00
João Matos 635fe7a37d Fixed Windows system commands calls with non-ASCII paths.
This is a bit of an hack but it works for now... ideally we should be processing the Unicode command line flags passed by the CRT at startup instead of trying to convert the MBCS string to a wide string.
2015-03-06 17:42:36 +00:00
Sebastien Pouliot 9c38772f09 Remove the EXPORT ciphers and related code path
That was still useful in 2003/2004 but the technical and legal landscape
    changed a lot since then. Removing the old, limited key size, cipher
    suites also allow removed additional parts of the code that deals with
    them.
2015-03-06 10:35:27 -05:00
Sebastien Pouliot b371da6b2d Remove the client-side SSLv2 fallback.
There's almost no SSLv3 web site left so a v2 fallback is only extra
    code we do not need to carry forward.
2015-03-06 10:34:59 -05:00
Sebastien Pouliot 1509226c41 TLS protocol: add handshake state validation 2015-03-06 10:34:14 -05:00
Miguel de Icaza 48992d4b3f Merge pull request #1155 from steffen-kiess/json-string
Fix System.Json string handling and make order of JsonObject entries deterministic
2015-03-06 09:47:56 -05:00
Zoltan Varga 0a968edad3 [jit] Use mini_get_underlying_type () in one more place. 2015-03-05 17:59:42 -05:00
Zoltan Varga c89496c89f [jit] Add a make target for running the jit tests without the nunit output wrapper. 2015-03-05 17:53:55 -05:00
Zoltan Varga 29fce2eda9 [jit] Use mini_get_underlying_type () in a few more places. 2015-03-05 17:46:10 -05:00
Zoltan Varga 181093864f [runtime] Remove the usage of MONO_INTERNAL, use MONO_API to mark exported functions and -fvisibility=hidden to exclude everything else. 2015-03-05 17:06:29 -05:00
Zoltan Varga d7da3b09a1 [runtime] Remove the usage of MONO_INTERNAL, use MONO_API to mark exported functions and -fvisibility=hidden to exclude everything else. 2015-03-05 16:02:21 -05:00
Rodrigo Kumpera 64058140ee [loader] If probing for a pinvoke fails, log the error mono_dl_symbol gives us.
We used to swallow the error, which is unhelpful.

The reason for that might be because we probe multiple names before giving up but
even then, it's ok log all attempts. It will make troubleshooting easy, even if we
have to go through a lot more log entries.
2015-03-05 15:12:36 -05:00
Zoltan Varga 53406a1e0c [sdb] Avoid asserts on darwin when the thread deregistration code is ran from a pthread dtor. Fixes #27697. 2015-03-05 15:02:28 -05:00
Zoltan Varga f1b172fc2d [runtime] Fix byref out marshalling of arrays with a size parameter. Fixes #27614. 2015-03-05 14:24:50 -05:00
Sebastien Pouliot f2e21ed3fa [tests] IPInterfaceProperties DNS address does not currently work on iOS devices (since it read /etc/resolve.conf). Ignore it for XI until #27707 is fixed 2015-03-05 14:03:04 -05:00
Marek Safar 25a486ee92 [corlib] BaseType of by-ref types is null 2015-03-05 18:41:19 +01:00
Miguel de Icaza 64c50872d7 [System.ServiceModel.Web/WebMessageFormatter] Fix OperationContracts with void returns
WebMessageFormatter crashes when the OperationContracts had a void return type.

Fixes #20764, patch from <[email protected]>
2015-03-05 11:33:26 -05:00
keneanung aa3de31b70 Add NoData as valid return state for Statements with params
When using stements with parameters, the OdbcCommand would throw an exception
on ExecSQL when no row was returned. The commit adapts the change done in
5264613b6d for the case of unprepared statements
without parameters.
2015-03-05 17:08:04 +01:00
Marek Safar 65dba595ea [corlib] Enum from reference sources 2015-03-05 14:37:09 +01:00
Marek Safar 13c1275569 Merge pull request #1615 from akoeplinger/fix-consolelogger-race
[Microsoft.Build.Enginge] Fix race in ConsoleLogger
2015-03-05 07:42:38 +01:00
Marek Safar 518c3bcac5 Merge pull request #1614 from akoeplinger/fix-memorycache-tests
[System.Runtime.Caching] Make some MemoryCache tests more reliable
2015-03-05 07:41:19 +01:00
Alexander Köplinger aeffabc10f [Microsoft.Build.Enginge] Fix race in ConsoleLogger
This occasionally made the BasicManualParallelBuilds test fail on Jenkins.
2015-03-05 03:46:50 +01:00
Zoltan Varga ac75172a00 [build] Avoid redefining clean target in mcs/class/Makefile. 2015-03-04 20:09:22 -05:00
Zoltan Varga 54f7682968 [jit] Add a new mini_get_underlying_type () function which handles byref, enums, native types, and generic sharing. Use it in places where possible. 2015-03-04 20:03:30 -05:00
Alexander Köplinger e5cf24acde [System.Runtime.Caching] Make some MemoryCache tests more reliable
After MemoryCache was imported from referencesources, some tests started
failing occasionally. Cross-testing on MS.NET showed that you need to
access the cached item to make MemoryCache.GetCount() reliably return the
correct number after an item was expired from the cache.

Also removed __MonoTimerPeriod and __MonoEmulateOneCPU configuration variables,
they were used in Mono code before and don't make sense with the new code.
2015-03-04 13:46:04 -08:00
jason_naylor 60ef531176 Fix for the XMLSerializer bug 18558
* Find the type map element that is the most-specific to the
  object in question, not the first type it is an instance of

Change-Id: I1867e790bf9f377ce0ae02871f4561b760e27624
2015-03-04 10:25:37 -06:00
jason_naylor 6b74a2814f Test to reveal defect in XmlSerializer (Bug 18558)
Given the test data in this patch the wrong element name
is used when serializing TestSerializeSecondType

Change-Id: I8aff732dfd22f4f654fb42f2d3b987d7ce58d600
2015-03-04 10:25:12 -06:00
Atsushi Eno 6fdc2ecf07 Remove old System.Xml.Linq code. 2015-03-04 23:47:57 +08:00
Marek Safar 50db473790 [system.xml] Clean up build output 2015-03-04 13:45:25 +01:00
Atsushi Eno 9dc2beb577 bump referencesource, bring in the fix for bug #27258. 2015-03-04 20:28:13 +08:00
Marcos Henrich 120351d4f5 [System] Replaced while loop logic with an if.
The while loop is unnecessary because Interlocked.CompareExchange in this case already guarantees that blocking_threads is not null.
2015-03-04 12:22:40 +00:00
Atsushi Eno 7964743ae0 Merge pull request #1613 from atsushieno/import-system-xml-linq
Import System.Xml.Linq from referencesource.
2015-03-04 16:05:42 +08:00
Atsushi Eno 60bc3cd67f Merge branch 'master' into import-system-xml-linq 2015-03-04 12:59:51 +08:00
Atsushi Eno 51c8433b18 bump referencesource. 2015-03-04 12:58:42 +08:00
Atsushi Eno 854a2fba5f XLinq in referencesource depends on S.R.Serialization. 2015-03-04 11:44:16 +08:00
Atsushi Eno c90c434b8d Merge branch 'master' into import-system-xml-linq 2015-03-04 11:44:07 +08:00
Miguel de Icaza 23625eff75 [Registry] Revert 826060172f until I fix the regression 2015-03-03 21:59:07 -05:00
Zoltan Varga d651e3d670 Fix Microsoft.Build tests which got broken by some newline changes in ef380e3712. 2015-03-03 19:11:36 -05:00
Zoltan Varga eb2bd2c1a8 Fix make dist. 2015-03-03 17:48:08 -05:00
Miguel de Icaza 1b7f975ba1 Style consistency with the rest of Mono's code 2015-03-03 17:26:23 -05:00
Zoltan Varga 34cdab89ff [build] Delete class/lib/$(PROFILE) on clean. 2015-03-03 16:55:31 -05:00
Zoltan Varga f88248ee17 [jit] Really enable partial generic sharing. 2015-03-03 16:46:37 -05:00
Alexander Köplinger 588046144a appveyor.yml: switch away from unstable image and simplify script
The unstable image seemed to cause problems recently.
We should just use the default image and fetch Cygwin ourselves.

Also added caching of the Cygwin files and simplified the script a bit.
2015-03-03 22:35:36 +01:00
Miguel de Icaza 826060172f [UnixRegistry] Fix leak (#25559), remove races.
There was a memory leak caused by not having a lookup mechanism for
the RegistryKey.  In addition, the entire code to dispose code was
never used (due to the leak), and it was wrong.

In addition, added locking to the "values" field, which currently was
racy.

No test cases, the repro is to run the above code for about 5 minutes.
2015-03-03 16:19:37 -05:00
Zoltan Varga ef380e3712 Rename Managed.Windows.Forms to System.Windows.Forms for consistency. 2015-03-03 15:59:16 -05:00
Zoltan Varga 837b034d76 [jit] Enable partial generic sharing when not using AOT as an experiment. 2015-03-03 15:27:11 -05:00
Atsushi Eno a314eac67e Remove old System.Xml sources. bye bye. 2015-03-04 03:31:00 +08:00
Alexander Kyte 06163ca774 [Runtime] Added logging around finalizers 2015-03-03 14:17:14 -05:00
Atsushi Eno cfa8bc07f6 import System.Xml.Linq from referencesource. 2015-03-04 02:40:49 +08:00
Marek Safar ce10d3b2be [corlib] Peek to attribute import from reference souces 2015-03-03 17:50:58 +01:00
Marek Safar 74793c47ab [corlib] Apply activation attributes for IsContextful types only 2015-03-03 17:50:58 +01:00
João Matos b91712816c Support multiple options when processing the AOT flag "ld-flags". 2015-03-03 16:29:08 +00:00
Marcos Henrich d26501a4d9 [runtime] Implemented mach and windows mono_threads_core_abort_syscall.
call_cancel_blocking_socket_operation relies on mono_threads_core_abort_syscall which will now work on mach and windows.
2015-03-03 16:07:44 +00:00
Marcos Henrich 7f5126dfaa [System] Moved blocking system calls logic to SafeSocketHandle.
All the blocking system calls are now registered.
SafeSocketHandle.ReleaseHandle now aborts system calls before closing the socket.
2015-03-03 15:33:51 +00:00
Atsushi Eno 8e3da5fe7c Update expected error message to match System.Xml referencesource. 2015-03-03 22:43:22 +08:00
João Matos ef2db766e2 Merge pull request #1611 from mono/akoeplinger-patch-1
Readme: add badges for armel/armhf and split off community supported archs
2015-03-03 14:40:32 +00:00
Alexander Köplinger 8ac85a3121 Readme: add badges for armel/armhf and split off community supported archs 2015-03-03 15:06:18 +01:00
Marek Safar a1487060c0 [corlib] Activator from reference sources 2015-03-03 14:28:34 +01:00
Atsushi Eno e9ef998703 Merge pull request #1608 from atsushieno/import-system-xml-4
Import large chunk of System.Xml sources from referencesource.
2015-03-03 20:04:43 +08:00
Zoltan Varga 1a679a64fc [aot] Fix thumb support with separate llvm modules. 2015-03-02 22:37:43 -05:00
Zoltan Varga bc849e04bc [arm] Fix support for backward branches in mono_arm_get_thumb_plt_entry (). 2015-03-02 22:37:20 -05:00
Zoltan Varga ec67acc7ae Disable bug-Xamarin-5278.exe for now to make the build green again, it was broken by 5d26590e79. 2015-03-02 20:39:01 -05:00
Zoltan Varga 65c4728162 Revert some accidental changes in c00a4c8003. 2015-03-02 20:20:53 -05:00
Zoltan Varga c00a4c8003 [runtime] Fix the non-loaded llvm build. 2015-03-02 20:16:15 -05:00
Rodrigo Kumpera 49d81f6c73 Merge pull request #1610 from madewokherd/decimalbuild
Rename decimal functions to not conflict with win32 versions.
2015-03-02 14:26:09 -06:00
Vincent Povirk 8ea6384117 Rename decimal functions to not conflict with win32 versions. 2015-03-02 14:19:09 -06:00
Atsushi Eno e7da0c1319 Merge branch 'master' into import-system-xml-4 2015-03-03 03:46:39 +08:00
Zoltan Varga 13685c2326 [build] Add the assemblies in LIB_REFS to LIB_MCS_FLAGS automatically to reduce duplication. 2015-03-02 14:03:56 -05:00
João Matos fa5e78a8d7 Merge pull request #1609 from iainx/build-cov-for-osx
[COV] Set the correct link flags for OS X
2015-03-02 16:08:40 +00:00
Iain 07654fb2ea [COV] Set the correct link flags for OS X
Cov needs to be linked using the flat namespace on OS X, the same way that proflog is linked or else it won't do anything.
2015-03-02 15:51:10 +00:00
Marcos Henrich 5194d5689e [System] Socket.socket is now a SafeSocketHandle. 2015-03-02 14:32:53 +00:00
Marcos Henrich ecf83bcb93 [System] Added SafeHandle overloads for Socket icalls.
Using a SafeHandle overload avoids handle reuse.
2015-03-02 14:32:52 +00:00
Marcos Henrich fe767bf2c7 [System] Added SafeSocketHandle.cs.
Added an implementation of SafeHandle that will be used by System.Net.Sockets.Socket to store socket handles.
2015-03-02 14:32:50 +00:00
Atsushi Eno 510710e423 take out ThisAssembly from SR.cs, conflicts with the one in Sys.Data. 2015-03-02 21:32:07 +08:00
Marek Safar 31afb2659c [mcs] Handle string constants inside interpolated string expression. Fixes #27533 2015-03-02 14:19:37 +01:00
Jo Shields 2175d73ac6 Add net_4_5_parallel_dirs to SUBDIRS, so it's included in "make dist" 2015-03-02 12:58:52 +00:00
Atsushi Eno 2fc5471e11 fix build; I only updated Consts.cs, not Consts.cs.in... 2015-03-02 19:35:32 +08:00
Atsushi Eno 751ecd3e5b [xml] take out some types in Dummy.cs to better source files. 2015-03-02 19:12:39 +08:00
Atsushi Eno 20cfe2e4c1 XML error messages has changed again now that they are from referencesource. 2015-03-02 19:11:54 +08:00
Marek Safar e17e4f170e [mcs] Add cloning to string interpolation expressions. Fixes #27525 2015-03-02 10:16:48 +01:00
Atsushi Eno 4bdf5defdd Add referencesource's [InternalsVisiblTo] attributes in System.Xml.dll. 2015-03-02 11:36:45 +08:00
Atsushi Eno 331e521fdc [xml] Fix dropped lines in Makefile during merge. 2015-03-02 11:36:45 +08:00
Atsushi Eno 55d49237d0 Fix mobile build wrt. Res classes. 2015-03-02 11:36:44 +08:00
Atsushi Eno c646ba01a3 Add referencesource-based message strings to the build.
It should be using RESOURCE_STRINGS, but mcs doesn't support its special
option for string resources for multiple files.

The resource .cs files are generated by genresstringcs.sh, but System.Xml.txt
contains some bogus characters that prevents source generation, so after
the tool has generated the sources, I manually fixed them.
It won't matter once mcs supports the option for multiple files anyways.
2015-03-02 11:36:44 +08:00
Atsushi Eno 0763126f4b [xml] update message resources for referencesource. 2015-03-02 11:36:43 +08:00
Atsushi Eno 4e2bd09616 Update all mcs errors expected messages for referencesource changes. 2015-03-02 11:36:43 +08:00
Atsushi Eno b91781b08f Fix regression in mcs/tools/mdoc by giving referencesource-based message.
(The error message is actually created by ourselves.)
2015-03-02 11:36:43 +08:00
Atsushi Eno 91657324d6 [mdoc/Test] add missing DTD.
With referencesource, the XmlReader now requires the DTD in SYSTEM
declaration to exist. So just add the DTD.
2015-03-02 11:36:43 +08:00
Atsushi Eno 47e8337395 [msbuild] fixing referencesource import "regression".
It is about insignificant whitespace handling difference.
2015-03-02 11:36:42 +08:00
Atsushi Eno cae1f99ef8 [Xml] another human readable exception message. 2015-03-02 11:36:42 +08:00
Atsushi Eno 82b6e115cc [Xml] fix regression in winforms tests.
ResXResourceReaderTest checks that the argument file is in the error
message. We only have stub messages so far, hence it "regressed".
2015-03-02 11:36:42 +08:00
Atsushi Eno b40dd06602 [WCF] fix mobile builds. Mono.Xml.XPath is gone. 2015-03-02 11:36:42 +08:00
Atsushi Eno 94f667b1f3 [Xml] add mobile XslCompiledTransform implementation.
XslCompiledTransform doesn't work without CodeDom and dynamic code
generation. This "implementation" just dispatches everything to XslTransform.
2015-03-02 11:36:42 +08:00
Atsushi Eno 281e3c0a11 [Xml] Removed XslCompiledTransform and co. Now monodroid builds.
It will be added as mere alias of XslTransform as mono used to do.
2015-03-02 11:36:41 +08:00
Atsushi Eno e7b1d9d96e [Sys.Xml] first onging mobile build work. It does NOT build for mobiles now.
Removed Configuration dependencies and codegenerator parts in XmlSerializer
as well as switching CodeIdentifier implementation to old mono stuff
as referencesource totally depends on CodeDom (mono doesn't).
2015-03-02 11:36:41 +08:00
Atsushi Eno 8d2cf588c9 [Xaml] fix EOL handling in tests. referencesource emits LF. 2015-03-02 11:36:41 +08:00
Atsushi Eno 6d3edb6643 [Sys.Xml] give understandable message and arguments for Xml_WrongToken. 2015-03-02 11:36:41 +08:00
Atsushi Eno 77c316c520 [XLinq] fix some "regressions" caused by referencesource switch.
EOLs are platform dependent on referencesource.

Turn NotDotNet into Ignore (as we're also importing buggy implementation).
2015-03-02 11:36:40 +08:00
Atsushi Eno 848916fb2b [S.R.Serialization] explicitly add MS serialization schema if it's not in the set. 2015-03-02 11:36:40 +08:00
Atsushi Eno 3c4c9e5759 [Sys.Xml] swap xmlns:xsd and xmlns:xsi in serialized xml to remove "regression".
The order of those namespaces are insignificant, and the latest
combination of mono corlib (partly referencesource-d) and sys.xml
(referencesource except for XmlSerializer) caused this implementation
glitch.
2015-03-02 11:36:40 +08:00
Atsushi Eno 27d469af0d [Sys.Data] fix wrong test in XmlDataDocument.
This doesn't match .NET behavior.
(Found by referencesource import, verified w/ .NET 4.5.)
2015-03-02 11:36:40 +08:00
Atsushi Eno 81e07b6e1a [Sys.Data] Fix tests regarding XmlTextWriter EOL handling.
MS referencesource changed XmlTextWriter behavior regarding EOL so that
now it preserves CRLF as is, instead of replacing them with
XmlWriterSettings.NewLineChars (mono implementation behavior).

There are some tests that depend on old behavior. The entire points of
those XmlDataDocument tests are not about checking EOLs, so just replace
the test XML file to not contain CRLF.
2015-03-02 11:36:39 +08:00
Atsushi Eno ff9d202ceb [Sys.Data] fix DOM event order related issue caused by referencesource.
There is implementation mismatch in XmlDocument event order regarding
Load(). Take this code:

	string xml = "<root><child>1</child></root>";

	var doc = new XmlDocument ();
	doc.NodeInserted += (o, e) =>
		Console.WriteLine (e.Node.NodeType + e.Node.LocalName);
	doc.LoadXml (xml);

This is mono output before referencesource:

	Text#text
	Elementchild
	Elementroot

This is with referencesource:

	Elementchild
	Text#text
	Elementroot

So, there are event order differences in our two implementations.

Now, XmlDataDocument depends on those XmlDocument events to fill DataRow
values. It worked fine with pre-referencesource System.Xml model, but
with referencesource it skipped to fill data row values.

This change makes sure to fill data row values from text node which are
added _after_ the parent node is added to the document.
2015-03-02 11:36:39 +08:00
Atsushi Eno fd25cd14ca [System.Data] fix another NRE that was exposed by referencesource. 2015-03-02 11:36:39 +08:00
Atsushi Eno e8fa9b5229 [System.Data] MS implementation doesn't expect CRLF on *nix. Use Env.NewLine. 2015-03-02 11:36:39 +08:00
Atsushi Eno a5ea493bdd [System.Data] MS implementation does NOT expect CRLF in the output on *nix. 2015-03-02 11:36:39 +08:00
Atsushi Eno eb71b01513 [System.Data] fix NRE that was exposed by referencesource. 2015-03-02 11:36:38 +08:00
Atsushi Eno e7d2a05791 update dummy messages to somewhat understandable values. 2015-03-02 11:36:38 +08:00
Atsushi Eno 4990b4c47b First step to import referencesource System.Xml.
It is not simply replacement because we have to workaround dynamic codegen
for Xamarin.iOS.

Also there were several tests failing with MS implementation (e.g. for
W3C DOM conformance), so we had to disable them.

There is one regression that rather needs to be fixed in Reflection.Emit.

Also, some WCF tests fail with this implementation. They need to be
investigated, reviewed and appropriately fixed.
2015-03-02 11:36:38 +08:00
Zoltan Varga b862ff8acc [jit] Rename mini-llvm.h to mini-llvm-loaded.c and make it a non-header file. 2015-03-01 22:15:09 -05:00
Zoltan Varga e71fdeef4c [runtime] Fix the loadable llvm build. 2015-03-01 18:36:26 -05:00
João Matos b8467ef0dd Merge pull request #1514 from directhex/master
Workaround for X509Certificate.RSA throwing an unhandled exception
2015-03-01 20:36:42 +00:00
Zoltan Varga 2d8af16663 [jit] Move aot method loading to mono_jit_compile_method_with_opt (). 2015-03-01 00:47:02 -05:00
Zoltan Varga 880fb9c3eb [jit] Remove some dead code/includes. 2015-03-01 00:17:38 -05:00
Zoltan Varga 83e2223403 [runtime] Split mini.c into two files: mini.c contains the JIT code, while mini-runtime.c contains the runtime code, i.e. startup/shutdown, threading, tls, etc. 2015-03-01 00:03:07 -05:00
Zoltan Varga f6ea703e09 Fix a warning. 2015-02-28 22:56:31 -05:00
Zoltan Varga ac637b0fa1 [build] Avoid changing System.Xml.Linq references to System.XML.Linq during parallel build dependency calculation. 2015-02-28 20:56:52 -05:00
Zoltan Varga 0b4533dd59 [jit] Remove some dead code. 2015-02-28 17:01:28 -05:00
Zoltan Varga 4cd6718bf6 Merge pull request #1607 from davidmoore1/bug-27529
Bug 27529 Tool Tip appears behind menu
2015-02-28 16:19:26 -05:00
David Moore f3ff59749f Bug 27529 Tool Tip appears behind menu
In certain cases, hovering over a ToolStripMenuItem
that has a tool tip defined will result in the tool
tip appearing behind, and hidden by, the context
menu containing the item.  The change is to cause
the tool tip to be pushed to the front when it is
displayed.
2015-02-28 11:00:05 -05:00
Jo Shields d53ed1c8f8 Workaround for X509Certificate.RSA throwing an unhandled exception in ASN1 parsing of certificates with ECC public keys only. 2015-02-28 12:48:49 +00:00
Zoltan Varga 3ceb869495 [bcl] Enable parallel build for parts of the 4.5 class libs/tools. 2015-02-27 19:46:29 -05:00
Zoltan Varga d5fcd29868 [llvm] Increase the size of a parameter array which was too small for some arm64 calling conventions. 2015-02-27 13:33:30 -05:00
Marek Safar c47a456d29 [Microsoft.Build.Engine] Update missing method exception type 2015-02-27 19:08:33 +01:00
Marek Safar 001c0d17eb [corlib] Throw correct exception for missing properties called via InvokeMember 2015-02-27 18:59:43 +01:00
João Matos 5927ede215 Added "ld-flags" to pass extra linker flags to the AOT linker pipeline. 2015-02-27 17:26:23 +00:00
Rodrigo Kumpera ec8a06433f Remove explicit support for 2.0, it will now use 4.5 2015-02-27 11:07:27 -05:00
Marek Safar 4f23050db1 [mcs] Better error reporting for wrong unexpected escaped characters. Fixes #27441 2015-02-27 16:57:35 +01:00
Zoltan Varga c947640d2a Merge pull request #1605 from iainx/cov-install-coverage-filter
Check the coverage hash exists before accessing it
2015-02-27 10:41:07 -05:00
iain holmes 7ce0c7c9bb Check the coverage hash exists before accessing it
If a profiler has not installed a coverage filter, or the coverage filter has returned FALSE, then calls to mono_profiler_coverage_get trigger a assertion failed warning in g_hash_table_lookup.
2015-02-27 15:28:31 +00:00
Zoltan Varga f4e7da7e0c Merge pull request #1604 from iainx/cov-install-coverage-filter
[cov] Install a coverage filter
2015-02-27 10:25:02 -05:00
Marek Safar 9b4e5bb49b [corlib] Implement Activator invocation on params constructor with conversion from object 2015-02-27 14:43:25 +01:00
Zoltan Varga 8b43cc0761 Merge pull request #1603 from iainx/coverage-null-protect
Check for valid coverage info before dereferencing it.
2015-02-27 08:07:48 -05:00
iain holmes 5e9bbbc27e Check for valid coverage info before dereferencing it.
If a profiler had requested MONO_PROFILE_COVERAGE events and not installed a
coverage filter, then the coverage info is NULL and a crash quickly followed
2015-02-27 12:35:40 +00:00
Marek Safar 2ec7528ec5 Bump reference sources to fix #27492 2015-02-27 13:13:01 +01:00
Marek Safar 23603fe1bd [corlib] Add DefaultDllImportSearchPathsAttribute 2015-02-27 13:02:35 +01:00
Marek Safar 5d26590e79 [corlib] Binder from reference sources 2015-02-27 12:06:17 +01:00
Marek Safar 739afc39be [build] Use resource strings for library builds only 2015-02-27 11:35:05 +01:00
iain holmes e91693fbb8 [cov] Install a coverage filter 2015-02-27 10:13:54 +00:00
Zoltan Varga 2656bf0cc7 [build] Fix a bug in 37983f7fc3. 2015-02-26 23:30:35 -05:00
Zoltan Varga 37983f7fc3 [build] Add dependency information for class libraries using a LIB_REFS variable which lists the assemblies a given assembly depends on to build. 2015-02-26 22:27:27 -05:00
Zoltan Varga 5cf4cbde3a [bcl] Remove some net 1.0 stuff from Makefiles. 2015-02-26 18:06:29 -05:00
Zoltan Varga c38f5406a7 Merge pull request #1602 from cdettmering/master
Fixing ToolStripManager.RevertMerge
2015-02-26 17:54:40 -05:00
Chad Dettmering 9fe0952221 Fixed up formatting to comply with Mono coding guidelines 2015-02-26 17:47:03 -05:00
Chad Dettmering 2550e73081 Changed System.Windows.Forms.ToolStripManager.RevertMerge to return
false when given a null argument instead of throwing an exception.
According to the msdn here:
https://msdn.microsoft.com/en-us/library/b4e35dwy%28v=vs.110%29.aspx
this method should never throw an exception. This was also confirmed
with the official Microsoft runtime.

This change is released under the MIT license.
2015-02-26 17:31:49 -05:00
Zoltan Varga 4c9cd80099 [jit] Disable direct calls to icalls when using llvm, llvm can't handle direct calls to 64 bit addresses (tests/jit-float.exe fails). 2015-02-26 15:18:56 -05:00
Rolf Bjarne Kvinge 6fe661159c Ignore a few decimal tests on mobile, according to #27269
https://bugzilla.xamarin.com/show_bug.cgi?id=27269
2015-02-26 20:01:06 +01:00
Zoltan Varga d32a4bd512 [runtime] Use mono_set_pending_exception () in some places in icalls. Avoid using it for throwing exceptions returned by mono_thread_execute_interruption (), since that seems to cause problems. 2015-02-26 13:08:34 -05:00
Zoltan Varga 690183aa08 [runtime] Disable the "bridge-implementation=tarjan,major=marksweep-conc|ms-conc-tarjan-bridge" sgen tests which currently fail. 2015-02-26 12:57:14 -05:00
Rolf Bjarne Kvinge d79c519b39 Don't use _NSGetEnviron on arm64. 2015-02-26 13:55:30 +01:00
Rolf Bjarne Kvinge 1dbe593001 Restrict IOKit usage to desktop OSX.
IOKit is a private framework in iOS, so it can't be used (and
no headers are provided, so it doesn't even compile).
2015-02-26 13:49:59 +01:00
João Matos 4b6173d11f Fixed compilation on Linux targets without linux/serial.h.
/Users/builder/data/lanes/monodroid-mavericks-master/7de6731a/source/mono/support/serial.c:25:26: fatal error: linux/serial.h: No such file or directory
 #include <linux/serial.h>

The header is only available on Android NDK API level >= 21.
2015-02-26 12:09:17 +00:00
Zoltan Varga c9b2e3e4c2 Merge pull request #1599 from StephenMcConnel/bug-26887-A
Prevent right click from triggering ToolStrip.OnItemClicked
2015-02-25 19:49:27 -05:00
Rodrigo Kumpera abd5c65999 [sgen-bridge] Fix all the bridges after the change to have descriptor loading happen outside of scanning.
This changes all bridges to use the _safe variant of sgen_obj_get_descriptor. Bridge processing happens in
the post-scan world, before objects get untagged.
2015-02-25 18:16:23 -05:00
Stephen McConnel 0c95513a0e Prevent right click from triggering ToolStrip.OnItemClicked
This addresses https://bugzilla.xamarin.com/show_bug.cgi?id=26887
(along with a previous fix).
2015-02-25 17:00:30 -06:00
Rodrigo Kumpera e02337995e Fix my last commit to properly include the tarjan test suite. 2015-02-25 17:54:51 -05:00
Rodrigo Kumpera 1d57482131 Add the tarjan bridge to the test matrix. 2015-02-25 17:50:46 -05:00
Rodrigo Kumpera 68dcdcaac6 [sgen] Fix the sgen bridge test suite. Oh my. 2015-02-25 17:43:42 -05:00
Rodrigo Kumpera 132d9511ff Merge pull request #1598 from mono/revert-1593-new_suspend
Revert "This introduces the new suspend machinery. Right now the unified...
2015-02-25 16:39:59 -06:00
Rodrigo Kumpera 43a734f579 Revert "This introduces the new suspend machinery. Right now the unified STW is disabled for sgen." 2015-02-25 17:39:26 -05:00
Atsushi Eno 03ff64f6e1 bump referencesource. 2015-02-26 05:16:13 +08:00
Rodrigo Kumpera 5786bd0ce9 Merge pull request #1597 from akoeplinger/remove-ef
Remove EntityFramework from class libs
2015-02-25 15:01:28 -06:00
Zoltan Varga 0bab8ed6a0 [runtime] Remove definitions of MONO_SHARED_DIR from scripts, its not needed anymore. 2015-02-25 15:45:22 -05:00
Alexander Köplinger c1bbee0b95 Remove EntityFramework from class libs
We currently ship a horribly outdated version of EF. This is unnecessary since EF is on NuGet and has an active set of users using it on Unix.

Miguel gave his +1 on the mailing list already.
2015-02-25 21:24:52 +01:00
Rodrigo Kumpera 9e79098001 Merge pull request #1593 from kumpera/new_suspend
This introduces the new suspend machinery. Right now the unified STW is disabled for sgen.
2015-02-25 13:53:36 -06:00
Zoltan Varga f30e78bcab [jit] Make the opcode emulation jit icalls callable without a wrapper in some cases. 2015-02-25 14:48:50 -05:00
Miguel de Icaza ccaf0cc44c [SslClientStream] Prevent crashes when a connection is closed
When a socket has been closed as part of the negotiation, the
SendAlert method would crash when trying to reuse the socket.

Add try/catch around this to prevent this.

Fixes #19334
2015-02-25 12:01:15 -05:00
Miguel de Icaza 2f953191fc Merge pull request #1584 from zevane/patch-2
Limit the lock to the writing operation
2015-02-25 10:32:00 -05:00
Miguel de Icaza 5b2d5b4bf4 [Serial] Add support for high baud rates to MacOS 2015-02-25 10:27:43 -05:00
Miguel de Icaza 87357b51e9 [serial,signal] Add support for Linux arbitrary baud rates + drop Apple legacy poll support
This patch brings support for arbitrary baud rates in Linux, from patch:

https://bugzilla.xamarin.com/show_bug.cgi?id=8207

Which has been MIT licensed (see mono-devel-list).

In addition, while testing the patch, discovered that we are using
fakepoll.h on MacOS which was there to support Tiger-era broken poll
implementations.

The details about the lack of poll support come from this document
that is now only available on web.archive.org:

http://web.archive.org/web/20030604064847/http://developer.apple.com/technotes/tn2002/tn2071.html

And the original Mono bug that reported the problem in 2008, followed
by the fixes is reported and discussed here:

https://bugzilla.novell.com/show_bug.cgi?id=384227

The source of the problem, confirmed by an Apple employee at the time
(form the bug) is that poll sometimes results in returning POLLHUP
when a POLLIN was expected:

http://curl.haxx.se/mail/lib-2005-05/0122.html

This web site tracks the behavior of poll (POLLHUP and POLLIN) across
Posix implementations when you reach an end of file:

http://www.greenend.org.uk/rjk/tech/poll.html
2015-02-25 10:20:44 -05:00
Marek Safar 0b7afa989d [system.net.http] Add another workaround for incompatible mono Uri handling. Fixes #27386 2015-02-25 12:28:47 +01:00
Marek Safar 6ee0adb342 [System.Net.Http] Change relative uri test to not require internet access 2015-02-25 08:45:03 +01:00
Atsushi Eno 06334e4f24 remove replaced and unused Encoding code. 2015-02-25 15:20:23 +08:00
Atsushi Eno 8d24d4dc74 Merge pull request #1590 from atsushieno/import-diagnostics-trace
Import System.Diagnostics.Trace from referencesource
2015-02-25 15:14:53 +08:00
Atsushi Eno c4929cbf9c remove replaced System.Diagnostics.Trace family code. 2015-02-25 15:13:27 +08:00
Zoltan Varga 93a5401ee0 Revert "[runtime] Use mono_set_pending_exception () in some places in icalls."
This reverts commit d0d0d29320.

Revert this as it caused too many test failures.
2015-02-24 18:20:41 -05:00
Atsushi Eno 4add6e6c44 [xml] add missing CONFIGURATION_DEP 2015-02-25 07:18:34 +08:00
Zoltan Varga 281c3842d3 [runtime] Declare ICALL_EXPORT as MONO_API so it works with -fvisibility=hidden. 2015-02-24 18:07:26 -05:00
Zoltan Varga 47ef0fd121 Fix a warning. 2015-02-24 18:07:26 -05:00
Zoltan Varga 623f54afed [runtime] Remove some dead definitions. 2015-02-24 18:07:26 -05:00
Marek Safar 48daad9728 [Mono.XBuild.Tasks] Fixes versioning with newer than 4.0 special msbuild profiles 2015-02-25 00:04:51 +01:00
Rodrigo Kumpera b0d6f33857 bump master version of mono. 2015-02-24 17:28:10 -05:00
Rodrigo Kumpera 59c82ade25 [threading] Rework suspend code to be based on a state machine and eliminate known races in the process.
The new suspend machinery is based around a single word state machine that is manipulated using CAS.

This solves the first set of problems with the current approach, the lack of atomicity and the impossibility of
doing race free manipulation of protected state. This is specially acute when doing a self suspend.
Suspend data must be atomically protected while we prepare to self suspend so a resume request won't race with the current
thread putting itself to sleep. This is a classical problem that calls for a mutex/conditional variable pair. Except that all
locks in the suspend path must be suspend safe. Wait, WHAT?

A Suspend Safe Lock is a primitive that is obstruction free in the face of the kernel suspending a thread either performing a
lock operation or waiting on a lock to become available. This, unfortunately, is not possible with pthread_mutex on OSX. The
only safe primitive are kernel semaphores, for which doesn't exist conditional variables for.

So back to locking and self-suspend. We need a lock because the existing thread state is not atomic but we can't use a
mutex/condvar pair so we're left with racy code. Yay! The fix is using CAS over a single variable.

Another change was the hardening of the suspend/resume code on posix targets. First we replace a semaphore wait with
sigsuspend for async suspend. This is needed since sem_wait is not async-signal safe (yet sem_post is). Second, we now
respect interruption requests by having a pair of suspend signals, one with SA_RESTART and one without.

Onto the design of the suspension system, a few concepts that are useful looking around.

* Self suspend: This is when the thread decides to suspend itself.

* Async suspend: This is when a thread decides to suspend another thread.

* Suspend Initiator: This the name of a thread that decided to suspend one or more other threads. This is important
since all suspending threads will notify it when they are suspended. There can be only one initiator in the system
at a given time.

* Suspension count: Number of resume calls before a thread is back to running state.

There are 7 states that can happen while a thread is runnable:

* Running: just running...

* (Async|Self) Suspended: Suspended, the difference comes into play when resuming.

* (Async|Self) Suspend Requested: Suspend requested, but not completed. See more below for the discussion on why the request state is needed.

* Suspend In Progress: Self suspend started saving its state thus async suspend should not modify it.
* Suspend Promoted to Async: Async tried to suspend a thread in the middle of a self suspend, it wants to be notified.

Now to the suspension protocol and how it happens on a high level view.

Suspension starts with a suspend request, which bumps the suspend count by one. This suspend request can be fulfilled either
by an async or self suspend action. This is confusing as there's only one initiator but any number of threads can be self suspending.

Async suspend then performs a platform specific action such as posix signals that forces a transition on the target. In the case
of self suspend, it depends on the thread polling its state and trigger the transition.

This works fine except that the suspend state is one huge struct with tons of fields. To control concurrent access to it we use a
single initiator in the case of async suspend and we put the thread in a transitional "saving my state" in the case of self suspend.

In the case of async suspend, the initiator must wait for all 1+ threads to notify back that they have suspended. Only after that
it's possible to know if the async suspend request actually worked or not (we might have hit a dying thread).

Together with this, there's an optional implementation of STW in sgen that can use this new machinery. To enable it set the
MONO_ENABLE_UNIFIED_SUSPEND env var for now while it gets more testing.
2015-02-24 17:14:28 -05:00
Zoltan Varga d0d0d29320 [runtime] Use mono_set_pending_exception () in some places in icalls. 2015-02-24 16:42:13 -05:00
Rodrigo Kumpera 0b3822a9e1 Merge pull request #1591 from akoeplinger/remove-npgsql
Remove Npgsql from class libs
2015-02-24 14:41:16 -06:00
Alexis Christoforides 2df1c787bf [Decimal] Fix C89 compliance in decimal-ms.c 2015-02-24 12:21:24 -08:00
Marek Safar 665a55d4f8 [facades] Add missing System.ServiceModel.Primitives forwarders to MT profile. Fixes #27338 2015-02-24 20:29:34 +01:00
Marek Safar 2984695832 [corlib] Use HGlobalUnmanagedMemoryStream directly from MonoTouch timezoneinfo 2015-02-24 20:15:56 +01:00
Alexander Köplinger 762bc0bbe6 Remove Npgsql from class libs
This has been requested by the maintainers of Npgsql a few times already (https://bugzilla.xamarin.com/show_bug.cgi?id=23119) and we should do it for Mono 4.0.
Miguel gave his +1 on the mailing list already.
2015-02-24 20:12:40 +01:00
João Matos b528a79db5 [runtime] Upgraded Jay MSVC project to VS 2013. 2015-02-24 18:46:11 +00:00
João Matos 220afd9d49 [runtime] Fixed the MSVC build.
Even though this seems like it's just moving the files around in the project, for some reason it makes a difference to VS.
2015-02-24 18:46:04 +00:00
Rodrigo Kumpera 46c30d31f8 [sgen] Introduce SgenThreadInfo::suspend_done.
This variable must be set to all threads that have been properly suspended. This is
an initial step to simplify suspend state and use explicitly named variables instead
of hiding state in stopped_ip / stopped_domain.
2015-02-24 13:33:49 -05:00
Rodrigo Kumpera 6bd7be2081 Add suspend done everywhere else. 2015-02-24 13:33:49 -05:00
Atsushi Eno 525c47a7f3 Bring back DefaultTraceListener because it already works better for mono. 2015-02-25 01:23:35 +08:00
Atsushi Eno d6bd25591b import System.Diagnostics.Trace etc. from referencesource. 2015-02-25 00:54:38 +08:00
Atsushi Eno c34def6299 bump referencesource to include System.Diagnostics changes. 2015-02-25 00:04:49 +08:00
Marek Safar 6f14f86357 [system.net.http] Accept header with multiple values. Fixes #27352 2015-02-24 16:55:01 +01:00
Rodrigo Kumpera e9836b3511 Merge pull request #1587 from kumpera/cleanup_threading
This is a small cleanup of the threading API.
2015-02-24 09:02:24 -06:00
Marek Safar f35b4f0996 [corlib] BinaryWriter/BinaryReader from reference sources 2015-02-24 10:33:45 +01:00
Marek Safar 6a415e894c [corlib] UnmanagedMemoryStream from reference sources 2015-02-24 10:28:35 +01:00
Atsushi Eno 9f5a54b33e bump referencesource (more BIGENDIAN fixes for UnicodeEncoding). 2015-02-24 12:56:17 +08:00
Zoltan Varga cd4cb57572 [runtime] Fix the non-msvc build. 2015-02-23 20:41:30 -05:00
Zoltan Varga 3d984f7feb [runtime] Mark mono_set_pending_exception () as a cold function, so calling code is generated out-of-line. 2015-02-23 20:05:40 -05:00
Zoltan Varga 40e8a35f27 [jit] Use mono_set_pending_exception () instead of throwing exceptions in JIT icalls. 2015-02-23 20:05:05 -05:00
Rodrigo Kumpera 7b6bb72285 [threading] Don't suspend a thread running out of its thread bounds. 2015-02-23 17:41:28 -05:00
Rodrigo Kumpera b093d2384f [threading] compute thread boulds on thread registration. 2015-02-23 17:41:27 -05:00
Zoltan Varga aa4768dafb [runtime] Disable some dyncall/gsharedvt fullaot tests on amd64. 2015-02-23 16:52:36 -05:00
Zoltan Varga 3eeb285c9a [bcl] Fix Console support on ios, the TextWriter class from the reference sources called TextWriter:Write(char), so stdout was never flushed. 2015-02-23 16:08:39 -05:00
Rodrigo Kumpera 4e1dca9d5e [threading] When checking if a thread is in a critical region, ask the GC too.
MonoThreads was previously ignoring sgen's in_critical_region, which could lead
to a thread suspended inside a gc critical region leading to the GC not been able
to STW.
2015-02-23 15:54:04 -05:00
Rodrigo Kumpera 8a133f2d7e [threading] Introduce mono_thread_info_is_live and move all thread state testing to inside MonoThread. 2015-02-23 15:47:17 -05:00
Zoltan Varga d20fb1aa2e [jit] Make mono_thread_interruption_checkpoint () return the exception which needs to be thrown and throw it from the managed method/wrapper which called it. 2015-02-23 14:19:20 -05:00
Marek Safar e3e6f308fd [system] Bymp reference sources to get correct category names 2015-02-23 19:24:17 +01:00
Marek Safar 602287a0da Bump reference sources for stream api update 2015-02-23 18:14:45 +01:00
Ludovic Henry a81a3ce4a1 [mdoc] Update few failing tests 2015-02-23 11:27:22 -05:00
Marek Safar a5f6ff93ed [mdoc] Update few failing tests 2015-02-23 17:15:44 +01:00
Marek Safar 04c5ac7f7e [system.core] Switch to dynamic visitor from reference sources and remove unused files 2015-02-23 17:03:43 +01:00
Marek Safar 31b143fdc1 [build] 3.10 bump for bootstrap was too much 2015-02-23 13:40:31 +01:00
Atsushi Eno 45d731a8bc bump referencesource (fix encoding endianness). 2015-02-23 20:24:59 +08:00
João Matos 82dbc244da Merge pull request #1586 from vkargov/master
[runtime] Prioritize loading a profiler library from the installation dir.
2015-02-23 11:11:52 +00:00
Marek Safar e220c8f7cb [build] Bump bootstrap mono requirement to 3.10 which does not have problems with flow-analysis in external/referencesource/mscorlib/system/text/asciiencoding.cs 2015-02-23 11:29:42 +01:00
Marek Safar d2978f3833 Merge pull request #1580 from akoeplinger/msbuild-3B-escape
[Microsoft.Build.Engine] Fix bug with escaped semicolon and spaces
2015-02-23 10:42:27 +01:00
Marek Safar 8408ce4b5d Merge pull request #1585 from akoeplinger/msbuild-makerelative
[Microsoft.Build.Engine] Implement MakeRelative() predefined property function
2015-02-23 07:36:11 +01:00
Vladimir Kargov e3cfac464b [runtime] Prioritize loading a profiler library from the installation dir over standard libarary paths. 2015-02-23 07:02:20 +03:00
Ludovic Henry 6e9c5ab5b3 [Linq] Replace implementation by Microsoft reference sources 2015-02-22 23:00:42 -05:00
Alexander Köplinger f3f1799700 Ensure MakeRelative() works even when basePath doesn't end in slash 2015-02-22 20:41:29 +01:00
Alexander Köplinger 0a8592dc5b [Microsoft.Build.Engine] Implement MakeRelative() predefined property function 2015-02-22 20:09:31 +01:00
Zoltan Varga 674a2849b4 [aot] Fix thumb support when using separate llvm modules. 2015-02-22 00:31:41 -05:00
Zoltan Varga d8b896bb7c [runtime] Add a --disable-visibility-hidden flag to disable the usage of -fvisibility=hidden for now. 2015-02-21 18:41:00 -05:00
Zoltan Varga 4249eba7f2 [runtime] Export a few more symbols. 2015-02-21 18:32:10 -05:00
Marek Safar 321bb7200c Merge pull request #1573 from akoeplinger/msbuild-import-empty
[Microsoft.Build.Engine] Ignore import with empty project attribute when condition is false
2015-02-21 13:22:01 +01:00
João Matos b92e728081 Merge pull request #1583 from akoeplinger/fix-genproj-line-endings
[genproj] Fix line endings in generated file to be CRLF
2015-02-20 20:14:15 +00:00
Atsushi Eno 684f9b08a5 Merge branch 'master' of github.com:mono/mono
(some commits occurred while I have been cherry-picking a lot of "they are
in import-system-xml branch but it works with existing sys.xml" stuff.)
work in master
2015-02-21 03:35:57 +08:00
Atsushi Eno 545cdaf8f7 [WCF] XmlWriter.WriteAttributeString(string,string) does not accept xml:*.
It needs LocalName. So use other overloads instead.
2015-02-21 03:33:23 +08:00
Atsushi Eno 6499ba871d [XLinq] create new instance of XmlSchemaInfo for each XObject from XmlReader.
In referencesource, XmlReader.SchemaInfo does not return different instances
for each node at its state but just returns the XmlReader itself (which
implements IXmlSchemaInfo). Hence, if we just set the corresponding
IXmlScemaInfo to each XObject, it results in inconsistent state.

This fixes two regressions in ExtensionsTest (XAttributeFailValidate and
XAttributeThrowExceptionValidate).
2015-02-21 03:32:44 +08:00
Atsushi Eno 923ed6b241 [Sys.Security] don't expect XmlNode.ChildNodes returns the same instance.
It did in mono implementation. It doesn't on referencesource.
2015-02-21 03:31:39 +08:00
Atsushi Eno d9184320f7 [Configuration] skip whitespaces in the settings xml.
This is required after we switch to referencesource, which somehow
preserves whitespaces during deserialization from xml.
2015-02-21 03:29:21 +08:00
Atsushi Eno 2951e3b6d8 [Xaml] XamlXmlWriter should flush output when disposing.
With referencesource, XmlWriter for TextWriter buffers the output.
When closing XamlXmlWriter, it does not flush the output, causing
the buffered XmlWriter output discarded in the wild.
2015-02-21 03:28:44 +08:00
Atsushi Eno 3001bd0d94 [WCF] for certain kind of Messages, do now write BodyContents twice. 2015-02-21 03:28:07 +08:00
Atsushi Eno a1d5c9c48d [Sys.Xml] when deserializing XmlNode, use XmlReader's NameTable. 2015-02-21 03:26:10 +08:00
Atsushi Eno abb3e7dcfc [WCF] fix wrong using scope on XmlWriter in security token serializer test. 2015-02-21 03:25:29 +08:00
Atsushi Eno cdb4002190 [WCF] do not use XmlReader.Name to check LocalName.
It won't match for prefixed ones.
2015-02-21 03:24:54 +08:00
Atsushi Eno 358275e836 [WCF] Do not expect XmlElement.FirstChild is non-whitespace here.
Fix several regressions caused by referencesource Sys.Xml import.
2015-02-21 03:24:12 +08:00
Atsushi Eno a0dece2329 [S.R.Serialization] fix referencesource glitch in XmlMtomDictionaryWriter.
MTOM writer didn't expect multiple top-level elements are rejected at
ConformanceLevel.Auto, neiher do against Write[Start/End]Document() with
such elements.

Also Flush is often needed before directly writing to the Stream(Writer).

EOLs handling was also inconsistent between referencesource and old mono.
2015-02-21 03:23:15 +08:00
Atsushi Eno a3383d1be5 [S.R.Serialization] add missing attributes in MS serialization namespace.
This fixes another regression which failed to load Test ns22.xsd.
2015-02-21 03:22:08 +08:00
Atsushi Eno 74e70ff985 [Sys.Xml] don't use XmlSchemaElement.ElementType anymore. MS doesn't use it.
XML Schema compilation is done in referencesource.
XmlSchemaImporter is based on mono code. Hence this glitch happened.

The following regression is fixed:

1) MonoTests.System.Xml.Serialization.XmlSchemaImporterTests.DefaultTypeTopLevelElementImportsAllComplexTypes : System.InvalidOperationException : 'Root' is missing.
at System.Xml.Serialization.XmlSchemaImporter.ImportTypeMapping (System.Xml.XmlQualifiedName name) [0x0005a] in /svn/mono/mcs/class/System.XML/System.Xml.Serialization/XmlSchemaImporter.cs:453
at MonoTests.System.Xml.Serialization.XmlSchemaImporterTests.DefaultTypeTopLevelElementImportsAllComplexTypes () [0x00039] in /svn/mono/mcs/class/System.XML/Test/System.Xml.Serialization/XmlSchemaImporterTests.cs:1104
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /svn/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230
2015-02-21 03:19:06 +08:00
Atsushi Eno d41451bcbf Our XmlDictionaryWriter implementation expects XmlReader at non-Initial state.
It is to fix glitch between mono Sys.Xml and referencesource.
2015-02-21 03:16:58 +08:00
Atsushi Eno c56064b05c [Sys.Data] DataSet.ReadXmlSchema(): use LocalName instead of Name on XmlReader.
MS referencesource Sys.Xml uncovered this bug.
2015-02-21 03:16:15 +08:00
zevane 4751c10f9c Limit the lock to the writing operation
I initially discarded this change, because locking BaseSet (name, sec), didn't prevent the threads from trying to add the same key. That said, following the code, the point at which it actually fails is in NameObjectCollectionBase.BaseAdd, lines 331 and 332. The threads were arriving the second line at the same time:

   if (_entriesTable[name] == null)
          _entriesTable.Add(name, entry);

In brief, it's safe to call BaseSet twice with the same key, so it's safe to lock only the call to BaseSet
2015-02-20 20:04:01 +01:00
Zoltan Varga 2202e97c33 [aot] Fix the emission of llvm plt entries. 2015-02-20 14:00:17 -05:00
Marek Safar cfbb82b747 [corlib] Fixes build with old UnmanagedMemoryStream 2015-02-20 18:46:31 +01:00
Atsushi Eno 49d79191ca Add missing new I18N DefaultEncoder class. 2015-02-21 00:52:26 +08:00
Atsushi Eno 3f355da212 Add old mono Encoder and use it in MonoEncoding to keep compatibility.
There was some glitch in CP932 encoding and referencesource Encoder
that caused error in Convert(), shown in System.XML tests.
To avoid this, bring back old Encoder as we used before and keep
compatible processing.

It might be buggier, but doesn't regress. We may be able to bring nlp-
based Encodings later too.
2015-02-21 00:52:20 +08:00
Zoltan Varga 392200a812 [runtime] Export the GC bridge api functions. 2015-02-20 11:51:19 -05:00
Miguel de Icaza 0e8701a161 Merge pull request #1582 from zevane/patch-1
Make the class thread-safe
2015-02-20 11:23:50 -05:00
Marek Safar 6800659e8c [corlib] Remove ResourceCloseHandler usage 2015-02-20 17:07:15 +01:00
Marek Safar 01db1cc9ad [corlib] Add more internal apis 2015-02-20 15:09:14 +01:00
Marek Safar ed2510cc14 [build] Handle multiple entries in RESOURCE_STRINGS 2015-02-20 13:34:18 +01:00
Marek Safar 7a57bd6b3d Bump reference sources to revert Add read-only interfaces to some collections 2015-02-20 11:25:23 +01:00
Marek Safar 8e90a963d6 Use more resource text strings from reference sources 2015-02-20 11:16:18 +01:00
Marek Safar 71533001b8 [System.Runtime.Serialization] Makefile cleanup 2015-02-20 09:57:30 +01:00
Marek Safar f364eca194 [System.Numerics] Cleanup Makefile 2015-02-20 09:52:44 +01:00
Marek Safar b1941bc08a [System.ComponentModel.DataAnnotations] Makefile clean-up 2015-02-20 09:44:37 +01:00
zevane b3ddd74efb Make the class thread-safe
If two threads request the same section, which isn't yet cached, both try to insert it into the cache, causing a "Key duplication when adding...". It's neccesary to lock the getter. This solves bugs #5263, #7785, #18303
2015-02-20 09:12:47 +01:00
Marek Safar 754793df9e [corlib] Switch to official mscorlib.txt 2015-02-20 08:49:17 +01:00
Miguel de Icaza 414d11f976 Bring referencesource messages that were just published by Microsoft 2015-02-19 21:02:49 -05:00
Zoltan Varga 285f867593 [aot] Fix the emission of dwarf debug info. 2015-02-19 20:24:38 -05:00
Zoltan Varga 5fc41fcb56 [aot] Emit dwarf emission on arm64. 2015-02-19 20:02:39 -05:00
Zoltan Varga af3c010407 [llvm] Fix a bug introduced by 61ae03fef1. 2015-02-19 18:53:37 -05:00
Zoltan Varga c3611d4d3b [llvm] Mark methods with the NOINLINING attribute as non-inlinable. 2015-02-19 17:17:20 -05:00
Zoltan Varga 61ae03fef1 [llvm] Refactor the calling convention handling code a bit, add support for returning fp structures by value. 2015-02-19 17:04:07 -05:00
Ludovic Henry 986e58d530 [tpl] Increase wait timing in test suite to adapt to the slower ramp up of the ThreadPool 2015-02-19 15:49:19 -05:00
Zoltan Varga 127602a843 [aot] Enable LLVM level inlining. 2015-02-19 14:34:33 -05:00
Marek Safar fbe7c55a56 [system.web] Tests update 2015-02-19 20:12:52 +01:00
Marek Safar 6e488234ae [WindowsBase] Implement Vector formattable ToString 2015-02-19 20:12:52 +01:00
Marek Safar ea43322c29 [corlib] BufferedStream from reference sources 2015-02-19 20:12:51 +01:00
Zoltan Varga 689a615a71 [llvm] Mark methods with clauses as noinline. 2015-02-19 14:06:20 -05:00
Zoltan Varga e869cc56a5 [jit] Fix the overflow checks in the liveness2 pass since the liveness ranges are stored as signed ints. 2015-02-19 14:05:51 -05:00
Zoltan Varga ae9d99d2d3 [aot] Fix catching exceptions in gshared methods on amd64. 2015-02-19 13:26:23 -05:00
Alexander Köplinger 042a9afd50 [genproj] Fix line endings in generated file to be CRLF
The template uses CRLF everywhere, so we should generate the same to avoid mixed line endings.
2015-02-19 19:23:23 +01:00
Zoltan Varga eb7ed887ac [llvm] Mark the mono_aot_personality () function as used, to prevent llvm from optimizing it away. 2015-02-19 12:10:02 -05:00
Zoltan Varga 08b8f74db5 [runtime] Export a few functions needed by xam.mac. 2015-02-19 11:41:11 -05:00
Jo Shields 2750f4970d Add ReferenceSources/mscorlib.txt to EXTRA_DIST (fixes distcheck) 2015-02-19 16:11:28 +00:00
Marek Safar 65347a166e [corlib] Text streams from reference sources 2015-02-19 17:04:14 +01:00
Marek Safar ce4e2497be [corlib] Use public TextWriter.Synchronized for Console synchronization and leave stream closing handling to underlying stream 2015-02-19 16:42:57 +01:00
Marek Safar 1425ace040 [corlib] Stream, MemoryStream from reference sources 2015-02-19 13:04:46 +01:00
Marek Safar 8da38a9e4a [corlib] Access null stream using public property 2015-02-19 13:04:46 +01:00
Marek Safar ffc36ef3bd [corlib] Rename IsDirectorySeparator method to match reference sources 2015-02-19 13:04:46 +01:00
Alex Rønne Petersen 9af7d9083a Stop building with -Wdeclaration-after-statement since we're C99 now. 2015-02-19 11:04:59 +01:00
Zoltan Varga f8c5acaf45 [aot] Fix an assertion. 2015-02-18 20:35:47 -05:00
Zoltan Varga 2c1b64477b [llvm] Emit null checks for remainders as well. 2015-02-18 19:15:12 -05:00
Zoltan Varga 5e0b127e15 [llvm] Emit null checks in div opcodes if needed. 2015-02-18 19:04:51 -05:00
Zoltan Varga a0c1fb5a1a [aot] Fix binary search in the code offsets table when emitting llvm code separately. 2015-02-18 19:04:08 -05:00
Zoltan Varga 98316e0be1 [aot] Fix the computation of LLVM code ranges. 2015-02-18 18:24:49 -05:00
Alexander Köplinger 51297ed7ab [Microsoft.Build.Engine] Fix bug with escaped semicolon and spaces 2015-02-19 00:19:31 +01:00
Jo Shields 2d6092f45e Ensure check-seq-point target exits immediately on failure. 2015-02-18 23:14:19 +00:00
Zoltan Varga 2c69ccd9f0 [jit] Disable llvm support for the atomic load/store opcodes for now to fix corlib test failures. 2015-02-18 17:31:02 -05:00
Zoltan Varga 77f4176af0 [aot] Handle separate blocks of llvm and jitted code correctly. 2015-02-18 17:10:57 -05:00
Alexander Köplinger 2850b1274c [Microsoft.Build.Tasks] Added tests for escaped semicolon and space 2015-02-18 22:41:48 +01:00
Mark Probst fee8ae7ef6 [sgen] Correctly calculate size of zero-based one-dimensional non-vector arrays. 2015-02-18 12:43:31 -08:00
Marek Safar a803d17038 [mcs] Make compiler output deterministic. Fixes #26842 2015-02-18 20:02:31 +01:00
Zoltan Varga 28a2664d4a Merge pull request #1576 from McSherry/patch-1
revises GZipStream ctor parameter names
2015-02-18 13:41:08 -05:00
Zoltan Varga 04ba85af27 [runtime] Really fix the loadable LLVM build. 2015-02-18 13:39:08 -05:00
Liam McSherry dd939ec86a revises GZipStream ctor parameter names
By changing the names of the parameters, code that uses .NET GZipStream constructors[1][2] with named parameters can use this GZipStream without change.

[1]: https://msdn.microsoft.com/en-us/library/as1ff51s(v=vs.110).aspx
[2]: https://msdn.microsoft.com/en-us/library/27ck2z1y(v=vs.110).aspx
2015-02-18 18:32:43 +00:00
Jo Shields 9f5a7ae769 Just avoid BSD sed altogether. 2015-02-18 18:29:01 +00:00
Jo Shields 85f78490d2 More fixes for BSD sed breaking check-seq-point target 2015-02-18 17:42:15 +00:00
Jo Shields dad995933c Further fixes to check-seq-point test 2015-02-18 17:17:21 +00:00
Jo Shields afc70b2b7e Fix test suite on OSX 2015-02-18 16:54:54 +00:00
Zoltan Varga 5e4ee3ccea [runtime] Fix the loadable LLVM build. 2015-02-18 11:43:32 -05:00
Marek Safar 038b3b6cea Bump ikdasm to fix crashes on mobile mscorlib 2015-02-18 17:05:16 +01:00
João Matos 08ea547ec4 Merge pull request #1575 from mono/revert-1574-patch-1
Revert "revises GZipStream ctor parameter names"
2015-02-18 16:00:06 +00:00
João Matos f0a399e640 Revert "revises GZipStream ctor parameter names" 2015-02-18 15:59:39 +00:00
João Matos fb9ae0f835 Merge pull request #1574 from McSherry/patch-1
revises GZipStream ctor parameter names
2015-02-18 15:59:16 +00:00
Liam McSherry 1f07b1320c revises GZipStream ctor parameter names
By changing the names of the parameters, code that uses .NET GZipStream constructors[1][2] with named parameters can use this GZipStream without change.

[1]: https://msdn.microsoft.com/en-us/library/as1ff51s(v=vs.110).aspx
[2]: https://msdn.microsoft.com/en-us/library/27ck2z1y(v=vs.110).aspx
2015-02-18 15:55:01 +00:00
João Matos 8e87cce42c [profiler] Fixed an Android build regression introduced by 2b74940f64. 2015-02-18 15:29:57 +00:00
Zoltan Varga bfafeddc2b [runtime] Use -fvisibility=hidden so only symbols marked with MONO_API are exported. Use a separate SHARED_CFLAGS variable so it only affects a subset of libs. 2015-02-18 08:12:32 -05:00
Zoltan Varga 0927b86347 Revert "[runtime] Use -fvisibility=hidden so only symbols marked with MONO_API are exported."
This reverts commit 8a5a230aec.

Revert this as it still causes test failures.
2015-02-18 08:11:22 -05:00
João Matos 7e9504a10d [monodis] Fixed building against LLVM-compiled Mono. 2015-02-18 12:49:01 +00:00
João Matos b50b381226 Merge pull request #1572 from directhex/emit-nunit-xml-in-unmanaged-tests
Emit NUnit representation of check-seq-points target.
2015-02-18 12:26:09 +00:00
Jo Shields a34e257fd2 Emit NUnit representation of check-seq-points target.
This generates an XML representation of the check-seq-points target,
as separate tests, which can be easily tracked by anything which
parses NUnit output (e.g. Jenkins or other CI systems). For example,
we are currently regressed on this on ARM.
2015-02-18 12:10:39 +00:00
Marek Safar da706a2058 [corlib] Removes extra bufffer from FileStream async mode writes. Fixes #27086 2015-02-18 12:56:36 +01:00
Alexander Köplinger e70880d895 [Microsoft.Build.Tasks] Fix bug in test method
The if check was inverted, so the actual test code didn't run.
2015-02-18 09:44:32 +01:00
Martin Baulig a20a0459be Merge pull request #1464 from akoeplinger/fix-portable-target
[xbuild] Only execute PCL target "ImplicitlyExpandTargetFramework" when corresponding property is true
2015-02-18 08:12:08 +01:00
Alexander Köplinger bf3d9609ba [Microsoft.Build.Engine] Ignore import with empty project attribute when condition is false
<Import Project="$(Variable)" Condition="false" /> causes an exception otherwise when Variable is not set.
Also added a test for condition referencing extension path after discussion in https://github.com/akoeplinger/mono/commit/f13d9cb5dacbb5c9f758d6dd8b9aacf46b5508b6
2015-02-18 07:38:41 +01:00
Miguel de Icaza aeb24275bc Merge pull request #1563 from directhex/emit-nunit-xml-in-unmanaged-tests
Generate NUnit interpretation of whether "mono --regressions" passed
2015-02-17 23:27:58 -05:00
Zoltan Varga 8a5a230aec [runtime] Use -fvisibility=hidden so only symbols marked with MONO_API are exported. 2015-02-17 19:05:03 -05:00
Zoltan Varga 2b74940f64 [runtime] Link the logging profiler against eglib. 2015-02-17 19:03:39 -05:00
Zoltan Varga 065f41d168 [runtime] Export mono_threads_attach_tools_thread (). 2015-02-17 19:03:39 -05:00
Marek Safar 4d91c8e7d2 [build] Remove misused bootstrap profile definition 2015-02-17 21:58:23 +01:00
Marek Safar 451e14e4c8 [corlib] Remove duplicate source files 2015-02-17 21:43:23 +01:00
Marek Safar c495250fde [corlib] Replace resource keys with actual messages during compilation 2015-02-17 21:43:22 +01:00
Rodrigo Kumpera 04eeb70c8c Merge pull request #1570 from mono/fix27010
Bug 27010 - Difference in Assembly.GetExportedTypes with .NET
2015-02-17 13:49:05 -06:00
Alex Rønne Petersen 8bf480fc62 Merge pull request #1571 from evincarofautumn/fix-warning
[utils] Fix warning in Makefile.am.
2015-02-17 19:58:14 +01:00
Jon Purdy f14d23b7f0 [utils] Fix warning in Makefile.am. 2015-02-17 10:56:15 -08:00
João Matos b8dec77eea [mini] Improve the driver to handle more cases of incompatible cross-compilation targets. 2015-02-17 16:12:49 +00:00
João Matos ac8ae330c7 [metadata] Do not try to use host context members when cross-compiling. 2015-02-17 16:12:11 +00:00
João Matos 85e5ebbfa9 [metadata] Add missing ARM64 object offsets.
This fixes the mobile products build with Mono master.
2015-02-17 16:11:21 +00:00
Zoltan Varga 0ba6d1777d [aot] Fix the emission of ElementAddr wrappers. 2015-02-17 07:46:11 -05:00
Zoltan Varga 4c8a1a6733 [runtime] Link monodis against libmonoruntime instead of libmono which can be a dynamic lib. 2015-02-17 06:59:29 -05:00
Zoltan Varga ff2cfae862 [gsharedvt] Implement support for multi-dimensional arrays in gsharedvt methods. 2015-02-17 06:57:43 -05:00
Zoltan Varga acbe5f52d5 Fix a warning. 2015-02-17 05:44:58 -05:00
Marek Safar 673e8fa8ee [mcs] Single name meaning relaxation to match roslyn 2015-02-17 10:59:33 +01:00
Alex Rønne Petersen 33ad107825 Update refsrc to get read-only interface changes for System/System.Core. 2015-02-17 10:53:10 +01:00
Marek Safar 877e8ce941 [mcs] Fixes check for overriden auto-properties. 2015-02-17 08:14:21 +01:00
Ungureanu Marius 818d229538 Bug 27010 - Difference in Assembly.GetExportedTypes with .NET 2015-02-17 06:41:12 +02:00
Alex Rønne Petersen 235f543d94 [mini] Fix a crash on armel. 2015-02-17 02:04:15 +01:00
Zoltan Varga 6ee1b1b565 [jit] Add tests for arm64 gsharedvt argument passing. 2015-02-16 16:07:03 -05:00
Zoltan Varga 175c1a521d [jit] Add tests for arm64 gsharedvt argument passing. 2015-02-16 15:20:17 -05:00
Alexander Köplinger 8f7a551c0c [Microsoft.Build.Tasks] Rethrow exception in Copy task
This way we don't lose the original stacktrace.
2015-02-16 19:05:00 +01:00
Marek Safar 724c1becc1 Add new test 2015-02-16 17:03:50 +01:00
Marek Safar ed517ad778 [mcs] Implements dictionary initializers on pointer types 2015-02-16 16:48:24 +01:00
Miguel de Icaza aef0b3e04c Merge pull request #1542 from ninjarobot/UriTemplateMatchException
Fix to UriTemplate.Match to properly handle query parameters without a v...
2015-02-16 10:19:44 -05:00
Miguel de Icaza 5715cdc582 [System.ServiceModel] Prevent server crash when client disconnect
This patch is an updated version of a pull request (377) from Rob
Wilkens to fix #5926
2015-02-16 10:01:22 -05:00
João Matos bccf5cf121 [aot] Re-organize JSON dumping code. 2015-02-16 12:48:05 +00:00
João Matos d9234357f6 Revert "[aot] Re-organize JSON dumping code."
This reverts commit 25969466b5.
2015-02-16 12:46:29 +00:00
João Matos b4926395c6 [git] Ignore Doxygen-related generated files. 2015-02-16 12:39:03 +00:00
Zoltan Varga 25969466b5 [aot] Re-organize JSON dumping code. 2015-02-16 12:38:40 +00:00
Marek Safar bc57fda921 Merge pull request #1568 from akoeplinger/xbuild
[Microsoft.Build.Tasks] Implement retries in Copy task and add a stub.
2015-02-16 07:54:54 +01:00
Atsushi Eno 90b1124402 Merge branch 'import-text-encoding-2' 2015-02-16 14:34:19 +08:00
Alexander Köplinger 40c0dfcf93 [Microsoft.Build.Tasks] Add stub for UseHardlinksIfPossible to Copy task
Creating hardlinks in .NET doesn't have a nice API and using Mono.Unix/Pinvoke doesn't
seem worth the effort at this point since the feature is off by default on msbuild as well.
2015-02-16 01:50:07 +01:00
Alexander Köplinger baaf07c104 [Microsoft.Build.Tasks] Implement retries in Copy task 2015-02-16 01:38:06 +01:00
Atsushi Eno e4b2bc75aa [sys.xaml] serialize string value as string, do not try ValueConverter.
Fixed some xwt object serialization.
2015-02-16 03:32:49 +08:00
Zoltan Varga bcd70a77a7 [jit] Fix a regression introduced by 00a28a7dfd which disabled liveness2 for most methods. 2015-02-14 15:51:11 -05:00
Zoltan Varga bca66a090d [arm64] Add a test for vtype by ref returns in dyn calls. 2015-02-13 17:54:31 -05:00
João Matos 874d17321d [runtime] Fixed TLS detection on AMD64 to support cross-compilation. 2015-02-13 16:45:46 +00:00
Marek Safar 52c33f00ff [mcs] Better error reporting after delegate probing failed. Fixs #27043 2015-02-13 17:42:41 +01:00
João Matos e3279063de [aot] Added JSON dumping support.
This is enabled by passing "aot=dump" to the Mono AOT driver and will create a JSON file in the working directory with the name of the assembly.

It's still a work-in-progress and will see improvements in the data dumped as it's needed.
2015-02-13 16:41:07 +00:00
Marek Safar b9c8a612b7 [mcs] Set fixed buffer layourt wihout StructLayoutAttribute when possible. Fixes #27020 2015-02-13 16:49:22 +01:00
Marek Safar 8d3c6d44f8 [corlib] Random from reference sources 2015-02-13 15:05:43 +01:00
Marek Safar da9546edfd [corlib] MissingMember exceptions from reference sources 2015-02-13 14:58:40 +01:00
Marek Safar 09b16951bc [corlib] UnitySerialization from reference sources 2015-02-13 14:45:46 +01:00
Marek Safar 8157ba59ce [system.net.http] Parsing of nested parens inside comment. Fixes #27036 2015-02-13 14:37:32 +01:00
Marek Safar 1128af49cf [mcs] Resolve using aliases on demand to fix issue with nested types. Fixes #27001 2015-02-13 14:37:31 +01:00
João Matos 08014c4629 [monodis] Attempt to fix the Cygwin build.
CCLD     monodis.exe
../../mono/metadata/.libs/libmonoruntimesgen-static.a(libmonoruntimesgen_static_la-opcodes.o): In function `mono_opcode_name':
/cygdrive/c/projects/mono-817/mono/metadata/opcodes.c:63: multiple definition of `mono_opcode_name'
../mini/.libs/libmonosgen-2.0.dll.a(d001720.o):(.text+0x0): first defined here
collect2: error: ld returned 1 exit status
2015-02-13 12:43:06 +00:00
Atsushi Eno f47937f8f3 avoid reflection in EncodingHelper.
as per https://github.com/mono/mono/pull/1566#discussion_r24653304
2015-02-13 18:25:49 +08:00
Atsushi Eno 59dc2b42c8 [encoding] import referencesource encoding foundation types.
This change does not involve Windows-specific NLS-based encodings.
We will be still using I18N assemblies until we make more grand design
changes (Xamarin products premise those assemblies).

This also fixes bug #23771 and probably more.
2015-02-13 16:41:05 +08:00
Zoltan Varga 2a3385da86 Fix a warning. 2015-02-13 02:16:16 -05:00
Alex Rønne Petersen 61e8b5e6d0 [mini] Add a MONO_ARM_FORCE_SOFT_FLOAT environment variable. 2015-02-13 08:08:44 +01:00
Zoltan Varga 8a3b8e716f [runtime] Overwrite logging profiler output files automatically. 2015-02-13 00:39:48 -05:00
Zoltan Varga f16a4a1975 [runtime] Export mono_personality (), which is accessed from llvm compiled code. 2015-02-13 00:29:24 -05:00
Zoltan Varga b45199d288 [corlib] Fix a race in LazyTest.EnsureSingleThreadSafeExecution (). 2015-02-13 00:15:52 -05:00
Zoltan Varga 82554c4e89 [runtime] Add a SHARED_CFLAGS autoconf var which can be used to pass the -fvisibility=hidden flag. 2015-02-13 00:10:51 -05:00
Rodrigo Kumpera 19a22ede0d Merge pull request #1439 from BrzVlad/feature-managed-allocator
[jit] Optimize the managed allocator fastpath for small objects
2015-02-12 17:43:52 -06:00
Atsushi Eno 93ce056a76 Merge pull request #1496 from echampet/serializers
System.Xml.Serialization: fix xml serializers generation for Web Services
2015-02-13 05:08:10 +08:00
Atsushi Eno 33694c02b3 [encoding] as part of referencesource import, use new EncodingHelper class.
This will remain after importing referencesource and offer mono-only
internals for some classes. This involves icall (owner class) change.
2015-02-13 04:24:47 +08:00
Marek Safar 2ca5117fd2 [system] Mark ping MT implementation as broken 2015-02-12 19:09:08 +01:00
João Matos ccf89b6b5b [runtime] Fixed TLS detection on x86 to support cross-compilation. Fixes #26969.
https://bugzilla.xamarin.com/show_bug.cgi?id=26969.
2015-02-12 17:40:13 +00:00
Zoltan Varga 83ae5b92ac [runtime] Fix an automake warning. 2015-02-12 12:29:37 -05:00
Zoltan Varga 679f9b44a5 [runtime] Fix an initialization race when using custom marshallers. 2015-02-12 12:13:54 -05:00
João Matos 98a88d8009 Merge pull request #1534 from haf/bugs/hmac-wrong-keysizes
Bugs/hmac wrong keysizes
2015-02-12 16:46:00 +00:00
Marek Safar 72eb18f84d [system] More linker friendly tests 2015-02-12 17:00:34 +01:00
Jo Shields 12baa6e696 Generate NUnit interpretation of whether "mono --regressions" passed 2015-02-12 15:22:17 +00:00
Zoltan Varga d7ae2816fe Merge pull request #1562 from vkargov/master
[runtime] Mark TLS variables as explicitly used
2015-02-12 10:03:40 -05:00
Vladimir Kargov 16ee025230 [runtime]
Mark TLS variables as explicitly used to avoid their unwarranted deletion
by the compiler overlooking their usage in inline assembly sections.
2015-02-12 17:45:34 +03:00
João Matos 90185288b1 [aot] Fixed LLVM assembly generation for non-Mach targets.
Fixes bugzilla #26964.
2015-02-12 13:42:46 +00:00
Marek Safar 45448a3f16 [corlib] Add timeout to more tests 2015-02-12 14:21:24 +01:00
Zoltan Varga 9eea9b6d70 [aot] Fix emission of symbol sizes which got broken by 05cd4225b2. 2015-02-12 07:49:08 -05:00
Marek Safar 3af8147e4d [system] Add old monotouch test codepath 2015-02-12 13:24:16 +01:00
Marek Safar 3d3c8b9bc6 [system.core] Fix wrong 405f9534df 2015-02-12 13:20:10 +01:00
Zoltan Varga 0871f1f266 Revert "[runtime] Use -fvisibility=hidden so only symbols marked with MONO_API are exported."
This reverts commit 90e86725ac.

Revert this as it causes many test failures.
2015-02-12 06:47:09 -05:00
Zoltan Varga b64c24b4ea [runtime] Export mono_gc_toggleref_add (). 2015-02-12 06:45:45 -05:00
Zoltan Varga 90e86725ac [runtime] Use -fvisibility=hidden so only symbols marked with MONO_API are exported. 2015-02-12 05:22:52 -05:00
Zoltan Varga 17eadbf010 [runtime] Define MONO_API_EXPORT properly for gcc, and define MONO_DLL_EXPORT so it is actually used during the build. 2015-02-12 05:21:50 -05:00
Zoltan Varga 029753034f Revert "[runtime] Use -fvisibility=hidden so only symbols marked with MONO_API are exported."
This reverts commit beb1463b6c.

Revert this for now as it breaks loading symbols from the mono executable on osx.
2015-02-12 04:51:06 -05:00
Marek Safar 52227a1e6d [runtime] Return strongly typed array from GetModules to match managed signature. Fixes a crash with strongly typed enumerator 2015-02-12 10:09:06 +01:00
Marcos Henrich b3aec8113a [corlib] Fixes commit ceef1e2.
We want to remove the module check from GetMethodToken not SetUserEntryPoint.
2015-02-12 08:59:21 +00:00
Zoltan Varga 4ef4090a22 [runtime] Export symbols from libtest. 2015-02-12 03:53:26 -05:00
Zoltan Varga 250cd40b86 [runtime] Remove unused MONO_ARCH_SAVE_REGS declarations. 2015-02-12 03:46:49 -05:00
Zoltan Varga b34c3f6f64 [jit] Remove unused MONO_ARCH_SAVE_REGS declarations. 2015-02-12 03:32:58 -05:00
Zoltan Varga d9259e59e1 [monodis] Build monodis against the static mono libraries. 2015-02-12 03:04:39 -05:00
Zoltan Varga beb1463b6c [runtime] Use -fvisibility=hidden so only symbols marked with MONO_API are exported. 2015-02-12 02:25:19 -05:00
Sebastien Pouliot cfc0d6fc73 [linker] Do not update the Scope on TypeSpecification (fix mmp regression tests) 2015-02-11 15:38:48 -05:00
Zoltan Varga 6f572dcc58 Merge pull request #1561 from main--/patch-1
Only call string.Format in Debug.Assert if really necessary
2015-02-11 13:49:53 -05:00
main() 2e6efb3149 Only call string.Format in Debug.Assert if really necessary
Right now (without this change), Debug.Assert **always** formats its string parameters, even if doing so wouldn't be necessary because the condition is true. This has a huge impact on code that asserts frequently because it assumes that calling Assert(true, ...) is cheap.
2015-02-11 19:42:29 +01:00
Marek Safar ceef1e2379 Merge pull request #1560 from esdrubal/xlstregression
[corlib] ModuleBuilder.GetMethodToken no longer has a module check.
2015-02-11 17:17:27 +01:00
Marcos Henrich 9eb81476bd [corlib] ModuleBuilder.GetMethodToken no longer has a module check.
.NET implementation is able to get method tokens from other modules.
This was causing a regression on a System.Xml.Xsl.XslTransformTests.Bug487065 while using referencesource's System.Xml implementation.
2015-02-11 15:59:37 +00:00
Marcos Henrich 1e7a4a2114 [corlib] Test GetMethodToken ability to get other modules' tokens.
.NET implementation is able to get method tokens from other modules.
2015-02-11 15:59:36 +00:00
João Matos f1006fbbe0 [msvc] Upgrade the projects to require VS2013. 2015-02-11 15:55:43 +00:00
Alex Rønne Petersen 628f3d998b Use -std=gnu99 as we rely on the linux macro in some places. 2015-02-11 16:50:59 +01:00
Marek Safar 2326fa0721 Bump reference sources 2015-02-11 16:42:40 +01:00
Zoltan Varga 46357aee0b [runtime] Enable C99 mode. 2015-02-11 10:32:34 -05:00
Zoltan Varga 984a13d908 [runtime] Use ISO C __typeof__ instead of typeof () in one place. 2015-02-11 10:32:13 -05:00
Zoltan Varga 3b85df9c0d Fix the loadable llvm build. 2015-02-11 09:44:45 -05:00
Sebastien Pouliot b6d6280821 [linker] Ignore null type arguments in MarkWithResolvedScope
It's ignored in MarkType but it breaks calling Resolve in this case
2015-02-11 09:01:35 -05:00
Marek Safar 8db46e61fd [corlib] Fixes build 2015-02-11 14:04:35 +01:00
Zoltan Varga a42f4d8d22 Merge pull request #1559 from directhex/emit-nunit-xml-in-unmanaged-tests
Add NUnit XML emission to the managed runtime test runner.
2015-02-11 08:00:18 -05:00
Jo Shields 84a8428de1 Add NUnit XML emission to the managed runtime test runner.
This makes it easy to plug failures from the runtime tests into a visualisation, such as Jenkins' jUnit display system.
2015-02-11 12:48:45 +00:00
Zoltan Varga 078968540f Make the managed test runner the default in mono/tests, run with make M=0 to use the old one. 2015-02-11 07:47:39 -05:00
Zoltan Varga 9b617125bd [llvm] Maps structs made up of floats/doubles to llvm structs containing floats. 2015-02-11 07:02:45 -05:00
Marek Safar 4e27a21367 [system] Fix ping process exit code check 2015-02-11 12:04:50 +01:00
Marek Safar f97001e2c8 [system] updates fixed test 2015-02-11 10:47:54 +01:00
Marek Safar 405f9534df [system.core] Update aes test to match imported code 2015-02-11 09:43:17 +01:00
Marek Safar ec2e126dfd [mcs] Additional fix for #26892 2015-02-11 09:21:20 +01:00
Sebastien Pouliot d07822286c [linker] Resolve types inside custom attributes since they might refer to types in assemblies we won't be keeping [#26752]
Custom attributes encoding means it's possible to have a scope that will
point into a PCL facade even if we (just before saving) will resolve all
type references.

Since all other references can be made on the _real_ assembly and that
we do not want to include any facade assembly just for this we need to
resolve those type and update their scope.
2015-02-10 21:04:02 -05:00
João Matos 325744cb85 [build] Fixed the MSVC build. 2015-02-10 15:14:16 +00:00
Marek Safar 9b9b96980b [corlib] Guid from reference sources 2015-02-10 15:42:13 +01:00
Marek Safar 86e2bada8a [mcs] Fixes failing test 2015-02-10 15:42:13 +01:00
Marcos Henrich b94c4cdce1 [corlib] Calling 'tzi.exe -i' now prints olson transitions. 2015-02-10 10:44:35 +00:00
Marcos Henrich 7169eeb5e0 [corlib] Updated make target tzi.exe 2015-02-10 10:39:29 +00:00
Marcos Henrich 8473c6db7e Moved android-dump-tzdata make target to corlib.
Reason: All TimeZoneInfo related files are now all in corlib directory.
2015-02-10 10:32:30 +00:00
Zoltan Varga 2f95909242 Merge pull request #1557 from StephenMcConnel/bug-26887
Prevent right click from triggering ToolStripItem.HandleClick
2015-02-10 04:25:34 -05:00
Marek Safar 158487fe94 Rename binary reference assemblies location 2015-02-10 10:21:29 +01:00
Marek Safar 85ee5582f6 [eval] Add C#6 using handling 2015-02-10 10:12:43 +01:00
Zoltan Varga e26e45cf2f Merge pull request #1558 from ermshiperete/fixCrash
[MWF] Fix NullReferenceException introduced by commit a080a7d
2015-02-10 04:05:26 -05:00
Damien Daspit f7593c22b0 [MWF] Fix NullReferenceException introduced by commit a080a7d
Change-Id: I5709063cc7eecc01fd1e2978cd8aac096060c31e
2015-02-10 09:59:50 +01:00
Marek Safar a74bac2da2 [mcs] Fixed casts rules don't apply to strings and arrays. Fixes #26892 2015-02-10 09:31:22 +01:00
Marek Safar c7a4778737 [mcs] Resolve delegate optional parameters only once. Fixes #26840 2015-02-10 08:49:50 +01:00
Zoltan Varga 8562a498f3 [jit] Factor out the gsharedvt constrained call handling code into a separate function. 2015-02-10 02:27:13 -05:00
Zoltan Varga 382cf74c98 [jit] Fix some issues with constrained gsharedvt calls to be able to handle some cases encountered with the new MS reference source code. 2015-02-10 02:20:32 -05:00
Zoltan Varga b8f1a79295 Increase some trampoline buffer sizes. 2015-02-09 23:08:57 -05:00
Zoltan Varga d7b1944dce Bump referencesource. 2015-02-09 22:40:50 -05:00
Zoltan Varga c83aeed35f Bump referencesource to e6af770c424af46f78d3b8f90eebbb2e0d7953a2. 2015-02-09 22:35:07 -05:00
Alex Rønne Petersen 23fa25b4b5 Revert "[mini] Implement atomic exchange with xchg on x86."
This reverts commit c96e58280c.

Getting this to work right with regards to register allocation
is turning out to be more complicated than it seems. Going to
abandon this for now.
2015-02-10 03:01:33 +01:00
Alex Rønne Petersen c96e58280c [mini] Implement atomic exchange with xchg on x86. 2015-02-10 01:49:18 +01:00
Stephen McConnel e9cf1dc44a Prevent right click from triggering ToolStripItem.HandleClick
This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=26887.
2015-02-09 18:39:18 -06:00
Zoltan Varga 8856edd6d3 Disable some full-aot tests on amd64 since it doesn't support dyn calls/gsharedvt. 2015-02-09 19:09:21 -05:00
Alex Rønne Petersen 0366b81069 [mini] Implement atomic exchange with xchg on amd64. 2015-02-09 23:41:30 +01:00
Marek Safar d2994b1b3d [corlib] Remove unused file 2015-02-09 23:15:16 +01:00
Marek Safar 8d9e34a098 [corlib] Keep file names ordered 2015-02-09 23:14:45 +01:00
Marek Safar 1bfa0567dc Merge pull request #1556 from atsushieno/import-text-encoding
import referencesource CharUnicodeInfo and remove some runtime char tables.
2015-02-09 20:09:04 +01:00
Alex Rønne Petersen 8aaed197ca Revert "[mini] Implement atomic exchange with xchg on x86/amd64."
This reverts commit 1a319806fe.

This seems to cause memory corruption that results in random
SGen crashes, especially in Roslyn.
2015-02-09 19:32:15 +01:00
Ludovic Henry 449666271a [runtime] Lower log level of "counters not enabled" message in counters 2015-02-09 13:12:11 -05:00
Atsushi Eno c72628cf46 Remove unused unicode category data (which is now charinfo.nlp). 2015-02-10 01:43:10 +08:00
João Matos 48b7a501b0 Initialize the counters support before registering new ones.
This bug manifests itself in mkbundle'd programs that use the machine config support. Under this case, we can end up registering counters before initializing the counter support in the runtime:

```
* thread #1: tid = 0x141dec, 0x003ebdff mtouch-32`mono_counters_register(name=0x0042f7e3, type=2048, addr=0x00b81288) + 31 at mono-counters.c:218, queue = 'com.apple.main-thread', stop reason = breakpoint 1.1
  * frame #0: 0x003ebdff mtouch-32`mono_counters_register(name=0x0042f7e3, type=2048, addr=0x00b81288) + 31 at mono-counters.c:218
    frame #1: 0x0025c3f6 mtouch-32`mono_loader_init + 198 at loader.c:106
    frame #2: 0x0025f005 mtouch-32`mono_dllmap_insert(assembly=0x00000000, dll=0x00d0a0c0, func=0x00000000, tdll=0x00d0a0d0, tfunc=0x00000000) + 53 at loader.c:1321
    frame #3: 0x002c28ca mtouch-32`dllmap_start(user_data=0x00d0a0b0, element_name=0x00d0a0a0, attribute_names=0x00d0a030, attribute_values=0x00d0a040) + 698 at mono-config.c:290
    frame #4: 0x002c2010 mtouch-32`start_element(context=0x00d09fa0, element_name=0x00d0a0a0, attribute_names=0x00d0a030, attribute_values=0x00d0a040, user_data=0xbffffb68, error=0x00000000) + 240 at mono-config.c:176
    frame #5: 0x0040ba6d mtouch-32`monoeg_g_markup_parse_context_parse(context=0x00d09fa0, text=0x00b72f30, text_len=240, error=0x00000000) + 1965 at gmarkup.c:351
    frame #6: 0x002c0a93 mtouch-32`mono_config_parse_xml_with_context(state=0xbffffb68, text=0x00b72f30, len=240) + 147 at mono-config.c:440
    frame #7: 0x002c09eb mtouch-32`mono_config_parse_memory(buffer=0x00b72f30) + 123 at mono-config.c:482
    frame #8: 0x00001e6d mtouch-32`install_dll_config_files + 29
    frame #9: 0x00001c86 mtouch-32`mono_mkbundle_init + 22
    frame #10: 0x000029db mtouch-32`main + 331
    frame #11: 0x00001c65 mtouch-32`start + 53
```

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=24605.
2015-02-09 17:40:04 +00:00
Atsushi Eno d8aba3fa75 replace CharUnicodeInfo with that of referencesource and update runtime.
CharUnicodeInfo had conversion methods for uppercase/lowercase
conversion, and they are actually used by TextInfo. So moved them.
Then added another icall for "lite" version of internal character table
loader.

The new CharUnicodeInfo depends on "charinfo.nlp" resource file, which
does not exist in referencesource but can be generated by coreclr build
tools (as src/mscorlib/src/System/Globalization/Tables/CharInfo.nlp).

The coreclr rev. that built this specific checkin was c4eb037.
2015-02-10 00:47:16 +08:00
Marek Safar 0daaf302a5 [corlib] Update failing test 2015-02-10 02:01:29 +10:00
Marek Safar fe40c28be0 Merge pull request #1555 from JetBrains/unrecognized_pragma
Skip unrecognized #pragma directive
2015-02-09 11:17:32 +01:00
Miguel de Icaza d12c06df59 Fix the build 2015-02-08 13:52:29 -05:00
Leonid Shalupov e9b8cb6682 Add test for skipping unrecognized #pragma directive 2015-02-08 19:09:25 +01:00
Leonid Shalupov c4890a882a Skip unrecognized #pragma directive 2015-02-08 19:09:02 +01:00
Zoltan Varga 8628fd051b [jit] Remove unused disable_vtypes_in_regs variable. 2015-02-08 03:23:53 -05:00
Miguel de Icaza 4489d2399d [monop] Port to use IKVM.Reflection, add -xi and -xa options to easily lookup Xamarin.Android and Xamarin.iOS types 2015-02-07 22:44:50 -05:00
Zoltan Varga cc6e967a23 [sdb] Use a variant of g_path_get_basename () which can handle windows paths as well. Fixes #26436. 2015-02-07 22:37:50 -05:00
Zoltan Varga 66f5f06469 Revert "[llvm] Maps structs made up of floats/doubles to llvm structs containing floats."
This reverts commit bc9c77280f.

Revert this as it breaks pinvoke2.exe.
2015-02-07 22:07:06 -05:00
Zoltan Varga e179554eee Revert "Fix the loadable llvm build."
This reverts commit dfe6b21b5e.

Revert this as it breaks pinvoke2.exe.
2015-02-07 22:06:47 -05:00
Zoltan Varga 1f14a9721b Fix the loadable llvm build. 2015-02-07 18:01:43 -05:00
João Matos 1a341220c6 [decimal] Fixed the Windows build.
Works around the following compile error:

```/Users/triton/Development/mono/mono/metadata/decimal-ms.h:3:16: error: redefinition of 'struct tagDEC'
 typedef struct tagDEC {
                ^
In file included from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/unknwn.h:37:0,
                 from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/objidl.h:477,
                 from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/objbase.h:66,
                 from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/ole2.h:17,
                 from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/wtypes.h:12,
                 from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/winscard.h:10,
                 from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/windows.h:97,
                 from /Users/triton/Development/mono/mono/io-layer/io-layer.h:24,
                 from /Users/triton/Development/mono/mono/metadata/process.h:17,
                 from /Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/unistd.h:11,
                 from /Users/triton/Development/mono/mono/metadata/icall.c:27:
/Users/triton/Development/monodroid/builds/toolchains/windows/mxe/usr/i686-w64-mingw32.static/include/wtypes.h:452:16: note: originally defined here
 typedef struct tagDEC {
                ^
```
2015-02-07 14:21:35 +00:00
Zoltan Varga dfe6b21b5e Fix the loadable llvm build. 2015-02-07 07:56:26 -05:00
Miguel de Icaza bc68eda84d Merge pull request #1552 from mono/ms-decimal
Bring the CoreCLR Decimal support to Mono.
2015-02-07 00:05:15 -05:00
Zoltan Varga bc9c77280f [llvm] Maps structs made up of floats/doubles to llvm structs containing floats. 2015-02-06 19:12:03 -05:00
Miguel de Icaza d1ff413081 Make referencesource point to mono/referencesource's mono branch 2015-02-06 17:39:44 -05:00
Miguel de Icaza b8f68cc3f4 [Decimal] Remove old decimal from the metadata directory 2015-02-06 17:28:37 -05:00
Jeffrey Stedfast f2c6ec43dc [Mono.Debugger.Soft] Fixed StackFrame.Domain logic to not blow up 2015-02-06 17:24:57 -05:00
Zoltan Varga ad38eb5cac [arm64] Add r4 opcodes. 2015-02-06 16:18:29 -05:00
Miguel de Icaza e4ee7a5e1f Remove old implementation of Decimal support, it served us well 2015-02-06 15:56:27 -05:00
Miguel de Icaza 97f01eac96 Merge branch 'master' into ms-decimal 2015-02-06 15:54:31 -05:00
Miguel de Icaza b1ca045003 [Decimal] Add test cases from the bugs that this branch fixes 2015-02-06 15:51:14 -05:00
Miguel de Icaza 9e13adae4b [Decimal] Expand test suite with Microsoft's CoreFX Decimal tests 2015-02-06 15:25:58 -05:00
Miguel de Icaza c13ecfcdee [Decimal] Fix another missing cast, makes the entire Mono test suite pass 2015-02-06 14:54:49 -05:00
Miguel de Icaza d72f9a0fc7 [Decimal] Set the reserved field, fix signed to unsigned cast mistakes from the port, document places where MS does not explicitly set reserved; Down to 1 failure 2015-02-06 14:09:40 -05:00
Zoltan Varga 7656a6beb4 Merge branch 'r4fp-ir' 2015-02-06 13:40:16 -05:00
Zoltan Varga 5a61d55c7f Fix the build. 2015-02-06 13:37:47 -05:00
Zoltan Varga 76b0aebf27 Add mixed r4/r8 opcodes to binary opcodes. 2015-02-06 13:32:03 -05:00
Zoltan Varga 32f6084793 Exclude the float32 optimization from -O=all. 2015-02-06 13:32:03 -05:00
Zoltan Varga 067ab06be1 Implement arm support. 2015-02-06 13:32:02 -05:00
Zoltan Varga c77eb2b62e Add LLVM support. 2015-02-06 13:32:02 -05:00
Zoltan Varga e0caebb53a Fix OP_MOVE_F_TO_I4 and OP_MOVE_I4_TO_F in float32 mode. 2015-02-06 13:32:02 -05:00
Zoltan Varga 1d6362cdbd Add support for generating 32 bit floating point code when operating on floats.
Design:

- Handle r4 types in the front-end normally like other types.
- Controlled using a 'float32' optimization flag, may become the default in the future.
- new stack type STACK_R4.
- new set of opcodes prefixed by 'R', use the same vregs as 'F' opcodes.
- opcodes which worked with r4 values are used as before, but generate different code
  in the back end (OP_R4CONST/OP_LOADR4_MEMBASE/OP_STORER4_MEMBASE_REG, etc.).
2015-02-06 13:30:19 -05:00
Miguel de Icaza 0a7d65e63e [Decimal] Fix enumeration values, down to 2 failures 2015-02-06 12:46:17 -05:00
Marek Safar b927fa8ee6 [corlib] Imports messages from coreclr project 2015-02-06 18:37:32 +01:00
Jeffrey Stedfast fcd44bb0d5 [Microsoft.Build.Utilities] Fixed to make unit tests pass again 2015-02-06 12:24:18 -05:00
Alex Rønne Petersen 1f6c5e8be7 [mini] Bump move_f_to_i4/move_i4_to_f insn sizes on x86. 2015-02-06 17:55:58 +01:00
Marek Safar 815c1bd287 Merge pull request #1551 from directhex/fix-missing-System.Web.ApplicationServices-sources
Move files which were split out in 4.0 from System.Web...
2015-02-06 17:55:54 +01:00
Marek Safar 9a26c9ef5f [mcs] Correctly import metadata constant with mismatched type and value. Fixes #24675 2015-02-06 17:54:59 +01:00
Jo Shields f3d505ed1e Ensure missing test_op_il_seq_point.sh is shipped in tarballs. 2015-02-06 10:48:47 -05:00
Alex Rønne Petersen cb085a39c5 [mini] Remove OP_ICONV_TO_R8_RAW since OP_MOVE_I4_TO_F does the same thing. 2015-02-06 16:45:14 +01:00
Alex Rønne Petersen 2bb9ed862c [mini] Use a spill var for float <-> int data transfer opcodes on x86. 2015-02-06 16:45:14 +01:00
Alex Rønne Petersen 1046214694 [mini] Remove some unnecessary amd64 codegen macros (we already had them with different names). 2015-02-06 16:45:14 +01:00
Jo Shields eb53f82111 Move files which were split out from System.Web into System.Web.ApplicationServices into the latter's directory. They no longer need to be in the former, since we no longer build the 2.0 profile they were originally part of. This fixes "no rule to make target" errors on tarball builds, caused by those files no longer being shipped in tarballs (make dist does not traverse a ../ boundary, so it wasn't enough for them to be listed in System.Web.ApplicationServices' manifest by System.Web's folder) 2015-02-06 10:17:54 -05:00
Miguel de Icaza a51ac80865 Merge pull request #1550 from tpetazzoni/mips-fix
mono-context.h: fix build on MIPS
2015-02-06 09:50:33 -05:00
Sebastien Pouliot 375b749fca [tests] Fix TypeDescriptorTests compilation when NUnitLite is used 2015-02-06 09:37:21 -05:00
Marek Safar c7ad272b9a [mcs] Fix cloning of labels from outer anonymous block. Fixes #26736 2015-02-06 15:14:26 +01:00
Marek Safar baa2c983b3 [mcs] Replace 1684 warning turned into error with unique 7069 error code 2015-02-06 15:14:26 +01:00
Thomas Petazzoni 8f489c24e1 mono-context.h: fix build on MIPS
The mono-context.h file uses definitions such as mips_fp and mips_sp,
which are defined in <mono/arch/mips/mips-codegen.h>, but this file is
not included, leading to build failures.

This fix is similar to 4437ecea91 (for
ARM).

Signed-off-by: Thomas Petazzoni <[email protected]>
2015-02-06 14:56:10 +01:00
João Matos 88e35ade18 [runtime] Fixed potential memory leak in a8390dcd63. 2015-02-06 12:46:24 +00:00
João Matos a8390dcd63 [runtime] Fixed marshalling bug in mono_marshal_get_native_func_wrapper.
It was caused by a mismatch of the `sig` and `csig` variables when looking the wrapper in the marshalling cache.

This was manifesting as the following crash in all Monodroid programs:

```
#0  mono_type_hash () at /Users/joao/Dev/droid/mono/mono/metadata/metadata.c:1390
#1  0x7512edf4 in mono_signature_hash () at /Users/joao/Dev/droid/mono/mono/metadata/metadata.c:4957
#2  0x75115d18 in signature_pointer_pair_hash () from /Users/joao/Dev/droid/monodroid/tests/runtime/gdb-symbols/libmonosgen-2.0.so
#3  0x751dca10 in rehash () from /Users/joao/Dev/droid/monodroid/tests/runtime/gdb-symbols/libmonosgen-2.0.so
#4  0x751dcbe0 in monoeg_g_hash_table_insert_replace () from /Users/joao/Dev/droid/monodroid/tests/runtime/gdb-symbols/libmonosgen-2.0.so
#5  0x75119570 in mono_mb_create_and_cache_full () from /Users/joao/Dev/droid/monodroid/tests/runtime/gdb-symbols/libmonosgen-2.0.so
#6  0x75127390 in mono_marshal_get_native_func_wrapper () from /Users/joao/Dev/droid/monodroid/tests/runtime/gdb-symbols/libmonosgen-2.0.so
#7  0x75127780 in mono_ftnptr_to_delegate () from /Users/joao/Dev/droid/monodroid/tests/runtime/gdb-symbols/libmonosgen-2.0.so
```

Originally introduced in https://github.com/mono/mono/pull/1540.
2015-02-06 12:35:45 +00:00
Marek Safar 6733010353 Merge pull request #1508 from slluis/fix-20966
Generate proper Link metadata for resources in imported projects
2015-02-06 11:05:40 +01:00
Marek Safar a62823ac14 Merge pull request #1549 from esdrubal/tziathens
[corlib] Fixed TimeZoneInfo.TryGetTransitionOffset.
2015-02-06 09:18:01 +01:00
Marcos Henrich 5df4852b1a [corlib] Fixed TimeZoneInfo.TryGetTransitionOffset.
Olson TZ transitions are in UTC, and TryGetTransitionOffset used the TZ standard time.
TryGetTransitionOffset was comparing UTC with TZ standard times thus DST transitions could be obtained some hours before their start.
TryGetTransitionOffset is now changing provided times to UTC before comparing them with the transition times.
Fixes #25050.
2015-02-06 09:30:51 +02:00
Marcos Henrich 0c5347ad43 [corlib] Added test to TimeZoneInfoTest. Covers #25050. 2015-02-06 06:20:54 +00:00
Miguel de Icaza 9241773f5c [Decimal] Fix structure definitions, down to 3 failures from Mono test suite 2015-02-06 00:42:44 -05:00
Miguel de Icaza 9d31706582 [Decimal] Down to six failures in Mono's test suite 2015-02-06 00:23:52 -05:00
Miguel de Icaza 98e9d352e4 [Decimal] Fix basic decimal startup issues 2015-02-05 22:56:41 -05:00
Miguel de Icaza fd78f734ea [Build] Make the code build with old bootstrapped environments 2015-02-05 22:11:59 -05:00
Miguel de Icaza 09abacdd14 [Decimal] Fix the build for unresolved symbols with some C compilers 2015-02-05 22:11:35 -05:00
Alex Rønne Petersen 36a5363ef7 [mini] Remove now-unneeded clob spec for move_f_to_i4 on amd64. 2015-02-06 03:47:40 +01:00
Miguel de Icaza 5bde5effed Merge pull request #1548 from akoeplinger/stubs
[bcl] Added a few stubs for missing APIs
2015-02-05 21:01:38 -05:00
Zoltan Varga 1445d4821c [runtime] Update valgrind headers to the ones from valgrind 3.10.1. Fixes #26688. 2015-02-05 20:53:21 -05:00
Miguel de Icaza dda1b86e64 [Decimal] Completed the methods in decimal-ms.c
This completes the list of methods in decimal-ms.c that are surfaced
to the Decimal class.  This change also swaps out the Decimal class
from Mono to the Microsoft implementation.

This has not been tested yet, beyond the compiler being able to read
decimals (it did crash without it).

CoreCLR has two different bits of code for SearchScale, it looks like
one is just old and has not been updated.  Moved to the new one, and
updated the code to pass the extra data that is missing from the
former one.
2015-02-05 18:25:48 -05:00
Zoltan Varga a5f77df5e1 [amd64] Avoid clobbering sreg1 in OP_MOVE_F_TO_I4. 2015-02-05 17:16:53 -05:00
Zoltan Varga 00a28a7dfd [jit] Avoid live range indexes overflowing for large basic blocks in the liveness pass. Fixes #26732. 2015-02-05 17:16:53 -05:00
Rodrigo Kumpera 8b4a2f2bd6 [runtime] Plug a loader error leak. 2015-02-05 17:15:42 -05:00
Zoltan Varga 54c312fa93 Revert "[jit] Avoid live range indexes overflowing for large basic blocks in the liveness pass. Fixes #26732."
This reverts commit 98f665aba9.

Revert this as it causes assertions on methods with large basic blocks.
2015-02-05 16:53:26 -05:00
Sebastien Pouliot 6bd76b142d Bump referencesource to disable some CAS usage 2015-02-05 15:55:09 -05:00
Alexander Köplinger 890ca8595e Fix error message to mention git instead of svn
Just a nitpick, but I saw this in a build log and thought I'd fix it.
2015-02-05 21:30:58 +01:00
Sebastien Pouliot 7145c08255 [linker] Only consider [Preserve] (i.e. without any parameters) on assembly-level as meaning 'preserve everything inside this assembly'. 2015-02-05 15:20:55 -05:00
Sebastien Pouliot 7b29d5abb2 [linker] Preserve types given to custom attributes - even if they are inside an array [#26030] 2015-02-05 15:19:46 -05:00
Sebastien Pouliot a7a4de9dd5 [linker] Do not process custom attribute fields unless there are some (avoids memory allocation for collections) 2015-02-05 15:18:47 -05:00
Mark Probst fe56186215 Merge pull request #1546 from evincarofautumn/faster-binprot
Make sgen-grep-binprot faster.
2015-02-05 11:55:26 -08:00
Jon Purdy b299715e36 [sgen] Make sgen-grep-binprot faster.
fread() spent a great deal of time locking, and we called malloc() once for
each entry. Replacing fread() with read() plus manual buffering, as well
as replacing malloc() with a static buffer, improves throughput by an
order of magnitude.

This also adds an '--input' option for reading from a stream other than
standard input.
2015-02-05 11:53:08 -08:00
Neale Ferguson d19817ad9c Use float<->integer instructions for move operations 2015-02-05 14:36:54 -05:00
Jeffrey Stedfast f076746dd7 [Microsoft.Build.Utilities] Fixed MSBuildErrorParser to be more robust 2015-02-05 13:43:14 -05:00
Marek Safar ecaa5d7faf [mcs] Prefer not missing type for ambiguous imported types. Fixes #26753 2015-02-05 18:25:18 +01:00
Alexander Köplinger 92af367655 [bcl] Added a few stubs for missing APIs
They are required for the upcoming System.Web port.
2015-02-05 18:09:40 +01:00
Marek Safar 52ce4a07b2 [corlib] TimeZoneInfo.ConvertTimeToUtc maximum datetime handling 2015-02-05 07:25:49 -05:00
Marek Safar 8442408da0 [runtime] Fixes setting FileVersionInfo managed booleans 2015-02-05 12:34:16 +01:00
Marek Safar 26a31a583b [xbuild] Fix When Condition with a user comment 2015-02-05 11:49:59 +01:00
Marek Safar 6b908c2f34 [build] remove unused defines 2015-02-05 11:28:40 +01:00
Marek Safar 7c0da3c990 [corlib] BitConverter from reference sources 2015-02-05 10:48:49 +01:00
Alex Rønne Petersen 4c887f7ba4 [mini] Really fix the float <-> int data transfer instructions on arm.
The ARM_CVTS/ARM_CVTD macros have somewhat deceptive names: They
describe the source data type, not the target data type.
2015-02-05 04:59:47 +01:00
Miguel de Icaza 5b2bb8c901 [decimal] Microsoft's unmanaged code for decimal support
This is a port of the CoreCLR Decimal support to C and to the Mono
coding conventions.  In the process of porting the code, I removed a
bunch of COM-isms and some Windows-isms that were just workaround with
compatibility typedefs and replaced it instead with stdint.h data
types as well as Mono assertions.

There are still a few methods missing, and the managed library is not
plugged yet (both constructors likely need to be altered to be managed
proxies to the init method).
2015-02-04 21:45:03 -05:00
Alex Rønne Petersen 136f17a024 Merge pull request #1541 from alexrp/mcs-build-cleanup
Clean up mcs build system
2015-02-05 03:13:59 +01:00
Miguel de Icaza dee36bfa52 Start work to generate dependencies 2015-02-04 21:05:29 -05:00
Alex Rønne Petersen 2baec073f4 [mini] Implement float <-> int data transfer instructions in the LLVM backend. 2015-02-05 02:03:38 +01:00
Rodrigo Kumpera 3b38dffbc4 [test] Add verifier test for cgt_un and valuetypes. 2015-02-04 17:08:47 -05:00
Rodrigo Kumpera ff87fbe74d [verifier] Properly verify CGT_UN when used with reference value and the null literal. 2015-02-04 17:06:38 -05:00
Zoltan Varga 98f665aba9 [jit] Avoid live range indexes overflowing for large basic blocks in the liveness pass. Fixes #26732. 2015-02-04 14:00:17 -05:00
Zoltan Varga 257620d383 [runtime] Enable the new interrupt code on arm64. 2015-02-04 13:22:38 -05:00
Marek Safar 03c62b9023 Move TimeZoneInfo tests to corlib 2015-02-04 19:09:14 +01:00
Marek Safar da7d598940 [system.xml] Disable failing test, requires reference source implementation 2015-02-04 18:46:30 +01:00
Marek Safar 798e9c0c41 [corlib] Fix overflow in TimeZoneInfo utc conversion 2015-02-04 17:55:41 +01:00
Marek Safar 22c8cc477f [mcs] update error message 2015-02-04 17:55:41 +01:00
Marek Safar b75b33ab83 [corlib] Boolean from reference sources 2015-02-04 17:55:41 +01:00
Radek Doulik 598920ce36 [android] disable TLS on android/x86_64
- otherwise we assert in sgen allocator
   in   sgen-gc.h:EMIT_TLS_ACCESS_NEXT_ADDR
   thru sgen-alloc.c:create_allocator
 - note that it is also disabled for ARM[64] and X86
   on android
2015-02-04 17:16:22 +01:00
Marek Safar 96eca3b925 [System] More TypeDescriptor tests 2015-02-04 15:49:41 +01:00
Marek Safar 9e396e4022 [corlib] Add test for #17626 2015-02-04 15:36:51 +01:00
Marek Safar aa4ba602fc [corlib] DateTime from reference sources 2015-02-04 15:36:51 +01:00
Alex Rønne Petersen 29a4519b5f Revert "[runtime] Fixed allowing non-object complex arguments to cgt.un"
This reverts commit 38f878ce9d.

This broke the build: http://wrench.mono-project.com/Wrench/WebServices/Download.aspx?workfile_id=3704132
2015-02-04 15:28:44 +01:00
Alex Rønne Petersen c294093080 [mini] Hopefully fix float <-> int data transfer instructions on x86. x87 sucks. 2015-02-04 14:58:03 +01:00
Alex Rønne Petersen 5ad8b5d9d4 [mini] Fix float <-> int data transfer instructions on arm/mips. 2015-02-04 14:42:43 +01:00
Alex Rønne Petersen b48718ed54 [mini] Fix x86/arm build. 2015-02-04 14:42:43 +01:00
João Matos 057af01163 Fixed System.Net.NetworkInformation tests to work with MonoTouch.NUnitLite. 2015-02-04 13:21:40 +00:00
João Matos acbf7557e4 [runtime] Added autoconf support for AMD64 Android cross compilation. 2015-02-04 13:08:32 +00:00
Alex Rønne Petersen 1a319806fe [mini] Implement atomic exchange with xchg on x86/amd64. 2015-02-04 13:18:13 +01:00
Alex Rønne Petersen 5ca71a7700 [mini] Use new float <-> int move opcodes to implement r4/r8 CAS/Exchange. 2015-02-04 12:05:59 +01:00
Alex Rønne Petersen afd8928030 [mini] Add new instructions for moving data between float and int regs.
These perform no conversions (other than any necessary single <-> double
conversions). They simply copy the raw data back and forth.
2015-02-04 12:05:59 +01:00
Alex Rønne Petersen 9095bc0d14 [mini] Apply the dreg != sreg1 optimization to OP_(F)MOVE in all backends. 2015-02-04 12:05:58 +01:00
Alex Rønne Petersen 1d3ec567aa [mini] Fix some cases where intrinsics did not have a stack type set. 2015-02-04 12:05:58 +01:00
Radek Doulik a99d8a396d [android] do not use tkill on android/amd64(x86_64) as well 2015-02-04 09:54:00 +01:00
Alex Rønne Petersen 00725c15bc Merge pull request #1543 from alexanderkyte/master
[runtime] Fixed allowing non-object complex arguments to cgt.un
2015-02-04 04:53:29 +01:00
Alexander Kyte 38f878ce9d [runtime] Fixed allowing non-object complex arguments to cgt.un 2015-02-03 22:43:50 -05:00
Zoltan Varga a85fe92f45 [amd64] Add missing amd64_sse_cvtss2si_reg_reg_size() codegen macro. 2015-02-03 20:44:26 -05:00
Vlad Brezae bea7d8a600 [jit] Pass the aligned object size to the managed allocator. 2015-02-03 23:51:59 +00:00
Vlad Brezae 29659f7623 [jit] Optimize the managed allocator fastpath
Send the instance_size as an argument to the managed object allocator to reduce memory dereferences from the vtable in the generated code.
2015-02-03 23:51:58 +00:00
Zoltan Varga 989301647e Merge pull request #1545 from akoeplinger/fix-windows-build
Fix Windows build
2015-02-03 15:58:12 -05:00
Alexander Köplinger 0b2a537abf Fix Windows build
It was broken by c731686feb
2015-02-03 10:40:03 -08:00
Miguel de Icaza 38a2f62b2f Updated the order file generated by following the instructions in msvc/scripts/README 2015-02-03 11:48:38 -05:00
Marek Safar 0b32ad8dfc [corlib] TimeSpan from reference sources 2015-02-03 16:20:55 +01:00
João Matos 58ae0ae309 [corlib] Fixed tests to work with NET_2_1 define. 2015-02-03 14:11:32 +00:00
Marek Safar 6427a13879 [corlib] DateTimeOffset from reference sources 2015-02-03 11:58:48 +01:00
Marek Safar 5937d3a70c [corlib] DateTimeFormatInfo and friends from reference sources 2015-02-03 10:30:30 +01:00
Marek Safar 98ecb517a7 [system] Add support for redirected http web-request with disabled AllowWriteStreamBuffering (empty streams only). Fixes #26640 2015-02-03 10:25:03 +01:00
Rodrigo Kumpera 98658d9091 [runtime] Replace a call to mono_get_method_full to mono_get_method_checked. 2015-02-02 22:36:15 -05:00
Alex Rønne Petersen e55268f3ab Remove old centum tests stuff.
Despite what the makefiles would have you believe, this was never
actually used when running the test suites. Don't ask me why - my
make-fu isn't good enough. Regardless, it's a bad idea to only
run tests for a specific set of assemblies. If some tests fail or
are unstable, they should be fixed, or disabled and have a bug
filed. Sweeping them under the rug like this is the wrong thing
to do. Incidentally, this commit doesn't add any new failures.
2015-02-03 03:41:15 +01:00
Alex Rønne Petersen c740b9831d Remove now-obsolete System.Web.Extensions(.Design)_1.0 assemblies.
These are no longer built in the newer profiles.
2015-02-03 03:41:14 +01:00
Alex Rønne Petersen 351e94964c Remove obsolete profiles and profile checks from the build system.
* Removed all old profiles from VALID_PROFILE checks.
* Removed most logic under checks like ifeq (net_2_0), $(PROFILE)) as
  it is dead code now that those old profiles are gone.
* Simplified the list of assemblies in mcs/class/Makefile now that we
  only have one profile.
* LIBRARY_NEEDS_POSTPROCESSING has been removed as it was only used by
  old 1.x assemblies that no longer exist.
* Build logic that sets MONO_PATH now points to mcs/class/lib/net_4_5
  instead of mcs/class/lib/net_2_0.
2015-02-03 03:41:14 +01:00
Alex Rønne Petersen 43a0088f3f Remove some leftover old 1.x, 2.x, 3.x profile ifdefs.
We no longer support these profiles so these code paths are dead.
2015-02-03 03:41:14 +01:00
Zoltan Varga 1b41e15f91 Avoid recompiling a test on every run. 2015-02-02 19:30:30 -05:00
Zoltan Varga d504f17272 Revert "Switch System.Web.ApplicationServices to referencesource"
This reverts commit ea88432e49.

Revert this as it breaks the System.Web tests.
2015-02-02 18:20:45 -05:00
Zoltan Varga e2193970c9 Revert "Include hard-coded strings (SR.cs-style) rather than using AppliCationServicesStrings.Designer.cs"
This reverts commit b88fc96610.

Revert this as it breaks the System.Web tests.
2015-02-02 18:20:23 -05:00
Rodrigo Kumpera 9621471d3a [io-layer] Small portability fix. 2015-02-02 17:39:38 -05:00
Jonathan Pryor 52eceb5460 [System.Core/Android] Update TimeZone database self test.
The `make tzi.exe` target had bitrotted, and the
`make android-dump-tzdata` target generated inadvertent/unintentional
errors.  Fix the makefile so that things build and run.
2015-02-02 15:20:39 -05:00
Marek Safar d8cbfdfbb1 [corlib] Makes AggregateException output visible 2015-02-02 20:26:52 +01:00
João Matos d9f9ba0d8b [corlib] Fixed xammac build. 2015-02-02 15:53:02 +00:00
João Matos b6df249cc2 [corlib] Fixed build with NET_2_1 define. 2015-02-02 15:51:50 +00:00
Rolf Bjarne Kvinge f3b7aa8afc [System.Xml] Overwrite instead of append so that subsequent executions doesn't end up with garbage in the output. 2015-02-02 13:51:42 +01:00
Rodrigo Kumpera 03a28d987a [jit] Fix bad_method_regression_2 when SSA is enabled on 32bits. 2015-02-01 19:20:17 -05:00
Dave Curylo 7cbeed36fd Fix to UriTemplate.Match to properly handle query parameters without a value. No longer throws IndexOutOfRangeException and the parameter is added to the resulting UriTemplateMatch.QueryParameters field with a null value, same as in .NET.
This change is released under the MIT license.
2015-01-31 07:21:03 -05:00
Zoltan Varga 3edd4ffe6b Merge pull request #1540 from esdrubal/marshallingcache
[runtime] Added native_func_wrapper_cache.
2015-01-31 02:42:34 -05:00
Zoltan Varga 910ebf9438 [jit] Increase the inline memcpy/memset cutoff to 8 machine words. 2015-01-30 23:50:28 -05:00
Zoltan Varga 1f5b328219 [llvm] Add a new LLVMArgAsFpArgs argument passing convention which means an argument is passed as a set of fp scalar arguments, i.e. HFAs on arm64. 2015-01-30 20:59:55 -05:00
Zoltan Varga 4b2d1f0edc Fix a warning. 2015-01-30 19:15:24 -05:00
Zoltan Varga 4bd4e7539a [arm] Enable llvm for methods with struct arguments larger than 2 words. 2015-01-30 17:46:43 -05:00
Zoltan Varga d4077516ed [runtime] Disable a test which fails with llvm/gcc. 2015-01-30 15:43:22 -05:00
Rodrigo Kumpera c731686feb Don't include the poll backed directly into the threadpool source code. 2015-01-30 14:07:52 -05:00
Rodrigo Kumpera ebf7c45f74 [runtime] Skip the finalizer thread while it's sleeping. 2015-01-30 14:07:52 -05:00
Marcos Henrich 09c48bc964 [runtime] Added native_func_wrapper_cache.
mono_marshal_get_native_func_wrapper now uses native_func_wrapper_cache indexed by SignaturePointerPair,

Using SignaturePointerPair index instead of MonoMethod index avoids problems when one native function needs multiple wrappers.
e.g: when the managed code creates delegates for function pointers with parameters that require different marshallings.

This fixes bug 26127.
2015-01-30 17:01:45 +00:00
Marcos Henrich e8f48de9bb [runtime] Renamed SignatureMethodPair to SignaturePointerPair.
Changed field MonoMethod* method to gpointer pointer.
This change was done because we need in some cases to use a signature pointer pair.
2015-01-30 15:26:03 +00:00
Marek Safar 26618719fe Merge pull request #1539 from directhex/use-referencesource-for-System.Web.ApplicationServices
Include hard-coded strings (SR.cs-style) rather than using AppliCationServicesStrings.Designer.cs
2015-01-30 15:13:37 +01:00
Jo Shields b88fc96610 Include hard-coded strings (SR.cs-style) rather than using AppliCationServicesStrings.Designer.cs
This avoids depending on a missing .resources file with string translations in it
2015-01-30 14:09:15 +00:00
João Matos 6fa8f480dd Merge pull request #1538 from directhex/use-referencesource-for-System.Web.ApplicationServices
Switch System.Web.ApplicationServices to ReferenceSource.
2015-01-30 12:45:38 +00:00
Jo Shields ea88432e49 Switch System.Web.ApplicationServices to referencesource
Due to the removal of the net_2_0 profile, the files in ../System.Web/System.Web.Security aren't included in make dist anymore since they aren't used in System.Web (the classes got moved to System.Web.ApplicationServices.dll in .NET 4).

This breaks the tarball builds, as System.Web.ApplicationServices relies
on those files, so we now include the ReferenceSource equivalents instead.
2015-01-30 12:44:47 +00:00
Rodrigo Kumpera 2436f4c059 [runtime] Use MonoError instead of loader error with signature parsing. 2015-01-30 01:03:01 -05:00
Sebastien Pouliot 998dbd5a9d Bump referencesource to disable CAS calls on System.Componentmodel.TypeDescriptor [#26554] 2015-01-29 19:58:45 -05:00
Alex Rønne Petersen f3d7670010 [mini] Fix Enum.HasFlag () intrinsic emitting a bad OP_LCEQ on 32-bit. 2015-01-30 01:10:31 +01:00
Zoltan Varga 8b6ae32c26 Fix the dreg op the long_ccc instructions, those instructions return ints. 2015-01-29 19:09:43 -05:00
Mark Probst d43c5b2723 Merge pull request #1537 from evincarofautumn/color-binprot
Add color mode to sgen-grep-binprot.
2015-01-29 14:09:14 -08:00
Jon Purdy b63d941ba0 [runtime] Add color mode to sgen-grep-binprot.
When searching for a pointer with '--color' or '-c', the field in a
protocol entry that matched will be highlighted; when searching for
multiple pointers, they will be highlighted in different colors
according to their order on the command line. When highlighting more
than six pointers, colors will be reused.
2015-01-29 13:51:27 -08:00
Jon Purdy 9df536fcc6 [runtime] Fix incorrect labels in sgen-grep-binprot output. 2015-01-29 12:52:13 -08:00
Miguel de Icaza 4bc5170cb5 Add more detail 2015-01-29 15:39:59 -05:00
Miguel de Icaza 9e53c70376 [lldb] Document and install the mono.py file for LLDB 2015-01-29 15:33:48 -05:00
Zoltan Varga 2457f29139 Fix a warning. 2015-01-29 15:29:45 -05:00
Alex Rønne Petersen bc13a8125e [mini] Fix decomposition of long opcodes in VolatileRead ()/VolatileWrite () intrinsics. 2015-01-29 19:06:33 +01:00
Alex Rønne Petersen 8221afc2bc Optimize Enum.HasFlag () implementation and recognize it in the JIT.
The previous implementation did a ton of reflection and boxing making
it about 4x slower than it should be. This new (native) implementation
simply memcpy ()s the values out of the Enum objects and then does the
bitwise AND.

In addition, the JIT now recognizes this common IL pattern:

	<push int or long ptr>
	<push int or long>
	box MyFlagsEnum
	constrained. MyFlagsEnum
	callvirt instace bool class [mscorlib] System.Enum::HasFlag (class [mscorlib] System.Enum)

This is generated from C# code such as:

	MyFlagsEnum a = ..., b = ...;
	a.HasFlag (b);

When the operand types of the `box` and `constrained.` instructions are
the same, we can skip all the slow stuff that HasFlag () normally does
and simply turn the whole thing into this IR:

	<this> = loadi4_membase <this_ptr>
	<temp> = int_and <this> <flag>
	icompare <temp> <flag>
	<result> = int_ceq

This is about 60x faster than the old HasFlag () without any JIT support
and about 15x faster than the new HasFlag () native implementation.

Also, added missing argument checks to HasFlag ().
2015-01-29 19:06:33 +01:00
João Matos 32db079545 [build] Updated the class library MSBuild projects. 2015-01-29 17:02:08 +00:00
Rodrigo Kumpera 7551802f99 Merge pull request #1536 from esdrubal/noreuse
[runtime] MonoIO methods using SafeHandle now prevent handle reuse.
2015-01-29 10:15:05 -06:00
João Matos 8c8eb43638 [System.Core] Fixed interpreter build. 2015-01-29 16:11:37 +00:00
Miguel de Icaza 27da886fe8 [FtpWebRequest] Add test for bug #26312, issue was fixed by bringing .NET's implementation 2015-01-29 10:45:59 -05:00
Marcos Henrich cfbd2c797b [runtime] MonoIO methods using SafeHandle now prevent handle reuse.
This reverts partially commit 753229c72dd9f2b63beb097700e350164b887c2.

Marshallers are not called for ICalls parameters so the change of ICalls parameters to SafeHandle did not prevents handle reuse.

To prevent handle reuse ICalls are no longer called directly.
Instead we call a method that receives a SafeHandle and wraps the ICall call with safeHandle.DangerousAddRef and safeHandle.DangerousReleaseRef.

This guarantees that the safe handle reference countererence does not reach zero before or while the ICall, thus avoiding the handle beeing released and possibly reused.
2015-01-29 15:27:57 +00:00
Marek Safar 01557ce516 [system.core] Fixes MT build 2015-01-29 15:54:54 +01:00
Marcos Henrich d08bfead6f [symbolicate] Added tool README. 2015-01-29 13:13:00 +00:00
Rodrigo Kumpera dc953f8095 [eglib] [io-layer] Have a single wrapper around getdtablesize. This removes the duplicate on io-layer and exports the eglib one. 2015-01-28 20:28:13 -05:00
Zoltan Varga d547860431 [mdoc] More updates to expected test output. 2015-01-28 20:15:28 -05:00
Alex Rønne Petersen 55b090587d [mini] Prefer OP_ICEQ over OP_CEQ in i4 CAS intrinsics. 2015-01-29 01:17:06 +01:00
Zoltan Varga 57a302ce03 [arm64] Add tests for loading of sbyte/bool arguments passed on the stack. 2015-01-28 18:39:24 -05:00
Rodrigo Kumpera 3798f91417 [profiler] Report methods not found in async mode due to AOT. 2015-01-28 18:25:46 -05:00
Rodrigo Kumpera bb83aaa4f0 [utils] Fix mono_dl_build_path termination logic. 2015-01-28 18:25:45 -05:00
Rodrigo Kumpera 1e47df3c7b [runtime] Fix appdomain loading event ordering. 2015-01-28 18:25:41 -05:00
Kai Ruhnau 46b5b849ae Populate the RequestingAssembly property of ResolveEventArgs 2015-01-28 18:15:30 -05:00
Zoltan Varga 98949d2e25 Merge pull request #1535 from StephenMcConnel/bug-26523
Fix the default behavior of ToolStripLayoutStyle.Table
2015-01-28 17:54:38 -05:00
Stephen McConnel aa7bfb2359 Fix the default behavior of ToolStripLayoutStyle.Table
This addresses https://bugzilla.xamarin.com/show_bug.cgi?id=26523.
2015-01-28 16:52:40 -06:00
Alex Rønne Petersen 962c9682ab [mini] Add some missing atomic instructions to cpu-arm64.md. 2015-01-28 23:48:36 +01:00
Ludovic Henry 2c524916b7 [runtime] Fix #26307 "Random crash due to threading issue in new threadpool heuristics code"
By locking `threads_lock` before launching the thread, we guarantee that the thread is not going to remove itself from `threads` before we actually add it to `threads`.
2015-01-28 15:56:07 -05:00
Zoltan Varga d1647dabf8 Merge pull request #1533 from jbevain/pdb2mdb-roslyn
[pdb2mdb] Skip unknown pdb metadata
2015-01-28 15:45:26 -05:00
Rodrigo Kumpera 36afbc6563 Merge pull request #1510 from BrzVlad/fix-file-map
Fix file map
2015-01-28 14:18:19 -06:00
Mark Probst 5f70b2e00b Merge pull request #1527 from ludovic-henry/master
[runtime] Generate binary protocol functions and structure with macro
2015-01-28 10:12:50 -08:00
Alex Rønne Petersen 5b1bce5693 [mini] Add atomic load/store instructions for float/double. 2015-01-28 18:29:09 +01:00
Alex Rønne Petersen 40ad17a1c3 [mini] Lower atomic load/store instruction sizes on ARM. 2015-01-28 18:29:09 +01:00
Alex Rønne Petersen 133aad946c [mini] Fix some warnings. 2015-01-28 18:29:09 +01:00
João Matos 78e28d1121 [runtime] Fixed mono_dl_open_file to work in Android. 2015-01-28 17:21:22 +00:00
Ludovic Henry b9da8d3f1e [runtime] Generate binary protocol functions and structure with macro
You just have to edit mono/metadata/sgen-protocol-def.h to generate a new binary protocol entry type
2015-01-28 11:51:51 -05:00
Marcos Henrich 4f2b974bfa [symbolicate] Added symbolicate.expected.
The added file Test/symbolicate.expected contains the value that we expect to find in Test/out/symbolicate.out.
make check now uses Test/symbolicate.expected.
2015-01-28 16:35:13 +00:00
Marcos Henrich c052b2618c [runtime] Duplicated instructions OP_IL_SEQ_POINT are now removed.
Sequences of OP_IL_SEQ_POINT instructions are now reduced to only the instruction.
This removes about half of the generated sequence point instructions.
2015-01-28 16:35:13 +00:00
Henrik Feldt 789d43622e [crypto] Re-instantiate for Invariants() test 2015-01-28 17:13:02 +01:00
Henrik Feldt 0b8d94d285 [crypto] check key length in test 2015-01-28 16:51:11 +01:00
Marek Safar b23077459a [System.Core] More reference sources 2015-01-28 16:30:19 +01:00
Marek Safar f90fe36593 [corlib] Move Aes.cs to corlib 2015-01-28 16:30:19 +01:00
Marek Safar 895f9cc39e [system.core] Profiles cleanup 2015-01-28 16:30:18 +01:00
Marek Safar cba3edec90 [corlib] Move TimeZoneInfo source files to assembly they are used 2015-01-28 16:30:18 +01:00
Marek Safar a303b38586 [system.core] Cleanup TimeZoneInfo ifdefs 2015-01-28 16:30:18 +01:00
Henrik Feldt 7fc8c726ad [crypto] Key size 128 bytes for HMACSHA512
Using recommended key size according to MSDN (1) and RFC4868 (2).

 (1): https://msdn.microsoft.com/en-us/library/w5y83hkf%28v=vs.110%29.aspx
 (2): https://tools.ietf.org/html/rfc4868
2015-01-28 16:28:24 +01:00
Henrik Feldt c72f6c2fb5 [crypto] Key size 128 bytes for HMACSHA384
Using recommended key size according to MSDN (1) and RFC4868 (2).

 (1): https://msdn.microsoft.com/en-us/library/h43559cy%28v=vs.110%29.aspx
 (2): https://tools.ietf.org/html/rfc4868
2015-01-28 16:28:24 +01:00
Henrik Feldt ad4a6a5369 [crypto] Key size 64 for HMACSHA256
Using recommended key size according to MSDN (1) and RFC4868.

Fixes #23808 - https://bugzilla.xamarin.com/show_bug.cgi?id=23808

 (1): https://msdn.microsoft.com/en-us/library/9c9tf8wc%28v=vs.110%29.aspx
 (2): https://tools.ietf.org/html/rfc4868 - under
      2.1.1.  Data Origin Authentication and Integrity Verification Usage
2015-01-28 16:28:09 +01:00
Henrik Feldt f3d2c41b26 [crypto] Key size 64 for HMACSHA1
This HMAC cipher accepts any key size (1), took from RFC2104, which uses
the full 64 bytes of key since it has a block length of 64 bytes.

 (1): https://www.ietf.org/rfc/rfc2104.txt - Chapter 2: Definition of HMAC
2015-01-28 16:27:54 +01:00
Henrik Feldt 1caf94bec7 [crypto] Key size 64 for HMACRIPEMD160
This HMAC cipher accepts any key size (1), took 64 bytes from MSDN (2)

 (1): https://tools.ietf.org/html/rfc2857 - chapter 3 keying material
 (2): https://msdn.microsoft.com/en-us/library/8k00xhf0%28v=vs.110%29.aspx
2015-01-28 16:27:41 +01:00
João Matos 786edf7ad6 [msvc] Updated runtime project files. 2015-01-28 15:09:14 +00:00
João Matos cde444ffb0 [runtime] Windows build fixes. 2015-01-28 15:07:17 +00:00
Jb Evain 974526dd3c [pdb2mdb] Skip unknown pdb metadata
This patch allows pdb2mdb to convert pdb files containing
metadata items emitted by the Roslyn compiler.
2015-01-28 15:36:46 +01:00
Alex Rønne Petersen 4d72abb180 [mini] Fix a few cases where incorrect vreg types were being allocated for intrinsics. 2015-01-28 14:36:49 +01:00
Alex Rønne Petersen c6fb35d47d [mini] Fix stack type for atomic intrinsics involving IntPtr. 2015-01-28 14:36:49 +01:00
Rolf Bjarne Kvinge 2bdeceed14 [mono-api-html] Take arity into account when comparing methods.
Fixes a crash when there are two methods overloaded by arity:

System.InvalidOperationException: Sequence contains more than one matching element
  at System.Linq.Enumerable.Single[XElement] (IEnumerable`1 source, System.Func`2 predicate, Fallback fallback) [0x00038] in /private/tmp/source-mono-mac-3.10.0-branch/bockbuild-mono-3.10.0-branch/profiles/mono-mac-xamarin/build-root/mono-3.10.0/mcs/class/System.Core/System.Linq/Enumerable.cs:2371
  at System.Linq.Enumerable.SingleOrDefault[XElement] (IEnumerable`1 source, System.Func`2 predicate) [0x00007] in /private/tmp/source-mono-mac-3.10.0-branch/bockbuild-mono-3.10.0-branch/profiles/mono-mac-xamarin/build-root/mono-3.10.0/mcs/class/System.Core/System.Linq/Enumerable.cs:2445
  at Xamarin.ApiDiff.MemberComparer.Find (IEnumerable`1 target) [0x00019] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/MemberComparer.cs:72
  at Xamarin.ApiDiff.MemberComparer.Compare (IEnumerable`1 source, IEnumerable`1 target) [0x0003c] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/MemberComparer.cs:83
  at Xamarin.ApiDiff.MemberComparer.Compare (System.Xml.Linq.XElement source, System.Xml.Linq.XElement target) [0x000a2] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/MemberComparer.cs:55
  at Xamarin.ApiDiff.ClassComparer.Modified (System.Xml.Linq.XElement source, System.Xml.Linq.XElement target) [0x0005b] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/ClassComparer.cs:210
  at Xamarin.ApiDiff.Comparer.Compare (IEnumerable`1 source, IEnumerable`1 target) [0x00093] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/Comparer.cs:80
  at Xamarin.ApiDiff.ClassComparer.Compare (System.Xml.Linq.XElement source, System.Xml.Linq.XElement target) [0x00055] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/ClassComparer.cs:67
  at Xamarin.ApiDiff.NamespaceComparer.Modified (System.Xml.Linq.XElement source, System.Xml.Linq.XElement target) [0x0001a] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/NamespaceComparer.cs:75
  at Xamarin.ApiDiff.Comparer.Compare (IEnumerable`1 source, IEnumerable`1 target) [0x00093] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/Comparer.cs:80
  at Xamarin.ApiDiff.NamespaceComparer.Compare (System.Xml.Linq.XElement source, System.Xml.Linq.XElement target) [0x00055] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/NamespaceComparer.cs:49
  at Xamarin.ApiDiff.AssemblyComparer.Modified (System.Xml.Linq.XElement source, System.Xml.Linq.XElement target) [0x0002b] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/AssemblyComparer.cs:70
  at Xamarin.ApiDiff.Comparer.Compare (IEnumerable`1 source, IEnumerable`1 target) [0x00093] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/Comparer.cs:80
  at Xamarin.ApiDiff.AssemblyComparer.Compare () [0x0004a] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/AssemblyComparer.cs:50
  at Xamarin.ApiDiff.Program.Main (System.String[] args) [0x00328] in /Users/builder/data/lanes/macios-mac-master/177810cb/source/mono/mcs/tools/corcompare/mono-api-html/ApiDiff.cs:164
2015-01-28 14:17:17 +01:00
Alex Rønne Petersen 416cbef8d8 [mini] Recognize and optimize Thread.VolatileRead ()/VolatileWrite (). 2015-01-28 13:30:57 +01:00
Alex Rønne Petersen 90d942e1c5 [mini] Recognize and optimize the new 4-parameter CAS overload. 2015-01-28 11:57:06 +01:00
Alex Rønne Petersen 9f3f9b174c [corlib] Add a new generated test file to .gitignore. 2015-01-28 11:57:06 +01:00
Jo Shields 559b0b2c67 Missing bracket from 8b10cef3 2015-01-28 10:50:32 +00:00
Marek Safar d5febd5365 [mdoc] update expected delegate exceptions 2015-01-28 10:07:15 +01:00
Zoltan Varga e5d76a7074 [amd64] Add 32bit fp codegen macros. 2015-01-27 20:25:56 -05:00
Rodrigo Kumpera 417fc5e789 [runtime] Cleanup networking init/shutdown code. 2015-01-27 18:35:38 -05:00
Rodrigo Kumpera 8b10cef344 [utils] Cleanup the dynamic loading code and split the platform specific code into multiple files.
This makes the actual code much simpler to read and work with as we can clearly see what's done on each
target.
2015-01-27 17:59:33 -05:00
Zoltan Varga 69dc4238a2 Merge pull request #1530 from StephenMcConnel/bug-26478
Fix TextBox display to handle kerning fonts
2015-01-27 16:47:24 -05:00
Stephen McConnel 3280b20650 Fix TextBox display to handle kerning fonts
Many fonts, including the default DejaVu Sans, use kerning between
certain character pairs.  This resulted in garbled or even invisible
display during typing of strings with a lot of kerning going on.  An
attempt is made to retain the current speed-optimized implementation
while using accurate, slower string width measurements when needed.
See https://bugzilla.xamarin.com/show_bug.cgi?id=26478 for details.
2015-01-27 15:40:11 -06:00
Marcos Henrich 81af7de23d [symbolicate] Makefile fixes. 2015-01-27 18:54:18 +00:00
Zoltan Varga ec1244784c Add tools/symbolicate to the build. 2015-01-27 13:49:30 -05:00
Marek Safar 6a0b61634d [corlib] Remove redundant checks from delegate::combine 2015-01-27 19:46:55 +01:00
Zoltan Varga d2ec22099a [sdb] Avoid errors when a vtype method is invoked with the InvokeOptions.Virtual flag set. 2015-01-27 13:09:59 -05:00
Marek Safar 0d1f48b9e1 [mcs] Fix type inference fixing to filter all candidates 2015-01-27 18:53:17 +01:00
Atsushi Eno 057623eb7c Merge pull request #1529 from alistair/xmlreader_read_to_next_sibling_bug
XmlReader.ReadToNextSibling(string) doesn't match .net behaviour
2015-01-28 01:04:26 +08:00
Marek Safar a24bb201eb Revert referencesource change from 9ac4b5b7a7 2015-01-27 17:58:29 +01:00
Marek Safar 52a93b2dbb Revert to broken scope reference indexing 2015-01-27 17:58:29 +01:00
Marcos Henrich 0e3f9853ac [symbolicate] Added target check to Makefile.
Target check verifies that symbolicate is capable of returning a debug stacktrace from a release stackframe.
2015-01-27 16:25:16 +00:00
Alistair Bush aba3b1a915 Unit test for reproduction of XmlReader.ReadToNextSibling behaviour 2015-01-28 04:17:52 +13:00
Marek Safar 3abac7458e Update ikvm 2015-01-27 16:14:54 +01:00
João Matos b655fb35c6 [runtime] Fixed MONO_STRUCT_OFFSET to work with non-cross builds. 2015-01-27 15:06:08 +00:00
Alex Rønne Petersen 157db2ae27 [corlib] Switch to reference source System.Threading.SpinLock. 2015-01-27 13:05:28 +01:00
Alex Rønne Petersen 4f5195edd2 [mini] Make intrinsic method signature checks more robust.
This is so we can avoid miscompiling things left and right
when new overloads are added. For example, before this patch,
we miscompiled the new 4-parameter CAS () overload.
2015-01-27 13:05:28 +01:00
Marcos Henrich 951299ddae test_op_il_seq_point.sh now properly generates tmp files. 2015-01-27 10:59:14 +00:00
Marcos Henrich b457329942 test_op_il_seq_point.sh now calls mono with option --compile-all=1
Calling mono with flag --compile-all=1 avoids running the code and possible stdout problems and it also compiles every method.
As test_op_il_seq_point.sh now only compiles it is now capable of testing libraries and executables that are expecting parameters.
2015-01-27 09:37:48 +00:00
Zoltan Varga 2140250e4f [corlib] Wait for tasks to finish in some Tasks tests to prevent races between tests. 2015-01-26 19:59:06 -05:00
Vlad Brezae 8b914ca48b When map size is 0, use the aligned size of the file.
As MS does.
2015-01-26 15:08:15 -08:00
Vlad Brezae 08f78b1615 Fail on mappings that exceed the file size.
As MS does.
2015-01-26 15:08:14 -08:00
Vlad Brezae 495cd1500b Fix handling of mappings over file size.
Add tests.
2015-01-26 15:08:14 -08:00
Vlad Brezae 3f81926327 Fix truncation of newly created map files.
File truncation could skip due to the fact that st_size field is only initialized for already existing files.
2015-01-26 15:06:53 -08:00
Zoltan Varga 85d7771306 [sdb] Avoid errors when a static method is invoked with the InvokeOptions.Virtual flag set. 2015-01-26 17:59:32 -05:00
Rodrigo Kumpera 89ed7a9018 [runtime] Check for sigaction been present when trying to use signals. 2015-01-26 16:30:43 -05:00
Rodrigo Kumpera b3a4976b6d [utils] Explicitly check if the system has mincore instead of relying on mmap been present. 2015-01-26 16:30:42 -05:00
Zoltan Varga b97979906b [runtime] Add infrastructure code for getting/setting Thread.Priority. 2015-01-26 15:13:46 -05:00
Rodrigo Kumpera 9ac4b5b7a7 [runtime] Introduce MonoError into mono_metadata_parse_method_signature_full. 2015-01-26 14:50:36 -05:00
Rodrigo Kumpera a4188b73cd Fix loader error <> MonoError interop. 2015-01-26 14:26:18 -05:00
Marek Safar 3632d51916 [corlib] Report constructor ContainsGenericParameters by inspecting parent type. Fixes #26412 2015-01-26 18:12:00 +01:00
Marek Safar 8fcdfeda92 Update reference sources to correctly fix #26375 2015-01-26 17:41:53 +01:00
Alex Rønne Petersen 1a858cbfbd [runtime] Use MonoBoolean in icall signature, not gboolean. 2015-01-26 17:14:51 +01:00
João Matos 20eb41f97a [runtime] Fixed the iOS build.
Failure caused by https://github.com/mono/mono/commit/2f1b464beb14a1b6b6099a03fc332493293bef35.

```
../../../../../mono/mono/utils/mono-proclib.c:104:8: error: use of undeclared identifier 'errno'
                        if (errno != ENOMEM)
                            ^
../../../../../mono/mono/utils/mono-proclib.c:104:17: error: use of undeclared identifier 'ENOMEM'
                        if (errno != ENOMEM)
```
2015-01-26 14:59:39 +00:00
João Matos b52a468f49 Partial revert of "Fixes mobile build"
This reverts commit 4d3877d23b.

We cannot remove this file as the build logic is expecting it since we override it from mono-extensions.

```System/Guid.cs(42,7): error CS0246: The type or namespace name `Crimson' could not be found. Are you missing an assembly reference?```
2015-01-26 14:59:39 +00:00
Marek Safar fc81c9a972 Revert corlib changes from 268627a68b 2015-01-26 15:50:58 +01:00
Marek Safar 268627a68b [mcs] Emit catch scope with correct start offset. Also fixes local variable scope index reference. Fixes #25358 2015-01-26 15:46:03 +01:00
Alex Rønne Petersen 506d405b98 Fixup for 2644152b06.
Accidentally committed an incomplete patch.
2015-01-26 14:11:20 +01:00
Marek Safar b3c4d9d786 Merge pull request #1521 from esdrubal/fshandle
[corlib] FileStream now uses SafeFileHandle.
2015-01-26 13:46:05 +01:00
Marcos Henrich 7a81fd5b30 [corlib] FileStream now uses SafeFileHandle.
FileStream now stores a SafeFileHandle instead of a IntPtr handle.
Added ObjectDisposedException to more methods.
2015-01-26 12:27:44 +00:00
Marcos Henrich 753229c72d [corlib] Changed some MonoIO methods to use SafeHandle. 2015-01-26 12:27:42 +00:00
João Matos 6c65d62a14 [System] Fixed mobile build. 2015-01-26 12:03:17 +00:00
Jo Shields cd9db9cb45 Merge pull request #1525 from akoeplinger/fix-dynamicdata-test
[System.Web.DynamicData] Fix MetaColumnTest.Attributes() test
2015-01-26 10:31:36 +00:00
Alex Rønne Petersen 33e5da7a47 Revert "[runtime] Fix getting main thread's stack size with musl."
This reverts commit 67d84faecb.

This is not enough on its own to fix sigaltstack support with musl.
2015-01-26 07:11:51 +01:00
Alex Rønne Petersen 67d84faecb [runtime] Fix getting main thread's stack size with musl.
See the code for an explanation of this mess.
2015-01-25 16:14:23 +01:00
Alexander Köplinger cb3835ba9e [System.Web.DynamicData] Fix MetaColumnTest.Attributes() test
It started failing when code from MS referencesource was imported.
I checked on MS.NET and the list of attributes is now the same on Mono
(except an additional __DynamicallyInvokableAttribute on MS.NET).
2015-01-25 15:05:16 +01:00
Alex Rønne Petersen 36589008a4 [runtime] Fix build when using musl libc. 2015-01-25 08:30:34 +01:00
Zoltan Varga 1d5f1c4760 Merge pull request #1522 from StephenMcConnel/bug-26258
Fix occasional rendering problem in TextBoxes
2015-01-24 22:10:10 -05:00
Zoltan Varga 2f1b464beb [runtime] Avoid failures in Process.GetProcesses () when the number of processes is above 400. Fixes #26382. 2015-01-24 21:14:53 -05:00
Zoltan Varga b21fe11d6c [runtime] Allow spaces after commas in generic instances passed in Type.GetType (). Fixes #26384. 2015-01-24 19:22:54 -05:00
Zoltan Varga f342649f75 [jit] Properly inflate method signatures used in CEE_NEWOBJ opcodes. Fixes #26346. 2015-01-24 19:11:11 -05:00
Marek Safar 4d3877d23b Fixes mobile build 2015-01-24 09:25:35 +01:00
Alex Rønne Petersen 94a922305a [mini] Fix setting stack type for some atomic instructions.
Fixes some assertion failures introduced by 78141114e3.
2015-01-24 08:47:10 +01:00
Zoltan Varga 0efa5704f4 Fix the build. 2015-01-23 20:13:05 -05:00
Alex Rønne Petersen 4d24ccadc6 [mini] Implement OP_MEMORY_BARRIER on MIPS. 2015-01-24 01:08:02 +01:00
Alex Rønne Petersen f457dee224 [mini] Fix CAS atomic ordering under LLVM.
AcquireRelease [0] and SequentiallyConsistent [1] are not equivalent.

[0] http://llvm.org/docs/Atomics.html#acquirerelease
[1] http://llvm.org/docs/Atomics.html#sequentiallyconsistent
2015-01-24 01:08:02 +01:00
Alex Rønne Petersen c118dae7d3 [mini] Add atomic load/store instruction definitions for ARM64. 2015-01-24 01:08:02 +01:00
Alex Rønne Petersen 5bf4ab138d [mini] Implement atomic load/store instructions on ARM. 2015-01-24 01:08:02 +01:00
Alex Rønne Petersen 52bfd89d96 [mini] Implement atomic load/store instructions on x86. 2015-01-24 01:08:02 +01:00
Alex Rønne Petersen c25ff177fd [mini] Implement atomic load/store instructions on AMD64. 2015-01-24 01:08:01 +01:00
Alex Rønne Petersen df625319bb [mini] Implement atomic load/store opcodes in the LLVM backend.
Requires a newer Mono LLVM fork and is only enabled on MONO_API_VERSION >= 4.
2015-01-24 01:08:01 +01:00
Alex Rønne Petersen 3198e62024 [mini] Add new atomic load/store opcodes with acq/rel/seq semantics.
These are emitted by recognizing Interlocked and Volatile methods. They allow
us to generate more efficient instruction sequences on certain architectures
(e.g. ARM64 which has specialized load-acquire and store-release instructions).
2015-01-24 01:08:01 +01:00
Alex Rønne Petersen 78141114e3 [mini] Also match Interlocked.Exchange<T> () in mono_method_to_ir (). 2015-01-24 01:08:01 +01:00
Alex Rønne Petersen e901b3377c [mini] Memory barrier fixes, simplifications, and optimizations.
* Barrier semantics is now specified as acquire, release, and sequentially
  consistent. This is in line with CIL/.NET semantics and also maps better to
  LLVM's fence types.
* Use the mfence instruction for memory barriers on AMD64 as it's smaller
  (and presumably also faster).
* We now emit specific barriers when using LLVM instead of always emitting
  sequentially consistent barriers.
* Barriers emitted for the CIL volatile prefix instruction are now more
  specific instead of always being sequentially consistent.
* Fixed emission of CEE_MONO_MEMORY_BARRIER in SGen's managed allocators. For
  some reason (that I haven't had time to look into), mono_mb_emit_op ()
  clobbers the barrier kind operand. This meant that in many cases we ended
  up not actually emitting any barriers because the switches in the backends
  didn't handle the clobbered values. mono_mb_emit_i4 () seems to work.
* Fixed handling of CEE_MONO_MEMORY_BARRIER in mono_method_to_ir (). Since it's
  a custom opcode, the opcode is actually 2 bytes long. Another source of
  barriers not actually being emitted.
2015-01-24 01:08:01 +01:00
Alex Rønne Petersen 2644152b06 Add an internal Interlocked.CompareExchange () icall overload needed by MS BCL. 2015-01-24 01:08:01 +01:00
Martin Baulig 3bcd0eb9de Bump referencesource to un-break Xamarin Studio.
See https://bugzilla.xamarin.com/show_bug.cgi?id=26375.
2015-01-24 00:48:16 +01:00
João Matos be92f03550 [runtime] Get Mono's LLVM API version from the LLVM repo when cross compiling.
The previous code was hardcoding Mono's LLVM API version which was less than ideal. The API has been bumped twice since without this being updated.

This depends on a recent Mono LLVM version, at least https://github.com/mono/llvm/commit/607aeaae423da73e6ddfe49af4741fa1bc5f9e78.
2015-01-23 16:46:32 +00:00
João Matos 6d17bd5611 [mini] Include signal.h in mini.c.
This fixes Monodroid cross build, which broke with https://github.com/mono/mono/commit/adca49cdd28e7c7b0cc65073167c143cc5f52fdd.

Error:

```
/Users/joao/Dev/droid/mono/mono/mini/mini.c:6645:31: note: each undeclared identifier is reported only once for each function it appears in
/Users/joao/Dev/droid/mono/mono/mini/mini.c: In function 'mono_sigsegv_signal_handler':
/Users/joao/Dev/droid/mono/mono/mini/mini.c:6704:31: error: 'SIGSEGV' undeclared (first use in this function)
   mono_handle_native_sigsegv (SIGSEGV, ctx, info);
```
2015-01-23 16:41:16 +00:00
João Matos 73292633fc [runtime] Check for signal.h when targeting Win32.
This fixes Monodroid cross build, which broke with https://github.com/mono/mono/commit/adca49cdd28e7c7b0cc65073167c143cc5f52fdd.
2015-01-23 16:40:07 +00:00
Marek Safar a09f7c6f7b Revert "[System] Remove network interface operational status test."
This reverts commit 519582150d.
2015-01-23 13:46:49 +01:00
Marek Safar a4a6ad39f8 [corlib] Add more tests 2015-01-23 13:46:26 +01:00
João Matos 519582150d [System] Remove network interface operational status test.
This test is proving to be problematic since the status of interfaces can be different on OSs.
2015-01-23 12:38:41 +00:00
Marek Safar b18af252e9 Fixes 579084d1f7 commit 2015-01-23 13:21:15 +01:00
Marek Safar dc462a850b [corlib] Increase timeout of failing test 2015-01-23 11:45:42 +01:00
Marcos Henrich 92f04b8636 [corlib] Added tests for FileStream SafeHandle. 2015-01-23 10:41:53 +00:00
Marek Safar 140d6e440c [system] Implement Android specific domain name. Fixes #26305 2015-01-23 11:23:10 +01:00
Marek Safar 579084d1f7 [system] Fixes failing test 2015-01-23 11:08:28 +01:00
Marek Safar 772c45aaf9 Revert "[corlib] StringBuilder from reference sourcers"
This reverts commit ef6b35a009.
2015-01-23 10:42:06 +01:00
Marek Safar ef6b35a009 [corlib] StringBuilder from reference sourcers 2015-01-23 10:24:10 +01:00
Zoltan Varga 5090e3557a [sdb] Move the checking of the various debugger attributes to one function to make it easier to add support for DebuggerStepperBoundaryAttribute. 2015-01-22 18:44:39 -05:00
Martin Baulig 335258b147 [System]: Add new internal Socket APIs. 2015-01-22 23:10:56 +01:00
Zoltan Varga 879cd1bed1 [runtime] Add a preliminary mono support mode for lldb. Currently, pretty printing some runtime types is supported. 2015-01-22 16:42:56 -05:00
Zoltan Varga af7a963fc0 [runtime] Use the new one parameter ctor to create RuntimeWrappedException objects. 2015-01-22 16:01:49 -05:00
Marek Safar 066bbf8b21 [corlib] Remove current timezone specific tests 2015-01-22 15:55:08 -05:00
Marek Safar f30d7e21a8 [Microsoft.Build.BuildEngine] Update failing test 2015-01-22 21:33:53 +01:00
Martin Baulig f0abad3748 Bring Internal.cs, Logging.cs and _LoggingObject.cs. 2015-01-22 20:28:10 +01:00
Martin Baulig c7d14ed7d8 Fix KeyContainerPermission.SetFlags(). 2015-01-22 20:27:07 +01:00
Martin Baulig 5311437f06 Make TraceSource.GetSupportedAttributes() "protected internal". 2015-01-22 20:26:59 +01:00
Martin Baulig dcfd3f23d1 The class needs to be called `FriendAccessAllowedAttribute'. 2015-01-22 20:26:52 +01:00
Mark Probst 14eda7354d [sgen] MONO_GC_DEBUG options to not run finalizers. 2015-01-22 14:04:00 -05:00
Stephen McConnel e62a37d332 Fix occasional rendering problem in TextBoxes
See https://bugzilla.xamarin.com/show_bug.cgi?id=26258 for details.
2015-01-22 12:26:42 -06:00
Zoltan Varga a9af48a4a6 Fix the build. 2015-01-22 12:27:03 -05:00
Zoltan Varga 412f680e56 [runtime] Make RuntimeWrappedExceptions work with the new reference source version of RuntimeWrappedException. 2015-01-22 12:20:26 -05:00
Martin Baulig 20d845ca07 Merge pull request #1156 from felfert/master
Fixed Bug #21135 - Deadlock in WebConnectionStream
2015-01-22 17:21:24 +01:00
Marek Safar 7c3c908458 [corlib] referencesources update 2015-01-22 17:04:26 +01:00
Crisdut 7c39ab701b Add unit test for the bug #1849 2015-01-22 15:41:59 +00:00
Crisdut 8098123ec2 Fix the bug #1849 2015-01-22 15:41:59 +00:00
Marek Safar ea6a13d413 Remove unused files 2015-01-22 16:05:40 +01:00
Marek Safar 5352329186 [corlib] Calendars from reference sources 2015-01-22 16:05:40 +01:00
Marek Safar 346894957c [corlib] generic collections from reference sources 2015-01-22 16:05:40 +01:00
Marek Safar 585c1278cb Merge pull request #1520 from madrang/SafeHandleFix
Small fix for SafeHandle Disposing
2015-01-22 11:33:04 +01:00
Neale Ferguson c9722940db Add memory barrier support using BCR 14,0 2015-01-22 05:12:17 -05:00
Marc-Andre Ferland b4776f20c7 Small fix for SafeHandle Disposing 2015-01-22 01:55:01 -05:00
Zoltan Varga 0c4cc7160a Merge pull request #1518 from akoeplinger/remove-only-net11-ifdef
[bcl] Remove ONLY_1_1 defines from class libs
2015-01-21 23:08:47 -05:00
Zoltan Varga 6cf56cbb2f [amd64] Fix r8->int conversions. Fixes #26219. 2015-01-21 15:00:06 -05:00
Zoltan Varga 03724e8d79 [arm64] Add a test for vtypebyref parameters in gsharedvt trampolines. 2015-01-21 13:48:12 -05:00
Zoltan Varga e478ab8364 Merge pull request #1519 from akoeplinger/remove-net35-ifdef
[bcl] Remove NET_3_5 defines from class libs
2015-01-21 12:53:56 -05:00
Alexander Köplinger 2a978a42f1 [bcl] Remove NET_3_5 defines from class libs 2015-01-21 17:59:27 +01:00
Alexander Köplinger d4d7374efc [bcl] Remove ONLY_1_1 defines from class libs
This is not used anymore.
2015-01-21 17:18:30 +01:00
João Matos 1e25d67aef [runtime] Fix sigsev signal handler Win32 build.
This was broken by: https://github.com/mono/mono/commit/45704daf22d1cec17851ce011ee391137932c471
2015-01-21 13:06:33 +00:00
João Matos c28e73de04 Merge pull request #1517 from akoeplinger/fix-network-test
[System] Skip loopback interfaces in the FirstInterfaceOperationalStatus() test
2015-01-21 12:27:39 +00:00
Marek Safar 50f2b63442 [corlib] Contracts and CompilerServices from reference sources 2015-01-21 11:46:03 +01:00
Marek Safar 4fd0f05f66 [corlib] Fixes more SafeHandle failing tests 2015-01-21 11:46:03 +01:00
Marek Safar 018e826d47 Merge pull request #1502 from madrang/SafeHandle.CloseTestDispose
Test that closing handle will release managed resource by calling Dispose
2015-01-21 09:11:28 +01:00
Marek Safar 912dda4613 Merge pull request #1504 from madrang/SafeHandle.SetInvalidRelease
Allows refs to be released after the handle is set as invalid.
2015-01-21 09:11:12 +01:00
Rodrigo Kumpera ebfa2d2b40 [runtime] Remove debug spew. 2015-01-20 15:31:21 -05:00
Zoltan Varga 76558bd382 Merge pull request #1516 from DavidKarlas/getThreadsHang
[sdb] Fixed GetThreads deadlock if thread was started or stopped during GetThread
2015-01-20 15:01:20 -05:00
Rodrigo Kumpera 75a4c28352 [runtime] Introduce mono_ldtoken_check and replace usage of the unchecked one with it. 2015-01-20 12:50:50 -05:00
Rodrigo Kumpera 6a348cfc32 [runtime] Weave MonoError into method_from_method_def_or_ref. 2015-01-20 12:50:50 -05:00
Rodrigo Kumpera 7650568113 [runtime] mono_type_create_from_typespec is no longer used by the runtime, it doesn't need to create a loader error. 2015-01-20 12:50:50 -05:00
Rodrigo Kumpera 4bb01e4a2d [runtime] Remove last usage of mono_class_get. Moving it and its _full variant to the bad to call set. 2015-01-20 12:50:50 -05:00
Rodrigo Kumpera 53424f1fae [runtime] Weave MonoError in mono_metadata_interfaces_from_typedef_full. 2015-01-20 12:50:49 -05:00
Rodrigo Kumpera b2c5eaba5d [runtime] Weave MonoError into more of the loader code. 2015-01-20 12:50:49 -05:00
Rodrigo Kumpera cd4a89e234 [runtime] Add more error checking. 2015-01-20 12:50:49 -05:00
Rodrigo Kumpera e9fc37d44e [runtime] Introduce the usage of mono_class_get_checked in most of the runtime. 2015-01-20 12:50:49 -05:00
Rodrigo Kumpera 027609046e [runtime] Explicitly call mono_class_setup_methods to fail types with bad methods. 2015-01-20 12:50:49 -05:00
Rodrigo Kumpera 047116c246 [runtime] Introduce mono_get_method_checked. 2015-01-20 12:50:48 -05:00
Rodrigo Kumpera 5995bb0ccb [runtime] switch to checked variant of mono_get_method_constrained. 2015-01-20 12:50:48 -05:00
Rodrigo Kumpera b8775906b1 [runtime] Introduce mono_get_method_constrained_checked. 2015-01-20 12:50:48 -05:00
Rodrigo Kumpera a40ade5fef [runtime] mono_get_method_constrained_with_method now uses MonoError. 2015-01-20 12:50:48 -05:00
Rodrigo Kumpera 6d09e35a0f [runtime] Introduce MonoError into get_method_constrained. 2015-01-20 12:50:47 -05:00
Rodrigo Kumpera 396d0623ad [runtime] Fix a loader error leakage. 2015-01-20 12:50:47 -05:00
Rodrigo Kumpera 8e18aca8cf [runtime] Introduce MonoError into mono_get_method_from_token. 2015-01-20 12:50:47 -05:00
Rodrigo Kumpera 20526d840d [runtime] Move the runtime to use the checked variants of mono_class_inflate_generic_method. 2015-01-20 12:50:47 -05:00
Rodrigo Kumpera 0a159bb035 [runtime] Move method_from_methodspec to use MonoError. 2015-01-20 12:50:46 -05:00
Rodrigo Kumpera a0056ed85b [runtime] Make method_from_memberref use MonoError. 2015-01-20 12:50:46 -05:00
Marek Safar d13b92edb1 [System] Extract NetworkInterface factory and implement LoopbackInterfaceIndex for more platforms 2015-01-20 15:04:32 +01:00
Marek Safar 2c472f0670 Merge pull request #1513 from akoeplinger/remove-net20-ifdefs
[bcl] Remove more NET_2_0 checks from class libs
2015-01-20 13:29:40 +01:00
Marek Safar 52cace8bb5 [corlib] Update System.Numeric mobile public key 2015-01-20 13:25:55 +01:00
Marek Safar 191cde43ad [System.Numerics] Update to latest mscorlib 2015-01-20 13:09:43 +01:00
Marek Safar 429fd07df8 [corlib] Primitive types from reference sources 2015-01-20 12:23:29 +01:00
David Karlaš 948689360b [sdb] Fixed GetThreads deadlock if thread was started or stopped during GetThreads call.
Regression introduced in 52b168e336
2015-01-20 11:29:44 +01:00
Zoltan Varga 7ef5dfed95 [sgen] Disable PREFETCH_CARDS when using xcode4 as it causes gcc to crash. 2015-01-19 17:06:43 -05:00
Marek Safar c1a50591da [corlib] Fixed failing covert test 2015-01-19 22:38:49 +01:00
Marek Safar cde677dbaf [corlib] Add more convert checks 2015-01-19 19:50:36 +01:00
Mark Probst abc0bc6fbe [sgen] Fix clearing ephemerons and weak links on domain unload.
At some point we zeroed all the unloaded domain's objects first, and then we cleared
weak links, ephemerons, etc.  Because the objects were zeroes, we only had to
check that the vtable was null.  Now we do it the other way around: clear weak links,
ephemerons, ..., and then zero objects.  Obviously we now need to check for the
object's domain, because their vtables will not be null.
2015-01-19 09:57:23 -08:00
Marek Safar 6f802b490c [corlib] Fixes ToDateTime for primitive types 2015-01-19 16:23:03 +01:00
Marek Safar 519ddb9895 [corlib] Char from reference sourcers 2015-01-19 16:23:03 +01:00
João Matos 435f968102 [runtime] Workaround missing net/route.h in iOS SDK. 2015-01-19 15:07:49 +00:00
Marek Safar c5e4cfc9fb [corlib] More system types from reference sources 2015-01-19 14:07:53 +01:00
Marek Safar 9aefc2627b [corlib] Type's GetInterfaceMap has no implementation 2015-01-19 14:07:53 +01:00
Marek Safar 8c41fbe08f [runtime] Remove Convert icalls 2015-01-19 14:07:53 +01:00
João Matos 396d9dbeb1 Merge pull request #1404 from woodsb02/mono-route
Add mono/metadata/mono-route.c for non-Linux ParseRouteInfo_local
2015-01-19 12:53:56 +00:00
Marek Safar 66a679268c [corlib] System.Convert from reference sources 2015-01-19 11:14:04 +01:00
Alexander Köplinger ff71a0fa40 [System] Skip loopback interfaces in the FirstInterfaceOperationalStatus() test
The status of loopback interfaces is always 'Unknown' on Linux.
This fails the test so we need to skip them.
2015-01-19 10:30:29 +01:00
Ben Woods 1e0c63e953 Add mono/metadata/mono-route.c for non-Linux ParseRouteInfo_local
Add #ifdef to ignore code in mono/metadata/mono-route.c if OS=linux
Also remove mono-route.c from msvc/libmonoruntime.vcxproj (Windows)

Add #ifdef to ensure mono/metadata/mono-route.h code is not included
on Linux

Change to using #if defined(PLATFORM_MACOSX) || defined(PLATFORM_BSD)

Use sizeof(addr) for maximum length of IP address string, instead of the hard-coded 16.
Should the size of addr ever change it will keep us from disaster in case if shrinking the array length.
Also, do not ignore snprintf return value - check for truncated output and act accordingly if it happens.

Add Tests for System.Net.NetworkInformation/IPInterfacePropertiesTest.cs and System.Net.NetworkInformation/NetworkInterfaceTest.cs

Remove accidental Copyright

add a space before the opening parenthesis, as shown in the coding guidelines.

Indent TestFixture to align with coding style of newer Test classes

Use G_N_ELEMENTS(mib) instead of sizeof(mib) / sizeof(mib[0])
2015-01-19 07:05:32 +08:00
Zoltan Varga a3f3abf8fd [arm64] Add a test for r4 hfa parameter passing in gsharedvt trampolines. 2015-01-18 11:32:22 -05:00
Zoltan Varga 12f36fd126 [arm64] Add a test for hfa parameter passing in gsharedvt out trampolines (#26085). 2015-01-17 20:29:05 -05:00
Zoltan Varga aeb7813213 [runtime] Fix aot-tests.cs. 2015-01-17 20:13:35 -05:00
Zoltan Varga 25246e4c3b [arm64] Add tests for dyn calls with floats. 2015-01-17 15:55:20 -05:00
Zoltan Varga 8cd6feb66b [arm64] Increase the size of the dyn_call instruction, and the buffers used during dyn calls. 2015-01-17 15:55:19 -05:00
David Karlaš eb29fb3fa4 [sdb] ILInterpreter handle Br_S same as Br 2015-01-17 17:02:30 +01:00
David Karlaš 6953d781cd [sdb] Fix deadlock in case of runtime disconnect while fetching frames(Bug 24434) 2015-01-17 16:24:30 +01:00
Alexander Köplinger 746650d1b9 [bcl] Remove more NET_2_0 checks from class libs 2015-01-17 05:45:39 +01:00
Miguel de Icaza 7d1cd56c5d [System] ComponentModel, make it build in the MOBILE profile 2015-01-16 20:20:26 -05:00
Zoltan Varga 43a9f2af11 [bcl] Fix System.Threading.Tasks.Dataflow tests. 2015-01-16 19:49:00 -05:00
Mark Probst 9daffb747a [sgen] Fix a concurrent collector bug.
Pinning is done in the worker thread, but reset in the main thread.
The main thread must wait for the worker jobs to finish until it can
reset pinning.  We didn't do this before.
2015-01-16 16:00:11 -08:00
Zoltan Varga d929a5d9ae Merge pull request #1511 from akoeplinger/windows
[utils] Extract Windows-specific networking fallback into networking-windows.c
2015-01-16 17:26:34 -05:00
Zoltan Varga ba6d6d74cd [bcl] Fix the serialization of string arrays to IEnumerable<string> in the Json serializer. Fixes #25808. 2015-01-16 14:11:51 -05:00
Marek Safar 014e3493b1 [System.Threading.Tasks.Dataflow] update atomicboolen location 2015-01-16 19:20:48 +01:00
Marek Safar a844019685 [system.core] TaskExtensions from reference source 2015-01-16 19:01:40 +01:00
Marek Safar 8fa4f20578 Another build fix 2015-01-16 18:33:09 +01:00
Marek Safar dc95e23048 Fixes build 2015-01-16 18:23:34 +01:00
Rodrigo Kumpera 45704daf22 [jit] Adjust the sigsegv handle to accomodate targets without siginfo. 2015-01-16 12:16:36 -05:00
Rodrigo Kumpera adca49cdd2 [jit] First pass of portability fixes for the JIT. 2015-01-16 12:16:36 -05:00
Marek Safar 5a6e9cc4eb [corlib] USe more types from System.Threading reference sources 2015-01-16 18:04:05 +01:00
Marek Safar de222aa4be [System.Core] System.Collections.Generic from reference sources 2015-01-16 16:55:36 +01:00
Marek Safar 2c439a5b84 [System.ServiceModel.Web] Update failing test 2015-01-16 16:32:03 +01:00
Alexander Köplinger e1010a2e35 [utils] Extract Windows-specific networking fallback into networking-windows.c 2015-01-16 16:23:48 +01:00
Marek Safar 061d7f3fb1 [system.xml] Fix broken ClassMap logic which relied on order of hashtable elements 2015-01-16 16:21:22 +01:00
Marek Safar b8d0752d82 [system.web] Update SqlDataSource test not to rely on idictionary order 2015-01-16 09:58:00 +01:00
Marek Safar 49721c35af [WindowsBase] Fix incorrect test 2015-01-16 09:11:28 +01:00
Zoltan Varga 9661a1fba0 [runtime] Fix the build. 2015-01-15 19:17:19 -05:00
Zoltan Varga 3a4c4766fa [sdb] Fix single stepping after a SetIP operation. Fixes #26033. 2015-01-15 19:13:27 -05:00
Vlad Brezae 098121114a Don't truncate the file to the page aligned size.
The second open attempt at opening would fail due to the capacity being smaller than the file size.
2015-01-15 15:27:50 -08:00
Miguel de Icaza 3619fe9c4c [Mono.Posix] Add overloads to pass ints and pointers 2015-01-15 18:22:58 -05:00
Zoltan Varga aae77596bf [sdb] Rename 'restore_ctx' to 'restore_state' and change its type to MonoThreadUnwindState. 2015-01-15 17:33:10 -05:00
Marek Safar 76ad4fb9fe [corlib] fixing TPL integration 2015-01-15 23:24:49 +01:00
Marek Safar 30ee7c53a4 [system] update failing tests 2015-01-15 23:13:36 +01:00
Ludovic Henry 9ac10ff321 [TPL] Replace implementation by Microsoft reference sources 2015-01-15 16:05:51 -05:00
Rodrigo Kumpera 18751d4475 Merge pull request #1458 from BrzVlad/feature-fat-cas
Poll-free fat locks
2015-01-15 14:54:12 -06:00
Zoltan Varga 5084172643 [runtime] Remap io-layer symbols using the prefix wapi_. Fixes #25821. 2015-01-15 15:07:56 -05:00
Zoltan Varga b27d024877 Fix a warning. 2015-01-15 14:42:01 -05:00
Martin Baulig e129937283 [Mono.Security]: More exception debug foo.
Note: This patch may cause some ugly exception messages.  This is intended to help
us debug and hopefully fix bug #19334.
2015-01-15 19:08:46 +01:00
Martin Baulig 8670be04bf [Mono.Security]: Test suite - we may not throw IOException as well here.
In fact, we should not ever throw ObjectDisposedException, but provide a
meaningful IOException.  Still working on it.
2015-01-15 17:53:57 +01:00
Martin Baulig 60bd02c236 [Mono.Security]: Fix TLS Alert level." This breaks the System test suite.
Prevent further abuse (calling it before the fields have been assigned to)
by making the helper function static.
2015-01-15 17:53:57 +01:00
João Matos d065c31a24 [msvc] Fixed the build. 2015-01-15 16:21:48 +00:00
Rodrigo Kumpera e50db21610 Revert "[Mono.Security]: Improve error reporting when sending TLS Alerts fail."
This reverts commit 95eff24950.
2015-01-15 11:04:32 -05:00
Rodrigo Kumpera 9b04cd4d29 Revert "[Mono.Security]: Fix TLS Alert level." This breaks the System test suite.
This reverts commit a036a6bf18.
2015-01-15 10:57:58 -05:00
Zoltan Varga 34f074e4fa Merge pull request #1507 from DavidKarlas/mdbRead0Line
[sdb] Fixed .mdb parsing when line equals 0
2015-01-15 10:39:55 -05:00
Marek Safar 46bdea893b [corlib] System.Collections from reference sources 2015-01-15 16:16:42 +01:00
Martin Baulig a036a6bf18 [Mono.Security]: Fix TLS Alert level. 2015-01-15 13:23:10 +01:00
Martin Baulig 95eff24950 [Mono.Security]: Improve error reporting when sending TLS Alerts fail. 2015-01-15 11:55:13 +01:00
Lluis Sanchez 639bf66171 Generate proper Link metadata for resources in imported projects
When importing a project that contains embedded resources, the id
of those resources must be generated using the path relative
to the project file that includes them, not relative to the
main project file. To fix this problem, we now generate a
Link metadata property for those resources that has the correct
relative path, and later this is used to generate the correct
id for the resource. We also now store a new metadata value
for all items (DefiningProjectFullPath) which contains the
path to the project file that defines the element. This is
used to check if an item was defined in an imported file,
in which case the Link assignment may need to be made.

This fixes bug BXC 20966.
2015-01-15 11:07:49 +01:00
Marek Safar 02782f4a1a [system] System.Timer from reference sources 2015-01-15 10:05:50 +01:00
Marek Safar bc6ea9d725 Merge pull request #1505 from esdrubal/tzifloatingrule
[System.Core] Fixed wrong DST of TimeZoneInfo with floating date rules.
2015-01-15 09:19:02 +01:00
David Karlaš 03082714c0 [sdb] Fixed .mdb parsing when line equals 0 2015-01-15 09:18:16 +01:00
Zoltan Varga 31ca4c480c Merge pull request #1506 from akoeplinger/fix-paste-test
[MWF] Fix unicode string handling from clipboard paste in X11
2015-01-14 23:57:05 -05:00
Zoltan Varga 18561ff041 [sdb] Don't continue single stepping when reaching the same line if locations without debug info were reached during the single step. 2015-01-14 19:57:49 -05:00
Rodrigo Kumpera e92b71af43 Sorry for breaking linux. 2015-01-14 19:26:13 -05:00
Rodrigo Kumpera 6f6e8586eb [runtime] I can still find unguarded used of signal.h, amazing. 2015-01-14 19:21:36 -05:00
Zoltan Varga 025f351123 [sdb] Fix the detection of whenever an image has debug info or not. 2015-01-14 19:13:46 -05:00
Mark Probst ae3b35aa23 Merge pull request #1466 from schani/stage-unified-card-table-scanning
Unified card table scanning
2015-01-14 14:56:12 -08:00
Zoltan Varga 4304c55302 Fix the build. 2015-01-14 17:48:51 -05:00
Marek Safar f9917c3110 [corlib] Hashtable constructor with equality comparer needs to use it during initialization as well 2015-01-14 23:25:32 +01:00
Zoltan Varga ea0159a4ac [sdb] Fix a few places missed in 73d14781d2. 2015-01-14 16:56:57 -05:00
Marek Safar 5c3e91d094 [Microsoft.Build.Utilities] Replace use of ProcessStringDictionary with case insensitive dictionary. It shouldn't case insensitive on non-windows but that'd break msbuild compatibility 2015-01-14 22:31:42 +01:00
Marek Safar b15de26512 Fixes build 2015-01-14 22:31:42 +01:00
Alexander Köplinger 9c05594fc5 [MWF] Fix unicode string handling from clipboard paste in X11
In the TextBoxTest.PasteTest () test case we copy the string "ABCD" to the clipboard.
We then try to paste it again and see if it's the same.

Internally in WinForms, the clipboard data is retrieved via an X11 API that returns
a pointer to the string. In this case, we have a unicode/utf16 string that usually
looks as follows in memory (2 byte per character):

65  'A'
0
-
66  'B'
0
-
67  'C'
0
-
68  'D'
0
-
0   '\0' end of string
0   potential garbage from here on
-
0
0
...

The bug is that we use Marshal.PtrToStringUni (), which reads until the
first null *char* not the first null *byte*.

Imagine if we get the following (happens sometimes):

65  'A'
0
-
66  'B'
0
-
67  'C'
0
-
68  'D'
0
-
0   '\0' end of string
230 <--- garbage, but considered part of a char by PtrToStringUni ()
-
47
56
-
74
43
...

This produces garbage like "ABCD㠯⭊" since PtrToStringUni () reads beyond the original string.

The fix is to use the nitems variable that is returned by the X11 API (it contains the
actual number of bytes in the string) and copy the bytes manually. We already do
the same for the UTF8 case above.

This fixes the TextBoxTest.PasteTest () that intermittently fails on Jenkins.
2015-01-14 22:31:30 +01:00
Zoltan Varga 73d14781d2 [sdb] Emit debug logs using g_print () on android, so it shows up in adb logcat output. 2015-01-14 16:29:54 -05:00
Marek Safar 053e618102 [system.net.http] Drop WebClient dependency 2015-01-14 21:41:49 +01:00
Marek Safar a90491c257 [system] System.Collections.ObjectModel from reference sources 2015-01-14 21:41:48 +01:00
Zoltan Varga d9341960de [pdb2mdb] Fix the decoding of nested scopes. 2015-01-14 13:44:44 -05:00
Marek Safar 941ac41ac0 [system] System.Collections.Specialized from reference sources 2015-01-14 18:42:12 +01:00
Marek Safar eb050de08a [system] Add UnicodeDecodingConformance, UnicodeEncodingConformance 2015-01-14 18:18:07 +01:00
Marek Safar 4403146ada [system] Switch to reference sources WebClient 2015-01-14 17:37:12 +01:00
Marek Safar af11f84af0 [system] Cookies implementation from reference sources 2015-01-14 16:41:27 +01:00
João Matos 8811a8704f [runtime] Do not use MONO_STRUCT_OFFSET for Win32-specific offsets.
We do not yet have auto-generated offsets for Win32 targets and this interacts in weird ways with the Android cross-compilers for Windows.
2015-01-14 15:28:11 +00:00
Marcos Henrich e0278f8f69 [System.Core] Fixed wrong DST of TimeZoneInfo with floating date rules.
Fixes #26008
We do not want (transition.DayOfWeek - first) % 7 to be negative.
As (transition.DayOfWeek - first) cannot be lower than -7, adding 7 to it solves the issue.
2015-01-14 15:20:27 +00:00
Marcos Henrich e4676f8a12 [System.Core] Added tests to TimeZoneInfoTest. Covers #26008. 2015-01-14 15:20:16 +00:00
Alex Rønne Petersen 9c660cf0b9 Fix mono_handle_native_sigsegv () signature in the cross compiler case. 2015-01-14 13:52:14 +01:00
Zoltan Varga 1f32c791d4 Fix a deadlock introduced by 3f10c46468. 2015-01-13 21:52:31 -05:00
Zoltan Varga a9e3b26344 Merge pull request #1500 from criteo-forks/criteo
Fix SpinLock.TryEnter
2015-01-13 20:31:07 -05:00
Vlad Brezae 3f16384da1 [amd64] Add monitor enter v4 fastpath. 2015-01-13 17:07:18 -08:00
Zoltan Varga 3f10c46468 [bcl] Break waits in KeventWatcher by closing the command fd instead of polling. 2015-01-13 18:58:02 -05:00
Zoltan Varga 3cf4d21f8a [bcl] Put the files created by the HostFileChangeMonitor test into an additional subdir to avoid the file system watcher starting to watch system temporary files in the parent dir. Dispose file system watchers at the end of the test. 2015-01-13 18:56:14 -05:00
Vlad Brezae 5b0fbd4c9c [x86] Add monitor enter v4 fastpath. 2015-01-13 14:26:33 -08:00
Zoltan Varga c1b4366932 [bcl] Remove NET_4_5 defines from class libs. 2015-01-13 16:34:23 -05:00
Zoltan Varga 2375c74a64 [bcl] Remove NET_4_5 defines from tools. 2015-01-13 16:34:11 -05:00
Zoltan Varga bfb9d6d5d9 [runtime] Move the monograph tool to tools/. 2015-01-13 16:25:19 -05:00
Zoltan Varga 032f313d5f [bcl] Remove NET_4_0 defines from class libs. 2015-01-13 16:06:31 -05:00
Zoltan Varga bc8041cbe5 [bcl] Remove NET_4_0 defines from tools. 2015-01-13 15:59:48 -05:00
Zoltan Varga 0985d4aa4b [bcl] Remove NET_2_0 defines from the class libs. This has been done using: unifdef -t -DNET_2_0 -o <filename> <filename>. 2015-01-13 15:29:38 -05:00
Zoltan Varga f54652de26 [bcl] Remove NET_2_0 defines from tools. 2015-01-13 15:13:27 -05:00
João Matos 7299191d96 Revert "[build] Add seq-points.c to the genmdesc to try to fix the Monotouch build."
This reverts commit 5510857e6b.
2015-01-13 17:53:18 +00:00
Marcos Henrich 80cd1c8a0f [build] Updated csproj files. 2015-01-13 17:47:48 +00:00
Marcos Henrich d19f5dc228 Fixed msvc/scripts/genproj.cs file seperator issue on UNIX.
On UNIX '\\' is a valid file name character.
In this case we have to replace '\\' for Path.GetFileNameWithoutExtension to work as expected.
2015-01-13 17:47:48 +00:00
Marcos Henrich 5b851f03a2 [System.ComponentModel.Composition] Updated Makefile thisdir.
Old thisdir was causing problems while doing make update-csproj on top dir.
2015-01-13 17:47:48 +00:00
João Matos 5510857e6b [build] Add seq-points.c to the genmdesc to try to fix the Monotouch build. 2015-01-13 17:25:15 +00:00
Marc-Andre Ferland 80f72a9dd9 Allows refs to be released after the handle is set as invalid. 2015-01-13 12:06:49 -05:00
Marek Safar 5a781d6d56 [system.data] refresh mobile sources 2015-01-13 17:02:08 +01:00
Marek Safar d0d5cd45de [system.data] Update for DataSetExtensions as GetTableMappingBySchemaAction is now more restrictive. 2015-01-13 16:11:07 +01:00
Marek Safar 04dc09cbf8 [corlib] Close underlying synchronized stream. Fixes #25498 2015-01-13 14:57:55 +01:00
Marek Safar 7c2bf5f2a1 [system.net.http] Split reading headers and content in GetStreamAsync. Fixes #23966 2015-01-13 12:28:06 +01:00
Marek Safar 4736f957a6 [corlib] Add range checks to CharUnicodeInfo. Fixes #25895 2015-01-13 11:19:21 +01:00
Marek Safar 9ceced044e [system.data] update mobile profile 2015-01-13 11:02:54 +01:00
Marek Safar 0042e68c2e [system.data] Replace connection string builder from reference sources 2015-01-13 10:59:21 +01:00
Alex Rønne Petersen 20f9db583e Fix the build on sigaltstack platforms. 2015-01-13 10:16:44 +01:00
Alex Rønne Petersen b1099af6c7 Fix the Android build; use HAVE_SYS_SYSCTL_H instead of HAVE_SYS_IOCTL_H. 2015-01-13 09:43:58 +01:00
Alex Rønne Petersen 15312e93ab Add an extension point for backtraces on native SIGSEGVs. 2015-01-13 09:20:06 +01:00
Alex Rønne Petersen d1c6023b32 Propagate siginfo to mono_handle_native_sigsegv ().
Some platforms (e.g. Android) need this to get a backtrace in a signal handler.
2015-01-13 09:20:06 +01:00
Marek Safar cb452cfff7 [system.data] Replace System.Data.SqlTypes from reference sources except SqlXml which depends on internal system.xml factory method 2015-01-13 09:19:11 +01:00
Marek Safar 696c08126c [system.data] Switch to DbEnumerator from reference sources. Fixes #24935 2015-01-13 09:19:11 +01:00
Guillaume Turri 3d17efc13c Fix SpinLock.TryEnter
Little and big endian cases were inverted. It can be seen e.g. from the
reference http://locklessinc.com/articles/locks, where the ticket algorithm
is given for little-endian machines

As a consequence, without this patch, if TryEnter succeeds, it increments
ticket.Value instead of ticket.User, which puts the SpinLock in a corrupted
state, and makes it impossible to release afterwards.
2015-01-13 08:47:09 +01:00
Miguel de Icaza 9d08d2b0d9 [Regex] Disable IL code generation until we figure out 25671 2015-01-12 23:23:23 -05:00
Miguel de Icaza a4c7885f7d [Mono.Posix] Add support for OSX F_NOCACHE 2015-01-12 23:13:58 -05:00
Marc-Andre Ferland f7d2cb47c0 Test that closing handle will release managed resource by calling Dispose 2015-01-12 21:37:09 -05:00
Zoltan Varga c38c9c6f25 [aot] Fix llvm support. 2015-01-12 19:38:01 -05:00
Zoltan Varga 037f47d973 [runtime] Fix the android build. 2015-01-12 18:08:39 -05:00
Zoltan Varga ca327b1162 [runtime] Use a guint64 for device/inode instead of dev_t/ino_t since ino_t is defined as 32 bit on newer android versions, but inode values can actually be 64 bit. 2015-01-12 17:23:41 -05:00
Zoltan Varga 02696b4d21 Fix the build. 2015-01-12 17:20:01 -05:00
Zoltan Varga 3ccc4e92b2 [runtime] Remove an unused define. 2015-01-12 17:08:21 -05:00
Zoltan Varga 57f99de33d [bcl] Fix a race in a System.Threading.Tasks test. 2015-01-12 17:02:39 -05:00
Zoltan Varga 05cd4225b2 [aot] Implement support for separate llvm object files when using static linking. Enable it on all platforms. 2015-01-12 16:45:07 -05:00
Zoltan Varga 472afb9fd7 [arm] Fix the decoding of backward branches in mono_arch_get_call_target (). 2015-01-12 16:45:07 -05:00
Marek Safar bb9d05a5f5 [system] Fixes barrier file name 2015-01-12 20:07:33 +01:00
Zoltan Varga 1e5ddf741c [aot] Add an 'llvm-outfile=' command line argument to specify the name of the assembly file holding the LLVM compiled code when the 'asmonly' option is used. 2015-01-12 13:41:54 -05:00
Marek Safar e9b135baca [system] Replace Barrier implementation from reference sources. Fixes #25928 2015-01-12 17:18:42 +01:00
Marek Safar 5728c1a3dd [system.net.http] ProductInfoHeader collection parsing/formatting uses special separators. Fixes #19881 2015-01-12 16:47:04 +01:00
Radek Doulik 581ac48a56 do not use liblog's absolute path in DllImport
- let it for dllmap to specify the path of liblog
   https://github.com/xamarin/monodroid/commit/e834a251d65cb8f677ee7140450ea11e09dbf5c8
 - when checking if running on Android, check the 64bit liblog location as well
2015-01-12 15:28:15 +01:00
Marcos Henrich 2dabfdf453 [System.Runtime.Caching] Removed unused files.
referencesource files are used instead of the removed files.
2015-01-12 13:08:20 +00:00
Marek Safar 9652f056bc [corlib] SafeHandle dispose can be called multiple times after closing. Fixes #25850 2015-01-12 14:05:38 +01:00
Marcos Henrich bcfdc181eb [runtime] update_liveness2 replaced wrong binary or with or. 2015-01-12 11:32:36 +00:00
Marcos Henrich 602a62377d [runtime] update_liveness2 now handles OP_IL_SEQ_POINT. 2015-01-12 11:05:15 +00:00
Marek Safar 28f16c8991 [corlib] Fixes SafeHandle invalidHandleValue handling 2015-01-12 11:52:31 +01:00
Marcos Henrich f0834d5407 Merge pull request #1455 from esdrubal/caching
[System.Runtime.Caching] .NET integration.
2015-01-12 08:27:48 +00:00
Marek Safar 7a7d04b618 Merge pull request #1499 from madrang/SafeHandleTesting
SafeHandle SetAsInvalid Testing
2015-01-12 00:13:40 +01:00
Marc-Andre Ferland 4288f7d687 More strict testing of SafeHandle.
SafeHandle.IsInvalid refer only to the handle value it self. Being true only if the handle is 0 || -1
	In all cases, Releasing, Disposing or SetHandleAsInvalid does not change the handle value, so SafeHandle.IsInvalid will remain unchanged.
	IsClosed will be true if the handle is released or if SetHandleAsInvalid is called.
	The handle will not be released when calling Dispose if SetHandleAsInvalid was called.
	The handle is not released at Dispose but when the last ref is removed by DangerousRelease
2015-01-11 18:10:06 -05:00
Zoltan Varga b2e5b02817 runtime] Really fix a race condition in mono_remoting_marshal_init (). 2015-01-11 12:07:16 -05:00
Zoltan Varga 1fa2463bc3 [aot] Enable direct llvm object file emission on x86 as well. 2015-01-11 10:31:29 -05:00
Zoltan Varga e3c000b256 [aot] Avoid duplicate symbol errors if two methods have the same cfg->method. 2015-01-11 10:26:41 -05:00
Marcos Henrich b9e97c9957 test_op_il_seq_point.sh now properly tests AOT compilation.
Added missing option --aot
2015-01-11 14:53:13 +00:00
Marcos Henrich 4db0888798 test_op_il_seq_point.sh no longer prints empty lines. 2015-01-11 14:53:13 +00:00
Marcos Henrich 984d3df9b1 TestDriver now has option --quiet to disable Console outputs.
test_op_il_seq_point.sh does not work well when TestDriver produces outputs, calling the tests with option -q solves this.
2015-01-11 14:53:13 +00:00
Zoltan Varga f663ba7ba7 [aot] Emit LLVM object files directly from llc on amd64. 2015-01-11 09:49:21 -05:00
Marcos Henrich 454d96dea6 test_op_il_seq_point.sh now prints whole diff. 2015-01-11 10:08:30 +00:00
Zoltan Varga 20113c5ec7 Fix warnings. 2015-01-10 23:04:05 -05:00
Zoltan Varga d1beab3cd8 Fix the build. 2015-01-10 22:55:13 -05:00
Zoltan Varga f717d75b69 Merge pull request #1498 from akoeplinger/fix-windows
Fix Windows build
2015-01-10 22:46:39 -05:00
Alexander Köplinger 6213c699d2 Fix Windows build
Some autoconf checks were missing when running on Windows.
Added stub for mono_get_local_interfaces back that was removed in b92e560d3f
for systems like Windows that have neither HAVE_SIOCGIFCONF nor HAVE_GETIFADDRS.
2015-01-10 22:09:18 +01:00
Marek Safar 9f9d9d25b3 [mcs] Auto-implemented properties must override all accessors of the overridden property 2015-01-10 18:51:01 +01:00
Marek Safar aa5f851bec [mcs] Contructors cannot be extern and have a constructor initializer 2015-01-10 18:51:01 +01:00
Marcos Henrich 55c0773505 test_op_il_seq_point.sh ignore diff unnecessary data. 2015-01-10 16:51:30 +00:00
Zoltan Varga f6b3eb0e80 [aot] Emit a separate GOT for LLVM and JITted code, this avoids having to reference the extern got symbol from JITted code if the LLVM code is emitted into a separate module. 2015-01-10 11:24:42 -05:00
Zoltan Varga 9130a8641e Add missing files to the windows build. 2015-01-10 10:07:41 -05:00
Zoltan Varga edbde3b6be Fix the windows build. 2015-01-10 08:18:25 -05:00
Marcos Henrich 3bcef7ef86 [System.Runtime.Caching] Updated MemoryCacheTest.
When config PhysicalMemoryLimitPercentage is not set or set to zero MemoryCache.PhysicalMemoryLimit value will depend on the total physical memory available.
2015-01-10 11:30:01 +00:00
Marcos Henrich b78211356f [System.Runtime.Caching] Improved CacheUsage sorting.
Now even if multiple MemoryCacheEntry are added to CacheUsage with the same date time CacheEntryCollection is able to sort them for removal in the same order.
2015-01-10 11:14:24 +00:00
Rodrigo Kumpera 6202a690ad [utils][runtime] Another rounds of header cleanup. 2015-01-09 21:06:39 -05:00
Rodrigo Kumpera 48f0075b9d [utils] Remove useless include. 2015-01-09 20:10:17 -05:00
Rodrigo Kumpera e095e8b011 [metadata] Fix the build. 2015-01-09 20:09:18 -05:00
Rodrigo Kumpera be917fb5ef [metadata] Rename security.c to mono-security.c to avoid conflicts with some weird linkers. 2015-01-09 20:03:55 -05:00
Rodrigo Kumpera 7090ce602b [io-layer] Fix another header missing a guard. 2015-01-09 19:46:51 -05:00
Rodrigo Kumpera 1f83d515cf [metadata] Use new networking abtraction to fix targets without inet_ntop 2015-01-09 19:36:45 -05:00
Rodrigo Kumpera 4b98deb7c9 [utils] Add API to stringify a network address. 2015-01-09 19:36:45 -05:00
Zoltan Varga 92ca06aa7d [jit] Add a MONO_PATCH_INFO_LDSTR_LIT patch type to handle strings which do not come from metadata, i.e. they are used in wrappers. Fixes #25891. 2015-01-09 17:30:27 -05:00
Marek Safar f52380fc7c [mcs] Add string interpolation conversions 2015-01-09 23:27:18 +01:00
Rodrigo Kumpera 7b84b28673 [io-layer] Fix linux build. 2015-01-09 15:13:10 -05:00
Zoltan Varga 86a65282f6 Merge pull request #1497 from esdrubal/sq
Tests and fixes for OP_IL_SEQ_POINT
2015-01-09 13:37:58 -05:00
Marcos Henrich 5caa7a1491 [System.Runtime.Caching] MemoryCacheTest.Trim now checks LRU.
Entries are now removed in the least recently used order.
MemoryCacheTest.Trim was updated to check that entries are removed in LRU order.
2015-01-09 15:36:57 +00:00
Marcos Henrich 70d30f9de1 [System.Runtime.Caching] Updated MemoryCacheTest.TestCacheSliding.
Changed sliding expiration timeout from 1 second to 2 seconds.
2015-01-09 15:36:57 +00:00
Marcos Henrich 861b335181 [System.Runtime.Caching] Updated tests default PhysicalMemoryLimit.
MemoryCache.PhysicalMemoryLimit default value is now 99 instead of 98.
2015-01-09 15:36:57 +00:00
Marcos Henrich 80427367c2 [System.Runtime.Caching] .sources now uses referecensource files. 2015-01-09 15:36:57 +00:00
Marcos Henrich 88262cfa6e [System.Runtime.Caching] Implemented referencesource missing classes.
Implemented classes UsageEntryRef, CacheUsage, ExpiresEntryRef and CacheExpires.
2015-01-09 15:36:56 +00:00
Marcos Henrich bcf7e6e797 [System.Runtime.Caching] Copied SRef.cs from .NET.
.NET was using this to retrieve the size of an object graph, by using special logic on its GC.
This version of SRef is not doing that, because Mono does not provide that kind of computation.
As the changes that the GC would require to support this are not trivial, SRef returns a wrong size for now.
Known problems:
   - CacheMemoryMonitor does not trim the cache when it reaches its memory size limit.
   - IMemoryCacheManager.UpdateCacheSize is called with incorrect size.
2015-01-09 15:36:56 +00:00
Marcos Henrich 04285d5ad2 [System.Runtime.Caching] Copied R.Designer.cs from .NET
We will be using this version of R.Designer.cs with hard coded strings until Mono has access to .NET resources.
2015-01-09 15:36:56 +00:00
Marcos Henrich b5d0ffe7dd Added performance counter "Available Physical Memory".
Performance counter "Available Physical Memory" return the current
amount of ram that is not in use.

This was added to be used by System.Runtime.Caching .NET integration
that relies on the available system memory to resize the cache.
2015-01-09 15:36:56 +00:00
Etienne CHAMPETIER 81057618ac System.Xml.Serialization: fix xml serializers generation for Web Services
(add a reference to System.Web.Services)

Without this patch we get the following exception after multiple call
to a soap web services:
Error while compiling generated serializer
/tmp/24ee1170/4996ddb2.cs(2519,27) : warning CS1522: Empty switch block
/tmp/24ee1170/4996ddb2.cs(969,29) : error CS0012: The type `System.Web.Services.Protocols.SoapHeader' is defined in an assembly that is not referenced. Consider adding a reference to assembly `System.Web.Services, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'

Signed-off-by: Frederic Mestayer <[email protected]>
Signed-off-by: Etienne CHAMPETIER <[email protected]>
2015-01-09 15:02:10 +01:00
Alexander Köplinger 1db6835638 [utils] Remove duplicate socklen_t typedef from Windows build
This is already defined in ws2tcpip.h
2015-01-09 00:42:48 +01:00
Alexander Köplinger d03e64a2ee Merge pull request #1433 from akoeplinger/system.numerics-port
[System.Numerics] Ported code from MS referencesource
2015-01-09 00:34:31 +01:00
Zoltan Varga 2617698743 [aot] Enable emission of LLVM code into a separate file on amd64 in full aot mode. This requires emitting got accesses using normal assembly instead of emit_symbol_diff (), since clang cannot handle <sym> - . expressions if <sym> is an extern symbol. 2015-01-08 17:59:11 -05:00
Rodrigo Kumpera 2ce793efb6 [io-layer] Header usage grooming. Remove some unused headers and add config.h guards to others. 2015-01-08 17:46:54 -05:00
Miguel de Icaza e397f7097a Merge pull request #1495 from akoeplinger/fix-cancelrequestviaproxy
[System.Net.Http] Fix CancelRequestViaProxy() test that intermittently fails on Jenkins
2015-01-08 17:09:13 -05:00
Rodrigo Kumpera 41c1a773f9 [gc] Fix gc bitmap for array of pointers. They don't contain references 2015-01-08 15:37:18 -05:00
Rodrigo Kumpera 047b15f4e6 [utils] Fix linux compilation. 2015-01-08 15:18:23 -05:00
Rodrigo Kumpera 0959de07bf [utils] Apparently ws2ipdef.h should not be included directly. Using ws2tcpip.h which is the recommended header. 2015-01-08 15:18:23 -05:00
Marek Safar f776513488 [mcs] Add string interpolation grammar 2015-01-08 20:55:49 +01:00
Rodrigo Kumpera c5d8151c22 [utils] Another round of windows fixing. 2015-01-08 12:33:48 -05:00
Rodrigo Kumpera ab72a3d6ba [utils] More portability cleanups. 2015-01-08 12:33:48 -05:00
Rodrigo Kumpera 2df9fc3e8c [utils] Don't enable usage of sigaction unless the function is available. 2015-01-08 12:33:47 -05:00
Zoltan Varga 281b4a4abf [runtime] Fix a race condition in mono_remoting_marshal_init (). 2015-01-08 12:15:04 -05:00
Rodrigo Kumpera 800a117da9 [utils] Don't special case android or FreeBSD when trying ucontext.h 2015-01-08 11:34:52 -05:00
Rodrigo Kumpera 373e055709 [utils] Small header sanitization. networking.h now include config.h 2015-01-08 11:34:03 -05:00
Rodrigo Kumpera dd07fe7aaf [utils] Another try to fix the windows build. 2015-01-08 10:57:56 -05:00
Alexander Köplinger ab77341c6f Only build the master branch on AppVeyor 2015-01-08 16:50:47 +01:00
Marcos Henrich 4629d64abd [runtime] Makefile check now calls check-seq-points
check-seq-points now also checks AOT
2015-01-08 15:28:21 +00:00
Marcos Henrich 46a65b39bb [runtime] mono_decompose_long_opts now handles OP_IL_SEQ_POINT. 2015-01-08 14:12:42 +00:00
Marcos Henrich e5e97ddf35 test_op_il_seq_point.sh now checks sizes using diff.
Replaced sdiff with diff because sdiff cuts long line and we need to parse the code length from its output.
2015-01-08 14:01:51 +00:00
Marcos Henrich 2f5e9048a1 test_op_il_seq_point.sh no longer compares native code with AOT.
AOT compilation is also including non deterministic data into the generated native code.
2015-01-08 13:56:43 +00:00
Zoltan Varga 16b2539bab [runtime] Another windows build fix. 2015-01-08 07:29:56 -05:00
Zoltan Varga 2368176d0f [runtime] Add a header check for arpa/inet.h. 2015-01-08 06:16:42 -05:00
Zoltan Varga 62b4e3a314 [cominterop] Fix a crash by passing the proper value to mono_marshal_free_ccw (). Fixes #24638. 2015-01-08 05:09:11 -05:00
Zoltan Varga a568b19c13 [cominterop] Avoid crashes when the first item of a list is deleted and the list head was stored in a hash table. Fixes #24720. 2015-01-08 05:05:08 -05:00
Zoltan Varga b103884634 [runtime] Avoid Process.GetCurrentProcess ().HasExited asserting. Fixes #25720. 2015-01-08 04:47:55 -05:00
Jo Shields 51f2a8c251 [msvc] 64-bit Windows still needs _WIN32_WINNT (for monoposixhelper) 2015-01-08 08:55:09 +00:00
Mark Probst c389a66121 [sgen] Unified loop for scanning card tables.
We had previously used two separate loops for scanning card tables: One
loop that handled blocks where the object slots were larger than a single card,
and one loop where they were smaller.  In the large case we would iterate over
the slots, check whether they were occupied, and if so, check their cards. In the
smaller case we would do it the opposite way: Check the card first, then check
the slots in the card.

For some workloads, the large loop resulted in lots of cache misses, because
we were fetching memory all over the blocks instead of just the cards.  The small
loop, on the other hand, would sometimes scan objects twice, namely when they
crossed the boundary between two cards, and both cards were marked.

This new unified loop fixes both problems.  We always look at the cards first,
and we keep a scan front pointer that prevents scanning objects more than
once.
2015-01-07 16:57:54 -08:00
Mark Probst 001c8a68ed [sgen] Don't scan card tables differently based on object size.
For objects that were larger than a card we iterated over the objects in a block, rather
than iterate over the cards.  To do that we had to load the object headers, which caused
cache misses.  The card bits are consecutive, so they'll be in the cache.
2015-01-07 15:34:56 -08:00
Mark Probst 5d0069dec3 [sgen] Use a scan front pointer to avoid scanning objects twice from cardtable. 2015-01-07 15:34:56 -08:00
Mark Probst 6be120bde8 [sgen] Prefetching of blocks and cards in cardtable scanning. 2015-01-07 15:34:56 -08:00
Zoltan Varga 15e9a61807 [arm] Fix OP_ICLE_UN. Fixes #25798. 2015-01-07 18:29:12 -05:00
Vlad Brezae 7786ec1408 [x86] Enable the monitor enter/exit fastpaths. 2015-01-07 14:21:45 -08:00
Vlad Brezae efe2234b98 [amd64] Enable the monitor enter/exit fastpaths. 2015-01-07 14:21:14 -08:00
Vlad Brezae 753348a68b Unmanaged implementation of spin free locks.
The commit addresses race issues between the waiting on the lock semaphore and the release of the lock. The entry count and the owner field are grouped together into the status field. Accesses to it are done using atomic cas operations so threads aren't lost waiting for release on the lock semaphore.

Disable native fastpaths for now, until they are updated to the new implementation.
2015-01-07 14:19:59 -08:00
Vlad Brezae 3327e1c25e [amd64] Fix compilation error when monitor fastpaths are disabled 2015-01-07 14:03:12 -08:00
Vlad Brezae b7482d9b22 Remove IL fastpaths for Monitor Enter/Exit. 2015-01-07 14:03:11 -08:00
Vlad Brezae 045422715f [runtime] If possible, use fast tls for small_id storage. 2015-01-07 13:48:18 -08:00
Marek Safar f41f2f0df1 [mcs] An argument to nameof operator cannot be extension method group 2015-01-07 21:06:11 +01:00
Marek Safar c97ef02dc8 [mcs] update exception filters syntax to use yet another contextual keyword 2015-01-07 19:22:04 +01:00
Zoltan Varga e2558972bd [sdb] Enable the StackFrame.Domain property on stack frames which represent native transitions. 2015-01-07 10:59:17 -05:00
Marcos Henrich 93ffd56a4a [runtime] Improved mono_local_cprop OP_IL_SEQ_POINT filtering.
Replaced more ins->next usages with mono_inst_next (ins, OP_IL_SEQ_POINT).
2015-01-07 14:11:16 +00:00
Marek Safar 50405e2e64 [mcs] Add reference to parent storey when this is hoisted in disconnected state machine. Fixes #25007 2015-01-07 14:02:12 +01:00
Marcos Henrich 0e90a8ccce test_op_il_seq_point.sh can now tests with and without AOT
Without AOT only code size is checked
With AOT native code is checked.
We cannot compare the native code without AOT because some undeterministic data is stored in the middle of the code and there is no easy way of making the native code dumper ignore it.
2015-01-07 12:39:27 +00:00
Marcos Henrich 1aa885d086 test_op_il_seq_point.sh now compares native code with AOT only.
Comparing native code is only possible with AOT because it is almost deterministic.
A diff of the smallest method changed by OP_IL_SEQ_POINT is now printed to ease problem identification.
2015-01-07 11:56:21 +00:00
Zoltan Varga 9b294f1fc0 [aot] Enable separate llvm modules on amd64. 2015-01-07 03:49:01 -05:00
Zoltan Varga bda99d7944 [aot] Enable emission of debug info for LLVM code if the LLVM code is emitted into a separate module. 2015-01-07 03:44:58 -05:00
Zoltan Varga ac94e5c7cd [aot] Add support for emitting the llvm code separately into a separate object file on amd64. Not enabled yet. 2015-01-07 03:11:49 -05:00
Zoltan Varga eb0a3fe358 [aot] Allow the emission of the LLVM code into a separate .s/.o file. Not enabled yet. 2015-01-07 01:46:14 -05:00
Rodrigo Kumpera b92e560d3f [runtime] Change socket-io.c to use new API for local IP discovery. 2015-01-06 16:11:43 -05:00
Rodrigo Kumpera 0457b278f2 [utils] Add abstraction to retrive the local interface addresses. 2015-01-06 16:11:43 -05:00
Rodrigo Kumpera da0acc6450 [runtime] IPV6 is now the norm so we can expect all systems to have it. 2015-01-06 16:11:43 -05:00
Zoltan Varga f6ecbd11dc [sdb] Bump protocol version to 2.39 so the single stepping changes can be detected by clients. 2015-01-06 15:14:09 -05:00
David Karlaš 1eb510ed44 [Sdb] Ignore hidden sequence points 2015-01-06 15:12:37 -05:00
David Karlaš 1187a32f28 [Sdb] With better mimicking of .Net debugging experience stepping out of method returns to method call instead of next statement 2015-01-06 15:12:17 -05:00
David Karlaš ccf808281d [Sdb] Fixed bug with STEP_DEPTH_MIN+STEP_SIZE_MIN which stopped on NONEMPTY_STACK sequence point in same method as it begin stepping 2015-01-06 15:12:16 -05:00
David Karlaš 1d195ac697 [Sdb] Removed exclusion of CEE_POP and CEE_NOP sequence point creation 2015-01-06 15:12:15 -05:00
David Karlaš 85c40f6784 [Sdb] Set filter on ss_req in ss_create because filter was never set condition "if ((ss_req->filter & STEP_FILTER_STATIC_CTOR) &&" in process_single_step_inner was nerver true 2015-01-06 15:12:15 -05:00
Zoltan Varga a5c3f535cc [sdb] Fix single stepping problems caused by missing seq point info in .mdb files. When stepping in, we have to put a single stepping breakpoint into the parent method, otherwise a missing seq point could cause the debugger to continue until it hits a method entry seq point. 2015-01-06 15:12:15 -05:00
Zoltan Varga 04753f184f [sdb] Avoid putting implicit seq points at nops followed by a sym seq point. 2015-01-06 15:12:15 -05:00
Zoltan Varga 3ce94182e2 [sdb] Put seq points at nop's following calls as well. 2015-01-06 15:12:14 -05:00
Zoltan Varga cd4cbc4c70 [sdb] Emit an implicit sequence point after every call and newobj instruction. 2015-01-06 15:12:14 -05:00
Zoltan Varga 6b43e2d103 [sdb] Avoid using implicit sequence points for methods without debug info in images which have debug info, like auto generated property accessors. 2015-01-06 15:12:14 -05:00
Rodrigo Kumpera 5229466676 [tests] Dump stdout/stderr on test failure. 2015-01-06 15:06:03 -05:00
Marek Safar 157083d1a5 [mcs] Additional fix for naming of nested types in attributes. Second fix of #24172 2015-01-06 19:22:51 +01:00
Rodrigo Kumpera ab0be9bbee [networking] mono_socket_address_init should set len to the size of sockaddr_* and not *_addr. 2015-01-06 13:12:08 -05:00
Zoltan Varga a9a87caa20 [runtime] Fix a crash in FieldInfo.GetRawConstantValue () if a dynamic field doesn't have a default value, but has the HasDefault flag set. 2015-01-06 12:59:30 -05:00
Zoltan Varga 96b25f0d82 [jit] Add a test for #25487. 2015-01-06 12:22:01 -05:00
Zoltan Varga 3a74470db6 Merge pull request #1493 from BrzVlad/vtune-integration2
Vtune integration
2015-01-06 04:00:09 -05:00
Rodrigo Kumpera 36128150d1 [io-layer] Remove some deadcode from the sockets code.
That function is no longer needed since nothing calls it.

This was effective dead code for ages as it would only be used by targets
with no ipv6. So, unless you're using Debian Potato, nothing to see here.
2015-01-05 18:50:43 -05:00
Rodrigo Kumpera c87236f052 [sdb] Move sdb to use the new portable networking APIS.
This simplifies a lot of the code in some cases and enables some ports
to have access to previously disabled functionality (passive inferior).
2015-01-05 18:48:41 -05:00
Rodrigo Kumpera 98df6c7728 [runtime] Use the new network abstraction in the sockets code.
By using a single networking abstraction for name resolution we no longer
need to have two code paths, one for struct hostent and one for struct addrinfo. Good riddance.

More specifically.

We now use functions to fetch protocol numbers and not rely on inline ifdefs.

We use the single abstraction over name resolution, which allows us to have a single code
path to convert the native structure into a managed one.

Finally, we moved the polyfill logic for missing functionality to a separate file to make
things easier.
2015-01-05 18:40:34 -05:00
Rodrigo Kumpera ab59edf8a5 [utils] Add a cross platform networking API for name discovery.
This meant to replace the ifdef hell that is part of the current socket code and to
modernize the sockets code on some targets.

For some reason we still relied on gethostbyname (and variants) in 2015.
Those functions were deprecated circa the KAME project - yes, I'm that old to remember it.

With that in mind, we now rely on getaddrinfo for all sane targets and drop straight to
the lowest common denominator when it's not available, which is gethostbyname/gethostbyname2.

This patch removes support for the glibc gethostbyname2_r extension. Which is not a practical
problem because all linux/android target we can realistically run on have getaddrinfo.
Sorry grampa, no Slackware 8.0 anymore.

This code has a simpler structure of whole file ifdefs as much as possible, which is
a blessing to OOT ports.
2015-01-05 18:29:02 -05:00
Rodrigo Kumpera 23b892dc3d [configure] Add checks for some posix networking functions (getaddrinfo, gethostbyname2, gethostbyname, getprotobyname).
Some targets lack different combinations of those functions so we got to check them all.
2015-01-05 18:21:48 -05:00
Vlad Brezae 97c01a0adb [profiler] Report code buffers to vtune. 2015-01-05 14:19:52 -08:00
Vlad Brezae 92128dfd4e [profiler] Include vtune support for jitted methods in the build system.
In order to track emitted code with vtune you need to :
* pass --enable-vtune=yes to autogen.sh
* have in the LD_LIBRARY_PATH the path to the profiler libraries (ex $(installation_folder)/lib)
* pass argument --profiler=vtune to mono
2015-01-05 14:19:50 -08:00
Zoltan Varga 1b9729dbf6 [arm64] Mark the 'tailcall' opcode as a call. Fixes #25646. 2015-01-05 15:22:16 -05:00
Alexander Köplinger 04170bbc67 Add build badge for debian-ppc64el to README.md 2015-01-05 19:20:04 +01:00
Marek Safar 81bd20edbd Fixes build 2015-01-05 19:13:16 +01:00
Marek Safar a9dbf2f152 [system.net.http] Use HttpWebRequest without additional buffering. Fixes #25213 2015-01-05 18:02:03 +01:00
Zoltan Varga 27fd291b19 [aot] Avoid returning different names for the same method in get_debug_sym () if llvm fails for a method. Fixes #25107. 2015-01-05 11:40:52 -05:00
Alexander Köplinger 4dce3c27d9 [System.Net.Http] Fix CancelRequestViaProxy() test that intermittently fails on Jenkins
Seems that on Jenkins, the request to the (non-existing) IP address used in the test returns before the 1s timeout,
causing the test to fail because the cancellation didn't fire.

Lowering the timeout to 1 millisecond should fix this.

I also verified that the test still correctly fails when the commit that fixed the original issue is reverted.
2015-01-05 16:41:30 +01:00
Marcos Henrich 6719c94da5 [runtime] Improved test_op_il_seq_point.sh
test_op_il_seq_point.sh now compares methods generated native code.
2015-01-05 14:56:18 +00:00
Zoltan Varga 56e0f4518f Merge pull request #1492 from akoeplinger/fix-eglib-remap-test
Add g_getdtablesize to list of acceptable g_* symbols in mono, for test-eglib-remap
2015-01-05 08:06:58 -05:00
Marek Safar cd3707a51f [system] Fixes HttpWebRequest::AllowReadStreamBuffering 2015-01-05 12:48:29 +01:00
Zoltan Varga 63a167dbcb Merge pull request #1491 from akoeplinger/fix-async_read
Fix unreliable async_read.exe test
2015-01-04 23:24:51 -05:00
Alexander Köplinger 0e298082d7 [System.Numerics] Ported code from MS referencesource 2015-01-04 11:26:42 +01:00
Zoltan Varga 7ab68ad32f [aot] Get rid of the code offsets code since direct method addresses are used on all supported platforms. 2015-01-04 04:43:06 -05:00
Zoltan Varga 3e0c70415e [aot] Avoid creating gsharedvt synchronized wrappers if gsharedvt is not enabled. 2015-01-04 04:19:39 -05:00
Zoltan Varga b73e4a71a0 [aot] Use direct method addresses on x86/amd64. 2015-01-04 04:13:45 -05:00
Zoltan Varga 1f2fe37733 [aot] Refactor the MONO_AOT_FILE_FLAG_DIRECT_METHOD_ADDRESSES code a bit. 2015-01-04 04:11:45 -05:00
Zoltan Varga 25abc112ea [aot] Split the unbox_trampolines table into two to separate the indexes and the method addresses/offsets. 2015-01-04 04:03:52 -05:00
Zoltan Varga e8156a0c8c [aot] Use nops as alignment padding on amd64 instead of zeros. 2015-01-04 03:07:47 -05:00
Alexander Köplinger dd8d450575 Add g_getdtablesize to list of acceptable g_* symbols in mono, for test-eglib-remap
The method was added in cd9f3b5859 and caused the test to fail.
2015-01-04 08:59:35 +01:00
Alexander Köplinger 219d56df76 Fix unreliable async_read.exe test 2015-01-04 05:51:18 +01:00
Zoltan Varga b7c3485cda [runtime] Use the proper domain in mono_thread_destroy_domain_tls (). Fixes #25629. 2015-01-03 13:36:02 -05:00
Zoltan Varga a0395d390a [jit] Disable the seq point tests for now, they seem to fail because of stdout buffering problems on osx. 2015-01-03 13:32:43 -05:00
Zoltan Varga 2e90c80f54 [runtime] Fix the LOCK_TRACER build. 2015-01-03 10:03:40 -05:00
Miguel de Icaza a080a7d8a9 [Windows.Forms] DataGridViewTextBoxCell: do not use a shared editing control
This fixes the case of the System.ObjectDisposedException being thrown
when editing a text cell in a DataGridView control a second time.

The problem is that the static control would be disposed by the code in
DataGridView's EditingControlInternal, but this instance was reused over
and over.

Instead, we now createa  new editing control every time that the TextBoxCell
is created.

The investigation for this bug took place here:

https://bugzilla.xamarin.com/show_bug.cgi?id=9653

Fixes also:

https://bugzilla.xamarin.com/show_bug.cgi?id=22297
2015-01-03 12:42:32 -02:00
Zoltan Varga 43aa9be05d [jit] Fix some IL_SEQ_POINT filtering issues on x86. 2015-01-03 07:13:09 -05:00
Zoltan Varga 9514523876 [runtime] Implement FieldInfo.GetRawConstantValue () for dynamic types. Fixes #25690. 2015-01-03 06:48:45 -05:00
Zoltan Varga 2d4209742d [sdb] Fix the previous change by setting SingleStepReq.start_method when the request is created, not when single stepping is started, since the latter can happen multiple times for a single step request. 2015-01-03 06:01:22 -05:00
Zoltan Varga 1139f71dc2 [sdb] Avoid stepping out of the current method if it is a cctor if StepFilter.StaticCtor is used. Fixes #14277. 2015-01-03 05:38:19 -05:00
Zoltan Varga 9d64590968 Merge pull request #1473 from esdrubal/sq
[runtime] Optimizations fixes for OP_IL_SEQ_POINT compatibility.
2015-01-03 04:40:22 -05:00
Zoltan Varga 9e03c10d8f [jit] Fix the returning of vtypes of size less than 8 in registers by using the proper sized load instructions instead of always 8. Fixes #25631. 2015-01-02 22:29:04 -05:00
Zoltan Varga f9bcd25048 [pdb2mdb] Implement support for scopes. Fixes #25357. 2015-01-02 21:08:59 -05:00
Zoltan Varga 46b15a2a6b [bcl] Fix crashes when FieldInfo.GetValue () is called on a pointer field with a null value. Fixes #25664. 2015-01-02 18:36:02 -05:00
Zoltan Varga 102f316ae2 [runtime] Avoid reading past the end of a MonoGenericParam structure in some cases. Fixes #25679. 2015-01-02 17:58:40 -05:00
Marek Safar 40810cf076 [mcs] More special case handling for explicit type names documentation. Fixes #25544 2015-01-02 23:16:33 +01:00
Marek Safar 4ab03af16a [corlib] Fix Type::GetEnumName/IsEnumDefined to return same value as Enum::GetName/IsDefined 2015-01-02 18:54:48 +01:00
João Matos a3510a115a Fixed metadata offsets for ARM64 support. 2015-01-02 16:30:14 +00:00
Alexander Köplinger e50764ba04 Fix CookieContainerTest to use expiration date in the future
It is 2015 now, so the cookie is already expired and the test fails otherwise.
2015-01-02 16:54:22 +01:00
Marek Safar e8796320bf [corlib] Allow bool/char to enum conversions 2015-01-02 15:19:51 +01:00
Alexander Köplinger c04f7e75bf Add missing quote to string added in 156ab8c5fc
This would fail to compile otherwise when the PCL constant is defined.
2014-12-31 12:42:05 +01:00
Alexander Köplinger 45a6bc149d Merge pull request #1081 from rneatherway/bug17537
Allow CLR binaries to be passed to Process.Start
2014-12-31 12:38:41 +01:00
Marek Safar fe37c2458d Merge pull request #1482 from akoeplinger/fix-codetaskfactory-2
[Microsoft.Build.Tasks] Rework CodeTaskFactory to use CodeDom and implement parameter support
2014-12-30 22:24:48 +01:00
Alexander Köplinger cdc8071806 [Microsoft.Build.Tasks] Rework CodeTaskFactory to use CodeDom and implement parameter support
Removed the old string-based code and use CodeDom APIs for everything.
Implemented parameter support by adding the necessary properties to the generated class.
Fixed bug where the task references weren't passed to the compiler.
This should now work with VB code as well (assuming the compiler is installed).
2014-12-28 13:08:20 +01:00
João Matos be8962df9c [runtime] Added support for builds with cross-compiled LLVM. 2014-12-24 19:49:12 +00:00
João Matos 1c3d900853 [runtime] Fixed mini-llvm.c build with MinGW.
MinGW-w64 lacks a definition for bzero which we use in the rest of this file, provide a simple implementation that should get the job done.
2014-12-24 19:49:11 +00:00
João Matos 28ce82dbed Merge pull request #1479 from mfoliveira/ppc64el-build-errors-v2-mit
Fix build errors in mono-context.c on ppc64el
2014-12-24 13:31:03 -05:00
Mauricio Faria de Oliveira 55fa0a561a Fix build errors in mono-context.c on ppc64el
Build error #1:

	libtool: compile:  gcc <...> -c mono-context.c  -fPIC -DPIC -o .libs/mono-context.o
	mono-context.c: In function 'mono_sigctx_to_monoctx':
	mono-context.c:435:68: error: 'MONO_SAVED_GREGS' undeclared (first use in this function)
	  memcpy (&mctx->regs, &UCONTEXT_REG_Rn(uc, 13), sizeof (mgreg_t) * MONO_SAVED_GREGS);
		                                                            ^
	mono-context.c:435:68: note: each undeclared identifier is reported only once for each function it appears in
	mono-context.c:436:70: error: 'MONO_SAVED_FREGS' undeclared (first use in this function)
	  memcpy (&mctx->fregs, &UCONTEXT_REG_FPRn(uc, 14), sizeof (double) * MONO_SAVED_FREGS);
		                                                              ^
The MONO_SAVED_GREGS and MONO_SAVED_FREGS macros are defined in mini-ppc.h.
The problem happens because commit 7e056cd346
moved code using them from exceptions-ppc.h (which includes mini-ppc.h) to
mono-context.c (which doesn't), where they're not #included.

So, include mini-ppc.h in mono-context.c (in the existing powerpc ifdef block).

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>

Build error #2:

Now, it turns out mini-ppc.h doesn't know MonoMethod, MonoMethodSignature, and MonoObject.
So, include object.h (MonoObject), which includes metadata.h (MonoMethod and MonoMethodSignature),
in mini-ppc.h.

	libtool: compile: gcc <...>  -c mono-context.c  -fPIC -DPIC -o .libs/mono-context.o
	In file included from mono-context.c:427:0:
	../../mono/mini/mini-ppc.h:37:2: error: unknown type name 'MonoMethod'
	  MonoMethod *method;
	  ^
	../../mono/mini/mini-ppc.h:306:31: error: unknown type name 'MonoMethodSignature'
	 mono_ppc_tail_call_supported (MonoMethodSignature *caller_sig, MonoMethodSignature *callee_sig) MONO_INTERNAL;
		                       ^
	../../mono/mini/mini-ppc.h:306:64: error: unknown type name 'MonoMethodSignature'
	 mono_ppc_tail_call_supported (MonoMethodSignature *caller_sig, MonoMethodSignature *callee_sig) MONO_INTERNAL;
		                                                        ^
	../../mono/mini/mini-ppc.h:312:27: error: unknown type name 'MonoObject'
	 mono_ppc_throw_exception (MonoObject *exc, unsigned long eip, unsigned long esp, mgreg_t *int_regs, gdouble *fp_regs, gboolean rethrow) MONO_INTERNAL;
		                   ^

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-12-24 15:52:07 -02:00
João Matos 052dd2c94e Merge pull request #1478 from mono/revert-1475-ppc64el-build-errors
Revert "Fix build errors in mono-context.c on ppc64el"
2014-12-24 11:43:37 -05:00
João Matos 30a7ba9808 Revert "Fix build errors in mono-context.c on ppc64el" 2014-12-24 16:42:17 +00:00
Miguel de Icaza 649f91f71b [System.IO.Compression.FileSystem] Fix infinite loop in ZipFile.Open(string,ZipArchiveMode) 2014-12-24 08:38:12 -02:00
João Matos 074873ab99 Merge pull request #1475 from mfoliveira/ppc64el-build-errors
Fix build errors in mono-context.c on ppc64el
2014-12-23 10:11:59 -05:00
Mauricio Faria de Oliveira e36ef8bda6 Fix build errors in mono-context.c on ppc64el
Build error #1:

	libtool: compile:  gcc <...> -c mono-context.c  -fPIC -DPIC -o .libs/mono-context.o
	mono-context.c: In function 'mono_sigctx_to_monoctx':
	mono-context.c:435:68: error: 'MONO_SAVED_GREGS' undeclared (first use in this function)
	  memcpy (&mctx->regs, &UCONTEXT_REG_Rn(uc, 13), sizeof (mgreg_t) * MONO_SAVED_GREGS);
		                                                            ^
	mono-context.c:435:68: note: each undeclared identifier is reported only once for each function it appears in
	mono-context.c:436:70: error: 'MONO_SAVED_FREGS' undeclared (first use in this function)
	  memcpy (&mctx->fregs, &UCONTEXT_REG_FPRn(uc, 14), sizeof (double) * MONO_SAVED_FREGS);
		                                                              ^
The MONO_SAVED_GREGS and MONO_SAVED_FREGS macros are defined in mini-ppc.h.
The problem happens because commit 7e056cd346
moved code using them from exceptions-ppc.h (which includes mini-ppc.h) to
mono-context.c (which doesn't), where they're not #included.

So, include mini-ppc.h in mono-context.c (in the existing powerpc ifdef block).

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>

Build error #2:

Now, it turns out mini-ppc.h doesn't know MonoMethod, MonoMethodSignature, and MonoObject.
So, include object.h (MonoObject), which includes metadata.h (MonoMethod and MonoMethodSignature),
in mini-ppc.h.

	libtool: compile: gcc <...>  -c mono-context.c  -fPIC -DPIC -o .libs/mono-context.o
	In file included from mono-context.c:427:0:
	../../mono/mini/mini-ppc.h:37:2: error: unknown type name 'MonoMethod'
	  MonoMethod *method;
	  ^
	../../mono/mini/mini-ppc.h:306:31: error: unknown type name 'MonoMethodSignature'
	 mono_ppc_tail_call_supported (MonoMethodSignature *caller_sig, MonoMethodSignature *callee_sig) MONO_INTERNAL;
		                       ^
	../../mono/mini/mini-ppc.h:306:64: error: unknown type name 'MonoMethodSignature'
	 mono_ppc_tail_call_supported (MonoMethodSignature *caller_sig, MonoMethodSignature *callee_sig) MONO_INTERNAL;
		                                                        ^
	../../mono/mini/mini-ppc.h:312:27: error: unknown type name 'MonoObject'
	 mono_ppc_throw_exception (MonoObject *exc, unsigned long eip, unsigned long esp, mgreg_t *int_regs, gdouble *fp_regs, gboolean rethrow) MONO_INTERNAL;
		                   ^

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-12-23 12:48:20 -02:00
Alex Rønne Petersen 95f9770413 Merge pull request #1472 from Aetf/zh-CHS-patch-fix-25554
Add zh-CHS parent_lcid handling
2014-12-22 18:50:07 +01:00
Mark Probst b4f51ba8e9 [sgen] Fix debug output for descriptor types. 2014-12-22 09:48:03 -08:00
Marcos Henrich e52f1e1f5a [runtime] mini-arm sequence point vars are only required to debug. 2014-12-22 10:51:40 +00:00
Marcos Henrich 44cbf38ddd [runtime] Do not emit seq points for entry/exit offsets on release.
METHOD_ENTRY_IL_OFFSET and METHOD_EXIT_IL_OFFSET are only used by the debugger agent.
2014-12-22 10:09:27 +00:00
Marcos Henrich 5054bd6233 [runtime] mono_if_conversion no longer breaks with OP_IL_SEQ_POINT.
mono_if_conversion now skips OP_NOP and OP_IL_SEQ_POINT while navigating through the instructions.
2014-12-22 10:03:12 +00:00
Aetf 7595f73821 fix coding style 2014-12-22 17:41:23 +08:00
Aetf 80d2c0a74f Add zh-CHS parent_lcid handling 2014-12-22 14:25:33 +08:00
João Matos dabfddfd28 Merge pull request #1470 from cmp-/fix-mutex-trylock-windows
Fix mono_mutex_trylock on Windows
2014-12-20 10:55:26 -05:00
cmp d34764ab2c Fix mono_mutex_trylock on Windows
mono_mutex_trylock is expected to return nonzero on failure, while
TryEnterCriticalSection returns nonzero on success.
2014-12-20 16:23:16 +01:00
Marek Safar 0fda579501 Merge pull request #1465 from akoeplinger/msbuild-getdirnameoffileabove
[xbuild] Implement GetDirectoryNameOfFileAbove ()
2014-12-20 00:09:49 +01:00
Marcos Henrich 6dfca8e721 [runtime] Check that sequence points have no effect on JIT code.
Added a test to check that each method of the test assemblies are JITed the same way with and without the sequence points enabled.
2014-12-19 20:53:46 +00:00
Zoltan Varga 3b5a261a1e Merge pull request #1375 from echampet/cleanup
TARGET_J2EE cleanup.
2014-12-19 14:59:51 -05:00
Miguel de Icaza 156ab8c5fc [Mono.DataConverter] Make it easier to use in PCL libraries 2014-12-19 14:55:25 -05:00
Marek Safar da7bfbe539 Merge pull request #1469 from akoeplinger/msbuild-missing-api
[xbuild] Add missing property 'StandardOutputImportance' to ToolTask
2014-12-19 16:15:05 +01:00
Alexander Köplinger a2f1dfbfcb Respond to code review feedback 2014-12-19 03:51:58 +01:00
Alexander Köplinger b4aa35a571 Respond to code review feedback 2014-12-19 03:45:25 +01:00
Ludovic Henry 22b3945b66 [runtime] Add support to trace generics 2014-12-18 15:47:43 -05:00
Ludovic Henry 4f3b70d511 [runtime] Fix #24605 : "counters not enabled" message with embeders 2014-12-18 15:47:42 -05:00
Alexander Köplinger ece634029e [xbuild] Add missing property 'StandardOutputImportance' to ToolTask
It's a stub and is currently not used by xbuild.
2014-12-18 19:58:51 +01:00
Alexander Köplinger b52e2e25f6 [xbuild] Implement GetDirectoryNameOfFileAbove ()
The method looks for the given file starting at the given path and traverses
the directory tree up until the file is found or root is reached.
2014-12-18 14:58:50 +01:00
Marcos Henrich 58f1c53708 [runtime] mono_local_deadce no longer breaks with OP_IL_SEQ_POINT.
Replaced ins->prev usages with mono_inst_prev (ins, FILTER_NOP | FILTER_IL_SEQ_POINT).
2014-12-18 11:04:36 +00:00
Marcos Henrich 702061aed0 [runtime] Updated amd64 with better OP_IL_SEQ_POINT handling. 2014-12-18 10:53:07 +00:00
Marcos Henrich f982e98f03 [runtime] OP_IL_SEQ_POINT no longer breaks mono_local_cprop
mono_local_cprop now uses mono_inst_next (ins, FILTER_IL_SEQ_POINT) which skips OP_IL_SEQ_POINT.
2014-12-18 10:32:36 +00:00
Marcos Henrich 7e6965d398 [runtime] mono_optimize_branches no longer breaks with OP_IL_SEQ_POINT.
bbn->code was replaced with mono_bb_first_inst (bbn, FILTER_IL_SEQ_POINT).
2014-12-18 09:00:01 +00:00
Marcos Henrich 77ee6e0e08 [runtime] mono_peephole_ins last_ins now skips OP_IL_SEQ_POINT. 2014-12-18 08:26:30 +00:00
Marcos Henrich bfb5185aab [runtime] Added helper methods to iterate MonoInst with filters.
Added methods mono_inst_next, mono_inst_prev, mono_bb_first_inst, mono_bb_last_inst
The added methods do respectively the same as ins->next, ins->prev, bb->code, bb->last_ins but skip the instruction until it matches the specified filter.
2014-12-18 08:15:53 +00:00
Alexander Köplinger 56ea776405 [xbuild] Only execute PCL target "ImplicitlyExpandTargetFramework" when corresponding property is true
This aligns xbuild with the MS.NET behavior.
2014-12-18 05:59:46 +01:00
Marcos Henrich d4a2bab840 Merge pull request #1462 from ExonyLimited/fix-25442
Performance fix for TimeZoneInfo.GetApplicableRule(), addresses #25442
2014-12-17 07:28:17 +00:00
Craig Minihan f0f976b985 Performance fix for TimeZoneInfo.GetApplicableRule(), addresses #25442
* Main use case - JSON.NET serialization of CLR objects containing DateTime fields, GetUtcOffset()=>GetApplicableRule() are the highest Mono methods in the profiler
* The property DateTime.Date access in the foreach is very expensive, this has been moved outside the foreach
* Performance for DateTime.Now passed as a parameter is 10x better than before
* This is the simplest possible change to yield an improvement, it would be better to replace the O(N) loop logic with a binary search - this yields a further 2-3x performance improvement, when master is building I may submit later
2014-12-16 17:19:36 -08:00
Marek Safar bb3fe582d5 [build] Fix bootstrap profile dependencies lib location 2014-12-17 00:09:01 +01:00
Mark Probst 4266d3bc98 [sgen] Never inline sgen_par_object_get_size().
This makes at least graph4 a lot faster.
2014-12-16 13:19:16 -08:00
Marek Habersack d8092c84a9 Bump the referencesource submodule
The new referenced commit in the submodule changes the macro used in the
mobile profile to disable CAS from MOBILE to DISABLE_CAS_USE
2014-12-16 21:50:11 +01:00
Marcos Henrich 67514a19d5 [runtime] remove_block_if_useless now ignores OP_IL_SEQ_POINT. 2014-12-16 20:28:27 +00:00
Marcos Henrich 2694840702 [runtime] mini-amd64 seq_point_info_var is only required to debug. 2014-12-16 20:28:27 +00:00
Marcos Henrich ab392debf4 [runtime] Added gen-compact-seq-points option to MONO_DEBUG.
gen-compact-seq-points can be used to enable the generation of the sequence points data required to map native offsets to IL offsets.
2014-12-16 20:28:27 +00:00
João Matos c021673939 Merge pull request #1336 from esdrubal/datatablereadxmlschema
DataTabe.ReadXmlSchema now handles non Schema base element.
2014-12-16 14:28:01 -05:00
João Matos 5742335f66 Merge pull request #1349 from martinjt/MachineKeyProtect
Implement MachineKey.Protect and MachineKey.Unprotect
2014-12-16 14:26:08 -05:00
João Matos 8597a88b69 Merge pull request #1459 from akoeplinger/fix-website-links
Updated the Mono website links in the man pages
2014-12-16 14:19:03 -05:00
João Matos b5ddc30ebc [System.IO.Compression] Fixed DeflateStream native error when handling empty input.
Bug: https://bugzilla.xamarin.com/show_bug.cgi?id=22346
2014-12-16 18:56:24 +00:00
Marek Safar 6c8b4c1e90 [buid] Fix bootstrap issue on cygwin 2014-12-16 16:00:14 +01:00
Alexander Köplinger 0c8492cbc6 Updated the Mono website links in the man pages
Even though the old links still work, we can save everyone an unnecessary redirect by using the new links.
2014-12-16 15:05:05 +01:00
Marek Habersack c2dce69079 Fix command stream encoding for FTP requests.
Whenever a connection to an FTP server is established, FtpWebRequest
sends an option command to the server to enable UTF8 encoding for the
transfer. So far we've failed to check the request status of that
command and assumed that UTF8 is enabled but *also* failed to actually
use the encoding when sending commands (we had the ASCII encoding
hard-coded). This resulted in failed requests whenever a command named a
file or path which included non-ASCII characters. This patch does two
things:

 * checks the status of the UTF8 enabling command and uses UTF8 encoding
   only if it succeeded. Otherwise Encoding.Default is used.
 * uses the encoding detected above for the command stream.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=24611

[Tests will follow at a later date]
2014-12-15 23:34:32 +01:00
Neale Ferguson e78a3c6857 Add per thread profiling support to s390x 2014-12-15 14:13:00 -05:00
Jo Shields f5e62d4d2f Merge pull request #1456 from directhex/fix_Microsoft.Build.Execution.BuildManagerTest.BuildCommonResolveAssemblyReferences
Fix Microsoft.Build.Execution.BuildManagerTest.BuildCommonResolveAssemblyReferences
2014-12-15 18:38:53 +00:00
João Matos e723d4ade5 [System] Relaxed Ping test to work under Linux.
So in Linux the PingTimeOut test was returning TtlExpired and failing the assertion. Since I'm not exactly sure how ping behaves under all platforms, relax the test to only make sure it doesn't succeed.
2014-12-15 17:06:27 +00:00
Jo Shields 70d3c7a23a Use net_4_5 libraries for xbuild tests, regardless of target.
This works around failures caused by tests asking for other frameworks (like 4.0) on Mono 4.0, which only has 4.5
2014-12-15 16:59:48 +00:00
Jo Shields d1a5f1d53a Move XBUILD_FRAMEWORK_FOLDERS_PATH definition somewhere useful & export
This variable isn't being passed to the child xbuild process during testing, making it sorta useless.
2014-12-15 16:58:14 +00:00
Alexis Christoforides e79dc945a5 [FileSystemWatcher] Properly handle multicast delegates.
Reverted the async delegate firing which is how Caching et al. expect FSW events; and properly handle the multicast case.

Also fixing a typo/regression in @2f1a136583c90cae805441e63b94bc4f277bb953
2014-12-15 11:05:19 -05:00
Marcos Henrich 25bcda516b Bump referencesource 2014-12-15 15:54:46 +00:00
Jo Shields 9bd865ecc3 Force MSBuildExtensionsPath to point to in-tree xbuild data
As-is, on non-Mac, Xbuild looks for MSBuildExtensionsPath in the folder specified by --prefix, i.e. /usr/local/mono/xbuild by default (which may not & should not exist).
2014-12-15 14:32:18 +00:00
Jo Shields 5b591e1098 Revert "Use ";" not Empty as bad TargetFrameworkDirectory value"
This reverts commit 7b58afa1c8.

Apparently this bad value passes on mac/wrench. So it's not a good failure condition for the test.
2014-12-15 13:37:19 +00:00
Jo Shields 7b58afa1c8 Use ";" not Empty as bad TargetFrameworkDirectory value
After manager.Build is called, a "null" empty for TargetFrameworkDirectory is
a string containing only ";" - a "good" value is the target framework
directory with a trailing ";". By testing for string.Empty, we don't actually
test whether the value has been correctly populated (causing all subsequent
failures).
2014-12-15 12:07:29 +00:00
Miguel de Icaza d16a01fe98 [System.Runtime.Serialization] Further baby steps 2014-12-14 00:02:45 -05:00
Miguel de Icaza 8f32e290ad [System.Runtime.Serialization] Dip toes into using ReferenceSource 2014-12-13 23:50:34 -05:00
Miguel de Icaza db6468e61e [Console/TerminfoDriver] Look in the TERMINFO directory if set 2014-12-13 23:49:51 -05:00
Miguel de Icaza 448f60e7f0 [System/SR] Brings some strings from .NET Core
Used the following script to do this:

var d = XDocument.Load ("Strings.resx");
foreach (var j in d.XPathSelectElements ("/root/data")){ var v = j.XPathSelectElement ("value"); Console.WriteLine ("\tpublic const string {0}=\"{1}\";", j.Attribute ("name").Value, v.Value); }
2014-12-13 19:58:06 -05:00
Miguel de Icaza fda6bf1a33 [Console] Updated to terminfo renderer.
This brings .NET's parameterized terminfo renderer, various fixes and
semantic changes.

The existing implementation of the Console did not have a proper an
implementation of terminfo's parameterized sequences.  Instead of
this, a collection of hacks existed to hardcode both light colors and
cursor position.  These are now gone, since the parameterized strings
do contain the correct values for this.

The search path for terminfo now picks the most modern location for
terminfo.   With the old paths in place.

The lookup for terminfo databases only supported the lookup based on
the first character of a terminal, so for example, for xterm this was
$terminfo_dir/x/xterm, but OSX and maybe other systems now store the
files in $terminfo_dir/78/xterm (where 78 is the hex representation of
'x', the first letter of the terminal name).

The fallback is still in place for other Unix systems.

We no longer use the built-in terminfo databases as the first pick,
instead we try to load the system terminfo database before we use the
built-in versions.

Worth figuring out if we want to remove the two built-in ones (Linux
and xterm) as broken terminfo databases are no longer the norm in Unix
and just keep the ansi one as a database of last resort.

This means that the console actually now gets high colors on MacOS,
not just Linux.

This also fixes the issue with consoles with more than 256 colors.  As
reported in bug 18315.
2014-12-13 19:37:39 -05:00
Marek Safar 8a061c8c8e Merge pull request #1451 from akoeplinger/fix-winforms-test
[MWF] Fix PropertyGridTest.PropertyGrid_ArrayParentTest by returning the correct value of PropertyCategoryDefault
2014-12-13 10:01:38 +01:00
Marek Safar 06a22be0a2 Merge pull request #1452 from esdrubal/xmlnamespace
[System.Xml.Linq] xmlns prefixes are no longer generated in some cases.
2014-12-13 10:01:11 +01:00
Marcos Henrich c750dcca8c Disable sequence points
Sequence points were disabled until the optimization issues it causes are handled.
2014-12-12 21:29:20 +00:00
Marcos Henrich c9f09f1354 Do not call seq_point_info_get_write_size with no seq points.
This change fixes a segfault when sequence points are disabled.
2014-12-12 21:29:19 +00:00
Marcos Henrich aad3c917e4 [System.Xml.Linq] xmlns prefixes are no longer generated in some cases.
- XNodeWrite.FillXmlns was adding a prefix to the attribute when no prefix was found (prefix==null)

  - XNodeWrite.LookupPrefix now returns string.Empty prefix when the namespace is the same as the element.
    A string.Empty prefix explicitly states that it has no prefix whereas null states that prefix was not defined.
    When LookupPrefix returns null for a namespace it means that a prefix should be generated first for anything that uses the namespace.
    That is what XmlSerializationWriter.GetQualifiedName does.

Fixes #24300
2014-12-12 19:50:15 +00:00
Marcos Henrich 2039c7d499 [System.Xml.Linq] Test XmlSerializer with custom namespace.
Covers #24300.
2014-12-12 19:01:51 +00:00
João Matos c7593a29f8 [System] Fixed Ping returning invalid results on OSX.
Simplify the code by re-using the OSX check from Platform which is more robust and add some tests to make sure we don't regress.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=25210.
2014-12-12 18:25:44 +00:00
Jonathan Pryor ade02c3f67 [mscorlib/Android] CultureInfo.ClearCachedData() clears DateTime.
Context: https://bugzilla.xamarin.com/show_bug.cgi?id=24947

When an Android user changes the timezone, those TimeZone changes
aren't reflected in Xamarin.Android apps. Part of this is a
Xamarin.Android bug, in which it needs to listen for TimeZone change
notifications and in turn let Mono know that the TimeZone changed.

Xamarin.Android can/will call Thread.CurrentCulture.ClearCachedData()
and Thread.CurrentUICulture.ClearCachedData() when the TimeZone has
changed. This will allow Mono to lookup the TimeZone info again.

At which point we hit two problems within Mono:

 1. TimeZoneInfo.AndroidTimeZones.Local is unnecessarily cached.
 2. DateTime itself caches the UTC offset for use by DateTime.Now.

TimeZoneInfo.Local is *already* cached, and TimeZoneInfo.Local is
properly cleared by TimeZoneInfo.ClearCachedData() while
TimeZoneInfo.AndroidTimeZones.Local wasn't. Removing the extra
cache allows the TimeZoneInfo to be looked up again.

Which brings us to DateTime.Now: for my simple test case, after
calling CultureInfo.ClearCachedData() the result of
DateTime.Now.ToString() didn't reflect the newly current TimeZone. The
cause for this was DateTime.to_local_time_span_object and
DateTime.last_now, which DateTime.Now uses as a cache for the
TimeZone's UTC offset.

Since these DateTime fields weren't cleared, subsequent DateTime.Now
invocations reported the *previous* TimeZone instead of the current
timezone.

To fix this, add an `internal` DateTime.ClearCachedData() method, and
call DateTime.ClearCachedData() from CultureInfo.ClearCachedData().
2014-12-12 12:29:04 -05:00
Alexander Köplinger bb100049e1 [MWF] Fix PropertyGridTest.PropertyGrid_ArrayParentTest by returning the correct value of PropertyCategoryDefault
The code in ComponentModel (https://github.com/mono/referencesource/blob/7dc4e513eafd3fb30d34111948ef14c981264463/System/compmod/system/componentmodel/CategoryAttribute.cs#L276) looks up the category name by string concatenation, which means it wasn't captured in our SR.cs.
We also can't add the correct value for PropertyCategoryDefault as a string constant to SR.cs since the value is retrieved via GetObject () and we currently just return the parameter name there.

A short-term workaround is to just special case PropertyCategoryDefault in GetObject ().
2014-12-12 02:39:02 +01:00
Zoltan Varga 8f21c92ad9 [amd64] Fix a simple peephole opt broken by the OP_IL_SEQ_POINT changes. 2014-12-11 19:30:07 -05:00
Zoltan Varga b9a6f0e669 [jit] Mark OP_IL_SEQ_POINT as not having side effects. 2014-12-11 19:14:18 -05:00
Zoltan Varga f372ba68ec [bcl] Fix another test failure caused by the usage of the reference version of System.ComponentModel. 2014-12-11 18:31:59 -05:00
Mark Probst 5e7e4438e7 [sgen] Add an assertion. 2014-12-11 15:02:15 -08:00
Mark Probst a8fd467805 [sgen] Use the SGEN_UPDATE_REFERENCE macro in optimized copy. 2014-12-11 15:01:45 -08:00
Mark Probst a532321bc4 [sgen] Fix evacuation.
We can't dereference an object's VTable before we know that it's not
tagged.  In this case, forwarded.  The access would be unaligned and
might even fault.
2014-12-11 14:57:58 -08:00
Zoltan Varga fcc0c902ea Revert "[jit] Enable tail calls from gshared code. Fixes #25224."
This reverts commit ca0dd5c0bb.

Revert this as it causes a performance regression in f#.
2014-12-11 17:51:19 -05:00
Alexis Christoforides 0146e5c751 Fix merge typo 2014-12-11 16:00:40 -05:00
Alexis Christoforides 2f1a136583 [System.IO.KeventWatcher] Fixed deadlock when watcher stopped/disposed from its own event handler.
This fixes hangs in tests that do that (ie. System.Runtime.Caching).
2014-12-11 15:44:54 -05:00
Zoltan Varga ca0dd5c0bb [jit] Enable tail calls from gshared code. Fixes #25224. 2014-12-11 15:40:00 -05:00
Zoltan Varga cd74f7a191 [jit] Remove some dead code. 2014-12-11 15:40:00 -05:00
Joao Matos 4733e56feb [runtime] Fixed shutdown crasher in mono_thread_pool_cleanup.
We call `mono_thread_pool_cleanup` twice from `mono_runtime_try_shutdown` and later `mono_domain_finalize`, which meant we tried to destroy the semaphore twice and that caused a crasher.

Fix this by clearing out the semaphore pointer. That way when we try to destroy it again it's already null and execution continues just fine.
2014-12-11 18:47:11 +00:00
Zoltan Varga 2040537203 [sdb] Fix the decoding of the next array when decoding sequence points. 2014-12-11 13:23:08 -05:00
Joao Matos 7453ec0520 [sgen] Fixed dump_alloc_records() to work on MSVC.
We are getting some crashers in printf when using the 'z' size_t printf specifier.
2014-12-11 17:49:06 +00:00
Joao Matos 9e85fd5fa9 [sgen] Align vtable pointers to 8-bytes for phony vtable used for filling the nursery.
Thanks to Kumpera for providing the fix!
2014-12-11 17:48:56 +00:00
Mark Probst e8791b18fe [sgen] Disable evacuation temporarily to fix crashes. 2014-12-11 09:30:12 -08:00
Zoltan Varga 0e311c027d [sdb] Another try at fixing #25009. 2014-12-11 11:58:41 -05:00
Marek Safar 554ee2294d Fix DateTimeConverter test 2014-12-11 13:40:29 +01:00
Zoltan Varga c4d9659266 [sdb] Fix another shutdown crash. Fixes #25009. 2014-12-11 07:34:04 -05:00
Vlad Brezae 49830fb910 Populate small id field for MonoInternalThread structure. 2014-12-10 12:22:42 -08:00
Rodrigo Kumpera 5572635566 Merge pull request #1403 from schani/fix-roslyn-linux-oom
Fix Roslyn Linux OOM
2014-12-10 10:53:16 -05:00
Atsushi Eno 8432d2d010 bump rx to rx-oss-v2.2 and add branch info on .gitmodules. 2014-12-10 23:16:35 +08:00
Marek Safar b691656aaf [mcs] Better recovery from failed async return type inference. Fixes #25165 2014-12-10 15:08:01 +01:00
Jo Shields 72c52fe46c Distribute reference assemblies in source tarball. Yuck. 2014-12-10 12:57:14 +00:00
Marek Safar f893a4ca84 [System.Drawing] Fixes commit 2abd0ed92e 2014-12-10 12:52:23 +01:00
Marek Safar 922ec7ce2a [mcs] Update static using to match the latest update (still work in progress) 2014-12-10 12:32:21 +01:00
Marek Habersack 99b622120b Specify referencesource branch in .gitmodules to make updating easier 2014-12-10 11:33:14 +01:00
Marek Habersack 7856988e65 Update external/referencesource to fix mobile builds 2014-12-10 11:31:27 +01:00
Mark Probst 4e58de23d2 [sgen] Always alloc degraded when nursery allocation fails.
There's an unlikely case that Roslyn triggers quite often on Linux: A
thread tries to allocate from the nursery, but it's full.  It triggers
a nursery collection, then tries allocating again.  Between the
collection and the allocation retry, another thread fills the nursery
so that the retry also fails.

We failed an assertion in this case.  Now we always go to the major
heap if it happens.
2014-12-09 17:31:25 -08:00
Zoltan Varga bcc31684e4 [arm] Really fix the build. 2014-12-09 18:34:35 -05:00
Zoltan Varga 7a242d8132 [arm] Fix the build. 2014-12-09 18:19:46 -05:00
Mark Probst d45c58afcd [runtime] Fix string size calculation in mono_string_new_size().
This bug is not hit when doing managed allocations with SGen because the
managed allocator catches it.  It can be triggered with the embedding API, as
well as when the heavy binary protocol is enabled, in which case `bug-17590`
fails.
2014-12-09 13:16:25 -08:00
Zoltan Varga 2607beed06 [runtime] Allow StructLayoutAttribute.Pack values between 16 and 128. Fixes #25059. 2014-12-09 15:40:11 -05:00
Zoltan Varga 2abd0ed92e [System.Drawing] Add support for a null culture argument to the ConvertFrom () method in RectangeConverter/SizeFConverter, the reference sources version of TypeConverter.ConvertFromString () passes null as the culture. 2014-12-09 15:16:49 -05:00
Zoltan Varga 476e87f593 [System.Data] Fix a test failure caused by the transition to the reference sources version of System.ComponentModel. 2014-12-09 14:53:18 -05:00
Marcos Henrich b99438f021 Merge pull request #1436 from esdrubal/readerwriterlockslim
[System.Core] Bring .NET implementation of ReaderWriterLockSlim.
2014-12-09 19:01:46 +00:00
Zoltan Varga 5c39898c62 Merge pull request #1448 from ermshiperete/TSBTextTruncation
[MWF] Don't truncate text on ToolStripButton
2014-12-09 13:34:47 -05:00
Zoltan Varga eb60df89d0 Merge pull request #1449 from ermshiperete/Xamarin-bug-23591
[MWF] Fix crash in multi-selection list view
2014-12-09 12:29:58 -05:00
Eberhard Beilharz c7ad829794 [MWF] Fix crash in multi-selection list view
Calling owner.UpdateMultiSelection can also change the selected item,
causing a crash.

This change improves the fix for Xamarin bug #23591.
2014-12-09 18:15:12 +01:00
Paolo Molaro bb4213224a [profiler] Enhance the profiler to keep track of and summarize jit trampolines and helpers. 2014-12-09 17:47:28 +01:00
Paolo Molaro 2946a09c04 [profiler] Report trampolines and other JIT helpers to the profiler. 2014-12-09 17:47:28 +01:00
Paolo Molaro 5664e72b7c [jit] Expose helper method to the rest of the JIT to get specific trampoline descriptions. 2014-12-09 17:47:28 +01:00
Paolo Molaro 017c171b36 [profiler] Provide more options for describing jit code buffers precisely. 2014-12-09 17:47:28 +01:00
Jo Shields 11a5109e41 ReferenceSource ComponentModel changes to mobile_System.dll.sources 2014-12-09 16:44:27 +00:00
Eberhard Beilharz c66e9e63c2 [MWF] Don't truncate text on ToolStripButton
Previous code subtracted 4 pixels of the height of the text of a
toolstrip button, presumably to leave a margin. However, margins
are handled elsewhere, so we ended up with truncated text.
2014-12-09 17:22:30 +01:00
Marek Safar 8a249042e4 [system] Workaround boostrap issue with HostProtectionAttribute 2014-12-09 15:56:45 +01:00
Zoltan Varga 91e3a07ece Merge pull request #1447 from chrisvire/bug-25102
[MWF] Use Ctrl+PageUp/PageDown for Tab Navigation
2014-12-09 09:25:03 -05:00
Marek Safar 0cff8cb933 [corlib] Workaround boostrap issue with HostProtectionAttribute 2014-12-09 15:09:34 +01:00
Marek Safar 767b1570f2 [System] Use ComponentModel from reference sources 2014-12-09 14:30:40 +01:00
Marek Safar c64b1d4809 Merge pull request #1446 from odinserj/master
Add DateTimeOffsetConverter to the default converters list
2014-12-09 10:03:30 +01:00
Marek Safar 8913ef3449 make dist fix 2014-12-09 09:59:25 +01:00
Marek Safar 7ac15125c0 Fix dmcs to have correct sdk value 2014-12-09 09:46:47 +01:00
Marek Safar 5c7bc03833 Update mcs test 2014-12-09 09:30:14 +01:00
Zoltan Varga 5e46fb50ca [sdb] Fix more crashes on shutdown when the assembly unload callbacks are called on the debugger thread. Fixes #25009. 2014-12-08 17:54:42 -05:00
Zoltan Varga 56a0a9e75e [build] Print out the version of the bootstrap mcs if the profile check fails. 2014-12-08 15:56:01 -05:00
Zoltan Varga b7925f2cfd [runtime] Remove the bug-438454.exe test, it tests behaviour which is by design. 2014-12-08 15:48:17 -05:00
Zoltan Varga bab4b8f9d2 [runtime] Add another rule for the builder-sgen.h -> main-sgen.o dependency since apparently some versions of automake etc. generate a main-sgen.o file too. 2014-12-08 15:18:06 -05:00
Zoltan Varga e0b6b44866 Revert "[build] Rework the buildver dep check."
This reverts commit a9f31e63db.

Revert this as it breaks make dist by having a source file depend on a generated file.
2014-12-08 15:18:06 -05:00
Marek Safar b304ec5e0e gmcs script is no longer installed.
The intention is to make build failures easy to spot instead of silently upgrading
target framework from 2 to 4 and then fail down the road on e.g type ambiguity
caused by new 4.0 framework types or methods
2014-12-08 19:59:07 +01:00
Sergey Odinokov 4a8e13a99b Add DateTimeOffsetConverter to the default converters list.
This is the fix for https://bugzilla.xamarin.com/show_bug.cgi?id=25158

Current implementation does not contain the DateTimeOffsetConverter
in the list of default converters. This cause NotSupportedException
to be thrown when trying to serialize/deserialize DateTimeOffset
values to/from strings.

In .NET Framework implementation this class is added to such a list.
2014-12-08 21:59:00 +03:00
Alex Rønne Petersen 41ee4e7cee Use git://... instead of git@... for submodules. 2014-12-08 19:40:15 +01:00
Marek Safar 067634117c [corlib] Update SafeHandle dispose pattern to match .net. Fixes #25132 2014-12-08 17:51:38 +01:00
Marek Habersack 142b512e9a Added reference-assemblies submodule to fix the build 2014-12-08 17:23:11 +01:00
Marek Safar 9546550237 Change 4.0 profile to metadata reference only profile 2014-12-08 16:46:54 +01:00
Marek Safar e00126f61e [corlib] Remove duplicate FirstChanceExceptionEventArgs 2014-12-08 16:46:53 +01:00
Atsushi Eno bcfec743d5 [mkbundle] fix execution for X.Android on Windows regarding dos2unix.
This fixes bug #25086 (Xamarin.Android). Details described there.

To fix the issue, we use #if XAMARIN_ANDROID to avoid that old cygwin-only
code path. (We are not sure if simply removing the old code still works,
so we don't remove that for now.)
2014-12-08 23:40:52 +08:00
Chris Hubbard 80b32bec27 [MWF] Use Ctrl+PageUp/PageDown for Tab Navigation
In the Windows implementation of the TabControl, Ctrl+PageUp
navigates to the previous tab and Ctrl+PageDown navigates to the
next tab (with both wrapping around).  This change implements this
feature in the Mono implementation.

Change-Id: Ib940bd08d5ba641f05ed91c0e789e356e68f72bb
2014-12-08 10:35:56 -05:00
Marek Safar 73699dc332 [system] Replace System.Collections.Generic from reference sources 2014-12-08 12:04:28 +01:00
Marek Safar f22e4d8986 [system] Add test for #25137 2014-12-08 12:04:28 +01:00
Marek Safar fb85eae8fc [system] Fix soctec test to not block indefinitely 2014-12-08 12:04:28 +01:00
Marek Safar a6e0aefa29 Merge pull request #1445 from meebey/registry_fix_unneeded_write_permission
[corlib] Fix needing write permission when reading registry values. Fixe...
2014-12-08 10:49:01 +01:00
Mirco Bauer 55e85a6da8 [corlib] Fix needing write permission when reading registry values. Fixes #25106
ToKey() ignores the setting parameter when calling RegistryKey.OpenSubKey() and
thus always asks for write permission. If you try to read read-only keys (say
HKLM without admin rights) it will fail with a  SecurityException.
2014-12-08 10:39:20 +01:00
Zoltan Varga 2a8f86f223 [amd64] Fix the passing of nested structures in registers which cross an 8 byte boundary in pinvoke. Fixes #25095. 2014-12-06 06:18:02 -05:00
Alexis Christoforides e010856ace [canaries] Removed accidental hardcode 2014-12-05 15:53:55 -05:00
Alexis Christoforides fdf9cf74a6 [runtime] Replace offsetof with G_STRUCT_OFFSET on commit's @b0cff959e47c3d9955e6675364bf71404cd74bac changes 2014-12-05 15:48:21 -05:00
Alexis Christoforides b5ed5a3631 [System.IO.KeventWatcher] More fixes and MS behavior matching for the new implementation.
* Fixed the FileSystemEventArgs.Name property for all events
* Fixed regression of bug #5747 (and related path normalizing issues) https://bugzilla.xamarin.com/show_bug.cgi?id=5747
* Improved error handling, set hard limit on file descriptors to 200 for now to help isolate issues
* Fixed issues with rapid event Changed+Renamed firing
2014-12-05 15:09:59 -05:00
Mark Probst 2f8e36d300 [sgen] Remove debugging comment. 2014-12-05 11:55:20 -08:00
Mark Probst 6c60288739 [sgen] Fix pinning in the presence of canaries. 2014-12-05 11:11:02 -08:00
Zoltan Varga 2b19bdc99c Merge pull request #980 from StephenMcConnel/bug-18638
Fix bugs in sizing TableLayoutPanel (Xamarin bug 18638)
2014-12-05 14:09:00 -05:00
Zoltan Varga c49994e904 Merge pull request #1442 from ermshiperete/TextOverlapsImage
[MWF] Fix problem when button text overlaps image
2014-12-05 14:07:39 -05:00
Zoltan Varga a1ab4919b0 Merge pull request #1322 from StephenMcConnel/bug23532
Remove excessive shortcut key matching in ToolStrip
2014-12-05 14:07:20 -05:00
Zoltan Varga fd556a44fe Merge pull request #1323 from StephenMcConnel/bug-23591
Fix potential crash in ListView.ItemControl.ItemsMouseDown
2014-12-05 14:06:36 -05:00
Jonathan Pryor 8be960fc36 [mscorlib/Android] TimeZoneInfo.Local.Id should NOT be "Local".
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=24742
Context: Commit f7fd52ad
Context: https://bugzilla.xamarin.com/show_bug.cgi?id=24958

The logic of Commit f7fd52ad was 'Desktop Mono returns "Local" from
TimeZoneInfo.Local.Id, so surely Xamarin.Android should', predicated
in part on the assumption that whatever Desktop Mono does should be
the same as what Desktop .NET does.

This assumption wasn't verified, and is in fact wrong; Desktop .NET
doesn't return "Local" from TimeZoneInfo.Local.Id, it returns an
actual identifier.

The reason why Desktop Mono returns "Local" is due to implementation
sanity, particularly on OS X: /etc/localtime may be a symlink OR a
copy of the timezone data, and when it's a copy there's no way to
determine the Olson ID for the timezone. Consequently, it may not be
possible to determine the TimeZone ID.

Xamarin.Android doesn't have that problem; it uses the Android
persist.sys.timezone system property value,
falling back to java.util.TimeZone.getDefault().getID() if necessary,
and thus always has access to an Olson ID.

Change TimeZoneInfo.Local.Id on Xamarin.Android to return the Olson ID
instead of "Local", partially reverting Commit f7fd52ad.
2014-12-05 13:36:04 -05:00
Marek Safar 1e1f1fc5b9 Update profiler tests environment 2014-12-05 18:51:28 +01:00
Marcos Henrich 2b668c2e50 Bump referencesource 2014-12-05 17:12:28 +00:00
Marek Safar 21bd41b1d6 [mcs] Fix null operator on arrays with property receiver. 2014-12-05 17:57:36 +01:00
Marek Safar 385bda0cad Merge pull request #1443 from esdrubal/userinfoescape
[System] Fixed UriParseComponents.ParseUser.
2014-12-05 17:41:05 +01:00
Eberhard Beilharz 3ae08e65b8 [MWF] Fix problem when button text overlaps image
When we draw a button with ImageAboveText.ImageAboveText and the
text is too big to fit below the image we have to draw the text over
the image. This should happen from the bottom, not from the top as
the previous implementation did. With the previous code we ended up
having the text at the top of the button under certain conditions.
2014-12-05 17:35:35 +01:00
Marcos Henrich b97f24c4ad [System] Fixed UriParseComponents.ParseUser. Fixes #25087.
UriParseComponents.ParseUser was unescaping all escaped chars and when a non valid user info char was encountered it was assuming that those chars were not part of the user info. The chars were not consumed thus the problems while parsing the rest of the input.
UriParseComponents.ParseUser now keeps non valid user info chars escaped.
2014-12-05 16:13:57 +00:00
Marcos Henrich f7ead304f6 [System] Test Uri constructor with escaped user info chars. 2014-12-05 16:11:32 +00:00
Marek Safar 2c6eb4f9b7 [mcs] Add dictionary initializer for arrays. 2014-12-05 16:51:25 +01:00
Marek Safar 79c0d7bcd3 Update runtime tests environment 2014-12-05 16:39:44 +01:00
Marek Safar 9df8a9e4f7 Fix resgen 4.0 profile path 2014-12-05 15:03:04 +01:00
Zoltan Varga ad5e7e102a Fix the DISABLE_REMOTING build. 2014-12-05 08:51:27 -05:00
Marek Safar b993596e59 Restore 4.0 profile as metadata only profile 2014-12-05 12:01:50 +01:00
Marek Safar 0c99796db6 [corlib] Add missing API 2014-12-05 12:01:50 +01:00
Atsushi Eno 991658d40d revive nunit-console which referenced lib/mono/2.0.
Actually the entire REWRITE2_* should be killed.
2014-12-05 14:55:33 +08:00
Mark Probst 8d2613ef44 Fix a C compiler warning. 2014-12-04 14:35:27 -08:00
Alex Rønne Petersen a46e3a51ba No longer include Volatile.cs in Mvc3 since the 4.0 profile is gone now. 2014-12-04 19:53:33 +01:00
Marek Safar db94f6284f Add System.Data.Entity assembly 2014-12-04 18:59:42 +01:00
Marek Safar 9f86d82be8 Bump referencesource 2014-12-04 18:54:41 +01:00
Marek Safar 2fa7448bf6 [corlib] Add missing API to AppDomainSetup 2014-12-04 18:49:45 +01:00
Marcos Henrich 049533031d Bump referencesource submodule. 2014-12-04 17:40:13 +00:00
Marek Safar b71ef88f44 Merge pull request #1441 from akoeplinger/fix-incorrect-test
[System.Web.DynamicData] Fixed test to verify the right behavior
2014-12-04 17:46:07 +01:00
Marek Safar 7fb7c91aaa Fix xbuild profile dependencies 2014-12-04 16:25:17 +01:00
Marek Safar 29b89dbfc9 Remove old (now unused) 2.0 sources 2014-12-04 15:25:41 +01:00
Marek Safar a1aced8ab2 Remove 4.0 profile 2014-12-04 15:16:31 +01:00
Marek Safar 336755ca9e [mcs] Validate more nameof argument expressions 2014-12-04 14:18:18 +01:00
Alexander Köplinger e6a473c659 [System.Web.DynamicData] Fixed test to verify the right behavior
The exception that is thrown is now consistent with MS.NET due to the imported System.ComponentModel.DataAnnotations code.
2014-12-04 02:35:39 +01:00
Marek Safar b50017eba3 [mcs] Improve extension methods error reporting 2014-12-03 22:02:22 +01:00
Marek Safar 93dfcdb60a [mcs] At least one of nameof methodgroup argument candidates needs to be accessible 2014-12-03 22:02:22 +01:00
Marek Safar 0f7d153c0b [mcs] Add support for __refvalue passed as a reference 2014-12-03 22:02:21 +01:00
Joao Matos de77d24361 [driver] Fixed outdated URL in help message. 2014-12-03 20:57:35 +00:00
Joao Matos d509226413 [msvc] Fixed heap problems at runtime when calling free().
Due to an incompatibility in the project files and DLL API setup code, we were importing locally defined symbols as DLL. This manifested as a debug heap dialog in VS caused by allocating and freeing memory between two Windows modules (which have their own memory heap).

Fix this by simplifying the DLL defines in MSVC, we are relying on .def files to manually specify the exports anyway.
2014-12-03 20:56:52 +00:00
Joao Matos 60361f26eb [msvc] Updated project files. 2014-12-03 20:07:23 +00:00
Joao Matos 23467f62c2 [msvc] Fixed empty struct declaration (it's not valid C according to MSVC). 2014-12-03 20:06:59 +00:00
Joao Matos b69666d434 Removed some dead code. 2014-12-03 20:05:40 +00:00
Joao Matos 562e497f8b [msvc] Fixed missing semi-colon. 2014-12-03 20:04:39 +00:00
Marcos Henrich 3a613dfd42 [runtime] Added missing else branch setting il_offset to -1. 2014-12-03 18:45:00 +00:00
Alex Rønne Petersen bc876c2427 [bcl] Remove all uses of Thread.Volatile{Read,Write}.
These methods are broken, misleading, and generally harmful. Always prefer the
`Volatile` class over these to make intent clear and to get sensible semantics.

http://blog.alexrp.com/2014/03/30/dot-net-atomics-and-memory-model-semantics/
2014-12-03 19:19:51 +01:00
Alex Rønne Petersen aec3ef0e8e Fix a bunch of warnings in the runtime code. 2014-12-03 19:13:58 +01:00
Zoltan Varga fa9c1f016c Fix make dist if boehm is disabled. 2014-12-03 17:33:11 +01:00
Jonathan Pryor 77e11f7fa9 [mscorlib/Android] Support TimeZoneInfo.FindSystemTimeZoneById("Local")
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=24741

Xamarin.Android didn't previously support
TimeZoneInfo.FindSystemTimeZoneById("Local") because of oversight (and
overly nested #if conditionals).

Compare `id` against "Local" *before* doing platform-specific
codepaths so that finding the "Local" TimeZone works as expected on
Xamarin.Android, and merge the `#if MONODROID` with the existing code.
2014-12-03 11:25:29 -05:00
Marcos Henrich 5c02f3efab [System.Core] Removed no longer used files.
System.Core is now using .NET implementations of LockRecursionPolicy and ReaderWriterLockSlim.
2014-12-03 13:24:22 +00:00
Marcos Henrich 4e735b6e30 [System.Core] Bring .NET implementation of ReaderWriterLockSlim. 2014-12-03 13:24:21 +00:00
Jo Shields 6856ccab7c Merge pull request #1410 from alesliehughes/master
Improved support for TimeZoneInfo under windows.
2014-12-03 12:20:13 +00:00
Zoltan Varga 90977ef96c Merge pull request #1437 from jonorossi/io_compression_fs_fix
Fixed ZipFile.CreateFromDirectory overload to use compressionLevel
2014-12-03 07:40:21 +01:00
Zoltan Varga e6b3e75226 Merge pull request #1438 from jonorossi/patch-1
Fixed incorrect markdown syntax for two links
2014-12-03 07:39:41 +01:00
Jonathon Rossi 184324e9cb Fixed incorrect markdown syntax for two links 2014-12-03 16:27:04 +10:00
Jonathon Rossi 7cabb3706b Fixed System.IO.Compression.FileSystem.ZipFile.CreateFromDirectory overload to use compressionLevel. 2014-12-03 16:13:06 +10:00
Mark Probst 8dde6e2c81 [sgen] Remove SGEN_HAVE_CONCURRENT_MARK.
We always have concurrent mark.
2014-12-02 15:16:14 -08:00
Marek Safar 080b48683c [xbuild] Update another default tools setting 2014-12-02 23:29:15 +01:00
Marek Safar dfebf124e5 Change bootstrap profile to target 4.0 framework. Bump system mono requirement to version 3.2 at least 2014-12-02 22:37:43 +01:00
Mark Probst f766a777e6 [counters] ulongs can be time, too. 2014-12-02 12:39:54 -08:00
Neale Ferguson 0526e429aa Minor reformatting 2014-12-02 13:59:03 -05:00
Zoltan Varga bc7badab34 Merge pull request #1434 from akoeplinger/fix-filehandle-leak
[counters] Fix file handle leak in cpu_load ()
2014-12-02 18:06:41 +01:00
Rodrigo Kumpera 3954590386 Merge pull request #1317 from nealef/master
Enable build on RHEL and CentOS
2014-12-02 10:16:06 -05:00
Marek Safar d9d6806867 [mcs] nameof implementation rewrite to match the latest spec 2014-12-02 16:01:59 +01:00
João Matos 320b2264cd Merge pull request #1435 from akoeplinger/fix-s390-build
Fix build on s390
2014-12-02 09:28:04 -05:00
Alex Rønne Petersen c9e3a47dd7 Merge pull request #1400 from RiJo/patch-1
Let ListViewItem implement interface IDataItemContainer
2014-12-02 05:55:21 +01:00
Alexander Köplinger e6bd66abf6 Fix build on s390 2014-12-02 05:49:59 +01:00
Alexander Köplinger b2b0d6c00f [counters] Fix file handle leak in cpu_load ()
If a premature return is taken, the FILE pointer f is not fclose()-ed.

Report and fix provided by Markus Beth on the mailing list: http://lists.ximian.com/pipermail/mono-devel-list/2014-December/042459.html
2014-12-02 05:41:00 +01:00
Mark Probst d09264fa13 [sgen] Fix 32 bits.
We didn't allocate proxy vtables aligned to 8 bytes.
2014-12-01 18:03:08 -08:00
Mark Probst 31fba69618 [sgen] Fix a bug when waking up workers. 2014-12-01 15:32:49 -08:00
Etienne CHAMPETIER a4134641d8 [cleanup] WebConfigurationManager: remove hasConfigErrors
it's not used since 2009 (6a261e04ad)

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-12-01 23:57:19 +01:00
Etienne CHAMPETIER 227b0d1b55 [cleanup] System.Web*: remove TARGET_J2EE
done using unifdef
git grep -l TARGET_J2EE | grep -v ChangeLog | xargs -n1 unifdef -m -UTARGET_J2EE

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-12-01 23:57:18 +01:00
RiJo 56178e6215 ListViewItem class now implements interface IDataItemContainer 2014-12-01 15:07:23 +01:00
Zoltan Varga ded052883b Fix a layout problem in the mono man page. 2014-12-01 10:45:19 +01:00
Zoltan Varga 92388f7d09 [runtime] Add support for jagged array ctors which create an array of arrays. Fixes #17944. 2014-12-01 10:26:51 +01:00
Zoltan Varga 33861cf32b Merge pull request #1412 from esdrubal/stackframe
Release sequence points and Symbolicate tool
2014-11-30 15:11:03 +01:00
Zoltan Varga c1d6e85d4a [runtime] Call mono_gc_base_init () in sdb, since it is no longer called by the code in mono-debug.c. 2014-11-30 15:02:46 +01:00
Zoltan Varga 7c009e0ece Fix the build. 2014-11-30 11:32:09 +01:00
Zoltan Varga 743ef03fd9 [runtime] Use SIGWINCH as the android debugger signal (), SIGUSR2 doesn't seem to work on emulators. 2014-11-30 03:13:03 +01:00
Zoltan Varga 173eaf1dfa Merge remote-tracking branch 'mfoliveira/ppc64el-v2'
This is a merge of:

https://github.com/mono/mono/pull/1409
2014-11-30 02:48:38 +01:00
Zoltan Varga 79bbcb6c04 [runtime] Remove some unused metadata includes from utils/. 2014-11-30 02:34:13 +01:00
Marek Safar f8a517624d Fixes build 2014-11-28 21:34:15 +01:00
Marek Safar e24b4f1d34 [mcs] new test 2014-11-28 20:23:40 +01:00
Marek Safar c1118b521e [mcs] Less cascading errors 2014-11-28 18:22:40 +01:00
Marek Safar 7e39c6e604 [mcs] Extend tie-breaking rules in overload resolution when default parameters are unused 2014-11-28 18:22:39 +01:00
João Matos 59c664f04e [build] Added support for ARM64 Android cross-compilation. 2014-11-28 17:07:05 +00:00
Alex Rønne Petersen e666a5ee28 Merge pull request #1401 from fquiroz01/patch-1
Add IE9 and newer to Up level navigator
2014-11-28 18:05:35 +01:00
Zoltan Varga 760db842cc [runtime] Fix a copyright date. 2014-11-28 17:43:19 +01:00
Marek Safar 4316b458e3 [mcs] Check delegate return type conversion during implicit delegate conversion 2014-11-28 15:23:09 +01:00
Marek Safar 69de3c2bd4 [mcs] Tweak naming of nested types. Fixes #24172 2014-11-28 13:24:36 +01:00
Zoltan Varga fff6d6d6f4 [runtime] Add a remoting.h file and move the remoting related marshal function declarations there. Add a low level lock used by the remoting.c file and an initialization function. 2014-11-28 06:23:48 +01:00
Zoltan Varga 9c658f2031 [runtime] Fix the build. 2014-11-28 06:15:05 +01:00
Zoltan Varga e211e33c1e [runtime] Fix the DISABLE_REMOTING build. 2014-11-28 05:55:18 +01:00
Zoltan Varga 3769cef763 [runtime] Extract the remoting code from marshal.c into a separate remoting.c file. 2014-11-28 05:50:39 +01:00
Zoltan Varga 7ac6b6b937 [runtime] Remove more unused debug code. 2014-11-28 03:40:42 +01:00
Zoltan Varga 69ba0b04fd [runtime] Simplify mono-debug.c since we no longer have to serialize a lot of the data. 2014-11-28 03:36:56 +01:00
Zoltan Varga 62e4fbe3ca [runtime] Remove an obsolete comment. 2014-11-28 01:10:03 +01:00
Zoltan Varga c476529db3 [runtime] Change the default runtime version to 4.5. 2014-11-28 01:07:15 +01:00
Alex Rønne Petersen d4ce72973d Merge pull request #1431 from esdrubal/enummap
Fixed how EnumMap serializes flag values.
2014-11-28 00:30:44 +01:00
Zoltan Varga 1e662349d1 Make the various '2' (al2/resgen2 etc.) scripts target net 4.5. 2014-11-28 00:26:28 +01:00
Zoltan Varga e037864832 Fix the build. 2014-11-28 00:11:27 +01:00
Marcos Henrich 37dabfc9f1 Fixed how EnumMap serializes flag values. Fixes #21072.
While serializing an enum value, EnumMap no longer considers partial matching flags when there is a flag that matches exactly.
2014-11-27 16:51:39 +00:00
Marcos Henrich 0eaf2a4ea1 Test DataContractSerializer with flags enum. Covers #21072.
When serializing an enum value, matching flags should not be consider when there is a flag that matches exactly.
2014-11-27 16:51:22 +00:00
Zoltan Varga 5314425331 Make gmcs/dmcs the same as mcs. 2014-11-27 17:42:10 +01:00
Marek Safar c7d8c2bb96 [mcs] Update import of private struct fields for flow analysis. 2014-11-27 17:36:44 +01:00
Marek Safar 0602561a31 Merge pull request #1432 from akoeplinger/parallel-fix
[corlib] Fix Parallel.ForEach overload that hardcoded -1 for the item index
2014-11-27 16:12:11 +01:00
Alexander Köplinger f5c32ef7bd [corlib] Fix Parallel.ForEach overload that hardcoded -1 for the item index
Xamarin bug #24891
2014-11-27 16:08:18 +01:00
Jo Shields 3080be5f20 Fix EXTRA_DIST of file in deleted regex folder 2014-11-27 11:22:03 +00:00
Alexander Köplinger fb7332bec1 [MWF] Fix bug in DataGridViewRowCollection Clear() introduced by recent commit
7d1b878fbf altered the behavior of removing rows, breaking
the DataGridViewRowCollectionTest.ClearRows () test

Before the change, this is what happened when the list was cleared
(the number in brackets is the value of the Index property of the DataGridViewRow):

[0]  Remove   [1]  ReIndex  [0] Remove  [1] ReIndex  [0]
[1] --------> [2] --------> [1] ------> [2] -------> [1]  ...
[2]           [3]           [2]
[3]

After the offending commit, ReIndex is only called after the list is cleared, which means
the Index property of the rows is never updated (as there are no items in the list).

The fix is to explicitly set the Index of each row to 0.
This was the end result before the commit anyway, so we can omit the ReIndex call entirely.
2014-11-27 12:11:20 +01:00
Marek Safar b044fa0f26 [system.net.http] Update range checks for invalid characters. Fixes #18800 2014-11-27 11:58:49 +01:00
Jo Shields a42ca4aeb2 Fix "make dist" error caused by renamed sgen-marksweep-drain-gray-stack.h 2014-11-27 09:20:39 +00:00
Alexander Köplinger 8473459f32 Fix build (SHARED_EXT was renamed to MONO_SOLIB_EXT in 4342bce441) 2014-11-27 03:26:11 +01:00
Marek Safar 21ac07aa0a [system.net.http] Escape more RFC5987 characters. Fixes #24785 2014-11-27 09:07:46 +01:00
Miguel de Icaza bb1d917b88 Merge pull request #1430 from akoeplinger/readme
Improve README.md and focus on relevant content
2014-11-26 22:17:23 -05:00
Alex Rønne Petersen e4aa060bea Merge pull request #1319 from directhex/systemwide-per-arch-aot-cache
Add a third AOT location, alongside ~/.mono/aot-cache and the assembly dir
2014-11-27 01:28:49 +01:00
Alexander Köplinger f6d6af35d7 Improve README.md and focus on relevant content
Before, the first thing the user saw were instructions for niche platforms like Itanium or Solaris.
Instead, we now just link to the "Compiling Mono" guides for OSX, Linux and Windows on the Mono website.

Additionally, a bunch of instructions were outdated / no longer relevant, updated those.

The "Configuration options" section was moved to the bottom of the readme, it was pretty long and pushed
the other sections into oblivion.
2014-11-27 01:16:14 +01:00
Alex Rønne Petersen d7e3600338 Merge pull request #1407 from chrisvire/bug-24587
[MWF] Fix focus issue when removing last item in ListView
2014-11-27 00:43:18 +01:00
Alex Rønne Petersen affa77b2fd Merge pull request #1424 from akoeplinger/remove-enable-nunit-tests
Remove --enable-nunit-tests option from build system
2014-11-27 00:41:29 +01:00
Marek Safar f40e35aed1 [mcs] Remove declaration expression named argument parsing (not part of the language yet). Fixes #24784 2014-11-26 22:59:07 +01:00
Mark Probst 805d6a8775 [sgen] Fix concurrent M&S. 2014-11-26 13:53:08 -08:00
Sebastien Pouliot 6744637030 Bump referencesource to fix mobile profile compilation of System.ComponentModel.DataAnnotations 2014-11-26 16:26:35 -05:00
Sebastien Pouliot f14dd6af87 Fix mobile build wrt System.Core changes 2014-11-26 16:00:57 -05:00
Miguel de Icaza efbcabe64d [System] Make it build with the MonoTouch profile 2014-11-26 14:43:25 -05:00
Miguel de Icaza f1ffa95460 Drop dead notes/code 2014-11-26 14:30:57 -05:00
Marek Safar d05e3e7a86 Fixes build 2014-11-26 19:54:35 +01:00
Mark Probst 890975f608 [sgen] Use all 3 lower vtable bits on 32 bits.
We can't actually use the trick of setting both the pinned and forwarded
bits to indicate cemented objects because the Tarjan bridge requires those
two bits never be set at the same time.
2014-11-26 10:38:50 -08:00
Mark Probst 4911c0b3c8 [sgen] Align vtable pointers to 8 bytes on 32 bits, too. 2014-11-26 10:38:50 -08:00
Mark Probst 51b8187b7a [sgen] Mempool allocations should be 8 byte aligned. Fix this on 32 bits.
The `MonoMemPool` struct is not a multiple of 8 bytes large, so we need
to align up to get the actual start of the pool data.
2014-11-26 10:38:50 -08:00
Mark Probst c6505f7830 [sgen] Remove unused defines. 2014-11-26 10:38:50 -08:00
Mark Probst fc0780b026 [sgen] Document descriptor types in comment. 2014-11-26 10:38:49 -08:00
Mark Probst 0087b319dd [sgen] Symbolic constants for pointer-free descriptor types. 2014-11-26 10:38:49 -08:00
Mark Probst c6c6095bcf [sgen] Separate descriptor type enums. 2014-11-26 10:38:49 -08:00
Mark Probst c4a119c05e [sgen] Use a symbolic constant for the descriptor type mask. 2014-11-26 10:38:49 -08:00
Mark Probst dba00f7fc9 [sgen] Rename LARGE_BITMAP to BITMAP.
There's only one bitmap descriptor type left and no need to
distinguish between large and small.
2014-11-26 10:38:49 -08:00
Mark Probst a81428f4c9 [sgen] Use guint64 for most counters, not long long. 2014-11-26 10:38:48 -08:00
Mark Probst 78a99907c0 [sgen] Fix cementing tag bit on 32 bits.
We used the third-lowest vtable bit to tag cemented objects.  On 32 bits,
vtables are only 4-byte aligned so we have to make do with 2 bits.
2014-11-26 10:38:48 -08:00
Mark Probst 6b7bd8250c [sgen] Remove DESCRIPTOR_FAST_PATH option - don't use it.
We're removing options that we've introduced for experimentation but that
didn't pan out.
2014-11-26 10:38:48 -08:00
Mark Probst 34bb779707 [sgen] Remove MARK_ON_ENQUEUE option - always use it now.
We're removing options that we've introduced for experimentation but that
didn't pan out.
2014-11-26 10:38:48 -08:00
Mark Probst 1729d16031 [sgen] Remove GRAY_QUEUE_HAVE_DESCRIPTORS option - always use it now.
We're removing options that we've introduced for experimentation but that
didn't pan out.
2014-11-26 10:38:47 -08:00
Mark Probst 4433d45d22 [sgen] Remove USE_PREFETCH_QUEUE option - don't use it.
We're removing options that we've introduced for experimentation but that
didn't pan out.
2014-11-26 10:38:47 -08:00
Mark Probst 6c7c1b8dda [sgen] Remove BLOCK_INFO_IN_HEADER option - always use it now.
We're removing options that we've introduced for experimentation but that
didn't pan out.
2014-11-26 10:38:47 -08:00
Mark Probst eee52c4f71 [sgen] Use a smaller slot size scaling factor.
The factor we used previously gave us object sizes in increments that made
some benchmarks use quite a lot more memory than necessary.  In particular,
we didn't have a size for 24 byte objects (on 64 bits), just for 16 and 32.
2014-11-26 10:38:47 -08:00
Mark Probst 5eadfaf8bb [sgen] Make block size fastenable. 2014-11-26 10:38:47 -08:00
Mark Probst 6f4e74bf77 [sgen] Fix card scanning with larger block sizes.
The card scanning code assumed that the size of the block header is less
than the size of a card.  If we put the block info into the header and increase
the block size enough, that assumption isn't true anymore, because the
mark bits take up space in proportion to the block size.
2014-11-26 10:38:46 -08:00
Mark Probst 77d2d231f0 [sgen] Experimental pre-fetch scan fast-path.
The idea here is to first extract all the references within an object
and then to process them, pre-fetching the objects they point to a few
steps ahead.
2014-11-26 10:38:46 -08:00
Mark Probst 06d43c4a91 [sgen] Fix build for mark-on-dequeue. 2014-11-26 10:38:46 -08:00
Mark Probst a3e7d28caa [sgen] Nicer visualization of concurrent collector pauses in gcpausevis.py. 2014-11-26 10:38:46 -08:00
Mark Probst 4318dac63c [sgen] Separate binary protocol entries for concurrent update and finish. 2014-11-26 10:38:46 -08:00
Mark Probst edeb654914 [sgen] Flush binary protocol buffers after unloading a domain.
When the runtime shuts down the last thing the GC usually hears about it
is that the root domain is unloaded.  If we don't flush the binary protocol
buffers at that point, we lose entries.
2014-11-26 10:38:45 -08:00
Mark Probst 21435d870f [sgen] Fix build on C99. 2014-11-26 10:38:45 -08:00
Mark Probst bc1b889fd5 [sgen] Fix build with heavy statistics. 2014-11-26 10:38:45 -08:00
Mark Probst f61314689f [sgen] Rename sgen-major-scan-object.h to sgen-marksweep-scan-object-concurrent.h. 2014-11-26 10:38:45 -08:00
Mark Probst fc6850fd1c [sgen] Remove some dead code in sgen-major-scan-object.h. 2014-11-26 10:38:44 -08:00
Mark Probst f469db655a [sgen] Unify scanning code a bit.
We still have two separate implementations of the scanning code: The optimized
one and the old one.  The old one is still needed because it supports the concurrent
collector.  For the non-concurrent collector we can now use the optimized
implementation, however.
2014-11-26 10:38:44 -08:00
Mark Probst 32bb23041f [sgen] Add/fix some assertions. 2014-11-26 10:38:44 -08:00
Mark Probst 0bbb8c9c6f [sgen] Add some missing binary protocol invocations. 2014-11-26 10:38:44 -08:00
Mark Probst 66311912de [sgen] New protocol entry for processing of individual reference. 2014-11-26 10:38:44 -08:00
Mark Probst 60b927f6df [sgen] In binary protocol grep, gray en-/dequeue must not always match. 2014-11-26 10:38:43 -08:00
Mark Probst d4945212c5 [sgen] Remove binary protocol entry for null dequeue. 2014-11-26 10:38:43 -08:00
Mark Probst 371372c137 [sgen] Fix build on highest debug level. 2014-11-26 10:38:43 -08:00
Mark Probst 11c326fc27 [sgen] Handle copy object failure.
This is just a verbatim copy of the old code.  It's unlikely it's ever
been tested, though.
2014-11-26 10:38:43 -08:00
Mark Probst ef8b82c738 [sgen] Increase debug level of assertions in inner loops. 2014-11-26 10:38:43 -08:00
Mark Probst 5d94bc96e5 [sgen] Remove dead code.
This was still left from the parallel collector.
2014-11-26 10:38:42 -08:00
Mark Probst eddce3e79f [sgen] Fix build with prefetch queue enabled. 2014-11-26 10:38:42 -08:00
Mark Probst f0149f2a73 [sgen] Make new M&S parameters fastenable.
Fasten is a small tool for optimizing compile-time options:

    https://github.com/evincarofautumn/fasten

It does that by parsing source files for numbers that have been marked
as "fastenable", and fiddling around with them.  We do this for all
the new optimizations.
2014-11-26 10:38:42 -08:00
Mark Probst 9664e14771 [sgen] Support evacuation in the optimized mark/scan loop.
We actually implement two separate mark/scan loops: One that doesn't
support evacuation and one that does.  We dynamically choose which one
to use.  The evacuation-less loop is faster, so we use it whenever we can.
2014-11-26 10:38:42 -08:00
Mark Probst 7c4a16d41d [sgen] Move drain_gray_stack() to copy/mark header file, too.
This inlines the scan/copy functions, so if we duplicate them we need
to duplicate this, too.
2014-11-26 10:38:42 -08:00
Mark Probst 3cd8c7ea50 [sgen] Remove old copy/mark function.
The new, optimized function can now do everything the old one did, so
let's get rid of it.
2014-11-26 10:38:41 -08:00
Mark Probst 0213613f58 [sgen] Move copy/mark function into separate header file.
So we can later include them twice, once with support for evacuation
and once without.
2014-11-26 10:38:41 -08:00
Mark Probst 5d209c8563 [sgen] Support evacuation again.
The performance impact of this is significant, so we will later make
two separate scan functions: one with evacuation and one without.
2014-11-26 10:38:41 -08:00
Mark Probst 28de59a2fc [sgen] Support split nursery again.
This might degrade performance, in which case we'll special-case it
later on.
2014-11-26 10:38:41 -08:00
Mark Probst 954aac5365 [sgen] Unify the two small object mark cases again.
The only difference between these two cases was that we used to
different heavy statistics counters.  We can do that within a single
case.
2014-11-26 10:38:40 -08:00
Mark Probst 3ddf2cc00c [sgen] Use MS_MARK_OBJECT_AND_ENQUEUE where we expanded it previously.
It's still the same code, so use the macro directly.
2014-11-26 10:38:40 -08:00
Mark Probst 2b826d3d50 [sgen] Always inline the optimized copy function.
This is a huge win for some benchmarks.
2014-11-26 10:38:40 -08:00
Mark Probst ecf0597302 [sgen] Never fall back to the old copy function. 2014-11-26 10:38:40 -08:00
Mark Probst c1c1ac59ce [sgen] Use scanning macro in optimized loop.
We expanded this macro previously, but it's still the same code, so
use the macro directly.
2014-11-26 10:38:40 -08:00
Mark Probst cf4a9878da [sgen] New SMALL_PTRFREE descriptor type for faster has_references checking.
We use 3 to denote SMALL_PTRFREE, and 7 for COMPLEX_PTRFREE, so we can
check for both simply with ((desc & 3) == 3).
2014-11-26 10:38:39 -08:00
Mark Probst 52537626d9 [sgen] Only enqueue objects with references. 2014-11-26 10:38:39 -08:00
Mark Probst 6cd4d4248a [sgen] Look at descriptor, not block, to see whether object has references. 2014-11-26 10:38:39 -08:00
Mark Probst 11d1a405d6 [sgen] Special descriptor encoding for strings.
The complex pointer-free type carries no additional information.  We use its
data to mark strings so we can determine object size quicker.
2014-11-26 10:38:39 -08:00
Mark Probst abeac5f741 [sgen] Faster generic large bitmap scanning if CTZ builtin is available. 2014-11-26 10:38:39 -08:00
Mark Probst 7a91fcd059 [sgen] Remove small bitmap descriptor type.
The reason for having a small bitmap was that we could encode the object
size in the descriptor.  The main attraction for having object size handy is that
we can quickly check whether an object is in the small object major heap or
in the LOS.  We solve this problem by always using complex descriptor types
for large objects, so now we can tell whether an object is small just by looking
at the descriptor type.
2014-11-26 10:38:38 -08:00
Mark Probst adb9dbc395 [sgen] Heavy statistics on copied object descriptors. 2014-11-26 10:38:38 -08:00
Mark Probst 23a9b55767 [sgen] Heavy statistic counter for scanning of no-ref objects. 2014-11-26 10:38:38 -08:00
Mark Probst 8c5c569bc2 [sgen] Use HANDLE_PTR in the fast-path, too.
We had just expanded the macro verbatim and never changed it, so
there's no point in not using it directly.
2014-11-26 10:38:38 -08:00
Mark Probst be12da27ef [sgen] Optional scanning without the small bitmap fast path.
To experiment with different optimization combinations.
2014-11-26 10:38:37 -08:00
Mark Probst 30afbb9164 [sgen] Fix heavy statistics in mark-scan loop. 2014-11-26 10:38:37 -08:00
Mark Probst 69458165e9 [sgen] Limit run-length descriptors to small object size, too.
To identify more small objects quicker.

Since we now use the runl-length descriptor types to indicate object
size as well, and strings can have any size, we can't use that type
for strings anymore, so we use the complex type which forces us to
look up its size to determine whether it's a small or large object.
2014-11-26 10:38:37 -08:00
Mark Probst c300c3de0c [sgen] Make mark on enqueue vs dequeue configurable.
So we can experiment with a variety of optimization configurations.
2014-11-26 10:38:37 -08:00
Mark Probst 5527def76c [sgen] Make block info in header optional.
So we can experiment with a variety of optimization configurations.
2014-11-26 10:38:37 -08:00
Mark Probst 512c9866ca [sgen] Tag cemented objects so we don't have to go through the hash.
We can do the cemented check faster by using the third vtable bit to
tag cemented objects (in addition to the pinned bit).  In workloads
that are heavy on cementing (like `lcscbench` or `perimeter`) this
significantly increases performance.
2014-11-26 10:38:36 -08:00
Mark Probst 23f12565d9 [sgen] Prefetch mark bits, not block start.
When prefetching, we calculate which mark bits we need and prefetch
those for writing.  The object itself we prefetch for reading.
2014-11-26 10:38:36 -08:00
Mark Probst 15f1597e89 [sgen] Put block info into blocks.
Another experiment: What if we put the whole block info into the block
itself, not just a pointer to it.  There's one less indirection we
need to do.  On the other hand, many of them will share the same cache
lines.  So do the pointers to the block infos, though.
2014-11-26 10:38:36 -08:00
Mark Probst 9883ecf2a0 [sgen] Bring mark-scan loop stats up to date. 2014-11-26 10:38:36 -08:00
Mark Probst 32d7a0a24c [sgen] Also prefetch the (potential) block header.
When we scan a small object in the major heap we have to read the
block header of its block.  It makes sense to prefetch that as well,
in addition to the object itself.
2014-11-26 10:38:36 -08:00
Mark Probst 44e806f6cb [sgen] Count scanned objects. 2014-11-26 10:38:35 -08:00
Mark Probst ab83e6316d [sgen] Mark on dequeue, not enqueue.
This is another experiment.

When marking on enqueue, what we need to do is look at the object
we're about to enqueue, to check whether it's a small or large object.
Then, when we dequeue to scan, we look at the object again, so we
essentially fetch each live object header twice.

With mark on dequeue, when we encounter a pointer we always enqueue
it, without even looking at the object.  Only when we dequeue do we
figure out whether it's marked yet, and thus whether we need to scan
it.
2014-11-26 10:38:35 -08:00
Mark Probst 91e7454c6c [sgen] Make enqueuing descriptors compile-time optional.
We want to test this in combination with other changes, so we make
each of them configurable.
2014-11-26 10:38:35 -08:00
Mark Probst 580f250a83 [sgen] Make prefetch queue compile-time optional.
We want to benchmark the prefetch queue in combination with other
changes, so we make each of them configurable.
2014-11-26 10:38:35 -08:00
Mark Probst ca8fe2c673 [sgen] Prefetch queue for optimized mark/scan loop.
We put a short FIFO between the gray stack and the actual scanning, to
be able to prefetch objects ahead of time, with an adjustable delay.
2014-11-26 10:38:34 -08:00
Mark Probst 6b8596eb32 [sgen] Optimized mark/scan loop for major collections.
The basic idea here is to make a loop that combines dequeuing from the
gray queue, scanning and marking/copying/enqueuing, with redundancies
removed and special-casing of the common case.

We make the small bitmap type descriptor only apply to small (as
opposed to LOS) objects so that we can quickly check in that case
whether an object is in the LOS or not without actually looking up its
size.

We disable evacuation and the split nursery because the code doesn't
support them yet.
2014-11-26 10:38:34 -08:00
Mark Probst a27ab44e35 [gc] Remove the new object count counter, because it's useless.
Without heavy statistics it counts almost no objects, and even with
heavy statistics turned on, it doesn't count everything.  SGen has an
accurate counter when heavy statistics are turned on.
2014-11-26 10:38:34 -08:00
Mark Probst 04adbae448 [sgen] Fix build with binary protocol. 2014-11-26 10:38:34 -08:00
Miguel de Icaza 055495c537 Merge pull request #1426 from ignacionr/webclient-delay-file-creation
Webclient delay file creation
2014-11-26 13:06:24 -05:00
Marek Safar 4d3f26e9f0 [corlib] Implement ExecutionContext flow for async infrastructure. Fixes #24757 2014-11-26 19:01:32 +01:00
Miguel de Icaza 4e9a0636c2 Merge pull request #1398 from jwestfall69/dgv-first_row_index
[MWF] DataGridView: ensure first_row_index will be valid after row removal
2014-11-26 13:02:16 -05:00
Miguel de Icaza 668fdf5e8a Merge pull request #1396 from jwestfall69/dgvrc-clear-speedup
[MWF] DataGridViewRowCollection Clear() speed up
2014-11-26 13:01:51 -05:00
Rodrigo Kumpera 92fbdbc591 Bump the version. 2014-11-26 11:20:45 -05:00
Marek Safar b0ef65e7ac Merge pull request #1429 from mono/fixProcessStartInfo2
Fix ProcessStartInfo null checking and replace with Length checks.
2014-11-26 13:43:20 +01:00
Ungureanu Marius d22bd32f04 Fix ProcessStartInfo null checking and replace with Length checks. 2014-11-26 14:18:12 +02:00
Jo Shields 9bdd77969a [msvc] duplicate 1d6b8a75fa for eglib 2014-11-26 11:42:31 +00:00
Marek Safar c092496335 Merge pull request #1428 from mono/fixProcessStartinfo
Update ProcessStartInfo to fix some inconsistency
2014-11-26 12:40:01 +01:00
Ungureanu Marius c9ff84dacb Shortcircuit ProcessStartInfo Verbs logic.
Let's not do IO operations except if needed.
2014-11-26 13:32:59 +02:00
Marius Ungureanu f494db3690 Update ProcessStartInfo to fix some inconsistency 2014-11-26 13:32:58 +02:00
Ungureanu Marius b1cae9a156 Introduce failing ProcessStartInfo tests. 2014-11-26 13:32:49 +02:00
Marcos Henrich d7efbfe509 ConsoleUi no longer breaks when the test runner returns null.
In case the test runner returns null we will no longer suffer a NullArgumentException and the collector exceptions will be printed.
The test runner was returning null because of an IOException "Too many open files" on NUnit side.
2014-11-26 10:12:01 +00:00
Zoltan Varga c181b54945 [jit] Resurrect the precise stack marking code. 2014-11-26 06:39:58 +01:00
Rodrigo Kumpera 27f20c510e [corlib] Improve a test failure to be more actionable. 2014-11-25 18:31:26 -05:00
Rolf Bjarne Kvinge 1163db5f07 [mono-api-html] Colorize html output.
* Add support for colorizing the HTML output. This can be turned off if desired.

* Some changes are now reported inline (using colors/underline/strikeout)
  instead of generating an removed/added pair. This makes the diff
  a lot easier to read.
2014-11-25 16:39:32 +01:00
Marek Safar 15cb0daaa0 [corlib] Replace few threading types from reference sources 2014-11-25 14:45:08 +01:00
Jo Shields 1d6b8a75fa [msvc] Allow cygwin "make" to be called after winsetup.bat
As-is, winsetup.bat replaces config.h with winconfig.h, which is needed for the MSVC compilation - but breaks all further use of cygwin's make (e.g. to build the class library, or run "make install").

This patch introduces a new cygconfig.h as a backup prior to squashing config.h (if it exists, so the runtime can still be built without cygwin ever being used), and makes winconfig.h use it on non-MSVC compilers (i.e. cygwin)
2014-11-25 12:49:26 +00:00
Jo Shields 9f6f6a9cce [msvc] Fix MONO_INTERNAL undefined in Boehm 2014-11-25 12:23:20 +00:00
Jo Shields dfc037f42a Fix "make dist" issue from MS.NET regex switchover 2014-11-25 10:14:20 +00:00
Marek Safar 5517c56afa [corlib] Add check for collection modification during ForEach. Fixes #24775 2014-11-25 10:33:34 +01:00
Rolf Bjarne Kvinge 1314cf9b87 Revert "[System] Ignore two tests which are failing due to external factors changing."
This reverts commit 597183658e.

According to the comments on the commit [1], this has already been fixed.

[1] https://github.com/mono/mono/commit/597183658e04260ba493495bcff2da28222b48b8
2014-11-25 09:38:06 +01:00
Rodrigo Kumpera 695a5278d6 Revert my last change to a submodule. ALL MY LOVE TO THOSE THAT INVENTED GIT SUBMODULES. <3 2014-11-24 17:10:21 -05:00
Rodrigo Kumpera 13db0d01c0 [System.Core] Make one test much less likely to fail. 2014-11-24 17:08:02 -05:00
Zoltan Varga 45213f7b25 [Microsoft.Build.Tasks] Fix a net 2.0 failure. 2014-11-24 16:40:08 -05:00
Marek Safar c7405e6ca0 [System.ComponentModel.DataAnnotations] Replace with .net implementation 2014-11-24 20:34:18 +01:00
Marek Safar 1007750608 Fixes build 2014-11-24 18:25:34 +01:00
irodriguez f1e329b299 [Fix] WebClient to delay downloaded file creation
Fixed unwanted spaces, changed for tabs.
2014-11-25 00:07:51 +07:00
irodriguez e234b3ce16 WebClient delay file creation until a response is obtained 2014-11-24 23:49:13 +07:00
Marcos Henrich 93b6e5fbee Update .csproj files to include .NET System.Text.RegularExpressions 2014-11-24 16:31:56 +00:00
Marek Safar 1e60e2868f Bring .NET implementation of concurrent collections 2014-11-24 17:25:56 +01:00
Marek Safar a21a2bbd57 [mcs] Add special-cased HostProtectionAttribute handling 2014-11-24 17:25:56 +01:00
Miguel de Icaza 1d563aceff Remove Mono's previous System.Text.RegularExpressions 2014-11-24 10:09:06 -05:00
Marek Safar 190df2239e Remove 2.0 profile csproj files 2014-11-24 12:15:55 +01:00
Marek Safar 02332b5ad2 [System.Core] Switch to common SR class 2014-11-24 12:15:55 +01:00
Marek Safar 76f6ead615 Simplify System.Data makefile 2014-11-24 12:15:54 +01:00
Jo Shields 37ae0c6550 Add SR.cs (for Reference Source regex implementation) to EXTRA_DIST 2014-11-24 10:59:40 +00:00
Jo Shields 996a3a73a4 Fix case error causing build failure on case-sensitive filesystems 2014-11-24 09:51:35 +00:00
Zoltan Varga 941865d7ff Remove net_2_0 reference from make dist. 2014-11-24 02:15:28 -05:00
Miguel de Icaza 9dda1417d8 [System] Bring tests for open bugs on RegularExpressions that have now been fixed 2014-11-23 23:16:39 -05:00
Miguel de Icaza 26fb3a8cab Add newline 2014-11-23 21:39:53 -05:00
Miguel de Icaza 74d0eeaf13 [System] Bring .NET implementation of System.Text.RegularExpressions
This patch brings .NET's implementation of the RegularExpressions
stack and brings some of the supporting infrastructure required to
build without resource files.

The build commands have been updated with two new defines to assist in
bringing .NET code: MONO (to indicate that the code is being compiled
as part of Mono) and a more granular DISABLE_CAS_USE that is used to
mark regions where Code Access Security is being used in the source
code, as Mono does not actually ship with a working CAS implementation.
2014-11-23 21:38:36 -05:00
Zoltan Varga 4342bce441 [jit] Move the SHARED_EXT define to mono-dl.h, rename it to MONO_SOLIB_EXT. 2014-11-23 21:17:49 -05:00
Zoltan Varga 5e7af8eda4 [runtime] Remove conditional logic from LL_SO_OPEN() macro. 2014-11-23 20:49:10 -05:00
Zoltan Varga 901f3c466a Fix the mcs-compileall test target. 2014-11-23 02:59:31 -05:00
Zoltan Varga afd52c893c Remove net 2.0 dependencies from mcs tests. 2014-11-23 02:59:31 -05:00
Zoltan Varga 937175849b Remove build system support for the net 2.0/3.5 profiles. 2014-11-23 02:59:31 -05:00
Zoltan Varga 2d1c6dd04b Revert "[android] Add a workaround for ndk r10c defining RTLD_DEFAULT as 0 on 64 bit platforms."
This reverts commit 5ee92ecb76.

Revert this. There was already some android specific code in LL_SO_OPEN ().
2014-11-23 02:32:13 -05:00
Alexander Köplinger 0ee2fc301c Remove --enable-nunit-tests option from build system
It isn't used anymore as the classlib tests are always enabled now during 'make check'.
2014-11-23 03:15:11 +01:00
Alexander Köplinger 5474ae596d Added missing newline to net_4_0_System.Core.dll.sources (fixes Linux build) 2014-11-22 15:43:20 +01:00
Marek Safar 05711a1b63 Build fix 2014-11-22 15:39:11 +01:00
Marek Safar bdd4bd1066 [system.core] Enable disabled test 2014-11-22 13:48:38 +01:00
Marek Safar 92a3aeada5 Fixes typo 2014-11-22 13:48:25 +01:00
Marek Safar 9425cb5055 [system.core] Replace PLINQ implementation with .net version 2014-11-22 13:36:41 +01:00
Zoltan Varga 033a7b4c4f [runtime] Add a wrapper around atexit () since it is missing on some android versions. 2014-11-22 00:08:04 -05:00
Zoltan Varga de7963ff5b [android] Avoid referencing SYS_fork which is not defined in some ndk versions. 2014-11-21 23:16:44 -05:00
Zoltan Varga 5ee92ecb76 [android] Add a workaround for ndk r10c defining RTLD_DEFAULT as 0 on 64 bit platforms. 2014-11-21 23:15:27 -05:00
Zoltan Varga 82f95843f4 [android] Disable the usage of tkill () on android/arm64, the tkill () function is no longer there. 2014-11-21 23:14:41 -05:00
Zoltan Varga b836476666 [runtime] Remove another getdtablesize () reference. 2014-11-21 20:39:49 -05:00
Zoltan Varga cd9f3b5859 [runtime] Remove a getdtablesize () reference from eglib too. 2014-11-21 20:31:36 -05:00
Zoltan Varga cb5c0f86f3 Merge pull request #1420 from directhex/define_ssize_max_on_windows
[msvc] Define SSIZE_MAX if not already defined (i.e. on Windows)
2014-11-21 19:00:29 -05:00
Zoltan Varga 6b29297dec [jit] Fix the AOT part of #24577, the epilog beginning was calculated using the code size, which can be different in AOT mode due to alignment padding between methods. 2014-11-21 18:45:26 -05:00
Rodrigo Kumpera c9c40ee704 Merge pull request #1423 from directhex/sgen_on_msvc
[msvc] Get sgen building on MSVC
2014-11-21 14:49:11 -05:00
Marek Safar 73bb10fff3 [mcs] Add string type to the list of valid cast tokens 2014-11-21 16:51:39 +01:00
Marek Safar a0bda09ee0 [mcs] Remove 2.0 profile dependency from one test 2014-11-21 15:20:40 +01:00
Marek Safar 63145e602a [system.net.http] Allow use of absolute url paths without scheme in HttpRequestMessage 2014-11-21 14:33:11 +01:00
Jo Shields d2b8c8557b [msvc] Add _SGen Configurations to {eglib,libgc,genmdesc}.vcxproj
These configurations are needed to build a Debug_SGen version of mono.vcxproj, which is needed to build mono-sgen.exe
2014-11-21 12:44:37 +00:00
Marek Safar d03bed3ad7 [system.net.http] set-up cancellation before any WebRequest method is called. Fixes #24704 2014-11-21 12:57:48 +01:00
Jo Shields ab61b5c7ad [msvc] Add missing sgen source files to libmonoruntime.vcxproj 2014-11-21 10:42:55 +00:00
Jo Shields 0279e7dc28 [msvc] Refreshed .def files (needed for SGen to build) 2014-11-21 10:40:39 +00:00
Marek Safar 35472d4f84 [xbuild] Change default tools profile to still work with not yet removed 2.0 profile 2014-11-21 10:31:24 +01:00
Marek Safar 91ea62331c [linq] optimize Take(0) 2014-11-21 10:27:07 +01:00
Marek Safar 3c9e0f1a43 [system.data] Fixes DbEnumerator current property to clone read data. Fixes #24452 2014-11-21 10:27:07 +01:00
Jo Shields cf4d77d21d [msvc] Define SSIZE_MAX if not already defined (i.e. on Windows)
limits.h from MSVC does not include SIZE_MAX or SSIZE_MAX. We need the latter to build sgen, so define it.
2014-11-21 09:00:31 +00:00
Rodrigo Kumpera 1230a4046e [profiler] Use the new hidden API to attach the helper thread as a tools thread. This makes JI lookup work more reliably. 2014-11-20 18:33:33 -05:00
Rodrigo Kumpera b511edee10 [jit] Don't sample threads that are not fully attached. 2014-11-20 18:32:53 -05:00
Rodrigo Kumpera a82848e48d [runtime] Introduce the notion of a tools thread.
A tools thread is one that can access core runtime structures but not touch anything managed (code or heap).

It's intended to enable the profiler to resolve missing backtraces from its helper thread.

THIS IS A HACK.

The right solution would be to not perform this on the profiler at all and simply log IPs and let the decoder
resolve them. But then there's reality and we can't simply break the current format without consequences.

We're taking this hack for now until we can fix the profiler to do something sensible.
2014-11-20 17:55:05 -05:00
Rodrigo Kumpera 1d6d5ed6bc [utils] Add foreach variant that supports filtering the list as you go. 2014-11-20 17:44:26 -05:00
Mark Probst 23c99f6e4e Merge pull request #1421 from BrzVlad/fix-monitor-resurrection
Fix monitor-resurrection test.
2014-11-20 11:12:27 -08:00
Vlad Brezae 9137e16bab Fix monitor-resurrection test.
Try to avoid the pinning of the object that needs to be finalized.
2014-11-20 10:57:00 -08:00
Zoltan Varga d66079267a Merge pull request #1419 from directhex/bump_msvc_VERSION
[msvc] Bump winconfig.h VERSION to match configure.ac
2014-11-20 12:56:41 -05:00
Jo Shields 67da1215f3 [msvc] Bump winconfig.h VERSION to match configure.ac
Unhelpfully, winconfig.h is used for building eglib, and it includes a hardcoded VERSION definition which needs to match configure.ac - otherwise msvc builds identify themselves as 2.11
2014-11-20 17:11:43 +00:00
Rodrigo Kumpera afa981edc8 Merge pull request #1416 from jbevain/token-wrapper-data
[jit] Use the proper function to resolve classes
2014-11-20 12:10:23 -05:00
Marcos Henrich 253b24588b Changed ConcurrentBagTests.Bug24213 () to reuse variable array. 2014-11-20 16:18:57 +00:00
Marek Safar de75999a8a Merge pull request #1418 from esdrubal/concurrentbag
Fixed CyclicDeque array growth.
2014-11-20 15:43:21 +01:00
Marcos Henrich 3a7a058e55 Fixed CyclicDeque array growth. Fixes 24213.
Changed CyclicDeque.PushBottom to resize the array when its size is equal to its length.
2014-11-20 14:22:58 +00:00
Marcos Henrich cb5bc3ffab Test ConcurrentBag growth. Covers #24213. 2014-11-20 14:19:42 +00:00
Miguel de Icaza 50fa153b29 Merge pull request #1417 from directhex/fix_msvc_build
[msvc] Add a definition for _WIN32_WINNT to MonoPosixHelper
2014-11-20 08:13:57 -05:00
Jo Shields 076e80f725 [msvc] Add a definition for _WIN32_WINNT to MonoPosixHelper
MonoPosixHelper fails to build in my testing, due to config.h bailing the
build out if it doesn't think the build platform is XP SP2 or higher.
Adding this define forces that minimum Windows version, allowing mono.sln
to build fully.
2014-11-20 13:05:10 +00:00
Marcos Henrich 873d616b2a Added missing projects files to corlib-net_4_5.csproj 2014-11-20 12:12:49 +00:00
Jb Evain 6d5c7fedab Test sizeof, mkrefany & refanyvalue in dynamic methods
They previously resulted in TypeLoadExceptions.
2014-11-20 12:59:53 +01:00
Jb Evain 7cbf11566f [jit] Use the proper function to get classes
For the opcodes sizeof, mkrefany and refanyval the jit
was resolving the operand tokens directly from the image.

In dynamic scenarios where the tokens are stored in the
wrapper data, this triggered TypeLoadExceptions.

This patch uses mini_get_class, as used everywhere else,
to resolve the operand tokens of those opcodes.
2014-11-20 12:59:40 +01:00
Zoltan Varga 8647ae45fc Fix #24577 correctly, cfg->code_len is the size of the code, while cfg->code_size is the size of the memory area allocated for code. 2014-11-20 04:45:44 -05:00
Zoltan Varga 3130eb18ce Fix a warning. 2014-11-20 00:06:03 -05:00
Zoltan Varga 9d3d8a5c53 Fix a warning. 2014-11-20 00:05:36 -05:00
Mauricio Faria de Oliveira 26e016f3ad Revert "PowerPC64 ELFv2 ABI: cases for in-register parameter passing, return values, and structs"
This reverts commit ba62bdf862.

Reverting as per discussion with Zoltan Varga (see PR 1409 [1]).
Some rework needed.

[1] https://github.com/mono/mono/pull/1409

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-11-19 21:56:54 -05:00
Miguel de Icaza 716b78c578 Add referencesource submodule 2014-11-19 21:01:39 -05:00
Zoltan Varga 5644d157c8 Merge pull request #1411 from jbevain/sdb-frame-domain
[sdb] Expose the domain of the stack frames
2014-11-19 20:51:34 -05:00
Zoltan Varga 2c7265d6b9 [jit] Remove an unused interpeter file. 2014-11-19 19:20:02 -05:00
Zoltan Varga fb033c5301 [jit] Remove some unused defines. 2014-11-19 19:13:01 -05:00
Stephen McConnel c735753a3c Fix bugs in sizing TableLayoutPanel (Xamarin bug 18638)
Consider spans and absolute sizes in computing PreferredSize for
TableLayoutPanel.
Also fix bug in allocating unused width to SizeType.Absolute columns.

Change-Id: Ic5065b83ced8195d1c5be39087f33b0d632fc9a6
2014-11-19 14:53:12 -06:00
Mark Probst d1b51438d1 [sgen] Remove dead code. 2014-11-19 12:46:39 -08:00
Marcos Henrich 8cdb1c959e Added Symbolicate tool.
Symbolicate tool replaces stack frames "<filename unknown>:0" with correct file name and line.
2014-11-19 19:45:15 +00:00
Miguel de Icaza 014f882aea Merge pull request #1415 from ermshiperete/FixTruncatedButton
[MWF] Fix bug that truncates button text
2014-11-19 14:05:03 -05:00
Zoltan Varga b464556d05 Merge pull request #1414 from ExonyLimited/process-vmswap
Process.PagedMemorySize64 now returns value from /proc/PID/status
2014-11-19 13:58:25 -05:00
Eberhard Beilharz da058bf8a4 [MWF] Fix bug that truncates button text
A previous change (885b065e) accidentally calculated the text size
in some places without padding. This resulted in a slightly to small
text rectangle, causing the text to be truncated.
2014-11-19 19:48:27 +01:00
Marek Safar 87f59dce24 Fixes build 2014-11-19 18:07:52 +01:00
Marek Safar 4de9aa838b [corlib] Capture awaited task exception stack. First part of #18629 2014-11-19 17:41:52 +01:00
Craig Minihan 1cc51f63ee Process.PagedMemorySize64 now returns value from /proc/PID/status 2014-11-19 08:07:37 -08:00
Rolf Bjarne Kvinge fbf1077afd Fix typo, there is no profile called 'xammaci'. 2014-11-19 10:29:33 +01:00
Mark Probst 38d9679d82 Merge pull request #1413 from BrzVlad/bin-prot-io
System calls for binary protocol writing
2014-11-18 17:59:16 -08:00
Vlad Brezae 66acb4f3e1 [sgen] Don't use standard C API for binary protocol IO.
This prevents deadlocks from libc locks when interrupting.
2014-11-18 17:56:01 -08:00
Zoltan Varga fccff0d9bb [sdb] Avoid asserts on shutdown when the appdomain unload callbacks are called on the debugger thread during shutdown. Fixes #24342. 2014-11-18 20:54:12 -05:00
Vlad Brezae 3c1147121e [sgen] Fix binary protocol build 2014-11-18 17:36:50 -08:00
Zoltan Varga 672a02e177 [jit] Fix the calculation of the epilog size for EH info. Fixes #24577. 2014-11-18 16:53:26 -05:00
Rodrigo Kumpera 4f2e8dfddd [runtime] Replace mono_method_get_signature(_full) with the _checked variant. 2014-11-18 16:51:07 -05:00
Rodrigo Kumpera f8de60d964 [runtime] Introduce mono_method_get_signature_checked as the MonoError variant of mono_method_get_signature_full. 2014-11-18 16:51:06 -05:00
Rodrigo Kumpera d67dd77506 [runtime] Remove monodiet.c. 2014-11-18 16:51:06 -05:00
Zoltan Varga 9347782b8b [jit] Remove an assert from mono_arch_find_jit_info () on x86 which can be hit when a profiler stack walk is done while in a jump trampoline. 2014-11-18 16:03:51 -05:00
Rodrigo Kumpera 939fa90ceb [jit] Use _checked variant of mono_field_from_token. 2014-11-18 14:04:10 -05:00
Rodrigo Kumpera e94e5e5ac1 [runtime] Use _checked variant of mono_field_from_token. 2014-11-18 14:04:10 -05:00
Rodrigo Kumpera 01f892bdb5 [jit] Use MonoError when possible for error handling. 2014-11-18 14:04:09 -05:00
Rodrigo Kumpera d1c8e68397 [jit] Add a JIT failure mode that uses MonoError. 2014-11-18 14:04:09 -05:00
Rodrigo Kumpera c544d330dd [runtime] more loader error cleanup. 2014-11-18 14:04:09 -05:00
Marcos Henrich b717961fb6 Added opcode il_seq_point.
il_seq_point has zero length and is used in release instead of the expensive seq_point opcode.
2014-11-18 18:04:26 +00:00
Marcos Henrich 3f259a1f95 Changed METHOD_EXIT_IL_OFFSET back to 0xffffff. The previous value was -2, that could introduce comparison issues. Added flag MONO_SEQ_POINT_FLAG_EXIT_IL that is used to encode the exit IL, this avoids a 4 byte IL offset delta. 2014-11-18 18:02:52 +00:00
Marcos Henrich ac5395bc05 Added out_buf parameter to encode_var_int and decode_var_int. 2014-11-18 18:02:52 +00:00
Marcos Henrich dda58dc6e3 Renamed seq_point_info_write_size to seq_point_info_get_write_size. 2014-11-18 18:02:51 +00:00
Marcos Henrich afb8ea6a96 MonoSeqPointInfo data is now compressed. Encode data MonoSeqPointInfo len, has_debug_data and alloc_data into a single variable int. 2014-11-18 18:02:50 +00:00
Marcos Henrich ca79ee98e4 MonoSeqPointInfo no longer uses a GByteArray. GByteArray requires too much memory, we still use GByteArray to build the buffer but when its done we store in MonoSeqPointInfo a copy. 2014-11-18 18:02:50 +00:00
Marcos Henrich d4644e78ca Merged SeqPoint.next_array with SeqPoint.array. 2014-11-18 18:02:49 +00:00
Marcos Henrich eb35cc1159 SeqPoint next array is no longer allocated by default. Next array will only be allocated if has_debug_data is true. 2014-11-18 18:02:48 +00:00
Marcos Henrich 79bd3278bb Added size of sequence points to mono jit stats. 2014-11-18 18:02:48 +00:00
Marcos Henrich c243c2447f Ignore seq points of entry and exit IL offsets. Those seq points are only required for debugging. 2014-11-18 18:02:47 +00:00
Marcos Henrich a73caf9930 Changed mini-exceptions functions to get IL offsets from seq point. mono_walk_stack_full and ves_icall_get_trace are now using find_prev_seq_point_for_native_offset to retrieve IL offsets. 2014-11-18 18:02:46 +00:00
Marcos Henrich ba11c1de28 Sequence points debug data is no longer store by default. Debug data is only stored when cfg->gen_seq_points_debug_data is true. 2014-11-18 18:02:46 +00:00
Marcos Henrich e47bad43de Sequence points are now generated by default. 2014-11-18 18:02:45 +00:00
Marcos Henrich 35f6f01ac2 Changed METHOD_EXIT_IL_OFFSET to -2 The new value produces lower deltas and does not overflow when using variable integer encoding. 2014-11-18 18:02:44 +00:00
Marcos Henrich e9d6024e62 aot-runtime and aot-compiler now use seq_point_info_read/write. 2014-11-18 18:02:43 +00:00
Marcos Henrich 4947481b1a Added methods to read and write MonoSeqPointInfo. 2014-11-18 18:02:43 +00:00
Marcos Henrich 2d14735141 SeqPoint are now kept in memory with a compact encoding. MonoSeqPointInfo has now a pointer to a buffer containing encoded sequence points, and to a buffer containing next values. As there is no longer an array of SeqPoint ready to be read, SeqPointIterator was added. 2014-11-18 18:02:42 +00:00
Marcos Henrich fee5465299 Moved sequence point logic to seq-points.h and seq-points.c 2014-11-18 18:02:41 +00:00
Marcos Henrich c64e105c69 Improved exception stack frame displayed data. Added stack frame method address display. 2014-11-18 18:02:41 +00:00
Marcos Henrich a5f2606a66 Added to StackFrame a field for the method address. Incremented MONO_CORLIB_VERSION. 2014-11-18 18:02:40 +00:00
Ludovic Henry c9c80ce2ce [runtime] Fix #24605 "counters not enabled" message in monodis and peverify 2014-11-18 11:51:43 -05:00
Marek Safar 383daff454 [eval] Don't assumen all captured types have storey assigned 2014-11-18 16:51:11 +01:00
Marek Safar 281934e127 [mcs] Remove primary constructors and declaration expressions from C#6 2014-11-18 14:44:16 +01:00
Jb Evain 567834db69 [Mono.Debugger.Soft] Add test for StackFrame.Domain
Assert that the property returns the proper domain for the stack frame.
2014-11-18 14:12:36 +01:00
Marek Safar 2cee8a135e [mcs] Fix error reporting for incomplete attribute target. Fixes #24537 2014-11-18 14:11:59 +01:00
Jb Evain 2729751fcf [Mono.Debugger.Soft] Implement StackFrame.Domain
This property uses the new CMD_STACK_FRAME_GET_DOMAIN command
to retrieve and cache the domain in which the stack frame
is executing.

Bump the protocol version to match the runtime.
2014-11-18 14:10:53 +01:00
Jb Evain f37be5d96b [sdb] Add command CMD_STACK_FRAME_GET_DOMAIN
This command returns the domain in which the stack frame is executing

Bump protocol version.
2014-11-18 14:09:15 +01:00
Marek Safar 20c5941b4c [mcs] Less cascading errors 2014-11-18 13:40:56 +01:00
Alistair Leslie-Hughes b3eccc8a79 Improved support for TimeZoneInfo under windows.
When cross compiling with gcc, LIBC is defined and
thus never checks the registry for the timezone information.

This change is released under the MIT license.
2014-11-18 20:46:15 +11:00
Marek Safar b9e6127506 [mcs] Makes flow analysis of goto/goto case significantly faster. Fixes #24511 2014-11-18 10:28:55 +01:00
Zoltan Varga df8abf4920 [jit] Fix a class initialization race which happens if a class initializer initializes a got slot before it finishes running. Fixes #23242. 2014-11-17 21:44:35 -05:00
Zoltan Varga 6b7a11a77b [aot] Disable COM support in AOT code, the COM wrapper code doesn't play well with AOT. 2014-11-17 17:42:35 -05:00
Mark Probst 40c30b5288 Merge pull request #1406 from BrzVlad/monitor-resurrect
Keep the monitor link to the object active also in the resurrection case
2014-11-17 14:17:32 -08:00
Rodrigo Kumpera 3ad76e42b2 Merge pull request #1388 from schani/fix-23401
Fix 23401
2014-11-17 17:17:04 -05:00
Zoltan Varga b3e8e1fa20 [runtime] Avoid crashes when a non-runtime thread receives a SIGQUIT. 2014-11-17 17:03:41 -05:00
Sebastien Pouliot 59b80fb93b Merge pull request #1408 from brendanzagaeski/signed-xml-bug-7716
[System.Security] Fix SignedXml bug #7716 with tests
2014-11-17 16:32:54 -05:00
Zoltan Varga e52d20ed7d [arm] Applied patch from Richard Dunkley <[email protected]>. Fix complication problems with newer gcc versions. Fixes #24588. 2014-11-17 15:46:39 -05:00
Brendan Zagaeski c5375566d5 [System.Security] Fix SignedXml bug #7716 with tests
The underlying problem for bug 7716 [1] was that the Mono C14N XML
canonicalizer was not sorting the XML attributes in the same order as
Microsoft .NET's canonicalizer.

The C14N specification [2] states: "the attributes are sorted
lexicographically by attribute name (based on Unicode character code
points)." This wording suggests that the order of attributes should be
strictly ascending based on Unicode byte value. This commit changes the
attribute sort order to match the specification.

The new tests pass on Windows, fail on Mono before this change, and
succeed on Mono after this change.

[1] https://bugzilla.xamarin.com/show_bug.cgi?id=7716
[2] http://www.w3.org/TR/2000/WD-xml-c14n-20000119.html
2014-11-17 15:45:53 -05:00
Chris Hubbard b47c95d902 Fix crash when removing last item in ListView
When the VirtualListSize changes, the focus_item_index should
be reset (similar to how it currently resets the selected indices).

If the last item in a ListView has focus and it is removed by
an another action on the form (i.e. push a button to remove the
current item), then the focused_item_index is not updated when
the VirtualListSize changes, even though that item doesn't exist
anymore.  When the ListView receives focus again, it tries to
invalidate the current focused item which causes an
ArgumentOutOfRangeException.
2014-11-17 15:35:33 -05:00
Vlad Brezae 09edaaf4d4 Keep the monitor link to the object active also in the resurrection case.
The MonoThreadsSync data field contains a weak reference to the object that uses the structure, which should be a tracking one.
2014-11-17 12:23:32 -08:00
Rodrigo Kumpera c12c27a9a9 Merge pull request #1405 from mono/revert-1289-stackframe
Revert "Improved exception stack frame displayed data."
2014-11-17 14:39:43 -05:00
Rodrigo Kumpera 7e7fce7bf1 Revert "Improved exception stack frame displayed data." 2014-11-17 14:37:41 -05:00
Rodrigo Kumpera f256f515de Merge pull request #1289 from esdrubal/stackframe
Improved exception stack frame displayed data.
2014-11-17 12:44:35 -05:00
Marcos Henrich 937c7233d2 Changed METHOD_EXIT_IL_OFFSET back to 0xffffff.
The previous value was -2, that could introduce comparison issues.
Added flag MONO_SEQ_POINT_FLAG_EXIT_IL that is used to encode the exit IL, this avoids a 4 byte IL offset delta.
2014-11-17 20:47:43 +08:00
Marcos Henrich 8bf7d26eaa Added out_buf parameter to encode_var_int and decode_var_int. 2014-11-17 18:20:15 +08:00
Marcos Henrich c6fb27e6e9 Renamed seq_point_info_write_size to seq_point_info_get_write_size. 2014-11-17 17:54:51 +08:00
Marcos Henrich 0f2444e940 MonoSeqPointInfo data is now compressed.
Encode data MonoSeqPointInfo len, has_debug_data and alloc_data into a single variable int.
2014-11-17 17:54:50 +08:00
Marcos Henrich 698e12809f MonoSeqPointInfo no longer uses a GByteArray.
GByteArray requires too much memory, we still use GByteArray to build the buffer but when its done we store in MonoSeqPointInfo a copy.
2014-11-17 17:54:49 +08:00
Marcos Henrich 95b1a5bbf9 Merged SeqPoint.next_array with SeqPoint.array. 2014-11-17 17:54:49 +08:00
Marcos Henrich 63dce7b8e3 SeqPoint next array is no longer allocated by default.
Next array will only be allocated if has_debug_data is true.
2014-11-17 17:54:48 +08:00
Marcos Henrich ba7b9fc562 Added size of sequence points to mono jit stats. 2014-11-17 17:54:48 +08:00
Marcos Henrich 49b7ef4442 Ignore seq points of entry and exit IL offsets.
Those seq points are only required for debugging.
2014-11-17 17:54:47 +08:00
Marcos Henrich 6dea3629f7 Changed mini-exceptions functions to get IL offsets from seq point.
mono_walk_stack_full and ves_icall_get_trace are now using find_prev_seq_point_for_native_offset to retrieve IL offsets.
2014-11-17 17:54:46 +08:00
Marcos Henrich e8412d602f Sequence points debug data is no longer store by default.
Debug data is only stored when cfg->gen_seq_points_debug_data is true.
2014-11-17 17:54:45 +08:00
Marcos Henrich d55bb757b3 Sequence points are now generated by default. 2014-11-17 17:54:23 +08:00
Mauricio Faria de Oliveira 3953793f0c [ppc] Bump (more) instruction sizes after 51c454f6b0.
This fixes ~30 ppc-specific failures in mono/tests (e.g., appdomain), like this:
	wrong maximal instruction length of instruction atomic_add_i4 (expected 20, got 28)
	* Assertion: should not be reached at mini-ppc.c:5235

The commit 51c454f6b0 introduced 2 ppc_sync
instructions in OP_ATOMIC_CAS_I4/8 *and* OP_ATOMIC_ADD_NEW_I4/8 (mini-ppc64.c).

Accordingly, commit 83a34c40c6 updated the maxlength
(+8 bytes) of atomic_cas_i4/8 - *but not* atomic_add_new_i4/8 (cpu-ppc64.md).

Recently, commit b784b866da made atomic_add_new_i4/8
exercised (as 'atomic_add_i4/8') - with an incorrect/non-updated 20-byte maxlength,
which should actually be 28.

Thus:
	wrong maximal instruction length of instruction atomic_add_i4 (expected 20, got 28)

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-11-17 02:34:13 +00:00
Bill Seurer ba62bdf862 PowerPC64 ELFv2 ABI: cases for in-register parameter passing, return values, and structs
The ELFv2 ABI specifies some particular cases for in-register parameter
passing, return values, float/double structs; e.g.,
- small struct returned via registers (2 doublewords)
- homogeneous float struct returned via registers (8 members)
- small float struct passed/returned via FR registers
- return via multiple registers

Author: Bill Seurer <[email protected]>
Origin: https://launchpad.net/ubuntu/+source/mono/3.2.8+dfsg-4ubuntu2
Changes: Mauricio Faria de Oliveira <[email protected]>

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-11-17 02:34:12 +00:00
Michael Matz 5785fd898a Use ppc_r12 for some global call sequences
After the mechanical exchange of ppc_r11 and ppc_r12 we now can use
ppc_r12 for global calls to hold the callees address without clobbering
r11 (which potentially contains IMT_REG, VTABLE_REG and RGCTX_REG).
We don't need to change all indirect calls, only those potentially reaching
functions containing a TOC setup based on r12 (in particular functions
in shared libs).  As the instruction sequence patcher can only deal
with one destination register we also need to make some additional
calls use r12.  We probably should convert all calls that currently
use r0 to use r12 if no other conflicts arise but this is enough to build.

Author: Michael Matz <[email protected]>
Origin: https://build.opensuse.org/request/show/225490
Changes: Mauricio Faria de Oliveira <[email protected]>

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-11-17 02:34:11 +00:00
Michael Matz 02cdf6abca Switch ppc_r11 with ppc_r12
This is a preliminary patch for ppc64le ELFv2 support.  That one requires
r12 to hold a functions address at calls to normal (global) C functions.
As is r12 is also used by mini for its IMT_REG, VTABLE_REG and RGCTX_REG
to pass around values to functions outside the normal argument registers
(ugh!), so there's a conflict.  This mechanical (by sed) patch simply switches
ppc_r11 and ppc_r12 everywhere, r11 doesn't have any special use in the ABI.

Author: Michael Matz <[email protected]>
Origin: https://build.opensuse.org/request/show/225490
Changes: Mauricio Faria de Oliveira <[email protected]>

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-11-17 02:34:10 +00:00
Michael Matz d9a3c39a04 Basic ppc64le support
This adds initial support for ppc64le to the ppc64 port.  That is:
* little endian aware (also in strtod),
* and ELFv2 aware (not using function descriptors)
* adjust various block sizes to be multiple of 64k, the default
  pagesize on ppc64le.  The sources should have used the system function
  to ensure alignment on pagesize, so this is just a stop-gap

It also corrects the list of registers for the precise GC, but that isn't
used in mini at all on any architecture currently.

Author: Michael Matz <[email protected]>
Origin: https://build.opensuse.org/request/show/225490
Changes: Mauricio Faria de Oliveira <[email protected]>

Signed-off-by: Mauricio Faria de Oliveira <[email protected]>
2014-11-17 02:33:59 +00:00
Jim Westfall 24742dc038 [MWF] Fix off-by-one from 5a5c683
first_row_index needs to be <= RowsLeft - 1, since we are comparing a
row count vs an index.
2014-11-15 09:35:54 -08:00
Marcos Henrich 4c8d5ee138 Changed METHOD_EXIT_IL_OFFSET to -2
The new value produces lower deltas and does not overflow when using variable integer encoding.
2014-11-15 03:44:10 +08:00
Marcos Henrich 49c48add7b aot-runtime and aot-compiler now use seq_point_info_read/write. 2014-11-15 03:44:09 +08:00
Marcos Henrich eecf7a8ab5 Added methods to read and write MonoSeqPointInfo. 2014-11-15 03:44:09 +08:00
Marcos Henrich 09bd838116 SeqPoint are now kept in memory with a compact encoding.
MonoSeqPointInfo has now a pointer to a buffer containing encoded sequence points, and to a buffer containing next values.
As there is no longer an array of SeqPoint ready to be read, SeqPointIterator was added.
2014-11-15 03:44:08 +08:00
Marcos Henrich d07e74a3f1 Moved sequence point logic to seq-points.h and seq-points.c 2014-11-15 03:44:07 +08:00
Marcos Henrich afc92f22dc Improved exception stack frame displayed data.
Added stack frame method address display.
2014-11-15 03:43:54 +08:00
Marcos Henrich 20523739f8 Added to StackFrame a field for the method address.
Incremented MONO_CORLIB_VERSION.
2014-11-15 03:34:31 +08:00
Zoltan Varga 4f237e0ce1 [runtime] Fix the errors in edb931dfb9 so it actually works. 2014-11-13 22:26:14 -05:00
fquiroz01 d380ffbb48 Add IE9 and newer to Up level navigator
This line enable the ASP Javascript validators in IE9 and upper. the user agent the IE10 is "Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1; WOW64; Trident/6.0)".
2014-11-13 22:05:39 -05:00
Mark Probst 06b8128992 [sgen] Add a FIXME. 2014-11-13 15:46:05 -08:00
Mark Probst 7bd3bd73d5 [sgen] Never mark from two threads at the same time.
We don't update mark bits atomically, so we can't have two threads
marking at the same time, which means we have to stop the concurrent
collector worker thread while we do work in the main GC thread.  That
includes nursery collections, because they also touch mark bits.

Also problematic are mod-union updates.  The worker threads can add
global remsets, which they do in the main cardtable.  This will conflict
with updating the mod-union table, so having the workers stopped also
applies there.
2014-11-13 15:46:01 -08:00
Mark Probst e12085b4c9 [sgen] Reorganize sgen_perform_collection for clarity. 2014-11-13 15:44:28 -08:00
Mark Probst 1624ec14c3 [sgen] Make check-mark-bits work again. 2014-11-13 15:44:28 -08:00
Mark Probst b87d9685bb [sgen] Scan the whole nursery in the finish mark pause.
Before we do all the major heap work in the finish mark pause of a
concurrent collection, we perform a nursery collection, for simplicity's
sake.

The nursery collection left pinned objects in the nursery, without
following their references into the major heap, so the major heap work
had to scan those objects again.  There was no special provisioning
for this—major mark would do the pinning again, and we would
automatically end up scanning the objects again.

The way we determine the stack end for the GC thread, however,
had the effect of making pinning non-deterministic.  We would
conservatively scan part of the GC thread's stack, which was
subject to change, to pinning again might result in less or more
objects pinned.

The proper solution would be to determine the stack end correctly,
but for now we will just the whole nursery.
2014-11-13 15:44:27 -08:00
Mark Probst 537665b54e [sgen] Only count cards for STW protocol if heavy is enabled. 2014-11-13 15:44:26 -08:00
Mark Probst 3639ee61f1 [sgen] Binary protocol entry for pin stage. 2014-11-13 15:44:15 -08:00
Mark Probst fbfe8518ce [sgen] Add missing volatile. 2014-11-13 15:44:14 -08:00
Rolf Bjarne Kvinge 597183658e [System] Ignore two tests which are failing due to external factors changing.
See https://bugzilla.xamarin.com/show_bug.cgi?id=24340
2014-11-14 00:31:16 +01:00
Jonathan Pryor 6299445e81 [mono-api-html] Allow ignoring addition of property setters.
As mentioned in commit 789517f8, I'm trying to compare inter-API level
differences in Mono.Android.dll, and want to reduce as much
"meaningless noise" as possible -- changes which don't meaningfully
break API or ABI.

Among those "meaningless" changes are the addition of property setters
to properties. Adding a setter doesn't break API or ABI.

Add a `mono-api-html --ignore-changes-property-setters` option.

  --ignore-changes-property-setters:
      Ignore the addition of property setters.

      If a source property contains a getter and the target property
      contains both a getter and a setter, do not flag this as a
      change.
2014-11-13 13:36:45 -05:00
Jonathan Pryor 09d16b7265 [mono-api-html] Make --ignore-changes-virtual less lenient.
As mentioned in commit 789517f8, the intentino of
`mono-api-html --ignore-changes-virtual` is so that when a method is
changed from non-virtual to virtual or override, or from virtual to
override, a "Removed member" message isn't triggered.

However, the previous implementation was too lenient. While *adding*
virtual to the method is fine, *removing* is NOT fine, as that would
be an API breaking change (e.g. all classes which attempt to override
a previously virtual method could no longer do so).

Make the virtual check stricter so that virtual/override to
non-virtual changes are not ignored.
2014-11-13 13:36:45 -05:00
Marek Safar 3d293f5a71 [xbuild] Add 14.0 toolchain 2014-11-13 18:37:43 +01:00
Marek Safar 4697ef6e77 [mcs] More updates to auto-properties v6 implementation 2014-11-13 17:19:04 +01:00
Jim Westfall ad651ff43b [MWF] Add unit test for #24372 2014-11-12 19:50:32 -08:00
Zoltan Varga a32054ece9 [jit] Fix gshared and aot support for --debug=casts. 2014-11-12 20:12:44 -05:00
Zoltan Varga cdfb430b48 [jit] Fix --debug=casts support for casts in gshared methods. 2014-11-12 19:58:27 -05:00
Jonathan Pryor 789517f878 [mono-api-html] Allow ignoring parameter names, virtual.
I've been trying to review API diffs in Xamarin.Android between API
levels, but the diffs are "noisy" because Google will change parameter
names at-will, or will change a non-virtual method into a virtual
method, or a virtual method into an override, all of which are
acceptable changes but individually generate a Removed line in
mono-api-html output, and manually removing the *hundreds* of changes
is error-prone.

Add two new option flags to mono-api-html:

  --ignore-changes-parameter-names:
      Ignore changes in constructor and method parameter names.

      If parameter names change between <reference.xml> and
      <assembly.xml>, don't report a change for the constructor or
      method.

  --ignore-changes-virtual:
      Ignore changes in "virtual-ness".

      If a method or property changes from non-virtual to virtual,
      non-virtual to override, or virtual to override, don't report a
      change for the member.
2014-11-12 17:34:21 -05:00
Rodrigo Kumpera b486e8372e [runtime] Fix a deadlock introduced in the last commit. 2014-11-12 16:49:30 -05:00
Rodrigo Kumpera 363e4bb2a6 [runtime] What MonoImage::ptr_cache with the image lock. Do optimistic locking here too. 2014-11-12 11:29:07 -05:00
Rodrigo Kumpera 2ef2b0d754 [runtime] Replace the loader lock when protecting the global module map. 2014-11-12 11:29:06 -05:00
Rodrigo Kumpera c6b845ea23 Add comment on one usage of the loader lock. 2014-11-12 11:29:06 -05:00
Rodrigo Kumpera 0526aa45e0 [runtime] Protect MonoImage::files with the image lock and make image loading optimistic. 2014-11-12 11:29:06 -05:00
Rodrigo Kumpera 4fe5a46e55 Change mono_class_from_generic_parameter to use the image lock.
We change the function to use the lock/validate pattern. This is both
more scalable and enables us to use the image lock, since the amount of
work done with it held is now trivial.
2014-11-12 11:29:06 -05:00
Rodrigo Kumpera 532420cc64 Reduce usage of the loader lock in method lookup.
The function mono_method_inflated_lookup no longer needs the loader lock to be held
as the hashtable is now protected by the imageset lock.

This means that mono_class_inflate_generic_method_full_checked doesn't need to take the
loader lock.

The function mono_method_set_generic_container uses mono_image_property_insert which takes
the image lock and not the loader lock. Adjust the locking comment.
2014-11-12 11:29:06 -05:00
Zoltan Varga 50e286b2e7 Fix the mobile build. 2014-11-11 20:11:45 -05:00
Zoltan Varga 60d83a46e7 [aot] Avoid an assert when AOTing a non-mobile mscorlib in a runtime with COM disabled. 2014-11-11 20:11:45 -05:00
Ludovic Henry 83fac07316 [perfcounters,proflog,mprof-report] Add support for Performance Counters sampling in the log profiler 2014-11-11 13:46:47 -05:00
Ludovic Henry 7b59f2dcf1 [counters,proflog] Add mono_counters_on_register/delete callbacks + Use them in proflog
This is used for counters that are defined after runtime initialization. It implies that TYPE_SAMPLE_COUNTERS_DESC can now be emitted at any time, and not only once.
2014-11-11 13:40:29 -05:00
Ludovic Henry 734b0e9d32 [counters] Make API thread safe 2014-11-11 13:40:28 -05:00
Ludovic Henry fcfb6c2935 [perf-counters] Fix return of the same counter even with different a counter parameter
The same counter instance would be returned if we use the "instance" parameter instead of the "counter"
parameter. Also it is the name of the counter that is stored in mono_perfcounter_create (mono-perfcounters.c:1488).
2014-11-11 13:40:27 -05:00
Ludovic Henry dc139819ea [perf-counters] Declare shared data header type directly after creation
Fix the following bug : shared_data_find_room return twice the same memory region because it was not marked as "in use" by setting the header.ftype value.
This bug is triggered when we want to create a new shared area (for example a new FTYPE_INSTANCE area) while creating another area (for example a new FTYPE_CATEGORY).
2014-11-11 13:40:27 -05:00
Ludovic Henry 38f2bff71d [perf-counters] Fix bug on SharedCounter decoding
The structure of the encoded SharedCounter is as follow :
 - compressed data type : 1 byte
 - index in the category : 1 byte
 - name of the counter : null terminated string
 - help of the counter : null terminated string
2014-11-11 13:40:26 -05:00
Marek Safar b82016bf29 [xbuild] Change default tools profile 2014-11-11 18:49:30 +01:00
Marek Safar eed64a2729 [corlib] Fix culture info error message. Fixes #24431 2014-11-11 15:53:04 +01:00
Marek Safar 9ddd46b890 [mcs] Extended pragma warning syntax 2014-11-11 15:42:05 +01:00
Marek Safar 31b2d60549 [mcs] Use same result bucket for extension method lookup in all types of using expression 2014-11-11 11:25:28 +01:00
Jim Westfall 5a5c683696 [MWF] DataGridView: ensure first_row_index will be valid after row removal
DataGridView keeps track of the first visible row in first_row_index.
DataGridViewRowCollection will notify DataGridView its about to delete 1 or
more rows via OnRowsPreRemovedInternal().  When this happens, we need to
ensure first_row_index will still fall within the number of rows that
will remain after the row removal.

This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=24372 which I
reported.
2014-11-10 19:20:56 -08:00
Zoltan Varga c09cd684b4 Add a test for #24419. 2014-11-10 20:54:12 -05:00
Zoltan Varga 5dd3347588 [jit] Remove some special casing from LDTOKEN, it doesn't seem to be needed. Fixes #24419. 2014-11-10 20:49:21 -05:00
Rodrigo Kumpera 5a2ef1b76f [runtime] Remove the second signal used by profiling and now multiplex distribution and sampling with the same signal. 2014-11-10 18:42:05 -05:00
Rodrigo Kumpera e6c3ff7551 [runtime] Introduce new MonoThread API for signal multiplexing. It's a provisional API until we figure out more of how it's suposed to work. 2014-11-10 18:41:25 -05:00
Rodrigo Kumpera 4d12ed3356 [profiler] Guard against null sbuff when serializing statistical data. 2014-11-10 18:41:20 -05:00
Rodrigo Kumpera a18dffad0d [profiler] Fix statistical backtraces to work and collect as many frames as possible.
This is a jumbo commit that addresses multiple issues with statistical backtrace collection:

1) It's not possible to reliably collect MonoMethod* so we check that they exist before
serializing to the .mlpd file and retrieve in sync context.

2) It was reporting the generic instance MonoMethod* under gsharing. Those methods are
not reported to the profiler since they are never compiled. They would turn out as unknowns.

3) Collecting IL offsets from async context is currently impossible to be done safely, so it's
now disabled. The way we'll do it in the future is by serializing the sequence point table when
JIT'ing.

4) The way we used to collect frames in statistical ignored all frames until the first LMF, which
discards a lot of them under statistical mode. We now properly pass sigcontext and have it been consumed.
In the future we should simply use the callchain mode.
2014-11-10 18:41:15 -05:00
Rodrigo Kumpera 3aa7f41bed [runtime] Changes mono_stack_walk_async_safe API to be truly async safe.
This is a very very tricky API, so we restrict the returned data to be what's really
possible under sig context.
2014-11-10 18:41:11 -05:00
Rodrigo Kumpera 412ed8153a [runtime] Harden the profiler signal handlers against not fully attached threads and HP reentrancy. 2014-11-10 18:41:05 -05:00
Zoltan Varga 25e04fa019 Revert "Disable building the NET 2.0 profile by default."
This reverts commit 458c9456f0.

This still breaks the build.
2014-11-10 17:46:34 -05:00
Zoltan Varga 458c9456f0 Disable building the NET 2.0 profile by default. 2014-11-10 15:43:53 -05:00
Zoltan Varga a8c183ac63 [jit] Get rid of the mono_arch_sigctx_to_monoctx()/monoctx_to_sigctx () functions, use mono_sigctx_to_monoctx()/monoctx_to_sigctx() instead. 2014-11-10 14:31:29 -05:00
Zoltan Varga a87062a145 [jit] Use xmm5 as an fp scratch register on winx64. 2014-11-10 14:04:23 -05:00
Jonathan Pryor 7f0da57a65 Merge pull request #1393 from akoeplinger/refresh-mdoc-expected
[mdoc] Refreshed the en.expected.importecmadoc files to fix errors after the recent XML changes

Output was generated on .NET, and thus is canonical.
2014-11-10 13:52:11 -05:00
Marek Safar 7c024c1d5a [mcs] Encode more win32 version info attributes. Fixes #23981 2014-11-10 16:09:38 +01:00
Marek Safar b7a8bfc7ad Merge pull request #1334 from ztone/delegate
Fix PrepareEmit error when evaluating delegates
2014-11-10 12:03:23 +01:00
Zoltan Varga 7e056cd346 [jit] Move the ppc sigctx<->monoctx conversion code to mono-context.c. 2014-11-10 05:22:04 -05:00
Zoltan Varga 1af68a199e Remove some dead code. 2014-11-10 05:06:51 -05:00
Zoltan Varga 0d1555dbd5 Fix the android build. 2014-11-09 21:41:43 -05:00
Miguel de Icaza fb3468e61c Merge pull request #1390 from woodsb02/FreeBSDMacNetworkInterfaces
Freebsd to use Mac NetworkInterface code instead of Linux NetworkInterface code
2014-11-09 20:17:50 -05:00
Zoltan Varga ab1c14290f Merge pull request #1392 from ludovic-henry/pr34-proflog-counters-sample-shutdown
[proflog] Add counters sampling on profiler shutdown and startup
2014-11-09 18:30:15 -05:00
Jim Westfall 7d1b878fbf [MWF] DataGridViewRowCollection Clear() speed up
When issuing a Clear() to remove all rows, a ReIndex() was being called for
each row that was being removed.  This is extremely inefficient, instead
do a single ReIndex() after all rows have been removed.

Before doing a Clear() of 30k rows was taking 5.8 seconds.  With this patch
it now takes 670ms.
2014-11-08 16:37:33 -08:00
Zoltan Varga 690a646c5e Merge pull request #1395 from ludovic-henry/pr38-proflog-only-counters
[proflog] Add onlycounters parameters which disable event dumping
2014-11-08 13:27:28 -05:00
Ludovic Henry bbfb0e86f3 [proflog] Add countersonly parameters which disable event dumping
This is useful in the case of the benchmarking suite because we are only interested in the counters, and they represent a minimal part of the output file size.
2014-11-08 10:40:34 -05:00
Zoltan Varga a255b522cb Fix a uninitialized variable warning. 2014-11-07 18:50:26 -05:00
Zoltan Varga 7d319221f1 Fix a problem introduced by e19f539121. 2014-11-07 16:53:22 -05:00
Zoltan Varga e19f539121 [amd64] Make xmm6:xmm15 callee saved on winx64 as required by the ABI. 2014-11-07 15:33:57 -05:00
Mark Probst 730d0ccd6f Merge pull request #1385 from BrzVlad/fin-hash
[sgen] Use hash based on current address for finalization hashes.
2014-11-07 12:14:48 -08:00
Alexander Köplinger 0442cdbc19 [System] Fixed formatting of new ClientWebSocket test and disabled it
We need to have an implementation for HttpListenerContext.AcceptWebSocketAsync () first before it works.
2014-11-07 20:16:51 +01:00
Alexander Köplinger 59d2397abc Merge branch 'patch-1' of https://github.com/ReubenBond/mono into ReubenBond-patch-1 2014-11-07 20:14:29 +01:00
Miguel de Icaza c97100c88d Merge pull request #1394 from kjpou1/master
Fix GetUsing to output the using name instead of -> using Mono.CSharp.Na...
2014-11-07 12:20:29 -05:00
Kenneth Pouncey de3ff228dc Add space 2014-11-07 16:59:42 +01:00
Kenneth Pouncey 3664e4c5a7 Add space 2014-11-07 16:57:41 +01:00
Kenneth Pouncey db2381da04 Fix GetUsing to output the using name instead of -> using Mono.CSharp.NamespaceExpression; <- for every using statement that was set
+ Fix NRE when source_file or source_file.Usings is null. This will now return back an empty string or empty List
+ **Note** that we are returning the ToString() value of NamespaceExpression which is the full resolved namespace of "System.Drawing" instead of "Drawing".
+ Add ToString override for NamespaceExpression to return the full resolved name of the namespace.
2014-11-07 16:41:05 +01:00
Atsushi Eno 367d417207 [Mono.Posix] consider nano time info in UnixFileSystemInfo.Last*Time.
Before this change, those Last*Time properties returned only based on
seconds (truncated), which could cause inaccurate time comparison.
Consider code like this:

var fileUpdated = DateTime.Now;
...
File.WriteAllText (path, "foobar");
...
if (fileUpdated > new UnixFileInfo (path).LastWriteTime)
   OnUpdatedFile (path);

This could always result in raising update event, even if there was
no update after writing.

Last*Time With milliseconds makes it very unlikely to happen.
2014-11-07 20:42:25 +08:00
Alexander Köplinger e1900d6dc2 [mdoc] Refreshed the en.expected.importecmadoc files to fix errors after the recent XML changes
The XML work in 661430fd1f and bf39f5aec0 changed the whitespace handling, so the mdoc test suite failed.
Refreshing the files makes them identical to what MS.NET produces and fixes the mdoc tests.
2014-11-07 12:34:26 +01:00
Atsushi Eno bf39f5aec0 [xml] XmlElement.InnserXml seems to preserve whitespaces.
Fix for mdoc test regression (see commit comments on #661430f).
2014-11-07 15:35:40 +08:00
Zoltan Varga edb931dfb9 [runtime] Use a separate signal with the SA_RESTART flag set for suspending/resuming threads during debugging on android, since lots of android native code cannot handle the interruptions caused by the normal abort signal. Fixes #22968/#23987. 2014-11-06 19:44:57 -05:00
Ludovic Henry e41c4efed5 [proflog] Add counters sampling on runtime initialized 2014-11-06 15:25:04 -05:00
Ludovic Henry 8a1db154e1 [proflog] Add counters sampling on profiler shutdown 2014-11-06 15:17:17 -05:00
Ben Woods ba998de3c9 Freebsd to use Mac NetworkInterface code instead of Linux NetworkInterface code 2014-11-06 17:27:36 +08:00
Mark Probst b9061f8807 [sgen] When out of memory, finish concurrent with scanning whole nursery. Fixes #23401.
If we run out of memory during the nursery collection in the finishing collection pause,
there will be late-pinned objects in the nursery: pinned objects that were not pinned
from conservative roots (or cementing).  We need to scan those, too, so in that case
we just walk the nursery and scan all objects.
2014-11-05 16:27:02 -08:00
Mark Probst 9bf45cc5ba [sgen] Make check-mark-bits also scan nursery objects. 2014-11-05 16:27:02 -08:00
Mark Probst d69d4c2472 [sgen] Optional check that the concurrent collector doesn't update references. 2014-11-05 16:27:02 -08:00
Mark Probst 9ed222bd75 [sgen] Add assertions. 2014-11-05 16:27:02 -08:00
Mark Probst 2ba7fb3a36 [sgen] Move heap checks before pinning. 2014-11-05 16:27:01 -08:00
Mark Probst b479e83275 [sgen] Stop concurrent worker during concurrent update and nursery collections.
The two collectors stepped on each other's toes.  Specifically, updating the mod union
card table while the worker thread might mark cards in the card table will not work.

The simplest solution for now is to stop the worker thread during concurrent updates
and nursery collections.  In the future we can have the thread help with the nursery
collection.
2014-11-05 16:27:01 -08:00
Mark Probst 72bd6b96fb [sgen] Remove workers_marking - workers are always marking. 2014-11-05 16:27:01 -08:00
Mark Probst 5479dd7e38 [sgen] Implement a proper state machine for workers.
What we had previously was an impromptu state machine that was
badly implemented, hard to reason about, and not easily extensible.
2014-11-05 16:27:01 -08:00
Mark Probst ef8f07687d [sgen] Fix build with heavy binary protocol. 2014-11-05 16:27:00 -08:00
Mark Probst 47287a6784 [sgen] Fix cementing with concurrent M&S.
Cementing can happen during a concurrent collection when processing
the cardtable.  We use a separate cementing hash during concurrent
collections but we didn't pin objects from there.
2014-11-05 16:27:00 -08:00
Zoltan Varga 363302f71f Install Mono.Cecil in the net 4.5 profile. 2014-11-05 17:31:48 -05:00
Zoltan Varga ed65bc251d Revert "Disable building the NET 2.0 profile by default."
This reverts commit fe265502cc.

Revert this for now as it breaks too much stuff.
2014-11-05 16:57:00 -05:00
Marcos Henrich 570cb1a10a Changed script DateTime.Now_Test.sh to use the compiled csharp.exe. 2014-11-05 16:38:39 +00:00
Marcos Henrich b324cecd4f TZ display name changes no longer reset adjustment rules.
Reset of adjustment rules is mandatory when the base offset is changed because the rules are relative to the base offset.
Adjustment rules are now kept until the base offset changes.
2014-11-05 16:30:13 +00:00
Radek Doulik d8aad87c88 [linker] blacklist System.Net.Sockets.MulticastOption fields
- merge fix for https://bugzilla.xamarin.com/show_bug.cgi?id=21578
   the MulticastOption's 'private IPAddress local' field was
   removed by linker and the app crashed later at runtime.
 - when System.Net.Sockets.MulticastOption object
   is passed to System.Net.Sockets.Socket.SetSocketOption
   and thru it to System.Net.Sockets.Socket.SetSocketOption_internal
   it accesses passed object fields
   (thru few more native calls).
2014-11-05 13:00:37 +01:00
Zoltan Varga 1ea6921beb Merge pull request #1387 from akoeplinger/improve-bug652331_2
[System.ServiceModel] Fixed Bug652331_2 test that failed on Jenkins by increasing timeout
2014-11-04 23:18:11 -05:00
Zoltan Varga 2a11a2f11b [arm] Fix OP_LOCALLOC on arm so it correctly adjusts sp with the param area size even if the size is large. Fixes #24221. 2014-11-04 22:45:23 -05:00
Rodrigo Kumpera d51f34fd21 [profiler] Expose new profiling modes and allow sampling rate to be set when using signal-based sampling. 2014-11-04 19:30:02 -05:00
Rodrigo Kumpera 9522723493 [profiler] Add new profiler API mono_profiler_set_statistical_mode that gives control to statistical mode and sampling rate. 2014-11-04 19:30:02 -05:00
Rodrigo Kumpera 53cd89d23a [profiler] Fix signal based profiling to sample all registered threads.
The current signal profiling code depended on invalid linux behavior of setitimer
allowing multiple threads to register for the same timer. Linux kernel 2.6.12 fixed
this and only the main thread gets the signal. Always.

The correct POSIX behavior happens on OSX/iOS.

On Linux we could use timer_create and SIGEV_THREAD_ID but that would not work on iOS/OSX
since it's specific to it. Given that little detail, I'll leave implementing it as an
exercise to the reader.

The solution, which aims to be as portable as possible, is to use a pair of signals and
have the first one fire the second one against all other threads.

We use a pair of signals since it's not well defined which thread will receive the signal
so detecting this from the signal is non-trivial.
2014-11-04 19:30:02 -05:00
Rodrigo Kumpera f34e6426f9 Make mono_threads_pthread_kill available to mach targets. 2014-11-04 19:30:01 -05:00
Zoltan Varga 82cfc3ea31 Make the build in docs/ uses the net 4.5 profile. 2014-11-04 18:24:27 -05:00
Zoltan Varga fe265502cc Disable building the NET 2.0 profile by default. 2014-11-04 17:49:18 -05:00
Zoltan Varga f6da6fa9ea Fix the loadable llvm build. 2014-11-04 16:44:39 -05:00
Zoltan Varga f812f43d2e [llvm] Add beginnings of support for emitting dwarf debug info for LLVM code. Not enabled yet, since it would clash with the dwarf info emitted by the AOT compiler for JITted code. 2014-11-04 16:20:05 -05:00
Alexander Köplinger d3ee9252da [System.ServiceModel] Fixed Bug652331_2 test that failed on Jenkins by increasing timeout
Looks like the test takes quite a while so 10 seconds was just too short. Increasing the timeout to 20s seems to fix it.
2014-11-04 21:17:26 +01:00
Jonathan Pryor c84d28ca73 [mscorlib] Marshal.GetExceptionForHR() takes an errorInfo parameter.
Parameter names are part of the ABI because of C#4 named parameter.
Consequently, they *must* be consistent with .NET, and .NET a
parameter name of "errorInfo", *not* "errorInfoPtr" [0]:

	public static Exception GetExceptionForHR(
		int errorCode,
		IntPtr errorInfo
	)

Change the parameter name from `errorCodeInfo` to `errorCode` so that
the parameter name is consistent with .NET.

[0]: http://msdn.microsoft.com/en-us/library/3xade62s(v=vs.100).aspx
2014-11-04 14:26:32 -05:00
Alexander Köplinger fc02486d6a Fix NET_2_0 build 2014-11-04 10:49:57 +01:00
Miguel de Icaza 9bb11ade6d Merge pull request #1363 from martinjt/AddMembershipPasswordAttribute
Added the MembershipPasswordAttribute class and associated unit tests
2014-11-04 12:51:53 -05:00
Vlad Brezae b160f1e3b7 [sgen] Use hash based on current address for finalization hashes.
Extend functionality of SgenPointerQueue.

The purpose of this commit is to avoid dependency between GC code and the obtaining of the hash from the object's synchronisation field, which might require additional processing.
2014-11-03 17:30:31 -08:00
Zoltan Varga 92c91d75f0 [jit] Factor out duplicate code from the castclass/unbox.any opcode implementation. 2014-11-03 17:53:21 -05:00
Martin Thwaites 8302b5782d Implement MachineKey.Protect and MachineKey.Unprotect 2014-11-03 21:52:18 +00:00
Martin Thwaites 1c6da6b912 Added the MembershipPasswordAttribute class and associated unit tests 2014-11-03 21:40:44 +00:00
Zoltan Varga 7b4bd74b4d [jit] Reenable the more efficient cast code in gshared methods. 2014-11-03 16:06:46 -05:00
Marcos Henrich e5fc5450dd Merge pull request #1185 from esdrubal/http-reuse
Allow stream reuse when InputStream has been disposed.
2014-11-03 11:41:13 +00:00
Miguel de Icaza 09308892bd Merge pull request #1347 from ermshiperete/ImproveEllipsisHandling
[MWF] Improve ellipsis handling
2014-11-02 12:36:49 -05:00
Alexander Köplinger 57feacab95 Add missing newline in .sources file, should fix build 2014-10-31 23:07:28 +01:00
Miguel de Icaza 716c7ad122 [asp.net] Implement the EventHandlerTaskAsyncHelper and HttpTaskAsyncHandler classes; Manually bring Pull Request 1365 from Kornel Pal 2014-11-01 21:23:15 -04:00
Miguel de Icaza 0afdce4e37 Merge pull request #1371 from martinjt/AddClientDisconnectedToken
Add ClientDisconnectedToken property to HttpResponseBase and Wrapper as ...
2014-11-01 20:50:48 -04:00
Miguel de Icaza 5c23f1e15d Set ReadEntityBodyMode default to Classic to force clients to use the old method
for reading the input stream.

According to the MSDN docs, if ReadEntityBodyMode returns "Classic" the code should use
the old method to read the input stream (HttpRequestBase.InputStream) which is fully
implemented in mono.

Manually applied patch from martinjt
2014-11-01 20:49:10 -04:00
Miguel de Icaza b11044a9a6 [asp.net] Implement the EventHandlerTaskAsyncHelper and HttpTaskAsyncHandler classes; Manually bring Pull Request 1365 from Kornel Pal 2014-11-01 20:48:12 -04:00
Miguel de Icaza e4d8f21cf6 Merge pull request #1163 from AerisG222/more_mvc_fixes
Add missing elements to allow MVC5.2 site to run
2014-11-01 20:36:49 -04:00
Atsushi Eno 661430fd1f [xml] XmlDocument.ReadNode() should not special case XmlTextReader.
Added test case that proves this change (by baulig).
2014-11-01 00:06:05 +08:00
Miguel de Icaza 3fd4901a23 Merge pull request #960 from ermshiperete/ShowHelp
[MWF] Partially implement Help.ShowHelp
2014-10-31 11:20:20 -04:00
João Matos 100ecb4f0f Merge pull request #1360 from madewokherd/winuncpath
File URI's without a host are not UNC paths on Windows.
2014-10-31 13:52:33 +00:00
Mark Probst 000c018169 [sgen] Add an explanatory comment about OOM. 2014-10-30 16:28:03 -07:00
Zoltan Varga f85a6bc77c [runtime] Fix the android build with ndk r10c. 2014-10-30 18:44:05 -04:00
Rodrigo Kumpera f05e658a2d Merge pull request #1381 from schani/fix-23401
Fix 23401
2014-10-30 18:43:36 -04:00
Zoltan Varga dbfee6a340 [aot] Remove some obsolete TODOs. 2014-10-30 17:56:19 -04:00
Zoltan Varga bf6fea51af [aot] Use the info->tramp_page_code_offsets array on arm as well. 2014-10-30 17:52:33 -04:00
Zoltan Varga 74d2172cd1 Fix a warning. 2014-10-30 17:28:31 -04:00
Zoltan Varga b40386d4f4 Add the -Qunused-arguments warning to CPPFLAGS too. 2014-10-30 17:28:22 -04:00
Zoltan Varga 7c162f952c [llvm] Remove the unused LLVM_MAJOR_VERSION/LLVM_MINOR_VERSION defines. 2014-10-30 17:23:18 -04:00
Alexander Köplinger 3c533de4a8 Add files that were forgotten in 6af7989628, which is the re-apply of 950d9c8a56 2014-10-30 22:16:35 +01:00
Mark Probst 5eec4d0c84 [sgen] Don't store pin queue addresses, only indexes. Fixes #24084.
The pin queue can get relocated as a side-effect of resizing when late
pinning happens, so we can't count on pointers into it to remain valid.
2014-10-30 13:34:44 -07:00
Mark Probst 45fc2e14fd [sgen] Fix crash in late pinning.
Our code assumed that late-pinned objects don't have a tag, but they
obviously have the pin tag, so use the safe function.
2014-10-30 13:30:26 -07:00
Mark Probst 03494c7387 [sgen] Don't loop endlessly when out of memory. 2014-10-30 13:30:26 -07:00
Ryan J. Melena ef13507552 Revert incorrect changes from commit 950d9c8a56
Correctly handle null value deserialization in non-generic Deserialize(string, Type) method.
2014-10-30 16:19:40 -04:00
Miguel de Icaza 6af7989628 Re-apply the patch, there isa fix for it 2014-10-30 16:19:07 -04:00
Zoltan Varga f269254917 [Mono.Data.Tds] Allow sending of text data longer than 4000 characters by using a different column type. Fixes #21172. 2014-10-30 14:39:44 -04:00
Miguel de Icaza 112079b844 Revert this patch, as it broke the test suite 2014-10-30 13:54:33 -04:00
Jonathan Pryor ac1dcc6ade [System.Core/Android] Update TimeZone database self test.
Add Makefile rules to automagically download the TimeZone database
from the Android target $(ADB_TARGET), and build the tzi.exe app.

	$ make android-dump-tzdata ADB_TARGET=-d
	# downloads timezone data into ./android/tzdb.
	# dumps timezone data into ./android/tzdata
	# builds ./tzi.exe

	# Show adjustment rules for a given timezone dump
	$ mono tzi.exe -i=tzdata/Asia/Amman

Add `tzi.exe -R` option to show the TimeZoneInfo.GetAdjustmentRules()
output for all encountered timezones.

Add `tzi.exe -o=PATH` option to dump the TimeZone data to disk for
interrogation.

Add `tzi.exe -i=PATH` option to read in the specified TimeZone data
file and dump the rules contained therein.

Update usage comments.
2014-10-30 12:42:37 -04:00
Zoltan Varga dacc3f8c5d Merge pull request #944 from ermshiperete/bug-novell-496138
Improve COM error handling
2014-10-29 19:06:05 -04:00
Zoltan Varga 6a738caa5a [corlib] Add some missing memory barriers to the ConcurrentQueue methods to order memory operations. Fixes #22788. 2014-10-29 17:14:10 -04:00
Zoltan Varga bd715a7c5e Merge pull request #1378 from DynamicDevices/ajl/warnings
[libgc] Eliminate warning about redefinition of GC_WIN32_THREADS
2014-10-29 15:03:31 -04:00
Miguel de Icaza c265540e76 Merge pull request #1337 from RyanMelenaNoesis/master
Additional JWT Security Token Support
2014-10-29 15:02:30 -04:00
Alexis Christoforides d585381555 Bump Mono version -> 3.12.1 2014-10-29 13:16:04 -04:00
Zoltan Varga dcdc8414df [llvm] Disable the extension of i8/i16 arguments to i32 on arm64, since the ios calling convention passes them differently than i32. Fixes #22800. 2014-10-29 12:55:31 -04:00
Alex J Lennon 41981cdca1 [libgc] Eliminate warning about redefinition of GC_WIN32_THREADS
Makefile defines GC_WIN32_THREADS as 1 but gc_config_macros was
redefining as defined but with no value.

Signed-off-by: Alex J Lennon <[email protected]>
2014-10-29 14:27:01 +01:00
Zoltan Varga 2e8f21d4f2 [llvm] Fix a regression caused by 6ec1ebf990. Do the direct call rewrite only if the caller and callee signature matches. 2014-10-28 23:30:44 -04:00
Zoltan Varga 7e8a11f888 [runtime] Disable the check for overlapping reference and non-reference fields, too much code depends on this to work. 2014-10-28 17:08:09 -04:00
Neale Ferguson 872e97cb30 Add OP_LREM_IMM support;Add implementation of mono_arch_get_delegate_virtual_invoke_impl 2014-10-28 14:48:45 -04:00
Marcos Henrich 36c9c006bc Merge pull request #1298 from esdrubal/uploadfileasync
Fixes missing ContentType on WebClient.UploadFileTaskAsync
2014-10-28 18:21:22 +00:00
Marcos Henrich 137718d9b4 Merge pull request #1321 from esdrubal/currentsystemtimezone
CurrentSystemTimeZone.GetUtcOffset now supports multiple DST periods.
2014-10-28 18:18:54 +00:00
Zoltan Varga 424d1cdc8b Merge pull request #1376 from StephenMcConnel/bug-24109
Zero out pointers to freed memory in AudioDevice
2014-10-28 13:40:28 -04:00
Stephen McConnel 328defdcde Zero out pointers to freed memory in AudioDevice
This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=24109.
2014-10-28 12:10:43 -05:00
Alexis Christoforides e0dab7749a Merge pull request #1373 from michaldobrodenka/master
Fix for random ObjectDiposedException in DispatcherCB class when connecting
2014-10-28 12:48:14 -04:00
João Matos e4b431e3a5 Merge pull request #1369 from DynamicDevices/ajl/appveyor
[CI] Add appveyor.yml configuration file to support Windows build
2014-10-28 16:47:19 +00:00
Zoltan Varga 039ffcafca Merge pull request #1374 from directhex/master
Add missing header file to s390x_sources
2014-10-28 01:08:37 -04:00
Alexis Christoforides 717c6de1cc [System.IO] Phase 2 of revamping KeventWatcher (FileSystemWatcher implementation for OS X/kqueue). Dozens of bugs and reliability issues fixed.
FileSystemWatcher.cs: Fixed multicast events.
SearchPattern.cs :  Fixed issue where case insensitivity was not being honored.
KeventWatcher.cs:
* Fixed several race conditions
* Fixed file descriptor duplication & leaks
* thread-safe/cleaner state transitions for watcher, and much cleaner stopping
* Now uses fsw.Filter parameter and respects IncludeSubdirectories = false. Use fsw.Filter to watch very large trees
* Added more error handling + OnError event
* Lots of behavior/reliability fixes and optimizations for Monitor() loop
* Fixed kevent/timespec struct definitions (for 64-bit build)
2014-10-27 21:20:16 -04:00
Cody Russell 13fd028ee8 [System.IO] Reimplemented much of the kqueue-based file watcher so that watching subdirectories works.
Reworked a lot of the internals of the kqueue FileSystemWatcher. There
is now a separate thread and a separate kqueue for each FileSystemWatcher
object.

https://bugzilla.xamarin.com/show_bug.cgi?id=16259
2014-10-27 21:20:16 -04:00
Zoltan Varga 80ca0394cd [jit] Fix the decomposition of OP_IREM_IMM on arm64. 2014-10-27 20:55:51 -04:00
Jo Shields 8b80178115 Add missing header file to s390x_sources, otherwise a required header file for s390x builds is missing from tarball builds. 2014-10-27 22:51:47 +00:00
Ludovic Henry 447975c12c [threadpool] Fix race condition on threads variable cleanup 2014-10-27 12:28:19 -04:00
michaldobrodenka 7174b069cf Fix for ObjectDiposedException in DispatcherCB class
https://bugzilla.xamarin.com/show_bug.cgi?id=23700
2014-10-27 13:28:59 +01:00
Martin Thwaites b7b94a8024 Add ClientDisconnectedToken property to HttpResponseBase and Wrapper as default None 2014-10-26 23:42:54 +00:00
Miguel de Icaza 45d831259b Merge pull request #1368 from martinjt/SuppressFormsAuthRedirect
Implement the SuppressFormsAuthenticationRedirect properties
2014-10-26 18:53:05 -04:00
Zoltan Varga c170351fde Merge pull request #1366 from DynamicDevices/ajl/win32build
Fix Windows build by including wstcpip.h before winsock.h is included
2014-10-26 11:17:39 -04:00
Mike Morano d35449e99b Add/update missing bits in order to support MVC5.2. 2014-10-26 11:14:08 -04:00
Martin Thwaites e55e70f8c7 Implement the SuppressFormsAuthenticationRedirect properties 2014-10-26 14:55:41 +00:00
Zoltan Varga 5a234d5d16 Merge pull request #1367 from kornelpal/dolt-mingw32
[build] Enable dolt on mingw32
2014-10-26 10:07:51 -04:00
Kornel Pal 0635a83c89 [build] Enable dolt on mingw32 2014-10-26 14:49:45 +01:00
Alex J Lennon ff1817f017 [CI] Add appveyor.yml configuration file to support Windows build
Adds a configuration file to facilitate build of Mono with Cygwin
on Appveyor Windows-based build workers.

Dependencies are installed on a clean Appveyor build image for
each build and the result of the 'make install' step is stored
as a build output 'artifact' for further testing or deployment.

Signed-off-by: Alex J Lennon <[email protected]>
2014-10-26 14:06:08 +01:00
Alex J Lennon d663c9f65c Fix Windows build by including wstcpip.h before winsock.h is included
Error generated by socket-io.c was:

/usr/i686-pc-mingw32/sys-root/mingw/include/ws2tcpip.h:38:2:
error: #error "ws2tcpip.h is not compatible with winsock.h.
Include winsock2.h instead."

Signed-off-by: Alex J Lennon <[email protected]>
2014-10-26 12:49:59 +01:00
Stone Gislason f1108aabba [eval] Fix delegate; add caching for PrepareEmit
The delegate class did not use the internal cache flag as other type definitions which caused the next evaluation to fail.
2014-10-26 01:15:37 +01:00
Zoltan Varga 8f9a74f2f6 Merge pull request #1364 from muojp/addDotNet45_SocketCtor
[System] Added missing ctor to Socket for initializing dual-mode socket
2014-10-25 17:24:53 -04:00
Kei Nakazawa dc30595ace [System] Added missing ctor to Socket for initializing dual-mode socket
- Ref: https://bugzilla.xamarin.com/show_bug.cgi?id=20048
 - Mono currently doesn't support 2-args Socket ctor added in .NET 4.5
 - Absence of this ctor prevents KestrelHttpServer (web server for
   ASP.NET vNext: https://github.com/aspnet/KestrelHttpServer ) test
   code from working
 - I hesitated to put IPv4 only implementation, but full dual stack
   (IPv4/v6) support would need bunch of works to be done. So, I pinned
   supported protocol of new ctor to IPv4. Also, I filed v4/v6 support
   issue as a MonoTODO entry inside the source code.
2014-10-26 02:57:22 +09:00
Eberhard Beilharz 5d869be794 [MWF] Improve ellipsis handling
- Don't subtract room for ellipsis. Ellipsis should be
  handled by the renderer so we shouldn't reserve space for it.
  Otherwise we end up not getting ellipsis (because the renderer
  thinks there is enough space available), or we don't use up the
  available space.
- Don't allow text to go below button if we want to show ellipsis.
2014-10-24 22:38:56 +02:00
Eberhard Beilharz ab361102db [MWF] Display visual feedback on pressed button (#23869)
When a button is pressed the image and the text needs to be rendered one
pixel to the right and to the bottom so that there is some visual
feedback of the button press. Previously this was only the case if
TextImageRelation was set to Overlay.
2014-10-24 22:26:59 +02:00
Jonathan Pryor f7fd52ad18 [mscorlib/Android] TimeZoneInfo.Local.Id should be "Local".
On Mono/.NET, TimeZoneInfo.Local has a TimeZoneInfo.Id value of
"Local" and a TimeZoneInfo.DisplayName value of "Local":

	$ csharp
	csharp> TimeZoneInfo.Local.Id;
	"Local"
	csharp> TimeZoneInfo.Local.DisplayName;
	"Local"

That isn't the case on Xamarin.Android, which returns the timezoneinfo
ID value from both DisplayName and Id, e.g. TimeZoneInfo.Local could
have Id and DisplayName values of "Australia/Sydney".

Rework things so that the TimeZoneInfo.Id and TimeZoneInfo.DisplayName
properties return "Local" on Xamarin.Android for the instance returned
from TimeZoneInfo.Local, just like normal Mono/.NET does.
2014-10-24 15:56:13 -04:00
Miguel de Icaza 84472a332e Merge pull request #1348 from ermshiperete/ImproveButtonTextLayout
[MWF] Improve button text layout
2014-10-24 14:44:29 -04:00
Miguel de Icaza c19e821763 Merge pull request #1357 from emergent-design/master
Include /dev/ttyACM in the search for serial port devices
2014-10-24 14:43:49 -04:00
Miguel de Icaza e867622025 Merge pull request #1362 from echampet/dupfix
Webapp stuck with "Key duplication when adding: httpModules"
2014-10-24 14:43:00 -04:00
Etienne CHAMPETIER c46234bf0c HttpApplication: if there is an exception in InitOnce, output it on the Console
Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-10-24 16:17:10 +02:00
Etienne CHAMPETIER 9b7b75d7ec WebConfigurationManager: simplify call to ConfigurationSection.GetRuntimeObject ()
this call come from an obfuscation contest :) ?

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-10-24 16:17:01 +02:00
Etienne CHAMPETIER 3fd3541704 WebConfigurationManager: protect GetSection
all public static should be thread-safe

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-10-24 16:16:55 +02:00
Etienne CHAMPETIER 8630afbd9b HttpApplication: set StatusCode = 500 when we send an exception to the client
Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-10-24 16:16:47 +02:00
Jo Shields 8da186ea62 Merge pull request #1361 from akoeplinger/fix-forms
[MWF] Use overload of Marshal.PtrToStringUni that reads up until the first null instead of explicitly specifying length
2014-10-24 13:23:15 +01:00
Atsushi Eno 976be34045 [xml] XmlTextReader: Value was wrong after ReadAttributeValue() on xml declaration. 2014-10-24 12:20:09 +08:00
Zoltan Varga e6b335e7f7 [runtime] Remove build system support for the interpreter. 2014-10-23 23:01:28 -04:00
Atsushi Eno 3d9a2b7175 [relaxng] fix default namespace handling in compact syntax.
Also had to disable RNC tests that depended on vanished web resource...
2014-10-24 07:14:58 +08:00
Alexander Köplinger ede4f3a8c6 [MWF] Use overload of Marshal.PtrToStringUni that reads up until the first null instead of explicitly specifying length
This fixes the two tests broken by 0ac61b03fc
2014-10-24 00:11:03 +02:00
Vincent Povirk dd68e53636 File URI's without a host are not UNC paths on Windows.
NUnit breaks when these URI's are treated as UNC paths, so I have no way of
running the tests on Windows without this change to see if it broke anything.
Not all URI tests pass, but the ones that fail seem unrelated to my change.

On Unix, the tests all work, but of course on Unix this is a no-op.

This commit licensed as MIT/X11.
2014-10-23 16:12:30 -05:00
Zoltan Varga e1da8e304d [jit] Use NULLIFY_INS () to nullify instructions and use MONO_INST_NEW to create phi node instructions to avoid asserts in the spill pass. Fixes #24006. 2014-10-23 14:47:19 -04:00
Zoltan Varga 2d3dd5a40a [runtime] Fix a regression introduced by 8d9f05ea9a. Only do the check for overlapping fields when the size of the type is known. 2014-10-23 14:04:32 -04:00
Zoltan Varga 87f4b14752 [jit] Print out methods which failed to JIT when using --regression. 2014-10-23 13:56:38 -04:00
Ludovic Henry 916abe5f57 [bcl] Restore ThreadPool number of threads configuration after each test 2014-10-23 11:00:47 -04:00
Zoltan Varga 8d9f05ea9a [runtime] Add checks for overlapping reference and non-reference fields when using explicit layout. Fixes #23954. 2014-10-22 18:20:41 -04:00
Zoltan Varga de8ca8fdf6 Merge pull request #1358 from madewokherd/win32build
Fix win32 build.
2014-10-22 17:47:48 -04:00
Zoltan Varga 6ec1ebf990 [llvm] Rewrite the way direct calls are made between llvm methods. Previously all calls were made to plt entries and the plt entry symbols were aliased to point to the corresponding method if the method was directly callable using the .set assembler directive. This doesn't seem to work with newer LLVM/CLANG versions, so do this completely on the LLVM side using Value::replaceAllUsesWith (). Fixes #23976. 2014-10-22 17:14:00 -04:00
Ludovic Henry a142d922aa [threadpool] Fix deadlock/starvation of the thread pool
The issue was with the new heuristic of the thread pool which would not create new threads, leading to deadlock between dependent tasks.
The fix is to check if every worker threads are sleeping, waiting or joining, and if that's the case, then we create a new thread because we might be in the case where the tasks being currently run depends on one still being enqueued in the cq or one of the wsq.

The following tests would previously fail :

1) MonoTests.System.Threading.Tasks.TaskTests.DoubleWaitTest :   #1
  Expected: True
  But was:  False

at MonoTests.System.Threading.Tasks.TaskTests.<DoubleWaitTest>m__27 () [0x00077] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:800
at MonoTests.System.Threading.Tasks.ParallelTestHelper.Repeat (System.Action action, Int32 numRun) [0x00007] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/ParallelTestHelper.cs:48
at MonoTests.System.Threading.Tasks.TaskTests.DoubleWaitTest () [0x00000] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:790
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230

2) MonoTests.System.Threading.Tasks.TaskTests.HideSchedulerTest :   #1
  Expected: True
  But was:  False

at MonoTests.System.Threading.Tasks.TaskTests.HideSchedulerTest () [0x0003d] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:1914
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230

3) MonoTests.System.Threading.Tasks.TaskTests.WaitAll_TimeoutWithExceptionsAfter :   #1
  Expected: True
  But was:  False

at MonoTests.System.Threading.Tasks.TaskTests.WaitAll_TimeoutWithExceptionsAfter () [0x00070] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:317
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230

4) MonoTests.System.Threading.Tasks.TaskTests.WaitAll_TimeoutWithExceptionsBefore :   #1
  Expected: True
  But was:  False

at MonoTests.System.Threading.Tasks.TaskTests.WaitAll_TimeoutWithExceptionsBefore () [0x00070] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:341
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230

5) MonoTests.System.Threading.Tasks.TaskTests.WaitAnyTest :   #3
  Expected: not -1
  But was:  -1

at MonoTests.System.Threading.Tasks.TaskTests.<WaitAnyTest>m__0 () [0x00026] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:142
at MonoTests.System.Threading.Tasks.ParallelTestHelper.Repeat (System.Action action, Int32 numRun) [0x00007] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/ParallelTestHelper.cs:48
at MonoTests.System.Threading.Tasks.ParallelTestHelper.Repeat (System.Action action) [0x00000] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/ParallelTestHelper.cs:42
at MonoTests.System.Threading.Tasks.TaskTests.WaitAnyTest () [0x00000] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:128
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230

6) MonoTests.System.Threading.Tasks.TaskTests.WaitChildTestCase :   #0b
  Expected: True
  But was:  False

at MonoTests.System.Threading.Tasks.TaskTests.<WaitChildTestCase>m__25 () [0x0006d] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:705
at MonoTests.System.Threading.Tasks.ParallelTestHelper.Repeat (System.Action action, Int32 numRun) [0x00007] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/ParallelTestHelper.cs:48
at MonoTests.System.Threading.Tasks.TaskTests.WaitChildTestCase () [0x00000] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:684
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230

7) MonoTests.System.Threading.Tasks.TaskTests.WaitingForChildrenToComplete :   #3
  Expected: True
  But was:  False

at MonoTests.System.Threading.Tasks.TaskTests.WaitingForChildrenToComplete () [0x00048] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:734
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /Users/ludovic/Xamarin/mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230
2014-10-22 17:09:11 -04:00
Vincent Povirk 21656fd89f Fix win32 build.
This commit licensed as MIT/X11.
2014-10-22 15:19:39 -05:00
Zoltan Varga bb86670c28 [bcl] Fix races in task tests. 2014-10-22 14:22:17 -04:00
Dan Parnham 87e7f1c2d7 Included /dev/ttyACM in the search for serial port devices, since CDC ACM is a standard
protocol for emulating serial ports over USB.
2014-10-22 16:21:20 +01:00
Ludovic Henry e15463e38a [sgen] Add GC max collection time counter 2014-10-21 15:28:59 -07:00
Ludovic Henry c4f72def57 [sgen] Add memory governor allocated size counter 2014-10-21 15:28:59 -07:00
Ludovic Henry 2a14bc4dad [sgen] Fix assertion error on 32bits 2014-10-21 10:03:31 -04:00
Jo Shields 63eb94b524 Merge pull request #1356 from martinjt/ReadEntityV2
Removed erroneously added property to HttpRequestBase in pull #1353
2014-10-21 14:17:36 +01:00
Zoltan Varga 066bdb9c24 [jit] Add some micro-optimizations to speed up the AOT compiler. 2014-10-20 22:51:49 -04:00
Zoltan Varga a26b297e11 Fix a warning. 2014-10-20 20:49:01 -04:00
Ludovic Henry 18cd82b380 [sgen] Adjust internal allocator block size to slot size.
The internal allocator used size segregated blocks which were always
16k large.  Since we have quite a few different size classes this led
to a lot of allocation even for very small programs.

We now use block sizes that are determined by the slot size and are as
small as possible.  They're power-of-two multiples of the page size,
so we end up with blocks of 4k, 8k and 16k.
2014-10-20 16:24:06 -07:00
Ludovic Henry 1daac38948 [sgen] Add assertion on power of 2 for internal allocator section size 2014-10-20 16:24:05 -07:00
Ludovic Henry 4619f9f070 [sgen] Add internal allocator default sizes usage statistic 2014-10-20 16:24:05 -07:00
Ludovic Henry d3788f892f [sgen] Utility function to compute number of unfaulted pages. 2014-10-20 16:24:05 -07:00
Ludovic Henry 26364535a0 [sgen] Cleanup some allocation code 2014-10-20 16:24:05 -07:00
Zoltan Varga 639413ef89 Fix the build after the signals changes. 2014-10-20 19:19:27 -04:00
Zoltan Varga 6716d439e9 [jit] Remove some unused definitions. 2014-10-20 18:22:40 -04:00
Zoltan Varga c3bd8334a3 Fix a typo. 2014-10-20 18:08:19 -04:00
Zoltan Varga 8410c9bb00 [runtime] Clean up the signal handling code by moving the signal handler signature definitions to mono-signal-handler.h and using them everywhere. 2014-10-20 18:07:24 -04:00
Ryan Melena 950d9c8a56 Additional JWT Security Token Support
Fix line endings.  Add test for JavaScriptSerializer.Deserialize(string input, Type targetType).
2014-10-20 16:00:16 -05:00
Mark Probst 5ae9f7d93f [sgen] Fix allowance calculation.
The formula for calculating allowance was not only overly complicated
but completely broken, which resulted in the allowance always being the
minimum (4 times the nursery size).  That resulted in too frequent garbage
collections when the heap grew larger.

Now we do something very similar to what Boehm does: Allow the heap
to grow by a third before the next major collection happens.
2014-10-20 13:40:50 -07:00
Martin Thwaites ce348f12da Removed erroneously added property to HttpRequestBase in pull #1353 2014-10-20 21:34:27 +01:00
Miguel de Icaza 643ad918e0 Merge pull request #1354 from martinjt/RequestAbort
Implement Request.Abort()
2014-10-20 10:04:35 -04:00
Miguel de Icaza e9ef2be437 Merge pull request #1353 from martinjt/ReadEntityBodyMode
Implement the ReadEntityBodyMode properties
2014-10-20 10:04:00 -04:00
Martin Thwaites 7eeb7f14f3 Implement Request.Abort() 2014-10-18 22:31:14 +01:00
Martin Thwaites 0db6c1418f Implement the ReadEntityBodyMode properties 2014-10-18 21:55:47 +01:00
Rodrigo Kumpera 6edd8bf89e [runtime] Don't define ucontext_t for android if PLATFORM is not android. 2014-10-17 15:37:14 -04:00
Zoltan Varga b67c4fe1c5 Fix a warning. 2014-10-17 12:14:26 -04:00
Zoltan Varga 36bfeec103 Fix a warning. 2014-10-16 18:35:55 -04:00
Zoltan Varga 77f9b3dc10 Fix a warning. 2014-10-16 17:11:19 -04:00
Zoltan Varga ddb83ce172 [bcl] Add an AppDomain.DoUnhandledException () internal method which can be used to invoke the UnhandledException event handlers. 2014-10-16 16:03:49 -04:00
Zoltan Varga 6f53824f35 [io-layer] Make _wapi_shm_enabled () inline so more code can be optimized away if shared handles are disabled. 2014-10-16 13:53:56 -04:00
Zoltan Varga 97866fc145 [io-layer] Remove more dead process code, add comments. 2014-10-16 12:59:11 -04:00
Paolo Molaro c5d4e39545 [jit] Fix -O=precomp option to skip generic methods and not crash. 2014-10-16 10:40:45 -04:00
Eberhard Beilharz 1189d3706a [MWF] Use full available height for text
This is especially relevant if we have to shrink the width because of
padding. In this case it is possible that MeasureString calculated that
the string would fit in one line, but because of padding we reduce the
width. If the button is large enough we want to display additional lines
even if MeasureString told us we only need one line.
2014-10-16 14:09:24 +02:00
Eberhard Beilharz 885b065e06 [MWF] Use full width for measuring text
Previously we applied the padding twice.
2014-10-16 14:08:53 +02:00
Zoltan Varga 45deb48384 [io-layer] Allocate the process name dynamically to make WapiHandle_process smaller. 2014-10-15 18:56:01 -04:00
Zoltan Varga b0077e8c2a [io-layer] Remove WapiHandle_process.self field, its no longer needed. 2014-10-15 18:50:09 -04:00
Zoltan Varga 1784575ef2 Include ucontext.h on android if it exists. 2014-10-15 17:22:08 -04:00
Zoltan Varga 5a4cd56c04 [runtime] Add a 'shared_handles' --enable-minimal option, same as --disable-shared-handles. 2014-10-15 17:18:21 -04:00
Zoltan Varga 04967b8dba Fix a warning. 2014-10-15 17:17:41 -04:00
Zoltan Varga ba6a479e5d [io-layer] Remove another usage of getdtablesize (). 2014-10-15 16:52:56 -04:00
Zoltan Varga 179fbf4b23 [runtime] Use getrlimit () to obtain the size of the fd table instead of getdtablesize () which is getting deprecated in Android. 2014-10-15 16:45:19 -04:00
Zoltan Varga 8e6ae13499 [io-layer] More coding convention/formatting fixes. 2014-10-15 16:28:47 -04:00
Zoltan Varga b58da19a66 [corlib] Implement MonoGenericClass:GetCustomAttributes () for created types. Fixes #23769. 2014-10-15 15:21:53 -04:00
Zoltan Varga 2ec479b762 [io-layer] Fix the linux build. 2014-10-15 15:08:54 -04:00
Zoltan Varga bf87077ac9 [io-layer] Make process handles non-shared. Fixes #23423. 2014-10-15 15:01:31 -04:00
João Matos e78e74cc1c Fixed linking on MinGW. 2014-10-15 14:37:25 -04:00
Zoltan Varga 727f8fe28d [jit] Fix the return of vtypes containing a single fp member from pinvoke methods on osx/x86. Fixes #23813. 2014-10-15 12:54:16 -04:00
Rodrigo Kumpera a9f31e63db [build] Rework the buildver dep check. 2014-10-14 18:12:08 -04:00
Zoltan Varga 30ed59ce3e Revert "Fixed buildver generated headers automake dependency tracking."
This reverts commit 8f41328a78.

Revert this for now as it breaks the parallel build.
2014-10-14 15:59:24 -04:00
Zoltan Varga 60d10d5464 Merge pull request #1341 from smortex/patch-2
Fix build on FreeBSD
2014-10-14 14:12:19 -04:00
Romain Tartière 54f5b48d44 Protect #include <unistd.h>
Protect inclusion as reported by @vargaz
2014-10-14 20:03:29 +02:00
Zoltan Varga 88ed113252 Merge pull request #1340 from smortex/patch-1
Add missing header
2014-10-14 13:49:53 -04:00
Romain Tartière 855bb5648b Fix build on FreeBSD
pid_t (used at line 216) is available on Linux in `unistd.h` and so on on FreeBSD (`sys/types.h` to be precise, included in `unistd.h`), yet on FreeBSD this header is not automatically included.
2014-10-14 19:48:31 +02:00
Romain Tartière 55fc7c277f Add missing header 2014-10-14 19:42:44 +02:00
Zoltan Varga 123d9a05db Merge pull request #1339 from tritao/master
Fixed buildver generated headers automake dependency tracking.
2014-10-14 12:54:48 -04:00
João Matos 8f41328a78 Fixed buildver generated headers automake dependency tracking.
We now include buildver-sgen/boehm.h in BUILT_SOURCES to have proper dependency tracking for these generated files.

Fixes the MinGW OSX cross build.
2014-10-14 11:46:36 -04:00
Zoltan Varga 4cba98f8c0 [runtime] Fix an SRE assert. Fixes #19039. 2014-10-13 18:39:56 -04:00
Marcos Henrich 48d05afa0e DataTabe.ReadXmlSchema now handles non Schema base element. Fixes #22501. 2014-10-13 16:15:23 -04:00
Marcos Henrich 9e5d94e72b Test DataTable.ReadXmlSchema with non Schema base element. Covers #22501. 2014-10-13 16:15:03 -04:00
Zoltan Varga 3b484c1fcb Merge pull request #1335 from nlhepler/master
Fix relocatable mono
2014-10-13 13:56:29 -04:00
Lance Hepler e3abaa85d8 Fix relocatable mono 2014-10-13 09:32:30 -07:00
Marek Safar 10b5567b3d [mcs] A pointer-type may be used as the type of a volatile field. Fixes #23770 2014-10-13 12:28:08 +02:00
Jo Shields f600c130ef Add a third AOT location, alongside ~/.mono/aot-cache and the assembly dir
Unless running in on-demand AOT mode, the AOT runtime will look for an AOT cache alongside the assembly (e.g. /usr/lib/mono/4.5/mscorlib.dll.so).

This patch adds a second search path to the non-on-demand AOT loader, /usr/lib/mono/aot-cache/ARCHITECTURE/path/to/assembly.dll.so

This new structure makes it possible to have more than one Mono architecture on a system, sharing assemblies but not sharing AOT caches (for example, i386 and amd64 Mono on the same system, for different needs)
2014-10-13 09:24:07 +01:00
Zoltan Varga 6e4ab1d3eb [runtime] Remove some dead code from the io-layer process code, avoid mixing ifdefs with control flow. 2014-10-12 18:03:02 -04:00
Marek Habersack abb760f376 Merge pull request #1333 from joero74/ignore-missing-host
Prevent NullReferenceException in case of missing Host
2014-10-10 18:36:50 +02:00
Joerg Rosenkranz f927c83afe Prevent NullReferenceException in case of missing Host
Do not throw a NullReferenceException when Host variable is not set.
Ignore the calls to RegisterObject and UnregisterObject instead.
2014-10-10 16:23:22 +02:00
Zoltan Varga 5f2f74f5de [runtime] Rewrite io-layer process code to reduce duplication and make it conform to the mono coding conventions. 2014-10-09 21:46:01 -04:00
Zoltan Varga 02be6a4f28 [runtime] Use explicit initialization in the io-layer process code instead of pthread_once (). Get rid of the WAPI_PROCESS_HANDLE_OFFSET code which was only used in shared mode. 2014-10-09 16:49:13 -04:00
Zoltan Varga e1af46ef45 [runtime] More win32 build fixes. 2014-10-09 16:21:56 -04:00
Zoltan Varga a487812e61 runtime] Really use WinXP SP2 as the minimum version on the msvc builds too. Update project files with newly
added/removed sources.
2014-10-09 15:51:49 -04:00
Zoltan Varga eea8080dad [runtime] Use WinXP SP2 as the minimum version on the msvc builds too. 2014-10-09 15:20:06 -04:00
Mark Probst a68a793383 Merge pull request #1326 from BrzVlad/master
[sgen] Fix pointer access.
2014-10-09 11:43:03 -07:00
Zoltan Varga 92d86659ca [runtime] Remove pre WinXP SP2 windows support code. 2014-10-09 14:04:31 -04:00
Zoltan Varga 4109ab0ee4 [runtime] Use the functionality in mono-proclib.c to get the current pid, remove duplicate code from the io-layer. 2014-10-09 14:04:31 -04:00
Zoltan Varga 43fd14b9d8 [runtime] Use the functionality in mono-proclib.c to enumerate processes, remove duplicate code from the io-layer. 2014-10-09 14:04:31 -04:00
Alexis Christoforides e92af12248 Fix oops in DataContractJsonSerializer fix 2014-10-08 22:04:34 -07:00
Zoltan Varga 17edd267ab [bcl] Use List instead of ArrayList () in a few places. 2014-10-08 16:12:01 -04:00
Zoltan Varga c33600f57d [bcl] Free strings allocated using Marshal.SecureStringToBSTR () using Marshal.ZeroFreeBSTR (). 2014-10-08 15:12:35 -04:00
Marek Safar 114a27e57c Merge pull request #1330 from esdrubal/blockingcollection
Improved BlockingCollection.AddAny.
2014-10-08 15:02:54 -04:00
Ludovic Henry 98ce3f76b2 [threaddpool] Fix deadlock in thread pool with monitor thread (2nd attempt)
Because the monitor thread was not marked as background thread, remove_and_abort_threads (threads.c:2807) would mark it as needed to be waited to shutdown the runtime, and wait_for_tids (threads.c:2652) would then wait indefinitely for it to finish. The issue was that the monitor was waiting on the semaphore monitor_sem, and thus would never exit.

Thread 7 (Thread 0x1c13 of process 99776):
#0  0x00007fff86590a56 in ?? () from /usr/lib/system/libsystem_kernel.dylib
#1  0x00000001003cc03a in mono_sem_wait (sem=0x1004f7f50, alertable=0) at mono-semaphore.c:103
#2  0x00000001002cef41 in monitor_thread (unused=0x0) at threadpool.c:898
#3  0x00000001002cb78f in start_wrapper_internal (data=0x10500abf0) at threads.c:657
#4  0x00000001002cb4a1 in start_wrapper (data=0x10500abf0) at threads.c:704
#5  0x00000001003d61d4 in inner_start_thread (arg=0x7fff5fbfe500) at mono-threads-posix.c:84
#6  0x00007fff8e7c9899 in _pthread_body () from /usr/lib/system/libsystem_pthread.dylib
#7  0x00007fff8e7c972a in _pthread_start () from /usr/lib/system/libsystem_pthread.dylib
#8  0x00007fff8e7cdfc9 in thread_start () from /usr/lib/system/libsystem_pthread.dylib
#9  0x0000000000000000 in ?? ()

Thread 1 (Thread 0x1503 of process 99776):
#0  0x00007fff86594716 in ?? () from /usr/lib/system/libsystem_kernel.dylib
#1  0x00007fff8e7cbc3b in _pthread_cond_wait () from /usr/lib/system/libsystem_pthread.dylib
#2  0x000000010039cfaa in _wapi_handle_timedwait_signal_handle (handle=0xa55, timeout=0x0, alertable=1, poll=0) at handles.c:1595
#3  0x000000010039d03d in _wapi_handle_wait_signal_handle (handle=0xa55, alertable=1) at handles.c:1540
#4  0x00000001003b7ba3 in WaitForSingleObjectEx (handle=0xa55, timeout=4294967295, alertable=1) at wait.c:194
#5  0x00000001003b865d in WaitForMultipleObjectsEx (numobjects=1, handles=0x7fff5fbff1f8, waitall=1, timeout=4294967295, alertable=1) at wait.c:516
#6  0x00000001002c75df in wait_for_tids (wait=0x7fff5fbff1f8, timeout=4294967295) at threads.c:2658
#7  0x00000001002c70e5 in mono_thread_manage () at threads.c:2951
#8  0x00000001000d551b in mono_main (argc=6, argv=0x7fff5fbff9e8) at driver.c:2021
#9  0x0000000100001bd1 in mono_main_with_options (argc=6, argv=0x7fff5fbff9e8) at ./main.c:91
#10 0x00000001000017d3 in main (argc=6, argv=0x7fff5fbff9e8) at ./main.c:122

Thanks @akoeplinger for the help debugging
2014-10-08 14:39:18 -04:00
Marcos Henrich 54844b08ef Refactored AddToAny and TakeFromAny to reuse code. 2014-10-08 12:59:42 +01:00
Marcos Henrich 7724a608a5 Improved BlockingCollection.AddAny. Fixes #22775.
AddAny no longer consumes OperationCanceledException.
AddAny no longer blocks while adding an item to the first collection when its full.
2014-10-08 12:16:36 +01:00
Marcos Henrich 0e13745ec2 Test BlockCollection.AddAny. Covers #22775. 2014-10-08 11:58:26 +01:00
Marcos Henrich 00c918e0a9 BlockingCollection.Add was adding one more item than it should. 2014-10-08 11:51:59 +01:00
Marcos Henrich 7e034defbc Test that BlockingCollection.Add blocks when there is no more space. 2014-10-08 10:41:14 +01:00
Zoltan Varga f51b9a4bb2 [jit] Extract the ctor calling code from the NEWOBJ implementation into a separate function. 2014-10-07 20:44:28 -04:00
Zoltan Varga c01afa20e8 [jit] Clean up the jit failure handling code a bit, move the the bulk of the eror handling macros into functions, unify the cleanup code at the end of mono_method_to_ir (). 2014-10-07 20:21:09 -04:00
Alexis Christoforides 71e152accc [bcl] Implement KnownTypes for DataContractJsonSerializer. Fixes #23058 and polymorphism support.
Also discarded old __type hint behavior in JsonSerializationReader that potentially allowed any loaded type to be instantiated.
2014-10-07 16:24:41 -07:00
Alexis Christoforides fbea921536 [tests] Add tests for Bug #23058 and polymorphism/known types in DataContractJsonSerializer. 2014-10-07 16:24:41 -07:00
Ludovic Henry 478f99f398 [threaddpool] Fix deadlock in thread pool with monitor thread
Because the monitor thread was not marked as background thread, remove_and_abort_threads (threads.c:2807) would mark it as needed to be waited to shutdown the runtime, and wait_for_tids (threads.c:2652) would then wait indefinitely for it to finish. The issue was that the monitor was waiting on the semaphore monitor_sem, and thus would never exit.

Thread 7 (Thread 0x1c13 of process 99776):
#0  0x00007fff86590a56 in ?? () from /usr/lib/system/libsystem_kernel.dylib
#1  0x00000001003cc03a in mono_sem_wait (sem=0x1004f7f50, alertable=0) at mono-semaphore.c:103
#2  0x00000001002cef41 in monitor_thread (unused=0x0) at threadpool.c:898
#3  0x00000001002cb78f in start_wrapper_internal (data=0x10500abf0) at threads.c:657
#4  0x00000001002cb4a1 in start_wrapper (data=0x10500abf0) at threads.c:704
#5  0x00000001003d61d4 in inner_start_thread (arg=0x7fff5fbfe500) at mono-threads-posix.c:84
#6  0x00007fff8e7c9899 in _pthread_body () from /usr/lib/system/libsystem_pthread.dylib
#7  0x00007fff8e7c972a in _pthread_start () from /usr/lib/system/libsystem_pthread.dylib
#8  0x00007fff8e7cdfc9 in thread_start () from /usr/lib/system/libsystem_pthread.dylib
#9  0x0000000000000000 in ?? ()

Thread 1 (Thread 0x1503 of process 99776):
#0  0x00007fff86594716 in ?? () from /usr/lib/system/libsystem_kernel.dylib
#1  0x00007fff8e7cbc3b in _pthread_cond_wait () from /usr/lib/system/libsystem_pthread.dylib
#2  0x000000010039cfaa in _wapi_handle_timedwait_signal_handle (handle=0xa55, timeout=0x0, alertable=1, poll=0) at handles.c:1595
#3  0x000000010039d03d in _wapi_handle_wait_signal_handle (handle=0xa55, alertable=1) at handles.c:1540
#4  0x00000001003b7ba3 in WaitForSingleObjectEx (handle=0xa55, timeout=4294967295, alertable=1) at wait.c:194
#5  0x00000001003b865d in WaitForMultipleObjectsEx (numobjects=1, handles=0x7fff5fbff1f8, waitall=1, timeout=4294967295, alertable=1) at wait.c:516
#6  0x00000001002c75df in wait_for_tids (wait=0x7fff5fbff1f8, timeout=4294967295) at threads.c:2658
#7  0x00000001002c70e5 in mono_thread_manage () at threads.c:2951
#8  0x00000001000d551b in mono_main (argc=6, argv=0x7fff5fbff9e8) at driver.c:2021
#9  0x0000000100001bd1 in mono_main_with_options (argc=6, argv=0x7fff5fbff9e8) at ./main.c:91
#10 0x00000001000017d3 in main (argc=6, argv=0x7fff5fbff9e8) at ./main.c:122
2014-10-07 18:15:04 -04:00
Zoltan Varga ac2d851398 [jit] Reduce code duplication in the inlining code. 2014-10-07 15:43:17 -04:00
Marek Safar c74ca49869 Merge pull request #1329 from esdrubal/httputility
HttpQSCollection.ToString now url encodes values.
2014-10-07 14:31:50 -04:00
Alexis Christoforides c677be429f Merge pull request #1327 from ermshiperete/Xamarin-23168
[MWF] Pass graphics when calculating button text and image
2014-10-07 11:30:52 -07:00
Jonathan Pryor 8b90653ff3 [System.Core/Android] Fix standalone unit tests.
Commit 5564dad1 broke the self-test (for testing on the developer
machine, not an Android target). Fixup the comment so that appropriate
data is grabbed and used for testing, and improve
AndroidTimeZones.GetDefaultTimeZoneName() so that the default timezone
ID can be specified via the __XA_OVERRIDE_TIMEZONE_ID__ environment
variable for testing.

Finally, demonstrate TimeZoneInfo.GetUtcOffset(DateTime) use so that I
can get better insight into the timezone data stored within the
database:

	$ __XA_OVERRIDE_TIMEZONE_ID__=America/New_York ANDROID_ROOT=`pwd` ANDROID_DATA=`pwd` mono --debug tzi.exe --offset=1969-01-01
	Using DateTime Offset: 1/1/1969 12:00:00 AM
	DB type: System.AndroidTzData
	name=Africa/Abidjan                           Africa/Abidjan                          From Offset: 00:00:00
	name=Africa/Accra                             Africa/Accra                            From Offset: 00:00:00
	name=Africa/Addis_Ababa                       Africa/Addis_Ababa                      From Offset: 03:00:00
	...
2014-10-07 13:59:49 -04:00
Marcos Henrich 843fe0b3c6 HttpQSCollection.ToString now url encodes values. Fixes 22557. 2014-10-07 18:50:45 +01:00
Marcos Henrich 6abce1e8d8 Test HttpQSCollection.ToString url encoding. Covers #22557. 2014-10-07 18:45:50 +01:00
Zoltan Varga 10c2cc4d3f [runtime] Move the MonoJit/MonoJitInfoTable code to a separate file from domain.c. 2014-10-07 13:26:12 -04:00
Zoltan Varga 7cfd463841 [runtime] Factor out some duplicate code from the MonoJitInfo creation code. 2014-10-07 13:03:41 -04:00
Zoltan Varga 04f89bb6fe Merge pull request #1328 from vkargov/master
[runtime] Take correct domain information from StackFrameInfo for each stack frame.
2014-10-07 12:45:52 -04:00
Eberhard Beilharz aab88e769c [MWF] Pass graphics when calculating button text and image
This fixes a problem with calculating the text width of a button
which caused the text to get truncated under certain circumstances
instead of being wrapped. This fixes Xamarin-23168.

Change-Id: Iac0d8a2720a99cf5433e05d5123a04c4b019e493
2014-10-07 17:34:44 +02:00
Vladimir Kargov 4cda578c6a [runtime] Take correct domain information from StackFrameInfo for each stack frame. 2014-10-07 19:30:31 +04:00
Rodrigo Kumpera bd002446fc Merge pull request #1179 from ludovic-henry/pr25-threadpool
[threadpool] Improve heuristic to approach optimal number of threads based on workload
2014-10-07 10:34:43 -04:00
Marcos Henrich fa2c2870e5 Added missing files to projects csproj files. 2014-10-07 14:03:29 +01:00
Marcos Henrich a1e558f6c6 Reset stream position before doing CopyToAsync.
CopyToAsync begins copying at the current position.
2014-10-07 09:53:01 +01:00
Marcos Henrich aea4abc755 Call SetupRequestAsync only after ContentType changes. Fixes 19529. 2014-10-07 09:52:54 +01:00
Alexis Christoforides 14d49cce10 [runtime] Fix another lost canary change 2014-10-06 17:02:23 -07:00
Zoltan Varga f533903590 Kill timed-out tests when using the managed test runner. 2014-10-06 16:13:54 -04:00
Vlad Brezae 7ecf25c7a1 [sgen] Fix pointer access.
Thanks to @martinpotter for finding the bug.
2014-10-06 12:19:52 -07:00
Zoltan Varga 5a22dacd4e [bcl] Remove some verbose test output. 2014-10-06 14:56:32 -04:00
Marcos Henrich 457c87c69f TimeZoneInfo.CreateLocal now handles environment variable TZ. 2014-10-06 15:57:13 +01:00
Rodrigo Kumpera b97e3209b3 [runtime] Silence a warning that has not helped us fix anything. 2014-10-06 10:54:16 -04:00
Marcos Henrich 27d26c36cc Added bash script to test DateTime.Now.
The test changes TZ environment variable and compares DateTime.Now with system date.
The test checks all the timezones installed in /usr/share/zoneinfo/.
2014-10-06 15:32:45 +01:00
Alexis Christoforides d29a341e73 [runtime] Fix canary oops 2014-10-05 23:08:48 -07:00
Alexis Christoforides ee90d5ff1d [runtime] Implement 'nursery-canaries' option for SGen. 2014-10-05 22:32:53 -07:00
Alexis Christoforides 84110040aa [runtime] Convert String.InternalSetLength to an icall. Needed for canary support.
The change does not have a negative impact on StringBuilder performance; under variable-string-length microbenchmarks it seems to perform ~15-20% faster than the managed implementation.
2014-10-05 22:21:15 -07:00
Alexis Christoforides d8ae2993ef [runtime] Implement nursery canaries.
Use the new MONO_GC_DEBUG option "nursery-canaries"  to suffix each nursery object with a canary (guard) word, which is checked on each minor collection. Can be used to detect/debug
heap corruption issues.

Adding canaries to LOS is also easy if wanted - not sure about major heap.
2014-10-05 22:16:27 -07:00
Marek Safar 153d104c07 [system.xml] Make XmlSerializer work even when XmlTextReader has explicitly set its resolver 2014-10-05 17:58:02 -04:00
Marek Safar 58105a4dc6 [system.xml] Add missing 4.0 property 2014-10-05 15:44:55 -04:00
Marek Safar f39cc88e58 [corlib] Notify parent task when child task uses NotOnFaulted. Fixes #23594 2014-10-05 14:36:05 -04:00
Zoltan Varga 9e573872f0 [arm] Increase size of tls_get opcode to 24. 2014-10-05 00:04:58 -04:00
Marcos Henrich 2a73a83d89 Use TZ transitions when AdjustementRules are ignored. Fixes 23170.
In some cases the timezone transitions provided by iOS are not convertible to AdjustmentRules because of changes on the base offset.
Now we store the transitions so they can be used instead of an incomplete list of AdjustmentRules.
2014-10-04 17:32:03 +01:00
Marcos Henrich 97c6bc06ea Refactored TimeZoneInfo.GetUtcOffset.
Added GetUtcOffset auxiliar methods with bool out parameter that is true when the given DateTime is a DST.
2014-10-04 16:46:47 +01:00
Marc-Andre Ferland 79f621ee7d Added null check in constructor.
Avoid throwing NRE later while using the class.
2014-10-04 06:42:31 -04:00
Stephen McConnel 82093256f4 Fix potential crash in ListView.ItemControl.ItemsMouseDown
This fixes Xamarin bug 23591.  Side-effects of internal processing of
ItemsMouseDown can cause ItemsMouseUp before ItemsMouseUp has finished.
2014-10-03 13:09:10 -05:00
Marcos Henrich 1a92f4e90b TimeZoneInfo.IsDaylightSavingTime now uses GetUtcOffset. 2014-10-03 17:43:47 +01:00
Marcos Henrich 374e1b13e0 TimeZoneInfo.GetUtcOffset now handles all DateTimeKinds.
Removed GetUtcOffset cohesion with TimeZoneInfo.IsDaylightSavingTime.
2014-10-03 17:43:32 +01:00
Marcos Henrich 09fc592499 Created helper method TimeZoneInfo.IsInDST. 2014-10-03 10:38:13 +02:00
Marcos Henrich 306ac05ea1 Removed repeated logic from TimeZoneInfo.ConvertTimeToUtc. 2014-10-03 10:38:13 +02:00
Marcos Henrich d6848d1ef6 ConvertTimeToUtc no longer relies in DateTime.ToUniversalTime. 2014-10-03 10:38:12 +02:00
Marcos Henrich b863d3c58d Simplified TimeZone.ToLocalTime.
Old code was producing invalid DST dates.
2014-10-03 10:38:11 +02:00
Marcos Henrich 411d4aa0bb Test TimeZoneInfo.GetUtcOffset with multiple DST and DateTimeKind. 2014-10-03 10:38:11 +02:00
Marcos Henrich 8ab9a76c7e Updated TimeZoneInfoTest.DSTTransisions to correct .NET behavior. 2014-10-03 10:38:10 +02:00
Alexis Christoforides b0cff959e4 [runtime] Fix allocation size calculation for strings in 64-bit builds.
Depending on alignment and packing, part of the string might be inside the MonoString struct boundaries. This e.g. shows up on 64-bit builds of mono where we were allocating 4 extra bytes per string.
2014-10-02 21:04:39 -07:00
Zoltan Varga 6e27f984ab [bcl] Use random ports for the HttpListener tests. 2014-10-02 23:29:53 -04:00
Zoltan Varga af33ad4eaa [jit] Implement 5dbf97e660 for calls made from NEWOBJ too. Fixes #23557. 2014-10-02 21:29:51 -04:00
Zoltan Varga 7a430acd77 [jit] Get rid of unused MONO_ARCH_THIS_AS_FIRST_ARG define. 2014-10-02 20:40:38 -04:00
Zoltan Varga 9523b73148 [arm] Implement handler block guards. 2014-10-02 20:35:42 -04:00
Zoltan Varga f862057fb1 [amd64] Simplify mono_arch_install_handler_block_guard (). 2014-10-02 19:04:27 -04:00
Zoltan Varga c1fe551f9c [arm] Increase the length of the tls_get opcode. 2014-10-02 18:41:42 -04:00
Chris Hamons 4c6a463678 [mono-api-html] Add filter for new namespaces/types
- Reviewed by Sebastien
2014-10-02 15:35:21 -05:00
Zoltan Varga e7778f3fd5 Fix a warning. 2014-10-02 16:06:24 -04:00
Zoltan Varga 4437ecea91 Fix the arm build. 2014-10-02 16:06:01 -04:00
Zoltan Varga 1317d99cae [sgen] Reorganize sgen-archdep.h to remove unused defines. 2014-10-02 15:49:00 -04:00
Zoltan Varga 1e709688bb [jit] Remove unused defines. 2014-10-02 14:32:11 -04:00
Zoltan Varga da3b7dd271 [amd64] Define MONO_ARCH_NOMAP32BIT on all non-linux platforms instead of defining it once for each platform. 2014-10-02 14:23:15 -04:00
Sebastien Pouliot 3e3fe21e7f Revert "Finish test changes started in 7ece665d16714db0979bde5df254231c5be24f10"
This reverts commit d171cdf5e2.
2014-10-02 13:45:11 -04:00
Sebastien Pouliot d525ff73e1 Revert "Refresh HashAlgorithmTest to match changed NullStream behaviour in 8b9c60075f7b97fe88c3c588968977ff9bcf8c28"
This reverts commit 7ece665d16.
2014-10-02 13:44:58 -04:00
Sebastien Pouliot 16dbea555d Revert "Missing Args checks."
This reverts commit 8b9c60075f.
2014-10-02 13:44:35 -04:00
Marcos Henrich 709d2c58ad Removed unused CurrentSystemTimeZone fields and methods. 2014-10-02 09:31:06 +01:00
Marcos Henrich 9be262f8cc CurrentSystemTimeZone.GetUtcOffset now supports multiple DST periods.
DateTime.Now was returning wrong values when system TimeZone had more than one daylight saving time.
Fixes 22648.
2014-10-02 09:31:06 +01:00
Marcos Henrich 88297792e7 TimeZoneInfo is now always present in corlib.
Prior to net_4_0 TimeZoneInfo is a private class.
2014-10-02 09:31:06 +01:00
Zoltan Varga aa73f76a34 [jit] Define NOMAP32BIT on winx64. 2014-10-01 22:49:29 -04:00
Mark Probst b86bd886d6 [sgen] Fix concurrent mark with split nursery. 2014-10-01 14:52:07 -07:00
Zoltan Varga c856758e54 [jit] Remove the unused MONO_DISABLE_PENDING_EXCEPTIONS env var, the functionality it disable is not experimental anymore. 2014-10-01 16:42:47 -04:00
Zoltan Varga d659d7540d [x86] Remove the now unused push based parameter passing code. 2014-10-01 16:36:27 -04:00
Stephen McConnel b3214a4a42 Remove excessive shortcut key matching in ToolStrip
This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=23532.
2014-10-01 15:04:39 -05:00
Jonathan Pryor 87454f9f83 Merge pull request #1306 from joelmartinez/docs-privateinterface
mdoc no longer documents private interfaces
2014-10-01 15:23:08 -04:00
Rodrigo Kumpera 0ac61b03fc [corlib] Fix UnicodeEncoding GetMaxByteCount and GetMaxCharCount to return the same values as .net. 2014-10-01 15:11:20 -04:00
Zoltan Varga 52834175e1 [runtime] Add a missing call to mono_thread_notify_pending_exc_fn () to the thread abort code. 2014-10-01 15:02:25 -04:00
Zoltan Varga 9aaf79b055 Fix some warnings by not including utils/mono-threads.h into threads-types.h. 2014-10-01 14:27:18 -04:00
Zoltan Varga fc7c8e9765 [jit] Make each CASTCLASS_CACHE patch unique by generating a unique identifier from the method index and an per-method counter. Fixes #23478. 2014-09-30 22:12:53 -04:00
Jo Shields d171cdf5e2 Finish test changes started in 7ece665d16 2014-09-30 14:51:13 +01:00
Jo Shields a49bd2664f Add new cert-sync command to scripts/.gitignore 2014-09-30 13:22:00 +01:00
Jo Shields 7ece665d16 Refresh HashAlgorithmTest to match changed NullStream behaviour in 8b9c60075f 2014-09-30 13:22:00 +01:00
Marek Safar 497481742a [mcs] Undo bool loads normalization from byte arrays 2014-09-30 13:02:32 +02:00
Marek Safar 999e88dcd5 [mcs] Correctly identify constant switch section when value match is not section start. Fixes #23475 2014-09-30 11:12:24 +02:00
Marek Safar 01ffcd4145 [mcs] struct initializers are still experimental 2014-09-30 09:48:41 +02:00
Marek Safar 2476a1b728 Merge pull request #1318 from AlexanderBekrenev/baa-membershipuser
MembershipUser::UpdateUser method fix
2014-09-29 22:28:19 -09:00
Alexander Bekrenev c9044d71bb MembershipUser::UpdateUser method fix 2014-09-30 10:46:14 +04:00
Neale Ferguson dbd022aba4 Enable build on RHEL and CentOS 2014-09-29 17:34:38 -04:00
Mark Probst 4e3ca74fcb Fix build on pre-C99 compilers. 2014-09-29 13:52:00 -07:00
Ludovic Henry ada4b4b06f [sgen] Remove useless internal allocation 2014-09-29 16:16:31 -04:00
Zoltan Varga 1fbdf06d04 [runtime] Enable the new interrupt code on ios. 2014-09-29 14:30:19 -04:00
Mark Probst c70c3c429a [sgen] Don't use callback for pinning cemented objects. 2014-09-29 11:04:03 -07:00
Mark Probst a12c4b8099 [sgen] Tag block pointers with whether the blocks contain references. 2014-09-29 11:04:02 -07:00
Mark Probst e8efdfa360 [sgen] Macro abstractions for pointer tagging. 2014-09-29 11:04:02 -07:00
Mark Probst ac83118056 [sgen] Shift, don't divide, just to make sure. 2014-09-29 11:04:02 -07:00
Mark Probst 70980c0cde [sgen] Move SGen statistics out of gc-internal.h.
This introduced a dependency from sgen-conf.h to a lot of compilation units
in metadata, leading to long build times when experimenting with SGen.
2014-09-29 11:04:02 -07:00
Mark Probst 0cfc7008a0 [sgen] Don't unroll run-length scanning loop. 2014-09-29 11:04:01 -07:00
Mark Probst 8e714a70a1 [sgen] Keep allocated blocks in array instead of linked list.
We were spending a lot of time in major_iterate_live_block_ranges() on
the lcscbench benchmark, mainly from following the linked block list.
This change makes it much faster.
2014-09-29 11:04:01 -07:00
Mark Probst 18ee4f22a3 [sgen] Move GRAY_OBJECT_ENQUEUE/DEQUEUE to sgen-gray.h. 2014-09-29 11:04:01 -07:00
Mark Probst 62df12c0e4 [sgen] Move HEAVY_STAT macro to sgen-conf.h.
That's where we define HEAVY_STATISTICS, too.
2014-09-29 11:04:01 -07:00
Mark Probst aa82365b6b [sgen] Scoping fix in a macro. 2014-09-29 11:04:01 -07:00
Mark Probst 0f7be7ca38 [sgen] Heavy statistics counters for scanned object descriptors. 2014-09-29 11:04:00 -07:00
Mark Probst aa8cabc373 [sgen] do-while loop instead of 1-unrolled while loop in bitmap scan. 2014-09-29 11:04:00 -07:00
Mark Probst 53b798f915 [sgen] Added some comments. 2014-09-29 11:04:00 -07:00
Mark Probst 533b11a0f6 [sgen] Simplify sgen_drain_gray_stack().
This seems to have accumulated code duplication by accident.
2014-09-29 11:03:59 -07:00
Mark Probst 78408ae100 [sgen] Free gray queue sections after GC, not at start of next.
We trim the free list of the gray queue to a maximum number of
sections, but we did it at each collection start, so the extraneous
sections were kept around between collections.
2014-09-29 11:03:59 -07:00
Mark Probst 72c15bb6f2 [sgen] Enqueue objects with their descriptors.
At the point where we enqueue objects we have already fetched their
descriptors, and when we later scan them (after dequeuing) we need the
descriptor again, so we avoid cache misses by enqueuing them together.
2014-09-29 11:03:59 -07:00
Mark Probst 96e37d79b3 [sgen] Pass descriptor, not vtable, to OBJ_COMPLEX_ARR_FOREACH_PTR.
Later on, when we enqueue objects with their GC descriptors, we won't
load the vtable before scanning (because we'll already have the
descriptor), so the scanning macros shouldn't take them as arguments.
2014-09-29 11:03:59 -07:00
Mark Probst 003488cc2a [sgen] GrayQueueEntry struct instead of just char*.
This makes it easier to later enqueue the GC descriptor with the
object.
2014-09-29 11:03:58 -07:00
Mark Probst c2022b34b7 [sgen] Remove obsolete check in #ifdef.
That macro doesn't exist anymore.
2014-09-29 11:03:58 -07:00
Mark Probst d07b7650c7 [sgen] Abstract block info->block via macro.
If we want to experiment with putting the block info into the block this
makes it easy.
2014-09-29 11:03:58 -07:00
Mark Probst 050ee93a67 [sgen] Implement get_and_reset_num_major_objects_marked() for non-conc, too.
This is used for profiling and debugging.  There's no reason to only
have it for concurrent.
2014-09-29 11:03:58 -07:00
Mark Probst 8a005b8290 [sgen] Remove parallel collector.
This was almost completely untested and performance was
erratic.
2014-09-29 11:03:57 -07:00
Mark Probst 06ba93fd0e [sgen] Remove SGen fixed heap configuration.
It's not well-tested, not widely used, we can surpass its speed with
upcoming improvements and we won't put those into the fixed
configuration because it's too much of a diversion.
2014-09-29 11:03:57 -07:00
Marek Safar 2a4230fe3b [facades] Add ComInterfaceType type forwarder 2014-09-29 19:50:29 +02:00
Zoltan Varga 67297b2710 Fix a warning. 2014-09-29 13:37:03 -04:00
Zoltan Varga 7968a8df16 [x86] Reenable the no pushes code again. 2014-09-29 13:01:52 -04:00
Marek Safar f1ca57ebb3 [mcs] Don't consider loads from captured local cheap 2014-09-29 16:44:46 +02:00
Marek Safar 5d762ffe93 [mcs] null operator on unconstrained generic values 2014-09-29 16:44:46 +02:00
Alexander Köplinger 22a218578a Updated links in CONTRIBUTING.md 2014-09-29 14:11:06 +02:00
Marek Safar 84f9d58737 [mcs] Handle crash in binary operators when enum is used and nullable type is undefined 2014-09-29 11:41:35 +02:00
Marek Safar 1e5638b59c Merge pull request #1316 from Therzok/addSealed
Improvements in CorCompare
2014-09-28 21:27:08 -09:00
Zoltan Varga 75eb6a9caf Revert "[jit] Enable deadce on fp instructions on x86. Fixes #23392."
This reverts commit a32e2c7fe6.

Revert this as it breaks the build.
2014-09-29 01:06:50 -04:00
Zoltan Varga b533e2abac Fix a warning. 2014-09-28 19:57:52 -04:00
Zoltan Varga 9ac8be28af [bcl] Add AppDomain.FirstChangeException event, not implemented yet. 2014-09-28 19:56:53 -04:00
Zoltan Varga 5d3a42dc0f [runtime] Disallow generic classes with explicit layout. Fixes #23438. 2014-09-28 19:44:23 -04:00
Marius Ungureanu 63f50e9a1a [CorCompare] Add pointer as a class type. 2014-09-28 23:50:39 +03:00
Marius Ungureanu a5439f9646 [CorCompare] Add sealed methods parsing. 2014-09-28 23:48:58 +03:00
Marek Safar f289255ed5 Merge pull request #1315 from rjvdboon/BootstrapContext
Add System.IdentityModel.BootstrapContext to .Net 4.5 profile, fixes #22560
2014-09-27 20:59:02 -09:00
Zoltan Varga 657b6caad6 [runtime] Implement and enable the new interrupt code on amd64. 2014-09-28 01:50:51 -04:00
rjvdboon 2f9fb9e888 more coding style changes 2014-09-27 21:32:46 +02:00
rjvdboon d90ab2a697 Adhere to mono coding guidelines. 2014-09-27 21:27:44 +02:00
Marek Safar bb12899b3a [corlib] Timespan ticks formatting rewrite. Fixes #23376 2014-09-27 16:41:46 +02:00
Marek Safar bd3f6f5abc Merge pull request #1314 from alesliehughes/master
Add basic implement of ManagementObjectSearcher
2014-09-27 02:13:34 -09:00
Alistair Leslie-Hughes 13e0175fc8 Add basic implement of ManagementObjectSearcher
This change is released under the MIT license.
2014-09-27 20:16:32 +10:00
Zoltan Varga a32e2c7fe6 [jit] Enable deadce on fp instructions on x86. Fixes #23392. 2014-09-26 19:48:21 -04:00
Zoltan Varga cca43a2d34 [sdb] Add an option to make debugger invokes virtual. Part of the fix for #23385. 2014-09-26 18:16:17 -04:00
Sebastien Pouliot f234e421ae Merge pull request #1282 from madrang/MinorChangesOfPull1281
Add missing argument validations and set disposed flag to true once Dispose is called
2014-09-26 16:24:22 -04:00
Sebastien Pouliot c648f28f54 [corlib] Move iOS-specific code to a separate file for System.Environment 2014-09-26 15:40:34 -04:00
Ludovic Henry 62edb78cd6 [threadpool] Put the monitor thread to sleep if there has been no tasks for the past 5 seconds (NON_BUSY_INTERATION * SAMPLES_PERIOD)
This should improve a lot power consumption, because this avoir having a thread waking up every 500ms keeping the CPU awake.
2014-09-26 15:06:43 -04:00
Ludovic Henry 681a0061ad [threadpool] Remove process_idle_times so monitor_thread is the only function to change the number of threads 2014-09-26 15:06:42 -04:00
Ludovic Henry c93f120211 [threadpool] Add heuristic to approach the optimal number of threads 2014-09-26 15:06:42 -04:00
Ludovic Henry 1210628a04 [threadpool] Add suspend pushing to a WSQ 2014-09-26 15:06:42 -04:00
Sebastien Pouliot 1641a095bb [Mono.Security] Clear Certificates after Import or Remove [part of PR #1004]
PR: https://github.com/mono/mono/pull/1004

commit: https://github.com/rahvee/mono/commit/9fa2a1928a50114eb144202b939269f3f8d823f2

Modified to match Mono guidelines.
2014-09-26 14:35:20 -04:00
Marek Safar 0567e7763e [mcs] Check for true/false user operators on unwrapped nullable type. Fixes #23199 2014-09-26 20:34:01 +02:00
Rodrigo Kumpera aa11aa6184 Revert "[runtime] Implement lazy resolution of array interfaces."
This reverts commit 6ee08cf772.

This broke corlib compilation in a very weird way. Reverting it for now as I have no idea on why things break.
2014-09-26 14:12:32 -04:00
Rodrigo Kumpera 0e37ed19be Revert "[runtime] Remove a bit chunk of what's dead code now."
This reverts commit cab1c00168.
2014-09-26 14:12:22 -04:00
Marek Safar 96b46d1ad0 [mcs] Add check for parameterless user constructor used as default parameter value 2014-09-26 14:31:40 +02:00
Marek Safar a59c434f46 Merge pull request #1312 from esdrubal/xmltext
Property with attribute XmlTest is now set from ReadString only.
2014-09-26 02:47:15 -09:00
Marcos Henrich 916121f3d7 Property with attribute XmlTest is now set from ReadString only.
Before the change when the property default value was not null or empty the deserialized value would be the concatenation of the default value and the serialized value.
The correct behavior is to use the serialized value only.
Fixes 18908.
2014-09-26 10:35:57 +01:00
Marcos Henrich 007413298d Test Xml serialization of a property with attribute XmlText.
The tested property has a default value that is not null.
Covers 18908.
2014-09-26 10:31:51 +01:00
Marek Safar c5cf618a14 [mcs] Fix codegen for coalescing operator involving user operator conversion to result type 2014-09-26 09:27:49 +02:00
Zoltan Varga 6c4bc5f9d7 [aot] Pass additional arguments to llc on x86. 2014-09-25 17:12:17 -04:00
Robert J. van der Boon 11049f9dd7 Added serialization of SecurityToken with Handler 2014-09-26 05:39:48 +09:00
Rodrigo Kumpera cab1c00168 [runtime] Remove a bit chunk of what's dead code now. 2014-09-25 16:23:24 -04:00
Rodrigo Kumpera 6ee08cf772 [runtime] Implement lazy resolution of array interfaces.
To resolve casting we make all relevant interfaces to use the generic variance casting code.
This only affected ICollection`1 and IList`1, which are not terribly popular.

To fix dispatch we augment vtable resolution to treat those interfaces as variant and use
the already in place machinery.

Memory reduction numbers for the corlib test suite:

Initialized classes 8004 -> 7470 (7% reduction)
Corlib mempool size: 2719832 -> 2678872 (1.5% reduction)

Inflated classes 4500: 3.972 (12% reduction)
Inflated signatures size: 166128 -> 139812 (16% reduction)
Inflated methods size: 565152 -> 485664 (15$ reduction)
2014-09-25 16:23:23 -04:00
rjvdboon 4d7a441967 Update unit tests for binary serialization 2014-09-25 22:09:21 +02:00
rjvdboon 8d405e7aa1 Change unittest to not use the UserNameSecurityTokenHandler base class (as it does not-exist in mono) 2014-09-25 21:33:22 +02:00
Marek Safar 410af9c0cc Merge pull request #1309 from esdrubal/json
Improved Json deserialization of floating-point numbers.
2014-09-25 07:42:36 -09:00
Joel Martinez 8f2377e855 [mdoc] No longer documenting explicitly implemented private interface members.
https://bugzilla.xamarin.com/show_bug.cgi?id=18411

If a class explicitly implements an internal interface, those members will no
longer be documented, nor will the interface show up in the class' signature.
This allows for a library to hide internal implementation details that an end
user would not be able to take advantage of (ie. can't cast to internal
interface to call methods).

Includes test (check-monodocer-internal-interface)  added to makefile.
2014-09-25 10:41:42 -04:00
Marcos Henrich 92a4fd26ac Improved Json deserialization of floating-point numbers.
When DataContractJsonSerializer was created from type object, deserialization of floating.point numbers was not possible.
Fixes 21583.
2014-09-25 15:30:46 +01:00
Marcos Henrich ee71f0a1e6 Test Json deserialization of a floating-point number as object.
Covers 21583.
2014-09-25 15:15:38 +01:00
Miguel de Icaza 40ccf510c6 Merge pull request #1307 from esdrubal/servicemodelrss
Rss20ItemFormatter.ReadFrom now sets Id when guid is PermaLink.
2014-09-25 09:52:23 -04:00
Marcos Henrich d7c598b74c Rss20ItemFormatter.ReadFrom now sets Id when guid is PermaLink.
Fixes 23262.
2014-09-25 13:38:59 +01:00
Marcos Henrich 5ddcc07c67 Test Rss20ItemFormatter.ReadFrom Guid. Covers 23262. 2014-09-25 13:36:40 +01:00
Mark Probst 294e5214b2 [sgen] Don't get time twice at the same time. 2014-09-24 16:31:19 -07:00
Ludovic Henry 546831886e [sgen] Add concurrent collector counter for time spent during concurrent phase 2014-09-24 16:31:19 -07:00
Ludovic Henry 5d4b1f978b [sgen] Add major concurrent collector stw time to "Major GC time" counter 2014-09-24 16:31:18 -07:00
Miguel de Icaza 4320e844e9 Merge pull request #1304 from slluis/mac-proxy-autoconfig
[System.Net] Add support for .pac proxy config scripts on mac
2014-09-24 11:17:33 -04:00
Lluis Sanchez f5f69e540e [System.Net] Add support for .pac proxy config scripts on mac 2014-09-24 16:50:15 +02:00
Miguel de Icaza c6ab899595 [System] Fix most warnings on the System test suite 2014-09-24 10:43:46 -04:00
Marcos Henrich 67ea9985cb UriParserTest.GetComponents_Ftp2 now uses the variable 'ftp2'. 2014-09-24 12:22:30 +01:00
João Matos e150fde4e2 Fixed TLS detection to check for TARGET_MACH instead of __APPLE__.
In the case of cross-compiling to x86 Linux from OSX we'd hit compilation issues here.
2014-09-24 12:21:35 +01:00
João Matos de0543fbea Added support for cross-compiling to x86 Linux/Android. 2014-09-24 12:21:34 +01:00
Marek Safar 1d94d1770d [mcs] More tweaks to conditional tokenizer. Fixes #23319 2014-09-24 12:29:06 +02:00
Jo Shields ff165854bd Move llvm_init_inner inside #ifdef ENABLE_LLVM
This should fix c30a3e46d2 failing to link properly with ld 2.22 and GCC 4.9.1, on Linux, with non-LLVM builds.

./.libs/libmini.a(libmini_la-mini.o): In function `llvm_init_inner':
mini.c:(.text+0x1182b): undefined reference to `mono_llvm_init'
/usr/bin/ld: .libs/libmonoboehm-2.0.so.1.0.0: hidden symbol `mono_llvm_init' isn't defined
/usr/bin/ld: final link failed: Bad value
2014-09-24 10:40:03 +01:00
Atsushi Eno db5275ca56 [xlinq] fix bug #23318 - XComment.ToString() accepts "invalid" values.
Before it passes the value to XmlWriter.WriteComment(), it replaces
invalid values to valid form.
2014-09-24 15:30:32 +08:00
Zoltan Varga da335abfba Merge pull request #1301 from Unity-Technologies/fix-isuserprotected
Fix Win32 call in IsUserProtected. Usage was incorrect and freeing the w...
2014-09-23 18:59:15 -04:00
Zoltan Varga 2b5078c306 [bcl] Fix the RenameTpThread test, renaming a tp thread should not fail. 2014-09-23 18:40:34 -04:00
Zoltan Varga a8185f3374 [jit] Fix LLVM support on amd64 which got broken by the epilog size changes. 2014-09-23 18:36:23 -04:00
Zoltan Varga c30a3e46d2 [aot] Fix running with a loadable llvm module in aot-cache mode. 2014-09-23 18:26:18 -04:00
Marcos Henrich feacff0185 Revert "Uri made from UNIX path and RelativeOrAbsolute is now relative."
This reverts commit 116f4d2749.
2014-09-23 22:30:24 +01:00
Rodrigo Kumpera 6fe521be5c Merge pull request #1302 from mono/revert-1300-unixrelativeorabsolute
Revert "Uri made from UNIX path and RelativeOrAbsolute is now relative."
2014-09-23 17:12:10 -04:00
Rodrigo Kumpera 7d3eaf50a8 Revert "Uri made from UNIX path and RelativeOrAbsolute is now relative." 2014-09-23 17:05:30 -04:00
Michael Hutchinson 18186487ee Environment.IsRunningOnWindows can be true on MOBILE 2014-09-23 15:03:09 -04:00
Sebastien Pouliot d127a1a911 [System.Data] Add new file to the mobile_* sources build (to fix XI build) 2014-09-23 14:23:12 -04:00
Zoltan Varga 42173889e7 [jit] Fix EH on amd64 which got broken by d5a18ba292. 2014-09-23 14:16:16 -04:00
Rodrigo Kumpera 7c7ae04f7f Merge pull request #1299 from esdrubal/uriuserinfo
UriParseComponents no longer decodes '@' in UserInfo.
2014-09-23 14:00:13 -04:00
Marcos Henrich 30ec69fd50 Allow stream reuse when InputStream has been disposed.
If InputStream is disposed FlushInput now sets it to null so a new one can be created.
2014-09-23 18:44:49 +01:00
Marcos Henrich 6a249a5611 Test connection reuse. 2014-09-23 18:44:49 +01:00
Marcos Henrich 116f4d2749 Uri made from UNIX path and RelativeOrAbsolute is now relative.
This was changed because the path might be a relative http path and should take precedence over an absolute UNIX path.
2014-09-23 18:01:38 +01:00
Jonathan Chambers d56a23750b Fix Win32 call in IsUserProtected. Usage was incorrect and freeing the wrong parameter causing a memory corruption. 2014-09-23 12:54:44 -04:00
Miguel de Icaza 0699e4da36 Fix warnings in mscorlib's Test suite + bring a couple more tests + fix thread rename test 2014-09-23 10:56:04 -04:00
Marcos Henrich b89b5c46d6 Test WebClient.UploadFileTaskAsync ContentType. Covers 19529. 2014-09-23 15:30:50 +01:00
Marek Safar 84ab6a7833 Merge pull request #1300 from esdrubal/unixrelativeorabsolute
Uri made from UNIX path and RelativeOrAbsolute is now relative.
2014-09-23 05:11:15 -09:00
Marcos Henrich b6874fa16b Uri made from UNIX path and RelativeOrAbsolute is now relative.
Fixes 22954.
2014-09-23 14:32:59 +01:00
Marcos Henrich f6f80d5e4d Test that Uri made from UNIX path and RelativeOrAbsolute is relative. 2014-09-23 14:27:35 +01:00
Marcos Henrich 2d52cec1ce Merge pull request #1203 from esdrubal/protect
KeyPairPresistence now tries to fix folder permissions.
2014-09-23 13:58:19 +01:00
Marcos Henrich e074772e92 UriParseComponents no longer decodes '@' in UserInfo. Fixes 23246. 2014-09-23 12:42:11 +01:00
Marcos Henrich b63c44670a Test Uri.UserInfo with percentage encoded '@'. 2014-09-23 12:42:10 +01:00
Marcos Henrich 2cf751f7f7 Fixed additional Uri.UserInfo char consumed after an escaped char. 2014-09-23 12:42:10 +01:00
Marcos Henrich ac52aece46 Test Uri.UserInfo with escaped 'a'. 2014-09-23 12:42:09 +01:00
Zoltan Varga 745a2b16ec [aot] Add an 'options' argument to the AOT cache configuration where additional --aot= options can be passed. 2014-09-22 21:11:03 -04:00
Zoltan Varga b0523c4ee8 [aot] Add more verbose aot cache logging, fix failure detection. 2014-09-22 20:52:53 -04:00
Zoltan Varga 627fc398ad [aot] Make --aot=llvm actually work by passing the flag down to the JIT. 2014-09-22 20:18:33 -04:00
Zoltan Varga 19619d925e [aot] Fix a regression introduced by 82c15fa592. 2014-09-22 20:11:22 -04:00
Zoltan Varga 82c15fa592 [aot] Add an 'llvm' aot option which does the same as --llvm. This allows running the AOT compiler with LLVM enabled in aot cache mode. 2014-09-22 20:03:48 -04:00
Zoltan Varga 40ca3ae249 [llvm] Fix support for unaligned offsets in the store_membase_imm opcodes. Fixes #23267. 2014-09-22 18:52:54 -04:00
Ludovic Henry 24013364b7 [sgen] Use memcpy to copy object
It is faster by around 5-6% on copy heavy gc stress tests.
2014-09-22 14:52:16 -07:00
Zoltan Varga 16d9d07821 [runtime] Allow renaming of threadpool threads. Fixes #23206. 2014-09-22 17:07:26 -04:00
Zoltan Varga 74b76bdc11 [runtime] Fix the lookup of nested types which have a namespace. Fixes #21653. 2014-09-22 16:20:25 -04:00
Marek Safar 0f36581baa [mcs] Populate inherited constraints member cache from types not only base types. Fixes #23017 2014-09-22 22:12:49 +02:00
Marek Safar b99e7ab957 Fixes commit ef94fbfd9c 2014-09-22 22:12:49 +02:00
Marius Ungureanu 32318db8cf Fixup to ef94fbfd9c
Thanks @ezavaleta
2014-09-22 21:16:13 +03:00
Marek Safar ef94fbfd9c [corlib] Update en-NZ designators. Fixes #22212 2014-09-22 17:30:35 +02:00
Marek Safar 5ad92e6b10 [mcs] declaration expression after ref/out argument 2014-09-22 17:30:34 +02:00
Miguel de Icaza fb3a6d1cd2 Merge pull request #1295 from nealef/master
Add SqlCredential support to SqlClient/Tds
2014-09-22 10:41:58 -04:00
Rodrigo Kumpera c47fab9285 Merge pull request #1296 from directhex/master
Add a tool which can sync the Mono cert store from an arbitrary cert bundle
2014-09-22 10:29:33 -04:00
Jo Shields 452073b91e Add a tool which can sync the Mono cert store from an arbitrary cert bundle (i.e. every trusted CA.pem in one big text file). This is a format used by most Linux distributions, so allows Mono packagers to automatically integrate the Mono cert store with the OS cert store. 2014-09-22 14:02:03 +01:00
Zoltan Varga 5f9c74f4c5 [runtime] Fix mono_sigctx_to_monoctx () on win32. 2014-09-22 01:16:00 -04:00
Zoltan Varga df43380ea6 [runtime] Fix the win32 build. 2014-09-22 01:01:11 -04:00
Zoltan Varga ab5dda7fba Fix warnings. 2014-09-22 06:46:23 +02:00
Zoltan Varga 12bceb1700 [jit] Fix the handler block trampolines on windows. 2014-09-22 06:44:54 +02:00
Zoltan Varga f930824ea9 [runtime] Enable the fastpath in CEE_MONO_JIT_ATTACH on windows. 2014-09-22 06:44:54 +02:00
Zoltan Varga e0a408f702 [runtime] Treat the tls key as the tls offset on windows, since they are the same. 2014-09-22 06:44:53 +02:00
Zoltan Varga 12dc660454 [runtime] Enable fp elimination on winx64. 2014-09-21 23:07:30 -04:00
Zoltan Varga ac2e2c7703 [runtime] Disable a few more tests on windows which hang on winx64. 2014-09-21 22:48:42 -04:00
Zoltan Varga d5a18ba292 [jit] Enable the pushless call code on windows too, get rid of the non-pushless code. 2014-09-21 22:21:41 -04:00
Zoltan Varga dfb8d2ac8e [jit] Implement the pushless call code on winx64. 2014-09-21 22:01:03 -04:00
Zoltan Varga ea77b1f9fb [jit] Enable monitor fast paths on win64. 2014-09-22 01:45:28 +02:00
Zoltan Varga 558750f053 [runtime] Fix the windows build. 2014-09-21 17:42:45 -04:00
Zoltan Varga e2e74c95e6 [runtime] Fix the unregistration of our exception handler on windows. Fixes #23221. 2014-09-21 14:54:24 -04:00
rjvdboon edca3467ce Added System.IdentityModel.Tokens.BootstrapContext including tests. 2014-09-20 22:44:34 +02:00
Zoltan Varga ca51c3b026 [runtime] Enable the new interrupt code on arm linux. 2014-09-20 02:43:47 -04:00
Zoltan Varga d4b4c2dbbc [runtime] Add wrappers around the wapi interrupt functions to mono-threads to reduce the amount of #ifdef WIN32 blocks in threads.c. 2014-09-19 17:51:14 -04:00
Sebastien Pouliot 23042a0aa3 Fix typo (and XI builds) 2014-09-19 16:48:37 -04:00
Sebastien Pouliot 64b8e0c063 [System.Numerics] Fix unit test to succeed on different culture (XI runs tests them on several cultures) 2014-09-19 16:30:16 -04:00
Neale Ferguson a83e9cf4aa Add SqlCredential support -
- Tds.cs: Use SecureString objects for passwords; Add method to retrieve string from SecureString
- Tds42.cs: Use SecureString for passwords
- Tds50.cs: Use SecureString for passwords
- Tds70.cs: Use SecureString for passwords
- TdsConnectionParameters.cs: Use SecureString for passwords; Initialize Password parameter as cleared string; Add indicator for when password is set
- SqlConnection.cs: Use SecureString for passwords; Add SqlConnect method that accepts an SqlCredential along with the Connection string; Perform checking of parameters to ensure user/password not specified in connection string if credentials have been specified or using credentials when domain login is specified.
- SqlCredential.cs: Add new class with support for credentials
- System.Data.dll.sources: Add SqlCredential.cs to the build list
2014-09-19 11:52:52 -04:00
Ludovic Henry 05d341392c [sgen] Fix wbarrier use if we define SGEN_HEAVY_BINARY_PROTOCOL, HEAVY_STATISTICS or XDOMAIN_CHECKS_IN_WBARRIER 2014-09-19 11:14:48 -04:00
Miguel de Icaza af429ecfd0 Merge pull request #1245 from StephenMcConnel/bug-22483
Fix scrolling in SWF.ListView.EnsureVisible(int index)
2014-09-19 10:17:09 -04:00
Miguel de Icaza d2c021407d Merge pull request #1287 from akoeplinger/fix-appconfig-performancecounters
[System] Add performanceCounters element to System.Diagnostics app.config configuration section
2014-09-19 10:15:05 -04:00
Miguel de Icaza 3461617bc2 Merge pull request #1290 from directhex/master
Put KeyPairPersistence load into a try{}catch{} block.
2014-09-19 10:13:55 -04:00
Miguel de Icaza 605c8771b8 Merge pull request #1273 from joelmartinez/docs-unified-fix
bugfix for mdoc update with --dropns feature
2014-09-19 10:11:01 -04:00
Ludovic Henry fcb9de513a [utils] Fix force inlining compilation error with gcc on linux
[02131]   CC       libmonoruntimesgen_la-sgen-marksweep.lo
[02131] In file included from sgen-major-copy-object.h:35:0,
[02131]                  from sgen-marksweep.c:1128:
[02131] sgen-copy-object.h:38:1: warning: always_inline function might not be inlinable [-Wattributes]
[02131]  par_copy_object_no_checks (char *destination, MonoVTable *vt, void *obj, mword objsize, SgenGrayQueue *queue)
[02131]  ^
[02131] sgen-marksweep.c: In function 'par_copy_object_no_checks':
[02131] sgen-copy-object.h:38:1: error: function 'par_copy_object_no_checks' can never be copied because it saves address of local label in a static variable
[02131] make[3]: *** [libmonoruntimesgen_la-sgen-marksweep.lo] Error 1
[02131] make[3]: Leaving directory `/root/rpmbuild/BUILD/mono-3.10.1/mono/metadata'
[02131] make[2]: *** [all-recursive] Error 1
[02131] make[2]: Leaving directory `/root/rpmbuild/BUILD/mono-3.10.1/mono'
[02131] make[1]: *** [all-recursive] Error 1
[02131] make[1]: Leaving directory `/root/rpmbuild/BUILD/mono-3.10.1'
[02131] make: *** [all] Error 2
[02131] error: Bad exit status from /var/tmp/rpm-tmp.YxcUOE (%build)
2014-09-19 09:46:09 -04:00
Marek Safar 7ad366c25a [mcs] Improve scoring of failed overload resolution. Fixes #22989 2014-09-19 00:09:35 +02:00
Ludovic Henry d1ffd5a794 [utils] Use MONO_ALWAYS_INLINE + Add MONO_NEVER_INLINE 2014-09-18 16:42:00 -04:00
Jo Shields 3552179bda Put KeyPairPersistence load into a try{}catch{} block.
Kpp.Load() will throw an unhandled exception if _filename (a folder to use as the key store) does not exist and it cannot be created.

This is an entirely valid thing to have happen - cert importing into the machine store (mozroots --import --machine --sync) as root will create a /usr/share/.mono/certs/ folder, but will not create /usr/share/.mono/keypairs - and since the root user owns /usr/share/.mono/, if the user tries to enumerate the certificates in /usr/share/.mono/certs/, they get 0 certificates returned due to the unhandled exception dropping each loaded certificate on the floor.

Closes: Xamarin bug 23015
2014-09-18 17:32:06 +01:00
Marek Safar eb6781f3cd [mcs] Fix output type inference when parameters after first one depend on fixed first set. Fixes #23024 2014-09-18 14:47:19 +02:00
Marek Safar 548dca4730 [mcs] Better check for parameterless constructor overload 2014-09-18 10:10:46 +02:00
Zoltan Varga a4024ba4ae [sdb] Use new style interrupt on win32 if available. 2014-09-17 22:49:02 -04:00
Zoltan Varga 8ed233ef06 [runtime] Use the windows CONTEXT<->MonoContext conversion code to mono-context.c, simplify some code. 2014-09-17 22:37:18 -04:00
Zoltan Varga 4fc8068d2a [runtime] Implement the new suspend infrastructure on windows. 2014-09-17 18:25:00 -04:00
Zoltan Varga 28179361ec [sdb] Implement support for win64. 2014-09-17 15:21:11 -04:00
Marek Safar d62679a4a4 [xbuild] Workaround for issues with CreateItem task where metadata are not generated due to up-to-data inputs. Fixes #23022 2014-09-17 20:22:36 +02:00
Zoltan Varga e2f24086a8 Merge pull request #1288 from ylatuya/patch-2
[mkbundle] Fix check for dos2unix
2014-09-17 14:03:43 -04:00
Jonathan Pryor 818b81ef40 [runtime] Use statfs(2) on Android.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=23077

Reverts commit 53ce92470.

Commit 53ce92470 disabled use of statfs(2) on Android, for unspecified
reasons. (My *suspicion* is that the Android version mono was
originally ported to didn't have statfs(2), but I can neither confirm
nor deny that guess.)

Android has supported statfs(2) since API-4 Android v1.6 (in that
statfs(2) is in the header files); what's missing is MNT_RDONLY. What
IS present is MS_RDONLY, which appears to serve the same purpose.

Re-enable use of statfs(2) and use MS_RDONLY when building against the
Android NDK.
2014-09-17 12:56:44 -04:00
Andoni Morales Alastruey 753f233a31 [mkbundle] Fix check for dos2unix
This fixes the command to check for dos2unix and makes mkbundle usable again with mingw.
We need first to redirect the standard input, otherwise the check always fails with an InvalidOperationException and set CreateNoWindow=false to avoid spawning a new window.
2014-09-17 16:17:33 +02:00
Marek Safar 4f719f9ce9 [xbuild] Fix few crashes when task loading fails 2014-09-17 11:19:57 +02:00
Zoltan Varga 5dbf97e660 [jit] Make calls from gshared to gsharedvt sharable methods indirect since otherwise at runtime we might find an instantiation and we cannot patch the call, leading to performance problems. Fixes #23021. 2014-09-16 23:17:54 -04:00
Michael Hutchinson 2804d6af37 Fix mobile and mobile_static profiles
And bring them to parity with monodroid and monotouch
2014-09-16 19:14:20 -04:00
Martin Baulig 87622fc711 [WCF]: Update to my last fix for bug #22129.
The problem already starts when creating the OperationDescription; we need
to also look at the End* method here to correctly parse the reply parameters.

Then ClientRuntimeChannel.Process needs to distinguish between sync/async
and copy the out/byref parameters when needed.
2014-09-16 21:34:20 +02:00
Zoltan Varga 4e1e37519a [runtime] Make stack walks done by the sampling profiler async safe. 2014-09-16 15:07:55 -04:00
Marek Safar 9aed010782 [mcs] struct parameterless instance constructors 2014-09-16 19:19:32 +02:00
Zoltan Varga 80b14d356f [runtime] Disable VS warnings C4273 (inconsistent dll linkage), and C4005 (macro redefinition). The former occurs becase we mark exported function declarations using MONO_API, but not the definitions. The latter occurs because we define _WINSOCKAPI_. 2014-09-15 23:30:40 -04:00
Zoltan Varga 557390ee46 [runtime] Fix the my_g_bit_nth_msf () function for win64. 2014-09-15 22:10:23 -04:00
Zoltan Varga 02f48039b1 [runtime] Add support for setting the thread name on windows. On windows, this will only work when running under a debugger. 2014-09-15 19:14:09 -04:00
Zoltan Varga ae030203e7 [arm64] Increase some opcode sizes. Fixes #23026. 2014-09-15 18:09:43 -04:00
Zoltan Varga fad438976c [runtime] Fix an assert in w32_dlerror () on winx64. 2014-09-15 17:35:05 -04:00
Marek Safar 240cf239a2 [xbuild] More tweaks to tool path setup 2014-09-15 22:25:11 +02:00
Zoltan Varga 64f6eb2d1d [aot] Use gsharedvt for collection types instantiated with generic structs as well. 2014-09-15 15:31:38 -04:00
Marcos Henrich 1531798bbe Added missing files to projects csproj files. 2014-09-15 19:14:48 +01:00
Marek Safar 2320d0dc40 [mcs] Revert usage of closed delegates for compiler generated anonymous method 2014-09-15 18:34:20 +02:00
Rodrigo Kumpera 6ea08668a2 Merge pull request #1280 from nealef/master
Maximum large object size should be limited by SSIZE_MAX not SIZE_MAX.
2014-09-15 12:31:16 -04:00
Martin Baulig 8b10d9bb0b [WCF]: Copy out/ref parameters on async call; bug #22129. 2014-09-15 18:25:54 +02:00
Marek Safar b7fb736254 Merge pull request #1286 from esdrubal/xmlnullablearrayitem
XmlSerializer nullable array items.
2014-09-15 07:20:02 -09:00
Marcos Henrich 5fc6ecd7c7 If not specified assume that array items are nullable. Fixes #19012. 2014-09-15 16:57:13 +01:00
Marcos Henrich 8790297c85 Test xml serialization of nullable array items. Covers #19012. 2014-09-15 16:55:31 +01:00
Marek Safar 1afc866f87 [xbuild] Workaround for null log service (which should never be null) 2014-09-15 17:37:49 +02:00
Marek Safar 52cdea5c0a Merge pull request #1257 from esdrubal/xmloptional
Added optional serialization based on ShouldSerialize{V}.
2014-09-15 03:44:30 -09:00
Marcos Henrich be02242f8b Ignore method ShouldSerialize if it is a generic. 2014-09-15 13:02:00 +01:00
Marcos Henrich 85650c7528 Test serialization wen class has method bool ShouldSerialize<T>().
.NET throws an exception but it should have no effect on the serialization.
2014-09-15 13:02:00 +01:00
Marcos Henrich 79de2b62f9 Added optional serialization based on ShouldSerialize{V}.
SerializationCodeGenerator and XmlSerializationWriterInterpreter will no longer serialize an attribute named {V} if its object has a method named ShouldSerialize{V}() that returns false.
{V}Specified now is also checked to be true before serializating the attribute even if it is a property that is not settable.
Fixes #1852.
2014-09-15 13:02:00 +01:00
Marcos Henrich 17ad50a165 Added test for optional {V}Specified and ShouldSerialize{V}.
{V}Specified is a property or field and ShouldSerialize{V} is a method that can be set to false if we do not want to serialize an attribute with name {V}.
2014-09-15 13:02:00 +01:00
Marcos Henrich 1ec4bd5c26 Fixed NullReferenceException. 2014-09-15 13:01:04 +01:00
Marek Safar 7439e997ac [xbuild] Use ToolPath when building ToolTask execution path. Fixes #22981 2014-09-15 13:38:40 +02:00
Robin Neatherway b50e4a8728 Allow CLR binaries to be passed to Process.Start
On *nix files are not executable by default where on Windows they
are. This causes problems if installing a NuGet package on *nix that
contains .exe files intended to be used by build tasks. On Windows the
build will invoke these without complaining whereas on *nix the build
will fail with "Native error: cannot find file specified".

On mono, the action that will be taken is to pass the path to the .exe
file to mono as a command-line argument. If this was done in a shell it
would succeed whether or not the .exe file has the executable bit set,
so it seems that this should also succeed within a program.

With thanks to @akoeplinger for help designing the test.

I release this under the MIT license.
2014-09-14 18:44:02 +01:00
Alexander Köplinger d77664ceb0 [System] Add performanceCounters element to System.Diagnostics app.config configuration section
See http://msdn.microsoft.com/en-us/library/ms229387(v=vs.110).aspx for details about the element.
The value that is set by the element isn't currently used in Mono, but applications using it in their app.config crash otherwise (e.g. http://stackoverflow.com/questions/25741651).
2014-09-14 07:45:11 +02:00
Marc-Andre Ferland 8b9c60075f Missing Args checks. 2014-09-14 00:28:33 -04:00
Marc-Andre Ferland 6354f74888 Missing setting disposed to true 2014-09-14 00:27:25 -04:00
Zoltan Varga 777f69153c [runtime] Remove an unused interpreter file. 2014-09-13 13:59:03 -04:00
Marek Safar 7f2825301e [mcs] nullable property pattern 2014-09-13 12:43:41 +02:00
Zoltan Varga a1f58d35be [runtime] Fix the windows build. Define _WINSOCKAPI_ to fix the compilation problems when windows.h is included before winsock2.h: http://stackoverflow.com/questions/1372480/c-redefinition-header-files. 2014-09-12 20:07:05 -04:00
Joel Martinez 6c1bf0d17e [mdoc] consolidated dropns and dropns-assemblies into a single parameter.
Based on pull request feedback, this is a simpler usage, and meets our required use-case. A sample version of this parameter would be: `--dropns MyUnifiedAssembly=MyDroppedPrefix`
2014-09-12 17:22:06 -04:00
Rodrigo Kumpera a8392ba567 [runtime] Improve thread dumping reliability by doing it while holding the fat locks.
We take the loader and the root domain locks before doing a thread dump. This reduces the odds
of us suspending a thread that holds either of them and deadlocking, for example, while decoding
AOT JIs.
2014-09-12 14:18:39 -04:00
Neale Ferguson f065a289f6 Maximum large object size should be limited by SSIZE_MAX not SIZE_MAX.
The latter appears to be a hangover from 32-bit systems.
2014-09-12 11:37:52 -04:00
Neale Ferguson 3f740f3d94 Fixes 19752 -
Users have been complaining about strange errors arising when using the OracleClient classes.
I have tracked it down to the OciDefineHandle and OciDefineByPos calls, and OracleParameter
handling of amanged objects by unmanaged code. Currently two of the parameters passed to the
above OCI  call are short variables. They are passed as "ref" fields as Oracle uses their
address to put size and indicator data once the data is fetched. However, being defined as
short means that they are eligible for being moved during garbage collection. Thus if that
field is moved between the OciDefineByPos call and the fetch of the data then what Oracle is
pointing to may no longer be variable. I'm thinking it may be better to define these fields as
IntPtr and allocate them and retrieve their values via Marshal.ReadInt16. As for OracleParameter,
it uses a managed object "indicator" that is also used in a similar way. This reference is replaced
by a IntPtr and a get/set method to access the contents.
2014-09-12 11:25:57 -04:00
Marek Safar 300876b229 [mcs] Don't use `1 naming for compiler generated second level and deeper nested types. Fixes #22893 2014-09-12 15:20:26 +02:00
Zoltan Varga 7f6a46403d Merge pull request #1276 from Therzok/master
Add concurrent hashtable test to gitignore.
2014-09-11 20:58:12 -04:00
Zoltan Varga f0d2ee46f8 Merge pull request #1275 from ranma42/fix-lib64
Fix build with lib64 folder for arch-specific libraries
2014-09-11 20:57:48 -04:00
Sebastien Pouliot 90bb9c6d00 [System] Fix building unit tests under the mobile profile 2014-09-11 20:43:21 -04:00
Zoltan Varga 41339d95c6 [jit] Always pass the imt arg to interface calls in gsharedvt methods. Fixes #22624. 2014-09-11 17:57:11 -04:00
Joel Martinez c842249d72 [mdoc] Formatting feedback from pull #1273 2014-09-11 15:43:28 -04:00
Marek Safar 9fd3c7ac4b [mcs] property pattern 2014-09-11 19:40:51 +02:00
Rolf Bjarne Kvinge 550d314e51 Don't throw TimeZoneNotFoundExceptions when iOS gives us invalid data.
iOS 8 GM lists "Asia/Chita" among its time zones, but when requesting
the time zone data for that time zone, no data is returned.

With this change we ignore time zones without any data when fetching
all the timezones on the system.
2014-09-11 19:04:00 +02:00
Marek Safar 0083728e19 Merge pull request #1278 from esdrubal/datetimegmt
GMT DateTimeOffset is now properly parsed.
2014-09-11 05:29:27 -09:00
Marcos Henrich e73499b337 GMT DateTimeOffset is now properly parsed. Fixes #22851.
GMT date formats set useutc to true, so now useutc is checked to init DateTimeOffset with a zero offset.
2014-09-11 15:12:36 +01:00
Marcos Henrich b818408b16 Test that offset is zero when date ends with GMT. Covers #22851. 2014-09-11 15:11:42 +01:00
Marek Safar b946785022 Merge pull request #1277 from esdrubal/calendarsdaysinyear
Improved CalendricalCalculations fixed_from_dmy methods.
2014-09-11 03:17:52 -09:00
Marcos Henrich 468160e712 Improved CalendricalCalculations fixed_from_dmy methods. Fixes #21930.
In some cases fixed_from_dmy is used with the month parameter greater than the number of months of that year.
Year is now incremented until month parameter is valid.
2014-09-11 12:54:36 +01:00
Marcos Henrich da04211894 Test Calendar.DaysInYear. Covers #21930. 2014-09-11 12:53:25 +01:00
Ungureanu Marius 924a954d1f Add concurrent hashtable test to gitignore. 2014-09-11 13:39:57 +03:00
Marek Safar 1242b4b82c [corlib] Enumerate all subdirectories including the first one. Fixes #22857 2014-09-11 11:20:44 +02:00
Marek Safar 1eb9ba45c4 [system] Fixes failing test 2014-09-11 10:31:26 +02:00
Andrea Canciani d2f391c80c Do not hardcode lib path
The changes from 3408b8e5f1 cause
regressions in distros which do not use lib as folder for
arch-specific libraries, like Fedora x86_64.

Instead, reloc_libdir should be used (as in data/mono.pc.in).

This change is released under the MIT/X11 license.
2014-09-11 08:50:47 +02:00
Zoltan Varga 2c11b2ea4a [aot] Avoid a stack overflow if profiler enter-leave events are requested in the full-aot mode. 2014-09-10 19:14:57 -04:00
Zoltan Varga 7912295bc9 [runtime] Fix the RESOLTION_SCOPE->RESOLUTION_SCOPE typo. 2014-09-10 19:07:04 -04:00
Joel Martinez 582b370761 [mdoc] added -dropns-assemblies parameter.
Will now only replace the namespace when the type or member is in a listed assembly
2014-09-10 16:54:54 -04:00
Zoltan Varga d3624fa257 [runtime] Redirect runtime logging to asl_log only on ios, not when running the cross compiler. 2014-09-10 14:24:11 -04:00
Marek Safar 1d63659429 Merge pull request #1271 from akoeplinger/fix-switch-ctor
[System] Fixed Diagnostics.Switch ctor behavior for null parameters
2014-09-10 08:19:20 -09:00
Alexander Köplinger 29abf6790d [System] Fixed Diagnostics.Switch ctor behavior for null parameters
Passing null to the displayName or description ctor parameter on MS.NET makes them equal to an empty string.
Fixed the Mono behavior to match .NET.
2014-09-10 19:09:34 +02:00
Marek Safar 6d07ad8e7a [system.net.http] Encode ContentDisposition name. Fixes #18422 2014-09-10 19:09:27 +02:00
Marek Safar 9050d9cba1 [mcs] Remove value type constrained type parameter instantiation optimization to handle parameterless struct constructors 2014-09-10 19:09:27 +02:00
Marek Safar 156c7cf97a Merge pull request #1270 from esdrubal/xmlimplicit
When needed serialized objects are now implicitly converted.
2014-09-10 08:08:26 -09:00
Marcos Henrich f8ff518ebe When needed serialized objects are now implicitly converted.
Fixes #20403.
2014-09-10 17:25:44 +01:00
Marcos Henrich 5fdbad2444 Changed method ImplicitConvert to internal static. 2014-09-10 17:24:38 +01:00
Marcos Henrich 0804720aaa ImplicitConvert was using method with wrong parameter and return type. 2014-09-10 17:23:44 +01:00
Marcos Henrich f008d4afb6 Test XmlSerialization of element that requires implicit conversion.
Covers #20403.
2014-09-10 16:30:03 +01:00
Martin Baulig bbbcc73bde [websocket]: Fix ClientWebSocket.ReceiveAsync() with small buffer; bug #22704.
When calling ClientWebSocket.ReceiveAsync() with a buffer that's smaller than
the received chunk, we need to cache the header until next call.
2014-09-10 17:09:43 +02:00
Alexander Köplinger 0537cb3c2a Fix the build 2014-09-10 14:26:36 +02:00
Marek Safar 95b09a1a79 Merge pull request #1269 from Therzok/refactorSwitches
[SourceSwitch] Refactor a piece of code.
2014-09-10 02:01:15 -09:00
Marius Ungureanu 6e5e8d7915 Fix build failure caused by #1267. 2014-09-10 13:59:49 +03:00
Marius Ungureanu 462c6b08e9 [SourceSwitch] Refactor a piece of code. 2014-09-10 13:04:10 +03:00
Marek Safar ebe2a3df1d [system.net.http] Handle Content-Disposition in textual form as well. 2014-09-10 09:48:26 +02:00
Marek Safar 5846c52247 Merge pull request #1267 from ramtinkermani/master
The ShouldTrace method's conditions are fixed to correctly trace the events based...
2014-09-09 20:40:10 -09:00
ramtin 6cb9a04fca Unit Tests for SourceSwitch. Counting the number of events traced based on the Trace Level 2014-09-09 15:07:14 -07:00
Marek Safar 5e9eba8ffb [system.net.http] Tokenize dash only in range values. Fixes #22764 2014-09-09 23:41:49 +02:00
Rodrigo Kumpera 65f17c2c26 [jit] Fix error handling in a few places in the jit. 2014-09-09 16:34:55 -04:00
Rodrigo Kumpera 00f631312f [runtime] Fix error handling in mono_metadata_parse_mh_full. 2014-09-09 16:34:54 -04:00
Rodrigo Kumpera 666ea5f867 [runtime] Update reflection.c to use mono_class_get_checked. 2014-09-09 16:34:54 -04:00
Rodrigo Kumpera 3bbedfebb7 [runtime] Update marshal.c to use mono_class_get_checked. 2014-09-09 16:34:54 -04:00
Rodrigo Kumpera a17da53c37 [runtime] Cleanup usage of mono_class_get to object.c 2014-09-09 16:34:54 -04:00
Rodrigo Kumpera 6382fd247d [runtime] Cleanup usage of mono_class_get in loader.c 2014-09-09 16:34:54 -04:00
Rodrigo Kumpera a94aa47cd8 [runtime] Make icall use mono_class_get_checked. 2014-09-09 16:34:53 -04:00
Rodrigo Kumpera ec7be0fd36 [utils] Add mono_error_convert_to_exception. 2014-09-09 16:34:53 -04:00
Rodrigo Kumpera 4b726a17b8 Introduce mono_class_from_name_case_checked 2014-09-09 16:34:53 -04:00
Rodrigo Kumpera 7dd6476b8e [runtime] Use MonoError in exception.c 2014-09-09 16:34:53 -04:00
Rodrigo Kumpera 2ed68d65e8 [runtime] Change mono_type_get_full to use MonoError properly. 2014-09-09 16:34:53 -04:00
Rodrigo Kumpera 3968beaced [runtime] Introduce MonoError to mono_type_create_from_typespec. 2014-09-09 16:34:52 -04:00
Rodrigo Kumpera 5fa8e1abe7 [runtime] Plug MonoError into another function. 2014-09-09 16:34:52 -04:00
Rodrigo Kumpera 6d60ff581c [runtime] Introduce MonoError to mono_class_get_full.
Introduce MonoError into callers of mono_class_get_full.

Make mono_class_get not abort on failure until all callers are fixed.
2014-09-09 16:34:52 -04:00
Rodrigo Kumpera 5c8ab13f0c Add mono_class_get_checked to mono_class_create_from_typedef. 2014-09-09 16:34:52 -04:00
Rodrigo Kumpera 32e2bb7c39 [runtime] Change mono_type_get_full to use mono_class_get_checked. 2014-09-09 16:34:52 -04:00
Rodrigo Kumpera a824dde30f [runtime] Change do_mono_metadata_parse_type to use mono_class_get_checked 2014-09-09 16:34:51 -04:00
Rodrigo Kumpera 3ee5d36ec7 [runtime] Introduce mono_class_get_checked. 2014-09-09 16:34:51 -04:00
Rodrigo Kumpera 57cce937d8 [runtime] Introduce mono_class_from_typeref_checked and replace usage of the old one with it.
This is another step into wiring up MonoError into the typeloading codebase. This is
one more function that needs it.
2014-09-09 16:34:51 -04:00
Rodrigo Kumpera efa5a5ad17 [utils] Add mono_error_set_assembly_load_simple to ease producing an error message for ref only assemblies. 2014-09-09 16:34:51 -04:00
Rodrigo Kumpera 82c38c4409 [metadata] Replace mono_class_get_full with a saner pair of mono_class_get and mono_class_inflate_generic_class_checked. 2014-09-09 16:34:51 -04:00
Rodrigo Kumpera d3da468965 [runtime] Expose mono_class_inflate_generic_class_checked to the internal API. 2014-09-09 16:34:50 -04:00
Rodrigo Kumpera 2006bf3f44 Add deprecation notice for mono_class_get_full. 2014-09-09 16:34:50 -04:00
ramtin 59be7ba9c5 The ShouldTrace conditions are fixed to correctly trace the events based on the Level 2014-09-09 11:50:06 -07:00
Marcos Henrich bb296086c0 TimeFormat "zzz" is only valid after a date. 2014-09-09 17:44:00 +01:00
Marek Safar ccbd0b1a0d Merge pull request #1266 from esdrubal/datetimenewformat
Added time format with only offset.
2014-09-09 05:29:34 -09:00
Rodrigo Kumpera a27d7ee86d Merge pull request #1248 from kumpera/kill_the_interpreter
[runtime] Remove the interpreter.
2014-09-09 09:15:01 -04:00
Rodrigo Kumpera 8602eed8f7 [cleanup] Remove more old files. 2014-09-09 09:14:37 -04:00
Marcos Henrich a27a42b99b Added time format with only offset. Fixes #22558. 2014-09-09 12:49:00 +01:00
Marcos Henrich cf7319008b Test DateTimeOffset.Parse with format yyyy-dd-MMzzz. Covers #22558. 2014-09-09 12:41:27 +01:00
Jo Shields 4f8114aabd Fix "make dist" error
ad8236ebb8 broke "make dist", by removing Makefile.am.in whilst leaving it in EXTRA_DIST
2014-09-09 11:30:52 +01:00
Ludovic Henry 749171e917 [sgen] Tweak internal class allocator sizes to add highly used on
We observed on multiples benchmarks that most internal allocations are for 8, 16, 296 (32bits), 328 (64bits), 504 (32bits) and 1016 (64bits) bytes of memory. To minimize waste, we added these memory sizes to the default allocator sizes.
2014-09-09 11:16:09 +02:00
Atsushi Eno 2b72c6bdf2 [aspnet/ajax] fix bug #6512 (by Mikkel Kruse Johnsen) - don't deserialize GET parameters. 2014-09-09 15:09:27 +08:00
Zoltan Varga c8e73660db Merge pull request #1263 from madewokherd/begindecls
Use G_BEGIN_DECLS instead of __BEGIN_DECLS.
2014-09-08 22:40:43 -04:00
Joel Martinez dc17504d3f [mdoc] New make test, reproduces issue with --dropns when run with a secondary assembly that doesn't drop the specified namespace 2014-09-08 20:45:16 -04:00
Zoltan Varga 4373bd213a [aot] Really fix the aot-cache logging. Rework how mscorlib is handled in the aot cache. 2014-09-08 20:25:49 -04:00
Zoltan Varga f574898b09 [aot] Fix a crash in the aot cache code if MONO_LOG_LEVEL is set. 2014-09-08 20:01:21 -04:00
Zoltan Varga ceb74f4118 Merge pull request #1264 from madewokherd/vasprintf
Avoid use of vasprintf.
2014-09-08 18:49:55 -04:00
Joel Martinez 41c28a59bb [mdoc] New make test for the --dropns functionality 2014-09-08 17:54:05 -04:00
Vincent Povirk 83924ebb2c Avoid use of vasprintf.
This is not available on mingw-w64, and the extra allocation is unnecessary.

This commit licensed as MIT/X11.
2014-09-08 15:48:20 -05:00
Vincent Povirk 3c920be3e5 Use G_BEGIN_DECLS instead of __BEGIN_DECLS.
__BEGIN_DECLS isn't available in mingw-w64.

This commit licensed as MIT/X11.
2014-09-08 13:54:48 -05:00
Marek Safar 27b3636cef Merge pull request #1262 from esdrubal/uriserializationinfo
Added support for UriComponents.SerializationInfoString.
2014-09-08 05:40:33 -09:00
Marcos Henrich ea6b8960d0 Added support for UriComponents.SerializationInfoString. Fixes #21571. 2014-09-08 22:21:02 +08:00
Marcos Henrich d2d338fe26 Test UriComponents.SerializationInfoString. Covers #21571. 2014-09-08 22:09:52 +08:00
Marek Safar 4bd9820eaa Merge pull request #1253 from esdrubal/datetimeiso8601
DateTime.Parse now handles unlimited number of fractional digits.
2014-09-08 03:52:54 -09:00
Marek Safar 14f56f6aea [system.numerics] Unify handling of default ctor and zero. Fixes #22591 2014-09-08 14:50:39 +02:00
Marek Safar 88bc5cee97 [mcs] switch statement with recursive pattern matching 2014-09-08 11:48:52 +02:00
Marek Safar 92ff3c372d [system.net.http] Make SendAsync state free to handle recursive calls. Fixes #22724 2014-09-08 11:48:51 +02:00
Rodrigo Kumpera 128f297b84 Merge pull request #1260 from khellang/patch-2
Added less media type
2014-09-07 12:26:57 -04:00
Rodrigo Kumpera 247bf1f21c Merge pull request #1259 from khellang/patch-1
Updated WOFF to official media type
2014-09-07 12:26:37 -04:00
Kristian Hellang d595c66bbd Added less media type 2014-09-07 17:24:37 +02:00
Kristian Hellang 788c95a0e0 Updated WOFF to official media type
See http://www.w3.org/TR/WOFF/#appendix-b for the media type registration
2014-09-07 17:19:42 +02:00
Marek Safar e207bf76ab Merge pull request #1258 from akoeplinger/unify-test-namespaces
Cleanup namespace names of class lib tests to follow convention
2014-09-06 21:25:38 -09:00
Zoltan Varga f8365f7900 [gsharedvt] Allow the SIZEOF opcode in gsharedvt code if it doesn't reference a gsharedvt type. Fixes #22711. 2014-09-06 00:38:38 -04:00
Zoltan Varga 4b6a2c8f89 Fix a warning. 2014-09-05 20:07:13 -04:00
Zoltan Varga 729bbe4041 [jit] Store the epilog length in MonoArchEHJitInfo instead of encoding it in jinfo->unwind_desc, since the latter can overflow for methods with large epilogs. Fixes #22685. 2014-09-05 18:07:42 -04:00
Zoltan Varga 3795639a4a Fix the linux build. 2014-09-05 17:18:18 -04:00
Zoltan Varga c8c4bd9a78 [runtime] Fix the linux build. 2014-09-05 15:46:19 -04:00
Martin Baulig 24fbaedcd2 [WCF]: Actually fix #22179 to allow concurrent requests.
Pass the 'OperationContext' around in a parameter instead of storing it
in an instance field to make this thread-safe.
2014-09-05 18:59:21 +02:00
Marcos Henrich 1852905c44 Test that wrong ISO8601 dates throw FormatException. 2014-09-05 21:31:53 +08:00
Zoltan Varga 385f84f18c [aot] Emit aot logging information to a per-assembly file when using the AOT cache. Cache aot failures. 2014-09-04 23:31:50 -04:00
Zoltan Varga 4f916f178b [aot] Print error messages to the aot logfile as well, avoid exiting the process on failures. 2014-09-04 20:06:53 -04:00
Zoltan Varga 39c87f6f69 [aot] Allow the redirection of output messages from the AOT compiler to a logfile. 2014-09-04 19:11:30 -04:00
Zoltan Varga d84d1a94a0 Fix the build. 2014-09-04 17:38:16 -04:00
Zoltan Varga ad8236ebb8 [runtime] Get rid of the Makefile.am.in->Makefile.am change in metadata/, its not needed. 2014-09-04 17:34:36 -04:00
Alexander Köplinger ddcfc42070 Cleanup namespace names of class lib tests to follow convention
A couple of the test suites didn't follow the MonoTests.<namespace of class under test> naming convention for the namespace.
2014-09-04 18:55:58 +02:00
Marek Safar 2b88d02356 [mcs] recursive pattern with named arguments 2014-09-04 15:12:21 +02:00
Marek Safar 806b95d844 [mcs] recursive pattern matching 2014-09-04 10:37:50 +02:00
Marek Safar e83f4a2ab3 Merge pull request #1254 from vkargov/master
[corlib] Take daylight change info for the current year in TimeZoneTest.cs
2014-09-03 20:30:38 -09:00
Alexis Christoforides 5d80954463 Bump Mono version -> 3.10.1 2014-09-04 00:15:40 -04:00
Zoltan Varga c7b3d5c3ba Revert "[build] Include mono/utils into the extensions module."
This reverts commit b760456501.

Revert this as it is not needed.
2014-09-03 21:20:33 -04:00
Zoltan Varga f746fe8d1b Revert "[build] Deps tracking for mono/utils/Makefile.am when extension module is disabled."
This reverts commit a2e939a8a3.

Revert this as is not needed.
2014-09-03 21:20:11 -04:00
Zoltan Varga d2cee144fe [sgen] Use mono_thread_info_get_stack_bounds () on win32 as well, the stack bottom value returned by it is correct, only the stack top value is unusable, since windows dynamically extends the stack. 2014-09-03 18:15:15 -04:00
Rodrigo Kumpera 43177ef54b [utils] Add android extension point to threading. 2014-09-03 16:58:30 -04:00
Rodrigo Kumpera a2e939a8a3 [build] Deps tracking for mono/utils/Makefile.am when extension module is disabled. 2014-09-03 16:34:18 -04:00
Rodrigo Kumpera b760456501 [build] Include mono/utils into the extensions module. 2014-09-03 16:32:30 -04:00
Rodrigo Kumpera 748fefa1d7 [runtime] Cleanup the horrible ifdef hell that is the stack bounds discovery code.
This split a single chunk of intractable ifdef hell into a beautiful set of per-target
files.

This will allow us to actually figure out what's going on on each target.
2014-09-03 16:30:35 -04:00
Zoltan Varga 4c1155f40a Merge pull request #1252 from alesliehughes/master
Stop warning about winsock2.h being included before windows.h
2014-09-03 14:44:32 -04:00
Vladimir Kargov 59668db7f4 [corlib] In a TimeZone test, UtcOffset is taken for the current year, so take DaylightChanges for the current year as well. 2014-09-03 16:36:35 +04:00
Marcos Henrich db57c23c29 DateTime.Parse now handles unlimited number of fractional digits.
This change was made because .NET can parse ISO8601 format with an unlimited number of fractional digits.
Fixes #22417.
2014-09-03 18:29:58 +08:00
Marcos Henrich 17972cec4f Added test ISO8601FractionalDigits.
Covers #22417.
2014-09-03 18:27:28 +08:00
Alistair Leslie-Hughes ec2b629fa9 Stop warning about winsock2.h being included before windows.h
This change is released under the MIT license.
2014-09-03 19:51:11 +10:00
Zoltan Varga f9b27e2e73 Fix a warning. 2014-09-02 21:10:11 -04:00
Zoltan Varga 541639c3bb [runtime] Load the runtime config file before initializing the runtime, so it can pick up the aot-cache configuration information. 2014-09-02 20:25:16 -04:00
Zoltan Varga 883f9399f4 [runtime] Add an 'app' attribute to the 'aotcache' config section to specify which apps should use the AOT cache. 2014-09-02 20:22:05 -04:00
Marek Safar b5fcd926f8 Merge pull request #1251 from esdrubal/utf8encoding
UTF8Encoding Fallback
2014-09-02 06:43:40 -09:00
Marcos Henrich f79c64942e Changed overlong byte to be processed again.
The byte is processed again because it can be the begin of a new multi-byte encoded character.
2014-09-02 23:14:09 +08:00
Marcos Henrich 91fa140dd0 Changed UTF8Encoding to call fallback with whole byte sequences.
Removed unnecessary parameters ref byte [] bufferArg.
This changes are required by UTF8EncodingTest.EncodingFallback that in some cases is expecting multibyte values..
2014-09-02 22:57:26 +08:00
Marcos Henrich 3d332ac26d Added UTF8EncodingTest.EncodingFallback.
EncodingFallback tests for multiple invalid inputs the unknownBytes that are given to the DecoderFallback.
2014-09-02 22:55:52 +08:00
Miguel de Icaza a7b779648b Bring fix for Cecil, includes fix for F#/Fody 2014-09-02 10:49:41 -04:00
Marcos Henrich 60aa49b35b Added class EncodingTester that can be used to test fallbacks.
EncodingTester is a testing helper class with a method TestDecoderFallback that makes DecoderFalback testing  easier.
2014-09-02 22:42:54 +08:00
Marek Habersack 10d4e76525 Do not specify key file when building for mobile, it should be passed on command line 2014-09-02 14:32:12 +02:00
Marcos Henrich 09bb2dc4bd Changed InternalGetCharCount to iterate the bytes as InternalGetChars. 2014-09-02 18:38:20 +08:00
Marek Safar fca9b48556 [mcs] more nonliteral constants pattern matching 2014-09-02 11:55:45 +02:00
Marek Habersack 38b25dc65a This method is internal in the mobile profile 2014-09-02 00:33:44 +02:00
Marek Habersack 14fba61b9d Added System.IO.InternalBufferOverflowException class to the mobile profile 2014-09-01 22:24:36 +02:00
Marek Habersack 58684cf2c4 Merge pull request #1249 from mattleibow/master
[system.data] DataRows with a NULL RowError incorrectly indicated HasError
2014-09-01 21:47:43 +02:00
Zoltan Varga eeb1227133 [runtime] Further reduce the usage of the loader lock in the metadata code by moving code out of locked regions and using the image lock instead. 2014-09-01 14:39:06 -04:00
Matthew Leibowitz a3c1bebc45 [system.data] DataRows with a NULL RowError incorrectly indicated HasError:
- MS.NET allows RowError to be set to NULL, but will convert it to string.Empty
2014-09-01 11:03:03 -07:00
Rodrigo Kumpera 6bee6a7b18 [runtime] Remove the interpreter. 2014-09-01 13:27:03 -04:00
Zoltan Varga bd8782b061 [runtime] Use a separate lock to protect global data structures in classes.c. 2014-09-01 13:05:25 -04:00
Zoltan Varga 03e4fe45d7 Disable a sys.data test which fails on wrench because of an old sqlite version. 2014-09-01 12:51:53 -04:00
Zoltan Varga f6ae9f133d Bump version to 3.10. 2014-09-01 11:47:11 -04:00
Zoltan Varga 00612b8049 [runtime] Factor out the nested types computation code from mono_class_get_nested_types () and reorganize it so most of the work is done outside the loader lock. 2014-09-01 11:40:56 -04:00
Zoltan Varga ea77a1201c [runtime] Use the image locks in many places instead of the loader lock. 2014-09-01 11:40:56 -04:00
Zoltan Varga 98ef62b1d1 [runtime] Remove a missed mono_loader_unlock () from mono_metadata_get_header (). 2014-09-01 11:40:55 -04:00
Zoltan Varga c73f87c669 [runtime] Reorganize mono_method_signature_checked () so most of the work is done outside the loader lock. 2014-09-01 11:40:55 -04:00
Zoltan Varga e043529add [runtime] Reorganize mono_method_get_header () so most of the work is done outside the loader lock. 2014-09-01 11:40:55 -04:00
Zoltan Varga 6730dfbf80 [runtime] Remove locking from the mono_get_method_constrained_... () functions, its not needed. 2014-09-01 11:40:55 -04:00
Zoltan Varga f5a0a351c2 [runtime] Reorganize mono_class_setup_interfaces () so most of the work is done outside the loader lock. 2014-09-01 11:40:54 -04:00
Zoltan Varga ff9b6836d2 [runtime] Move the initialization of class->has_finalize into mono_class_has_finalizer () in most cases. 2014-09-01 11:40:54 -04:00
Zoltan Varga e87e75fe3a [runtime] Reorganize mono_class_setup_methods () so most of the work is done outside the loader lock. 2014-09-01 11:40:54 -04:00
Zoltan Varga a3f28b43f7 [runtime] Reorganize mono_class_has_finalizer () so most of the work is done outside the loader lock. 2014-09-01 11:40:54 -04:00
Zoltan Varga 042114b194 [runtime] Reorganize mono_class_setup_events () so most of the work is done outside the loader lock. 2014-09-01 11:40:53 -04:00
Zoltan Varga 8dac2761fc [runtime] Reorganize mono_class_setup_properties () so most of the work is done outside the loader lock. 2014-09-01 11:40:53 -04:00
Zoltan Varga 7704a952f6 [runtime] Use the image lock in mono_type_from_typespec () instead of the loader lock. Also do most of the work outside the lock. 2014-09-01 11:40:53 -04:00
Rodrigo Kumpera 2c6b6ff553 Merge pull request #1246 from schani/feature-separate-pointer-queue
[sgen] Refactor pointer queue out of pinning code.
2014-09-01 10:13:41 -04:00
Marek Safar 79ea6ce4d0 Put back csharp project removed in 0450000dc4 2014-09-01 14:58:32 +02:00
Marek Safar 20c85188ab [mcs] Fix removing incomplete generic types from eval cache. Fixes #22393 2014-09-01 14:57:23 +02:00
Marek Safar 05feed5de7 [mcs] Parsing of ternary expressions whose then condition is a lambda. Fixes #22523 2014-09-01 13:26:48 +02:00
Marek Safar 11ac4dfb22 [mcs] Remove wrong test 2014-09-01 13:22:21 +02:00
Marek Safar 6e6ad378c0 Fixes c2ac44d3dd 2014-09-01 12:43:32 +02:00
Marek Safar c2ac44d3dd [system.data.linq] Delay reflection hit to actual execution point. Workarounds #22522 2014-09-01 11:22:57 +02:00
Marek Safar bcf33452dd [system.net.http] Update RequestMessage.RequestUri.AbsoluteUri after redirect. Fixes #22383 2014-09-01 10:10:30 +02:00
Zoltan Varga 5646004e39 [runtime] Fix the windows build. 2014-08-31 04:34:18 -04:00
Marek Safar 01bc7c1923 [mcs] Revert to broken native csc definite assignment for structs 2014-08-30 14:04:16 +02:00
Marek Safar c8b482d640 [mcs] nonliteral constants pattern matching 2014-08-30 14:04:16 +02:00
Marek Safar 723dc9ad6f [xbuild] Fix InstalledAssemblyTables signature 2014-08-30 14:04:15 +02:00
Marek Safar 8897b572c7 [mcs] simple constants pattern matching 2014-08-30 14:04:15 +02:00
Zoltan Varga 644ff6b019 [aot] Fix full-aot support when the AOT cache is enabled. 2014-08-29 23:47:33 -04:00
Zoltan Varga 567c08843d [jit] Avoid hardcoding tls offsets into the aot versions of the monitor enter/exit trampolines on amd64. 2014-08-29 23:47:01 -04:00
Zoltan Varga f8db51ecb4 [jit] Avoid uninitialized fields in the MonoDelegateTrampInfo structure. 2014-08-29 19:30:15 -04:00
Zoltan Varga 34df6ae34b [runtime] Fix reading past the end of a string when setting the native thread name. 2014-08-29 19:29:48 -04:00
Zoltan Varga 96b74d362a [runtime] Fix a problem introduced by 522663cdfa. 2014-08-29 17:42:37 -04:00
Zoltan Varga 522663cdfa [runtime] Add an adapter between the MonoPrintCallback and the eglib GPrintFunc types. 2014-08-29 17:03:23 -04:00
Mark Probst 2f126c13e8 [sgen] Refactor pointer queue out of pinning code. 2014-08-29 13:33:34 -07:00
Tom Hindle bb672ad95e Fix mono_marshal_free_ccw (). Fixes #22414. 2014-08-29 16:05:50 -04:00
Zoltan Varga bfc3336224 [bcl] Catch exceptions thrown by SerialPortStream.Dispose () when called from the finalizer. Fixes #15514. 2014-08-29 15:06:25 -04:00
Zoltan Varga abfd4b5732 [sdb] Fix the checking of the handshake message. 2014-08-29 15:04:40 -04:00
Zoltan Varga b8766a812d [runtime] Add functionality for AOTing assemblies on demand when they are first used. Configurable using a new "aotconfig" config element, i.e. <aotcache assemblies="mscorlib System"/>. 2014-08-29 15:02:52 -04:00
Zoltan Varga 8dea307fa4 [runtime] Add Steve Reid's public domain SHA1 code. 2014-08-29 15:01:26 -04:00
Rodrigo Kumpera 62b1e5a653 [eglib] Fix stderr output redirection. 2014-08-29 14:33:27 -04:00
Stephen McConnel 44acb717d8 Fix scrolling in SWF.ListView.EnsureVisible(int index)
This fixes https://bugzilla.xamarin.com/show_bug.cgi?id=22483
2014-08-29 12:25:48 -05:00
Marek Safar 38c3874627 Merge pull request #1242 from esdrubal/xelement
Fixes XContainer attempt to create a XNode from a null value.
2014-08-29 01:16:24 -09:00
Marcos Henrich acb0cc0d7d Fixes XContainer attempt to create a XNode from a null value.
Fixes #20151.
2014-08-29 17:59:39 +08:00
Marcos Henrich 8308eb87e0 Test XElement constructed from array with null values as object.
Covers #20151.
2014-08-29 17:57:31 +08:00
Marek Safar b2d61a33a6 Merge pull request #1237 from esdrubal/xdocument
Changed XObject OnChanged and OnChanging to use Owner.
2014-08-28 21:05:14 -09:00
Marek Safar ba64d7a8eb Merge pull request #1241 from RyanMelenaNoesis/patch-1
Update X509CertificateValidationMode.cs
2014-08-28 21:03:44 -09:00
Ryan Melena 5b8dad3895 Update X509CertificateValidationMode.cs
Remove explicit enum values for sake of consistency with existing enum.
2014-08-28 20:26:08 -05:00
Alexis Christoforides c109e47433 Merge pull request #1240 from NoesisLabs/master
Correct duplicate X509CertificateValidationMode definition error
2014-08-28 20:21:58 -04:00
Ryan J. Melena b1446b1982 Correct duplicate X509CertificateValidationMode definition error caused by enum changing assemblies between .NET 4.0 and 4.5. 2014-08-28 19:01:48 -05:00
Zoltan Varga 03aee949f1 Merge pull request #1200 from akoeplinger/remove-jvm
[Cleanup] Remove TARGET_JVM
2014-08-28 19:17:43 -04:00
Rodrigo Kumpera 903c5e3aa6 Revert "Merge pull request #1219 from panzone/los_partial_marking"
This reverts commit 397176d701, reversing
changes made to 33c345a945.
2014-08-28 19:12:51 -04:00
Zoltan Varga 7ec9786a3f Merge pull request #1235 from directhex/master
Add g_Ctoc to list of acceptable g_* symbols in mono, for test-eglib-remap
2014-08-28 18:50:47 -04:00
Zoltan Varga fff41afa51 [runtime] Fix a crash in the logging profiler when enumerating elf images. 2014-08-28 16:44:55 -04:00
Rodrigo Kumpera dc75a4a86e Merge pull request #1238 from esdrubal/datetimeoffset
Fixed DateTime compiler errors.
2014-08-28 16:12:47 -04:00
Alexis Christoforides b27c2d690d Merge pull request #1236 from NoesisLabs/master
Support JWT functionality in System.IdentityModel.Tokens.Jwt
2014-08-28 16:08:46 -04:00
Marcos Henrich 4fa7c08306 Fixed DateTime compiler errors. 2014-08-29 03:58:03 +08:00
Marcos Henrich 8854761cc4 Changed XObject OnChanged and OnChanging to use Owner.
When XObject.Owner is not a XElement XObject.Parent returns null and the owner would not be notified of changing and changed events.
Fixes:#18772
2014-08-29 02:12:39 +08:00
Marcos Henrich 74afbbb110 Test XDocument.Changed event. Covers #18772. 2014-08-29 02:00:30 +08:00
Ryan J. Melena b7f40f6682 Add compiler pragmas for conditional .NET 4.5 compilation 2014-08-28 11:57:47 -05:00
Ryan J. Melena 7f0fc12f3a Add file comment headers. This change is released under the MIT license. 2014-08-28 11:57:46 -05:00
Ryan J. Melena ed1e4e2918 Fix VS changes to .csproj file. This change is released under the MIT license. 2014-08-28 11:57:45 -05:00
Ryan J. Melena 725b211d9f Minimal implementation of classes and methods necessary to support the JWT functionality in System.IdentityModel.Tokens.Jwt (https://github.com/MSOpenTech/azure-activedirectory-identitymodel-extensions-for-dotnet). This change is released under the MIT license. 2014-08-28 11:57:44 -05:00
Rodrigo Kumpera 397176d701 Merge pull request #1219 from panzone/los_partial_marking
[Sgen parallel collector] Los partial marking
2014-08-28 12:28:05 -04:00
Jo Shields 4b48ec236a Add g_Ctoc to list of acceptable g_* symbols in mono, for test-eglib-remap.
In theory, this test is used to verify that no unknown glib symbols exist
in eglib. However, it's tripping on g_Ctoc which is not a glib (or eglib)
symbol, instead it comes from the IO layer - and glib symbols never use
uppercase characters anyway
2014-08-28 17:26:31 +01:00
Marek Safar 33c345a945 Merge pull request #1234 from esdrubal/datetimeoffset
DateTime.CoreParseExact.
2014-08-28 07:06:30 -09:00
Marek Safar fee0db958c [xbuild] Allow metadata in skipped task output expressions 2014-08-28 17:44:42 +02:00
Marcos Henrich 5e86fba0b9 Removed unreachable code. 2014-08-28 23:43:10 +08:00
Marcos Henrich cb0d8221e0 Changed DateTimeOffset.ParseExact to use DateTime.CoreParseExact. 2014-08-28 23:39:03 +08:00
Marcos Henrich af977863fe Improved DateTime._DoParse offset logic. 2014-08-28 23:37:29 +08:00
Marcos Henrich 727b045f36 Removed line causing problems when 'K' was followed by something. 2014-08-28 23:35:48 +08:00
Marcos Henrich a95479875e Improved DateTime parsing of years.
Years with 5 or more digits and less than 1000 are now correctly parsed.
2014-08-28 23:31:19 +08:00
Marcos Henrich 8c9f47900c Created DateTime.CoreParseExact so to be used by DateTimeOffset. 2014-08-28 23:27:57 +08:00
Marek Safar 924d6216bf [mcs] Fixes failing error test 2014-08-28 16:35:59 +02:00
Marek Safar 121766abb9 [mcs] type pattern expression 2014-08-28 16:35:59 +02:00
Marcos Henrich 379be33c4e Changed DateTime._DoParser to support DateTimeOffset patterns. 2014-08-28 22:11:15 +08:00
Marek Safar 4b2ddc74cc Merge pull request #1233 from esdrubal/uriparserisbaseof
UriParser.IsBaseOf now explicitly throws ArgumentNullException.
2014-08-28 03:22:48 -09:00
Marcos Henrich 8c6e7faba3 UriParser.IsBaseOf now explicitly throws ArgumentNullException.
A change in Uri.Compare was making IsBaseOf to return false when arguments were null.
NullReferenceException is thrown by .NET, nonetheless the correct behavior is to throw a ArgumentNullException..
2014-08-28 19:46:35 +08:00
Marek Safar ed9291e086 Merge pull request #1232 from akoeplinger/fix-test
[MSBuild] Fixed a test that failed when the GAC wasn't available
2014-08-27 20:44:34 -09:00
Alexander Köplinger b45cd3f489 [MSBuild] Fixed a test that failed when the GAC wasn't available
PR #1229 added a test that relies on the GAC and fails when it isn't available, like when building on a clean machine with monolite.
Skip the test in that case.
2014-08-27 22:28:49 +02:00
Rodrigo Kumpera 88c3f0b7ec [runtime] Incorporate team feedback on the new logging APIs. 2014-08-27 15:47:43 -04:00
Alexander Köplinger 7152730bcd Fix badge URL in README.md, the previous one got cached by GitHub 2014-08-27 20:06:47 +02:00
Marek Safar 9330b9f221 [mcs] Add 6.0 to version error reporting 2014-08-27 17:56:17 +02:00
Marek Safar 5787f73a39 Merge pull request #1231 from esdrubal/gthreshold
Serializer were not generated if generationThreshold was changed.
2014-08-27 06:13:45 -09:00
Marcos Henrich baa495e78b Serializer were not generated if generationThreshold was changed. 2014-08-27 22:20:00 +08:00
Marek Safar 4866102820 Merge pull request #1230 from esdrubal/xslattribute
Process XslLiteralElements with only child attributes as empty ones.
2014-08-27 03:58:41 -09:00
Marcos Henrich af4dcd117d Process XslLiteralElements with only child attributes as empty ones.
Fixes #14751
2014-08-27 20:51:49 +08:00
Marcos Henrich d7f5c71baa Test xls transformation of single child node to an attribute. 2014-08-27 20:20:47 +08:00
Sebastien Pouliot 2332ba9a10 [eglib] Fix logging on iOS (asl_vlog != asl_log)
asl_vlog last parameter is a va_list and giving it a char* leads to crash
which calls our native unhandled exception handler, which also tries to
log what happens making the watchdog unhappy about the food quality

0x000000008badf00d
2014-08-26 21:54:30 -04:00
Alexis Christoforides 813d6610ec Resolve build issues on Windows. 2014-08-26 15:49:19 -04:00
Zoltan Varga 3ccd45f8f3 Fix the build. 2014-08-26 15:01:24 -04:00
Martin Baulig 37d2e36ca9 [WCF]: Fix #22179 - 'finally' protect ClientRuntimeChannel.Begin/EndProcess(). 2014-08-26 20:00:44 +02:00
Marek Safar 7f030179c4 Merge pull request #1229 from andreiagaita/master
[MSBuild] Make sure assembly references with extensions are located correctly
2014-08-26 08:07:09 -09:00
Marek Safar f0afe2f9c4 [mcs] Predefined attibutes can have unresolved parameter types. 2014-08-26 17:13:41 +02:00
Marek Safar c106cdc775 [mcs] Put back future lang version for easier migration path 2014-08-26 13:46:16 +02:00
Marek Safar a8994e23a7 [mcs] Don't report error when predefined InterlockedCompareExchange_T is not available. 2014-08-26 13:39:15 +02:00
Marek Safar f5b09d21a5 [mcs] Hide backing fields in default debugger display 2014-08-26 10:02:38 +02:00
Marek Safar e1d28db6fc [mcs] Replace future with experimental 2014-08-26 10:02:37 +02:00
Marek Safar d87c706981 [mcs] Better error message 2014-08-26 10:02:37 +02:00
Marek Safar 8c6593f8a8 [system] Add AcceptWebSocketAsync signatures 2014-08-26 10:02:37 +02:00
Zoltan Varga ef5549b572 Update the LLVM backend to work with llvm branch mono-2014-08-23-b401e6b9699423409a055dc873e4d3f361a908c0. 2014-08-26 00:33:05 -04:00
T.J. Purtell 5d07b77a67 [runtime] Don't call mono_arch_handle_exception() when chaining
Context: https://bugzilla.xamarin.com/show_bug.cgi?id=18763#c12
Context: https://bugzilla.xamarin.com/show_bug.cgi?id=18763#c14
Context: http://stackoverflow.com/a/1789879/83444

mono_set_crash_chaining() was added in 8ffc4070 in order to better
support Android crash logs.

Crash logging in Android is "weird" (something we didn't know at the
time of 8ffc4070); when a process crashes on Android, ideally:

 1. The Android signal handler is executed,
 2. Bionic will attempt to connect to /system/bin/debuggerd.
 3. debuggerd will try to connect to the crashing process, then
    retrieve "useful" information from the crashing process (stack
    trace, register values, etc.)

The problem with 8ffc4070 was that there is a "window" between steps
(1) and (3) during which the crashing process continues to execute but
debuggerd hasn't attached to the process. It is possible that the
crashing process can thus exit before debuggerd has had a chance to
attach, killing the purpose of the crash logs.

Case in point: consider mono_sigsegv_signal_handler(). In 8ffc4070,
if mono_do_crash_chaining is TRUE, then Mono will execute:

  mono_handle_native_sigsegv (SIGSEGV, ctx);
  mono_chain_signal (SIG_HANDLER_PARAMS);
  mono_arch_handle_exception (ctx, NULL);

Because mono_chain_signal() doesn't block, abort the process, or
otherwise do anything to prevent execution from continuing, execution
will hit mono_arch_handle_exception(), which will exit the process.
If you're unlucky, this will happen before debuggerd has had a chance
to attach to the process.

The obvious fix is to prevent mono_arch_handle_exception() from being
invoked. The question is, *how*? jonp suggested [0] that after
mono_chain_signal() returns then _exit(2) or a busy loop could be
invoked. Unfortunately, _exit(2) makes the process exit explicit, and
~reliably prevents debuggerd from doing anything.

A busy loop doesn't work because it just causes the process to hang
within signal handler context, and debuggerd is never able to log
anything about the crashed process.

It would seem that the signal handler itself must exit without causing
the process to exit so that debuggerd has a chance to do ANYTHING,
otherwise nothing will happen reliably.

Thanks to T.J. Purtell for investigating and providing the patch.

[0]: https://github.com/mono/mono/pull/1206#issuecomment-52357802

--- Original commit message [formatted] ---

re #18763: After the chained handler executes, it may return to allow
the crashed instruction to be restarted or it may have taken
corrective action so the instruction can be resumed successfully.

For example, bionic resets the signal handler for SIGSEGV to default
expecting that the kernel will restart the offending instruction and
cause the kernel to abort the process.  Don't do mono exception
handling after chaining to support these types of signal management.
2014-08-25 23:54:36 -04:00
Jonathan Pryor 9e7713121b [eglib] Fix compilation on PLATFORM_ANDROID.
Compilation of eglib/src/goutput.c was broken in commit 989165e1:

	mono/eglib/src/goutput.c: In function 'monoeg_log_default_handler':
	mono/eglib/src/goutput.c:159:75: error: 'args' undeclared (first use in this function)
	  __android_log_vprint (to_android_priority (log_level), log_domain, "%s", args);
	                                                                           ^
	mono/eglib/src/goutput.c:159:75: note: each undeclared identifier is reported only once for each function it appears in
	mono/eglib/src/goutput.c: In function 'default_stdout_handler':
	mono/eglib/src/goutput.c:168:2: error: incompatible type for argument 4 of '__android_log_vprint'
	  __android_log_vprint (ANDROID_LOG_ERROR, "mono", "%s", message);
	  ^
	mono/eglib/src/goutput.c:139:0:
	$ANDROID_NDK_PATH/platforms/android-4/arch-arm/usr/include/android/log.h:109:5: note: expected 'va_list' but argument is of type 'const gchar *'
	 int __android_log_vprint(int prio, const char *tag,
	     ^
	mono/eglib/src/goutput.c: In function 'default_stderr_handler':
	mono/eglib/src/goutput.c:175:2: error: incompatible type for argument 4 of '__android_log_vprint'
	  __android_log_vprint (ANDROID_LOG_ERROR, "mono", "%s", message);
	  ^

(The cause of the breakage is that __android_log_vprint() takes a
va_args parameter, which is no longer present in 989165e1.)

Use __android_log_write() instead of __android_log_vprint().

Note: __android_log_write() writes a "simple string" to `adb logcat`,
meaning there is no printf(3)-style formatting applied.
2014-08-25 22:58:30 -04:00
Sebastien Pouliot 28d400df31 [corlib] Update ClaimsPrincipalTest to avoid Is[Not]Empty as this is not part of NUnitLite 1.0 (and can't be run on XiOS) 2014-08-25 20:43:31 -04:00
Rodrigo Kumpera debdc1c127 [eglib] Restore previous defaults for some platforms. 2014-08-25 14:51:07 -04:00
Rodrigo Kumpera 97c8674bf4 [msvc] Fix release 64bits builds. 2014-08-25 14:42:22 -04:00
Rodrigo Kumpera 1996d664b4 [jit] Ensure no threads are running when the JIT is asked to cleanup. 2014-08-25 14:42:22 -04:00
Rodrigo Kumpera 8c36d76bd2 [utils] Add runtime API for output redirection, logging and aborting. 2014-08-25 14:42:22 -04:00
Rodrigo Kumpera 0a08dede53 [eglib] g_assertion_message should not abort, g_logv will do it. 2014-08-25 14:42:22 -04:00
Rodrigo Kumpera 989165e12f [eglib] Add log/print redirection functions to eglib. 2014-08-25 14:42:22 -04:00
Martin Baulig 7d8798c15d [System]: WebClient.OpenWrite() must get the response on close; fixes #10163.
When the stream returned by WebClient.OpenWrite() / OpenWriteAsync() /
OpenWriteTaskAsync(), we need to call GetResponse() and read the full
response.

Unfortunately, there is no async API available for this, so this API should
not be used in async applications.
2014-08-25 18:15:49 +02:00
Martin Baulig d56c28373b [System]: Fix WebClient.UploadValuesTaskAsync(); bug #20359. 2014-08-25 18:15:48 +02:00
Marcos Henrich 5d2f303311 Test DateTimeOffest parsing of partial dates. 2014-08-25 23:51:37 +08:00
Marek Safar 60d9c66011 [msbuild] corcompare public API 2014-08-25 14:00:05 +02:00
Marek Safar 8c5488e79c [corlib] Fix ClaimsIdentity claim value comparison 2014-08-25 13:12:42 +02:00
Marek Safar 336382e2b1 [corlib] corcompare update 2014-08-25 13:12:42 +02:00
Marek Safar 4eb632730e Merge pull request #1224 from esdrubal/codecompiler
Changed mono_path profile replacement to be case insensitive.
2014-08-25 12:56:04 +02:00
Marek Safar 78b1cde8fc Merge pull request #1223 from esdrubal/xmlgenerator
Test SerializationCodeGenerator.
2014-08-25 12:55:33 +02:00
Marek Safar f2b5c86467 Merge pull request #1226 from mattleibow/TransactionScope-InvalidTimoutNotThrowingException
[system.transactions] Throw exception when an invalid TimeSpan is provided
2014-08-23 07:54:03 +02:00
Matthew Leibowitz 5b4172c8cc [system.transactions] Throw exception when an invalid TimeSpan is provided:
- MS.NET throws
 - prevent construction when an invalid (negative) timeout is provided
2014-08-23 00:38:15 +02:00
Alexis Christoforides 96b66b3867 Added mono_string_from_utf32() 2014-08-22 17:11:11 -04:00
Marek Safar 0661867309 [corlib] Improve System.Security.Claims. Fixes #22282 2014-08-22 22:09:11 +02:00
Marek Safar 289331a627 [mcs] Handle partial entry point method 2014-08-22 22:09:11 +02:00
Marek Safar 2712774292 Remove unused mdb icall 2014-08-22 22:09:10 +02:00
David Straw 5b6c684d26 Fix for bug 22307 - Intermittent IndexOutOfRangeException on closing connection 2014-08-22 11:50:08 -06:00
Zoltan Varga 0d839a1e09 [runtime] Add a mono_thread_detach_if_exiting () public api function which can be called by embedding code to detach the runtime if the code is running from a pthread dtor. Fixes part of #21164. 2014-08-22 11:37:14 -04:00
Marcos Henrich a6a4d75dda Changed mono_path profile replacement to be case insensitive. 2014-08-22 22:20:53 +08:00
Marcos Henrich 9d2ede6010 Fixed serialization of XmlNode field with attribute XmlAnyElement.
Fixes #3211.
2014-08-22 21:50:40 +08:00
Marcos Henrich 24bfa83876 Added missing XmlTypeMapping.IsAny logic.
This complements commit 05444c7c1c570db730f17b6d15dd66d3728b6.
2014-08-22 21:50:39 +08:00
Marcos Henrich 9f52a988cf Replaced incorrect bool.ToString() by GetLiteral(bool). 2014-08-22 21:50:39 +08:00
Marcos Henrich 1e5ce9cc4f Added GetTypeFullName, fixes wrong nullable valuetype names. 2014-08-22 21:50:38 +08:00
Marcos Henrich 526cbd5ced Changed UsageCount and generationThreshold to zero based. 2014-08-22 21:46:38 +08:00
Marek Safar 93e590439c [xbuild] Resolve output properties for skipped task to match task output when it's not skipped 2014-08-22 09:24:40 +02:00
Marcos Henrich 5df652e7d2 Test SerializationCodeGenerator.
XmlSerializerTests was mostly testing XmlSerializationReaderInterpreter and XmlSerializationWriterInterpreter.
XmlSerializerGeneratorTests forces the usage of SerializationCodeGenerator while running XmlSerializerTests.
2014-08-22 02:56:05 +08:00
Marcos Henrich dd6aca8621 Tests serialization of XmlNode field with attribute XmlAnyElement.
Covers #3211.
2014-08-22 02:42:19 +08:00
Andreia Gaita 5e8e4f3883 [MSBuild] Make sure assembly references with extensions are located correctly 2014-08-21 18:30:47 +01:00
Alex Rønne Petersen 8020aafc3b Update badge URL in README.md. 2014-08-21 18:30:17 +02:00
Alex Rønne Petersen 105c916504 Fix a warning in mono-conc-hashtable. 2014-08-21 18:23:06 +02:00
Alex Rønne Petersen 0d8ddc225a Remove unused/undefined function. 2014-08-21 18:23:06 +02:00
Marek Safar 8376abf928 Merge pull request #1221 from LogosBible/uri-compare
Fix NullReferenceException in Uri.Compare when only one of the Uris is null
2014-08-21 15:51:12 +02:00
Martin Potter 30c0309f15 Lower-case the host in Uri.TryCreate to match behavior of constructors
On Microsoft's implementation of the Uri class, the contructors and TryCreate method both lower-case the host. This commit fixes the issue where the constructors lower-cased the host but the TryCreate method did not.
2014-08-21 06:43:52 -07:00
Alex Rønne Petersen 0cdfb23e29 Merge pull request #1172 from roji/datarow_null
Fix DataRow error management
2014-08-21 14:59:28 +02:00
Martin Potter d990d904c4 Fix NullReferenceException in Uri.Compare when only one of the Uris is null 2014-08-21 05:52:38 -07:00
Marek Safar f070b646f6 [corlib] Handle String::Format with escaped closing }. Fixes #22114 2014-08-21 10:35:38 +02:00
Zoltan Varga bdeb6123fd [jit] Use mini_type_stack_size () instead of mono_type_size () in the stack slot allocation code, this aligns vtype size to a multiple of the pointer size, preventing problems when vtypes are returned in registers on some platforms like arm64. 2014-08-20 21:39:46 -04:00
Miguel de Icaza e9b93e2788 Merge pull request #1189 from joelmartinez/docs-64bit-squash
MDoc and monodoc.dll changes to support iOS 64Bit API
2014-08-20 16:56:57 -04:00
Zoltan Varga 776efa6920 [jit] Fix the switching of domains in native-to-managed wrappers, previously this only worked in some cases. 2014-08-20 13:55:28 -04:00
Marek Safar e57c1ed37d [mcs] Emit event fields even when compare-and-exchange is not available 2014-08-20 15:54:06 +02:00
Marek Safar 37e33ceb3e [mcs] Easy restrictions on enum base type epxression 2014-08-20 13:16:55 +02:00
Marek Safar ebcc2ee853 [corlib] Task never is CompletedSynchronously 2014-08-20 12:01:42 +02:00
Marek Safar 8aa250524c Fix wrong time test 2014-08-20 09:01:57 +02:00
Jo Shields 7178ce2c40 Switch to using jenkins.mono-project.com for DNS tests
This test requires a simple single mapping for Hostname<->IP with one IP and reverse DNS. Using EC2-hosted sites doesn't work as they don't have valid reverse DNS. Use the Jenkins subdomain, since that fits the criteria.
2014-08-20 07:20:41 +01:00
Marek Safar ca5e18f6a9 [mcs] Clean-up flow analysis for boolean expressions 2014-08-20 08:20:26 +02:00
Marek Safar 09f73f3070 [mcs] Null operator flow analysis 2014-08-20 08:20:26 +02:00
Mark Probst c69e743177 [sgen] Small simplification of sgen_pin_objects_in_section().
We only have one section, which is the nursery, so don't even pass it in.
Furthermore, it's only called locally, so make it static.
2014-08-19 12:17:50 -07:00
Mark Probst f35fa6adf5 [sgen] Simplify pin_objects_from_addresses() and fix potential performance issue.
In the case where more than one pointer pointed to the same empty region within
the nursery we would search through that empty region for each pointer instead of
just once.
2014-08-19 12:17:50 -07:00
Mark Probst 4564b54ded [sgen] Sanitize and fix pin_objects_from_addresses().
Assume we have an object at address 0x1000, with size 0xf0, then
a hole of size 0x10, and the next object starting at 0x1100, of
size 0x20.  In the pin queue we have the addresses 0x10f8 and
0x1100.

When we process the first pin queue entry, 0x10f8, we jump over
the object at 0x1000, to 0x10f0.  Then we skip the hole and end
up at 0x1100.  We set last_obj to that address.  Then we check
against the pin queue entry we're looking for and find that we've
overshot it, so we end our search and go to the next pin queue
entry, 0x1100.  There's an object at that address, but because of
this check we don't pin it:

	if (addr >= last_obj && (char*)addr < (char*)last_obj + last_obj_size) {

addr == 0x1100, last_obj == 0x1100, last_obj_size == 0x20
2014-08-19 12:17:50 -07:00
Mark Probst b4c9630073 [sgen] Make optimizations in new bridge turn-offable at compile-time.
This will help find bugs.
2014-08-19 12:09:34 -07:00
Mark Probst 8a56cba5b7 [sgen] Fix new bridge implementation. 2014-08-19 12:09:34 -07:00
Andrea Francesco Iuorio 24ef95ece8 [Sgen] Implement partial marking for big array of objects
This commit changed the gray stack to support work items. When a big
array of objects is marked, Sgen now create several work items. Every
work item rappresents a pieces of the array that must be scanned.
Since they are different pieces, the workers can now parallel scan
and mark the array, resulting in a better work distribution between
the workers.

I release this change under the MIT license.
2014-08-19 20:38:23 +02:00
Andrea Francesco Iuorio 30a627f9a8 [Sgen] Transport scan macros from sgen-descriptor.h to sgen-scan-object.h
This commit transport the scan macro from sgen-descritor.h to
sgen-scan-object.h. This is useful for modify at compile time
the scan macro according to the scan function.

I release this change under the MIT license.
2014-08-19 20:37:39 +02:00
Marek Safar 5c42807469 Merge pull request #1213 from fengari/system_timers_timer_opt
System.Timers.Timer optimization and small correction
2014-08-19 16:59:50 +02:00
Andrey Akinshin dbc021772a Suppression of negative Elapsed in Stopwatch
There was a bug (https://connect.microsoft.com/VisualStudio/feedbackdetail/view/94083/stopwatch-returns-negative-elapsed-time) in the old Microsoft .NET versions: the Stopwatch.Elapsed property could return negative value for a small time period. It was be fixed in .NET 4.0, but it can be still reproduced by the current Mono version.
For example, this can be reproduced during dynamic processor frequency scaling (see http://en.wikipedia.org/wiki/SpeedStep).
2014-08-19 15:55:50 +07:00
Marek Safar 2c6797db48 [mcs] Add more error checks 2014-08-19 10:34:54 +02:00
fengari b3251b6248 Do not dispose the underlying Timer every time the Enabled is set to false, keep it around for as long as this Timer exists. Throw ObjectDisposedException on Enabled setter. ArgumentException throwing according to docs. Removed 'disposed' field. DueTime for underlying timer changes only if enabled (as per docs). Check for already disposed in Dispose(). Not firing Elapsed if disposed. Unit tests. 2014-08-19 11:21:52 +03:00
Marek Safar 74ad56cdfa [mcs] Complex binary logical expressions flowanalysis 2014-08-19 09:34:39 +02:00
Marek Safar a41a626dab [mcs] More warnings for lifted nullable operators working on value types 2014-08-19 09:26:25 +02:00
Marek Safar 9c46884097 Merge pull request #1216 from AndreyAkinshin/master
Removing excess line with debug Console.WriteLine
2014-08-19 09:00:58 +02:00
Andrey Akinshin 4be0d33040 Removing excess line with debug Console.WriteLine 2014-08-19 11:27:33 +07:00
Zoltan Varga 68e5cc395f [bcl] Add a missing check to TypeBuilder.CreateType (). Fixes #22059. 2014-08-18 21:38:50 -04:00
Zoltan Varga aa3e8cb211 Fix a warning. 2014-08-18 18:24:49 -04:00
Marek Safar 5809028135 Merge pull request #1214 from esdrubal/xmlbase
Xml Serialization of Base class w/o a parameterless constructor.
2014-08-18 16:57:43 +02:00
Marcos Henrich 8fa4a77948 Xml Serialization of Base class w/o a parameterless constructor.
Removed validation code that did not allowed serialization of base classes without a parameterless constructor.
Fixes #6913.
2014-08-18 15:27:53 +01:00
Rodrigo Kumpera b0a2135f5c [utils] Improve error message in case of thread suspend fails. 2014-08-18 09:18:37 -04:00
Marcos Henrich 2c5f30d7bd Added test BaseClassWithoutParameterlessConstructor.
Covers #6913
2014-08-18 14:08:02 +01:00
Marek Safar 24005444c7 Merge pull request #1212 from esdrubal/isany
Fixed XmlSerializer to handle attribute XmlSchemePrivider.IsAny.
2014-08-18 12:45:04 +02:00
Marcos Henrich 38d56909d9 Fixed XmlSerializer to handle attribute XmlSchemePrivider.IsAny.
XmlSerializer no longer outputs a root element with class name when the class has the attribute XmlSchemeProvider and IsAny is true.
Fixes #11916
2014-08-18 11:42:05 +01:00
Marcos Henrich 6c5ea03852 Test XmlSerialization of class with XmlSchemaProvider with IsAny.
Covers #11916.
2014-08-18 11:40:58 +01:00
Rodrigo Kumpera a8a518752e [runtime] Fix malloc backend for mempools. 2014-08-17 02:40:42 -04:00
Zoltan Varga 6986ed5c1c Merge pull request #1210 from Mailaender/mono-core-parallel-build
Fixed parallel build for MCS dir-check
2014-08-16 15:51:29 -04:00
Matthias Mailänder 7e267ff2fe fix parallel build 2014-08-16 16:48:01 +02:00
Zoltan Varga eaa343fcba Merge pull request #1208 from Mailaender/ppc-build-fixes
PowerPC Garbage Collector build fixes
2014-08-16 10:11:15 -04:00
Marek Safar 557ad88e3d [mcs] Extend missing type check to type lookups. Fixes #20933 2014-08-16 14:49:38 +02:00
Marek Safar 2c037b85c6 [mcs] Fix copy and paste error in constraints checker. Fixes #22131 2014-08-16 14:49:37 +02:00
Marek Safar 76efee0a49 Merge pull request #1207 from nlhepler/master
Fix buffer overflow for long paths in jay
2014-08-16 10:27:56 +02:00
Matthias Mailänder 58de3013d1 fix ppc build failures 2014-08-16 08:28:55 +02:00
Lance Hepler 015e847e11 Handle long paths in jay 2014-08-15 16:06:11 -07:00
Zoltan Varga 5ab34b2477 [jit] Fix yet another native types problem. Fixes #22053. 2014-08-15 15:32:00 -04:00
Marek Safar 230b3bfce4 [mcs] Add dictionary initializer 2014-08-15 20:51:18 +02:00
João Matos d34210d900 [System.IO.Compression] Fixed Zip support for empty directories. 2014-08-15 19:13:30 +01:00
Joel Martinez a8d74cc095 [mdoc] Changed 'old' and 'new' to 'classic' and 'unified' per feedback. 2014-08-15 11:19:48 -04:00
Zoltan Varga 31e92f2442 [runtime] Fix the leaking of mach ports introduced by 98bbf8512a. Fixes #22068. 2014-08-15 09:56:47 -04:00
Zoltan Varga 12e4b4fed4 [runtime] Make more wrappers use a WrapperInfo structure. 2014-08-14 22:06:15 -04:00
Zoltan Varga 844ad76318 [runtime] Integrate calls to mono_wrapper_info_set () into mono_mb_create_and_cache () to fix races when a wrapper is placed into a cache without its wrapper info set. 2014-08-14 21:45:31 -04:00
Zoltan Varga 407b8163c8 [jit] Add support for constrained calls with vtype return types in gsharedvt code. Fixes #22109. 2014-08-14 15:54:55 -04:00
Zoltan Varga 8e3b2fa421 [jit] Fix the stack alignment checking code in the x86 trampolines. 2014-08-14 15:54:55 -04:00
Marek Safar 33023bf7de [mcs] Improve commit 409024fcab 2014-08-14 21:01:28 +02:00
Joel Martinez 8b6a9693bd [mdoc] Style updates per pull request feedback 2014-08-14 14:16:29 -04:00
Marek Safar 5aeec74842 [mcs] null propagating operator on delegate invocation 2014-08-14 19:05:27 +02:00
Marek Safar acb5527b57 Warnings cleanup 2014-08-14 19:05:27 +02:00
Marek Safar 409024fcab [mcs] Speed up nullable tokenizer. Fixes #20195 2014-08-14 19:05:27 +02:00
Joel Martinez 1051734504 [mdoc] Moved enumeration back into deferred mode.
This resolved an issue with the ecmadoc importer that assumed execution would be deffered in order to keep reading from the XmlReader
2014-08-14 11:07:43 -04:00
Marek Safar 5f5bed4643 Merge pull request #1188 from arktronic/master
[TimeZoneInfo] Fix DST bug and implement To/FromSerializedString
2014-08-14 14:16:19 +02:00
Marek Safar 62a15c8e13 [mcs] coalescing operator if the lhs of a null is a integer type that is larger than the integer type on the rhs. Fixes #22054 2014-08-14 11:50:54 +02:00
Marek Safar 512c1407b3 Merge pull request #1205 from akoeplinger/fix-tests
[System] Use xamarin.com instead of mono-project.com for DNS tests
2014-08-14 08:54:24 +02:00
Alexander Köplinger a81feba777 [System] Use xamarin.com instead of mono-project.com for DNS tests
The latter is now hosted on a different IP behind a CDN and the IP may change depending on location.
Using xamarin.com instead fixes the tests for now.
2014-08-14 01:21:20 +02:00
Joel Martinez 867299720c [mdoc] Fixed issue with assembly versions being added incorrectly 2014-08-13 17:11:03 -04:00
Ludovic Henry d273a16452 [jit] Disable delegate virtual optimisation while we are fixing it 2014-08-13 16:34:30 -04:00
Mark Probst 37dcfd1819 [sgen] Use a power of two as the cement hash size.
Cementing, specifically the hashing, showed up when profiling GC heavy
code.  This reduces the footprint.
2014-08-13 13:00:05 -07:00
Mark Probst 60a6084e9b [sgen] In the GC pause visualizer histogram, label the axis. 2014-08-13 13:00:04 -07:00
Mark Probst 0e2322f9d8 [gc] Measure Boehm GC time correctly. 2014-08-13 13:00:04 -07:00
Zoltan Varga 2ceb43d380 [runtime] Fix the PLATFORM_GNU check so it works with gnueabi etc. as well. Fixes #21520. 2014-08-13 15:33:40 -04:00
Zoltan Varga e46452652f [runtime] Don't make runtime invoke signatures generic. Fixes #21973. 2014-08-13 15:17:40 -04:00
Marek Safar db3eb16307 Merge pull request #1204 from VQComms/claimsprincipaloverloads
Added HasClaim, FindFirst, FindAll into ClaimsPrincipal
2014-08-13 20:22:22 +02:00
Marek Safar 9c377582d1 [mcs] null operator on address locations 2014-08-13 20:21:10 +02:00
Marek Safar c8c631ae2b [mcs] Check for duplicate destructors. Fixes #21983 2014-08-13 20:21:10 +02:00
Zoltan Varga a4f96bc571 [aot] Fix a small memory leak. 2014-08-13 13:59:19 -04:00
Jonathan Channon db06435616 Added space before parenthesis according to Mono guidelines 2014-08-13 18:11:11 +01:00
Jonathan Channon 05bf78d278 added HasClaim, FindFirst, FindAll System.Security.Claims.ClaimsPrincipal method overloads - This change in released under the MIT license. 2014-08-13 17:57:55 +01:00
Atsushi Eno 0322d96b73 [MS.Build] when building MSBuild task, inherit properties.
This makes difference when the build has started from a solution especially
via command line with /p option. Those command-line-passed properties need
to be inherited to each project, but they weren't.
xbuild worked fine here.
2014-08-13 19:35:18 +09:00
Atsushi Eno 778c3b5a02 [MS.Build] add test regarding item condition and target-generated property. 2014-08-13 19:35:12 +09:00
Marek Safar b8d8f62956 [mcs] nameof operator with unbound type arguments 2014-08-13 07:05:10 +02:00
Zoltan Varga be86c5d406 [arm64] Allow v8..v15 in unwind info on arm64. Fixes part of #21615. 2014-08-12 19:52:47 -04:00
Joel Martinez 49699b8188 [mdoc] Fixed an issue with type-file path resolution.
In certain cases, such as stubbing out namespace-less classes it was failing to produce the right paths.
2014-08-12 17:45:54 -04:00
Joel Martinez 2cb5217d48 [mdoc] Added preserver.cs to build script so make compiles 2014-08-12 17:44:17 -04:00
Marcos Henrich 8e9da60e99 KeyPairPresistence now tries to fix folder permissions.
An exception is no longer thrown if the folder permissions can be fixed.
Fixes bug 19274.
2014-08-12 19:08:37 +01:00
Zoltan Varga abb5e6f7e1 Merge pull request #1161 from ludovic-henry/pr22-delegate-virtual-trampoline
[delegate virtual] Improve trampoline caching
2014-08-12 13:53:49 -04:00
Ludovic Henry 8022fec251 [delegate-virtual-trampoline] Add virtual functions delegate trampoline support
This optimization is activated in the ldvirtftn + delegate case, and is deactivated in the case where the architecture does not support it (mono_arch_get_delegate_virtual_invoke_impl return NULL)
2014-08-12 13:30:45 -04:00
Ludovic Henry 87b5b1c6ca [delegate-virtual-trampoline] Add virtual parameter to existing JIT time code path 2014-08-12 13:30:45 -04:00
João Matos 025877a34b [System] Restrict GZip/DeflateStream tests to .NET 4.5. 2014-08-12 17:36:26 +01:00
João Matos f39bebefea [System] Implemented .NET 4.5 overloads for GZipStream and DeflateStream.
Fixes xambug #21982.
2014-08-12 16:17:08 +01:00
Paolo Molaro 374b71131e [runtime] Fix logic when allocating code region if the first try at a fixed address fails. 2014-08-12 15:31:18 +02:00
Marek Safar e7dbeee80d Re-enable valid tests 2014-08-12 10:34:33 +02:00
Marek Safar 2f043e033d [System.Net.Http] Handle quoted filename value. Fixes #21960 2014-08-12 10:31:32 +02:00
Marek Safar b184bbea53 [corlib] Remove heavyweight EndsWith from 1bff9d890f 2014-08-12 08:49:29 +02:00
Marek Safar cd48aae3b8 [mcs] nameof operator 2014-08-12 08:16:21 +02:00
Marek Safar 147d410929 [mcs] Any type parameter is allowed for null propagating operator 2014-08-12 08:16:21 +02:00
Marek Safar 7bdcefb038 [mcs] auto-property initializer can be array initializer 2014-08-12 08:16:20 +02:00
Miguel de Icaza 7c9d050961 Merge pull request #1192 from LogosBible/regex-fixes-21803
Regex substring fix
2014-08-11 23:27:48 -04:00
Atsushi Eno 82f411d44a [ms.build] add some cyclic dependency related tests (some are not working). 2014-08-11 21:53:35 +09:00
Atsushi Eno 7ec59c3177 [ms.build] Fix bug #20961 - add KeepDuplicates etc. to 4.0 as internal.
Since NET_4_0 and NET_4_5 share the same ToolsVersion (4.0) there seems no
way to distinguish the appropriate framework .targets file, so I ended up
to add the missing members as internal for 4.0.
2014-08-11 21:53:34 +09:00
Atsushi Eno d09be4600c [ms.build] Do not try to release threads upon finalization. 2014-08-11 21:53:33 +09:00
Marek Safar 11a3daa71d Merge pull request #1190 from esdrubal/encoder-convert
System.Text.Encoder convert
2014-08-11 10:50:03 +02:00
Zoltan Varga 6f3ad3b7a2 Merge pull request #1201 from crisdut/fix-win-mono-dependencies
Adding the mutex header file dependency
2014-08-08 22:46:36 +02:00
João Matos 1bff9d890f Fixed Path.GetFullPath to work correctly when the current path is '/'.
Fixes xambug #833.
2014-08-08 19:03:39 +01:00
João Matos 90ccde72e5 Merge pull request #1196 from tritao/master
System.IO.Compression.FileSystem implementation
2014-08-08 18:42:29 +01:00
João Matos f17d714385 Implemented System.IO.Compression.FileSystem. 2014-08-08 18:40:01 +01:00
Armando C. Dutra 2549d18cb5 adding the mutex header file dependency 2014-08-08 04:29:40 -03:00
Alexander Köplinger 48e112d652 [Cleanup] Removed TARGET_JVM
It was once part of a special Java target profile, but this is no longer used today.
2014-08-08 03:28:34 +02:00
Zoltan Varga 5c59fee91f [jit] Reorganize the locking in mono_jit_compile_method_inner, the domain lock already makes the code lookup+insert atomic, no need to do more work inside the jit code hash lock. Also lock jit_code_hash in mono_jit_free_method (). 2014-08-08 02:17:54 +02:00
Zoltan Varga 1e8a5b2809 [jit] Avoid taking the loader lock in mono_jit_compile_method_inner (), it shouldn't be needed any more. 2014-08-08 02:09:06 +02:00
Zoltan Varga 766e8c3504 [sdb] Avoid asserting when a cattr cannot be loaded. Fixes #21653. 2014-08-08 00:37:04 +02:00
Alexander Köplinger c685b21764 [Cleanup] Removed files that imported Java namespaces
They were once part of a special Java target profile, but this is no longer used today.
2014-08-07 23:01:53 +02:00
Alexander Köplinger 5f4b8c2cf4 [Cleanup] Removed JavaEE csproj and sln files
They were once part of a special Java target profile, but this is no longer used today.
2014-08-07 23:01:53 +02:00
Alexander Köplinger 4165d879cd [Cleanup] Removed net_1_1_java from Makefiles
It was once part of a special Java target profile, but this is no longer used today.
2014-08-07 23:01:52 +02:00
Alexander Köplinger 31daf92e72 [Cleanup] Removed net_1_1_java*.sources files
They were once part of a special Java target profile, but this is no longer used today.
2014-08-07 23:01:52 +02:00
Alexander Köplinger a8b2f07578 [Cleanup] Removed .jvm.cs files that are no longer used
They were once part of a special Java target profile, but this is no longer used today.
2014-08-07 23:01:51 +02:00
Marek Safar 76c34a1574 [System] Disable failing test 2014-08-07 20:01:46 +02:00
Marek Safar f5629c16e0 [mcs] null propagating operator and expressions which cannot be null 2014-08-07 16:54:57 +02:00
Zoltan Varga 98bbf8512a [runtime] Fix Process.PrivateMemorySize64 etc. on ios. Fixes #21882. 2014-08-07 14:56:51 +02:00
Marek Safar c6ae57fa19 [mcs] null propagating operator and extension methods 2014-08-07 14:25:07 +02:00
Zoltan Varga 0f1a427b67 [jit] Fix enum->int casts in gsharedvt code. Fixes #21893. 2014-08-07 13:56:56 +02:00
Marek Safar d3553fefdc [mcs] null propagating operator with nested receiver 2014-08-07 11:04:16 +02:00
Marcos Henrich 631f3685bb Added classes EncodingEncoder and EncodingDecoder.
EncodingEncoder and EncodingDecoder override Encoder.Convert.
The Convert overrides allow retrieval of chars/bytes buffers with the same size as .NET.
2014-08-07 09:28:44 +01:00
Marek Safar ed065cd04d Merge pull request #1199 from esdrubal/packurihelper
PackUriHelper
2014-08-07 10:25:47 +02:00
Marcos Henrich 9d781928b2 Added argument validations to ComparePackUri an ComparePartUri. 2014-08-07 09:10:53 +01:00
Marcos Henrich d3d078eb51 Changed Check.PartUriIsValid to throw ArgumentException. 2014-08-07 09:09:22 +01:00
Marcos Henrich 33f0c427f7 Removed [Category("NotWorking")] from PackUriHelperTests.
CompareInvalidTest is still not working because .NET PackUriHelper.ComparePackUri is doing something that uses Uri and throws an exception whereas Mono is not.
2014-08-07 09:02:49 +01:00
Marek Safar bdd8f8212f Merge pull request #1198 from chriswebb/master
Fixed issue where XmlReflectionImporter unable to handle XmlEnums with colons
2014-08-07 08:18:30 +02:00
Chris Webb 1a3ec8c3b3 Fixed issue related to fully qualified namespaces being used for XmlEnumAttribute values. 2014-08-07 06:15:55 +00:00
Marek Safar 5398bc14a4 Merge pull request #1197 from akoeplinger/remove-csproj
[Cleanup] Removed a bunch of superfluous .csproj and .sln files
2014-08-07 07:44:36 +02:00
Alexander Köplinger 0450000dc4 [Cleanup] Removed a bunch of superfluous .csproj and .sln files
Most of these files weren't updated in the last >5 years and serve no purpose today, so they only clutter the repository.
2014-08-06 18:02:30 +02:00
Shay Rojansky 416c5e9df4 Correct code review comments on test 2014-08-06 17:37:51 +03:00
Marek Safar e64af2edbf Merge pull request #1195 from akoeplinger/fix-uri-with-digits
[System] Fix parsing of URI schemes with digits
2014-08-06 15:11:53 +02:00
Alexander Köplinger 636d9c3186 [System] Fix parsing of URI schemes with digits
Initializing an Uri previously throwed an exception when the URI scheme contained a digit (e.g. net.p2p).
The loop was missing a digit check, similar to https://github.com/mono/mono/blob/1f1dc988ad7b165603a1175bf0a92156c4372c43/mcs/class/System/System/Uri.cs#L767
2014-08-06 14:53:01 +02:00
Marek Safar 1f1dc988ad Merge pull request #1168 from esdrubal/iriparsing
IriParsing
2014-08-06 12:47:14 +02:00
Marek Safar e003c4e8f9 Merge pull request #1193 from esdrubal/decimal-round
Decimal.Round trailing zeros
2014-08-06 12:41:39 +02:00
Marek Safar 6b32f6951a Merge pull request #1180 from akoeplinger/no-net40-in-make-check
Don't run net_4_0 tests during "make check"
2014-08-06 12:40:30 +02:00
Marek Safar ba1842208d [mcs] switch statement with constant block at first label. Fixes #21805 2014-08-06 09:52:48 +02:00
Alexis Christoforides adf5717203 Added MonoString<->UTF-32 conversion helper functions. 2014-08-05 19:58:51 -04:00
Zoltan Varga 571df7ac2b Fix the build. 2014-08-06 01:33:48 +02:00
Zoltan Varga abde1a90c6 [runtime] Remove unused critical-sections files. 2014-08-05 23:52:07 +02:00
Zoltan Varga ee230d0620 [runtime] Use the mono_mutex types/functions instead of CriticalSection's. 2014-08-05 23:36:06 +02:00
Zoltan Varga 8fe4231357 [jit] Use the mono_mutex types/functions of CriticalSection's. 2014-08-05 23:21:14 +02:00
Dave Dunkin cd364b4374 Add test for Regex RTL substring matching. 2014-08-05 08:51:38 -07:00
Marcos Henrich 60022096d1 Decimal.Round output no longer keeps trailing zeros. 2014-08-05 14:00:12 +01:00
Marcos Henrich 880f273f56 Test Decimal.ToString after rounding with trailing zeros. 2014-08-05 13:58:07 +01:00
Paolo Molaro ff983a6a9e [profiler] Increase the number of maximum and default frames in backtraces. 2014-08-05 13:15:17 +02:00
Zoltan Varga 2897dba601 [jit] Emit OP_FMOVE instead of OP_MOVE for r4 arguments in hard float mode on arm. 2014-08-05 13:02:58 +02:00
Paolo Molaro d5bce925f0 [runtime] Don't assert when loading a generic methodspec with 0 arity (xambug #19097). 2014-08-05 11:52:35 +02:00
Sasha Kotlyar 76a25717e7 Miscellaneous changes per review 2014-08-04 19:15:10 -04:00
Martin Potter 1af8016a5c Regex fixes for substring parsing. 2014-08-04 14:42:35 -07:00
Dave Dunkin 509863e570 Add test for Regex.Match with anchors on a substring. 2014-08-04 14:42:34 -07:00
Rodrigo Kumpera 8da27c63c3 Merge pull request #1066 from esdrubal/bug19313
Changed DeflateStream to stop reading base_stream sooner. Fixes #19313.
2014-08-04 12:29:43 -04:00
Rodrigo Kumpera 9e91c36e1c Merge pull request #1063 from esdrubal/bug18482
Resets all private key values on RSAManaged.ImportParameters. Fixes #18482.
2014-08-04 12:28:50 -04:00
Marek Safar 3bd87b33c5 [mcs] null propagating operator on index expressions 2014-08-04 17:33:43 +02:00
Zoltan Varga 04ae3b8a2e [runtime] Remove unneccesary locking from some metadata functions. 2014-08-04 17:29:04 +02:00
Marcos Henrich 97e5bfb498 Test Encoder.Convert and UTF8Encoder.Convert behaviors.
Added class ExposedEncoder to test the virtual method Encoder.Convert behavior.
Test UTF8Encoder.Convert override.
2014-08-04 15:26:53 +01:00
Zoltan Varga e98a83ec63 [runtime] Initialize klass->supertypes properly for dynamic classes. 2014-08-03 22:09:51 +02:00
Sasha Kotlyar a66732c039 [TimeZoneInfo] Fix issue with some floating DST transition times creating invalid DateTime values, and implement ToSerializedString and FromSerializedString.
This change is released under the MIT license.
2014-08-03 15:25:43 -04:00
Marek Safar cc90ac0be7 [system.xml] Dispose XmlReader using correct value. Fixes #21771 2014-08-03 19:10:45 +02:00
Marek Safar 76875075df [mcs] decimal constants modulo folding. Fixes #21743 2014-08-03 18:55:53 +02:00
Marek Safar c8796a126d [mcs] null propagating operator cannot work on pointer types 2014-08-03 18:55:53 +02:00
Joel Martinez da44df5a50 [mdoc] Changes to support new-style iOS API:
- the dropns flag now lets you define a namespace that is dropped in a new version of the assembly during update.
- the ntypes flag lets you tell the update command that certain methods are now using native types, and as such will attempt to match with old types in order to preserve documentation.
- the preserve flag will avoid removing members. This is to avoid dropping documentation for members that changed from one version of the framework to another new-style version (ie. iOS).
2014-08-02 19:48:11 -04:00
Joel Martinez be7502c908 [monodoc] Changes to support new-style iOS documentation:
- Fixed bug in creating CREF strings.
- Refactored XML file processing for customization during new style iOS assembly. This was done through the new file source interface, which lets you use dependency injection to customize the process.
- Added the ability to rewrite CREF references when assembling docs that use native types. Also, the ability to handle dropped namespaces.
2014-08-02 19:48:11 -04:00
Marek Habersack 59258ea3f0 Turns out some devices can have network interfaces without names.
If we encounter such a device we assign it an empty name followed by index number, so that we can
put any number of such devices in the dictionary and report them to the user.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=21741
2014-07-31 19:45:05 -04:00
Mark Probst 2169799f5a [sgen] File size limit for binary protocols.
We can now pass a file size limit to the `binary-protocol` option.  It will
create numbered binary protocol files, and only keep the last two around.
This is useful for cases where the only way to reproduce a bug is through
a long run that would otherwise create a protocol that's much too big.
2014-07-31 13:29:42 -07:00
Mark Probst da8f1879ad [sgen] Debug option for clear-at-tlab-creation nursery clear policy.
With the debug policy, we do clear at TLAB creation, but at GC time, whenever
we would clear with `clear-at-gc`, instead of not clearing, we fill with 0xff.
2014-07-31 13:29:36 -07:00
Zoltan Varga 597a3e8964 [jit] Avoid making generic calls from gsharedvt methods normally, go through the rgctx infrastructure instead. Fixes #21677. 2014-07-31 21:56:08 +02:00
Marek Safar c6685c1953 [mcs] Update codegen for boolean loads. Fixes #21685 2014-07-31 18:40:19 +02:00
Marek Safar ac9e90a89d [mcs] null coallescing operator can end up working on value types 2014-07-31 16:43:58 +02:00
Zoltan Varga c3a3132005 Merge pull request #1184 from directhex/kfreebsd
Support for GNU/kFreeBSD
2014-07-31 16:40:36 +02:00
Zoltan Varga 90c38a6b9e Merge pull request #1183 from directhex/xinerama
Don't do the soname checking dance for Xinerama.
2014-07-31 16:38:23 +02:00
Marek Safar 30407b77ce [xbuild] Fix handling of reference aliases 2014-07-31 15:21:46 +02:00
Jo Shields 056cc3be24 Define PLATFORM_GNU which covers any OS with GNU userland.
This define covers kFreeBSD, not just Linux. This is required because
the error which 120d194d10 works around is
a GNU problem, not a Linux problem, so causes FTBFS on kFreeBSD.
2014-07-31 12:04:59 +01:00
Jo Shields 0fe5be9fd8 Use host_win32 not platform_win32 in kfreebsd defines 2014-07-31 11:58:47 +01:00
Jo Shields edfbc1d848 Don't do the soname checking dance for Xinerama.
Xinerama has only ever had a soname of 1.

Checking for 1, 2, and 3 is just weird and pointless. And by not using a
default value, we duplicate the bug which add24aaa1 fixed.
2014-07-31 11:45:14 +01:00
Jo Shields 164ead5fb1 Fix warning message when libX11.so.* are not found.
We complain that we can't find "X development files", but the reverse
is true - if we had X development files, we'd find libX11.so (which
we aren't looking for). What we look for (and find) are the runtime files.
2014-07-31 11:45:13 +01:00
Jo Shields 1f513847b2 Support for GNU/kFreeBSD.
GNU/kFreeBSD is an experimental OS provided by the Debian project, consisting
of a FreeBSD kernel and GNU userland/libc. For a small number of cases, this
offers advantages over a more common GNU/Linux combination, such as fast
in-kernel support for ZFS storage.

This patch changes various ifdefs, either using __FreeBSD_kernel__ where a
trait from the kernel is what matters, or __GLIBC__ where a trait from the
C library matters.

This patch set has been carried downstream, in one form or another, since
1.2.3.1-1.

https://bugzilla.novell.com/show_bug.cgi?id=321634
2014-07-31 11:44:51 +01:00
Marek Safar 13f4ba52e0 [mcs] Fixes bootsrap with older mcs 2014-07-31 11:53:09 +02:00
Marek Safar e7bf6d81ea [mcs] Member access null propagating operator 2014-07-31 11:06:52 +02:00
Marek Safar 2915003696 [mcs] Finalizers cannot use expression_block syntax 2014-07-31 11:06:52 +02:00
Marek Habersack 303e42b130 Implement the Mono side of Android support for NetworkInterface.GetAllNetworkInterfaces ()
Added code to call Xamarin.Android internal implementation of getifaddrs/freeifaddrs to provide us
with the required information to fulfill the request.

Added a handful of Linux ARP hardware IDs which are considered to be tunnel devices and which may occur
on Android devices.

Part of fix for https://bugzilla.xamarin.com/show_bug.cgi?id=1969
2014-07-30 18:22:33 -04:00
Alexis Christoforides cd59827c22 Bump Mono version -> 3.8.1 2014-07-30 14:52:33 -04:00
Alexander Köplinger d16413148e Don't run net_4_0 tests during "make check"
As @marek-safar noted in mono@cf4f10e#commitcomment-7128403, the IL code for the 4.0 profile is never used
for running (the assemblies are just built for having metadata), so it makes no sense to execute 4.0 tests during "make check"
2014-07-30 18:58:08 +02:00
Zoltan Varga 81867287f8 [xbuild] Disable some tests which fail on wrench. 2014-07-30 17:41:51 +02:00
Ludovic Henry 44214ee4de [PLinq] Avoid cache thrashing of locals array when looping over enumerator 2014-07-30 11:40:30 -04:00
Zoltan Varga 21112244e0 [jit] Fix another native-types problem. Hopefully fixes #21670 and #21636. 2014-07-29 23:59:58 +02:00
Zoltan Varga af066033c6 Merge pull request #1181 from directhex/master
Delete assemblies from external/ when building "make dist" tarballs
2014-07-29 23:42:33 +02:00
Marek Habersack 81c30e4e24 Do not assume the GetCurrentTimeZone method exists in Mono.Android
Not checking whether the method exists caused a null reference exception in CreateDelegate.

Fixes bug https://bugzilla.xamarin.com/show_bug.cgi?id=21603
2014-07-29 15:30:46 -04:00
Jo Shields debb0c7af2 Delete assemblies from external/ when building "make dist" tarballs 2014-07-29 12:01:58 -04:00
Marek Safar cb34d86717 Merge pull request #1178 from dougrathbone/master
Bug fix caused by Dispose failing because 'Initialize' method throws exception
2014-07-29 13:44:46 +02:00
Zoltan Varga 768bd9bb2c Fix 91b224d004. 2014-07-29 11:56:27 +02:00
Zoltan Varga 91b224d004 [bcl] Disable some tests which are expected to fail in mt. 2014-07-29 11:48:02 +02:00
Marcos Henrich 1c815b18aa Uri.ToString now returns registered parser components when possible. 2014-07-29 07:46:56 +01:00
Marcos Henrich 6d7be6df27 ParseNoExceptions is now using registered parsers when possible. 2014-07-29 07:22:43 +01:00
Marcos Henrich 9f34f2d7f0 TryParseComponent returns when the scheme has a registered parser. 2014-07-29 07:17:21 +01:00
Marcos Henrich 17aeeb761f Removed parameter parser from UriParseComponents.ParseComponents. 2014-07-29 07:14:55 +01:00
Rodrigo Kumpera e8a721a2ff [jit] Use alias information to eliminate explicit null checks. Fixes #21645. 2014-07-29 01:31:10 -03:00
Rodrigo Kumpera b6f9dff71c [jit] Handle second order aliases. Based on patch by Vlad Brezae.
In some cases, usually when dealing with IntPtr <> void* conversions, 2nd order aliases arises.

To handle them, first we consider the lowered load/stores for alias information, second
we iterate over handle globals/dce while aliases can still be eliminated.
2014-07-29 01:17:37 -03:00
Zoltan Varga d0d9b5706b [runtime] Initialize fields in MonoField:GetFieldOffset () if needed. Fixes part of #21604. 2014-07-29 02:47:26 +02:00
Marcos Henrich 095c0f8513 Changed some IriParsing behaviors to be platform behaviors. 2014-07-28 12:37:58 +01:00
Marcos Henrich e7604d6268 Added UriTestAux that tests non default IriParsing. Fixed Tests. 2014-07-28 12:36:28 +01:00
Rodrigo Kumpera 9d8be3d40c [runtime] Properly handle rethrow outside of catch blocks. Fixes #20412
Fix the verifier to fail a rethrow in a filter block.
Change the JIT to emit an exception instead of asserting.
2014-07-27 18:58:11 -03:00
Doug Rathbone bade84a5fc Fixing bug caused by Dispose failing because the Initialize method threw a CryptographicException before the private variables m_p, m_G, m_X could be set. 2014-07-27 12:21:37 -07:00
Marek Safar 91c346a3f6 Merge pull request #1176 from RyanMelenaNoesis/patch-1
Implement missing constructor
2014-07-25 23:27:07 +02:00
RyanMelenaNoesis dbe8dbd370 Implement missing constructor
http://msdn.microsoft.com/en-us/library/hh194482(v=vs.110).aspx
2014-07-25 16:07:55 -05:00
Marcos Henrich efdbd10e61 Refactored ifs into switches. 2014-07-25 14:47:54 +01:00
Marcos Henrich d2ac7759d8 Removed unnecessary parameter modifier ref.
No need of modifier ref because ParserState is not a value type.
2014-07-25 14:05:23 +01:00
Marcos Henrich 6b4da3d6c4 Added missing spaces. 2014-07-25 13:57:09 +01:00
Marcos Henrich 0ad1394bcb Call more appropriate string.TrimStart overload. 2014-07-25 13:54:29 +01:00
Marcos Henrich d9936a0c15 Parse methods are now chained in conjunction. 2014-07-25 13:52:47 +01:00
Marcos Henrich c89e7905c7 Refactored UriHelper.Reduce to use string.Split. 2014-07-25 13:31:57 +01:00
Marcos Henrich 507d10aaa1 Removed redundant code. 2014-07-25 13:29:39 +01:00
Marcos Henrich ab60fa30d3 Splited if to test % first. 2014-07-25 13:28:29 +01:00
Marcos Henrich aa71718828 UriHelper.HexEscapeMultiByte is now using StringBuilder. 2014-07-25 13:20:38 +01:00
Marcos Henrich 9d7d96f594 Class UriHelper is now static. 2014-07-25 13:17:51 +01:00
Marcos Henrich a710d0b8ec Changed string operations to use StringComparison.Ordinal. 2014-07-25 13:14:16 +01:00
Marcos Henrich 351a689463 Removed redundant IriParsing init and changed if to else if. 2014-07-25 11:57:07 +01:00
Marcos Henrich d9ad2fd413 Removed redundant initializations. 2014-07-25 09:41:19 +01:00
Marcos Henrich d7d72f9a81 Control chars with invalid escape are no longer unescaped in 2.0. 2014-07-25 09:08:07 +01:00
Marcos Henrich dd88b4cc18 Results location is now set from defines NET_X_X. 2014-07-25 08:42:47 +01:00
Martin Baulig 288489d637 [http]: Correctly handle partial chunk sizes; fixes #20583. 2014-07-25 00:37:16 +02:00
Marcos Henrich 565432ae1f Removed bad LocalPath testing. 2014-07-24 18:21:51 +01:00
Marcos Henrich fc847d6e69 Test invalid utf8 encodings. 2014-07-24 18:12:09 +01:00
Marcos Henrich 9092b7f27f Added UriPermutationsTest.PercentageEncoding_AbsolutePath. 2014-07-24 18:04:40 +01:00
Marcos Henrich 695fb400b3 Added UriPermutationsTest.PercentageEncoding_Unescape. 2014-07-24 18:02:48 +01:00
Marcos Henrich 3b75fd9dea Updated UriBuilderTest.IPv6_Host with IriParsing behavior. 2014-07-24 17:30:14 +01:00
Marcos Henrich e95021f029 Custom schemes '\' are now replaced with '/' on windows paths. 2014-07-24 17:23:05 +01:00
Marek Habersack 6034d4ad85 Use Android-specific code to get the current system time zone 2014-07-24 18:06:14 +02:00
Marek Safar 056a487386 [System.ComponentModel.Composition] Remove ReadOnlyDictionary. It's not used in 4.5 profile (it implements different interfaces compare to public ReadOnlyDictionary anyway) 2014-07-24 13:51:35 +02:00
Marcos Henrich 1aa8771d3f Changed Uri.Unescape to use UriHelper.FormatAbsolute. 2014-07-24 12:41:06 +01:00
Marcos Henrich d6b7409e73 Invalid escapes are left untouched on .NET 4.0 and higher. 2014-07-24 12:34:11 +01:00
Marcos Henrich de7e103073 Added HexUnescapeMultiByte overload with invalidEscape out param.
Invalid escapes are left untouched on .NET 4.0 and higher.
2014-07-24 12:31:53 +01:00
Marcos Henrich 21e2b4db20 Added missing FormatFlag.NoSlashReplace condition. 2014-07-24 12:27:47 +01:00
Marcos Henrich 4c5add3387 Added FormatFlag.NoReduce. 2014-07-24 12:26:46 +01:00
Marek Safar 9a53dd4e91 [mcs] Implements expression bodied members 2014-07-24 13:08:37 +02:00
Zoltan Varga 120d194d10 [runtime] Disable runtime unit tests on linux, because it cannot be linked due to circular dependencies between libraries. Fixes #21520. 2014-07-23 13:00:36 -04:00
Marek Safar c52d085ef4 [mcs] Better betterness for ambiguous lambda expressions 2014-07-23 15:48:44 +02:00
Zoltan Varga a69cc775ea Merge pull request #1174 from rhapsodyn/patch-1
fix a typo in comment
2014-07-23 12:58:17 +02:00
Marcos Henrich 59ca31f5d2 Uri.Merge ignores on 2.0 base filename when relative has a query. 2014-07-23 11:46:51 +01:00
Marcos Henrich de0ac0589a On .NET 4.0 and higher avoid unescaping of user escaped Uri. 2014-07-23 10:53:23 +01:00
Marcos Henrich 1ae9ae3b08 Format is now setting FormatFlags.HasUriCharactersToNormalize. 2014-07-23 10:48:30 +01:00
Marcos Henrich ff8156b040 Fixed UriHelper.Format to unescape surrogate char only when needed. 2014-07-23 10:40:07 +01:00
Marcos Henrich fffa1dadfa Added FormatFlag.UserEscaped to Uri.LocalPath. 2014-07-23 10:30:16 +01:00
rhapsodyn 8af2417115 fix a typo in comment 2014-07-23 16:17:36 +08:00
Marek Safar 408e394426 [corlib] Allow reading serialized delegate format from pre 2.0 era 2014-07-23 10:15:53 +02:00
Marek Safar cf4f10ef51 Update test binary data 2014-07-23 10:15:16 +02:00
Marek Safar b0246f004f Add extra test for 027ff81512 2014-07-23 09:20:34 +02:00
Marek Safar 027ff81512 [corlib] Fix multicast delegates serialization to handle curried delegates and more than 1 subscriber 2014-07-22 20:33:11 +02:00
Marek Safar 1d6529de70 [mcs] Pickup params modifier from base member for overload verification as well 2014-07-22 18:52:23 +02:00
Marcos Henrich 9bcae25144 Improved Uri.Merge.
Merge is now using UriParseComponents and UriHelper.Reduce.
2014-07-22 16:13:53 +01:00
Marcos Henrich 33f653951c UriHelper.Reduce visibility is now internal. 2014-07-22 16:05:54 +01:00
Marcos Henrich 4e925a2809 Fixed missing "/" after reduce of paths ending with "/..". 2014-07-22 16:01:13 +01:00
Marek Safar 7edcd42a15 [mcs] Use closed delegate over static generated methods from anonymous methods 2014-07-22 14:18:48 +02:00
Marek Safar 6e150f6bf3 [mcs] Effective base class can include inherited types. Fixes #21390 2014-07-22 14:13:15 +02:00
Marek Safar 71bd92e047 [mcs] Handle duplicate resume point registration. Fixes #21387 2014-07-22 13:41:10 +02:00
Marcos Henrich 16db13ed87 Refactored Uri.ParseNoExceptions to use UriParseComponents. 2014-07-22 10:58:30 +01:00
Rolf Bjarne Kvinge 2afbbedd63 Disable a few tests that don't compile without SRE. 2014-07-22 11:54:11 +02:00
Marcos Henrich a4dc63385d Set isUnc to true for file scheme on windows. 2014-07-22 10:36:47 +01:00
Marek Safar 30913d31b0 Fixes broken test 2014-07-22 10:28:38 +02:00
Shay Rojansky 566646719f Test uses SQLite in-memory DB for test
Also spaces to tabs
2014-07-22 05:56:33 +00:00
Marcos Henrich 16cd5535c9 Improved UriParseComponents.
Added Uri.ParseNoException error cases.
Changed to behave as Uri.ParseNoException.
2014-07-21 23:22:01 +01:00
Marcos Henrich e87c78c022 Setting UriElements.isAbsoluteUri, isUnc, isUnixFilePath, scopeId. 2014-07-21 23:16:47 +01:00
Marcos Henrich 4d610d50db Added UriElements.isAbsoluteUri, isUnixFilePath, isUnc, scopeId. 2014-07-21 23:07:19 +01:00
Marcos Henrich e07d36786b Added parameter UriParser to UriParseComponent. 2014-07-21 23:05:15 +01:00
Rodrigo Kumpera 04c3d5dff4 [corlib] Add regression test for #21388. 2014-07-21 18:55:43 -03:00
Rodrigo Kumpera 1994095049 [runtime] When parsing a method header, ensure we pass any available generic context. Fixes #21388.
We need to pass the right generic context to the method parsing so local variables with
generic argument types get the owner properly set.

In addition to that, harden the icall in case the owner is not set.
2014-07-21 18:55:43 -03:00
Rodrigo Kumpera 9b4293c035 [corlib] Fix regression in Delegate::Equal found by gtest-etree-01. 2014-07-21 18:55:42 -03:00
Marcos Henrich 02d383f202 Improved IPv6 parsing.
Parsing was failing when a port was specified after IPv6 address. ie: "http://[::1]:8080"
2014-07-21 21:57:51 +01:00
Zoltan Varga 2d3d1787a3 [jit] Fix the DISABLE_JIT build. 2014-07-21 22:32:17 +02:00
Marcos Henrich beca8d580c UriParseComponents is now parsing Uri port as an int. 2014-07-21 20:32:23 +01:00
Marek Safar fa19bfd400 [corlib] Tweak Dictionary initial capacity to be more conservative. Fixes #21375 2014-07-21 20:35:14 +02:00
Marek Safar 3dfffa82d9 Merge pull request #1173 from Serguzest/upstream
wrong behaviour in ClaimsIdentity's constructor
2014-07-21 20:22:43 +02:00
Serguzest 62569f1a1c wrong behaviour in ClaimsIdentity's constructor
claims must be added regardless of identity parameter
Since constructors are chained in that class,  this wrong behaviour causes chained trouble of claims to be never added
2014-07-21 17:36:43 +00:00
Zoltan Varga fd12271ce3 [arm] Fix native types support in the dyn call code on arm. 2014-07-21 19:14:33 +02:00
Alexis Christoforides d1a36ddbd9 [appdomain] Allocate core AppDomain objects with mono_object_new_pinned().
The objects end up being pinned anyway, but in SGen's case they are placed in the nursery, creating permanent fragmentation.
2014-07-21 11:36:03 -04:00
Marek Safar 2907aa0417 [mcs] Initializers with parameters scope and primary constructors 2014-07-21 17:12:10 +02:00
Marek Safar 735f225345 [bcl] Remove old projects 2014-07-21 14:14:12 +02:00
Jeffrey Stedfast 8297563629 [System.Web] Oops, there really is a .moov file extension 2014-07-21 06:21:50 -04:00
Shay Rojansky c0d6c47c6b Added test for DataRow error 2014-07-21 09:10:08 +00:00
Rodrigo Kumpera 60c498279e [corlib] Add regression test for #21196. 2014-07-20 22:57:56 -03:00
Rodrigo Kumpera 56fb85195f [corlib] Handle closed-over-null delegates created with IL when using InvokeDynamic. Fixes #21196.
The previous fix to handle curried delegates with DynamicInvoke did not correctly handle
those create with IL (in contrast to Delegate.CreateDelegate), as they don't hit any managed code.

The solution is to always require DelegateData to be filled for InvokeDynamic, if not, lazily
calculate it.
2014-07-20 22:57:56 -03:00
Jeffrey Stedfast 0237ddc8e0 [System.Web] Fixed some mime types 2014-07-20 20:54:16 -04:00
Zoltan Varga eb566d04da [runtime] Avoid loading marshal info for types without field marshallers when calling FieldInfo:get_marshal_info (). 2014-07-21 01:27:27 +02:00
Shay Rojansky 4c31accaca Fix DataRow error management
DataRow's RowError is supposed to be String.Empty to indicate
no errors, but is sometimes wrongly set to null, falsely indicating
errors. Fixed to be String.Empty.
2014-07-20 15:48:21 +03:00
Zoltan Varga effa4c07ba [runtime] Add method_is_dynamic () inline function to allow code to be optimized away when DISABLE_REFLECTION_EMIT is defined. 2014-07-19 23:42:23 +02:00
Zoltan Varga 3a786664d7 [runtime] Add image_is_dynamic ()/assembly_is_dynamic () inline functions to allow code to be optimized away when DISABLE_REFLECTION_EMIT is defined. 2014-07-19 22:28:22 +02:00
Marek Safar 6136fa0f0a Revert "[mcs] Initializers with parameters scope and primary constructors"
This reverts commit 221b9c920d.
2014-07-19 22:02:15 +02:00
Marek Safar 221b9c920d [mcs] Initializers with parameters scope and primary constructors 2014-07-19 17:16:13 +02:00
Marek Safar 16a37dba07 [mcs] Less cascading errors 2014-07-19 17:16:12 +02:00
Zoltan Varga f49ca11375 Revert "[runtime] Force inlining of membar functions."
This reverts commit 4935a15fc6.

Revert this as it is causing a huge amount of warnings.
2014-07-19 16:32:14 +02:00
Zoltan Varga 262ef7eb34 [bcl] Increase a timeout to fix a corlib+llvm test failure. 2014-07-17 23:15:49 +02:00
Zoltan Varga 472240a3a2 [runtime] Add a mono_reflection_assembly_get_assembly () public api function to get a MonoAssembly* from a System.Reflection.Assembly object. 2014-07-17 22:27:59 +02:00
Marcos Henrich 37dbbb2172 UriParser now appends '/' to Uri path when delimiter is '://'. 2014-07-17 18:57:33 +01:00
Marcos Henrich add9f6a2d7 Changed property IriParsing visibility to internal. 2014-07-17 18:43:25 +01:00
Joao Matos 896ceb1d9a Fixed MSVC build by explicitly providing "ssize_t". 2014-07-17 18:22:58 +01:00
Marcos Henrich adee464395 Replaced ToLower usage with ToLowerInvariant. 2014-07-17 18:15:30 +01:00
Marcos Henrich 88af5f54e7 Changed character comparison to a disjunction of equalities. 2014-07-17 18:11:56 +01:00
Zoltan Varga dd397d562e Bump required windows version to xp sp2. 2014-07-17 18:38:08 +02:00
Zoltan Varga 58afe69070 Fix the windows build. 2014-07-17 18:37:09 +02:00
Zoltan Varga f4175ebd98 Fix the windows build. 2014-07-17 18:11:32 +02:00
Zoltan Varga f0c469f167 [jit] Fix some build problems when cross compiling. 2014-07-17 17:51:52 +02:00
Marcos Henrich b8e2fad391 Moved s_IriParsing initialization and removed volatile modifier. 2014-07-17 16:17:16 +01:00
Rodrigo Kumpera a06fd81271 [jit] Move runtime_invoke_hash to use the concurrent hashtable. Big wins on TP workloads. 2014-07-17 11:01:48 -04:00
Rodrigo Kumpera 77cc06ffb3 [runtime] Move field_cache to use the concurrent hashtable as it was showing up on profiling. 2014-07-17 11:01:06 -04:00
Rodrigo Kumpera 9eeb7f1de0 [runtime] Add tests for concurrent hashtable. 2014-07-17 11:00:19 -04:00
Rodrigo Kumpera 4157b0d81c [runtime] Add a lock-free read hashtable. 2014-07-17 10:52:36 -04:00
Rodrigo Kumpera 4935a15fc6 [runtime] Force inlining of membar functions. 2014-07-17 10:50:51 -04:00
Marcos Henrich 1664692ddd Added TryParseComponent to UriParseComponent. 2014-07-17 09:21:11 +01:00
Alexis Christoforides d959941265 Revert "Reimplemented much of the kqueue-based file watcher so that watching subdirectories works."
This reverts commit fa9bbe1487.
2014-07-16 17:40:22 -04:00
Alexis Christoforides d0d774479b Revert "Revert some whitespace changes."
This reverts commit dd19aacb90.
2014-07-16 17:40:19 -04:00
Alexis Christoforides a386b772f7 Revert "Add a test for Creation event on FileSystemWatcher."
This reverts commit 66416d2655.
2014-07-16 17:40:11 -04:00
Stephen McConnel f5f2eb11b8 Fix error in tooltip display for ListView.ShowGroups
This fixes Xamarin bug 21346 " SWF.ListView does not handle item
tooltips when Groups are used".
2014-07-16 17:27:21 -04:00
Cody Russell 66416d2655 Add a test for Creation event on FileSystemWatcher. 2014-07-16 17:27:21 -04:00
Cody Russell dd19aacb90 Revert some whitespace changes. 2014-07-16 17:27:21 -04:00
Cody Russell fa9bbe1487 Reimplemented much of the kqueue-based file watcher so that watching subdirectories works.
https://bugzilla.xamarin.com/show_bug.cgi?id=16259
2014-07-16 17:27:20 -04:00
Marcos Henrich 156c7ce52a ParseQuery is now skipped if scheme does not support query. 2014-07-16 14:40:33 +01:00
Marcos Henrich 3e9e2c5fd3 Improved ParseHost of files and IpV6. 2014-07-16 14:32:39 +01:00
Marcos Henrich 6b8a3ac105 Moved scheme delimiter parsing into own method. 2014-07-16 14:12:14 +01:00
Marcos Henrich eb60e33d00 Added Unix and Windows file paths parsing. 2014-07-16 13:53:22 +01:00
Marcos Henrich 42482d540f Added UriKind and String error to UriParseComponent.ParserState.
UriKind was added so Relative Uri can be parsed by UriParseComponent.ParseComponents.
String error was added so a error can be returned when an invalid Uri is provided.
2014-07-16 13:45:04 +01:00
Zoltan Varga d1818f6e35 Merge pull request #1164 from nlhepler/patch-1
Guess base for mono-sgen and -boehm equivalently
2014-07-16 12:48:12 +02:00
Marek Safar f20d61de40 [mcs] Make primary constructor body parsing more error resilient 2014-07-16 10:28:01 +02:00
Marek Safar e56375a2a2 [mcs] Remove backing field from primary constructors 2014-07-16 09:57:18 +02:00
Lance Hepler fe315d71a4 mint and monodiet are no longer built 2014-07-15 20:00:47 -07:00
Lance Hepler 7626a539b1 Guess base for mono-sgen and -boehm equivalently 2014-07-15 18:35:51 -07:00
Zoltan Varga 66ca91f10b [jit] Clean up the libgc configuration code in configure.ac. 2014-07-15 23:15:10 +02:00
Marcos Henrich e9ccb6d1b4 Replaced Uri.LocalPath Unescape uses by UriHelper.FormatAbsolute. 2014-07-15 19:30:00 +01:00
Marcos Henrich f9ab3ac8de Added FormatFlag.NoSlashReplace. 2014-07-15 19:24:48 +01:00
Marcos Henrich d29b9c93f5 Host unicode characters are no longer escaped. 2014-07-15 19:20:39 +01:00
Marcos Henrich 2aac5c54aa IpV6 Host characters are no escaped or unescaped. 2014-07-15 19:08:06 +01:00
Marcos Henrich a0304b0ab9 Scope id is now removed from IpV6 Host. 2014-07-15 18:41:52 +01:00
Marcos Henrich a4089ba0ef Uri.Host is now escaped with UriHelper.FormatAbsolute. 2014-07-15 18:39:06 +01:00
Zoltan Varga 511a8367ad Merge pull request #1162 from DavidKarlas/endInvokeWithResult
[Mono.Debugger.Soft] Added methods EndInvokeMethodWithResult to all mirrors
2014-07-15 15:41:10 +02:00
Marek Safar 6374d49610 [mcs] More work on primary constructors 2014-07-15 10:59:52 +02:00
David Karlaš 10f73cb8b4 [Mono.Debugger.Soft] Added methods EndInvokeMethodWithResult to all mirrors
StructMirror also set overrides fields of structure in case InvokeMethod was called with InvokeOptions.ReturnOutThis option set
2014-07-15 09:42:29 +02:00
Zoltan Varga d795d17c3d Enable sgen on mingw64. 2014-07-15 00:46:24 +02:00
Zoltan Varga 853e9a1ba0 Revert "Enable sgen on mingw64."
This reverts commit 3cd09d1d84.

Revert this as it reverts unrelated changes.
2014-07-15 00:43:20 +02:00
Zoltan Varga d852e58bdc [jit] Remove some unneccesary ifdefs from the amd64 backend. 2014-07-14 22:53:11 +02:00
Zoltan Varga 80e6cdc3ca [jit] Remove more dead code. 2014-07-14 22:53:11 +02:00
Aaron Bockover b62eebc2eb [mcs] eval.cs: remove CWL that snuck in with my last commit 2014-07-14 16:41:16 -04:00
Zoltan Varga 55a8a2c3a9 [jit] Remove some dead code. 2014-07-14 22:31:33 +02:00
Aaron Bockover 61ef51978b [mcs] eval.cs: add ValueModificationHandler delegate to be more clear 2014-07-14 16:25:02 -04:00
Zoltan Varga 49d68ea47c [jit] Fix support for tls entries with offset >= 64 on winx64. 2014-07-14 21:31:26 +02:00
Zoltan Varga 9b5b116083 Fix the build. 2014-07-14 20:43:27 +02:00
Rodrigo Kumpera 9503cfad87 Merge pull request #1150 from ludovic-henry/pr17c-delegate-trampoline
[delegate] Improve trampoline caching
2014-07-14 14:40:38 -04:00
Zoltan Varga 8dfabbb582 [jit] Fix the objdump cmd line used on winx64. 2014-07-14 20:05:32 +02:00
Zoltan Varga 3cd09d1d84 Enable sgen on mingw64. 2014-07-14 20:03:53 +02:00
Zoltan Varga 16a3fcc3cc Fix the mingw64 build. 2014-07-14 20:03:36 +02:00
Zoltan Varga 1a604e7342 [jit] Use the generic lmf push/pop code on winx64. 2014-07-14 20:02:36 +02:00
Zoltan Varga d995399b40 [runtime] Avoid building libgc if its disabled. 2014-07-14 18:29:40 +02:00
Alexis Christoforides cdd3d2b7c7 Merge pull request #1064 from ranma42/fix-config-paths
Improve handling of lib paths for libMonoPosixHelper and libgdiplus. Fixes #18555.
2014-07-14 12:14:40 -04:00
Rodrigo Kumpera 6607fdf579 Merge pull request #1122 from PoppermostProductions/master
Added new mono_domain_set_config function; used to fix ConfigurationErro...
2014-07-14 10:54:50 -04:00
Marek Safar b8ac40d824 [mcs] Handling CreateStandardLiftedOperatorsTable for corlib without nullable type 2014-07-14 14:45:13 +02:00
Marek Safar e78be50cda [mcs] Arguments can be empty when reporting missing params argument. Fixes #21215 2014-07-14 11:22:27 +02:00
Marek Safar 276e8eb4f8 [mcs] Wrap exceptions in async state machine with no resume points 2014-07-14 11:22:27 +02:00
Marcos Henrich 65f103458b Fixed EscapeDataString and EscapeUriString behavior.
The methods have now the same behavior as .NET 4.5, 4.0 and 2.0.
2014-07-14 10:07:50 +01:00
Marcos Henrich 2f1b0a3494 Missing line from previous commit cc4fae8. 2014-07-14 09:32:57 +01:00
Zoltan Varga 85378c45be Revert "[runtime] Fix a win32 build failure, more remains."
This reverts commit 5c90d7cdba.

Revert this as it breaks the build.
2014-07-14 01:33:27 +02:00
Zoltan Varga 216f1b6c71 [jit] Remove an unneccesary line from the win32 tls_get implementation, it was setting SetLastError (). 2014-07-14 00:45:34 +02:00
Zoltan Varga c5ac00e6b7 [bcl] Fix build dependencies for the corlib vts tests. 2014-07-14 00:39:58 +02:00
Zoltan Varga ccb6f5b4de [runtime] Fix the --disable-boehm build on windows. 2014-07-13 22:51:40 +02:00
Zoltan Varga 673700f506 [jit] Enable support for tls offsets >= 64 on win32. 2014-07-13 22:46:21 +02:00
Zoltan Varga c10329d0aa [jit] Disable MONO_ARCH_ENABLE_MONO_LMF_VAR on win32, emit_push_lmf () uses a different method. 2014-07-13 22:44:25 +02:00
Zoltan Varga 1289b87cf8 [jit] Implement support for tls offsets >= 64 on win32. 2014-07-13 22:33:22 +02:00
Zoltan Varga b6994c101f [runtime] Fix some win32 warnings. 2014-07-13 22:31:54 +02:00
Zoltan Varga 80cca0a423 [runtime] Use pthread tls on mingw32, recent versions support __thread, but its emulated. 2014-07-13 22:30:40 +02:00
Zoltan Varga 5c90d7cdba [runtime] Fix a win32 build failure, more remains. 2014-07-13 20:53:53 +02:00
Zoltan Varga b9207a3dae [jit] Avoid conditional members in the MonoJitInfo structure. 2014-07-13 20:51:43 +02:00
Zoltan Varga aa39a2d113 [runtime] Avoid using tls in the monitor wrappers if its not available. 2014-07-13 19:07:25 +02:00
Zoltan Varga 6206280a84 [runtime] Avoid initializing static variables to NULL, its not needed. 2014-07-13 18:18:32 +02:00
Filip Lundgren ab5b39f991 Fixed libmono MSVC compilation 2014-07-13 17:49:33 +02:00
i59 c1a611494a Corrected mono_domain_set_config description. 2014-07-13 17:49:32 +02:00
i59 57f5187ad2 Added new mono_domain_set_config function; used to fix ConfigurationErrorsException in #10468.
This change is released under the MIT license.

https://bugzilla.xamarin.com/show_bug.cgi?id=10468
2014-07-13 17:49:31 +02:00
Zoltan Varga b6a8a10e6e [jit] Move the registration of jit icalls into a separate function. 2014-07-13 17:49:08 +02:00
Zoltan Varga ece3b55369 Fix the build. 2014-07-13 17:40:03 +02:00
Zoltan Varga d07d02078c [runtime] Remove unused g_thread () functions. 2014-07-13 17:35:35 +02:00
Zoltan Varga 281904708f [jit] Remove MONO_ARCH_HAVE_IMT define, all platforms support imt now. 2014-07-13 17:31:36 +02:00
Zoltan Varga b921dc0cef [jit] Use the win32 check for all tls keys in mini_get_tls_offset (). 2014-07-13 17:00:31 +02:00
Jonathan Pryor 70e0756a41 Merge pull request #1153 from akoeplinger/fix-doc-message
[monodoc] Clarified message when a backing file isn't found
2014-07-13 09:49:14 -04:00
Jeffrey Stedfast d3f190cf87 [corlib] minor code cleanup 2014-07-13 08:29:09 -04:00
Zoltan Varga e1b5523c94 [runtime] Handle generic methods in interfaces in imt thunks correctly. Fixes crashes in the System.ServiceModel tests. 2014-07-12 20:05:39 +02:00
Zoltan Varga d0be44220b Revert a change added by cd35ca1 by mistake 2014-07-12 14:20:44 +02:00
Marcos Henrich 856306e21a With IriParsing some escaped chars are changed to upper case. 2014-07-12 09:48:59 +01:00
Marcos Henrich 00b7582bb2 Changed UriHelper.Format to case of percentage encoded characters. 2014-07-12 09:03:00 +01:00
Zoltan Varga cd35ca1fe9 [bcl] Fix a race in a Task test. Fixes #20921. 2014-07-12 00:31:47 +02:00
Zoltan Varga 2103f2394e [jit] Fix system aot on amd64. 2014-07-11 21:21:34 +02:00
Zoltan Varga f9016dc075 Fix a warning. 2014-07-11 21:21:33 +02:00
Fritz Elfert ce9db9db3f Fixed Bug #21135 - Deadlock in WebConnectionStream 2014-07-11 19:20:11 +02:00
Steffen Kieß d65e93b74f Use SortedDictionary in System.Json.JsonObject
Currently JsonObject uses a Dictionary and JsonValue does not sort the keys
in SaveInternal(). As iterating over a Dictionary returns the values in
random order, this causes the JSON string to be non-deterministic.
Switching to SortedDictionary makes sure that the same object always will
produce the same JSON string.
The keys are sorted using StringComparer.Ordinal to produce the same order
in all locales.
2014-07-11 16:13:41 +02:00
Marcos Henrich 9ac47f6347 Tests lower case percentage encoding. 2014-07-11 14:58:35 +01:00
Steffen Kieß 1a021c1e79 Fix handling of strings in System.Json
- Escape control characters, as required by JSON spec
- Escape invalid surrogate pairs
- Escape characters invalid in JavaScript strings
- Escape "</" for HTML script tags
- Fix serialization of chars
- Remove unused variable in JavaScriptReader.cs
- Add tests
2014-07-11 15:46:25 +02:00
Marcos Henrich 3fe13e0b3c UriParser.GetComponentsHelper now sets flag UserEscaped. 2014-07-11 14:38:15 +01:00
Marcos Henrich c0c240bc65 Added uuid to Uri.schemes so its delimiter can be obtained. 2014-07-11 14:34:43 +01:00
Marcos Henrich 34005846d3 Replaced Escape and Reduce usage by FormatAbsolute.
Also removed userEscaped logic because it is verified by FormatAbsolute.
2014-07-11 14:22:19 +01:00
Marcos Henrich e25be38aea Added FormatFlag.UserEscaped. 2014-07-11 12:30:53 +01:00
Alex Rønne Petersen 7008bb6867 Merge pull request #1154 from Zoltu/patch-1
Makes AppendTextUnquoted public.
2014-07-11 05:26:49 +02:00
Zoltan Varga 7892d21b5b [runtime] Only apply the maverick stack size hack added by d6673ca8ec to the main thread since some system threads might really have a small stack size, causing us to overestimate their stack size. This can cause us to mprotect () random memory in mono_setup_altstack (), cause random crashes. Hopefully fixes #10096. 2014-07-10 23:57:32 +02:00
Micah Zoltu 2987746589 Backwards accuracy.
The method is only public in .NET 4+, previously it was protected.  Wrapping the access modifier in a #if NET_4_0 ensures that when building .NET 2, it is protected but when building 4+ it is public.
2014-07-10 11:01:35 -07:00
Marek Safar fab66aa272 [mcs] auto-implemented property initializer 2014-07-10 18:58:08 +02:00
Alexander Köplinger a3d7cfdb20 [monodoc] Clarified message when a backing file isn't found
If the backing file doesn't exist, it will be ignored.
The previous message made it sound like this is a serious problem, which confused people as it is the last message that is
printed when building Mono (because of a reference to 'DoesNotExist' in docs/toc.xml) while in reality everything is fine.
2014-07-10 17:32:10 +02:00
Zoltan Varga 9192bdf57c [sdb] Add a new 'socket-fd' transport, this is the same as the 'dt_socket' transport, but the address is the number of an an already connected socket fd. 2014-07-10 17:21:45 +02:00
Marcos Henrich cc4fae8c12 Fixed tests to pass in .NET 4.5, 4.0 and 2.0. 2014-07-10 15:38:14 +01:00
Marcos Henrich dfe46039b1 Changed cr lf end of lines to lf. 2014-07-10 12:44:06 +01:00
Marcos Henrich b13b5a366e Removed ToString call on OriginalString when source is null.
Uri.Merge is no longer leaving source with a null value.
2014-07-10 09:38:01 +01:00
Marcos Henrich 175a461d55 UriParser is now able to print empty user info. 2014-07-10 09:18:28 +01:00
Marcos Henrich 9d83e94b4d UriHelper.GetScheme is now case insensitive. 2014-07-10 09:09:18 +01:00
Marcos Henrich 27c58c5d70 Changed '#' in a fragment to be escaped in a special case.
When a fragment contains a unescaped or escaped '%', characters '#' are escaped in some cases.
2014-07-10 09:06:44 +01:00
Marcos Henrich bad111fc45 Test special case of '#' escaping in fragment.
When a fragment contains a unescaped or escaped '%' characters '#' are escaped in some cases.
2014-07-10 09:00:01 +01:00
Micah Zoltu 1e655137d3 Makes AppendTextUnquoted public.
The Microsoft version is public, so should this be.
NuGet.MSBuild.Tools.CommandLineBuilderExtensions:AppendTextUnquotedIfNotNullOrEmpty attempts to call this method in NuGet for MSBuild NuGet package.
2014-07-09 21:44:44 -07:00
Zoltan Varga 1693feb77c Fix a warning. 2014-07-09 22:35:52 +02:00
Zoltan Varga 49c6b57089 [jit] Rewrite the generic trampoline code on x86 to avoid pushes. 2014-07-09 22:19:03 +02:00
Miguel de Icaza 9763da775f Fix fallout from WebSocketMessageType change.
The WebSocketMessageType values were being used to send data over the
wire.  This is likely the reason why WebSocketMessageType had values
that were not compatible with .NET.
2014-07-09 15:05:34 -04:00
Ludovic Henry abe94a1faa [delegate-trampoline] Update invoke_impl and method_ptr cache value
With this patch, we see a 3x execution speed improvement in the following micro-benchmark :

using System;

class Foo {
	public int Test () { return 10; }
}

class Program {
	public static int Main (String[] args) {
		long n = 50000000;
		if (args.Length > 0)
			n = Math.Max (n, Int64.Parse (args [0]));

		var a = new Foo ();

		for (long i = 0; i < n; i++) {
			var f = new Func<int> (a.Test);
			if (f () != 10)
				return 1;
		}
		return 0;
	}
}
2014-07-09 14:56:02 -04:00
Ludovic Henry 9e38a4075c [delegate-trampoline] Share DelegateTrampInfo with method-to-ir.c 2014-07-09 14:46:34 -04:00
Zoltan Varga 62ed7761fd [runtime] Enable system aot when using --enable-loadedllvm, hopefully it works now. 2014-07-09 18:55:49 +02:00
Marek Safar 770c223893 [mcs] Extend intermediate value modification checks on generic value types 2014-07-09 18:32:55 +02:00
Marek Safar 5721da66f2 [corlib] Fix incorrect assert 2014-07-09 17:37:28 +02:00
Marek Safar 60def70139 [corlib] Make CompletionOnDifferentCustomSynchronizationContext test more reliable 2014-07-09 17:07:29 +02:00
Zoltan Varga 757ae5f2a9 [bcl] Fix retaining objects in one of the ConditionalWeakTable tests. 2014-07-09 16:26:26 +02:00
Daniel Reiter Horn ceb092eae7 Fixes https://github.com/OfficeDev/Open-XML-SDK/issues/6 by formatting core.xml date according to W3CDTF
This change in released under the MIT license.
2014-07-09 09:24:36 -04:00
Miguel de Icaza 905d434b4e Merge pull request #1132 from mattleibow/bugfix-20925
[system.data] BUGFIX: fixes issue with expression columns and IsNull:
2014-07-09 09:23:45 -04:00
Miguel de Icaza 630116d1b6 Merge pull request #1142 from edbprx/master
ConnectCallback needs to call EndConnect
2014-07-09 09:21:37 -04:00
Miguel de Icaza 3aca7c1500 Merge pull request #1148 from steffen-kiess/json
Fix several issues in System.Json
2014-07-09 09:19:10 -04:00
Miguel de Icaza 430d570aff Merge pull request #1152 from danielrh/hyperlink_package_parse
Fixes https://github.com/OfficeDev/Open-XML-SDK/issues/7 by allow absolute urls in relationships
2014-07-09 09:15:00 -04:00
Miguel de Icaza 1796d0df61 Fix enumeration values 2014-07-09 09:12:34 -04:00
Marek Safar 682f82ba3d [mcs] Disable dedb33eade due to runtime bug 2014-07-09 15:10:28 +02:00
Marek Safar 2b45d2ec56 [corlib] Fix test to not rely on compiler generated method 2014-07-09 15:01:17 +02:00
Marek Safar 74263907dc [mcs] Undo project changes from dedb33eade due to XS stupidity 2014-07-09 11:59:27 +02:00
Marek Safar dedb33eade [mcs] Use closed delegate over static generated methods from anonymous methods 2014-07-09 11:44:41 +02:00
Daniel Reiter Horn 722e83c7a1 Fixes https://github.com/OfficeDev/Open-XML-SDK/issues/7 by allowing both relative and absolute urls
This change in released under the MIT license.
2014-07-09 00:15:05 -07:00
Rodrigo Kumpera aa217360ce [System.Numerics] Contract the values array when decoding an array with a negative number and a trailer that evals to zero. Fixes #20456. 2014-07-08 20:02:19 -04:00
Rodrigo Kumpera 2fa4d25053 Don't hardcode the temp dir to /tmp, use g_get_tmp_dir instead. Fixes #20894.
Hardcoding a temporary dir doesn't work on sandboxed apps.
2014-07-08 18:27:36 -04:00
Zoltan Varga c21c377162 [sdb] Fix handling of out ref parameters. 2014-07-08 18:55:18 +02:00
Marek Safar b8fe4a7941 [Facades] Add more comtypes to System.Runtime.InteropServices 2014-07-08 14:57:02 +02:00
Marek Safar cd95b8238f [mcs] C# static using 2014-07-08 14:57:02 +02:00
Zoltan Varga fd0aaf0c59 [runtime] Remove another duplicate switch case from configure. 2014-07-08 14:35:11 +02:00
Zoltan Varga 29dd3d4c02 [runtime] Remove a duplicate switch case from configure. 2014-07-08 14:34:45 +02:00
Marcos Henrich be150ba5ea LocalPath expected values are now generated for UNIX and MS-DOS.
Depending on the OS the directory separator may be different.
2014-07-08 13:26:12 +01:00
Marcos Henrich 9cbe36c6d8 Fragment_Escape '#' escaping with and without IriParsing.
With IriParsing '#' in a fragment is not escaped in Uri.Fragment while without IriParsing it is.
2014-07-08 13:19:10 +01:00
Marcos Henrich 8de4ca3e16 QueryEscape '%2f' unescaping with and without IriParsing.
With IriParsing '%2f' in a query is not unescaped by ToString while without IriParsing it is.
2014-07-08 13:15:00 +01:00
Marcos Henrich ca9c20afaa Changed reduce to keep consecutive slashes. 2014-07-08 10:24:31 +01:00
Marcos Henrich 0851d2b3ca Added "" to reduceElements to test consecutive slashes.
Changed some paths to avoid id conflicts.
2014-07-08 10:20:25 +01:00
Marcos Henrich 4c737936bc Updated IPv6 test to use the correct form.
With IriParsing the IPv6 is on the mixed form n:n:n:n:n:n:d.d.d.d
Without IriParsing the address is on the hexa-decimal form n:n:n:n:n:n:n:n
2014-07-08 07:52:51 +01:00
Marek Safar 015419959d Merge pull request #1149 from akoeplinger/fix-httpwebreq-test
[System] Fixed HttpWebRequest test that sometimes failed
2014-07-08 08:39:05 +02:00
Zoltan Varga f8ee303ea9 [runtime] Lock the root domain in mono_jit_info_add_aot_module () to simplify locking. 2014-07-08 01:08:16 +02:00
Rodrigo Kumpera afa4cebee3 [runtime] Explicit thread GC data around instead of relying on TLS storage. Fixes #20360.
Some systems do locking in their TLS implementation (yeah, super smart, I know).

Due to how we implement stop-the-world this can lead to deadlocks.
2014-07-07 18:55:26 -04:00
Zoltan Varga dd2b784606 [bcl] Increase some test timeouts to avoid failures when running with llvm. 2014-07-08 00:46:31 +02:00
Alexander Köplinger 2bacb92d36 [System] Fixed HttpWebRequest test that sometimes failed
The TestTimeoutPropertyWithServerThatDoesntExist test sometimes failed with a 'ConnectFailure' instead of a 'Timeout'.
As per the discussion in PR #1145, the test should actually check that a ConnectFailure is thrown before the timeout is reached.
This proved unreliable with the 10.128.200.100 IP address, as it was up to the networking stack to decide whether the endpoint can be reached,
which can take quite a long time (sometimes >100secs).

Instead, we now use the loopback address with a port where no service listens, which should be equivalent.

Additionally, the assert which checks for the correct exception switched the 'expected' and 'actual' parameter, which resulted in the wrong output, this is fixed as well.
2014-07-07 23:53:50 +02:00
Ludovic Henry ccc677e3d6 [delegate-trampoline] Fallback to slow path in case of failure to create fast path 2014-07-07 17:43:05 -04:00
Rodrigo Kumpera 66cbeeb35a Move amd64 to use object offsets. 2014-07-07 16:47:32 -04:00
Ed Boren 0c55c45450 ConnectCallback needs to call EndConnect
Socket.ConnectAsync uses BeginConnect, and ends here in
ConnectCallback. It needs to call EndConnect so any error can be
propagated up.

See Xamarin bug: https://bugzilla.xamarin.com/show_bug.cgi?id=21017
2014-07-07 13:25:51 -04:00
Steffen Kieß b005523cb1 Fix several issues in System.Json
- Fix detection of extra characters in JSON input
- Fix detection of invalid negative numeric literals
- Disallow leading zeros
- Use "round-trip" format for floating point numbers
- Serialize NaN and Infinity as strings
- Use NumberFormatInfo.InvariantInfo for Convert.To*()
- Use standard number parsing methods in ReadNumericLiteral()
- Add test cases
2014-07-07 19:22:29 +02:00
Marcos Henrich 449040617c ParseHost is now retrieving IPv6 addresses with the correct form.
With IriParsing the IPv6 is on the mixed form n:n:n:n:n:n:d.d.d.d
Without IriParsing the address is on the hexa-decimal form n:n:n:n:n:n:n:n
2014-07-07 18:09:13 +01:00
Marcos Henrich cf21937a2e ParseScheme now retrieves a lower case scheme. 2014-07-07 18:00:29 +01:00
Alex Rønne Petersen 66b9914768 Poking Jenkins again... 2014-07-07 18:02:58 +02:00
Alex Rønne Petersen e616159577 Merge pull request #1147 from akoeplinger/misc-test-cleanup
Cleanup untracked test files
2014-07-07 14:27:03 +02:00
Alexander Köplinger 9739c4d1a2 [mdoc] Ignore generated test files 2014-07-07 14:24:56 +02:00
Alexander Köplinger 9c73576f10 [System.Drawing] Delete test files after test 2014-07-07 14:24:55 +02:00
Alexander Köplinger af75afdcda [System.IO.Compression] Delete test file after test 2014-07-07 14:24:54 +02:00
Alexander Köplinger 2670fd3a1c [MWF] Get rid of unused resx.resx file
The other tests already use GetResXFileWithNode () to create this file, make this consistent and get rid of the checked-in file
2014-07-07 14:24:54 +02:00
Alexander Köplinger 45b783a172 [System.Web] Remove superfluous write to file in test
The written file is never used, all the Asserts happen in RenderPostBackEvent_OnSaveStateComplete ().
2014-07-07 14:24:53 +02:00
Alex Rønne Petersen 9fa6327978 Merge pull request #1124 from UCIS/patch-5
Fixed NullReferenceExcepton in Socket.Connect for non-IP endpoints
2014-07-07 14:18:49 +02:00
Alex Rønne Petersen 701da9c664 Add a build status badge to README.md. 2014-07-07 14:16:37 +02:00
Marek Safar 42d5dc7692 [mcs] Flow analysis of moved arguments. Fixes #20983 2014-07-07 13:31:26 +02:00
Marcos Henrich 1eb4eadd02 Removed schemes news: and custom: from tests.
Those schemes have a wrong behavior in .NET.
new Uri("news:a/a%30").ToString() == "news:a/a%30a/a0"
2014-07-07 11:56:41 +01:00
Marcos Henrich e5048fc268 Updated method UriHelper.SupportsQuery to return false with news. 2014-07-07 11:52:56 +01:00
Marcos Henrich 163fe0450a Fixed path starting with '/' on custom schemes, mailto and news. 2014-07-07 11:46:52 +01:00
Marcos Henrich 6311335d7b Added method UriHelper.IsKnownScheme(string scheme). 2014-07-07 11:45:14 +01:00
Marcos Henrich 3c23b670fa Support for custom scheme parsing.
Custom schemes can have a delimiter "://" with a host and a delimiter ":" without a host.
Added FormatFlag.HasHost and UriScheme.CustomWithHost.
2014-07-07 11:35:51 +01:00
Marcos Henrich 9aab7beda3 Change UriParser to correctly parse scheme separator ":" or "://"
Schemes expect a separator ":" or "://" but unknown schemes can use either one, so the used delimiter is now stored in UriElement.
2014-07-07 11:21:01 +01:00
Marcos Henrich 8695716072 Changed Uri.ToString() to use property Uri.Parser. 2014-07-07 11:09:58 +01:00
Alexander Köplinger 1910095e25 [mono] Ignore *.trs files in unit-tests 2014-07-05 23:35:48 +02:00
Alexander Köplinger 96201fbaa7 Ignore automake 'test-driver' file
This was introduced by automake 1.12 and can be safely ignored.
2014-07-05 23:34:40 +02:00
Zoltan Varga 243fc9e374 [jit] Rename MonoJitInfo.used_regs to 'unwind_info' to better reflect its current purpose. 2014-07-05 21:51:56 +02:00
Zoltan Varga 496579788e Add support for precise unwind info in epilogs on amd64:
* Implement DW_CFA_remember_state/restore_state opcodes.
* Add a DW_CFA_mono_advance_loc opcode to advance to a location stored outside
  of the unwind info. Use this to allow the sharing of unwind info between
  methods.

This is need to prevent crashes during unwinding when the ip of the last frame is in the epilog. This can be reproduced by
running sgen-new-threads-dont-join-stw.exe in a loop.
2014-07-05 16:10:13 +02:00
Zoltan Varga e7c56da507 Update the required bootstrap mono version to 2.10, 2.4 will no longer work. 2014-07-04 18:13:40 +02:00
Marek Safar 85e83288f8 [corlib] Update 6b94215d0b to work with not null targets too 2014-07-04 16:26:45 +02:00
Marek Safar 29520fe1b0 [mcs] Allow more conversions for CallerLineNumberAttribute 2014-07-04 16:26:45 +02:00
Zoltan Varga 9ae041a631 [sdb] Add support for out arguments in invokes. 2014-07-04 15:56:16 +02:00
Marcos Henrich 82a4c17b2b Uri.IriParsing can now be set by using an environment variable.
The Uri static constructor reads the environment variable MONO_URI_IRIPARSIN and sets Uri.IriParsing.
2014-07-04 11:25:48 +01:00
Marek Safar 6b94215d0b [corlib] Fix Delegate::DynamicInvoke for open delegates of instance methods and closed delegates of static methods 2014-07-04 12:24:16 +02:00
Alex Rønne Petersen 8ecdad183b Empty commit, poking Jenkins... 2014-07-04 04:55:16 +02:00
Zoltan Varga 3bbaf9096e [runtime] Use sleep (1) instead of sleep (0) in the native SIGSEGV suspend loop to reduce cpu usage. 2014-07-04 03:08:23 +02:00
Zoltan Varga fce3972b58 [sdb] Add support for returning the changed valuetype receiver after invokes to valuetype methods. 2014-07-03 23:33:10 +02:00
Marcos Henrich 98b6fe5827 Fixed missing # encoding.
With IriParsing disabled if the fragment has a character to be normalized then an # should be encoded.
new Uri("http://a/a?#%30#").ToString() should be "http://a/a?#0%23".
new Uri("http://a/a?#0#").ToString() should be "http://a/a?#0#".
2014-07-03 19:26:18 +01:00
Marcos Henrich c4508573a9 Updated UriHelper.FormatFlags.
Renamed HasCharactersToNormalize to HasUriCharactersToNormalize
Added HasComponentCharactersToNormalize.
2014-07-03 19:24:32 +01:00
Marcos Henrich 2d12b5be53 Fixed bad reduce of "ftp://a\.\". 2014-07-03 18:18:41 +01:00
Marcos Henrich d66a5dafb4 Added backslash to reduceLocations. Simplified componentLocations. 2014-07-03 18:02:55 +01:00
Marcos Henrich 94ca53a315 StringTester.Assert parameter message is now optional.
Additionaly if no message is provided the assert id is used instead.
2014-07-03 17:55:51 +01:00
Marcos Henrich a810e34cdb Updated Uri.Tostring.
Uri.ToString now use GetComponentsHelpers to get and format an absolute Uri and uses FormatRelative to format a relative Uri.
2014-07-03 17:41:14 +01:00
Marcos Henrich 48b81e65ff Added method GetComponentsHelper.
With GetComponentsHelper components with format UriHelper.ToStringUnescape can be retrieve without the ArgumentOutOfRangeException thrown by GetComponents.
2014-07-03 17:39:52 +01:00
Marek Safar d73e2354f3 [mcs] Don't cache lambda expressions in static constructor context 2014-07-03 17:50:41 +02:00
Marek Safar 50a98385b4 [mcs] Fixes flow analysis of if statement with constant expression 2014-07-03 17:50:40 +02:00
Marek Safar 667c78579c [mcs] Overload resolution should not fail when type inference infers inaccessible types but other overload exists 2014-07-03 17:50:40 +02:00
Marek Safar ea4d8490c7 [mcs] Methodgroup probing checks are not allowed 2014-07-03 17:50:40 +02:00
Marek Safar 9b026032a3 [mcs] Methodgroup conversion involving user defined operators 2014-07-03 17:50:40 +02:00
Marek Safar d462fc4443 [mcs] Use same result conversion rules of predefined enum operators for unary and binary expressions 2014-07-03 17:50:39 +02:00
Marek Safar 2139eeab4c [mcs] A value for params parameter with default valus is still empty array 2014-07-03 17:50:39 +02:00
Zoltan Varga 0d166ba085 [runtime] Enable aot on 64 bit osx. 2014-07-03 16:49:51 +02:00
Marcos Henrich 986071016d Updated Fragment, Query, AbsoluteUri.
Fragment and Query are now processed with UriHelper.FormatAbsolute.
AbsoluteUri is using obtained from GetComponents.
2014-07-03 14:43:43 +01:00
Marcos Henrich c55d3dfa29 UriHelper.Format now reduces paths. 2014-07-03 12:55:07 +01:00
Marcos Henrich b3dc98ad27 Improved reduce tests.
Reduce tests now test sequences of 1 to 3 encoded or decoded dots inside paths with or without trailing character and encoded fowardslash and backslash.
2014-07-03 12:46:13 +01:00
Alex Rønne Petersen 4d59f61b23 Revert "[corlib] Re-enable TaskContinuationChainLeak test."
This reverts commit 265060cc22.

The test is still failing:

2) MonoTests.System.Threading.Tasks.TaskTests.TaskContinuationChainLeak :   Expected: False
  But was:  True

at MonoTests.System.Threading.Tasks.TaskTests+TaskContinuationChainLeakTester.Verify () [0x00000] in /var/lib/jenkins/workspace/Mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:1991
at MonoTests.System.Threading.Tasks.TaskTests.TaskContinuationChainLeak () [0x00022] in /var/lib/jenkins/workspace/Mono/mcs/class/corlib/Test/System.Threading.Tasks/TaskTest.cs:1948
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00054] in /var/lib/jenkins/workspace/Mono/mcs/class/corlib/System.Reflection/MonoMethod.cs:230
2014-07-03 05:54:01 +02:00
Alex Rønne Petersen dff4b38a95 [System] Add more logging to the BeginConnectMultiple test. 2014-07-03 02:46:21 +02:00
Alex Rønne Petersen d56373ffc0 [WCF] Disable CloseTest and OpenTest4 in CustomPeerResolverServiceTest.
These tests occasionally time out:

Test Case Failures:
1) MonoTests.System.ServiceModel.PeerResolvers.CustomPeerResolverServiceTest.CloseTest : System.TimeoutException : The operation has timed-out.
at System.ServiceModel.Channels.HttpRequestChannel+HttpChannelRequestAsyncResult.WaitEnd () [0x00000] in <filename unknown>:0
at System.ServiceModel.Channels.HttpRequestChannel.EndRequest (IAsyncResult result) [0x00000] in <filename unknown>:0
at System.ServiceModel.Channels.HttpRequestChannel.Request (System.ServiceModel.Channels.Message message, TimeSpan timeout) [0x00000] in <filename unknown>:0
at System.ServiceModel.MonoInternal.ClientRuntimeChannel.Request (System.ServiceModel.Channels.Message msg, TimeSpan timeout) [0x00000] in <filename unknown>:0
at System.ServiceModel.MonoInternal.ClientRuntimeChannel.Request (System.ServiceModel.Description.OperationDescription od, System.Object[] parameters) [0x00000] in <filename unknown>:0
at System.ServiceModel.MonoInternal.ClientRuntimeChannel.DoProcess (System.Reflection.MethodBase method, System.String operationName, System.Object[] parameters) [0x00000] in <filename unknown>:0
at System.ServiceModel.MonoInternal.ClientRuntimeChannel.Process (System.Reflection.MethodBase method, System.String operationName, System.Object[] parameters) [0x00000] in <filename unknown>:0

I.e. we're timing out waiting for the async wait handle here: https://github.com/mono/mono/blob/master/mcs/class/System.ServiceModel/System.ServiceModel.Channels/HttpRequestChannel.cs#L495

Since we have no current WCF maintainer and this is deep, deep within
WCF land and causes unstable builds on Jenkins, disable these tests
for now.

Bug: https://bugzilla.xamarin.com/show_bug.cgi?id=21069
2014-07-03 02:31:07 +02:00
Alex Rønne Petersen 26789fb447 [System] Add some debugging code to BeginConnectMultiple test.
The WaitOne () call has a tendency to time out on the Jenkins
VMs. However, reproducing the problem outside of Jenkins has
proven futile.

This makes the WaitOne () call block for as long as needed and
still fails the test if the elapsed time was longer than 30s.
We print the actual elapsed time to the console.

Hopefully this'll help us find out if it's just taking quite a
long time to run or if it's a hang.
2014-07-03 02:20:11 +02:00
Rodrigo Kumpera c0bb6c817c [runtime] Add cross helper extensions. 2014-07-02 16:20:08 -04:00
Marcos Henrich 5119bb867e Improved unescape testing.
With IriParsing the presencee of encoded alpha numeric, non ASCII, '-', '.', '_' and '~' characters trigger the decoding of some other characters.
Tested permutations now include tests with and tests without those characters.
2014-07-02 21:02:07 +01:00
Marcos Henrich aa1130e4fe Added methods FormatAbsolute, FormatRelative, and enum FormatFlags.
Changed Format methods to receive FormatFlags.
Added FormatFlag.HasCharactersToNormalize, which improves character decoding.
The flag is set when Iriparsing is true and the Uri contains an encoded alpha numeric, non ASCII, '-', '.' , '_' and '~'.
When the flag is set some other encoded charcaters need also to be decoded.
2014-07-02 19:17:03 +01:00
Ludovic Henry 49e43b69e5 [sgen] Use gc_stats minor and major collection counts instead of local variable 2014-07-02 13:52:57 -04:00
Zoltan Varga c81847aad0 [runtime] Fix the win32 build. 2014-07-02 19:10:22 +02:00
Marek Safar c1a3af342a [mcs] Constant folding of null strings casted to object 2014-07-02 15:33:16 +02:00
Marek Safar f2c645206b [mcs] Add new test 2014-07-02 15:33:04 +02:00
Marek Safar bde70c6954 [mcs] Parsing of nullable type cast inside statement with open parens 2014-07-02 15:31:06 +02:00
Marek Safar c25e3160cd [mcs] Switch with user conversion to nullable governing type 2014-07-02 13:10:12 +02:00
Marek Safar 36465ac8ca [mcs] Object initializer for events which can be initialized using field expression 2014-07-02 13:10:12 +02:00
Alex Rønne Petersen 68b843055d [ppc] Lower long_rem_imm to long_rem when on ppc64. 2014-07-02 10:50:07 +02:00
Alex Rønne Petersen f9435b5381 mcs/class/Makefile: Remove duplicate System.Web entry.
Second take on 5fbb351375.
2014-07-02 01:48:35 +02:00
Alex Rønne Petersen 1c0a2b274d mcs/class/Makefile: Merge common_dirs into net_2_0_dirs.
They're used in the same places so we may as well simplify.
2014-07-02 01:48:34 +02:00
Alex Rønne Petersen e7ea135959 Revert "Remove duplicate System.Web in mcs/class/Makefile."
This reverts commit 5fbb351375.

This breaks the build because System.Runtime.Remoting needs System.Web.
2014-07-02 01:35:40 +02:00
Rodrigo Kumpera d97ad1baef [runtime] First pass of cross compilation cleanup. Allow offsets and alignment to be externally calculated. 2014-07-01 19:33:57 -04:00
Alex Rønne Petersen 5fbb351375 Remove duplicate System.Web in mcs/class/Makefile.
It was listed both in net_2_0_dirs and common_dirs so
it would get tested twice in some profiles.
2014-07-02 00:37:05 +02:00
Alex Rønne Petersen 74f1bd23d2 Remove duplicate System.ServiceModel in mcs/class/Makefile.
This was causing tests to be run several times in the same profile(s).
2014-07-01 23:30:06 +02:00
Rodrigo Kumpera a5245506a5 [runtime] Fix the android build. 2014-07-01 16:19:19 -04:00
Alex Rønne Petersen 265060cc22 [corlib] Re-enable TaskContinuationChainLeak test.
This is hopefully fixed after a57fb5b.
2014-07-01 21:53:56 +02:00
Alex Rønne Petersen 8ee0cae366 [ppc] Clean up atomic opcodes.
* Support atomic_add_i4 on ppc32 in addition to ppc64.
* Make the atomic_add_* code more in line with the atomic_cas_* code.
2014-07-01 21:53:56 +02:00
Alex Rønne Petersen b784b866da [mini] Simplify the way the JIT emits atomic opcodes.
* MONO_ARCH_HAVE_ATOMIC_* macros have been removed.
* Backends now report whether they support atomic opcodes via
  the mono_arch_opcode_supported () function.
* The default implementation of mono_arch_opcode_supported ()
  has been removed as almost all backends need to define one
  anyway.
* All old atomic_add_* opcodes have been removed. These were no
  longer being used but some backends still had code for them.
* atomic_add_new_* opcodes have been renamed to atomic_add_* as
  they are now the only atomic add opcodes.
* Itanium-specific atomic_add_imm_* opcodes have been moved to
  the __ia64__ section of mini-ops.h.
* Comments have been added to mini-ops.h explaining the precise
  semantics of the atomic opcodes.

The net result of this change is a simpler backend interface at
the cost of a slightly bigger binary.
2014-07-01 21:53:56 +02:00
Alex Rønne Petersen 654f2908d6 Merge pull request #1143 from akoeplinger/fix-gc-descriptor-error
[tests] gc-descriptors: Only copy file in case of VPATH build
2014-07-01 21:40:35 +02:00
Alex Rønne Petersen d1da287383 Merge pull request #1127 from oleg-st/master
Added fix for Bug 20869
2014-07-01 21:36:58 +02:00
Alexander Köplinger 687fd0e45f [tests] gc-descriptors: Only copy file in case of VPATH build
Instead of ignoring the cp error when copying over the same file in non-VPATH builds.
2014-07-01 21:17:53 +02:00
Zoltan Varga a57fb5b645 [runtime] Make WaitForPendingFinalizers () really wait for the finalizers added by a previous GC. Fixes #20503. 2014-07-01 21:10:33 +02:00
Alex Rønne Petersen e773c8681b Merge pull request #1141 from akoeplinger/fix-mono-shlib-cop
[tools] Fixed mono-shlib-cop test
2014-07-01 20:43:40 +02:00
Zoltan Varga cb0e956570 Fix the marshal7.cs test, longs can be aligned to 4 bytes on 32 bit linux, and the runtime no longer aligns structure sizes to 8 bytes. Fixes #20788. 2014-07-01 19:53:26 +02:00
Marcos Henrich 4d3934f7c9 Changed UriPermutationsTest createMode to false. 2014-07-01 14:49:09 +01:00
Alexander Köplinger eb30357e6f [tools] Fixed mono-shlib-cop test
MONO_PATH was missing when running the tests.

Use "libMonoPosixHelper.so" in local directory when checking if DllImport of a development library generates a warning (libglib2.0-dev might not be installed, but libMonoPosixHelper is always built with mono)
2014-07-01 14:55:00 +02:00
Andrea Canciani 39108b009f Improve libgdiplus path handling
Since libgdiplus is not installed together with Mono, it should not be
assumed to be in the same prefix.

The new policy for the --with-libgdiplus configure option is the
following:

 - --with-libgdiplus=/absolute/path/to/libgdiplus.{so,dylib}

   both during build/check and after installation Mono will try to use
   the specified libgdiplus library; the rationale is that when an
   absolute path is given, it can be assumed to be the full path to
   the library that is already installed (possibly in a non-default
   path).

 - default, --with-libgdiplus=no, --with-libgdiplus=installed

   both during build/check and after installation Mono will try to use
   a system-wide libgdiplus library, that is assumed to reside in the
   paths that are automatically searched by the dynamic linker; the
   library is supposed to be already installed in the default path and
   to be useable both during the build and afterwards.

 - --with-libgdiplus=sibling, --with-libgdiplus=yes

   during build/check Mono will try to use the libgdiplus library that
   is assumed to be in the sibling folder (../libgdiplus), but after
   the installation it will try to use a system-wide libgdiplus
   library, that should be in the paths that are automatically
   searched by the dynamic linker; the assumption is that the library
   is not yet installed, but it will go to the default prefix after
   installing it.

 - --with-libgdiplus=../some/relative/path/to/libgdiplus.{so,dylib,la}

   during build/check Mono will try to use the specified libgdiplus
   library, but after the installation it will try to use a
   system-wide libgdiplus library, that should be in the paths that
   are automatically searched by the dynamic linker; the assumption is
   that the library is not yet installed, but it will go to the
   default prefix after installing it.
2014-07-01 14:25:21 +02:00
Andrea Canciani 3408b8e5f1 Use Mono prefix for libMonoPosixHelper
The libMonoPosixHelper is installed together with Mono, hence its path
in the configuration should be relative to the Mono prefix.

It was previously assumed to reside in a system path, so the the
dynamic linker would find it anyway.

This patch is based on the one included in bug #18555 (by Gaëtan
Lehmann <[email protected]>), but it also updates
runtime/Makefile.am to keep runtime/etc/mono/config consistent.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=18555
2014-07-01 14:25:12 +02:00
Marek Safar 14c22b76c3 [mcs] Add missing lock expression flow analysis 2014-07-01 14:03:53 +02:00
Marcos Henrich b827f67a4e Added UriPermutationsTest.
Created a new set of tests that create&store or that load&assert uri permutations.
Uris are created with permutations of schemes, components, characters then methods and properties output is asserted against expected values obtained on .NET.
2014-07-01 12:14:31 +01:00
Marek Safar a2b77fd158 [mcs] Emit valid code for exception filter using constrained type parameter 2014-07-01 12:45:28 +02:00
Marek Safar 7dc9d3c84f [mcs] Emit correct token for inherited nested non-generic types from unbound types 2014-07-01 09:45:02 +02:00
Marek Safar 8f961e6560 [mcs] Re-add obsolete reporting for enumerators removed in 6643bc119c 2014-07-01 08:36:05 +02:00
Zoltan Varga 309e3348d3 Allocate the finalizable object in finalizer-exception.cs in another thread to make it less likely that it is retained. Fixes finalizer-exception.exe on 64 bit osx+llvm. 2014-07-01 00:35:29 +02:00
Alex Rønne Petersen f2e0ddfe07 Merge pull request #1140 from kitsilanosoftware/no-gitlink-in-dist
[dist] Do not include .git link files in dist tarball
2014-07-01 00:18:28 +02:00
Damien Diederen 8b29589414 [dist] Do not include .git link files in dist tarball
Recent versions of Git co-host submodule GIT_DIRs in <root-project>/.git/
by default, and write their relative path into <subproject>/.git,
which is a regular file:

    $ ls -l external/cecil/.git
    -rw-r--r-- 1 foo  bar  42 Jun 16 12:50 external/cecil/.git
    $ cat external/cecil/.git
    gitdir: ../../.git/modules/external/cecil

Relax the expression in Makefile.am to also delete these (broken)
"symlinks" when preparing a distribution tarball.
2014-06-30 23:59:22 +02:00
Alex Rønne Petersen 6a71dad5fe Add /reflection-load-dir to mono/tests/.gitignore. 2014-06-30 23:25:49 +02:00
Alex Rønne Petersen f6f5131915 Emit correct memory barriers in the JIT intrinsic for Interlocked.Read (). 2014-06-30 23:25:14 +02:00
Zoltan Varga 83f5d832c3 [amd64] Remove the callee saved registers from MonoLMF, save/restore them normally using the normal register save/restore code. 2014-06-30 23:04:38 +02:00
Alex Rønne Petersen c659ba284a Merge pull request #1138 from akoeplinger/fix-webtest-deadlocks
[System.Web] Tests: Fix deadlock when ThreadAbortException is thrown
2014-06-30 21:12:26 +02:00
Alexander Köplinger f7f627b756 [System.Web] Tests: Fix deadlock when ThreadAbortException is thrown
This reverts commit ed11296c51.

When a ThreadAbortException is thrown during request processing in AsyncRun () the _done.Set () call is not executed.
This then results in a deadlock because _done.WaitOne () doesn't get signaled and waits forever.
One solution would be enclosing the _done.Set () in a finally clause, but even then we'd need to relaunch the AsyncRun () loop to be in a usable state.

A simpler solution is to revert the commit that introduced the AsyncRun () in the first place, as it doesn't seem necessary now (the tests pass just fine without it).

The test that was disabled in 429cdf17cf is reenabled too, as it wasn't the culprit of the problem.
2014-06-30 21:01:30 +02:00
Marek Safar 6643bc119c [mcs] Not applicable GetEnumerator candidates were not rejected early enough 2014-06-30 19:45:46 +02:00
Alex Rønne Petersen dd96dbf5a9 Merge pull request #1133 from kitsilanosoftware/mcs-tests-no-jscript
[mcs tests] class/Microsoft.JScript does not exist anymore
2014-06-30 19:43:14 +02:00
Zoltan Varga 65c9838151 [jit] Move the 'remove any unused lmf' code from mono_arch_find_jit_info () to mini-exceptions.c to reduce code duplication and fix some problems where ctx->sp and lmf->sp was used to determine whenever the LMF was below the end of the stack instead of new_ctx->sp and lmf. 2014-06-30 19:40:10 +02:00
Zoltan Varga bffc57cca8 [amd64] Fix the popping of LMF frames during unwinding. Fixes #20616. 2014-06-30 18:54:25 +02:00
Marek Safar 2820631d68 [mcs] Emit partial type parameters attributes too 2014-06-30 17:25:27 +02:00
Marek Safar 819a50e76e [mcs] Use same rules in dynamic context as in normal instance member hidding. 2014-06-30 17:25:27 +02:00
Marcos Henrich 085fc9b574 Improved UriHelper.Format '%' handling.
When a % was found HexUnescapeMultiByte output was always considered escaped.
Now a % that is not a percentage encoded character will be processed has a not escaped character.
2014-06-29 15:44:20 +01:00
Zoltan Varga faa73b1290 [runtime] Fix the marshalling of ByValTStr types which have a size specified. Fixes #20674. 2014-06-29 15:24:29 +02:00
Marcos Henrich 666987dbcf Changed Uri.SupportsQuery to use UriHelper.SupportsQuery. 2014-06-29 11:26:33 +01:00
Marcos Henrich 048d3a198e Changed ParsePath to only break on '?' if scheme supports queries. 2014-06-29 11:01:36 +01:00
Marcos Henrich addeff3b8f Replaced UriParser.Format with UriHelper.Format.
UriParser.Format was deleted and UriParser.GetComponents is now using UriHelper.Format.
2014-06-29 10:51:09 +01:00
Marcos Henrich 77113c8429 Changed UriElements query and fragment default values to null.
Default values are now null so UriParser.GetComponents can return an empty query or fragment..
2014-06-29 10:31:43 +01:00
Marcos Henrich 6b9726ed2a Created file UriHelper.cs.
UriHelper has the method Format that escapes or unescapes a string's characters depending on the Scheme, UriKind, UriComponent and UriFormat.
2014-06-29 10:06:22 +01:00
Marcos Henrich e5eea6a591 Changed method HexUnescapeMultiByte to internal. 2014-06-29 09:48:48 +01:00
Marcos Henrich b31f2bf454 Added property IriParsing and field s_IriParsing.
The property IriParsing will be used to change between .NET 4.5 and .NET 4.0 default percentage encoding/decoding behavior.
A private field named s_IriParsing same as .NET was also added so it can be changed the same way through reflection in .NET and Mono.
2014-06-29 09:10:00 +01:00
Marcos Henrich 9d624b7d4e Added UriScheme name.
Added UriSchemeTelnet, UriSchemeLdap, UriSchemeUuid.
2014-06-28 19:15:07 +01:00
Ludovic Henry 1fdc7407a0 [sgen-worker] Improve worker data stealing distribution
The idea is simply to make a worker tries to steal work from the workers that are next to him firs, before trying back at the beginning.
This reduce lock contention on the first workers and distribute more evenly work between workers by not starving the first ones.
2014-06-27 16:21:31 -07:00
Alex Rønne Petersen 143e50f97d Fix a format string warning in decode.c. 2014-06-27 23:46:33 +02:00
Alex Rønne Petersen c2ede005a3 Only enable finally_block_ending_in_dead_bb.exe on x86/amd64 (not NaCl and Win32).
We would previously run this everywhere, but it only works on
x86 and amd64 at the moment (similar to finally_guard.exe).
This meant that it would always fail on e.g. ARM and PPC. We
still disable it under NaCl (because it uses Thread.Abort ())
and Win32.
2014-06-27 23:37:27 +02:00
Alex Rønne Petersen 2bf3cf31c1 [Ms.Build] Disable 4 tests in ProjectTest and ProjectCollectionTest under NET_4_0.
Bug: https://bugzilla.xamarin.com/show_bug.cgi?id=20961

These tests fail under this particular profile only with the following:

1) MonoTests.Microsoft.Build.Evaluation.ProjectCollectionTest.GlobalProperties :   #2
  Expected: True
  But was:  False

at MonoTests.Microsoft.Build.Evaluation.ProjectCollectionTest.GlobalProperties () [0x00000] in <filename unknown>:0
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0

2) MonoTests.Microsoft.Build.Evaluation.ProjectTest.BuildCSharpTargetBuild : Microsoft.Build.Exceptions.InvalidProjectFileException : Attribute "KeepDuplicates" is not known on node "_TargetFrameworkDirectories" [type Microsoft.Build.Construction.ProjectItemElement].  at: /home/alexrp/Projects/mono/mcs/class/lib/net_4_5/Microsoft.Common.targets (182,5)
at Microsoft.Build.Construction.ProjectElement.LoadAttribute (System.String name, System.String value) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectItemElement.LoadAttribute (System.String name, System.String value) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectRootElement.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectRootElement.Create (System.Xml.XmlReader xmlReader, Microsoft.Build.Evaluation.ProjectCollection projectCollection) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Import (Microsoft.Build.Construction.ProjectImportElement import) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project+<EvaluatePropertiesAndImportsAndChooses>c__Iterator0.MoveNext () [0x00000] in <filename unknown>:0
at System.Linq.Enumerable.ToArray[ProjectElement] (IEnumerable`1 source) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Import (Microsoft.Build.Construction.ProjectImportElement import) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project+<EvaluatePropertiesAndImportsAndChooses>c__Iterator0.MoveNext () [0x00000] in <filename unknown>:0
at System.Linq.Enumerable.ToArray[ProjectElement] (IEnumerable`1 source) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.ProcessXml () [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Initialize () [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion, Microsoft.Build.Evaluation.ProjectCollection projectCollection, ProjectLoadSettings loadSettings) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion, Microsoft.Build.Evaluation.ProjectCollection projectCollection) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion) [0x00000] in <filename unknown>:0
at MonoTests.Microsoft.Build.Evaluation.ProjectTest.BuildCSharpTargetBuild () [0x00000] in <filename unknown>:0
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0

3) MonoTests.Microsoft.Build.Evaluation.ProjectTest.CreateProjectInstance : Microsoft.Build.Exceptions.InvalidProjectFileException : Attribute "KeepDuplicates" is not known on node "_TargetFrameworkDirectories" [type Microsoft.Build.Construction.ProjectItemElement].  at: /home/alexrp/Projects/mono/mcs/class/lib/net_4_5/Microsoft.Common.targets (182,5)
at Microsoft.Build.Construction.ProjectElement.LoadAttribute (System.String name, System.String value) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectItemElement.LoadAttribute (System.String name, System.String value) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectRootElement.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectRootElement.Create (System.Xml.XmlReader xmlReader, Microsoft.Build.Evaluation.ProjectCollection projectCollection) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Import (Microsoft.Build.Construction.ProjectImportElement import) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project+<EvaluatePropertiesAndImportsAndChooses>c__Iterator0.MoveNext () [0x00000] in <filename unknown>:0
at System.Linq.Enumerable.ToArray[ProjectElement] (IEnumerable`1 source) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Import (Microsoft.Build.Construction.ProjectImportElement import) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project+<EvaluatePropertiesAndImportsAndChooses>c__Iterator0.MoveNext () [0x00000] in <filename unknown>:0
at System.Linq.Enumerable.ToArray[ProjectElement] (IEnumerable`1 source) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.ProcessXml () [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Initialize () [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion, Microsoft.Build.Evaluation.ProjectCollection projectCollection, ProjectLoadSettings loadSettings) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion, Microsoft.Build.Evaluation.ProjectCollection projectCollection) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion) [0x00000] in <filename unknown>:0
at MonoTests.Microsoft.Build.Evaluation.ProjectTest.CreateProjectInstance () [0x00000] in <filename unknown>:0
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0

4) MonoTests.Microsoft.Build.Evaluation.ProjectTest.LoadCaseInsensitive : Microsoft.Build.Exceptions.InvalidProjectFileException : Attribute "KeepDuplicates" is not known on node "_TargetFrameworkDirectories" [type Microsoft.Build.Construction.ProjectItemElement].  at: /home/alexrp/Projects/mono/mcs/class/lib/net_4_5/Microsoft.Common.targets (182,5)
at Microsoft.Build.Construction.ProjectElement.LoadAttribute (System.String name, System.String value) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectItemElement.LoadAttribute (System.String name, System.String value) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.LoadValue (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectElementContainer.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectRootElement.Load (System.Xml.XmlReader reader) [0x00000] in <filename unknown>:0
at Microsoft.Build.Construction.ProjectRootElement.Create (System.Xml.XmlReader xmlReader, Microsoft.Build.Evaluation.ProjectCollection projectCollection) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Import (Microsoft.Build.Construction.ProjectImportElement import) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project+<EvaluatePropertiesAndImportsAndChooses>c__Iterator0.MoveNext () [0x00000] in <filename unknown>:0
at System.Linq.Enumerable.ToArray[ProjectElement] (IEnumerable`1 source) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Import (Microsoft.Build.Construction.ProjectImportElement import) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project+<EvaluatePropertiesAndImportsAndChooses>c__Iterator0.MoveNext () [0x00000] in <filename unknown>:0
at System.Linq.Enumerable.ToArray[ProjectElement] (IEnumerable`1 source) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.ProcessXml () [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project.Initialize () [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion, Microsoft.Build.Evaluation.ProjectCollection projectCollection, ProjectLoadSettings loadSettings) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion, Microsoft.Build.Evaluation.ProjectCollection projectCollection) [0x00000] in <filename unknown>:0
at Microsoft.Build.Evaluation.Project..ctor (Microsoft.Build.Construction.ProjectRootElement xml, IDictionary`2 globalProperties, System.String toolsVersion) [0x00000] in <filename unknown>:0
at MonoTests.Microsoft.Build.Evaluation.ProjectTest.LoadCaseInsensitive () [0x00000] in <filename unknown>:0
at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0
2014-06-27 23:37:27 +02:00
Alex Rønne Petersen 3130eae0bc atomic.c: Get rid of the fallback warning.
This is really noisy on platforms like ARM where we
intentionally use the fallback mutex-based code.
2014-06-27 23:37:27 +02:00
Matthew Leibowitz 7f8d148ec2 [system.data] Appended the fix to correct the whitespace Expression and argument checking
- Whitespace Espressions:
 -- if a column expression is a pure whitespace, use an empty string instead
 -- if a column expression is surrounded by whitespace, preserve whitespace
 -- if a column expression is null/empty, use an empty string
 - Get a row's column value:
 -- make sure we throw exceptions if the column we are looking at is null
 -- make sure we throw exceptions if we can't find the column with the provided name
2014-06-27 20:56:37 +02:00
Michael Hutchinson 8afba772b2 [MSBuild] Reload projects after parsing sln file
When building sln files, they are first converted to sln.proj
files, then the project file is built.

The engine unloaded and reloaded the sln.proj file itself, but
not the projects implicitly loaded while parsing the sln file.
This meant that some state was kept around that prevented
AfterTargets from being handled correctly

BXC18761 - AfterTargets and AfterBuild ignored by xbuild
2014-06-27 14:31:44 -04:00
Rodrigo Kumpera 3acca04eaf Revert "Don't touch internal feature macros in eglib"
This reverts commit dd412cfb2e.

We need to know what target was broken by this and verify that this won't break the platitude of libc's around.

This is currently a non-trivial job, so let's just revert this for now.
2014-06-27 14:16:29 -04:00
Michael Hutchinson c8e2f04965 [MSBuild] Suppress useless message
The DotConfigExtensionsPath won't ever exist unless the user
creates it manually, so prevent spewing out dozens of messages
that it's missing.
2014-06-27 14:09:21 -04:00
João Matos 994c2c32fd [System.IO.Compression] Tidy up formatting. 2014-06-27 16:30:32 +01:00
João Matos 53b028a5c2 [System.IO.Compression] Fixed archive entry opening for non-Create mode archives. 2014-06-27 16:04:06 +01:00
Marek Safar e206a4a2d3 Merge pull request #1134 from kitsilanosoftware/mcs-tests-dll-il-distfile
[mcs tests] Add tests/dlls/*.il to DISTFILES
2014-06-27 16:52:45 +02:00
Marek Habersack f1d4d8d1bc Merge pull request #1135 from kitsilanosoftware/rpm-spec-dead-entries
[rpm spec] Mono.Web and OpenSystem.C do not exist anymore
2014-06-27 16:45:43 +02:00
Alex Rønne Petersen abb4701d10 Use mono_strtod () instead of strtod () on ARM.
The former used to miscompile back in 2005, but this no
longer appears to be the case. Further, using strtod ()
is problematic on Linux/ARM systems with many non-US
locales that use a comma as the decimal separator.

In particular, this breaks almost all compilation with
MCS because it can't parse floating point literals.

Based on investigation by Damien Diederen <[email protected]>.
2014-06-27 16:34:18 +02:00
Alex Rønne Petersen abc9511500 Fix a format string warning in decode.c. 2014-06-27 16:34:18 +02:00
Damien Diederen 1d474d3480 [mcs tests] Add tests/dlls/*.il to DISTFILES
Without this,

    cd mcs/tests && make run-test

fails when run from a distribution tarball.
2014-06-27 16:30:35 +02:00
Damien Diederen 4984d2be23 [mcs tests] class/Microsoft.JScript does not exist anymore 2014-06-27 16:30:04 +02:00
Damien Diederen 0332f3b622 [rpm spec] Mono.Web and OpenSystem.C do not exist anymore 2014-06-27 16:29:21 +02:00
Matthew Leibowitz 19908c6b94 [system.data] BUGFIX: fixes issue with expression columns and IsNull:
- bugzilla.xamarin.com issue 20925
 - if an expression column was added ayer there were rows, and then IsNull is called, the result is incorrect (it will always be true)
2014-06-27 13:43:12 +02:00
Marek Safar 7bf00fe94c [System] Fixes a warning 2014-06-27 13:37:50 +02:00
Marek Safar fcb3c36009 [corlib] Array qsort without head allocation. Fixes #20922 2014-06-27 12:44:59 +02:00
Marek Safar 90d6774c0b [mcs] Fix crash in inherited type parameter interface check 2014-06-27 12:44:59 +02:00
Marek Safar 087c85a0a8 [mcs] Workaround MSIL limitation when loading bool elements 2014-06-27 12:44:58 +02:00
Ludovic Henry c988f486f9 [sgen-gray-queue] Fix crashing sgen-domain-unload sgen test
sgen-domain-unload.exe test would crash because of a bug involving queue->alloc_prepare_func => workers_gray_queue_share_redirect => sgen_gray_object_dequeue_section on queue => set queue->first->size depending on queue->cursor. The solution is simply to make sure that the cursor is set on the queue, before allocating a new section, even if it is does not seems necessary in the first place.
2014-06-26 20:32:46 -07:00
Ludovic Henry cc4dc922aa [sgen-gray-queue] Always update queue->cursor when dequeing
Previously, queue->cursor would not be set to NULL if the last element would be dequeued and queue->first would be set to NULL.
2014-06-26 20:31:12 -07:00
Zoltan Varga eedc51cb8f [jit] Remove now unused MONO_ARCH_HAVE_OP_LREM_IMM define. 2014-06-27 03:53:53 +02:00
Alex Rønne Petersen 28d7376a01 Fix a couple of format string warnings in sgen-gc.c. 2014-06-27 03:48:05 +02:00
Zoltan Varga 5e1960cef7 Merge pull request #1131 from schani/feature-portable-fast-lrem-imm
[jit] Portably decompose power-of-two OP_[IL]REM_IMM.
2014-06-27 03:44:22 +02:00
Zoltan Varga 9b0fcf35a8 [sdb] Avoid running tests in the 2.0 profile. 2014-06-27 02:02:16 +02:00
Mark Probst 515350999b [jit] Portably decompose power-of-two OP_[IL]REM_IMM.
Instead of generating a sequence of AMD64 instructions for
power-of-two OP_[IL]REM_IMM, portably decompose them to intermediate
code.

OP_IREM_IMM is decomposed on 32 and 64 bit archs, OP_LREM_IMM only on
64 bit archs.
2014-06-26 15:26:38 -07:00
Alex Rønne Petersen 1dd682eb3c Merge pull request #1130 from akoeplinger/descriptive-tests
[System] Make tests more descriptive on failure
2014-06-26 21:01:19 +02:00
Alexander Köplinger 4d93cac6d7 [System] Make tests more descriptive on failure
By using StringAssert we get a more descriptive error message when the test fails, i.e. the expected vs. the actual string value instead of just true/false.
2014-06-26 20:58:15 +02:00
Mark Probst 3451058c52 Merge pull request #1128 from ludovic-henry/pr19g-sgen-grayqueue
[sgen-gray-queue] Use a cursor based accessing pattern to reduce memory indirection
2014-06-26 11:46:53 -07:00
Alex Rønne Petersen 3d3da63af5 [System] Up the timeout in the BeginConnectMultiple test to 30s.
Most Linux systems have the net.ipv4.tcp_syn_retries sysctl
set to 5 or 6, so we need at least 30 seconds here.
2014-06-26 20:40:06 +02:00
Oleg Stepanischev f7b81bda13 Added fix for Bug 20869 2014-06-26 22:24:34 +04:00
Rolf Bjarne Kvinge 4c756653a6 [Mono.Data.Sqlite] Add support for Scalar and Aggregate functions in Xamarin.iOS. 2014-06-26 19:07:55 +02:00
Marek Safar d151adb4fe [corlib] Update racy test 2014-06-26 17:20:29 +02:00
Marek Safar a58750d9ac [mcs] Emit correct attribute reference when async lambda ends up in nested type. Fixes #20849 2014-06-26 17:20:29 +02:00
Marek Safar 8d282b527e [corlib] Fix typo 2014-06-26 17:20:29 +02:00
Marek Safar 37e584789e [mcs] Fix local exits from try-finally scope with awaited statements 2014-06-26 17:20:29 +02:00
Jonas 'Sortie' Termansen a4f87aef0e Print pid_t's portably in mono/metadata/attach.c
The pid_t type is required by POSIX to be a signed integer type (and that it
isn't wider than long in at least one programming environment). Mono has a
bunch of issues with 64-bit pids at the present, this is a start. Cast the
pid to the largest available signed type before printing it.

This change is released under the MIT/X11 license.
2014-06-26 10:59:10 -04:00
Jonas 'Sortie' Termansen 1e35e62d1c Avoid non-standard BSD types in mono/io-layer/wapi_glob.c
The u_char, u_short and u_int types are non-standard and no system headers
are required to provide them. There are no particular use for them and the
builtin standard types will do just as well.

This change is released under the MIT/X11 license.
2014-06-26 10:58:59 -04:00
Jonas 'Sortie' Termansen a869ac45ab Restore the null garbage collector
I had to use the null garbage collector due to boehm being troublesome. The
code appears unmaintained but I can see a recent git commit enabled support
again. However, I had to do more than that to get it working. I'm really not
sure how semantically correct this is and it needs review from an expert in
how threads and garbage collection interplay in Mono. It seems very odd that
various attributes (such as its short id) about the main thread is
initialized as a side effect of initializing the garbage collection. The
mono_thread_info_attach was needed to prevent a crash.

This change is released under the MIT/X11 license.
2014-06-26 10:53:22 -04:00
Jonas 'Sortie' Termansen 325982b65f Remove Mono_Posix_Syscall_utimes_bad
Welcome to the world of tomorrow! It's been almost a decade since this was
made obsolete in 2005. Nothing uses this function any longer. Additionally
it is completely broken as utimes takes a pointer to an array with two
timevals, but the code passes only a pointer to a single timeval.

This change is released under the MIT/X11 license.
2014-06-26 10:52:53 -04:00
Jonas 'Sortie' Termansen 8305af7c9b Remove test whether thread-local storage works in shared libraries
This test was added in 2004 to work around buggy Linux distributions and is
not needed today. The test caused problems as it also ran on non-Linux
operating systems and assumed dynamic linking was available. This caused it
to mistakenly decide thread-local storage was unavailable on operating
systems with no dynamic linking (but perfectly usable thread-local storage).

This change is released under the MIT/X11 license.
2014-06-26 10:10:51 -04:00
Jonas 'Sortie' Termansen dd412cfb2e Don't touch internal feature macros in eglib
The __USE_GNU macro is an internal macro used by glibc to enable the GNU
extensions. Programs are instead meant to use the _GNU_SOURCE macro before
including any system header.

This change is released under the MIT/X11 license.
2014-06-26 10:09:15 -04:00
Jonas 'Sortie' Termansen 82364ccaaa Use SIGPROF only if it is available
The SIGPROF signal is an XSI option and obsolescent in XSI. POSIX systems
are not required to have it.

This change is released under the MIT/X11 license.
2014-06-26 10:09:08 -04:00
Jonas 'Sortie' Termansen b564bf4919 Use memset instead of bzero
There is no standard bzero function, only the standard memset function, and
Mono does not declare its own bzero function.

This change is released under the MIT/X11 license.
2014-06-26 10:08:59 -04:00
Jonas 'Sortie' Termansen 4ea1407655 Remove MONO_SIZEOF_SUNPATH
The configure script determines the size of the sun_path member in struct
sockaddr_un. However the test is broken during cross-compilation (with a
comment that there is no macro to determine the size of struct members at
configure time) and MONO_SIZEOF_SUNPATH defaults to 0 (leading to buffer
underflows and overflows). There is no reason to determine this at configure
time when a simple traditional sizeof will do the job at compile time.

This change is released under the MIT/X11 license.
2014-06-26 10:08:54 -04:00
Jonas 'Sortie' Termansen 37acf9e69c Use MAP_FAILED instead of (void*)-1
The MAP_FAILED macro is the standard return value of mmap() upon failure and
it is allowed to have other values than (void*)-1.

This change is released under the MIT/X11 license.
2014-06-26 10:00:03 -04:00
Jonas 'Sortie' Termansen ba1b74d003 Avoid unused function warning in mono/profiler/proflog.c
The dump_ubin function is only used by the elf_dl_callback function. It
should be wrapped in the same #if conditional to avoid a warning if the
preprocessor conditional isn't true.

This change is released under the MIT/X11 license.
2014-06-26 09:59:56 -04:00
Jonas 'Sortie' Termansen bdcc267c59 Avoid unused function warning in mono/io-layer/io.c
The get_fstypename function is only used by the GetVolumeInformation
function. It should be wrapped in the same #if conditional to avoid a
warning if the preprocessor conditional isn't true.

This change is released under the MIT/X11 license.
2014-06-26 09:59:48 -04:00
Jonas 'Sortie' Termansen 05fb00fad6 Use S_IWUSR instead of S_IWRITE
The S_IWRITE macro is a non-standard macro provided by some operating
systems for compatibility with BSD. POSIX specifics a standard macro with
identical semantics with the name S_IWUSR.

This change is released under the MIT/X11 license.
2014-06-26 09:59:24 -04:00
Jonas 'Sortie' Termansen e9a8ca77f1 Get struct timespec from <time.h> in mono/io-layer/misc-private.h
POSIX defines struct timespec in time.h and struct timeval in sys/time.h.
Some operating systems have merged these headers, but this isn't required or
encouraged by POSIX.

This change is released under the MIT/X11 license.
2014-06-26 09:59:17 -04:00
Jonas 'Sortie' Termansen 984de6388c Remove unnecessary <sys/syscall.h> inclusion
Only mono/metadata/icall.c and mono/metadata/filewatcher.c include the
mono/metadata/filewatcher.h header and none of them depend on the contents
of the non-standard header <sys/syscall.h>.

This change is released under the MIT/X11 license.
2014-06-26 09:59:06 -04:00
Jonas 'Sortie' Termansen c765c61f57 Only include the <sys/param.h> header if available
The <sys/param.h> header is non-standard and usually not required if it isn't
available.

This change is released under the MIT/X11 license.
2014-06-26 09:57:42 -04:00
Jonas 'Sortie' Termansen 6479266304 Use <poll.h> to get poll rather than <sys/poll.h>
POSIX specifies <poll.h> as the standard header that declares the poll
function. Many systems provide <sys/poll.h> to be compatible with historical
practice. Prefer the <poll.h> header over <sys/poll.h> if it is available.

This change is released under the MIT/X11 license.
2014-06-26 09:57:34 -04:00
Jonas 'Sortie' Termansen 3512f22ee7 Use <sys/select.h> to get select
POSIX mandates that select is declared in <sys/select.h> (and in the header
<sys/time.h> for compatibility). It would be best to include the new header
if it is available. This is already done throughout the source tree, though
not in all instances.

This change is released under the MIT/X11 license.
2014-06-26 09:57:18 -04:00
Ludovic Henry 748ca8163b [sgen-gray-queue] Add heavy statistics for allocation, and enqueue/dequeue fast/slow paths 2014-06-25 17:40:08 -07:00
Ludovic Henry b1be64cb18 [sgen-gray-queue] Remove compilation warning in mini-gc.c : redefinition of typedef 'mword' 2014-06-25 17:40:08 -07:00
Ludovic Henry f2a6fb719d [sgen-binprot,sgen-gray-queue] Add binary_protocol_gray_(en|de)queue and call them on object enqueuing and dequeuing 2014-06-25 17:40:07 -07:00
Ludovic Henry 470dd7b570 [sgen-protocol] Avoid multiple inclusion of sgen-protocol.h 2014-06-25 17:40:06 -07:00
Ludovic Henry 29a63c160b [sgen-gray-queue] Add macros to compute first and last cursor position address on a section 2014-06-25 17:40:05 -07:00
Ludovic Henry f80999e89b [sgen-gray-queue] Transform GRAY_OBJECT_(EN|DE)QUEUE to always inlined functions 2014-06-25 17:40:05 -07:00
Ludovic Henry 73121dcdc9 [sgen-gray-queue] Change from index based to cursor based gray queue access to current element
This patch consist in changing the way we access the current element value in the gray queue. Before, we would save the index of the last element in the queue, then to access to the current value, we would have to make 2 memory access + 1 array offset access. Now we store a pointer to the current element, so we only need 1 memory access, thus reducing the number of memory indirection. We see ~25% speed improvement in major gc collection time on gc-graystack-stress test.
2014-06-25 17:39:54 -07:00
Ludovic Henry 79a9694861 [sgen-gray-queue] Add graystack stress test 2014-06-25 17:08:52 -07:00
Zoltan Varga ddfd29c85c [jit] Add a MONO_ARCH_HAVE_OP_LREM_IMM define instead of using TARGET_AMD64. 2014-06-25 19:34:55 +02:00
Joao Matos 256a379643 Fixed compiler warning introduced in the last commit about redefining typedefs.
Redefinition of typedef 'foo' is a C11 feature [-Wtypedef-redefinition].
2014-06-25 18:26:43 +01:00
Joao Matos 0b4a34433b Fixed Mono includes to be able to be included independently. 2014-06-25 16:57:16 +01:00
Joao Matos 1cf398ae57 Cleaned up C++ keywords in Mono metadata headers. 2014-06-25 16:57:06 +01:00
Marek Safar f3760960d6 [corlib] Enum::TryParse ignores leading whitespaces. Fixes #20870 2014-06-25 17:31:03 +02:00
Marek Safar d27b129837 [mcs] Fix array access of value type compound assignment with awaited argument 2014-06-25 17:31:03 +02:00
Marek Safar 091b1b5770 [xbuild] Add 4.5.1 framework. Fixes #20827 2014-06-25 17:31:02 +02:00
Marek Safar 4b3572d4a6 [mcs] Allow unsafe code in async block when scope does not need variable capturing 2014-06-25 17:31:02 +02:00
Alex Rønne Petersen 429cdf17cf [System.Web] Disable AppResourcesCompilerTest for now.
This is a stopgap measure: This test hangs a *lot* on Jenkins
and it's only being disabled to get stable-ish builds. It's
being actively investigated still.
2014-06-25 13:22:35 +02:00
Marek Safar f6da699cb6 [mcs] Add experimental value changes notifications to evaluator 2014-06-25 08:50:31 +02:00
Marek Safar c72443eea7 [mcs] Handle side effect constants in await context 2014-06-25 08:50:31 +02:00
Zoltan Varga 90513b115a Fix a warning. 2014-06-25 02:13:10 +02:00
Zoltan Varga 5e761c8175 Merge pull request #1126 from schani/feature-fast-lrem-imm
[amd64] Fast OP_LREM_IMM for power of two operands.
2014-06-25 02:03:20 +02:00
Mark Probst 8580919c1b [amd64] Fast OP_LREM_IMM for power of two operands.
This was the reason for one of our bad performance results in the
paper "Clash of the Lambdas" by Biboudis, Palladinos, Smaragdakis:

http://cgi.di.uoa.gr/~biboudis/clashofthelambdas.pdf
2014-06-24 16:04:26 -07:00
Zoltan Varga 39d07051cf [aot] Fix the decoding of MonoJitInfo. Fixes #16439. 2014-06-25 00:49:07 +02:00
Mark Probst d280b9c122 [sgen] Binary protocol freeing whole M&S blocks. 2014-06-24 10:02:18 -07:00
Mark Probst ad32d49ad7 [sgen] Nicer sgen-grep-binprot output.
Indent events that are always printed so that the ones we're grepping
for are more easily recognized.
2014-06-24 10:02:17 -07:00
Jeffrey Stedfast 10fa44a5e6 Merge pull request #995 from yjoly/master
Fix the date time set in file by removing the ':'.
2014-06-24 11:07:35 -04:00
Marek Safar a58aeafe1d [corlib] Fix racy test 2014-06-24 14:20:16 +02:00
Marek Safar bfa0db9efa [System.Net.Http] Fix disposing of DelegatingHandler. Fixes #20818 2014-06-24 14:20:16 +02:00
Marek Safar 4e937922fa [mcs] Emit side effects of reduced probing expression 2014-06-24 14:20:15 +02:00
Marek Safar 675203a9b7 [mcs] Fix emit of array access with awaited indexer expression and result field write. 2014-06-24 14:20:15 +02:00
Marek Safar b3e65f596d [mcs] Fix scope initialization for exception filters using hoisted lambdas with awaited catch clause 2014-06-24 14:20:15 +02:00
Marek Safar 6d032de710 [mcs] Recognize await as simple name in type context 2014-06-24 14:20:15 +02:00
Alex Rønne Petersen 18bf2e6869 Add a section to CONTRIBUTING.md on inactivity. 2014-06-24 11:12:08 +02:00
Ivo Smits 0e2f0a23b6 Fixed NullReferenceExcepton in Socket.Connect for non-IP endpoints
Socket.Connect(EndPoint) throws a NullReferenceException when connecting to non-IP (eg Unix) endpoints in Dgram mode.
2014-06-24 00:21:06 +02:00
Mark Probst 2d3735c6a6 [sgen] Don't crash for describe_ptr() when there's no bridge processor. 2014-06-23 13:18:35 -07:00
Chris Hamons 90162e5201 Fix Mono.Linker.csproj so it can build
Mono.Linker.csproj has drifted from its associated Makefile was was not buildable.
This change applies changes from the last few Makefile changes.
2014-06-23 10:32:39 -05:00
Marek Safar 3c2f52ef67 [corlib] Fix race in unit test 2014-06-23 14:30:02 +02:00
Marek Safar 41a903da83 [mcs] Handle try await nested in multiple finally blocks. 2014-06-23 14:17:05 +02:00
Alex Rønne Petersen 1633666e82 [corlib] Disable TaskContinuationChainLeak test on non-mobile too. 2014-06-23 14:11:40 +02:00
Alex Rønne Petersen 4ae5924002 Merge pull request #1123 from akoeplinger/fix-webreq-test
[System] Use the same port number instead of a random port in HttpWebRequestTest
2014-06-23 04:06:46 +02:00
Zoltan Varga 6a197bad93 Fix a warning. 2014-06-22 21:38:24 +02:00
Alexander Köplinger 7b5f4a511f [System] Use the same port number instead of a random port in HttpWebRequestTest
A random port doesn't add any value and resulted in at least one port conflict on monojenkins:
http://monojenkins.cloudapp.net/job/Mono/243/testReport/MonoTests.System.Net/HttpWebRequestTest/BeginGetRequestStreamCancelIfNotAllBytesWritten/
2014-06-22 20:10:17 +02:00
Alex Rønne Petersen 8c3ec62481 Merge pull request #1121 from inkdev/master
Fix MSVC build
2014-06-22 16:30:53 +02:00
i59 1dba47fa44 libmono.vcxproj: Link to libmonoruntimesgen.lib in the Release_SGen mode
Previously attempted to link to the libmonoruntime library outputted by the boehm configuration
2014-06-22 16:24:46 +02:00
i59 2bb991cc21 Added file-mmap-windows.c to libmonoruntime.vcxproj 2014-06-22 16:23:16 +02:00
i59 d0feb53196 Moved _WIN32_WINNT to winconfig.h; dropped support for WinXP SP1 and below
Win32 compilation was broken due to attempting to use Interlocked* functions introduced with XP SP2.
2014-06-22 16:21:29 +02:00
i59 daa5a50f41 libmonoutils: Removed need for X64 MASM definition
Check for availability of the RAX register, checking if we're running x64
2014-06-22 16:19:52 +02:00
Alex Rønne Petersen afa2f52e54 Merge pull request #1118 from kitsilanosoftware/udp-client-test-check-ipv6
[System.Net] Do not assume IPv6 is enabled in UdpClientTest
2014-06-21 23:45:54 +02:00
Alex Rønne Petersen 470b80cdfd Merge pull request #1119 from akoeplinger/fix-currencymanager
[Managed.Windows.Forms] Revert a revert commit that accidentally changed the wrong code
2014-06-21 23:45:03 +02:00
Zoltan Varga 50426fe3fd [llvm] Update the LLVM backend to llvm ca4e226df2e13a9e87376a880035efa376639c98. 2014-06-21 18:40:05 +02:00
Alexander Köplinger 1d9a3dc83c [Managed.Windows.Forms] Added more asserts to the CurrencyManagerTest2 test
These were useful while investigating 4b50211fb7
2014-06-21 16:51:09 +02:00
Alexander Köplinger 4b50211fb7 [Managed.Windows.Forms] Revert a revert commit that accidentally changed the wrong code
When the commit 8334fe3a56 was reverted in a791cfc164, accidentally the wrong chunk of code was changed.

This commit reverts the changes correctly.
2014-06-21 16:37:34 +02:00
Zoltan Varga 9daad272b1 [llvm] Remove a small source workaround which is no longer needed. 2014-06-21 15:42:21 +02:00
Reuben Bond eeac252404 Test ClientWebSocket.SendAsync EndOfMessage 2014-06-21 14:57:56 +10:00
Alex Rønne Petersen f2261b6786 Merge pull request #1117 from akoeplinger/fix-databindingsource
[Managed.Windows.Forms] Verify that DataMember is valid when setting DataSource
2014-06-20 20:48:21 +02:00
Damien Diederen 3d21e9cd2f [System.Net] Do not assume IPv6 is enabled in UdpClientTest
Without this, three of the tests fail on Linux kernels without IPv6
support.

This is a minimal fix, copy'n'pasting a conditional which was used in
other tests.  It might be nicer to factor out the SupportsIPv6 to its
own utility function.
2014-06-20 18:45:35 +02:00
Alexander Köplinger f71a3c2683 [Managed.Windows.Forms] Verify that DataMember is valid when setting DataSource
When DataMember is already set before DataSource we need to verify that it refers to a valid property in the DataSource setter, otherwise we'd get an exception in ResetList ().
This fixes the following failing tests: BindingSourceTest.DataMemberBeforeDataSource and BindingSourceTest.DataSourceAssignToDefaultType.

Commit licensed under MIT/X11.
2014-06-20 16:45:38 +02:00
Reuben Bond bbbe1e52d3 ClientWebSocket: SendAsync endOfMessage inverted.
endOfMessage should indicate whether or not additional message parts will follow the current one. Currently, the meaning in ClientWebSocket.cs is inverted: !endOfMessage indicates that no more parts will follow the current one.

See the WebSockets RFC, 'frame-fin' at the top of http://tools.ietf.org/html/rfc6455#page-31.
Also see the MSDN docs for SendAsync: http://msdn.microsoft.com/en-us/library/system.net.websockets.websocket.sendasync(v=vs.110).aspx
2014-06-20 16:48:36 +10:00
Alex Rønne Petersen e385d1f039 Fix the build. 2014-06-20 04:17:30 +02:00
Alex Rønne Petersen 7461128a7d Silence a warning in file-mmap-posix.c. 2014-06-20 04:12:11 +02:00
Alex Rønne Petersen e437882c77 Merge pull request #1113 from akoeplinger/fix-cache-test
[System.Runtime.Caching] Fixed test that failed intermittently on slow systems
2014-06-20 03:26:29 +02:00
Alex Rønne Petersen 6d69a0674b [MWF] Disable OneIdlePerThread test.
The code that made this test work was reverted, so this test is
bound to fail randomly.
2014-06-20 03:25:01 +02:00
Alexis Christoforides 5bdff7c7e9 Added test for bug #20672 (fixed in aeab5b5902) 2014-06-19 19:49:33 -04:00
Rodrigo Kumpera 2bf354ca84 [runtime] Rework named mapping to use an unlinked file to provide correct mapping semantics.
Instead of using mono_valloc we create a temp file and unlink it. With this we can have the right
mmap semantics regarding CoW and access rights.

This does simplify the code too by completely removing the mapping kind.
2014-06-19 19:10:39 -04:00
Rodrigo Kumpera 1d2e26c1ee [runtime] Fix error handling with named memory regions. 2014-06-19 19:10:39 -04:00
Rodrigo Kumpera 8cd47821b9 [runtime] Make it possible to create views to magic zero size files such as /dev/zero. Fixes #19460 2014-06-19 19:10:39 -04:00
Rodrigo Kumpera c92dfa2731 [runtime] Define DEFFILEMODE to 0666 if not defined. 2014-06-19 19:10:38 -04:00
Alex Rønne Petersen 17d6f1cbb8 [MWF] Disable DataRemainsOnClipboard_Xamarin4959 test.
It works fine on a regular system but breaks under Xvfb.

http://monojenkins.cloudapp.net/job/Mono/230/testReport/MonoTests.System.Windows.Forms/ClipboardTest/DataRemainsOnClipboard_Xamarin4959/
2014-06-19 23:58:05 +02:00
Miguel de Icaza 8d15c21023 [WCF] Make BasicHttpBinding.AllowCookies work
This patch is from Brendan Zagaeski and fixes bug 11307

The description of the problem was:

In Mono 2.10.12, the BasicHttpBinding property no longer supports
EnableHttpCookieContainer because it is Depreciated. The replacement
is AllowCookies, but this property does not work. Upon inspection of
the source source, we find that the HttpCookieContainerBindingElement
is added in accordance with EnableHttpCookieContainer, but not
AllowCookies.

The conditional compile logic at [1] is no longer needed for
Xamarin.iOS or Xamarin.Android.
2014-06-19 17:45:15 -04:00
Alexander Köplinger 98513c62ec [System.Runtime.Caching] Fixed test that failed intermittently on slow systems
Apparently on slow systems the items with 1sec expiration time are already removed from the cache by the time the #CS3 Assert() is hit, which caused the test to fail.
Increasing the expiration time by +2sec should hopefully fix this.

Commit licensed under MIT/X11.
2014-06-19 21:54:02 +02:00
Alex Rønne Petersen 3e1d41ab5d Also disable generic-xdomain.2.exe in gsharing tests. 2014-06-19 21:52:38 +02:00
Zoltan Varga 15c725c674 [runtime] Free static bound delegate wrappers of dynamic methods. Fixes #19058. 2014-06-19 20:58:24 +02:00
Rodrigo Kumpera c5771113c2 [runtime] Don't perform double accounting of offset for named memory segments. Fixes #20591 2014-06-19 14:32:48 -04:00
Rodrigo Kumpera e41cdd1666 Merge pull request #946 from akoeplinger/fix-mono-parallel
[Mono.Parallel] Removed broken Mono.Threading.Tasks code
2014-06-19 11:46:06 -04:00
Rodrigo Kumpera 21f79f8d6e Merge pull request #1074 from esdrubal/bug18421
Changed TryPeek to handle race condition with Dequeue.
2014-06-19 11:45:17 -04:00
Marek Safar feec628026 [xbuild] Parsing conditions with property references. Fixes #20634 2014-06-19 17:28:52 +02:00
Miguel de Icaza 3ee57747e4 Revert change that introduces a new undocumented environment variable 2014-06-19 09:34:59 -04:00
Marek Safar 357e5fe0ee [xbuild] Implements property functions using constructor syntax. Fixes #12999 2014-06-19 14:59:17 +02:00
Alexis Christoforides aeab5b5902 [System.ComponentModel] BindingList.ListChanged now attempts to provide a PropertyDescriptor when possible.
BindingList subscribes to PropertyChanged events of eligible contained objects. Iff the PropertyName provided is valid,
the list event's ListChangedEventArgs will also contain a PropertyDescriptor.

This is to match MS behavior.
2014-06-18 22:11:43 -04:00
Alex Rønne Petersen f777bc37a4 Merge pull request #1109 from adbre/iss358
Override registry storage with MONO_CURRENTUSER_REGISTRY_PATH
2014-06-19 02:34:53 +02:00
Alex Rønne Petersen 83a34c40c6 [ppc] Bump instruction sizes after 51c454f6b0. 2014-06-18 21:30:30 +02:00
Jonathan Pryor b9afa88209 Merge pull request #1014 from txdv/master
Expose full epoll_ctl functionality.
2014-06-18 15:21:05 -04:00
Alex Rønne Petersen a2fa438af6 Merge pull request #1110 from tpokorra/FixImageListStreamerGeneratingValidResourcesForMSNet
Fixing ImageListStreamer generating winform resource files that work on MS.Net
2014-06-18 21:02:38 +02:00
Iain Lane 2f3d0439a2 Override registry storage with MONO_CURRENTUSER_REGISTRY_PATH
https://bugzilla.xamarin.com/show_bug.cgi?id=358
2014-06-18 21:00:44 +02:00
Alex Rønne Petersen 383d23d87a Merge pull request #1111 from akoeplinger/add-gtk-dllmap
Added dllmap for libgtk-x11 and libgdk-x11
2014-06-18 17:21:03 +02:00
Alexander Köplinger df49c2d640 Added dllmap for libgtk-x11 and libgdk-x11
Commit licensed under MIT/X11.
2014-06-18 17:18:08 +02:00
Andrius Bentkus b8d5a800f8 Expose full epoll_ctl functionality.
Now the user has access to all struct elements in EpollEvent when
using epoll_ctl. This is in particular very intersting when the
user wants to access the ptr field.

The user can use GCHandle.ToIntPtr to give the struct a GCHandle
and then handle the pointer later on when using epoll_wait.
2014-06-18 18:06:44 +03:00
Timotheus Pokorra cfa3d9898a ImageListStreamer generates winform resource files that work on Mono but fail on Microsoft.net
with exception System.InvalidOperationException: Loading of the ImageList did not succeed.
see bug https://bugzilla.xamarin.com/show_bug.cgi?id=3841 for detailed analysis
2014-06-18 16:33:31 +02:00
Alex Rønne Petersen 51c454f6b0 [ppc] Add missing sync instructions to atomic opcodes.
Note that lwarx and stwcx don't produce the necessary
load/store barrier that's needed to conform to the
`Interlocked` API.
2014-06-18 16:08:14 +02:00
Alexander Köplinger db9f761a78 Fixed another 8080 test port
I missed that one in f396d37c54.
2014-06-18 10:01:36 +02:00
Alex Rønne Petersen e761d7d521 Silence a warning in file-mmap-posix.c. 2014-06-18 02:38:52 +02:00
Alex Rønne Petersen 5780ee5fd3 Merge pull request #1108 from akoeplinger/change-test-ports
[System.ServiceModel] Changed test port from 8080 to 30158
2014-06-17 23:05:04 +02:00
Alexander Köplinger f396d37c54 [System.ServiceModel] Changed test port from 8080 to 30158
Port 8080 is widely used and resulted in address conflicts on monojenkins, so we use a different port instead.

Commit licensed under MIT/X11.
2014-06-17 23:00:42 +02:00
Zoltan Varga cc0a7a9516 [aot] Add support for overriding the alignment calculations done by the runtime during AOT. This is needed because the alignment of some types, notable i8/double can be different between the host and the target platform. 2014-06-17 20:43:55 +02:00
Alex Rønne Petersen 9f3e361cfb Disable generic-xdomain.2.exe on CI as it occasionally hangs. 2014-06-17 17:55:29 +02:00
Alex Rønne Petersen fb36574f62 Merge pull request #1106 from akoeplinger/fix-winforms-tests
[Managed.Windows.Forms] Fixed System.Resources tests that relied on DummyAssembly
2014-06-17 17:47:45 +02:00
Alex Rønne Petersen 228f23886d Merge pull request #1107 from akoeplinger/fix-numericupdown
[Managed.Windows.Forms] Fix 'minimum' default value of NumericUpDown
2014-06-17 17:46:56 +02:00
Alexander Köplinger b66e06d51c [Managed.Windows.Forms] Fix 'minimum' default value of NumericUpDown
The 'minimum' default value of NumericUpDown was set to 0.0M, which caused the ToString() to format it as "0.0" instead of "0" as it does on .NET.
A similar change was done for the 'maximum' default value already in f6c8d48a3a.

Commit licensed under MIT/X11.
2014-06-17 17:35:46 +02:00
Marek Safar d14176dd3f [mcs] Implements finally execution for await with try block exit. 2014-06-17 16:45:08 +02:00
Alexander Köplinger 8fb625e06d [Managed.Windows.Forms] Fixed System.Resources tests that relied on DummyAssembly
Several System.Resources tests rely on a DummyAssembly.dll, which was removed in 016b0b5170 (possibly by accident?).
This commit adds the assembly back.

Commit licensed under MIT/X11.
2014-06-17 13:51:20 +02:00
Atsushi Eno eeb5fe56f7 Revert "[msbuild] fix some weird local result variable initialization issue."
This reverts commit 76b08f12ef.
2014-06-17 13:59:01 +09:00
Zoltan Varga 2ddfbf51f6 Merge pull request #1103 from nathanaeljones/patch-1
Fix AddCacheDependency signature to use params
2014-06-16 23:26:28 +02:00
Zoltan Varga 62bef77ea0 [runtime] Add a workaround to file-mmap-posix.c to fix the android build. 2014-06-16 23:10:13 +02:00
Zoltan Varga 161e57021c [aot] Use g_print instead of printf in one place since the former works on android. 2014-06-16 22:25:54 +02:00
Zoltan Varga 3c2c696ad0 [arm] Fix alignment problems when AOTing from osx to arm linux. 2014-06-16 22:25:12 +02:00
Alex Rønne Petersen 959a4de741 Merge pull request #1104 from tpokorra/TarballIncludeMoreDllsInMonoLite
Tarball: include System.Security.dll and System.Configuration.dll in monolite directory
2014-06-16 21:49:08 +02:00
Timotheus Pokorra 3432138155 Tarball: include System.Security.dll and System.Configuration.dll in monolite directory
this is related to commit https://github.com/mono/mono/commit/993f4773638bcb36abf8b9660ee737d6445c5200
2014-06-16 21:11:26 +02:00
Zoltan Varga 8f4cb8ed33 [bcl] Fix the mobile build. 2014-06-16 19:06:41 +02:00
Nathanael Jones 2feb372609 Fix AddCacheDependency signature to use params
The .NET AddCacheDependency method signature is `public void AddCacheDependency(params CacheDependency[] dependencies);` Mono should mirror the signature (even if it isn't implemented) to prevent build errors. Conditional code, of course, will need to be used for an alternative mono path.
2014-06-16 18:43:28 +02:00
Alex Rønne Petersen f56aeff39a Merge pull request #1102 from tpokorra/TarballFixAvoidCDataTextReaderTests
Remove a reference to the file AvoidCDataTextReaderTests.cs so that tarballs can be built again
2014-06-16 16:11:43 +02:00
Timotheus Pokorra c419208296 Remove a reference to the file AvoidCDataTextReaderTests.cs so that tarballs can be built again.
The file was removed in https://github.com/mono/mono/commit/d8d1b0be6baf6f8881871592b040d85be790926c
2014-06-16 16:03:46 +02:00
Alex Rønne Petersen e0747e6952 Merge pull request #1101 from jariq/master
Support both unencrypted PKCS#12 and PKCS#12 encrypted with an empty pas...
2014-06-16 14:54:30 +02:00
Marek Safar 8826a3bb45 [mcs] Run new initializer await checks only in async context. Fixes #20614 2014-06-16 14:13:40 +02:00
Marek Safar 8f53ba7970 Merge pull request #1099 from jsportaro/master
Added fix for Bug 11630
2014-06-16 12:52:45 +02:00
Marek Safar 94f466897f [system.data] Parse numeric expressions using invariant culture. Fixes #20582 2014-06-16 12:07:25 +02:00
Marek Safar e579555a53 [mcs] Reachability analysis should ignore local variables declarations. Fixes #20603 2014-06-16 11:56:57 +02:00
Zoltan Varga b124f29f83 Merge pull request #1100 from BrzVlad/master
[x86] Fix initialization of stackalloc-ed memory in no pushes mode.
2014-06-15 12:34:45 +02:00
Zoltan Varga eed0a5d920 [runtime] Enable support for arm64-darwin in dolt. 2014-06-15 00:41:28 +02:00
Jaroslav Imrich d798c91b01 Support both unencrypted PKCS#12 and PKCS#12 encrypted with an empty password in X509Certificate2 constructor 2014-06-15 00:32:15 +02:00
Brezae Vlad a6df42cfa9 [x86] Align stackalloc-ed memory in no pushes mode. 2014-06-15 00:07:52 +03:00
Zoltan Varga 79e70b4692 [arm] Add an enum for gsharedvt argument marshalling conventions. 2014-06-14 22:40:16 +02:00
Brezae Vlad b152bc9f1c [x86] Fix initialization of stackalloc-ed memory in no pushes mode. 2014-06-14 00:43:12 +03:00
Larry O'Brien d8d1b0be6b Monodoc: Fix for CDATA bug (https://bugzilla.xamarin.com/show_bug.cgi?id=17850). Reverts 3f361e1a26
Removed code that stripped CDATA statements (but not blocks) from input when showing a namespace page:

The function Ecma2Html.WrapStream(TextReader,Dictionary<String,String>) very explicitly returns a new `AvoidCDataTextReader` when the system is showing a namespace. The `AvoidCDataTextReader` strips the CDATA statement, but not it's internal contents. The intent, according to AvoidCDataTextReaderTests, is to allow class summaries of this form:

"<elements><summary>Addressbook APIs.</summary><remarks /><class name=""ABAddressBook"" fullname=""MonoTouch.AddressBook.ABAddressBook"" assembly=""monotouch""><summary><![CDATA[
      Provides access to the system Address Book.]]>
    </summary></class></elements>"

But that form is not desired.

The bug arose because the input to `WrapStream` is very large (it actually includes the entire *description* for each class and member in the namespace!). If any CDATA-block contained entities such as, e.g., < or >, the resulting XML would (obviously) be ill-formed:

"<xml>This should be valid <![CDATA[<T>]]> </xml>"

would throw because the <T> would be attempted to be parsed as XML. Obviously, samples that contain generics or lambda or XAML would cause this problem.

Although an XMLException was thrown, Macdoc swallows the exception in DocTools.GetHTML(). That is why this caused a silent failure on macdoc and was visible on Webdoc.
2014-06-13 11:13:24 -10:00
Rodrigo Kumpera 66aaa61cb7 [System.Core] Add new tests for MemoryMappedFile. 2014-06-13 14:53:34 -04:00
Rodrigo Kumpera c5c1dc716e [runtime] Fix share/private flags when doing file mmap. 2014-06-13 14:35:55 -04:00
Rodrigo Kumpera 59fd337839 [runtime] Rewrite MemoryMappedFile to support named mappings. 2014-06-13 12:17:27 -04:00
Joseph Portaro 159f2dc89d Added fix for Bug 11630 2014-06-13 11:55:37 -04:00
Marek Safar 429c2c7f42 [mcs] Always store hidden catch variable when clause contains await 2014-06-13 17:39:11 +02:00
Marek Safar 9fba495639 [corlib] Set AggregateException message text in all overloads 2014-06-13 17:39:10 +02:00
Marek Safar 66a9644ee8 [mcs] Emit correct value type collection initialization when second initializer uses await 2014-06-13 17:39:10 +02:00
Marek Safar 3f6b2feebd [mcs] Keep stack populated when array initializer contains await 2014-06-13 17:39:10 +02:00
Zoltan Varga 805bcf7e82 [x86] Pop the vtype return addr from the stack in no pushes mode too. 2014-06-13 16:23:35 +02:00
Alex Rønne Petersen bd6089a84a Merge pull request #1098 from tpokorra/TarMissing_vasprintfh
tarball is missing file vasprintf.h
2014-06-13 16:21:20 +02:00
Timotheus Pokorra 5e2cd9c29f since gerror.c requires vasprintf.h, we need to add that file so that it becomes part of the tarball 2014-06-13 16:15:19 +02:00
Zoltan Varga a3f242b793 [x86] Reduce some code duplication in the x86 call opcodes. 2014-06-13 15:55:49 +02:00
Alex Rønne Petersen 93f8df65f9 Disable push-less x86 code for now.
Breaks stuff: https://wrench.mono-project.com/Wrench/ViewLane.aspx?lane_id=10&host_id=8&revision_id=68534
2014-06-13 15:32:42 +02:00
Zoltan Varga a0448cd729 Merge pull request #1097 from BrzVlad/master
[jit] Fix bug when using pushless code and reenable the feature.
2014-06-13 13:15:03 +02:00
Marek Safar 74b24b0e55 [mcs] Handle catch filter with await-ed rethrow and exception filters 2014-06-13 11:22:03 +02:00
Brezae Vlad 9ae8e72ceb [jit] Fix bug when using pushless code and reenable the feature. 2014-06-12 21:48:51 +03:00
Marek Safar a97fb68e66 [mcs] Add support for await in finally clause 2014-06-12 17:46:55 +02:00
Jeffrey Stedfast eab18c98cb [Mono.Debugger.Soft] Handle cases where the instruction list is empty 2014-06-11 18:27:15 -04:00
Zoltan Varga 254c71b060 [jit] Don't emit a write barrier when writing to the delegate->method field, its not needed. 2014-06-11 19:09:13 +02:00
Martin Baulig bad5ef8453 [Http]: Fix a potential race condition in the WebConnectionGroup's connection list.
Remove the "ConnectionState" from the connection list before closing the connection,
this should avoid ServicePoint.SendRequest() ever crashing with a NullReferenceException
due to getting a null return value from WebConnectionGroup.GetConnection().
2014-06-11 19:07:15 +02:00
Marek Safar 7347c5a195 [mcs] Check for missing dependencies of container types. Fixes #20382 2014-06-11 15:13:00 +02:00
Marek Safar 1e4fd01f6d [mcs] Resolve event expression when testing left side expression. Fixes #20493 2014-06-11 14:24:34 +02:00
Marek Safar 39a52aff4c [mcs] Inflate nested pointer containers too. 2014-06-11 12:02:33 +02:00
Marek Safar 83a5fe8f1a [mcs] Flow analysis of binary expressions not using logical operators. Fixes #20515 2014-06-11 10:09:56 +02:00
Alex Rønne Petersen 2ab02d99c4 Merge pull request #890 from xoofx/master
[Mono.Linker] Add support for <Module> with static method and pre-mark t...
2014-06-11 09:22:29 +02:00
Alexandre Mutel 121a4dd894 [Mono.Linker] Add support for using the linker with assemblies referencing WPF 2014-06-11 15:03:57 +09:00
Alexandre Mutel be589710f5 [Mono.Linker] Add support for <Module> with static method and pre-mark them if necessary 2014-06-11 15:03:47 +09:00
Rodrigo Kumpera d2f66f2d9b [sgen] Fix an infinite loop in find_previous_pointer_fragment due to remove CAS'ing the wrong value.
The fragment list has one invariant, the next pointer is tagged if the current fragment is been deleted,
which means the list head can never point to a tagged pointer.

If this invariant is broken, the code in find_previous_pointer_fragment will end up in an infinite loop.

The infinite loop happens in this simplified fragment:

try_again:
	prev = &allocator->alloc_head;
1)	cur = unmask (*prev);
	while (1) {
2)		if (*prev != cur)
			goto try_again;

So assume allocator->alloc_head points to 0x121, which is tagged.

So execution goes like this:

1) cur is set to 0x120
2) *prev (value 0x121) is different than cur (value 0x120) so retry.

The above will loop forever as the fixup code never touches allocator->alloc_head.

Now that we understand the infinite loop, let's see how the remove code can trigger it.

Use use the following notation in the event sequence:

-> a non tagged pointer
-*> a tagged pointer
first CAS: InterlockedCompareExchangePointer ((volatile gpointer*)&frag->next, mask (next, 1), next)
second CAS: InterlockedCompareExchangePointer ((volatile gpointer*)prev_ptr, next, frag)

Assuming the following initial fragment list and two threads removing two separate fragments:

fragment list; -> A -> B -> C

thread 1 removes A
thread 2 removes B

thread 2 succeed the first CAS
-> A -> B -*> C

thread 1 succeed the first CAS
-> A -*> B -*> C

thread 2 fail the second CAS because of thread 1
-> A -*> B -*> C

thread 1 succeed the second CAS
-> B -*> C

thread 2 succeed the second CAS and set prev_ptr to next,
which at this point is a tagged pointer. Leaving the fragment list like this:
-*> C

After the last CAS, we end up with alloc_head with a tagged pointer, which will cause
the infinite loop we previously explained.

The fix is to unmask the value we store in the second CAS, as the objective is to link
two live fragments and not flag the previous fragment for deletion.

The exact same bug exists in mono-linked-list-set and was fixed there.
2014-06-10 17:51:16 -04:00
Martin Baulig 7cb33a4fcc [Http]: Cosmetic, remove some dead code.
The is no reason to ever invoke the callback on the ThreadPool,
it would in fact only cause trouble.

Marek's commit db92449f was correct, I removed the commented out
code and the no longer used method.
2014-06-10 23:11:47 +02:00
Marek Safar aecf3db62b [mcs] Implement rethrow support in awaited catch clause 2014-06-10 22:05:11 +02:00
Martin Baulig 5e33f9eccf [Http]: Fix digest authentication (bug #18799).
We did not correctly parse key-value pairs without quotes in the
challenge.
2014-06-10 21:42:35 +02:00
Martin Baulig d5f7694acc [System.Net.Http]: Always add "Content-Length" in HttpClientHandler.SendAsync().
This has been reported on the forums:
http://forums.xamarin.com/discussion/17770/length-required-error-in-http-post-since-latest-release
2014-06-10 21:42:35 +02:00
Jeffrey Stedfast db0132029e [Mono.Debugger.Soft] Improved ILInterpreter to eval properties that return a primitive constant 2014-06-10 15:16:36 -04:00
Joao Matos 9aa982e166 [windows] Return early in the vectored exception handler if the thread is not managed by the runtime. 2014-06-10 20:15:10 +01:00
Martin Baulig f462bcc944 [Http]: Only recycle ServicePoints from the idle timer (fixes #19823).
Thanks a lot for Martin Potter to find and report the race condition
which was causing the problem.

ServicePointManager.RecycleServicePoints() was a left-over from the
old times when we didn't have an idle-timer based approach.
2014-06-10 19:21:32 +02:00
Jeffrey Stedfast 6759817ac2 [Mono.Debugger.Soft] minor code cleanup 2014-06-10 12:54:48 -04:00
Joao Matos d8e44abb07 Fix mono exception handler crashing on windows.
Here's the scenario that causes the crash:

Exception is fired, which invokes mono's vectored exception handler. It
is not an exception mono recognizes, so falls through to the default:
case in the exception handler. The problem is the return value has been
initialized to EXCEPTION_CONTINUE_EXECUTION. This causes SEH not to
process any other handlers, and just attempt to continue execution at
the point the exception was thrown.

The problem is much of windows internals will catch various exceptions
internally and handle them. So instead of the exception being handled,
we would just crash in the bowels of windows.

The solution is to set mono_win_chained_exception_needs_run to TRUE in
the default case - this is what the various exception handlers do if the
exception is not in JIT'd code. This causes the handler to return
EXCEPTION_CONTINUE_SEARCH, which causes SEH to search for the next
handler, and no crash is produced.

Both x86 and x64 had this bug, so I fixed it in both places.

Fix contributed by Steve Anichini.
2014-06-10 17:05:23 +01:00
Joao Matos dcc7a89be1 Changed mono_win_chained_exception_needs_run to be a JIT TLS variable.
This fixes a potential race condition that might happen if two threads try to handle an exception at the same time.
2014-06-10 17:05:14 +01:00
Atsushi Eno 93e5f42f80 [sys.xaml] fix TypeId and get broken WindowsBase tests pass. 2014-06-10 21:49:05 +09:00
Alex Rønne Petersen 975bf0a379 Attempt to sanitize the vasprintf situation in eglib.
The problem is that on some platforms we call the function
without having provided a prototype for it. This breaks when
building with `-Werror`.

Now we declare it in the private `vasprintf.h` header when
the platform doesn't have a declaration in `stdio.h`. This
should also let us remove the hack in `glib.h` for MSVC.

This may or may not break the build on some platforms; I've
tried on those that I have access to with success. Let me
know if this breaks anything.
2014-06-10 09:40:22 +02:00
Alex Rønne Petersen be483f24da Add build system plumbing for building with -Werror. 2014-06-10 09:35:01 +02:00
Alex Rønne Petersen be195eb1e6 Merge pull request #1094 from LRFalk01/master
Identities not being set in ClaimsPrincipal Ctor
2014-06-10 03:29:10 +02:00
Lucas ad354665a8 Identities not being set in ClaimsPrincipal Ctor
Class' identities member is not set in constructor ClaimsPrincipal
(IEnumerable<ClaimsIdentity> identities)
2014-06-09 21:20:35 -04:00
Alex Rønne Petersen ec0304a599 Remove unnecessary MPH_INTERNAL applied to a function definition.
This should be applied to prototypes, and it already is for
this function (in mph.h).
2014-06-10 03:15:16 +02:00
Alex Rønne Petersen 96e1ee0578 Remove the architecture conditions for using perf in the log profiler.
We now use generic atomics which work on all platforms, so there's
no reason to keep this constraint here. This allows the `perf`-backed
profiler to be used on mips, ppc, s390x, etc.
2014-06-10 01:46:32 +02:00
Alex Rønne Petersen 79d2d4c11d Revert "Disable perf support in the profiler when running on Android (for now)."
This reverts commit 8e35b7d01e.

The fallback implementation (as used on other platforms) appears to hang
the runtime. Having a maybe-working `perf`-backed sample profiler is better
than a not-working sample profiler.
2014-06-10 01:46:32 +02:00
Zoltan Varga ed2daa2a84 Revert "[x86] Reenable the no pushes code."
This reverts commit 5093efd558.

Revert this as it still breaks the build.
2014-06-09 17:37:20 +02:00
Zoltan Varga 6fffdcacef [x86] Fix the build. 2014-06-09 17:11:51 +02:00
Zoltan Varga 5093efd558 [x86] Reenable the no pushes code. 2014-06-09 16:35:39 +02:00
Atsushi Eno b8580c63d3 [sys.xaml] remove extraneous NET_2_1 and use __MOBILE__ to make it build for XA/XiOS. 2014-06-09 12:43:53 +09:00
Zoltan Varga e7bc174077 [jit] Align the stack when using the pushless code on x86. 2014-06-08 23:19:07 +02:00
Alex Rønne Petersen f0368f1014 Merge pull request #1090 from BrianDurham/patch-2
Update X11Display.cs - change "Check you DISPLAY"
2014-06-08 21:05:03 +02:00
Alex Rønne Petersen 3acadefda7 Merge pull request #1089 from BrianDurham/patch-1
Update Graphics.cs - change "Check you DISPLAY"
2014-06-08 21:04:33 +02:00
Alex Rønne Petersen 161005fd4c Merge pull request #1091 from BrianDurham/patch-3
Update XplatUIX11.cs - change "Check you DISPLAY"
2014-06-08 19:51:56 +02:00
Alex Rønne Petersen 65d967946b Merge pull request #1092 from BrianDurham/patch-4
Update XplatUIX11GTK.cs - change "Check you DISPLAY"
2014-06-08 19:51:42 +02:00
Brian Durham f5858f05f1 Update XplatUIX11GTK.cs - change "Check you DISPLAY"
Update XplatUIX11GTK.cs - change "Check you DISPLAY" text to "Check your DISPLAY"
2014-06-08 10:24:35 -05:00
Brian Durham 98d56eb303 Update XplatUIX11.cs - change "Check you DISPLAY"
Update XplatUIX11.cs - change "Check you DISPLAY" to "Check your DISPLAY"
2014-06-08 10:22:06 -05:00
Brian Durham ca7f073b7e Update X11Display.cs - change "Check you DISPLAY"
Change "Check you DISPLAY environment variable" to "Check your DISPLAY environment variable"
2014-06-08 10:18:02 -05:00
Brian Durham 039f01d6b0 Update Graphics.cs - change "Check you DISPLAY"
Update Graphics.cs - change "Check you DISPLAY environment variable" to "Check your DISPLAY environment variable"
2014-06-08 10:14:50 -05:00
Zoltan Varga 8530d2b60e [x86] Disable the no-pushes code for now, it breaks many tests. 2014-06-08 14:28:48 +02:00
Alex Rønne Petersen e6aa46a391 Apply the change in a99ebf9843 to mprof-report too. 2014-06-08 04:09:05 +02:00
Alex Rønne Petersen a99ebf9843 Fix a ton of warnings when building the log profiler with newer zlib versions. 2014-06-08 01:56:39 +02:00
Rodrigo Kumpera 416d4e10f9 Merge pull request #1088 from BrzVlad/pushless
[x86] Arguments to calls are passed via moves, instead of pushes.
2014-06-07 19:10:50 -04:00
Alex Rønne Petersen da1d328913 Silence another array subscript warning in eglib/src/sort.frag.h. 2014-06-07 22:27:22 +02:00
Alex Rønne Petersen 06a33428d2 Fix typo in bf703c4a8f. 2014-06-07 22:20:20 +02:00
Joao Matos f6b7bf735a Fixed the build on MSVC.
Local variables need to be declared at the start of the block.
2014-06-07 18:35:41 +01:00
Alex Rønne Petersen b45527f44b Add missing prototypes to supportw.c. 2014-06-07 18:03:31 +02:00
Alex Rønne Petersen f35c6a0b07 Comment an unused function in minizip. 2014-06-07 18:03:19 +02:00
Alex Rønne Petersen 93e7f8691c Fix z_alloc () signature.
Yes, really. zlib really uses a 32-bit int here...
2014-06-07 18:02:29 +02:00
Alex Rønne Petersen 58ebad8f72 Add missing prototypes to Mono.Posix C sources. 2014-06-07 18:02:14 +02:00
Alex Rønne Petersen 6db015b5e3 Move shared_area_disabled () behind ifdef. 2014-06-07 18:01:10 +02:00
Alex Rønne Petersen a96bd2f959 Wrap deadce_has_run variable in DISABLE_SSA ifdef. 2014-06-07 18:00:41 +02:00
Alex Rønne Petersen 86602698da Add g_assert_not_reached () to mono_gc_pthread_exit ().
On Android, pthread_exit () is not decorated as noreturn.
2014-06-07 17:59:49 +02:00
Alex Rønne Petersen 54de0818bf Silence unused mkstemp result warnings in jay. 2014-06-07 17:59:18 +02:00
Alex Rønne Petersen 27c58875c2 Add missing prototypes in ikvm-native. 2014-06-07 17:58:48 +02:00
Alex Rønne Petersen 1ef4b48014 Mark an unused variable as such in eglib/test/file.c. 2014-06-07 17:58:32 +02:00
Alex Rønne Petersen d6aee5a283 Disable -Warray-bounds in eglib/src/sort.frag.h!insert_list in GCC 4.6.0+. 2014-06-07 17:57:46 +02:00
Alex Rønne Petersen bf703c4a8f Disable -Wreturn-local-addr in libgc/mark_rts.c!GC_approx_sp with GCC 4.8.0+. 2014-06-07 17:56:50 +02:00
Alex Rønne Petersen 69ed93a8fa Compile libgc with -Wno-deprecated-declarations as it uses some obsolete POSIX APIs. 2014-06-07 17:56:06 +02:00
Alex Rønne Petersen 09f85a32d9 Revert unintentional change. 2014-06-07 16:52:50 +02:00
Alex Rønne Petersen 2cecaa4713 Fix the build. We've been missing this include for ages... 2014-06-07 16:38:47 +02:00
Alex Rønne Petersen c94206ef72 Bring the implementation of the 64-bit CAS fallback in line with the 32-bit one. 2014-06-07 16:18:35 +02:00
Alex Rønne Petersen 97e016c966 Mark the spin variable in atomic.c as G_GNUC_UNUSED.
It would require an `#ifdef` forest to get the conditions
under which it is used right.
2014-06-07 16:13:22 +02:00
Alex Rønne Petersen fc869fd398 Merge branch 'master' of github.com:mono/mono 2014-06-07 15:54:32 +02:00
Zoltan Varga eeef746ffc Revert "Fix a warning in atomic.c."
This reverts commit 1fdc8789a7.

This breaks the ios build:

../../../../../mono/mono/utils/atomic.c: In function ‘InterlockedCompareExchange64’:
../../../../../mono/mono/utils/atomic.c:572: error: ‘spin’ undeclared (first use in this function)
../../../../../mono/mono/utils/atomic.c:572: error: (Each undeclared identifier is reported only once
../../../../../mono/mono/utils/atomic.c:572: error: for each function it appears in.)
2014-06-07 15:21:02 +02:00
Zoltan Varga 4149ba44cf [arm] Fix OP_ATOMIC_CAS_I4. 2014-06-07 01:22:12 +02:00
Brezae Vlad bb3ccfb141 [x86] Arguments to calls are passed via moves, instead of pushes.
I release these changes under the MIT license.
2014-06-07 00:25:30 +03:00
Alex Rønne Petersen 8e35b7d01e Disable perf support in the profiler when running on Android (for now).
We need to assess the situation before we enable this everywhere. Apparently
some older devices have trouble with `perf`.
2014-06-06 23:02:33 +02:00
Alex Rønne Petersen 1fdc8789a7 Fix a warning in atomic.c. 2014-06-06 22:58:20 +02:00
Alex Rønne Petersen 8fc059bea3 Remove a #warning in security.c which gets triggered on OS X. 2014-06-06 22:58:07 +02:00
Ludovic Henry a587e4641a [counters] Add counters documentation to man page 2014-06-06 16:00:03 -04:00
Alex Rønne Petersen 11e01299d9 Fix printf formatting warnings in mono-counters.c. 2014-06-06 15:20:52 +02:00
Alex Rønne Petersen 56819afa82 Use G_GNUC_UNUSED instead of commenting out variable declarations.
The previous approach resulted in mixed decls/stmts warnings.
2014-06-06 15:19:20 +02:00
Alex Rønne Petersen 3b3f4bd673 Fix a ton of printf formatting warnings in decode.c. 2014-06-06 15:17:19 +02:00
Alex Rønne Petersen dd82497ce2 Silence some warnings in decode.c. 2014-06-06 14:52:28 +02:00
Alex Rønne Petersen 0b168543d7 Fix volatile pointer casts in proflog.c. 2014-06-06 14:52:09 +02:00
Alex Rønne Petersen bfaa08475e Silence a bunch of unused result warnings in proflog.c. 2014-06-06 14:51:44 +02:00
Alex Rønne Petersen 35a03dcec2 Fix a bunch of warnings caused by unused functions. 2014-06-06 14:41:18 +02:00
Alex Rønne Petersen 1aecffad3f Add suggested parentheses to RHS of ^ operator. 2014-06-06 14:40:56 +02:00
Alex Rønne Petersen 6135b2695e Fix formatting specifiers for some size_t arguments. 2014-06-06 14:40:24 +02:00
Zoltan Varga 0b58028883 [runtime] Avoid joining attached threads. Fixes #19343. 2014-06-06 03:00:41 +02:00
Martin Baulig e6ce33bc7d [Http]: Read version from "HTTP CONNECT" response.
When using "HTTP CONNECT" to create a tunnel to a proxy server,
check the proxy server's response for the HTTP Version and close
the connection if it's HTTP/1.0.
2014-06-05 21:31:31 +02:00
Martin Baulig 5428bdfb71 [Http]: Fix the loop in WebConnection.ReadHeaders().
We need to reset `gotStatus' each time we enter the outer loop or we
would attempt to interpret the status line as a header.
2014-06-05 21:31:31 +02:00
Zoltan Varga f8afadcdf0 Merge pull request #1084 from tritao/msvc-warnings
MSVC warning fixes
2014-06-05 20:57:50 +02:00
Zoltan Varga 4385e25d7a [runtime] Fix support for custom marshallers defined in other assemblies. Fixes #20020. 2014-06-05 20:48:09 +02:00
Joao Matos ea326aa924 Fixed monodis MSVC build.
We need to include "mono/utils/mono-compiler.h" to get the proper isinf/isnan declaration.
2014-06-05 19:46:20 +01:00
Marek Safar 97fb37a95b [mcs] Return type inference of async anonymous methods 2014-06-05 19:36:17 +02:00
Marek Safar 876126e680 [mcs] Check for await expression inside new delegate statement 2014-06-05 19:36:17 +02:00
Zoltan Varga 2aa7af5863 [runtime] Fix a jit assertion on a class which contains an empty struct as a static field. Fixes #20349. 2014-06-05 19:05:50 +02:00
Joao Matos 92f13d1988 Regenerate keyboards.resx resource file.
The existing one is reported as malformed XML by csc.
2014-06-05 16:20:56 +01:00
Joao Matos c353c84db3 Fixed warning in MSVC: 'unreferenced local variable'. 2014-06-05 15:40:37 +01:00
Joao Matos 623e43dcd6 Fixed warning in MSVC: 'different types for formal and actual parameter'. 2014-06-05 15:39:40 +01:00
Joao Matos 13e47bf9cb Fixed warning in MSVC: 'void' function returning a value. 2014-06-05 15:37:46 +01:00
Joao Matos 12926a22ac Fixed warnings in MSVC: 'unreferenced local variable'. 2014-06-05 15:35:39 +01:00
Joao Matos 0338bfae3f Removed an unused variable from the code, fixes a warning in MSVC. 2014-06-05 15:34:00 +01:00
Joao Matos cfea841bb4 Fixed warning in MSVC: 'unreferenced local variable'. 2014-06-05 15:31:28 +01:00
Joao Matos 47324cca65 Fixed warning in MSVC: 'unreferenced local variable'. 2014-06-05 15:29:55 +01:00
Joao Matos f7cc6db9c3 Fixed warning in MSVC: 'different types for formal and actual parameter'. 2014-06-05 15:28:33 +01:00
Joao Matos 8c940e6459 Fixed warning in MSVC: 'getpid' undefined; assuming extern returning int. 2014-06-05 15:27:45 +01:00
Joao Matos 4d4332ce91 Fixed unreferenced local variable warning in MSVC. 2014-06-05 15:25:13 +01:00
Joao Matos c4dfe62e05 Fixed MSVC warning about unreferenced local variable. 2014-06-05 15:21:05 +01:00
Joao Matos 08ac4efcf1 Fixed MSVC warning about different types for formal and actual parameter. 2014-06-05 15:20:06 +01:00
Joao Matos d8164bb3fc Fixed unreferenced variables/label warnings in MSVC. 2014-06-05 15:15:01 +01:00
Joao Matos fd0659abd4 Fixed unsigned/signed mismatch warning. 2014-06-05 15:12:12 +01:00
Joao Matos 770c5536e9 Fixed warning in MSVC by prefixing the macros, MEM_FREE is already defined in winnt.h. 2014-06-05 15:09:01 +01:00
Zoltan Varga 252ea94fce Merge pull request #1083 from christianhuening/NetworkInterfaceFix
- ADDED: Support to read out Interface flags on OS X
2014-06-05 15:05:42 +02:00
Christian Hüning 5e43e5d6db - ADDED: Support to read out Interface flags on OS X
- ADDED: Implemented NetworkInterface property "OperationalStatus" to be UP, in case the IFF_UP flag is set
- ADDED: Implemented NetworkInterface property "SupportsMulticast" to be true, in case the IFF_MULTICAST flag is set

This change is released under the MIT license.
2014-06-05 14:09:11 +02:00
Atsushi Eno 76b08f12ef [msbuild] fix some weird local result variable initialization issue.
I cannot explain why, but this affects building solution that has more than
one projects for MS.Build.dll. <MSBuild/> task returns false for successful
builds without this change.
Most likely codegen or runtime issue, but a bit too high level to drill down.
2014-06-05 13:11:45 +09:00
Atsushi Eno 939fa58ae9 [MS.Build] disable failing test.
It somehow passes on my dev. environment so I cannot reproduce...
2014-06-05 13:11:44 +09:00
Atsushi Eno 5ed465d94b [MS.Build] metadata is also replaced its windows path separators. 2014-06-05 13:11:43 +09:00
Zoltan Varga 9932336e7b [jit] Avoid licm for volatile variables, ssa ignores them so we can't detect whenever they are loop invariant by looking at phi nodes. 2014-06-05 01:56:28 +02:00
Joao Matos a2c3c36768 Fixed unreachable methods in mono-thread-windows to use g_assert_not_reached.
This fixes a couple warnings.
2014-06-04 21:10:03 +01:00
Joao Matos facf8c8ad9 Modified g_assert_not_reached to use g_unreachable. 2014-06-04 21:09:54 +01:00
Joao Matos 7d93575e58 Added g_unreachable to explicitly notify the compiler of unreachable code. 2014-06-04 21:09:45 +01:00
Rodrigo Kumpera 956ec8a589 [sgen] Fix logging due to changes in a lot of size types. 2014-06-04 14:36:07 -04:00
Zoltan Varga 3f977bc61d [runtime] Add another test for passing many small arguments. 2014-06-04 20:33:14 +02:00
Rodrigo Kumpera 9c1bd5b6ee [sgen] Fix clang compilation. 2014-06-04 14:30:29 -04:00
Rodrigo Kumpera c68e59600e [sgen] Fix a few warnings related to lossy conversion of size_t to int on 64bits. 2014-06-04 13:34:50 -04:00
Rodrigo Kumpera 94784f4342 [sgen] Fix nursery size calculation and the managed write barrier to be 64bits clean. 2014-06-04 13:34:49 -04:00
Rodrigo Kumpera 222eea0a55 [sgen] Fix the object size functions to be 64bits clean. 2014-06-04 13:34:48 -04:00
Rodrigo Kumpera 429f9ca6db [sgen] Ensure the cardtable code is 64bits clean. 2014-06-04 13:34:47 -04:00
Rodrigo Kumpera 137d0578d2 [sgen] Use size_t for all heap limits. 2014-06-04 13:34:46 -04:00
Rodrigo Kumpera 4d958ad0a0 [sgen] Fix size warnings in the descriptor code. 2014-06-04 13:34:45 -04:00
Rodrigo Kumpera 6c268d316c [sgen] Silence warnings when big arrays are not in use on 64bits. 2014-06-04 13:34:44 -04:00
Rodrigo Kumpera f50822f39c [sgen] Make degrated_mode a size_t. 2014-06-04 13:34:43 -04:00
Rodrigo Kumpera 238f52088b [sgen] Make los usage of size_t cosnsitent. 2014-06-04 13:34:42 -04:00
Rodrigo Kumpera 828d4c9e60 [sgen] Use size_t consistently in the major collector for object sizes and number of memory blocks. 2014-06-04 13:34:40 -04:00
Rodrigo Kumpera a066f0d94b [sgen] Use size_t consistently in the nursery code. 2014-06-04 13:34:40 -04:00
Rodrigo Kumpera ba95eaba43 [sgen] Move the pinning code to use size_t internally. This makes this code 64bits clean. 2014-06-04 13:34:38 -04:00
Rodrigo Kumpera a5593126ad [sgen] Fix small localized warnings. 2014-06-04 13:34:37 -04:00
Rodrigo Kumpera 955c2e1010 [sgen] Fix win64 issues with longs and inline assembly. 2014-06-04 13:34:36 -04:00
Rodrigo Kumpera 16fe0d24af [runtime] Fix a bunch of warnings in threads.c related to int64 -> int32 lossy casts. 2014-06-04 13:34:35 -04:00
Rodrigo Kumpera c670b35edc [verifier] Silence a size mismatch warning in the verifier. 2014-06-04 13:34:34 -04:00
Rodrigo Kumpera 00643150c5 [runtime] Replace gulong with size_t to fix counter sizes in win64. 2014-06-04 13:34:33 -04:00
Rodrigo Kumpera 1505c43d70 [win64] Windows64 MSVC compiler dropped support for inline assembly. Move that code into a .asm file. 2014-06-04 13:34:32 -04:00
Rodrigo Kumpera d248c1516b [VS] Fix the solutions to work with win64. Update the file list to include some new sgen files. 2014-06-04 13:34:31 -04:00
Rodrigo Kumpera c9ef61d47a [runtime] Fix warnings in mono-threads. 2014-06-04 13:34:30 -04:00
Rodrigo Kumpera d1882a4dc3 [runtime] Replace gulong with size_t so it works on win64. 2014-06-04 13:34:29 -04:00
Rodrigo Kumpera 3fd79bd70e fix win thread size calc. 2014-06-04 13:34:28 -04:00
Marek Safar f7834aa3cf [mcs] Revert unwanted change from 9e5d5e5c90 2014-06-04 19:06:59 +02:00
Marek Safar 22ca1862ee Fixes build 2014-06-04 19:02:40 +02:00
Marek Safar 9e5d5e5c90 [mcs] Better error message for attribute value used for unsupported parameter type 2014-06-04 19:02:40 +02:00
Marek Safar d82542fb00 [mcs] Emit result type conversion for null coalescing operator on nullable type 2014-06-04 19:02:40 +02:00
Neale Ferguson 5348a0daca Correct op_seqpoint length 2014-06-04 10:50:03 -04:00
Neale Ferguson a2920353b6 Fix s390x soft debug 2014-06-04 10:48:43 -04:00
Neale Ferguson 4dfae5ba82 Architectural level set to z10 instruction set 2014-06-04 10:48:43 -04:00
Marek Safar 4f5ddeea8a [mcs] Add more checks to dynamic logical operations when lhs is not of dynamic type 2014-06-04 14:41:24 +02:00
Marek Safar ca13dbf1e1 [mcs] Don't wrap enum constants during folding when result is reduced 2014-06-04 14:41:24 +02:00
Marek Safar eb0edaa05e Merge pull request #1082 from esdrubal/bug19287
Improved JavaScriptSerializer.ConvertToType Nullable handling. Fixes #19287.
2014-06-04 13:02:04 +02:00
marcos henrich e28d8783c5 Improved JavaScriptSerializer.ConvertToType Nullable handling. Fixes #19287. ConvertToType was returning null even when the object was not a string. When the target type is Nullable, ConvertToType returns null if the object is an empty string, if the object is not a string and the target type is obtainable from a string then the object is converted to a string and the string to the target type. 2014-06-04 11:20:05 +01:00
marcos henrich 5e76deaf72 Test JavaScriptSerializer.Deserialize with nullable enums. Covers #19287. 2014-06-04 11:17:35 +01:00
Marek Safar 92e321f26f [mcs] null coalescing operator cannot reduce constants 2014-06-04 11:25:24 +02:00
Marek Safar 63b64977bc [msbuild] Implemented instance members on static property evaluation 2014-06-04 11:25:23 +02:00
Alex Rønne Petersen a0064f9d5a [System] Fix WebClientTest build in net_2_0.
CancellationTokenSource is a 4.0 thing.
2014-06-03 23:33:30 +02:00
Marek Safar 0828b8e574 [System.ServiceModel.Security] Exclude security forwarders from mobile builds 2014-06-03 22:29:51 +02:00
Alex Rønne Petersen 80c4c54dd7 Merge pull request #1079 from esdrubal/webclient_cancel
UploadStringAsync cancel
2014-06-03 20:27:58 +02:00
Zoltan Varga 1feb13fe25 [runtime] Add an EXTRA_DISABLED_TESTS make variable to disable tests on the command line. 2014-06-03 20:19:33 +02:00
Zoltan Varga 5006b465ce [bcl] Disable a test added by 3cf55e6016, it depends on precise gc behaviour. 2014-06-03 19:31:09 +02:00
marcos henrich e2e64fada5 Changed UploadStringAsync to handle UploadString encapsulated exceptions.
UploadString call UploadData that encapsulates all exceptions in a WebException. ThreadInterruptedException were encapsulated into a WebException, so UploadStringAsync now uses e.InnerException is ThreadInterruptedException instead of trying to catch it.
2014-06-03 16:23:22 +01:00
Marek Safar 77d18f7661 [mcs] Update new error codes 2014-06-03 16:53:32 +02:00
Zoltan Varga 5d0df9e2c0 [runtime] Applied patch from Kyle Edwards <[email protected]>. Fix isinf () check with clang. Fixes #20244. 2014-06-03 16:07:51 +02:00
Marek Safar 4e87c47d54 [corlib] Add CreateTypeInfo method 2014-06-03 11:56:47 +02:00
Marek Safar 6884bcd6b7 [mcs] Better error reporting for incorrect async lambdas 2014-06-03 11:32:02 +02:00
Alex Rønne Petersen 856ac29f9b Merge pull request #1080 from chillitom/patch-1
Add missing definitions to ClaimTypes
2014-06-03 00:42:57 +02:00
Tom Rathbone c1a7602394 Add new missing ClaimTypes entries
Added 2008 and 2009 definitions and fixed Email definition
2014-06-02 23:31:44 +01:00
marcos henrich 0b1ea4edc9 Test WebClient asynchronous uploads cancellation.
Tests that UploadStringAsync triggers UploadStringCompleted with Cancelled == true.
Tests that UploadDataAsync triggers UploadDataCompleted with Cancelled == true.
Tests that UploadValuesAsync triggers UploadValuesCompleted with Cancelled == true.
Tests that UploadFileAsync triggers UploadFileCompleted with Cancelled == true.
2014-06-02 19:04:43 +01:00
Zoltan Varga 03e5354c32 [llvm] Fix a native types problem. 2014-06-02 20:02:15 +02:00
Zoltan Varga 227ae7a873 Merge pull request #1070 from tpokorra/FixTarball
Fix tarball for master
2014-06-02 19:51:34 +02:00
Atsushi Eno 9494158a3d [xbuild/msbuild] fix previous ItemGroup definition (should be in <ItemGroup>). 2014-06-03 01:19:14 +09:00
Marek Safar 22dc82012b [mcs] Remove wrong comment 2014-06-02 17:19:51 +02:00
Marek Safar bd13be55c2 [mcs] Add more warnings for caller attributes 2014-06-02 17:13:50 +02:00
Atsushi Eno 1abe0a39b9 [xbuild/msbuild] fix build: fix Exists() argument. 2014-06-02 22:40:19 +09:00
Marek Safar 4681266d9d [mcs] Add support for await in catch clause 2014-06-02 14:53:12 +02:00
Marek Safar ed584e7751 Fixes build 2014-06-02 13:15:22 +02:00
Marek Safar 243f654837 [mcs] Extend possible unintended reference comparison check 2014-06-02 13:05:19 +02:00
Atsushi Eno 992fd970eb [msbuild/xbuild] use ToolLocationHelper.GetPathToStandardLibraries() to get corlib path, for new build engine.
This is enabled only with Microsoft.Build.dll because property function
support is not fully implemented in MS.Build.Engine.dll and simply fails.

Since the targets files are shared between xbuild and msbuild, I added
some well-known property for msbuild and used it in the targets file.
2014-06-02 19:28:21 +09:00
Atsushi Eno 1b41fd7635 [MS.Build] add MS.Build.dll-specific well-known property, to differentiate from MS.Build.Engine. 2014-06-02 19:28:20 +09:00
Atsushi Eno 5265579628 [xbuild] fix 4.0-only test condition. 2014-06-02 19:28:19 +09:00
Atsushi Eno 001edf133e [msbuild] build the projects via MSBuild task with appropriate configuration, not the entire projects in the solution. 2014-06-02 18:01:14 +09:00
Atsushi Eno 8498e0dbcc [MS.Build] ProjectOnErrorInstance should not cause build failure. 2014-06-02 17:59:30 +09:00
Atsushi Eno c29ae4c3e1 [MS.Build] added test for ToolLocationHelper.GetPathToStandardLibraries() to add target item.
It should be used in Microsoft.CSharp.targets to pass the path to mscorlib.dll
but it's not working yet, so I'm making it to work step by step.
2014-06-02 17:59:29 +09:00
Atsushi Eno 756f3740c2 [MS.Build] when evaluated as object, do not add extra quotes.
When the object is passed as argument to property function, it gets extra
" or ' and could result in unexpected value.
2014-06-02 17:59:28 +09:00
Atsushi Eno 867c2e5f31 [xbuild] ToolLocationHelper.GetPathToStandardLibraries() skips "" too.
Test is added too, but since it requires some environment setup, I didn't
enable it so far.
2014-06-02 17:59:27 +09:00
Atsushi Eno eb898301e5 [MS.Build] fix some issues around quoted string handling.
Since the parser didn't really detect those quotation chars unless they are
top of the next tokeniation, it was always starting from wrong position.
2014-06-02 17:59:26 +09:00
Atsushi Eno 5a23a8263c [MS.Build] add function call releated tests. 2014-06-02 17:58:54 +09:00
Atsushi Eno 57370802bc [MS.Build] '\\' is also escaped syntax, so parse it carefully too. 2014-06-02 17:58:53 +09:00
Atsushi Eno c0cb2bee54 [MS.Build] fix function call expression parsing wrt nested refs: $(X('$(Y)','$(Z)'))
Nested references inside quoted strings are not parsed correctly.
To resolve this issue, parse quoted expressions in more complicated way.
2014-06-02 17:58:52 +09:00
Atsushi Eno 331215cfb6 [ms.build] make sure that we don't skip any other kind of child under target element. 2014-06-02 17:58:51 +09:00
Atsushi Eno 95405ddfdf [MS.Build] simplify IBuildEngine.Build() implementation, and build the argument project, not the project that is being built by the BuildManager.
That was wrong recursion.
2014-06-02 17:58:51 +09:00
Atsushi Eno d86c100d20 [MS.Build] make env. properties are read only, and show initial properties in different manner.
Now it's easier to see project properties and other properties.
2014-06-02 17:58:50 +09:00
Atsushi Eno 30414940d2 [MS.Build] revise previous fix; only Items are in reverse order.
The previous change regressed at order of property evaluation. Now this fix
does not regress as well as F# project still builds.
2014-06-02 17:58:49 +09:00
Atsushi Eno f2d143e6c3 [MS.Build] ProjectInstance needs ChildrenReversed to evaluate items.
This behavioral difference between ProjectRootElement, Project and
ProjectInstance was discovered while trying to get F# project working
(where item order significantly matters).
2014-06-02 17:58:48 +09:00
Atsushi Eno ce1d55ff60 [MS.Build] load ImportGroup in root. 2014-06-02 17:58:47 +09:00
Atsushi Eno 0ef2316adb [ms.build] several fixes in BuildEngine4.
- InitialTargets also need to be executed.
- toolsVersion must be filled.
- HostServices object is also passed from the parent build.
2014-06-02 17:58:46 +09:00
Atsushi Eno 029044a956 [ms.build] pass DefaultToolsVersion from ProjectInstance to build request data. 2014-06-02 17:58:46 +09:00
marcos henrich 6a6631d883 Removed DeflateStream.UnmanagedRead Read loop. Fixes #19313.
If the base_stream was a NetworkStream UnmanagedRead loop would call base_stream.Read a second time and block until one byte was available to return. Without the loop UnmanagedRead will only read the base_stream once.
2014-06-02 08:22:33 +01:00
marcos henrich 19f48e7920 Test that DeflateStream.Read does read an empty stream. Covers #19313. 2014-06-02 08:21:08 +01:00
Marek Safar ef7d65f093 Merge pull request #1078 from LRFalk01/master
Null Exception in System.Security.Claims
2014-06-02 08:42:50 +02:00
Lucas 203320edc9 Null Exception in System.Security.Claims
This fixed a runtime exception when trying to get a ClaimsPrincipal from an IIdentity.
Noticed this work working with aspnet Identity in a Web Api 2 controller.
Exception fired when running User.Identity.IsAuthenticated.

Exception detail:
http://falk.pw:7777/tocehuhemo.xml
2014-06-01 18:21:11 -04:00
Alex Rønne Petersen 1eb8ba78f4 Merge pull request #1071 from bl8/cairo-additions
Cairo API additions in Context class
2014-06-01 21:52:18 +02:00
Alex Rønne Petersen 7474d008f1 Merge pull request #1075 from Meai1/patch-1
Update README.md
2014-06-01 21:51:14 +02:00
Alex Rønne Petersen a810af4524 Merge pull request #1077 from sethjackson/null-gc-sgen
Allow building with null-gc and sgen.
2014-06-01 21:50:47 +02:00
Alex Rønne Petersen e5e7fbaa6e Merge pull request #1076 from sethjackson/null-gc-msg
Print the correct GC type if compiling using --with-gc=none.
2014-06-01 21:48:30 +02:00
Seth Jackson 7fee3f491b Allow building with null-gc and sgen.
Previously if --with-gc=none --with-sgen=yes was specified the sgen runtime
would include the null GC and the sgen GC which would confuse the linker.

This change released uner the MIT license.
2014-06-01 11:08:32 -04:00
Seth Jackson 5511ba6d61 Print the correct GC type if compiling using --with-gc=none.
This change released under the MIT license.
2014-06-01 10:46:56 -04:00
Meai1 91d14d4d5a Update README.md 2014-05-31 20:25:33 +02:00
Miguel de Icaza a64dbc3e94 MemoryMappedFile fixes
This patch includes a few fixes:

	* CreateNew will actually create a memory map file, the previous logic
	  in MemoryMapImpl.Open was wrong, and would fail if the file did not
	  exist.   We now cope with this (bug #20052 was caused by this).

 	* Some exceptions were wrong, so this patch updates the
	  exceptions being thrown to be the right ones

	* On Mobile, we inverted the logic to ensure that capacity must be
	  bigger or equal than the file size (which is what the API needs to do),
	  previously it performed the opposite test.

Added tests that match the behavior on .NET for this.
2014-05-31 12:53:11 -04:00
Zoltan Varga 5f55a5c6a5 Merge pull request #1073 from DavidKarlas/logging
[Mono.Debugger.Soft] Using environment variable MONO_SDB_LOG as logfile path
2014-05-31 17:11:10 +02:00
Meai1 3b13098006 Update README.md
Add info on parallel installations which is going to be the case for 99% of people trying to compile and use mono from source.
2014-05-31 12:36:50 +02:00
Zoltan Varga 45362dc90b [sdb] Add a lower level lock and use it in place of the loader lock in some places. 2014-05-31 01:41:45 +02:00
marcos henrich 4449269d8f Changed TryPeek to handle race condition with Dequeue.
Dequeue sets the head.Value to its default. When TryPeek is interrupted in the process of retrieving the value some times Dequeue sets the value to its default. TryPeek now checks the head has not been changed before returning the value.
2014-05-30 20:31:47 +01:00
marcos henrich 02aacdb39e Added stress test to ConcurrentQueue.TryPeek.
The test checks that in some race condition the queue does not return null.
2014-05-30 20:22:21 +01:00
Jérémie Laval 610d1e7aaf Merge pull request #1068 from esdrubal/bug18421
Changed ConcurrentQueue to remove last ref/value. Fixes 18421
2014-05-30 14:50:35 -04:00
David Karlaš 610a5d2c08 [Mono.Debugger.Soft] Using environment variable MONO_SDB_LOG as logfile path 2014-05-30 20:10:54 +02:00
Rolf Bjarne Kvinge 103fd26cbb Merge pull request #1072 from esdrubal/bug19862
FileInfo members that rely on AccessControl are now inside a conditional block !MOBILE
2014-05-30 17:59:52 +02:00
marcos henrich b124b68759 FileInfo members that rely on System.Security.AccessControl are now inside a conditional block !MOBILE 2014-05-30 16:55:52 +01:00
Bertrand Lorentz 014d517bfb Mono.Cairo: Add Context.SetSourceColor(Color) convenience method
The Color property was obsoleted, but the suggested replacement
SetSourceRGBA has 4 double parameters, which can be unconvenient.

Add a SetSourceColor that takes a Cairo.Color parameter, make the Color
property use it, and update the message on the Obsolete attribute.
2014-05-30 17:11:55 +02:00
Bertrand Lorentz acc644b7a5 Mono.Cairo: Add Context.HasCurrentPoint property
The cairo_has_current_point function was added in cairo 1.6.
2014-05-30 17:10:28 +02:00
Bertrand Lorentz 382ed03051 Mono.Cairo: Add Context.InClip method
The cairo_in_clip function was added in cairo 1.10.
2014-05-30 17:05:04 +02:00
Rolf Bjarne Kvinge a9b8a73f68 [System.Xml] Use profile-specific file names for generated files.
Otherwise parallel builds will break randomly.
2014-05-30 16:57:54 +02:00
Marek Safar 090895472a [mcs] Add lang version 2014-05-30 15:13:19 +02:00
Timotheus Pokorra 399ba6758b make sure that the subdirectories of mcs/class/Facades are included in the tarball
to avoid errors like:
MCS     [net_4_5] System.Xml.Serialization.dll
/bin/sh: line 4: cd: System.Collections.Concurrent: No such file or directory
2014-05-30 15:04:39 +02:00
Timotheus Pokorra 993f477363 add files System.Configuration.dll and System.Security.dll to monolite directory in tarball
to avoid: error CS0006: Metadata file `System.Security.dll' could not be found
2014-05-30 15:01:48 +02:00
Marek Safar 8f5e512264 Merge pull request #1069 from esdrubal/bug16990
Changed ConcurrentDictionary.Contains(KeyValuePair) to also compare value. Fixes #16990.
2014-05-30 13:43:02 +02:00
marcos henrich db71dba1b7 Changed ConcurrentDictionary.Contains(KeyValuePair<TKey, TValue>) to also compare value. Fixes #16990. 2014-05-30 11:33:02 +01:00
marcos henrich ff441b11d3 Test ConcurrentDictionary.Contains(KeyValuePair<TKey, TValue>). Covers #16990. 2014-05-30 11:22:01 +01:00
Rodrigo Kumpera 2eaf6e71b3 [boehm] Implement the finalization extension API. 2014-05-29 21:52:29 -04:00
Rodrigo Kumpera a153eed835 [gc] Add finalizer API, implemented only on sgen.
The new finalizer API allows an embedder to be notified during a collector
when an object is queued for finalization.

This is a VERY low level interface, as this is called with the world stopped, so the
code MUST be async safe. If you don't precisely know what that means, don't use it.
2014-05-29 21:52:29 -04:00
Zoltan Varga 42de311ee3 [jit] Applied patch from Vladimir Kargov <[email protected]>. Fix a local register allocation problem involving global registers and x86 register constraints. 2014-05-30 02:57:48 +02:00
Alexis Christoforides 4b4a29f9c1 Bump 'master' branch version. 2014-05-29 18:12:35 -04:00
Sebastien Pouliot 822cbde2e2 [mobile] Add support for Environment.SetEnvironmentVariable in the mobile profile (e.g. iOS) 2014-05-29 15:29:52 -04:00
Zoltan Varga 0461967838 [sdb] Avoid clearning event requests if they reference an assembly which is unloaded. Instead, remove the assembly reference from the event request so it stays active. Fixes #19924. 2014-05-29 21:08:32 +02:00
marcos henrich 7c52a7bf5f Overwrites dequeued ref/value with default. Fixes 18421.
ConcurrentQueue was keeping the last dequeued ref/value.
2014-05-29 17:53:32 +01:00
marcos henrich 3cf55e6016 Test that ConcurrentQueue does not keep old references. Covers 18421. 2014-05-29 17:42:10 +01:00
Marek Safar adcc7740c8 [verifier] Set correctly stack type based on constrained type 2014-05-29 17:54:39 +02:00
Marek Safar fe911348c6 [mcs] If the overriding property is sealed, then the overridden accessors cannot be inaccessible 2014-05-29 14:32:27 +02:00
Marek Safar 8bed2a7525 Fixes build with newer mcs 2014-05-29 14:18:34 +02:00
Marek Safar 6a40d676aa [mcs] Use constrained prefix for enum calls too 2014-05-29 12:52:09 +02:00
Marek Safar c9042f1ed0 [verifier] Fix constrained type unwrap for enum types. Fixes #18371 2014-05-29 12:03:14 +02:00
Marek Safar db2d59eb4d Add System.ServiceModel.Security assembly. Fixes #20108 2014-05-29 09:50:44 +02:00
Zoltan Varga d4014f16df Merge pull request #1067 from esdrubal/bug19862
Removed NET_2_1 conditional blocks from FileInfo. Fixes #19862.
2014-05-29 02:01:34 +02:00
Zoltan Varga 11098d2ba9 [amd64] Simplify mono_arch_handle_altstack_exception () by passing a MonoContext on the stack instead of an os specific sigctx structure which required special handling and broke when _XOPEN_SOURCE was defined. 2014-05-29 01:07:51 +02:00
Jeffrey Stedfast ae8cec1f33 [Mono.Debugger.Soft] minor code cleanup 2014-05-28 14:14:48 -04:00
Jeffrey Stedfast 286e99ace3 Merge pull request #1048 from DavidKarlas/cacheThreadsAndBulkFetch
[Mono.Debugger.Soft] Caching threads and bulk fetching StackFrames
2014-05-28 13:59:27 -04:00
marcos henrich 77b1aacb9d Removed NET_2_1 conditional blocks from FileInfo. Fixes #19862. 2014-05-28 18:24:16 +01:00
Marek Safar a9cf06d9fb [mcs] Fix betterness logic for default vs params parameters. Fixes #19754 2014-05-28 17:59:47 +02:00
Marek Safar a74c354454 Tests update 2014-05-28 16:35:01 +02:00
Sebastien Pouliot 1355ca90df [System] Ensure pinvoke into OXS/iOS CFNetwork framework (for proxy support) are 64bits safe 2014-05-28 10:33:57 -04:00
Marek Safar fad2723818 [mcs] Flow analysis of binary expressions not using logical operators. Fixes #20086 2014-05-28 16:24:37 +02:00
Sebastien Pouliot 789e27a9bf [System] Ensure pinvoke into OXS/iOS Security framework are 64bits safe 2014-05-28 09:49:03 -04:00
Sebastien Pouliot 93076a9c75 [corlib][ios] Fix 'write' pinvoke declaration to be 64bits safe 2014-05-28 09:06:44 -04:00
David Karlaš 8a4a61c13c Changed API for fetching StackFrames in bulk on multiple threads ThreadMirror.FetchFrames instead of automatically on VirtualMachine.GetThreads 2014-05-28 12:58:38 +02:00
Marek Safar edbadc8241 [mcs] Emit unmanaged version info from AssemblyFileVersion. Fixes #20057 2014-05-28 11:00:54 +02:00
Zoltan Varga 5ed69a0f8a [runtime] Call mono_threads_join_threads () to prevent running out of threads when the finalizer threads becomes blocked/backlogged. 2014-05-28 00:09:47 +02:00
Zoltan Varga 5df3fd4797 [llvm] Fix the loadable llvm build. 2014-05-27 22:36:51 +02:00
Rodrigo Kumpera eea7a21324 [runtime] Add a test for the type loading changes. 2014-05-27 15:42:05 -04:00
Rodrigo Kumpera 639e3b5b21 [runtime] Ensure reflection-based assembly load has a basedir set.
When loading assemblies, we must ensure that a basedir is provided otherwise
things like custom attributes and Type.GetType won't be able to load sibling
assemblies when basedir is not the same of the domain.
2014-05-27 15:42:05 -04:00
Miguel de Icaza d6c6b28516 [build] Address the System.Configuration test problem
The compiler seems to ignore reference assemblies with a full path when the
-lib: directive is passed, so things like:

      -lib:FOO -r:BAR/bar.dll

Would resolve bar.dll to FOO/bar.dll, instead of BAR/bar.dll.

This is a problem with the test suite as it needs to reference the
final build of System.Configuration from $(the_libdir_base) and not
the intermediate step.

To work around this issue, we introduce "test_remove" variable that is
a piece of text that will be removed from the TEST_COMPILE variable
when this is evaluated.

This means that it gets CSCOMPILE and then it removes the bits that we
are not interested in.
2014-05-27 14:59:33 -04:00
Zoltan Varga 7b09fdb830 [llvm] Fix support for native types. 2014-05-27 20:42:07 +02:00
Mark Probst 164d79525a [sgen] Remove unnecessary newline from warning. 2014-05-27 10:46:59 -07:00
Mark Probst aa7447a7c5 [sgen] Fix for ridiculously small nurseries. 2014-05-27 10:46:58 -07:00
Joao Matos 649a692f38 Fixed TLAB_ACCESS_INIT usages in MSVC by moving the macro expansions to the start of each block. 2014-05-27 17:29:45 +01:00
Joao Matos 0f060c8c22 Revert "Fixed TLAB_ACCESS_INIT usages in MSVC by declaring the variables explicitly at the start of each block."
This will be fixed in a slightly different way.

This reverts commit aa7ab303ba.
2014-05-27 17:26:33 +01:00
Joao Matos 1342054e41 Replaced "__asm call $+5" pattern to get the IP with a label.
This was suggested by Kumpera as a work-around for the lack of support for $ in clang-cl.
2014-05-27 17:26:24 +01:00
Marek Safar aad8d4924b [corlib] Disable test 2014-05-27 18:14:27 +02:00
Marek Safar 3e36314d78 [mcs] More of correct error propagation 2014-05-27 18:14:27 +02:00
Rodrigo Kumpera d8eaf057ce [System.Configuration] Temporary fix for system.configuration test suite. 2014-05-27 11:04:42 -04:00
Marek Safar d1d81c9cb5 [system] Fix warnings 2014-05-27 17:04:24 +02:00
Marek Safar 9c07c63053 [mcs] Fix expression tree conversion type for lifted enum equality comparisons. Fixes #19938 2014-05-27 16:15:10 +02:00
Zoltan Varga 5ee706de7d [arm64] Fix mono_strtod (). 2014-05-27 15:29:17 +02:00
Marek Safar d79572f85c [mcs] Report error when named argument for param parameter is given but not all formal parameters are provided. Fixes #19878 2014-05-27 14:39:56 +02:00
marcos henrich da47aed900 Fixed bug 18482. Reseting all private key values to null is required because a new import may not overwrite existing values. 2014-05-27 12:11:32 +01:00
marcos henrich 1cc3bead45 Added test that covers bug 18482. 2014-05-27 12:06:55 +01:00
Alex Rønne Petersen 21b8b7da1e Merge pull request #1062 from sethjackson/sem_timedwait
OpenBSD has sem_timedwait().
2014-05-27 12:18:42 +02:00
Marek Safar fb220ceca1 [mcs] Unify reachable label lookup. Fixes #19887 2014-05-27 10:48:05 +02:00
Marek Safar 1f906df0a4 Merge pull request #1060 from rolfbjarne/logical-name-in-embedded-resources
[Microsoft.Build.Tasks] Add support for LogicalName in EmbeddedResources...
2014-05-27 09:32:55 +02:00
Atsushi Eno d75beb55c5 [ms.build] use appropriate ProjectCollection so that it can build the projects with appropriate settings.
Now a solution turns into a project with "BuildingSolutionFile" property
which is assigned by SolutionParser and subsequently gets _ExplicitReference
that is to store path to mscorlib.dll and thence projects build.
2014-05-27 14:11:49 +09:00
Atsushi Eno 1a5c229e9f [ms.build] follow xbuild to use version 12.0. 2014-05-27 14:11:48 +09:00
Atsushi Eno fcb70eeacb [ms.build] Add msbuild.rsp. 2014-05-27 14:11:47 +09:00
Seth Jackson 09456b827b OpenBSD has sem_timedwait().
This change released under the MIT license with permission from the original
author Robert Nagy.
2014-05-26 21:43:35 -04:00
Sebastien Pouliot dc872d9f5f [Mono.Security] Add new test files (form previous PR) to the build 2014-05-26 20:02:46 -04:00
Sebastien Pouliot 99b5aad5ee Merge pull request #1057 from lextm/master
[Mono.Security] Added Encode to AuthorityKeyIdentifierExtension and Subj...
2014-05-26 20:00:43 -04:00
Zoltan Varga e8082e1bcc Merge pull request #1061 from sethjackson/L_cuserid
L_cuserid was removed from OpenBSD.
2014-05-27 01:50:32 +02:00
Joao Matos 1c3a2b526c Replaced C99 variable-length array with an alloca to work with MSVC. 2014-05-26 23:43:28 +01:00
Joao Matos d5061abf1f Fixed SGEN_HASH_TABLE_INIT usages to work in MSVC. 2014-05-26 23:43:20 +01:00
Joao Matos aa7ab303ba Fixed TLAB_ACCESS_INIT usages in MSVC by declaring the variables explicitly at the start of each block. 2014-05-26 23:43:11 +01:00
Sebastien Pouliot 13ff02dc31 [System.ServiceModel.Web] Fix issue with types explicitly implementing IDictionary or IDictionary<,>
Issue: The previous code, with new tests [1], failed when the linker was
enabled.

That was caused because the code looks for the Keys and Item properties
getter using reflection. The linker handled that imperfectly (it left
some holes), in part because:

* System.Collections.Generic.IDictionary`2 does not implement
  System.Collections.IDictionary; and

* It preserved the explicit methods - not the implicit one that were
  used the the reflection-based code;

That later fact is also a bug (without the linker involvment) and solved
by this commit. A unit test was added to show the issue (NRE).

The patch also avoid the use of reflection for IDictionary since we can
simply typecast to get the same result (without the additional cost).
2014-05-26 17:27:26 -04:00
Seth Jackson c38e27bc7b L_cuserid was removed from OpenBSD.
This change released under the MIT license with permission from the original
author Christian Weisgerber.
2014-05-26 17:21:27 -04:00
Rolf Bjarne Kvinge 6143b52b03 Use string.IsNullOrEmpty instead of .Length. 2014-05-26 18:53:05 +02:00
Marek Safar 122a67e4c8 [mcs] Don't release field address copy before it's used. Fixes #20040 2014-05-26 18:51:11 +02:00
Rolf Bjarne Kvinge 7134ec8abf [arm64] Fix another crash due to not using the right objc_msgSend signature.
Also simplify the code a little bit, there's no need to have separate
code paths for ARM64, since using the correct objc_msgSend signature
works on all architectures.
2014-05-26 18:29:25 +02:00
Rolf Bjarne Kvinge 4f2920cbc1 Fix a couple of compiler warnings. 2014-05-26 18:29:25 +02:00
Rolf Bjarne Kvinge f7879a61a9 [Microsoft.Build.Tasks] Add support for LogicalName in EmbeddedResources. 2014-05-26 18:22:34 +02:00
Lex Li 0ff2798265 [Mono.Security] Added AuthorityKeyIdentifierExtensionTest and SubjectKeyIdentifierExtensionTest. 2014-05-26 13:24:00 +00:00
Marek Safar ec28a5d4b7 [mcs] Fix error reporting propagation for loop statements. Fixes #20034 2014-05-26 15:16:10 +02:00
Zoltan Varga 5b860c3cf5 Merge pull request #1059 from ranma42/jenkins-warnings-cleanup
Cleanup of some MonoJenkins warnings
2014-05-26 11:49:12 +02:00
Marek Safar 97baa22e86 Merge pull request #1033 from godFather89/master
When dynamically compiling script with a class with a nested class defin...
2014-05-26 09:55:40 +02:00
Marek Safar 49e626f420 [mcs] Don't report hiding warnings for compiler generated fields 2014-05-26 09:55:11 +02:00
Marek Safar e014ce692b [mcs] Add cref handling of user operator documentation without parameters 2014-05-26 09:55:11 +02:00
Marek Safar e08d611cfa [eval] Add test for nested types 2014-05-26 09:55:11 +02:00
Andrea Canciani a0d84a2661 Fix non-prototype function declarations
MonoJenkins repeatedly complains about:
mono-counters.c:xxx:1: warning: function declaration isn't a prototype
[-Wstrict-prototypes]

This is caused by the missing declaration of the function arguments.

This change is released under the MIT license.
2014-05-26 09:22:26 +02:00
Andrea Canciani 9f7554e973 More C90 compatibility fixes
This silences the following gcc/clang warnings from MonoJenkins:
sgen-tarjan-bridge.c:395:2: warning: ISO C90 forbids mixed declarations and code
proflog.c:1942:2: warning: ISO C90 forbids mixed declarations and code
proflog.c:1999:3: warning: ISO C90 forbids mixed declarations and code
decode.c:2409:6: warning: ISO C90 forbids mixed declarations and code
decode.c:2433:6: warning: ISO C90 forbids mixed declarations and code

Moving the declarations to the beginning of the blocks is sufficient
to silence the warnings.

This change is released under the MIT license.
2014-05-26 09:21:52 +02:00
Alex Rønne Petersen 09126b1b21 Rename configure.in -> configure.ac. Based on PR #976. 2014-05-25 19:04:06 +02:00
Alex Rønne Petersen d61bf0d21b Merge pull request #1056 from ranma42/vc-compat-C90
Fix the build on Visual C++
2014-05-25 18:49:12 +02:00
Lex Li 74eee04f28 [Mono.Security] Added Encode to AuthorityKeyIdentifierExtension and SubjectKeyIdentifierExtension. 2014-05-25 12:25:08 +00:00
Andrea Canciani d6ffe17718 Fix the build on Visual C++
Visual C++ does not support intermixed declarations and code and
errors out with:
error C2275: 'guint' : illegal use of this type as an expression

This also silences gcc/clang warnings such as:
mono-counters.c:xxx:3: warning: ISO C90 forbids mixing declarations
and code

In this case this can be fixed easily by skipping the intermediate
variable.

Based on pull request #1043 by J-M <[email protected]>

This change is released under the MIT license.
2014-05-25 10:07:34 +02:00
Marek Safar f2df46f68e Merge pull request #1055 from josedonizetti/fix_datacontractserializer_tests
validate if attribute is defined before check IsAny
2014-05-25 09:27:34 +02:00
Miguel de Icaza 60fa2525fb [build] the csproj files can now do a full class libraries build 2014-05-25 00:47:09 -04:00
Miguel de Icaza b5da7cd80d [System.Runtime.Remoting] Build if DBEUG Is defined 2014-05-25 00:41:55 -04:00
Miguel de Icaza a7eace18c1 [build] MSBuild setup: Add support for -keyfile and -delaysign, thanks to Marek Safar for the pointer 2014-05-25 00:33:21 -04:00
Miguel de Icaza ef0fdb0b2f [build] Drop AssemblyInfo from the sources in Mono.Cecil.Mdb 2014-05-25 00:32:18 -04:00
Miguel de Icaza 99574754c1 [build] Fix Mono.Cecil.Mdb build with xbuild 2014-05-25 00:07:57 -04:00
josedonizetti e30d3314e2 validate if attribute is defined before check IsAny 2014-05-24 21:08:09 -04:00
Marek Safar e1f9b1e084 Revert "[build] Make Mono.Cecil use an [assmebly:AssemblyKeyFile] to specify keyfile"
This reverts commit 20872b3abe to fix the build
2014-05-24 08:24:42 +02:00
Miguel de Icaza 20872b3abe [build] Make Mono.Cecil use an [assmebly:AssemblyKeyFile] to specify keyfile
Currently the flag is passed on the command line, but this is
problematic for us since our xbuild implementation does not seem to support
the attribute that generates the /keyfile: argument
2014-05-23 22:40:24 -04:00
Rolf Bjarne Kvinge 8f478d0861 Fix TimeZoneTest to build properly with new-style XI assemblies. 2014-05-24 02:18:39 +02:00
Rolf Bjarne Kvinge 8722bb5e9c Remove unused namespace from LazyTest.cs 2014-05-24 02:18:39 +02:00
Miguel de Icaza f7c32488e8 [build] Fix the reference to ecma.pub 2014-05-23 18:03:46 -04:00
Rodrigo Kumpera 36a382c794 [runtime] Don't leak memory if the custom attribute constructor throws. 2014-05-23 17:34:31 -04:00
Rodrigo Kumpera 8565d8dc35 [runtime] Add regression tests for custom attribute loader errors. 2014-05-23 17:34:31 -04:00
Rodrigo Kumpera 25f6affd89 [reflection] Harder the custom attribute code against common type load errors.
Replace silent failures with exceptions.
2014-05-23 17:34:31 -04:00
Rodrigo Kumpera 4d56422960 [runtime] Change the semantics of mono_error_set_type_load_name to acquire alloc'd strings.
The use case for this function compared to the one that take MonoClass/MonoImage is for lookups
and the failed names are usually freshly alloc'd.

Fix a leak in class.c usage of mono_error_set_type_load_name.
2014-05-23 17:34:30 -04:00
Rodrigo Kumpera 5e905069c4 [reflection] Do proper error handling in more cases.
Remove all internal usages of mono_custom_attrs_construct and replace with mono_custom_attrs_construct_by_type
that takes a MonoError.

Introduce mono_custom_attrs_get_attr_checked and replace usage of the old one where it's needed.
2014-05-23 17:34:29 -04:00
Miguel de Icaza 3599b97b57 [build] Fresh new csproj files based on the updated build system. 2014-05-23 17:15:53 -04:00
Miguel de Icaza e5428041b2 [build] Fix location of the key file 2014-05-23 17:15:53 -04:00
Miguel de Icaza b9501aa28d [Managed.Windows.Forms] Disable TRACE code, since it is broken 2014-05-23 17:15:52 -04:00
Miguel de Icaza 965220e1ef [build] The ecma.pub is one directory above 2014-05-23 17:15:52 -04:00
Miguel de Icaza 56dc31d943 [msvc/scripts] Update order.xml file with Makefile changes, update generator 2014-05-23 17:15:52 -04:00
Miguel de Icaza ae90d07888 [build] Ensure that staged build directories are set on LOCAL_MCS_FLAGS
The LOCAL_MCS_FLAGS are passed to the compiler before the standard
directory for the profile.  This is important both for correctness,
and also assists the solution generator, since we can now precisely
determine which intermediate project must be referenced.
2014-05-23 17:15:52 -04:00
Marek Safar db92449f41 Fix warnings 2014-05-23 21:27:38 +02:00
Marek Safar 1eac449e69 [system] Add SendMailAsync methods 2014-05-23 21:27:38 +02:00
Miguel de Icaza 8eade95cf8 [mscorlib] Since .NET 4.5 some of the System.IdentityModel now is in the core, add this class 2014-05-23 15:11:32 -04:00
Jonathan Pryor d2b5279484 [Mono.Posix] Support OS X ENOATTR
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=19991

The original Mono.Unix.Native.Errno design used the Linux <errno.h>
constants and values...largely because it was easy.

As it turns out, this is also incomplete. The getxattr(2) defines
ENOATTR as a possible error code. On Linux, ENOATTR is an alias for
ENODATA [0]. On OS X, ENOATTR is _not_ an alias. Furthermore, since
ENOATTR is not a Linux errno value (it's an alias!),
Mono_Posix_ToErrno() couldn't check for the native ENOATTR value, so a
Syscall.GetLastError() call after a failing Syscall.getxattr() would
fail with a System.ArgumentOutOfRangeException:

	$ csharp -r:Mono.Posix.dll
	Mono C# Shell, type "help;" for help

	Enter statements below.
	csharp> using Mono.Unix.Native;
	csharp> byte[] value;
	csharp> Syscall.getxattr(".", "test", out value);
	-1
	csharp> Syscall.GetLastError();
	System.ArgumentOutOfRangeException: Current platform doesn't support this value.
	Parameter name: value
	93
		at Mono.Unix.Native.NativeConvert.ThrowArgumentException (System.Object value) [0x00000] in <filename unknown>:0
		at Mono.Unix.Native.NativeConvert.ToErrno (Int32 value) [0x00000] in <filename unknown>:0
		at Mono.Unix.Native.Stdlib.GetLastError () [0x00000] in <filename unknown>:0

The fix is to add an Errno.ENOATTR field [1].

The complication is one of what enum value to use: at present, the
Errno values are based on the Linux values. In the case of ENOATTR
(and others), there is no Linux value. Meanwhile, there is the
possibility of additional Linux error values; how do we future proof
ourselves?

This isn't a perfect solution, but it should punt the problem down the
road a bit: Errno is an `int` enum, and thus has large range. To
support the OS X values, we add 1000 to the OS X error value.

	/* OS X: <errno.h> */
	#define ENOATTR		93		/* Attribute not found */

	// C# Errno enum:
	public enum Errno : int {
		// ...
		ENOATTR = 1093,
	}

This gives us 0..1000 for POSIX+Linux error codes, 1000..2000 for OS X
specific error codes, and as new platforms require additional support
they can all start at multiples of 1000.

Hopefully no single *nix platform will add more than 1000 error codes...

[0]: http://linux.die.net/man/2/getxattr
[1]: Related part of the fix: add all the OTHER <errno.h> values that
     OS X includes but weren't included in the Errno enum.
2014-05-23 13:45:10 -04:00
Sebastien Pouliot 4bc2c11690 Revert "[system] Add new StreamWebSocket.cs file to the mobile profile list of sources"
This reverts commit 00ecc7392d.
2014-05-23 13:26:34 -04:00
Atsushi Eno 103f398dcc [xbuild] fix NET_2_0 build. 2014-05-24 01:28:00 +09:00
Atsushi Eno 8db521d6f3 [xbuild] implement ToolLocationHelper.GetPathToStandardLibraries(). 2014-05-24 01:27:59 +09:00
Miguel de Icaza 0a806a14eb [build] Add new project files based on the new staged build 2014-05-23 11:51:20 -04:00
Miguel de Icaza 44f6d288ad [build] Use LOCAL_MCS_FLAGS to give preference to the intermediate dir in System builds, and do not use temporary files for corlib builds 2014-05-23 11:35:20 -04:00
Marek Safar a6dccdaf6d Revert "Merge pull request #981 from methane/websocket"
This reverts commit 62cc262196, reversing
changes made to c1028cf912.
2014-05-23 17:24:45 +02:00
Miguel de Icaza ec3fb70d33 [System] Fix parsing of IPv6 addresses (bug #18574)
From Dick Porter:

The IPv6 address parser misses some syntax errors, and can become confused by
addresses that at first glance look IPv4 compatible.  The attach patch contains
the following fixes:

Don't fail to parse an address if we mistakenly thought it was IPv4 compatible
or mapped, just treat it as IPv6.

Fix IPv4-compatible and mapped address formatting in ToString().

Fix parsing of colons - specifically occurrences of ':::'.

Make sure blocks of digits are no longer than 4 characters.

Add some more parsing tests to Mono's NUnit test suite.

Add a NUnit test for bogus IPv6 addresses.
2014-05-23 11:05:09 -04:00
Miguel de Icaza bed972e170 Update order.xml 2014-05-23 11:05:09 -04:00
Sebastien Pouliot dead6f36cf [system] Small optimization for Xamarin.Mac (where we know we're executing on a Mac) 2014-05-23 09:15:26 -04:00
Atsushi Eno 44f97b131b [msbuild] implement CodeTaskFactory i.e. inline tasks. 2014-05-23 21:19:29 +09:00
Atsushi Eno 28f7a73690 [MS.Build] fix some TaskFactory related bugs uncovered by CodeTaskFactory impl.
- ITaskFactory could return null, so check the return value.
- UsingTask descendants could have property references, so use ExpandString.
- TaskBody was not appropriately passed to internal structure.
2014-05-23 21:19:28 +09:00
Atsushi Eno 2e16d9bb6a [MS.Build] fix default build targets to not return empty list in Project.
And since the code is almost the same as existing ProjectInstance one, just
make it identical. (Should be unified, but depends on members, hence TODO.)
2014-05-23 21:19:27 +09:00
Martin Baulig 55ef36a296 Small fix. 2014-05-23 13:15:25 +02:00
Martin Baulig c30f3763a3 Revert "Fix WebProxy.BypassProxyOnLocal logic."
This reverts commit 3f7ad8f457.

WebProxy.BypassProxyOnLocal is really broken!  There seems to be no
way of actually bypassing a proxy on local connections.
2014-05-23 13:13:48 +02:00
Alex Rønne Petersen 08aee65d94 Merge pull request #1052 from sethjackson/master
Don't define _XOPEN_SOURCE on OpenBSD.
2014-05-23 12:49:28 +02:00
Marek Safar f93fa0d582 Fix tests not to hang on failure 2014-05-23 11:15:37 +02:00
Marek Safar 7a415e3919 [mcs] Expand type parameter member change using effective base type 2014-05-23 10:57:48 +02:00
Martin Baulig 3f7ad8f457 Fix WebProxy.BypassProxyOnLocal logic. 2014-05-23 10:22:44 +02:00
Marek Safar d737b63512 [mcs] Handling of nested effective base classes 2014-05-23 09:27:58 +02:00
Marek Safar 051ffdfbde Merge pull request #1051 from josedonizetti/bug11916-DataContractSerializer
add IsAny=true support for DataContractSerializer
2014-05-23 06:44:42 +02:00
Seth Jackson 256ec5591a Don't define _XOPEN_SOURCE on OpenBSD. With _XOPEN_SOURCE defined mincore() is not visible.
This change is licensed under the MIT license.
2014-05-23 00:06:44 -04:00
Miguel de Icaza f3237b8eb1 [build/msbuild] Tool resolves assemblies based on exact match, not random-last 2014-05-22 23:04:22 -04:00
Jose Donizetti 1690b16a73 add IsAny=true support for DataContractSerializer 2014-05-22 23:01:16 -04:00
Zoltan Varga cede1a3a6a [arm64] Fix the definition of DWARF_PC_REG, it should be x30 (lr). 2014-05-22 23:49:47 +02:00
Rolf Bjarne Kvinge a4738c64b0 Fix casing in monotouch_Mono.CSharp.dll.sources 2014-05-22 15:18:29 +02:00
Enrico Sada 920c4fbc3c fix V547 Expression 'ccw->ref_count >= 0' is always true. Unsigned type value is always >= 0. 2014-05-22 09:51:25 +02:00
Enrico Sada 8251d2b335 fix V547 Expression 'index >= 0' is always true. Unsigned type value is always >= 0. 2014-05-22 09:51:14 +02:00
Enrico Sada 759115c188 fix V547 Expression 'index >= 0' is always true. Unsigned type value is always >= 0. 2014-05-22 09:50:56 +02:00
Enrico Sada a36b6a47ac fix V595 The 'method' pointer was utilized before it was verified against nullptr. Check lines: 302, 303. 2014-05-22 09:48:03 +02:00
Enrico Sada 9e566344cf fix V595 The 'amodule' pointer was utilized before it was verified against nullptr 2014-05-22 09:45:51 +02:00
Atsushi Eno 0be292818e Merge pull request #924 from marcusva/master
- Use the correct absolute path for relative paths within a rooted path
2014-05-22 16:40:17 +09:00
Marek Safar e00a400b3b Merge pull request #164 from LogosBible/AppSettingsFileChanges
Use the configuration file path directory for AppSettings File directory
2014-05-22 09:13:56 +02:00
Alex Rønne Petersen abf8af6b78 Merge pull request #1045 from sethjackson/master
kinfo_proc2 was removed from OpenBSD. Use kinfo_proc instead.
2014-05-22 09:01:02 +02:00
Alex Rønne Petersen 14fc4325f6 Merge pull request #1046 from sethjackson/null-gc
Allow building with no GC again.
2014-05-22 08:59:55 +02:00
Marek Safar c9f4ae33e0 [mcs] Emit better code for null coalescing operator with nullable return type. Fixes #19702 2014-05-22 08:38:42 +02:00
Seth Jackson 2bcf7bdaea Allow building with no GC again.
These changes are released under the MIT license.
2014-05-21 17:02:35 -04:00
Seth Jackson 11973b1b7e kinfo_proc2 was removed from OpenBSD. Use kinfo_proc instead.
This change is released under the MIT license with permission from the
original author Robert Nagy.
2014-05-21 16:54:18 -04:00
Alex Rønne Petersen 02d6d971f3 Merge pull request #1049 from ranma42/fix-check-gdi-sibling
Fix checking when libgdi is configured as "sibling"
2014-05-21 21:09:00 +02:00
Andrea Canciani c9304c4262 Fix checking when libgdi is configured as "sibling"
When libgdiplus is configured as sibling, it is available in the
libgdiplus_loc path. This path was added to runtime/mono/config, but
it was later overridden by the prefix-based path.

Using the same approach as for libMonoPosixHelper fixed the lookup of
the library (performed, for example, when testing
MonoTests.System.Drawing without installing libgdiplus).

This change is released under the MIT license.
2014-05-21 19:28:20 +02:00
Martin Baulig f7f1bb819c [Http]: Cleanup and simplify the ServicePoint's connection group list. 2014-05-21 18:47:41 +02:00
Alex Rønne Petersen 3598b336cf Merge pull request #1032 from miguelzf/master
[Jay] Fix memory corruptions: out-of-bounds and uninitialized value.
2014-05-21 17:59:34 +02:00
Alex Rønne Petersen da1f37b001 Merge pull request #1044 from ranma42/fix-icc-build
Fix building mono with icc
2014-05-21 17:10:31 +02:00
Andrea Canciani 239cad7f18 Fix building mono with icc
When compiling mono with icc (ICC) 14.0.0 20130728 the build fails on

  CC     libmonoruntimesgen_la-sgen-stw.lo

with the following error:

Assembler messages:
Error: suffix or operands invalid for `lea'

Apparently icc (or the assembler) dislikes the rip-based LEA
operation. This can be worked around by manually assembling the
instruction and replacing it with the corresponding byte sequence.

This change is released under the MIT license.
2014-05-21 14:18:56 +02:00
David Karlaš 52b168e336 [Mono.Debugger.Soft] Caching VirtualMachine threads, caching frames in ThreadMirror and fetching StackFrames in bulk for all threads 2014-05-21 13:13:44 +02:00
Marek Safar 36f7dd787f [mcs] Add explicit array conversion involving type parameters. Fixes #18474 2014-05-21 12:50:55 +02:00
Marek Safar 7a550bd91a [mcs] Undo implicit object prefix for cref interface references 2014-05-21 12:50:55 +02:00
Atsushi Eno 348fa2580e [MS.Build] fix support for MSBuildExtensionsPath* to try more than one paths.
So, it seems that where MSBuildExtensionsPath* is evaluated should be likely
evaluated multiple times, and find actually matching files in one of those.
F# build .targets file expects that.
Since it is almost impossible to assume in which usage scenario it is going
to be evaluated multiple times (those properties can be used anywhere by
simple $(...) syntax), it limits the attempts only for Import() so far.
Old xbuild actually does so too. That way, the particular F# issue is fixed.
2014-05-21 19:03:33 +09:00
Atsushi Eno b5349f25ff [MS.Build] Fix metadata item parsing wrong indexing. 2014-05-21 19:03:33 +09:00
Marek Safar 35a8179e1d [mcs] Explicit type parameter conversion to generic parameter 2014-05-21 10:19:25 +02:00
Rodrigo Kumpera f304ca8be1 [GC] Make size dependent vars use size_t instead of glong or int.
This opens the door for huge nurseries.
2014-05-21 00:03:52 -04:00
Miguel de Icaza b8799913fa [vsbuild] Update Makefiles to not generate the VS metadata for the 'basic' profile 2014-05-20 22:31:49 -04:00
Miguel de Icaza 8eb943998c [build] Kill OpenSystem.C from the Makefile 2014-05-20 22:31:44 -04:00
Miguel de Icaza a6eaaffb4c [build] Revert change in Facades parellism patch, since it works great for builds, but not for other recursive targets (ie: update-csproj, maybe others 2014-05-20 22:30:29 -04:00
Miguel de Icaza 783b24aeac [build] Kill OpenSystem.C, nobody ever used this 2014-05-20 22:17:14 -04:00
Miguel de Icaza e62f341e57 [build] Fix the build for NET_4_5 (and maybe other profiles) from the pull request 981 2014-05-20 22:04:29 -04:00
Martin Baulig e49d56e8d1 [Http]: Cleanup chained async operations; bug #19161. 2014-05-21 02:26:48 +02:00
Sebastien Pouliot 00ecc7392d [system] Add new StreamWebSocket.cs file to the mobile profile list of sources 2014-05-20 17:29:12 -04:00
Sebastien Pouliot 8f51223150 [facades] Build the facades assemblies defined for the profile being built 2014-05-20 16:57:12 -04:00
Zoltan Varga f29c547b65 [sdb] Make sure the ids of unloading assemblies is the same in the ASSEMBLY_UNLOAD event as it was in the ASSEMBLY_LOAD event. 2014-05-20 21:28:31 +02:00
Zoltan Varga 75a7c3219c [runtime] Clean up an #ifdef block. 2014-05-20 20:01:23 +02:00
Marek Safar 62cc262196 Merge pull request #981 from methane/websocket
[websocket] Implement HttpListenerContext.AcceptWebSocketAsync()
2014-05-20 19:56:13 +02:00
Marek Safar c1028cf912 [corlib] Fix public api 2014-05-20 19:35:25 +02:00
Zoltan Varga 628aa55e74 [llvm] Update to the llvm backend to work with llvm a82b09c3a3efbfaf2ce39adc113f9a5458cde398. 2014-05-20 19:09:31 +02:00
Sebastien Pouliot d6eaeb508a [System.Core][ios] Fix value for ENAMETOOLONG (typo?) internal constant in System.IO.MemoryMappedFiles.MemoryMappedFile 2014-05-20 11:24:40 -04:00
Marek Safar b7adbe3140 [corlib] Add Guid hex format parsing with whitespaces. Fixes #19915 2014-05-20 16:37:48 +02:00
Zoltan Varga dbb6cfa908 [llvm] Detect the cpu architecture and pass it to EngineBuilder, recent llvm versions require this to be able to support sse etc. 2014-05-20 15:00:35 +02:00
Marek Safar feaba5a270 [mcs] Use correct parent type in partial type base context 2014-05-20 14:05:38 +02:00
Alexis Christoforides 256e54e232 Merge pull request #1040 from ermshiperete/bug-xamarin-19856
[MWF] Fix opacity of form (#19856)
2014-05-20 07:22:56 -04:00
Marek Habersack 0c62f05785 Add a missing assembly name to full type specification.
Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=19839
2014-05-20 10:13:25 +02:00
Atsushi Eno 957b3a4a5d [MS.Build] add internal expression debugging helper strings. 2014-05-20 16:20:56 +09:00
Atsushi Eno 79492ddd92 [MS.Build] process Choose/When/Otherwise elements (they were left forgotten). 2014-05-20 16:20:55 +09:00
Atsushi Eno 375c8f755c [ms.build] remove unused code. 2014-05-20 16:20:54 +09:00
Marek Safar 80f19dc90f [xbuild] Add ReferenceOutputAssembly filter 2014-05-20 07:12:15 +02:00
Marek Safar eb35c311f1 Remove 2.0 defines 2014-05-20 07:12:15 +02:00
Miguel de Icaza 28df1505c6 [build] Record extra library builds for our Visual Studio input files
Added local targets (csproj-local) to all the assemblies that have
staged builds to dump their build information for the underlying
dependencies.

This information is needed to create the new Visual Studio csproj
files.

This commit also updates the collected build metadata from running:

     make update-csproj
     make package-inputs

As described in msvc/scripts/README
2014-05-19 22:55:00 -04:00
Joao Matos de46a3dd58 Added System.IO.Compression implementation based on SharpCompress. 2014-05-19 22:24:41 +01:00
Joao Matos d4c8e67b63 Added SharpCompress Zip archive implementation.
This copy is based on our own fork at mono/sharpcompress.
2014-05-19 22:24:37 +01:00
Rodrigo Kumpera 13a26cd03e [corlib] Fix the 2.0 testsuite. 2014-05-19 10:19:26 -04:00
Atsushi Eno 84892f7051 [MS.Build] add "OS" _undocumented_ predefined property.
It is used by Xamarin.Android to determine which compiler to use (csc or smcs)
and lack of this property simply caused Csc build task failure.
2014-05-19 19:38:52 +09:00
Atsushi Eno e29bf81fe6 [MS.Build] now ITaskItem impl. in BuildEngine4 behaves consistent with MS.Build.Tasks.
To be precise, now the implementation returns ItemSpec for ToString().
WriteLinesIntoFile task writes ITaskItem[] lines into a file, without calling
ItemSpec.
Maybe it is better to fix Tasks.dll but I'm unsure about xbuild compatibility.

This missing ToString() override caused target framework monikor output
to become invalid source file (i.e. it used to write ItemSpec as code(!) but
this ITaskItem impl. in BuildEngine4 just wrote its type name as .ToString()
result).
2014-05-19 17:54:59 +09:00
Marek Safar c2d39344f3 [System.Net.Http] Parsing productinfo like headers with missing version. Fixes #19881 2014-05-19 10:03:07 +02:00
Marek Safar 9543a375a7 [mcs] Add handling for special case cref types/members 2014-05-19 10:03:07 +02:00
Marek Safar fcd79ef5c1 [xbuild] Add missing apis 2014-05-19 10:03:07 +02:00
Marek Safar 9036c4c51a [xbuild] Add string to char[] argument conversion 2014-05-19 10:03:07 +02:00
Miguel de Icaza dad7d32075 [build] System.Configuration: fix signatures.
We must use the secxml library directory to reference System, not
bare.

The bare build does not contain a full signature for some interfaces
(there is a using XmlNode = object in a few interfaces that
System.Configuration depends on).

So System.Configuration must reference the System that has been
compiled with XML support.
2014-05-18 23:11:29 -04:00
Zoltan Varga c1f711e373 Merge pull request #1042 from xplicit/fixdocs
[docs] added mising closing h4 tag
2014-05-18 12:41:53 +02:00
xplicit cba0492522 [docs] closing h2 tag 2014-05-18 07:43:13 +07:00
xplicit bb90bc9e4d added closing h4 tag 2014-05-18 05:23:49 +07:00
Zoltan Varga 2537c96476 [sdb] Avoid waiting for an answer for the START_BUFFERING/STOP_BUFFERING commands. 2014-05-17 23:39:22 +02:00
Zoltan Varga 13e32b3fed [sdb] Add support for client side packet buffering. 2014-05-17 23:27:46 +02:00
Zoltan Varga e0d791f7a5 [sdb] Add ability to buffer reply packets in the wire protocol when running on high latency links like usb. Uses a pair of START_BUFFERING/STOP_BUFFERING protocol commands. 2014-05-17 21:45:19 +02:00
Miguel de Icaza 0f5cc494a7 [build/Facades] Parallelize the Facades directory build
The parallelization is done by overriding the default "all" target
and instead of using the serial subdirectory processing that goes
over the SUBDIR and xx_SUBDIR rules, we turn the list of
subdirectories into the name of the target, for example:

     System.Collections.Concurrent

becomes:

     ../../class/lib/net_4_5/Facades/System.Collections.Concurrent.dll

Then a pattern is added to handle that rule:

     $(target_dir)/%.dll:

This allows the build to be parallized.
2014-05-16 21:48:47 -04:00
Rodrigo Kumpera 1531d4f34d [System] Throw IOE in more cases when dealing with an invalid Process object. Fixes #19864 2014-05-16 16:30:56 -04:00
Rodrigo Kumpera 17f8e4142f [corlib] Fix ClaimsIdentity default ctor. 2014-05-16 16:04:22 -04:00
Miguel de Icaza a3de5976ed Merge pull request #1041 from mono/staged-cyclic-builds
This patch introduces an infrastructure to stage the builds for the core
assemblies that have cyclic dependencies.   This deals directly with
the following cycle:

    System.dll requires:
	System.Configuration.dll
	Mono.Security.dll
	System.Xml.dll

	They all require System.dll to be built

    System.Xml requires:
	System.dll
	System.Configuration.dll

    System.Security.dll requires:
	System.dll
	Mono.Security.dll
	System.Xml.dll

Principle
=========

The patch works by directing the build infrastructure to place
intermediate build steps on their own directory.  For example the
first System.dll build that only takes a dependency in mscorlib.dll is
placed not under the final directory but on a subdirectory called
"bare".

The second time that System.dll is built (after Mono.Security and
System.Xml have been built) is placed on the "secxml" directory.

The third time is the final build, and that one ends in the profile
directory.

The same principle is applied to System.Xml.

Better Dependency Tracking
==========================

To handle the multiple stages, the new Makefiles for the various
parties involved in this loop are now able to build their
dependencies.  This means that typing "make" on System.Security or
System.Xml or System will build all of the intermediate steps as
required, without needing the toplevel Makefile to perform multiple
build shots to incrementally build the result.

Bug fixes
=========

We must have regressed at some point the build of System.Xml as we
were only doing one build of it, one without System.Configuration
support.  This patch introduces back the changes to build System.Xml
in two steps.

This patch fixes the setup where we end up rebuilding System.dll and
overwriting it two times as the build progresses as a side effect
(this is what required LIBRARY_USE_INTERMEDIATE_FILE).

Details
=======

library.make:

	Introduces a new "the_libdir_base" which is the raw directory
	where the final output will go.   This points to the same location
	that libdir_base previously pointed to.

	The existing libdir_base is modified to contain an optional
	"intermediate" directory, where intermediate builds can be
	placed.
2014-05-16 15:48:41 -04:00
Eberhard Beilharz 2614e55bee [MWF] Fix opacity of form (#19856) 2014-05-16 18:50:37 +02:00
Miguel de Icaza 89e0b257d4 Merge pull request #1039 from joelmartinez/master
[monodoc] removed erroneous instance of 'FOO' string.
2014-05-16 12:13:53 -04:00
Miguel de Icaza 39ad7e3786 Merge pull request #943 from ermshiperete/bug-novell-325669
[MWF] Implement multi-display support on Linux (Fixes #325669)
2014-05-16 10:54:22 -04:00
Stephen McConnel 809bd8c9b6 [MWF] Fix ComboBox list to not display offscreen (#15462)
The fix mimics the behavior of Windows/.NET.
2014-05-16 16:21:59 +02:00
Stephen McConnel c4ce5cce49 [MWF] Fix Screen.FromRectangle (#8271)
The Screen.FromRectangle method was too simple minded.  It did not try to
find the best match for a screen when the system has more than one screen.
The new implementation makes at least some effort to find the closest
screen with the most overlap with the rectangle.
2014-05-16 16:21:58 +02:00
Eberhard Beilharz e1b7ecdb7b [MWF] Implement multi-display support on Linux (Fixes #325669)
The number of displays and sizes can be retrieved with the help of
libXinerama. The implementation was done in a way that is backwards
compatible, so on non-Linux systems or when libXinerama is not
available the behavior will be the same as before.

Also fixed the implementation of FormStartPosition.CenterScreen to
bring up the form centered on the current display (with the current
display being either the screen the top left corner of the owner
form is on, or if there is no owner the screen that has the mouse
pointer). This fixes Novell bug #325669 on Linux
(https://bugzilla.novell.com/show_bug.cgi?id=325669).
2014-05-16 16:21:51 +02:00
Joel Martinez 4de2bc52c5 [monodoc] removed erroneous instance of 'FOO' string. 2014-05-16 09:52:14 -04:00
Atsushi Eno 4930f612ae [MS.Build] for item metadata access expression, remove surrounding ' and ".
The test case would explain what is not desired there.
2014-05-16 22:00:05 +09:00
Atsushi Eno 554dc2983e [MS.Build] more cleanup (remove debugging, kill extra code). 2014-05-16 14:50:59 +09:00
Miguel de Icaza 524f732a6d Merge pull request #993 from ancailliau/fix-datacontract-json-serialization
[Fix] DataContractJsonSerializer fails serializing/deserializing collections
2014-05-15 17:34:53 -04:00
Miguel de Icaza bf2e5e58df Merge pull request #925 from ermshiperete/novell-bug-602934
[Printing] Fix for Novell bug #602934: improve values that printer settings return
2014-05-15 17:27:39 -04:00
Miguel de Icaza 4f61b92ce0 Merge pull request #942 from ermshiperete/MessageBoxBugs
[MWF] Improvements to MessageBox width
2014-05-15 17:26:13 -04:00
Miguel de Icaza 8a28f5d152 Merge pull request #948 from ermshiperete/bug-xamarin-2394
[MWF] Fixes related to Height and MinimumHeight in DataGridView
2014-05-15 17:22:31 -04:00
Miguel de Icaza 96edd46e16 Merge pull request #926 from ermshiperete/novell-bug-674098
[MWF] Fix hang if clipboard source application closes down
2014-05-15 17:21:55 -04:00
Mika Aalto ef4ed1a61f Removed unneeded NET_2_0 ifdefs 2014-05-15 17:17:44 -04:00
Mika Aalto ccd93fc95a Added implementation and unit tests for GetFieldValue, GetStream and GetTextReader methods in DbDataReader class.
Used https://github.com/matthid/mono/commit/51e808b3836e9ba32901762ea23941ee60b2746d as reference.
2014-05-15 17:17:44 -04:00
Miguel de Icaza 69cd9d1b14 Merge pull request #954 from ermshiperete/bug-xamarin-8907
[MWF] Fix TableLayoutPanel layout bug (#8907)
2014-05-15 17:13:21 -04:00
Miguel de Icaza 48496cae2b Merge pull request #952 from ermshiperete/bug-xamarin-2912
[MWF] Fix AutoSize behavior of FlowLayoutPanel (#2912)
2014-05-15 17:12:51 -04:00
Miguel de Icaza b60bbdc365 Merge pull request #951 from ermshiperete/bug-xamarin-2462
[MWF] Fix clipping of last line of dropdown (#2462)
2014-05-15 17:11:46 -04:00
Miguel de Icaza adc40c3f99 Merge pull request #950 from ermshiperete/bug-xamarin-2787
[MWF] Release capture when clicking LinkLabel (Fixes #2787)
2014-05-15 17:11:14 -04:00
Miguel de Icaza 6bc565c1f7 Merge pull request #949 from ermshiperete/bug-novell-463149
[MWF] Fix text position on buttons (#463149)
2014-05-15 17:08:54 -04:00
Miguel de Icaza 80b9d3ac18 Merge pull request #1038 from ermshiperete/bug-xamarin-19818
[MWF] Don't try to remove non-child control (#19818)
2014-05-15 16:10:21 -04:00
Miguel de Icaza e0137c416b Drop mono.web.pc 2014-05-15 15:54:18 -04:00
Rodrigo Kumpera a9b07ba04b [runtime] Fix hazard pointer usage in the suspend sequence.
We now have a pair of functions to match mono_thread_info_safe_suspend_sync.
They should be used instead of mono_thread_resume as they do the right thing
WRT to hazard pointers.
2014-05-15 15:52:55 -04:00
Rodrigo Kumpera 2285b4c10f [runtime] Fix a hazard pointer leakage in mono_thread_info_resume.
mono_thread_info_lookup leaves the current value on hazard pointer 1,
so all callers must clean it afterwards. This was not done in all cases
by mono_thread_info_resume.
2014-05-15 15:52:54 -04:00
Rodrigo Kumpera eaa625e707 [runtime] Pass the MonoThreadInfo explicitly to mono_thread_state_init_from_handle to avoid nested hazzard point usage.
This function was called from code that uses hazard pointers, so their values could get overridden.
Besides that, we did not clean up the hazard pointer table afterwards, which is wrong too.
2014-05-15 15:52:54 -04:00
Miguel de Icaza 34b0d2d87f [Mono.Web] Further steps to kill Mono.web, this time the pkg-config files 2014-05-15 15:45:01 -04:00
Alexis Christoforides 60dc549a32 [io-layer] Added missing handle type in _wapi_handle_struct_size... 2014-05-15 15:27:55 -04:00
Miguel de Icaza 3cd9b7e003 Merge pull request #1034 from joelmartinez/msdoc-import2
Second pass of Microsoft Documentation import
2014-05-15 14:48:07 -04:00
Marek Safar 563a83943e [System.ComponentModel.DataAnnotations] Add UrlAttribute type. 2014-05-15 19:44:20 +02:00
Alexis Christoforides 509ce4486f [io-layer] Fixed error condition in _wapi_handle_struct_size. 2014-05-15 13:27:22 -04:00
Zoltan Varga 8d9e02de31 [runtime] Fix decoding of jagged arrays in custom attributes. Fixes #19825. 2014-05-15 19:27:10 +02:00
Marek Safar c065a43742 Fixes 60d7997e02 commit 2014-05-15 19:25:37 +02:00
Miguel de Icaza d5c37b6a12 [System.Security.Claims] Add ClaimsPrincipal 2014-05-15 12:54:16 -04:00
Miguel de Icaza 2aed7bc797 [System.Security.Claims] Add basic support for Claims 2014-05-15 12:54:16 -04:00
Marek Safar 9a252dffbc [xbuild] Property Functions implementation 2014-05-15 17:45:39 +02:00
Eberhard Beilharz 29d8e275d5 [MWF] Don't try to remove non-child control (#19818)
When removing a control from a controls collection we have to
check that the control is part of the collection. Otherwise
we shouldn't do anything.
2014-05-15 17:28:57 +02:00
Eberhard Beilharz 2b1086994f [MWF] Add unit test for #19818 2014-05-15 17:21:08 +02:00
Alexis Christoforides 58834ddfd6 [io-layer] Precise memcpy of handle structs.
First issue found by AddressSanitizer.
2014-05-15 10:57:11 -04:00
Atsushi Eno 60d7997e02 [MS.Build] cleanup ITaskItem evaluation related old code. 2014-05-15 23:55:20 +09:00
Atsushi Eno 16c9f61199 [MS.Build] now ITaskItems are collected while evaluating expression and metadata is filled later.
It is kind of reverting previous implementation of item metadata for expression.
Code cleanup should follow.
2014-05-15 23:55:19 +09:00
Atsushi Eno 89417f1bef [MS.Build] skip null string entry as input to string.Join(). 2014-05-15 23:55:19 +09:00
Atsushi Eno 2091b968fd [msbuild] ongoing ITaskItem input parameter handling improvements.
Right now all the input parameters are computed based on string, and any
metadata items are simply chopped out when it is passed to a Task.
To fix this, we need to replace ExpandString() use with more complicated
evaluator that takes ITaskItem into consideration.

(It is not complete as of now; evaluation method needs to be replaced and
any regressions need to be fixed.)
2014-05-15 23:55:18 +09:00
Atsushi Eno 51034e6056 [MS.Build] more of the same (remove obsolete comment). 2014-05-15 23:55:18 +09:00
Atsushi Eno ed2f443041 [MS.Build] remove extraneous expression evaluation code. 2014-05-15 23:55:17 +09:00
Atsushi Eno 45c5657c3e [MS.Build] add another expression expansion test. 2014-05-15 23:55:17 +09:00
Atsushi Eno 35dda9dacd [MS.Build] output item was dropping metadata after running task. 2014-05-15 23:55:16 +09:00
Ludovic Henry 962b14ae36 [mprof-report] Add counter filter when not in verbose mode
This will reduce the amount of printed counters in non verbose mode.
2014-05-15 09:50:16 -04:00
Ludovic Henry 858db2fabc [mprof-report] Extract the counter key prefix of dump_counters_value 2014-05-15 09:50:15 -04:00
Zoltan Varga bf4c6fe295 [runtime] Avoid calling mono_thread_current () in sgen_thread_detach (), since it can construct objects. Fixes #19755. 2014-05-15 14:05:03 +02:00
Miguel de Icaza effaf02382 Adjust the path for Mono.Security 2014-05-14 23:25:28 -04:00
Miguel de Icaza 4b3977ecef Last of the cycles is gone 2014-05-14 23:06:19 -04:00
Jonathan Pryor c4775a55b8 [mdoc] Fix NullReferenceException when importing @name attribute.
(Reported by directhex on #mono 2014-05-14 at 14:28 EDT.)

When importing Microsoft XML Documentation, if a //altmember/@name,
//exception/@name, or //permission/@name attribute is encountered then
mdoc will die with a NullReferenceException:

	mdoc: System.NullReferenceException: Object reference not set to an instance of an object
	  at Mono.Documentation.MsxdocDocumentationImporter.ImportDocumentation (Mono.Documentation.DocsNodeInfo info)
	  at Mono.Documentation.MDocUpdater.MakeDocNode (Mono.Documentation.DocsNodeInfo info)
	  at Mono.Documentation.MDocUpdater.UpdateMember (Mono.Documentation.DocsNodeInfo info)
	  at Mono.Documentation.MDocUpdater.MakeMember (System.Xml.XmlDocument doc, Mono.Documentation.DocsNodeInfo info)
	  at Mono.Documentation.MDocUpdater.DoUpdateType2 (System.String message, System.Xml.XmlDocument basefile, Mono.Cecil.TypeDefinition type, System.String output, Boolean insertSince)
	  at Mono.Documentation.MDocUpdater.StubType (Mono.Cecil.TypeDefinition type, System.String output)
	  at Mono.Documentation.MDocUpdater.DoUpdateType (Mono.Cecil.TypeDefinition type, System.String basepath, System.String dest)
	  at Mono.Documentation.MDocUpdater.DoUpdateAssembly (Mono.Cecil.AssemblyDefinition assembly, System.Xml.XmlElement index_types, System.String source, System.String dest, System.Collections.Generic.HashSet`1 goodfiles)
	  at Mono.Documentation.MDocUpdater.DoUpdateAssemblies (System.String source, System.String dest)
	  at Mono.Documentation.MDocUpdater.Run (IEnumerable`1 args)
	  at Mono.Documentation.MDoc.Run (System.String[] args)
	  at Mono.Documentation.MDoc.Main (System.String[] args)

The cause of the NullReferenceException is due to inconsistent
checking: we check that _either_ `child.Attributes["cref"]` OR
`child.Attributes["name"]` is not null, and if one of them IS non-null
then we just grab `child.Attributes["cref"].Value`, which will throw a
NullReferenceException if the @name attribute was present but not the
@cref attribute.

The fix is to be consistent: once we grab an XmlAttribute, use the
already looked up XmlAttribute, don't re-look it up.
2014-05-14 16:09:10 -04:00
Zoltan Varga 4d388f07d4 [runtime] Avoid passing commands to lldb using the python api, it doesn't seem to work well in script files. Fixes #19732. 2014-05-14 21:23:48 +02:00
Michael Hutchinson cb33b94c85 [xbuild] Fix parsing messages with empty/blank origin 2014-05-14 14:22:01 -04:00
Zoltan Varga abaceb24f4 [runtime] Fix Process.TotalProcessorTime becoming negative. Fixes #19739. 2014-05-14 19:17:57 +02:00
Jonathan Pryor 4c45fe93a1 [system.net.http] Set version to 4.0.0.0 on MOBILE
For a variety of reasons, we need to bump the assembly version of
System.Net.Http.dll to "4.0.0.0" (from 2.0.5.0) on our MOBILE
profiles, lest much pain and suffering occur, e.g.:

	http://motzcod.es/post/78863496592/portable-class-libraries-httpclient-so-happy

> For some reason at compile time the facades don’t kick in
> properly and it tries to use the NuGet version of
> System.Net.Http which has some specific functionality for
> older platforms. ...
> All you need to do is create a new app.config file in your
> Android and iOS project.

The need to create a custom app.config is ugly and something
to be avoided. Setting our System.Net.Http.dll version to
v4.0.0.0 removes the need for the custom app.config.
2014-05-14 13:02:10 -04:00
Jeffrey Stedfast 2ad48abb5d Merge pull request #1037 from DavidKarlas/fixingParamName
Fixing regression from previous commit
2014-05-14 11:14:44 -04:00
David Karlaš f8d7ff9249 [Mono.Debugger.Soft] Fixing regression from previous commit where type name instead of parameter name was used 2014-05-14 16:56:46 +02:00
Jeffrey Stedfast a8f3f7754f Merge pull request #1036 from DavidKarlas/cacheSdbLocking
[Mono.Debugger.Soft] Adding thread locking on access to tokensCache dictionary
2014-05-14 06:47:53 -04:00
David Karlaš 98137aad31 [Mono.Debugger.Soft] Adding thread locking on access to tokensCache dictionary 2014-05-14 06:41:43 +02:00
Jeffrey Stedfast 1495baabf4 Merge pull request #1035 from DavidKarlas/cacheSdb
[Mono.Debugger.Soft] More caching
2014-05-13 19:39:38 -04:00
Rodrigo Kumpera 701e303006 [runtime] Fix a pair of thread abort races in classic abort code.
The two races in question are:

In signal_thread_state_change we need to block the target from
further waiting before we signal it or otherwise it might miss the
broadcast asking it to wakeup.

In mono_thread_request_interruption we need to ensure we self interrupt
before returning from the signal handler.
2014-05-13 19:19:43 -04:00
Rodrigo Kumpera 56130af322 [jit] Unblock more critical signals at startup.
Unblock the GC suspend/restart signals and SIGCHLD. Those are required to make the GC
and process watching work.

The SIGCHLD issue was found on mod_mono that fork a process with that signal blocked.

The GC signals are been preemptively unblocked as we can never know what sort of sig mask
we'll start with.
2014-05-13 19:19:38 -04:00
Rodrigo Kumpera dd77c09cae [gc] Add mono_gc_get_restart_signal. 2014-05-13 19:19:36 -04:00
Rodrigo Kumpera faef3b958e [sgen] Implement mono_gc_get_restart_signal. 2014-05-13 19:19:30 -04:00
Rodrigo Kumpera 0d368edf3f [boehm] Implement mono_gc_get_restart_signal. 2014-05-13 19:10:57 -04:00
Miguel de Icaza c60aaa3af6 [System.IO.KeventWatcher] Introduce enums with the KEvent flags and constants
This merely introduces a more readable version of some of the constants that
were hardcoded on the source code.

There is a suspect value "20" that was on the original source code, that
stands for VNodeLink and VNodeExtend, but perhaps the original author
meant to say VNodeRename.   In any case, it seems like we should catch all
of them (except for Revoke).
2014-05-13 18:11:57 -04:00
Zoltan Varga a4f595060b [bcl] Fix Process.PrivateMemorySize64 on osx, we now return task_baic_info.resident_size. Fixes #19738. 2014-05-13 23:51:58 +02:00
Zoltan Varga fc9d536e74 Clean up the usage of FILETIME structures, avoid accessing them as gint64 since that would lead to alignment problems. Hopefully fixes #19739. 2014-05-13 23:40:48 +02:00
David Karlaš d4c5107882 [Mono.Debugger.Soft] Caching tokens resolving 2014-05-13 20:20:46 +02:00
David Karlaš f7b5ab5d9f [Mono.Debugger.Soft] Using cached GetParameters when fetching GetLocals 2014-05-13 20:18:26 +02:00
Ludovic Henry c162b07256 [mprof-report] Fix crash in case no counters values were sampled because of too short run time 2014-05-13 13:49:07 -04:00
Zoltan Varga 5f54be7af1 [sdb] Avoid stack overflows when a boxed vtype recursively references itself using fields. Fixes #18914. 2014-05-13 18:32:12 +02:00
Paolo Molaro aca422f6ac [profiler] Add managed backtrace support to sampling mode for the signal-based impl. 2014-05-13 17:42:04 +02:00
Ludovic Henry 3fe3529a45 [mprof-report] Fix bug where no counters would be printed if --verbose or --counters-sort=category were not passed 2014-05-13 09:50:06 -04:00
Paolo Molaro 6e81eda0e4 [profiler] Filter more event types in mprof-report based on time (more xambug #11904). 2014-05-13 15:18:22 +02:00
Paolo Molaro fa59a719c0 [profiler] In mprof-report fix handling of the time filter when starting from 0 (xambug #11904). 2014-05-13 13:20:50 +02:00
Paolo Molaro d33d022896 [profiler] Emit statistical samples at 1 second intervals and fix race condition. 2014-05-13 12:59:06 +02:00
Ludovic Henry f51237aa3e Merge pull request #1020 from ludovic-henry/pr7-system-counters
[counters] Add system counters
2014-05-12 17:19:34 -04:00
Ludovic Henry 3b5527fa00 [counters] Edit according to Kumpera review 2014-05-12 16:37:20 -04:00
Joel Martinez e9068ebf5b [docs] documentation import for 'returns' elements. 2014-05-12 14:52:53 -04:00
Joel Martinez 891e93e1fe [docs] Import of additional member documentation that contain generic parameteres 2014-05-12 14:52:48 -04:00
Joel Martinez d4fcdb95b4 [docs] namespace documentation import. 2014-05-12 14:52:47 -04:00
Joel Martinez b7293faf40 [docs] type parameter documentation impport. 2014-05-12 14:52:47 -04:00
Joel Martinez aef2cb86cb [docs] Additional parameter documentation import. 2014-05-12 14:52:47 -04:00
Marek Habersack 92f2a76fea [system.web] remove some more remnants of Mono.Web.dll to fix Xamarin Studio activation
The section mapping system wasn't being initialized and used properly since some ifdefs had
been left in the source code. This caused a null reference exception while trying to perform
some HTTP requests and, as the result, broke Xamarin Studio activation.
2014-05-12 19:33:10 +02:00
Zoltan Varga ca4ebb4f67 [arm] Add support for the new compare instructions used by native types. 2014-05-12 18:20:28 +02:00
Ludovic Henry 0b2833cca0 [decode] Edit according to Paolo review 2014-05-12 11:02:44 -04:00
Ludovic Henry 74e49cef38 [decode] Fix sample difference parsing 2014-05-12 11:02:43 -04:00
Ludovic Henry 8d9661bd1f [decode] Add command line counters options parsing 2014-05-12 11:02:43 -04:00
Ludovic Henry 6e3fdba3fe [decode] Add dump_counters
Two main way to dump :
 - per Time : equivalent to a --stats but every seconds, useful to see the overall evolution of all counters
 - per Category : print sample values grouped per category and counters, useful to see the evolution of a specific counter over time
2014-05-12 11:02:43 -04:00
Ludovic Henry 5ff75a022f [decode] Add parsing for TYPE_SAMPLE_COUNTERS 2014-05-12 11:02:43 -04:00
Ludovic Henry 384e15f7c9 [decode] Add parsing for TYPE_SAMPLE_COUNTERS_DESC 2014-05-12 11:02:42 -04:00
Ludovic Henry cbd1950ad9 [decode] Add functions to transform mono-counters enum to strings 2014-05-12 11:02:42 -04:00
Ludovic Henry 6552bcff44 [decode] Add functions to manipulate counters, counters_sections and counters_timestamps
This variables are respectively :
 - the list of all counters
 - the list of all counters grouped by sections
 - the list of all counters groupes by sample value timestamps and sections
2014-05-12 11:02:42 -04:00
Ludovic Henry 8f60e4edc0 [decode] Add Counter, CounterValue, CounterList, CounterSection and CounterTimestamp structs
Counter : contains metadata concerning a counter. There is one in memory per counter index (right now ~100).
CounterValue : represent a sample value of a counter.
CounterList : it is a utility struct that contains a list of counters.
CounterSection : represent all the counters that are in this sections. Used only when we sort counters per category.
CounterTimestamp : represent all the counters that have a sample value at this timestamp. Used only when we sort counters per time.
2014-05-12 11:02:42 -04:00
Ludovic Henry 034494dd99 [decode] Add check for computer endianness on startup 2014-05-12 11:02:41 -04:00
Marek Safar 4fbb65ae05 [http] Convert string output data using BOM header when available. Fixes #19667 2014-05-12 15:24:57 +02:00
Marek Safar 8090e090cb [system.net.http] Fix encoding of Content-MD5. Based on patch by nberardi. Fixes #19644 2014-05-12 13:26:04 +02:00
godFather89 b2a6ea31bd When dynamically compiling script with a class with a nested class defined, the collection would be null.
Example:
class test
{
 class asd
 {
 }
}
2014-05-12 05:29:51 -04:00
Zoltan Varga 068462ab14 [sdb] Fix a deadlock in the assembly cache invalidation code. 2014-05-12 00:47:00 +02:00
Zoltan Varga 8d56fb591f [sdb] Avoid placing implicit sequence points at offsets where the IL stack is empty when using symbol file based sequence points. Fixes #13640. 2014-05-11 23:08:13 +02:00
Zoltan Varga 475f989405 [jit] Add a test for lrem_un. 2014-05-11 21:53:36 +02:00
Zoltan Varga a60a9fe456 [sdb] Fix the serialization of variables with address mode VTADDR. 2014-05-11 21:14:31 +02:00
Miguel de Icaza 6eb9bbd1d7 [build] Untangle the System.Web build, just like System and System.Core 2014-05-09 21:59:49 -04:00
Miguel de Icaza 140040fd65 [build] Drop most uses of LIBRARY_USE_INTERMEDIATE_FILE, clean debug targets 2014-05-09 21:16:52 -04:00
Zoltan Varga 079c2e126f [eglib] Remove test-glib code, we don't have to maintain compatibility with glib any more. Fixes #19638. 2014-05-10 03:07:37 +02:00
Michael Hutchinson 88cf2f1f92 [xbuild] Make tool output parsing more robust
It's now also much more compatible with the subtleties of
the MS .NET parser and includes a substantial test suite.

Fixes BXC19542 - Broken F# Error Reports
2014-05-09 19:59:51 -04:00
Zoltan Varga 04c2e60603 [runtime] Remove an assert from inner_start_thread () on win32 which is not needed. 2014-05-10 01:00:16 +02:00
Miguel Ferreira ea6c2b2267 [Jay] Fix memory corruptions: out-of-bounds and uninitialized value. 2014-05-09 21:33:16 +01:00
Mark Probst b9db795648 [tests] Fix a trivial consistency issue in a test case. 2014-05-09 13:12:26 -07:00
Marek Safar fc061e3296 [xbuild] Implement WriteCodeFragment task 2014-05-09 18:53:12 +02:00
Marek Safar fa5dd111c1 [xbuild] Add ItemDefinitionGroup basic handling 2014-05-09 18:53:12 +02:00
Marek Safar f0ad5f592c [xbuild] Evaluate Choose and PropertyGroup elements in order of appearance 2014-05-09 18:53:12 +02:00
Marek Safar bb4d539b35 [xbuild] Simplify and speedup ConditionFunctionExpression 2014-05-09 18:53:12 +02:00
Miguel de Icaza 9adb22769b [build] Prevent cyclic targets from being built in parallel
Since we are invoking make recursively to satisfy the dependencies
for any of the cyclic components, we need to inform make to not try
to parallelize any work on any of the cyclic dependencies, otherwise
multiple builds will execute building the same binary, and the result
will be truncated outputs.

For example, System's Makefile would launch all the parallel builds for
the dependencies:

        $(secxml_libdir)/System.dll             \
        $(the_libdir_base)System.Xml.dll        \
        $(the_libdir_base)Mono.Security.dll     \
        $(bare_libdir)/System.dll

They could be launched in parallel, and in turn the makefiles on those
directories might try simultaneously to invoke recursively a component
that has not been built yet.

So we use .NOTPARALLEL to flag all the cyclic dependencies on a given
directory to instruct make to not run those in parallel.
2014-05-09 11:27:53 -04:00
Miguel de Icaza 366c13fc51 Drop the extra separator 2014-05-09 11:27:53 -04:00
Miguel de Icaza 8cb819d880 Use LOCAL_MCS_FLAGS to prepend the directories 2014-05-09 11:27:53 -04:00
Miguel de Icaza 7dcf097763 [System.Core] Add explicit cycle dependency tracking to System.Core
This patch is a continuation of the previous work on System to remove
the multi-stage build configuration in Mono's class libraries and avoid
the overwriting of assemblies in a multi-stage build setup.
2014-05-09 11:27:53 -04:00
Miguel de Icaza e0e3f3cd4f [build] Staged setup for building assemblies with cyclic dependencies
This patch introduces an infrastructure to stage the builds for the core
assemblies that have cyclic dependencies.   This deals directly with
the following cycle:

    System.dll requires:
	System.Configuration.dll
	Mono.Security.dll
	System.Xml.dll

	They all require System.dll to be built

    System.Xml requires:
	System.dll
	System.Configuration.dll

    System.Security.dll requires:
	System.dll
	Mono.Security.dll
	System.Xml.dll

Principle
=========

The patch works by directing the build infrastructure to place
intermediate build steps on their own directory.  For example the
first System.dll build that only takes a dependency in mscorlib.dll is
placed not under the final directory but on a subdirectory called
"bare".

The second time that System.dll is built (after Mono.Security and
System.Xml have been built) is placed on the "secxml" directory.

The third time is the final build, and that one ends in the profile
directory.

The same principle is applied to System.Xml.

Better Dependency Tracking
==========================

To handle the multiple stages, the new Makefiles for the various
parties involved in this loop are now able to build their
dependencies.  This means that typing "make" on System.Security or
System.Xml or System will build all of the intermediate steps as
required, without needing the toplevel Makefile to perform multiple
build shots to incrementally build the result.

Bug fixes
=========

We must have regressed at some point the build of System.Xml as we
were only doing one build of it, one without System.Configuration
support.  This patch introduces back the changes to build System.Xml
in two steps.

This patch fixes the setup where we end up rebuilding System.dll and
overwriting it two times as the build progresses as a side effect
(this is what required LIBRARY_USE_INTERMEDIATE_FILE).

Details
=======

library.make:

	Introduces a new "the_libdir_base" which is the raw directory
	where the final output will go.   This points to the same location
	that libdir_base previously pointed to.

	The existing libdir_base is modified to contain an optional
	"intermediate" directory, where intermediate builds can be
	placed.

Other cycles
============

The System.Design assembly was listed as having cycles, but while this
cycle exists in theory, in practice we have not implemented any of the
code that brings the cycle in System.Windows.Forms.Design's
ImageListImageEditor and chances are, we wont any time soon.
2014-05-09 11:27:53 -04:00
Marek Habersack 69a1519d25 Remove last traces of Mono.Web 2014-05-09 16:01:45 +02:00
Zoltan Varga 3f8134d3fd Merge pull request #1028 from DavidKarlas/sdbTypesCaching
[Mono.Debugger.Soft] Caching Assemblies and Types
2014-05-09 14:52:28 +02:00
Atsushi Eno 7df6ef4d03 assign project FullPath before creating ProjectInstance so that properties are assigned appropriately. 2014-05-09 21:51:25 +09:00
Atsushi Eno 120920f90f MSBuildExtensionsPath32/64 should default to MSBuildExtensionsPath value. 2014-05-09 21:51:24 +09:00
Atsushi Eno d3e5522fa3 fix previous change (huh, I was blind, no such option -f, use -p). 2014-05-09 18:09:06 +09:00
Atsushi Eno 085fc8638a use mkdir -f to ignore "directory already exists" error. 2014-05-09 18:04:53 +09:00
Zoltan Varga 0bb0e8a6b8 Merge pull request #1029 from ranma42/dont_free_global_codeman-cleanup
[runtime] Remove the last bits of mono_dont_free_global_codeman
2014-05-09 03:03:40 +02:00
Sebastien Pouliot 37fd3b5e65 [mono-api-html] Add the [Obsolete] message for API additions and removals
Less common case - unless the API difference has a large delta.

Some additional spacing is added to ease readability: if an entry takes two line then it needs a empty line.
2014-05-08 20:18:02 -04:00
Andrea Canciani 07a9e93298 [runtime] Remove the last bits of mono_dont_free_global_codeman
All uses of the mono_dont_free_global_codeman variable (including its
definition) have been removed in
4a1ae4694a.

Its declaration should be removed as well to keep the codebase clean.
2014-05-09 01:25:09 +02:00
Zoltan Varga f9504523d5 [runtime] Wait for the finalizer thread to exit in both code paths where waiting for it succeeded. 2014-05-09 01:00:13 +02:00
Zoltan Varga 07f5a5dc25 Fix make runtest-managed in tests/. 2014-05-09 00:56:35 +02:00
Zoltan Varga ce77f52e00 Fix make check in tests/ 2014-05-09 00:44:09 +02:00
David Karlaš 01876c5c2c [Mono.Debugger.Soft] Catching AssemblyMirror in AppDomainMirror and TypeMirror in AssemblyMirror 2014-05-09 00:41:37 +02:00
Zoltan Varga 4a1ae4694a [runtime] Remove the mono_dont_free_global_codeman hack, it shouldn't be needed now that we actually wait for threads to exit. 2014-05-09 00:36:33 +02:00
Zoltan Varga 17f9fa1afe [jit] Disable the interval based linear scan algorithm in aot+debug mode, since it doesn't respect cfg->disable_reuse_registers, leading to problems during debugging when registers are shared between variables. 2014-05-08 23:03:28 +02:00
Jeffrey Stedfast 3fd97814cd [Mono.Debugger.Soft] Added TypeMirror.IsNested 2014-05-08 16:38:44 -04:00
Ludovic Henry 9da5058dee Merge pull request #1024 from ludovic-henry/pr10-proflog-counters
[proflog] Add counters support to proflog
2014-05-08 16:26:09 -04:00
Ludovic Henry c453aa1469 [proflog] Edit according to Paolo review 2014-05-08 16:21:29 -04:00
Alex Rønne Petersen e20beda857 Update MONO_CPU_ARCH description in man/mono.1. 2014-05-08 20:33:04 +02:00
Marek Habersack fc4874fac3 Merge Mono.Web back into System.Web and remove the Mono.Web module 2014-05-08 20:30:53 +02:00
Jeffrey Stedfast 9fe7e76b3d Merge pull request #1026 from DavidKarlas/cacheThreadInfo
[Mono.Debugger.Soft] Adding caching of ThreadInfo in ThreadMirror
2014-05-08 14:05:46 -04:00
Sebastien Pouliot 9296b4b2d7 [mono-api-html] Refactor to ensure the RegEx (if used) is applied everywhere
* The existing regex was not always used (e.g. new sections);

* It's now possible to use a regex on 'removed' (not just added) elements;

* It's possible to use the same regex for both (or have different ones);
2014-05-08 13:31:27 -04:00
Ludovic Henry e1397e1776 [counters] Fix operator precedence 2014-05-08 11:29:01 -04:00
Ludovic Henry d8a2ed3f1b [counters] Edit dump_counter to use mono_counters_sample and accessors 2014-05-08 11:26:59 -04:00
Zoltan Varga 664ff2167e [gsharedvt] Add tests for large structs. 2014-05-08 17:10:38 +02:00
Rolf Bjarne Kvinge 62deaefea1 Initialize out parameters to NULL.
Fixes a crash in the debugger, where we were freeing random pointers:

(lldb)
frame #2: 0x000dc981 monotouchtest`method_commands_internal(command=<unavailable>, method=<unavailable>, domain=<unavailable>, p=0x7f52aca4, end=<unavailable>, buf=<unavailable>) + 9009 at debugger-agent.c:8116
   8113			g_free (il_offsets);
   8114			g_free (line_numbers);
   8115			g_free (column_numbers);
-> 8116			g_free (end_line_numbers);
   8117			g_free (end_column_numbers);
   8118			g_free (source_files);
   8119			g_ptr_array_free (source_file_list, TRUE);
2014-05-08 17:01:27 +02:00
David Karlaš 8a536f371f [Mono.Debugger.Soft] Adding caching of ThreadInfo in ThreadMirror 2014-05-08 10:51:40 +02:00
Marek Safar fc5f457120 [corlib] Use invariant culture for GetTempFileName generator 2014-05-08 10:26:29 +02:00
Marek Safar 4631b47277 [xbuild] Don't crash when reporting top level unknown elements 2014-05-08 10:26:29 +02:00
Sebastien Pouliot 7fefa95e63 [System.Core] Fix MOBILE-implementation of MemoryMappedFile
Internal API was updated only for the non-MOBILE part. Public/shared API requires them in sync.
2014-05-07 19:33:45 -04:00
Ludovic Henry 3cc9e4968e [counters] Fix -1 array access in case counter is of type string and value is null 2014-05-07 18:40:11 -04:00
Rodrigo Kumpera c941e03b0a [counters] Improve the documentation of the counters API. 2014-05-07 17:55:54 -04:00
Rodrigo Kumpera 51e760f771 [counters] Fix the build and do some error handling. 2014-05-07 17:55:20 -04:00
Rodrigo Kumpera 0e3b816a04 Merge pull request #1022 from ludovic-henry/pr9-string-counters
[counters] Add support for string values
2014-05-07 17:40:10 -04:00
Ludovic Henry 8accb3121e [counters] Fix potential overflow in string sampling 2014-05-07 17:34:11 -04:00
Sebastien Pouliot 0cd8e6b022 [mono-api-html] Prettier output when dealing with arrays ([] or [][]), nullable (?) and pointers (*). 2014-05-07 17:25:04 -04:00
Ludovic Henry 8a7181b6c1 [counters] Edit get process pid and /proc/loadavg according to Paolo review 2014-05-07 17:06:20 -04:00
Ludovic Henry ce7dfe8479 [proflog] Increment LOG_DATA_VERSION 2014-05-07 16:59:34 -04:00
Ludovic Henry 0c7e37856d [proflog] Add integration of counters_init and counters_sample
counters_init is called at the end of runtime initialization, on runtime_initialized hook
counters_sample is called in the helper_thread at least once per second
2014-05-07 16:55:00 -04:00
Ludovic Henry 9ccb2fdeb7 [proflog] Add counters_init and counters_sample functions 2014-05-07 16:54:33 -04:00
Ludovic Henry 739eb1b3cb [proflog] Add counters enum type and documentation 2014-05-07 16:29:19 -04:00
Ludovic Henry 2c947ab445 [proflog] Add counters option parsing 2014-05-07 16:28:02 -04:00
Ludovic Henry 3a1ebe87ae [proflog] Add emit_string and emit_double functions 2014-05-07 16:18:40 -04:00
Marek Safar cad2f3ac42 Merge pull request #1023 from LogosBible/NetworkStreamBeginWriteInnerException
Include inner exception when BeginWrite fails due to exception from Sock...
2014-05-07 19:10:27 +02:00
Ludovic Henry b430745186 [counters] Add support for string values
Add new function mono_counters_register_with_size which let the counters API now what is going to be the max size of the string.
The type of the value passed when MONO_COUNTER_STRING is passed must be char* (instead of char** previously). This is to guarantee that, if we want to change the value of the counter, we do not reallocate and free the old value, but we change the value in place. Thus to avoir race condition and access to freed memory.
2014-05-07 13:03:46 -04:00
Tom Philpot 323255c174 Include inner exception when BeginWrite fails due to exception from Socket.BeginSend. 2014-05-07 09:48:31 -07:00
Marek Safar 8d02439588 Undo project change from 073fe7a39c which should not be included 2014-05-07 17:01:37 +02:00
Alex Rønne Petersen 7848571e6f Fix the check in 4660f44381 for special files. 2014-05-07 16:57:12 +02:00
Marek Safar 073fe7a39c [mcs] Fix completion for `new {' input 2014-05-07 16:51:08 +02:00
Marek Safar 8ada649a15 [mcs] Don't report interface implementation errors for optional implementations. Fixes #18030 2014-05-07 15:10:37 +02:00
Zoltan Varga 1e4e2bd449 Fix the build. 2014-05-07 14:50:29 +02:00
Marek Safar 4660f44381 [system.core] Fix some MemoryMappedFile argument checks 2014-05-07 14:19:57 +02:00
Zoltan Varga 4044cb7c07 [sdb] Add end lines/end columns to line number information. 2014-05-07 14:02:28 +02:00
Zoltan Varga 97dc571fe2 Add end line/end column information to the mdb file format and pdb2mdb. 2014-05-07 14:02:28 +02:00
Marek Safar b787868fa8 [corlib] Rethrow user not initialization exception when lazy initialization throws. Fixes #19564 2014-05-07 13:13:08 +02:00
Rodrigo Kumpera fd27e16386 Fix copyright. 2014-05-06 23:11:25 -04:00
Sebastien Pouliot 6bdf1e274e [mono-api-html] Allow a lax processing mode of the XML files
This is useful when the files needs to be pre-processed (e.g. a major change between the assemblies internals) and where some duplicate entries might be created (e.g. merged types/namespaces).

Note: normally the mono-api* tools should not produce such files (so it's better not used unless required)
2014-05-06 20:20:25 -04:00
Sebastien Pouliot 05876475d1 [mono-api-html] Prettier output using singular and plural forms in sections 2014-05-06 20:20:25 -04:00
Ludovic Henry da2e4c791d [counters] Add system counters
After discussion with Kumpera, it was decided to load them lazily when calling mono_counters_foreach for the first time. It has to be inside the mono runtime, and not in a profiler because it accesses proclib API which is all MONO_INTERNAL functions.
2014-05-06 20:09:42 -04:00
Rodrigo Kumpera d8dc2fb2fa [counters] Fix --stat to not dump counters for all sections. 2014-05-06 17:26:39 -04:00
Miguel de Icaza 41858f8b42 Merge pull request #1018 from ermshiperete/xamarin-19567
[MWF] Clear currentCell before disposing (fixes #19567)
2014-05-06 17:24:51 -04:00
Rodrigo Kumpera 5ae3f41410 [sgen-bridge] Add color duplication pathology. 2014-05-06 15:39:29 -04:00
Rodrigo Kumpera a89e635840 [sgen] Improve bridge comparison code a bit. 2014-05-06 15:39:29 -04:00
Rodrigo Kumpera 2e088c49d3 [sgen-bridge] Add the tarjan-coloring bridge.
The tarjan-coloring bridge is significant departure from the old bridge. It's design is based
on the Tarjan Strongly Connected Component algorithm.

SCC links are calculated as part of the Tarjan dfs on the second scan to calculate the low index and
form the components.

The algorithm does inspect all children after they have been processed, which enables us to do backward
propagation of the reachable SCCs.

In order to avoid the xref mess of the old algorithm, we color each component based on the sum of all
reachable components (colors). This means no matter how many non-bridge objects are in between two bridges,
they will all receive the same color and be represented in the final output as a single node in the SCC
graph.

This allows for a reasonably compact output graph as it will only include colors with no bridges when
a single object has multiple bridges reachable.

Said that, the basic algorithm received a series of optimizations:

1)Flag based merging, great idea from Mark, it bounds color and xref merging to be linear on the number of
colors found.

2)Objects and Colors bucket allocation. Instead of using expansible arrays we use fixed size buckets that
form a linked list. This allow us to use direct pointers instead of indexes. It avoid the expensive expansions.
Another benefit is that it reduces the work by sgen's malloc, which can be really slow.

3)Replace the object hash table with header patching. We tag objects with both pinning and forwarded bits and
store a pointer in the lock word. This eliminates the hashtable, a big source of perf issues. Patching objects
back at the end of bridge processing is much much cheaper than free'ing all the hashtable entries.

4)Color deduplication. It's possible to produce duplicated colors due to mutually unreachable paths that
both points to the same set of bridges. A cache is introduced to reduce it for colors points to 2 or 3 others.

The way we build colors allow us in the future to fix the hub object problem (SetupDoubleFan).

Experimental results with sgen-bridge-pathologies shows this implementation been 2-3x faster than the new one.
2014-05-06 15:39:29 -04:00
Rodrigo Kumpera f41a9ecabf [bridge] change the log entry name to make it easier to read logs. 2014-05-06 15:39:28 -04:00
Rodrigo Kumpera 7623a52cdc [sgen-bridge] Each bridge needs it own internal mem type as their sizes differ. 2014-05-06 15:39:28 -04:00
Miguel de Icaza 4d1a5dd977 Merge pull request #1010 from davidmoore1/bug-19304
Prevent call to OwnerLostFocusHandler for disposed object
2014-05-06 14:19:43 -04:00
Marek Safar 686ee099af [mcs] Include more unicode categories in parsing identifier part character. Fixes #18229 2014-05-06 19:59:36 +02:00
Eberhard Beilharz 3505e01e30 [MWF] Clear currentCell before disposing (fixes #19567)
If currentCell still has a value when we call Columns.Clear() we
might try to end the editing. Because the columns got disposed
before calling Columns.Clear() we get a crash. This patch fixes
the problem by setting currentCell to null.
2014-05-06 19:09:29 +02:00
Eberhard Beilharz 414ce39e1d [MWF] Unit test for DataGridView bug (#19567) 2014-05-06 19:06:50 +02:00
Rodrigo Kumpera 46cccd7feb Merge pull request #992 from ludovic-henry/ludovic-counters-pr1
[counters] Add sample and accessors to mono counters API
2014-05-06 12:34:42 -04:00
Marek Safar 549c4df9c5 [mcs] Emit null constant value for default parameters of generic types to indicate not missing value. Fixes #19033 2014-05-06 17:56:50 +02:00
Marek Safar 7e389f425d [mcs] Report error for invalid unary nullable predefined operators 2014-05-06 17:19:15 +02:00
Marek Safar 1ef93c5318 [mcs] Do type parameter conversion involving type parameters using dependency rules. Fixes #18473 2014-05-06 16:52:24 +02:00
Marek Safar 48742484f7 Merge pull request #1017 from akoeplinger/fix-monocc
[Mono.CodeContracts] Always build debug file for the test assembly
2014-05-06 15:39:23 +02:00
Alexander Köplinger 520091343a [Mono.CodeContracts] Always build debug file for the test assembly
The tests require that the debug file is available, however in the net_4_0 profile this file isn't generated by default.
We now ensure the debug file is always generated for the test assembly.
2014-05-06 15:37:16 +02:00
Sebastien Pouliot c15721382c [mono-api-html] Prettier output of ref and out (instead of &) 2014-05-06 08:55:50 -04:00
Sebastien Pouliot d3b101db33 [mono-api-html] Make the [Obsolete] a bit prettier when no text message is available 2014-05-06 08:54:56 -04:00
Zoltan Varga 934b12770a [sdb] Add a new TypeMirror.NewInstance () method which can create valuetypes without a ctor. 2014-05-05 23:39:46 +02:00
Jeffrey Stedfast c049f307f1 [Mono.Debugger.Soft] Modified TypeMirror.NewInstance() to check that the method is a .ctor 2014-05-05 17:20:07 -04:00
Sebastien Pouliot d9aaa0985f [mono-api-html] Report [Obsolete] members in a separate section (not as both removed and added with an [Obsolete]). That makes it easier to read long API diff reports 2014-05-05 16:17:54 -04:00
Ludovic Henry d70ae3f463 [counters] Disable register filter on valid_mask
This was previously used to not store counters that were not going to be dumped, but because we can now sample them, we have to make sure that they are stored, even if we do not plan to dump or sample them.
2014-05-05 14:10:48 -04:00
Marek Safar 0137058a18 [dlr] Emit correct code for convert of nullable types. Fixes #19500 2014-05-05 19:16:11 +02:00
Ludovic Henry 8da4b9b1b4 [counters] Fix type issue on mini counters
Used MONO_COUNTER_WORD for gint32 variable, crashed on 64bits platform.
2014-05-05 12:23:20 -04:00
Ludovic Henry fe6bc0068b [counters] Use macro to copy counter in sampling, and use sizeof directly instead of mono_counter_get_size
The use of sizeof will enable compilers optimization on memcpy.
2014-05-05 12:20:59 -04:00
Marek Safar dba4ec7936 [mcs] Emit all method like members in same order as they appear in source code. Fixes #19509 2014-05-05 17:53:26 +02:00
Tom Philpot dbee33d41c Add tests for AppSettingsSection. 2014-05-05 08:18:02 -07:00
Ludovic Henry 84fb018c7e [counters] Sample should fail if buffer size is too small 2014-05-05 10:47:23 -04:00
Ludovic Henry 5b538b8c30 [counters] Add sample and accessors functions 2014-05-05 10:47:23 -04:00
Marek Safar 34241c020f [mcs] Convert extended underlying enum constants to their underlying type. Fixes #18866 2014-05-05 14:57:57 +02:00
Miguel de Icaza d518bd927a [corlib] Remove stale comments 2014-05-04 17:34:12 -04:00
Miguel de Icaza 3d04a49a2c System: Fix the previous bulid 2014-05-04 17:33:51 -04:00
Miguel de Icaza 705da187cf [System] Fix build warnings 2014-05-04 17:15:18 -04:00
Zoltan Varga 47db8f756f [jit] Register the Mono_UnhandledException_internal icall when TARGET_ANDROID is set. 2014-05-03 21:50:52 +02:00
Zoltan Varga 9c4f0a3bea [runtime] Fix some automake conditionals in scripts/, they should be in the beginning of the line. 2014-05-03 19:29:42 +02:00
Zoltan Varga b55efe4e71 [runtime] Fix a warning which happens because we store the thread tid as a guint64. 2014-05-03 18:47:35 +02:00
Tom Philpot 8553af0d71 Use the configuration file path directory as the working directory for the file attribute of the appSettings section instead of the current working directory. 2014-05-03 06:42:00 -07:00
Mark Probst ad626249b9 [sgen-bridge] Don't forward a node to itself. 2014-05-02 14:02:57 -07:00
Mark Probst 9f7bc87b6b [sgen-bridge] Compare xrefs between bridge implementations, too. 2014-05-02 14:02:57 -07:00
Mark Probst 0aba200f1f [sgen-bridge] Compare SCCs between bridge implementations. 2014-05-02 14:02:57 -07:00
Mark Probst c6a3beb160 [sgen-bridge] Allow second bridge implementation to run alongside the active one. 2014-05-02 14:02:57 -07:00
Mark Probst ee61a6e168 [sgen-bridge] Small refactoring. 2014-05-02 14:02:56 -07:00
Mark Probst a852c7a94b [sgen-bridge] Move bridge debug option handling to sgen-bridge.c. 2014-05-02 14:02:56 -07:00
Mark Probst 68b306dcb2 [sgen-bridge] Set bridge_processing_in_progress in sgen-bridge.c. 2014-05-02 14:02:56 -07:00
Mark Probst a8a03927be [sgen-bridge] Also separate old bridge into pre- and post-callback. 2014-05-02 14:02:56 -07:00
Mark Probst a697fec8db [sgen-bridge] Move processing of API data structures to sgen-bridge.c, for sgen-new-bridge.c. 2014-05-02 14:02:55 -07:00
Mark Probst eeaba286c3 [sgen-bridge] Separate before- and after-callback in new bridge. 2014-05-02 14:02:55 -07:00
Mark Probst a92f9ab4c1 [sgen-bridge] Special-case ptr array for 1 entry without allocating. 2014-05-02 14:02:55 -07:00
Mark Probst c236dcd475 [sgen-bridge] Use bit field for is_visited and finishing_time. 2014-05-02 14:02:54 -07:00
Mark Probst e3dfcd2918 [sgen-bridge] Make finishing_time a 32 bit unsigned int. 2014-05-02 14:02:54 -07:00
Mark Probst 362674f49b [sgen-bridge] Fix forwarding.
We can't forward to HashEntry's because they are volatile - the
hash table will resize, and the entries move.  We need to point to
the objects, and then look them up via the hash.  Also, we have
to forward chains of forwards.
2014-05-02 14:02:54 -07:00
Mark Probst e225acdd52 [sgen-bridge] Remove redundant object pointer in hash table entry. 2014-05-02 14:02:54 -07:00
Mark Probst c8fb0ce1e5 [sgen-bridge] Separate DFS1 and DFS2 fields in HashEntry. 2014-05-02 14:02:53 -07:00
Mark Probst 996405bee5 [sgen-bridge] Add a new bridge (non-)pathology. 2014-05-02 14:02:53 -07:00
Mark Probst 9714ba95a9 [sgen-bridge] object_is_live() should be called object_needs_expansion(). 2014-05-02 14:02:53 -07:00
Mark Probst 69a6d8f3f3 [sgen-bridge] Debugging option to dump whole bridge object graph. 2014-05-02 14:02:53 -07:00
Mark Probst 5238cc8fc7 [sgen-bridge] Remove single-reference non-bridge objects from graph. 2014-05-02 14:02:52 -07:00
Mark Probst 0c7470aefc [sgen-bridge] Added test case with bridge performance pathologies.
This is not meant as part of the test suite, but as a reference for
where the bridge has performance issues.
2014-05-02 14:02:52 -07:00
Mark Probst 83eee1ecd7 [sgen-bridge] Copy-on-write for DynArrays.
This eliminates a pathological case for the old algorithm, where a
large array of SCCs is copied from one node to the next without
modification.
2014-05-02 14:02:52 -07:00
Mark Probst 56a2887d69 [sgen-bridge] Remove dead DynArray merging code. 2014-05-02 14:02:52 -07:00
Mark Probst 1cbc22a12b [sgen] Heavy hash table statistics. 2014-05-02 14:02:51 -07:00
Mark Probst ca8c0f110b [sgen-bridge] Make merging in old xrefs algorithm much more efficient.
Instead of merging the two lists by keeping them sorted, use the flag on
the SCCs the indicate whether an SCC has already been merged in, and
just append it if not.  This makes it as fast as the new algorithm on one
test case where it was pathologically slow, while not exhibiting another
pathology that the new algorithm has.
2014-05-02 14:02:51 -07:00
Mark Probst da71185b3a [sgen-bridge] New xrefs graph optimization for nodes with incoming order 1. 2014-05-02 14:02:51 -07:00
Mark Probst 1cedf05d43 [sgen-bridge] Don't merge xrefs in DFS2. Speeds up some cases by orders of magnitude. 2014-05-02 14:02:51 -07:00
Neale Ferguson 0b078d3e36 Support the datetime2 parameter type 2014-05-02 16:39:24 -04:00
Jeffrey Stedfast d8ab5a6b6b [Mono.Debugger.Soft] Fixed the ILInterpreter to catch ArgumentExceptions from ObjectMirror.GetValue() 2014-05-02 12:52:09 -04:00
Jeffrey Stedfast 0acac62678 [Mono.Debugger.Soft] Make the ObjectMirror.GetValues() exception a bit more useful 2014-05-02 12:51:24 -04:00
Marek Safar 31da1c8b2f [mcs] Don't apply reference type is optimization for dynamic expressions. Fixes #19423 2014-05-02 18:02:29 +02:00
Rodrigo Kumpera 6baafcebca Merge pull request #1013 from ranma42/fix-19380
Fix 19380
2014-05-02 11:45:53 -04:00
Marek Safar 688dc29cf1 [mcs] Inflate anonymymous method with correct type arguments when async this requires hoisting in parent type. Fixes #19176 2014-05-02 15:32:10 +02:00
Marek Safar 1e17a61f72 [mcs] Fix using type relationship check for type parameters. Fixes #18639 2014-05-02 10:12:59 +02:00
Andrea Canciani 29f0d0fa91 Document MONO_PATH behaviour for relative paths
Tha previous behaviour of MONO_PATH for relative paths (that implied
using the paths as relative to the current directory when loading
assemblies) was not yet documented and led to some failures when
executing tests.

In order to fix the failures, a new behaviour has been introduced:
relative paths are resolved at launch time, so that the folders which
are examined when loading assemblies do not depend on the current path
of the program.

This patchset is released under the MIT license.
2014-05-01 21:42:09 +02:00
Andrea Canciani 75ae368e7e Canonicalize folders when setting up assemblies_path
When MONO_PATH contains relative folders, they are meant as relative
from where the application is launched, not from the current directory
of each assembly load.

Fixes #19380.
2014-05-01 21:41:44 +02:00
Alex Rønne Petersen bdd4d5bec5 Put the "degraded allocation" warning behind a log level.
We generally shouldn't print stuff to stdout/stderr unless we're
about to fatally crash or something.
2014-05-01 17:25:07 +02:00
Andrea Canciani 53899e397a Fix minor memleak
Instead of just dropping empty strings from the assemblies_path array,
they should be freed to avoid leaking them.
2014-05-01 13:00:47 +02:00
Marek Safar e1d0655aa3 Disable failing test on partical day only 2014-04-30 17:56:19 +02:00
Rodrigo Kumpera de7bffa0be Revert "wip". This idiot here pushed a working branch.
This reverts commit 1bcf96fae0.
2014-04-30 11:37:23 -04:00
Rodrigo Kumpera 196bc4bfcc Revert "might be working" Stupid me pushed a working branch. Glad it had no swearing.
This reverts commit a9d74622fd.
2014-04-30 11:36:58 -04:00
Rodrigo Kumpera 92aeb68b3b [runtime] Fix use before null-check crasher. Found by PVS Studio. 2014-04-30 11:33:43 -04:00
Rodrigo Kumpera a9d74622fd might be working 2014-04-30 11:26:29 -04:00
Rodrigo Kumpera 1bcf96fae0 wip 2014-04-30 11:26:28 -04:00
Marek Safar 93f44693ce [mcs] Better fix for 0d11522afe to consider full member accesibility 2014-04-30 16:16:02 +02:00
Miguel de Icaza 2bd0a1fb21 Updated HTML reference test output 2014-04-30 10:07:20 -04:00
Marek Safar b2b76edc29 [mcs] Caching of type argument types should not happen under error conditions. Fixes #18282 2014-04-30 15:32:09 +02:00
Marek Safar c8ec5331fc Merge pull request #966 from ermshiperete/bug-xamarin-18511
[mcs] Fix recursive resolving of crefs (#18511)
2014-04-30 12:06:54 +02:00
Marek Safar f1790decb8 [linq] Use hashtable lookup instead of linear scan for groupby keys. Fixes #18673 2014-04-30 11:55:17 +02:00
Marek Safar 47f76bb61e Merge pull request #1011 from Fabian-Koenig/master
[DbDataReader] Implement GetFieldValue<T> function to make mono working with EntityFramework 6.x
2014-04-30 08:23:39 +02:00
Alex Rønne Petersen dc16bfe2fe Backport some changes from nunit/nunitv2 that hopefully fix some test agent hangs. 2014-04-30 00:02:52 +02:00
Alex Rønne Petersen 9954763927 Add .gitignore file in mono/arch/arm64. 2014-04-30 00:02:52 +02:00
Alex Rønne Petersen a860232c6e Add a check target to mcs/errors/Makefile. 2014-04-30 00:02:52 +02:00
Fabian König bc69c64bea [DbDataReader] Implement GetFieldValue<T> function to make mono working with EntityFramework 6.x 2014-04-29 23:35:12 +02:00
Miguel de Icaza 626b3929bd Small touchups to the UI, remove some extra space, use a bold, large font for the text 2014-04-29 17:31:26 -04:00
Michael Hutchinson 8989a87902 Merge pull request #1008 from lambdalice/master
[xbuild] Add GetAssemblyIdentity task to Microsoft.Common.tasks
2014-04-29 17:14:43 -04:00
Marek Safar 0d11522afe [mcs] Private member can still have base members when in nested types. Fixes #19378 2014-04-29 19:52:47 +02:00
Paolo Molaro d4a3cc50d3 Adjust the test check to look for the correct heapshot number in the profile data. 2014-04-29 18:48:57 +02:00
Marek Safar 491da5c899 [mcs] Make unused event warning reporting consistent to csc. Fixes #19095 2014-04-29 18:44:54 +02:00
Paolo Molaro 1dbd5e22fa Fix regression in thread name reporting in the profiler.
metadata/threads.c: fix regression from the 695b17f8d5 change and
avoid useless memory allocation. Report thread name to the profiler at
thread startup if it was set before that.
profiler/decode.c: fix typo.
profiler/proflog.c: ensure we get a consistent first buffer header at runtime
initialization.
2014-04-29 17:25:16 +02:00
Paolo Molaro aa181455bb Make assembly resolve events more compatible with the MS runtime.
We now try and trigger assembly resolve events for referenced assemblies
in a way that is more compatible with the MS runtime behaviour. If that still
fails we continue falling back and looking in the same directory as the referencing
image as before to keep compatibility with code that relies on the previous mono
behaviour.
The assemblyresolve_event3.cs test that used to fail on the MS runtime has been fixed
so it works now with both engines.
2014-04-29 15:00:46 +02:00
Marek Safar 9845ce1ea5 [mcs] Add parent storey reference only when this is not captured directly. Fixes #19077 2014-04-29 13:24:35 +02:00
David Moore a32e725b0c Prevent call to OwnerLostFocusHandler for disposed object
bugzilla.xamarin.com bug reference: Bug 19304
ComboBox reverts to original selection when it loses focus.
The LostFocus handler for the internal ComboTextBox class
was being called after it had been disposed.  The dispose
was correctly called when the ComboBoxStyle changed from
it's initial default value to DropDownList.  However, when
the ComboBox control lost focus later on, the LostFocus event handler
was called, which resulted in the Text value for the ComboBox
being overwritten by the value in the disposed object.

Could not see how to write a unit test within the ComboBoxTest.cs
that would simulate losing focus so only providing fix.

Change-Id: I9ca4cc75da5711a7d7c1dd166d5f52d580f44df1
2014-04-29 01:52:36 -04:00
Alexis Christoforides ea464418b5 Merge pull request #920 2014-04-28 18:51:41 -04:00
Miguel de Icaza 1b936ba7e3 Merge pull request #1009 from joelmartinez/msdoc-import
[docs] monodoc style update for blockquote attribution.
2014-04-28 17:55:02 -04:00
Joel Martinez 9d463c4b29 [docs] monodoc style update for blockquote attribution.
Handles the case for method lists, which are contained in blockquotes.
2014-04-28 17:27:32 -04:00
Alexis Christoforides 2d9b230c73 Merge pull request #971
+ trivial adjustments on test timers to prevent intermittent failures.
2014-04-28 17:13:42 -04:00
Alexis Christoforides 4c2a8ed3dd Extended test time for timer-sensitive tests. 2014-04-28 16:52:25 -04:00
Rodrigo Kumpera d5d49b2d59 Drop Events and Items units in favor of Count as they represent pretty much the same thing. 2014-04-28 16:35:22 -04:00
Rodrigo Kumpera 71642b547b [counters] Only dump monotonic counters as variable ones are meaningless during shutdown. 2014-04-28 16:35:22 -04:00
Rodrigo Kumpera 0f66803aaf [counters] Restore the previous behavior of mono_counters_dump, add variance filtering and reorg the bitfield.
The previous behavior when using mono_counters_dump was to pass -1 as the section and get all
counters dumped. This commit restore this behavior.

In addition to that, we want to enable callers to filter by variance as non monotonic counters are not useful
to be dumped at shutdown. To do so you just OR the variance with the sections you want. So what the runtime wants is:

	mono_counters_dump (MONO_COUNTER_SECTION_MASK | MONO_COUNTER_MONOTONIC, stdout);

Dump all counters that are monotonic. Perfect.

Finally, to make the above neat, a reorg of the type bitfield was needed. Variance is now using a bit per kind.
Variance and unit where shrunk to 4 bits each, to open space for more sections.
2014-04-28 16:35:21 -04:00
Rodrigo Kumpera 607c882c43 [counters] Document mono_counters_foreach. 2014-04-28 16:35:21 -04:00
Rodrigo Kumpera 2c31356e6c [counters] Install mono-counters.h since it's part of the public API. 2014-04-28 16:35:21 -04:00
Rodrigo Kumpera a31f1b33a9 [mono-counters] Bring MONO_COUNTER_TIME_INTERVAL back. 2014-04-28 16:35:21 -04:00
Rodrigo Kumpera 401c2f1828 Revert "[counters] Simplify things a bit by removing unsigned counter types."
This reverts commit 2fa83d9a8c.
2014-04-28 16:35:20 -04:00
Miguel de Icaza f34f996a11 genproj: add support for Alias in project references 2014-04-28 15:16:07 -04:00
Miguel de Icaza f57daf91e1 [genproj] For Path.GetFullPath to work, we must use convert Windows paths to Unix paths 2014-04-28 15:16:07 -04:00
Alexis Christoforides 2d2d90eeb2 Merge pull request #961 from ermshiperete/bug-xamarin-18118
[System.XML] XSL bugfixes for #18118 #18114 #18113
2014-04-28 14:16:46 -04:00
Alexander Köplinger 3f6a2ee3b7 [Mono.Parallel] Removed broken Mono.Threading.Tasks code
The code in MonoTaskExtensions.cs relied on the internal method Execute(Action<Task>) in System.Threading.Tasks.Task which was removed in 0a66e60.
2014-04-28 18:17:22 +02:00
Alex Rønne Petersen 7b48e454d7 Emit profiler enter/leave instrumentation calls as icalls.
This is more portable than using the mono_arch_instrument_* functions and
thus isn't prone to nasty arch-specific bugs. In particular, the old way
of instrumenting function prologues/epilogues resulted in a somewhat elusive
stack corruption bug on Android (ARM). Eventually, we should get rid of these
functions entirely and only use icalls, with JIT opcodes for special cases
(such as saving arguments for --trace).

This new way of doing things also makes profiler instrumentation AOT-safe,
since we're now going through the proper channels to emit references to the
runtime functions (mono_profiler_method_enter/leave) and to embed MonoMethod
pointers.

Since we're using icalls without wrappers to do this, there should be no
visible performance impact from this commit.
2014-04-28 16:52:58 +02:00
Eberhard Beilharz 7e69ca21ce [MWF] Fix AutoSize behavior of FlowLayoutPanel (#2912)
A FlowLayoutPanel that has AutoSize set needs to resize if the
contained controls wrap.
2014-04-28 16:22:10 +02:00
Eberhard Beilharz 96b68424a4 [MWF] Add unit tests for AutoSize behavior of FlowLayoutPanel 2014-04-28 16:20:17 +02:00
Alice a5e7519b33 [xbuild] Add GetAssemblyIdentity task to Microsoft.Common.tasks 2014-04-28 22:45:50 +09:00
Marek Safar 038456fe38 Merge pull request #1005 from ranma42/race-free-parallel-build
Use mktemp instead of $RANDOM to generate unique names
2014-04-28 09:21:50 +02:00
Miguel de Icaza e84755ae4c Merge pull request #1006 from joelmartinez/msdoc-import
Import of Microsoft BCL Documentation
2014-04-27 23:08:02 -04:00
Joel Martinez a341c136e6 [docs] Minor update to monodoc html template.
Handles the case where a bullet list has only a paragraph rather than a term
2014-04-27 22:37:25 -04:00
Joel Martinez 6999270099 [docs] Import of Microsoft BCL Documentation.
The documentation is creative commons licensed.
2014-04-27 21:33:01 -04:00
Joel Martinez 7c67e309d8 [docs] Schema additions, and monodoc template updates.
- Expanded monodoc-ecma schema to support the 'preserve-mono' attribute, and the attribution tag.
- Added preserve-mono to several pieces of documentation that we would like to preserve across future automated documentation imports: CipherSuitesCallback, ServicePointManager, CultureInfo, Environment+SpecialFolder.xml
- XSL template changes for monodoc HTML generation to support <attribution>
2014-04-27 21:32:54 -04:00
Zoltan Varga f244461065 [arm] Fix some native types issues. 2014-04-26 12:44:32 +02:00
Marek Habersack 34fb07d05f Include support for SSL/TLS right in System when building for the MONODROID profile
This patch builds upon commit 96a8500795 which placed parts of Mono.Security
responsible for dealing with SSL/TLS certificates for the purpose of certificate verification. The code enables
validation of the certifcates even if the user does not provide their own validation callback. The changes as related to
the original commit are few, basically consisting of enabling the same code used by MonoTouch in the MonoDroid context with
the only actual code change being the certificate validation bit mentioned above.

Since the change involves adding a subset of Mono.Security files to the monodroid version of System.dll, it is
also necessary to remove Mono.Android's dependence on Mono.Security.dll. The reason is that the code in AndroidPlatform
which looks up TLS support methods in Mono.Android.dll would use a type (X509CertificateCollection) that is now part of
System.dll but is *also* in Mono.Security.dll referenced by Mono.Android.dll and therefore the lookup would fail since
we'd have two distinct types from the reflection point of view.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=18962
2014-04-25 21:39:53 +02:00
Rodrigo Kumpera f964245f21 [sgen-bridge] Fix the bridge with forwarded objects. 2014-04-25 14:49:16 -04:00
Marek Safar b3c6f228b3 [corlib] Fix extra await context switch when custom SynchronizationContext does not change. Fixes #17878 2014-04-25 18:03:43 +02:00
Rolf Bjarne Kvinge 19f49f93f9 Revert "Revert "Merge branch 'master' of https://github.com/mono/mono""
This reverts commit 8f09dad435.

8f09dad435 is reverting a merge commit,
which will not do what you think it does. It will revert much more,
so revert the revert to get back the unintentionally reverted commits.

It looks like the next commit (1a15d4ec54)
is doing the original intention (reverting 164f9cbec4),
so this revert will leave the tree in a good state, with no pending
reverts.
2014-04-25 16:57:01 +02:00
Rolf Bjarne Kvinge f37e86ff58 [mono-api-html] Print string fields with no (or null) value without an NRE. 2014-04-25 16:01:39 +02:00
Alex Rønne Petersen 436328d91d Merge pull request #916 from akoeplinger/fix-gac-test
[MSBuild] Fixed a test that failed when the GAC wasn't available
2014-04-25 12:29:43 +02:00
Rodrigo Kumpera 242cc0df76 [sgen-bridge] Implement type based dfs1 filtering.
Some types are statically known to never lead to a bridge. Objects like
string or int[]. By filtering them out very early in dfs1 we save memory by
not inserting them into the hashtable and reduce work done by all further steps.
2014-04-24 19:09:31 -04:00
Rodrigo Kumpera ee99d7e569 [sgen-bridge] Fix counters. They were not zeroed after each collection. 2014-04-24 19:09:31 -04:00
Rodrigo Kumpera 57829a6492 [sgen-bridge] Use an extra vtable bit to flag opaque objects. 2014-04-24 19:09:30 -04:00
Rodrigo Kumpera d7b60ebe61 [runtime] Fix bitfield comments. 2014-04-24 19:09:30 -04:00
Joao Matos 26ec7f63a0 Revert "Added our own slightly modified copy of Ionic.Zip library."
This is currently breaking the build for Mono Droid.

This reverts commit bb3f24e999.
2014-04-24 14:49:00 +01:00
Joao Matos dc79b5bff7 Revert "Added System.IO.Compression implementation."
This is currently breaking the build for Mono Droid.

This reverts commit b175675ad9.
2014-04-24 14:48:57 +01:00
Rolf Bjarne Kvinge 924c113d86 [System.Xml] Use profile-specific file names for generated files.
Otherwise parallel builds will break randomly.
2014-04-24 13:21:47 +02:00
Alex Rønne Petersen fea1cd4278 Merge pull request #1002 from ranma42/make-check-no-install
Fix 'make check' when mono is not installed
2014-04-24 12:08:02 +02:00
Marek Safar 994661d0b9 Merge pull request #1003 from robertpi/Bug12211
Allow .NET 4.0 + users to use the ConnectSocket property
2014-04-24 11:28:31 +02:00
Robert Pickering fb2f5e0a2f Allow .NET 4.0 + users to use the ConnectSocket property 2014-04-24 07:34:27 +02:00
Atsushi Eno 3e6f644393 Fix bug #9541 by Bart Verthé - do not reset document schema when reading an element. 2014-04-24 12:26:01 +09:00
Rodrigo Kumpera ff938b5960 [sgen-bridge] Add the new bridge to the testing matrix. 2014-04-23 20:10:23 -04:00
Rodrigo Kumpera 7767167ecc [sgen-bridge] New bridge implementation - currently is just a copy of the old one.
The bridge implementation can be picked by having bridge-implementation=old|new in
MONO_GC_PARAMS.

This commit just prepared the ground to land experimental improvements to the bridge
while retaining an working implementation by default.
2014-04-23 20:10:22 -04:00
Rodrigo Kumpera 83341e8416 [sgen-bridge] Move the bridge implementation behind a pointer table.
This change is in preparation to introduce two implementations of the bridge.

The current implementation is now know as old.
2014-04-23 20:10:16 -04:00
Mark Probst aed957b65e [sgen] Fix time logging. We inflated durations by a factor of 10.
SGEN_TV_GETTIME reports via mono_100ns_ticks(), but we treated the
values as if they were in us.
2014-04-23 16:19:54 -07:00
Joao Matos b175675ad9 Added System.IO.Compression implementation. 2014-04-23 22:12:06 +01:00
Joao Matos bb3f24e999 Added our own slightly modified copy of Ionic.Zip library.
The changes are documented in the Xamarin.txt file.
2014-04-23 22:11:55 +01:00
Andrea Canciani e3592a0091 Fix 'make check' when mono is not installed
When the xbuild_12 profile is verified, the corlib from the net_4_5
profile should be in the MONO_PATH, otherwise the verification will
fail with:

The assembly mscorlib.dll was not found or could not be loaded.
It should have been installed in the `.../mono/4.5/mscorlib.dll' directory.
2014-04-23 22:53:14 +02:00
Alexis Christoforides 1a15d4ec54 Revert "Mono version is now pulled in to configure.in from MONO_VERSION"
This reverts commit 164f9cbec4.
2014-04-23 14:57:38 -04:00
Alexis Christoforides 8f09dad435 Revert "Merge branch 'master' of https://github.com/mono/mono"
This reverts commit 9dd632fb9e, reversing
changes made to 164f9cbec4.
2014-04-23 14:56:39 -04:00
Alexis Christoforides 9dd632fb9e Merge branch 'master' of https://github.com/mono/mono 2014-04-23 14:44:48 -04:00
Alexis Christoforides 164f9cbec4 Mono version is now pulled in to configure.in from MONO_VERSION
This makes it easier to grab&use the version elsewhere in the future (e.g. in packaging)
2014-04-23 14:42:45 -04:00
Zoltan Varga 62342d9f56 [jit] Add some comments to register_icall (). 2014-04-23 17:31:54 +02:00
Marek Habersack 73f09870a1 Update test description to include full bug report url 2014-04-23 17:24:37 +02:00
Marek Habersack 3df23604a4 Correctly apply DST offset if the date being converted falls after Jan 1st and is within the last year's DST zone
The adjustment rule must take into account that DST can start in the previous year and extend to some initial period
of the DateTime's year. This patch makes the code take that into account and correctly applies the DST offset to the
date being converted to some target timezone.

Fixes xambug https://bugzilla.xamarin.com/show_bug.cgi?id=17155
2014-04-23 17:15:18 +02:00
Rodrigo Kumpera 9143696db6 Revert "Disable bug-18026.exe when running tests in the CI environment"
This reverts commit 5699e87d5b.

We don't disable tests that reveal regressions. This is one of such cases.
2014-04-23 09:45:36 -04:00
Andrea Canciani 9b78ea6412 Use mktemp instead of $RANDOM to generate unique names
Using $RANDOM is not safe because collisions can occur. An example of
such a failure is available here:
https://s3.amazonaws.com/archive.travis-ci.org/jobs/23572639/log.txt

Using mktemp avoids this issue and removes the dependency on bash.
2014-04-23 15:11:12 +02:00
Marek Habersack 44c0689534 A couple of fixes for TimeZoneInfo.ConvertTime.
* ConvertTime (DateTime, TimeZoneInfo) now correctly takes the date kind from the DateTime parameter
      and uses it to select the source time zone according to this criteria:

         if DateTime kind is Utc, use TimeZoneInfo.Utc as source, in all other cases use TimeZoneInfo.Local

    * Move argument checks in ConvertTime (DateTime, TimeZoneInfo, TimeZoneInfo) so that there's no risk of a NREX
      should sourceTimeZone be null.

Added relevant tests for all of the above changes.
2014-04-23 14:53:01 +02:00
Rodrigo Kumpera b3920c6fda [sgen] Add a bunch of clear-at-gc variants to the test matrix. 2014-04-23 08:50:23 -04:00
Rolf Bjarne Kvinge 810306d84b [Mono.CSharp] Fix compilation for the monotouch profile with new exception filter support in mcs.
Otherwise this happens:

    MCS     [monotouch] Mono.CSharp.dll
    ../../mcs/codegen.cs(294,7): error CS1061: Type `System.Reflection.Emit.ILGenerator' does not contain
    a definition for `BeginExceptFilterBlock' and no extension method `BeginExceptFilterBlock' of
    type `System.Reflection.Emit.ILGenerator' could be found. Are you missing an assembly reference?
2014-04-23 12:25:28 +02:00
Zoltan Varga cad503aafd Merge pull request #1000 from ranma42/disable-18026-on-wrench
Disable bug-18026.exe when running tests in the CI environment
2014-04-23 09:44:11 +02:00
Andrea Canciani 5699e87d5b Disable bug-18026.exe when running tests in the CI environment
The test performed in bug-18026.exe can sometimes fail if the hazard
table gets full. Disabling it in CI testing avoids unwanted noise.

See https://bugzilla.xamarin.com/show_bug.cgi?id=19235
2014-04-23 08:56:38 +02:00
Zoltan Varga 2facf4db1f [sdb] Add support for DebuggerNonUserCodeAttribute. 2014-04-22 23:16:53 +02:00
Zoltan Varga 66aa6bb316 [arm64] Add AOT support. 2014-04-22 19:35:00 +02:00
Zoltan Varga 924fb2a51a [arm64] Add JIT support. 2014-04-22 19:34:26 +02:00
Zoltan Varga 6b94388f8e [arm64] Add sgen support. 2014-04-22 19:34:25 +02:00
Zoltan Varga 80ec6b529b [arm64] Add context/mach support. 2014-04-22 19:34:25 +02:00
Zoltan Varga a4c4a5120a [arm64] Add basic port infrastructure. 2014-04-22 19:34:25 +02:00
Marek Safar 09366779f0 [system] Don't terminate response reading on bad cookie value. Fixes #18868 2014-04-22 14:31:19 +02:00
Alexis Christoforides 8b1ca21e8f Merge pull request #994 from drummerhu/patch-1
xml type parameters have no size specifier
2014-04-22 00:00:49 -04:00
Zoltan Varga 70a2afb818 [jit] Fix a bug introduced by 683527c694. 2014-04-21 21:15:35 +02:00
Rodrigo Kumpera 2fa83d9a8c [counters] Simplify things a bit by removing unsigned counter types. 2014-04-21 12:24:06 -04:00
Rodrigo Kumpera 356e0f2bea [counters] Add mono_counters_foreach API. 2014-04-21 12:24:06 -04:00
Rodrigo Kumpera 3d24680ebe [counter] Kill counter type MONO_COUNTER_TIME_INTERVAL in favor of using a proper unit type.
This makes it more explicit and will further simplify the agent.
2014-04-21 12:23:43 -04:00
Rodrigo Kumpera 44b1144ed1 [counters] Introduce variance and units. 2014-04-21 12:23:42 -04:00
Rodrigo Kumpera 8e4d85b584 [counters] Introduce two new counters categories, runtime and system.
The runtime category is for high level counters on runtime operations.
Things like number of threads, threadpool status, total memory consumption
and so on.

The system category is for synthetic counters that report system values
such as RSS, user time and load.
2014-04-21 12:23:37 -04:00
Zoltan Varga 683527c694 [jit] Get rid of mono_arch_nullify_plt_entry (), it works the same way on all platforms. 2014-04-19 20:07:42 +02:00
Alex Rønne Petersen 86c7d75bce Update CONTRIBUTING.md with info about pull request testing. 2014-04-19 08:04:35 +02:00
Miguel de Icaza 29a2d0db57 [genproj] Steps towards making pre-build scripts cross platform; Lots more build now 2014-04-18 23:18:38 -04:00
Miguel de Icaza d79280674b Refreshed the CSProj files to use the new output build directory 2014-04-18 18:15:35 -04:00
Miguel de Icaza caa7615328 [genproj] Set the output directory to the Mono one, not an intermediary one 2014-04-18 18:15:35 -04:00
Miguel de Icaza c6c7c5af9c Update order.xml 2014-04-18 18:15:35 -04:00
Alexis Christoforides 49ac34bc80 Fixed xamarin #18898 # / novell #595899
DataRowView indexer should not break on "completed" added rows (any rows other than the IsNew one)
2014-04-18 18:08:16 -04:00
Alex Rønne Petersen 5e2f1f3301 Fix my last commit to match our libgc's declaration style. 2014-04-18 19:51:34 +02:00
Alex Rønne Petersen fb7c7e39b5 Hopefully fix a build error in libgc on some compilers.
../../libgc/alloc.c: In function ‘GC_stopped_mark’:
../../libgc/alloc.c:501:9: error: implicit declaration of function ‘GC_cond_register_dynamic_libraries’ [-Werror=implicit-function-declaration]
         GC_cond_register_dynamic_libraries();
2014-04-18 19:34:49 +02:00
Miguel de Icaza f07d6c58bc [genproj] Some hygiene changes to genproj, to be able to even digest this 2014-04-18 10:57:01 -04:00
Rodrigo Kumpera 816dde7892 [sgen-bridge] Introduce accounting mode to bridge processing.
This accounting mode logs the "cost" of each bridge-object during bridge processing.
This should give a very good first clue on how expensive each object is.
2014-04-17 19:26:41 -04:00
Alex Rønne Petersen 1669d0456b Really, seriously, for real fix mono/tests/Makefile.am when run with CI=1/V=1. 2014-04-18 01:07:51 +02:00
Martin Baulig f647afb02f [Http]: Correctly handle request bodies when resending with authentication.
My previous changes modified the way how we're handing the request body when
resending a request due to a 30x redirection.

Authentication is a "special" form of redirection because we sometimes need
to resend a request with additional authentication headers.  Unfortunately,
I forgot this, causing a regression which is now fixed.

This has been reported as bugs #19119 and #19068.
2014-04-17 22:27:19 +02:00
Jeffrey Stedfast 0096790ae5 [Mono.Debugger.Soft] Throw a NotSupportedException if we encounter an unsupported IL opcode 2014-04-17 16:05:39 -04:00
Marek Safar 394eb0d670 [corlib] Defer TypeInfo instantiation logic in DefinedTypes. Fixes #19082 2014-04-17 20:00:34 +02:00
Zoltan Varga f287d3c95b [jit] Fix an unreachable code part in mini_emit_memset (). Fixes #19083. Thanks to Bill Seurer for spotting it. 2014-04-17 17:49:36 +02:00
Alex Rønne Petersen 1d30486054 Shell expansion rules suck. Fix a7712d9093. 2014-04-17 16:32:38 +02:00
Miguel de Icaza b45701b799 Add System.Xml.Linq to the dotnet.pkg 2014-04-17 10:14:57 -04:00
Alex Rønne Petersen 4ea81c1845 Fix a couple of warnings in sgen-cardtable.c. 2014-04-17 14:51:54 +02:00
Alex Rønne Petersen 357afd3e25 Remove .travis.yml.
Travis simply doesn't give us anywhere near enough execution time
to run runtime tests + BCL tests.
2014-04-17 14:39:54 +02:00
Alex Rønne Petersen a2e4404751 Ignore testlist files in mono/tests. 2014-04-17 14:39:54 +02:00
Alex Rønne Petersen a7712d9093 Clean up mono/tests/Makefile.am.
This removes a lot of duplicated logic and special-casing for Wrench. There
are now only 3 important top-level targets:

* `check`: Run all stable (~fast) tests.
* `check-full`: Run all stable, unstable, and slow tests.
* `check-parallel`: Compile tests in parallel, then run `check-full`.

By default, `no-dump` is passed to the test runner. To pass `dump-output` and
get `stdout`/`stderr` dumped to console when a failure occurs, set `V` as in:

    $ make check V=1

Or:

    $ make check-full V=1

If you're running tests in a CI environment, it may be desirable to disable
tests that are known to be unstable. To do so, run:

    $ make check CI=1

Or:

    $ make check-full CI=1
2014-04-17 14:39:54 +02:00
Marek Safar b36b99fc06 [mcs] Fix tie breaking rules when both candidates have used default parameters 2014-04-17 13:13:31 +02:00
Zoltan Varga 0da13fe72f [aot] Add a separate mutex to each AOT module to reduce contention. 2014-04-17 12:48:04 +02:00
Zoltan Varga 8caa3960e9 [jit] Use compile-time conditionals in a few places. 2014-04-17 12:33:01 +02:00
Zoltan Varga 4797f0b912 [llvm] Fix the decomposition of some long opcodes on 32 bit machines. 2014-04-17 12:29:08 +02:00
Zoltan Varga ee785d7c42 Fix the build. 2014-04-17 11:43:51 +02:00
Zoltan Varga ae34bffe53 [llvm] Remove unused LLVM_MONO_BRANCH define. 2014-04-17 07:15:00 +02:00
Zoltan Varga 4bcbce9b02 Disable the self-assign warning when using clang. 2014-04-17 07:10:29 +02:00
Zoltan Varga cef112d74d [llvm] Update the LLVM backend to the LLVM mono-2014-04-17-cc117f4ad24a7ae6743ab6f08b8f5e8fc65d2d7f branch. 2014-04-17 07:06:38 +02:00
Zoltan Varga 0b197c8234 [llvm] Add a LLVM_API_VERSION define which is incremented in llvm every time there is a public api break. This allows the llvm backend to compile with different versions of LLVM. 2014-04-17 07:06:37 +02:00
Mark Probst c08bca90ee [sgen] Counter for time we spend starting and stopping the world. 2014-04-16 14:18:17 -07:00
Mark Probst cdce271a81 [sgen] Fix M&S object iteration.
When we want to iterate without sweeping, then on blocks that
have not been swept, we can only iterate over objects that are
marked.
2014-04-16 14:18:16 -07:00
Mark Probst 6a67811198 [sgen] Fix CLEAR_AT_GC.
We end up with faux arrays when we’re allocating new objects, but
the nursery must be zeroed.  We just zero the first few words when the
TLAB is created to get rid of the array header.

An alternative would be to erase the headers once the nursery
collection is over, which is cleaner and would only zero what we know
must be zeroed, i.e. it would catch errors in cases where we now
overwrite non-zero garbage in the nursery.  That’s an unlikely case,
though, and we don’t use this debug feature often anyway.
2014-04-16 14:18:16 -07:00
Mark Probst 86b1ca3abc [sgen] Fix remset consistency check in presence of cementing. 2014-04-16 14:18:16 -07:00
Mark Probst 713a6d2186 [sgen] Make binary protocol grep work without search addresses. 2014-04-16 14:18:15 -07:00
Mark Probst 35f397edc8 [sgen] Count cards for binary protocol. 2014-04-16 14:18:15 -07:00
Mark Probst 9f6ab33462 [sgen] Don't scan cards in no-reference LOS objects. 2014-04-16 14:18:14 -07:00
Mark Probst 83b51581f8 [sgen] Make missing remset debugging easier. 2014-04-16 14:18:14 -07:00
Mark Probst 659c69a0ba [sgen] Small refactoring of sgen_card_table_update_mod_union(). 2014-04-16 14:18:14 -07:00
Mark Probst 2308ee2ab9 [sgen] Make mod-union consistency check work again. 2014-04-16 14:18:13 -07:00
Mark Probst 97f8411a7d [sgen] Tool for visualizing GC pauses from binary protocols. 2014-04-16 14:18:13 -07:00
Mark Probst 3ba6b6919f [sgen] Binary protocol entries for world stop/restart with timestamps. 2014-04-16 14:18:13 -07:00
Mark Probst 9b36e8ec43 [sgen] Enable binary protocol by default, make the heavy stuff optional. 2014-04-16 14:18:12 -07:00
Marek Safar 329a10976a [mcs] Fix parsing member access expression with await simple name 2014-04-16 21:19:47 +02:00
Marek Safar 7fddc01287 [mcs] Relax struct definitive assignment rules for private fields 2014-04-16 20:05:16 +02:00
Alex Rønne Petersen 80b154781e Since make distcheck has been fixed, use it in .travis.yml again. 2014-04-16 18:39:16 +02:00
Alex Rønne Petersen 0ac40d8c71 Flush po/... files. 2014-04-16 18:19:46 +02:00
Miguel de Icaza e3150746f3 Runtime documentation will now build with srcdir != builddir
This removes an old and broken patch that did not allow for
clean builds of Mono.   The old patch was so bad, that instead
of fixing the actual source of the problem (the ability to build
the runtime documentation when the source directory was not the
same as the build directory), a hack was added to circumvent
`make distcheck''s security system and changed the permissions
at build time for the source directory to become read/write.

This fixes the problem
2014-04-16 12:09:20 -04:00
Miguel de Icaza 8f790e107f Update the configuration file for project builds 2014-04-16 12:09:20 -04:00
Miguel de Icaza 816c9eb193 Remove empty space from assembly name 2014-04-16 12:09:19 -04:00
Zoltan Varga 10f6606d5b [jit] Fix the lookup of the AOT version of Interlocked.Exchange<T> in full-aot mode. Fixes #19070. 2014-04-16 18:05:46 +02:00
Rodrigo Kumpera d2108392db [win64] Fix stack probing and disable omit_fp. Fixes iltests.
Stack probing on windows must be done a page a time so we must always force it to happen on windows.
Disable omit_fp on win64 for now as it makes the tail call tests fail.
2014-04-16 11:37:27 -04:00
Zoltan Varga 37f78e42a8 [llvm] Fix the loadable llvm build. 2014-04-16 17:19:47 +02:00
Marek Safar dac82c328c [mcs] Emit exception filters with empty stack 2014-04-16 16:53:48 +02:00
Marek Habersack 5564dad150 Fall back to calling Java.Util.TimeZone.Default.ID if the persist.sys.timezone system
property is not present on the system or its value is an empty string. This ensures that
we obtain valid timezone info on systems which do not define the above property.

Part of fix for https://bugzilla.xamarin.com/show_bug.cgi?id=4902
2014-04-16 16:23:16 +02:00
Antoine Cailliau b2b269b1e8 [Fix] DataContractJsonSerializer fails serializing/deserializing collections 2014-04-16 15:10:17 +02:00
Alex Rønne Petersen c7c6506ce3 Avoid make distcheck in .travis.yml for now. 2014-04-16 14:57:02 +02:00
Alex Rønne Petersen f2e208a3a1 Only build master for now. 2014-04-16 13:34:32 +02:00
Alex Rønne Petersen 228aed9001 Add initial .travis.yml. 2014-04-16 13:07:49 +02:00
Alex Rønne Petersen a7c60da137 Make all Python scripts Python 3-friendly. 2014-04-16 12:54:41 +02:00
Marek Safar 8148b9c576 Update tests 2014-04-16 11:40:07 +02:00
Marek Safar 4ef97a07f3 Update error message 2014-04-16 11:40:07 +02:00
Marek Safar 8db075c049 [mcs] Initial implemntation of exception filters 2014-04-16 11:40:07 +02:00
Marek Safar b7399f6c0d [mcs] Primary constructors 2014-04-16 11:40:07 +02:00
Marek Safar 2865d4bda1 Merge pull request #996 from DavidS/fixes/string-format-nre
[System] handle arguments whose ToString returns null in String.Format
2014-04-16 10:10:44 +02:00
David Schmitt 3f9dd10eed [System] handle arguments whose ToString returns null in String.Format
When an argument to String.Format has no formatter, its ToString method
is called. This change takes care that the FormatHelper can handle
arguments whose ToString() method returns null.
2014-04-16 09:26:23 +02:00
Zoltan Varga 945faf65d1 [jit] Rewrite lookup_method () to reduce contention by not taking the loader lock while doing hashtable lookups. 2014-04-16 08:54:46 +02:00
Zoltan Varga dd72864f56 [runtime] Add some low level locks to image sets to reduce contention and the usage of the loader lock. 2014-04-16 06:47:58 +02:00
Rodrigo Kumpera b8ab042da7 [runtime] Don't g_string_append an empty string when running regression tests. 2014-04-15 17:55:23 -04:00
Rodrigo Kumpera f15f527aff [windows] Win64 requires 16 bytes alignment too. 2014-04-15 17:55:21 -04:00
Rodrigo Kumpera deeaba4549 [VS] Change the tools version back to v110 so it works with VS 2012. 2014-04-15 17:55:20 -04:00
Rodrigo Kumpera d30aa865a5 [windows] Remove sdb symbol from mono.def. Fix the build. 2014-04-15 17:55:18 -04:00
Marek Safar da35cb932b Add ICscHostObject4 skeleton 2014-04-15 23:31:48 +02:00
Miguel de Icaza 718ab59105 Merge pull request #987 from StephenMcConnel/bug-18874
Adjust scrollbar display after layout if autosized children
2014-04-15 16:29:06 -04:00
Alexis Christoforides 2a949443bc Added contribution guideline links in README
New section has links to guideline wiki page, and the page's Important Rules section that all contributors should be aware of.
2014-04-15 16:10:29 -04:00
yjoly a4a65eda9a Fix the date time set in file by removing the ':'.
This is the same code than the one under SendCore. The date time should
not have the : (time zone offset) to be able to use the file.
2014-04-15 15:41:40 -04:00
drummerhu b4786dbd7e xml type parameters have no size specifier
generate "@p1 xml" instead of "@p1 xml(123)"
2014-04-15 21:09:11 +02:00
Zoltan Varga 7e33fc7450 [llvm] Fix a few problems with longs on 32 bit platforms. Fixes #18925. 2014-04-15 08:54:05 +02:00
Alex Rønne Petersen 6a7791058f Ignore scripts/ikdasm. 2014-04-14 22:53:36 +02:00
Rodrigo Kumpera f62347fe66 [llvm] Fix llvm loading. 2014-04-14 15:53:53 -04:00
Alex Rønne Petersen 759257d32d Fix handling of the volatile. prefix instruction.
* Respect the `volatile.` prefix on all instructions specified in
  Ecma 335, Partition III, 2.6.
* Emit release barriers _before_ the instructions they affect.
* Skip certain optimizations when the `volatile.` prefix is used,
  since we can't easily emit barriers correctly in those
  optimization paths.
* Use `ins_flag` to check for `MONO_INST_VOLATILE` as it doesn't
  depend on an instruction having been emitted. This would kind of
  not work when we need to emit barriers before other instructions.
* Set `ins_flag` to zero in all cases where it's consumed.
2014-04-14 19:03:50 +02:00
Alex Rønne Petersen 7c6c3f9b39 Remove pointless #elif branch in mono-membar.h. 2014-04-14 19:03:50 +02:00
Alex Rønne Petersen bc31c79675 Clean up the log profiler's use of atomics. 2014-04-14 19:03:50 +02:00
Alexis Christoforides 7b9fc5514c Merge pull request #986 from ninjarobot/patch-1
Update io.c to support NFS mounts when parsing drives.
2014-04-14 11:28:53 -04:00
ninjarobot a177760688 Update io.c
Support for NFS mounts when parsing drives.  Previously ignored since they don't start with '/'.

This change is released under the MIT license.
2014-04-14 11:02:02 -04:00
Rodrigo Kumpera ba175a7bc5 Merge pull request #990 from BrandonLWhite/bw/cqleak
[runtime] Fixed leak of MonoListItems in MonoCQ
2014-04-14 09:12:10 -04:00
INADA Naoki f69cdd00ba Remove checking Origin header.
RFC requires Origin header for browser client.
Non browser client may be omit Origin header.
2014-04-13 16:03:22 +09:00
Sebastien Pouliot 81bdc35dd4 [xammac] Remove the Makefile hack as the extensions instructions will be applied (only) when a PROFILE_*.sources is present (and add that xammac_corlib.dll.sources file) 2014-04-12 12:41:26 -04:00
Alex Rønne Petersen ac60ecf03f Merge pull request #656 from LogosBible/collection_lock
Take shared file lock before collecting file share_info.
2014-04-12 15:40:23 +02:00
Brandon e4cdce00aa [runtime] Fixed leak of MonoListItems in MonoCQ
I release this change under the MIT license.
2014-04-12 08:25:11 -05:00
Alex Rønne Petersen 90d6059c54 Merge pull request #273 from joncham/bug-getpid
Use getpid instead of GetCurrentProcessId as the latter calls into io-la...
2014-04-12 10:29:38 +02:00
Alex Rønne Petersen e8f2c7111d Merge pull request #991 from ranma42/fix-jay-sh-bashism
Use bash when using $RANDOM bashism
2014-04-12 09:30:07 +02:00
Andrea Canciani 0c6920546b Use bash when using $RANDOM bashism
$RANDOM is only supported by bash, not by sh.
2014-04-12 09:03:56 +02:00
INADA Naoki c54a3f5d9d Fix indent of author. 2014-04-12 14:55:53 +09:00
INADA Naoki 32462f8089 Fix handling fragment and opcode. 2014-04-12 14:53:46 +09:00
Zoltan Varga ea490c5486 [runtime] Improve the hashing of MONO_TYPE_VAR/MONO_TYPE_MVAR. Hopefully fixes #18880. 2014-04-12 04:56:14 +02:00
Zoltan Varga 506cd5e9f0 Merge pull request #988 from ranma42/fix-lls-test
Fix assertion in test-mono-linked-list-set
2014-04-12 02:31:19 +02:00
Zoltan Varga 83e085556d Merge pull request #989 from rolfbjarne/bundle-tracing-improvements
Improve tracing output for loaded assemblies from bundles.
2014-04-12 02:28:59 +02:00
Rolf Bjarne Kvinge cc7162510a Report bundle tracing using the filename, not the full path. 2014-04-12 00:56:33 +02:00
Rolf Bjarne Kvinge fb069fc1bc Improve tracing output for loaded assemblies from bundles. 2014-04-12 00:46:30 +02:00
Rodrigo Kumpera a2dd3db49b Use mono_dl_open_runtime_lib as an additional fallback for loading the profiler. Fixes profiler loading on OSX. 2014-04-11 18:16:10 -04:00
Rodrigo Kumpera 920b500407 Use mono_dl_open_runtime_lib instead of hand crafted load commands. 2014-04-11 18:16:09 -04:00
Rodrigo Kumpera 30532e6174 New function mono_dl_open_runtime_lib that loads runtime libraries.
This extracts the code used to load LLVM.
2014-04-11 18:16:09 -04:00
Sebastien Pouliot f39b3d794a [Mono.Security] Add .sources file for xammac (same as monotouch) 2014-04-11 18:11:30 -04:00
Sebastien Pouliot 911b80fc86 [xammac] Ajust corlib and System.Core builds to allow to use of CommonCrypto in Xamarin.Mac 2014-04-11 16:08:44 -04:00
Sebastien Pouliot 8df01216de [Mono.Security] Send all the certificates (except the root) from an SSL/TLS 'Server certificate' message (7.4.2 in RFC2246). Fix contributed by [email protected] [#16974] 2014-04-11 15:55:47 -04:00
Alexis Christoforides 5e4093ab13 Merge pull request #845 from meyerrj/master
Support for video/mp4, video/ogg, video/webm
2014-04-11 15:16:16 -04:00
INADA Naoki e4f842adf5 Use do ... while (true) 2014-04-12 03:23:31 +09:00
INADA Naoki 8f3f12726a Support receiving frame larger than buffer. 2014-04-12 03:21:01 +09:00
INADA Naoki e63e21edc2 Support CloseStatus 2014-04-12 03:06:36 +09:00
INADA Naoki 298e70c307 Fix some bugs. 2014-04-12 02:49:08 +09:00
Miguel de Icaza 53a08ebc1d Style on the README file, make it more readable for command line users 2014-04-11 12:04:10 -04:00
INADA Naoki 4239b4cb2e Reimplement StreamWebSocket. 2014-04-11 23:15:24 +09:00
Alex Rønne Petersen 3652241132 ARM: Fix epilogue instrumentation to handle MONO_TYPE_{GENERICINST,R4,R8} correctly. 2014-04-11 10:22:28 +02:00
Alex Rønne Petersen 2d797acdd8 Revert "ARM: Fix epilogue instrumentation to handle MONO_TYPE_{GENERICINST,R4,R8} correctly."
This reverts commit 1afa622ba4.

I had a more recent version of this commit locally...
2014-04-11 10:22:08 +02:00
Alex Rønne Petersen 1afa622ba4 ARM: Fix epilogue instrumentation to handle MONO_TYPE_{GENERICINST,R4,R8} correctly. 2014-04-10 23:24:16 +02:00
Alexis Christoforides 73ba8a9535 [System.Net] Fixed intermittent test failures from undisposed UdpClients 2014-04-10 15:56:48 -04:00
Alexis Christoforides 5df45ecd4e [Security] Added check for failed chmod on "keypairs" directory creation
This is to help detect issues where the directory is later found to be not locked down.
2014-04-10 15:00:10 -04:00
Marek Safar f59d306ad2 [system.net.http] Improve 50879b35cf to close all connections not only the last one 2014-04-10 13:02:34 +02:00
Marek Safar 7be9829aa9 [mcs] Typo in error message 2014-04-10 11:17:22 +02:00
Marek Safar f860fe0aaf [mcs] Reference assemblies with same identity cannot have different version number 2014-04-10 10:54:33 +02:00
Andrea Canciani 78a64f7331 Fix assertion in test-mono-linked-list-set
When running 'make check', test-mono-linked-list-set fails with:

* Assertion at hazard-pointer.c:353, condition `small_id == i' not met

This happens since 71ad74dc11, because
that commit changes the behaviour of mono_thread_smr_init() so that
invoking it should not be invoked more than once.
2014-04-09 23:10:25 +02:00
Stephen McConnel cfd4b71552 Adjust scrollbar display after layout if autosized children
ScrollableControl.OnLayout sets the scroll bar display before doing the
actual layout.  If any children are autosized, they may change size as
a result of the layout, and that may change whether or not the scrollbar
is needed.  (This addresses Xamarin bug 18874.)
2014-04-09 15:42:28 -05:00
Rodrigo Kumpera 217e071a40 Revert "[runtime] Improve the hashing of MONO_TYPE_VAR/MONO_TYPE_MVAR. Hopefully fixes #18880."
This reverts commit 078dc0321d.

It's breaking for everyone.
2014-04-09 15:41:53 -04:00
Marek Safar 633db36bd3 [System.Core] Don't auto increment when trimming hashset. Fixes #18687 2014-04-09 21:19:11 +02:00
Marek Safar 50879b35cf [system.net.http] Close service-point slot on explicit dispose. Fixes #18848 2014-04-09 20:35:23 +02:00
Alexis Christoforides f34a97d2e7 Merge pull request #985 from joelmartinez/master
[docs] Fixed XML syntax issue with CipherSuitesCallback, and ServicePointManager xml files.
2014-04-09 14:26:45 -04:00
Marek Safar abbb766d3a [interpreter] Disable fast call invocation using methodinfo delegates due to aot limitation. Fixes #18688 2014-04-09 17:57:49 +02:00
Zoltan Varga 078dc0321d [runtime] Improve the hashing of MONO_TYPE_VAR/MONO_TYPE_MVAR. Hopefully fixes #18880. 2014-04-08 21:53:39 -04:00
Zoltan Varga 8ecdcaa526 Revert "[llvm] Fix the build."
This reverts commit 8990ab3363.

Revert this as it only works with an llvm version which doesn't compile on lion.
2014-04-08 21:53:39 -04:00
Alexis Christoforides 94b523275e [XML] Added unit test for multiple XMLElement attributes on arrays & ArrayLists 2014-04-08 18:05:46 -04:00
Alan McGovern 159c0b02cd [Microsoft.Build.Tasks] 'Copy' task now returns failure when errors are logged
If we try to copy a file which does not exist, we log the error (as we have
always done) but now we return failure from the Copy task if any errors were
logged.

This means we will correctly fail the build later on instead of having a
successful build which did not complete correctly.
2014-04-08 12:22:49 -04:00
Marek Safar fd4a8931d4 Merge pull request #984 from echampet/trim-column
Fix CreateErrorFromString: match.Result("${column}") may contain a '+', ...
2014-04-08 16:31:27 +02:00
Etienne CHAMPETIER 919e7caf88 Fix CreateErrorFromString: match.Result("${column}") may contain a '+', trim it
Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-04-08 16:27:49 +02:00
Marek Safar a10df86558 [corlib] Better checks for release of parent task 2014-04-08 15:31:53 +02:00
BrandonLWhite 5e5f3a19fd Fixed memory leak in Task when child tasks are continually created.
This resolves bug # 18398 and other OOM scenarios in long running applications that make use of FromAsync, ContinueWith, etc. to "rearm" asynchronous operations.
2014-04-08 15:31:52 +02:00
Alex Rønne Petersen cde40faf26 Merge pull request #983 from xen2/master
Fix MSVC compilation (mini-native-types.c was considered as header) and updated VTune project to use 2013 version.
2014-04-08 14:56:37 +02:00
Joel Martinez c9dd31f779 [docs] Fixed XML syntax issue with CipherSuitsCallback, and ServicePointManager xml files. 2014-04-08 08:05:17 -04:00
Marek Safar 404466030e [System.Core] Exclude legacy visitor in new profiles 2014-04-08 12:44:07 +02:00
Martin Baulig f986a59333 [Http]: Disable redirect with body and no buffering. 2014-04-08 08:24:40 +02:00
Martin Baulig 461855eddd [Http]: Clear the 'SendChunked' flag when redirecting. 2014-04-08 08:24:21 +02:00
Martin Baulig 9f7e64c187 [Http]: Remove chunked/etc headers when redirecting a request as GET. 2014-04-08 08:23:54 +02:00
Virgile Bello dda7f2c520 VTune profiler: update to VTune Amplifier 2013. 2014-04-08 11:45:08 +09:00
Virgile Bello 8910bd2715 MSVC: In libmono.vcxproj, mini-native-types.c was included as header instead of source file. 2014-04-08 11:44:41 +09:00
Marek Safar 9b61bc6fcd [corlib] Add SortVersion. Fixes #18770 2014-04-07 19:22:17 +02:00
Marek Safar c52a372c78 [corlib] Set test failure when test hangs 2014-04-07 19:22:17 +02:00
Alexis Christoforides 6f677fd8c3 Merge pull request #955 from ermshiperete/bug-xamarin-10537
[MWF] Fix crash from null control in ContainerControl (#10537)
2014-04-07 11:55:47 -04:00
INADA Naoki 7a8efe928c [websocket] Don't use string += 2014-04-07 14:40:43 +09:00
INADA Naoki 0efffb11d8 [websocket] Use string.Equals instead of String.Compare 2014-04-07 14:26:20 +09:00
INADA Naoki 69b3e44b11 [websocket] Better hijacking. 2014-04-07 11:08:18 +09:00
INADA Naoki 69ff10cc32 [websocket] Cleaner closing. 2014-04-07 10:53:43 +09:00
INADA Naoki 7e221721de [websocket] Implement HttpListenerContext.AcceptWebSocketAsync(). 2014-04-07 10:36:03 +09:00
Zoltan Varga 3d469b99ac [runtime] Refactor mono_marshal_get_delegate_invoke_internal (). 2014-04-05 21:33:24 -04:00
Zoltan Varga a2e69cea69 [bcl] Simplify the check added in 0ab4372189. 2014-04-05 13:27:47 -04:00
Zoltan Varga 0ab4372189 [bcl] Add an explicit null check to one of the unsafe string cctors instead of relaying on the implicit null check in memcpy () to easy debugging. 2014-04-04 20:37:34 -04:00
Alexis Christoforides 01bc03ffde Merge pull request #941 from upsilon/fix-layoutsettings-setter
Fix setter of TableLayoutPanel.LayoutSettings throws unwanted exception (Novell bug #497562)
2014-04-04 20:17:27 -04:00
Michael Hutchinson 5cbb6452af [xbuild] Fix building with 2.0 toolset, take 2
BXC18794 - Error executing task Csc with 2.0 toolset since Mono 3.4.0
2014-04-04 16:37:00 -04:00
Zoltan Varga 7fafa50a31 Fix building the monotouch_runtime profile. 2014-04-04 15:50:54 -04:00
Zoltan Varga 45345e6790 Revert "[xbuild] Fix building with 2.0 toolset"
This reverts commit 2086958399.

Revert this as it breaks the build:

MCS [net_2_0] Microsoft.Build.Engine.dll
Microsoft.Build.BuildEngine/Engine.cs(114,81): error CS0117: Microsoft.Build.Utilities.TargetDotNetFrameworkVersion' does not contain a definition forVersion30'
/root/my-mono-fork/mcs/class/Microsoft.Build.Engine/./../../class/lib/net_2_0/Microsoft.Build.Utilities.dll (Location of the symbol related to previous error)
Microsoft.Build.BuildEngine/Engine.cs(116,81): error CS0117: Microsoft.Build.Utilities.TargetDotNetFrameworkVersion' does not contain a definition forVersion35'
/root/my-mono-fork/mcs/class/Microsoft.Build.Engine/./../../class/lib/net_2_0/Microsoft.Build.Utilities.dll (Location of the symbol related to previous error)
Compilation failed: 2 error(s), 0 warnings
2014-04-04 14:58:34 -04:00
Zoltan Varga 8990ab3363 [llvm] Fix the build. 2014-04-04 14:35:54 -04:00
Zoltan Varga edce99bf2e [jit] Fix a regression caused by 837773af14. 2014-04-03 23:03:42 -04:00
Zoltan Varga 32860abf66 [jit] Make generic ctor calls made out of gsharedvt methods indirect, since they cannot be patched. Fixes #18634. 2014-04-03 16:43:07 -04:00
Zoltan Varga 754317f328 [runtime] Disable some warnings. 2014-04-03 16:42:12 -04:00
Zoltan Varga 2629d9775a [jit] Fix some of the check for support of atomic intrinsics on arm. 2014-04-03 16:10:52 -04:00
Michael Hutchinson 2086958399 [xbuild] Fix building with 2.0 toolset
BXC18794 - Error executing task Csc with 2.0 toolset since Mono 3.4.0
2014-04-03 15:38:11 -04:00
Rodrigo Kumpera 8ffc4070a9 Add new public API function mono_set_crash_chaining.
mono_set_crash_chaining tells mono to chain crash signals instead of just
running the next one.

This allows us to get the crash info from both mono and the native system.
2014-04-03 12:04:59 -04:00
Jonathan Pryor 199edbc851 [System] Add [MonoTODO] on DefaultTraceListener.AssertUiEnabled.
See the mono-list thread for fun/gory details:

http://lists.ximian.com/pipermail/mono-list/2014-March/050732.html
2014-04-03 11:54:25 -04:00
Marek Safar b79ebc6d2a Merge pull request #978 from echampet/ikdasm-spec
Fix spec file for ikdasm
2014-04-02 12:25:34 -06:00
Etienne CHAMPETIER 769582078f Fix spec file for ikdasm
Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-04-02 18:57:29 +02:00
Michael Hutchinson c4667496bf [xbuild] Include PCL common targets in tarball
BXC18690 - Microsoft.Portable.Common.targets is missing in mono 3.4.0 tarball
2014-04-01 17:32:32 -04:00
Zoltan Varga 64372c1928 [arm] Remove some unused code. 2014-04-01 15:32:38 -04:00
Zoltan Varga 837773af14 [jit] Implement support for atomic intrinsics on arm. 2014-04-01 18:39:05 +00:00
Zoltan Varga 695b17f8d5 [runtime] Fix a crash if the thread name is set before the thread is started. 2014-04-01 18:32:33 +00:00
Marek Safar 56cf1b8c2e [corlib] Fixes CancellationTokenSource dispose race 2014-04-01 11:10:50 -07:00
Etienne CHAMPETIER a8ee7c2326 [FIX] correctly handle custom onclick attribute when autopostback = true for checkbox
onclick is in common_attrs not in Attributes, so we can't use BuildScriptAttribute

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-04-01 11:43:19 +02:00
Marek Safar 897e95954e [corlib] Update test with failure info 2014-03-31 16:37:24 -07:00
Marek Safar 2f710f7ac8 [corlib] Make invariant NumberFormatter thread static too as it has internal static state. Fixes #18599 2014-03-31 11:12:44 -07:00
Marek Safar c72270afd6 [corlib] Filter out any right-to-left sign characters. Fixes #18522 2014-03-31 10:09:29 -07:00
Rolf Bjarne Kvinge c3b8b74340 Fix monotouch's repl support to build Mono.CSharp (and its dependencies) as well. 2014-03-31 16:58:32 +02:00
Zoltan Varga db75057d43 Merge pull request #973 from methane/fix-build-on-mac
Add mono_threads_core_set_name() on Mac.
2014-03-31 04:17:24 -04:00
INADA Naoki 4bdf2a2d37 Add mono_threads_core_set_name() on Mac. 2014-03-31 16:19:04 +09:00
Alex Rønne Petersen 148b100061 Fix a wrong check in 254954dc09. 2014-03-30 07:31:31 +02:00
Zoltan Varga 97ad698ab4 [aot] Add ReadOnlyCollection to the list of types supported by gsharedvt. 2014-03-29 23:17:08 -04:00
Zoltan Varga 5e0579782e [runtime] Add support for setting the native thread name on linux. 2014-03-30 00:45:37 +01:00
Miguel de Icaza 776002ee28 Remove profanity 2014-03-28 20:56:02 -04:00
Zoltan Varga 02b95e9552 Fix ikdasm submodule repository path. 2014-03-28 11:06:58 -04:00
Alex Rønne Petersen 9191b70c44 Merge pull request #972 from madewokherd/win32service
System.ServiceProcess: Implement ServiceBase.Run for Win32 services.
2014-03-28 07:59:58 +01:00
Vincent Povirk 223e9566a5 System.ServiceProcess: Implement ServiceBase.Run for Win32 services.
This commit licensed as MIT/X11.
2014-03-27 17:55:40 -05:00
Zoltan Varga 369ce3a4fa [aot] Add a 'log-instances=filename' aot option to dump a list of method instances generated to a file for statistical purposes. 2014-03-27 16:02:07 -04:00
Craig Minihan 3c759e3969 [Fix] Bugzilla #18213 - System.Runtime.Caching.MemoryCache doesn't honor SlidingExpiration 2014-03-26 17:32:01 -07:00
Zoltan Varga 2c092e3b65 [aot] Refactor the code a bit. 2014-03-26 18:00:05 -04:00
Zoltan Varga e145e2fead [aot] Add more stats to the AOT compiler output. 2014-03-26 17:56:31 -04:00
Zoltan Varga e09c9f7a08 Distribute the ikdasm managed disassembler written by Jeroen Frijters. 2014-03-25 14:35:44 -04:00
Zoltan Varga 9999740d3a Bump external/ikdasm to master. 2014-03-25 14:26:50 -04:00
Zoltan Varga 47f30b288f Add the mono/ikdasm repository as a submodule. 2014-03-25 14:07:30 -04:00
Zoltan Varga 80d1a36c85 Revert "[llvm] Fix the build."
This reverts commit d9139d3f77.

Revert this as it doesn't work with the currently used mono llvm version.
2014-03-25 12:02:06 -04:00
Rodrigo Kumpera 2ea66a5906 Fix the build. 2014-03-25 10:34:43 -04:00
Zoltan Varga 5c054e5130 [runtime] Fix mono_sem_timedwait. 2014-03-25 10:24:39 -04:00
Zoltan Varga a2668b3d15 [runtime] Reduce timeouts in a test to speed it up. 2014-03-25 10:24:39 -04:00
Rodrigo Kumpera 5ed85e7aad Merge pull request #970 from Therzok/fixTypo
[BigInteger] Fix some tests typos.
2014-03-25 09:58:25 -04:00
Rolf Bjarne Kvinge b1babf0ff5 [System.Xml.Linq] Fix XNamespace.GetName locking to not be racy. Fixes #18564. 2014-03-25 08:50:46 -04:00
Marius Ungureanu b9e053aee5 [Mono.Posix] Remove profanity from tests. 2014-03-25 13:29:50 +02:00
Marius Ungureanu 2f4416a462 [BigInteger] Fix some tests typos. 2014-03-25 13:12:40 +02:00
Zoltan Varga 4f15ef462d [sdb] Implement a SetIP () method in ThreadMirror which can be used to implement the 'Set Next Statement' functionality in the VS debugger. 2014-03-24 22:14:08 -04:00
Zoltan Varga 9d156dab71 Fix a warning. 2014-03-24 16:32:07 -04:00
Zoltan Varga d9139d3f77 [llvm] Fix the build. 2014-03-24 09:13:46 -04:00
Marek Safar 7000b8ab4e Merge pull request #969 from eburgos/fix-wrong-cs0177-squashed
[mcs] Fix wrong case for error CS0177 (squashed)
2014-03-23 20:54:56 +01:00
Eduardo Burgos f953af2044 Adding fix for case of error CS0177 2014-03-23 13:48:44 -04:00
Zoltan Varga 6ee36b8a71 [jit] Fix rethrowing of exceptions in thumb mode. Fixes #18448. 2014-03-21 20:41:40 -04:00
Zoltan Varga 5d32ecb619 [jit] Add a few more constraints to the UnsafeMov intrinsic. 2014-03-21 20:37:15 -04:00
Zoltan Varga 9ccbd6a096 [runtime] Fix a regression caused by a7d26d4822. 2014-03-21 18:15:55 -04:00
Zoltan Varga 6f7a395e92 [runtime] Fix a warning. 2014-03-21 16:35:56 -04:00
Zoltan Varga db32a4e29e [jit] Disallow mixing structs/non-structs in the UnsafeMov intrinsic, the JIT can't handle it. 2014-03-21 15:42:09 -04:00
Zoltan Varga 4d066f415d [aot] Reorganize emit_and_reloc_code () a bit. 2014-03-21 15:42:09 -04:00
Eberhard Beilharz ecc5430d31 [mcs] Fix recursive resolving of crefs (#18511) 2014-03-21 18:23:59 +01:00
Eberhard Beilharz 88031ccb8d [mcs] Adding unit test for #18511 2014-03-21 18:23:58 +01:00
Marek Safar f9a509be0f Merge pull request #965 from PiotrZierhoffer/patch-1
Fix typo in exception message
2014-03-21 16:05:02 +01:00
Piotr Zierhoffer e7dce0eeba Fix typo in exception message 2014-03-21 16:00:45 +01:00
Zoltan Varga 3c0c5f8624 [runtime] Add a 'debug-domain-unload' MONO_DEBUG option to make the DEBUG_DOMAIN_UNLOAD define runtime configurable. 2014-03-20 21:09:31 -04:00
Marek Safar 9c5490d8c8 [System] CookieParser optimization tweaks 2014-03-20 22:20:59 +01:00
Zoltan Varga 8affdfa6fa [sdb] Add an Evaluate method to MethodMirror which can evaluate simple methods like property accessors on the client side without invoking methods in the debuggee. 2014-03-20 15:40:57 -04:00
Marek Safar 29d1e82bef [System.Net.Http] Incomplete byte ranges parsing. Fixes #18494 2014-03-20 18:57:01 +01:00
Zoltan Varga a7d26d4822 [jit] Add a 'check-pinvoke-callconv' MONO_DEBUG option to check for cdecl/stdcall mismatches. 2014-03-19 21:03:58 -04:00
Zoltan Varga ccdcf9cfdb [sdb] Implement support for fields in MethodBodyMirror. 2014-03-19 19:16:58 -04:00
Marek Safar 6169424b4c [corlib] Optimize EqualityComparer for common value types. Fixes #18400 2014-03-19 23:11:00 +01:00
Rodrigo Kumpera 6d405d4fd9 [jit] New Array.UnsafeMov intrinsic for overcomming our JIT lack of store-forwarding and type-aware opts. 2014-03-19 15:40:53 -04:00
Marek Safar 6363006285 [mcs] Better heuristics for error parsing of interrogation point. 2014-03-19 17:25:39 +01:00
Zoltan Varga fdae26513f Fix the cross-compiler build. 2014-03-18 19:58:35 -04:00
Marek Safar 652615f0a2 [mcs] Flow analysis of nested binary expressions inside anonymous methods was missing on left/right reset. Fixes #18417 2014-03-18 18:38:59 +01:00
Marek Safar 5bc6a95a39 [pcl] Update facades 2014-03-18 18:38:25 +01:00
Marek Safar 3163ab4f67 [mcs] Emit field initializer with expression tree in all user constructors. Fixes #18308 2014-03-18 16:44:41 +01:00
Marek Safar 6352c16dd5 Merge pull request #963 from kebby/master
Fix Process.CancelErrorRead
2014-03-18 13:45:38 +01:00
Tammo 'kb' Hinrichs e8eefe67ac Merge branch 'master' of https://github.com/kebby/mono 2014-03-18 12:46:10 +01:00
Tammo 'kb' Hinrichs dce6eeaece Fix Process.CancelErrorRead
Fixed CancelErrorRead throwing an InvalidOperationException because it checked the wrong output stream (probably a cut&paste mistake).
2014-03-18 12:45:11 +01:00
Tammo 'kb' Hinrichs 318127993d Fix error message in Process.CancelErrorRead 2014-03-18 12:15:14 +01:00
Tammo 'kb' Hinrichs de520ab9fa Fix Process.CancelErrorRead
Fixed CancelErrorRead throwing an InvalidOperationException because it checked the wrong output stream (probably a cut&paste mistake).
2014-03-18 12:08:48 +01:00
Sebastien Pouliot 13b942c073 [System.ServiceModel.Web] Fix JsonQueryStringConverter.ConvertValueToString to work when running on any culture [#18437] 2014-03-17 21:46:33 -04:00
Jérémie Laval 95f9ffacad Merge pull request #932 from exony-craigminihan/bugzilla#18182
[Fix] Bugzilla #18182 - ConcurrentQueue<T>.TryPeek() is not thread safe
2014-03-17 13:38:05 -04:00
Damien Daspit f01a48e5b4 [System.XML] Fix handling of space in XSL value-of elements (#18113) 2014-03-17 16:22:50 +01:00
Damien Daspit bc802fe9ff [System.XML] Add unit test for XSL value-of bug (#18113) 2014-03-17 16:22:34 +01:00
Damien Daspit ef1b6fb63c [System.XML] Fix XSL node-set bug (#18114)
XSL node-set function now behaves more like MS version.
2014-03-17 16:12:02 +01:00
Damien Daspit bdde4c4147 [System.XML] Add unit test for XSL note-set bug (#18114) 2014-03-17 16:04:12 +01:00
Marek Safar 276e18d2c7 [system] Update mobile sources list 2014-03-17 15:48:21 +01:00
Marek Safar 30305335b8 Merge pull request #956 from ermshiperete/bug-xamarin-14987
[corlib] Fix localized resource loading bug (#14987)
2014-03-17 15:42:08 +01:00
Marek Safar 16c05cafdf [mcs] Allow to set any metadata version 2014-03-17 15:38:45 +01:00
Damien Daspit edf75ac255 [System.XML] Fix handling of global variables in XSLs (#18118) 2014-03-17 15:19:39 +01:00
Damien Daspit c1d5e5ca14 [System.XML] Add unit test for #18118 2014-03-17 15:16:04 +01:00
MarkS 707051b342 [MWF] Partially implement Help.ShowHelp 2014-03-17 12:30:16 +01:00
Marek Safar ef3f17e5a5 Merge pull request #959 from NN---/patch-4
Do not crash if path is specified
2014-03-17 08:56:19 +01:00
Rodrigo Kumpera e777f9d045 Merge pull request #937 from exony-craigminihan/bugzilla#18235
[Fix] Bugzilla #18235 - System.Runtime.Caching.MemoryCache doesn't order...
2014-03-16 22:02:42 -04:00
NN f6bfc46060 Do not crash if path is specified
AssemblyBuilder is not a good class for doing that but simply taking only the file name covers most cases.
The best solution is to rewrite this tool using Mono.Cecil.

FYI AL.exe from .NET is not written in managed because of the SRE limitation
2014-03-16 23:08:53 +02:00
Zoltan Varga cfd789102b [runtime] Fix the msvc build. 2014-03-16 13:29:46 -04:00
Craig Minihan c3a89bffeb [Fix] Bugzilla #18182 - ConcurrentQueue<T>.TryPeek() is not thread safe
- removed IsEmpty test from TryPeek() since not needed now
2014-03-15 14:05:01 -07:00
Craig Minihan 8218c4afa1 [Fix] Bugzilla #18235 - System.Runtime.Caching.MemoryCache doesn't order expirable items correctly
- BubbleUp() in MemoryCacheEntryPriorityQueue was not ordering correctly on item insert
- Added a test case
2014-03-15 13:57:50 -07:00
Craig Minihan 704456aa48 [Fix] Bugzilla #18182 - ConcurrentQueue<T>.TryPeek() is not thread safe
- in the previous version the IsEmpty could be false, but by time we get
  to head.Next.Value we get an exception since Value is now null
- passes existing test cases, although these are not definitive since
  they don't show threading issue
- would need to adapt System.Threading.Tasks.ParallelTestHelper to allow
  TryPeek() to be called during Enqueue/Dequeue operations to truly
  test this change out
2014-03-15 13:50:51 -07:00
Mark Probst 71ad74dc11 [sgen] Restore hazard pointers in suspend signal handler. Fixes #15695. 2014-03-14 15:29:28 -07:00
Zoltan Varga b17ae00fa3 [runtime] Fix make install when boehm is disabled. 2014-03-14 17:44:00 -04:00
Rodrigo Kumpera e593b75bce Bump mono version. 2014-03-14 14:57:57 -04:00
Stephen McConnel 25ab7f7e36 [corlib] Fix localized resource loading bug (#14987)
We shouldn't share non-existent resources between resource
managers since different resources can have different localizations.
2014-03-14 17:24:46 +01:00
Stephen McConnel 18d7638422 [MWF] Fix crash from null control in ContainerControl (#10537) 2014-03-14 12:06:53 +01:00
Stephen McConnel 9b21123d56 [MWF] Fix TableLayoutPanel layout bug (#8907)
This fixes the TableLayoutPanel implementation to check for control names
as well as the the controls themselves in looking up the row and column
values.
2014-03-14 11:59:22 +01:00
Marek Safar 578585e0e8 Merge pull request #953 from rcook/p-rcook-correct-spelling
Correct spelling DEFAULT_ACCESS_MODIFER -> DEFAULT_ACCESS_MODIFIER
2014-03-14 08:56:16 +01:00
Miguel de Icaza 0a13aae80e System/PCL: Implement HttpWebRequest.SupportsCookieContainer, WebRequest.CreateHttp; Fixes #18378 2014-03-13 22:53:49 -04:00
Miguel de Icaza 9566a1fd9e WebResponse.cs: Implement SupportsHeaders property 2014-03-13 22:36:53 -04:00
Rodrigo Kumpera ecf3c6499a [boehm] Fix memory management for toggleref.
Replace GC_free with GC_INTERNAL_FREE. The former might take the GC lock
and deadlock us.

Replace GC_INTERNAL_MALLOC with GC_INTERNAL_MALLOC_IGNORE_OFF_PAGE as
we don't need the rest of the GC messing around with the toggleref array.
2014-03-13 18:47:26 -04:00
Rodrigo Kumpera 5dc84a1dcf [thread] Only register a dead letter if the current NSThread is non-null.
This breaks all embedder that don't link with CoreFoundation. In mono's case, monodis.
2014-03-13 18:19:33 -04:00
Richard Cook a8fc26651c Correct spelling DEFAULT_ACCESS_MODIFER -> DEFAULT_ACCESS_MODIFIER 2014-03-13 15:19:26 -07:00
Rodrigo Kumpera f6e4b69727 Fix a race condition in the test suite. 2014-03-13 18:19:22 -04:00
Rodrigo Kumpera d8f724157b [sgen] Fix the merging code.
The right behavior is that the loop move values up to the original size
and them the store after the loop store past it.

Let's see the last 2 iterations:

//i == size - 1 (value = array[size - 2], tmp = array [size - 1])
dyn_array_int_set (array, size, value); //ok
value = tmp; //ok
tmp = dyn_array_int_get (array, i + 1); //tmp has an unknown value, as the last element was never stored to.

//i == size (value = array[size - 1], tmp = array [size])
dyn_array_int_set (array, size, value); //This sets the last element to the right value
value = tmp; //value is undefined, as tmp has
tmp = dyn_array_int_get (array, i + 1); //this is an out-of-bounds read as we're reading 2 elements past the end.

The after the loop store (tmp = array [size + 1]):
dyn_array_int_set (array, size + 1, tmp); //This sets the last element to an unknown value.

With the fix on the last iteration is - 1. The post store will use value, which has
the right value (array [size - 1]).
2014-03-13 18:19:22 -04:00
Zoltan Varga 89d46b1b36 [jit] Add a MONO_IS_CROSS_COMPILE define. 2014-03-13 14:28:19 -04:00
Zoltan Varga 1aa0b78cc4 [runtime] Update configure after changes to llvm-config in the newest llvm versions. 2014-03-13 13:55:46 -04:00
Eberhard Beilharz 2d420bfb7a Set ErrorInfo in Marshal.GetHRForException
Marshal.GetHRForException had a MonoTODO because it needs to set
the errorinfo object so that exceptions get properly passed to
unmanaged code. Since not all managed exceptions have a corresponding
HR value but we might need to get to the original thrown exception
we implement a ManagedErrorInfo helper class that implements the
IErrorInfo interface but also stores the exception.

In GetExceptionForHR we check if the errorinfo we get is a
ManagedErrorInfo. If it is we return the exception stored in there
(if it converts to the same error code), otherwise we construct a new
exception.
2014-03-13 18:55:39 +01:00
Eberhard Beilharz 554d6abf4c Properly convert COM error codes to C# exceptions
Also use additional information provided by IErrorInfo to fill in
exception details.

To make use of IErrorInfo on Linux a suitable implementation has to be
provided, e.g. by including libcom plus adding a mapping from
oleauth32.dll to the shared library that provides the implementation.

This completes mono bug 496138
(https://bugzilla.novell.com/show_bug.cgi?id=496138)
2014-03-13 18:53:57 +01:00
Aaron Bockover caadde86d9 [bxc#18361] mdbrebase: use File.Move instead of FileInfo.MoveTo 2014-03-13 13:12:51 -04:00
Eberhard Beilharz 41ee671083 [MWF] Fix clipping of last line of dropdown (#2462)
The height we calculate is the inner height, so we need to add the top
and bottom borders when setting the height of the listbox. The width
however is the outer width so we need to subtract the left and right
borders when setting the client width.
2014-03-13 16:53:27 +01:00
Eberhard Beilharz 8584903ca6 [MWF] Release capture when clicking LinkLabel (Fixes #2787)
When clicking on a LinkLabel we need to release the mouse capture
otherwise the UI might lock up.

This fixes Xamarin bug #2787.
2014-03-13 12:47:13 +01:00
Eberhard Beilharz 85d54839fe [MWF] Fix text position on buttons (#463149)
Vertically centered text on buttons didn't show up centered. The
referenced bug reports it on Windows. Matters were worse on Linux.
This patch tries to fix the problem on both Windows and Linux. On Linux
the positioning is improved although probably still not perfect.

This fixes Novell bug #463149
(https://bugzilla.novell.com/show_bug.cgi?id=463149).
2014-03-13 11:40:55 +01:00
Marek Safar 060c0c67c0 [mcs] Ignore import failures for private types used in private structs 2014-03-13 10:33:15 +01:00
Alex Rønne Petersen f74f34db43 Add some pointless zero initializations to shut GCC at -O3 up. 2014-03-13 02:06:30 +01:00
Alex Rønne Petersen 0b97ca8686 Convert asserts in sgen-hash-table.c to SGEN_ASSERT (). 2014-03-12 22:59:47 +01:00
Alex Rønne Petersen 0e962a1782 Add an assert to sgen-hash-table.c!rehash_if_necessary () to make GCC at -O3 shut up. 2014-03-12 22:50:30 +01:00
Alex Rønne Petersen 3a45747932 Silence a gcc warning. 2014-03-12 22:05:58 +01:00
Alex Rønne Petersen a9e3264504 Add/update some .gitignore files so that a clean build + make check results in a clean repo. 2014-03-12 21:49:12 +01:00
Alex Rønne Petersen 8310ce510c Remove now-unused dyn_array_ptr_set () function. 2014-03-12 21:11:49 +01:00
Alex Rønne Petersen cfd5e7753b Add -fwrapv to gcc/clang flags.
We rely on signed overflow in many places (in particular for *detecting*
signed overflow), so we need to tell GCC and Clang to not perform any
optimizations that rely on it being undefined.
2014-03-12 21:11:09 +01:00
Rodrigo Kumpera ae165c5eb8 [sgen] Wrap DynArray into strongly types variants making the code cleaner and safer.
This paves the way for having different number of objects inline.
2014-03-12 14:31:05 -04:00
Rodrigo Kumpera dca87415f3 [sgen] Cleanup argument list of dfs1, src is a constant. 2014-03-12 14:31:04 -04:00
Rodrigo Kumpera 507d9bcd77 [sgen] Remove the elem_size field from DynArray - explicitly pass it instead.
This reduces the size of DynArray from 4 to 3 words. Small perf gain.
2014-03-12 14:31:04 -04:00
Rodrigo Kumpera d7612d7ed2 [sgen] Add an optimized variant of qsort using macros. This is 4x faster on sgen-bridge.
The macro produces a custom version of qsort that doesn't use memcpy or a function pointer.
2014-03-12 14:31:04 -04:00
Marek Safar b7ba13f9af [mcs] Private fields of structs can have type of another private not imported type 2014-03-12 18:28:02 +01:00
Marek Safar a492928ef8 [pcl] Complete System.Runtime.InteropServices facade 2014-03-12 18:28:02 +01:00
Eberhard Beilharz e11d2f4816 [MWF] Don't allow Height become less than MinimumHeight
In RowHeightInfoNeededEventArgs we need to check that the new
Height value isn't larger than the current MinimumHeight.
2014-03-12 16:45:44 +01:00
Eberhard Beilharz 5a9e3af896 [MWF] Add unit tests for DataGridViewRowHeightInfoNeededEventArgs 2014-03-12 16:45:44 +01:00
Eberhard Beilharz 4a2aff77aa [MWF] Fix crash when setting Row.Height (Fixes #2394)
When setting both Row.Height and MinimumHeight we need to set the
MinimumHeight first otherwise we will get a crash if the new Height
value is less than the old MinimumHeight value.
2014-03-12 16:45:43 +01:00
Eberhard Beilharz e5335d8a7f [MWF] Unit test for Row.Height/MinimumHeight bug (#2394)
This change adds unit tests that demonstrate the bug #2394
where setting Row.Height below MinumumHeight in a DataGridView
doesn't work as expected. The unit tests also document the
behavior of .NET which isn't documented in MSDN.
2014-03-12 16:45:43 +01:00
Eberhard Beilharz 1c98779dab [MWF] Adjust DataGridViewRow.Height according to MinimumHeight
When the MinimumHeight gets changed to a value less than Height
we set height to the new minimum height (and fire the
DataGridView.RowMinimumHeightChanged event). This matches the
behavior on .NET.

When the user tries to set Height to a value less than MinimumHeight
we silently set the height to the minimum height (instead of
throwing an exception). This matches also the behavior on .NET.
2014-03-12 16:42:44 +01:00
Eberhard Beilharz 5d1887a377 [MWF] Refactor DataGridViewRow.MinimumHeight tests
- fix the tests (tests made partially wrong assumptions which didn't
  match the behavior of .NET).
- split MinimumHeight test in multiple smaller tests that test only
  one thing.
- add a few more tests for MinimumHeight and Row.
2014-03-12 16:42:44 +01:00
Zoltan Varga ddd6681635 [jit] Fix the passing of vtypes on arm in vararg calls. Fixes MonoTests.System.Reflection.Emit.MethodBuilderTest.CanCallVarargMethods in corlib. 2014-03-11 19:11:51 -04:00
Marek Safar 323f0816f4 Add missing types and methods 2014-03-11 23:22:16 +01:00
Miguel de Icaza 6d0ffb3df8 Further doc updates, and schema fixing 2014-03-11 12:32:34 -04:00
Sebastien Pouliot 5bda991de3 [System] Document the new API for SSL/TLS cipher suites control added in ServicePointManager 2014-03-11 11:25:31 -04:00
Rodrigo Kumpera a678a101ee Merge pull request #938 from exony-craigminihan/bugzilla#18245
[Fix] Bugzilla #18245 - System.Runtime.MemoryCache.GetValues() throws Lo...
2014-03-11 10:28:54 -04:00
Marek Safar e14d3d04a4 [interpreter] Fix a typo 2014-03-11 14:29:56 +01:00
Marek Safar 2fd90f98a4 [interpreter] Implement simple quote expression. Fixes #18248 2014-03-11 14:29:55 +01:00
Alex Rønne Petersen 07b4f05070 Add support/ to the build when cross-compiling. 2014-03-11 10:11:36 +01:00
Zoltan Varga d65d91435a Fix a warning. 2014-03-10 21:06:45 -04:00
Zoltan Varga bd546d2926 [runtime] Fix the build with newer clang versions. 2014-03-10 20:59:20 -04:00
Mark Probst a10dcb6eb2 [runtime] Simplify unit-tests Makefile. 2014-03-10 15:59:07 -07:00
Mark Probst d180972ddf [runtime] Move unit tests to separate directory. 2014-03-10 15:59:07 -07:00
Mark Probst 539b2b929e [runtime] Unit test for lock-free linked list set. 2014-03-10 15:59:07 -07:00
Michael Hutchinson 2e939dd1b8 [MSBuild] BXC18246 - GetAssemblyIdentity is not implemented 2014-03-10 17:26:11 -04:00
Zoltan Varga e2a27f3326 [llvm] Update the LLVM backend to llvm 714a9d742af9ce911a3a46aa6e55041099a04be1. 2014-03-10 17:17:17 -04:00
Rodrigo Kumpera 83f77a71f9 Merge pull request #945 from joelmartinez/master
Documentation Update - 4.5 Profile
2014-03-10 16:52:02 -04:00
Joel Martinez 8ca91971eb docupdate: System.Numerics documentation update 2014-03-10 15:14:03 -04:00
Joel Martinez 4122e47891 docupdate: Microsoft.CSharp documentation update 2014-03-10 15:14:03 -04:00
Joel Martinez 7e0cfc10a5 docupdate: System.ComponentModel.DataAnnotations documentation update 2014-03-10 15:14:02 -04:00
Joel Martinez 3a0e33c369 docupdate: System.ComponentModel.Composition documentation update 2014-03-10 15:14:02 -04:00
Joel Martinez 7e5a64f35c docupdate: System.Core documentation update 2014-03-10 15:14:02 -04:00
Joel Martinez 307bd4fa43 docupdate: System.IO.Compression documentation update 2014-03-10 15:14:01 -04:00
Joel Martinez 2b564279c7 docupdate: System.Json documentation update 2014-03-10 15:14:01 -04:00
Joel Martinez 93f2e9f1f4 docupdate: System.Runtime.Serialization documentation update 2014-03-10 15:14:01 -04:00
Joel Martinez 46bf898791 docupdate: System.Security documentation update 2014-03-10 15:14:01 -04:00
Joel Martinez 68cf38bad0 docupdate: System.ServiceModel documentation update 2014-03-10 15:14:00 -04:00
Joel Martinez 25ca8ae5df docupdate: System.Xml.Linq documentation update 2014-03-10 15:14:00 -04:00
Joel Martinez 7bdbca8e92 docupdate: System.Xml documentation update 2014-03-10 15:13:59 -04:00
Joel Martinez 6537401395 docupdate: Mono.Options documentation update 2014-03-10 15:13:59 -04:00
Joel Martinez b17e448d93 docupdate: updated corlib documentation to the 4.5 profile 2014-03-10 15:13:59 -04:00
Joel Martinez b6baded277 Updated mdoc to remove <AssemblyVersions> tag 2014-03-10 15:13:57 -04:00
Joel Martinez ec03cbdc01 Fixed some reference issues with mdoc.csproj: mono.cecil assembly reference, and some resource files were incorrect 2014-03-10 15:13:56 -04:00
Joel Martinez eebbfbef2b docupdate: updated System.dll documentation 2014-03-10 15:13:56 -04:00
Joel Martinez df40b02d52 Updated makefile for Facades to avoid updating docs in that folder. 2014-03-10 15:13:55 -04:00
Zoltan Varga 6b6aee8c65 [jit] Add support for --debug=casts to one cast codepath, factor out common code. Fixes #18280. 2014-03-10 15:10:33 -04:00
Zoltan Varga 98619c109a [jit] Add an optimization to use the optimized delegate invoke trampolines in some special cases, since the corresponding delegate invoke wrappers cannot be AOTed. Fixes part of #17423. 2014-03-10 14:54:35 -04:00
Zoltan Varga f81868477f [jit] Change the sgen vector allocator il code so it can be AOTed. 2014-03-10 14:45:55 -04:00
Stephen McConnel 17cf11f433 [MWF] Better account for icon width in MessageBox
This fixes Xamarin bug #16374.
2014-03-10 16:47:25 +01:00
Stephen McConnel 4c88b53785 [MWF] Fix MessageBox to wrap texts reasonably
Wrap text in MessageBox window so that the message box has a reasonable
width.  This fixes Xamarin bug #15504.
2014-03-10 16:45:16 +01:00
Eberhard Beilharz 61f9fca85e [MWF] Fix size of text area on message box (Fixes #2090)
Previously some characters might have been concatenated on a message
box that displayed an icon because the size of the text area was
calculated wrong. This fixes bug #2090
(https://bugzilla.xamarin.com/show_bug.cgi?id=2090).
2014-03-10 16:45:10 +01:00
Marek Safar 3d23503a90 [interpreter] Size reduction 2014-03-10 16:14:56 +01:00
Marek Safar 6b959efb22 [corlib] Update en-au pm/am designators 2014-03-10 11:33:44 +01:00
Kimura Youichi cc21d974b5 Fix setter of TableLayoutPanel.LayoutSettings throws unwanted exception (Novell bug #497562) 2014-03-10 05:26:46 +09:00
Kimura Youichi 44bedb30d7 Add unit test for Novell bug #497562 2014-03-10 05:26:35 +09:00
Marek Safar 81573de69d [corlib] Add .net compatible separators for es culture 2014-03-08 23:05:53 +01:00
Marek Safar 0d4949b842 Merge pull request #940 from alistair/ilist_xml_serialization
ilist xml serialization
2014-03-08 23:01:13 +01:00
Zoltan Varga 34fa78a5d8 [bcl] Work around quadratic behavior in NunitLite's AreEquivalent () methods. 2014-03-08 16:11:36 -05:00
Alistair Bush eaa5a184ca Add test to ensure using concrete List as readonly property still serializes
This change is released under the MIT license.
2014-03-09 01:12:06 +13:00
Alistair Bush f3296a1559 When a read only property and the type is an interface we can't serialize the type.
This change is released under the MIT license.
2014-03-09 01:05:24 +13:00
Rodrigo Kumpera 8a0c516a7c [corlib] Fix the mobile profile. 2014-03-07 18:00:17 -05:00
Rodrigo Kumpera c40af3e9a0 [io-layer] Bionic doesn't have clock_nanosleep. 2014-03-07 18:00:17 -05:00
Zoltan Varga beb190172d [runtime] Make different kinds of delegate invokes use a different name. 2014-03-07 14:23:26 -05:00
Marek Safar 200682ac78 Update CLDR to version 2.4. Fixes #17615 2014-03-07 17:56:33 +01:00
Marek Safar 802bc45cae [corlib] Fix culture name constants in CreateSpecificCultureFromNeutral to be all lower case 2014-03-07 17:56:33 +01:00
Rodrigo Kumpera 7ca713e156 [sgen] Change the bridge interface to include richer type information on classes.
There is an additional axis to bridge processing than just if a type is a bridge or not.
It can be processing transparent or opaque.

We didn't make this distinction before and treated all types as transparent.

Opaque types means that bridge processing should stop at them. An opaque bridge, in
addition to that, means it should be reported in.

This change paves the way for bridge graph pruning.
2014-03-07 10:37:20 -05:00
Craig Minihan d4ea35a94a [Fix] Bugzilla #18245 - System.Runtime.MemoryCache.GetValues() throws LockRecursionException with expired items
- GetValues() calls MemoryCacheContainer.GetEntry() which now gets an EnterUpgradeableReadLock needed by ExpireIfNeeded()
- Added a test case
2014-03-07 04:40:23 -08:00
Michael Hutchinson e01250c2c7 Merge pull request #915 from knocte/master
xbuild: include a Microsoft.Portable.Common.targets file (for F#)
2014-03-06 16:57:18 -05:00
Marek Safar ea324fa5ea [system.net.htt[] Pass CancellationToken in GetAsync. Fixes #13281 2014-03-06 22:54:39 +01:00
Marek Safar 4b4ddb66b3 [corlib] Improve flow of ExecutionContext (few tests taken from https://github.com/mono/mono/pull/864). Fixes #18121 and similar. 2014-03-06 19:54:06 +01:00
Rodrigo Kumpera 0da40ef41b Merge pull request #936 from adahn/master
[runtime] Fixed flags for VirtualAlloc in mono_valloc (Windows)
2014-03-06 11:18:31 -05:00
Marek Safar bc1d754ec1 Merge pull request #866 from linquize/content-type-encoding
(master) If HTTP charset header is empty, do not append content encoding to Content-Type header
2014-03-06 17:07:27 +01:00
Adam Rzepka 5dc8b1cdff [runtime] Fixed flags for VirtualAlloc in mono_valloc (Windows) 2014-03-06 15:46:54 +01:00
Rodrigo Kumpera 00853025ec Merge pull request #934 from exony-craigminihan/bugzilla#17897-B
[Fix] Bugzilla #17897 - MemoryCacheEntryPriorityQueue throws out of boun...
2014-03-06 08:40:47 -05:00
Craig Minihan 58e399bb9b [Fix] Bugzilla #17897 - MemoryCacheEntryPriorityQueue throws out of bounds after shrink
- when MemoryCacheEntryPriorityQueue grows the timed items after a shrink
  the value of the member variable heapSize is wrong allowing an out-of-
  bounds exception which would normally be prevented by bounds tests
- A test case was added for the out-of-bounds exception
2014-03-06 02:46:49 -08:00
Zoltan Varga 865389c630 Disable the test-messages test on win32, its not needed. 2014-03-05 21:23:09 -05:00
Zoltan Varga 8d65a236c9 [runtime] Fix loaded llvm support. 2014-03-05 21:13:45 -05:00
Zoltan Varga cfabe7be1c [runtime] Disable MONO_XEN_OPT on windows. 2014-03-05 21:12:36 -05:00
Zoltan Varga 7070b4ab46 [jit] Implement the push/pop LMF code in IR on windows too. 2014-03-05 21:11:49 -05:00
Zoltan Varga b5523227a5 Really fix the build. 2014-03-05 19:15:40 -05:00
Zoltan Varga 03212f394f [runtime] Move some counters to the mono-counters infrastructure, to break dependencies between utils/ and metadata/. 2014-03-05 17:30:08 -05:00
Marek Safar 4a9ea4c37a [corlib] Parse datetime string using culture calendar. Fixes #18052 2014-03-05 23:26:16 +01:00
Zoltan Varga 5b258ea848 [runtime] Fix a memory leak. 2014-03-05 17:01:48 -05:00
Zoltan Varga c5f8c79486 [runtime] Fix a memory leak. 2014-03-05 16:41:56 -05:00
Zoltan Varga ac8ecaaea4 [runtime] Fix a memory leak. 2014-03-05 16:40:50 -05:00
Zoltan Varga 0c40a9856a [runtime] Implement wapi_process_get_path () on non osx platforms by falling back to get_process_name_from_proc (). 2014-03-05 15:49:49 -05:00
Zoltan Varga 0bbaa58f20 [sdb] Add some debug output to help track down #18100. 2014-03-05 14:41:15 -05:00
Zoltan Varga 0bdbf3f2ba Fix the build. 2014-03-05 14:33:09 -05:00
Marek Safar 0c35602a17 [corlib] Implement CultureInfo.ClearCachedData. Fixes #18162 2014-03-05 19:45:28 +01:00
Zoltan Varga ed16d69d4b [mdoc] Fix the tests. 2014-03-05 13:12:38 -05:00
Marek Safar 66aa46557b Merge pull request #931 from exony-craigminihan/bugzilla#18097
Correctly set Count after call to ConcurrentStack.PushRange()
2014-03-05 15:19:27 +01:00
Craig Minihan 7bc35e0a01 Correctly set Count after call to ConcurrentStack.PushRange() 2014-03-05 04:33:54 -08:00
Marek Safar 153692f609 Merge pull request #930 from theraot/master
New cast to double and float for BigInteger
2014-03-05 08:22:02 +01:00
Alex Rønne Petersen 7843622f2c Add a MONO_CONSERVATIVE_HWCAP environment variable.
Also a bit of cleanup in the hwcap code.
2014-03-05 07:44:23 +01:00
Alex Rønne Petersen fcbf89d2ad Add a MONO_DEBUG=suspend-on-exception option. 2014-03-05 07:44:15 +01:00
Zoltan Varga 243899a5bd [runtime] Launch managed exe's using the current runtime executable if possible. Fixes #17820. 2014-03-04 22:05:33 -05:00
Zoltan Varga 490ca4b751 Revert parts of 6769a30f4, it disabled the hand-specialized sort methods in the non-aot case instead of the aot case. 2014-03-04 18:41:42 -05:00
theraot df50c16760 [Fix] BigInteger: reimplemented cast to single (float)
- The new implementation casts to double and then to float.
2014-03-04 16:19:19 -05:00
theraot f2dd91de16 [Fix] BigInteger: improved cast to double
- Added overloads for PopulationCount and LeadingZeroCount that take ulong.
- Added helper method BuildDouble that constructs a double by sign, mantissa
  and exponent. This method truncates the mantissa, thus may differ in
  rounding to Math.Pow.
- The new implementation avoids Math.Pow by using BuildDouble.
- Passing all recently added tests.
2014-03-04 13:59:11 -05:00
theraot 7d23576855 BigInteger: more test cases for cast to double 2014-03-04 13:43:58 -05:00
Marek Safar 2f909cf433 [interpreter] Size reduction 2014-03-04 19:40:25 +01:00
Marek Safar 6f96d2d973 [mcs] Emit correct code for lifted nullable bool logical operators where left operand is not pre cached. 2014-03-04 18:34:31 +01:00
theraot f277bca903 BigInteger: added tests for double conversion 2014-03-04 11:28:34 -05:00
theraot 1868150cbe [Performance] BigInteger: cast to double and float
- The new implementation converts directly to double or float.
2014-03-04 11:14:01 -05:00
theraot 697c793e47 BigIngeter: new LeadingZeroCount helper method
- The new helper method LeadingZeroCount returns the number of bits
  that are set to 0 at the start of an uint.
2014-03-04 11:12:41 -05:00
Sebastien Pouliot 56d406876f [System.ServiceModel.Web] Fix regression when converting strings using some (like German) cultures [#18131] and add unit test 2014-03-04 09:00:36 -05:00
Marek Safar 9cbe9c372b [corlib] Seal InternalThread 2014-03-04 10:17:30 +01:00
Zoltan Varga 1e811b2c65 [runtime] Fix the cross-compiler build. 2014-03-04 00:05:42 -05:00
Zoltan Varga 9c1971cf9d [runtime] Fix a memory leak. 2014-03-03 22:26:16 -05:00
Zoltan Varga d1c6d5a164 [llvm] Create separate MonoLLVMModule and an LLVM execution engine for each appdomain so they can be freed when the appdomain is unloaded. Part of the fix for #18083. 2014-03-03 20:32:35 -05:00
Zoltan Varga 9968d23b8c Fix the build. 2014-03-03 16:22:02 -05:00
Zoltan Varga b28b84f05e [llvm] Remove some debug spew. 2014-03-03 15:04:52 -05:00
Zoltan Varga 9ed2e8e22e [llvm] Make the 'llvm_types' hashtable per-domain to fix memory leaks. 2014-03-03 14:54:00 -05:00
Zoltan Varga b1b7ef35b1 [jit] Add support for the new DUMMY_ opcodes to the arm backend. 2014-03-03 14:53:28 -05:00
Zoltan Varga 2e34a838d3 [llvm] Fix more memory leaks. 2014-03-03 14:49:11 -05:00
Zoltan Varga 1aa63665e6 [llvm] Fix a memory leak. 2014-03-03 12:58:22 -05:00
Zoltan Varga d8a94636ac [llvm] Fix a memory leak. 2014-03-03 12:50:47 -05:00
Marek Safar db84f82ecb [mcs] Mark switch statement block scope statements as reachable. Fixes #18092 2014-03-03 18:10:08 +01:00
Martin Baulig 93fe81b22e This is a .NET 4.5 test. 2014-03-03 17:35:38 +01:00
Zoltan Varga ff9d20e5b1 [jit] Add LLVM support for the new OP_DUMMY_ opcodes. 2014-03-02 17:16:16 -05:00
Zoltan Varga cf2aa3162e [jit] Avoid forcing initlocals to TRUE when the 'unsafe' optimization flag is set. Fixes #18068. 2014-03-02 17:06:24 -05:00
Jeffrey Stedfast 250756b5f5 Merge pull request #929 from edbprx/master
Data corruption using SslStream (Xamarin bug 15293)
2014-03-01 20:53:37 -05:00
Zoltan Varga eef1f283a6 [jit] Allow inlining of calls to method with the AggressiveInlining attribute in aot mode. 2014-02-28 20:06:13 -05:00
Zoltan Varga 2d77b39444 [jit] Fix an uninitialized memory problem in the soft-float code. 2014-02-28 19:52:39 -05:00
Zoltan Varga ea38ea330c [jit] Implement proper tail call support on arm. Fixes #17654. 2014-02-28 19:01:16 -05:00
Ed Boren ee17eca298 Data corruption using SslStream (Xamarin bug 15293)
When reading and writing data at the same time over an
System.Net.Security.SslStream, an exception will be thrown often.
Usually the exception is: Mono.Security.Protocol.Tls.TlsException “Bad
record MAC”

The issue is that the single TlsCipherSuite instance used for both
reading and writing does not synchronize access to the “header” member.
If the contents get corrupted the MAC calculation returned by
ComputServerRecordMAC or ComputeClientRecordMAC is incorrect.

See https://bugzilla.xamarin.com/show_bug.cgi?id=15293. Reproduced in
OS X, iOS and Windows.
2014-02-28 17:08:15 -05:00
Alex Rønne Petersen 510eae664c Fix a warning introduced by the boehm toggleref code. 2014-02-28 22:43:03 +01:00
Alex Rønne Petersen 830c5172c4 Merge pull request #927 from ermshiperete/novell-bug-708856
[MWF] Fix finding of X11 shared library on Ubuntu (#708856)
2014-02-28 22:29:51 +01:00
Alex Rønne Petersen af7ed330ae Properly fix the iowait_ticks / strtoull () warning in mono-proclib. 2014-02-28 22:18:58 +01:00
Zoltan Varga 476c90fe96 [llvm] Fix --enable-loadedllvm on osx/amd64. 2014-02-28 13:36:59 -05:00
Eberhard Beilharz 5a79253d67 [MWF] Fix finding of X11 shared library on Ubuntu (#708856)
When libX11-dev is not installed on an end-user's machine MWF apps
will crash in XCreateFontSet. This change uses dynamic search path
when building instead of hard coded directories when
searching for libX11.so.*. This fixes bug 708856
(https://bugzilla.novell.com/show_bug.cgi?id=708856).
2014-02-28 18:04:40 +01:00
Zoltan Varga 342418201c [runtime] Fix memory leaks and usage of freed memory in ves_icall_System_Net_Dns_GetHostByName_internal. Fixes #18063. 2014-02-28 11:31:49 -05:00
Tom Hindle 4813a70a29 [MWF] Fix hang if clipboard source application closes down (fixes #674098)
This change adds a timeout to the Clipboard.Enumerating loop, making a
hang less likely. This fixes Novell bug #674098
(https://bugzilla.novell.com/show_bug.cgi?id=674098).
2014-02-28 17:31:22 +01:00
Martin Baulig 51984e1631 Fix this again. 2014-02-28 17:27:16 +01:00
Eberhard Beilharz 049a349dae [Printing] Improve reported printer settings (Fixes #602934)
Report the actual values of the printer driver in printer settings
instead of using hard coded default values. This fixes Novell bug
#602934 (https://bugzilla.novell.com/show_bug.cgi?id=602934).
2014-02-28 16:45:46 +01:00
Eberhard Beilharz 4ee69bbd30 [Printing] Add unit test for Novell bug #602934
This unit test demonstrates the problem reported as #602934
(https://bugzilla.novell.com/show_bug.cgi?id=602934).
2014-02-28 16:36:26 +01:00
Marek Safar 9c4c295524 [corlib] Method signature fixes 2014-02-28 13:30:16 +01:00
Zoltan Varga fe3b21ae71 [corlib] Disable an OOM test which shouldn't fail on 64 bit machines. 2014-02-27 19:14:22 -05:00
Mark Probst ba9e1a26a8 [sgen] Fix cardtable for huge (>4gb) objects on 64bit.
We use an overlapping card table on 64 bits, meaning that the address
space wraps around our card table (every 4gb).  We had assumed in a few
places that an object could wrap around the end of the card table at most
once, but with objects larger than 4gb that is not the case.

Fixes the corlib test suite crash on OSX/64bit
(in SortedListTest.TestCapacity4).
2014-02-27 14:41:52 -08:00
Marcus von Appen 1870f70369 - Use the correct absolute path for relative paths within a rooted path 2014-02-27 20:48:26 +01:00
Martin Baulig 154272d7a6 NUnitLite does not know Assert.IsInstanceOfType(). 2014-02-27 20:39:22 +01:00
Zoltan Varga 10b3d70111 [runtime] Fix an assertion which is hit if thread_cleanup () is called for a thread after it has been finalized during shutdown. 2014-02-27 14:33:33 -05:00
Marek Safar dff86fe824 [corlib] Add missing api 2014-02-27 20:22:12 +01:00
Zoltan Varga e98625a6e3 [runtime] Switch the order of LLVM_LIBS and LLVM_LDFLAGS on the linker command line. Hopefully fixes #17931. 2014-02-27 13:32:50 -05:00
Zoltan Varga 42edc1dddb Revert "[runtime] Add support for jagged array ctors which create an array of arrays. Fixes #17944."
This reverts commit 2136f8f0bc.

Revert this as it breaks make check PROFILE=net_2_0 in corlib.
2014-02-27 12:36:37 -05:00
Eberhard Beilharz 0dd29f1e7f [Sys.Data] Fix Novell Bug #519648
Don't throw an exception when passing "new object[] {null}" to
DataRowCollection.Find. This makes the behaviour more compatible
with .NET. This fixes bug #519648
(https://bugzilla.novell.com/show_bug.cgi?id=519648).
2014-02-27 17:35:54 +01:00
Eberhard Beilharz 6505533785 [Sys.Data] Add unit tests for Novell bug #519648
These unit tests demonstrate the difference to .NET
(https://bugzilla.novell.com/show_bug.cgi?id=519648).
2014-02-27 17:33:06 +01:00
Marek Safar 2009c2284e Merge pull request #922 from ermshiperete/novell-bug-599689
Fix Novell bug 599689
2014-02-27 16:41:04 +01:00
Marek Safar 1642d39e9f Merge pull request #921 from ermshiperete/novell-bug-594490
Allow qualified names in XmlAttribute serialization
2014-02-27 16:40:11 +01:00
Eberhard Beilharz aa6842b2fc [Sys.Xml] Fix Novell bug #599689
This change fixes #599689
(https://bugzilla.novell.com/show_bug.cgi?id=599689) by making the
output of XmlSchemaException.ToString() match the output under .NET.
2014-02-27 16:33:08 +01:00
Martin Baulig 5011900cc3 Fix the mobile build.
On the mobile profile, System.Xml.Linq is signed with the winfx key, not
with the ecma one, so we need a different [assembly: InternalsVisibleTo].
2014-02-27 16:30:29 +01:00
Eberhard Beilharz 86164dac13 [Sys.Xml] Add unit test for Novell bug #599689
The unit test demonstrates a difference between Mono and .NET
(https://bugzilla.novell.com/show_bug.cgi?id=599689).
2014-02-27 16:28:08 +01:00
Neil Mayhew 43ccb972b4 [Sys.Xml] Allow qualified names in XmlAttribute serialization
This fixes Mono bug #594490
(https://bugzilla.novell.com/show_bug.cgi?id=594490).
2014-02-27 16:01:50 +01:00
Eberhard Beilharz c0ef1fcb02 [Sys.Xml] Add unit test for Novell bug #594490
The unit test demonstrates the problem of serializing the
xml:lang attribute.
2014-02-27 15:57:57 +01:00
Miguel de Icaza 89684c509a Merge pull request #912 from Treer/patch-1
[FIX] mono-xmltool can't write to a file when prettyprinting, and corrupts the input file.
2014-02-26 23:09:19 -05:00
Rodrigo Kumpera 5611946a30 [boehm] Integrate toggleref support into the runtime. 2014-02-26 18:07:28 -05:00
Rodrigo Kumpera ae15e93b92 [boehm] Add toggleref support for boehm. This is line by line port of the sgen code, so keep them in sync. 2014-02-26 18:07:28 -05:00
Zoltan Varga 2136f8f0bc [runtime] Add support for jagged array ctors which create an array of arrays. Fixes #17944. 2014-02-26 16:16:45 -05:00
Zoltan Varga cba20cd722 [jit] Move a debug message to a larger verbosity level. 2014-02-26 16:16:44 -05:00
Zoltan Varga 243cecfaf2 [runtime] Fix the --enable-loadedllvm build on linux. 2014-02-26 21:39:33 +01:00
Zoltan Varga 9ad06a3bf6 [bcl] Allow Marshal.SizeOf () to work on pointer types. Fixes #17587. 2014-02-26 15:14:39 -05:00
Zoltan Varga 3953bef4aa [runtime] Add a FIXME. 2014-02-26 14:53:47 -05:00
Mark Probst 484d5d0408 [runtime] Fix a thread join race condition. Fixes #18026. 2014-02-26 11:07:19 -08:00
Zoltan Varga b87d9f4a32 [runtime] Fix an assert if a thread cannot be created. Fixes #18000. 2014-02-26 13:41:58 -05:00
Rodrigo Kumpera 8bbaaa0c57 [sgen] Ensure togglerefs are only cleared after we proccess finalizers and CWT.
Clearing TRs before finalizers and CWT means user driver resurrection would fail
badly.
2014-02-26 12:24:35 -05:00
Zoltan Varga 2c64ed7866 [bcl] Fix System tests. 2014-02-26 12:00:48 -05:00
Martin Baulig 8f2d3ea31d HttpWebRequest: Only add "Content-Length" if we have a body; fixes #17736. 2014-02-26 15:49:25 +01:00
Marek Safar e511e29095 [System] Add NetworkCredential 4.0 construtors. Fixes #18005 2014-02-26 10:54:29 +01:00
Marek Safar 32317ae405 [dlr] Add interpreter increment emit 2014-02-26 10:44:51 +01:00
Michael Hutchinson 0246bd1729 [gacutil] Create correct relative package symlinks
BXC17951 - broken softlinks in mono/xbuild/12.0/bin
2014-02-25 19:32:25 -05:00
Zoltan Varga 6124460628 [runtime] Remove the usage of pthread_cleanup_push/pop functions from io-layer code. 2014-02-25 19:03:51 -05:00
Zoltan Varga 7f0b4dc545 Merge pull request #914 from eiz/master
Fix memory leak.
2014-02-25 17:55:09 -05:00
Alexander Köplinger f9c6ed950e [MSBuild] Fixed a test that failed when the GAC wasn't available
The test tried to resolve an assembly from the GAC, which doesn't work on a
clean machine without an existing Mono installation.
We now check if the GAC directory is missing and ignore the test in that case.
2014-02-25 21:21:10 +01:00
Martin Baulig c4941b96b6 Oops, fix the build. 2014-02-25 19:11:05 +01:00
Martin Baulig 2d573ae1ce [Sys.Xml]: Allow XElement to be deserialized; fixes #12571. 2014-02-25 18:59:29 +01:00
Martin Baulig 42c568fb11 [System]: Split WebClient.UploadData() data into chunks and fire the event.
This is mostly cosmetic and won't help unless you're sending a very large
buffer due to the kernel's internal buffering.  Unfortunately, there is no
way of getting a notification when the data has actually been sent over the
wire - socket.Write() returns after the kernel has accepted the data.
2014-02-25 18:59:20 +01:00
Martin Baulig faaa8a7c94 Async-ify the remaining WebConnectionStream pieces. 2014-02-25 18:57:30 +01:00
Zoltan Varga 190bd17354 [runtime] Fix the arm build. 2014-02-25 11:54:38 -05:00
Alex Rønne Petersen f759f1eef1 Merge pull request #913 from Daniel15/fix-catchall-routing-master
Fix routing of CatchAll tokens (Bug #17960) - on master
2014-02-25 17:52:21 +01:00
Paolo Molaro 57ade9dfca Added new API mono_runtime_set_main_args() and fixed CommandLine for embedders.
The new API allows to set the program arguments from embedders that don't call
mono_jit_exec() and related functions that set them automatically. This change
also fixes the NullRef exception that would happen if the arguments are not set.
2014-02-25 17:43:08 +01:00
Miguel de Icaza a871be7826 Add documentation for CFNetworkHandler 2014-02-25 11:43:01 -05:00
Zoltan Varga 2027961a5c Fix the build. 2014-02-25 11:38:46 -05:00
Miguel de Icaza 92beedb3a0 Add System.Net.Http documentation 2014-02-25 11:29:27 -05:00
Andrés G. Aragoneses 76d4e2ad1e xbuild: include a Microsoft.Portable.Common.targets file (for F#)
F# PCL projects expect this file to exist in:
$(MSBuildExtensionsPath32)\Microsoft\Portable\$(TargetFrameworkVersion)\Microsoft.Portable.Common.targets

So in order to avoid pristine F# PCL projects (created from VS) fail
the build that file has to exist, and import the Core targets like
its CSharp counterpart (Microsoft.Portable.CSharp.targets) does.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=17906
2014-02-25 13:10:29 +01:00
Mackenzie Straight f657c5c5f4 Fix memory leak.
Introduced in b322a6e410. variance_used
was not being set before use, resulting in leaked trampolines when
calling methods on variant interfaces.
2014-02-25 04:05:04 -05:00
Miguel de Icaza d28e7b7955 [System.Runtime.Serialization] Fix from Brendan Zagaeski for bug #17663 2014-02-24 21:16:29 -05:00
Miguel de Icaza a195d21e04 [runtime] some inline api docs 2014-02-24 21:14:05 -05:00
Rodrigo Kumpera ba5aecb347 [sgen] Ensure minor_collection_allowance is always initialized. This avoid a spurious GC on startup. 2014-02-24 18:35:06 -05:00
Rodrigo Kumpera fba337b499 [sgen] Add regression test for toggleref transient marking bug. 2014-02-24 18:35:06 -05:00
Rodrigo Kumpera 362b3cc059 [sgen] Split mark/clean phase of sgen-toggle processing to account for transitive liveness.
Given two TG objects A and B. A is strong, B is weak, A points to B. B should remain registered
for TG processing since it's reachable thru A.

This means we have to split processing in multiple steps. Phase one marks all strong refs that should
happen before finalizer processing and phase two that happens after finalizers that cleanup those
that turned unreachable.
2014-02-24 18:35:05 -05:00
Rodrigo Kumpera 93f3bdf944 [sgen] We must do bridge processing with all sgen locks taken. 2014-02-24 18:35:05 -05:00
Rodrigo Kumpera a30838160e [sgen] Add internal test helper for sgen-toggleref. 2014-02-24 18:35:05 -05:00
Zoltan Varga 3114a6561a [runtime] Fix reading invalid memory during some checks for remoting types. 2014-02-24 17:25:39 -05:00
Zoltan Varga ce43afaee2 [runtime] Fix a memory leak. 2014-02-24 17:25:39 -05:00
Marek Safar 706426c3a2 [mcs] Don't report internal error for unresolved catch type. Fixes #17975 2014-02-24 23:08:16 +01:00
Zoltan Varga a1ee26a7c8 [runtime] Fix the order of how we fix types during appdomain unload. Fixes #17977. 2014-02-24 16:30:52 -05:00
Marek Safar 7632747636 [corlib] Simplify ambiguous chinese legacy name check 2014-02-24 21:59:10 +01:00
Zoltan Varga a1f8b20f20 [runtime] Export mini_type_is_vtype on linux as it is needed by the loaded llvm module. 2014-02-24 21:20:40 +01:00
Zoltan Varga e040f62eff [aot] Add support for encoding method addresses using call instructions on x86/amd64 as well, not enabled. 2014-02-24 14:41:34 -05:00
Zoltan Varga 98a57b7e67 [jit] Fix mono_arch_get_call_target () on x86/amd64. 2014-02-24 14:41:33 -05:00
Daniel Lo Nigro 627e902c8d Fix routing of CatchAll tokens 2014-02-24 10:11:47 -08:00
Rodrigo Kumpera 9e8ecbc553 Fix the version string. 2014-02-24 11:53:45 -05:00
Marek Safar adb82c8bb0 [mcs] Simplify array element initializer load 2014-02-24 16:01:22 +01:00
Marek Safar 9cf471386b [mcs] Release array stack variable once all elements are initialized. Fixes #17942 2014-02-24 16:01:21 +01:00
Treer 18201dd3e9 xmltool.cs fix for writing output to files
A bug in argument handling meant that "mono-xmltool --prettyprint source.xml dest.xml" fails to write dest.xml and erases the contents of source.xml
2014-02-24 21:01:18 +11:00
Marek Safar 28243cc0e4 Merge pull request #910 from akoeplinger/cleanup-test-ignores
[Test] Cleaned up how a bunch of tests were ignored
2014-02-24 08:46:23 +01:00
Alexander Köplinger b0032294da [Test] Cleaned up how a bunch of tests were ignored
Previously, many tests just had a return statement when the test shouldn't
be executed (e.g. Unix-only). This made it look like the test was successful
when in fact it wasn't executed at all.
Assert.Ignore() is now used instead to correctly exclude those tests.
2014-02-23 19:44:21 +01:00
Atsushi Eno 06502ec1e9 [msbuild] for EmbeddedResource naming, take AutoGen property into consideration. 2014-02-23 23:36:02 +09:00
Miguel de Icaza c86473c2ba Work around DNS problem on the build hosts 2014-02-21 18:09:36 -05:00
Rodrigo Kumpera ed2d8f0b60 Merge pull request #908 from madewokherd/mingw-build
Avoid a POSIX include on Windows.
2014-02-21 17:48:19 -05:00
Vincent Povirk 5d89c7ccad Avoid a POSIX include on Windows.
This commit licensed as MIT/X11.
2014-02-21 16:41:13 -06:00
Zoltan Varga 7f8a9abb17 [jit] Add more comments about why the 'dse' llvm optimization is disabled. 2014-02-21 16:21:45 -05:00
Zoltan Varga c198a393b4 Fix bootstrap with older mono versions. 2014-02-21 13:57:15 -05:00
Sebastien Pouliot bc0900537c [System] Enable WebSockets on the mobile profile. Update related unit tests to run on mobile (and fix one to build with NUnitlite) 2014-02-21 13:41:57 -05:00
Mark Probst 1a662679aa [runtime] Fix build on Linux. 2014-02-21 10:22:26 -08:00
Zoltan Varga 47a274c3d5 [runtime] More io-layer threading cleanups. 2014-02-25 17:38:53 -05:00
Zoltan Varga c58749d1e8 [runtime] Get rid of the _wapi_thread_signal_self () function. 2014-02-25 17:21:51 -05:00
Zoltan Varga b6732f5a98 [runtime] Get rid of the unused _wapi_thread_dispatch_apc_queue () function. 2014-02-25 17:13:24 -05:00
Zoltan Varga 55fe4ac0a4 [runtime] Get rid of OpenThread (), move its functionality to mono-threads.c. 2014-02-25 17:09:32 -05:00
Zoltan Varga 2fed14d6ef [runtime] Allocate code chunks next to each other if possible to prevent vm fragmentation when they are freed during domain unloading. Fixes #17987. 2014-02-25 17:05:26 -05:00
Zoltan Varga 269879d6cd [runtime] Align sizes before aligning them to pagesize in the code manager to avoid allocating blocks which are larger than they should be. 2014-02-25 17:00:23 -05:00
Zoltan Varga d962b11e1b Fix a warning. 2014-02-25 16:21:20 -05:00
Zoltan Varga 4e012c326d [runtime] Fix SleepEx () on linux to clock_nanosleep () to work around time drifting caused by interrupts. 2014-02-25 16:20:01 -05:00
Marek Safar c83e56292d [System.Runtime.Caching] Fix ambiguous method call 2014-02-21 09:27:30 +01:00
Zoltan Varga 5065dab960 [runtime] Simplify the io-layer threading code a bit more. 2014-02-20 19:31:50 -05:00
Miguel de Icaza 22a4103091 [style] comment style updated 2014-02-20 19:12:08 -05:00
Rodrigo Kumpera 51d57122ef Add missing file I forget. Fix the build. 2014-02-20 18:24:38 -05:00
Rodrigo Kumpera 2d97048024 [runtime] Add an additional to detect thread death on Mach that happens even further in the cleanup process. 2014-02-20 18:11:01 -05:00
Zoltan Varga 426c784f50 [runtime] Disable DEBUG_DOMAIN_UNLOAD which was enabled by mistake. Fixes #17805. 2014-02-20 17:51:45 -05:00
Zoltan Varga e7c8bb12a5 [runtime] Get rid of the wapi_thread_interrupt_self () and the has_apc flag, it doesn't seem to be needed. 2014-02-20 17:07:20 -05:00
Marek Safar 2f076e3b2d Merge pull request #907 from enricosada/era_names
fix DateTimeFormatInfo era names
2014-02-20 21:28:09 +01:00
Zoltan Varga 6ecbeb2c2f Fix a warning. 2014-02-20 15:17:03 -05:00
Rodrigo Kumpera cff7efdb32 [runtime] Use the system limit when enforcing a new thread stack size. Fixes #17908. 2014-02-20 15:04:18 -05:00
Marek Safar eb04c47aa1 [mcs] Cleanup tie-breaking rules of better function member. Fixes #17755 2014-02-20 20:34:46 +01:00
Zoltan Varga 6d95657a21 [corlib] Remove the stack size limit check from CheckStackSize (), it should be possible to create larger stacks than the default. Fixes #17908. 2014-02-20 12:12:31 -05:00
Zoltan Varga 859f0ac73a [jit] Precompute a bit more information for delegate trampolines to speed them up. 2014-02-20 11:02:06 -05:00
Atsushi Eno 4139e7e658 When comparing string expressions, A, "A" and 'A' should be regarded as equivalent. 2014-02-20 18:23:03 +09:00
Atsushi Eno c57e14c21c Fix item expression parsing, indexes were wrong to parse after "->" . 2014-02-20 18:23:02 +09:00
Atsushi Eno 295ea83b32 ITaskItem.GetMetadata() implementations should not return null, but return "". 2014-02-20 18:23:02 +09:00
Atsushi Eno 25310c5561 Now our MS.Build.dll behaves like MS.Build.Engine.dll, replace \ with / at expansion time for everything.
Some MSBuild targets premises \ to work just like a path separator, and they
cannot be logically distinguished from any possible "normal" use of '\'.
(Except for escaped strings, which is why this change replaces \ with / after
expanding strings.)

I have added another override for NormalizeFilePath() and rather renamed old
one that works as file lookup, but there is no obvious difference in use.
They may be unified later to bring less confusion.
2014-02-20 18:23:01 +09:00
Atsushi Eno ce374a5817 Task load failures should not result in build errors, should be just warnings. 2014-02-20 18:22:41 +09:00
Atsushi Eno 8140531d91 Fix ElementLocation.File to NOT contain file URI, and then load task assembly from correct paths. 2014-02-20 18:22:40 +09:00
Atsushi Eno 03fc8b7fd9 UsingTasks are not collected expectedly when imports are involved. 2014-02-20 18:22:40 +09:00
Atsushi Eno d7702ec671 do not try to load assembly with empty string specification. Add tests for import/usingTask ordering.
One of the tests fail because we actually fail to pick up imported UsingTasks.
2014-02-20 18:22:23 +09:00
Atsushi Eno b3087090a6 Make sure to override existing ProjectPropertyInstance values when new decl. arrives. 2014-02-20 18:22:22 +09:00
Atsushi Eno 459b986b1c There is no local scope for properties and items that can be defined in a Target. 2014-02-20 18:22:22 +09:00
Atsushi Eno 92a1a5a008 remove some MonoTODOs. 2014-02-20 18:22:21 +09:00
Atsushi Eno c9122d4cba In a Project, Target can be overriden by another one with the identical name. 2014-02-20 18:22:21 +09:00
Jonathan Pryor 5597172dec [runtime] Add a "mobile" runtime version.
Xamarin.Android has historically used the "v2.0.50727" runtime
version -- which works -- but has the side effect that Mono constantly
generates runtime "warnings" akin to:

	The request to load the assembly mscorlib v2.0.5.0 was remapped to v2.0.0.0

The reason for this is that all of the Xamarin.Android assemblies have
the version number v2.0.5.0, while the "v2.0.50727" runtime version
expects assemblies to have version number v2.0.0.0; they differ.

Result: Mono warns (appropriately), and I do my best to ignore the
~meaningless warning message. (For years and years and years...)

It's time we fixed this.

Introduce a "mobile" runtime version which specifies the
Xamarin.Android v2.0.5.0 assembly versions. Xamarin.Android 4.14+ will
then specify the "mobile" runtime version, "fixing" the assembly remap
messages.
2014-02-19 22:22:14 -05:00
Enrico Sada fe489824b2 fix DateTimeFormatInfo era names
Calendar.Eras values start from 1 (1 = oldest)
As parameter of GetEraName or GetAbbreviatedEraName, era 0 mean current
era
2014-02-20 03:40:23 +01:00
Alex Rønne Petersen 5ff25684da Merge pull request #906 from kelly-linden/master
Add msvc/mono.props to EXTRA_DIST so make dist will find it.
2014-02-20 01:26:57 +01:00
Kelly eb0344c34f Add msvc/mono.props to EXTRA_DIST so make dist will find it. 2014-02-19 16:23:24 -08:00
Zoltan Varga 04a08edc14 Fix a warning. 2014-02-19 16:14:20 -05:00
Zoltan Varga 6295df5208 [jit] Optimize mono_merge_basic_blocks () for large methods. 2014-02-19 15:26:45 -05:00
Zoltan Varga e44f11191a [jit] Fix a crash when using -v -v -v -v with dynamic methods. 2014-02-19 15:26:45 -05:00
Aaron Bockover 494b4d6395 mono-api-html: ignore members using regex, add detailed help 2014-02-19 14:22:44 -05:00
Aaron Bockover 1f01ada267 mono-api-html: support ignoring added members
Use Mono.Options as well.
2014-02-19 14:22:44 -05:00
Rodrigo Kumpera 676ef96431 [bcl] Fix test suites. 2014-02-19 14:19:35 -05:00
Rodrigo Kumpera 8f4609ffe3 Bump version. 2014-02-19 14:13:01 -05:00
Zoltan Varga 08eb1124d8 [jit] Fix the stack cleanup during EH on x86 when LLVM is enabled. 2014-02-19 13:16:30 -05:00
Marek Safar 5fd43ffcb3 Add failing Uri test 2014-02-19 18:03:51 +01:00
Marek Safar da666f3aa0 [System] Kill some Uri static fields 2014-02-19 18:03:51 +01:00
Rodrigo Kumpera 8c33ccc896 Merge pull request #903 from simonhartmann/master
Bug 17838 - IDictionary item property implemention for ConcurrentDiction...
2014-02-19 11:59:49 -05:00
Simon Hartmann 11b5312c83 Bug 17838 - IDictionary item property implemention for ConcurrentDictionary/SortedList_T throws exception on non-existing key
Avoid double lookup for Dictionary IDictionary.get_Item property impl
2014-02-19 16:40:57 +01:00
Sebastien Pouliot 669d6a4561 [SSL/TLS] Fix typo to build when INSIDE_SYSTEM is defined 2014-02-19 09:54:30 -05:00
Marek Safar 651fc6a289 [System.Net.Http] Return ContentLength of the buffer when content is loaded into a buffer in request handler. Fixes #17861 2014-02-19 15:30:42 +01:00
Marek Safar f2f4e366b4 Merge pull request #905 from AxlPr/master
Fixed time out on HTTP redirects
2014-02-19 15:09:00 +01:00
Sebastien Pouliot ee2a498b05 [SSL/TLS] Update tlstest tool to build with 4.5 and to use/filter the client cipher suites 2014-02-19 08:51:52 -05:00
Sebastien Pouliot 43fcd744d0 [SSL/TLS] Expose Client/Server callbacks that can be used to select/reorder SSL/TLS cipher suites used (for client or server) and add unit tests for them [#16327] 2014-02-19 08:51:51 -05:00
Sebastien Pouliot 0af984a39b [SSL/TLS] Add support to select and/or re-order ciphers suites [#16327] 2014-02-19 08:51:51 -05:00
Sebastien Pouliot ec565240cf [System] Add new NET_4_5 values for SslProtocols enum 2014-02-19 08:51:51 -05:00
AxlPr b3ae7c6d11 Fixed time outs on http redirects
Fixed bug introduced by change 6ab86f50fd
where http request times out when it encounters a redirect.
2014-02-19 13:27:22 +00:00
Martin Baulig da6c88b49b [System] WebConnection and WebConnectionStream code cleanups.
* Merged WebConnection.EndWrite() and EndWrite2().

* WebConnectionStream.BeginWrite(): Use the same async-write
  callback for both chunked and non-chunked; remove the single-use
  small WriteRequestAsync() and inline it here to make the code
  more readable.

* WebConnectionStream.WriteRequestAsyncCB(): Now called for all
  async writes, call WebConnection.EndWrite() here.

The code is now more readable and easier to understand.  This is
the first part of a series of cleanups, which should eventually
lead towards full async and 100-continue.
2014-02-19 11:08:18 +01:00
Alex Rønne Petersen 0570fc0be4 Fix some warnings on !MONO_ARCH_AOT_SUPPORTED targets. 2014-02-19 03:43:27 +01:00
Alex Rønne Petersen ab73ddab6f Fix another mips32 warning. 2014-02-19 03:34:48 +01:00
Alex Rønne Petersen 07e74e129d Fix some warnings on mips32. 2014-02-19 03:19:08 +01:00
Michael Hutchinson d562f82d8f [xbuild] Exists should be false for empty values
BXC17802 - xbuild evaluates Exist wrongly when the item group does not exist
2014-02-18 18:25:39 -05:00
Alex Rønne Petersen 254954dc09 ARM: Emit shorter floating point load/store sequences when possible. 2014-02-18 23:22:55 +01:00
Alex Rønne Petersen f485233168 ARM: Handle large offsets in emit_float_args (). 2014-02-18 23:22:53 +01:00
Alex Rønne Petersen b0467a0c17 ARM: Back up VFP scratch registers before using them on hard float.
This is because d0-d7 are argument registers and d8-d15 are
preserved registers - we can't use any of them as scratch
registers without restoring their previous values.
2014-02-18 23:22:51 +01:00
Michael Hutchinson dadacb5421 [xbuild] Really don't local-copy mscorlib 2014-02-18 16:59:37 -05:00
Rodrigo Kumpera 3df3899e4b [runtime] Fix the linux build. 2014-02-18 16:36:20 -05:00
Marek Safar c4289c7764 [corlib] Change AggregateException get base exception to not rely on base GetBaseException 2014-02-18 22:33:01 +01:00
Marek Safar 268a8fbbaf [corlib] Remove unreliable test check 2014-02-18 21:41:16 +01:00
Michael Hutchinson 4f025a381c [xbuild] Clean up some API to match .NET
Some .NET 4 API had leaked into .NET 2 builds.
2014-02-18 12:04:23 -05:00
Michael Hutchinson ec7288ea3c [xbuild] Fix accidental local-copy of mscorlib
s
2014-02-18 12:04:21 -05:00
Michael Hutchinson 0396f3b1c3 [xbuild] Fix PCL 4.5 targets 2014-02-18 12:04:19 -05:00
Sebastien Pouliot 07d043e37c [Test] Fix previous test change as the test is dependent on line numbers 2014-02-18 10:49:25 -05:00
Sebastien Pouliot 1088183741 [Test] Avoid StackFrameTest.* failures when debugging symbols are not available (e.g. release configuration on iOS or Android) 2014-02-18 08:44:29 -05:00
Sebastien Pouliot d34c9297d1 [Test] Avoid MethodInfoTest.GetMethodBody failure when executed on a release (IL stripped) application on iOS 2014-02-18 08:44:28 -05:00
Sebastien Pouliot 2a81c70eaa [Test] Change FileTtest.MoveTest to use the temporary directory so it can be executed, without an access denied, on most environment (e.g. an iOS device) 2014-02-18 08:44:28 -05:00
Marek Safar a0173a7e76 Merge pull request #901 from Blewzman/FixAggregateExceptionGetBaseException
Add [Category ("NotWorking")] to failing test.
2014-02-18 11:42:47 +01:00
Blewzman a416234759 Add [Category ("NotWorking")] to failing test. 2014-02-18 10:22:54 +01:00
Alex Rønne Petersen 4d2de5c6ab Merge pull request #898 from UCIS/patch-3
Prevent exception in finalization of Form class
2014-02-18 03:41:27 +01:00
Alex Rønne Petersen 1a83c6ed5b Merge pull request #899 from UCIS/patch-4
Fix error in ToolStripItem finalization
2014-02-18 03:41:02 +01:00
Zoltan Varga 3f72288f57 [llvm] Disable the 'dse' optimization pass as it is buggy and causes #17616. Fixes #17616. 2014-02-17 18:34:26 -05:00
Rodrigo Kumpera a2c41c347f [runtime] Add two variants of mono_gc_bzero and mono_gc_memmove. They better convey the behavior we need.
After reviewing all usage of mono_gc_bzero and mono_gc_memmove, I found that there are two usage patterns
we care for:

1)Aligned pointer, any size, have managed pointers.
This happens when directly dealing with managed objects like when cloning of boxing.
On this case, all pointers MUST be aligned.

2)Maybe aligned pointer, any size, might have managed pointers.
This happens for functions dealing with structs, specially around boxing and unboxing them.
Our data layout code ensures that structs with managed layout are aligned to at least a word.
This means that if the pointer is unaligned, no managed pointer can exists in the memory range
been processed.

Given those two scenarios, lets introduce two variants that enforce those constrains.

_aligned:
Pointers must be aligned, ensures atomicity of word copies;

_atomic:
If pointers are aligned, works like _aligned, otherwise it inherits the behavior of the
system memmove&memset.

The above split ensures we won't have to deal with any RISC unaligned load nonsense.

It also adds some sanity checks to code that must respect alignment.

We still need fast code for mono_gc_memmove_aligned and mono_gc_bzero_aligned.

We still need to verify if a version of memcpy version is needed. Maybe the extra
branch is not such a perf penalty.
2014-02-17 17:03:56 -05:00
Marek Safar 5ad1099341 Merge pull request #900 from Blewzman/FixAggregateExceptionGetBaseException
Add unit test for AggregateException.GetBaseException that works on .net but is broken on Mono.
2014-02-17 17:56:55 +01:00
Blewzman a163bb7197 Add unit test for AggregateException.GetBaseException that works on .net but is broken on Mono. 2014-02-17 17:07:26 +01:00
Marek Safar 3646f687fe [mcs] Add NamespaceExpression to avoid problems with error location for misused namespaces. Fixes #17803 2014-02-17 16:37:30 +01:00
Rolf Bjarne Kvinge fff8231165 Properly preserve VPF registers in iOS. Fixes #17793. 2014-02-17 15:52:24 +01:00
Marek Safar 3f08ba83cc [mcs] Add nested types handling to check whether types unify for some type parameter substitutions. Fixes #17647 2014-02-17 11:15:34 +01:00
Marek Safar 657b95a863 Merge pull request #891 from DavidKarlas/listenerprefix
HttpListener now listens on default ports if not specified instead of random
2014-02-17 11:12:04 +01:00
Marek Safar eeeab3446f [corlib] Throw CultureNotFoundException using invariant culture. Fixes #17690 2014-02-16 18:11:46 +01:00
David Karlaš eaed50c0a2 HttpListener now listens on default ports if not specified instead of random 2014-02-16 04:58:32 -08:00
Zoltan Varga 50685c9733 Revert "[jit] Implement OP_CARD_TABLE_WBARRIER on ios."
This reverts commit b3f36681c7.

Revert this as it breaks mt.
2014-02-14 19:06:42 +01:00
Zoltan Varga 9c8a0eb7a1 Revert "[jit] Fix a regression introduced by b3f36681c72a6900cd5e9df9b593d555b351669f."
This reverts commit d50c836721.

Revert this as d50c836721 breaks mt.
2014-02-14 19:06:42 +01:00
Marek Safar 4447979d51 Fixes commit a63d0009af 2014-02-14 17:40:09 +01:00
Marek Safar a63d0009af [corlib] Unicode numbers are not considers valid in number parsing. Fixes #17628 2014-02-14 17:36:26 +01:00
Marek Safar f6eb2fc9ff [corlib] Fix warnings 2014-02-14 16:25:29 +01:00
Marek Safar 1abe31f994 [corlib] Improve TimeSpan custom formatting. Fixes #17699 2014-02-14 11:55:52 +01:00
Joao Matos eefbe2d246 Fixed incomplete decompression bug in System.IO.Compression.DeflateStream.
Call zlib's inflate() even if no data was read from the stream, there might still be some data left to process.

Originally reported by Eric Roller, as Xamarin bugzilla #17183.
https://bugzilla.xamarin.com/show_bug.cgi?id=17183

Reviewed by Rodrigo Kumpera.
2014-02-13 16:52:55 -05:00
Marek Safar 27feeb5a9a [corlib] Reset List enumerator current field. Fixes #17760 2014-02-13 22:26:13 +01:00
Marek Safar ceb62fdbe8 Fix typo 2014-02-13 22:13:30 +01:00
Marek Safar 8d40cb5b9c [system] Fix valid sorted set operations which could cause underlying tree modification 2014-02-13 19:59:56 +01:00
Marek Safar 831db4e0db [mcs] Imported methods need to have SpecialName flag to be valid C# operators 2014-02-13 19:59:56 +01:00
Marek Safar 049477004e Tests update 2014-02-13 19:59:56 +01:00
Martin Baulig 5e03c107bc Put back and fix the SSL async patch.
Revert "Revert "Merge pull request #829 from symform/httpwebreq-async-ssl""

This reverts commit 56d9a057eb, which was a
revert of 35899c07ff, thus putting 35889 back.
2014-02-13 18:48:16 +01:00
Marek Safar 1451cd9bce [mcs] Lift any non-nullable operand under runtime binder for lifted binary operation 2014-02-13 17:21:20 +01:00
Rodrigo Kumpera da2fe7195c Merge pull request #897 from echampet/scanbuild
Scanbuild
2014-02-13 11:02:09 -05:00
Martin Baulig 4b5f5f96c8 [System]: Reset NTLM auth state when redirecting; distinguish host and proxy. 2014-02-13 15:48:44 +01:00
Martin Baulig c6a70a9586 Rewrite and fix the web stack's connection reuse and idle logic.
* ServicePoint now uses an idle timer to close idle connections.

* WebConnectionGroup has been mostly rewritten to use a linked
  list of open connections and their idle times.

  This fixes both the problem that we were leaking sockets and
  that we were not reusing existing connections.

* ServicePoint now correctly keeps track of the number of open
  connections.

* ServicePointManager now uses the correct default idle time
  of 100 seconds (previously 15 minutes).

* WebConnection uses the new WebConnectionGroup's busy logic
  to correctly flag connections as busy / reusable.
2014-02-13 14:17:14 +01:00
Martin Baulig 861d495951 Fix WebConnectionStream.CheckComplete() logic for chunked encoding. 2014-02-13 13:22:19 +01:00
Rodrigo Kumpera a89b144a7d [corlib] Fix the 4.5 test suite. 2014-02-12 19:12:03 -05:00
Rodrigo Kumpera 21223d89c1 [runtime] Initialize param_count under DISABLE_JIT 2014-02-12 19:00:30 -05:00
Rodrigo Kumpera b4eaff51c0 [runtime] Don't abort on null module scope, there's nothing special to do there. Fixes #5835.
The defacto behavior of a null module scope is to resolve in the current image.
2014-02-12 18:53:10 -05:00
Rodrigo Kumpera 4072c020e1 [corlib] Remove obj_address debug helper, if anyone needs this, it can be done with overlapping fields. 2014-02-12 18:53:10 -05:00
Rodrigo Kumpera 51d2b75664 [corlib] Fix 4.0 test suite compilation. 2014-02-12 18:53:10 -05:00
Miguel de Icaza 3071b20dc5 Add test for Bug #15572 from pull request #820 2014-02-12 16:06:32 -05:00
Miguel de Icaza 1d1f618de4 Add tests for bug #15574, pull request 819 2014-02-12 15:39:24 -05:00
Miguel de Icaza dc186cf9ef Add tests for bug #15574, pull request 819 2014-02-12 15:39:24 -05:00
Miguel de Icaza c39718bbb3 Merge pull request #820 from brendanzagaeski/master
Bug 15572. Lookup KnownTypeCollection element types in MSSimpleNamespace
2014-02-12 15:31:12 -05:00
Miguel de Icaza 424595ea70 Merge pull request #819 from brendanzagaeski/patch-1
Bug 15574. XML deserialization recursion: add array type to known_types?
2014-02-12 15:30:30 -05:00
Miguel de Icaza e2812813f9 Merge pull request #796 from alesliehughes/master
Support for DispIdAttribute in GetIdsOfNames
2014-02-12 15:29:39 -05:00
Miguel de Icaza b57fcaa28b Merge pull request #778 from cmorris98/master
SqlBulkCopy Implementation
2014-02-12 15:25:59 -05:00
Miguel de Icaza 2cf74970a1 Merge pull request #835 from HorstKakuschke/master
Fixes Xamarin Bug 16742:  XmlConvert.ToDateTime(string, XmlDateTimeSeria...
2014-02-12 15:24:11 -05:00
Michael Hutchinson e753ca24e8 [xbuild] Fix dependency in C# targets
There was a typo in DependsOnTargets attribute of the
_AddCorlibReference target definition. It didn't break any
behaviour, since the target it depended on was always built
earlier in the build anyway, so it was really a sanity check.

However, it broke the tests for the new (unused) engine,
Microsoft.Build.dll, which checks for unexpected attributes.
2014-02-12 14:19:30 -05:00
Zoltan Varga 01ade94f36 Revert "[jit] Align the stack in mono_arch_restore_context () on x86 since it might be unaligned if it was captured asynchronously."
This reverts commit 7798b94706.

Revert this as it breaks debugging on android/x86 (#17410).
2014-02-12 20:11:35 +01:00
Miguel de Icaza 040ba8b7e8 [mscorlib] Path: fix GetFullPath (/../bin/bash) to return /bin/bash, not bin/bash, fixes 17083 2014-02-12 13:19:31 -05:00
Miguel de Icaza a2339679bc [HttpListener] Only bind to the specified hosts (and support '*' as Any), fixes #17204, #10818 2014-02-12 12:08:10 -05:00
Michael Hutchinson c1974786ca [xbuild] Fix 2.0 tests to handle mcs sdk argument 2014-02-12 12:04:59 -05:00
Miguel de Icaza 52e252bd1d [Uri] Fix the ParserUser feature of UriParseComponents
The current implementation was wrong, did not bother with pct-encoding
(despite being listed in the comments) and did not use the actual set
of characters listed on the spec, instead of using a white-list, it
had its own incorrect black-list.
2014-02-12 11:08:12 -05:00
Miguel de Icaza 847e71fdfe #17636: Allow Int32.Parse with/AllowExponents to take negative exponents. This is a change in behavior from 2009, when we fixed this: Novell#542464, now we match .NET 4.5 2014-02-12 09:32:23 -05:00
Miguel de Icaza f3fc0bb865 [DataAnnotation.Validator] Add support for nullable types, patch from [email protected], fixes #17318 2014-02-11 22:02:25 -05:00
Miguel de Icaza f2565054d5 WebRequest: Provide stub ImpersonationLevel
The old implementation threw an exception requesting that the method be implemented
in a derived class, but the method is not virtual, so it could have never been
implemented.

Since Mono does not support this, at least we keep the token around and avoid
throwing.
2014-02-11 21:53:44 -05:00
Ivo Smits 67a30ef5de Fix error in ToolStripItem finalization
The Dispose function in ToolStripItem should not remove itself from its owner during finalization. Finalization implies that the owner has also been garbage collected, and accessing it may result in undesirable behaviour. More specifically, the call to owner.Items.Remove ultimately may boil down to a call to GDI+ throwing an Exception like the following:

Program.UnhandledException: System.ArgumentException: A null reference or invalid value was found [GDI+ status: InvalidParameter]
  at System.Drawing.GDIPlus.CheckStatus (Status status) [0x00000] in <filename unknown>:0 
  at System.Drawing.Graphics.GdipMeasureString (IntPtr graphics, System.String text, System.Drawing.Font font, System.Drawing.RectangleF& layoutRect, IntPtr stringFormat) [0x00000] in <filename unknown>:0 
  at System.Drawing.Graphics.MeasureString (System.String text, System.Drawing.Font font, Int32 width, System.Drawing.StringFormat format) [0x00000] in <filename unknown>:0 
  at (wrapper remoting-invoke-with-check) System.Drawing.Graphics:MeasureString (string,System.Drawing.Font,int,System.Drawing.StringFormat)
  at System.Windows.Forms.TextRenderer.MeasureTextInternal (IDeviceContext dc, System.String text, System.Drawing.Font font, Size proposedSize, TextFormatFlags flags, Boolean useMeasureString) [0x00000] in <filename unknown>:0 
  at System.Windows.Forms.TextRenderer.MeasureText (System.String text, System.Drawing.Font font, Size proposedSize, TextFormatFlags flags) [0x00000] in <filename unknown>:0 
  at System.Windows.Forms.ToolStripItem.CalculateAutoSize () [0x00000] in <filename unknown>:0 
  at System.Windows.Forms.ToolStripItem.set_InternalOwner (System.Windows.Forms.ToolStrip value) [0x00000] in <filename unknown>:0 
  at (wrapper remoting-invoke-with-check) System.Windows.Forms.ToolStripItem:set_InternalOwner (System.Windows.Forms.ToolStrip)
  at System.Windows.Forms.ToolStripItemCollection.Remove (System.Windows.Forms.ToolStripItem value) [0x00000] in <filename unknown>:0 
  at System.Windows.Forms.ToolStripItem.Dispose (Boolean disposing) [0x00000] in <filename unknown>:0 
  at System.Windows.Forms.ToolStripDropDownItem.Dispose (Boolean disposing) [0x00000] in <filename unknown>:0 
  at System.Windows.Forms.ToolStripMenuItem.Dispose (Boolean disposing) [0x00000] in <filename unknown>:0 
  at System.ComponentModel.Component.Finalize () [0x00000] in <filename unknown>:0
2014-02-11 23:55:54 +01:00
Michael Hutchinson 693176c27f [xbuild] Fix Tooltask.ToolPath behaviour to match .NET 2014-02-11 16:46:28 -05:00
Michael Hutchinson df528313ab [xbuild] Make ToolLocationHelper work better for 2.0/3.5
Mono keeps unversioned tools in the 4.5 directory, so look there
for 2.0. Additionally, most 3.5 tools are in the 2.0 directory.
2014-02-11 16:44:09 -05:00
Michael Hutchinson a55c58844e [xbuild] Fix typo that broke 2.0/3.5 targets 2014-02-11 16:41:08 -05:00
Michael Hutchinson c705849b59 [xbuild] Fix mscorlib resolution for custom frameworks
Now that mcs supports multi-targeting, we can use the MSBuild 4.0+
system of finding mscorlib.dll in the target framework folders and
passing it to the compiler, along with the /nostdlib argument.

Like MSBuild, the old NoStdLib property can be set to true to disable
passing mscorlib.dll to the compiler, and the new NoCompilerStandardLib
property can be set to false to disable passing /nostdlib to the compiler.

This makes custom target frameworks work correctly without having to
override CscExe with a wrapper script.
2014-02-11 14:30:53 -05:00
Marek Safar 85fbadafd0 [mcs] Don't report any not applicable operator errors during constant folding. 2014-02-11 19:09:17 +01:00
Martin Baulig f70d569806 [NTLM]: Add new 'NtmlSettings' class to hold the 'DefaultAuthLevel' property.
When the NTLM sources are compiled into System.dll, then we need to store the
configuration variables there and peek/poke it in Mono.Security.
2014-02-11 18:51:33 +01:00
Marek Safar 1a33c018d1 [system] Updates to WebUtility decoders and encoders 2014-02-11 16:50:14 +01:00
Marek Safar 9ba1566be6 [system.xml] Add more invalid argument checks 2014-02-11 16:50:13 +01:00
Etienne CHAMPETIER 4d0e014a76 int a[0], malloc(0), memcpy(a,b,0), memcmp(c,d,0) doesn't make much sense
This remove a scan-build warning

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-02-11 13:42:47 +01:00
Etienne CHAMPETIER df0030ccdd fix typo in mono_counters_cleanup leading to a double free
Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-02-11 12:49:57 +01:00
Zoltan Varga 620efd4c33 [arm] Use d0/d1 as fp scratch regs on non-hard float platforms. Hopefully fixes #17597. 2014-02-10 23:47:00 +01:00
Marek Safar a6e236b2d6 [system.xml] Support more primitive types in XmlReader::ReadContentAs 2014-02-10 23:10:58 +01:00
Mark Probst e3fa93de35 [runtime] Remove overly pessimistic test.
The test asserts that we can't allocate int arrays with 2G elements.
With SGen on 64 bits, however, we can, which is a feature, not
a bug.
2014-02-10 13:35:45 -08:00
Mark Probst 38637f5314 [sgen] new T[-1] must throw OverflowException, not OOM.
Fixes failure in mini/arrays.cs.
2014-02-10 13:33:10 -08:00
Mark Probst d77573cead [sgen] Hint OOM exception branch as not taken. 2014-02-10 12:45:11 -08:00
Mark Probst a3ab067241 [sgen] Fix overflow occurring with large object allocations. Fixes #17590. 2014-02-10 11:17:47 -08:00
Marek Safar c1539ef07f [corlib] Mark awaited task exception observed when GetResult does the wait 2014-02-10 20:08:29 +01:00
Marek Safar 56d9a057eb Revert "Merge pull request #829 from symform/httpwebreq-async-ssl"
This reverts commit 35899c07ff, reversing
changes made to 80166fd02f.
2014-02-10 18:48:03 +01:00
Marek Safar b54c72e680 Merge pull request #892 from initram/master
Implemented Parse() and TryParse() for System.Numerics.BigInteger and DaysInYearBeforeMinSupportedYear for Calendars
2014-02-10 08:21:31 +01:00
Marek Safar ff3351ef61 Merge pull request #895 from ranma42/fix-tuple-hash-codegen
[corlib] Fix implementation of Tuple hash generator
2014-02-10 08:19:18 +01:00
Andrea Canciani 5b7d557523 [corlib] Fix implementation of Tuple hash generator
The Tuples.cs code generator dies with:

Unhandled Exception:
System.NotImplementedException: The requested feature is not implemented.
  at TupleGen.computeHash (Int32 destVar, Int32 start, Int32 count) [0x00000] in <filename unknown>:0
  at TupleGen.WriteHash (Int32 destVar, Int32 start, Int32 count) [0x00000] in <filename unknown>:0
  at TupleGen.Main () [0x00000] in <filename unknown>:0

This is caused by the incorrect definition of WriteHash(), which
instead of recursively calling itself is calling computeHash().

Thanks to Marek Safar for reporting the issue in
https://github.com/fsharp/fsharp/issues/188#issuecomment-34351850
2014-02-09 20:40:44 +01:00
Martin Midtgaard 3c7dd7421c Implemented DaysInYearBeforeMinSupportedYear for all Calendars that should have it in .Net 4.5 2014-02-08 17:44:20 +01:00
Martin Midtgaard 787bb65a0e Cleanup and better comment. 2014-02-08 16:34:16 +01:00
Martin Midtgaard c2034c8718 Merge remote-tracking branch 'upstream/master' 2014-02-08 16:16:02 +01:00
Zoltan Varga d50c836721 [jit] Fix a regression introduced by b3f36681c7. 2014-02-08 11:29:35 +01:00
Marek Safar 6bc362b1db [numerics] Fix type in Cosh 2014-02-07 23:45:48 +01:00
Sebastien Pouliot 35899c07ff Merge pull request #829 from symform/httpwebreq-async-ssl
Convert blocking operations in HttpWebRequest and SslClientStream to non-blocking
2014-02-07 16:48:05 -05:00
Marek Safar 80166fd02f [corlib] Make primitive types smaller than int compare result compatible 2014-02-07 20:19:16 +01:00
Marek Safar bdc78fd98d [corlib] Fixes formatting of nested tuples 2014-02-07 20:17:14 +01:00
Marek Safar f43d02d563 [corlib] Default comparer uses IComparable interface only 2014-02-07 20:07:45 +01:00
Martin Midtgaard 3fb128ac0d Merge branch 'BigIntegerParse' 2014-02-07 11:23:37 +01:00
Martin Midtgaard 61a2e43f49 Implemented overloaded versions of Parse and TryParse functions for BigInteger.
Implementation is heavily inspired by Int32.
Added unit tests for the new functions.
2014-02-07 11:21:49 +01:00
Marek Safar 16a24ef559 Fixes build 2014-02-06 22:36:50 +01:00
Marek Safar 025cb7a5d7 [corlib] Update fixed test 2014-02-06 22:30:49 +01:00
Marek Safar 84021289bc Merge pull request #889 from slluis/serializer-fix
Fix serialization issue
2014-02-06 22:28:59 +01:00
Lluis Sanchez 4a8e55bf69 Fix serialization issue
Fixes BXC 5667 - SerializationException: The object with ID 1 could
not be resolved
2014-02-06 22:01:14 +01:00
Rodrigo Kumpera 4db7fe7112 [System] Fix process creation when UseShellExecute is set to false.
This fixes the behavior of process spawning when UseShellExecute is
set to true.

The right behavior is to return no process only when we used the system
launcher. So, spawning /bin/cat should behave in the same way independent
of how UseShellExecute is set.
2014-02-06 15:52:43 -05:00
Rodrigo Kumpera a6bc3bf4e1 Revert "[runtime] Don't pass SEE_MASK_NOCLOSEPROCESS to ShellExecuteEx as we don't care for the launched process. Part 1/3 of Bug #16119."
This reverts commit 6c06d10995.
2014-02-06 15:52:43 -05:00
Rodrigo Kumpera f351a6cc82 [corlib] Harden CustomAttributeData::GetHashCode 2014-02-06 15:52:43 -05:00
Zoltan Varga f88602911f [runtime] Put back ensure_synch_cs_set () which was removed in a157ac79e8 to work around some shutdown crashes. 2014-02-06 20:08:17 +01:00
Marek Safar 4b5125c707 [mcs] Tests update 2014-02-06 18:08:40 +01:00
Marek Safar d28989fddd [runtime] Filter out events with same name 2014-02-06 18:08:38 +01:00
Marek Safar 8d56b51656 Fixes build 2014-02-06 18:08:38 +01:00
Marek Safar 268771b856 [corlib] Cleanup type ToString formatting. 2014-02-06 18:08:37 +01:00
Marek Safar 21aae7666a [corlib] Fix some AssemblyName tests 2014-02-06 18:08:37 +01:00
Marek Safar 1383b1834d [corlib] Better recovery when tasks run on broken scheduler 2014-02-06 18:08:37 +01:00
Marek Safar d6c71e400b [corlib] Cleanup ThreadLocal output formatting. 2014-02-06 18:08:36 +01:00
Zoltan Varga f3443866ad [runtime] Fix the computation of AssemblyName.ProcessorArchitecture () to be compatible with MS.NET. Fixes #17632. 2014-02-06 11:58:31 +01:00
Andrés G. Aragoneses 0522c8b92a Add types from the method header even for gshared methods. 2014-02-06 11:34:29 +01:00
Zoltan Varga d73dcf705f Revert "[aot] Applied patch from "Andrés G. Aragoneses" <[email protected]>: Add types from the method header even for gshared methods."
This reverts commit 9231594314.
2014-02-06 11:34:28 +01:00
Atsushi Eno 21cb4135ea fix bug #16744 - null values on nullable value types were not handled in deserializer. 2014-02-06 17:11:30 +09:00
Rolf Bjarne Kvinge 1e10c63073 [Mono.Data.Sqlite] Add SqliteFunction tests. 2014-02-05 20:16:42 -05:00
Rolf Bjarne Kvinge 22cf2b620c [Mono.Data.Sqlite] Add support for custom collation functions in MonoTouch. 2014-02-05 19:55:26 -05:00
Zoltan Varga 9231594314 [aot] Applied patch from "Andrés G. Aragoneses" <[email protected]>: Add types from the method header even for gshared methods. 2014-02-06 00:52:13 +01:00
Zoltan Varga 9d34aac9c3 Revert "[aot] Add types from the method header even for gshared methods."
This reverts commit 70d7512ac8.
2014-02-06 00:51:31 +01:00
Zoltan Varga 70d7512ac8 [aot] Add types from the method header even for gshared methods. 2014-02-06 00:33:08 +01:00
Zoltan Varga 5a59eef22b [runtime] Fix the windows build. 2014-02-06 00:16:43 +01:00
Ivo Smits 3ed3a2ddf2 Prevent exception in finalization of Form class
If initialization of the Form class or one of its base classes fails, possibly because X11 is not available and the constructor of the parent Control class throws an exception, the owned_forms member is not initialized. This results in a NullReferenceException during initialization, if the error that occurs during construction is handled.

Stack traces:
Unhandled Exception:
System.TypeInitializationException: An exception was thrown by the type initializer for System.Windows.Forms.WindowsFormsSynchronizationContext ---> System.TypeInitializationException: An exception was thrown by the type initializer for System.Windows.Forms.XplatUI ---> System.ArgumentNullException: Could not open display (X-Server required. Check you DISPLAY environment variable)
Parameter name: Display
  at System.Windows.Forms.XplatUIX11.SetDisplay (IntPtr display_handle) [0x00000] in <filename unknown>:0
  at System.Windows.Forms.XplatUIX11..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.XplatUIX11.GetInstance () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.XplatUI..cctor () [0x00000] in <filename unknown>:0
  --- End of inner exception stack trace ---
  at System.Windows.Forms.Theme.get_MenuAccessKeysUnderlined () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.SystemInformation.get_MenuAccessKeysUnderlined () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.Control..ctor () [0x00000] in <filename unknown>:0
  at (wrapper remoting-invoke-with-check) System.Windows.Forms.Control:.ctor ()
  at System.Windows.Forms.WindowsFormsSynchronizationContext..cctor () [0x00000] in <filename unknown>:0
  --- End of inner exception stack trace ---
  at System.Windows.Forms.Control..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.ScrollableControl..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.ContainerControl..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.Form..ctor () [0x00000] in <filename unknown>:0
  at AutoCRCheck.frmOptions..ctor () [0x00000] in <filename unknown>:0
  at (wrapper remoting-invoke-with-check) AutoCRCheck.frmOptions:.ctor ()
  at AutoCRCheck.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0
[ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: An exception was thrown by the type initializer for System.Windows.Forms.WindowsFormsSynchronizationContext ---> System.TypeInitializationException: An exception was thrown by the type initializer for System.Windows.Forms.XplatUI ---> System.ArgumentNullException: Could not open display (X-Server required. Check you DISPLAY environment variable)
Parameter name: Display
  at System.Windows.Forms.XplatUIX11.SetDisplay (IntPtr display_handle) [0x00000] in <filename unknown>:0
  at System.Windows.Forms.XplatUIX11..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.XplatUIX11.GetInstance () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.XplatUI..cctor () [0x00000] in <filename unknown>:0
  --- End of inner exception stack trace ---
  at System.Windows.Forms.Theme.get_MenuAccessKeysUnderlined () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.SystemInformation.get_MenuAccessKeysUnderlined () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.Control..ctor () [0x00000] in <filename unknown>:0
  at (wrapper remoting-invoke-with-check) System.Windows.Forms.Control:.ctor ()
  at System.Windows.Forms.WindowsFormsSynchronizationContext..cctor () [0x00000] in <filename unknown>:0
  --- End of inner exception stack trace ---
  at System.Windows.Forms.Control..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.ScrollableControl..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.ContainerControl..ctor () [0x00000] in <filename unknown>:0
  at System.Windows.Forms.Form..ctor () [0x00000] in <filename unknown>:0
  at AutoCRCheck.frmOptions..ctor () [0x00000] in <filename unknown>:0
  at (wrapper remoting-invoke-with-check) AutoCRCheck.frmOptions:.ctor ()
  at AutoCRCheck.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0

---------------------------------------------------------
Handling the previous exception results in the following exception:

System.NullReferenceException: Object reference not set to an instance of an object
  at System.Windows.Forms.Form.Dispose (Boolean disposing) [0x00000] in <filename unknown>:0
  at AutoCRCheck.frmOptions.Dispose (Boolean disposing) [0x00000] in <filename unknown>:0
  at System.ComponentModel.Component.Finalize () [0x00000] in <filename unknown>:0
2014-02-05 20:37:30 +01:00
Zoltan Varga f97bc9e491 [arm] Increase the length of the endfinally instruction. Fixes #17589. 2014-02-05 17:37:14 +01:00
Marek Safar 5a20d0438a [corlib] Path.Combine with variable arguments length where one is empty should give same result as other Combine overloads 2014-02-05 16:56:03 +01:00
Marek Safar 22e1ab3666 [corlib] Convert with incorrect provider type should still return value when possible 2014-02-05 16:56:02 +01:00
Marek Safar 9bc33d4aae [corlib] Use shared version of utf8 encoding in stream reader 2014-02-05 16:56:02 +01:00
Marek Safar 6c99c56018 [corlib] Add nullable tests 2014-02-05 16:56:01 +01:00
Zoltan Varga b3f36681c7 [jit] Implement OP_CARD_TABLE_WBARRIER on ios. 2014-02-05 16:40:31 +01:00
Rodrigo Kumpera a9054cd8c5 Flush changes in corlib expected results. 2014-02-05 10:06:18 -05:00
Marek Safar 9c787bbc85 [corlib] Add more argument checks to ConcurrentStack 2014-02-05 14:09:11 +01:00
Marek Safar c964e24d02 [system] More SortedDictionary argument checks 2014-02-05 13:16:40 +01:00
Marek Safar d90906cbaa [system] Fix calls on empty linked list 2014-02-05 12:07:17 +01:00
Michael Hutchinson 1dd3e5b460 [xbuild] Fix ResolveAssemblyReference verbosity
Always log search logger messages with low importance.

Missing non-primary references are a low priority message,
not a warning.
2014-02-05 00:04:05 -05:00
Marek Safar 88ad199d5c [corlib] Implement parsing of complex double strings. 2014-02-04 17:39:35 +01:00
Marek Safar d3b817cbb8 [corlib] Initialize null stream reader 2014-02-04 13:14:33 +01:00
Marek Safar 27836846a5 [corlib] Add overflow checks to string padding 2014-02-04 12:44:44 +01:00
Zoltan Varga 7604aae1b1 [jit] Avoid running class cctors during AOT when using the AggressiveInlining attribute. Fixes #17558. 2014-02-04 09:52:42 +01:00
Zoltan Varga 86e5a5d90b [runtime] Fix a warning. 2014-02-04 07:05:47 +01:00
Rodrigo Kumpera 6083678eff [corlib] The hashcode of an empty struct must be constant. Fixes #17577 2014-02-03 18:08:53 -05:00
Rodrigo Kumpera 35148629ee [corlib] Add overflow checks to functions that alloc memory and uses raw pointers. 2014-02-03 17:37:30 -05:00
Zoltan Varga 0c27914928 [runtime] Applied patch from Frank Fuchs <[email protected]>. Add win64 support to mono_threads_core_get_stack_bounds (). 2014-02-03 22:15:30 +01:00
Zoltan Varga 83139b20e2 [runtime] Applied patch from Frank Fuchs <[email protected]>. Fix the windows build. 2014-02-03 22:12:11 +01:00
Marek Safar b90fc130ff [corlib] Allow to use custom comparer when sorting null values. 2014-02-03 20:27:58 +01:00
Marek Safar e679803c89 [corlib] Clean up array binary search argument checks 2014-02-03 18:36:24 +01:00
Marek Safar 27b2190c88 [corlib] Throw correct exception when array::copy elements don't match 2014-02-03 16:13:49 +01:00
Marek Safar 908676bca9 Merge pull request #886 from dmpot/master
[WindowsBase]: 6 fixes to Dispatcher
2014-02-03 00:40:56 -08:00
Dmitry Potapov e9a6400785 Dispatcher should process a higher-priority task
When a higher-priority tasked appeared in the dispatcher queue, the
dispatcher stopped processing of the current queue but moved to a low
priority queue instead of processing the most high priority queue.
2014-02-03 02:07:44 +04:00
Dmitry Potapov 0dc598dfe6 InvalidOperationException in Dispatcher.RunFrame
When a Dispatcher exits due to 'frame.Continue' being false, it does not
clear queue_bits. As result, the next run of the Dispatcher could try to
dequeue a non-existing dispatcher operation.
2014-02-03 01:57:20 +04:00
Dmitry Potapov 3479f368e8 Dispatcher should stop if Continue is false
If the dispatcher encounters that frame.Continue is false, it should return
immediately and do not try to execute anything. The unit test may be seen as
rather artificial, but the problem may happen in more realistic situations
when frames are unwound.
2014-02-03 01:48:32 +04:00
Dmitry Potapov ed448193fb Dispatcher: Run() can be used more than once
When Run() was invoked a second time, main_execution_frame had the Continue
flag set to false. So it did not work correctly.
2014-02-03 01:41:42 +04:00
Zoltan Varga 6472ba5272 [runtime] Simplify the io-layer threading code a bit more. 2014-02-02 22:36:28 +01:00
Dmitry Potapov 0a339c31a3 Dispatcher.PushFrame: clean references before return
The dispatcher did not clean references before returning, therefore
the second call to Dispatcher.Run() failed.
2014-02-02 23:55:12 +04:00
Dmitry Potapov 38a1e8d3bd Fix src and dest indexes in DispatcherOperation ctor
The source and the destination indexes are confused. The source index, which
is the second parameter, should be 0 and the destination index, which is the
fourth parameter, should be 1.
2014-02-02 22:40:55 +04:00
Zoltan Varga 17fcfee696 [runtime] Move more thread attach code to mono-threads from io-layer. 2014-02-02 16:44:40 +01:00
Marek Safar 549fddc4b4 Merge pull request #884 from akoeplinger/fix-ipv6-teredo
[System] Fixed an error in the implementation of System.Net.IPAddress.IsIPv6Teredo
2014-02-02 05:17:22 -08:00
Zoltan Varga 089012eefb [runtime] Simplify _wapi_set_termination_details (). 2014-02-02 06:11:31 +01:00
Alexander Köplinger daf2340d47 [System] Fixed an error in the implementation of System.Net.IPAddress.IsIPv6Teredo
The property was introduced with PR #870 but it missed to convert network byte order to host byte order, so the comparison
wasn't working correctly and the corresponding unit test failed. @marek-safar erroneously "fixed" the test in 27e07c7.

This is the corrected implementation and the original test now works as intended.
2014-02-01 22:02:27 +01:00
Zoltan Varga 6c36ba39f9 [runtime] Rename mono_thread_info_dettach () to mono_thread_info_detach (). 2014-02-01 19:31:07 +01:00
Zoltan Varga 4fe10052f3 [runtime] Rename the MONO_GSHARING define to ENABLE_GSHAREDVT for consistency. 2014-02-01 13:56:19 +01:00
Zoltan Varga f6f319715b [runtime] Implement GetCurrentThreadId () using mono-threads. 2014-02-01 13:50:47 +01:00
Zoltan Varga 4b4409213a [runtime] Move thread attaching to mono-threads from the io-layer. 2014-02-01 13:44:54 +01:00
Zoltan Varga 97bd727bc0 [runtime] Remove code duplication from the wapi_interrupt_.. functions. 2014-01-31 18:58:25 +01:00
Marek Safar e30d5edecc [corlib] Fixes our of range index access from a5fc91fc42 2014-01-31 17:42:06 +01:00
Marek Safar 7d200b7624 More tests 2014-01-31 15:44:12 +01:00
Marek Safar a5fc91fc42 [corlib] Decimal parsing with banker's rounding with non-zero digits beyond the thousandths digit. Fixes #17536 2014-01-31 15:32:21 +01:00
Zoltan Varga d64b215b8a [runtime] Remove some references to gc_wrapper.h which are no longer needed. 2014-01-31 14:29:51 +01:00
Zoltan Varga 6427caaea8 [runtime] Move the thread exit code to mono-threads from io-layer. 2014-01-31 14:18:26 +01:00
Marek Safar 83dd786b66 [mcs] Improve daa862f17f commit 2014-01-31 14:04:49 +01:00
Marek Safar 9ba287cc13 [mcs] Explicit user conversion from nullable types does not have to lift the result. Fixes #17469 2014-01-31 13:30:49 +01:00
Marek Safar daa862f17f [mcs] Report less internal errors. Fixes #17472 2014-01-31 11:44:04 +01:00
Marek Safar f5a0d45808 [mcs] Fixes warning 2014-01-31 11:25:25 +01:00
Marek Safar 587b934b22 [mcs] Release array initializer stack field at the end of initialization. Fixes #17494 2014-01-31 10:19:36 +01:00
Zoltan Varga 7f5859ea2d [runtime] Fix a shutdown leak. 2014-01-31 08:58:16 +01:00
Zoltan Varga 2468027212 [runtime] Use mono_thread_join () to wait for the finalizer thread to exit. 2014-01-31 06:43:32 +01:00
Zoltan Varga 19362c66ee [llvm] Disable llvm instead of asserting in some cases. Fixes #17527. 2014-01-31 06:17:41 +01:00
Zoltan Varga c0a34485ae [runtime] Use a separate lock for the joinable_threads () hash table. 2014-01-31 04:12:54 +01:00
Michael Hutchinson dbc5c2b43f Merge pull request #880 from awinters-fvs/xbuild/make-dist-fix
Fix 'make dist' broken since 35287878
2014-01-30 13:13:59 -08:00
Rodrigo Kumpera a86c932c77 [corlib] WeakReference<T>::TryGetTarget should return true only for non null targets. 2014-01-30 16:11:39 -05:00
Zoltan Varga 6de1a802b2 Fix warnings. 2014-01-30 19:08:22 +01:00
Zoltan Varga 7eb1f72f17 [runtime] Change the way the runtime waits for threads to finish. Instead of detaching them at thread startup and waiting for them using WaitForMultipleObject(), add threads to a hash table before they exit mono code and use the finalizer thread to call pthread_join () on them. This will hopefully fix the problems where a thread tried to access data which the runtime at shutdown/appdomain unload. 2014-01-30 10:28:42 +01:00
Alex Rønne Petersen c5bddd396d Merge pull request #882 from jgagnon/master
Fixes a socket leak in class TcpListener
2014-01-29 19:51:18 -08:00
Rodrigo Kumpera e614bd0216 [jit]Add a missing call to mini_native_type_replace_type in mini_get_basic_type_from_generic. 2014-01-29 14:17:19 -05:00
Zoltan Varga 80ef831207 [aot] Add a more helpfull error message when a method cannot be loaded. 2014-01-29 16:47:19 +01:00
Zoltan Varga 44fcdaf505 [sgen] Fix a regression caused by 07fc727b86. Fixes the windows build. 2014-01-29 16:24:28 +01:00
Michael Hutchinson a8392fb5e8 [xbuild] Rework escaping in TaskItem to be compatible with MSBuild
The escaping/unescaping behaviour of TaskItem:ITaskItem was undocumented
originally in MSBuild, so our implementation did not perform any. This
caused issues with Tasks getting metadata and paths that were escaped,
trying to use them as-is, and failing horribly.

Fortunately the ITaskItem2 interface in .NET 4 provides complementary
accessors with documentation that indicates that it stores values
escaped internally, and the old accessors unescape the values.

This commit implements ITaskItem2, fixes the escaping behavior of the
old accessors, and removes some superluous uses of IDictionary.Contains.
2014-01-28 18:25:57 -05:00
Michael Hutchinson 9d344c33ad [xbuild] Remove unnecessary/inconsistent path conversion hack
Directory separators are automatically converted from Windows->Native
when parsing MSBuild files, but any paths provided in code must already
be native.
2014-01-28 18:24:38 -05:00
Alan McGovern 216608a183 [Microsoft.Build.Utilities] Properly escape/unescape ItemSpec
With tests.
2014-01-28 16:18:57 -05:00
Alan McGovern d5611e8dc6 [Microsoft.Build.Utilities] Fix the escaping/unescaping of ItemSpec
This should hopefully fix compilation of projects using files with
names like '[email protected]' in various places like embedded resources
or content items which must be copied to the output directory.

With tests.
2014-01-28 15:40:25 -05:00
Marek Safar f25566d57b [mcs] Better check for invalid attribute targets. Fixes #17447 2014-01-28 10:16:58 +01:00
Zoltan Varga f060b99989 [llvm] Load rgctx/imt arguments using a volatile load on arm to prevent LLVM from moving the setting of the argument elsewhere. This is needed because these arguments are passed in a caller save register, but our code treats it as callee save in a lot of places. Fixes #17435. 2014-01-28 06:30:19 +01:00
Zoltan Varga 393325a1b8 Revert "[jit] Precompute a bit more information for delegate trampolines to speed them up."
This reverts commit e3de4cb92e.

Revert this as it seems to break mt.
2014-01-28 06:30:19 +01:00
Michael Hutchinson 28163fd254 [xbuild] Define VisualStudioVersion, since F# projects can depend on it 2014-01-27 17:00:08 -05:00
Rodrigo Kumpera 6b43686f98 Properly compare assembly versions when performing binding. Fixes #17368.
The right way to compare assembly versions is by translating the major/minor
pair into a single number and compare that.

Since each element can only be one byte long, we multiply major by 256
before adding to minor.

This solves the problem where version 100.0.0.0 was not after 3.5.0.0.
2014-01-27 16:28:01 -05:00
Jonathan Gagnon b699b14b06 Fixes a socket leak in class TcpListener
Fixes a socket leak in TcpListener.AcceptTcpClient and
TcpListener.EndAcceptTcpClient.
2014-01-27 09:18:10 -05:00
Marek Safar 9ec6141610 New test 2014-01-27 11:35:41 +01:00
Marek Safar bff1c7a08c [mcs] Remove used method 2014-01-27 11:21:34 +01:00
Marek Safar a360e899ae [mcs] Don't crash when default parameter constant member access cannot be resolved. Fixes #17354 2014-01-27 11:19:54 +01:00
Marek Safar f2eab9919d [dlr] Handle more expressions in interpreter 2014-01-26 11:35:09 +01:00
Marek Safar 280f85db70 [mcs] Do underlying float constant operation on double values. Fixes #15463 2014-01-26 11:35:08 +01:00
Marek Safar acccf24cca [mcs] Check for nested type arguments of cached method group. Fixes #17403 2014-01-26 11:35:08 +01:00
Linquize 506c11ae62 Add unit test for Content-Type header with and without charset set 2014-01-26 18:31:00 +08:00
Zoltan Varga e3de4cb92e [jit] Precompute a bit more information for delegate trampolines to speed them up. 2014-01-26 07:32:08 +01:00
Zoltan Varga b5f3d5c835 [jit] Store the spvar offsets for the finally clauses in MonoJitExceptionInfo to avoid disassembly in mono_arch_install_handler_block_guard (). 2014-01-25 07:39:36 +01:00
Zoltan Varga 0198a3afaa [jit] Change to signature of mono_arch_create_handler_block_trampoline () to be consistent with the signature of the other trampoline creation functions. 2014-01-25 07:27:40 +01:00
Ashley Winters 49238f289e Update mono-core.spec.in with xbuild reorganization 2014-01-24 14:30:22 -08:00
Zoltan Varga a33190d8e8 [jit] Add a mono_jinfo_get_unwind_info () helper function. 2014-01-24 20:44:28 +01:00
Sebastien Pouliot 5048ce7bd9 Allow a TLS1.1+ client (like recent Google Chrome, 1.2) to fallback to TLS1.0 when using System.dll (or Mono.Security.dll) server side SSL/TLS [#6843][#11736] 2014-01-24 08:47:10 -05:00
Atsushi Eno 6c9fb62368 Fix build (and cosmetic code formatting). 2014-01-24 17:34:27 +09:00
Atsushi Eno 4dabbbc56d remove private msbuild hacking project files. 2014-01-24 16:42:54 +09:00
Atsushi Eno 3f88e7c517 Merge branch 'msbuilddll2' 2014-01-24 16:41:00 +09:00
Atsushi Eno 001dc741f1 Log target build error. 2014-01-24 16:25:29 +09:00
Zoltan Varga 7fa4b9ab15 [jit] Fix/simplify the x86 handler guard trampoline code. Part of the fix for #16807. 2014-01-24 08:23:41 +01:00
Atsushi Eno b47eaa6c88 Make sure to fail build when exception is thrown while building a target. 2014-01-24 16:02:08 +09:00
Zoltan Varga 60ba4e74da Revert "finally_guard has been promoted to the stable set of tests."
This reverts commit 31d902a285.

finally_guard still fails when using LLVM.
2014-01-24 07:49:55 +01:00
Zoltan Varga 6c9a1d91c8 [jit] Fix a regression caused by 28374f3161. Fixes #17392. 2014-01-24 07:45:55 +01:00
Zoltan Varga 6154dc7731 [jit] Hopefully fix the loaded LLVM build. 2014-01-24 04:47:23 +01:00
Atsushi Eno 2556ac769e add comment on MSB4057. 2014-01-24 10:41:08 +09:00
Ashley Winters 75e0f8d7e5 Include xbuild_4_0_dirs in dist; fixes 425fdc03
In commit 425fdc03fa:

  [xbuild] Build & install MSBuild 12.0 assemblies

The net_3_5_only_dirs containing the Build classes were moved to
various xbuild_X_dirs variables, but an undefined $(xbuild_dirs)
variable was appended to DIST_ONLY_SUBDIRS.

This patch adds $(xbuild_4_0_dirs) instead.
2014-01-23 17:14:21 -08:00
Ashley Winters 48d027c872 Fix 'make dist' broken since 35287878
In commit 35287878b9:

    [xbuild] Reorganize xbuild targets/frameworks/bin data

Several files were shuffled around, but the EXTRA_DISTFILES was
not fully updated with the new file paths.

This patch is required to build a 3.2.7 tarball.
2014-01-23 17:14:18 -08:00
Sebastien Pouliot 0da4887478 [System] Exclude LinuxNetworkChange from MONOTOUCH build (since it won't work as the p/invoke are not present) 2014-01-23 16:57:11 -05:00
Atsushi Eno 3354229821 update .csproj. 2014-01-23 23:46:46 +09:00
Atsushi Eno e975cdcd71 Add BuildRequestDataTest and fixed some .NET compatibility in tests. 2014-01-23 23:46:09 +09:00
Atsushi Eno 0f2a28f154 Check null buildTargets at BuildRequestData. But not in ProjectInstance. 2014-01-23 23:45:23 +09:00
Alex Rønne Petersen 62a953fddf Merge pull request #735 from wtfrank/bitblt
dllmap for BitBlt in gdi32.dll
2014-01-23 03:59:37 -08:00
Atsushi Eno 77394d2b6b Path existence and lookup is now based on insensitive search. 2014-01-23 19:14:35 +09:00
Atsushi Eno 5afd546fdd comment out error check on Inputs/Outputs mismatch. 2014-01-23 17:03:18 +09:00
Atsushi Eno 845b1b7e5c implement OnError on target. 2014-01-23 17:02:15 +09:00
Atsushi Eno 30e1ab9a21 Exists() needs to normalize Windows path first. 2014-01-23 17:00:32 +09:00
Zoltan Varga e28ad88aea [jit] Add a mono_get_jit_tls () helper function. 2014-01-23 04:46:55 +01:00
Atsushi Eno 9d81eb03de exclude extraneous stuff from msbuild dir. 2014-01-23 11:56:25 +09:00
Atsushi Eno ff13feb917 DefaultTargets must be first picked up from imports' attributes, then first of Targets. 2014-01-23 11:31:07 +09:00
Atsushi Eno b8b67850a3 property name comparison should be done in case insensitive manner. 2014-01-23 11:30:43 +09:00
tritao f574fff5ef Follow up on return intrinsics tightening the preprocessor checks and using the declared version of the intrinsic instead of declaring it ourselves.
Addressing a post-commit review by @alexrp.
2014-01-23 00:34:45 +00:00
Rodrigo Kumpera 3ebef4abdf [runtime] Handle native size of structs with explicit layout and min alignment smaller than default packing. Fixes #4510
The calculating the native size of structs with explicit layout we need to take into consideration the minimum alignment
needed and the packing asked.

If no packing is supplied, we should respect the minimum alignment. If packing is supplied we should use the minimum required.
2014-01-22 16:51:50 -05:00
João Matos 5e0c599e4a Merge pull request #878 from tritao/master
MSVC build improvements
2014-01-22 10:46:45 -08:00
Marek Safar 95d5c30a29 New tests 2014-01-22 17:54:14 +01:00
Marek Safar ee5bf38ad0 [dlr] Implement few missing interpreter instructions 2014-01-22 17:54:14 +01:00
Marek Safar a2febcf2de [dlr] Fix UInt64 add/div 2014-01-22 17:54:13 +01:00
Zoltan Varga 738f9c3c38 [jit] Fix the freeing of AOT jump target lists. Fixes #17201. 2014-01-22 01:11:23 +01:00
Zoltan Varga 216ccda87a [amd64] Make seq_points clobber callee save registers. Fixes #17310. 2014-01-22 00:58:39 +01:00
Marek Safar c9cb2f4c4a [mkbundle] Make duplicate assembly name error tracking less painful 2014-01-21 23:11:43 +01:00
Marek Safar 4956113701 [mkbundle] Remove no longer needed System.Reflection hack 2014-01-21 20:39:28 +01:00
Marek Safar c6bd624372 [mcs] Check for initially unassigned struct instance variables of unassigned structs. 2014-01-21 16:33:01 +01:00
Rolf Bjarne Kvinge 5fe24cd406 [System] Include IndentedTextWriter in the mobile profile.
Fixes a build problem for Xamarin.iOS and besides there doesn't seem
to be any reason for it to not be included.
2014-01-21 10:41:27 +01:00
Zoltan Varga 93540ce41d [runtime] Fix the DISABLE_JIT build. 2014-01-21 04:27:06 +01:00
Zoltan Varga 26ac16318d [gsharedvt] Fix memory leaks. Fixes #16787. 2014-01-21 03:51:33 +01:00
tritao 0737176a13 Explicitly define strtoull for MSVC releases previous to 2013. 2014-01-20 18:50:44 +00:00
tritao eca6062b12 Fixed SGen qsort code to compile with MSVC.
MSVC does not understand C99, so we emulate it with some explicit allocas.
2014-01-20 18:49:37 +00:00
tritao 110bfc8bbe Fixed return address intrinsics in MSVC.
Patch previously contributed Vincent Povirk, slightly updated due to some review feedback by Alex Petersen.
2014-01-20 18:47:11 +00:00
tritao a7cc9fedd8 Fixed missing Interlocked intrinsics in MSVC x86.
Patch previously contributed by Vincent Povirk.
2014-01-20 18:44:39 +00:00
Alex Rønne Petersen 3c3b8ae818 Move a variable into the #ifdef path it's used in. Fixes a warning. 2014-01-20 18:15:33 +01:00
Alex Rønne Petersen fbde76e4c5 Remove unused emit_line_number_info_begin () function. Fixes a warning. 2014-01-20 18:15:13 +01:00
Alex Rønne Petersen 4e2c39751e Remove unused dummy_apc () function on non-WIN32. Fixes a warning. 2014-01-20 16:15:15 +01:00
Miguel de Icaza 165a35c18c Revert "Exclude more console code from NET_2_1"
Since we no longer care about Moonlight, this patch is no longer needed,
and enables some cute functionality on the iOS REPL.

This reverts commit ec445c82f7.
2014-01-20 09:22:17 -05:00
Marek Safar 7db9ee7b47 Merge pull request #876 from knocte/master
Fix very sticky typo in numerous places
2014-01-19 23:41:11 -08:00
Andrés G. Aragoneses 0eb40ad2da Fix very sticky typo in numerous places 2014-01-19 17:51:24 +01:00
Zoltan Varga 05821ed6e9 [runtime] Rename QueueUserAPC () to wapi_thread_interrupt_self () and simplify it. 2014-01-19 05:40:54 +01:00
Rodrigo Kumpera 31d902a285 finally_guard has been promoted to the stable set of tests. 2014-01-17 18:15:01 -05:00
Rodrigo Kumpera b7d2b9a000 The shutdown check is racy, we should check if the queue has been cleaned up instead. 2014-01-17 18:13:57 -05:00
Rodrigo Kumpera 7d688f1c02 [runtime] Properly unlink a node in the tls slot freelist. Fixes #17290.
The existing search code would not update the previous pointer so we would be
always unlinking all nodes in the freelist in front of the one picked.
2014-01-17 17:54:42 -05:00
Rodrigo Kumpera c9230c1fdb [runtime] Don't raise a ExecutionEngineException is shadown copying fails to find the file. Fixes #17251.
Patch by Jan Lamecki. Released under MIT X11 license as per https://bugzilla.xamarin.com/show_bug.cgi?id=17251
2014-01-17 16:07:41 -05:00
Marek Safar 4de39e0eac [corlib] BinaryStream sting reading from custom stream uses correct count. Fixes #15143 2014-01-17 21:59:40 +01:00
Richard Meyer 4ee22819a5 Added additional common internet media types
Many of the changes come from: http://en.wikipedia.org/wiki/Internet_media_type#List_of_common_media_types

dtd as application/xml-dtd
http://tools.ietf.org/html/rfc3023#section-3.5

vcf and vcard as text/vcard				http://tools.ietf.org/html/rfc6350#section-10.1

dart as application/dart
https://www.dartlang.org/articles/embedding-in-html/

xps as application/vnd.ms-xpsdocument
oxps as application/oxps
http://www.ecma-international.org/publications/standards/Ecma-388.htm

flac as audio/x-flac
http://en.wikipedia.org/wiki/FLAC

spx as audio/ogg
http://tools.ietf.org/html/rfc5334#section-10.3

opus as audio/ogg
http://tools.ietf.org/html/draft-terriberry-oggopus-01

X3D Mime Types:
http://www.web3d.org/x3d/learn/mimetypes/
http://www.iana.org/assignments/media-types/model/x3d-vrml

appcache for text/cache-manifest
http://en.wikipedia.org/wiki/Cache_manifest_in_HTML5
2014-01-17 14:26:50 -06:00
Marek Safar 661af380c3 [corlib] Fixes race in disposing CancellationTokenSource. Fixes #17256 2014-01-17 21:04:08 +01:00
Marek Safar 14db2127d4 [mcs] Less cascading errors 2014-01-17 21:04:08 +01:00
Marek Safar eee540621a Merge pull request #868 from mariokmk/master
Using the fully qualified assembly name in dependencies
2014-01-17 12:00:02 -08:00
Richard Meyer 9fc58a5bec Added application/json and application/xhtml+xml
application/json:
http://www.ietf.org/rfc/rfc4627.txt
This could improve support for libraries like jQuery that request raw .json files

application/xhtml+xml:
http://www.rfc-editor.org/rfc/rfc3236.txt
2014-01-17 11:51:23 -06:00
Richard Meyer 9d5ecce947 Some corrections and additions
Changed "aac" to "audio/aac"
http://en.wikipedia.org/wiki/Advanced_Audio_Coding

Added "m4a" for "audio/mp4" and "m4v" for "video/mp4"
Commented out "mp4a" since the official extension is "m4a"
http://tools.ietf.org/rfc/rfc4337.txt
http://en.wikipedia.org/wiki/MPEG-4_Part_14

Added "3pg" for "video/3gpp"
http://tools.ietf.org/html/rfc3839#section-3.2

Added "3g2" for "video/3gpp2"
http://tools.ietf.org/html/rfc4393#section-3.2

Added "ogx" for "application/ogg"
http://tools.ietf.org/html/rfc5334#section-10.1
2014-01-17 11:14:14 -06:00
Rodrigo Kumpera 058e285738 [metadata] Fix a potential crasher. 2014-01-17 12:06:50 -05:00
Rodrigo Kumpera 65e808bb55 [runtime] Fix a few warnings in io-layer and utils. 2014-01-17 12:06:49 -05:00
Rodrigo Kumpera eb460afc7b [utils] The fallback mmap should fail if it cannot read the full contents of a file. 2014-01-17 12:06:49 -05:00
Rodrigo Kumpera 20149a0ecc [eglib] Fix a possible memory leak. 2014-01-17 12:06:49 -05:00
Zoltan Varga 87bbf05c11 [runtime] Use mono_thread_info_tls_get () in sgen as well. 2014-01-17 18:03:02 +01:00
Atsushi Eno c9021a5d28 [mkbundle] fix template for compressed version. stderr is in stdio.h. 2014-01-17 23:18:27 +09:00
Marek Safar 47071c959e [mcs] Initial lambda checked scope comes from parent block. 2014-01-17 11:33:35 +01:00
Alex Rønne Petersen 3a86569d27 Merge pull request #856 from madewokherd/textcontrol
Avoid adjusting selection twice in TextControl.
2014-01-17 00:24:50 -08:00
Alex Rønne Petersen 6fd9c8ec2c Merge pull request #861 from RobertZenz/patch-1
Noted that the fullname attribute is not the same as Type.FullName.
2014-01-17 00:23:09 -08:00
Alex Rønne Petersen 6d2ab18976 Merge pull request #875 from justincc/master
Change Mono manpage to correct effect of MONO_THREADS_PER_CPU env var
2014-01-17 00:20:44 -08:00
Zoltan Varga ed1476e621 Fix boehm after eb1a7c1591. 2014-01-17 07:50:05 +01:00
Zoltan Varga 8a3bfc92ac [runtime] Remove some unused includes. 2014-01-17 07:27:48 +01:00
Zoltan Varga 3c2898ebb0 [runtime] Simplify mono_thread_state_init_from_handle () on darwin a bit. 2014-01-17 07:26:40 +01:00
Zoltan Varga eb1a7c1591 [runtime] Store the values of some TLS variables into an array in MonoThreadInfo, and use it in mono_thread_state_init_from_handle () on darwin to avoid the usage of platform specific hacks to obtain their values. 2014-01-17 04:59:23 +01:00
Zoltan Varga 7be7431b9f [runtime] Add a mono_thread_info_yield () function. 2014-01-17 03:29:33 +01:00
Zoltan Varga 07fc727b86 [runtime] Use mono_thread_info_get_stack_bounds () in sgen instead of duplicating code. 2014-01-17 03:13:10 +01:00
Zoltan Varga 679092e662 [runtime] Move mono_thread_get_stack_bounds () to utils/mono-threads. 2014-01-17 03:06:22 +01:00
Zoltan Varga 28374f3161 [aot] Add the rgctx trampolines required by array helper wrappers in the normal place instead of in mono_aot_get_method () so they won't interfere with gsharedvt. Fixes #17284. 2014-01-17 02:15:22 +01:00
Zoltan Varga 81182d1406 Disable a gsharedvt test which depends on async functionality which no longer works. 2014-01-17 02:15:22 +01:00
Aaron Bockover e22bb79ae6 driver.c: Revert "Update message"
This reverts commit 85841d0bbd.

Some scripts unfortunately depend on the verbage "Mono JIT compiler"
in the "mono --version" message. While this was never a blessed
or supported way of getting the version (use pkg-config) of Mono,
nonetheless this breaks some important stuff. We can use the better
message in the (somewhat distant) future.
2014-01-16 18:02:08 -05:00
Justin Clark-Casey a41ab301e8 Change Mono manpage to correct effect of MONO_THREADS_PER_CPU env var
1.  MONO_THREADS_PER_CPU affects ThreadPool min threads rather than max threads
2.  Effect is MONO_THREADS_PER_CPU * cpu_cores, there is no +20
3.  Default is 1, not 10
2014-01-16 20:02:53 +00:00
Aaron Bockover a66f333246 profiles: define xammac (Xamarin.Mac) profile
Based on the Mobile profile and modeled after
the MonoDroid profile.
2014-01-16 14:16:59 -05:00
Aaron Bockover 975d419550 build: use MOBILE_DYNAMIC instead of MONODROID
Some conditional compilation shouldn't really
be bound to MONODROID, instead add a new define
that can be reused, MOBILE_DYNAMIC.
2014-01-16 14:13:10 -05:00
Aaron Bockover 354e22bc89 configure.in: remove --with-mobile
It doesn't actually do anything. Was quite
misleading.
2014-01-16 14:09:55 -05:00
Zoltan Varga 401d832ca7 [jit] Handle native types in mini_type_get_underlying_type () as well. 2014-01-16 15:32:03 +01:00
Zoltan Varga cac0aaa9ce Fix the --enable-native-types build. 2014-01-16 04:03:52 +01:00
Zoltan Varga 8af5af5763 Fix the build. 2014-01-16 03:37:21 +01:00
Rodrigo Kumpera f5a80b8456 [runtime] Make gsharing and explicit configure extension. 2014-01-15 20:29:03 -05:00
Rodrigo Kumpera 01e18a7fcd [runtime]Add native type extension. 2014-01-15 20:26:56 -05:00
Marek Safar eca138a47f New test file 2014-01-15 23:03:52 +01:00
Alan McGovern 6d7e812d70 [Microsoft.Build.Engine] Fix the escaping/unescaping of FullPath metadata
It is incorrect to escape the FullPath metadata for a build item when
we invoke GetEvaluatedMetadata. If we do this we end up completely breaking
every file with a special character in it as things like this would always
fail as we'd pass an escaped path to the filesystem:
	File.Exists (item.GetEvaluatedMetadata ("FullPath"))

The iOS designer encountered this issue when we added retina images
called "[email protected]" to our solution.

With tests.
2014-01-15 15:33:16 -05:00
Marek Safar 89fcde4fd1 [mcs] Add additional l-value checks on member access properties as well. Fixes #9571 2014-01-15 20:45:58 +01:00
Marek Safar c30144b4b0 [mcs] Import extension methods dynamic generic arguments correctly. 2014-01-15 20:10:15 +01:00
Zoltan Varga 3a4464fcda [jit] Use the jit lock instead of the loader lock in mono_tramp_info_register (). 2014-01-15 18:50:47 +01:00
Zoltan Varga 791387fd05 [runtime] Get rid of SuspendThread()/ResumeThread(), integrate its functionality into mono-thread-info.c. 2014-01-15 18:34:34 +01:00
Zoltan Varga f18648d642 [jit] Fix dwarf line number info generation, make AOT use it again instead of the .loc/.file directives of GAS, since CLANG only supports those with assembly, not with .byte directives. Fixes part of #15202. 2014-01-15 04:22:45 +01:00
Marek Safar 8f1a0ccce6 [corlib] Improve 85aaf9b074 change 2014-01-14 19:23:23 +01:00
Miguel de Icaza 7d80c22054 Add support for stdout returns 2014-01-14 12:52:18 -05:00
Zoltan Varga 285f815fc5 [runtime] Fix a regression caused by a0afa38296. 2014-01-14 18:23:21 +01:00
Rolf Bjarne Kvinge f093f00839 The monotouch_runtime profile needs the DISABLE_COM flag too. 2014-01-14 18:19:06 +01:00
Zoltan Varga 1da09a9d20 [runtime] Fix regressions caused by 9e5b23eee3. 2014-01-14 17:52:50 +01:00
Zoltan Varga 9ee744d388 Revert "[runtime] Get rid of ResumeThread(), use mono_thread_info_resume () instead."
This reverts commit e0cff63013.

Revert this as its racy.
2014-01-14 17:52:50 +01:00
Sebastien Pouliot 835ac90fc0 Add missing (new) file for System.Net.Http.dll (monotouch build) 2014-01-14 11:51:25 -05:00
Rolf Bjarne Kvinge 6d75a5f34a The monotouch_runtime profile needs the DISABLE_REMOTING flag.
Since the corresponding mono runtime being used has also disabled remoting.
2014-01-14 17:31:22 +01:00
Marek Safar 4b1b421832 [mcs] Disable container definition check on platforms which don't support it 2014-01-14 17:30:50 +01:00
Marek Safar 09496c2a83 [linker] Add missing descriptors 2014-01-14 17:30:49 +01:00
Zoltan Varga 8ab9b5a4ee [runtime] Fix the windows build. 2014-01-14 16:50:56 +01:00
Sebastien Pouliot 24a220f373 The mobile profile can support IBindingRuntimePreferences on WebHttpBinding. Fix one S.SM.W unit test failure for XI 2014-01-14 10:12:11 -05:00
Sebastien Pouliot b7c10a7c1d There's no need for those special NET_2_1 cases (not using NameValueCollection like MS) anymore and it fixes 7 S.SM.W unit tests failures for XI (e.g. case sensitiveness) 2014-01-14 10:11:21 -05:00
Sebastien Pouliot 439b2917d9 There's no need for those special NET_2_1 cases (excluding System.Char) anymore and it fixes 6 S.SM.W unit tests failures for XI. 2014-01-14 10:10:35 -05:00
Sebastien Pouliot f83814bfbb [test] Disable a test for XI (only) as it does not support dynamic proxy code generation 2014-01-14 10:09:46 -05:00
Zoltan Varga 26f6ace91f Fix a warning. 2014-01-14 14:52:01 +01:00
Zoltan Varga 7982af4290 Revert "Fix a warning."
This reverts commit c5104c091a.
2014-01-14 14:52:01 +01:00
Marek Safar 27e07c76d8 Fixes failing test 2014-01-14 14:45:38 +01:00
Marek Safar f74fa4a0ac [build] Add Microsoft.CSharp to monotouch profile 2014-01-14 14:25:46 +01:00
Marek Safar c5eab2d5dc [System] Use generic equality comparer in Find/FindLast methods. Fixes #5245 2014-01-14 14:25:45 +01:00
Zoltan Varga fefea60aa0 [arm] Fix an assert caused by large offsets. Fixes #17208. 2014-01-14 04:37:43 +01:00
Zoltan Varga e0cff63013 [runtime] Get rid of ResumeThread(), use mono_thread_info_resume () instead. 2014-01-14 03:47:26 +01:00
Zoltan Varga c5104c091a Fix a warning. 2014-01-14 02:51:54 +01:00
Zoltan Varga 9e5b23eee3 [runtime] Centralize low-level thread creation in utils/mono-threads.c. Get rid of the CreateThread () function in io-layer. 2014-01-14 02:49:16 +01:00
Michael Hutchinson c25957f1a4 [xbuild] Add 4.0 client profile
BXC1426 - xbuild should include the ".NET 4.0 client" framework profile
2014-01-13 14:58:47 -05:00
Michael Hutchinson 07dfe00301 [xbuild] 4.0 test targets go in 4.5 profile 2014-01-13 14:58:46 -05:00
Zoltan Varga dab4dc951c [jit] Call mini_replace_type () in one place. 2014-01-13 19:03:00 +01:00
Zoltan Varga fc23a8e268 [runtime] Fix an assert caused by a157ac79e8. 2014-01-13 18:27:49 +01:00
Zoltan Varga 74bc71da95 [sdb] Fix setting of byref variables in registers. Fixes #17185. 2014-01-13 17:14:19 +01:00
Rodrigo Kumpera c1128bb7b0 [io-layer] Add essay on my choices for is_file_writable. 2014-01-13 10:52:49 -05:00
Marek Safar 5359f9feaf Merge pull request #844 from scottmcarthur/master
Check for null item in BindingList<T>.InsertItem
2014-01-13 06:24:13 -08:00
Marek Safar a41fe9781b Tests update 2014-01-13 15:13:40 +01:00
Marek Safar 2d0272d9c2 [System.Net.Http] Add parsing of multi-value strings. Fixes #17132 2014-01-13 14:48:12 +01:00
Zoltan Varga 0b1316bccb Fix the build. 2014-01-13 14:03:25 +01:00
Zoltan Varga 00141cd3d1 [runtime] Fix the --disable-boehm build. 2014-01-13 13:59:43 +01:00
Zoltan Varga 8aee5e61e8 Merge pull request #872 from Unity-Technologies/upstreaming/customize-suspend-policy2
allow users to specify a suspension policy when enabling an event
2014-01-13 04:35:19 -08:00
Lucas Meijer a650855da8 allow users to specify a suspension policy when enabling an event 2014-01-13 08:52:17 +01:00
Marek Safar 269c7e48dc Merge pull request #871 from tumtumtum/master
Fix for transactions hanging and timing out if PreparingEnlistment.Done() is called
2014-01-12 23:19:36 -08:00
Rodrigo Kumpera e613a00e46 [io-layer] Properly check write permission of a file. Fixes #3501.
The existing check only verified if owner had write privileges.
Which returns the wrong value when the file is not owned by the user.

And doesn't work when the file is globally writeable or the user
belongs to the user of the file.

We check flags for when euid/egid matches file's. Otherwise we fallback
to access(2), which sucks, but it's the only thing close to working
that exists on unix and has a reasonably portable behavior.
2014-01-13 00:59:43 -05:00
Zoltan Varga a0afa38296 Move the mono_thread_create () function into utils/mono-threads.h/c, change/simplify its signature a bit. 2014-01-13 04:04:58 +01:00
Zoltan Varga b71c0d6afc Clean up the thread startup code by moving common code into a new create_thread () function. 2014-01-13 02:14:47 +01:00
Thong Nguyen 99d7cb1610 Quickfix for transactions timing out and not committing when PreparingEnlistment.Done is called instead of PreparingEnlistment.Prepared 2014-01-12 22:00:57 +00:00
Zoltan Varga 0aa1d4fe15 Add LOCK_THREAD/UNLOCK_THREAD macros, get rid of ensure_synch_cs_set (). 2014-01-12 14:22:03 +01:00
Zoltan Varga a157ac79e8 Clean up the setup of thread->synch_cs. Initialize it when the MonoInternalThread object is created, and delete it in the finalizer. 2014-01-12 14:22:02 +01:00
Marek Safar 111e40018a Merge pull request #870 from wayoutmind/master
[system] Add IsIPv6Teredo to System.Net.IpAddress
2014-01-12 00:34:55 -08:00
Michael Hutchinson de413aa54e [xbuild] Properly disable tests on 4.0 framework profile 2014-01-12 01:12:43 -05:00
Michael Hutchinson a2829d26b1 [xbuild] Tests need older MSBuild targets 2014-01-12 01:12:42 -05:00
Rodrigo Kumpera 300bacd521 Merge pull request #869 from alistair/copyfile
Don't raise an exception if we can't find the src assembly on a shadow copy appdomain
2014-01-11 21:09:15 -08:00
Fredrick Galoso d27abb23af [system] Add IsIPv6Teredo to System.Net.IpAddress
Adds support for checking for an IPv6 Teredo address, introduced in
.NET Framework 4.
2014-01-11 21:23:50 -06:00
Alistair Bush 2d7b174c93 Don't raise an exception if we can't find the src assembly.
These changes are released under the MIT license.
2014-01-12 00:35:37 +13:00
Aaron Bockover bc6da57cc1 mono-api-info: avoid NumberOverflow
GetFlaggedEnumValue converts values to Int64 which
can cause a NumberOverflow exception when the value
is too large to fit (e.g. a large UInt64). Special
case UInt64 values for now (duplicates the logic,
which sucks).
2014-01-10 14:13:02 -05:00
Miguel de Icaza 319f562ca7 [csharp] do not try to read 0 characters for a string 2014-01-10 12:37:09 -05:00
Miguel de Icaza 2a728c2a86 [csharp] Make the stream reader iterate until all data has been read 2014-01-10 11:36:21 -05:00
Miguel de Icaza f85bf44466 Add new --client/--server[=server[:port] support for the shell 2014-01-10 11:36:20 -05:00
Miguel de Icaza bf60e93ea2 update copyright 2014-01-10 11:36:20 -05:00
Marek Safar 62dda0260a [corlib] Update en-GB first day of week. Fixes #17151 2014-01-10 16:47:47 +01:00
Marek Safar c92e96e850 [mcs] Check type of index used in pointer array aritmetic. Fixes #17145 2014-01-10 15:57:27 +01:00
Zoltan Varga 427d242009 [runtime] Fix large file support on android, it doesn't support -D_FILE_OFFSET_BITS=64, so call lseek64 directly. Fixes #17128. 2014-01-09 19:16:40 -05:00
Marek Safar 75bc8d1e1d [corlib] Hunting down rare Task.WaitAll race 2014-01-10 14:38:35 +01:00
Atsushi Eno c67aed9a47 fix build. 2014-01-10 20:42:25 +09:00
Marek Safar c4222e06ff [mdoc] Update expected result xml templates 2014-01-10 11:36:06 +01:00
Atsushi Eno bf909bcbd0 fix bug #11335. 2014-01-10 19:04:58 +09:00
Atsushi Eno 2fd8da4920 Fix bug #11336. 2014-01-10 19:03:33 +09:00
Marek Safar 9939588f48 [System.Core] Update MonoTouch System.Linq.Expression to be 4.5 compatible 2014-01-10 10:46:45 +01:00
Marek Safar e7c6b18e4e [mcs] Add missing object to dynamic conversion for imported types 2014-01-10 10:46:45 +01:00
Michael Hutchinson e6ffa41b0e [xbuild] Do not allow running tests or installing exe w/4.0 profile
It's not a usable MSBuild 4.0 toolset, that's in the 4.5 profile directory.
2014-01-10 01:11:33 -05:00
Michael Hutchinson 21a85cdd21 [xbuild] The 4.0 toolset is in the 4.5 directory 2014-01-10 01:11:32 -05:00
Michael Hutchinson 35287878b9 [xbuild] Reorganize xbuild targets/frameworks/bin data
They had been squashed into one single source directory
despite being installed into very different locations.

Made it easier to follow what's what by separating them
into:

* data: targets and data files for xbuild bin directory
* targets: misc pcl/web targets for extension directory
* frameworks: framework definitions
2014-01-10 01:11:31 -05:00
Rodrigo Kumpera 11edb27437 Revert "[runtime] Make mono_class_is_assignable_from lazy resolve its arguments." This broke WCF.
This reverts commit decc91e8da.
2014-01-09 16:47:31 -05:00
Rodrigo Kumpera b8bb36eb2f [runtime] Change MonoImage::field_cache lock from the loader lock to the image lock. 2014-01-09 16:47:12 -05:00
Marek Safar b3f05d8b00 [System.Core] Add dynamic interpreter 2014-01-09 20:40:09 +01:00
Marek Safar 57b915d78f [dlr] Better FEATURE_REFEMIT checks 2014-01-09 20:40:09 +01:00
Rodrigo Kumpera 4b0111dac9 [corlib] Add an exhaustive regression test for file sharing and File.Move. 2014-01-08 20:47:01 -05:00
Rodrigo Kumpera e66015a55e [io-layer] Correctly implement permission checking for File.Move. Fixes #17009.
The old check was simply for open sharing status, which is incorrect. The right
thing to do is to check for FileShare.Delete and not FileAccess.
2014-01-08 20:47:00 -05:00
Marek Safar 1b41e096fe [mcs] Suport recursive references of non-FX assemblies 2014-01-08 20:49:39 +01:00
Mario Kosmiskas a01e1ca877 Using the fully qualified assembly name in dependencies
Some assemblies fail to load without specifying the full name,
namely bundling an app that uses GTK
2014-01-08 11:32:28 -08:00
Zoltan Varga 22b3e7f2b1 [jit] Use the mono_restore_context () helper function in one place. 2014-01-08 16:58:33 +01:00
Zoltan Varga 7798b94706 [jit] Align the stack in mono_arch_restore_context () on x86 since it might be unaligned if it was captured asynchronously. 2014-01-08 16:56:03 +01:00
Zoltan Varga b5af5b72ca [jit] Fix some checks in the arm dyn call code. Fixes #17101. 2014-01-08 04:33:59 +01:00
Michael Hutchinson 91ed5dfbfc [xbuild] Suppress new window for child processes
BXC14584 - Console windows pop up during build with mono runtime
2014-01-07 22:23:13 -05:00
Michael Hutchinson 6bb2ab2f06 [xbuild] Add pkgconfig file for xbuild 12 2014-01-07 22:22:32 -05:00
Michael Hutchinson 84b473c086 [xbuild] Fix the xbuild 12 tests 2014-01-07 18:39:34 -05:00
Michael Hutchinson 15fedf3b08 [xbuild] Add binding redirects so old tasks work w/ new xbuild 2014-01-07 18:39:33 -05:00
Michael Hutchinson 794e185592 [xbuild] Remove Silverlight targets, they don't work w/o framework 2014-01-07 18:39:32 -05:00
Michael Hutchinson b22bf8cbbf [xbuild] Set correct DefaultToolsVersion for xbuild 12 2014-01-07 18:39:32 -05:00
Michael Hutchinson 76d9d6a458 [xbuild] Fix 12.0 toolset location and public API 2014-01-07 18:39:31 -05:00
Michael Hutchinson 92ac9868a3 [xbuild] Fix 12.0 tasks 2014-01-07 18:39:30 -05:00
Michael Hutchinson 6926accf40 [xbuild] MSBuild 12 toolset should be available for XBUILD_12 2014-01-07 18:39:30 -05:00
Michael Hutchinson 47cb8c24c8 [xbuild] Update printed version/copyright 2014-01-07 18:39:29 -05:00
Michael Hutchinson 5e70ba51a0 [xbuild] Make xbuild script point to xbuild 12 2014-01-07 18:39:29 -05:00
Michael Hutchinson 3313d9ee10 [xbuild] Install data files for xbuild 12 2014-01-07 18:39:28 -05:00
Michael Hutchinson 425fdc03fa [xbuild] Build & install MSBuild 12.0 assemblies 2014-01-07 18:39:27 -05:00
Rodrigo Kumpera c8a343cf30 [runtime] ves_icall_type_is_assignable_from should not init its arguments as this is done properly by its callees. 2014-01-07 17:47:02 -05:00
Rodrigo Kumpera decc91e8da [runtime] Make mono_class_is_assignable_from lazy resolve its arguments.
Drop the requirement to call mono_class_init in mono_class_is_assignable_from.

The solution is not ideal as it relies on mono_class_implement_interface_slow which
is significantly slower than the regular checks and is less tested / complete.

The right approach here would be to promote setup_offsets to have proper laziness and
not be hidden behind vtable initialization. Until this happen we can't drop the
usage of the slow variant here.
2014-01-07 17:41:26 -05:00
Rodrigo Kumpera bc6387b7dd [runtime] Make mono_class_is_assignable_from_slow handle arrays. 2014-01-07 17:32:13 -05:00
Zoltan Varga 208c3ed412 [jit] Fix the loading of arguments received on the stack on arm. 2014-01-07 18:47:54 +01:00
Atsushi Eno 9dbcf29891 Merge branch 'msbuilddll2' of https://github.com/atsushieno/mono into msbuilddll2
Conflicts:
	mcs/tools/msbuild/ErrorUtilities.cs
	mcs/tools/msbuild/Main.cs
	mcs/tools/msbuild/Parameters.cs
	mcs/tools/msbuild/SolutionParser.cs
2014-01-08 01:13:11 +09:00
Atsushi Eno 67c6be79ab several fixes to load get buildable Project and run working builds. 2014-01-08 00:48:38 +09:00
Atsushi Eno 4640310ab0 BuildEngine4 must not be reused as IBuildEngine when building another project by <MSBuild> task. Set current directory. 2014-01-08 00:48:28 +09:00
Atsushi Eno 9a1fa0225e Unlike MS.Build.Engine, sln files cannot be supported in MS.Build.dll, so deal with them in this tool. 2014-01-08 00:48:21 +09:00
Atsushi Eno 0c9f224f1e skip Condition and ContinueOnError as task parameters. Do not use null toolsVersion as is in IBuildEngine2 implementation.
Conflicts:
	mcs/class/Microsoft.Build/Microsoft.Build.Internal/BuildEngine4.cs
2014-01-08 00:48:10 +09:00
Atsushi Eno 17183a6fbf Merge branch 'master' into msbuilddll2
Conflicts:
	mcs/class/Microsoft.Build.Engine/Microsoft.Build.BuildEngine/ConsoleLogger.cs
	mcs/class/Microsoft.Build/Microsoft.Build.Evaluation/Project.cs
	mcs/class/Microsoft.Build/Microsoft.Build.Execution/ProjectInstance.cs
	mcs/class/Microsoft.Build/Microsoft.Build.Execution/ProjectTargetInstance.cs
2014-01-08 00:20:29 +09:00
Zoltan Varga 50b0ab321a [aot] Disable aot for methods with tail calls in non full-aot mode, instead of compiling them without tail calls. 2014-01-07 16:17:57 +01:00
Zoltan Varga 5fbf9f1d11 [jit] Pass flags to mini_method_compile () as an enum. 2014-01-07 16:14:36 +01:00
Atsushi Eno 9676535077 Use ProjectInstance's DefaultTargets which also covers imports. 2014-01-08 00:09:35 +09:00
Atsushi Eno f20299d09a Add test for DefaultTargets handling with imports. 2014-01-08 00:09:34 +09:00
Atsushi Eno 6e33f6f724 rename some use of "xbuild" to "msbuild". Give loggers to ProejctInstance.Build() as expected. 2014-01-08 00:09:34 +09:00
Atsushi Eno c304f080a7 Add logger related tests (to sort out those Loggers properties relationship) 2014-01-08 00:09:33 +09:00
Atsushi Eno 96fe7c8372 update .sln too. 2014-01-08 00:09:33 +09:00
Atsushi Eno c915716227 Update .csproj (to add MSBuild.csproj). 2014-01-08 00:09:32 +09:00
Atsushi Eno 3bcf27afc1 Add experimental "MSBuild.exe" implementation which is based on Microsoft.Build.dll.
Conflicts:
	mcs/tools/msbuild/Main.cs
	mcs/tools/msbuild/SolutionParser.cs
2014-01-08 00:09:30 +09:00
Martin Baulig d8a1b2b353 [PCL]: Add ReadOnlyDictionary type-forwarder for XI. Fixes #16951. 2014-01-07 16:07:17 +01:00
Zoltan Varga a449c18d7a [jit] Disable tail calls in AOT mode so methods using tail calls can be AOT-ed. 2014-01-07 15:46:27 +01:00
Zoltan Varga 0ac4a74e51 [aot] Don't pass -W option to the clang assembler, it causes a warning. 2014-01-07 15:46:27 +01:00
Atsushi Eno 00c52b4cdd Revert "Remove private sln/csproj files."
I need these projects while I'm hacking MSBuild.

This reverts commit f188c158d4.
2014-01-07 22:47:47 +09:00
Atsushi Eno fde7b35e03 Fix mobile builds. 2014-01-07 22:33:06 +09:00
Atsushi Eno 7034ffa8b0 Fix mobile builds. 2014-01-07 22:32:26 +09:00
Atsushi Eno ebbc1b57b5 several fixes to load get buildable Project and run working builds. 2014-01-07 22:04:42 +09:00
Atsushi Eno ffb97e6fb8 BuildEngine4 must not be reused as IBuildEngine when building another project by <MSBuild> task. Set current directory. 2014-01-07 22:04:42 +09:00
Atsushi Eno b827e1f37c Unlike MS.Build.Engine, sln files cannot be supported in MS.Build.dll, so deal with them in this tool.
Conflicts:
	mcs/tools/msbuild/Main.cs
	mcs/tools/msbuild/SolutionParser.cs
2014-01-07 22:03:51 +09:00
Atsushi Eno d1e7c3be8b skip Condition and ContinueOnError as task parameters. Do not use null toolsVersion as is in IBuildEngine2 implementation. 2014-01-07 22:02:03 +09:00
Atsushi Eno 39a76b7d38 Evaluate Condition each Import within ImportGroup. 2014-01-07 22:02:02 +09:00
Zoltan Varga 2e1dc1864c [jit] Allocate MonoJumpInfo structures using alloc0. 2014-01-07 13:32:40 +01:00
Zoltan Varga 81295dd502 [runtime] Update copyright date in --version. 2014-01-07 11:54:52 +01:00
Alex Rønne Petersen d8feb5e9ad Allow creating MemoryMappedFiles with an in-memory and on-disk capacity of zero on Unix.
This is necessary to map special files such as /dev/mem.
2014-01-06 21:41:48 +01:00
Zoltan Varga eae1c9cb84 Merge pull request #865 from madewokherd/icallinit
Initialize icalls before exceptions.
2014-01-06 11:02:34 -08:00
Vincent Povirk 149e786af4 Initialize icalls before exceptions.
This commit licensed as MIT/X11.
2014-01-06 12:48:51 -06:00
Marek Safar e83bf13866 [corlib] Mark all promise-style task exceptions observed. Fixes #17015 2014-01-06 17:52:19 +01:00
Atsushi Eno 31a2e167f5 [rx][iOS] Do not try to generate doc comments with build properties, they don't work so far. 2014-01-07 00:55:14 +09:00
Marek Safar e619ed7765 [mcs] Emit Debuggable attribute. Fixes #16924 2014-01-06 15:24:33 +01:00
Marek Safar 76d899d494 [System.Web] Clean up assembly level attributes. 2014-01-06 12:05:42 +01:00
Marek Safar 2ce91c2481 [mcs] Method group caching needs to consider type arguments as well. Fixes #17059 2014-01-06 11:10:09 +01:00
Marek Safar 605b949141 New test 2014-01-06 11:10:08 +01:00
Zoltan Varga 3dba964da7 [jit] Save/restore all-callee saved registers in methods using some atomic opcodes on x86, since the opcode implementations use these registers, and the push/pop code used by these opcodes is not async safe, since the unwind code doesn't know about it. Fixes part of #16808. 2014-01-06 01:20:12 +01:00
Zoltan Varga 9921b0306f [runtime] Fix yet another metadata problem with dynamically created types. Fixes #14977. 2014-01-05 16:47:03 +01:00
Zoltan Varga c0278865da [jit] Fix the handling of OP_ISUB_IMM in abcrem. 2014-01-05 11:59:06 +01:00
Zoltan Varga 7efa9e3134 Merge pull request #852 from ranma42/abc-64bits
Improve ABCREM
2014-01-05 02:57:37 -08:00
Zoltan Varga a4eddbe982 [sdb] Add async variants to the InvokeMethod methods. 2014-01-05 11:32:35 +01:00
Linquize 3cc0e3fe3d If HTTP charset header is empty, do not append content encoding to Content-Type header 2014-01-05 16:56:05 +08:00
Zoltan Varga 01f587ef97 [jit] Emit calls to class init trampolines for fields accesses inside inline methods in AOT mode. Fixes #16461. 2014-01-05 02:03:30 +01:00
Zoltan Varga 41c521df6f [runtime] Avoid RuntimeHelpers.EnsureSufficientExecutionStack () failing on windows. Works around #16776. 2014-01-05 00:58:47 +01:00
Zoltan Varga a4070ceb60 [runtime] Call mono_class_setup_methods () before accessing klass->method.count. Fixes #16883. 2014-01-05 00:50:59 +01:00
Robert 'Bobby' Zenz ea33947ba3 Noted that the fullname attribute is not the same as Type.FullName.
Because of Cecil the fullname attribute does expect the fullname attribute to be in the format of ECMA-335. This is in certain cases not the same as the name reported by Type.FullName.

See jbevain/cecil#150 for some details on this.
2014-01-04 19:10:23 +01:00
Marek Safar 65f5704a2c [corlib] Update datetime patters. Fixes #17044 2014-01-04 15:33:24 +01:00
Marek Safar 46d83567ac [mcs] Type arguments resolve failure needs to be reported after probing mode 2014-01-04 15:33:12 +01:00
Marek Safar 48537ccc00 [mcs] Better check for value type base call. Fixes #16806 2014-01-04 15:33:11 +01:00
Marek Safar a62c32736f [mcs] Await flow analysis uses resolved expression. Fixes #16840 2014-01-04 15:33:11 +01:00
Zoltan Varga 0ed2afe61d [gsharedvt] Avoid using the variable size code paths for non-variable size types with some array opcodes. Fixes #17023. 2014-01-04 13:18:58 +01:00
Marek Safar 1913a6900b Merge pull request #858 from madewokherd/datavis
System.Windows.Forms.DataVisualization fixes
2014-01-04 02:05:03 -08:00
Marek Safar 996a249ff2 Merge pull request #859 from antoniusriha/groupDescription
Implement GroupDescription based on moonlight implementation
2014-01-04 00:51:42 -08:00
Zoltan Varga fefb5f9b7b [jit] Avoid nullifying class init trampolines for recursive calls to class initializers. Fixes #16489 2014-01-04 01:15:21 +01:00
Rodrigo Kumpera 79a3a432a7 [sdb] The sdb library depends on Process.Start returning a Process object, so force UseShellExecute to false.
This fixes a massive breakage on wrench.
2014-01-03 15:27:19 -05:00
Antonius Riha 57c18def14 Implement GroupDescription based on moonlight implementation 2014-01-03 21:15:32 +01:00
Vincent Povirk 21bc38b80d Avoid infinite loop in property getter.
This commit licensed as MIT/X11.
2014-01-03 12:46:00 -06:00
Vincent Povirk 3d387843cd Change System.Windows.Forms.DataVisualization PKT to match Windows.
This commit licensed as MIT/X11.
2014-01-03 12:45:52 -06:00
Zoltan Varga 0a558a7af6 Remove usage of mini_replace_type () from mono_jit_runtime_invoke (), runtime invokes care about the precise types of parameters. Fixes #16830. 2014-01-03 14:49:08 +01:00
Zoltan Varga 0a1f1fe87c [aot] Sanitize utf8 characters in symbol names. Fixes #16851. 2014-01-03 13:17:49 +01:00
Michael Hutchinson b3b28212f6 Merge pull request #822 from carlosmn/asp-pc
Use full path for aspnetwebstack pkg-config file
2014-01-02 17:19:57 -08:00
Michael Hutchinson 79e63ca4a9 Merge pull request #849 from antoniusriha/pcCacheBug
Fix for PkgConfig cache orphaned entries bug (xam bug #11133)
2014-01-02 16:58:37 -08:00
Rodrigo Kumpera 8bc8d64457 Merge pull request #838 from desdesdes/master
Implementation of System.Reflection.ParameterInfo.HasDefaultValue
2014-01-02 15:49:51 -08:00
Bart Vries 3d1779302e Implementation of System.Reflection.ParameterInfo.HasDefaultValue 2014-01-03 00:15:52 +01:00
Vincent Povirk 539862aded Avoid adjusting selection twice in TextControl.
This commit licensed as MIT/X11.
2014-01-02 16:28:49 -06:00
Antonius Riha 726fe38c48 Remove obsolete pc infos from pc cache on Update()
The pc info file cache (~/.config/xbuild/pkgconfig-cache-2.xml) stored data
for files which don't exist anymore on the system which causes
https://bugzilla.xamarin.com/show_bug.cgi?id=11133.

This patch removes obsolete entries from the cache when
PcFileCache.Update() is called.
2014-01-02 21:14:54 +01:00
Antonius Riha 3fcb8f8a6c Remove redundant pc info store.
* PcFileCache.filesByFolders held copies of the package infos in
  PcFileCache.infos grouped by the resp. pkg config directories the pc files
  resided in.

* Rewrite GetPackages:
    - Returns a snapshot-in-time IEnumerable<PackageInfo> ordered by pkg config
      folder.
    - Noramilzes paths of pkgConfigDirs parameter

* Remove now superfluous method PcFileCache.Add(,,)
2014-01-02 21:14:53 +01:00
Antonius Riha 37c3ac78f5 Add a test for PcFileCache.GetPackages() 2014-01-02 21:14:53 +01:00
Antonius Riha bbd2412985 Setup PcFileCache stubs and ctor tests 2014-01-02 21:14:53 +01:00
Antonius Riha 9ac4fc1b52 Move internals from Microsoft.Build.Tasks to new dll Mono.XBuild.Tasks
All internal members (such as PcFileCache) have been made public to make them unit-testable.

* mcs/class/Makefile: Add Mono.XBuild.Tasks as build target

* mcs/class/Microsoft.Build.Tasks/Makefile: Add Mono.XBuild.Tasks.dll as build
  reference of Microsoft.Build.Tasks.dll

* mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_2_0.csproj:
* mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_3_5.csproj:
* mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_4_0.csproj:
* mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks-net_4_5.csproj: Remove
  source files, which have been moved to Mono.XBuild.Tasks.dll and add a
  project reference to Mono.XBuild.Tasks.dll

* mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks.dll.sources: Remove
  files that have been moved to Mono.XBuild.Tasks.dll from
  Microsoft.Build.Tasks.dll

* mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks/PcFileCache.cs:
* mcs/class/Microsoft.Build.Tasks/Microsoft.Build.Tasks/LibraryPcFileCache.cs:
  This file was moved to Mono.XBuild.Tasks.dll

* mcs/class/Mono.XBuild.Tasks/Assembly/AssemblyInfo.cs: Moved from
  Microsoft.Build.Tasks.dll. Signing key is mono.pub.

* mcs/class/Mono.XBuild.Tasks/Mono.XBuild.Tasks/PcFileCache.cs:
* mcs/class/Mono.XBuild.Tasks/Mono.XBuild.Tasks/LibraryPcFileCache.cs:
  Moved from Microsoft.Build.Tasks.dll. All internal members have been made
  public.

* mcs/class/Mono.XBuild.Tasks/Test/Mono.XBuild.Tasks/PcFileCacheTest.cs: Create
  test file stub.
2014-01-02 21:14:53 +01:00
Marek Safar 4248ffaf1c [mcs] Don't wrap reference type values in explicit nullable conversion. Fixes #16900 2014-01-02 18:53:09 +01:00
Marek Safar a9eb08036e Merge pull request #855 from echampet/spec
Fix a small typo in mono-core.spec.in breaking the build
2014-01-02 09:37:47 -08:00
Marek Safar c9f9f94d36 Merge pull request #854 from antoniusriha/sortDescription
Make SortDescriptionCollection returned by SortDescriptionCollection.Empty read-only
2014-01-02 08:47:42 -08:00
Marek Safar 9a36b4fd76 [eval] Consider base type members in tab completion 2014-01-02 17:40:10 +01:00
Antonius Riha 3e28c643b0 Make empty SortDescriptionCollection read-only.
This is in accordance with the behavior of SortDescriptionCollection in .NET.
2014-01-02 17:31:36 +01:00
Antonius Riha 9e20dc9fa8 Add tests for empty, non-modifiable SortDesriptionCollection 2014-01-02 17:31:22 +01:00
Etienne CHAMPETIER 3109cc5fb4 Fix a small typo in mono-core.spec.in breaking the build
Signed-off-by: Etienne CHAMPETIER <[email protected]>
2014-01-02 17:02:26 +01:00
Marek Safar 2ccb89fd97 [mcs] Restore async modifiers context after nested enums declaration. Fixes #16997 2014-01-02 14:18:42 +01:00
Marek Safar 99aa6cf9b2 [corlib] Promise style tasks cannot be started manually. Fixes #16857 2014-01-02 14:13:00 +01:00
Andrea Canciani 6c0fa0d567 Improve ABCREM on 64-bits architectures
Array indexes can be 32-bits integers even on 64-bits
architectures. This causes most loops to fail Array Bounds Checking
REMoval because the index is sign-extended before the check (see
mini_emit_ldelema_1_ins).

Sign-extending an I4 to I8 preserves its value, hence it is possible
to propagate the relation between the variables.
2014-01-01 18:55:23 +01:00
Marek Safar 92887027be [system] Make ICommand 4.5 profile only 2014-01-01 15:30:06 +01:00
Marek Safar dce005f81f [corlib] Thread.GetNamedDataSlot allocates slot on failure. Fixes #16788 2014-01-01 15:28:40 +01:00
Marek Safar 12e28957fc Merge pull request #851 from ranma42/fix_16992v2
Fix bug #16992
2014-01-01 02:01:09 -08:00
Andrea Canciani 6395563467 Use LIFO policy for CancellationTokenSource
The .NET implementation of CancellationTokenSource invokes the
callbacks in the opposite order from that of the registration.
In order to mixamize compatibility, use the same order.

Fixes ReEntrantRegistrationTest, Cancel_Order, Cancel_ExceptionOrder
(in CancellationTokenSourceTest) and
https://bugzilla.xamarin.com/show_bug.cgi?id=16992
2013-12-31 22:01:46 +01:00
Andrea Canciani 0ac0c15211 Add testcases for callback and exception ordering
Translated from the F# testcases available here
https://github.com/fsharp/fsharp/blob/19507b98bc6a7995e9c19c40f044fdfeb578ef77/src/fsharp/FSharp.Core.Unittests/FSharp.Core/Microsoft.FSharp.Control/Cancellation.fs#L100
2013-12-31 22:01:27 +01:00
Andrea Canciani 33178ca69c Fix CancellationTokenSourceTest.ReEntrantRegistrationTest
This test run on .NET would result in both "unregister" and "register"
set to a "true" value. In order to ensure that the "unregister = true"
fragment is not executed, its disposal needs to be registered after,
because on .NET the CancellationTokenSource has a LIFO behavior.

This change simplifies the code and makes the expected behavior
consistent with that of .NET.
2013-12-31 22:00:34 +01:00
Rodrigo Kumpera 87e820dfe0 Merge pull request #847 from ranma42/fsharp-tuple-hashing
F#-compatible tuple hashing
2013-12-26 10:05:41 -08:00
Andrea Canciani 648782fa2e Make tuple hash function consistent with the F# implementation
The F# compiler optimizes the hashing of tuples when it can inline
it. This is consistent with the hashing algorithm used in .NET, but it
is not with the one used in Mono, as pointed out in
https://github.com/fsharp/fsharp/issues/188

This patch modifies Tuples.cs so that the hashing algorithm is the
same as that used in F#, i.e. the XOR variant of DJB2, using a
balanced tree parenthesization.
2013-12-26 17:50:03 +01:00
Andrea Canciani de70cc72ff Fix Tuples.cs code generator
The code generator in Tuple.cs did not build because of missing
escaping of a string.
2013-12-26 17:45:46 +01:00
Marek Safar 20d948f98e Merge pull request #846 from abatishchev/patch-1
String.Join() calls List(IEnum) instead of looping
2013-12-24 00:21:46 -08:00
Alexander M. Batishchev e5618d9e15 String.Join() calls List(IEnum) instead of looping
String.Join() instead of looping over IEnumerable<T> calls the constructor of List<T> accepting IEnumerable<T>.
According to https://github.com/mono/mono/blob/master/mcs/class/corlib/System.Collections.Generic/List.cs#L67 it should be more efficient.

Because JoinUnchecked() accepts string[] the option #2 is to call ToArray() extension method instead.
https://github.com/mono/mono/blob/master/mcs/class/System.Core/System.Linq/Enumerable.cs#L2886
2013-12-23 19:57:03 -08:00
Rolf Bjarne Kvinge 3c928782dd Don't call CFNetworkCopyProxiesForAutoConfigurationScript from more than one thread. Fixes #7923, comment 21. 2013-12-24 00:51:01 +01:00
Richard Meyer e90b9743fc Updated various mime types, sources in description
http://blogs.msdn.com/b/vsofficedeveloper/archive/2008/05/08/office-2007-open-xml-mime-types.aspx

http://support.microsoft.com/?id=936496

http://www.rfc-editor.org/rfc/rfc4329.txt

Also added svg image/svg+xml
2013-12-23 16:01:53 -06:00
Richard Meyer 0ff662fa25 Support for audio/ogg and audio/mp4
.ogg, .oga audio/ogg
.mp4a, .aac audio/mp4
http://tools.ietf.org/html/rfc4337
2013-12-23 15:11:46 -06:00
meyerrj c9434cdb79 Support for video/mp4, video/ogg, video/webm
Added support for the three leading HTML5 Video mime types
.mp4 video/mp4
.ogv video/ogg
.webm video/webm

When Internet Explorer 10 or 11 receives application/octet-stream as the mime type for HTML5 video, it will not play the video. This resolves the issue in an Apache/mod_mono environment.
2013-12-23 04:01:06 -06:00
scottmcarthur 7a5ab1d8c9 Test for bug 16902
Check insert of null item, in a BindingList<T> where T implements INotifyPropertyChanged does not cause NullReferenceException.
2013-12-22 18:08:16 +00:00
scottmcarthur 6150625424 Check for null item in BindingList<T>.InsertItem
Prevents `NullReferenceException` when inserting `null` object into `BindingList<T>` where `T` implements `INotifyPropertyChanged`
2013-12-21 17:28:35 +00:00
Alex Rønne Petersen d7ce227abe Handle 12.00 in XBuild's SolutionParser.
This doesn't fix support for VS 2013 projects, but it's a start...
2013-12-21 09:57:45 +01:00
Sebastien Pouliot 69d82906cb Do not assume the first certificate of a PKCS12 file is the one matching the key (even if it's the most common way). ref: desk #54722 2013-12-18 14:21:23 -05:00
Sebastien Pouliot 4ec15d9627 Switch to File.ReadAllBytes since we do not have to support pre-2.0 code 2013-12-18 14:21:23 -05:00
Sebastien Pouliot 2c58476bbb Replace custom Load with File.ReadAllBytes 2013-12-18 14:21:22 -05:00
Marek Safar 12dc6607ee Merge pull request #841 from knocte/master
[System] Change S.N.S.NetworkStream's param name on ctor
2013-12-18 01:00:31 -08:00
Andrés G. Aragoneses bd964bab4b [System] Change S.N.S.NetworkStream's param name on ctor
Changed to the name that is used in MS.NET:
http://msdn.microsoft.com/en-us/library/te7e60bx%28v=vs.110%29.aspx

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=16832
2013-12-17 23:09:22 +01:00
Horst Kakuschke 88af4836ad Cleaned up the using statements in DateTime tests 2013-12-17 15:42:25 +01:00
Horst Kakuschke 280fe42c65 Additional tests for Xamarin Bug 16742 + style enhancements 2013-12-17 13:53:25 +01:00
Alex Rønne Petersen bed99adf75 Merge pull request #839 from glinos/master
Implemented System.Threading.Monitor.IsEntered
2013-12-16 22:04:01 -08:00
Harry Glinos 245e3c11fa Implemented System.Threading.Monitor.IsEntered 2013-12-16 23:23:02 -06:00
Rodrigo Kumpera 5066972814 [System] When starting a process with UseShellExecute=true, don't return a process. Fixes #16119 2013-12-16 17:13:06 -05:00
Rodrigo Kumpera ee07f97545 [io-layer] On OSX don't pass -W to open as we don't care for it waiting. 2013-12-16 16:55:16 -05:00
Rodrigo Kumpera 6c06d10995 [runtime] Don't pass SEE_MASK_NOCLOSEPROCESS to ShellExecuteEx as we don't care for the launched process. Part 1/3 of Bug #16119.
The System.Diagnostics.Process API always return a null process when starting with UseShellExecute=true.
This means we should not track the launched process and not gather information regarding it.
2013-12-16 16:50:40 -05:00
Rodrigo Kumpera a17ce06e42 [runtime] A thread without a domain set cannot be running managed code. Fixes #16794. 2013-12-16 14:14:42 -05:00
Atsushi Eno d4afca2276 Updated Rx to 2.2 release. 2013-12-17 03:30:39 +09:00
Martin Baulig 2c4d09109c [runtime]: Cosmetic, fix log level on diagnostic PCL remapping messages. 2013-12-16 18:10:48 +01:00
Miguel de Icaza 8bfc95c49a Updated documentation 2013-12-16 13:03:18 -02:00
Marek Safar edbcca9467 [doc] Document CurrentCultureInfo 2013-12-16 13:58:43 +01:00
Zoltan Varga 3312a1af0c [aot] Give the compilation unit entries in the DWARF debug info different names, the osx tools seem to need this (#15202). 2013-12-16 01:24:53 +01:00
Zoltan Varga 32861b70dd [aot] Add runtime wrappers for methods of generic classes and generic methods. Fixes #16747. 2013-12-15 03:02:34 +01:00
Zoltan Varga 5b6c4ceb68 [gsharedvt] Add a wrapper to the mono_gsharedvt_constrained_call () icall, since it calls mono_runtime_invoke () which can throw exceptions. Fixes #16439. 2013-12-14 22:15:08 +01:00
Zoltan Varga 1dcee202f4 [jit] Remove an extra newline from a mono_trace () call. 2013-12-14 08:10:32 +01:00
Zoltan Varga 07dd8f8568 [jit] Fix TLS+AOT support in the monitor enter/exit trampolines. 2013-12-14 08:08:01 +01:00
Zoltan Varga b1693a8109 [jit] Cache gsharedvt types in get_gsharedvt_type (). 2013-12-14 07:05:22 +01:00
Zoltan Varga 9e5f1db551 [jit] Fix memory leaks in get_gsharedvt_type (). Fixes #16787. 2013-12-14 06:52:11 +01:00
Zoltan Varga cc46700633 Disable the bin writer on osx, it only works with xdebug, but the AOT compiler tries to use it as well. 2013-12-14 06:51:21 +01:00
Marek Safar 01b7a50189 [corlib] Don't inline await continuations when the context does not allow it. Fixes #16548 2013-12-13 17:09:24 +01:00
Rodrigo Kumpera 7ea732a51c Merge pull request #832 from xplicit/webperf1
Header names should be compared binary but not linguistic.
2013-12-13 07:24:06 -08:00
Zoltan Varga f6e4c12036 Revert "[gsharedvt] Avoid using gsharedvt trampolines for calls with a non-variable signature."
This reverts commit 38b6a9dffd.

Revert this as it causes failures in tests.
2013-12-12 23:58:25 +01:00
Zoltan Varga d04f68bf2b Merge pull request #837 from madewokherd/update-def
Update msvc .def files
2013-12-12 14:35:24 -08:00
Rodrigo Kumpera 2c0ed72458 [jit]Replace usage of mini_type_get_underlying_type with first arg null with new function mini_replace_type. 2013-12-12 17:04:17 -05:00
Rodrigo Kumpera a7029a72ba [jit] Properly wire the MGSC in the amd64 backend. 2013-12-12 17:04:17 -05:00
Zoltan Varga d24e0ade72 Merge pull request #806 from AxlPr/master
Fixed  g_win32_getlocale
2013-12-12 13:51:14 -08:00
Vincent Povirk 4162ac8716 Update msvc .def files.
This commit licensed as MIT/X11.
2013-12-12 15:50:38 -06:00
Vincent Povirk a4821b47a6 Exclude some functions that aren't on win32.
This commit licensed as MIT/X11.
2013-12-12 15:50:29 -06:00
Zoltan Varga b09b63db8b Merge pull request #836 from madewokherd/buildfixes
various build fixes
2013-12-12 13:49:54 -08:00
Vincent Povirk 3d590a378a Update create-windef.pl to account for sgen/boehm compiles.
This commit licensed as MIT/X11.
2013-12-12 15:23:24 -06:00
Miguel de Icaza 758246c2aa Update 2012 changes to sgen license 2013-12-12 12:31:57 -05:00
Marek Safar e586b796b1 [corlib] Mark ConcurrentDictionary serializable. Fixes #16730 2013-12-12 11:32:36 +01:00
Marek Safar 74e946bd85 Merge pull request #834 from OttoG/master
Stub implementation of EndGetRequestStream overload in HttpWebRequest.cs
2013-12-11 23:44:27 -08:00
Vincent Povirk 71c0296e69 Add HAVE_DECL_INTERLOCKED* symbols to winconfig.h.
This commit licensed as MIT/X11.
2013-12-11 17:23:26 -06:00
Vincent Povirk e6db4097a8 Update file listinigs in msvc projects. 2013-12-11 17:23:01 -06:00
Vincent Povirk acb851f494 Include config.h in mono-tls.c.
This commit licensed as MIT/X11.
2013-12-11 17:22:23 -06:00
Vincent Povirk bceebec90c Check for InterlockedDecrement64 in configure.
We already have code looking for the corresponding symbol.

This commit licensed as MIT/X11.
2013-12-11 17:21:26 -06:00
Rodrigo Kumpera 09e65ba543 [bcl] When finalizing a Process object, don't touch the streams as they are finalized on their own. Fixes #10883. 2013-12-11 17:15:12 -05:00
OttoG e4a09c8613 Changed compiler directive according to documentation
EndGetRequestStream with TransportContext parameter was introduced in .NET 3.5. Also added "using" statement for System.Net (namespace for TransportContext).
2013-12-11 22:03:18 +01:00
Horst Kakuschke 2ff1bf33aa Fixes Xamarin Bug 16742: XmlConvert.ToDateTime(string, XmlDateTimeSerializationMode) throws index out of bounds exception
Fix for bug + added tests for method
XmlConvert.ToDateTime(string, XmlDateTimeSerializationMode)
2013-12-11 20:14:17 +01:00
Marek Safar cd7f8a4ae8 [system] Make TransportContext 3.5 api 2013-12-11 20:03:18 +01:00
Marek Safar f7f54fa01a [mcs] Clone labeled statements cache in probing mode. Fixes #16376 2013-12-11 20:03:17 +01:00
Zoltan Varga 42f7b0bdd7 Make a test work in the presence of llvm optimizations. 2013-12-11 19:20:14 +01:00
Zoltan Varga 1d654c8828 [jit] Fix a problem in the liveness pass, where the variable which was only used in the first instruction of the first bblock was incorrectly marked as dead. 2013-12-11 19:19:53 +01:00
Rodrigo Kumpera 7888d9f224 [jit]Reenable int/long/double -> float rounding tests. 2013-12-11 11:15:25 -05:00
Rodrigo Kumpera cbf44a1e55 [jit]Emit explicit float rounding on amd64. Fixes #15987 2013-12-11 11:15:25 -05:00
Rodrigo Kumpera 88e7ef4729 [arch]Add cvtsi2ss to amd64 codegen. 2013-12-11 11:15:24 -05:00
OttoG a9079357c6 Stub implementation of EndGetRequestStream overload in HttpWebRequest.cs
I am not sure if a "do-nothing" implementation like this is acceptable in the Mono code base, but it does solve the problem described in https://bugzilla.xamarin.com/show_bug.cgi?id=12875 (successfully executing simple requests using the Google API .NET client library).
2013-12-11 12:35:57 +01:00
Sebastien Pouliot e4dcfc71ff [tests] Fix some corlib unit tests to run successfully on iOS 2013-12-10 21:48:09 -05:00
Martin Baulig d0d5f5a0d8 [corlib]: Add stubs for the remaining `System.Runtime.InteropServices.WindowsRuntime' APIs. 2013-12-11 02:13:18 +01:00
Martin Baulig 1908e1dce6 [PCL]: Add new 'System.Runtime.InteropServices.WindowsRuntime' Facade Assembly.
FIXME: This is only a stub, the only type currently present is
       `System.Runtime.InteropServices.WindowsRuntime.EventRegistrationToken',
       which is only a stub.
2013-12-11 00:59:19 +01:00
Martin Baulig 7d238658ed [corlib]: Add 'System.Runtime.InteropServices.WindowsRuntime.EventRegistrationToken' stub. 2013-12-11 00:52:32 +01:00
Martin Baulig 37af8b7fe7 [PCL]: Add "System.Dynamic.Runtime.dll" Facade Assembly to MonoTouch.
Added the type-forwarder for `ConditionalWeakTable<T,V>', put all the
others inside a `!FULL_AOT_RUNTIME' conditional, then enabled this in
the MonoTouch build.
2013-12-11 00:44:37 +01:00
Rodrigo Kumpera 6b2137e66e [jit] Use mini_type_get_underlying in a few missing places in the jit. 2013-12-10 15:20:21 -05:00
Rodrigo Kumpera 73591211e3 [jit] Use mini_type_get_underlying in a few missing places in the jit. 2013-12-10 15:20:21 -05:00
Rodrigo Kumpera c3bcbb87c8 [jit] Use mini_type_get_underlying type in a few missing places in the x86 port. 2013-12-10 15:20:20 -05:00
Rodrigo Kumpera dbce960c82 [jit] Use mini_type_get_underlying type in a few missing places int the amd64 port. 2013-12-10 15:20:20 -05:00
Zoltan Varga 1786712331 [jit] Disable the optimized lmf push/pop code even if the arch specific code enables if it is not supported. 2013-12-10 18:33:53 +01:00
Mark Probst 85ef4bad2a [sgen] Explain a FIXME. 2013-12-10 18:19:02 +01:00
Mark Probst 08e9f6ec2e [sgen] Our bzero()/memmove() must store “volatile”, lest LLVM screw us. 2013-12-10 18:18:35 +01:00
Mark Probst 2effcc1b53 [sgen] Reverse the free-list after sweeping to be in address-order. 2013-12-10 15:13:41 +01:00
Mark Probst de75a12c63 [sgen] Only enqueue LOS objects if they contain references. 2013-12-10 15:13:41 +01:00
Marek Safar 39fa8bb4c2 [mcs] Update populated member cache of dynamic containers manually for additional entries. Fixes #16659 2013-12-10 11:12:23 +01:00
xplicit 583e8e07f6 Header names should be compared binary but not linguistic.
Moreover according to RFC2616 header names are subset of ASCII chars [0-127],
so culture-aware comparison is useless and eats too many processor time
(according to my benchmarks get an item from Hashtable with OrdinalIgnoreCase
comparers more than 20x times faster compared to Hashtable with InvariantCultureIgnoreCase
comparer)
2013-12-10 12:02:09 +07:00
Zoltan Varga c1908d7e47 [jit] Implement the delegate ctor optimization in AOT mode too. 2013-12-10 03:36:01 +01:00
Alex Rønne Petersen a07c846bc9 Merge pull request #831 from madewokherd/win64-warnings
fix various warnings in win64 exception code
2013-12-09 15:02:27 -08:00
Vincent Povirk 493d786a89 Fix MonoW32ExceptionHandler type on win64.
This commit licensed as MIT/X11.
2013-12-09 15:56:08 -06:00
Vincent Povirk 524362a752 Move a variable declaration to the start of a block.
This commit licensed as MIT/X11.
2013-12-09 15:56:02 -06:00
Vincent Povirk 9ee5928c57 Mark some functions as static.
This commit licensed as MIT/X11.
2013-12-09 15:55:57 -06:00
Vincent Povirk c79a76411a Adjust type of mono_win_vectored_exception_handle to match its use.
This commit licensed as MIT/X11.
2013-12-09 15:55:39 -06:00
Zoltan Varga e652c6d7f2 [corlib] Disable a test which causes a wapi_unref_full () warning. 2013-12-09 19:56:47 +01:00
Marek Safar c2385c5ebf [corlib] Update current LogicalCallContext from empty context 2013-12-09 19:12:34 +01:00
Marek Safar 90ff06c7c3 [mcs] Show correct #line location for files in other than current location referenced as relative files. Fixes #16576 2013-12-09 14:37:47 +01:00
Marek Safar 6ab86f50fd [system] Redirect of put requests was converted to get. Fixes #16670 2013-12-09 14:18:15 +01:00
Atsushi Eno 3217cdc7f9 Merge pull request #830 from akoeplinger/fix-net40-build
Fix NET_4_0 tests build by correcting accessibility of properties/classes...
2013-12-08 19:32:21 -08:00
Marek Safar e94da6da6c [corlib] Ignore awaited default synchronization context. 2013-12-08 21:24:32 +01:00
Alexander Köplinger f9c02685a0 Fix NET_4_0 tests build by correcting accessibility of properties/classes
that should be public according to MSDN, but were internal:

http://msdn.microsoft.com/en-us/library/microsoft.build.evaluation.project.targets(v=vs.100).aspx
http://msdn.microsoft.com/en-us/library/microsoft.build.execution.projectinstance.targets(v=vs.100).aspx
http://msdn.microsoft.com/en-us/library/microsoft.build.execution.projecttargetinstance(v=vs.100).aspx
2013-12-08 19:55:53 +01:00
Marek Safar b05fdd2562 [corlib] Not continue on awaited source context should also ignore user task schedulers 2013-12-08 10:42:13 +01:00
Marek Safar de61f61d53 [corlib] Keep original cancellation exception from awaited task 2013-12-08 10:42:12 +01:00
Marek Safar 6a84e4ed21 Add new test 2013-12-08 10:42:12 +01:00
Marek Safar 6cce4a3937 Merge pull request #817 from desdesdes/master
[Bug 14664] LogicalSet/GetData implementation in CallContext
2013-12-08 01:39:27 -08:00
Marek Safar 127ff387ba [corlib] Block configurable task awaiter until task completes. 2013-12-07 19:51:36 +01:00
Marek Safar 85aaf9b074 [corlib] Better handling of awaiter continuation on finished task 2013-12-07 19:51:36 +01:00
Marek Safar 395cf8f623 [corlib] Add check for launching cancelled task to all overloads 2013-12-07 19:51:35 +01:00
Rodrigo Kumpera 971eba81ac [sgen]Fix a deadlock when the GC try to free a JI during world restart. Fixes #15759
This is deadlock prone as the GC lock is a leaf lock while the domain
lock required to free a JI is not.

There are plenty of places where we alloc memory while holding the
domain lock, so we cannot do it the other way.
2013-12-06 15:23:02 -05:00
Zoltan Varga 26b81f1358 [bcl] Invoke assembly resolve hooks even if the assembly name has a parse error. Fixes #16487. 2013-12-06 19:40:05 +01:00
Marek Safar 6cc37a6607 [corlib] Optimize one string Join<T> overload. Fixes #16647 2013-12-06 19:32:46 +01:00
Bassam Tabbara 90f9595967 Convert blocking operations in HttpWebRequest and SslClientStream to non-blocking operations. This fixes #15451.
More details:
  * HttpWebRequest now writes the HTTP request headers asynchronously. This will avoid blocking a thread pool thread until the headers are written.
  * SslClientStream was doing the TLS negotiations in a blocking manner. Converted the negotiation method to an async state machine where all operations are done asynchronously.
  * The test case identified in #15451 now completes quickly with less than 15 threads created, vs. 100s of threads used before this fix.

Future work if needed:
  * I did not convert SslServerStream but the same pattern could be used here.
  * SendAlert is still blocking. I thought it was not worth converting it to non-blocking.
2013-12-06 09:32:22 -08:00
Francis Fisher f698a81dbf gdi32.dll redirection apply to non-windows only 2013-12-06 16:14:15 +00:00
Francis Fisher baadfab798 dllmap for BitBlt in gdi32.dll 2013-12-06 16:13:46 +00:00
Rodrigo Kumpera b535b6a553 [bcl] Handle BigInt -> long conversions that should overflow but dont. Fixes #16526 2013-12-06 11:13:29 -05:00
Rodrigo Kumpera ac7a23e3a8 Merge pull request #828 from mateusz-holenko/master
Fix build.
2013-12-06 07:38:52 -08:00
Marek Safar 13899a5658 [System.Net.Http] Don't throw on invalid input in TryGetValues. Fixes #16634 2013-12-06 16:35:34 +01:00
Marek Safar a485cff9de [mcs] Don't stop type inference when a unique construction of the generic interface cannot be found. Fixes #16567 2013-12-06 16:35:33 +01:00
Mateusz Hołenko b6e27528e8 Fix build. 2013-12-06 16:18:44 +01:00
Zoltan Varga 537bffffa6 [aot] Avoid emitting two debug_line sections when using the GAS .file and .loc directives. 2013-12-06 15:20:22 +01:00
Marek Safar bb44c68952 [mcs] Add better type conversion to unary mutators. Fixes #16578 2013-12-06 14:33:31 +01:00
Marek Safar c8d91bc505 Bump mscorlib version for monolite to work correctly 2013-12-06 09:50:21 +01:00
Marek Safar 164119d8c5 Partially revert 3019283237 2013-12-06 09:40:26 +01:00
Marek Safar c9311087d9 Improve test failure check 2013-12-06 09:39:30 +01:00
Zoltan Varga 3019283237 Fix the arm build with xcode 5.1. 2013-12-06 03:50:45 +01:00
Atsushi Eno f9b37c6939 Fix build. 2013-12-06 10:11:23 +09:00
Sebastien Pouliot 2ef208b1a6 [Test] Fix build of System.Core unit tests 2013-12-05 17:52:53 -05:00
Jonathan Pryor a699e7444e [Mono.Options] Improve error message for badly bundled args.
mono(1) supports a "joined" verbose flag, `mono -v-v-v-v`, which
Mono.Options doesn't support. Attempting to use it, however, resulted
in a "weird" error message:

	$ csharp -r:Mono.Options.dll
	csharp> using Mono.Options;
	csharp> var p = new OptionSet { { "v", v => {} } };
	csharp> p.Parse (new[]{"-v-v-v"});
	Mono.Options.OptionException: Cannot bundle unregistered option '--'.
	...

This looks very weird to users because they never used a "--" option,
and if they had then `--` would have disabled further option
processing (as documented and implemented in OptionSet.Parse()).

Confusion all around.

Improve the error message so that it instead generates:

	Mono.Options.OptionException: Cannot use unregistered option '-' in bundle '-v-v-v'.

That way the user gets the full context of where this "unregistered
option" came from.
2013-12-05 15:43:35 -05:00
Miguel de Icaza 37e3c51b13 Comment style; Wrap at 100 2013-12-05 14:43:53 -05:00
Miguel de Icaza 01c5c73599 Comment style 2013-12-05 14:42:48 -05:00
Sebastien Pouliot c1193a68d2 [Test] Ignore a test case if executed on the main thread 2013-12-05 14:35:34 -05:00
Rodrigo Kumpera f60bd66244 [lock-tracer]Update the decoder to handle the current runtime and OSX. 2013-12-05 14:11:58 -05:00
Rodrigo Kumpera 3ffae9f5df [lock-tracer]Workaround ASLR on OSX by recording offsets to the main binary base address. 2013-12-05 14:11:58 -05:00
Rodrigo Kumpera 8998e08d7d [runtime]Fix deregister_reflection_info_roots_from_list to avoid full type resolution during unload. 2013-12-05 14:11:58 -05:00
Rodrigo Kumpera e90df12b26 [runtime]Add the marshal lock to the lock tracer. 2013-12-05 14:11:58 -05:00
Rodrigo Kumpera f274be9b81 [runtime]Replace the loader lock with the marshal lock in mono_marshal_load_type_info.
In order to make this possible, we now construct the marshal information without holding
any locks and then double-check on publication.
2013-12-05 14:11:57 -05:00
Rodrigo Kumpera 7b2e5477d0 [runtime] Don't hold the loader lock when calling mono_mb_create_method.
mono_mb_create_method no longer requires the loader lock. All use sites
replace the loader lock with simpler locks.

Those new locks cannot be held while we're building the methods themselves
as that piece of code does type resolution - thus taking the loader lock.
2013-12-05 14:11:57 -05:00
Rodrigo Kumpera b15194d70b [runtime] The assembly bindings are now protected by a separate lock instead of the loader lock. 2013-12-05 14:11:57 -05:00
Rodrigo Kumpera 0e4ad400c1 [runtime] Change deregister_reflection_info_roots to not take the loader lock.
We should not need the loader lock here as this only deals with dynamic images
that belong to the current domain that is been shutdown.

To ensure this is the case, added an assert to mono_image_append_class_to_reflection_info_set.
2013-12-05 14:11:57 -05:00
Rodrigo Kumpera df30abe4e6 [runtime] Cleanup usage of reflection_info_unregister_classes. Move it under the image lock and use image memory. 2013-12-05 14:11:56 -05:00
Rodrigo Kumpera ffee0d25c8 [runtime] mono_metadata_clean_for_image no longer needs to return a free list of classes. 2013-12-05 14:11:56 -05:00
Rodrigo Kumpera d3d6158ecb [runtime] Protect mono_create_icall_signature with the corlib image lock. 2013-12-05 14:11:55 -05:00
Rodrigo Kumpera 6f916be5c8 [runtime] Protect MonoImage::generic_def_objects with the image lock and not the loader lock. 2013-12-05 14:11:55 -05:00
Rodrigo Kumpera 720c9f42c7 [runtime] Introduce the icall lock to be used when looking up icall related information. 2013-12-05 14:11:55 -05:00
Rodrigo Kumpera d9d9ea796a [runtime] Ensure mono_class_setup_supertypes is atomic and drop the loader lock around it. 2013-12-05 14:11:54 -05:00
Marek Safar ad13ff15b3 Merge pull request #827 from Blewzman/master
Support IReadOnlyList in System.Linq.Enumerable.ElementAt and ElementAtOrDefault
2013-12-05 11:09:11 -08:00
Marek Safar 8f089b2bdd [mcs] Convert dotted paths to full path 2013-12-05 20:04:38 +01:00
Blewzman f17a1808cc Small coding style fixes. 2013-12-05 19:49:04 +01:00
Blewzman 3eae2c2407 Support IReadOnlyList in System.Linq.Enumerable.ElementAt and ElementAtOrDefault - with additional unit tests. 2013-12-05 19:35:35 +01:00
Marek Safar 6886a6e916 [sle] Implement DynamicExpressionVisitor. 2013-12-05 13:05:23 +01:00
Marek Safar 7efbb345ce Bump ikvm-reflection 2013-12-05 11:59:52 +01:00
Atsushi Eno 62712bc64b In ConsoleLogger, add workaround for bogus use of EventSource senders in MS.Build.Engine.
See comments for details.
2013-12-05 18:08:29 +09:00
Marek Safar 3b664f331f [corlib] Implement task awaiters running on custom task scheduler. Fixes #16587 2013-12-05 09:51:56 +01:00
Alex Rønne Petersen e42840fdd9 Fix monograph to build under various --disable-boehm/--disable-libraries configurations. 2013-12-05 00:28:18 +01:00
Zoltan Varga e62565f1e4 Fix the pp64 build. 2013-12-05 00:13:05 +01:00
Zoltan Varga 6be4932222 Fix the windows build. 2013-12-04 23:07:40 +01:00
Alex Rønne Petersen e20c2ecc68 Also use __builtin_extract_return_addr in these files. 2013-12-04 20:54:50 +01:00
Alex Rønne Petersen 6a4a396ba0 Apply __builtin_extract_return_addr to the result of __builtin_return_address. 2013-12-04 20:48:44 +01:00
Alex Rønne Petersen 41400cb378 Fix some warnings in mini-arm.c. 2013-12-04 20:42:16 +01:00
Martin Baulig c64997288f [xbuild]: Fix the tests.
'TestMessageLogger.Count' should not be used in tests to check for the
number of logged messages because it would also includes diagnostic messages.

Extra diagnostic messages should not be considered an error condition; in
fact, we have too few diagnostic messages, not too many.

Use 'TestMessageLogger.NormalMessageCount' and 'TestMessageLogger.WarningMessageCount'
instead.
2013-12-04 20:38:10 +01:00
Alex Rønne Petersen 4917c94318 Fix some pointer/integer size issues in unwind.c on 32-bit systems. 2013-12-04 17:31:47 +01:00
Alex Rønne Petersen 41b80b909b Add a dummy assignment to shut GCC up. 2013-12-04 17:26:08 +01:00
Alex Rønne Petersen e2367fc957 Fix some warnings caused by always_inline functions not being marked inline. 2013-12-04 16:58:14 +01:00
Marek Safar 97bb0ff149 [corlib] Better conversion betwen system locale and CultureInfo. Fixes #15875 2013-12-04 16:47:08 +01:00
Alex Rønne Petersen 99fda9e5ed Fix some warnings in mini-amd64.c. 2013-12-04 15:27:54 +01:00
Alex Rønne Petersen 04ce9f30b0 Fix a couple of warnings in mini-exceptions.c. 2013-12-04 15:19:31 +01:00
Alex Rønne Petersen 9794a36a67 Fix more PPC warnings. 2013-12-04 15:19:18 +01:00
Alex Rønne Petersen 81d70cc5ce Fix a warning on PPC. 2013-12-04 15:08:46 +01:00
Zoltan Varga d2485bf370 Merge pull request #824 from hanswolff/patch-1
Fixed missing pointer conversion tests in sizes.c
2013-12-04 04:18:44 -08:00
Alex Rønne Petersen 5ed3db3596 Unbreak libgc. 2013-12-04 12:56:58 +01:00
Marek Safar ef3f3753b8 [corlib] CreateSpecificCulture without exception retry 2013-12-04 12:18:10 +01:00
Alex Rønne Petersen 69997b9b28 Remove some more mdb bits. 2013-12-04 11:37:52 +01:00
Marek Safar 0a9cbdd968 [corlib] Update CurrentRegion to work with DefaultThreadCurrentCulture 2013-12-04 10:46:51 +01:00
Mark Probst 6f4e1151e0 [sgen] Link unit test programs with all libs.
Should fix the build for monodroid.
2013-12-04 10:32:47 +01:00
Hans Wolff a2f850e178 Fixed missing pointer conversion tests in sizes.c
Unsigned pointer conversion was not tested at all (looks like a copy & paste mistake)
2013-12-04 10:09:11 +01:00
Martin Baulig 0d0f4ae035 [xbuild]: Check a <Target>'s "Returns" first, then fall-back to "Outputs".
This fixes a problem with the "Microsoft.Bcl.Build" NuGet package, which
overrides the "GetTargetPath" target in a custom .targets file and uses
"Returns" instead of "Outputs".
2013-12-04 01:58:06 +01:00
Martin Baulig 305ce0e382 [xbuild]: Provide diagnostic logging of all executed targets. 2013-12-03 23:35:28 +01:00
Martin Baulig 1cf4b6f02e [xbuild]: Allow expressions inside a dynamic <ItemGroup>'s metadata.
Fixes #14661.
2013-12-03 21:05:07 +01:00
Zoltan Varga 6d7dd9e9fc Fix the build. 2013-12-03 20:06:27 +01:00
Alex Rønne Petersen 8b74167481 [sdb] Support a setpgid=y/n option to --debugger-agent. 2013-12-03 19:41:10 +01:00
Mark Probst c9ff997797 [sgen] Never invoke libc’s memmove() or bzero().
Those two functions are not guaranteed to do word-atomic copying or
zeroing under any circumstances.  memmove() on OSX, for instance,
has an SSE optimized variant that, if source and destination are 8-byte,
but not 16-byte aligned, will copy the first 8 bytes byte-wise, which can
crash SGen.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=16449.
2013-12-03 19:27:41 +01:00
Marek Safar afbd51e876 [mcs] Report nice error instead of crash for cyclic type forwarders. Fixes #16385 2013-12-03 19:21:39 +01:00
Marek Safar ffba0b7378 [mcs] Report all failure errors in lambda conversions. Fixes #16513 2013-12-03 19:21:39 +01:00
Marek Safar 83f166c110 [corlib] Replace manual array resize with Resize call 2013-12-03 19:21:37 +01:00
Atsushi Eno b90937ef14 Fix android-specific build (use of unassigned variable). 2013-12-04 01:37:38 +09:00
Alex Rønne Petersen 73e4f1d4a6 Sanitize the kqueue check in configure.in. 2013-12-03 13:37:54 +01:00
Mark Probst cd0631b0ef [sgen] Fix build on Linux. 2013-12-03 02:24:04 -08:00
Alex Rønne Petersen b9bcafb382 Merge branch 'armhf' of github.com:alexrp/mono 2013-12-03 10:04:58 +01:00
Atsushi Eno f188c158d4 Remove private sln/csproj files. 2013-12-03 16:55:47 +09:00
Atsushi Eno b3d6490a35 update .csproj. 2013-12-03 16:53:30 +09:00
Atsushi Eno 06b0f3d28a Add missing exception types. 2013-12-03 16:53:30 +09:00
Atsushi Eno 4914ab0b6a ProjectCollection.DefaultToolsVersion is settable. 2013-12-03 16:53:29 +09:00
Atsushi Eno cac790f7ca Some parser error message got source string for Condition evaluation. 2013-12-03 16:53:28 +09:00
Atsushi Eno cafdbf84dc Target items related fixes - give diagnostic outputs for initial items. Evaluate item condition. 2013-12-03 16:53:28 +09:00
Atsushi Eno c89d31260f Fix some default properties: OutputType has default to Exe. AssemblyName defaults to the project file name, not RootNamespace. 2013-12-03 16:53:27 +09:00
Atsushi Eno 37dd28603a Enable parallel build test, with successful command, now that ConsoleLogger is now parallel ready. 2013-12-03 16:53:27 +09:00
Atsushi Eno 79aead48aa ConsoleLogger is now parallel build ready. 2013-12-03 16:53:26 +09:00
Atsushi Eno f044685b16 Fixed Task output item string result creator and fixed test expectation.
Item output task parameters don't show up on TargetResult Items. Instead
those items can be retrieved via ProjectInstance after builds.
2013-12-03 16:53:26 +09:00
Atsushi Eno 33ddd9e511 Empty items could still slipped in when converting string to array.
ResolveAssemblyReferences was hit with empty SearchPaths because of this.
2013-12-03 16:53:25 +09:00
Atsushi Eno 717c7f504c Make sure to raise matching TaskFinished event. 2013-12-03 16:53:25 +09:00
Atsushi Eno ed990229fa While converting string to array, trim each element before converting.
ResolveAssemblyReferences should work now.
2013-12-03 16:53:24 +09:00
Atsushi Eno a86c3161a4 implement "skip target due to previous success" feature. 2013-12-03 16:53:24 +09:00
Atsushi Eno 8b991126cd Improve item evaluation whitespace handling. 2013-12-03 16:53:23 +09:00
Atsushi Eno f85c526832 disable parallel build test because it is ConsoleLogger which does not work fine. 2013-12-03 16:53:23 +09:00
Atsushi Eno f428a45eda ProjectTaskOutputPropertyInstance was not appropriately created. 2013-12-03 16:53:22 +09:00
Atsushi Eno 60b27cd208 Make sure to use BuildNodeManager in any build run, and corrected error handling to somewhat better state.
Also, now EndBuild() won't finish until all callbacks are done.
2013-12-03 16:53:22 +09:00
Atsushi Eno 58ce380ecb LoadProject() should add the loaded project to the collection. 2013-12-03 16:53:21 +09:00
Atsushi Eno 9cdcf9f7ce Any errors inside BuildEngine build could be logged by loggers.
Some exceptions _outside_ that can be still on stderr, but they are
much less now.
2013-12-03 16:53:21 +09:00
Atsushi Eno 3ae629a509 Give Project FullPath a unique name for each test so that error outputs could be attributed. 2013-12-03 16:53:20 +09:00
Atsushi Eno d744f4e374 Make sure to fire TargetFinished event in any result (namely, internal error).
That possible mismatch caused invalid Stack operation in ConsoleLogger.
2013-12-03 16:52:58 +09:00
Atsushi Eno 19c8247277 couple of minor refactoring and warnings cleanup.
BuildSubmission.IsCompleted is valid now.
Renamed some argument in BuildEngine4.
Removed ProjectTargetInstance field by moving them to arguments in BuildEngine4.
2013-12-03 16:52:57 +09:00
Atsushi Eno 87da3f6382 do not try to evaluate and set non-required and empty Task parameter for ITask instance. 2013-12-03 16:52:57 +09:00
Atsushi Eno cbe898bb70 fix test file name. 2013-12-03 16:52:56 +09:00
Atsushi Eno 6f58bb39c6 Handle target Inputs and Outputs so that extra targets can be skipped. Add some value convert (for task property) tests. 2013-12-03 16:52:55 +09:00
Atsushi Eno 2abc6438a0 For Condition, "yes", "no", "on" and "off" are also treated as valid boolean... 2013-12-03 16:52:54 +09:00
Atsushi Eno 1ef9aa3355 For ItemType-less metadata expression, apply all items in the project. 2013-12-03 16:52:53 +09:00
Atsushi Eno a27353ead3 Evaluate Target Condition too. 2013-12-03 16:52:53 +09:00
Atsushi Eno 46a949f958 Make use of XBUILD_FRAMEWORK_FOLDERS_PATH in GetReferenceAssemblyPaths task and make it testable importing common targets. 2013-12-03 16:52:52 +09:00
Atsushi Eno 733566f8e8 implement MetadataAccessExpression evaluate methods. 2013-12-03 16:52:51 +09:00
Atsushi Eno 14db3ee236 ProjectInstance never had valid ToolsVersion because ProjectRootElement holds "", not null(!) for default value. 2013-12-03 16:52:50 +09:00
Atsushi Eno 96e448b624 Fix ProjectInstance.ToolsVersion, never returned valid value. 2013-12-03 16:52:49 +09:00
Atsushi Eno 6761e5d3c8 Check Condition on task parameter before trying to apply it. 2013-12-03 16:52:49 +09:00
Atsushi Eno e72e4e9863 Well-Known metadata support is now in ProjectItemInstance too, sharing code with ProjectItem. 2013-12-03 16:52:48 +09:00
Atsushi Eno dd418612a7 Split lengthy DoBuildTarget() function into understandable units. 2013-12-03 16:52:47 +09:00
Atsushi Eno ebe1e4799d Project.GetItems() and ProjectInstance.GetItems() are now shared code.
They will involve more complication and I don't want to have duplicates.
2013-12-03 16:52:46 +09:00
Atsushi Eno 59a117b2e9 add some workaround for "PLATFORM" property that should not be filled by environment.
Add some tests to evaluate IntermediateOutputPath.
2013-12-03 16:52:45 +09:00
Atsushi Eno 16f67cab87 implement UnloadProject(). 2013-12-03 16:52:45 +09:00
Atsushi Eno 4a46f0a37a STRING_LITERAL could contain expandable expressions, so evaluate them too.
We cannot simply "expand strings first then evaluate condition as boolean"
because there are things like "$(A)=='true'" which is expanded as "=='true'".
2013-12-03 16:52:44 +09:00
Atsushi Eno 5b1d772403 remove redundant "throw NIE". 2013-12-03 16:52:44 +09:00
Atsushi Eno eaedaf632a implement ExpressionParserManual.EvaluateMetadataExpression(). 2013-12-03 16:52:43 +09:00
Atsushi Eno 14205a135c Forgot to rename namespace in .jay. 2013-12-03 16:52:42 +09:00
Atsushi Eno 87bf489e87 For expression stuff, change namespace to MS.Build.Internal.Expressionns.
Too annoying to track build engine traces.
2013-12-03 16:52:42 +09:00
Atsushi Eno 30bc1486dd Add more diagnostic logging in BuildEngine4. 2013-12-03 16:52:41 +09:00
Atsushi Eno 992fb0aeda update .csproj. 2013-12-03 16:52:41 +09:00
Atsushi Eno a93c8bf8e6 Add and use BuildAbortedException. 2013-12-03 16:52:40 +09:00
Atsushi Eno bbc7218256 implement ProjectInstance.GetItems() which is now actually used. 2013-12-03 16:52:40 +09:00
Atsushi Eno 25dd0d206a Filter out empty strings in split item array. 2013-12-03 16:52:39 +09:00
Atsushi Eno 18b80adf2b Task parameters has to be expanded before being applied to ITask instance. 2013-12-03 16:52:38 +09:00
Atsushi Eno e1b6ef6039 several BuildEngine4 fixes.
- DependsOnTargets has to be Trim()med before search.
- Metadata implementation is required in the TaskItem.
2013-12-03 16:52:38 +09:00
Atsushi Eno cd94d959fe Fix namespace. 2013-12-03 16:52:37 +09:00
Atsushi Eno 8958a54d81 use ConcurrentQueue in BuildNodeManager. 2013-12-03 16:52:37 +09:00
Atsushi Eno 6f65e552de fix class visibility. 2013-12-03 16:52:36 +09:00
Atsushi Eno 4cbaff75a5 dump possible build node exceptions that would have been silently ignored. 2013-12-03 16:52:36 +09:00
Atsushi Eno cf6fa9eb19 Evaluate and include property and item on <Target> element before running tasks.
BuildEngine4.BuildTarget() became too lengthy, so split it.
2013-12-03 16:52:35 +09:00
Atsushi Eno 777ec86a1a Fix ContinueOnError evaluation (was almost always true). Add more logging. 2013-12-03 16:52:35 +09:00
Atsushi Eno 5fec8ad019 handle Target/@DependsOnTargets. To make it possible, some code reorganization. 2013-12-03 16:52:34 +09:00
Atsushi Eno 6c5640122a make locations internal in NET_4_0. 2013-12-03 16:52:34 +09:00
Atsushi Eno 3f3748e9ca No need to fill UsingTaskElement content here. Load() takes care of it. 2013-12-03 16:52:33 +09:00
Atsushi Eno 8d2ad3c460 Fix bogus expression tokenizer that failed at parenthesized expressions with And/Or. 2013-12-03 16:52:33 +09:00
Atsushi Eno 8d28a5e143 MaxNodeCount is documented as 1 by default. (not in use so far anyways...) 2013-12-03 16:51:55 +09:00
Atsushi Eno 7bd9052eb7 Show better error location in InvalidProjectFileException. 2013-12-03 16:51:54 +09:00
Atsushi Eno 7f41201372 slightly changed Csc task test project structure so that it could at least launch compiler. 2013-12-03 16:51:53 +09:00
Atsushi Eno c16c3dfb2e Fix load error with related to new attributes since 4.0. 2013-12-03 16:51:52 +09:00
Atsushi Eno ed859d6303 Fix possible NRE on null Location. 2013-12-03 16:51:52 +09:00
Atsushi Eno 96dad50549 implement ProjectIntance.AddItem(). 2013-12-03 16:51:51 +09:00
Atsushi Eno aa3e42ef74 Use ContinueOnError property on BuildEngine itself. 2013-12-03 16:51:51 +09:00
Atsushi Eno a806c1e8ba Set Task properties before running it, and get output task parameters when done. 2013-12-03 16:51:50 +09:00
Atsushi Eno 1fe034409b Several fixes to get ProjectUsingTaskElement could be loaded and task database gets correct match.
Now tasks could be loaded, ready to execute.
2013-12-03 16:51:50 +09:00
Atsushi Eno 4df2a71e86 workaround threading by Task isse. Also fix regression on "no target found" case (should fail).
(Task causes NotImplementedException under the hood).
2013-12-03 16:51:49 +09:00
Atsushi Eno 3412c85d2a update .csproj. 2013-12-03 16:51:48 +09:00
Atsushi Eno 62ab57ae8a ongoing task database implementation.
This somehow causes thread freeze, I had to disable some tests.
2013-12-03 16:51:48 +09:00
Atsushi Eno 5b42283cad ITaskFactory2 is public. 2013-12-03 16:51:47 +09:00
Atsushi Eno c3c1b455b4 update .csproj. 2013-12-03 16:51:46 +09:00
Atsushi Eno 87eb7b68a9 add missing OutOfProcNode class (though it seems unused). 2013-12-03 16:51:46 +09:00
Atsushi Eno 86d65aadba update .csproj. 2013-12-03 16:51:45 +09:00
Atsushi Eno af6757b7c1 delete old file. 2013-12-03 16:51:44 +09:00
Atsushi Eno 90f95ad9b2 implement basic node management skeleton (which does not really manage nodes, just to hold node retriever). 2013-12-03 16:51:43 +09:00
Atsushi Eno 721fffe2ad Ongoing build engine implementation and some fixes in build submission handling.
BuildSubmission could be posted multiple times so that multiple projects can
be built within one BuildManager. Now node manager should be implemented too...
2013-12-03 16:51:43 +09:00
Atsushi Eno 612c8bc88a Fix API: remove non-existent property in .NET (copy-paste bad). 2013-12-03 16:51:42 +09:00
Atsushi Eno fc029e1327 update .csproj. 2013-12-03 16:51:41 +09:00
Atsushi Eno 580fa5a9db Add missing ITaskFactory/2 and co. Add BuildEventArgs.set_Context(). 2013-12-03 16:51:40 +09:00
Atsushi Eno 687bd6fa31 update csproj. 2013-12-03 16:51:39 +09:00
Atsushi Eno e13cfb0bb5 Add IBuildEngine implementation, required to expose some features to tasks. 2013-12-03 16:51:39 +09:00
Atsushi Eno bb0c8641cb add test for BuildManager.PendBuildRequest(). Looks like it's mostly for internal use... 2013-12-03 16:51:38 +09:00
Atsushi Eno 5930c3fa8d fix NET_2_0 build: INodeLogger is only in 4.0. 2013-12-03 16:51:37 +09:00
Atsushi Eno 3f0e9ea33d slightly reorganized external sources dirs. 2013-12-03 16:51:36 +09:00
Atsushi Eno 0c2f47f1cc add missing copyright headers. 2013-12-03 16:51:36 +09:00
Atsushi Eno 8e71ae89fe implement HostServices, not sure if we're going to use it though. 2013-12-03 16:51:35 +09:00
Atsushi Eno 33ab64e9b3 add missing license headers. 2013-12-03 16:51:35 +09:00
Atsushi Eno 6df1bb8344 slightly reduce NIE code path. 2013-12-03 16:51:34 +09:00
Atsushi Eno 91c57db0fd update csproj. 2013-12-03 16:51:34 +09:00
Atsushi Eno 5795a5d1ce Add test for BuildSubmission (which is mostly for build operation so far). 2013-12-03 16:51:33 +09:00
Atsushi Eno 9c8b90b3ce Implement more precise DefaultTargets handling. 2013-12-03 16:51:33 +09:00
Atsushi Eno 43042abc79 Several fixes on manual expression parser with related to function args and property accesses. 2013-12-03 16:51:32 +09:00
Atsushi Eno 85c24d7ef2 fix some string evaluator tests. Some of them even fails in prop values. 2013-12-03 16:51:32 +09:00
Atsushi Eno 5524846de1 slightly improve property access error message. 2013-12-03 16:51:31 +09:00
Atsushi Eno 716dbf8d4e Apply windows path loader fix to ProjectInstance too. 2013-12-03 16:51:31 +09:00
Atsushi Eno b752051d18 Resolve property value by EvaluatedValue where appropriate. 2013-12-03 16:51:30 +09:00
Atsushi Eno ee9d2692f9 Sequence of comparison expressions (A==B==C) is invalid. Avoid ANE on property evaluation. 2013-12-03 16:51:30 +09:00
Atsushi Eno 0355d025e2 Fix binary expression evaluation. They can be combined. 2013-12-03 16:50:51 +09:00
Atsushi Eno ce97b1a68b implement prebuilt Condition evaluation function support. 2013-12-03 16:50:50 +09:00
Atsushi Eno ea85db2436 Fix location of windows path compatibility change. 2013-12-03 16:50:49 +09:00
Atsushi Eno 520616ae21 Fix 4.5 toolpath. 2013-12-03 16:50:48 +09:00
Atsushi Eno a8a49c37b3 fix import path for ProjectInstance too. 2013-12-03 16:50:48 +09:00
Atsushi Eno f2bf63cd62 update csproj. 2013-12-03 16:50:47 +09:00
Atsushi Eno d0f9b5427d Add missing built-in properties. Resolve properties on import paths. Resolve \ with / on import paths. 2013-12-03 16:50:46 +09:00
Atsushi Eno 7ecb09c1dd Project needs to build just fine for empty projects. 2013-12-03 16:50:45 +09:00
Atsushi Eno 1c19fc890f some BuildSubmission and BuildResult implementation, as well as tiny bit of build operation. 2013-12-03 16:50:44 +09:00
Atsushi Eno 8fd57e40ae sorted out BuildManager build logic up to BuildSubmission.Execute(). 2013-12-03 16:50:43 +09:00
Atsushi Eno 05c976aefe Reuse logger types in Microsoft.Build.dll. 2013-12-03 16:50:43 +09:00
Atsushi Eno 3f9eacfecd update csproj. 2013-12-03 16:50:42 +09:00
Atsushi Eno b35862adb6 sorted out logger stuff. Imported many of existing loggers from MS.Build.Engine. Stubbed some. 2013-12-03 16:50:41 +09:00
Atsushi Eno ae34234c86 update .sources too. 2013-12-03 16:50:40 +09:00
Atsushi Eno 0a140fcec1 update csproj. 2013-12-03 16:50:39 +09:00
Atsushi Eno 4e5ba453e1 add missing logging types which are required for Microsoft.Build.dll. 2013-12-03 16:50:39 +09:00
Atsushi Eno 593e1c8cc3 update csproj. 2013-12-03 16:50:38 +09:00
Atsushi Eno 609a5659a2 Add missing ProjectPropertyGroupTaskIntance and descendant, and implement more of this namespace. 2013-12-03 16:50:38 +09:00
Atsushi Eno 9faf9ca526 Added some comments on loaders in the two project object models. 2013-12-03 16:50:37 +09:00
Atsushi Eno 9c4c85f376 implemented more ProjectInstance family. Enabled some tests back. 2013-12-03 16:50:37 +09:00
Atsushi Eno 0e54cf20ac implemented a lot of ProjectTargetInstance and its descendants. Fixed a lot of Location stuff to fix NET_4_0 build. 2013-12-03 16:50:36 +09:00
Atsushi Eno f101e9abe2 implement basic project loader for ProjectInstance. 2013-12-03 16:50:36 +09:00
Atsushi Eno d75b5e5e94 refactoring some internals to make code sharable between Project and ProjectInstance. 2013-12-03 16:50:35 +09:00
Atsushi Eno 27c08dce64 update .csproj. 2013-12-03 16:50:34 +09:00
Atsushi Eno 7961c3db2e implement ProjectMetadataInstance and add some MS.Build.Execution tests. 2013-12-03 16:50:34 +09:00
Atsushi Eno 803607d04f add another GetLoadedProject() test, this time with ProjectInstance. 2013-12-03 16:50:33 +09:00
Atsushi Eno 1c8ee6ae17 implement GetLoadedProject(), ProjectAdded and adjust relevant methods. 2013-12-03 16:50:33 +09:00
Atsushi Eno bdda009028 Added workaround for DirectoryScanner bug that finds multiple files. Then implemented RecursiveDir metadata. 2013-12-03 16:50:32 +09:00
Atsushi Eno c3e5e8c861 update .csproj. 2013-12-03 16:50:32 +09:00
Atsushi Eno 40ec8b64dd make TaskItem available (as internal) in Microsft.Build.dll. 2013-12-03 16:50:31 +09:00
Atsushi Eno 7569cc8a93 implement item wildcard support, except for "**" which looks buggy at DirectoryScanner. 2013-12-03 16:50:31 +09:00
Atsushi Eno 215b84c1b8 implement IsImported. 2013-12-03 16:50:30 +09:00
Atsushi Eno 92c1b87789 implemented well-known item metadata. 2013-12-03 16:50:29 +09:00
Atsushi Eno 956395ecd2 Fix API for ProjectItemElement.Condition. Add test for item definition Condition. 2013-12-03 16:50:29 +09:00
Atsushi Eno 099e027422 GetMetadataValue() returns "" if metadata is not found. 2013-12-03 16:50:28 +09:00
Atsushi Eno 86d1bc5fee Fix MSBuildThisFile reserved property value (empty by default). 2013-12-03 16:50:28 +09:00
Atsushi Eno 92810da48d got imports working. Imported ProjectRootElement needed XmlReader to load it. 2013-12-03 16:50:27 +09:00
Atsushi Eno 6a57658654 For expression, string equality comparison is done in case-insensitive manner. 2013-12-03 16:50:27 +09:00
Atsushi Eno ead100a78e fix couple of regressions caused by lazy evaluation of properties. 2013-12-03 16:50:26 +09:00
Atsushi Eno fab2d35312 update .csproj. 2013-12-03 16:50:26 +09:00
Atsushi Eno 198f0082e5 partal import implementation. 2013-12-03 16:50:08 +09:00
Atsushi Eno d3ab7f2f4f missing Project attribute causes load error at ProjectRootElement level. 2013-12-03 16:50:07 +09:00
Atsushi Eno 61927bbc50 Allow empty function args and fix "sigle-argument is ignored" issue. 2013-12-03 16:50:06 +09:00
Atsushi Eno 9104907d9a Fix fullname (dotted name) parsing in boolean expression parser. 2013-12-03 16:50:05 +09:00
Atsushi Eno 0f6863df4e Now we can directly evaluate boolean expression with jay-based parser. 2013-12-03 16:50:04 +09:00
Atsushi Eno 26830c94ef fix NRE. 2013-12-03 16:50:03 +09:00
Atsushi Eno 9e4d891e11 fix NRE. 2013-12-03 16:50:02 +09:00
Atsushi Eno 68356ed43c implemented (hacky) method resolution for overloads and varargs. 2013-12-03 16:50:01 +09:00
Atsushi Eno 29bef8b989 support property function calls in tokenizer. 2013-12-03 16:50:00 +09:00
Atsushi Eno f795db2981 support type's static property access. 2013-12-03 16:50:00 +09:00
Atsushi Eno e4c1837c6c fix whitespace skipping. Do not accept sequential binary operations. 2013-12-03 16:49:59 +09:00
Atsushi Eno 9d8d2572af prevent invalid sequential property reference such as $(X)$(Y), by explicitly adding surrounding APOS to the expanded value. 2013-12-03 16:49:59 +09:00
Atsushi Eno a8b56ab70f couple of tokenization fixes with more tests. 2013-12-03 16:49:58 +09:00
Atsushi Eno 0b566b28ee made several fixes in jay-based expression parser and use it for boolean evaluation.
For item/propery reference expansion, use manual parser.
2013-12-03 16:49:58 +09:00
Atsushi Eno 4338a63f9b fix test for GetPropertyValueEscaped(). (expects WTF behavior) 2013-12-03 16:49:57 +09:00
Atsushi Eno aab6d6e7bc evaluate condition on PropertyGroup too. 2013-12-03 16:49:57 +09:00
Atsushi Eno c9a584e7a7 evaluate Condition on property to add Properties list.
Now we got a couple of errors because of malfunctional expression evaluator...
2013-12-03 16:49:56 +09:00
Atsushi Eno 15970da3a7 property reference is valid in Condition too. 2013-12-03 16:49:56 +09:00
Atsushi Eno b218dd0fe2 implement well-known and reserved properties. 2013-12-03 16:49:55 +09:00
Atsushi Eno 7357be85f7 Item references can be evaluated as boolean and hence can be a valid Condition expression. 2013-12-03 16:49:55 +09:00
Atsushi Eno c8f38da2d8 fix tests that incorrectly allowed empty/missing Include attribute. 2013-12-03 16:49:54 +09:00
Atsushi Eno e6fcc65278 implement string literal boolean evaluation. 2013-12-03 16:49:54 +09:00
Atsushi Eno 672f575afa forgot to commit exception change. 2013-12-03 16:49:53 +09:00
Atsushi Eno 3deb8d0a85 fix IndexOutOfRangeException for parsing "$" "@" or "%" (one char for each). 2013-12-03 16:49:52 +09:00
Atsushi Eno f12f734432 implement IsDirty() (incomplete of course), MarkDirty() and DisableMarkDirty. Fix tests. 2013-12-03 16:49:52 +09:00
Atsushi Eno 7d4e2ff71b update csproj. 2013-12-03 16:49:51 +09:00
Atsushi Eno 5e26a81f7c Raise error when project item has empty Include attribute or lacks it. 2013-12-03 16:49:50 +09:00
Atsushi Eno 455eaa7af3 ProjectItems are created after splitting Include paths by ';'.
So there could be more than one ProjectItem for the same ProjectItemElement.
2013-12-03 16:49:49 +09:00
Atsushi Eno 1fb98239a1 update csproj. 2013-12-03 16:49:49 +09:00
Atsushi Eno 228a5f4099 delete generated code. 2013-12-03 16:49:48 +09:00
Atsushi Eno e61d88d238 Altered expression parser to hand-written one (which was kind of anticipated) for torelant parsing. 2013-12-03 16:49:47 +09:00
Atsushi Eno f7d05af3ea Add full-scratch expression parser implementation. 2013-12-03 16:49:46 +09:00
Atsushi Eno 8735d655c9 implemented couple of Project members, while changing some members to throw NIE. 2013-12-03 16:49:45 +09:00
Atsushi Eno 79c7800f9a update .csproj. 2013-12-03 16:49:45 +09:00
Atsushi Eno f1d08b2a5d implement ProjectItem and co. 2013-12-03 16:49:44 +09:00
Atsushi Eno 0667fbd6c3 ProjectItemDefinition.ItemType was not initialized (also not tested.) 2013-12-03 16:49:44 +09:00
Atsushi Eno 13e60b8816 update .csproj. 2013-12-03 16:49:43 +09:00
Atsushi Eno ffa341ffdc implement ProjectItemDefinition and co. 2013-12-03 16:49:43 +09:00
Atsushi Eno 19647da75d implement Project.RemoveProperty() and ProjectProperty.Predecessor (i.e. property overrides). 2013-12-03 16:49:42 +09:00
Atsushi Eno 0a86f8456f implement several ProjectProperty types. 2013-12-03 16:49:42 +09:00
Atsushi Eno 6ccce5d459 fix csproj too. 2013-12-03 16:49:35 +09:00
Atsushi Eno c59f6e852b fix wrong type nest for added event handler and args. 2013-12-03 16:49:34 +09:00
Atsushi Eno a983f2bde4 update .csproj. 2013-12-03 16:49:33 +09:00
Atsushi Eno b04389411b Added missing ProjectCollection events and co. 2013-12-03 16:49:32 +09:00
Atsushi Eno 0157410a00 update .csproj. 2013-12-03 16:49:31 +09:00
Atsushi Eno 5f6841b609 implement basic ProjectProperty members. 2013-12-03 16:49:30 +09:00
Atsushi Eno a7a11fc7ea Add more tests and fixes in Construction loaders. 2013-12-03 16:49:30 +09:00
Atsushi Eno 59e67847fa update csproj. 2013-12-03 16:49:29 +09:00
Atsushi Eno 03b31eca2b implement toolset and build related members. 2013-12-03 16:49:28 +09:00
Atsushi Eno 4669f9ab6c forgot to add ProjectCollectionTest.cs. 2013-12-03 16:49:26 +09:00
Atsushi Eno e07081d760 update .csproj. 2013-12-03 16:49:25 +09:00
Atsushi Eno 8fdb340ce3 Add more project loader tests. 2013-12-03 16:49:24 +09:00
Atsushi Eno ee54380121 Fix regarding GetProjectInstanceForBuild(), and added some tests regarding Escape(). 2013-12-03 16:49:23 +09:00
Atsushi Eno 758e14c4e2 update csproj. 2013-12-03 16:49:23 +09:00
Atsushi Eno 3bf0ffb55d implement Project.Build() and ProjectInstance.Build() (they lead to NIE yet)
..., but still sorts out relationship between those types and methods.
2013-12-03 16:49:21 +09:00
Atsushi Eno 950ca86f45 fill ElementLocation items at loading. Fix Subtool-related build fix for 4.0. 2013-12-03 16:49:20 +09:00
Atsushi Eno 47aaaff471 update .csproj. 2013-12-03 16:49:19 +09:00
Atsushi Eno fe66ba6f41 Add BuildEventContextTest and slightly made Equals() clear on how it works. 2013-12-03 16:49:19 +09:00
Atsushi Eno b28c703044 update test csproj. 2013-12-03 16:49:18 +09:00
Atsushi Eno 2628dbd1f8 Fix ProjectRootElement.DirectoryPath. Add unit test for ProjectRootElement. 2013-12-03 16:49:16 +09:00
Atsushi Eno 66e97df577 update MS.Build csproj to the latest status. 2013-12-03 16:49:15 +09:00
Atsushi Eno 221184f747 Fix net_4_0 build. 2013-12-03 16:49:15 +09:00
Atsushi Eno 0f28c05d99 add BuildEventContext to .csproj. 2013-12-03 16:49:14 +09:00
Atsushi Eno 412bfd34c0 Add BuildEventContext. 2013-12-03 16:49:14 +09:00
Atsushi Eno 8e31fa7597 update MS.Build test csproj. 2013-12-03 16:49:13 +09:00
Atsushi Eno e2a79db75f Add ToolsetTest and fix Toolset construction. 2013-12-03 16:49:13 +09:00
Atsushi Eno 2e8f7fc585 Fix MS.Build.Tasks.csproj build too. 2013-12-03 16:49:12 +09:00
Atsushi Eno 84bbf45c67 fix test csproj build. 2013-12-03 16:49:12 +09:00
Atsushi Eno 1b1ede900b update MS.Build.csproj. 2013-12-03 16:49:11 +09:00
Atsushi Eno 698edb13ff implement ProjectCollection.Toolsets. 2013-12-03 16:49:10 +09:00
Atsushi Eno 8cf480afbc Add ToolLocationHelper and co. to MS.Build.dll (as internal). 2013-12-03 16:49:10 +09:00
Atsushi Eno 5f9868a372 ToolLocationHelper is now used in MS.Build.dll too (as internal). 2013-12-03 16:49:09 +09:00
Atsushi Eno 89293d29d9 Add IBuildEngine3 and IBuildEngine4 to csproj. 2013-12-03 16:49:09 +09:00
Atsushi Eno a782e6178c Add IBuildEngine3 and IBuildEngine4. 2013-12-03 16:49:08 +09:00
Atsushi Eno e012992e25 Add missing tests in csproj. 2013-12-03 16:49:07 +09:00
Atsushi Eno aafe0a4e2e MS.Build.dll: Add more missing members and implementation for some members. 2013-12-03 16:49:07 +09:00
Atsushi Eno b6a3785bc9 implement some MS.Build members as well as adding missing members. 2013-12-03 16:49:06 +09:00
Atsushi Eno 4a9e3cdf9c Add missing ProjectInstance family. 2013-12-03 16:49:06 +09:00
Atsushi Eno 6c2776884f implement various not-implemented types in Microsoft.Build.dll. 2013-12-03 16:49:05 +09:00
Atsushi Eno acad24f57f Add hacking MSBuild solution for MSBuild libraries. 2013-12-03 16:49:05 +09:00
Atsushi Eno 40fb52be0f update .sln too. 2013-12-03 16:48:02 +09:00
Marek Safar 51927cb419 Merge pull request #823 from DavidKarlas/master
Update PointConverter exception message from RectConverter to PointConverter
2013-12-02 23:47:00 -08:00
Atsushi Eno 46c451adc0 Update .csproj (to add MSBuild.csproj). 2013-12-03 16:46:57 +09:00
David Karlaš 018df75d54 Update PointConverter.cs 2013-12-03 06:48:03 +01:00
Zoltan Varga 45d5758db9 Hopefully the --enable-loadedllvm build on linux. 2013-12-03 04:01:51 +01:00
Martin Baulig 93d55a3daf [xbuild]: Implement task batching for properties; fixes #16403. 2013-12-02 22:56:58 +01:00
Atsushi Eno 623ba9bff2 Add experimental "MSBuild.exe" implementation which is based on Microsoft.Build.dll. 2013-12-03 05:05:43 +09:00
Atsushi Eno bb96a90b69 update .csproj. 2013-12-03 04:55:17 +09:00
Atsushi Eno 0466344052 Add missing exception types. 2013-12-03 04:55:03 +09:00
Atsushi Eno fcd1a0278a ProjectCollection.DefaultToolsVersion is settable. 2013-12-03 04:54:31 +09:00
Alex Rønne Petersen e70dec1e27 Fix comment style. 2013-12-02 19:33:27 +01:00
Alex Rønne Petersen a6bb88d2e5 Avoid clobbering IP when passing single-precision args on ARM hard float. 2013-12-02 19:27:39 +01:00
Alex Rønne Petersen 59e4edb1f6 Maintain max_len when emitting calls on ARM hard float.
It has to be adjusted dynamically as with OP_SWITCH since
we emit extra instructions in the various call opcodes when
the argument list contains single-precision floats.

Also, allocate extra storage space when needed (we would
potentially overflow previously).
2013-12-02 19:27:39 +01:00
Alex Rønne Petersen 64732bae27 Use d14 and d15 as scratch VFP registers.
Using d0 and d1 is problematic because they're argument registers
and so can end up being clobbered by instructions inserted in the
middle of a call sequence.

d14 and d15 on the other hand are OK because they don't have any
particular meaning in the ABI, and we don't even use them in the
register allocator at the moment anyway.
2013-12-02 19:27:39 +01:00
Alex Rønne Petersen 49f5625797 Correct the VFP check in exceptions-arm.c.
This should be a runtime decision, and also should be in
effect when using the hard float ABI (ARM_FPU_VFP_HARD).
2013-12-02 19:27:39 +01:00
Alex Rønne Petersen 1cdf7fafbd Implement support for single-precision args on ARM hard float.
This is done with a gross hack that maintains a list of args
in the MonoCallInst and emits them as late as possible. This
is not pretty, but we have to work around the register
allocator. See the code comments for details.
2013-12-02 19:27:39 +01:00
Alex Rønne Petersen f978a34abd Make sure FPRs aren't used for implicit arguments on ARM hard float. 2013-12-02 19:27:38 +01:00
Alex Rønne Petersen 4f8e1a7ff8 Add register assignment for double-precision args on ARM hard float. 2013-12-02 19:27:38 +01:00
Alex Rønne Petersen 3fb9ed6ee3 Implement add_float () for hard float on ARM. 2013-12-02 19:27:38 +01:00
Alex Rønne Petersen 87931e22c5 Print detected ARM version in configure. 2013-12-02 19:27:38 +01:00
Alex Rønne Petersen 369c838eb1 Implement return value passing for ARM hard float.
This is currently only for float32/float64 values. They are passed
in the d0 register. The code is a bit complicated because we only
speak float64 in the JIT, so float32 values have to be converted
to/from float64.
2013-12-02 19:27:38 +01:00
Alex Rønne Petersen 76c7f42e11 Handle the MONO_ARM_FPU_VFP_HARD case in mono_arch_emit_setret (). 2013-12-02 19:27:38 +01:00
Alex Rønne Petersen 6d4cd2f03a Add VFP register saving to trampolines. 2013-12-02 19:27:37 +01:00
Alex Rønne Petersen fb478ba04c Add a helper function to the ARM back end to determine hard float mode. 2013-12-02 19:27:37 +01:00
Alex Rønne Petersen 5082618f54 Adjust various FP register values for hard float in mini-arm.h. 2013-12-02 19:27:37 +01:00
Alex Rønne Petersen f5004f9b83 Add detection of VFP v3 variants to mono-hwcap-arm. 2013-12-02 19:27:37 +01:00
Alex Rønne Petersen fb6e4eb972 Add an IS_HARD_FLOAT macro to the ARM back end.
Also define correct values for IS_SOFT_FLOAT and IS_VFP for
the hardware floating point (ARM_FPU_VFP_HARD) case.
2013-12-02 19:27:37 +01:00
Alex Rønne Petersen ddf82bffe2 Remove the #error for the ARM_FPU_VFP_HARD case. 2013-12-02 19:27:37 +01:00
Marek Safar 521a61ae5d [linq] Enumerable.Join and GroupJoin needs to ignore null keys. Fixes #16530 2013-12-02 19:03:37 +01:00
Marek Safar 611ce3a9ed [corlib] DebuggerTypeProxyAttribute.ProxyName needs to return an assembly qualified type name. Fixes #16527 2013-12-02 17:54:22 +01:00
Mark Probst 42c2a5207d [sgen] Integrate sgen_qsort() unit test in Makefile. 2013-12-02 16:20:47 +01:00
Atsushi Eno 6754431cc8 Some parser error message got source string for Condition evaluation. 2013-12-02 19:05:12 +09:00
Atsushi Eno c8552029dd Target items related fixes - give diagnostic outputs for initial items. Evaluate item condition. 2013-12-02 19:04:20 +09:00
Zoltan Varga 8304e4407b Fix dwarf section names in the mach image writer. 2013-12-02 02:01:45 +01:00
Zoltan Varga 9003740b64 Fix a warning. 2013-12-01 14:30:01 +01:00
Zoltan Varga 858e4ee61e [amd64] Fix the tail call code after 4c0376d037. 2013-12-01 14:10:11 +01:00
Zoltan Varga 073752949f [jit] Implement double->uintptr conversions on 64 bit platforms. Fixes #16529. 2013-12-01 13:03:06 +01:00
Zoltan Varga a1024016a0 [sdb] Fix step-over with recursive functions. Fixes #5700. 2013-11-30 21:05:19 +01:00
Zoltan Varga e21dc7cec8 [bcl] Fix a culture test on linux. 2013-11-30 12:08:27 +01:00
Zoltan Varga 24a429c116 Fix a warning. 2013-11-30 05:45:59 -05:00
Zoltan Varga 14095c336b [x86] Simplify emit_push_lmf()/emit_pop_lmf () by removing cases which are handled by the IR based code. 2013-11-30 05:43:57 -05:00
Carlos Martín Nieto e2b0132a16 Use full path for aspnetwebstack pkg-config file
Referencing the assemblies by DLL name isn't enough for MonoDevelop to
pick them up for listing. Use the full path so they show up the
references list.
2013-11-30 04:03:34 +01:00
Marek Safar ae3f5aa141 [corlib] Consider all unicode separators in ToTitleCase. Fixes #16365 2013-11-29 20:40:07 +01:00
Marek Safar 8006bd5011 [corlib] Set initialized List<T> capacity to match input enumeration. Fixes #16318 2013-11-29 20:40:07 +01:00
Zoltan Varga e020c3bc2c [jit] Add beginnings of a mach image writer for use with xdebug. 2013-11-29 18:45:23 +01:00
Atsushi Eno 19e8e3dc0e Fix some default properties: OutputType has default to Exe. AssemblyName defaults to the project file name, not RootNamespace. 2013-11-30 00:44:57 +09:00
Marek Safar 3d59213ac4 [mcs] Better cloning debugging 2013-11-29 16:17:32 +01:00
Marek Safar 34700deb47 Fixes build 2013-11-29 16:14:31 +01:00
Atsushi Eno 5a9ca18776 Enable parallel build test, with successful command, now that ConsoleLogger is now parallel ready. 2013-11-29 23:41:09 +09:00
Atsushi Eno 63d1004b97 ConsoleLogger is now parallel build ready. 2013-11-29 23:40:46 +09:00
Marek Safar 31cab6a76d Fixes build 2013-11-29 13:51:02 +01:00
Marek Safar 985b7ba6f9 [mcs] Better error message for lambda expressions used as statements 2013-11-29 13:48:33 +01:00
Atsushi Eno 2c6cc958f8 Fixed Task output item string result creator and fixed test expectation.
Item output task parameters don't show up on TargetResult Items. Instead
those items can be retrieved via ProjectInstance after builds.
2013-11-29 20:02:09 +09:00
Marek Safar 564e390eb5 [mcs] Report ambiguity in attribute types in expanded mode. Fixes #16342 2013-11-29 11:45:55 +01:00
Atsushi Eno d2220188fe Empty items could still slipped in when converting string to array.
ResolveAssemblyReferences was hit with empty SearchPaths because of this.
2013-11-29 18:55:54 +09:00
Atsushi Eno eea81f1b32 Make sure to raise matching TaskFinished event. 2013-11-29 18:24:22 +09:00
Atsushi Eno 60b6ddc82b While converting string to array, trim each element before converting.
ResolveAssemblyReferences should work now.
2013-11-29 18:24:21 +09:00
Atsushi Eno 83df434707 implement "skip target due to previous success" feature. 2013-11-29 18:24:20 +09:00
Atsushi Eno 6a9c76131c Improve item evaluation whitespace handling. 2013-11-29 18:24:19 +09:00
Atsushi Eno 9d95a1b592 disable parallel build test because it is ConsoleLogger which does not work fine. 2013-11-29 18:24:18 +09:00
Atsushi Eno 2cd4d9d956 ProjectTaskOutputPropertyInstance was not appropriately created. 2013-11-29 18:24:17 +09:00
Atsushi Eno 639a7e9a4b Make sure to use BuildNodeManager in any build run, and corrected error handling to somewhat better state.
Also, now EndBuild() won't finish until all callbacks are done.
2013-11-29 18:24:16 +09:00
Atsushi Eno b3311e865e LoadProject() should add the loaded project to the collection. 2013-11-29 18:24:15 +09:00
Atsushi Eno 6c8dfee821 Any errors inside BuildEngine build could be logged by loggers.
Some exceptions _outside_ that can be still on stderr, but they are
much less now.
2013-11-29 18:24:14 +09:00
Atsushi Eno 94a5d5b2de Give Project FullPath a unique name for each test so that error outputs could be attributed. 2013-11-29 18:24:13 +09:00
Atsushi Eno c8a5add1d8 Make sure to fire TargetFinished event in any result (namely, internal error).
That possible mismatch caused invalid Stack operation in ConsoleLogger.
2013-11-29 18:24:13 +09:00
Atsushi Eno 956bdf55f7 couple of minor refactoring and warnings cleanup.
BuildSubmission.IsCompleted is valid now.
Renamed some argument in BuildEngine4.
Removed ProjectTargetInstance field by moving them to arguments in BuildEngine4.
2013-11-29 18:24:12 +09:00
Atsushi Eno 7730a23131 do not try to evaluate and set non-required and empty Task parameter for ITask instance. 2013-11-29 18:24:11 +09:00
Atsushi Eno a1a9af7198 fix test file name. 2013-11-29 18:24:10 +09:00
Atsushi Eno adae939ef6 Handle target Inputs and Outputs so that extra targets can be skipped. Add some value convert (for task property) tests. 2013-11-29 18:24:09 +09:00
Atsushi Eno eedce4342a For Condition, "yes", "no", "on" and "off" are also treated as valid boolean... 2013-11-29 18:24:09 +09:00
Atsushi Eno 383ac87fdb For ItemType-less metadata expression, apply all items in the project. 2013-11-29 18:24:08 +09:00
Atsushi Eno 700d1ac945 Evaluate Target Condition too. 2013-11-29 18:24:07 +09:00
Atsushi Eno 180564d655 Make use of XBUILD_FRAMEWORK_FOLDERS_PATH in GetReferenceAssemblyPaths task and make it testable importing common targets. 2013-11-29 18:23:43 +09:00
Atsushi Eno a37b1c848b implement MetadataAccessExpression evaluate methods. 2013-11-29 18:23:42 +09:00
Atsushi Eno 335ec4dbae ProjectInstance never had valid ToolsVersion because ProjectRootElement holds "", not null(!) for default value. 2013-11-29 18:23:41 +09:00
Atsushi Eno 59bd373236 Fix ProjectInstance.ToolsVersion, never returned valid value. 2013-11-29 18:23:40 +09:00
Atsushi Eno e3fe185333 Check Condition on task parameter before trying to apply it. 2013-11-29 18:23:39 +09:00
Atsushi Eno 2fad4ce3bb Well-Known metadata support is now in ProjectItemInstance too, sharing code with ProjectItem. 2013-11-29 18:23:38 +09:00
Atsushi Eno 0151a69ee3 Split lengthy DoBuildTarget() function into understandable units. 2013-11-29 18:23:37 +09:00
Atsushi Eno d6baf62ee3 Project.GetItems() and ProjectInstance.GetItems() are now shared code.
They will involve more complication and I don't want to have duplicates.
2013-11-29 18:23:36 +09:00
Atsushi Eno 492dcbd4f7 add some workaround for "PLATFORM" property that should not be filled by environment.
Add some tests to evaluate IntermediateOutputPath.
2013-11-29 18:23:36 +09:00
Atsushi Eno 7227dd419b implement UnloadProject(). 2013-11-29 18:23:35 +09:00
Atsushi Eno 2c10d72eff STRING_LITERAL could contain expandable expressions, so evaluate them too.
We cannot simply "expand strings first then evaluate condition as boolean"
because there are things like "$(A)=='true'" which is expanded as "=='true'".
2013-11-29 18:23:34 +09:00
Atsushi Eno de51bfe66e remove redundant "throw NIE". 2013-11-29 18:23:33 +09:00
Atsushi Eno c066736954 implement ExpressionParserManual.EvaluateMetadataExpression(). 2013-11-29 18:23:32 +09:00
Atsushi Eno 98079828b1 Forgot to rename namespace in .jay. 2013-11-29 18:23:31 +09:00
Atsushi Eno c594d61da9 For expression stuff, change namespace to MS.Build.Internal.Expressionns.
Too annoying to track build engine traces.
2013-11-29 18:23:30 +09:00
Atsushi Eno 2019930748 Add more diagnostic logging in BuildEngine4. 2013-11-29 18:23:29 +09:00
Atsushi Eno 710735e0fa update .csproj. 2013-11-29 18:23:28 +09:00
Atsushi Eno 32b70c6379 Add and use BuildAbortedException. 2013-11-29 18:23:27 +09:00
Atsushi Eno c256216287 implement ProjectInstance.GetItems() which is now actually used. 2013-11-29 18:23:26 +09:00
Atsushi Eno 9739f7d204 Filter out empty strings in split item array. 2013-11-29 18:23:25 +09:00
Atsushi Eno 6069a3d16d Task parameters has to be expanded before being applied to ITask instance. 2013-11-29 18:23:24 +09:00
Atsushi Eno b40071b2d4 several BuildEngine4 fixes.
- DependsOnTargets has to be Trim()med before search.
- Metadata implementation is required in the TaskItem.
2013-11-29 18:23:23 +09:00
Atsushi Eno ce33ad2b0f Fix namespace. 2013-11-29 18:23:22 +09:00
Atsushi Eno d20c5365e4 use ConcurrentQueue in BuildNodeManager. 2013-11-29 18:23:21 +09:00
Atsushi Eno 6fac6fe343 fix class visibility. 2013-11-29 18:23:20 +09:00
Atsushi Eno 8a1c344309 dump possible build node exceptions that would have been silently ignored. 2013-11-29 18:23:19 +09:00
Atsushi Eno 83b70b28c6 Evaluate and include property and item on <Target> element before running tasks.
BuildEngine4.BuildTarget() became too lengthy, so split it.
2013-11-29 18:23:18 +09:00
Atsushi Eno b986c4936c Fix ContinueOnError evaluation (was almost always true). Add more logging. 2013-11-29 18:23:17 +09:00
Atsushi Eno 7b0cc4fe01 handle Target/@DependsOnTargets. To make it possible, some code reorganization. 2013-11-29 18:23:16 +09:00
Atsushi Eno c8de1afe58 make locations internal in NET_4_0. 2013-11-29 18:23:15 +09:00
Atsushi Eno 8d1c9a3b32 No need to fill UsingTaskElement content here. Load() takes care of it. 2013-11-29 18:23:14 +09:00
Atsushi Eno b39c93b3a3 Fix bogus expression tokenizer that failed at parenthesized expressions with And/Or. 2013-11-29 18:23:13 +09:00
Atsushi Eno bb250ee469 MaxNodeCount is documented as 1 by default. (not in use so far anyways...) 2013-11-29 18:23:12 +09:00
Atsushi Eno 5fb2f0646a Show better error location in InvalidProjectFileException. 2013-11-29 18:23:12 +09:00
Atsushi Eno a94d52aecc slightly changed Csc task test project structure so that it could at least launch compiler. 2013-11-29 18:23:11 +09:00
Atsushi Eno fe8d96084e Fix load error with related to new attributes since 4.0. 2013-11-29 18:23:10 +09:00
Atsushi Eno 3377cb384c Fix possible NRE on null Location. 2013-11-29 18:23:09 +09:00
Atsushi Eno 5d31178c39 implement ProjectIntance.AddItem(). 2013-11-29 18:23:08 +09:00
Atsushi Eno 6769d12a51 Use ContinueOnError property on BuildEngine itself. 2013-11-29 18:23:07 +09:00
Atsushi Eno 81a7b71b32 Set Task properties before running it, and get output task parameters when done. 2013-11-29 18:23:06 +09:00
Atsushi Eno 01a080ca19 Several fixes to get ProjectUsingTaskElement could be loaded and task database gets correct match.
Now tasks could be loaded, ready to execute.
2013-11-29 18:23:05 +09:00
Atsushi Eno 0d895877b1 workaround threading by Task isse. Also fix regression on "no target found" case (should fail).
(Task causes NotImplementedException under the hood).
2013-11-29 18:23:04 +09:00
Atsushi Eno 8d6ecbf257 update .csproj. 2013-11-29 18:23:03 +09:00
Atsushi Eno 4149f6d5d6 ongoing task database implementation.
This somehow causes thread freeze, I had to disable some tests.
2013-11-29 18:23:02 +09:00
Atsushi Eno f0c157933f ITaskFactory2 is public. 2013-11-29 18:23:02 +09:00
Atsushi Eno 1a8d1b356c update .csproj. 2013-11-29 18:23:01 +09:00
Atsushi Eno 4a163333cc add missing OutOfProcNode class (though it seems unused). 2013-11-29 18:23:00 +09:00
Atsushi Eno ada1007296 update .csproj. 2013-11-29 18:23:00 +09:00
Atsushi Eno ced599348c delete old file. 2013-11-29 18:22:14 +09:00
Atsushi Eno 532f1b16b1 implement basic node management skeleton (which does not really manage nodes, just to hold node retriever). 2013-11-29 18:22:13 +09:00
Atsushi Eno c1ba5d85f2 Ongoing build engine implementation and some fixes in build submission handling.
BuildSubmission could be posted multiple times so that multiple projects can
be built within one BuildManager. Now node manager should be implemented too...
2013-11-29 18:22:12 +09:00
Atsushi Eno ff2726545d Fix API: remove non-existent property in .NET (copy-paste bad). 2013-11-29 18:22:11 +09:00
Atsushi Eno 86eddfa308 update .csproj. 2013-11-29 18:22:10 +09:00
Atsushi Eno 5aeda36257 Add missing ITaskFactory/2 and co. Add BuildEventArgs.set_Context(). 2013-11-29 18:22:09 +09:00
Atsushi Eno 5040de10b2 update csproj. 2013-11-29 18:22:08 +09:00
Atsushi Eno e75f0d726b Add IBuildEngine implementation, required to expose some features to tasks. 2013-11-29 18:22:07 +09:00
Atsushi Eno c6c76b3a70 add test for BuildManager.PendBuildRequest(). Looks like it's mostly for internal use... 2013-11-29 18:22:06 +09:00
Atsushi Eno 91aaf0f60b fix NET_2_0 build: INodeLogger is only in 4.0. 2013-11-29 18:22:05 +09:00
Atsushi Eno 8d481f11d1 slightly reorganized external sources dirs. 2013-11-29 18:22:04 +09:00
Atsushi Eno 1d7a853df4 add missing copyright headers. 2013-11-29 18:22:03 +09:00
Atsushi Eno ca691c74f0 implement HostServices, not sure if we're going to use it though. 2013-11-29 18:22:02 +09:00
Atsushi Eno 6b8f1d0eee add missing license headers. 2013-11-29 18:22:01 +09:00
Atsushi Eno 220d96cba7 slightly reduce NIE code path. 2013-11-29 18:22:00 +09:00
Atsushi Eno 282915ba7e update csproj. 2013-11-29 18:22:00 +09:00
Atsushi Eno 741650f7c2 Add test for BuildSubmission (which is mostly for build operation so far). 2013-11-29 18:21:58 +09:00
Atsushi Eno 339871f523 Implement more precise DefaultTargets handling. 2013-11-29 18:21:57 +09:00
Atsushi Eno a1160ebc79 Several fixes on manual expression parser with related to function args and property accesses. 2013-11-29 18:21:56 +09:00
Atsushi Eno c942af4f9f fix some string evaluator tests. Some of them even fails in prop values. 2013-11-29 18:21:56 +09:00
Atsushi Eno 006a7bd303 slightly improve property access error message. 2013-11-29 18:21:55 +09:00
Atsushi Eno caf1e274b2 Apply windows path loader fix to ProjectInstance too. 2013-11-29 18:21:54 +09:00
Atsushi Eno 6626dfe95a Resolve property value by EvaluatedValue where appropriate. 2013-11-29 18:21:53 +09:00
Atsushi Eno bc3ab82b2b Sequence of comparison expressions (A==B==C) is invalid. Avoid ANE on property evaluation. 2013-11-29 18:21:52 +09:00
Atsushi Eno 2efdcb618d Fix binary expression evaluation. They can be combined. 2013-11-29 18:21:51 +09:00
Atsushi Eno c5d68b1922 implement prebuilt Condition evaluation function support. 2013-11-29 18:21:50 +09:00
Atsushi Eno a666fc9886 Fix location of windows path compatibility change. 2013-11-29 18:21:49 +09:00
Atsushi Eno 1280072e42 Fix 4.5 toolpath. 2013-11-29 18:21:48 +09:00
Atsushi Eno 0e8be129d9 fix import path for ProjectInstance too. 2013-11-29 18:21:47 +09:00
Atsushi Eno 5671aa742a update csproj. 2013-11-29 18:21:46 +09:00
Atsushi Eno 4986fc1d50 Add missing built-in properties. Resolve properties on import paths. Resolve \ with / on import paths. 2013-11-29 18:21:45 +09:00
Atsushi Eno c3e86429b4 Project needs to build just fine for empty projects. 2013-11-29 18:21:44 +09:00
Atsushi Eno 9bd1c8dcc1 some BuildSubmission and BuildResult implementation, as well as tiny bit of build operation. 2013-11-29 18:21:43 +09:00
Atsushi Eno dfcb502de9 sorted out BuildManager build logic up to BuildSubmission.Execute(). 2013-11-29 18:21:42 +09:00
Atsushi Eno 6d54b6e218 Reuse logger types in Microsoft.Build.dll. 2013-11-29 18:21:41 +09:00
Atsushi Eno 7c53a29fbe update csproj. 2013-11-29 18:21:40 +09:00
Atsushi Eno 7dd532d3ca sorted out logger stuff. Imported many of existing loggers from MS.Build.Engine. Stubbed some. 2013-11-29 18:21:39 +09:00
Atsushi Eno a4aae3e863 update .sources too. 2013-11-29 18:21:39 +09:00
Atsushi Eno cf31055124 update csproj. 2013-11-29 18:21:38 +09:00
Atsushi Eno 926c4f9bf4 add missing logging types which are required for Microsoft.Build.dll. 2013-11-29 18:21:37 +09:00
Atsushi Eno 0b80dfee1e update csproj. 2013-11-29 18:21:36 +09:00
Atsushi Eno 5eb01842ba Add missing ProjectPropertyGroupTaskIntance and descendant, and implement more of this namespace. 2013-11-29 18:21:35 +09:00
Atsushi Eno e7f42549e9 Added some comments on loaders in the two project object models. 2013-11-29 18:21:34 +09:00
Atsushi Eno 886aed3450 implemented more ProjectInstance family. Enabled some tests back. 2013-11-29 18:21:33 +09:00
Atsushi Eno 38b7328cb2 implemented a lot of ProjectTargetInstance and its descendants. Fixed a lot of Location stuff to fix NET_4_0 build. 2013-11-29 18:21:32 +09:00
Atsushi Eno 191815a093 implement basic project loader for ProjectInstance. 2013-11-29 18:21:32 +09:00
Atsushi Eno b00ebb0e3c refactoring some internals to make code sharable between Project and ProjectInstance. 2013-11-29 18:21:31 +09:00
Atsushi Eno c62b93e4e2 update .csproj. 2013-11-29 18:21:31 +09:00
Atsushi Eno ce24491e7a implement ProjectMetadataInstance and add some MS.Build.Execution tests. 2013-11-29 18:21:16 +09:00
Atsushi Eno 36771fce36 add another GetLoadedProject() test, this time with ProjectInstance. 2013-11-29 18:21:15 +09:00
Atsushi Eno bf7320eaf4 implement GetLoadedProject(), ProjectAdded and adjust relevant methods. 2013-11-29 18:21:14 +09:00
Atsushi Eno fbbca213a6 Added workaround for DirectoryScanner bug that finds multiple files. Then implemented RecursiveDir metadata. 2013-11-29 18:21:13 +09:00
Atsushi Eno f92a803094 update .csproj. 2013-11-29 18:21:13 +09:00
Atsushi Eno 74ce017542 make TaskItem available (as internal) in Microsft.Build.dll. 2013-11-29 18:21:12 +09:00
Atsushi Eno 6425733f3d implement item wildcard support, except for "**" which looks buggy at DirectoryScanner. 2013-11-29 18:21:11 +09:00
Atsushi Eno f86010a6d9 implement IsImported. 2013-11-29 18:21:10 +09:00
Atsushi Eno b11b278ebd implemented well-known item metadata. 2013-11-29 18:21:09 +09:00
Atsushi Eno 6956ad5939 Fix API for ProjectItemElement.Condition. Add test for item definition Condition. 2013-11-29 18:21:08 +09:00
Atsushi Eno 631ccfc234 GetMetadataValue() returns "" if metadata is not found. 2013-11-29 18:21:07 +09:00
Atsushi Eno 251ee38cb5 Fix MSBuildThisFile reserved property value (empty by default). 2013-11-29 18:21:06 +09:00
Atsushi Eno 07e6b5cf6f got imports working. Imported ProjectRootElement needed XmlReader to load it. 2013-11-29 18:21:05 +09:00
Atsushi Eno 386284c675 For expression, string equality comparison is done in case-insensitive manner. 2013-11-29 18:21:04 +09:00
Atsushi Eno e91fa0a69d fix couple of regressions caused by lazy evaluation of properties. 2013-11-29 18:21:03 +09:00
Atsushi Eno e57cbc1a2f update .csproj. 2013-11-29 18:21:02 +09:00
Atsushi Eno eb71da804f partal import implementation. 2013-11-29 18:21:01 +09:00
Atsushi Eno a645b4d25a missing Project attribute causes load error at ProjectRootElement level. 2013-11-29 18:21:00 +09:00
Atsushi Eno ce1337ab37 Allow empty function args and fix "sigle-argument is ignored" issue. 2013-11-29 18:20:59 +09:00
Atsushi Eno 966a31ce5a Fix fullname (dotted name) parsing in boolean expression parser. 2013-11-29 18:20:58 +09:00
Atsushi Eno eba5645adb Now we can directly evaluate boolean expression with jay-based parser. 2013-11-29 18:20:57 +09:00
Atsushi Eno c96143ed69 fix NRE. 2013-11-29 18:20:56 +09:00
Atsushi Eno 38950e5ba9 fix NRE. 2013-11-29 18:20:55 +09:00
Atsushi Eno 5c83336164 implemented (hacky) method resolution for overloads and varargs. 2013-11-29 18:20:54 +09:00
Atsushi Eno d1bd7c431d support property function calls in tokenizer. 2013-11-29 18:20:53 +09:00
Atsushi Eno 55e01f6eaf support type's static property access. 2013-11-29 18:20:53 +09:00
Atsushi Eno d24ec0ee9c fix whitespace skipping. Do not accept sequential binary operations. 2013-11-29 18:20:52 +09:00
Atsushi Eno 222b644a94 prevent invalid sequential property reference such as $(X)$(Y), by explicitly adding surrounding APOS to the expanded value. 2013-11-29 18:20:51 +09:00
Atsushi Eno 52fcb37ef5 couple of tokenization fixes with more tests. 2013-11-29 18:20:51 +09:00
Atsushi Eno 2296908450 made several fixes in jay-based expression parser and use it for boolean evaluation.
For item/propery reference expansion, use manual parser.
2013-11-29 18:20:50 +09:00
Atsushi Eno ba15463a18 fix test for GetPropertyValueEscaped(). (expects WTF behavior) 2013-11-29 18:20:49 +09:00
Atsushi Eno 6c1ade2208 evaluate condition on PropertyGroup too. 2013-11-29 18:20:49 +09:00
Atsushi Eno f49a313031 evaluate Condition on property to add Properties list.
Now we got a couple of errors because of malfunctional expression evaluator...
2013-11-29 18:20:48 +09:00
Atsushi Eno e44316aac8 property reference is valid in Condition too. 2013-11-29 18:20:47 +09:00
Atsushi Eno e401791fd2 implement well-known and reserved properties. 2013-11-29 18:20:47 +09:00
Atsushi Eno daf32712af Item references can be evaluated as boolean and hence can be a valid Condition expression. 2013-11-29 18:20:46 +09:00
Atsushi Eno 31e660b0f4 fix tests that incorrectly allowed empty/missing Include attribute. 2013-11-29 18:20:45 +09:00
Atsushi Eno 7892970584 implement string literal boolean evaluation. 2013-11-29 18:20:44 +09:00
Atsushi Eno e71071b1da forgot to commit exception change. 2013-11-29 18:20:43 +09:00
Atsushi Eno 36203fda98 fix IndexOutOfRangeException for parsing "$" "@" or "%" (one char for each). 2013-11-29 18:20:43 +09:00
Atsushi Eno 1169b64aa3 implement IsDirty() (incomplete of course), MarkDirty() and DisableMarkDirty. Fix tests. 2013-11-29 18:20:42 +09:00
Atsushi Eno fc8246b03a update csproj. 2013-11-29 18:20:41 +09:00
Atsushi Eno 1da050daf0 Raise error when project item has empty Include attribute or lacks it. 2013-11-29 18:20:40 +09:00
Atsushi Eno c0fcd506d6 ProjectItems are created after splitting Include paths by ';'.
So there could be more than one ProjectItem for the same ProjectItemElement.
2013-11-29 18:20:39 +09:00
Atsushi Eno a5f96125d0 update csproj. 2013-11-29 18:20:38 +09:00
Atsushi Eno 691b1e9799 delete generated code. 2013-11-29 18:20:37 +09:00
Atsushi Eno 5002b25ec3 Altered expression parser to hand-written one (which was kind of anticipated) for torelant parsing. 2013-11-29 18:20:37 +09:00
Atsushi Eno 7b9d44886e Add full-scratch expression parser implementation. 2013-11-29 18:20:36 +09:00
Atsushi Eno 34d86a8497 implemented couple of Project members, while changing some members to throw NIE. 2013-11-29 18:20:05 +09:00
Atsushi Eno cda2e72d37 update .csproj. 2013-11-29 18:20:04 +09:00
Atsushi Eno 47ccaa7d18 implement ProjectItem and co. 2013-11-29 18:20:03 +09:00
Atsushi Eno 85ed86a799 ProjectItemDefinition.ItemType was not initialized (also not tested.) 2013-11-29 18:20:02 +09:00
Atsushi Eno 1a3cd4eac3 update .csproj. 2013-11-29 18:20:02 +09:00
Atsushi Eno 819b18a732 implement ProjectItemDefinition and co. 2013-11-29 18:20:01 +09:00
Atsushi Eno edc982f914 implement Project.RemoveProperty() and ProjectProperty.Predecessor (i.e. property overrides). 2013-11-29 18:20:01 +09:00
Atsushi Eno 5cce2ee718 implement several ProjectProperty types. 2013-11-29 18:20:00 +09:00
Atsushi Eno 48bd97af64 fix csproj too. 2013-11-29 18:20:00 +09:00
Atsushi Eno d39128ce21 fix wrong type nest for added event handler and args. 2013-11-29 18:19:59 +09:00
Atsushi Eno b4aaae8931 update .csproj. 2013-11-29 18:19:58 +09:00
Atsushi Eno dedde5fb02 Added missing ProjectCollection events and co. 2013-11-29 18:19:58 +09:00
Atsushi Eno bc0f489f06 update .csproj. 2013-11-29 18:19:57 +09:00
Atsushi Eno 21441a9b48 implement basic ProjectProperty members. 2013-11-29 18:19:57 +09:00
Atsushi Eno be330e18ff Add more tests and fixes in Construction loaders. 2013-11-29 18:19:56 +09:00
Atsushi Eno 659eb9638a update csproj. 2013-11-29 18:19:55 +09:00
Atsushi Eno 97ea0acfec implement toolset and build related members. 2013-11-29 18:19:55 +09:00
Atsushi Eno 618d699a42 forgot to add ProjectCollectionTest.cs. 2013-11-29 18:19:54 +09:00
Atsushi Eno 4c7461c7af update .csproj. 2013-11-29 18:19:54 +09:00
Atsushi Eno b053b3c022 Add more project loader tests. 2013-11-29 18:19:53 +09:00
Atsushi Eno 400cf174f2 Fix regarding GetProjectInstanceForBuild(), and added some tests regarding Escape(). 2013-11-29 18:19:52 +09:00
Atsushi Eno 3da51cf17a update csproj. 2013-11-29 18:19:52 +09:00
Atsushi Eno 6e8d703fd0 implement Project.Build() and ProjectInstance.Build() (they lead to NIE yet)
..., but still sorts out relationship between those types and methods.
2013-11-29 18:19:51 +09:00
Atsushi Eno 0656e72353 fill ElementLocation items at loading. Fix Subtool-related build fix for 4.0. 2013-11-29 18:19:51 +09:00
Atsushi Eno 5cc3b0a007 update .csproj. 2013-11-29 18:19:50 +09:00
Atsushi Eno c6652332bc Add BuildEventContextTest and slightly made Equals() clear on how it works. 2013-11-29 18:19:50 +09:00
Atsushi Eno 6e44a54461 update test csproj. 2013-11-29 18:19:49 +09:00
Atsushi Eno 6c983b97f1 Fix ProjectRootElement.DirectoryPath. Add unit test for ProjectRootElement. 2013-11-29 18:19:48 +09:00
Atsushi Eno 60309a490e update MS.Build csproj to the latest status. 2013-11-29 18:19:48 +09:00
Atsushi Eno e33a6e056b Fix net_4_0 build. 2013-11-29 18:19:47 +09:00
Atsushi Eno 7631feae4b add BuildEventContext to .csproj. 2013-11-29 18:19:47 +09:00
Atsushi Eno 5d2f218ebb Add BuildEventContext. 2013-11-29 18:19:46 +09:00
Atsushi Eno cbd796fab3 update MS.Build test csproj. 2013-11-29 18:19:46 +09:00
Atsushi Eno 49fe80ab14 Add ToolsetTest and fix Toolset construction. 2013-11-29 18:19:45 +09:00
Atsushi Eno c7e31cf15b Fix MS.Build.Tasks.csproj build too. 2013-11-29 18:19:45 +09:00
Atsushi Eno 9d1b389da5 fix test csproj build. 2013-11-29 18:19:44 +09:00
Atsushi Eno 52728856ba update MS.Build.csproj. 2013-11-29 18:19:43 +09:00
Atsushi Eno a2ccbe1a15 implement ProjectCollection.Toolsets. 2013-11-29 18:19:43 +09:00
Atsushi Eno ad6f38d35e Add ToolLocationHelper and co. to MS.Build.dll (as internal). 2013-11-29 18:19:42 +09:00
Atsushi Eno f52d76b755 ToolLocationHelper is now used in MS.Build.dll too (as internal). 2013-11-29 18:19:42 +09:00
Atsushi Eno 7523eda306 Add IBuildEngine3 and IBuildEngine4 to csproj. 2013-11-29 18:19:41 +09:00
Atsushi Eno f392cecddf Add IBuildEngine3 and IBuildEngine4. 2013-11-29 18:19:41 +09:00
Atsushi Eno 5cc3fe2d12 Add missing tests in csproj. 2013-11-29 18:19:40 +09:00
Atsushi Eno 1b3593d6c2 MS.Build.dll: Add more missing members and implementation for some members. 2013-11-29 18:19:40 +09:00
Atsushi Eno eead7876af implement some MS.Build members as well as adding missing members. 2013-11-29 18:19:39 +09:00
Atsushi Eno cb16086cf3 Add missing ProjectInstance family. 2013-11-29 18:19:38 +09:00
Atsushi Eno 2fa725aeca implement various not-implemented types in Microsoft.Build.dll. 2013-11-29 18:19:38 +09:00
Atsushi Eno 63bc28d10a Add hacking MSBuild solution for MSBuild libraries. 2013-11-29 18:19:37 +09:00
Marek Safar 53cb3abb08 [mcs] Implements definite assignment of expressions 2013-11-29 09:12:28 +01:00
Marek Safar f12192b425 Fixes build 2013-11-29 09:12:28 +01:00
Zoltan Varga 22650957a3 [jit] Get rid of the mono_arch_get_domain_intrinsic () function, use the generic mono_get_domain_intrinsic () function instead. 2013-11-28 20:39:58 +01:00
Zoltan Varga 5a23148944 [x86] Emit the push/pop LMF code as IR on linux. 2013-11-28 03:11:44 -05:00
Zoltan Varga de62cc7d9b [x86] Emit the push/pop LMF code as IR on osx. 2013-11-28 20:08:46 +01:00
Zoltan Varga 38b6a9dffd [gsharedvt] Avoid using gsharedvt trampolines for calls with a non-variable signature. 2013-11-28 19:31:04 +01:00
Zoltan Varga 0b7712cdbc [amd64] Translate TLS offsets on osx/amd64 too. 2013-11-28 19:07:34 +01:00
Zoltan Varga f35e533000 [x86] Revert some changes which seem to cause regressions when compiling fsharp. 2013-11-28 18:34:24 +01:00
Mark Probst 1eef047d0d [sgen] Wait for workers before the finishing nursery collection.
Fixes the sgen-bridge.exe crash on concurrent M&S.
2013-11-28 13:51:35 +01:00
Mark Probst c8ed716a10 [sgen] Missed a binary protocol event for mark. 2013-11-28 13:51:35 +01:00
Mark Probst 0c7553a3de [sgen] Binary protocol records worker thread vs non-worker thread events. 2013-11-28 13:51:34 +01:00
Zoltan Varga 3da6eab45e [x86] Remove some dead code. 2013-11-28 13:34:56 +01:00
Zoltan Varga 88ffd6150f [jit] Translate TLS offsets on osx/x86 in mono_resolve_patch_target () to make OP_TLS_GET_REG/OP_TLS_SET_REG faster. 2013-11-28 13:18:37 +01:00
Zoltan Varga 2d2d96f2d7 [jit] Avoid emitting two AOT_CONST instructions for managed TLS access. 2013-11-28 13:10:50 +01:00
Zoltan Varga 516b33cff4 [x86] Implement OP_TLS_SET/OP_TLS_SET_REG opcodes. 2013-11-28 13:00:59 +01:00
Zoltan Varga f7914fec6d [x86] Disable fast tls access in the push/pop LMF code in AOT mode, the TLS offsets are not constant and we cannot load them from the GOT since the GOT address is not computed yet. 2013-11-28 11:58:03 +01:00
Zoltan Varga 23ddd68e86 [x86] Remove some dead code. 2013-11-28 11:51:14 +01:00
Alistair Leslie-Hughes 3c6517b67e Support for DispIdAttribute in GetIdsOfNames
License: This patch is under the MIT/X11 license.
2013-11-28 14:08:14 +11:00
Zoltan Varga aa389dc8c9 [x86] Fix the epilog tls access on linux too. 2013-11-27 20:59:19 -05:00
Zoltan Varga 9f593ceb06 [runtime] Fix the windows build. 2013-11-28 10:56:22 +01:00
Zoltan Varga 8355e54373 [x86] Fix tls access in epilogs in AOT code. 2013-11-28 10:46:22 +01:00
Zoltan Varga 2cd074ed31 Rework the x86 lmf code to use stores instead of pushes, and to be more consistent with the code on other platforms. 2013-11-27 23:29:10 +01:00
Zoltan Varga 2b2806ddf4 Revert "Rework the x86 lmf code to use stores instead of pushes, and to be more consistent with the code on other platforms."
This reverts commit 4f562893b7.

Revert this as it breaks many tests.
2013-11-27 22:13:58 +01:00
Zoltan Varga 0ba0e0cc67 [runtime] Really fix the windows build. 2013-11-27 20:46:59 +01:00
Zoltan Varga 4f562893b7 Rework the x86 lmf code to use stores instead of pushes, and to be more consistent with the code on other platforms. 2013-11-27 20:44:58 +01:00
Zoltan Varga 267e4f693a [runtime] Fix the windows build. 2013-11-27 19:38:36 +01:00
Craig Morris e5a83e6857 SqlBulkCopy Implementation
This are the code changes to get the SqlBulkCopy procedure working on
mono.
2013-11-27 11:11:11 -07:00
Marek Safar 4855d214c4 [corlib] Better exception message for unexpected task result 2013-11-27 18:55:42 +01:00
Alex Rønne Petersen 7897869121 Merge pull request #812 from ColdPie1/master
Fix getting current system locale
2013-11-27 09:44:14 -08:00
Rodrigo Kumpera 3c3e109e59 Merge pull request #815 from tmds/master
socket-io: interface index handling
2013-11-27 05:44:36 -08:00
Marek Safar 56ccb68415 [mcs] Emit this initializer for structs. Fixes #16430 2013-11-27 14:12:46 +01:00
Rolf Bjarne Kvinge 7249051374 Ignore generated files. 2013-11-27 11:27:24 +01:00
Zoltan Varga 5b65cb80ac [runtime] Avoid busy waiting when using the MONO_DEBUG=suspend-on-sigsegv option. 2013-11-27 10:11:27 +01:00
brendanzagaeski d0c24d73e5 Bug 15572. Lookup KnownTypeCollection element types in MSSimpleNamespace
This patch prevents the problem in https://bugzilla.xamarin.com/show_bug.cgi?id=15572. This change allows the DataContractSerializer to deserialize DataMembers that use an array KnownType, at least for the test case in the bug report.
2013-11-26 23:09:00 -05:00
brendanzagaeski df9535c5a4 Bug 15574. XML deserialization recursion: add array type to known_types?
One way to prevent https://bugzilla.xamarin.com/show_bug.cgi?id=15574 is to add the problematic array type to the `known_types`.

On the other hand, this might not be the intended use of `known_types`. In that case, perhaps a better fix would be to guard against recursion in the `foreach` loop:

	if (t != type)
		RegisterTypeAsKnown (t);
2013-11-26 22:47:48 -05:00
Alex Rønne Petersen 742171f317 Unbreak the amd64 build. 2013-11-27 03:45:00 +01:00
Alex Rønne Petersen 1a05494a15 Remove mdb stuff from configure.in. 2013-11-27 03:23:41 +01:00
Master T 962a30b605 SocketTest: added tests for multicast index handling for MulticastOption class and MulticastInterface socket option
This commit is under the MIT license.
2013-11-27 00:18:46 +01:00
Rodrigo Kumpera 958c1e23f4 [runtime] Remove the old debugger interface. 2013-11-26 14:25:19 -05:00
Rodrigo Kumpera 7d747d08f8 [jit] Remove mono_debug_add_icall_wrapper as it doesn't do anything. 2013-11-26 14:25:18 -05:00
Rodrigo Kumpera 556fd28f0c [runtime]Hide public fields and kill MONO_DEBUG_FORMAT_DEBUGGER. 2013-11-26 14:25:17 -05:00
Rodrigo Kumpera 8c42423030 [jit]Remove the last uses of MONO_DEBUGGER_SUPPORTED. 2013-11-26 14:25:16 -05:00
Rodrigo Kumpera e8b614d5bc [runtime] Mark all symbols in mono-debug-debugger as private as we don't install that header. 2013-11-26 14:25:05 -05:00
Rodrigo Kumpera 308fad9335 [runtime] Remove mono_debug_using_mono_debugger. This would only return true under mdb. 2013-11-26 14:25:04 -05:00
Rodrigo Kumpera fea01b0982 [jit] Kill the debug-mini.h header. 2013-11-26 14:25:03 -05:00
Rodrigo Kumpera d5ce87ee9a [jit] Remove some unused definitions. 2013-11-26 14:25:03 -05:00
Rodrigo Kumpera b7ba901ae9 [jit] Remove the rest of the API exposed by debug-mini.h. 2013-11-26 14:25:02 -05:00
Rodrigo Kumpera 254ffd0190 [jit] Remove mono_debugger_handle_exception, which was only used by mdb. 2013-11-26 14:25:01 -05:00
Rodrigo Kumpera 671814f8b3 [jit] Remove the exception handling code of the old debugger. 2013-11-26 14:24:21 -05:00
Rodrigo Kumpera f6d49c21dd [jit] Kill more of mdb. 2013-11-26 14:24:20 -05:00
Rodrigo Kumpera 549d7a45e7 [jit] Kill debug-debugger.c 2013-11-26 14:24:19 -05:00
Rodrigo Kumpera 3c29ad660a [jit] Remove the mdb debug-info files. 2013-11-26 14:24:14 -05:00
Marek Safar e062a637a3 [mcs] Don't merge unreachable if blocks 2013-11-26 19:02:57 +01:00
Alex Rønne Petersen e554e95f15 Merge pull request #818 from hanswolff/patch-1
fixed some warnings in mono-proclib.c
2013-11-26 07:37:34 -08:00
Marek Safar a6cb9fd714 [mcs] Fix flow analysis of infinite for statement with breaks 2013-11-26 15:16:37 +01:00
Marek Safar e0f8c2c2f8 [mcs] Run struct field assignment check on every exit point. 2013-11-26 14:25:01 +01:00
Marek Safar 099ffcb094 [mcs] Reachability analysis of constant switch 2013-11-26 13:08:31 +01:00
Hans Wolff 5fdcb5fc69 fixed some warnings in mono-proclib.c
mono-proclib.c: In function ‘get_cpu_times’:
mono-proclib.c:600:24: warning: ‘sirq_ticks’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   *sirq = (sirq_ticks) * 10000000 / hz;
                        ^
mono-proclib.c:598:22: warning: ‘irq_ticks’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   *irq = (irq_ticks) * 10000000 / hz;
                      ^
mono-proclib.c:602:24: warning: ‘idle_ticks’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   *idle = (idle_ticks) * 10000000 / hz;
                        ^
mono-proclib.c:596:29: warning: ‘system_ticks’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   *systemt = (system_ticks) * 10000000 / hz;
                             ^
mono-proclib.c:594:23: warning: ‘nice_ticks’ may be used uninitialized in this function [-Wmaybe-uninitialized]
   *user = (user_ticks + nice_ticks) * 10000000 / hz;
                       ^
mono-proclib.c:594:23: warning: ‘user_ticks’ may be used uninitialized in this function [-Wmaybe-uninitialized]
2013-11-26 11:38:24 +00:00
Marek Safar 66403410b0 [mcs] Excluded methods should not take a part in flow analysis 2013-11-25 17:51:34 +01:00
Bart Vries e3c37d1042 LogicalSet/GetData implementation in CallContext 2013-11-25 16:59:59 +01:00
Marek Safar 1d5cefe7ad [mcs] Arguments flow analysis needs to ignore out modifier. 2013-11-25 16:02:58 +01:00
Marek Safar 8c6864df1c [mcs] Optimize DefiniteAssignmentBitSet 2013-11-25 16:02:58 +01:00
Mark Probst 8a4e1ca74e [sgen] Implement our own qsort() so as not do deadlock.
qsort() may call malloc(), which can lead to a deadlock when the
world is stopped.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=16432.
2013-11-25 15:42:08 +01:00
Mark Probst 10ee80de68 [sgen] Improve describe_ptr().
Don’t try to print the vtable if the major allocator knows it’s invalid.
Print bridge information.
2013-11-25 15:22:45 +01:00
Zoltan Varga 4c0376d037 [amd64] Unify the register saving/restoring code for the fp/no-fp cases. 2013-11-25 10:33:46 +01:00
Master T 27024b966c socket-io.c: merge #ifdef HAVE_STRUCT_IP_MREQN of network interface index and address
This commit and the related commits 11b2e351d8 and af9fc5f16f) are under the MIT license.
2013-11-25 08:56:49 +01:00
Zoltan Varga 0ad5599acb [amd64] Simplify the push/pop LMF code a bit more. 2013-11-24 20:56:32 +01:00
Zoltan Varga f06efbe8b1 Fix a warning. 2013-11-24 20:41:42 +01:00
Zoltan Varga b710d972a8 Fix a warning. 2013-11-24 13:35:00 -05:00
Zoltan Varga 07c19b537b [amd64] Use the IR based push/pop LMF code on all platforms except windows. 2013-11-24 13:33:48 -05:00
Marek Safar d92b0d6d9f [mcs] Dynamically calculate size of flow-analysis bitset. Fixes #4210 2013-11-24 14:14:54 +01:00
Master T af9fc5f16f socket-io: pass MulticastOption InterfaceIndex into ip_mreqn imr_ifindex 2013-11-24 10:27:06 +01:00
Master T 11b2e351d8 socket-io: make it possible to specify an interface index as a MulticastInterface SocketOption on linux.
On windows, a value to IP_MULTICAST_IF with a most significant byte of zero is interpreted as an interface index instead of an ip address.
This makes it possible to set the interface index from .NET as follows:
socket.SetSocketOption(SocketOptionLevel.IP,
SocketOptionName.MulticastInterface, IPAddress.HostToNetworkOrder(ifindex));

For this to work on other platforms, we need to detect this case and handle it with an ip_mreqn struct.
2013-11-24 10:23:36 +01:00
Jeffrey Stedfast 2c7864ae98 [Mono.Data.Sqlite] Fixed for Windows .NET 4.0
Thanks to Joe for the patch.

Fixes bug #2148
2013-11-23 15:56:42 -05:00
Zoltan Varga c54015435a [sgen] Add minimal mingw64 support. 2013-11-23 20:02:50 +01:00
Zoltan Varga c6a041ed80 Disable a corlib test which hangs on windows. 2013-11-23 20:02:49 +01:00
Alex Rønne Petersen 926638469e Fix the encoding of x86_imul_reg_mem_imm. 2013-11-23 18:26:55 +01:00
Jérémie Laval 2211e3a5d0 Merge pull request #811 from criteo/16334-ConcurrentBag
[Bug 16334] Fix ConcurrentBag.TryTake and TryPeek
2013-11-22 13:35:42 -08:00
Maxime Brugidou 07be9a1f9c Add Unit tests 2013-11-22 15:33:26 +01:00
Marek Safar 86d6b6f7ca [mcs] Flow analysis of conditional expression 2013-11-21 21:06:54 +01:00
Marek Safar c5d1278525 Update failing tests 2013-11-21 21:06:53 +01:00
Zoltan Varga 1a8004315c [jit] Implement the optimized variant of the push/pop LMF code on amd64. 2013-11-21 18:55:24 +01:00
Zoltan Varga 4dc607fc8c [jit] Fix the optimized variant of push/pop LMF code. 2013-11-21 18:55:24 +01:00
Marek Safar 1ff37128b7 Add more tests 2013-11-21 15:06:15 +01:00
Marek Safar 31e9bb50b3 [mcs] Better error message for expected return expression in async Task<T> block 2013-11-21 14:59:32 +01:00
Marek Safar d12330eda7 [mcs] Reachability and flow analysis rewrite to work on resolved statements and expressions 2013-11-21 14:43:08 +01:00
Zoltan Varga cc4049bcf2 [jit] Emit the push/pop LMF code as IR on amd64. 2013-11-21 11:47:50 +01:00
Zoltan Varga e1e914a0cb [jit] Avoid pushing the lmf in inlined methods. Allow the variable holding the lmf address to be allocated to a global register. 2013-11-21 11:47:50 +01:00
Miguel de Icaza 658753c9c8 Merge pull request #780 from miniBill/master
Fix off-by-one error in ArraySegment
2013-11-20 10:00:03 -08:00
Miguel de Icaza 748a705230 Merge pull request #814 from ranma42/fix-monop
[monop] Fix handling of private and filter-obsolete flags when rendering...
2013-11-20 09:34:34 -08:00
Miguel de Icaza 05007a63c5 Merge pull request #802 from alistair/universaltime_at_boundary_end
TimeZone.GetUtcOffset daylight savings improvements
2013-11-20 09:34:07 -08:00
Andrea Canciani a726ea2b13 [monop] Fix handling of private and filter-obsolete flags when rendering all types
They were simply swapped.
2013-11-20 17:42:49 +01:00
Alex Rønne Petersen 9a587b5266 Merge pull request #807 from akoeplinger/fix-fonttest
Fixed a test failure that occurs when the specified font is not installed
2013-11-19 21:03:07 -08:00
Alex Rønne Petersen 114b545a2c Merge pull request #810 from criteo/16267-SemaphoreSlim
[Bug 16267] SemaphoreSlim.Wait fix when no timeout
2013-11-19 21:02:33 -08:00
Alex Rønne Petersen 261cdf42e5 Merge pull request #813 from ColdPie1/mingw64fix
Check for __readfsdword at configure-time
2013-11-19 20:58:11 -08:00
Rodrigo Kumpera 04fd2a832c Bump mono to 3.2.7. 2013-11-19 16:35:03 -05:00
Andrew Eikum 4f76360417 Check for __readfsdword at configure-time
Recent versions of mingw-w64 have moved this definition to a header
included by this file, so checking simply for GCC would cause a multiple
definition error. We should instead check for this function's
availability at configure-time.

These changes are released under MIT/X11 license.
2013-11-19 14:16:38 -06:00
Andrew Eikum b727b34091 Replace underscores with hyphens when reading system locale
The locale descriptions in
<mono/metadata/culture-info-tables.h:culture_name_entries> use 'xx-yy'
format, where most current systems use 'xx_YY', including Mono itself in
<eglib/src/gmisc-win32.c:g_win32_getlocale>. In normalizing the system
locale for comparison, we should switch any underscores for dashes.

Mono used to do this, but commit
be532638f5 removed this behavior, which
causes System.Globalization.CultureInfo.CurrentCultureInfo to always
point to the invariant culture on systems with LANG similar to xx_YY.

These changes are released under MIT/X11 license.
2013-11-19 13:38:19 -06:00
Miguel de Icaza 7b737a2715 Update for coverity 2013-11-19 13:54:44 -05:00
Miguel de Icaza 6cfd02c68d List maintainer, for scan.coverity.com 2013-11-19 13:53:59 -05:00
Zoltan Varga 54d1751b24 [sdb] Move the setup of the sdb invoke LMF structure to an arch-specific function mono_arch_init_lmf_ext (). 2013-11-19 17:14:42 +01:00
Zoltan Varga 0701d9d07f [amd64] Instead of saving callee saved registers in the LMF in trampoline frames, save a pointer to the register array inside the trampoline frame. 2013-11-19 17:14:42 +01:00
Rodrigo Kumpera 90e5ec63d5 [bcl]CultureInfo.DefaultThreadCurrentUICulture has now been implemented. Remove [MonoTODO] 2013-11-19 10:51:15 -05:00
Zoltan Varga b4f562d82c [amd64] Remove the unused 'method' field from MonoLMF. 2013-11-19 15:24:46 +01:00
Sebastien Pouliot f4dfcba64c [linker] Allow overriding MarkCustomAttribute and expose the MarkDefaultConstructor feature to subclasses 2013-11-19 08:41:57 -05:00
Maxime Brugidou 233396aa13 ConcurrentBag staging could become empty
after all items have been removed from a bag, the staging dictionary
is cleaned up but never filled again.
2013-11-19 13:55:03 +01:00
Zoltan Varga 18299f080f [llvm] Fix the handling of moves in the LICM optimization. 2013-11-19 13:16:10 +01:00
Zoltan Varga e4bf54392a [llvm] Decompose OP_STOREV_MEMBASE opcodes earlier since they might need write barriers. 2013-11-19 12:55:45 +01:00
Zoltan Varga 3a9ccd0683 [llvm] Implement support for OP_TLS_GET_REG on osx/amd64. 2013-11-19 12:05:04 +01:00
Zoltan Varga 12153dd3e6 [llvm] Pass the type token index to throw_corlib_exception on amd64 too. 2013-11-19 11:44:53 +01:00
Maxime Brugidou d970f3744e [Bug 16334] Fix ConcurrentBag.TryTake and TryPeek
Should return false if no result in all cases

see https://bugzilla.xamarin.com/show_bug.cgi?id=16334
2013-11-19 11:09:35 +01:00
Zoltan Varga 77e28973ac [llvm] Make the rgctx arg a pointer type as well. 2013-11-19 05:42:23 +01:00
Zoltan Varga f200c99c33 [llvm] Make some types more precise to decrease the number of int<->ptr conversions generated. 2013-11-19 05:28:56 +01:00
Rodrigo Kumpera 349cb638ff [bcl] Implement CultureInfo.DefaultThreadCurrentUICulture. 2013-11-18 18:13:03 -05:00
Rodrigo Kumpera 703eb84911 [bcl]Add test for CultureInfo.DefaultThreadCurrentCulture 2013-11-18 18:13:03 -05:00
Rodrigo Kumpera 5b8f9ad666 [bcl] Implement CultureInfo.DefaultThreadCurrentCulture.
The way DefaultThreadCurrentCulture is to be implemented is that its current value
will always be used by a thread that didn't set a value for its culture.

This means we can't cache DefaultThreadCurrentCulture value as it's allowed to
change and threads must always show the latest value.
2013-11-18 18:13:02 -05:00
Rodrigo Kumpera b1b2a0a8fb [bcl]Memoize the default culture so it can be reused across threads. 2013-11-18 18:13:02 -05:00
Rodrigo Kumpera e499793125 [bcl]Set the culture of the thread local NumberFormatter everytime.
the problem of changing the culture when a new value is set in the current thread
is that is doesn't work well with CultureInfo.DefaultThreadCurrentCulture.
2013-11-18 18:13:02 -05:00
Jonathan Pryor 57091eda02 [System] Add more of System.ComponentModel to MOBILE profile.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=16071

Improve compatibility of the MOBILE profile with Desktop .NET:
Add (nearly) everything from System.ComponentModel (and nested
namespaces) _except_ for things that depend on Licensing.

This includes System.ComponentModel.Design.HelpKeywordAttribute
(requested in Bug #16071), many many other attributes, more
exceptions, more EventArgs subclasses, etc.
2013-11-18 16:03:49 -05:00
Rodrigo Kumpera 055eeccb76 [bcl] Add regression test for bxc #16096. 2013-11-18 14:26:40 -05:00
Rodrigo Kumpera 5d6ca293ec [runtime] Avoid caching member_ref tokens of dynamic images. Fixes #16096
SRE encodes references to self-instantiated generic types in a different way
that regular code.

This is required as there's no clear way to differentiate between an open type
and a self-instantiated type when using System.Type.

Given that restriction, code that deals with loading such methods must take
special case and not cache then as the context under generic sharing will not
be used - so it would be seen as cacheable.

When using regular instantiation the same method lookup will require the context
to be used but will hit the cache before.

This is another problem of passing the instantiation context around. It messes
up with way too much stuff.
2013-11-18 14:26:39 -05:00
Zoltan Varga 0f197300e9 [llvm] Disable the LLVM verifier, it does module wide checks leading to quadratic behavior. 2013-11-18 10:09:14 +01:00
Zoltan Varga cb23a4fd2f [llvm] Collect used methods only in AOT mode. 2013-11-18 10:05:23 +01:00
Zoltan Varga f8e9706a45 [llvm] Add some micro optimizations to the LLVM/AOT code. 2013-11-18 07:52:32 +01:00
Zoltan Varga 5106e3a56d [llvm] Use a pointer type as the type of 'this' instead of an int. 2013-11-18 06:08:29 +01:00
Zoltan Varga 31d9292013 Fix the previous commit. 2013-11-18 05:32:05 +01:00
Zoltan Varga 07d6cfef02 Bump expected LLVM version in configure. 2013-11-18 05:31:03 +01:00
Zoltan Varga 62dda65498 Upgrade the LLVM backend to LLVM e656caccc7dfb5c51c208906f0e176f0973f030f. 2013-11-18 05:20:55 +01:00
Zoltan Varga a2be8ab682 Don't register the LLVM SSE intrinsics on arm. 2013-11-18 05:19:46 +01:00
Zoltan Varga c11973240b [jit] Handle the caller saved D8..D15 register during unwinding on ARM. 2013-11-18 05:19:39 +01:00
Zoltan Varga d6d4d305df [jit] Avoid clearing MONO_INST_FAULT flags when using explicit null checks, LLVM can move the non-faulting loads before the null checks. 2013-11-18 05:19:34 +01:00
Zoltan Varga 270fc62074 [runtime] Fix unaligned access in volatile icalls. 2013-11-16 13:05:55 +01:00
Marek Safar 521e757bfe Bump ikvm-reflection 2013-11-16 10:44:28 +01:00
Marek Safar 384adcd6f3 Add new test 2013-11-16 09:49:47 +01:00
Marek Safar 4571ac894d [ilasm] Correctly set empty export attributes 2013-11-16 09:49:46 +01:00
Zoltan Varga 60145c3028 Fix corlib tests. 2013-11-16 05:21:57 +01:00
Marek Safar cd13a48d06 [mcs] Import only forwarder kind of exported types. 2013-11-15 20:13:08 +01:00
Maxime Brugidou f346baaf96 [Bug 16267] SemaphoreSlim.Wait fix when no timeout
See https://bugzilla.xamarin.com/show_bug.cgi?id=16267
2013-11-15 18:10:16 +01:00
Alex Rønne Petersen a0cd023d06 Fix the nop opcode on some MIPS-based Loongson CPUs.
After much trouble building Mono in Debian/MIPS, @directhex
narrowed it down to this issue:

https://sourceware.org/ml/binutils/2009-11/msg00387.html

So since some of the 2E and 2F versions of the Loongson CPUs
break with a regular `sll zero, zero, 0` we need to issue an
`or at, at, 0`. This makes sure we don't randomly deadlock or
blow up when the CPU is under heavy load.

Yes, really.
2013-11-15 15:08:06 +01:00
Marek Safar 891d594b3f Merge pull request #809 from criteo/16186-SqlCommand
[Bug 16186] SqlCommand.BeginExecuteInternal fix
2013-11-15 04:57:53 -08:00
Maxime Brugidou a02d0c2e9a [Bug 16186] SqlCommand.BeginExecuteInternal fix
If you use a stored procedure or a prepared statement, with
CommantType.StoredProcedure the ar variable is not set as the result of
onnection.Tds.BeginExecuteProcedure().
2013-11-15 13:14:08 +01:00
Zoltan Varga 689adf38b5 Mark a few corlib tests as LLVMNotWorking. 2013-11-15 09:23:19 +01:00
Zoltan Varga d115725ade [jit] Make the exceptions.cs test suite runnable in mobile. 2013-11-15 01:41:33 +01:00
Zoltan Varga c3b5906efd [sdb] Add an ExitCode property to VMDeathEvent. Fixes #16113. 2013-11-15 00:59:16 +01:00
Jeffrey Stedfast 75d1cf2f19 [Mono.Debugger.Soft] Added FlagsAttrbite where appropriate 2013-11-14 15:05:01 -05:00
Zoltan Varga 32e5575768 [aot] Increase a buffer size to avoid an assert. Fixes #16239. 2013-11-14 21:01:59 +01:00
Rodrigo Kumpera 18aa5e3bf0 Add some tests for #15124. 2013-11-14 12:28:53 -05:00
Rodrigo Kumpera bd741f0aac [runtime]Type parsing of generics should not rely on the presence of a backtick. Fixes #15124.
We previously depended on the presence of a backtick in a generic type name to try to
parse a generics argument list. This is not what the spec says and F# breaks this expectation.

The right way to handle this is to probe for array syntax.
2013-11-14 12:28:52 -05:00
Rodrigo Kumpera 4a656ad29e [runtime]When setting a loader error, clear the previous one to avoid the leak. 2013-11-14 12:28:52 -05:00
Marek Safar a734827992 [mcs] Assignment to value type readonly generated variables needs to check all member access expressions. Fixes #15832 2013-11-14 18:16:57 +01:00
Marek Safar 58d4cd39c7 [mcs] Missing type forwarded types should not cause type collision. Fixes #16196 2013-11-14 16:26:58 +01:00
Marek Safar c0567c50b8 [ilasm] Fixes forwarded types namespace encoding 2013-11-14 16:26:58 +01:00
Marek Safar 5659b9a9ea Merge pull request #808 from knocte/master
[System.Configuration/Test] Try to track down failure in buildbot
2013-11-14 04:41:06 -08:00
Andrés G. Aragoneses d4ed8a8e9e [System.Configuration/Test] Try to track down failure in buildbot
This TestConnectionStringRetrieval unit test (committed by me some months
ago) succeeds for me in a clean checkout, but I don't understand why it
fails in the buildbot, so let's place some sanity check in it.
2013-11-14 13:08:07 +01:00
Zoltan Varga 0927129c35 [jit] Fix the DISABLE_JIT build. 2013-11-14 04:50:13 +01:00
Sebastien Pouliot 8332e5db56 [linker] Do not import something that is not marked when sweeping type references (otherwise we might re-intoduce dependencies we're not including or need) [#16213] 2013-11-13 21:42:18 -05:00
Zoltan Varga 4fc5a4ce34 [llvm] Fix type mismatches in the implementation of the atomic opcodes. 2013-11-13 22:39:38 +01:00
Rodrigo Kumpera d51c9f1a4f [runtime]Don't expand variant generic interfaces on arrays.
We don't need to expand variant interfaces in 4.5 as they work
just fine.

This saves us from loading a lot of extra metadata and inflating
spurious classes.
2013-11-13 15:54:27 -05:00
Jonathan Pryor 73f1946128 [mdoc] Flush expected output.
Commit 0a2c38df changed Delegate.Remove() so that it uses
Locale.GetText(), which thus introduces additional exceptions which
can be possibly thrown from Delegate.Remove().

This is similar to the situation in corlib/3d3fe6af (added
Locale.GetText() use) and mdoc/574dbc8e (updated unit tests).
2013-11-13 15:25:28 -05:00
Marek Safar cd21aebc7a Always show error message when type resolver produces ambiguous type. Fixes #16115 2013-11-13 20:38:18 +01:00
Marek Safar 46ccd3b4a8 [mcs] tests update 2013-11-13 14:13:38 +01:00
Rolf Bjarne Kvinge dc1dc9ca74 Merge pull request #801 from Ninds/master
Setting ReceiveBufferSize & SendBufferSize on Socket (Bug 16021 & Bug 12754)
2013-11-13 00:51:37 -08:00
Marek Safar 7692600c86 Disable failing test 2013-11-13 09:46:56 +01:00
Marek Safar 5d20cad529 [sle] Enable char equality comparison. Fixes #15582 2013-11-12 20:45:13 +01:00
Rodrigo Kumpera aea002c504 Fix the build. 2013-11-12 14:18:31 -05:00
Marek Safar 1da5ac516c Update currency separators. Fixes #15425 2013-11-12 20:12:34 +01:00
Marek Safar ff631b91cc Extract CurrencyDecimalDigits using currency and not territory info. Fixes #15895 2013-11-12 20:12:34 +01:00
Marek Safar ebe4dd413e Add more tests 2013-11-12 20:12:33 +01:00
Rodrigo Kumpera 06ba83bfb7 [jit] Use unsigned comparisons with the IMT thunks as they can live in high memory addresses. 2013-11-12 14:01:26 -05:00
Rodrigo Kumpera ef3524b267 [jit] Improve arm IMT debugging. 2013-11-12 14:01:25 -05:00
Rodrigo Kumpera 0a2c38df5e [corlib] Improve the exception message in Delegate::Remove. 2013-11-12 14:01:25 -05:00
Sebastien Pouliot cff65d2ae5 [linker] Do not remove resources from mscorlib unless it's action is set to Link 2013-11-12 13:56:15 -05:00
Alexander Köplinger 6923ba9c02 Fixed a test failure that occurs when the specified font is not installed.
On systems where 'Liberation Sans' is not installed out-of-the-box
(e.g. Ubuntu Server, OpenSuse Server) it falls back to 'DejaVu Sans',
which makes the GetHashCode_NameDiffers_HashesNotEqual() test fail as
the two font names are now equal. Instead we use 'Arial' and 'Courier New'
which resolve to different fonts on most systems.

Changes licensed under MIT/X11.
2013-11-12 19:07:25 +01:00
AxlPr 2e579c47fb Fixed g_win32_getlocale
Implemented g_win32_getlocale function to return correct locale.
2013-11-12 09:31:11 +00:00
Marek Safar a2850fc7da Merge pull request #799 from kebby/master
Task.WhenAllCore<T> now handles empty argument list correctly. Fixes #15956
2013-11-12 00:38:48 -08:00
Marek Safar 507c434d1e Merge pull request #805 from supershitauto/master
2013-11-12 Ryan Williams <[email protected]>
2013-11-12 00:11:18 -08:00
supershitauto 82eaaec7db 2013-11-12 Ryan Williams <[email protected]>
Renamed member variables to be compatible with Microsoft for serialization.

Slight change to Equals method for consistency.
2013-11-12 16:13:39 +11:00
Zoltan Varga 31009c93ca [aot] Fix a typo causing crashes when using async jit info. 2013-11-11 19:22:06 +01:00
Marek Safar d5f0a573ce Merge pull request #804 from xplicit/attrfix
Fixed StackOverflow exception in Attribute.GetHashCode()
2013-11-11 06:22:35 -08:00
xplicit 850dd01678 fixed stackoverflow exception in Attribute.GetHashCode()
MS implementation of Attribute.GetHashCode does not depend on TypeId property, so you can return any value in TypeId and hashcode in MS.NET will be the same.
2013-11-11 20:44:59 +07:00
Narinder CLAIRE bbd4ee4181 Socket ReceiveBufferSize & SendBufferSize set to random values.
Fixes :

https://bugzilla.xamarin.com/show_bug.cgi?id=16021
https://bugzilla.xamarin.com/show_bug.cgi?id=12754

Resolves:

http://lists.ximian.com/pipermail/mono-list/2013-June/050008.html

A reference to the variable bufsize, local to the else-if block was being passed to the function setsockopt hence
the properties ReceiveBufferSize & SendBufferSize were being set to garbage on the Socket class. This could and did have a SERIOUS performance hit on socket communication. It is not inconceivable that people would try to increase the
buffer sizes and inadvertently shrink them considerably with a consequence of drastically degrade performance.

Narinder Claire
narinder.claire <> gmail.com

Signed-off-by: Narinder CLAIRE <[email protected]>
2013-11-11 10:48:56 +00:00
Zoltan Varga f0094a00b5 [aot] Remove -mattr=-avx flag to llc on amd64+osx, its no longer needed. 2013-11-11 08:56:07 +01:00
Zoltan Varga cc395b92a3 [aot] Clean up the linker invocation code a bit. 2013-11-11 08:37:27 +01:00
Zoltan Varga 3c4f1df5a7 [aot] Use temp.bc/temp.opt.bc instead of temp.s.bc/temp.s.opt.bc as llvm temporary file names. 2013-11-11 08:23:33 +01:00
Zoltan Varga 8b870df629 [llvm] Add the strip-dead-prototypes pass to remove unused intrinsics definitions from the .bc file. 2013-11-11 08:09:24 +01:00
Zoltan Varga 994466e0e6 [aot] Use clang as the assembler on osx. 2013-11-11 06:54:34 +01:00
Zoltan Varga 2eb34b1a69 [aot] Avoid emitting a 'methods' symbol using .set methods, clang's integrated assembler doesn't seem to support it. 2013-11-11 06:35:58 +01:00
Zoltan Varga 81f7293aac [llvm] Use i64*/i32* as the LLVM type of objrefs instead of i64/i32, the basicaa LLVM pass cannot see through the inttoptr casts we were emitting before loads. 2013-11-11 06:05:29 +01:00
Zoltan Varga 4e8e3cb466 [llvm] Update list of optimizations passed to 'opt'. 2013-11-11 05:37:08 +01:00
Zoltan Varga f9582d2945 [llvm] Rename the MONO_INST_CONSTANT_LOAD flag to MONO_INST_INVARIANT_LOAD for consistency with LLVM. 2013-11-11 02:37:06 +01:00
Miguel de Icaza 18b72517b8 Do not justify the text 2013-11-10 20:24:54 -05:00
Zoltan Varga cff88593e0 [llvm] Mark the load generated by OP_AOTCONST as invariant. 2013-11-11 02:01:18 +01:00
Zoltan Varga 3e14c8db3d [jit] Add a simple loop invariant loop motion pass for use with LLVM, which moves loop invariant instructions out of loop headers into the preceeding bblock. 2013-11-10 21:11:06 +01:00
Alistair Bush 5c3c64d368 TimeZone.GetUtcOffset should use Standard UTC offsets for the period when daylight savings ends. 2013-11-10 09:36:11 +00:00
Marek Safar 25a3e0e4b8 Merge pull request #803 from Wolpertinger/patch-1
System.CompomentModel.Component.cs: Make disposedEvent key static
2013-11-10 00:10:43 -08:00
Alex Willmy c749da6d02 System.CompomentModel.Component.cs: Make disposedEvent key static
There is no need for an instance of Component to create its own lookup key for the Disposed event. Use a shared static key instead.
2013-11-09 17:49:12 +01:00
Alex Rønne Petersen a571d29499 Improve my previous change a bit.
Checking the `disposing` argument is cleaner.
2013-11-09 02:52:20 +01:00
Alex Rønne Petersen 2d18195d17 Fix an NRE in System.Timers.Timer.Dispose ().
This would happen because _lock is nullified by the GC during
finalization. Dispose () calls Close () which sets the Enabled
property to false, which then attempts to lock on _lock.
2013-11-09 02:18:23 +01:00
Zoltan Varga 55e766632f [jit] Remove references to unused llvm.invariant.start/end intrinsics. 2013-11-08 23:52:29 +01:00
Zoltan Varga f8701513e9 [jit] Make ABCREM really remove bounds checks, not just when running with -v -v -v -v. 2013-11-08 18:27:01 +01:00
Rolf Bjarne Kvinge 009689da63 [Mono.Tuner] Make ISubStep.Initialize public virtual instead of private, so that consumers can override.
Previously derived classes could implement ISubStep.Initialize, but after
da82237da0 this (correctly) not allowed anymore.
2013-11-08 14:50:46 +01:00
Atsushi Eno d6225bca64 fix package build. 2013-11-08 17:09:53 +09:00
Atsushi Eno 8bccb2fb73 Merge pull request #800 from alistair/south_timezone_fix
Southern Hemisphere timezone fix
2013-11-07 21:02:24 -08:00
Zoltan Varga b68ef214e1 [jit] Remove a few LLVM_MONO_BRANCH defines, we don't support non-mono versions of LLVM any more. 2013-11-08 05:24:30 +01:00
Zoltan Varga 09a0c58b7a [jit] Fix sgen support in LLVM. Use the new LLVM 'invariant.load' metadata instead of our 'mono.noalias' metadata. 2013-11-08 05:12:41 +01:00
Zoltan Varga 623b9d0dcf [jit] Implement support for OP_TLS_GET on amd64+llvm. 2013-11-08 04:40:25 +01:00
Zoltan Varga 3cb85f36f5 [runtime] Remove some debug spew. 2013-11-08 02:44:19 +01:00
Zoltan Varga 21d5d266e9 [runtime] Only do the stack manipulation added by 79e0856ffd on linux, since it seems to crash on osx. 2013-11-08 02:40:06 +01:00
Sebastien Pouliot 8cf7650d3d [monolinker] Add additional preserve instruction for IReadOnlyCollection on System.Array 2013-11-07 14:42:46 -05:00
Zoltan Varga 79e0856ffd [runtime] Preserve the call chain in mono_arch_setup_async_callback () on amd64 to prevent crashes in the libgcc unwinder (#15969). 2013-11-07 04:56:57 +01:00
Tammo 'kb' Hinrichs a3bf4b4356 Added tests for Task.WhenAll w/ empty list 2013-11-06 15:55:32 +01:00
Tammo 'kb' Hinrichs 9fce6c603c Return empty result array when calling Task.WhenAllCore<T> with empty argument list. Fixes #15956 2013-11-06 13:21:47 +01:00
Sebastien Pouliot 613906e04b Further reduce the chance of an NRE in WebConnection, ref: 55f400b644 2013-11-05 16:52:19 -05:00
Leonardo Taglialegne 6c3e614cc5 Fix off-by-one error in ArraySegment 2013-11-05 20:49:21 +01:00
Zoltan Varga fe80190fc4 [runtime] Fix the osx mavericks stack size calculation in sgen too. 2013-11-05 20:18:14 +01:00
Zoltan Varga d6673ca8ec [runtime] Fix stack size detection on osx mavericks. Fixes #15890. 2013-11-05 19:53:22 +01:00
Sebastien Pouliot 33663b2db8 [linker] Allow accessing more MarkStep.Mark* methods from subclasses 2013-11-05 11:44:57 -05:00
Paolo Molaro cc7b7992ff Reduce contention and unnecessary checks at each lookup, part of xambug #14644. 2013-11-05 17:37:08 +01:00
Rodrigo Kumpera cf8c83129d [runtime]Split thread unregistration in two steps, one with no locks, one with locks taken. Fixes #15916.
In order allow for arbitrary code in the profiler callback we must invoke it without
holding any runtime leaf lock - this happens quite frequently with sdb as it tries to
suspend the world on those callbacks.

So thread shutdown is now split in two phases, first one that does the no-locks part
where the thread remains suspendable afterwards and then onewith locks taken where we
do the final cleanup and final shutdown.
2013-11-05 09:59:27 -05:00
Zoltan Varga 1832b006ba [runtime] Handle unaligned access in all interlocked icalls. Fixes #15925. 2013-11-05 15:44:24 +01:00
Zoltan Varga f2c5766230 [runtime] Fix warnings. 2013-11-05 15:44:24 +01:00
Rodrigo Kumpera c2dfadefc2 Fix the mobile_static build. 2013-11-04 17:02:43 -05:00
Rodrigo Kumpera 0261d6fcea [jit] Cleanup a bit how we handle small structs. 2013-11-04 15:48:01 -05:00
Rodrigo Kumpera 86add8950f [jit]Add amd64 support for the new compare instructions. 2013-11-04 15:36:58 -05:00
Rodrigo Kumpera b44597cb49 [jit]Add x86 support for the new compare instructions. 2013-11-04 15:36:54 -05:00
Rodrigo Kumpera f047afaccb [jit] Add some missing compare instructions which will make it easier to optimize inlined boolean expressions. 2013-11-04 15:36:50 -05:00
Rodrigo Kumpera 1ba345570f [build]Enable passing arguments to the extension module.
The build argument --enable-extension-module now takes a comma separated list
of arguments that are passed down. Passing no arguments triggers the old behavior.
2013-11-04 11:04:53 -05:00
Zoltan Varga 9eda1b444b [jit] Reduce the number of #ifdefs in the JIT code by a little. 2013-11-03 22:26:16 +01:00
Zoltan Varga cbb0c783e6 Fix corlib tests with hard coded line numbers. 2013-11-03 22:22:07 +01:00
Zoltan Varga c508278e9c [jit] Get rid of the intermediate OP_..CALLVIRT opcodes, use the _MEMBASE opcodes instead. 2013-11-03 21:54:57 +01:00
Zoltan Varga c574de067d [jit] Add support for generating the push/pop the LMF from the LMF stack as IR instead of hand-written assembly code in the backends. Not yet used. 2013-11-03 14:38:44 +01:00
Zoltan Varga abc18e4340 Mark some corlib tests with the LLVMNotWorking category. 2013-11-03 14:19:09 +01:00
Alistair Bush 813fe8057d Fix compile warning and break from for loop once complete 2013-11-03 22:29:15 +13:00
Alistair Bush 883a0e0e7d Attempt to implement GetTimeZoneData to support all hemispheres 2013-11-03 22:28:36 +13:00
Alistair Bush 23dfdd23d8 Add unit test for NZST 2013-11-03 21:56:38 +13:00
Zoltan Varga fc169c3839 [jit] Disable the optimization added by 63eb94e451 when using LLVM, the handler bblock has no in edges, which seems to cause problems when using LLVM. 2013-11-03 01:35:50 +01:00
Zoltan Varga 762d5fb72b [jit] Add a comment. 2013-11-02 23:53:47 +01:00
Zoltan Varga 45ce641f28 [jit] Remove OP_JMP implementation from the x86 backend, its not used there. 2013-11-02 23:45:08 +01:00
Zoltan Varga 90e0dbcc17 [jit] Clean up the tail call code a bit. 2013-11-02 22:14:18 +01:00
Zoltan Varga 56fa47629f [sdb] Implement support for DebuggerStepThrough attribute. Fixes #15139. 2013-11-02 20:42:59 +01:00
Marek Safar 54ecc9c6a1 Merge pull request #798 from akoeplinger/fix-test
Fixed an issue in corlib Makefile
2013-11-02 01:20:02 -07:00
Atsushi Eno 40d5064d04 hack SettingValueElement.Unmerge(). 2013-11-02 16:54:09 +09:00
Zoltan Varga 36cf982222 [jit] Fix fbd9fd7167, a wrong version was commited. 2013-11-02 03:26:33 +01:00
Rodrigo Kumpera 0cf6982962 [fullaot] Don't use the complicated generics-heavy cache under full-aot. 2013-11-01 17:51:16 -04:00
Jonathan Pryor 55f400b644 [System] Avoid an NRE when Close() and Write() are concurrent.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=15857

Scenario (for which I couldn't easily create a testcase, but can
sketch out): Imagine using HttpClient...in a multithreaded manner:

	// shared:
	static CancellationTokenSource _cancellationTokenSource = new CancellationTokenSource ();

	// Thread 1
	var request = new HttpRequestMessage(HttpMethod.Post, "https://www.google.com/") {
		Content = new StringContent (new string('x', 1024)),
	};
	using (request)
	using (HttpClient httpClient = new HttpClient())
	using (HttpResponseMessage response = await httpClient.SendAsync(request,
			_cancellationTokenSource.Token)) {
		string responseContent = await response.Content.ReadAsStringAsync();
		Console.WriteLine ("Read {0} chars", responseContent.Length);
	}

	// Thread 2
	_cancellationTokenSource.Cancel ();

This isn't entirely farfetched; in the case of #15857, Thread 2 was
the Main thread (due to the user clicking a button), while Thread 1
was the ThreadPool (because of async/await).

The _occasional_ result: a TargetInvocationException exception:

	System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object
	  at (wrapper delegate-invoke) <Module>:invoke_bool__this___HttpsClientStream (Mono.Security.Protocol.Tls.HttpsClientStream)
	  at System.Reflection.MonoProperty.GetterAdapterFrame[HttpsClientStream,Boolean] (System.Reflection.Getter`2 getter, System.Object obj)
	  at System.Reflection.MonoProperty.GetValue (System.Object obj, System.Object[] index)
	  --- End of inner exception stack trace ---
	  at System.Reflection.MonoProperty.GetValue (System.Object obj, System.Object[] index)
	  at System.Net.WebConnection.Write (System.Net.HttpWebRequest request, System.Byte[] buffer, Int32 offset, Int32 size, System.String& err_msg)
	  at System.Net.WebConnectionStream.WriteHeaders ()
	  at System.Net.WebConnectionStream.SetHeaders (System.Byte[] buffer)
	  at System.Net.HttpWebRequest.SendRequestHeaders (Boolean propagate_error)
	--- End of stack trace from previous location where exception was thrown ---
	  at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw ()
	  at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1+ConfiguredTaskAwaiter[System.Net.Http.HttpResponseMessage].GetResult ()
	  at System.Net.Http.HttpClient+<SendAsyncWorker>c__async0.MoveNext ()
	--- End of stack trace from previous location where exception was thrown ---
	  at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw ()
	  at System.Runtime.CompilerServices.TaskAwaiter`1[System.Net.Http.HttpResponseMessage].GetResult ()
	  at HttpClientAsyncCancellationRepro.Activity1+<AccessGoogleButton_Click>c__async0.MoveNext ()

Huh?

The reason why is because HttpClientHandler.SendAsync() registers a
Cancel handler with the CancellationTokenSource, and the registered
handler calls HttpWebRequest.Abort() (which eventually calls
WebConnection.Close()). This causes WebConnection.nstream to _change_
while WebConnection.Write() is executing, causing
WebConnection.nstream to go from non-null to null, which
WebConnection.Write() does not expect:

	# WebConnection.CreateStream; from 5 Threadpool worker
	# WebConnection.Write; from 5 Threadpool worker
	# WebConnection.Close; from 1  at    at System.Environment.get_StackTrace()
	   at System.Net.WebConnection.Close(Boolean sendNext)
	   at System.Net.WebConnection.Abort(System.Object sender, System.EventArgs args)
	   at System.Net.WebConnection+AbortHelper.Abort(System.Object sender, System.EventArgs args)
	   at System.Net.HttpWebRequest.Abort()
	   at System.Net.Http.HttpClientHandler+<SendAsync>c__async0.<>m__0(System.Object l)
	   at System.Threading.CancellationToken+<Register>c__AnonStorey0.<>m__0()
	   at System.Threading.CancellationTokenSource.Cancel(Boolean throwOnFirstException)
	   at System.Threading.CancellationTokenSource.Cancel()
	   at System.Threading.CancellationTokenSource.SafeLinkedCancel()
	   at System.Threading.CancellationTokenSource.Cancel(Boolean throwOnFirstException)
	   at System.Threading.CancellationTokenSource.Cancel()
	   at HttpClientAsyncCancellationRepro.Activity1.CancelButton_Click(System.Object sender, System.EventArgs e)
	   at Android.Views.View+IOnClickListenerImplementor.OnClick(Android.Views.View v)
	   at Android.Views.View+IOnClickListenerInvoker.n_OnClick_Landroid_view_View_(IntPtr jnienv, IntPtr native__this, IntPtr native_v)
	   at System.Object.e7b5b870-ea0f-434f-bc31-984f665a44ad(IntPtr , IntPtr , IntPtr )
	# WebConnection.Write: checking piTrustFailure; from 5 Threadpool worker

(Yay extra logging. Notice that WebConnection creates a stream from
the ThreadPool, starts WebConnection.Write(), then before it can se
piTrustFailure the instance is Close()d, which nulls out nstream.)

Since WebConnection.Write() attempts to access the (now null)
WebConnection.nstream field, it results in a NullReferenceException,
which is wrapped into a TargetInvocationException by
System.Reflection.

The fix? As usual, "don't do that."

In this case, WebConnection.Write() has already captured
WebConnection.nstream into the local variable `s` (which thus can't be
changed by another thread). Instead of using WebConnection.nstream,
reuse the `s` local variable, which cannot be null, thus avoiding the
NullReferenceException.

(This solution could fail if HttpsClientStream ever throws e.g.
ObjectDisposedException from HttpsClientStream.TrustFailure, but at
present HttpsClientStream.TrustFailure never throws, so this is fine.)
2013-11-01 16:56:53 -04:00
Miguel de Icaza 06693aa3bb Comment style 2013-11-01 16:49:35 -04:00
Rodrigo Kumpera 63eb94e451 [jit] Avoid linking the try block with the EH block as this produces spurious BBs during inlining.
The inliner could not handle optimally when we inline code inside the try block as it would be linked
with the catch block.

Since the source block would have more than one exit, the inliner would conservatively not link them together,
which hinders further local optimizations.
2013-11-01 15:27:12 -04:00
Alexander Köplinger 9550e4ce08 Fixed an issue in corlib Makefile that would make a resource test case fail which relies on satellite assemblies.
The satellite assembly generated by the Makefile was suffixed with '.Resources.dll', but the assembly loader looks for '.resources.dll', thus the satellite assembly wasn't found.
2013-11-01 20:08:06 +01:00
Rodrigo Kumpera 11b2e3e60f [jit]Extract emit_init_local and use it with the ldloca optimization to handle any kind of types. 2013-11-01 15:05:55 -04:00
Zoltan Varga 53c777d22b [jit] Fix a gsharedvt crash on x86. 2013-11-01 18:12:50 +01:00
Zoltan Varga f3b4e40281 Revert "[sgen] Use mono_class_has_parent () instead of mono_class_has_parent_fast () in one place."
This reverts commit 2594b36363.

Revert this as its wrong.
2013-11-01 17:16:18 +01:00
Zoltan Varga 2fc3754d21 Fix warnings. 2013-11-01 16:20:09 +01:00
Zoltan Varga 2594b36363 [sgen] Use mono_class_has_parent () instead of mono_class_has_parent_fast () in one place. 2013-11-01 11:19:38 -04:00
Zoltan Varga 7f61dee23f [jit] Implement support for OP_TLS_GET_REG on amd64 linux. 2013-11-01 11:19:38 -04:00
Rodrigo Kumpera be58704339 Fix the linker script for OSX. libtool screwed up the first attempt. 2013-11-01 10:56:55 -04:00
Zoltan Varga 19be2cd66a Merge pull request #797 from ranma42/fix-log-message
[runtime] Fix AOT log message
2013-11-01 06:47:40 -07:00
Zoltan Varga daccd00b00 Fix the amd64 build. Fix a warning. 2013-11-01 14:40:54 +01:00
Zoltan Varga e4a37a7663 [sdb] Fix an assertion if a single step breakpoint is hit in a thread other than the thread the single stepping is done on. Fixes #14950. 2013-11-01 14:16:15 +01:00
Zoltan Varga fbd9fd7167 [jit] Fix the processing of LLVM compiled method frames on x86. Fixes running corlib tests with LLVM. 2013-11-01 13:14:48 +01:00
Zoltan Varga 644359eb5d [sdb] Fix tests. 2013-11-01 13:14:47 +01:00
Andrea Canciani 1bcb295fed [runtime] Fix AOT log message
In 72ca429d6c the message format was
refactored and an additional '%s' format specifier was left over.
2013-11-01 11:38:51 +01:00
Alex Rønne Petersen 7ab1185624 Fix indentation.
Oddly, we don't use tabs here...
2013-11-01 09:53:38 +01:00
Rodrigo Kumpera 382210f927 [jit] Pair of fixes from last merge. 2013-10-31 19:44:40 -04:00
Rodrigo Kumpera 98d59927c6 [jit] The AggressiveInlining hint now triggers class initialization so more stuff gets force-inlined. 2013-10-31 19:34:04 -04:00
Rodrigo Kumpera a85d5e0285 [jit] Clean up emit_init_rvar and reduce code duplication. 2013-10-31 19:30:09 -04:00
Rodrigo Kumpera d994c2ea19 [jit] Clean up usage of signature variables. 2013-10-31 18:41:18 -04:00
Rodrigo Kumpera 363b1864e8 [jit]Add an alias analysis pass to the JIT.
The alias analysis pass is capable of simplifying indirection against
local or temporary variables. It will replace a memory load or store
with direct access to the variable.

It does a local pass looking for addresses and replacing memory
ops with direct ops.

If any conversion happens, it does a DCE pass to try to kill those
LDADDR and then recalculate the indirect flag.

Finally, if the number of indirect variables is reduced, it does a
global to local vreg pass and another DCE pass to kill most spurious
copying.

Performance numbers on 32bits OSX:

Code size:
mcs: -11.366 (0.6%)
corlib: -15.397 (0.6%)

Execution time increased by less than 0.2% which is about the same
value of the test variance.

Numbers are not impressive since we don't perform store forwarding
or constant load elimination. Proper handling of value type aggregates
and longs would move us much further.
2013-10-31 17:37:13 -04:00
Rodrigo Kumpera 33e4ab9bde [jit] Add counters for alias analysis. 2013-10-31 17:37:07 -04:00
Rodrigo Kumpera 8c92a0da08 [jit] Introduce has_indirection flag in MonoCompile to signal that LDADDR was generated.
To reduce the cost of alias analysis we detect which methods can potentially profit from
the optimization.

The current detection logic is very simple, every time LDADDR is generated, we set
has_indirection to TRUE.
2013-10-31 17:37:06 -04:00
Rodrigo Kumpera cdd96589ad [jit]Replace all usages of MONO_INST_INDIRECT to force regalloc with MONO_INST_VOLATILE.
The indirect flag should only be used to signal that the address of the given variable
has been taken. This means that it should be possible to recompute that flag from the IR.

The usage of the volatile flag remains not ideal as it conflates two separate issues
and will in the future hinder efforts to implement address based alias analysis.
2013-10-31 17:37:06 -04:00
Rodrigo Kumpera e30fed93a6 [jit] Add new optimization flag for alias analysis. 2013-10-31 17:37:06 -04:00
Jeffrey Stedfast bbd3769cde [Mono.Debugger.Soft] Test the inherited Type attributes 2013-10-31 15:58:04 -04:00
Jeffrey Stedfast b79cd5abd3 [Mono.Debugger.Soft] Fixed unit test for getting custom type attributes 2013-10-31 15:02:42 -04:00
Rodrigo Kumpera d57d8ccd12 Revert "Implementation of Properties and Methods in MethodSignatureGenerator.cs"
This reverts commit 46cd052a3a.

This breaks the build.
2013-10-31 14:59:19 -04:00
Zoltan Varga 4e9f9fcf6e [runtime] Fix the ARM build. 2013-10-31 18:05:24 +01:00
Martin Baulig edbc59e9db [linker]: Fix my previous commit.
We need to resolve all the TypeReferences before we update their scopes.
After setting the scope to null, calling Resolve() on a nested child would
crash.
2013-10-31 10:34:20 -04:00
Marek Safar 96a201f7fe Merge pull request #794 from aakashapoorv/patch-1
Implementation of Properties and Methods in MethodSignatureGenerator.cs
2013-10-30 23:58:27 -07:00
aakashapoorv 46cd052a3a Implementation of Properties and Methods in MethodSignatureGenerator.cs
Implemented following properties:-

CodeProvider 
ContainerParameterType
DataSetClassName
IsGetMethod 
PagingMethod 
ParameterGenerationOption
ParameterOption 
TableClassName

and following methods:-

GenerateMethod
GenerateMethodSignature 
GenerateUpdatingMethods
SetDesignTableContent
SetMethodSourceContent
2013-10-31 11:00:22 +08:00
Zoltan Varga 724f6285a3 Dist README.md. 2013-10-31 02:31:41 +01:00
Zoltan Varga 72ca429d6c [runtime] Make an AOT log message smaller. 2013-10-31 02:31:41 +01:00
Jeffrey Stedfast e7db8e896a [Mono.Debugger.Soft] Implemented inheritance for TypeMirror.GetCustomAttributes()
Fixes bug #15320
2013-10-30 15:36:24 -04:00
Miguel de Icaza 599a21d6ae Merge pull request #795 from mono/readme2
[README] Minor update to content and use markdown formatting.
2013-10-30 11:45:21 -07:00
Therzok da6191eaeb [README] Minor update to content and use markdown formatting. 2013-10-30 20:42:27 +02:00
Miguel de Icaza 93468652f7 Rename README to README.md 2013-10-30 14:36:34 -04:00
Neale Ferguson 0c07e4a0b8 Add mono_arch_get_nullified_class_init_trampoline 2013-10-30 14:35:36 -04:00
Zoltan Varga 212e36fc3a Fix MONO_PATH for run-test-vts in corlib. 2013-10-30 14:31:00 +01:00
Zoltan Varga cbacd4801f [runtime] Fix a warning. 2013-10-30 13:04:05 +01:00
Zoltan Varga 992e3d6ace [runtime] Fix an assertion in mono_arch_context_get_int_reg () on amd64. Fixes #15786. 2013-10-30 13:03:47 +01:00
Zoltan Varga d8e44958d4 Dist the subdirs of class/Facades. 2013-10-30 11:31:26 +01:00
Rodrigo Kumpera 75165860c4 Fix skip_scan to handle proper load errors. 2013-10-29 15:25:20 -04:00
Marek Safar 01abc8bb07 Fixes build 2013-10-29 20:07:07 +01:00
Marek Safar ef722ff122 When parsing documentation cref text turn on error probing for tokenizer as well. Fixes #15511 2013-10-29 19:04:27 +01:00
Zoltan Varga 93c6b94bb0 [aot] Small AOT changes. Save some constants into the AOT image instead of duplicating them in aot-runtime.c. Emit some padding so multiple symbols do not point to the same address. 2013-10-29 17:23:33 +01:00
Zoltan Varga 4c1198f3b8 [runtime] Add mno-signal-handler.h to dist. 2013-10-29 17:05:26 +01:00
Marek Safar da82237da0 Better error message when member does not implement interface. Fixes #15369 2013-10-29 15:04:44 +01:00
Marek Safar dd1826124a Variables from diffent parameter block still need to be captures even if async block has no await. Fixes #15719 2013-10-29 11:51:39 +01:00
Sebastien Pouliot 5b56dc2ce2 The stripper does not care if some variables can't be referenced (they'll be removed) and new cecil has a similar fix [#15727] 2013-10-28 09:56:11 -04:00
Marek Safar 9209bf5634 Better error message when type inference resolves valid types but parameter types still don't match 2013-10-28 13:08:58 +01:00
Marek Safar b5bc9d75d5 Update lower/upper type inference fixing to match the latest C# standard. Fixes #15505 2013-10-27 21:37:34 +01:00
Marek Safar ee09ac3bcf Enum subtraction quirk needs to work with numeric constants only. Fixes #15520 2013-10-27 08:40:51 +01:00
Alex Rønne Petersen 0a17e9070d Silence some noisy warnings in mono/tests/. 2013-10-27 01:23:41 +02:00
Alex Rønne Petersen 05f4546a96 Add a .gitignore file to support/minizip/ to ignore *.la *.lo files. 2013-10-27 01:15:45 +02:00
Alex Rønne Petersen 6c3edfc5eb Ignore .dirstamp files. 2013-10-27 01:15:00 +02:00
Alex Rønne Petersen b37ba14801 Don't assert in Interlocked.Add () icalls on 64-bit systems.
The checks here were wrong in the first place; they should have
checked for MONO_ARCH_HAVE_ATOMIC_ADD rather than SIZEOF_VOID_P.
But regardless, these methods need to work when invoked via
reflection, which they wouldn't previously.
2013-10-27 00:52:09 +02:00
Alex Rønne Petersen 4b6494f0c6 Define WIN32_LEAN_AND_MEAN before including windows.h. 2013-10-26 21:39:39 +02:00
Marek Safar e00cbf2c42 Merge pull request #790 from akoeplinger/fixtests
Fixed a test issue where net45 methods were used in net40 profile
2013-10-26 00:11:19 -07:00
Alex Rønne Petersen d7e3f8f1bb Remove dead s390(x) code from mono-membar.h. 2013-10-26 05:08:19 +02:00
Alex Rønne Petersen 00bdbda27f Enable GCC atomics on sparc32/64. 2013-10-26 05:08:16 +02:00
Alex Rønne Petersen 481abfa4f3 Correct VFP detection in mono-hwcap-arm.
This is supposed to be the value 64, not 100.
2013-10-25 23:31:54 +02:00
Rodrigo Kumpera 6a2975513a [runtime]Add a wrapper around signal handlers to ease porting work. 2013-10-25 15:49:10 -04:00
Alexander Köplinger 40eaa78a8d Fixed a test issue where net45 methods were used in net40 profile 2013-10-25 19:52:36 +02:00
Alex Rønne Petersen c4a9aa1f8c Add LLDB support to mono_gdb_render_native_backtraces () on POSIX. 2013-10-25 18:20:44 +02:00
Rodrigo Kumpera 12cdbfceb7 [runtime] Improve the docs on reference queues a bit. 2013-10-25 11:41:08 -04:00
Rodrigo Kumpera 248c37dfa9 [runtime] Promote the reference queue API to the public. 2013-10-25 11:40:51 -04:00
Martin Baulig c8b403250f [linker]: Also reference all type-references for LinkAction.Link and Save. 2013-10-25 15:15:46 +02:00
Marek Safar 707d914007 Tests update 2013-10-25 12:25:49 +02:00
Marek Safar fcad876ef1 When looking for base implementation of generic MVAR methods use non-inflated parameter types. Fixes #15523 2013-10-25 11:59:53 +02:00
Marek Safar f4aa1c4149 Add new tests 2013-10-25 10:42:57 +02:00
Zoltan Varga 913a2d5fbd [runtime] Fix the windows build. 2013-10-24 22:47:45 +02:00
Zoltan Varga 6a9c585384 [runtime] Fix the sparc build. 2013-10-24 19:37:11 +02:00
Alex Rønne Petersen 0ab2677994 Prefix internal variables with mono_. 2013-10-24 17:28:51 +02:00
Rolf Bjarne Kvinge 8ff7f5748c Add OrderedDictionary to the mobile profile.
Requested in support case #49635.
2013-10-24 16:07:53 +02:00
Rolf Bjarne Kvinge 64c326af71 Move mono_get_optimizations_for_method to mini.c, since driver.c is only included in binaries, not libraries. 2013-10-24 16:07:43 +02:00
Zoltan Varga bc4e870d2b Add a --with-llvm=<llvm prefix> argument to configure to make the location of llvm-config explicit, instead of reading it from the PATH, which might be different on a reconfigure. 2013-10-24 01:58:34 +02:00
Rodrigo Kumpera 90690f5036 [runtime]Properly calculate the bitmap of valuetype [ThreadStatic] variables.
We must account that a valuetype field offset is relative to a boxed instance
and TLS memory stores a valuetype unboxed.
2013-10-23 18:09:40 -04:00
Alex Rønne Petersen 04a90dcbb0 Fix mono_gc_wbarrier_generic_store_atomic semantics.
It should ensure that stores are fully atomic with barriers.
2013-10-24 00:06:23 +02:00
Alex Rønne Petersen 3f6b4e4fea Fix the semantics for System.Threading.Volatile methods.
This is a bit tricky. The System.Threading.Thread.Volatile* methods
don't actually guarantee atomicity; all they guarantee is that the
runtime will insert acquire barriers for loads and release barriers
for stores. The methods in the System.Threading.Volatile class,
however, require both barriers *and* atomicity.

So, we need an entirely separate set of icalls for the Volatile
class in order to get the right semantics there.

These APIs are insane.
2013-10-24 00:06:23 +02:00
Alex Rønne Petersen 41d1358f09 Add Interlocked{Read,Write}{8,16,Pointer} functions. 2013-10-24 00:06:23 +02:00
Alex Rønne Petersen 9bcda222de Merge pull request #787 from directhex/master
Don't redeclare desc in mini_create_ftnptr on ppc64
2013-10-23 15:01:46 -07:00
Jo Shields 1a1c17d59c Don't redeclare desc in mini_create_ftnptr on ppc64 2013-10-23 22:58:41 +01:00
Sebastien Pouliot c0cbbb15d9 Merge pull request #786 from xplicit/master
fix DivideByZeroException in Random.Next()
2013-10-23 14:42:48 -07:00
Rolf Bjarne Kvinge caff055609 Provide more public API to inspect MonoTypes, MonoClasses and MonoMethodSignatures. 2013-10-23 23:25:46 +02:00
xplicit edbcf074ce fix DivideByZeroException in Random.Next() 2013-10-24 04:09:30 +07:00
Zoltan Varga 0943037e68 [runtime] Fix a warning. 2013-10-23 21:18:45 +02:00
Zoltan Varga c6994ed5fd [runtime] Fix the windows build. 2013-10-23 21:18:36 +02:00
Alex Rønne Petersen bc55637bd1 Add more missing atomic functions for MinGW. 2013-10-23 19:47:19 +02:00
Alex Rønne Petersen 93edc5e860 Add separate icall for System.Threading.VolatileRead (object&).
Previously, the icall that was used for the IntPtr overload was
used for this overload as well. Having a separate icall is less
error-prone for future modification as the two types are no longer
conflated.
2013-10-23 19:47:19 +02:00
Zoltan Varga 50d4232bbe [runtime] Fix the DISABLE_JIT build on ARM. 2013-10-23 17:46:18 +02:00
Alex Rønne Petersen 80f7e1f15b Add InterlockedExchange64 () based on GCC intrinsics for MinGW.
As with InterlockedCompareExchange64, MinGW appears to lack this
one from its Windows headers.
2013-10-23 15:06:09 +02:00
Sebastien Pouliot f9bbb7c58b Disable ClientWebSocketTest.cs (for mobile) until the type itself is added to the mobile profile (i.e. added to mobile_System.dll.sources). Fix building/running System.dll unit tests 2013-10-23 08:22:25 -04:00
Marek Safar ab93080478 Merge pull request #784 from alesliehughes/master
Support for ManagementQuery and ObjectQuery classes
2013-10-23 00:17:22 -07:00
Alistair Leslie-Hughes b1d551265a Implement ObjectQuery 2013-10-23 08:13:34 +11:00
Alistair Leslie-Hughes 13d44dbcbe Implement ManagementQuery QueryString 2013-10-23 08:13:33 +11:00
Alistair Leslie-Hughes 596921b77d Implement ManagementQuery QueryLanguage 2013-10-23 08:13:32 +11:00
Alex Rønne Petersen 3be7b103d8 Use THREAD_INFO_TYPE consistently in mono-threads.h. 2013-10-22 23:09:14 +02:00
Zoltan Varga ea4d594639 [runtime] Add a missing TLS key for LMF addr. 2013-10-22 19:44:02 +02:00
Rodrigo Kumpera 3153dec190 Fix this test to work on 2.0. 2013-10-22 13:12:05 -04:00
Zoltan Varga 6be13313df [runtime] Fix the interlocked increment/decrement/add functions. 2013-10-22 15:11:44 +02:00
Zoltan Varga 0d40321933 [runtime] Centralize the processing of MonoTrampInfo structures into the mono_tramp_info_register () function, to reduce code duplication. 2013-10-22 14:35:46 +02:00
Zoltan Varga d48b2f6a29 [runtime] Use mono_restore_context () to reduce code duplication in the back ends. 2013-10-22 14:12:38 +02:00
Zoltan Varga 9be988fc33 [runtime] Use mini_exception_id_by_name () on ARM. 2013-10-22 14:05:43 +02:00
Zoltan Varga 3ee03145ff [runtime] Use mini_get_nullified_class_init_trampoline () to reduce code duplication in the back ends. 2013-10-22 14:04:50 +02:00
Zoltan Varga f62ffb9b89 [runtime] Add a mini_get_nullified_class_init_trampoline () helper function. 2013-10-22 07:33:41 -04:00
Zoltan Varga e6f000945f [runtime] Fix gsharedvt support in mono_helper_compile_generic_method (). 2013-10-22 07:32:27 -04:00
Zoltan Varga 3b5d644f27 [runtime] Add a mono_restore_context () helper function. 2013-10-22 07:28:56 -04:00
Zoltan Varga 7226a70c87 [runtime] Avoid crashing in mini_jit_info_table_find () if the current thread is not set. 2013-10-22 07:27:35 -04:00
Zoltan Varga dde6bb81f5 [jit] Add a mini_exception_id_by_name () helper function. 2013-10-22 07:26:01 -04:00
Zoltan Varga 7994b74bc4 [jit] Add a MONO_TRAMPOLINE_TYPE_HAS_ARG macro which determines whenever a given trampoline type receives its argument directly in a register. 2013-10-22 07:22:59 -04:00
Zoltan Varga 71a7f55907 [jit] Add a 'relocation' field to MonoJumpInfo which contains an architecture specific relocation constant so mono_arm_patch_code () doesn't have to decompile the patch site to determine the type of patching to do. 2013-10-22 07:21:37 -04:00
Zoltan Varga 60c5ef5e2b [jit] Add a 'call_info' field to MonoCallInst so the OP_CALL_... opcodes have access to the calling convention information computed in mono_arch_emit_call (). 2013-10-22 07:18:28 -04:00
Zoltan Varga 16d53c2dd7 runtime] Print unwind information in the JIT debug output. 2013-10-22 07:16:02 -04:00
Zoltan Varga e833cd7669 [jit] Add a MONO_ARCH_EMULATE_LONG_MUL_OVF_OPTS define for architectures which have mul but not mul.ovf opcodes. 2013-10-22 07:14:39 -04:00
Zoltan Varga 5557499b1a [runtime] Make --regression work when a domain is not yet setup during porting. 2013-10-22 06:51:14 -04:00
Zoltan Varga 47fcf8de8c [sdb] Fix support of vtypes passed by ref. 2013-10-22 06:48:47 -04:00
Zoltan Varga e6fcd7e886 [runtime] Avoid running tests using AC_TRY_RUN () when cross-compiling. 2013-10-22 06:45:43 -04:00
Zoltan Varga fb4dd485c9 [runtime] Use a cache in mono_create_rgctx_lazy_fetch_trampoline () in the full-aot case as well. 2013-10-22 06:42:37 -04:00
Zoltan Varga 4e6c494b30 [sdb] Add an IncludeSubclasses property to ExceptionEventRequest, to control whenever to include subclasses of the exception type. Fixes #15541 2013-10-22 08:38:07 +02:00
Sebastien Pouliot 64eff753bd Merge pull request #730 from LogosBible/locale-changes
Improving the retrieval of the user's locale on Apple systems.
2013-10-21 14:19:26 -07:00
Sebastien Pouliot ba6de2d5cc Fix condition (for MOBILE) that excluded System.Xml.Schema/Extensions.cs. Removed the condition since every profile we now support includes this [#15552] 2013-10-21 17:15:53 -04:00
Jeffrey Stedfast e028273cff Fixed a some compiler warnings 2013-10-21 17:15:02 -04:00
Alex Rønne Petersen c17e2527d1 Add comment explaining the TARGET_OSX oddity in atomic.c. 2013-10-21 23:10:44 +02:00
Alex Rønne Petersen e6b5336bb9 Add a couple of casts to scan_thread_data () to shut GCC up.
This would result in the following warnings on e.g. PowerPC:

sgen-gc.c: In function 'scan_thread_data':
sgen-gc.c:4045:6: warning: passing argument 1 of 'conservatively_pin_objects_from' from incompatible pointer type [enabled by default]
sgen-gc.c:1467:1: note: expected 'void **' but argument is of type 'void * (*)[32]'
sgen-gc.c:4045:6: warning: passing argument 2 of 'conservatively_pin_objects_from' from incompatible pointer type [enabled by default]
sgen-gc.c:1467:1: note: expected 'void **' but argument is of type 'void * (*)[32]'
2013-10-21 23:10:15 +02:00
Rodrigo Kumpera cd474dc552 Bump mono to 3.2.5 2013-10-21 15:25:46 -04:00
Rodrigo Kumpera 0a4a52cb96 [mkbundle] New mkbundle options for better handling integration with native libs.
New --skip-scan flag allow us to handle resource assemblies as opaque data.
New --static-ctor flag allows us to better interop with weird C libraries requirements.
2013-10-21 15:22:47 -04:00
Miguel de Icaza 2a4a459021 Merge pull request #717 from mono/client_websockets_impl
Add implementation of ClientWebSocket
2013-10-21 11:28:04 -07:00
Alex Rønne Petersen 0b3c3126ea Merge pull request #268 from pcc/menudeactivate
Cause MenuDeactivate event to be delivered when appropriate
2013-10-21 11:21:06 -07:00
Alex Rønne Petersen e946a6cdeb Merge pull request #260 from pcc/topmost
X11: improve handling of WS_EX_TOPMOST
2013-10-21 11:19:47 -07:00
Michael Hutchinson b86af48486 Merge pull request #565 from rneatherway/master
This is a possible fix for finding xml documentation files
2013-10-21 11:09:23 -07:00
Alex Rønne Petersen 457a8453f7 Merge pull request #587 from madewokherd/gdipdllmap
Ignore the gdiplus dllmap on Windows.
2013-10-21 10:00:26 -07:00
Alex Rønne Petersen 67d6c8f685 Remove commented-out irix path from configure.in. 2013-10-21 18:17:10 +02:00
Alex Rønne Petersen e4d2cc49a0 Add mono_gc_wbarrier_generic_store_atomic () function.
This is used in place of mono_gc_wbarrier_generic_store () when
we need the store to be atomic with release semantics.
2013-10-21 18:08:16 +02:00
Alex Rønne Petersen 55d338134d Add an extension point in atomic.c. 2013-10-21 18:08:15 +02:00
Alex Rønne Petersen 1b9ca03c22 Use slow 64-bit cmpxchg for 32-bit ARM, MIPS, and PowerPC.
GCC doesn't provide a 64-bit __sync_val_compare_and_swap intrinsic
for these architectures.
2013-10-21 18:08:05 +02:00
Alex Rønne Petersen 53398c4641 Correct our implementation of Thread.VolatileRead ()/VolatileWrite ().
We have various issues:

* All of the functions assumed that doing volatile loads/stores was
  enough, when load-acquire, store-release semantics were actually
  needed. This may have worked before purely by chance. We now use
  proper memory barriers so that we don't have to hope for the
  compiler and CPU to do the right thing.
* Removes the hack for 64-bit quantities on 32-bit systems. This is
  no longer needed now that we use explicit memory barriers in
  these functions. Also, these functions are not supposed to do
  atomic reads/writes in the first place - they're purely about the
  memory barrier semantics.
* The VolatileWrite (object&, object) overload was not using the
  volatile qualifier at all, thus not getting volatile semantics
  as per: http://gcc.gnu.org/onlinedocs/gcc/Volatiles.html
2013-10-21 17:59:30 +02:00
Alex Rønne Petersen 421e1beea5 Use InterlockedAdd64 () for Interlocked.Add (long&, long). 2013-10-21 17:59:29 +02:00
Alex Rønne Petersen 89a99c2634 Use InterlockedAdd () for Interlocked.Add (int&, int). 2013-10-21 17:59:29 +02:00
Alex Rønne Petersen d785b33891 Use InterlockedExchange64 () for Interlocked.Exchange (double&, double). 2013-10-21 17:59:28 +02:00
Alex Rønne Petersen b9db6c2071 Use InterlockedExchange64 () for Interlocked.Exchange (long&, long). 2013-10-21 17:59:28 +02:00
Alex Rønne Petersen 15f9be5d03 Use InterlockedDecrement64 () for Interlocked.Decrement (long&). 2013-10-21 17:59:28 +02:00
Alex Rønne Petersen bb62cced7e Use InterlockedIncrement64 () for Interlocked.Increment (long&). 2013-10-21 17:59:27 +02:00
Alex Rønne Petersen ab90040305 Use InterlockedRead64 () for Interlocked.Read (long&). 2013-10-21 17:59:27 +02:00
Alex Rønne Petersen e02b11b708 Use __sync_sub_and_fetch () for atomic decrements for clarity. 2013-10-21 17:59:26 +02:00
Alex Rønne Petersen e48f61dc84 Move definition of NEED_64BIT_CMPXCHG_FALLBACK to top of atomic.c. 2013-10-21 17:59:26 +02:00
Alex Rønne Petersen a92cfede81 Add interlocked read/write functions to atomic.c/.h.
These are guaranteed to have sequential consistency regardless
of the bitness of the machine they run on.
2013-10-21 17:59:25 +02:00
Alex Rønne Petersen ec96b2dc22 Add implementations of various interlocked functions to atomic.c/.h.
Mainly 64-bit variants, but also InterlockedAdd ().
2013-10-21 17:59:21 +02:00
Alex Rønne Petersen e601897f3f Use mono_memory_barrier () for Thread.MemoryBarrier ().
This gets rid of the rather hacky lock-based barrier.
2013-10-21 15:57:25 +02:00
Alex Rønne Petersen 7fae16348a Kill the Cygwin hack in mono-membar.h.
We only support GCC 4.x in Cygwin now.
2013-10-21 15:57:25 +02:00
Alex Rønne Petersen 6d2008b013 Remove MONO_ARCH_SAVE_REGS from threading icalls. 2013-10-21 15:57:25 +02:00
Alex Rønne Petersen a3632c6274 Use GCC atomics on s390x. 2013-10-21 15:57:25 +02:00
Alex Rønne Petersen bf0b8a1d1a Remove unneeded ARM code from atomic.c. 2013-10-21 15:57:24 +02:00
Alex Rønne Petersen a33ce0c39f Use host preprocessor identifiers in atomic.c, not target.
Here we care about the system we run on, not the kind of
system that Mono is built to compile for.
2013-10-21 15:57:24 +02:00
Alex Rønne Petersen fd6f60245f Simplify the ifdeffery in atomic.c/.h a bit. 2013-10-21 15:57:24 +02:00
Alex Rønne Petersen 9dd59c1f13 Remove unneeded NetBSD code path from atomic.h. 2013-10-21 15:57:24 +02:00
Marek Safar 17d4130d1b Merge pull request #783 from alistair/timezoneinfo_fix_for__convert_utc_to_local
Bug 15373: Return Local DateTime instead of Unspecified for >net_4_0
2013-10-19 08:34:26 -07:00
Alistair Bush 98f1c8c584 Return Local DateTime instead of Unspecified for >net_4_0 2013-10-19 23:41:17 +13:00
Mark Probst a57f9ce8a0 [runtime] JIT debugging option to optimize only single methods.
The --single-method option run regression tests from an assembly, like
--regression.  Instead of going through a list of optimizations,
however, it takes one optimization combination, runs all tests with
all optimizations turned off, while gathering a list of which methods
were jitted.  Then, for each jitted method, it runs all tests again,
with the optimizations applied to only that one method, stopping as
soon as a test fails.  Example:

    mono --single-method=branch,peephole basic-float.exe
2013-10-18 16:19:00 -07:00
Zoltan Varga b17461cb8a Disable a corlib test assertion which is no longer true. 2013-10-18 22:24:04 +02:00
Rodrigo Kumpera 9acd6e303d Merge pull request #768 from madewokherd/gcnotdll
Define GC_NOT_DLL for included boehm on win32.
2013-10-18 11:09:11 -07:00
Zoltan Varga 930e8fe970 [sgen] Set the TLS key offsets in one place in create_allocator (). 2013-10-18 19:28:39 +02:00
Zoltan Varga 6633bf1697 [aot] Add the JIT icall wrappers later, so it can pick up the JIT icalls registered by the managed allocators. 2013-10-18 19:25:09 +02:00
Zoltan Varga 8ff186652f [runtime] Fix the build. 2013-10-18 18:32:28 +02:00
Zoltan Varga cb2e262116 [runtime] Really fix the build. 2013-10-18 18:14:25 +02:00
Zoltan Varga 88bbc34b27 [runtime] Fix the build. 2013-10-18 18:10:30 +02:00
Zoltan Varga c94acdd085 [runtime] Add a missing file. 2013-10-18 18:01:44 +02:00
Zoltan Varga 2735588c0c [runtime] Clean up the usage of the CEE_MONO_TLS opcode in wrappers. Instead of passing it the tls offset, pass one of the TLS_KEY_ constants defined in mono-tls.h, and resolve the offset in the JIT. This allows these wrappers to work with AOT. 2013-10-18 17:54:20 +02:00
Zoltan Varga dc0bf73e84 Merge pull request #781 from directhex/master
SPARC build fixes
2013-10-18 02:22:32 -07:00
Jo Shields 842b67d546 Define REG_SP on SPARC in sgen-archdep.h, if needed.
This definition is stolen from exceptions-sparc.c
2013-10-18 09:36:00 +01:00
Jonathan Lima 49017bc699 Fix MSVC build. 2013-10-18 10:19:33 +02:00
Jo Shields dd149e75e6 Add missing ; characters to mono-hwcap-sparc.c. Fixes build failure. 2013-10-18 09:07:52 +01:00
Atsushi Eno 6dae772d49 Merge pull request #762 from echampet/wsdl
[FIX] Bug 267: wsdl fails with "Argument is out of range."
2013-10-18 00:52:08 -07:00
Atsushi Eno 87f80d1139 Merge pull request #766 from remobjects/resx-delete-on-clean
When generating resources, it intends to add the .resources file to the ...
2013-10-18 00:49:51 -07:00
Atsushi Eno 0075f39215 Merge pull request #767 from ovatsus/Bug14922
Fix for #14922
2013-10-18 00:48:26 -07:00
Zoltan Varga 6934f160db Fill out AssemblyName.ProcessorArchitecture for assemblies. Fixes #15347. 2013-10-17 11:53:17 +02:00
Marek Safar 4387da1524 Better check for open generic types in probing expression. Fixes #15422 2013-10-16 20:21:18 +02:00
Marek Safar b055fa22df Fixes too early optimization of binary &&/& bool constants. Fixes part of #15392 2013-10-16 19:17:25 +02:00
Martin Baulig 346b2ee260 Dummy test commit. 2013-10-16 11:24:57 +02:00
Mark Probst 5db0301dc8 [sgen] Don't crash on nurseries of 512M or larger. 2013-10-15 16:47:18 -07:00
Martin Baulig 65aefd9749 [PCL]: Update the PCL Facade Assemblies. 2013-10-15 20:31:03 +02:00
Zoltan Varga b322a6e410 [aot] Only use an AOT shortcut in the trampoline code if its safe to do so. Fixes #15345. 2013-10-15 17:01:24 +02:00
Martin Baulig f0fe1fbd79 Makefile magic ... 2013-10-15 14:49:49 +02:00
Marek Safar 3a7e67b4c5 Fixes CodeDom regression introduced by 66d4b82a87 2013-10-14 19:17:52 +02:00
Marek Safar 394591e203 Merge pull request #779 from LogosBible/UTF8Encoding
Fixing bugs in UTF8Encoding's GetMaxByteCount and GetMaxCharCount.
2013-10-14 00:32:13 -07:00
Martin Potter 1b318701b9 Fixing bugs in UTF8Encoding's GetMaxByteCount and GetMaxCharCount.
The previous implementation of GetMaxByteCount has two bugs: it incorrectly took into account the byte order mark and it was taking the max of a byte count (3) and a character count (EncoderFallback.MaxCharCount). This could result in returning the max number of bytes required to convert a string that was less than the number bytes used when converting the string.

GetMaxCharCount did not previously take into account DecoderFallback.MaxCharCount or the fact that there may still be part of a surrogate pair left on the buffer from a previous call to convert.

I removed the #if NET_2_0 conditionals and NotWorking category since these methods now return results consistent with Microsoft's implementation. I also added two simple tests for custom EncoderFallback and DecoderFallback cases.

This commit is licensed under MIT/X11.
2013-10-13 14:37:45 -07:00
Jeffrey Stedfast 779127e0a5 Merge pull request #774 from DavidS/patch-1
Minor fix to avoid ArgumentOutOfRangeException
2013-10-12 15:07:27 -07:00
Zoltan Varga 0cbc4ad6c0 [runtime] Run the tests in mono/tests in sorted order. 2013-10-12 15:17:59 +02:00
Zoltan Varga d4741184d3 [xdebug] Avoid using a MonoDebugMethodJitInfo structure after it has been freed. Fixes #15090. 2013-10-12 02:49:10 +02:00
Sebastien Pouliot cb19547a83 [mono-api-html] Several indexer properties (Item) can have the name (with different parameters) 2013-10-11 16:44:59 -04:00
Sebastien Pouliot 24169a083e [mono-api-html] Output nested type correctly (was missing the declaring type name) 2013-10-11 11:05:17 -04:00
Marek Safar d2b121244a The first definite assignment cleanup 2013-10-11 15:35:28 +02:00
Mark Probst ace1e095ce [regalloc2] Handle sreg3. 2013-10-10 16:55:01 -07:00
Mark Probst ce6ec03e5d [regalloc2] Lazily allocate intervals. 2013-10-10 16:55:01 -07:00
Rodrigo Kumpera cb04c5a12d Merge pull request #777 from nealef/master
Remove debug message
2013-10-10 11:44:45 -07:00
Neale Ferguson d6a8d9880e Remove debug message 2013-10-10 14:37:43 -04:00
Rodrigo Kumpera 796c64439b Merge pull request #776 from nealef/master
Fix memory leaks in Oracle Client. The largest leaks come from the curso...
2013-10-10 11:26:54 -07:00
Neale Ferguson 0b26afc182 Fix memory leaks in Oracle Client. The largest leaks come from the cursors being created but never freed in OracleParameter.cs. The size of the memory used by these cursors varies from tens to thousands of bytes depending on the statement being executed. Several hours of transactions can lead to OOM errors. The other fixes are relatively minor but they do clean up other unmanaged memory not being returned. 2013-10-10 13:17:17 -04:00
Aaron Bockover d075623275 bxc#13642: MacNetworkChange: implement using managed code
The previous version used SCNetworkReachability
in C inside libMonoPosixHelper. This was less
than ideal and made it more problematic for
supporting iOS as it doesn't actually link
MPH in.

Rewrite using P/Invokes directly into the
SCNetworkReachability APIs for Mac OS X and
iOS.

Fixes https://bugzilla.xamarin.com/show_bug.cgi?id=13642
for iOS and Mac OS X.
2013-10-10 12:35:47 -04:00
Marek Safar a55758d136 Compound assignment of optimized binary constant needs to decompose it first. Fixes #15315 2013-10-10 16:09:31 +02:00
Marek Safar 87d6328f2f Better debugger visualization for .net 1.1 style custom collections 2013-10-10 16:09:31 +02:00
Sebastien Pouliot 8113f9b237 [mono-api-html] Output C# 'char' instead of 'System.Char' 2013-10-10 08:12:13 -04:00
Sebastien Pouliot 93399696e0 [mono-api-html] Do not produce (near-)empty files when no (public) changes are detected 2013-10-10 08:12:13 -04:00
Marek Safar 66d4b82a87 Ensure that CodeDom generated temporary directory is always created. Fixes #12202 2013-10-10 11:54:20 +02:00
Sebastien Pouliot a812e9a24b [mono-api-html] Show 'static' fields as such 2013-10-09 20:59:21 -04:00
Sebastien Pouliot 4407f88ea6 Process/compare/output method's generic parameters [#15311] 2013-10-09 20:31:13 -04:00
Marek Safar 6e5cd4b5cf Anonymous type are shared across module hence need module counters. 2013-10-09 20:01:44 +02:00
Rodrigo Kumpera 6b71c73790 Fix net_2_0 test. 2013-10-09 12:58:44 -04:00
Jonathan Pryor 4490185a8d Merge pull request #775 from directhex/fix-gendarme-doc-generation
[monodoc] Ensure we don't try to use <Parameters/> when it might be null. Fixes Gendarme doc generation.
2013-10-09 08:07:05 -07:00
Jo Shields 0e08c1f9c2 [monodoc] Support fields that match operator naming convention 2013-10-09 16:02:35 +02:00
Jo Shields 94eb62fdb9 [monodoc] Add a test for ba222d4eb9 2013-10-09 15:57:47 +02:00
Jo Shields ba222d4eb9 [monodoc] Ensure we don't try to use <Parameters> when it might be null. Fixes Gendarme doc generation. 2013-10-09 15:31:23 +02:00
Gustavo Guerra 6c8c17c932 Adjust defines to check for 4_0 instead of 3_0 2013-10-09 13:38:35 +01:00
Marek Safar 0e040e2244 anonymous: move counters to TypeContainer
With the anonymous counters on ModuleContainer,
    anonymous method and type names will be generated
    in a way that depends on the order of the sources
    passed to mcs. This can cause undesirable API
    and IL differences.

    Moving the counters to TypeContainer instead
    avoids this issue.
2013-10-09 14:27:19 +02:00
Marek Safar e0b711beaf Enum IConvertible can convert to same enum or System.Enum. Fixes #15289 2013-10-09 14:04:47 +02:00
Marek Safar d6f05668d4 Cleanup redundant code 2013-10-09 13:52:10 +02:00
Marek Safar 5d96c0de63 Simplify work item registration for internal work items 2013-10-09 12:51:16 +02:00
Marek Safar e591a1d63c Remove redundant initialization 2013-10-09 11:39:14 +02:00
Marek Safar f410e545e2 Allow to queue multicast delegates in thread-pool 2013-10-09 11:26:34 +02:00
Marek Safar e5bd8bc98b Release continuation ancestor before running. Fixes #15036 2013-10-09 10:43:41 +02:00
David Schmitt bb3d1b7ca3 Minor fix to avoid ArgumentOutOfRangeException
When the file is empty, data[0] would throw and swallow the original exception.
2013-10-09 10:36:37 +02:00
Marek Safar f33bd8ad7f Adds async type inference of void return type. Fixes #15238 2013-10-08 19:30:32 +02:00
Marek Safar cf2ac2171b Make Task.Delay more reliable. Fixes #14585 2013-10-08 10:16:19 +02:00
Jeffrey Stedfast c82aea5fb2 [System.ComponentModel.DataAnnotations] Implemented EmailAddressAttribute.IsValid() 2013-10-07 17:51:17 -04:00
Atsushi Eno 8d401cb39d Element() and Elements() could also reduce use of extraneous iterators. 2013-10-08 01:57:17 +09:00
Jonathan Pryor a601831f63 Fallback to $LANG if $LC_ALL isn't set.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=15214

This is a regression introduced in be532638.

Xamarin.Android assumes that the $LANG environment variable can be
used to control System.Globalization.CultureInfo.CurrentCulture,
setting LANG based on the current Java locale.

This was broken in be532638 because $LANG was no longer being checked
to determine the default locale, as $LC_ALL was not set.

Fix the fallback logic so that $LANG is checked when $LC_ALL is not.
2013-10-07 12:31:06 -04:00
Atsushi Eno 5d25022423 reduce memory use on Attribute() caused by Attributes(). 2013-10-08 01:25:51 +09:00
Marek Safar 43a0a9d47f Inline more is instance checks 2013-10-07 17:04:13 +02:00
Marek Safar 3fbd4b873c Cache only resolved types not expression to report correct error location. Fixes #15035 2013-10-07 15:04:09 +02:00
Atsushi Eno 2a52ec9e36 in XLinq XObject there is no need to instantiate XObjectEventArgs every time. 2013-10-07 21:32:10 +09:00
Zoltan Varga f4ada63ae8 Merge pull request #771 from madewokherd/rvamap
For module handles, only check that rva's are within the image size.
2013-10-05 21:12:58 -07:00
Sebastien Pouliot dd197f0c5f Ignore some asserts since the validation were removed 2013-10-04 17:08:48 -04:00
Miguel de Icaza 096c647c80 FixBuild 2013-10-04 17:07:14 -04:00
Marek Safar 009d937c1d Better check for instance equality of generic types. Fixes #15100 2013-10-04 16:42:57 -04:00
Marek Safar 7585958bfd Fix some code issue warnings 2013-10-04 16:42:57 -04:00
Zoltan Varga fd7cec894d [sgen] Use gcc bitcount intrinsics where appropriate. 2013-10-04 15:54:17 -04:00
Miguel de Icaza 8f604d71f1 This regex was wrong in the first place, and second, it uses CC code from Stackoverflow 2013-10-04 15:47:22 -04:00
Miguel de Icaza 9d13d1aeb0 Remove CodeProject licensed code 2013-10-04 15:43:47 -04:00
Miguel de Icaza 58cf2e272a Add actual source 2013-10-04 15:42:49 -04:00
Miguel de Icaza a52849e336 Fix inacurrate reference 2013-10-04 15:39:09 -04:00
Vincent Povirk 7a4f59d121 For module handles, only check that rva's are within the image size.
This commit licensed as MIT/X11.
2013-10-04 13:33:56 -05:00
Rodrigo Kumpera 48266c8b04 Merge pull request #770 from abock/master
mdbrebase: fix prefix replacement, add regex & filename modes
2013-10-04 09:55:00 -07:00
Aaron Bockover b8be8f0e63 mdbrebase: fix prefix replacement, add regex & filename modes
Existing prefix replacement was incorrect as
it tested for a prefix but performed a multi
search and replace instead of just a prefix
replace. Fix that.

Add -r|--regex mode to indicate that path
replacement should be performed with regular
expressions.

Add -f|--filename mode to indicate that
replacements should be performed only on
a file name and not the full absolute path.

Add -v|--verbose mode to print the replacements
that are performed.
2013-10-04 10:26:24 -04:00
Gustavo Guerra 0fd61547a1 [xBuild] Don't set any VisualStudioVersion 2013-10-04 10:49:00 +01:00
Sebastien Pouliot 8e037f7cef [mdoc] Fix output of GenericParameter (Cecil now overrides DeclaringType since 60ce19429e9cfaa770d72c2f395fdcdf11eb0f7b) not to include namespace (and match previous, correct, output) 2013-10-03 21:59:41 -04:00
Jonathan Pryor eda41be355 Support deserializing relative Uris. Fixes #15169.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=15169
2013-10-03 11:06:21 -04:00
Marek Safar a769cce0b7 Fixes regression caused by 3912066fe1 change 2013-10-03 09:07:45 -04:00
Rodrigo Kumpera d7cc362ebd Merge pull request #769 from schani/fix-exception-throw-signal
[x86] Fix bug when getting a signal while throwing exception.
2013-10-02 14:45:09 -07:00
Marek Safar 7e01f047fa Emit better debugger attribute for stepping over state machine initialization 2013-10-02 17:29:59 -04:00
Sebastien Pouliot 7885214216 Use more detailled assert messages in some, randomly failing, Timer unit tests (to help track #14305) 2013-10-02 16:28:12 -04:00
Zoltan Varga 3e745070db [runtime] Save MonoTrampInfo structures in a list so mono_print_method_from_ip () would work on trampolines. 2013-10-02 13:20:43 -04:00
Gustavo Guerra b8a031d583 [xBuild] Add missing VisualStudioVersion propety which was introduced in VS2012 2013-10-02 16:12:29 +01:00
Mark Probst 3f587a4ec5 [x86] Fix bug when getting a signal while throwing exception. 2013-10-02 10:58:53 -04:00
Mark Probst 8828fafe29 [AMD64] Fix bug when getting a signal while throwing exception.
This is a very rarely occurring bug that's also still present on x86
and possibly other architectures, as well.
2013-10-02 10:06:50 -04:00
Atsushi Eno 2f7631188b revive XSLT standalone tests (which was broken because of dependency on too old nunit and build profiles). 2013-10-02 23:04:44 +09:00
Zoltan Varga 6622e98ec6 [runtime] Fix a runtime test which got broken by the newly added methods to the Marshal class. 2013-10-02 09:24:32 -04:00
Gustavo Guerra 92eda1e2a6 [xBuild] Fix use of properties in project references when those properties use MSBuildExtensionPath after expanded 2013-10-01 21:45:54 +01:00
Robin Neatherway 80dea22861 [xBuild] Fix compilation for Mono 2.0 2013-10-01 21:45:13 +01:00
Martin Baulig 714efcf7d1 [System]: Fix System.IO.Compression.CompressionLevel enum. 2013-10-01 12:48:57 -04:00
Sebastien Pouliot f7882be852 Relax name check when deserializing a WindowsIdentity instance as the name can be empty (e.g. iOS7 simulator will hide the user name) [#12789] 2013-09-30 20:39:14 -04:00
Sebastien Pouliot f5c5728ba6 [mono-api-html] Better handling of generic types (so they can be simplified and displayed correctly, e.g. for arrays) 2013-09-30 17:32:57 -04:00
Sebastien Pouliot 2ce488024f [mono-api-html] Fix ending quote for non-string fields 2013-09-30 17:32:56 -04:00
Marek Safar 3912066fe1 Anonymous method with this access inside an iterator needs to initialize captured this field from iterator's copy. Fixes #14926 2013-09-29 17:58:19 -04:00
Gustavo Guerra f7a787b140 [xBuild] Fix Import elements with the combination of wildcards and absolute paths
Used in the .targets files shipped with VS2013
2013-09-29 21:28:56 +01:00
Gustavo Guerra 29bb48cdc7 [xBuild] Support for ImportGroup element
Used in the .targets files shipped with VS2013
2013-09-29 21:26:00 +01:00
Gustavo Guerra ad8b4d7a4b [xBuild] Suport >= in string conditions
e.g: '$(MSBuildAssemblyVersion)' == '' and ('$(VisualStudioVersion)' != '' and '$(VisualStudioVersion)' >= '12.0'), used in the .targets files shipped with VS2013
2013-09-29 21:22:47 +01:00
Gustavo Guerra fed01f9b44 [xBuild] Support use of properties defined in Choose elements in project references
This is used by the .fsproj files generated by VS2013 which use a Choose element to set the location of the F# targets file to import
2013-09-29 21:21:34 +01:00
Gustavo Guerra b9a4200cae [xBuild] Support ToolsVersion 12
From VS2013, MSBuild is now decouple from the .NET Framework and is a separate redistributable. This means it has a new location and version numbering scheme. There are also some addition MSBuild properties because of this
2013-09-29 21:13:58 +01:00
Sebastien Pouliot 6336e516d3 Fix potential NRE and give better output for fields and some types 2013-09-28 13:07:17 -04:00
Atsushi Eno 99bcb28944 Add ConsoleLoggerTest and fixed implementation to match .NET implementation. 2013-09-28 20:58:52 +09:00
Atsushi Eno d8b8cab32a implement some "new in 4.0" build event args types. 2013-09-28 20:57:50 +09:00
Rodrigo Kumpera 44545f6cc2 Revert "Allow workitems to startup faster and reduce polling thread interval in the threadpool."
This commit is causing unbound growth in the number of threads for a series of workloads.

It's leading a sgen test to crash with 800 tp threads around, which doesn't make sense on a
4 cores system with default TP configuration.

This reverts commit 3c347d5d3a.
2013-09-27 19:51:54 -04:00
Rolf Bjarne Kvinge 28a6623aa9 [Mono.Tuner] Remove unused field. 2013-09-27 15:03:42 +02:00
Atsushi Eno 3579ae4ec7 Add some "new in 4.0" API regarding build event args. 2013-09-27 20:02:14 +09:00
Zoltan Varga 9c2e07499e [sdb] Fix decoding of nested structs. Fixes #14942. 2013-09-27 12:35:22 +02:00
Atsushi Eno 5b867d6fb7 Fix build.
I forgot to save buffer, build, then save, then committed :(
2013-09-27 19:12:54 +09:00
Sebastien Pouliot ff7b7254bc Drop the System.Enum and System.ValueType for enum and struct. 2013-09-26 16:17:15 -04:00
Sebastien Pouliot c90d23bed5 Add a new tool to produce HTML diff of assemblies similar to what Xamarin.iOS has been producing 2013-09-26 15:42:29 -04:00
Vincent Povirk bd421b40ee Define GC_NOT_DLL for included boehm on win32.
This commit licensed as MIT/X11.
2013-09-26 14:06:06 -05:00
Atsushi Eno 630cace193 implement some primary members of ConsoleLogger (and FileLogger). 2013-09-27 01:54:41 +09:00
Jeffrey Stedfast 450407d1c8 [MacProxy] Initialize err to IntPtr.Zero before calling CFNetworkCopyProxiesForAutoConfigurationScript 2013-09-26 12:27:12 -04:00
Zoltan Varga ef53ac8727 [sdb] Fix a race in the sdb tests exposed by the recent threadpool changes. 2013-09-26 13:02:30 +02:00
Mark Probst b4320bf02f [sgen] A better fix for the POSIX stop-world deadlock. 2013-09-25 18:40:21 -07:00
R. Brian Lindahl e1a1624504 When generating resources, it intends to add the .resources file to the FilesWritten list. However, it sets the ItemSpec on the wrong item, and a 'Clean' ends up deleting the .resx file. 2013-09-25 08:40:43 -07:00
Zoltan Varga 91ae2ef9aa Implement net 4.5.1 generic wrapper methods in Marshal. 2013-09-25 13:04:02 +02:00
Atsushi Eno 20716c55e7 Fix bug #14951 - there was another escape sequence 1B 24 40 to indicate "old" JIS. 2013-09-25 18:37:30 +09:00
Marek Safar 269db1075c Bump ikvm-reflect 2013-09-25 11:27:06 +02:00
Marek Safar a4a84a1325 Report less cascading errors 2013-09-25 11:20:09 +02:00
Marek Safar dd108ce0ac Don't crash when reporting invalid named argument name. Fixes #14962 2013-09-25 10:53:49 +02:00
Zoltan Varga 4a38ae76cb Fix the build. 2013-09-25 01:35:19 +02:00
Mark Probst a4f089aadb Add a section to the README on how to submit bug reports. 2013-09-24 15:17:14 -07:00
Jonathan Pryor 4672f532ea [System] Fix the CSharpCodeCompiler error parsing regex.
Use the same regex as xbuild uses for error parsing; see 7a2d2c24.
2013-09-24 17:14:55 -04:00
Jonathan Pryor 7a2d2c247c [MSBuild] Fix the ${level} and ${number} capture.
Fixes: https://bugzilla.xamarin.com/show_bug.cgi?id=14767

	Some people, when confronted with a problem, think
	“I know, I'll use regular expressions.”   Now they have two problems.
	- http://regex.info/blog/2006-09-15/247

ToolTask uses a regular expression to extract various bits of
information from the warning/error message. Unfortunately it was
inadequate, and didn't correctly match on some errors.

The error message in this case is:

	class1.cs(16,4): error CS0152: The label `case 1:' already occurs in this switch statement.

The problem was that while the previous regular expression would
succeed in matching the above string, it was horribly inaccurate in
what it captured:

	${file}   = "error CS0152"
	${line}   = "16"
	${column} = "4"
	${level}  = "The"
	${number} = "label `case 1"
	${message}= "' already occurs in this switch statement."

Did I mention hilariously wrong?

There were two problems with the previous pattern:

 1. It allowed filename+(line,column) to be _repeated_, which is
    clearly insane. Filename/etc. shouldn't be repeated.

 2. ${number} captured ".*\d", i.e. anything ending with a number, so
    when the message had a number embedded within it, it was captured.

For good measure, use RegexOptions.IgnorePatternWhitespace so that
we don't have a horrendously long regex pattern to compare for diffs
the next time this needs fixing, and add NUnit tests.
2013-09-24 16:29:31 -04:00
Mark Probst 8c57ebccfd [sgen] Fix a thread startup deadlock on POSIX.
If the GC stops the world and a thread is in the process of starting
up, but has not yet registered (it's not in the thread_list), it is
possible that the thread does register while the world is stopped.
When restarting the GC will then try to restart said thread, but since
it never got the suspend signal, it cannot answer the restart signal,
so a deadlock results.

This is triggered by `tests/sgen-bridge.cs`, about once every 10 runs.

We solve this by using a negative value in the `signal` field in the
thread info to indicate threads that have never been suspended.
2013-09-24 11:27:29 -07:00
Marek Safar 0d06d873f8 Better checks for inaccessible member used via dynamic proxy. Fixes #14762 2013-09-24 19:17:06 +02:00
Marek Safar b70d5e1b96 Reenable accidentally disabled test 2013-09-24 16:04:07 +02:00
Marek Safar 40fb1399c9 Fixes compilation error on Mavericks 2013-09-24 16:00:58 +02:00
Marek Safar f9ba0a1b8f Initialize cookie container for default requests. Fixes #14783 2013-09-24 16:00:57 +02:00
Marek Safar 1c89349477 Optmizes one string comparison.
Remove useless GC.SuppressFinalize
2013-09-24 16:00:57 +02:00
Paolo Molaro 3c347d5d3a Allow workitems to startup faster and reduce polling thread interval in the threadpool.
Deals with xambug #14644 and similar issues.
2013-09-24 15:30:51 +02:00
Sebastien Pouliot 6cf0c51ae3 Update cecil sources to latest 2013-09-24 08:56:51 -04:00
Sebastien Pouliot 97a9e58789 [linker] Resolve every type references if we're to save an assembly that is not linked (so the scope won't point to assemblies that were removed) 2013-09-24 08:56:51 -04:00
Marek Safar 5eb58e2e4e Check modifying members of readonly value-type field. Fixes #14802 2013-09-24 10:22:07 +02:00
Zoltan Varga a3f67badc0 Fix the windows build. 2013-09-24 06:11:50 +02:00
Rodrigo Kumpera 3734c725a4 Fix the windows build. 2013-09-23 19:14:05 -04:00
Rodrigo Kumpera 98d23141f9 Add test case for xref behavior for the sgen bridge. 2013-09-23 19:13:20 -04:00
Rodrigo Kumpera 86df16b7bc Make sure we properly account for transitive liveness when processing bridge objects. Fixes #13858
We depend on the latent liveness state of objects at the time we collect bridged objects. To
preserve this we must perform the dfs1 step right after collecting them and before we drain the
gray stack or all objects pointed by candidate bridge objects will be marked as alive.
2013-09-23 19:13:20 -04:00
Miguel de Icaza 89f10a3ba5 Wrap the code in MONO_BEGIN/END_DECLS 2013-09-23 13:03:12 -04:00
Miguel de Icaza 85841d0bbd Update message 2013-09-23 13:03:12 -04:00
Marek Safar b52c963187 Pass cancellation token to CopyAsync read block 2013-09-22 19:23:17 +02:00
Marek Safar 17a018fef8 Implements content loading cancellation. Fixes #13200 2013-09-22 19:15:08 +02:00
Marek Safar 61ab67065d Test update 2013-09-22 17:43:41 +02:00
Marek Safar b8e3beb7d3 Bump ikvm-reflection 2013-09-22 17:42:47 +02:00
Zoltan Varga 3a84cf0612 [runtime] Ignore --llvm when LLVM is not enabled in configure. 2013-09-21 14:56:58 +02:00
Vincent Povirk be23ac1a4e Add test for native thiscall methods.
Licensed under MIT/X11.
2013-09-21 05:13:10 +02:00
Vincent Povirk 437f115dcd Add support for thiscall pinvokes on x86.
Licensed under MIT/X11.
2013-09-21 05:12:26 +02:00
Zoltan Varga e0fb186df2 [aot] Pass correct architecture to llc on x86-64. 2013-09-21 05:03:48 +02:00
Zoltan Varga 767a1311ee Make the test-aot test less verbose. 2013-09-21 02:45:09 +02:00
Zoltan Varga 6244e939b8 Merge pull request #765 from knocte/runtime_fixage
[sgen] Improve fix for BXC#14834 to avoid redundant code
2013-09-20 15:51:35 -07:00
Andrés G. Aragoneses f55996d3b4 [sgen] Improve fix for BXC#14834 to avoid redundant code
Improve https://github.com/mono/mono/commit/d2cc22580898df5d4a15e0f99ab513e1570a6082
by making OBJ_BITMAP_FOREACH be less redundant thanks to new macro
GNUC_BUILTIN_CTZ
2013-09-20 22:15:42 +02:00
Marek Safar ee5939881d Fixed TaskFactory::ContinueWhenAny with func result. Fixes #14839 2013-09-20 19:41:15 +02:00
Zoltan Varga d2cc225808 [sgen] Use __builtin_ctzl () in OBJ_BITMAP_FOREACH_PTR () on 64 bit platforms. Fixes #14834. 2013-09-20 19:06:44 +02:00
Mark Probst 0a695738d8 Fix the build. 2013-09-20 09:34:44 -07:00
Marek Safar 8e78bec72e AggregateException::GetBaseException uses only 1-based inner exceptions. Fixes #14824 2013-09-20 18:01:08 +02:00
Marek Safar 8914882238 Merge pull request #760 from mayerwin/patch-2
Fix: bug https://bugzilla.xamarin.com/show_bug.cgi?id=14811 (to be reviewed)
2013-09-20 08:39:51 -07:00
Martin Baulig 90f23bfccf [xbuild]: Actually add the $(TargetFrameworkMonikerAssemblyAttributesPath) to @(Compile). 2013-09-20 16:56:17 +02:00
APS e4620ee888 [FIX] Bug 267: wsdl fails with "Argument is out of range."
This fix bug 267
https://bugzilla.xamarin.com/show_bug.cgi?id=267

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2013-09-20 14:24:59 +02:00
Marek Habersack bdc4eb0085 Merge pull request #758 from echampet/capabilities
Fix crashes with browser capabilities
2013-09-20 05:21:52 -07:00
Etienne CHAMPETIER ce65812cb2 [System.Web] Re-enable AppBrowsersTest.cs tests for net_2_0
For now mcs/class/System.Web/Test/mainsoft/NunitWebResources/adapters.browser
depends on System.Web_test_net_2_0.dll

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2013-09-20 14:19:41 +02:00
Etienne CHAMPETIER ae17ceeecc [Install] Add Compat.browser files for net_4_0 and net_4_5
Without that referencing browser 'Default' (parentID="Default")
in a .browser file make the app throw exceptions here
mcs/class/System.Web/System.Web.Configuration_2.0/nBrowser/Build.cs#L206

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2013-09-20 14:19:40 +02:00
Frederic Mestayer 03e31732d3 [System.Web] Do not crash on duplicate keys in browser capabilities
Correct https://bugzilla.xamarin.com/show_bug.cgi?id=14720 and
probably https://bugzilla.xamarin.com/show_bug.cgi?id=13014

Signed-off-by: Etienne CHAMPETIER <[email protected]>
Signed-off-by: Frederic Mestayer <[email protected]>
2013-09-20 14:19:40 +02:00
Rolf Bjarne Kvinge db195e8e90 [System.Net] Fix CFNetworkCopyProxiesForAutoConfigurationScript signature. Fixes #7923. 2013-09-20 10:33:49 +02:00
Mark Lintner 8ad18569c5 removed a hello world from the code. 2013-09-19 21:49:04 -07:00
Mark Lintner 9cb08ed0a8 undid some unecessary formatting 2013-09-19 21:43:04 -07:00
Mark Lintner b2dcf4fdab This adds a unit test and a more robust method for determining the servicecontract to be returned from ContractDescription.GetContract and to more accurately determine exceptional conditions. 2013-09-19 18:58:20 -07:00
Rolf Bjarne Kvinge e638c4d7ca [System.Net.Http] Add a way to add extra build arguments.
This is used by monotouch to add a reference to monotouch.dll.

Also add a profile-specific sources file for monotouch so the
extensions module can add even more files.
2013-09-20 01:05:57 +02:00
Rodrigo Kumpera db047c0473 Merge pull request #763 from madewokherd/mingwbuild
Fix the mingw-w64 build
2013-09-19 15:05:15 -07:00
Vincent Povirk c5635f8fa6 Fix undeclared variables in exceptions-amd64.c on win64.
This commit is licensed under MIT/X11.
2013-09-19 16:17:41 -05:00
Vincent Povirk b97629ec79 Test for InterlockedCompareExchange64 in the configure script.
mingw.org doesn't have this function but mingw-w64 does.

This commit is licensed under MIT/X11.
2013-09-19 16:17:18 -05:00
Zoltan Varga 267253b355 Disable the LLVM version check for now, it doesn't work if llvm was not compiled in a git repo. 2013-09-19 22:33:16 +02:00
Zoltan Varga 8ea61a7b5e Check the version of LLVM at configure time to make sure it has a matching version. 2013-09-19 22:05:00 +02:00
Rodrigo Kumpera 84432a62a1 Add test-aot target. 2013-09-19 16:03:23 -04:00
Rodrigo Kumpera 7d3c65c1b5 [runtime]Fix typo in detection of the need of 64bits atomic intrinsics. 2013-09-19 16:03:23 -04:00
Sebastien Pouliot 28882bd094 Change Random implementation to JKISS which is faster and has a longer period. Also match .NET 2.0 behaviour wrt calls to protected Sample. Add unit tests (and removed the commented ones). Ref: http://www0.cs.ucl.ac.uk/staff/d.jones/GoodPracticeRNG.pdf 2013-09-19 15:28:40 -04:00
Zoltan Varga 9ae3d769cb [runtime] Improve error checking for temporary file creation in the AOT compiler. 2013-09-19 21:23:24 +02:00
Rolf Bjarne Kvinge 2f60b53c8b Revert "Add System.Net.Http.dll to the monotouch build."
This reverts commit 9df6eebc34.

Not quite ready for this yet, more changes are needed.
2013-09-19 19:47:29 +02:00
Rolf Bjarne Kvinge 9df6eebc34 Add System.Net.Http.dll to the monotouch build. 2013-09-19 19:23:32 +02:00
Rodrigo Kumpera b445f447a0 [llvm] On OSX we need to search in /Libraries in addition to /lib. 2013-09-19 12:56:18 -04:00
Zoltan Varga 6bbf88d8cc [runtime] Fix a bug in the local register allocator when an fp vreg wasn't clobbered by a call if its href happened to be equal to the hreg of the call instruction. Fixes #12510. 2013-09-19 02:03:29 +02:00
Rodrigo Kumpera 920332a133 Fix the Makefile addition of a new test. 2013-09-18 16:21:49 -04:00
Rodrigo Kumpera 35e90b1af7 [runtime]Do an alignment check before using the atomic op. 2013-09-18 16:20:19 -04:00
Zoltan Varga e3bf9e84ff Fix the DISABLE_JIT build. 2013-09-18 22:09:37 +02:00
Rodrigo Kumpera 8288f81dfd Add a sgen test for threads joining/leaving at random places. 2013-09-17 19:25:27 -04:00
Rodrigo Kumpera 9dc8efe26e [sgen] Kill SgenThreadInfo::thread_is_dying in favor of the thread-info state information. 2013-09-17 19:23:50 -04:00
Rodrigo Kumpera 5942afee6f [runtime]Properly set mono-thread state as when starting/running/shutting down/dead. 2013-09-17 19:23:49 -04:00
Rodrigo Kumpera d6581bdf14 [sgen]Remove doing_handshake field since the race condition it fixes is now handled by mono-threads. 2013-09-17 19:23:49 -04:00
Rodrigo Kumpera a85ae5f10e [io-layer] Fix a warning. 2013-09-17 19:23:48 -04:00
Rodrigo Kumpera ce5327414f [runtime] Small optimizations and cleanup in ves_icall_System_Array_FastCopy. 2013-09-17 19:23:48 -04:00
Rodrigo Kumpera 8403a9ad43 [runtime]Add more fast variants of the mono_array functions as those shown up in profiling. 2013-09-17 19:23:48 -04:00
Rodrigo Kumpera 13a8893171 [sgen] Force inlining of some perf-critical functions. 2013-09-17 19:23:48 -04:00
Rodrigo Kumpera 9cae0d7361 [sgen]We no longer need joined_stw as new threads can't join once the suspend lock has been acquired.
Since no new thread can join until the collection is over, FOREACH_THREAD won't miss any thread.
2013-09-17 19:23:47 -04:00
Rodrigo Kumpera a1d20a2d53 [runtime]Provide a consistent view of registered threads during suspend operations.
We previously failed to provide a consistent view of the registered threads set. This
would should up in the following ways:

-New threads would join in between two FOREACH_THREAD passes. The recently joined threads
lead to broken invariants that one loop carried to the other.

-Existing threads would leave during a FOREACH_THREAD. The now defunct threads lead
to code waiting them to ack back and deadlock in the process.

-It was possible to witness an in-progress cleanup. This would show up by
mono_thread_info_current returning null when it should not.

To amend this we provide a a consistent view of all registered threads once the global
suspend lock is acquired. This is done by acquiring that lock when registering/unregistering.

This allows us to remove some of the work-around in the sgen thread registration
code and avoid taking the GC lock.
2013-09-17 19:23:47 -04:00
Mark Probst d836e9f05b [sgen] Don't stack overflow when there are too many binary protocol buffers.
Binary protocol buffers are linearly linked from newest to oldest, but need to be
written out from oldest to newest.  This was sloppily implemented with a recursive
call, which caused a stack overflow when there were too many buffers.  We now
allocate an array and store pointers to all the buffers in it, then iterate over it in
reverse.
2013-09-17 16:07:16 -07:00
mayerwin 5a25913631 Fix: bug https://bugzilla.xamarin.com/show_bug.cgi?id=14811 (to be reviewed) 2013-09-18 01:14:04 +08:00
Atsushi Eno 6176e0b179 Merge pull request #756 from akoeplinger/fix-xmlreader
Fixing inconsistency in XmlSchemaValidatingReader between Mono and MS.NET
2013-09-17 10:09:28 -07:00
Martin Potter c5918aef82 Improving the retrieval of the user's locale on Apple systems.
The previous behavior used the entire local identifier string that includes optional settings such as variant and calendar format. This returns locales like en_US_POSIX@calendar=buddhist which result in the user's culture being the invariant culture.

This change builds the locale from the language, country code and optional script code so that the locale returned is in the expected format.

This commit is licensed under MIT/X11.
2013-09-17 07:26:27 -07:00
Rodrigo Kumpera ab184afd66 Merge pull request #754 from blackfusion/master
[Scripts] Fix a Shebang in mono-test-install for freeBSD
2013-09-17 06:25:00 -07:00
Zoltan Varga 1a2668ce95 [runtime] Fix a regression introduced by 5503991372. Use __builtin_popcountl () on 64 bit machines. 2013-09-17 13:41:28 +02:00
Zoltan Varga 7c9b28a127 Disable a profiler test which fails on osx. 2013-09-16 23:26:24 +02:00
Zoltan Varga 248b6160be Fix the profiler tests. 2013-09-16 23:09:56 +02:00
Zoltan Varga 9aec810235 Revert "Set tls->context.valid to FALSE if a thread is suspended in native code. Fixes #1540."
This reverts commit 5ddbe31ee5.

Revert this as its incorrect, and causes a regression (#14058).
2013-09-16 20:46:04 +02:00
Larry O'Brien 9454174ee5 [mdoc] Switched from swallowing error to guarded execution
Improves a60ff0fd1e

Tests for file existence and outputs diagnostic rather than treating it as a local recoverable exception.

Leaving the question of general mdoc error-reporting for another day.
2013-09-16 07:19:00 -10:00
Zoltan Varga a88eb036a6 [runtime] Avoid constructing vtables in a few places during AOT. 2013-09-16 15:02:06 +02:00
Zoltan Varga a580cab5d6 [runtime] Avoid calling mono_resolve_patch_target () while AOTing, its not needed. 2013-09-16 01:44:02 +02:00
Zoltan Varga 3627b977d7 [runtime] Add support for constrained gsharedvt calls to normal virtual methods. 2013-09-16 01:23:15 +02:00
Zoltan Varga f160a59231 [runtime] Avoid looking up pinvoke addresses when AOT compiling. 2013-09-16 01:23:14 +02:00
Larry O'Brien a60ff0fd1e Bugzilla 14672 (mdoc namespace-level summary and remarks elements weren't being included)
commit 6ec0ddc7e5c4d5640da7420600898c10578a7974
Author: Larry O'Brien <[email protected]>
Date:   Sun Sep 15 11:03:32 2013 -1000

    Coding style

commit f034514fca8298a8ed2a167f3ab288f32bc7c74f
Author: Larry O'Brien <[email protected]>
Date:   Sun Sep 15 10:28:47 2013 -1000

    Bugzilla 14672

    Added namespace file ("ns-{namespace}.xml") summary and remarks into the nsSummaries, which results in displaying the data prior to the namespace type-list when the user searches at the namespace level.

    Appears to only be necessary for native viewer (Web viewer for some reason "knows" about the summaries).
2013-09-15 11:12:27 -10:00
Mark Lintner dd25ba0629 These changes fix 14335. When in getcontractinternal various things can confuse the host processing of ContractInterfaces. I only identified and fixed a couple so far and they fix problems with multiple inheritance of contracts and deep hierarchies. It is looking to verify that all of the contract interfaces it has in the list inherit from the root interface. However when IA and IB inherit from the IRoot. It will iterate nxn times and with multiple inehritance it will eventuall get a 1A and verify that it inherits from iroot it gois along until it verifies that A inherits from the root then finds it cannot verify IA becuase because it is checking to see if IB inherits from it. It doesnt because both of them are peers and inheit from IRoot. This threw an exception. I fixes that and a couple of related bugs.
Please enter the commit message for your changes. Lines starting
2013-09-15 10:27:04 -07:00
Zoltan Varga bb2bc9ae42 [runtime] Fix a few more places which accessed jinfo->method directly. 2013-09-15 03:21:44 +02:00
Zoltan Varga 454a4c5de7 Fix a problem introduced by c6989ab9f9. Avoid foreach on _items since that includes empty entries too. 2013-09-15 02:42:28 +02:00
Zoltan Varga 52072b80a5 [sdb] Simplify tests. 2013-09-15 01:51:25 +02:00
Zoltan Varga 25ec53d1f1 Update AOT after changes to SeqPoint in 488888ce61. 2013-09-15 01:39:05 +02:00
Zoltan Varga 488888ce61 [sdb] Add an implicit seq point after every nonvoid call and make step over skip them. Fixes #10782. 2013-09-15 01:36:38 +02:00
Zoltan Varga eb3e8946a8 Fix the ENABLE_JIT_MAP build. Fixes #14752. 2013-09-14 21:10:02 +02:00
Zoltan Varga 9a6510ece6 [runtime] Make mono_install_handler_block_guard () async-safe. Fixes #14073. 2013-09-13 21:37:00 +02:00
Zoltan Varga 2451de6cb3 [runtime] Make the stack walking code async safe when run in an async context. 2013-09-13 21:36:59 +02:00
Zoltan Varga 1597b525b9 [runtime] Make mono_aot_find_jit_info () async-safe by allocating memory from the lock-free domain mempool, avoiding loading metadata, and caching jit info entries in a lock-free array. 2013-09-13 21:36:59 +02:00
Zoltan Varga 2b7f5921f1 [runtime] Add a 'is_async_context' property to MonoThreadInfo, allowing functions to detect whenever they are in async context without having to pass an 'async' parameter around. 2013-09-13 21:36:59 +02:00
Zoltan Varga 3ac10d3382 [runtime] Add a lock-free mempool allocator to MonoDomain. 2013-09-13 21:36:58 +02:00
Marek Safar 5c8befbe27 Move dynamic handling out of Binary::DoResolve to reduce stack size 2013-09-13 18:55:47 +02:00
Marek Safar 22fd61d3b5 Add new test 2013-09-13 18:55:46 +02:00
Zoltan Varga 197b08dbe9 Fix a warning. 2013-09-13 18:46:34 +02:00
Zoltan Varga dace44d806 [runtime] Make the address->aot module lookup in mono_jit_info_table_find () async-safe by storing the mapping in another MonoJitInfoTable. 2013-09-13 18:46:34 +02:00
Zoltan Varga f48233a1e1 Extract the jit info table code into separate functions so we it can be used in more places. 2013-09-13 18:46:34 +02:00
Zoltan Varga 5bc25b90fb [runtime] Avoid direct access to MonoJitInfo.method, use an accessor function instead. 2013-09-13 18:46:33 +02:00
Mark Probst 1bdd4a6662 [sgen] Fix a toggleref array resize bug. 2013-09-13 09:21:32 -07:00
Atsushi Eno f0478f1f51 UTF8Encoding.GetMaxByteCount() was returning too big number.
The thing is, unlike the standards describe in codepoints, .NET String
characters beyond BMP are represented as surrogate pairs and they can be
converted all in 3 bytes.

The implementation didn't take care of encoder fallbacks, or byte order
marks either, so take them into considertion too.
2013-09-14 00:56:48 +09:00
Marek Safar 43bd9a8c6d Don't crash when unreachable code contains unreachable constant switch. Fixes #14587 2013-09-13 16:53:51 +02:00
Zoltan Varga 803cf83566 Fix parallel compression in mkbundle, not enabled yet. 2013-09-13 15:12:30 +02:00
Marek Safar c6989ab9f9 Unify Array/List FindIndex/FindLastIndex handling and argument checking. Fixes #14632 2013-09-13 14:51:08 +02:00
Sebastien Pouliot 1b4d970000 Move undef HAVE_SIOCGIFCONF later so it's not defined again by other includes 2013-09-12 19:48:33 -04:00
Miguel de Icaza be532638f5 Simplify locale fetching, we have very simple needs 2013-09-12 17:21:39 -04:00
Miguel de Icaza 06dc8911a0 Add workaround for DNS garbage return 2013-09-12 16:54:18 -04:00
Rodrigo Kumpera e03314480d [bcl] Fix BlockingCollection.TakeFromAny to handle when no items are available on the first collection. Fixes #6095. 2013-09-12 16:42:53 -04:00
Marek Safar 040b028811 Bump ikvm. Fixes the build 2013-09-12 17:00:16 +02:00
Sebastien Pouliot eeff03c59c Reduce/remove the probability of having test failures wrt UdpClient.Available 2013-09-11 21:00:04 -04:00
Marek Safar cb52f180bd Bump ikvm 2013-09-11 23:17:20 +02:00
Zoltan Varga 5503991372 Use __builtin_popcount () in mono_bitset_count (). 2013-09-11 22:51:59 +02:00
Miguel de Icaza be272cb3e8 Remove comment, refer to the spec instead 2013-09-11 16:26:47 -04:00
Miguel de Icaza 47b5f3a52c Remove text from article 2013-09-11 15:47:10 -04:00
Martin Baulig 8d3b4b7ae5 Bump ikvm again to only pick-up my single commit.
I created a new 'mono-master' branch in ivkm-fork, which is based
at the previous ikvm commit, then cherry-picked my single commit.

Apparently, there are API changes in IVKM which prevent it from
being applied cleanly.
2013-09-11 21:13:10 +02:00
Miguel de Icaza 0c25f98893 Rewrite the header file, based on the internal mono-hash.c contents 2013-09-11 15:06:18 -04:00
Miguel de Icaza 17669cd166 More inline docs 2013-09-11 15:06:18 -04:00
Martin Baulig 018c4af398 Bump ikvm to pick up ce0e014ed68d052989b162f0e74524cac2199647. 2013-09-11 20:52:31 +02:00
Martin Baulig 40a8a891f7 Add comment that this must be kept in sync with ikvm. 2013-09-11 20:52:30 +02:00
Marek Safar fb3ad60837 Revert "Bump ikvm"
This reverts commit 89166a0ea7.
2013-09-11 18:31:19 +02:00
Marek Safar 89166a0ea7 Bump ikvm 2013-09-11 18:26:16 +02:00
Martin Baulig 55065d0d02 [System.Core]: Minor API fix in the Non-DLR version of System.Linq.Expressions. 2013-09-11 15:42:19 +02:00
Martin Baulig 446857eaa3 Use ecma.pub for System.Xml.Serialization. 2013-09-11 15:39:21 +02:00
Martin Baulig 1ae48f124c Use msfinal.pub for System.Net in .NET 4.0/4.5. 2013-09-11 15:37:06 +02:00
Alexander Köplinger 3dfeae598a Fixed inconsistency in XmlSchemaValidatingReader between Mono and MS.NET 2013-09-11 12:38:19 +02:00
Rodrigo Kumpera 1f0eebb35f Fix the OSX and Windows build. 2013-09-10 19:43:09 -04:00
Rodrigo Kumpera b3d80013a0 Improve the build system. 2013-09-10 18:43:22 -04:00
Marek Safar 4529532aa7 Bump ikvm 2013-09-10 15:50:01 +02:00
Marek Safar 7db34940fe Don't set sealed flag for imported static types 2013-09-10 15:44:18 +02:00
Marek Safar 78a8c012d4 Don't emit inflated type parameter constraints which can collide with special constraint types. 2013-09-10 14:56:27 +02:00
Marek Safar 8bd66dbbeb Add System.ServiceModel.Activation assembly. Fixes #14544 2013-09-10 10:14:50 +02:00
Rodrigo Kumpera 6531ed7dd7 [verifier]Check generic constraints for duplicates. Fixes #1782. 2013-09-09 14:49:27 -04:00
Marek Safar c71c7fd196 Merge pull request #755 from ondrejmyska/master
Suggestion fix for bug https://bugzilla.xamarin.com/show_bug.cgi?id=6327
2013-09-09 10:15:23 -07:00
Rodrigo Kumpera 0ef4bd5dc9 [runtime] Fix a loader leak in the aot compiler. 2013-09-09 12:08:41 -04:00
Rodrigo Kumpera a578665b8a [runtime] Make suspend work during thread cleanup. Fixes #14555
SDB does suspend/resume during thread cleanup. It used to work until I introduced
critical regions. This won't work anymore as we need to lookup the thread info object
and during cleanup it will be gone.

The fix is to introduce mono_thread_info_current_slow which is a variant of
mono_thread_info_current that does search the thread list if the TLS key
is gone.
2013-09-09 11:25:49 -04:00
Ondrej Myska 50b53c5e1c Suggestion fix for bug https://bugzilla.xamarin.com/show_bug.cgi?id=6327 2013-09-09 17:19:34 +02:00
Zoltan Varga a918a64771 [runtime] Fix a nullref when casting a null object to a complex type when using --debug=casts. Fixes #14552/#14493. 2013-09-09 17:15:39 +02:00
Marek Safar 253b7cfc3f Set empty string to TraceListeners for empty assert message. Fixes #14505 2013-09-09 09:42:53 +02:00
Marek Safar 84d93ab24f Cleanup TraceImpl 2013-09-09 09:36:03 +02:00
Marek Safar f33ed3fd4f Fixes parallel enumerable index counter. Fixes #14515 2013-09-09 09:12:41 +02:00
Raphael Boissel eaa39bd1c7 [Scripts] Fix a Shebang in mono-test-install for freeBSD 2013-09-08 22:40:30 +02:00
Zoltan Varga 0318cfae1a [runtime] Force the usage of --host=i686-pc-mingw32 when running configure on windows. 2013-09-08 11:08:22 +02:00
Marek Safar 3dec818807 Don't print empty detailed assert message 2013-09-08 10:59:28 +02:00
Zoltan Varga 94856d264c [runtime] Fix the mingw build by defining InterlockedCompareExchange64 () which is missing from mingw's winbase.h. 2013-09-08 10:52:42 +02:00
Zoltan Varga 31db4c7cb4 [sdb] Add support for invoking interface methods. Fixes #14503. 2013-09-07 06:31:07 +02:00
Martin Baulig f59fa062fb [System]: WebRequest.GetSystemProxy(): Return custom proxy for monodroid.
On ICS and newer, we can use Java.Net.ProxySelector, which supports
per-access point proxy settings.  Fixes #12640.
2013-09-07 00:06:00 +02:00
Rodrigo Kumpera 715be9e991 Add another extension point to the runtime. 2013-09-06 17:22:25 -04:00
Mark Probst 0b296662ae [runtime] Thread teardown race condition. Fixes #13813. 2013-09-06 10:46:31 -07:00
Marek Safar 0372e3cd93 Implements parsing of multi value User-Agent string. Fixes #8719 2013-09-06 13:41:20 +02:00
Zoltan Varga 81d7fec759 Fix the test added by e682eceec3. 2013-09-06 06:43:12 +02:00
Zoltan Varga 7ca581cd34 [runtime] Add more logging to a test which fails on wrench. 2013-09-06 03:29:41 +02:00
Zoltan Varga a5839c9c20 [runtime] Make a marshalling test more robust. 2013-09-06 02:22:58 +02:00
Zoltan Varga e682eceec3 Avoid the managed->copy for ref vtypes with an [In] attribute in native-to-managed wrappers. Fixes #14069. 2013-09-05 18:13:43 +02:00
Zoltan Varga 6f5f478329 Avoid printing an error message in UnixRegistryApi which can happen during normal usage when a root process has created a registry under the mono installation prefix. Fixes #14366. 2013-09-05 17:43:48 +02:00
Rodrigo Kumpera 7ac5749d3e [runtime]Fix the OSX build due to crappy compilers. 2013-09-05 11:17:38 -04:00
ProUkorNew 98246b0552 Remove repeated include 2013-09-05 17:07:19 +02:00
Zoltan Varga 38ee810a9e Clear out the ref fields from MonoDomain before calling mono_gc_clear_domain (), since they will be invalidated by that call, and a GC could try to mark the invalid objects. Fixes #14339. 2013-09-05 16:21:36 +02:00
Marek Safar 894114cdf6 Merge pull request #751 from akoeplinger/AssemblyNameReferenceMatchesDefinition
Implemented AssemblyName.ReferenceMatchesDefinition ()
2013-09-05 06:13:31 -07:00
Marek Habersack 41f7b18368 Merge pull request #752 from echampet/bug-10001-2
[FIX][v2] Do not use chunked encoding with CGI/FastCGI
2013-09-05 04:51:28 -07:00
Alexander Köplinger 4f37c78e6a Implemented AssemblyName.ReferenceMatchesDefinition () 2013-09-05 03:58:40 -07:00
Zoltan Varga 9778d252c9 Revert "Fix the windows build."
This reverts commit 71e0c38272.

Revert this as its no longer needed.
2013-09-05 07:50:58 +02:00
Miguel de Icaza e4f8a6c339 Improve inline docs 2013-09-05 00:14:32 -04:00
Zoltan Varga 71e0c38272 Fix the windows build. 2013-09-05 03:44:06 +02:00
Rodrigo Kumpera 99a8261acc Fix the windows build. 2013-09-04 20:21:40 -04:00
Miguel de Icaza 3d613f0c68 Add inline api docs 2013-09-04 17:30:21 -04:00
Rodrigo Kumpera a3b80aeccb [bcl]Replace more long fields with int to make them CAS friendly on 32 bits systems. 2013-09-04 14:59:13 -04:00
Rodrigo Kumpera 0acb81dc64 [bcl] Replace more long fields with int to make them CAS friendly on 32 bits systems. 2013-09-04 14:47:27 -04:00
Rodrigo Kumpera fa2419c9cf Perform alignment checks for CAS on 32bits systems. Fixes #14426. 2013-09-04 13:38:52 -04:00
Zoltan Varga b71ab29b8c [runtime] Remove a needless ifdef. 2013-09-04 18:53:08 +02:00
Stefan da51407be5 [FIX][v2] Do not use chunked encoding with CGI/FastCGI
it's forbiden by http://tools.ietf.org/html/rfc3875#section-6.3.4

This correct bug 10001, https://bugzilla.xamarin.com/show_bug.cgi?id=10001

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2013-09-04 18:29:54 +02:00
Zoltan Varga 119df901c2 Disable a corlib test which fails on some test runners. 2013-09-04 17:32:01 +02:00
Zoltan Varga 7a7a1ff947 Optimize MonoCustomAttrs.GetCustomAttributes(): add fastpaths for common cases, add a cache for looking up AttributeUsageAttributes, clean up intendation. 2013-09-04 17:31:19 +02:00
Zoltan Varga 431248dd0a Revert "[runtime] Handle MONO_PATCH_INFO_OBJC_SELECTOR_REF in mono_patch_info_hash ()."
This reverts commit 924e2b28ce.

Revert this, its not needed.
2013-09-04 17:20:47 +02:00
Zoltan Varga 924e2b28ce [runtime] Handle MONO_PATCH_INFO_OBJC_SELECTOR_REF in mono_patch_info_hash (). 2013-09-04 17:19:19 +02:00
Marek Safar 71b463fef1 Don't resolve extension method expression when in probing mode it may fail to resolve. Fixes #14384 2013-09-04 17:06:36 +02:00
Marek Safar 8d0de999d8 Less cascading errors 2013-09-04 17:06:36 +02:00
Miguel de Icaza c9db2bb7db mono_patch_info_hash: handle the MONO_PATCH_INFO_OBJC_SELECTOR_REF case 2013-09-04 10:53:48 -04:00
Zoltan Varga ec46c85cc4 Implement an intrinsics for Selector.GetHandle (). 2013-09-04 04:34:36 +02:00
Sebastien Pouliot 11df177e10 [linker] Allow some useful methods to be reused elsewhere 2013-09-03 21:23:39 -04:00
Zoltan Varga e2128ca26e Fix the mt build. 2013-09-04 02:48:10 +02:00
Zoltan Varga 6168d7a278 Rename a test target to hopefully fix the linux wrench build. 2013-09-04 02:36:01 +02:00
Zoltan Varga 7ba82952d6 Use $(MAKE) instead of make in one place. 2013-09-04 02:14:32 +02:00
Rodrigo Kumpera 4f41e84fde [bcl]Switch BlockingCollection to do CAS over ints and not longs.
The reasoning behind doing CAS on longs was to avoid overflowing
which is not a problem because 2-completement math does the trick.

This is much more reliable than using longs on 32 bits.
2013-09-03 17:03:59 -04:00
Rodrigo Kumpera 0923ad6b26 [bcl]Switch BlockingCollection to use SequentialLayot to make sure its longs are 8 bytes aligned everywhere. 2013-09-03 16:29:32 -04:00
Rodrigo Kumpera 7e2c7665a5 Fix Thread.VolatileRead(long&) on 32bits. 2013-09-03 16:29:32 -04:00
Rodrigo Kumpera 5d903d6762 [runtime]Use InterlockedCompareExchange64 instead of local hack. 2013-09-03 16:29:32 -04:00
Rodrigo Kumpera 32615d361b [runtime]Implement InterlockedCompareExchange64 on 64bits target, x86 and arm.
The current state of ARM compilers don't allow us to use compiler intrinsics as
they ICE on us, so we suck it up and use a naked function.
2013-09-03 16:29:31 -04:00
Marek Habersack 0101c86471 Revert "Merge pull request #744 from echampet/bug-10001"
This reverts commit 5178f29c4b, reversing
changes made to fb653dc0ea.
2013-09-03 21:16:26 +02:00
Marek Habersack a970e70152 Revert "Fix typo in commit b6d634dd."
This reverts commit d5dbf35c80.
2013-09-03 21:16:05 +02:00
Duncan Mak 3a91222d39 Change the version number to 3.2.3 2013-09-03 13:04:39 -04:00
Zoltan Varga 67b5d1d51f Add 'AM_PROG_CC_C_O' to configure to hopefully fix the build on older systems. 2013-09-03 18:31:46 +02:00
Marek Safar 1ea250fbd6 Merge pull request #749 from head-thrash/master
Fixes build when running `make -k check`
2013-09-03 08:21:09 -07:00
head-thrash 5f014934ae Fixes build when running make -k check:
* Fixes Broken Test in BuildEngine for 4.0 and 3.5
* Fixes build for Mono.Debugger.Soft not in 4_5 profile
* Fixes build for NET_4_0 profile (CustomAttributes and HasDefaultValue)
2013-09-03 18:52:29 +04:00
Martin Baulig c5e7004e98 Fix mobile build of my commit 1ae87e9. 2013-09-03 15:15:43 +02:00
Zoltan Varga 6cd4ddc089 Only print the 'Assuming PLATFORM messages when running make with V=1. 2013-09-03 10:36:21 +02:00
Zoltan Varga 43679b54e6 Fix warnings. 2013-09-03 10:36:21 +02:00
Alex Rønne Petersen 67db6fd702 Merge pull request #748 from spicypixel/hotfix/mini-codegen-disable-jit
Fix build break compiling with DISABLE_JIT
2013-09-02 23:40:59 -07:00
Aaron Oneal c25510b2b9 Fix build break compiling with DISABLE_JIT
When building with DISABLE_JIT, mono_inst_name which is normally defined in helpers.c is not. But, mini-codegen.c tries to use it anyway. This fix updates mini-codegen.c to not rely on this logging feature.
2013-09-02 22:45:35 -07:00
Martin Baulig d5dbf35c80 Fix typo in commit b6d634dd. 2013-09-02 21:56:52 +02:00
Marek Safar 4f64de335d Merge pull request #747 from spicypixel/hotfix/object-disable-com
Fix build break when COM is disabled
2013-09-02 12:53:43 -07:00
Martin Baulig 1ae87e9ee9 [WCF]: Add stubs for some missing .NET 4.0/4.5 APIs. 2013-09-02 21:52:13 +02:00
Martin Baulig 4db812ca7e Add missing .NET 4.5 APIs
* System.Text.RegularExpressions.Regex.InfiniteMatchTimeout
* System.Net.HttpStatusCode.UpgradeRequired
* Add System.Reflection.TypeAttributes.WindowsRuntime
* System.Runtime.GCLatencyMode.SustainedLowLatency
* System.UriComponents.NormalizedHost
2013-09-02 21:52:13 +02:00
Aaron Oneal edf74c2289 Fix build break when COM is disabled
This removes a typo that was introduced which caused COM dependencies to be referenced.
2013-09-02 10:53:06 -07:00
Marek Habersack 5178f29c4b Merge pull request #744 from echampet/bug-10001
Do not use chunked encoding with CGI/FastCGI
2013-09-02 08:39:57 -07:00
Stefan b6d634dd24 [FIX] Do not use chunked encoding with CGI/FastCGI
it's forbiden by http://tools.ietf.org/html/rfc3875#section-6.3.4

This correct bug 10001, https://bugzilla.xamarin.com/show_bug.cgi?id=10001

Signed-off-by: Etienne CHAMPETIER <[email protected]>
2013-09-02 17:30:14 +02:00
Marek Safar fb653dc0ea Better check for hoisted this location when emitting nested lambda expressions inside async containers. Fixes #14351 2013-09-01 14:49:01 +02:00
Zoltan Varga 36dc978682 Precompile the test assemblies in tests/ in parallel to speed up wrench test runs. 2013-08-30 22:00:59 +02:00
Zoltan Varga 9d714e77f4 Fix make check in tests/. 2013-08-30 22:00:59 +02:00
Zoltan Varga 2e5994b2ae Use AC_PROG_MKDIR_P instead of AM_PROG_MKDIR_P in m4/ since the latter is obsoleted by automake. 2013-08-30 22:00:59 +02:00
Zoltan Varga 63eeec0c81 Pass 'subdir-objects' to AM_INIT_AUTOMAKE() to quiet an automake warning. 2013-08-30 22:00:58 +02:00
Marek Safar 0e31ea67b7 More thorough check for managed type parameters. Fixes #14347 2013-08-30 17:48:59 +02:00
Marek Safar 17e5901d34 Probing of generic parameter for value type generic parameter needs to check both operands. Fixes #14289 2013-08-30 11:40:28 +02:00
Zoltan Varga 3dafb861ab Remove moon support from the build system. 2013-08-30 05:36:07 +02:00
Zoltan Varga ce263fe530 Disable the running of sgen tests on windows on wrench, they fail consistently. 2013-08-30 05:28:22 +02:00
Zoltan Varga cbe03c20e3 Check the cfg exception at the start of mono_method_to_ir (), to catch failures caused by mono_compile_create_var_for_vreg (). 2013-08-30 04:08:59 +02:00
Zoltan Varga c981bb9922 Fix warnings. 2013-08-30 04:08:04 +02:00
Zoltan Varga 82128fa503 Fix an LLVM assertion on structs with unaligned size. Fixes #14217. 2013-08-30 00:49:56 +02:00
Rodrigo Kumpera 9849c0a8fc Merge pull request #746 from madewokherd/sgenbuild
Fix non-sgen builds.
2013-08-29 14:46:17 -07:00
Vincent Povirk 226ebc4bef Fix non-sgen builds.
This commit licenced as MIT/X11.
2013-08-29 16:27:31 -05:00
Lluis Sanchez 9b5bc71e76 Fixed bug #14295 - Project.Load incorrectly resets the FullFileName property 2013-08-29 10:59:13 +02:00
Rodrigo Kumpera 18baa67f72 Fix some warning. 2013-08-28 16:14:53 -04:00
Rodrigo Kumpera a9b4ca9b36 [runtime]Don't assume MonoType extends directly from System.Type 2013-08-28 16:12:31 -04:00
Marek Safar fc522a49ed Fixes parameter name 2013-08-28 17:55:53 +02:00
Marek Safar 2f639b3c78 Use IReflectType interface instead of TypeDelegator for introspection type extensions. Fixes #14168 2013-08-28 17:55:53 +02:00
Marek Safar af31330de4 Make setProperties private 2013-08-28 10:18:26 +02:00
Marek Safar abe95222de Merge pull request #743 from gvillanueva/master
Rewrote Font.GetHashCode() to improve uniqueness
2013-08-28 01:15:59 -07:00
gvillanueva 234c346b81 Rewrote Font.GetHashCode() to improve uniqueness.
Added test cases to prevent reintroduction of collision scenarios observed in Font.GetHashCode().
2013-08-27 22:22:09 -07:00
Rodrigo Kumpera be400d4fc8 Naming cleanup. 2013-08-27 14:29:41 -04:00
Miguel de Icaza b08d9c20a1 Console.iOS: Reset sb.Length in all cases, even for poor man's print 2013-08-27 12:01:50 -04:00
Jérémie Laval 036ed3cc63 [System] Implement a first pass of ClientWebSocket. 2013-07-29 00:47:12 -04:00
Jérémie Laval 96935b19e1 [System] Add crude (for now) socket stealing of an HttpWebRequest.
HttpWebRequest is a very tricky piece of code when it comes to its socket, this patch is more like a hack to get something working out of it but it's definitely not the best option.
2013-07-29 00:47:11 -04:00
Jérémie Laval ee7a497ed4 [System] Don't overwrite custom Connection header on HttpWebRequest 2013-07-29 00:47:11 -04:00
Jonathan Gagnon 05d7064c1c GetIdElement must look for "ID" and "id". Fixes #4938 2013-07-12 14:48:55 -04:00
Robin Neatherway c26a40eef7 Fix Bug 4811, xbuild should find xml documentation 2013-07-02 17:26:15 +01:00
Tom Philpot aeed8baa68 Take shared file lock before collecting file share_info. 2013-06-06 22:08:38 -07:00
Vincent Povirk 3a44c65b03 Ignore the gdiplus dllmap on Windows. 2013-03-02 13:54:47 -06:00
David Straw 14b42141c0 Handle multiple concurrent calls to BeginTryReceiveRequest 2012-09-17 11:39:30 -06:00
Jonathan Chambers 12085044cd Use getpid instead of GetCurrentProcessId as the latter calls into io-layer which is not initialzed at this point. 2012-04-16 09:48:54 -04:00
Peter Collingbourne 6c620c74f3 X11: improve handling of WS_EX_TOPMOST
Currently, WS_EX_TOPMOST is handled by making the window transient-for
the root window.  I was unable to find any documentation that indicated
that this would have the desired effect.  Instead, use SetTopmost to
set _NET_WM_STATE to _NET_WM_STATE_ABOVE, per EWMH.

Also, use XMapRaised to raise topmost windows to the top of the stack
when mapped, as a last ditch effort to support window managers that
do not respect _NET_WM_STATE, such as xmonad.

This fixes an issue I encountered when running a winforms application
in xmonad, whereby drop down menus would fail to re-open if windows
had been re-arranged after the menu was first opened (in reality,
the menu was hiding behind the form).
2012-04-09 02:22:37 +01:00
Peter Collingbourne 2f04977242 Cause MenuDeactivate event to be delivered when appropriate
This is achieved by moving the FireMenuDeactivate call to
MenuStrip.Dismiss and causing it to be called in a couple of places
where it ought to be.
2012-04-02 05:52:21 +01:00
22566 changed files with 1926077 additions and 1717528 deletions

No files matched your search

+1 -1
View File
@@ -1,5 +1,5 @@
# ensure LF endings on all checkouts
configure.in crlf=input
configure.ac crlf=input
# ensure native line endings on checkout
*.c crlf
+10 -3
View File
@@ -23,7 +23,6 @@
*.tlb
*.tlh
*.bak
*.[Cc]ache
*.ilk
*.log
*.lib
@@ -44,6 +43,8 @@ Ankh.NoLoad
_ReSharper*/
*.resharper
[Tt]est[Rr]esult*
*.orig
*.rej
# NuGet packages
!.nuget/*
@@ -69,6 +70,7 @@ config.status
config.sub
configure
configure.scan
cygconfig.h
depcomp
install-sh
libtool
@@ -79,6 +81,7 @@ releases
stamp-h
stamp-h1
stamp-h.in
/test-driver
*~
*.swp
*.o
@@ -107,15 +110,19 @@ GRTAGS
GSYMS
GTAGS
# Doxygen
docs/doxygen*
docs/perlmod*
##############################################################################
# Mono-specific patterns
##############################################################################
.dirstamp
compile
mono.h
mono-*.tar.*
mono.spec
mono-core.spec
tmpinst-dir.stamp
msvc/scripts/inputs/
+14 -6
View File
@@ -10,15 +10,23 @@
[submodule "external/debian-snapshot"]
path = external/debian-snapshot
url = git://github.com/directhex/mono-snapshot.git
[submodule "external/entityframework"]
path = external/entityframework
url = git://github.com/mono/entityframework.git
[submodule "external/rx"]
path = external/rx
url = git://github.com/mono/rx.git
branch = rx-oss-v2.2
[submodule "external/ikvm"]
path = external/ikvm
url = git://github.com/mono/ikvm-fork.git
[submodule "external/Lucene.Net"]
path = external/Lucene.Net
url = git://github.com/mono/lucene.net.git
[submodule "external/ikdasm"]
path = external/ikdasm
url = git://github.com/mono/ikdasm.git
[submodule "external/referencesource"]
path = external/referencesource
url = git://github.com/mono/referencesource
branch = mono
[submodule "external/reference-assemblies"]
path = external/binary-reference-assemblies
url = git://github.com/mono/reference-assemblies.git
[submodule "external/Lucene.Net.Light"]
path = external/Lucene.Net.Light
url = git://github.com/mono/Lucene.Net.Light.git
-3
View File
@@ -1,3 +0,0 @@
Miguel de Icaza ([email protected])
Paolo Molaro ([email protected])
Dietmar Maurer ([email protected])
+47 -12
View File
@@ -1,4 +1,3 @@
Guidelines
==========
@@ -6,7 +5,7 @@ When contributing to the Mono project, please follow the [Mono Coding
Guidelines][1]. We have been using a coding style for many years,
please make your patches conform to these guidelines.
[1] http://www.mono-project.com/Coding_Guidelines
[1]: http://www.mono-project.com/community/contributing/coding-guidelines/
Etiquette
=========
@@ -32,18 +31,54 @@ file in this directory.
When contributing code, make sure that your contribution falls under
the appropriate license. For example, contributions to code licensed
under MIT X11 code, should be MIT X11 code.
under MIT/X11 code, should be MIT/X11 code.
The Runtime is a special case. The code is dual licensed by Xamarin
under both the GNU LGPL v2 license and is also available under
commercial terms. For the runtime, you should either sign an
The runtime (`mono/...`) is a special case. The code is dual-licensed
by Xamarin under both the GNU LGPL v2 license and is also available
under commercial terms. For the runtime, you should either sign an
agreement that grants Xamarin the rights to relicense your code under
other licenses other than the LGPL v2 or your contribution must be
made as an MIT X11 license which grants us the same rights, but
involves no paperwork.
made as an MIT/X11 license which grants us the same rights, but
involves no paperwork. For the latter case, please specify on your
commit(s) that you are licensing the changes under MIT/X11.
Submitting Patches
==================
For other parts of the project that are dual-licensed, please state
on your commit(s) what license you are contributing the changes under.
When Submitting patches to the dual-licensed portions, please specify
on the commit the license that the code is under.
Testing
=======
Pull requests go through testing on our [Jenkins server][2]. We will
usually only merge a pull request if it causes no regressions in a
test run there.
When you submit a pull request, one of two things happens:
* If you are a new contributor, Jenkins will ask for permissions (on
the pull request) to test it. A maintainer will reply to approve
the test run if they find the patch appropriate. After you have
submitted a few patches, a maintainer will whitelist you so that
all of your future pull requests are tested automatically.
* If you are a well-known, whitelisted contributor, Jenkins will go
ahead and test your pull request as soon as a test machine is
available.
When your pull request has been built, Jenkins will update the build
status of your pull request. If it succeeded and we like the changes,
a maintainer will likely merge it. Otherwise, you can amend your pull
request to fix build breakage and Jenkins will test it again.
[2]: http://jenkins.mono-project.com/
# Inactivity
Occasionally, a pull request sits for several months without any
response from the author. This isn't necessarily an issue, but we may
sometimes decide to close pull requests that have not seen any
progress for a long time. This is in interest of keeping the pull
request list clean so that other pull requests don't get lost in the
clutter.
If we do close your pull request due to inactivity, you're more than
welcome to submit it anew after you address any comments or issues that
were brought up on the original pull request.
+2 -9
View File
@@ -8,8 +8,8 @@ For comments, corrections and updates, please contact [email protected]
Parts of Mono are dual licensed, they are available to the
public in GPL or LGPL forms, but we also offer those pieces
under commercial terms from Xamarin for the cases wher the GPL
and the LGPL are not suitable.
under commercial terms from Xamarin for the cases where the
GPL and the LGPL are not suitable.
We have tried to pick the licenses that will maximize adoption
of Mono, so we tend to use the MIT X11 or LGPL liceses.
@@ -64,13 +64,6 @@ For comments, corrections and updates, please contact [email protected]
the terms of the MIT X11, this means that this code can be
used for any purposes by anyone.
** mono/metadata/sgen*: Mono's Copying Collector
This new garbage collector is licensed under the terms of
the MIT X11 license, in hopes that the GC could be reused
by third party projects, follows the same spirit than the
Boehm GC.
** mono/arch/*/XXX-codegen.h
This are C macros that are useful when generating native
+18 -41
View File
@@ -1,26 +1,19 @@
ACLOCAL_AMFLAGS = -I m4
MOONLIGHT_SUBDIRS = $(libgc_dir) eglib/src mono
AM_CFLAGS = $(WERROR_CFLAGS)
MONOTOUCH_SUBDIRS = $(libgc_dir) eglib/src mono
if CROSS_COMPILING
SUBDIRS = po $(libgc_dir) eglib mono $(ikvm_native_dir) data runtime scripts man samples msvc $(docs_dir)
SUBDIRS = po $(libgc_dir) eglib mono $(ikvm_native_dir) support data runtime scripts man samples msvc $(docs_dir)
# Keep in sync with SUBDIRS
## 'tools' is not normally built
DIST_SUBDIRS = m4 po libgc eglib mono ikvm-native data runtime scripts man samples tools msvc docs
else
if ONLY_MONOTOUCH
SUBDIRS = $(MONOTOUCH_SUBDIRS) runtime
else
if ONLY_MOONLIGHT
SUBDIRS = $(MOONLIGHT_SUBDIRS) runtime
DIST_SUBDIRS = m4 po $(libgc_dir) eglib mono ikvm-native support data runtime scripts man samples tools msvc docs
else
SUBDIRS = po $(libgc_dir) eglib mono $(ikvm_native_dir) support data runtime scripts man samples msvc $(docs_dir)
# Keep in sync with SUBDIRS
## 'tools' is not normally built
DIST_SUBDIRS = m4 po libgc eglib mono ikvm-native support data runtime scripts man samples tools msvc docs
endif
endif
DIST_SUBDIRS = m4 po $(libgc_dir) eglib mono ikvm-native support data runtime scripts man samples tools msvc docs
endif
all: update_submodules
@@ -32,13 +25,12 @@ update_submodules:
.PHONY: update_submodules
EXTRA_DIST= \
README.md \
LICENSE \
autogen.sh \
build-mingw32.sh \
mkinstalldirs \
mono-uninstalled.pc.in \
winconfig.h \
mono-core.spec \
external
DISTCHECK_CONFIGURE_FLAGS = EXTERNAL_MCS=false EXTERNAL_RUNTIME=false
@@ -48,7 +40,11 @@ GIT_DIR ?= $(srcdir)/.git
dist-hook:
test -d $(distdir)/mcs || mkdir $(distdir)/mcs
d=`cd $(distdir)/mcs && pwd`; cd $(mcs_topdir) && $(MAKE) distdir=$$d dist-recursive
rm -rf `find $(top_distdir)/external -path '*\.git' -and -type d`
rm -rf `find $(top_distdir)/external -path '*\.git'`
rm -f `find $(top_distdir)/external -path '*\.exe'`
rm -f `find $(top_distdir)/external -path '*\.dll' -not -path '*/binary-reference-assemblies/*'`
cp mcs/class/lib/basic/System.Configuration.dll mcs/class/lib/monolite/
cp mcs/class/lib/basic/System.Security.dll mcs/class/lib/monolite/
# Disable this for now because it is very slow and causes wrench to timeout:
# test ! -d $(GIT_DIR) || ./scripts/commits-to-changelog.py --root=$(distdir) last-commit-with-compulsory-changelog-entry
@@ -60,7 +56,7 @@ DISTCLEANFILES= mono-uninstalled.pc
mcslib = $(mcs_topdir)/class/lib
monolite = $(mcslib)/monolite
mono_corlib_version = $(shell sed -n "s/\#define MONO_CORLIB_VERSION //p" $(srcdir)/mono/metadata/appdomain.c)
monolite_url = http://storage.bos.xamarin.com/mono-dist-master/latest/monolite-$(mono_corlib_version)-latest.tar.gz
monolite_url = http://download.mono-project.com/monolite/monolite-$(mono_corlib_version)-latest.tar.gz
.PHONY: get-monolite-latest
get-monolite-latest:
-rm -fr $(mcslib)/monolite-*
@@ -92,31 +88,6 @@ mcs-do-compiler-tests:
bootstrap-world: compiler-tests
$(MAKE) install
if MOONLIGHT
moon-do-build: config.h
@list='$(MOONLIGHT_SUBDIRS)'; for subdir in $$list; do \
case "x$$subdir" in \
xmono ) target="moon-do-build";; \
* ) target="all";; \
esac; \
echo "Making $$target in $$subdir"; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$target); \
done;
(cd runtime && $(MAKE) $(AM_MAKEFLAGS) moon-do-build)
moon-do-clean:
@list='$(MOONLIGHT_SUBDIRS)'; for subdir in $$list; do \
case "x$$subdir" in \
xmono ) target="moon-do-clean";; \
* ) target="clean";; \
esac; \
echo "Making $$target in $$subdir"; \
(cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$target); \
done;
(cd runtime && $(MAKE) $(AM_MAKEFLAGS) moon-do-clean)
endif
if INSTALL_MONOTOUCH
monotouch-do-build: config.h
@list='$(MONOTOUCH_SUBDIRS)'; for subdir in $$list; do \
@@ -185,3 +156,9 @@ package-inputs:
done
echo "</root>" >> msvc/scripts/order.xml
# Update llvm version in configure.ac to the output of $LLVM_DIR/bin/llvm-config --version
update-llvm-version:
if test "x$$LLVM_DIR" = "x"; then echo "Set the make variable LLVM_DIR to the directory containing the LLVM installation."; exit 1; fi
REV=`$(LLVM_DIR)/bin/llvm-config --version` && sed -e "s,expected_llvm_version=.*,expected_llvm_version=\"$$REV\"," < configure.ac > tmp && mv tmp configure.ac && echo "Version set to $$REV."
+1 -6
View File
@@ -1,8 +1,3 @@
Release notes for Mono are hosted on the web, please see:
http://www.go-mono.com/archive/VERSION
Where version is the version of this Mono package, for example:
http://www.go-mono.com/archive/1.1.9
http://www.mono-project.com/docs/about-mono/releases/
-592
View File
@@ -1,592 +0,0 @@
This is Mono.
1. Installation
2. Using Mono
3. Directory Roadmap
4. git submodules maintenance
1. Compilation and Installation
===============================
a. Build Requirements
---------------------
On Itanium, you must obtain libunwind:
http://www.hpl.hp.com/research/linux/libunwind/download.php4
On Solaris, make sure that you used GNU tar to unpack this package, as
Solaris tar will not unpack this correctly, and you will get strange errors.
On Solaris, make sure that you use the GNU toolchain to build the software.
Optional dependencies:
* libgdiplus
If you want to get support for System.Drawing, you will need to get
Libgdiplus. This library in turn requires glib and pkg-config:
* pkg-config
Available from: http://www.freedesktop.org/Software/pkgconfig
* glib 2.4
Available from: http://www.gtk.org/
* libzlib
This library and the development headers are required for compression
file support in the 2.0 profile.
b. Building the Software
------------------------
If you obtained this package as an officially released tarball,
this is very simple, use configure and make:
./configure --prefix=/usr/local
make
make install
Mono supports a JIT engine on x86, SPARC, SPARCv9, S/390,
S/390x, AMD64, ARM and PowerPC systems.
If you obtained this as a snapshot, you will need an existing
Mono installation. To upgrade your installation, unpack both
mono and mcs:
tar xzf mcs-XXXX.tar.gz
tar xzf mono-XXXX.tar.gz
mv mono-XXX mono
mv mcs-XXX mcs
cd mono
./autogen.sh --prefix=/usr/local
make
The Mono build system is silent for most compilation commands.
To enable a more verbose compile (for example, to pinpoint
problems in your makefiles or your system) pass the V=1 flag to make, like this:
make V=1
c. Building the software from GIT
---------------------------------
If you are building the software from GIT, make sure that you
have up-to-date mcs and mono sources:
If you are an anonymous user:
git clone git://github.com/mono/mono.git
If you are a Mono contributors with read/write privileges:
git clone [email protected]:mono/mono.git
Then, go into the mono directory, and configure:
cd mono
./autogen.sh --prefix=/usr/local
make
For people with non-standard installations of the auto* utils and of
pkg-config (common on misconfigured OSX and windows boxes), you could get
an error like this:
./configure: line 19176: syntax error near unexpected token `PKG_CHECK_MODULES(BASE_DEPENDENCIES,' ...
This means that you need to set the ACLOCAL_FLAGS environment var
when invoking autogen.sh, like this:
ACLOCAL_FLAGS="-I $acprefix/share/aclocal" ./autogen.sh --prefix=/usr/loca
where $acprefix is the prefix where aclocal has been installed.
This will automatically go into the mcs/ tree and build the
binaries there.
This assumes that you have a working mono installation, and that
there's a C# compiler named 'mcs', and a corresponding IL
runtime called 'mono'. You can use two make variables
EXTERNAL_MCS and EXTERNAL_RUNTIME to override these. e.g., you
can say
make EXTERNAL_MCS=/foo/bar/mcs EXTERNAL_RUNTIME=/somewhere/else/mono
If you don't have a working Mono installation
---------------------------------------------
If you don't have a working Mono installation, an obvious choice
is to install the latest released packages of 'mono' for your
distribution and running autogen.sh; make; make install in the
mono module directory.
You can also try a slightly more risky approach: this may not work,
so start from the released tarball as detailed above.
This works by first getting the latest version of the 'monolite'
distribution, which contains just enough to run the 'mcs'
compiler. You do this with:
# Run the following line after ./autogen.sh
make get-monolite-latest
This will download and automatically gunzip and untar the
tarball, and place the files appropriately so that you can then
just run:
make EXTERNAL_MCS=${PWD}/mcs/class/lib/monolite/gmcs.exe
And that will use the files downloaded by 'make get-monolite-latest.
Testing and Installation
------------------------
You can run (part of) the mono and mcs testsuites with the command:
make check
All tests should pass.
If you want more extensive tests, including those that test the
class libraries, you need to re-run 'configure' with the
'--enable-nunit-tests' flag, and try
make -k check
Expect to find a few testsuite failures. As a sanity check, you
can compare the failures you got with
https://wrench.mono-project.com/Wrench/
You can now install mono with:
make install
You can verify your installation by using the mono-test-install
script, it can diagnose some common problems with Mono's install.
Failure to follow these steps may result in a broken installation.
d. Configuration Options
------------------------
The following are the configuration options that someone
building Mono might want to use:
--with-sgen=yes,no
Generational GC support: Used to enable or disable the
compilation of a Mono runtime with the SGen garbage collector.
On platforms that support it, after building Mono, you
will have both a mono binary and a mono-sgen binary.
Mono uses Boehm, while mono-sgen uses the Simple
Generational GC.
--with-gc=[boehm, included, sgen, none]
Selects the default Boehm garbage collector engine to
use, the default is the "included" value.
included:
This is the default value, and its
the most feature complete, it will allow Mono
to use typed allocations and support the
debugger.
It is essentially a slightly modified Boehm GC
boehm:
This is used to use a system-install Boehm GC,
it is useful to test new features available in
Boehm GC, but we do not recommend that people
use this, as it disables a few features.
none:
Disables the inclusion of a garbage
collector.
--with-tls=__thread,pthread
Controls how Mono should access thread local storage,
pthread forces Mono to use the pthread APIs, while
__thread uses compiler-optimized access to it.
Although __thread is faster, it requires support from
the compiler, kernel and libc. Old Linux systems do
not support with __thread.
This value is typically pre-configured and there is no
need to set it, unless you are trying to debug a
problem.
--with-sigaltstack=yes,no
Experimental: Use at your own risk, it is known to
cause problems with garbage collection and is hard to
reproduce those bugs.
This controls whether Mono will install a special
signal handler to handle stack overflows. If set to
"yes", it will turn stack overflows into the
StackOverflowException. Otherwise when a stack
overflow happens, your program will receive a
segmentation fault.
The configure script will try to detect if your
operating system supports this. Some older Linux
systems do not support this feature, or you might want
to override the auto-detection.
--with-static_mono=yes,no
This controls whether `mono' should link against a
static library (libmono.a) or a shared library
(libmono.so).
This defaults to yes, and will improve the performance
of the `mono' program.
This only affects the `mono' binary, the shared
library libmono.so will always be produced for
developers that want to embed the runtime in their
application.
--with-xen-opt=yes,no
The default value for this is `yes', and it makes Mono
generate code which might be slightly slower on
average systems, but the resulting executable will run
faster under the Xen virtualization system.
--with-large-heap=yes,no
Enable support for GC heaps larger than 3GB.
This value is set to `no' by default.
--enable-small-config=yes,no
Enable some tweaks to reduce memory usage and disk footprint at
the expense of some capabilities. Typically this means that the
number of threads that can be created is limited (256), that the
maxmimum heap size is also reduced (256 MB) and other such limitations
that still make mono useful, but more suitable to embedded devices
(like mobile phones).
This value is set to `no' by default.
--with-ikvm-native=yes,no
Controls whether the IKVM JNI interface library is
built or not. This is used if you are planning on
using the IKVM Java Virtual machine with Mono.
This defaults to `yes'.
--with-profile4=yes,no
Whether you want to build the 4.x profile libraries
and runtime.
It defaults to `yes'.
--with-moonlight=yes,no
Whether you want to generate the Silverlight/Moonlight
libraries and toolchain in addition to the default
(1.1 and 2.0 APIs).
This will produce the `smcs' compiler which will reference
the Silverlight modified assemblies (mscorlib.dll,
System.dll, System.Code.dll and System.Xml.Core.dll) and turn
on the LINQ extensions for the compiler.
--with-moon-gc=boehm,sgen
Select the GC to use for Moonlight.
boehm:
Selects the Boehm Garbage Collector, with the same flags
as the regular Mono build. This is the default.
sgen:
Selects the new SGen Garbage Collector, which provides
Generational GC support, using the same flags as the
mono-sgen build.
This defaults to `boehm'.
--with-libgdiplus=installed,sibling,<path>
This is used to configure where should Mono look for
libgdiplus when running the System.Drawing tests.
It defaults to `installed', which means that the
library is available to Mono through the regular
system setup.
`sibling' can be used to specify that a libgdiplus
that resides as a sibling of this directory (mono)
should be used.
Or you can specify a path to a libgdiplus.
--disable-shared-memory
Use this option to disable the use of shared memory in
Mono (this is equivalent to setting the MONO_DISABLE_SHM
environment variable, although this removes the feature
completely).
Disabling the shared memory support will disable certain
features like cross-process named mutexes.
--enable-minimal=LIST
Use this feature to specify optional runtime
components that you might not want to include. This
is only useful for developers embedding Mono that
require a subset of Mono functionality.
The list is a comma-separated list of components that
should be removed, these are:
aot:
Disables support for the Ahead of Time
compilation.
attach:
Support for the Mono.Management assembly and the
VMAttach API (allowing code to be injected into
a target VM)
com:
Disables COM support.
debug:
Drop debugging support.
decimal:
Disables support for System.Decimal.
full_messages:
By default Mono comes with a full table
of messages for error codes. This feature
turns off uncommon error messages and reduces
the runtime size.
generics:
Generics support. Disabling this will not
allow Mono to run any 2.0 libraries or
code that contains generics.
jit:
Removes the JIT engine from the build, this reduces
the executable size, and requires that all code
executed by the virtual machine be compiled with
Full AOT before execution.
large_code:
Disables support for large assemblies.
logging:
Disables support for debug logging.
pinvoke:
Support for Platform Invocation services,
disabling this will drop support for any
libraries using DllImport.
portability:
Removes support for MONO_IOMAP, the environment
variables for simplifying porting applications that
are case-insensitive and that mix the Unix and Windows path separators.
profiler:
Disables support for the default profiler.
reflection_emit:
Drop System.Reflection.Emit support
reflection_emit_save:
Drop support for saving dynamically created
assemblies (AssemblyBuilderAccess.Save) in
System.Reflection.Emit.
shadow_copy:
Disables support for AppDomain's shadow copies
(you can disable this if you do not plan on
using appdomains).
simd:
Disables support for the Mono.SIMD intrinsics
library.
ssa:
Disables compilation for the SSA optimization
framework, and the various SSA-based
optimizations.
--enable-llvm
--enable-loadedllvm
This enables the use of LLVM as a code generation engine
for Mono. The LLVM code generator and optimizer will be
used instead of Mono's built-in code generator for both
Just in Time and Ahead of Time compilations.
See the http://www.mono-project.com/Mono_LLVM for the
full details and up-to-date information on this feature.
You will need to have an LLVM built that Mono can link
against,
The --enable-loadedllvm variant will make the llvm backend
into a runtime-loadable module instead of linking it directly
into the main mono binary.
--enable-big-arrays
This enables the use arrays whose indexes are larger
than Int32.MaxValue.
By default Mono has the same limitation as .NET on
Win32 and Win64 and limits array indexes to 32-bit
values (even on 64-bit systems).
In certain scenarios where large arrays are required,
you can pass this flag and Mono will be built to
support 64-bit arrays.
This is not the default as it breaks the C embedding
ABI that we have exposed through the Mono development
cycle.
--enable-parallel-mark
Use this option to enable the garbage collector to use
multiple CPUs to do its work. This helps performance
on multi-CPU machines as the work is divided across CPUS.
This option is not currently the default as we have
not done much testing with Mono.
--enable-dtrace
On Solaris and MacOS X builds a version of the Mono
runtime that contains DTrace probes and can
participate in the system profiling using DTrace.
--disable-dev-random
Mono uses /dev/random to obtain good random data for
any source that requires random numbers. If your
system does not support this, you might want to
disable it.
There are a number of runtime options to control this
also, see the man page.
--enable-nacl
This configures the Mono compiler to generate code
suitable to be used by Google's Native Client:
http://code.google.com/p/nativeclient/
Currently this is used with Mono's AOT engine as
Native Client does not support JIT engines yet.
2. Using Mono
=============
Once you have installed the software, you can run a few programs:
* runtime engine
mono program.exe
* C# compiler
mcs program.cs
* CIL Disassembler
monodis program.exe
See the man pages for mono(1), mint(1), monodis(1) and mcs(2)
for further details.
3. Directory Roadmap
====================
docs/
Technical documents about the Mono runtime.
data/
Configuration files installed as part of the Mono runtime.
mono/
The core of the Mono Runtime.
metadata/
The object system and metadata reader.
mini/
The Just in Time Compiler.
dis/
CIL executable Disassembler
cli/
Common code for the JIT and the interpreter.
io-layer/
The I/O layer and system abstraction for
emulating the .NET IO model.
cil/
Common Intermediate Representation, XML
definition of the CIL bytecodes.
interp/
Interpreter for CLI executables (obsolete).
arch/
Architecture specific portions.
man/
Manual pages for the various Mono commands and programs.
samples/
Some simple sample programs on uses of the Mono
runtime as an embedded library.
scripts/
Scripts used to invoke Mono and the corresponding program.
runtime/
A directory that contains the Makefiles that link the
mono/ and mcs/ build systems.
../olive/
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.
4. Git submodules maintenance
=============================
Read documentation at http://mono-project.com/Git_Submodule_Maintenance
+499
View File
@@ -0,0 +1,499 @@
Mono is a software platform designed to allow developers to easily
create cross platform applications. It is an open source
implementation of Microsoft's .NET Framework based on the ECMA
standards for C# and the Common Language Runtime.
[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/mono/mono?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
1. [Compilation and Installation](#compilation-and-installation)
2. [Using Mono](#using-mono)
3. [Directory Roadmap](#directory-roadmap)
4. [Contributing to Mono](#contributing-to-mono)
5. [Reporting bugs](#reporting-bugs)
6. [Configuration Options](#configuration-options)
7. [Working with Submodules](#working-with-submodules)
**Build Status**
Officially supported architectures:
| debian-amd64 | debian-i386 | debian-armel | debian-armhf | windows-amd64 |
|-------------------------|------------------------|-------------------------|-------------------------|---------------------------|
| [![debian-amd64][1]][2] | [![debian-i386][3]][4] | [![debian-armel][5]][6] | [![debian-armhf][7]][8] | [![windows-amd64][9]][10] |
Community supported architectures:
| centos-s390x |
|---------------------------|
| [![centos-s390x][11]][12] |
[1]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-amd64/badge/icon
[2]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-amd64/
[3]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-i386/badge/icon
[4]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-i386/
[5]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armel/badge/icon
[6]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armel/
[7]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armhf/badge/icon
[8]: http://jenkins.mono-project.com/job/test-mono-mainline/label=debian-armhf/
[9]: https://ci.appveyor.com/api/projects/status/1e61ebdfpbiei58v/branch/master?svg=true
[10]: https://ci.appveyor.com/project/ajlennon/mono-817/branch/master
[11]: http://jenkins.mono-project.com/job/test-mono-mainline-communityarchitectures/label=nealef-s390x-1/badge/icon
[12]: http://jenkins.mono-project.com/job/test-mono-mainline-communityarchitectures/label=nealef-s390x-1/
Compilation and Installation
============================
Building the Software
---------------------
Please see our guides for building Mono on
[Mac OS X](http://www.mono-project.com/docs/compiling-mono/mac/),
[Linux](http://www.mono-project.com/docs/compiling-mono/linux/) and
[Windows](http://www.mono-project.com/docs/compiling-mono/windows/).
Note that building from Git assumes that you already have Mono installed,
so please download and [install the latest Mono release](http://www.mono-project.com/download/)
before trying to build from Git. This is required because the Mono build
relies on a working Mono C# compiler to compile itself
(also known as [bootstrapping](http://en.wikipedia.org/wiki/Bootstrapping_(compilers))).
If you don't have a working Mono installation
---------------------------------------------
If you don't have a working Mono installation, you can try a slightly
more risky approach: getting the latest version of the 'monolite' distribution,
which contains just enough to run the 'mcs' compiler. You do this with:
# Run the following line after ./autogen.sh
make get-monolite-latest
This will download and place the files appropriately so that you can then
just run:
make
The build will then use the files downloaded by `make get-monolite-latest`.
Testing and Installation
------------------------
You can run the mono and mcs test suites with the command: `make check`.
Expect to find a few test suite failures. As a sanity check, you
can compare the failures you got with [https://wrench.mono-project.com/Wrench/](https://wrench.mono-project.com/Wrench/)
and [http://jenkins.mono-project.com/](http://jenkins.mono-project.com/).
You can now install mono with: `make install`
You can verify your installation by using the mono-test-install
script, it can diagnose some common problems with Mono's install.
Failure to follow these steps may result in a broken installation.
Using Mono
==========
Once you have installed the software, you can run a few programs:
* `mono program.exe` runtime engine
* `mcs program.cs` C# compiler
* `monodis program.exe` CIL Disassembler
See the man pages for mono(1), mcs(1) and monodis(1) for further details.
Directory Roadmap
=================
* `data/` - Configuration files installed as part of the Mono runtime.
* `docs/` - Technical documents about the Mono runtime.
* `external/` - Git submodules for external libraries (Newtonsoft.Json, ikvm, etc).
* `man/` - Manual pages for the various Mono commands and programs.
* `mcs/` - The class libraries, compiler and tools
* `class/` - The class libraries (like System.*, Microsoft.Build, etc.)
* `mcs/` - The Mono C# compiler written in C#
* `tools/` - Tools like gacutil, ikdasm, mdoc, etc.
* `mono/` - The core of the Mono Runtime.
* `arch/` - Architecture specific portions.
* `cil/` - Common Intermediate Representation, XML
definition of the CIL bytecodes.
* `dis/` - CIL executable Disassembler
* `io-layer/` - The I/O layer and system abstraction for
emulating the .NET IO model.
* `metadata/` - The object system and metadata reader.
* `mini/` - The Just in Time Compiler.
* `runtime/` - A directory that contains the Makefiles that link the
mono/ and mcs/ build systems.
* `samples/` -Some simple sample programs on uses of the Mono
runtime as an embedded library.
* `scripts/` - Scripts used to invoke Mono and the corresponding program.
Contributing to Mono
====================
Before submitting changes to Mono, please review the [contribution
guidelines](http://www.mono-project.com/community/contributing/).
Please pay particular attention to the [Important
Rules](http://www.mono-project.com/community/contributing/#important-rules)
section.
Reporting bugs
==============
To submit bug reports, please use [Xamarin's
Bugzilla](https://bugzilla.xamarin.com/)
Please use the search facility to ensure the same bug hasn't already
been submitted and follow our
[guidelines](http://www.mono-project.com/community/bugs/make-a-good-bug-report/)
on how to make a good bug report.
Configuration Options
=====================
The following are the configuration options that someone building Mono
might want to use:
* `--with-sgen=yes,no` - Generational GC support: Used to enable or
disable the compilation of a Mono runtime with the SGen garbage
collector.
* On platforms that support it, after building Mono, you will have
both a `mono` binary and a `mono-sgen` binary. `mono` uses Boehm,
while `mono-sgen` uses the Simple Generational GC.
* `--with-gc=[included, boehm, none]` - Selects the default Boehm
garbage collector engine to use.
* *included*: (*slighty modified Boehm GC*) This is the default
value for the Boehm GC, and it's the most feature complete, it will
allow Mono to use typed allocations and support the debugger.
* *boehm*: This is used to use a system-install Boehm GC, it is
useful to test new features available in Boehm GC, but we do not
recommend that people use this, as it disables a few features.
* *none*:
Disables the inclusion of a garbage collector.
* This defaults to `included`.
* `--with-tls=__thread,pthread`
* Controls how Mono should access thread local storage,
pthread forces Mono to use the pthread APIs, while
__thread uses compiler-optimized access to it.
* Although __thread is faster, it requires support from
the compiler, kernel and libc. Old Linux systems do
not support with __thread.
* This value is typically pre-configured and there is no
need to set it, unless you are trying to debug a problem.
* `--with-sigaltstack=yes,no`
* **Experimental**: Use at your own risk, it is known to
cause problems with garbage collection and is hard to
reproduce those bugs.
* This controls whether Mono will install a special
signal handler to handle stack overflows. If set to
`yes`, it will turn stack overflows into the
StackOverflowException. Otherwise when a stack
overflow happens, your program will receive a
segmentation fault.
* The configure script will try to detect if your
operating system supports this. Some older Linux
systems do not support this feature, or you might want
to override the auto-detection.
* `--with-static_mono=yes,no`
* This controls whether `mono` should link against a
static library (libmono.a) or a shared library
(libmono.so).
* This defaults to `yes`, and will improve the performance
of the `mono` program.
* This only affects the `mono' binary, the shared
library libmono.so will always be produced for
developers that want to embed the runtime in their
application.
* `--with-xen-opt=yes,no` - Optimize code for Xen virtualization.
* It makes Mono generate code which might be slightly
slower on average systems, but the resulting executable will run
faster under the Xen virtualization system.
* This defaults to `yes`.
* `--with-large-heap=yes,no` - Enable support for GC heaps larger than 3GB.
* This defaults to `no`.
* `--enable-small-config=yes,no` - Enable some tweaks to reduce memory usage
and disk footprint at the expense of some capabilities.
* Typically this means that the number of threads that can be created
is limited (256), that the maximum heap size is also reduced (256 MB)
and other such limitations that still make mono useful, but more suitable
to embedded devices (like mobile phones).
* This defaults to `no`.
* `--with-ikvm-native=yes,no` - Controls whether the IKVM JNI interface library is
built or not.
* This is used if you are planning on
using the IKVM Java Virtual machine with Mono.
* This defaults to `yes`.
* `--with-profile4=yes,no` - Whether you want to build the 4.x profile libraries
and runtime.
* This defaults to `yes`.
* `--with-libgdiplus=installed,sibling,<path>` - Configure where Mono
searches for libgdiplus when running System.Drawing tests.
* It defaults to `installed`, which means that the
library is available to Mono through the regular
system setup.
* `sibling` can be used to specify that a libgdiplus
that resides as a sibling of this directory (mono)
should be used.
* Or you can specify a path to a libgdiplus.
* `--disable-shared-memory`
* Use this option to disable the use of shared memory in
Mono (this is equivalent to setting the MONO_DISABLE_SHM
environment variable, although this removes the feature
completely).
* Disabling the shared memory support will disable certain
features like cross-process named mutexes.
* `--enable-minimal=LIST`
* Use this feature to specify optional runtime
components that you might not want to include. This
is only useful for developers embedding Mono that
require a subset of Mono functionality.
* The list is a comma-separated list of components that
should be removed, these are:
* `aot`:
Disables support for the Ahead of Time compilation.
* `attach`:
Support for the Mono.Management assembly and the
VMAttach API (allowing code to be injected into
a target VM)
* `com`:
Disables COM support.
* `debug`:
Drop debugging support.
* `decimal`:
Disables support for System.Decimal.
* `full_messages`:
By default Mono comes with a full table
of messages for error codes. This feature
turns off uncommon error messages and reduces
the runtime size.
* `generics`:
Generics support. Disabling this will not
allow Mono to run any 2.0 libraries or
code that contains generics.
* `jit`:
Removes the JIT engine from the build, this reduces
the executable size, and requires that all code
executed by the virtual machine be compiled with
Full AOT before execution.
* `large_code`:
Disables support for large assemblies.
* `logging`:
Disables support for debug logging.
* `pinvoke`:
Support for Platform Invocation services,
disabling this will drop support for any
libraries using DllImport.
* `portability`:
Removes support for MONO_IOMAP, the environment
variables for simplifying porting applications that
are case-insensitive and that mix the Unix and Windows path separators.
* `profiler`:
Disables support for the default profiler.
* `reflection_emit`:
Drop System.Reflection.Emit support
* `reflection_emit_save`:
Drop support for saving dynamically created
assemblies (AssemblyBuilderAccess.Save) in
System.Reflection.Emit.
* `shadow_copy`:
Disables support for AppDomain's shadow copies
(you can disable this if you do not plan on
using appdomains).
* `simd`:
Disables support for the Mono.SIMD intrinsics
library.
* `ssa`:
Disables compilation for the SSA optimization
framework, and the various SSA-based optimizations.
* `--enable-llvm`
* `--enable-loadedllvm`
* This enables the use of LLVM as a code generation engine
for Mono. The LLVM code generator and optimizer will be
used instead of Mono's built-in code generator for both
Just in Time and Ahead of Time compilations.
* See http://www.mono-project.com/docs/advanced/mono-llvm/ for the
full details and up-to-date information on this feature.
* You will need to have an LLVM built that Mono can link
against.
* The `--enable-loadedllvm` variant will make the LLVM backend
into a runtime-loadable module instead of linking it directly
into the main mono binary.
* `--enable-big-arrays` - Enable use of arrays with indexes larger
than Int32.MaxValue.
* By default Mono has the same limitation as .NET on
Win32 and Win64 and limits array indexes to 32-bit
values (even on 64-bit systems).
* In certain scenarios where large arrays are required,
you can pass this flag and Mono will be built to
support 64-bit arrays.
* This is not the default as it breaks the C embedding
ABI that we have exposed through the Mono development
cycle.
* `--enable-parallel-mark`
* Use this option to enable the garbage collector to use
multiple CPUs to do its work. This helps performance
on multi-CPU machines as the work is divided across CPUS.
* This option is not currently the default as we have
not done much testing with Mono.
* `--enable-dtrace`
* On Solaris and MacOS X builds a version of the Mono
runtime that contains DTrace probes and can
participate in the system profiling using DTrace.
* `--disable-dev-random`
* Mono uses /dev/random to obtain good random data for
any source that requires random numbers. If your
system does not support this, you might want to
disable it.
* There are a number of runtime options to control this
also, see the man page.
* `--enable-nacl`
* This configures the Mono compiler to generate code
suitable to be used by Google's Native Client:
http://code.google.com/p/nativeclient/
* Currently this is used with Mono's AOT engine as
Native Client does not support JIT engines yet.
Working With Submodules
=======================
Mono references several external git submodules, for example
a fork of Microsoft's reference source code that has been altered
to be suitable for use with the Mono runtime.
This section describes how to use it.
An initial clone should be done recursively so all submodules will also be
cloned in a single pass:
$ git clone --recursive git@github.com:mono/mono
Once cloned, submodules can be updated to pull down the latest changes.
This can also be done after an initial non-recursive clone:
$ git submodule update --init --recursive
To pull external changes into a submodule:
$ cd <submodule>
$ git pull origin <branch>
$ cd <top-level>
$ git add <submodule>
$ git commit
By default, submodules are detached because they point to a specific commit.
Use `git checkout` to move back to a branch before making changes:
$ cd <submodule>
$ git checkout <branch>
# work as normal; the submodule is a normal repo
$ git commit/push new changes to the repo (submodule)
$ cd <top-level>
$ git add <submodule> # this will record the new commits to the submodule
$ git commit
To switch the repo of a submodule (this should not be a common or normal thing
to do at all), first edit `.gitmodules` to point to the new location, then:
$ git submodule sync -- <path of the submodule>
$ git submodule update --recursive
$ git checkout <desired new hash or branch>
The desired output diff is a change in `.gitmodules` to reflect the
change in the remote URL, and a change in /<submodule> where you see
the desired change in the commit hash.
-120
View File
@@ -1,120 +0,0 @@
README.vsnet Last updated: 2006-02-01
SVN includes a Visual Studio .NET 2005 solution, mono.sln, and some
projects files to build most of the unmanaged parts in Mono.
The "mono.sln" solution file contains the VC projects files for:
* Embedded Samples
* test-invoke.vcproj
* test-metadata.vcproj
* teste.vcproj
* Libraries
* libgc.vcproj
* libmono.vcproj
* Tools
* genmdesc.vcproj
* monoburg.vcproj
* monodiet.vcproj
* monodis.vcproj
* monograph.vcproj
* pedump.vcproj
* mono.vcproj
REQUIREMENTS
* A working (i.e. where you could succesfully build mono) cygwin
(http://www.cygwin.com/) setup! This is required to:
* generate some files (via monoburg and genmdesc);
* build the class libraries; and
* test for regressions.
* Visual Studio .NET 2005. Previous Visual Studio versions may work or
requires, hopefully minimal, changes.
* VSDependencies.zip must be decompressed under the /mono/ directory
(otherwise you will need to edit all the projects files). This file can
be downloaded from http://www.go-mono.com/archive/VSDependencies.zip
LOCAL CHANGES
Sadly solution/projects files aren't easy to move from computers to
computers (well unless everyone follow the same naming convention) so
you'll likely have to changes some options in order to compile the
solution.
* each executed assembly (i.e. the EXE) must be able to find a
working mscorlib.dll (and all the other required assemblies).
This can be done in different ways. My preference is to use the
project "properties pages" in the "Configuration Properties
\Debugging\Environment" options and set MONO_PATH to the class
libraries directory build by cygwin (local) or on Linux
(remote).
e.g. MONO_PATH=z:\svn\mcs\class\lib\default\
allows me to use the class libs build under Linux, while
MONO_PATH=C:\cygwin\opt\mono\lib\mono\1.0
use the one built from cygwin (after a make install)
Some useful informations to adapt the solution/project files...
* My cygwin root dir is: c:\cygwin\
* My username is: poupou
* My mono install prefix is: /opt/mono
BUILDING
Once everything is installed (and edited) you can right-click on the
"mono" solution (in the "Solution Explorer"), select "Clean
Solution" (for the first time) then "Build Solution".
KNOWN ISSUES
[1] Most, BUT NOT ALL, the regressions tests pass under this build. The
failures seems limited to some mathematical differences and to code
relying on the stack walking functions. The hacks to replace the GCC
functions (__builtin_frame_address and __builtin_return_address) are
incomplete;
[2] The solution doesn't provide complete (i.e. from scratch) build. It
requires a working cygwin environment to create some files (e.g. via
genmdesc, monoburg). This isn't so bad as without cygwin you wouldn't be
able to test Mono properly (see REQUIREMENTS);
[3] Only the Debug target is configured properly (that would be easy to
fix, but would require turning off some optimizations like omitting
stack frames). Anyway there are other issues [1] to fix before switching
to Release and IMHO the _biggest_ advantage to VS.NET is it's debugger/
debugging tools;
[4] The C compiler emits _lots_ of warning during compilation. Some
warnings have been turned off for some projects (there was so much that
it slowed down compilation). You can bring them back (or hide more of
them) using the project "properties pages" windows, "Configuration
Properties\C/C++\Advanced\Disable Specific Warnings";
[5] Visual Studio 2005 should have all the latest header files required,
but if not (or if you're using an older version of VS) then install MS
Platform SDK (Windows Server 2003 is the latest) to ensure you have the
latest Windows header files. You can download it from:
http://www.microsoft.com/msdownload/platformsdk/sdkupdate/psdk-full.htm
[6] Not everyone has VS.NET so it is possible you may have to add some
(new) files to the build from time to time. See "more informations" for
reporting those changes.
[7] Probably a lot more I didn't discover... or has changed since.
MORE INFORMATION
Please email <[email protected]> if you have any problem
and/or if there's something wrong/missing in the instructions.
An online version of this file is available at
http://www.mono-project.com/Compiling_Mono_VSNET
+4 -4
View File
@@ -22,11 +22,11 @@ if test x$GCC != xyes; then
dolt_supported=no
fi
case $host in
i?86-*-linux*|x86_64-*-linux*|powerpc-*-linux*|powerpc64-*-linux* \
|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*|arm*-*-linux*|sparc*-*-linux*|mips*-*-linux*|x86_64-apple-darwin*)
i?86-*-linux*|i?86-apple-darwin*|x86_64-*-linux*|powerpc-*-linux*|powerpc64-*-linux* \
|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*|arm*-*-linux*|sparc*-*-linux*|mips*-*-linux*|x86_64-apple-darwin*|aarch64*)
pic_options='-fPIC'
;;
?86-pc-cygwin*|i?86-pc-cygwin*)
?86-pc-cygwin*|i?86-pc-cygwin*|i?86-pc-mingw32*)
pic_options='-DDLL_EXPORT'
;;
i?86-apple-darwin*|arm-apple-darwin*)
@@ -158,7 +158,7 @@ modeok=false
tagok=false
for arg in "$[]@"; do
case "$arg" in
--silent) ;;
--silent) ;;
--mode=compile) modeok=true ;;
--tag=CC|--tag=CXX) tagok=true ;;
--quiet) ;;
+79
View File
@@ -0,0 +1,79 @@
#
# Appveyor configuration file for CI build of Mono on Windows (under Cygwin)
#
# For further details see http://www.appveyor.com
#
#
# Custom environment variables
#
environment:
global:
CYG_ROOT: C:\cygwin
CYG_MIRROR: http://cygwin.mirror.constant.com
CYG_CACHE: C:\cygwin\var\cache\setup
CYG_BASH: C:\cygwin\bin\bash
#
# Cache Cygwin files to speed up build
#
cache:
- '%CYG_CACHE%'
#
# Do a shallow clone of the repo to speed up build
#
clone_depth: 1
#
# Initialisation prior to pulling the Mono repository
# Attempt to ensure we don't try to convert line endings to Win32 CRLF as this will cause build to fail
#
init:
- git config --global core.autocrlf input
#
# Install needed build dependencies
#
install:
- ps: 'Start-FileDownload "http://cygwin.com/setup-x86.exe" -FileName "setup-x86.exe"'
- 'setup-x86.exe --quiet-mode --no-shortcuts --only-site --root "%CYG_ROOT%" --site "%CYG_MIRROR%" --local-package-dir "%CYG_CACHE%" --packages autoconf,automake,bison,gcc-core,gcc-g++,mingw-runtime,mingw-binutils,mingw-gcc-core,mingw-gcc-g++,mingw-pthreads,mingw-w32api,libtool,make,python,gettext-devel,gettext,intltool,libiconv,pkg-config,git,curl,libxslt > NUL 2>&1'
- '%CYG_BASH% -lc "cygcheck -dc cygwin"'
# Cygwin build script
#
# NOTES:
#
# The stdin/stdout file descriptor appears not to be valid for the Appveyor
# build which causes failures as certain functions attempt to redirect
# default file handles. Ensure a dummy file descriptor is opened with 'exec'.
#
build_script:
- 'echo Building...'
- '%CYG_BASH% -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; ./autogen.sh --prefix=/usr/local --host=i686-pc-mingw32"'
- '%CYG_BASH% -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make get-monolite-latest"'
- '%CYG_BASH% -lc "cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make -j2"'
- 'echo Installing...'
- 'mkdir %APPVEYOR_BUILD_FOLDER%\install'
- '%CYG_BASH% -lc "export CYGWIN=winsymlinks:native; mount \"$APPVEYOR_BUILD_FOLDER\install\" /usr/local; cd $APPVEYOR_BUILD_FOLDER; exec 0</dev/null; make install; umount /usr/local"'
#
# Disable tests for now
#
test: off
#
# Only build the master branch
#
branches:
only:
- master
#
# NOTE: Currently this is the Mono installation tree. In future we will create an installation package artifact.
# It has to be relative to the project path. Thus we have installed to within the build tree.
#
artifacts:
- path: install
name: mono-binaries
type: zip
+13 -10
View File
@@ -37,7 +37,7 @@ if [ -z "$LIBTOOL" ]; then
fi
fi
(grep "^AM_PROG_LIBTOOL" $srcdir/configure.in >/dev/null) && {
(grep "^AM_PROG_LIBTOOL" $srcdir/configure.ac >/dev/null) && {
($LIBTOOL --version) < /dev/null > /dev/null 2>&1 || {
echo
echo "**Error**: You must have \`libtool' installed to compile Mono."
@@ -47,8 +47,8 @@ fi
}
}
grep "^AM_GNU_GETTEXT" $srcdir/configure.in >/dev/null && {
grep "sed.*POTFILES" $srcdir/configure.in >/dev/null || \
grep "^AM_GNU_GETTEXT" $srcdir/configure.ac >/dev/null && {
grep "sed.*POTFILES" $srcdir/configure.ac >/dev/null || \
(gettext --version) < /dev/null > /dev/null 2>&1 || {
echo
echo "**Error**: You must have \`gettext' installed to compile Mono."
@@ -95,7 +95,7 @@ xlc )
esac
if grep "^AM_PROG_LIBTOOL" configure.in >/dev/null; then
if grep "^AM_PROG_LIBTOOL" configure.ac >/dev/null; then
if test -z "$NO_LIBTOOLIZE" ; then
echo "Running libtoolize..."
${LIBTOOL}ize --force --copy
@@ -107,19 +107,22 @@ fi
# Plug in the extension module
#
has_ext_mod=false
ext_mod_args=''
for PARAM; do
if test "$PARAM" = "--enable-extension-module" ; then
has_ext_mod=true
fi
if [[ $PARAM =~ "--enable-extension-module" ]] ; then
has_ext_mod=true
if [[ $PARAM =~ "=" ]] ; then
ext_mod_args=`echo $PARAM | cut -d= -f2`
fi
fi
done
if test x$has_ext_mod = xtrue; then
pushd ../mono-extensions/scripts
sh ./prepare-repo.sh || exit 1
sh ./prepare-repo.sh $ext_mod_args || exit 1
popd
else
cat mono/mini/Makefile.am.in > mono/mini/Makefile.am
cat mono/metadata/Makefile.am.in > mono/metadata/Makefile.am
fi
@@ -134,7 +137,7 @@ aclocal -Wnone -I m4 -I . $ACLOCAL_FLAGS || {
exit 1
}
if grep "^AC_CONFIG_HEADERS" configure.in >/dev/null; then
if grep "^AC_CONFIG_HEADERS" configure.ac >/dev/null; then
echo "Running autoheader..."
autoheader || { echo "**Error**: autoheader failed."; exit 1; }
fi
-227
View File
@@ -1,227 +0,0 @@
#!/bin/bash -e
CURDIR="`pwd`"
MINGW=i386-mingw32msvc
CROSS_DIR=/opt/cross/$MINGW
EXTRA_CROSS_DIR=
INSTALL_DESTDIR="$CURDIR/mono-win32"
PROFILES="default net_2_0 net_3_5 net_4_0 net_4_5 moonlight"
TEMPORARY_PKG_CONFIG_DIR=/tmp/$RANDOM-pkg-config-$RANDOM
ORIGINAL_PATH="$PATH"
export CPPFLAGS_FOR_EGLIB CFLAGS_FOR_EGLIB CPPFLAGS_FOR_LIBGC CFLAGS_FOR_LIBGC
function cleanup ()
{
if [ -d "$TEMPORARY_PKG_CONFIG_DIR" ]; then
rm -rf "$TEMPORARY_PKG_CONFIG_DIR"
fi
}
function check_pkg_config_dir ()
{
local DIR="$1"
local DIR_PREFIX="$2"
if [ ! -d "$DIR" ]; then
return
fi
install -d -m 755 "$TEMPORARY_PKG_CONFIG_DIR"
for pc in "$DIR"/*.pc; do
if [ -f $pc ]; then
pcname="`basename $pc`"
sed -e "s;^prefix=.*;prefix=$DIR_PREFIX;g" < $pc > "$TEMPORARY_PKG_CONFIG_DIR"/$pcname
fi;
done
if [ -z "$CROSS_PKG_CONFIG_DIR" ]; then
CROSS_PKG_CONFIG_DIR="$TEMPORARY_PKG_CONFIG_DIR"
fi
}
function show_build_info ()
{
cat <<EOF
Installation prefix: $MONO_PREFIX
CPPFLAGS: ${CPPFLAGS:=not set}
LDFLAGS: ${LDFLAGS:=not set}
MONO_PATH: ${MONO_PATH:=not set}
EOF
}
function setup ()
{
local pcname
CROSS_BIN_DIR="$CROSS_DIR/bin"
CROSS_DLL_DIR="$CROSS_DIR/bin"
PATH=$CROSS_BIN_DIR:$PATH
MONO_VERSION=`grep AC_INIT configure.in | cut -d ',' -f 2|tr -d '\[ \]'`
if [ -d ./.git ]; then
MONO_GIT_COMMIT="`git log -1 --format=format:%t`"
MONO_GIT_BRANCH="`git branch|grep '\*'|cut -d ' ' -f 2|tr -d '\)'|tr -d '\('`"
MONO_RELEASE="$MONO_VERSION-$MONO_GIT_BRANCH-$MONO_GIT_COMMIT"
else
MONO_RELEASE="$MONO_VERSION"
fi
MONO_PREFIX="$MONO_PREFIX/mono-$MONO_RELEASE"
NOCONFIGURE=yes
export NOCONFIGURE
check_pkg_config_dir "$CROSS_DIR/lib/pkgconfig" "$CROSS_DIR"
if [ -n "$EXTRA_CROSS_DIR" -a -d "$EXTRA_CROSS_DIR" ]; then
if [ -d "$EXTRA_CROSS_DIR/bin" ]; then
PATH="$EXTRA_CROSS_DIR/bin":$PATH
fi
check_pkg_config_dir "$EXTRA_CROSS_DIR/lib/pkgconfig" "$EXTRA_CROSS_DIR"
if [ -d "$EXTRA_CROSS_DIR/include" ]; then
if [ -z "$CPPFLAGS" ]; then
CPPFLAGS="-I \"$EXTRA_CROSS_DIR/include\""
else
CPPFLAGS="-I \"$EXTRA_CROSS_DIR/include\" $CFLAGS"
fi
fi
if [ -d "$EXTRA_CROSS_DIR/lib" ]; then
if [ -z "$LDFLAGS" ]; then
LDFLAGS="-I \"$EXTRA_CROSS_DIR/lib\""
else
LDFLAGS="-I \"$EXTRA_CROSS_DIR/lib\" $LDFLAGS"
fi
fi
if [ -d "$EXTRA_CROSS_DIR/share/aclocal" ]; then
if [ -z "$MONO_PATH" ]; then
MONO_PATH="\"$EXTRA_CROSS_DIR\""
else
MONO_PATH="\"$EXTRA_CROSS_DIR\":$MONO_PATH"
fi
fi
fi
export PATH MONO_PATH CPPFLAGS
show_build_info
}
function build ()
{
if [ -f ./Makefile ]; then
make distclean
fi
if [ -d ./autom4te.cache ]; then
rm -rf ./autom4te.cache
fi
if [ -f ./config.status ]; then
for f in `find -name config.status -type f`; do
rm $f
done
fi
./autogen.sh
BUILD="`./config.guess`"
if [ ! -d "$CURDIR/build-cross-windows" ]; then
mkdir "$CURDIR/build-cross-windows"
fi
cd "$CURDIR/build-cross-windows"
rm -rf *
../configure --prefix=$MONO_PREFIX --with-crosspkgdir=$CROSS_PKG_CONFIG_DIR --build=$BUILD --target=$MINGW --host=$MINGW --enable-parallel-mark --program-transform-name="" --with-tls=none --disable-mcs-build --disable-embed-check --enable-win32-dllmain=yes --with-libgc-threads=win32 --with-profile4=yes
make
cd "$CURDIR"
if [ ! -d "$CURDIR/build-cross-windows-mcs" ]; then
mkdir "$CURDIR/build-cross-windows-mcs"
fi
rm -rf autom4te.cache
unset PATH
PATH="$ORIGINAL_PATH"
export PATH
cd "$CURDIR/build-cross-windows-mcs"
rm -rf *
../configure --prefix=$MONO_PREFIX --enable-parallel-mark
make
}
function doinstall ()
{
if [ -d "$INSTALL_DIR" ]; then
rm -rf "$INSTALL_DIR"
fi
cd "$CURDIR/build-cross-windows"
make DESTDIR="$INSTALL_DESTDIR" USE_BATCH_FILES=yes install
if test -d $CURDIR/mcs; then
mcsdir=$CURDIR/mcs
else
mcsdir=$CURDIR/../mcs
fi
cd "$mcsdir/mcs"
for p in $PROFILES; do
make DESTDIR="$INSTALL_DESTDIR" PROFILE=$p install || echo "mcs profile $p installation failed"
done
cd "$mcsdir/class"
for p in $PROFILES; do
make DESTDIR="$INSTALL_DESTDIR" PROFILE=$p install || echo "class library profile $p installation failed"
done
cd "$mcsdir/tools"
for p in $PROFILES; do
make DESTDIR="$INSTALL_DESTDIR" PROFILE=$p install || echo "tools profile $p installation failed"
done
cd "$CURDIR/mono-win32"
rm -f "$CURDIR/mono-win32-$MONO_RELEASE".zip
zip -9r "$CURDIR/mono-win32-$MONO_RELEASE".zip .
}
function usage ()
{
cat <<EOF
Usage: build-mingw32.sh [OPTIONS]
where OPTIONS are:
-d DIR Sets the location of directory where MINGW is installed [$CROSS_DIR]
-e DIR Sets the location of directory where additional cross develoment packages are installed [${EXTRA_CROSS_DIR:=none}]
-m MINGW Sets the MINGW target name to be passed to configure [$MINGW]
-p PREFIX Prefix at which Mono is to be installed. Build will append the 'mono-X.Y' string to that path
EOF
exit 1
}
trap cleanup 0
pushd . > /dev/null
while getopts "d:m:e:p:" opt; do
case "$opt" in
d) CROSS_DIR="$OPTARG" ;;
m) MINGW="$OPTARG" ;;
e) EXTRA_CROSS_DIR="$OPTARG" ;;
p) MONO_PREFIX="$OPTARG" ;;
*) usage ;;
esac
done
setup
build
doinstall
show_build_info
popd > /dev/null
+3990
View File
File diff suppressed because it is too large. Load diff
-3689
View File
File diff suppressed because it is too large. Load diff
File renamed without changes.
File renamed without changes.
File renamed without changes.
+9 -18
View File
@@ -1,10 +1,7 @@
SUBDIRS = net_2_0
if INSTALL_4_0
SUBDIRS += net_4_0 net_4_5
endif
SUBDIRS = net_2_0 net_4_0 net_4_5
monodir = $(sysconfdir)/mono
monolldbdir = $(libdir)/mono/lldb
EXTRA_DIST = \
config.in \
@@ -12,10 +9,12 @@ EXTRA_DIST = \
mono.pc.in mono-2.pc.in monosgen-2.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 \
mono-lineeditor.pc.in system.web.extensions_1.0.pc.in system.web.extensions.design_1.0.pc.in\
dtrace-prelink.sh mono.web.pc.in system.web.mvc.pc.in system.web.mvc2.pc.in system.web.mvc3.pc.in aspnetwebstack.pc.in reactive.pc.in \
dtrace-prelink.sh system.web.mvc.pc.in system.web.mvc2.pc.in system.web.mvc3.pc.in aspnetwebstack.pc.in \
reactive.pc.in xbuild12.pc \
net_1_1/machine.config \
gdb/mono-gdb.py \
gdb/gdb-python.diff
gdb/gdb-python.diff \
lldb/mono.py
pkgconfigdir = $(libdir)/pkgconfig
@@ -25,24 +24,16 @@ else
SGENPCFILE=
endif
if JIT_SUPPORTED
if INTERP_SUPPORTED
pkgconfig_DATA= mono.pc mono-2.pc mint.pc dotnet.pc dotnet35.pc wcf.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc system.web.extensions_1.0.pc \
system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc reactive.pc $(SGENPCFILE)
else
pkgconfig_DATA= mono.pc mono-2.pc dotnet.pc dotnet35.pc wcf.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc system.web.extensions_1.0.pc \
system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc reactive.pc $(SGENPCFILE)
endif
else
pkgconfig_DATA= mint.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc
endif
system.web.extensions.design_1.0.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc reactive.pc xbuild12.pc $(SGENPCFILE)
DISTCLEANFILES= mono-2.pc mono.pc mint.pc dotnet.pc dotnet35.pc wcf.pc mono-nunit.pc mono-cairo.pc mono-options.pc cecil.pc monodoc.pc mono-lineeditor.pc system.web.extensions_1.0.pc \
system.web.extensions.design_1.0.pc mono.web.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc reactive.pc $(SGENPCFILE) mono-sgen-gdb.py
system.web.extensions.design_1.0.pc system.web.mvc.pc system.web.mvc2.pc system.web.mvc3.pc aspnetwebstack.pc reactive.pc $(SGENPCFILE) mono-sgen-gdb.py
mono_DATA = config \
browscap.ini
monolldb_DATA = lldb/mono.py
gdbdir = $(bindir)
mono-sgen-gdb.py: gdb/mono-gdb.py
+1 -1
View File
@@ -1,4 +1,4 @@
Name: AspNetWebStack
Description: References Microsoft ASP.NET Web Stack
Version: @VERSION@
Libs: -r:System.Web.Razor.dll -r:System.Web.Http.dll -r:System.Web.WebPages -r:System.Web.WebPages.Razor -r:System.Web.WebPages.Deployment
Libs: -r:@prefix@/lib/mono/gac/System.Web.Razor/2.0.0.0__31bf3856ad364e35/System.Web.Razor.dll -r:@prefix@/lib/mono/gac/System.Web.Http/4.0.0.0__31bf3856ad364e35/System.Web.Http.dll -r:@prefix@/lib/mono/gac/System.Web.WebPages/2.0.0.0__31bf3856ad364e35/System.Web.WebPages.dll -r:@prefix@/lib/mono/gac/System.Web.WebPages.Razor/2.0.0.0__31bf3856ad364e35/System.Web.WebPages.Razor.dll -r:@prefix@/lib/mono/gac/System.Web.WebPages.Deployment/2.0.0.0__31bf3856ad364e35/System.Web.WebPages.Deployment.dll
+8 -3
View File
@@ -10,12 +10,15 @@
<dllmap dll="i:odbc32.dll" target="libiodbc.dylib" os="osx"/>
<dllmap dll="oci" target="libclntsh@libsuffix@" os="!windows"/>
<dllmap dll="db2cli" target="libdb2_36@libsuffix@" os="!windows"/>
<dllmap dll="MonoPosixHelper" target="libMonoPosixHelper@libsuffix@" os="!windows" />
<dllmap dll="MonoPosixHelper" target="$mono_libdir/libMonoPosixHelper@libsuffix@" os="!windows" />
<dllmap dll="i:msvcrt" target="@LIBC@" os="!windows"/>
<dllmap dll="i:msvcrt.dll" target="@LIBC@" os="!windows"/>
<dllmap dll="sqlite" target="@SQLITE@" os="!windows"/>
<dllmap dll="sqlite3" target="@SQLITE3@" os="!windows"/>
<dllmap dll="libX11" target="@X11@" os="!windows" />
<dllmap dll="libgdk-x11-2.0" target="@GDKX11@" os="!windows"/>
<dllmap dll="libgtk-x11-2.0" target="@GTKX11@" os="!windows"/>
<dllmap dll="libXinerama" target="@XINERAMA@" os="!windows" />
<dllmap dll="libcairo-2.dll" target="libcairo.so.2" os="!windows"/>
<dllmap dll="libcairo-2.dll" target="libcairo.2.dylib" os="osx"/>
<dllmap dll="libcups" target="libcups.so.2" os="!windows"/>
@@ -26,6 +29,8 @@
<dllentry dll="__Internal" name="MoveMemory" target="mono_win32_compat_MoveMemory"/>
<dllentry dll="__Internal" name="ZeroMemory" target="mono_win32_compat_ZeroMemory"/>
</dllmap>
<dllmap dll="gdiplus" target="@prefix@/lib/libgdiplus@libsuffix@" />
<dllmap dll="gdiplus.dll" target="@prefix@/lib/libgdiplus@libsuffix@" />
<dllmap dll="gdiplus" target="@libgdiplus_install_loc@" os="!windows"/>
<dllmap dll="gdiplus.dll" target="@libgdiplus_install_loc@" os="!windows"/>
<dllmap dll="gdi32" target="@libgdiplus_install_loc@" os="!windows"/>
<dllmap dll="gdi32.dll" target="@libgdiplus_install_loc@" os="!windows"/>
</configuration>
+1 -1
View File
@@ -2,4 +2,4 @@
Name: Standard libraries in a .NET setup
Description: References all the standard .NET libraries for compilation
Version: @VERSION@
Libs: -r:Accessibility.dll -r:cscompmgd.dll -r:Microsoft.VisualC.dll -r:System.Configuration.Install.dll -r:System.Data.dll -r:System.Data.OracleClient.dll -r:System.Design.dll -r:System.DirectoryServices.dll -r:System.dll -r:System.Drawing.Design.dll -r:System.Drawing.dll -r:System.EnterpriseServices.dll -r:System.Management.dll -r:System.Messaging.dll -r:System.Runtime.Remoting.dll -r:System.Runtime.Serialization.Formatters.Soap.dll -r:System.Security.dll -r:System.ServiceProcess.dll -r:System.Web.dll -r:System.Web.Services.dll -r:System.Windows.Forms.dll -r:System.Xml.dll
Libs: -r:Accessibility.dll -r:cscompmgd.dll -r:Microsoft.VisualC.dll -r:System.Configuration.Install.dll -r:System.Data.dll -r:System.Data.OracleClient.dll -r:System.Design.dll -r:System.DirectoryServices.dll -r:System.dll -r:System.Drawing.Design.dll -r:System.Drawing.dll -r:System.EnterpriseServices.dll -r:System.Management.dll -r:System.Messaging.dll -r:System.Runtime.Remoting.dll -r:System.Runtime.Serialization.Formatters.Soap.dll -r:System.Security.dll -r:System.ServiceProcess.dll -r:System.Web.dll -r:System.Web.Services.dll -r:System.Windows.Forms.dll -r:System.Xml.dll -r:System.Xml.Linq.dll
+21 -20
View File
@@ -15,6 +15,7 @@
# When attaching to a mono process, make sure you are in the same directory.
#
from __future__ import print_function
import os
class StringPrinter:
@@ -35,7 +36,7 @@ class StringPrinter:
while i < len:
val = (chars.cast(gdb.lookup_type ("gint64")) + (i * 2)).cast(gdb.lookup_type ("gunichar2").pointer ()).dereference ()
if val >= 256:
c = "\u%X" % val
c = "\u%X".format (val)
else:
c = chr (val)
res.append (c)
@@ -52,7 +53,7 @@ def stringify_class_name(ns, name):
if ns == "":
return name
else:
return "%s.%s" % (ns, name)
return "%s.%s".format (ns, name)
class ArrayPrinter:
"Print a C# array"
@@ -65,7 +66,7 @@ class ArrayPrinter:
def to_string(self):
obj = self.val.cast (gdb.lookup_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))
return "%s [%d]".format (stringify_class_name (self.class_ns, self.class_name [0:len (self.class_name) - 2]), int (length))
class ObjectPrinter:
"Print a C# object"
@@ -95,7 +96,7 @@ class ObjectPrinter:
return (field.name, self.obj [field.name])
except:
# Superclass
return (field.name, self.obj.cast (gdb.lookup_type ("%s" % (field.name))))
return (field.name, self.obj.cast (gdb.lookup_type ("%s".format (field.name))))
def children(self):
# FIXME: It would be easier if gdb.Value would support iteration itself
@@ -108,11 +109,11 @@ class ObjectPrinter:
class_name = obj ['vtable'].dereference ()['klass'].dereference ()['name'].string ()
if class_name [-2:len(class_name)] == "[]":
return {}.__iter__ ()
gdb_type = gdb.lookup_type ("struct %s_%s" % (class_ns.replace (".", "_"), class_name))
gdb_type = gdb.lookup_type ("struct %s_%s".format (class_ns.replace (".", "_"), class_name))
return self._iterator(obj.cast (gdb_type))
except:
print sys.exc_info ()[0]
print sys.exc_info ()[1]
print (sys.exc_info ()[0])
print (sys.exc_info ()[1])
return {}.__iter__ ()
def to_string(self):
@@ -128,16 +129,16 @@ class ObjectPrinter:
return ArrayPrinter (self.val,class_ns,class_name).to_string ()
if class_ns != "":
try:
gdb_type = gdb.lookup_type ("struct %s.%s" % (class_ns, class_name))
gdb_type = gdb.lookup_type ("struct %s.%s".format (class_ns, class_name))
except:
# Maybe there is no debug info for that type
return "%s.%s" % (class_ns, class_name)
return "%s.%s".format (class_ns, class_name)
#return obj.cast (gdb_type)
return "%s.%s" % (class_ns, class_name)
return "%s.%s".format (class_ns, class_name)
return class_name
except:
print sys.exc_info ()[0]
print sys.exc_info ()[1]
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.lookup_type ("guint64"))
@@ -153,9 +154,9 @@ class MonoMethodPrinter:
val = self.val.dereference ()
klass = val ["klass"].dereference ()
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
return "\"%s:%s ()\"" % (class_name, val ["name"].string ())
return "\"%s:%s ()\"".format (class_name, val ["name"].string ())
# This returns more info but requires calling into the inferior
#return "\"%s\"" % (gdb.parse_and_eval ("mono_method_full_name (%s, 1)" % (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
#return "\"%s\"".format (gdb.parse_and_eval ("mono_method_full_name (%s, 1)".format (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
class MonoClassPrinter:
"Print a MonoClass structure"
@@ -168,9 +169,9 @@ class MonoClassPrinter:
return "0x0"
klass = self.val.dereference ()
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
return "\"%s\"" % (class_name)
return "\"%s\"".format (class_name)
# This returns more info but requires calling into the inferior
#return "\"%s\"" % (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*)%s)->byval_arg)" % (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
#return "\"%s\"".format (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*)%s)->byval_arg)".format (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
def lookup_pretty_printer(val):
t = str (val.type)
@@ -216,9 +217,9 @@ class MonoSupport(object):
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)
gdb.execute ("shell as -o xdb.o xdb.s && ld -shared -o %s xdb.o".format (sofile))
# FIXME: This prints messages which couldn't be turned off
gdb.execute ("add-symbol-file %s 0" % sofile)
gdb.execute ("add-symbol-file %s 0".format (sofile))
self.s_size = new_size
class RunHook (gdb.Command):
@@ -229,7 +230,7 @@ class RunHook (gdb.Command):
def invoke(self, arg, from_tty):
mono_support.run_hook ()
print "Mono support loaded."
print ("Mono support loaded.")
mono_support = MonoSupport ()
@@ -244,4 +245,4 @@ exec_file = gdb.current_objfile ().filename
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)))
gdb.execute ("source %s/%s-gdbinit".format (exec_dir, os.path.basename (exec_file)))
+2 -2
View File
@@ -3,8 +3,8 @@
import sys
gdb.execute ("file %s" % sys.argv [0])
gdb.execute ("r --break *:* %s" % " ".join (sys.argv[1:len(sys.argv)]))
gdb.execute ("file %s".format (sys.argv [0]))
gdb.execute ("r --break *:* %s".format (" ".join (sys.argv [1:len (sys.argv)])))
while True:
try:
+32 -31
View File
@@ -10,6 +10,7 @@
# - run mono under gdb, or attach to a mono process started with --debug=gdb using gdb.
#
from __future__ import print_function
import os
class StringPrinter:
@@ -30,7 +31,7 @@ class StringPrinter:
while i < len:
val = (chars.cast(gdb.lookup_type ("gint64")) + (i * 2)).cast(gdb.lookup_type ("gunichar2").pointer ()).dereference ()
if val >= 256:
c = "\u%X" % val
c = unichr (val)
else:
c = chr (val)
res.append (c)
@@ -47,7 +48,7 @@ def stringify_class_name(ns, name):
if ns == "":
return name
else:
return "%s.%s" % (ns, name)
return "%s.%s".format (ns, name)
class ArrayPrinter:
"Print a C# array"
@@ -60,7 +61,7 @@ class ArrayPrinter:
def to_string(self):
obj = self.val.cast (gdb.lookup_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))
return "%s [%d]".format (stringify_class_name (self.class_ns, self.class_name [0:len(self.class_name) - 2]), int(length))
class ObjectPrinter:
"Print a C# object"
@@ -90,7 +91,7 @@ class ObjectPrinter:
return (field.name, self.obj [field.name])
except:
# Superclass
return (field.name, self.obj.cast (gdb.lookup_type ("%s" % (field.name))))
return (field.name, self.obj.cast (gdb.lookup_type ("%s".format (field.name))))
def children(self):
# FIXME: It would be easier if gdb.Value would support iteration itself
@@ -104,13 +105,13 @@ class ObjectPrinter:
if class_name [-2:len(class_name)] == "[]":
return {}.__iter__ ()
try:
gdb_type = gdb.lookup_type ("struct %s_%s" % (class_ns.replace (".", "_"), class_name))
gdb_type = gdb.lookup_type ("struct %s_%s".format (class_ns.replace (".", "_"), class_name))
return self._iterator(obj.cast (gdb_type))
except:
return {}.__iter__ ()
except:
print sys.exc_info ()[0]
print sys.exc_info ()[1]
print (sys.exc_info ()[0])
print (sys.exc_info ()[1])
return {}.__iter__ ()
def to_string(self):
@@ -126,16 +127,16 @@ class ObjectPrinter:
return ArrayPrinter (self.val,class_ns,class_name).to_string ()
if class_ns != "":
try:
gdb_type = gdb.lookup_type ("struct %s.%s" % (class_ns, class_name))
gdb_type = gdb.lookup_type ("struct %s.%s".format (class_ns, class_name))
except:
# Maybe there is no debug info for that type
return "%s.%s" % (class_ns, class_name)
return "%s.%s".format (class_ns, class_name)
#return obj.cast (gdb_type)
return "%s.%s" % (class_ns, class_name)
return "%s.%s".format (class_ns, class_name)
return class_name
except:
print sys.exc_info ()[0]
print sys.exc_info ()[1]
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.lookup_type ("guint64"))
@@ -151,9 +152,9 @@ class MonoMethodPrinter:
val = self.val.dereference ()
klass = val ["klass"].dereference ()
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
return "\"%s:%s ()\"" % (class_name, val ["name"].string ())
return "\"%s:%s ()\"".format (class_name, val ["name"].string ())
# This returns more info but requires calling into the inferior
#return "\"%s\"" % (gdb.parse_and_eval ("mono_method_full_name (%s, 1)" % (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
#return "\"%s\"".format (gdb.parse_and_eval ("mono_method_full_name (%s, 1)".format (str (int (self.val.cast (gdb.lookup_type ("guint64")))))).string ())
class MonoClassPrinter:
"Print a MonoClass structure"
@@ -167,20 +168,20 @@ class MonoClassPrinter:
klass = self.val.dereference ()
class_name = stringify_class_name (klass ["name_space"].string (), klass ["name"].string ())
if klass ["generic_class"].cast (gdb.lookup_type ("guint64")) != 0:
class_name = "%s<%s>" % (class_name, str (klass ["generic_class"]["context"]["class_inst"]))
class_name = "%s<%s>".format (class_name, str (klass ["generic_class"]["context"]["class_inst"]))
if add_quotes:
return "\"%s\"" % (class_name)
return "\"%s\"".format (class_name)
else:
return class_name
# This returns more info but requires calling into the inferior
#return "\"%s\"" % (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*)%s)->byval_arg)" % (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
#return "\"%s\"".format (gdb.parse_and_eval ("mono_type_full_name (&((MonoClass*)%s)->byval_arg)".format (str (int ((self.val).cast (gdb.lookup_type ("guint64")))))))
def to_string(self):
try:
return self.to_string_inner (True)
except:
#print sys.exc_info ()[0]
#print sys.exc_info ()[1]
#print (sys.exc_info ()[0])
#print (sys.exc_info ()[1])
return str(self.val.cast (gdb.lookup_type ("gpointer")))
class MonoGenericInstPrinter:
@@ -197,7 +198,7 @@ class MonoGenericInstPrinter:
inst_args = inst ["type_argv"]
inst_str = ""
for i in range(0, inst_len):
print inst_args
print (inst_args)
type_printer = MonoTypePrinter (inst_args [i])
if i > 0:
inst_str = inst_str + ", "
@@ -221,14 +222,14 @@ class MonoGenericClassPrinter:
method_inst_str = ""
if int(method_inst.cast (gdb.lookup_type ("guint64"))) != 0:
method_inst_str = str(method_inst)
return "%s, [%s], [%s]>" % (container_str, class_inst_str, method_inst_str)
return "%s, [%s], [%s]>".format (container_str, class_inst_str, method_inst_str)
def to_string(self):
try:
return self.to_string_inner ()
except:
#print sys.exc_info ()[0]
#print sys.exc_info ()[1]
#print (sys.exc_info ()[0])
#print (sys.exc_info ()[1])
return str(self.val.cast (gdb.lookup_type ("gpointer")))
class MonoTypePrinter:
@@ -251,12 +252,12 @@ class MonoTypePrinter:
info = str(t ["data"]["generic_class"])
if info != "":
return "{%s, %s}" % (kind, info)
return "{%s, %s}".format (kind, info)
else:
return "{%s}" % (kind)
return "{%s}".format (kind)
except:
#print sys.exc_info ()[0]
#print sys.exc_info ()[1]
#print (sys.exc_info ()[0])
#print (sys.exc_info ()[1])
return str(self.val.cast (gdb.lookup_type ("gpointer")))
def to_string(self):
@@ -277,12 +278,12 @@ class MonoMethodRgctxPrinter:
inst_args = inst ["type_argv"]
inst_str = ""
for i in range(0, inst_len):
print inst_args
print (inst_args)
type_printer = MonoTypePrinter (inst_args [i])
if i > 0:
inst_str = inst_str + ", "
inst_str = inst_str + type_printer.to_string ()
return "MRGCTX[%s, [%s]]" % (klass_printer.to_string(), inst_str)
return "MRGCTX[%s, [%s]]".format (klass_printer.to_string(), inst_str)
class MonoVTablePrinter:
"Print a MonoVTable structure"
@@ -297,7 +298,7 @@ class MonoVTablePrinter:
klass = vtable ["klass"]
klass_printer = MonoClassPrinter (klass)
return "vtable(%s)" % (klass_printer.to_string ())
return "vtable(%s)".format (klass_printer.to_string ())
def lookup_pretty_printer(val):
t = str (val.type)
@@ -348,6 +349,6 @@ XdbCommand ()
gdb.execute ("set environment MONO_XDEBUG gdb")
print "Mono support loaded."
print ("Mono support loaded.")
+2 -2
View File
@@ -3,8 +3,8 @@
import sys
gdb.execute ("file %s" % sys.argv [0])
gdb.execute ("r --break *:* %s" % " ".join (sys.argv[1:len(sys.argv)]))
gdb.execute ("file %s".format (sys.argv [0]))
gdb.execute ("r --break *:* %s".format (" ".join (sys.argv [1:len (sys.argv)])))
while True:
try:
+174
View File
@@ -0,0 +1,174 @@
#
# Author: Zoltan Varga ([email protected])
# License: MIT/X11
#
#
# This is a mono support mode for lldb
#
# Comments about the lldb python api:
# - there are no accessors, i.e. valobj["name"]
# - http://lldb.llvm.org/python_reference/index.html seems to be outdated
# - there is no autoload support, i.e. can't load this file automatically
# when 'mono' is the debugger target.
import lldb
# FIXME: Generate enums from runtime enums
MONO_TYPE_END = 0x00
MONO_TYPE_VOID = 0x01
MONO_TYPE_BOOLEAN = 0x02
MONO_TYPE_CHAR = 0x03
MONO_TYPE_I1 = 0x04
MONO_TYPE_U1 = 0x05
MONO_TYPE_I2 = 0x06
MONO_TYPE_U2 = 0x07
MONO_TYPE_I4 = 0x08
MONO_TYPE_U4 = 0x09
MONO_TYPE_I8 = 0x0a
MONO_TYPE_U8 = 0x0b
MONO_TYPE_R4 = 0x0c
MONO_TYPE_R8 = 0x0d
MONO_TYPE_STRING = 0x0e
MONO_TYPE_PTR = 0x0f
MONO_TYPE_BYREF = 0x10
MONO_TYPE_VALUETYPE = 0x11
MONO_TYPE_CLASS = 0x12
MONO_TYPE_VAR = 0x13
MONO_TYPE_ARRAY = 0x14
MONO_TYPE_GENERICINST= 0x15
MONO_TYPE_TYPEDBYREF = 0x16
MONO_TYPE_I = 0x18
MONO_TYPE_U = 0x19
MONO_TYPE_FNPTR = 0x1b
MONO_TYPE_OBJECT = 0x1c
MONO_TYPE_SZARRAY = 0x1d
MONO_TYPE_MVAR = 0x1e
primitive_type_names = {
MONO_TYPE_BOOLEAN : "bool",
MONO_TYPE_CHAR : "char",
MONO_TYPE_I1 : "sbyte",
MONO_TYPE_U1 : "byte",
MONO_TYPE_I2 : "short",
MONO_TYPE_U2 : "ushort",
MONO_TYPE_I4 : "int",
MONO_TYPE_U4 : "uint",
MONO_TYPE_I8 : "long",
MONO_TYPE_U8 : "ulong",
MONO_TYPE_R4 : "float",
MONO_TYPE_R8 : "double",
MONO_TYPE_STRING : "string"
}
#
# Helper functions for working with the lldb python api
#
def member(val, member_name):
return val.GetChildMemberWithName (member_name)
def string_member(val, member_name):
return val.GetChildMemberWithName (member_name).GetSummary ()[1:-1]
def isnull(val):
return val.deref.addr.GetOffset () == 0
def stringify_class_name(ns, name):
if ns == "System":
if name == "Byte":
return "byte"
if name == "String":
return "string"
if ns == "":
return name
else:
return "{0}.{1}".format (ns, name)
#
# Pretty printers for mono runtime types
#
def stringify_type (type):
"Print a MonoType structure"
ttype = member(type, "type").GetValueAsUnsigned()
if primitive_type_names.has_key (ttype):
return primitive_type_names [ttype]
else:
return "<MonoTypeEnum 0x{0:x}>".format (ttype)
def stringify_ginst (ginst):
"Print a MonoGenericInst structure"
len = int(member(ginst, "type_argc").GetValue())
argv = member(ginst, "type_argv")
res=""
for i in range(len):
t = argv.GetChildAtIndex(i, False, True)
if i > 0:
res += ", "
res += stringify_type(t)
return res
def print_type(valobj, internal_dict):
type = valobj
if isnull (type):
return ""
return stringify_type (type)
def print_class (valobj, internal_dict):
klass = valobj
if isnull (klass):
return ""
aname = member (member (member (klass, "image"), "assembly"), "aname")
basename = "[{0}]{1}".format (string_member (aname, "name"), (stringify_class_name (string_member (klass, "name_space"), string_member (klass, "name"))))
gclass = member (klass, "generic_class")
if not isnull (gclass):
ginst = member (member (gclass, "context"), "class_inst")
return "{0}<{1}>".format (basename, stringify_ginst (ginst))
return basename
def print_method (valobj, internal_dict):
method = valobj
if isnull (method):
return ""
klass = member (method, "klass")
return "{0}:{1}()".format (print_class (klass, None), string_member (valobj, "name"))
def print_domain(valobj, internal_dict):
domain = valobj
if isnull (domain):
return ""
target = domain.target
root = target.FindFirstGlobalVariable("mono_root_domain")
name = string_member (domain, "friendly_name")
if root.IsValid () and root.deref.addr.GetOffset () == root.deref.addr.GetOffset ():
return "[root]"
else:
return "[{0}]".format (name)
def print_object(valobj, internal_dict):
obj = valobj
if isnull (obj):
return ""
domain = member (member (obj, "vtable"), "domain")
klass = member (member (obj, "vtable"), "klass")
return print_domain (domain, None) + print_class (klass, None)
# Register pretty printers
# FIXME: This cannot pick up the methods define in this module, leading to warnings
lldb.debugger.HandleCommand ("type summary add -w mono -F mono.print_method MonoMethod")
lldb.debugger.HandleCommand ("type summary add -w mono -F mono.print_class MonoClass")
lldb.debugger.HandleCommand ("type summary add -w mono -F mono.print_type MonoType")
lldb.debugger.HandleCommand ("type summary add -w mono -F mono.print_domain MonoDomain")
lldb.debugger.HandleCommand ("type summary add -w mono -F mono.print_object MonoObject")
lldb.debugger.HandleCommand ("type category enable mono")
# Helper commands for runtime debugging
# These resume the target
# Print the method at the current ip
lldb.debugger.HandleCommand ("command alias pip p mono_print_method_from_ip((void*)$pc)")
# Print the method at the provided ip
lldb.debugger.HandleCommand ("command regex pmip 's/^$/p mono_print_method_from_ip((void*)$pc)/' 's/(.+)/p mono_print_method_from_ip((void*)(%1))/'")
print "Mono support mode loaded."
+76 -10
View File
@@ -102,15 +102,35 @@ Global locks:
Adding global locks is not to be taken lightly.
The current lock hierarchy:
loader lock
domain lock
domain jit lock
loader lock (global)
domain lock (complex)
domain jit lock (complex)
marshal lock
simple locks
Examples:
You can take the loader lock without holding a domain lock.
You cannot take a domain lock if the loader lock is held.
You can take the domain load while holding the loader lock
You cannot take the loader lock if only the domain lock is held.
You cannot take a domain lock while holding the lock to another domain.
TODO:
We have a few known ok violation. We need a way to whitelist them.
Known ok issues:
ERROR: tried to acquire lock DomainLock at mono_domain_code_reserve_align while holding DomainLock at mono_class_create_runtime_vtable: Hierarchy violation.
This is triggered when building the vtable of a non-root domain and fetching a vtable trampoline for an offset that has not been built. We'll take the root
domain lock while holding the other one.
This is ok since we never allow locking to have in the other direction, IOW, the root-domain lock is one level down from the other domain-locks.
WARNING: tried to acquire lock ImageDataLock at mono_image_init_name_cache while holding ImageDataLock at mono_class_from_name
WARNING: tried to acquire lock ImageDataLock at mono_image_init_name_cache while holding ImageDataLock at mono_image_add_to_name_cache
Both of those happen when filling up the name_cache, as it needs to alloc image memory.
This one is fixable by spliting mono_image_init_name_cache into a locked and an unlocked variants and calling them appropriatedly.
*/
public enum Lock {
@@ -120,6 +140,12 @@ public enum Lock {
DomainLock,
DomainAssembliesLock,
DomainJitCodeHashLock,
IcallLock,
AssemblyBindingLock,
MarshalLock,
ClassesLock,
LoaderGlobalDataLock,
ThreadsLock,
}
public class SimLock
@@ -139,6 +165,7 @@ public class SimLock
case Lock.DomainLock:
return 1;
case Lock.DomainJitCodeHashLock:
case Lock.MarshalLock:
return 2;
default:
return 3;
@@ -157,6 +184,10 @@ public class SimLock
get { return kind == Lock.LoaderLock; }
}
public bool IsResursiveLock {
get { return kind == Lock.LoaderLock || kind == Lock.DomainLock; }
}
/*locked is already owned by the thread, 'this' is the new one*/
bool Compare (SimThread thread, SimLock locked, out bool isWarning, out string msg)
{
@@ -212,7 +243,24 @@ public class SimLock
}
public override string ToString () {
return String.Format ("{0}", kind);
switch (kind) {
case Lock.LoaderLock:
case Lock.IcallLock:
case Lock.AssemblyBindingLock:
case Lock.MarshalLock:
case Lock.ClassesLock:
case Lock.LoaderGlobalDataLock:
case Lock.ThreadsLock:
return String.Format ("{0}", kind);
case Lock.ImageDataLock:
case Lock.DomainLock:
case Lock.DomainAssembliesLock:
case Lock.DomainJitCodeHashLock:
return String.Format ("{0}[{1}]", kind, id);
default:
return String.Format ("Unknown({0})[{1}]", kind, id);
}
}
}
@@ -276,6 +324,15 @@ public class Trace {
"mono_loader_unlock",
"mono_image_lock",
"mono_image_unlock",
"mono_icall_lock",
"mono_icall_unlock",
"add_record",
"mono_locks_lock_acquired",
"mono_locks_lock_released",
"mono_threads_lock",
"mono_threads_unlock",
"mono_domain_lock",
"mono_domain_unlock",
};
public Trace (string[] fields) {
@@ -326,6 +383,10 @@ public class Symbol : IComparable<Symbol>
public int CompareTo(Symbol other) {
return offset - other.offset;
}
public void AdjustSize (Symbol next) {
size = next.offset - this.offset;
}
}
public interface SymbolTable {
@@ -352,21 +413,26 @@ public class OsxSymbolTable : SymbolTable
string line;
while ((line = proc.StandardOutput.ReadLine ()) != null) {
string[] fields = line.Split(new char[] {' ', '\t'}, StringSplitOptions.RemoveEmptyEntries);
if (fields.Length < 4)
if (fields.Length < 7)
continue;
if (!(fields [1].Equals ("g") || fields [1].Equals ("d")))
continue;
if (!fields [2].Equals ("*UND*"))
if (!fields [3].Equals ("FUN"))
continue;
int offset = fields [0].ParseHex ();
string name = fields [3];
string name = fields [6];
if (name.StartsWith ("_"))
name = name.Substring (1);
if (offset != 0)
list.Add (new Symbol (offset, 0, name));
}
table = new Symbol [list.Count];
list.CopyTo (table, 0);
Array.Sort (table);
for (int i = 1; i < table.Length; ++i) {
table [i - 1].AdjustSize (table [i]);
}
}
public string Translate (int offset) {
+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/2.0/nunit.core.dll -r:${libdir}/mono/2.0/nunit.core.interfaces.dll -r:${libdir}/mono/2.0/nunit.core.extensions.dll -r:${libdir}/mono/2.0/nunit.framework.dll -r:${libdir}/mono/2.0/nunit.framework.extensions.dll -r:${libdir}/mono/2.0/nunit.mocks.dll -r:${libdir}/mono/2.0/nunit.util.dll -r:${libdir}/mono/2.0/nunit-console-runner.dll
Libs: -r:${libdir}/mono/4.5/nunit.core.dll -r:${libdir}/mono/4.5/nunit.core.interfaces.dll -r:${libdir}/mono/4.5/nunit.core.extensions.dll -r:${libdir}/mono/4.5/nunit.framework.dll -r:${libdir}/mono/4.5/nunit.framework.extensions.dll -r:${libdir}/mono/4.5/nunit.mocks.dll -r:${libdir}/mono/4.5/nunit.util.dll -r:${libdir}/mono/4.5/nunit-console-runner.dll
+1 -24
View File
@@ -21,21 +21,8 @@ provider mono {
probe gc__requested (int generation, uintptr_t requested_size, int wait_to_finish);
probe gc__checkpoint__1 (int generation);
probe gc__checkpoint__2 (int generation);
probe gc__checkpoint__3 (int generation);
probe gc__checkpoint__4 (int generation);
probe gc__checkpoint__5 (int generation);
probe gc__checkpoint__6 (int generation);
probe gc__checkpoint__7 (int generation);
probe gc__checkpoint__8 (int generation);
probe gc__checkpoint__9 (int generation);
probe gc__concurrent__start__begin (int generation);
probe gc__concurrent__start__end (int generation, long long num_major_objects_marked);
probe gc__concurrent__update__finish__begin (int generation, long long num_major_objects_marked);
probe gc__concurrent__update__end (int generation, long long num_major_objects_marked);
probe gc__concurrent__finish__end (int generation, long long num_major_objects_marked);
probe gc__sweep__begin (int generation, int full_sweep);
probe gc__sweep__end (int generation, int full_sweep);
@@ -45,19 +32,12 @@ provider mono {
probe gc__world__restart__begin (int generation);
probe gc__world__restart__end (int generation);
probe gc__heap__alloc (uintptr_t addr, uintptr_t len);
probe gc__heap__free (uintptr_t addr, uintptr_t len);
probe gc__locked ();
probe gc__unlocked ();
probe gc__nursery__tlab__alloc (uintptr_t addr, uintptr_t len);
probe gc__nursery__obj__alloc (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
probe gc__major__obj__alloc__large (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
probe gc__major__obj__alloc__pinned (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
probe gc__major__obj__alloc__degraded (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
probe gc__major__obj__alloc__mature (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
/* Can be nursery->nursery, nursery->major or major->major */
probe gc__obj__moved (uintptr_t dest, uintptr_t src, int dest_gen, int src_gen, uintptr_t size, char *ns_name, char *class_name);
@@ -70,13 +50,10 @@ provider mono {
probe gc__finalize__enqueue (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name, int generation, int is_critical);
probe gc__finalize__invoke (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
probe gc__weak__update (uintptr_t ref_addr, uintptr_t old_addr, uintptr_t new_addr, uintptr_t size, char *ns_name, char *class_name, int track);
probe gc__weak__update (uintptr_t ref_addr, uintptr_t new_addr, uintptr_t size, char *ns_name, char *class_name, int track);
probe gc__global__remset__add (uintptr_t ref_addr, uintptr_t obj_addr, uintptr_t size, char *ns_name, char *class_name);
probe gc__obj__cemented (uintptr_t addr, uintptr_t size, char *ns_name, char *class_name);
probe gc__internal__alloc (uintptr_t addr, uintptr_t size, int type);
probe gc__internal__dealloc (uintptr_t add, uintptr_t size, int type);
};
#pragma D attributes Evolving/Evolving/Common provider mono provider
-4
View File
@@ -1,4 +0,0 @@
Name: Mono.Web
Description: Mono ASP.NET extension classes
Version: 2.0.0.0
Libs: -r:@prefix@/lib/mono/gac/Mono.Web/2.0.0.0__0738eb9f132ed756/Mono.Web.dll
+2 -2
View File
@@ -1,6 +1,6 @@
monodir = $(sysconfdir)/mono/2.0/Browsers
EXTRA_DIST = Compat.browser
EXTRA_DIST = ../../Browsers/Compat.browser
mono_DATA = Compat.browser
mono_DATA = ../../Browsers/Compat.browser
+2 -2
View File
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<settingsMap>
<map sectionType="System.Web.Configuration.MembershipSection, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
mapperType="Mono.Web.Util.MembershipSectionMapper, Mono.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756"
mapperType="Mono.Web.Util.MembershipSectionMapper, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
platform="Unix">
<!-- The 'what' tag specifies which region of the section to modify. The 'value' attribute value is mapper-specific and is not defined here. It can be
@@ -24,7 +24,7 @@
</map>
<map sectionType="System.Web.Configuration.RoleManagerSection, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
mapperType="Mono.Web.Util.RoleManagerSectionMapper, Mono.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756"
mapperType="Mono.Web.Util.RoleManagerSectionMapper, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
platform="Unix">
<!-- The 'what' tag specifies which region of the section to modify. The 'value' attribute value is mapper-specific and is not defined here. It can be
File renamed without changes.
+6
View File
@@ -0,0 +1,6 @@
monodir = $(sysconfdir)/mono/4.0/Browsers
EXTRA_DIST = ../../Browsers/Compat.browser
mono_DATA = ../../Browsers/Compat.browser
+1 -1
View File
@@ -1,4 +1,4 @@
SUBDIRS =
SUBDIRS = Browsers
monodir = $(sysconfdir)/mono/4.0
+2 -2
View File
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<settingsMap>
<map sectionType="System.Web.Configuration.MembershipSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
mapperType="Mono.Web.Util.MembershipSectionMapper, Mono.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756"
mapperType="Mono.Web.Util.MembershipSectionMapper, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
platform="Unix">
<!-- The 'what' tag specifies which region of the section to modify. The 'value' attribute value is mapper-specific and is not defined here. It can be
@@ -24,7 +24,7 @@
</map>
<map sectionType="System.Web.Configuration.RoleManagerSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
mapperType="Mono.Web.Util.RoleManagerSectionMapper, Mono.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756"
mapperType="Mono.Web.Util.RoleManagerSectionMapper, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
platform="Unix">
<!-- The 'what' tag specifies which region of the section to modify. The 'value' attribute value is mapper-specific and is not defined here. It can be
+2
View File
@@ -0,0 +1,2 @@
/Makefile
/Makefile.in
+6
View File
@@ -0,0 +1,6 @@
monodir = $(sysconfdir)/mono/4.5/Browsers
EXTRA_DIST = ../../Browsers/Compat.browser
mono_DATA = ../../Browsers/Compat.browser
+1 -1
View File
@@ -1,4 +1,4 @@
SUBDIRS =
SUBDIRS = Browsers
monodir = $(sysconfdir)/mono/4.5
+4 -1
View File
@@ -13,11 +13,14 @@
<section name="startup" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowLocation="false"/>
<section name="system.codedom" type="System.CodeDom.Compiler.CodeDomConfigurationHandler, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<section name="system.data" type="System.Data.Common.DbProviderFactoriesConfigurationHandler, System.Data, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<section name="system.diagnostics" type="System.Diagnostics.DiagnosticsConfigurationHandler, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<section name="system.diagnostics" type="System.Diagnostics.SystemDiagnosticsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<section name="system.runtime.remoting" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowLocation="false"/>
<section name="system.windows.forms" type="System.Windows.Forms.WindowsFormsSection, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
<section name="windows" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowLocation="false" />
<section name="strongNames" type="System.Configuration.IgnoreSection, System.Configuration, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowLocation="false"/>
<sectionGroup name="system.runtime.serialization" type="System.Runtime.Serialization.Configuration.SerializationSectionGroup, System.Runtime.Serialization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<section name="dataContractSerializer" type="System.Runtime.Serialization.Configuration.DataContractSerializerSection, System.Runtime.Serialization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
</sectionGroup>
<sectionGroup name="system.web" type="System.Web.Configuration.SystemWebSectionGroup, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<section name="anonymousIdentification" type="System.Web.Configuration.AnonymousIdentificationSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowDefinition="MachineToApplication"/>
<section name="authentication" type="System.Web.Configuration.AuthenticationSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" allowDefinition="MachineToApplication"/>
+2 -2
View File
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8" ?>
<settingsMap>
<map sectionType="System.Web.Configuration.MembershipSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
mapperType="Mono.Web.Util.MembershipSectionMapper, Mono.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756"
mapperType="Mono.Web.Util.MembershipSectionMapper, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
platform="Unix">
<!-- The 'what' tag specifies which region of the section to modify. The 'value' attribute value is mapper-specific and is not defined here. It can be
@@ -24,7 +24,7 @@
</map>
<map sectionType="System.Web.Configuration.RoleManagerSection, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
mapperType="Mono.Web.Util.RoleManagerSectionMapper, Mono.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756"
mapperType="Mono.Web.Util.RoleManagerSectionMapper, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
platform="Unix">
<!-- The 'what' tag specifies which region of the section to modify. The 'value' attribute value is mapper-specific and is not defined here. It can be
+7
View File
@@ -0,0 +1,7 @@
bindir=${pcfiledir}/../mono/xbuild/12.0/bin
Name: XBuild 12.0
Description: XBuild/MSBuild 12.0
Version: 12.0
Libs: -r:${bindir}/Microsoft.Build.Engine.dll -r:${bindir}/Microsoft.Build.Framework.dll -r:${bindir}/Microsoft.Build.Tasks.v12.0.dll -r:${bindir}/Microsoft.Build.Utilities.v12.0.dll -r:${bindir}/Microsoft.Build.dll
+29 -36
View File
@@ -14,7 +14,6 @@ ASSEMBLED_DOCS = \
EXTRA_DIST = \
abc-removal.txt \
api-style.css \
assembly-bundle \
check-exports \
check-coverage \
convert.cs \
@@ -23,7 +22,6 @@ EXTRA_DIST = \
docs.make \
documented \
embedded-api \
exceptions \
exdoc \
file-share-modes \
gc-issues \
@@ -35,35 +33,31 @@ EXTRA_DIST = \
jit-imt \
jit-thoughts \
jit-trampolines \
local-regalloc.txt \
magic.diff \
mini-doc.txt \
mono-api-metadata.html \
mono-file-formats.config\
mono-file-formats.source\
mono_handle_d \
mono-tools.config \
mono-tools.source \
monoapi.source \
new-regalloc \
object-layout \
opcode-decomp.txt \
precise-gc \
produce-lists \
public \
public-api \
README \
release-notes-1.0.html \
remoting \
ssapre.txt \
stack-alignment \
stack-overflow.txt \
threading \
toc.xml \
TODO \
tree-mover.txt \
unmanaged-calls
-include $(mcs_topdir)/build/config.make
CLASS=$(mcs_topdir)/class/lib/$(DEFAULT_PROFILE)
dist-hook:
$(mkdir_p) $(distdir)/sources
$(mkdir_p) $(distdir)/svgs
@@ -73,41 +67,40 @@ dist-hook:
cp HtmlAgilityPack/* $(distdir)/HtmlAgilityPack
clean-local:
-rm -Rf $(srcdir)/html
-rm -f $(srcdir)/deploy/* $(srcdir)/convert.exe* $(srcdir)/AgilityPack.dll*
-cd $(srcdir) && rm -f $(ASSEMBLED_DOCS)
-rm -Rf html
-rm -f deploy/* convert.exe* AgilityPack.dll*
-rm -f $(ASSEMBLED_DOCS)
TOOL_MAKE=$(MAKE) -f $(srcdir)/docs.make topdir=$(srcdir)/../mcs srcdir=$(srcdir)
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 perms
cd $(srcdir) && cp -f api-style.css deploy
cd $(srcdir) && $(MAKE) -f docs.make topdir=$(mcs_topdir_from_srcdir) $@
monoapi.tree: $(srcdir)/docs.make $(srcdir)/Makefile.am $(srcdir)/toc.xml $(srcdir)/deploy/.stamp
-mkdir -p deploy
cp -f $(srcdir)/api-style.css deploy
$(TOOL_MAKE) $@
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 perms
cd $(srcdir) && $(MAKE) -f docs.make topdir=$(mcs_topdir_from_srcdir) $@
mono-file-formats.zip: mono-file-formats.tree perms
@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-tools.tree: $(srcdir)/docs.make Makefile.am deploy/.stamp
$(TOOL_MAKE) $@
$(srcdir)/deploy/.stamp: convert.exe Makefile.am perms
$(mkdir_p) $(srcdir)/html
mono-file-formats.zip: mono-file-formats.tree
mono-file-formats.tree: $(srcdir)/docs.make $(srcdir)/Makefile.am $(srcdir)/deploy/.stamp
$(TOOL_MAKE) $@
deploy/.stamp: convert.exe Makefile.am
$(mkdir_p) html
runtimedir=`cd ../runtime && pwd`; export runtimedir; \
cd $(srcdir) && MONO_PATH=$(mcs_topdir_from_srcdir)/class/lib/net_2_0 perl ./exdoc -h . ../mono/*/*.c
MONO_PATH=$(CLASS) perl $(srcdir)/exdoc -h $(srcdir) -t . $(srcdir)/../mono/*/*.c
touch $@
extract: $(srcdir)/deploy/.stamp
extract: deploy/.stamp
convert.exe: convert.cs AgilityPack.dll perms
cd $(srcdir) && $(MAKE) PROFILE=net_2_0 -f docs.make topdir=$(mcs_topdir_from_srcdir) convert.exe
convert.exe: convert.cs AgilityPack.dll
$(TOOL_MAKE) convert.exe
AgilityPack.dll: perms
cd $(srcdir) && $(MAKE) PROFILE=net_2_0 -f docs.make topdir=$(mcs_topdir_from_srcdir) AgilityPack.dll
.PHONY: perms
perms:
-@test -w $(srcdir) || chmod a+w $(srcdir)
AgilityPack.dll:
$(TOOL_MAKE) AgilityPack.dll
-57
View File
@@ -1,57 +0,0 @@
HOWTO bundle assemblies inside the mono runtime.
Paolo Molaro ([email protected])
* Intent
Bundling assemblies inside the mono runtime may be useful for a number
of reasons:
* creating a standalone complete runtime that can be more easily
distributed
* having an application run against a known set of assemblies
that has been tested
Of course, there are drawbacks, too: if there has been fixes
to the assemblies, replacing them means recompiling the
runtime as well and if there are other mono apps, unless they
use the same mono binary, there will be less opportunities for
the operating system to optimize memory usage. So use this
feature only when really needed.
* Creating the Bundle
To bundle a set of assemblies, you need to create a file that
lists the assembly names and the relative files. Empty lines
and lines starting with # are ignored:
== cut cut ==
# Sample bundle template
mscorlib: /path/to/mscorlib/assembly.dll
myapp: /path/to/myapp.exe
== cut cut ==
Next you need to build the mono runtime using a special configure option:
./configure --with-bundle=/path/to/bundle/template
The path to the template should be an absolute path.
The script metadata/make-bundle.pl will take the specifie
assemblies and embed them inside the runtime where the loading
routines can find them before searching for them on disk.
* Open Issues
There are still two issues to solve:
* config files: sometimes they are needed but they are
not yet bundled inside the library ()
* building with the included libgc makes it not
possible to build a mono binary statically linked to
libmono: this needs to be fixed to make bundles
really useful.
+1 -4
View File
@@ -292,7 +292,6 @@ mono_free_method
mono_free_verify_list
mono_gc_collect
mono_gc_collection_count
mono_gc_enable_events
mono_gc_get_generation
mono_gc_get_heap_size
mono_gc_get_used_size
@@ -301,12 +300,11 @@ mono_gchandle_get_target
mono_gchandle_new
mono_gchandle_new_weakref
mono_gc_invoke_finalizers
mono_gc_is_finalizer_thread
mono_gc_max_generation
mono_gc_out_of_memory
mono_gc_wbarrier_arrayref_copy
mono_gc_wbarrier_generic_nostore
mono_gc_wbarrier_generic_store
mono_gc_wbarrier_generic_store_atomic
mono_gc_wbarrier_object_copy
mono_gc_wbarrier_set_arrayref
mono_gc_wbarrier_set_field
@@ -603,7 +601,6 @@ mono_object_get_class
mono_object_get_domain
mono_object_get_size
mono_object_get_virtual_method
mono_object_is_alive
mono_object_isinst
mono_object_isinst_mbyref
mono_object_new
+13 -5
View File
@@ -1,3 +1,8 @@
#
# This makefile is here because it uses the configuration from the
# in-place built mono to run and compile a few C# tools
#
thisdir = docs
SUBDIRS =
include $(topdir)/build/rules.make
@@ -7,25 +12,28 @@ ASSEMBLED_DOCS = \
mono-tools.tree mono-tools.zip \
monoapi.tree monoapi.zip
convert.exe: convert.cs AgilityPack.dll
convert.exe: $(srcdir)/convert.cs AgilityPack.dll
$(CSCOMPILE) -out:$@ $< -r:AgilityPack.dll
AgilityPack.dll:
$(CSCOMPILE) -target:library -out:$@ HtmlAgilityPack/*.cs
$(CSCOMPILE) -target:library -out:$@ $(srcdir)/HtmlAgilityPack/*.cs
monoapi.zip: monoapi.tree
@test -f $@ || { rm -f $< && $(MAKE) $<; }
monoapi.tree: toc.xml docs.make
monoapi.tree: $(srcdir)/toc.xml $(srcdir)/docs.make
$(MDOC) assemble -o monoapi -f hb $<
mono-tools.zip: mono-tools.tree
@test -f $@ || { rm -f $< && $(MAKE) $<; }
mono-tools.tree: mono-tools.config docs.make
mono-tools.tree: $(srcdir)/mono-tools.config $(srcdir)/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.tree: mono-file-formats.config docs.make
mono-file-formats.tree: $(srcdir)/mono-file-formats.config $(srcdir)/docs.make
$(MDOC) assemble -o mono-file-formats -f man $<
.doc-stamp:
-4
View File
@@ -269,12 +269,9 @@ mono_gc_weak_link_get
mono_gc_weak_link_remove
mono_gc_disable
mono_gc_enable
mono_gc_is_finalizer_thread
mono_gc_out_of_memory
mono_gc_start_world
mono_gc_stop_world
mono_gc_alloc_fixed
mono_gc_enable_events
mono_gc_free_fixed
mono_gc_make_descr_from_bitmap
mono_gc_base_init
@@ -526,7 +523,6 @@ mono_object_isinst
mono_object_register_finalizer
mono_object_unbox
mono_object_castclass_mbyref
mono_object_is_alive
mono_object_get_size
mono_value_box
mono_value_copy
-37
View File
@@ -71,40 +71,3 @@ unwinding code.
catch handler: catch hanlders are always called from the stack unwinding
code. The exception object is passed in a local variable (cfg->exvar).
gcc support for Exceptions
==========================
gcc supports exceptions in files compiled with the -fexception option. gcc
generates DWARF exceptions tables in that case, so it is possible to unwind the
stack. The method to read those exception tables is contained in libgcc.a, and
in newer versions of glibc (glibc 2.2.5 for example), and it is called
__frame_state_for(). Another usable glibc function is backtrace_symbols() which
returns the function name corresponding to a code address.
We dynamically check if those features are available using g_module_symbol(),
and we use them only when available. If not available we use the LMF as
fallback.
Using gcc exception information prevents us from saving the LMF at each native
call, so this is a way to speed up native calls. This is especially valuable
for internal calls, because we can make sure that all internal calls are
compiled with -fexceptions (we compile the whole mono runtime with that
option).
All native function are able to call function without exception tables, and so
we are unable to restore all caller saved registers if an exception is raised
in such function. Well, its possible if the previous function already saves all
registers. So we only omit the the LMF if a function has an exception table
able to restore all caller saved registers.
One problem is that gcc almost never saves all caller saved registers, because
it is just unnecessary in normal situations. But there is a trick forcing gcc
to save all register, we just need to call __builtin_unwind_init() at the
beginning of a function. That way gcc generates code to save all caller saved
register on the stack.
+9 -3
View File
@@ -1,17 +1,23 @@
#!/usr/bin/perl
if ($ARGV[0] eq "-h"){
$dir = $ARGV[1];
$sourcedir = $ARGV[1];
$dir = $sourcedir;
$html = 1;
shift @ARGV;
shift @ARGV;
}
if ($ARGV[0] eq "-t"){
$dir = $ARGV[1];
shift @ARGV;
}
if ($html){
opendir (D, "$dir/sources/") || die "Can not open $dir";
opendir (D, "$sourcedir/sources/") || die "Can not open $dir";
while ($n = readdir (D)){
if ($n =~ /mono-api-.*\.html$/){
open (IN, "$dir/sources/$n") || die "Can not open $n";
open (IN, "$sourcedir/sources/$n") || die "Can not open $n";
$files[$filecount] = $n;
while (<IN>){
@files_content[$filecount] .= $_;
-208
View File
@@ -1,208 +0,0 @@
* Proposal for the local register allocator
The local register allocator deals with allocating registers
for temporaries inside a single basic block, while the global
register allocator is concerned with method-wide allocation of
variables.
The global register allocator uses callee-saved register for it's
purpouse so that there is no need to save and restore these registers
at call sites.
There are a number of issues the local allocator needs to deal with:
*) some instructions expect operands in specific registers (for example
the shl instruction on x86, or the call instruction with thiscall
convention, or the equivalent call instructions on other architectures,
such as the need to put output registers in %oX on sparc)
*) some instructions deliver results only in specific registers (for example
the div instruction on x86, or the call instructionson on almost all
the architectures).
*) it needs to know what registers may be clobbered by an instruction
(such as in a method call)
*) it should avoid excessive reloads or stores to improve performance
While which specific instructions have limitations is architecture-dependent,
the problem shold be solved in an arch-independent way to reduce code duplication.
The register allocator will be 'driven' by the arch-dependent code, but it's
implementation should be arch-independent.
To improve the current local register allocator, we need to
keep more state in it than the current setup that only keeps busy/free info.
Possible state information is:
free: the resgister is free to use and it doesn't contain useful info
freeable: the register contains data loaded from a local (there is
also info about _which_ local it contains) as a result from previous
instructions (like, there was a store from the register to the local)
moveable: it contains live data that is needed in a following instruction, but
the contents may be moved to a different register
busy: the register contains live data and it is placed there because
the following instructions need it exactly in that register
allocated: the register is used by the global allocator
The local register allocator will have the following interfaces:
int get_register ();
Searches for a register in the free state. If it doesn't find it,
searches for a freeable register. Sets the status to moveable.
Looking for a 'free' register before a freeable one should allow for
removing a few redundant loads (though I'm still unsure if such
things should be delegated entirely to the peephole pass).
int get_register_force (int reg);
Returns 'reg' if it is free or freeable. If it is moveable, it moves it
to another free or freeable register.
Sets the status of 'reg' to busy.
void set_register_freeable (int reg);
Sets the status of 'reg' to freeable.
void set_register_free (int reg);
Sets the status of 'reg' to free.
void will_clobber (int reg);
Spills the register to the stack. Sets the status to freeable.
After the clobbering has occurred, set the status to free.
void register_unspill (int reg);
Un-spills register reg and sets the status to moveable.
FIXME: how is the 'local' information represented? Maybe a MonoInst* pointer.
Note: the register allocator will insert instructions in the basic block
during it's operation.
* Examples
Given the tree (on x86 the right argument to shl needs to be in ecx):
store (local1, shl (local1, call (some_arg)))
At the start of the basic block, the registers are set to the free state.
The sequence of instructions may be:
instruction register status -> [%eax %ecx %edx]
start free free free
eax = load local1 mov free free
/* call clobbers eax, ecx, edx */
spill eax free free free
call mov free free
/* now eax contains the right operand of the shl */
mov %eax -> %ecx free busy free
un-spill mov busy free
shl %cl, %eax mov free free
The resulting x86 code is:
mov $fffc(%ebp), %eax
mov %eax, $fff0(%ebp)
push some_arg
call func
mov %eax, %ecx
mov $fff0(%ebp), %eax
shl %cl, %eax
Note that since shl could operate directly on memory, we could have:
push some_arg
call func
mov %eax, %ecx
shl %cl, $fffc(%ebp)
The above example with loading the operand in a register is just to complicate
the example and show that the algorithm should be able to handle it.
Let's take another example with the this-call call convention (the first argument
is passed in %ecx).
In this case, will_clobber() will be called only on %eax and %edx, while %ecx
will be allocated with get_register_force ().
Note: when a register is allocated with get_register_force(), it should be set
to a different state as soon as possible.
store (local1, shl (local1, this-call (local1)))
instruction register status -> [%eax %ecx %edx]
start free free free
eax = load local1 mov free free
/* force load in %ecx */
ecx = load local1 mov busy free
spill eax free busy free
call mov free free
/* now eax contains the right operand of the shl */
mov %eax -> %ecx free busy free
un-spill mov busy free
shl %cl, %eax mov free free
What happens when a register that we need to allocate with get_register_force ()
contains an operand for the next instruction?
instruction register status -> [%eax %ecx %edx]
eax = load local0 mov free free
ecx = load local1 mov mov free
get_register_force (ecx) here.
We have two options:
mov %ecx, %edx
or:
spill %ecx
The first option is way better (and allows the peephole pass to
just load the value in %edx directly, instead of loading first to %ecx).
This doesn't work, though, if the instruction clobbers the %edx register
(like in a this-call). So, we first need to clobber the registers
(so the state of %ecx changes to freebale and there is no issue
with get_register_force ()).
What if an instruction both clobbers a register and requires it as
an operand? Lets' take the x86 idiv instruction as an example: it
requires the dividend in edx:eax and returns the result in eax,
with the modulus in edx.
store (local1, div (local1, local2))
instruction register status -> [%eax %ecx %edx]
eax = load local0 mov free free
will_clobber eax, edx free mov free
force mov %ecx, %eax busy free free
set %edx busy free busy
idiv mov free free
Note: edx is set to free after idiv, because the modulus is not needed
(if it was a rem, eax would have been freed).
If we load the divisor before will_clobber(), we'll have to spill
eax and reload it later. If we load it just after the idiv, there is no issue.
In any case, the algorithm should give the correct results and allow the operation.
Working recursively on the isntructions there shouldn't be huge issues
with this algorithm (though, of course, it's not optimal and it may
introduce excessive spills or register moves). The advantage over the current
local reg allocator is that:
1) the number of spills/moves would be smaller anyway
2) a separate peephole pass could be able to eliminate reg moves
3) we'll be able to remove the 'forced' spills we currently do with
the return value of method calls
* Issues
How to best integrate such a reg allocator with the burg stuff.
Think about a call os sparc with two arguments: they got into %o0 and %o1
and each of them sets the register as busy. But what if the values to put there
are themselves the result of a call? %o0 is no problem, but for all the
next argument n the above algorithm would spill all the 0...n-1 registers...
* Papers
More complex solutions to the local register allocator problem:
http://dimacs.rutgers.edu/TechnicalReports/abstracts/1997/97-33.html
Combining register allocation and instruction scheduling:
http://citeseer.nj.nec.com/motwani95combining.html
More on LRA euristics:
http://citeseer.nj.nec.com/liberatore97hardness.html
Linear-time optimal code scheduling for delayedload architectures
http://www.cs.wisc.edu/~fischer/cs701.f01/inst.sched.ps.gz
Precise Register Allocation for Irregular Architectures
http://citeseer.nj.nec.com/kong98precise.html
Allocate registers first to subtrees that need more of them.
http://www.upb.de/cs/ag-kastens/compii/folien/comment401-409.2.pdf
-98
View File
@@ -1,98 +0,0 @@
=pod
=head1 Internal design document for the mono_handle_d
This document is designed to hold the design of the mono_handle_d and
not as an api reference.
=head2 Primary goal and purpose
The mono_handle_d is a process which takes care of the (de)allocation
of scratch shared memory and handles (of files, threads, mutexes,
sockets etc. see L<WapiHandleType>) and refcounts of the
filehandles. It is designed to be run by a user and to be fast, thus
minimal error checking on input is done and will most likely crash if
given a faulty package. No effort has been, or should be, made to have
the daemon talking to machine of different endianness/size of int.
=head2 How to start the daemon
To start the daemon you either run the mono_handle_d executable or try
to attach to the shared memory segment via L<_wapi_shm_attach> which
will start a daemon if one does not exist.
=head1 Internal details
The daemon works by opening a socket and listening to clients. These
clients send packages over the socket complying to L<struct
WapiHandleRequest>.
=head2 Possible requests
=over
=item WapiHandleRequest_New
Find a handle in the shared memory segment that is free and allocate
it to the specified type. To destroy use
L</WapiHandleRequest_Close>. A L<WapiHandleResponse> with
.type=WapiHandleResponseType_New will be sent back with .u.new.handle
set to the handle that was allocated. .u.new.type is the type that was
requested.
=item WapiHandleRequestType_Open
Increase the ref count of an already created handle. A
L<WapiHandleResponse> with .type=WapiHandleResponseType_Open will be sent
back with .u.new.handle set to the handle, .u.new.type is set to the
type of handle this is.
=item WapiHandleRequestType_Close
Decrease the ref count of an already created handle. A
L<WapiHandleResponse> with .type=WapiHandleResponseType_Close will be
sent back with .u.close.destroy set to TRUE if ref count for this
client reached 0.
=item WapiHandleRequestType_Scratch
Allocate a shared memory area of size .u.scratch.length in bytes. A
L<WapiHandleResponse> with .type=WapiHandleResponseType_Scratch will be
sent back with .u.scratch.idx set to the index into the shared
memory's scratch area where to memory begins. (works just like
malloc(3))
=item WapiHandleRequestType_Scratch
Deallocate a shared memory area, this must have been allocated before
deallocating. A L<WapiHandleResponse> with
.type=WapiHandleResponseType_ScratchFree will be sent back (works just
like free(3))
=back
=head1 Why a daemon
From an email:
Dennis: I just have one question about the daemon... Why does it
exist? Isn't it better performancewise to just protect the shared area
with a mutex when allocation a new handle/shared mem segment or
changing refcnt? It will however be a less resilient to clients that
crash (the deamon cleans up ref'd handles if socket closes)
Dick: It's precisely because with a mutex the shared memory segment
can be left in a locked state. Also, it's not so easy to clean up
shared memory without it (you can't just mark it deleted when creating
it, because you can't attach any more readers to the same segment
after that). I did some minimal performance testing, and I don't
think the daemon is particularly slow.
=head1 Authors
Documentaion: Dennis Haney
Implementation: Dick Porter
=cut
-68
View File
@@ -1,68 +0,0 @@
We need to switch to a new register allocator.
The current one is split in a global and a local register allocator.
The global one can assign only callee-saves registers and happens
on the tree-based internal representation: it assigns local variables
to hardware registers.
The local one happens on the linear representation on a per basic
block basis and assigns hard registers to virtual registers (which
hold temporary values during expression executions) and it deals also
with the platform-specific issues (fixed registers, call conventions).
Moving to a different register will help solve some of the performance
issues introduced by the above split, make the register more easily
portable and solve some of the issues generated by dealing with trees.
The general design ideas are below.
The new allocator should have a global view of all the method, so it can be
able to assign variables also to some of the volatile registers if possible,
even across basic blocks (this would improve performance).
The allocator would be driven by per-arch declarative data, so porting
should be easier: an architecture needs to specify register classes,
call convention and instructions requirements (similar to the gcc code).
The allocator should operate on the linear representation, this way it's
easier and faster to track usages more correctly. We need to assign virtual
registers on a per-method basis instead of per basic block. We can assign
virtual registers to variables, too. Note that since we fix the stack offset
of local vars only after this step (which happens after the burg rules are run),
some of the burg rules that try to optimize the code won't apply anymore:
the peephole code may need to be enhanced to do the optimizations instead.
We need to handle floating point registers in the global allocator, too.
The new allocator also needs to keep track precisely of which registers
contain references or managed pointers to allow us to move to a precise GC.
It may be worth to use a single increasing set of integers for the virtual
registers, with the class of the register stored separately (unless the
current local allocator which keeps interger and fp registers separate).
Since this is a large task, we need to do it in steps as much as possible.
The first is to run the register allocator _after_ the burg rules: this
requires a rewrite of the liveness code, too, to use linear indexes instead
of basic-block/tree number combinations. This can be done by:
*) allocating virtual regs to all the locals that can be register allocated
*) running the burg rules (some may require adjustments): the local virtual
registers are assigned starting from global-virt-regs+1, instead of the current
hardware-regs+1, so we can tell apart global and local virt regs.
*) running the liveness/whatever code is needed to allocate the global registers
*) allocate the rest of the local variables to stack slots
*) continue with the current local allocator
This work could take 2-3 weeks.
The next step is to define the kind of declarative data an architecture needs
and assigning virtual regs to all the registers and making the allocator
assign from the volatile registers, too.
Note that some of the code that is currently emitted in the arch-specific
code, will need to be emitted as instructions that the reg allocator
can inspect: think of a method that returns the first argument which is
received in a register: the current code copies it to either a local slot or
to a global reg in the prolog an copies it back to the return register
int he basic block, but since neither the regallocator nor the peephole code
knows about the prolog code, the first store cannot be optimized away.
The gcc code has some example of how to specify register classes in a
declarative way.
-113
View File
@@ -1,113 +0,0 @@
* How to handle complex IL opcodes in an arch-independent way
Many IL opcodes are very simple: add, ldind etc.
Such opcodes can be implemented with a single cpu instruction
in most architectures (on some, a group of IL instructions
can be converted to a single cpu op).
There are many IL opcodes, though, that are more complex, but
can be expressed as a series of trees or a single tree of
simple operations. Such simple operations are architecture-independent.
It makes sense to decompose such complex IL instructions in their
simpler equivalent so that we gain in several ways:
*) porting effort is easier, because only the simple instructions
need to be implemented in arch-specific code
*) we could apply BURG rules to the trees and do pattern matching
on them to optimize the expressions according to the host cpu
The issue is: where do we do such conversion from coarse opcodes to
simple expressions?
* Doing the conversion in method_to_ir ()
Some of these conversions can certainly be done in method_to_ir (),
but it's not always easy to decide which are better done there and
which in a different pass.
For example, let's take ldlen: in the mono implementation, ldlen
can be simply implemented with a load from a fixed position in the
array object:
len = [reg + maxlen_offset]
However, ldlen carries also semantics information: the result is the
length of the array, and since in the CLR arrays are of fixed size,
this information can be useful to later do bounds check removal.
If we convert this opcode in method_to_ir () we lost some useful
information for further optimizations.
In some other ways, decomposing an opcode in method_to_ir() may
allow for better optimizations later on (need to come up with an
example here ...).
* Doing the conversion in inssel.brg
Some conversion may be done inside the burg rules: this has the
disadvantage that the instruction selector is not run again on
the resulting expression tree and we could miss some optimization
(this is what effectively happens with the coarse opcodes in the old
jit). This may also interfere with an efficient local register allocator.
It may be possible to add an extension in monoburg that allows a rule
such as:
recheck: LDLEN (reg) {
create an expression tree representing LDLEN
and return it
}
When the monoburg label process gets back a recheck, it will run
the labeling again on the resulting expression tree.
If this is possible at all (and in an efficient way) is a
question for dietmar:-)
It should be noted, though, that this may not always work, since
some complex IL opcodes may require a series of expression trees
and handling such cases in monoburg could become quite hairy.
For example, think of opcode that need to do multiple actions on the
same object: this basically means a DUP...
On the other end, if a complex opcode needs a DUP, monoburg doesn't
actually need to create trees if it emits the instructions in
the correct sequence and maintains the right values in the registers
(usually the values that need a DUP are not changed...). How
this integrates with the current register allocator is not clear, since
that assigns registers based on the rule, but the instructions emitted
by the rules may be different (this already happens with the current JIT
where a MULT is replaced with lea etc...).
* Doing it in a separate pass.
Doing the conversion in a separate pass over the instructions
is another alternative. This can be done right after method_to_ir ()
or after the SSA pass (since the IR after the SSA pass should look
almost like the IR we get back from method_to_ir ()).
This has the following advantages:
*) monoburg will handle only the simple opcodes (makes porting easier)
*) the instruction selection will be run on all the additional trees
*) it's easier to support coarse opcodes that produce multiple expression
trees (and apply the monoburg selector on all of them)
*) the SSA optimizer will see the original opcodes and will be able to use
the semantic info associated with them
The disadvantage is that this is a separate pass on the code and
it takes time (how much has not been measured yet, though).
With this approach, we may also be able to have C implementations
of some of the opcodes: this pass would insert a function call to
the C implementation (for example in the cases when first porting
to a new arch and implemenating some stuff may be too hard in asm).
* Extended basic blocks
IL code needs a lot of checks, bounds checks, overflow checks,
type checks and so on. This potentially increases by a lot
the number of basic blocks in a control flow graph. However,
all such blocks end up with a throw opcode that gives control to the
exception handling mechanism.
After method_to_ir () a MonoBasicBlock can be considered a sort
of extended basic block where the additional exits don't point
to basic blocks in the same procedure (at least when the method
doesn't have exception tables).
We need to make sure the passes following method_to_ir () can cope
with such kinds of extended basic blocks (especially the passes
that we need to apply to all the methods: as a start, we could
skip SSA optimizations for methods with exception clauses...)
+1 -4
View File
@@ -292,7 +292,6 @@ mono_free_method
mono_free_verify_list
mono_gc_collect
mono_gc_collection_count
mono_gc_enable_events
mono_gc_get_generation
mono_gc_get_heap_size
mono_gc_get_used_size
@@ -301,12 +300,11 @@ mono_gchandle_get_target
mono_gchandle_new
mono_gchandle_new_weakref
mono_gc_invoke_finalizers
mono_gc_is_finalizer_thread
mono_gc_max_generation
mono_gc_out_of_memory
mono_gc_wbarrier_arrayref_copy
mono_gc_wbarrier_generic_nostore
mono_gc_wbarrier_generic_store
mono_gc_wbarrier_generic_store_atomic
mono_gc_wbarrier_object_copy
mono_gc_wbarrier_set_arrayref
mono_gc_wbarrier_set_field
@@ -603,7 +601,6 @@ mono_object_get_class
mono_object_get_domain
mono_object_get_size
mono_object_get_virtual_method
mono_object_is_alive
mono_object_isinst
mono_object_isinst_mbyref
mono_object_new
-49
View File
@@ -1,49 +0,0 @@
With this change, we bundle Reactive Extensions from Microsoft.
Steps to do:
- Until we add submodule, check out Rx sources from http://rx.codeplex.com:
$ cd external
$ git clone git://github.com/atsushieno/rx.git
$ cd rx
$ git checkout rx-oss-v1.0
$ cd ../..
Note that the original repo at rx.codeplex.com will *fail* on Linux!
codeplex.codeplex.com/workitem/26133
Also note that rx.codeplex.com is huge and takes very long time to checkout.
- expand rx-mono-changes-3.tar.bz2
$ tar jxvf rx-mono-changes-3.tar.bz2
- Apply changes to mcs/class/Makefile:
$ cd mcs/class
$ patch -i add-rx-libs.patch -p3
$ cd ../..
Then it should be done.
Note that this does not include Mono.Reactive.Testing into the build yet -
this library depends on nunit.framework.dll but it wouldn't be built before
this assembly is built. This needs to be resolved.
** Current Status
- We don't have Microsoft.Reactive.Testing.dll. Instead, I created an
alternative Mono.Reactive.Testing.dll which *mostly* uses MS sources for
that assembly but uses NUnit.Framework instead.
To make it happen, I added a small script that automatically replaces
MSTest dependency parts with that for NUnit (replacer.sh under rx tree).
(We'll also have to rename namespaces and have more source changes, but
so far it is to get things runnable.)
- To check the build sanity, I imported unit tests (as explained above)
and it is supposed to run by "make run-test" in Mono.Reactive.Testing
directory (the tests were all in one place in MS tests, so I made it
in Mono.Reactive.Testing directory instead).
-16
View File
@@ -1,16 +0,0 @@
<h1>Mono 1.0 Release Notes</h1>
<h2>What does Mono Include</h2>
<h2>Missing functionality</h2>
<p>COM support.
<p>EnterpriseServices are non-existant.
<p>Windows.Forms is only available as a preview, it is not
completed nor stable.
<h3>Assembly: System.Drawing</h3>
<p>System.Drawing.Printing is not supported.
-3
View File
@@ -93,12 +93,9 @@
<h4><a name="api:mono_gc_disable">mono_gc_disable</a></h4>
<h4><a name="api:mono_gc_enable">mono_gc_enable</a></h4>
<h4><a name="api:mono_gc_is_finalizer_thread">mono_gc_is_finalizer_thread</a></h4>
<h4><a name="api:mono_gc_out_of_memory">mono_gc_out_of_memory</a></h4>
<h4><a name="api:mono_gc_start_world">mono_gc_start_world</a></h4>
<h4><a name="api:mono_gc_stop_world">mono_gc_stop_world</a></h4>
<h4><a name="api:mono_gc_alloc_fixed">mono_gc_alloc_fixed</a></h4>
<h4><a name="api:mono_gc_enable_events">mono_gc_enable_events</a></h4>
<h4><a name="api:mono_gc_free_fixed">mono_gc_free_fixed</a></h4>
<h4><a name="api:mono_gc_make_descr_from_bitmap">mono_gc_make_descr_from_bitmap</a></h4>
-1
View File
@@ -93,7 +93,6 @@ result = mono_object_new (mono_domain_get (), version_class);
<h4><a name="api:mono_object_isinst">mono_object_isinst</a></h4>
<h4><a name="api:mono_object_unbox">mono_object_unbox</a></h4>
<h4><a name="api:mono_object_castclass_mbyref">mono_object_castclass_mbyref</a></h4>
<h4><a name="api:mono_object_is_alive">mono_object_is_alive</a></h4>
<h4><a name="api:mono_object_get_size">mono_object_get_size</a></h4>
<a name="valuetypes"></a>
+1 -1
View File
@@ -23,7 +23,7 @@
<h4><a name="api:mono_custom_attrs_from_property">mono_custom_attrs_from_property</a></h4>
<h4><a name="api:mono_custom_attrs_has_attr">mono_custom_attrs_has_attr</a></h4>
<h2>
<h2></h2>
<h4><a name="api:mono_module_file_get_object">mono_module_file_get_object</a></h4>
<h4><a name="api:mono_module_get_object">mono_module_get_object</a></h4>
<h4><a name="api:mono_method_body_get_object">mono_method_body_get_object</a></h4>
+22 -22
View File
@@ -19,12 +19,12 @@
<h4><a name="api:CreateMutex">CreateMutex</a></h4>
<h4><a name="api:CreatePipe">CreatePipe</a></h4>
<h4><a name="api:CreateProcess">CreateProcess</a></h4>
<h4><a name="api:CreateProcessWithLogonW">CreateProcessWithLogonW</a>
<h4><a name="api:CreateProcessWithLogonW">CreateProcessWithLogonW</a></h4>
<h4><a name="api:CreateSemaphore">CreateSemaphore</a></h4>
<h4><a name="api:CreateThread">CreateThread</a></h4>
<h4><a name="api:DeleteCriticalSection">DeleteCriticalSection</a></h4>
<h4><a name="api:DeleteFile">DeleteFile</a></h4>
<h4><a name="api:DuplicateHandle">DuplicateHandle</a>
<h4><a name="api:DuplicateHandle">DuplicateHandle</a></h4>
<h4><a name="api:EnterCriticalSection">EnterCriticalSection</a></h4>
<h4><a name="api:EnumProcesses">EnumProcesses</a></h4>
<h4><a name="api:EnumProcessModules">EnumProcessModules</a></h4>
@@ -35,14 +35,14 @@
<h4><a name="api:FindFirstFile">FindFirstFile</a></h4>
<h4><a name="api:FindNextFile">FindNextFile</a></h4>
<h4><a name="api:FlushFileBuffers">FlushFileBuffers</a></h4>
<h4><a name="api:FormatMessage">FormatMessage</a>
<h4><a name="api:FormatMessage">FormatMessage</a></h4>
<h4><a name="api:GetCurrentDirectory">GetCurrentDirectory</a></h4>
<h4><a name="api:GetCurrentProcess">GetCurrentProcess</a></h4>
<h4><a name="api:GetCurrentProcessId">GetCurrentProcessId</a></h4>
<h4><a name="api:GetCurrentThread">GetCurrentThread</a></h4>
<h4><a name="api:GetCurrentThreadId">GetCurrentThreadId</a></h4>
<h4><a name="api:GetDiskFreeSpaceEx">GetDiskFreeSpaceEx</a>
<h4><a name="api:GetDriveType">GetDriveType</a>
<h4><a name="api:GetDiskFreeSpaceEx">GetDiskFreeSpaceEx</a></h4>
<h4><a name="api:GetDriveType">GetDriveType</a></h4>
<h4><a name="api:GetExitCodeProcess">GetExitCodeProcess</a></h4>
<h4><a name="api:GetExitCodeThread">GetExitCodeThread</a></h4>
<h4><a name="api:GetFileAttributesEx">GetFileAttributesEx</a></h4>
@@ -50,14 +50,14 @@
<h4><a name="api:GetFileSize">GetFileSize</a></h4>
<h4><a name="api:GetFileTime">GetFileTime</a></h4>
<h4><a name="api:GetFileType">GetFileType</a></h4>
<h4><a name="api:GetFileVersionInfo">GetFileVersionInfo</a>
<h4><a name="api:GetFileVersionInfoSize">GetFileVersionInfoSize</a>
<h4><a name="api:GetFileVersionInfo">GetFileVersionInfo</a></h4>
<h4><a name="api:GetFileVersionInfoSize">GetFileVersionInfoSize</a></h4>
<h4><a name="api:GetLastError">GetLastError</a></h4>
<h4><a name="api:GetLogicalDriveStrings">GetLogicalDriveStrings</a></h4>
<h4><a name="api:GetModuleBaseName">GetModuleBaseName</a></h4>
<h4><a name="api:GetModuleFileNameEx">GetModuleFileNameEx</a>
<h4><a name="api:GetModuleInformation">GetModuleInformation</a>
<h4><a name="api:GetPriorityClass">GetPriorityClass</a>
<h4><a name="api:GetModuleFileNameEx">GetModuleFileNameEx</a></h4>
<h4><a name="api:GetModuleInformation">GetModuleInformation</a></h4>
<h4><a name="api:GetPriorityClass">GetPriorityClass</a></h4>
<h4><a name="api:GetProcessId">GetProcessId</a></h4>
<h4><a name="api:GetProcessTimes">GetProcessTimes</a></h4>
<h4><a name="api:GetProcessWorkingSetSize">GetProcessWorkingSetSize</a></h4>
@@ -86,7 +86,7 @@
<h4><a name="api:ReleaseMutex">ReleaseMutex</a></h4>
<h4><a name="api:ReleaseSemaphore">ReleaseSemaphore</a></h4>
<h4><a name="api:RemoveDirectory">RemoveDirectory</a></h4>
<h4><a name="api:ReplaceFile">ReplaceFile</a>
<h4><a name="api:ReplaceFile">ReplaceFile</a></h4>
<h4><a name="api:ResetEvent">ResetEvent</a></h4>
<h4><a name="api:ResumeThread">ResumeThread</a></h4>
<h4><a name="api:RevertToSelf">RevertToSelf</a></h4>
@@ -98,7 +98,7 @@
<h4><a name="api:SetFilePointer">SetFilePointer</a></h4>
<h4><a name="api:SetFileTime">SetFileTime</a></h4>
<h4><a name="api:SetLastError">SetLastError</a></h4>
<h4><a name="api:SetPriorityClass">SetPriorityClass</a>
<h4><a name="api:SetPriorityClass">SetPriorityClass</a></h4>
<h4><a name="api:SetProcessWorkingSetSize">SetProcessWorkingSetSize</a></h4>
<h4><a name="api:ShellExecuteEx">ShellExecuteEx</a></h4>
<h4><a name="api:SignalObjectAndWait">SignalObjectAndWait</a></h4>
@@ -110,12 +110,12 @@
<h4><a name="api:TlsFree">TlsFree</a></h4>
<h4><a name="api:TlsGetValue">TlsGetValue</a></h4>
<h4><a name="api:TlsSetValue">TlsSetValue</a></h4>
<h4><a name="api:TransmitFile">TransmitFile</a>
<h4><a name="api:TransmitFile">TransmitFile</a></h4>
<h4><a name="api:TryEnterCriticalSection">TryEnterCriticalSection</a></h4>
<h4><a name="api:UnlockFile">UnlockFile</a></h4>
<h4><a name="api:VerLanguageName">VerLanguageName</a>
<h4><a name="api:VerQueryValue">VerQueryValue</a>
<h4><a name="api:WaitForInputIdle">WaitForInputIdle</a>
<h4><a name="api:VerLanguageName">VerLanguageName</a></h4>
<h4><a name="api:VerQueryValue">VerQueryValue</a></h4>
<h4><a name="api:WaitForInputIdle">WaitForInputIdle</a></h4>
<h4><a name="api:WaitForMultipleObjectsEx">WaitForMultipleObjectsEx</a></h4>
<h4><a name="api:WaitForMultipleObjects">WaitForMultipleObjects</a></h4>
<h4><a name="api:WaitForSingleObjectEx">WaitForSingleObjectEx</a></h4>
@@ -136,9 +136,9 @@
APIs.
<h4><a name="api:mono_once">mono_once</a></h4>
<h4><a name="api:wapi_clear_interruption">wapi_clear_interruption</a>
<h4><a name="api:wapi_current_thread_desc">wapi_current_thread_desc</a>
<h4><a name="api:wapi_interrupt_thread">wapi_interrupt_thread</a>
<h4><a name="api:wapi_self_interrupt">wapi_self_interrupt</a>
<h4><a name="api:wapi_thread_clear_wait_handle">wapi_thread_clear_wait_handle</a>
<h4><a name="api:wapi_thread_set_wait_handle">wapi_thread_set_wait_handle</a>
<h4><a name="api:wapi_clear_interruption">wapi_clear_interruption</a></h4>
<h4><a name="api:wapi_current_thread_desc">wapi_current_thread_desc</a></h4>
<h4><a name="api:wapi_interrupt_thread">wapi_interrupt_thread</a></h4>
<h4><a name="api:wapi_self_interrupt">wapi_self_interrupt</a></h4>
<h4><a name="api:wapi_thread_clear_wait_handle">wapi_thread_clear_wait_handle</a></h4>
<h4><a name="api:wapi_thread_set_wait_handle">wapi_thread_set_wait_handle</a></h4>
-33
View File
@@ -1,33 +0,0 @@
Size and alignment requirements of stack values
===============================================
P ... System.IntPtr
I1 ... System.Int8
I2 ... System.Int16
I4 ... System.Int32
I8 ... System.Int64
F ... System.Single
D ... System.Double
LD ... native long double
-----------------------------------------------------------
ARCH | P | I1 | I2 | I4 | I8 | F | D | LD |
-----------------------------------------------------------
X86 | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 |12/4 |
-----------------------------------------------------------
X86/W32 | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 |12/4 |
-----------------------------------------------------------
ARM | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 | 8/4 |
-----------------------------------------------------------
M68K | 4/4 | 4/4 | 4/4 | 4/4 | 8/4 | 4/4 | 8/4 |12/4 |
-----------------------------------------------------------
ALPHA | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 |
-----------------------------------------------------------
SPARC | 4/4 | 4/4 | 4/4 | 4/4 | 8/8 | 4/4 | 8/8 |16/8 |
-----------------------------------------------------------
SPARC64 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 | 8/8 |16/16|
-----------------------------------------------------------
MIPS | 4/4 | 4/4 | 4/4 | 4/4 | ?/? | 4/4 | 8/8 | 8/8 |
-----------------------------------------------------------
| | | | | | | | |
-----------------------------------------------------------
-261
View File
@@ -1,261 +0,0 @@
Purpose
Especially when inlining is active, it can happen that temporary
variables add pressure to the register allocator, producing bad
code.
The idea is that some of these temporaries can be totally eliminated
my moving the MonoInst tree that defines them directly to the use
point in the code (so the name "tree mover").
Please note that this is *not* an optimization: it is mostly a
workaround to issues we have in the regalloc.
Actually, with the new linear IR this will not be possible at all
(there will be no more trees in the code!).
Anyway, this workaround turns out to be useful in the current state
of things...
-----------------------------------------------------------------------
Base logic
If a local is defined by a value which is a proper expression (a tree
of MonoInst, not just another local or a constant), and this definition
is used only once, the tree can be moved directly to the use location,
and the definition eliminated.
Of course, none of the variables used in the tree must be defined in
the code path between the definition and the use, and the tree must be
free of side effects.
We do not handle the cases when the tree is just a local or a constant
because they are handled by copyprop and consprop, respectively.
To make things simpler, we restrict the tree move to the case when:
- the definition and the use are in the same BB, and
- the use is followed by another definition in the same BB (it is not
possible that the 1st value is used again), or alternatively there
is no BB in the whole CFG that contains a use of this local before a
definition (so, again, there is no code path that can lead to a
subsequent use).
To handle this, we maintain an ACT array (Available Copy Tree, similar
to the ACP), where we store the "state" of every local.
Ideally, every local can be in the following state:
[E] Undefined (by a tree, it could be in the ACP but we don't care).
[D] Defined (by a tree), and waiting for a use.
[U] Used, with a tree definition available in the same BB, but still
without a definition following the use (always in the same BB).
Of course state [E] (empty) is the initial one.
Besides, there are two sort of "meta states", or flags:
[W] Still waiting for a use or definition in this BB (we have seen no
occurrence of the local yet).
[X] Used without being previously defined in the same BB (note that if
there is a definition that precedes the use in the same BB, even if
the definition is not a tree or is not available because of side
effects or because the tree value has changed the local is not in
state [X]).
Also note that state [X] is a sort of "global" condition, which if set
in one BB will stay valid for the whole CFG, even if the local will
otherwise change state. The idea of flagging a local as [X] is that if
there is a definition/use pair that reaches the end of a BB, it could
be that there is a CFG path that then leads to the BB flagging it as
[X] (which contains a use), so the tree cannot be moved.
So state [X] will always be set, and never examined in all the state
transitions we will describe.
In practice, we use flag [W] to set state [X]: if, when traversing a
BB, we find a use for a local in state [W], then that local is flagged
[X].
For each BB, we initialize all states to [E] and [W], and then we
traverse the code one inst at a time, and update the variable states
in the ACT in the following ways:
[Definition]
- Flag [W] is cleared.
- All "affected trees" are killed (go from state [D] to [E]).
The "affected trees" are the trees which contain (use) the defined
local, and the rationale is that the tree value changed, so the
tree is no longer available.
- If the local was in state [U], *that* tree move is marked "safe"
(because *this* definition makes us sure that the previous tree
cannot be used again in any way).
The idea is that "safe" moves can happen even if the local is
flagged [X], because the second definition "covers" the use.
The tree move is then saved in the "todo" list (and the affecting
nodes are cleared).
- If the local was defined by a tree, it goes to state [D], the tree
is recorded, and all the locals used in it are marked as "affecting
this tree" (of course these markers are lists, because each local
could affect more than one tree).
[IndirectDefinition]
- All potentially affected trees (in state [D]) are killed.
[Use]
- If the local is still [W], it is flagged [X] (the [W] goes away).
- If the local is in state [D], it goes to state [U].
The tree move must not yet be recorded in the "todo" list, it still
stays in the ACT slot belonging to this local.
Anyway, the "affecting" nodes are updated, because now a definition
of a local used in this tree will affect only "indirect" (or also
"propagated") moves, but not *this* move (see below).
- If the local is in state [U], then the tree cannot be moved (it is
used two times): the move is canceled, and the state goes [E].
- If the local is in state [E], the use is ignored.
[IndirectUse]
- All potentially affected trees (in state [D] or [U]) are killed.
[SideEffect]
- Tree is marked as "unmovable".
Then, at the end of the BB, for each ACT slot:
- If state is [U], the tree move is recorded in the "todo" list, but
flagged "unsafe".
- Anyway, state goes to [E], the [W] flag is set, and all "affecting"
lists are cleared (we get ready to traverse the next BB).
Finally, when all BBs has been scanned, we traverse the "todo" list,
moving all "safe" entries, and moving "unsafe" ones only if their ACT
slot is not flagged [X].
So far, so good.
But there are two issues that make things harder :-(
The first is the concept of "indirect tree move".
It can happen that a tree is scheduled for moving, and its destination
is a use that is located in a second tree, which could also be moved.
The main issue is that a definition of a variable of the 1st tree on
the path between the definition and the use of the 2nd one must prevent
the move.
But which move? The 1st or the 2nd?
Well, any of the two!
The point is, the 2nd move must be prevented *only* if the 1st one
happens: if it is aborted (for an [X] flag or any other reason), the
2nd move is OK, and vice versa...
We must handle this in the following way:
- The ACT must still remember if a slot is scheduled for moving in
this BB, and if it is, all the locals used in the tree.
We say that the slot is in state [M].
Note that [M] is (like [X] and [W]) a sort of "meta state": a local
is flagged [M] when it goes to state [U], and the flag is cleared
when the tree move is cancelled
- A tree that uses a local whose slot is in state [M] is also using all
the locals used by the tree in state [M], but the use is "indirect".
These use nodes are also included in the "affecting" lists.
- The definition of a variable used in an "indirect" way has the
effect of "linking" the two involved tree moves, saying that only one
of the two can happen in practice, but not both.
- When the 2nd tree is scheduled for moving, the 1st one is *still* in
state [M], because a third move could "carry it forward", and all the
*three* moves should be mutually exclusive (to be safe!).
The second tricky complication is the "tree forwarding" that can happen
when copyprop is involved.
It is conceptually similar to the "indirect tree move".
Only, the 2nd tree is not really a tree, it is just the local defined
in the 1st tree move.
It can happen that copyprop will propagate the definition.
We cannot make treeprop do the same job of copyprop, because copyprop
has less constraints, and is therefore more powerful in its scope.
The main issue is that treeprop cannot propagate a tree to *two* uses,
while copyprop is perfectly capable of propagating one definition to
two (or more) different places.
So we must let copyprop do its job otherwise we'll miss optimizations,
but we must also make it play safe with treeprop.
Let's clarify with an example:
a = v1 + v2; //a is defined by a tree, state [D], uses v2 and v2
b = a; //a is used, state [U] with move scheduled, and
//b is defined by a, ACP[b] is a, and b is in state [DC]
c = b + v3; // b is used, goes to state [U]
The real trouble is that copyprop happens *immediately*, while treeprop
is deferred to the end of the CFG traversal.
So, in the 3rd statement, the "b" is immediately turned into an "a" by
copyprop, regardless of what treeprop will do.
Anyway, if we are careful, this is not so bad.
First of all, we must "accept" the fact that in the 3rd statement the
"b" is in fact an "a", as treeprop must happen *after* copyprop.
The real problem is that "a" is used twice: in the 2nd and 3rd lines.
In our usual setup, the 2nd line would set it to [U], and the 3rd line
would kill the move (and set "a" to [E]).
I have tried to play tricks, and reason as of copyprop didn't happen,
but everything becomes really messy.
Instead, we should note that the 2nd line is very likely to be dead.
At least in this BB, copyprop will turn all "b"s into "a"s as long as
it can, and when it cannot, it will be because either "a" or "b" have
been redefined, which would be after the tree move anyway.
So, the reasoning gets different: let's pretend that "b" will be dead.
This will make the "a" use in the 2nd statement useless, so there we
can "reset" "a" to [D], but also take note that if "b" will end up
not being dead, the tree move associated to this [D] must be aborted.
We can detect this in the following way:
- Either "b" is used before being defined in this BB, or
- It will be flagged "unsafe".
Both things are very easy to check.
The only quirk is that the "affecting" lists must not be cleared when
a slot goes to state [U], because a "propagation" could put it back
to state [D] (where those lists are needed, because it can be killed
by a definition to a used slot).
-----------------------------------------------------------------------
Implementation notes
All the implementation runs inside the existing mono_local_cprop
function, and a separate memory pool is used to hold the temporary
data.
A struct, MonoTreeMover, contains the pointers to the pool, the ACT,
the list of scheduled moves and auxiliary things.
This struct is allocated if the tree move pass is requested, and is
then passed along to all the involved functions, which are therefore
aware of the tree mover state.
The ACT is an array of slots, obviously one per local.
Each slot is of type MonoTreeMoverActSlot, and contains the used and
affected locals, a pointer to the pending tree move and the "waiting"
and "unsafe" flags.
The "affecting" lists a built from "dependency nodes", of type
MonoTreeMoverDependencyNode.
Each of the nodes contains the used and affected local, and is in
two lists: the locals used by a slot, and the locals affected by a
slot (obviously a different one).
So, each node means: "variable x is used in tree t, so a definition
of x affects tree t".
The "affecting" lists are doubly linked, to allow for O(1) deletion.
The "used" lists are simply linked, but when they are mantained there
is always a pointer to the last element to allow for O(1) list moving.
When a used list is dismissed (which happens often, any time a node is
killed), its nodes are unlinked from their respective affecting lists
and are then put in a "free" list in the MonoTreeMover to be reused.
Each tree move is represented by a struct (MonoTreeMoverTreeMove),
which contains:
- the definition and use points,
- the "affected" moves (recall the concept of "indirect tree move"),
- the "must be dead" slots (recall "tree forwarding"). and
- a few utility flags.
The tree moves stays in the relevant ACT slot until it is ready to be
scheduled for moving, at which point it is put in a list in the
MonoTreeMover.
The tree moves structs are reused when they are killed, so there is
also a "free" list for them in the MonoTreeMover.
The tree mover code has been added to all the relevant functions that
participate in consprop and copyprop, particularly:
- mono_cprop_copy_values takes care of variable uses (transitions from
states [D] to [U] and [U] to [E] because of killing),
- mono_cprop_invalidate_values takes care of side effects (indirect
accesses, calls...),
- mono_local_cprop_bb sets up and cleans the traversals for each BB,
and for each MonoInst it takes care of variable definitions.
To each of them has been added a MonoTreeMover parameter, which is not
NULL if the tree mover is running.
After mono_local_cprop_bb has run for all BBs, the MonoTreeMover has
the list of all the pending moves, which must be walked to actually
perform the moves (when possible, because "unsafe" flags, "affected"
moves and "must be dead" slots can still have their effects, which
must be handled now because they are fully known only at the end of
the CFG traversal).
+2
View File
@@ -1,5 +1,7 @@
ACLOCAL_AMFLAGS = -I m4
AM_CFLAGS = $(WERROR_CFLAGS)
if HOST_WIN32
SUBDIRS = m4 src
else
+3 -3
View File
@@ -22,11 +22,11 @@ if test x$GCC != xyes; then
dolt_supported=no
fi
case $host in
i?86-*-linux*|x86_64-*-linux*|powerpc-*-linux*|powerpc64-*-linux* \
|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*|arm*-*-linux*|sparc*-*-linux*|mips*-*-linux*)
i?86-*-linux*|i?86-apple-darwin*|x86_64-*-linux*|powerpc-*-linux*|powerpc64-*-linux* \
|amd64-*-freebsd*|i?86-*-freebsd*|ia64-*-freebsd*|arm*-*-linux*|sparc*-*-linux*|mips*-*-linux*|x86_64-apple-darwin*|aarch64*)
pic_options='-fPIC'
;;
?86-pc-cygwin*|i?86-pc-cygwin*)
?86-pc-cygwin*|i?86-pc-cygwin*|i?86-pc-mingw32*)
pic_options='-DDLL_EXPORT'
;;
i?86-apple-darwin*|arm-apple-darwin*)
+10 -14
View File
@@ -88,7 +88,7 @@ case $host in
esac
case $target in
arm*-darwin*)
arm*-darwin*|aarch64*-*)
CFLAGS="$CFLAGS -U_FORTIFY_SOURCE"
;;
i*86-*-darwin*)
@@ -135,6 +135,8 @@ AC_CHECK_SIZEOF(void *)
AC_CHECK_SIZEOF(long)
AC_CHECK_SIZEOF(long long)
AC_CHECK_FUNCS(strlcpy stpcpy strtok_r rewinddir vasprintf)
AC_CHECK_FUNCS(getrlimit)
AC_CHECK_FUNCS(fork execv execve)
#
# Mono currently supports 10.6, but strndup is not available prior to 10.7; avoiding
@@ -149,7 +151,7 @@ elif test x$target_ios = xno; then
AC_CHECK_FUNCS(strndup getpwuid_r)
fi
AM_CONDITIONAL(NEED_VASPRINTF, test x$have_vasprintf = x )
AM_CONDITIONAL(NEED_VASPRINTF, test x$ac_cv_func_vasprintf = xno )
AM_ICONV()
AC_SEARCH_LIBS(sqrtf, m)
@@ -179,7 +181,8 @@ if test "x$have_iso_varargs" = "xyes"; then
fi
AC_SUBST(G_HAVE_ISO_VARARGS)
AC_CHECK_HEADERS(getopt.h sys/time.h sys/wait.h pwd.h langinfo.h iconv.h localcharset.h sys/types.h)
AC_CHECK_HEADERS(getopt.h sys/select.h sys/time.h sys/wait.h pwd.h langinfo.h iconv.h localcharset.h sys/types.h sys/resource.h)
AC_CHECK_LIB([iconv], [locale_charset],[],[AC_CHECK_LIB([charset], [locale_charset],[LIBS+="-liconv -lcharset"])])
AC_CHECK_HEADER(alloca.h, [HAVE_ALLOCA_H=1], [HAVE_ALLOCA_H=0])
AC_SUBST(HAVE_ALLOCA_H)
@@ -235,18 +238,11 @@ AC_ARG_WITH(crosspkgdir, [ --with-crosspkgdir=/path/to/pkg-config/dir Chan
fi
)
dnl
dnl No, you can not replace the call below with a pkg.m4 macro
dnl
have_glib=false
if test "x$PKG_CONFIG" != "xno"; then
if $PKG_CONFIG --atleast-version=$GLIB_REQUIRED_VERSION glib-2.0; then
have_glib=true;
else
have_glib=false;
fi
AC_ARG_ENABLE(werror, [ --enable-werror Pass -Werror to the C compiler], werror_flag=$enableval, werror_flag=no)
if test x$werror_flag = xyes; then
WERROR_CFLAGS="-Werror"
fi
AM_CONDITIONAL(HAVE_GLIB, $have_glib)
AC_SUBST([WERROR_CFLAGS])
AC_SUBST(GPOINTER_TO_INT)
AC_SUBST(GPOINTER_TO_UINT)
+4 -6
View File
@@ -1,4 +1,6 @@
noinst_LTLIBRARIES = libeglib.la libeglib-static.la
noinst_LTLIBRARIES = libeglib.la
AM_CFLAGS = $(WERROR_CFLAGS)
win_files = \
eglib-config.hw \
@@ -30,6 +32,7 @@ libeglib_la_SOURCES = \
garray.c \
gbytearray.c \
gerror.c \
vasprintf.h \
ghashtable.c \
giconv.c \
gmem.c \
@@ -56,8 +59,6 @@ libeglib_la_SOURCES = \
$(vasprintf_files)
libeglib_la_CFLAGS = -g -Wall -D_FORTIFY_SOURCE=2
libeglib_static_la_SOURCES=$(libeglib_la_SOURCES)
libeglib_static_la_CFLAGS = $(libeglib_la_CFLAGS)
AM_CPPFLAGS = -I$(srcdir)
@@ -69,9 +70,6 @@ libeglib_la_LIBADD = -llog
endif
endif
libeglib_static_la_LIBADD = $(libeglib_la_LIBADD) $(LIBICONV)
libeglib_static_la_LDFLAGS = -static
MAINTAINERCLEANFILES = Makefile.in
EXTRA_DIST = eglib-config.h.in $(win_files) $(unix_files)
+1 -1
View File
@@ -36,7 +36,7 @@ typedef signed @GSIZE@ gssize;
#define G_HAVE_ISO_VARARGS
#endif
#if defined (__native_client__)
#if defined (__native_client__) || defined (HOST_WATCHOS)
#undef G_BREAKPOINT
#define G_BREAKPOINT()
#endif
+6
View File
@@ -273,3 +273,9 @@
#define g_utf8_get_char_validated monoeg_utf8_get_char_validated
#define g_utf8_prev_char monoeg_utf8_prev_char
#define g_utf8_to_ucs4 monoeg_utf8_to_ucs4
#define g_log_default_handler monoeg_log_default_handler
#define g_log_set_default_handler monoeg_log_set_default_handler
#define g_set_print_handler monoeg_set_print_handler
#define g_set_printerr_handler monoeg_set_printerr_handler
+2
View File
@@ -30,6 +30,8 @@
#include <string.h>
#include <glib.h>
#include "vasprintf.h"
GError *
g_error_new (gpointer domain, gint code, const char *format, ...)
{
+1 -1
View File
@@ -58,7 +58,7 @@ int mkstemp (char *tmp_template)
utf16_template = _wmktemp( utf16_template);
if (utf16_template && *utf16_template) {
/* FIXME: _O_TEMPORARY causes file to disappear on close causing a test to fail */
fd = _wopen( utf16_template, _O_BINARY | _O_CREAT /*| _O_TEMPORARY*/ | _O_EXCL, _S_IREAD | _S_IWRITE);
fd = _wopen( utf16_template, _O_BINARY | _O_CREAT /*| _O_TEMPORARY*/ | _O_RDWR | _O_EXCL, _S_IREAD | _S_IWRITE);
}
/* FIXME: this will crash if utf16_template == NULL */
+16 -23
View File
@@ -49,12 +49,6 @@
G_BEGIN_DECLS
#ifdef G_OS_WIN32
/* MSC and Cross-compilatin will use this */
int vasprintf (char **strp, const char *fmt, va_list ap);
#endif
/*
* Basic data types
*/
@@ -182,7 +176,6 @@ typedef struct _GMemChunk GMemChunk;
/*
* Misc.
*/
#define g_atexit(func) ((void) atexit (func))
const gchar * g_getenv(const gchar *variable);
gboolean g_setenv(const gchar *variable, const gchar *value, gboolean overwrite);
@@ -609,10 +602,14 @@ void g_assertion_message (const gchar *format, ...) G_GNUC_NORETURN
#define g_message(...) g_log (G_LOG_DOMAIN, G_LOG_LEVEL_MESSAGE, __VA_ARGS__)
#define g_debug(...) g_log (G_LOG_DOMAIN, G_LOG_LEVEL_DEBUG, __VA_ARGS__)
#endif /* ndef HAVE_C99_SUPPORT */
#define g_log_set_handler(a,b,c,d)
#define G_GNUC_INTERNAL
typedef void (*GLogFunc) (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer user_data);
typedef void (*GPrintFunc) (const gchar *string);
void g_log_default_handler (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer unused_data);
GLogFunc g_log_set_default_handler (GLogFunc log_func, gpointer user_data);
GPrintFunc g_set_print_handler (GPrintFunc func);
GPrintFunc g_set_printerr_handler (GPrintFunc func);
/*
* Conversions
*/
@@ -727,8 +724,16 @@ GUnicodeBreakType g_unichar_break_type (gunichar c);
#define G_UNLIKELY(x) (x)
#endif
#if defined(_MSC_VER)
#define eg_unreachable() __assume(0)
#elif defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4 && (__GNUC_MINOR__ >= 5)))
#define eg_unreachable() __builtin_unreachable()
#else
#define eg_unreachable()
#endif
#define g_assert(x) G_STMT_START { if (G_UNLIKELY (!(x))) g_assertion_message ("* Assertion at %s:%d, condition `%s' not met\n", __FILE__, __LINE__, #x); } G_STMT_END
#define g_assert_not_reached() G_STMT_START { g_assertion_message ("* Assertion: should not be reached at %s:%d\n", __FILE__, __LINE__); } G_STMT_END
#define g_assert_not_reached() G_STMT_START { g_assertion_message ("* Assertion: should not be reached at %s:%d\n", __FILE__, __LINE__); eg_unreachable(); } G_STMT_END
/*
* Unicode conversion
@@ -809,6 +814,7 @@ gboolean g_spawn_command_line_sync (const gchar *command_line, gchar **standard_
gboolean g_spawn_async_with_pipes (const gchar *working_directory, gchar **argv, gchar **envp, GSpawnFlags flags, GSpawnChildSetupFunc child_setup,
gpointer user_data, GPid *child_pid, gint *standard_input, gint *standard_output, gint *standard_error, GError **error);
int eg_getdtablesize (void);
/*
* Timer
@@ -1008,19 +1014,6 @@ glong g_utf8_pointer_to_offset (const gchar *str, const gchar *pos);
#define G_PRIORITY_DEFAULT 0
#define G_PRIORITY_DEFAULT_IDLE 200
/*
* Empty thread functions, not used by eglib
*/
#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_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))
+16 -11
View File
@@ -93,24 +93,29 @@ get_pw_data (void)
pthread_mutex_unlock (&pw_lock);
return;
}
home_dir = g_getenv ("HOME");
user_name = g_getenv ("USER");
#ifdef HAVE_GETPWUID_R
if (getpwuid_r (getuid (), &pw, buf, 4096, &result) == 0) {
home_dir = g_strdup (pw.pw_dir);
user_name = g_strdup (pw.pw_name);
if (home_dir == NULL || user_name == NULL) {
if (getpwuid_r (getuid (), &pw, buf, 4096, &result) == 0) {
if (home_dir == NULL)
home_dir = g_strdup (pw.pw_dir);
if (user_name == NULL)
user_name = g_strdup (pw.pw_name);
}
}
#endif
if (home_dir == NULL)
home_dir = g_getenv ("HOME");
if (user_name == NULL) {
user_name = g_getenv ("USER");
if (user_name == NULL)
user_name = "somebody";
}
if (user_name == NULL)
user_name = "somebody";
if (home_dir == NULL)
home_dir = "/";
pthread_mutex_unlock (&pw_lock);
}
/* Give preference to /etc/passwd than HOME */
const gchar *
g_get_home_dir (void)
{
+6 -4
View File
@@ -87,10 +87,12 @@ g_unsetenv(const gchar *variable)
gchar*
g_win32_getlocale(void)
{
/* FIXME: Use GetThreadLocale
* and convert LCID to standard
* string form, "en_US" */
return strdup ("en_US");
LCID lcid = GetThreadLocale();
gchar buf[19];
gint ccBuf = GetLocaleInfo(lcid, LOCALE_SISO639LANGNAME, buf, 9);
buf[ccBuf - 1] = '-';
ccBuf += GetLocaleInfo(lcid, LOCALE_SISO3166CTRYNAME, buf + ccBuf, 9);
return strdup(buf);
}
gboolean
+168 -92
View File
@@ -31,87 +31,51 @@
#include <stdlib.h>
#include <glib.h>
#include "vasprintf.h"
/* The current fatal levels, error is always fatal */
static GLogLevelFlags fatal = G_LOG_LEVEL_ERROR;
static GLogFunc default_log_func;
static gpointer default_log_func_user_data;
static GPrintFunc stdout_handler, stderr_handler;
#if PLATFORM_ANDROID
#include <android/log.h>
static android_LogPriority
to_android_priority (GLogLevelFlags log_level)
{
switch (log_level & G_LOG_LEVEL_MASK)
{
case G_LOG_LEVEL_ERROR: return ANDROID_LOG_FATAL;
case G_LOG_LEVEL_CRITICAL: return ANDROID_LOG_ERROR;
case G_LOG_LEVEL_WARNING: return ANDROID_LOG_WARN;
case G_LOG_LEVEL_MESSAGE: return ANDROID_LOG_INFO;
case G_LOG_LEVEL_INFO: return ANDROID_LOG_DEBUG;
case G_LOG_LEVEL_DEBUG: return ANDROID_LOG_VERBOSE;
}
return ANDROID_LOG_UNKNOWN;
}
static void
out_vfprintf (FILE *ignore, const gchar *format, va_list args)
{
/* TODO: provide a proper app name */
__android_log_vprint (ANDROID_LOG_ERROR, "mono", format, args);
}
#elif MONOTOUCH && defined(__arm__)
#include <asl.h>
static int
to_asl_priority (GLogLevelFlags log_level)
{
switch (log_level & G_LOG_LEVEL_MASK)
{
case G_LOG_LEVEL_ERROR: return ASL_LEVEL_CRIT;
case G_LOG_LEVEL_CRITICAL: return ASL_LEVEL_ERR;
case G_LOG_LEVEL_WARNING: return ASL_LEVEL_WARNING;
case G_LOG_LEVEL_MESSAGE: return ASL_LEVEL_NOTICE;
case G_LOG_LEVEL_INFO: return ASL_LEVEL_INFO;
case G_LOG_LEVEL_DEBUG: return ASL_LEVEL_DEBUG;
}
return ASL_LEVEL_ERR;
}
static void
out_vfprintf (FILE *ignore, const gchar *format, va_list args)
{
asl_vlog (NULL, NULL, ASL_LEVEL_WARNING, format, args);
}
#else
static void
out_vfprintf (FILE *file, const gchar *format, va_list args)
{
vfprintf (file, format, args);
}
#endif
static void default_stdout_handler (const gchar *string);
static void default_stderr_handler (const gchar *string);
void
g_print (const gchar *format, ...)
{
char *msg;
va_list args;
va_start (args, format);
out_vfprintf (stdout, format, args);
if (vasprintf (&msg, format, args) < 0)
return;
va_end (args);
if (!stdout_handler)
stdout_handler = default_stdout_handler;
stdout_handler (msg);
free (msg);
}
void
g_printerr (const gchar *format, ...)
{
char *msg;
va_list args;
va_start (args, format);
out_vfprintf (stderr, format, args);
if (vasprintf (&msg, format, args) < 0)
return;
va_end (args);
if (!stderr_handler)
stderr_handler = default_stderr_handler;
stderr_handler (msg);
free (msg);
}
GLogLevelFlags
@@ -138,42 +102,16 @@ g_log_set_fatal_mask (const gchar *log_domain, GLogLevelFlags fatal_mask)
void
g_logv (const gchar *log_domain, GLogLevelFlags log_level, const gchar *format, va_list args)
{
#if PLATFORM_ANDROID
__android_log_vprint (to_android_priority (log_level), log_domain, format, args);
#elif MONOTOUCH && defined(__arm__)
asl_vlog (NULL, NULL, to_asl_priority (log_level), format, args);
#else
char *msg;
if (!default_log_func)
default_log_func = g_log_default_handler;
if (vasprintf (&msg, format, args) < 0)
return;
#ifdef G_OS_WIN32
printf ("%s%s%s\n",
log_domain != NULL ? log_domain : "",
log_domain != NULL ? ": " : "",
msg);
#else
#if MONOTOUCH
FILE *target = stderr;
#else
FILE *target = stdout;
#endif
fprintf (target, "%s%s%s\n",
log_domain != NULL ? log_domain : "",
log_domain != NULL ? ": " : "",
msg);
#endif
default_log_func (log_domain, log_level, msg, default_log_func_user_data);
free (msg);
if (log_level & fatal){
fflush (stdout);
fflush (stderr);
}
#endif
if (log_level & fatal){
abort ();
}
}
void
@@ -194,6 +132,144 @@ g_assertion_message (const gchar *format, ...)
va_start (args, format);
g_logv (G_LOG_DOMAIN, G_LOG_LEVEL_ERROR, format, args);
va_end (args);
abort ();
exit (0);
}
#if PLATFORM_ANDROID
#include <android/log.h>
static android_LogPriority
to_android_priority (GLogLevelFlags log_level)
{
switch (log_level & G_LOG_LEVEL_MASK)
{
case G_LOG_LEVEL_ERROR: return ANDROID_LOG_FATAL;
case G_LOG_LEVEL_CRITICAL: return ANDROID_LOG_ERROR;
case G_LOG_LEVEL_WARNING: return ANDROID_LOG_WARN;
case G_LOG_LEVEL_MESSAGE: return ANDROID_LOG_INFO;
case G_LOG_LEVEL_INFO: return ANDROID_LOG_DEBUG;
case G_LOG_LEVEL_DEBUG: return ANDROID_LOG_VERBOSE;
}
return ANDROID_LOG_UNKNOWN;
}
void
g_log_default_handler (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer unused_data)
{
__android_log_write (to_android_priority (log_level), log_domain, message);
if (log_level & fatal)
abort ();
}
static void
default_stdout_handler (const gchar *message)
{
/* TODO: provide a proper app name */
__android_log_write (ANDROID_LOG_ERROR, "mono", message);
}
static void
default_stderr_handler (const gchar *message)
{
/* TODO: provide a proper app name */
__android_log_write (ANDROID_LOG_ERROR, "mono", message);
}
#elif defined(HOST_IOS)
#include <asl.h>
static int
to_asl_priority (GLogLevelFlags log_level)
{
switch (log_level & G_LOG_LEVEL_MASK)
{
case G_LOG_LEVEL_ERROR: return ASL_LEVEL_CRIT;
case G_LOG_LEVEL_CRITICAL: return ASL_LEVEL_ERR;
case G_LOG_LEVEL_WARNING: return ASL_LEVEL_WARNING;
case G_LOG_LEVEL_MESSAGE: return ASL_LEVEL_NOTICE;
case G_LOG_LEVEL_INFO: return ASL_LEVEL_INFO;
case G_LOG_LEVEL_DEBUG: return ASL_LEVEL_DEBUG;
}
return ASL_LEVEL_ERR;
}
void
g_log_default_handler (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer unused_data)
{
asl_log (NULL, NULL, to_asl_priority (log_level), "%s", message);
if (log_level & fatal)
abort ();
}
static void
default_stdout_handler (const gchar *message)
{
asl_log (NULL, NULL, ASL_LEVEL_WARNING, "%s", message);
}
static void
default_stderr_handler (const gchar *message)
{
asl_log (NULL, NULL, ASL_LEVEL_WARNING, "%s", message);
}
#else
void
g_log_default_handler (const gchar *log_domain, GLogLevelFlags log_level, const gchar *message, gpointer unused_data)
{
FILE *target = stdout;
fprintf (target, "%s%s%s\n",
log_domain != NULL ? log_domain : "",
log_domain != NULL ? ": " : "",
message);
if (log_level & fatal) {
fflush (stdout);
fflush (stderr);
abort ();
}
}
static void
default_stdout_handler (const gchar *string)
{
fprintf (stdout, "%s", string);
}
static void
default_stderr_handler (const gchar *string)
{
fprintf (stderr, "%s", string);
}
#endif
GLogFunc
g_log_set_default_handler (GLogFunc log_func, gpointer user_data)
{
GLogFunc old = default_log_func;
default_log_func = log_func;
default_log_func_user_data = user_data;
return old;
}
GPrintFunc
g_set_print_handler (GPrintFunc func)
{
GPrintFunc old = stdout_handler;
stdout_handler = func;
return old;
}
GPrintFunc
g_set_printerr_handler (GPrintFunc func)
{
GPrintFunc old = stderr_handler;
stderr_handler = func;
return old;
}
+3 -2
View File
@@ -216,8 +216,8 @@ cont:
gchar *
g_find_program_in_path (const gchar *program)
{
char *p = g_strdup (g_getenv ("PATH"));
char *x = p, *l;
char *p;
char *x, *l;
gchar *curdir = NULL;
char *save = NULL;
#ifdef G_OS_WIN32
@@ -228,6 +228,7 @@ g_find_program_in_path (const gchar *program)
#endif
g_return_val_if_fail (program != NULL, NULL);
x = p = g_strdup (g_getenv ("PATH"));
if (x == NULL || *x == '\0') {
curdir = g_get_current_dir ();
+2 -2
View File
@@ -126,7 +126,7 @@ g_ptr_array_remove_index(GPtrArray *array, guint index)
gpointer removed_node;
g_return_val_if_fail(array != NULL, NULL);
g_return_val_if_fail(index >= 0 || index < array->len, NULL);
g_return_val_if_fail(index < array->len, NULL);
removed_node = array->pdata[index];
@@ -147,7 +147,7 @@ g_ptr_array_remove_index_fast(GPtrArray *array, guint index)
gpointer removed_node;
g_return_val_if_fail(array != NULL, NULL);
g_return_val_if_fail(index >= 0 || index < array->len, NULL);
g_return_val_if_fail(index < array->len, NULL);
removed_node = array->pdata[index];
+40 -3
View File
@@ -41,6 +41,10 @@
#include <unistd.h>
#endif
#ifdef HAVE_SYS_SELECT_H
#include <sys/select.h>
#endif
#ifdef HAVE_SYS_TIME_H
#include <sys/time.h>
#endif
@@ -49,6 +53,10 @@
#include <sys/wait.h>
#endif
#ifdef HAVE_SYS_RESOURCE_H
# include <sys/resource.h>
#endif
#ifdef G_OS_WIN32
#include <io.h>
#include <winsock2.h>
@@ -66,7 +74,7 @@
#define NO_INTR(var,cmd) do { (var) = (cmd); } while ((var) == -1 && errno == EINTR)
#define CLOSE_PIPE(p) do { close (p [0]); close (p [1]); } while (0)
#if defined(__APPLE__) && !defined (__arm__)
#if defined(__APPLE__) && !defined (__arm__) && !defined (__aarch64__)
/* Apple defines this in crt_externs.h but doesn't provide that header for
* arm-apple-darwin9. We'll manually define the symbol on Apple as it does
* in fact exist on all implementations (so far)
@@ -209,6 +217,29 @@ write_all (int fd, const void *vbuf, size_t n)
return nwritten;
}
#ifndef G_OS_WIN32
int
eg_getdtablesize (void)
{
#ifdef HAVE_GETRLIMIT
struct rlimit limit;
int res;
res = getrlimit (RLIMIT_NOFILE, &limit);
g_assert (res == 0);
return limit.rlim_cur;
#else
return getdtablesize ();
#endif
}
#else
int
eg_getdtablesize (void)
{
g_error ("Should not be called");
}
#endif
gboolean
g_spawn_command_line_sync (const gchar *command_line,
gchar **standard_output,
@@ -217,6 +248,9 @@ g_spawn_command_line_sync (const gchar *command_line,
GError **error)
{
#ifdef G_OS_WIN32
#elif !defined (HAVE_FORK) || !defined (HAVE_EXECV)
fprintf (stderr, "g_spawn_command_line_sync not supported on this platform\n");
return FALSE;
#else
pid_t pid;
gchar **argv;
@@ -252,7 +286,7 @@ g_spawn_command_line_sync (const gchar *command_line,
close (stderr_pipe [0]);
dup2 (stderr_pipe [1], STDERR_FILENO);
}
for (i = getdtablesize () - 1; i >= 3; i--)
for (i = eg_getdtablesize () - 1; i >= 3; i--)
close (i);
/* G_SPAWN_SEARCH_PATH is always enabled for g_spawn_command_line_sync */
@@ -313,6 +347,9 @@ g_spawn_async_with_pipes (const gchar *working_directory,
GError **error)
{
#ifdef G_OS_WIN32
#elif !defined (HAVE_FORK) || !defined (HAVE_EXECVE)
fprintf (stderr, "g_spawn_async_with_pipes is not supported on this platform\n");
return FALSE;
#else
pid_t pid;
int info_pipe [2];
@@ -413,7 +450,7 @@ g_spawn_async_with_pipes (const gchar *working_directory,
}
if ((flags & G_SPAWN_LEAVE_DESCRIPTORS_OPEN) != 0) {
for (i = getdtablesize () - 1; i >= 3; i--)
for (i = eg_getdtablesize () - 1; i >= 3; i--)
close (i);
}
+2
View File
@@ -32,6 +32,8 @@
#include <ctype.h>
#include <glib.h>
#include "vasprintf.h"
/* This is not a macro, because I dont want to put _GNU_SOURCE in the glib.h header */
gchar *
g_strndup (const gchar *str, gsize n)
+3 -3
View File
@@ -219,10 +219,10 @@ g_get_charset (G_CONST_RETURN char **charset)
is_utf8 = FALSE;
#else
/* These shouldn't be heap allocated */
#if HAVE_LOCALCHARSET_H
my_charset = locale_charset ();
#elif defined(HAVE_LANGINFO_H)
#if defined(HAVE_LANGINFO_H)
my_charset = nl_langinfo (CODESET);
#elif defined(HAVE_LOCALCHARSET_H)
my_charset = locale_charset ();
#else
my_charset = "UTF-8";
#endif
+24
View File
@@ -88,12 +88,24 @@ merge_lists (list_node *first, list_node *second, GCompareFunc func)
static inline list_node *
sweep_up (struct sort_info *si, list_node *list, int upto)
{
#if defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__ >= 406)
/*
* GCC incorrectly thinks we're writing below si->ranks array bounds.
*/
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Warray-bounds"
#endif
int i;
for (i = si->min_rank; i < upto; ++i) {
list = merge_lists (si->ranks [i], list, si->func);
si->ranks [i] = NULL;
}
return list;
#if defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__ >= 406)
#pragma GCC diagnostic pop
#endif
}
/*
@@ -124,6 +136,14 @@ sweep_up (struct sort_info *si, list_node *list, int upto)
static inline void
insert_list (struct sort_info *si, list_node* list, int rank)
{
#if defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__ >= 406)
/*
* GCC incorrectly thinks we're writing below si->ranks array bounds.
*/
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Warray-bounds"
#endif
int i;
if (rank > si->n_ranks) {
@@ -149,6 +169,10 @@ insert_list (struct sort_info *si, list_node* list, int rank)
si->n_ranks = i + 1;
si->min_rank = i;
si->ranks [i] = list;
#if defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__ >= 406)
#pragma GCC diagnostic pop
#endif
}
#undef stringify2
+11
View File
@@ -0,0 +1,11 @@
#ifndef __VASPRINTF_H
#define __VASPRINTF_H
#include <stdarg.h>
#include <config.h>
#ifndef HAVE_VASPRINTF
int vasprintf(char **ret, const char *fmt, va_list ap);
#endif
#endif /* __VASPRINTF_H */
-18
View File
@@ -37,26 +37,8 @@ test_eglib_LDADD = ../src/libeglib.la $(LIBICONV)
run-eglib: all
srcdir=`readlink -f $(srcdir)` ./test-eglib
if HAVE_GLIB
noinst_PROGRAMS = test-glib test-eglib
test_glib_SOURCES = $(SOURCES)
test_glib_CFLAGS = `pkg-config --cflags glib-2.0` -DDRIVER_NAME=\"GLib\"
test_glib_LDFLAGS = `pkg-config --libs glib-2.0 gmodule-2.0`
run-glib: all
srcdir=`readlink -f $(srcdir)` ./test-glib
run-both: run-glib run-eglib
else
noinst_PROGRAMS = test-eglib
run-both: run-eglib
endif
MAINTAINERCLEANFILES = Makefile.in
+1 -1
View File
@@ -115,7 +115,7 @@ test_file ()
#ifndef G_OS_WIN32 /* FIXME */
gchar *sympath;
gint ignored;
gint ignored G_GNUC_UNUSED;
#endif
res = g_file_test (NULL, 0);
+9 -9
View File
@@ -60,22 +60,22 @@ test_ptrconv ()
return FAILED ("int to pointer and back conversions fail %d != %d", iv, iv2);
uv = 0;
ptr = GUINT_TO_POINTER (iv);
ptr = GUINT_TO_POINTER (uv);
uv2 = GPOINTER_TO_UINT (ptr);
if (iv != iv2)
return FAILED ("uint to pointer and back conversions fail %u != %d", iv, iv2);
if (uv != uv2)
return FAILED ("uint to pointer and back conversions fail %u != %d", uv, uv2);
uv = 1;
ptr = GUINT_TO_POINTER (iv);
ptr = GUINT_TO_POINTER (uv);
uv2 = GPOINTER_TO_UINT (ptr);
if (iv != iv2)
return FAILED ("uint to pointer and back conversions fail %u != %d", iv, iv2);
if (uv != uv2)
return FAILED ("uint to pointer and back conversions fail %u != %d", uv, uv2);
uv = UINT32_MAX;
ptr = GUINT_TO_POINTER (iv);
ptr = GUINT_TO_POINTER (uv);
uv2 = GPOINTER_TO_UINT (ptr);
if (iv != iv2)
return FAILED ("uint to pointer and back conversions fail %u != %d", iv, iv2);
if (uv != uv2)
return FAILED ("uint to pointer and back conversions fail %u != %d", uv, uv2);
return NULL;
+5
View File
@@ -1,6 +1,10 @@
/* config.h. Generated by configure. */
/* config.h.in. Generated from configure.ac by autoheader. */
#ifndef _MSC_VER
#include "cygconfig.h"
#else
/* Define to 1 if you have the <dlfcn.h> header file. */
#define HAVE_DLFCN_H 1
@@ -74,3 +78,4 @@
#define VERSION "0.1"
#define HAVE_STRTOK_R 1
#endif
Submodule external/Lucene.Net deleted from 88fb67b076.
Vendored Submodule
+1
+1 -1
Vendored Submodule
+1
Submodule external/ikdasm added at 3bf7a4b543.
+1 -1
Vendored Submodule
+1
Submodule external/referencesource added at 05654b3d01.
Vendored
+1 -1
Submodule external/rx updated: 17e8477b2c...b29a4b0fda.
+2 -2
View File
@@ -1,9 +1,9 @@
AM_CPPFLAGS = $(GMODULE_CFLAGS)
AM_CPPFLAGS = $(GLIB_CFLAGS)
lib_LTLIBRARIES = libikvm-native.la
libikvm_native_la_SOURCES = jni.c os.c jni.h
libikvm_native_la_LDFLAGS = -avoid-version
libikvm_native_la_LIBADD = $(GMODULE_LIBS)
libikvm_native_la_LIBADD = $(GLIB_LIBS)
+7 -1
View File
@@ -486,11 +486,15 @@ static void* JNIEnv_vtable[] =
0 // jlong JNICALL GetDirectBufferCapacity(jobject buf);
};
JNIEXPORT void** JNICALL ikvm_GetJNIEnvVTable()
void** ikvm_GetJNIEnvVTable(void);
JNIEXPORT void** JNICALL ikvm_GetJNIEnvVTable(void)
{
return JNIEnv_vtable;
}
void* JNICALL ikvm_MarshalDelegate(void* p);
JNIEXPORT void* JNICALL ikvm_MarshalDelegate(void* p)
{
return p;
@@ -498,6 +502,8 @@ JNIEXPORT void* JNICALL ikvm_MarshalDelegate(void* p)
typedef jint (JNICALL *PJNI_ONLOAD)(JavaVM* vm, void* reserved);
jint JNICALL ikvm_CallOnLoad(PJNI_ONLOAD method, JavaVM* vm, void* reserved);
JNIEXPORT jint JNICALL ikvm_CallOnLoad(PJNI_ONLOAD method, JavaVM* vm, void* reserved)
{
return method(vm, reserved);
+12
View File
@@ -61,16 +61,22 @@
#include <sys/mman.h>
#include "jni.h"
void* JNICALL ikvm_LoadLibrary(char* psz);
JNIEXPORT void* JNICALL ikvm_LoadLibrary(char* psz)
{
return g_module_open(psz, 0);
}
void JNICALL ikvm_FreeLibrary(GModule* handle);
JNIEXPORT void JNICALL ikvm_FreeLibrary(GModule* handle)
{
g_module_close(handle);
}
void* JNICALL ikvm_GetProcAddress(GModule* handle, char* name, jint argc);
JNIEXPORT void* JNICALL ikvm_GetProcAddress(GModule* handle, char* name, jint argc)
{
void *symbol;
@@ -83,16 +89,22 @@
return NULL;
}
void* JNICALL ikvm_mmap(int fd, jboolean writeable, jboolean copy_on_write, jlong position, jint size);
JNIEXPORT void* JNICALL ikvm_mmap(int fd, jboolean writeable, jboolean copy_on_write, jlong position, jint size)
{
return mmap(0, size, writeable ? PROT_WRITE | PROT_READ : PROT_READ, copy_on_write ? MAP_PRIVATE : MAP_SHARED, fd, position);
}
int JNICALL ikvm_munmap(void* address, jint size);
JNIEXPORT int JNICALL ikvm_munmap(void* address, jint size)
{
return munmap(address, size);
}
int JNICALL ikvm_msync(void* address, jint size);
JNIEXPORT int JNICALL ikvm_msync(void* address, jint size)
{
#if defined(__native_client__) && defined(USE_NEWLIB)
Loaded 100 of 22566 files, more files were not shown because too many files have changed in this diff. Show more