mono.git
8 years ago[swf] Flow SynchronizationContext through ExecutionContext. Fixes #38599
Marek Safar [Wed, 10 Feb 2016 19:24:13 +0000 (20:24 +0100)]
[swf] Flow SynchronizationContext through ExecutionContext. Fixes #38599

8 years ago[corlib] Use correct max/min value for DateTime overflows. Fixes #35876
Marek Safar [Wed, 10 Feb 2016 09:21:38 +0000 (03:21 -0600)]
[corlib] Use correct max/min value for DateTime overflows. Fixes #35876

8 years ago[System] Simple readability changes to SimpleAsyncResult
Marek Safar [Tue, 9 Feb 2016 19:09:33 +0000 (20:09 +0100)]
[System] Simple readability changes to SimpleAsyncResult

8 years ago[jit] Add a peephole optimization to remove the ldaddr+compare_imm 0+cond_exc checks...
Zoltan Varga [Wed, 10 Feb 2016 06:59:22 +0000 (01:59 -0500)]
[jit] Add a peephole optimization to remove the ldaddr+compare_imm 0+cond_exc checks inserted when using explicit null checks.

8 years ago[llvmonly] Disable the 'overriding the module target triple with' clang warning when...
Zoltan Varga [Wed, 10 Feb 2016 06:10:38 +0000 (01:10 -0500)]
[llvmonly] Disable the 'overriding the module target triple with' clang warning when compiling the bitcode files.

8 years ago[llvmonly] Fix a few issues passing and returning vtypes smaller than one machine...
Zoltan Varga [Wed, 10 Feb 2016 05:46:57 +0000 (00:46 -0500)]
[llvmonly] Fix a few issues passing and returning vtypes smaller than one machine word.

8 years ago[llvmonly] Fix the locking in the gsharedvt wrapper creation functions.
Zoltan Varga [Wed, 10 Feb 2016 02:55:37 +0000 (21:55 -0500)]
[llvmonly] Fix the locking in the gsharedvt wrapper creation functions.

8 years agoMerge pull request #2584 from lewurm/fix-mobile-compilation
monojenkins [Wed, 10 Feb 2016 02:20:32 +0000 (02:20 +0000)]
Merge pull request #2584 from lewurm/fix-mobile-compilation

[bcl] fix compilation of test on mobile

although a nunit category is specified, the compilation still failed on mobile.

8 years ago[bcl] fix compilation of test on mobile
Bernhard Urban [Tue, 9 Feb 2016 23:07:19 +0000 (15:07 -0800)]
[bcl] fix compilation of test on mobile

fix for the following problem:
> [13:33:37] src/System/Test/System.Diagnostics/ProcessTest.cs(1048,19): error CS0103: The name `GetCrossPlatformStartInfo' does not exist in the current context

8 years agoMerge pull request #2582 from ludovic-henry/fix-threadpool-starvation
monojenkins [Tue, 9 Feb 2016 23:00:32 +0000 (23:00 +0000)]
Merge pull request #2582 from ludovic-henry/fix-threadpool-starvation

[threadpool] Improve the monitor thread heuristic

Because the ThreadPool heuristic is optimized for short lived work item, it has more difficulty when executing long lived work item. That case can lead to a starvation of the worker threads: they are all doing work, while there is outstanding request, and these requests are not satisfied because we reached the max number of working thread.

To fix that issue, we have the monitor thread, whose sole job is to unstuck this kind of starvation cases. Unfortunately, it only works when all the worker threads are in the ThreadState.WaitSleepJoin state, which excludes the case of calling an IO operation in a Task. That includes the case of FileStream.BeginRead/Write/... which implementation can be simplified as follows: FileStream.BeginRead(...) -> Task.Run(() => FileStream.Read(...)).

The way we implement it in this commit is: every MONITOR_INTERVAL (500ms here), we check if there is any outstanding request, and if so, we assume that we are in the starvation case, and we simply increase the max number of working thread. Also to reduce the number of false positives, we do that only if there has been no completed work item for more than at least MONITOR_INTERVAL (in case of low CPU usage, more otherwise, see monitor_sufficient_delay_since_last_dequeue). This case is typically the case where we have all working thread stuck in long running work items.

Finally we increase the monitor interval from 100ms to 500ms so we guarantee we do not create more than 2 threads per second in the monitor thread. That is the value used by the old threadpool.

8 years ago[Docs] handle code-markdown with dots on the names
Miguel de Icaza [Tue, 9 Feb 2016 22:05:34 +0000 (17:05 -0500)]
[Docs] handle code-markdown with dots on the names

8 years ago[Docs] Continue to improve the Mono runtime documentation
Miguel de Icaza [Tue, 9 Feb 2016 20:52:53 +0000 (15:52 -0500)]
[Docs] Continue to improve the Mono runtime documentation

8 years agoMerge pull request #2570 from lambdageek/monoerror-reflection-bubble-2
Aleksey Kliger (λgeek) [Tue, 9 Feb 2016 20:52:52 +0000 (15:52 -0500)]
Merge pull request #2570 from lambdageek/monoerror-reflection-bubble-2

[reflection] Grab bag of MonoError commits

8 years ago[threadpool] Improve the monitor thread heuristic
Ludovic Henry [Tue, 9 Feb 2016 19:17:14 +0000 (19:17 +0000)]
[threadpool] Improve the monitor thread heuristic

Because the ThreadPool heuristic is optimized for short lived work item, it has more difficulty when executing long lived work item. That case can lead to a starvation of the worker threads: they are all doing work, while there is outstanding request, and these requests are not satisfied because we reached the max number of working thread.

To fix that issue, we have the monitor thread, whose sole job is to unstuck this kind of starvation cases. Unfortunately, it only works when all the worker threads are in the ThreadState.WaitSleepJoin state, which excludes the case of calling an IO operation in a Task. That includes the case of FileStream.BeginRead/Write/... which implementation can be simplified as follows: FileStream.BeginRead(...) -> Task.Run(() => FileStream.Read(...)).

The way we implement it in this commit is: every MONITOR_INTERVAL (500ms here), we check if there is any outstanding request, and if so, we assume that we are in the starvation case, and we simply increase the max number of working thread. Also to reduce the number of false positives, we do that only if there has been no completed work item for more than at least MONITOR_INTERVAL (in case of low CPU usage, more otherwise, see monitor_sufficient_delay_since_last_dequeue). This case is typically the case where we have all working thread stuck in long running work items.

Finally we increase the monitor interval from 100ms to 500ms so we guarantee we do not create more than 2 threads per second in the monitor thread. That is the value used by the old threadpool.

8 years ago[reflection] Fix decl of mono_image_create_token
Aleksey Kliger [Tue, 9 Feb 2016 18:34:39 +0000 (13:34 -0500)]
[reflection] Fix decl of mono_image_create_token

For the DISABLE_REFLECTION_EMIT case

8 years ago[reflection] Mark mono_custom_attrs_construct external only
Aleksey Kliger [Thu, 4 Feb 2016 00:24:01 +0000 (19:24 -0500)]
[reflection] Mark mono_custom_attrs_construct external only

The function mono_custom_attrs_construct_by_type is available for the
runtime (though currently static) and uses MonoError for error handling.

8 years ago[reflection] Use MonoError in mono_reflection_marshal_as_attribute_from_marshal_spec
Aleksey Kliger [Wed, 3 Feb 2016 23:56:59 +0000 (18:56 -0500)]
[reflection] Use MonoError in mono_reflection_marshal_as_attribute_from_marshal_spec

8 years ago[runtime] Use MonoError for mono_event_get_object
Aleksey Kliger [Wed, 3 Feb 2016 23:07:53 +0000 (18:07 -0500)]
[runtime] Use MonoError for mono_event_get_object

Mark mono_event_get_object external only.
Runtime should use mono_event_get_object_checked.

8 years ago[runtime] Use MonoError for mono_property_get_object
Aleksey Kliger [Wed, 3 Feb 2016 22:58:21 +0000 (17:58 -0500)]
[runtime] Use MonoError for mono_property_get_object

Mark mono_property_get_object external only.
Runtime should use mono_property_get_object_checked.

8 years ago[reflection] Push MonoError through some static functions
Aleksey Kliger [Wed, 3 Feb 2016 22:21:24 +0000 (17:21 -0500)]
[reflection] Push MonoError through some static functions

8 years ago[debugger] Don't call buffer_add_objid with NULL
Aleksey Kliger [Tue, 9 Feb 2016 16:39:08 +0000 (11:39 -0500)]
[debugger] Don't call buffer_add_objid with NULL

Fixup 64778857e4652ccac18c6fbf990f3e7cc69fa275

8 years ago[runtime] Cleanup MonoError after mono_runtime_try_invoke
Aleksey Kliger [Tue, 9 Feb 2016 17:10:26 +0000 (12:10 -0500)]
[runtime] Cleanup MonoError after mono_runtime_try_invoke

If both an exception exc is set and the MonoError is not ok, we could
leak the MonoError memory.  Explicitly cleanup.

8 years ago[mini] Use catchExcInMonoError to decide if exc should be embedded in MonoError
Aleksey Kliger [Tue, 9 Feb 2016 16:59:24 +0000 (11:59 -0500)]
[mini] Use catchExcInMonoError to decide if exc should be embedded in MonoError

Do the dyn_runtime_invoke decision the same way as other invokes.

Fixup to 45bd9bb5d50e6cbd806a5e95696656eedad3bb78

8 years ago[runtime] Don't raise MonoError when unloading appdomain
Aleksey Kliger [Tue, 9 Feb 2016 16:45:43 +0000 (11:45 -0500)]
[runtime] Don't raise MonoError when unloading appdomain

There's no managed code calling mono_domain_try_unload, so raising was
wrong.  Thread the error out through exc which gets checked by callers.

Fixup for 45bd9bb5d50e6cbd806a5e95696656eedad3bb78

8 years ago[Docs] document one of our most key APIs: mono_add_internal_call
Miguel de Icaza [Tue, 9 Feb 2016 17:05:24 +0000 (12:05 -0500)]
[Docs] document one of our most key APIs: mono_add_internal_call

8 years ago[Docs] Improved the rendering, added some docs
Miguel de Icaza [Tue, 9 Feb 2016 16:46:46 +0000 (11:46 -0500)]
[Docs] Improved the rendering, added some docs

8 years agoMerge pull request #2579 from ludovic-henry/fix-asyncresult-unhandledexception
monojenkins [Tue, 9 Feb 2016 12:25:36 +0000 (12:25 +0000)]
Merge pull request #2579 from ludovic-henry/fix-asyncresult-unhandledexception

[AsyncResult] Fix unhandled exception behaviour in AsyncCallback

The AsyncCallback is called after the BeginInvoke has completed. In all cases, this AsyncCallback is called on the ThreadPool, meaning that an unhandled exception would lead to a process crash.

The correct behaviour, after verification on .NET, is to not swallow the exception, and to properly crash the process.

@monojenkins merge

8 years ago[AsyncResult] Fix unhandled exception behaviour in AsyncCallback
Ludovic Henry [Tue, 9 Feb 2016 10:31:33 +0000 (10:31 +0000)]
[AsyncResult] Fix unhandled exception behaviour in AsyncCallback

The AsyncCallback is called after the BeginInvoke has completed. In all cases, this AsyncCallback is called on the ThreadPool, meaning that an unhandled exception would lead to a process crash.

The correct behaviour, after verification on .NET, is to not swallow the exception, and to properly crash the process.

8 years ago[corlib] AppContext from reference source
Marek Safar [Tue, 9 Feb 2016 10:34:35 +0000 (11:34 +0100)]
[corlib] AppContext from reference source

8 years ago[Docs] Use an external style sheet, prefix the css classes with mapi to isolate,...
Miguel de Icaza [Tue, 9 Feb 2016 03:00:13 +0000 (22:00 -0500)]
[Docs] Use an external style sheet, prefix the css classes with mapi to isolate, fix various processing problems

8 years agoMerge pull request #2578 from akoeplinger/fix-hardcoded-mono-2.0-path
Alexander Köplinger [Tue, 9 Feb 2016 01:31:21 +0000 (02:31 +0100)]
Merge pull request #2578 from akoeplinger/fix-hardcoded-mono-2.0-path

[metadata] Fix hardcoded mono/2.0 path in assembly.c

8 years ago[llvmonly] Compile the bitcode files using -O2.
Zoltan Varga [Tue, 9 Feb 2016 01:01:58 +0000 (20:01 -0500)]
[llvmonly] Compile the bitcode files using -O2.

8 years agoMerge pull request #2577 from xmcclure/bugzilla-37834
monojenkins [Tue, 9 Feb 2016 00:45:26 +0000 (00:45 +0000)]
Merge pull request #2577 from xmcclure/bugzilla-37834

Recognize OS X file "locked" state (fixes #37834)

Quick fix for https://bugzilla.xamarin.com/show_bug.cgi?id=37834

IOLayer is_file_writable/System.IO.File.GetAttributes on posix systems looks only at the unix file permissions and does not consider special OS flags. This leads to an easily end-user-triggered bug on OS X if a mono app (the bug was observed in Xamarin Studio) uses GetAttribute on a file which has been "Locked" using the checkbox in Finder Get Info. This patch recognizes the "uchg" flag for non-writability which Finder uses.

8 years ago[llvmonly] Add unbox wrappers when invoking vtype instance methods through a delegate.
Zoltan Varga [Tue, 9 Feb 2016 00:21:49 +0000 (19:21 -0500)]
[llvmonly] Add unbox wrappers when invoking vtype instance methods through a delegate.

8 years ago[Documentation] Fix the nesting of docs
Miguel de Icaza [Mon, 8 Feb 2016 22:15:17 +0000 (17:15 -0500)]
[Documentation] Fix the nesting of docs

8 years ago[metadata] Fix hardcoded mono/2.0 path in assembly.c
Alexander Köplinger [Mon, 8 Feb 2016 20:44:32 +0000 (21:44 +0100)]
[metadata] Fix hardcoded mono/2.0 path in assembly.c

The performance team discovered this on their bots using the Jenkins snapshot packages. Mono would fail to start with a message like:

```
The assembly mscorlib.dll was not found or could not be loaded.
It should have been installed in the `/opt/mono-2016.02.08+15.25.39/lib/mono/4.5/mscorlib.dll' directory.
```

The one odd thing is that they are using Mono installed in a path which is different from the prefix used during compilation.

It turns out that the runtime has a hardcoded check for lib/mono/2.0 in https://github.com/mono/mono/blob/7d5a7ea7ac324bb4ee63094ddcf8e20ae9ba4322/mono/metadata/assembly.c#L633-L637.
Since we recently stopped shipping 2.0 in the packages (we moved to 2.0-api for the reference assemblies) this directory wasn't there,
so the code in fallback() called into mono_config_get_assemblies_dir() which just returns the MONO_ASSEMBLIES preprocessor symbol.

That preprocessor symbol is defined to the value of --prefix during compilation, so Mono couldn't find corlib there as well since it's installed in another path which ultimately results in the above error message.

The fix is to change the hardcoded value to 4.5, which is what we established as the directory with the "latest" assemblies now.
Ideally we should find a way to stop hardcoding those paths in the runtime.

PS: I grepped through the runtime source to make sure we don't hardcode 2.0/3.5/4.0 elsewhere and only found one instance in a test.
I fixed it there as well, though the test looks suspicious since it hardcodes /usr ...

8 years ago[docs] Improve the rendering of our API binding APIs and runtime API documentation
Miguel de Icaza [Mon, 8 Feb 2016 18:56:51 +0000 (13:56 -0500)]
[docs] Improve the rendering of our API binding APIs and runtime API documentation

8 years agoSupport OS X "locked" state (fixes #37834)
Andi McClure [Mon, 8 Feb 2016 20:01:45 +0000 (15:01 -0500)]
Support OS X "locked" state (fixes #37834)

IOLayer is_file_writable/System.IO.File.GetAttributes on posix systems
looks only at the unix file permissions and does not consider special
OS flags. This leads to an easily end-user-triggered bug on OS X if a
mono app (the bug was observed in Xamarin Studio) uses GetAttribute on
a file which has been "Locked" using the checkbox in Finder Get Info.
This patch recognizes the "uchg" flag for non-writability which Finder
uses.

8 years agoMerge pull request #2555 from lambdageek/monoerror-mono_runtime_invoke-2
Aleksey Kliger (λgeek) [Mon, 8 Feb 2016 19:12:47 +0000 (14:12 -0500)]
Merge pull request #2555 from lambdageek/monoerror-mono_runtime_invoke-2

Use MonoError for mono_runtime_invoke

8 years ago[mcs] Use $(PLATFORM_PATH_SEPARATOR) instead of ':' for MONO_PATH to fix Windows...
Alexander Köplinger [Mon, 8 Feb 2016 17:36:47 +0000 (18:36 +0100)]
[mcs] Use $(PLATFORM_PATH_SEPARATOR) instead of ':' for MONO_PATH to fix Windows tests

./ was added to MONO_PATH in b5c2b5892f3ff4c104f701a4175b90989e9c7045, but the Unix path separator ':' doesn't work on Windows.

8 years ago[msvc] Fix Debug build by disabling outdated projects in sln
Alexander Köplinger [Fri, 18 Dec 2015 02:49:43 +0000 (03:49 +0100)]
[msvc] Fix Debug build by disabling outdated projects in sln

8 years agoMerge pull request #2571 from lambdageek/monoerror-mono_assembly_get_object
Aleksey Kliger (λgeek) [Mon, 8 Feb 2016 18:08:28 +0000 (13:08 -0500)]
Merge pull request #2571 from lambdageek/monoerror-mono_assembly_get_object

Use MonoError in mono_assembly_get_object

8 years ago[System.Runtime.Caching] Make TestExpiredGetValues test more reliable
Alexander Köplinger [Sat, 6 Feb 2016 20:25:17 +0000 (21:25 +0100)]
[System.Runtime.Caching] Make TestExpiredGetValues test more reliable

It failed twice on Jenkins over the weekend:

```
Test Case Failures:
1) MonoTests.System.Runtime.Caching.MemoryCacheTest.TestExpiredGetValues :   #EGV4
  Expected: 0
  But was:  9

at MonoTests.System.Runtime.Caching.MemoryCacheTest.TestExpiredGetValues () [0x0012b] in /media/ssd/jenkins/workspace/test-mono-mainline/label/debian-armel/mcs/class/System.Runtime.Caching/Test/System.Runtime.Caching/MemoryCacheTest.cs:1304
```

We're sleeping just as long as the expiry time of the cache items (1s) which might not be enough.
Bumping the sleep time should fix this.

8 years ago[readme] Clarify --enable-parallel-mark description
Alexander Köplinger [Mon, 8 Feb 2016 15:46:17 +0000 (16:46 +0100)]
[readme] Clarify --enable-parallel-mark description

It's Boehm only and not enabled by default on some platforms (e.g. it's disabled on OSX).

8 years ago[runtime] Switch to mono_runtime_invoke_checked and mono_runtime_try_invoke
Aleksey Kliger [Fri, 5 Feb 2016 21:00:19 +0000 (16:00 -0500)]
[runtime] Switch to mono_runtime_invoke_checked and mono_runtime_try_invoke

Mark mono_runtime_invoke external only.
Runtime should use mono_runtime_invoke_checked and mono_runtime_try_invoke.

8 years ago[runtime] Use MonoError for mono_jit_runtime_invoke and mono_llvmonly_runtime_invoke
Ludovic Henry [Fri, 22 Jan 2016 16:55:32 +0000 (16:55 +0000)]
[runtime] Use MonoError for mono_jit_runtime_invoke and mono_llvmonly_runtime_invoke

8 years ago[reflection] Use MonoError in mono_assembly_get_object
Aleksey Kliger [Fri, 29 Jan 2016 21:47:19 +0000 (16:47 -0500)]
[reflection] Use MonoError in mono_assembly_get_object

Mark mono_assembly_get_object external only.
Runtime should use mono_assembly_get_object_checked.

Also propagated MonoError through a few static functions in reflection:
mono_reflection_get_type_internal () and
mono_reflection_get_type_internal_dynamic ()

8 years agoMerge pull request #2574 from abrasive/gcc5_fix_gc
Rodrigo Kumpera [Mon, 8 Feb 2016 14:30:16 +0000 (06:30 -0800)]
Merge pull request #2574 from abrasive/gcc5_fix_gc

libgc: use __builtin_frame_address in GC_approx_sp

8 years agoMerge pull request #2575 from alexrp/master
Rodrigo Kumpera [Mon, 8 Feb 2016 14:27:34 +0000 (06:27 -0800)]
Merge pull request #2575 from alexrp/master

[profiler] Fix a rare crash when sending SIGPROF to a starting thread.

8 years ago[profiler] Fix a rare crash when sending SIGPROF to a starting thread.
Alex Rønne Petersen [Mon, 8 Feb 2016 10:24:51 +0000 (11:24 +0100)]
[profiler] Fix a rare crash when sending SIGPROF to a starting thread.

When sample profiling is enabled and we send a SIGPROF signal to a thread that
hasn't yet transitioned to a running state (e.g. STATE_RUNNING), the signal can
sometimes be delivered at such an early point that libc has not even finished
initializing TLS for that thread yet. This is problematic because we then go
right on to crash in the SIGPROF signal handler when we try to save errno. We
then further crash in the SIGSEGV handler because we can't access the jit_tls
variable either.

The fix is fairly simple: Only send SIGPROF to threads that have transitioned
to a running state. Technically, TLS is initialized 'much' earlier than when
this state transition happens, but since the worst thing that can happen is
that we miss one sampling event (i.e. ~1sec by default) right at the beginning
of the thread's lifetime, this simple fix is good enough.

This crash seemingly only happened on OS X.

8 years ago[llvmonly] Disable tail calls as they break stack traces.
Zoltan Varga [Mon, 8 Feb 2016 07:28:28 +0000 (02:28 -0500)]
[llvmonly] Disable tail calls as they break stack traces.

8 years ago[llvm] Make the stack walk code return.
Zoltan Varga [Mon, 8 Feb 2016 07:27:33 +0000 (02:27 -0500)]
[llvm] Make the stack walk code return.

8 years agolibgc: use __builtin_frame_address in GC_approx_sp
James Laird-Wah [Sun, 7 Feb 2016 23:19:53 +0000 (10:19 +1100)]
libgc: use __builtin_frame_address in GC_approx_sp

With GCC 5.x, the compiler optimises away the dummy load used to
estimate the stack pointer address in GC_approx_sp; it returns
zero. This leads to segfaults when embedding Mono.

Instead, use __builtin_frame_address, which GCC's libgc uses for
the same purpose.

8 years ago[llvmonly] Compile the bitcode files using -O2 (only in desktop llvmonly mode).
Zoltan Varga [Sun, 7 Feb 2016 02:11:06 +0000 (21:11 -0500)]
[llvmonly] Compile the bitcode files using -O2 (only in desktop llvmonly mode).

8 years ago[llvm] When storing valuetypes received in registers to the stack, store only the...
Zoltan Varga [Sun, 7 Feb 2016 02:10:37 +0000 (21:10 -0500)]
[llvm] When storing valuetypes received in registers to the stack, store only the value parts of the register, the upper bits might container garbage.

8 years agoMerge pull request #2567 from lambdageek/monoerror-mono_module_file_get_object
Aleksey Kliger (λgeek) [Sat, 6 Feb 2016 16:08:39 +0000 (11:08 -0500)]
Merge pull request #2567 from lambdageek/monoerror-mono_module_file_get_object

[reflection] Use MonoError in mono_module_file_get_object

8 years ago[jit] Disable to returning of trampolines from mini_jit_info_table_find () to see...
Zoltan Varga [Sat, 6 Feb 2016 08:09:50 +0000 (03:09 -0500)]
[jit] Disable to returning of trampolines from mini_jit_info_table_find () to see whenever that fixes failures on wrench.

8 years ago[llvmonly] Remove the mono_llvmonly_get_calling_assembly () workaround since stack...
Zoltan Varga [Sat, 6 Feb 2016 06:59:38 +0000 (01:59 -0500)]
[llvmonly] Remove the mono_llvmonly_get_calling_assembly () workaround since stack walks work in llvmonly mode now.

8 years ago[reflection] Use MonoError in mono_module_file_get_object
Aleksey Kliger [Fri, 29 Jan 2016 17:20:30 +0000 (12:20 -0500)]
[reflection] Use MonoError in mono_module_file_get_object

Mark mono_module_file_get_object external only.
Use mono_module_file_get_object_checked in runtime code.

8 years agoFix the build.
Zoltan Varga [Fri, 5 Feb 2016 20:22:11 +0000 (15:22 -0500)]
Fix the build.

8 years agoMerge pull request #2569 from xmcclure/gshared-enable
Andi McClure [Fri, 5 Feb 2016 18:39:58 +0000 (13:39 -0500)]
Merge pull request #2569 from xmcclure/gshared-enable

Miscellaneous minor improvements around amd64 aot

8 years agoFixed compiler to wrap paths with embedded spaces when calling external tools.
João Matos [Fri, 5 Feb 2016 16:52:49 +0000 (16:52 +0000)]
Fixed compiler to wrap paths with embedded spaces when calling external tools.

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

8 years ago[corlib] Disable ThreadLocalTests.DisposeOnThreadExit on MonoTouch, it's randomly...
Rolf Bjarne Kvinge [Fri, 5 Feb 2016 14:15:45 +0000 (15:15 +0100)]
[corlib] Disable ThreadLocalTests.DisposeOnThreadExit on MonoTouch, it's randomly failing.

8 years agoMerge pull request #2572 from akoeplinger/fix-monodoc-language
Alexander Köplinger [Fri, 5 Feb 2016 15:14:05 +0000 (16:14 +0100)]
Merge pull request #2572 from akoeplinger/fix-monodoc-language

[monodoc] Fix literal formatting on systems where decimal separator is not a dot

8 years ago[llvmonly] Various small fixes. Make mono_llvm_throw_exception etc. directly callable...
Zoltan Varga [Fri, 5 Feb 2016 07:07:40 +0000 (02:07 -0500)]
[llvmonly] Various small fixes. Make mono_llvm_throw_exception etc. directly callable in static mode. Add support for directly calling pinvoke methods. Fix an assertion during EH.

8 years ago[Docs] More API docs
Miguel de Icaza [Fri, 5 Feb 2016 04:14:01 +0000 (23:14 -0500)]
[Docs] More API docs

8 years ago[llvmonly] Don't set the invariant.load flag on loads from the GOT, they are initiali...
Zoltan Varga [Fri, 5 Feb 2016 03:40:44 +0000 (22:40 -0500)]
[llvmonly] Don't set the invariant.load flag on loads from the GOT, they are initialized by a call to init_method () so they are not completely invariant.

8 years agoRevert "[jit] Don't allocate memory for unused vreg"
Zoltan Varga [Fri, 5 Feb 2016 00:02:18 +0000 (19:02 -0500)]
Revert "[jit] Don't allocate memory for unused vreg"

This reverts commit 137c0999cc8e1e9171c7703af9b013f2e43731f5.

Revert this as leads to a memory overwrite on x86:

defs [ins->dreg + 1] = NULL;

8 years agoMove some amd64 constants out of source into header
Andi McClure [Thu, 4 Feb 2016 19:11:45 +0000 (14:11 -0500)]
Move some amd64 constants out of source into header

8 years agoClarify trampoline error message in aot-runtime
Andi McClure [Thu, 4 Feb 2016 18:43:03 +0000 (13:43 -0500)]
Clarify trampoline error message in aot-runtime

8 years agoMerge pull request #2566 from lambdageek/monoerror-mono_module_get_object
Aleksey Kliger (λgeek) [Thu, 4 Feb 2016 15:26:54 +0000 (10:26 -0500)]
Merge pull request #2566 from lambdageek/monoerror-mono_module_get_object

[reflection] Use MonoError for mono_module_get_object

8 years agoMerge pull request #2535 from lambdageek/monoerror-reflection-bubble
Aleksey Kliger (λgeek) [Thu, 4 Feb 2016 15:26:25 +0000 (10:26 -0500)]
Merge pull request #2535 from lambdageek/monoerror-reflection-bubble

[reflection] Push MonoError through misc methods

8 years ago[System] Remove explicit sdk target from CSharpCodeCompiler
Marek Safar [Thu, 4 Feb 2016 15:03:11 +0000 (16:03 +0100)]
[System] Remove explicit sdk target from CSharpCodeCompiler

8 years ago[io-layer] Print from which pipe we just read
Ludovic Henry [Thu, 4 Feb 2016 14:30:55 +0000 (14:30 +0000)]
[io-layer] Print from which pipe we just read

8 years ago[Process] Fix possible double call to Begin(Output|Error)ReadLine
Ludovic Henry [Thu, 4 Feb 2016 14:28:17 +0000 (14:28 +0000)]
[Process] Fix possible double call to Begin(Output|Error)ReadLine

This is not allowed in .NET, as it could lead to unexpected results.

8 years ago[threads] Remove mono_thread_notify_pending_exc_fn dead code
Ludovic Henry [Tue, 2 Feb 2016 11:30:59 +0000 (11:30 +0000)]
[threads] Remove mono_thread_notify_pending_exc_fn dead code

8 years ago[thread] Remove mono_thread_info_begin_suspend unused parameter
Ludovic Henry [Mon, 1 Feb 2016 18:17:35 +0000 (18:17 +0000)]
[thread] Remove mono_thread_info_begin_suspend unused parameter

8 years ago[threads] Remove unecessary block/unblock suspend ACK signal
Ludovic Henry [Tue, 2 Feb 2016 10:23:25 +0000 (10:23 +0000)]
[threads] Remove unecessary block/unblock suspend ACK signal

Blocking suspend_ack_signal_mask is only useful if we are notifying the initiator of suspend followed by waiting on the suspend_signal_mask.

8 years ago[mcs] Update sdk profile paths after 88b287f06584a6284face60accb94d000b1c6ce7
Marek Safar [Thu, 4 Feb 2016 13:08:57 +0000 (14:08 +0100)]
[mcs] Update sdk profile paths after 88b287f06584a6284face60accb94d000b1c6ce7

8 years ago[monodoc] Fix literal formatting on systems where decimal separator is not a dot
Alexander Köplinger [Thu, 4 Feb 2016 01:37:36 +0000 (02:37 +0100)]
[monodoc] Fix literal formatting on systems where decimal separator is not a dot

E.g. on a German language OS the "make check-mdoc-export-html" test fails with this:

```
diff --exclude=.svn -rup Test/en.expected/Mono.DocTest/Widget.xml Test/en.actual/Mono.DocTest/Widget.xml
--- Test/en.expected/Mono.DocTest/Widget.xml 2015-11-18 04:42:11.000000000 +0100
+++ Test/en.actual/Mono.DocTest/Widget.xml 2016-02-04 02:38:09.000000000 +0100
@@ -1061,8 +1061,8 @@
       </Docs>
     </Member>
     <Member MemberName="PI">
-      <MemberSignature Language="C#" Value="protected const double PI = 3.14159;" />
-      <MemberSignature Language="ILAsm" Value=".field familyorassembly static literal float64 PI = (3.14159)" />
+      <MemberSignature Language="C#" Value="protected const double PI = 3,14159;" />
+      <MemberSignature Language="ILAsm" Value=".field familyorassembly static literal float64 PI = (3,14159)" />
       <MemberType>Field</MemberType>
       <AssemblyInfo>
         <AssemblyVersion>0.0.0.0</AssemblyVersion>
@@ -1070,7 +1070,7 @@
       <ReturnValue>
         <ReturnType>System.Double</ReturnType>
       </ReturnValue>
-      <MemberValue>3.14159</MemberValue>
+      <MemberValue>3,14159</MemberValue>
       <Docs>
```

The fix is to always use InvariantCulture for literal formatting.

8 years ago[llvm] Zero extend unsigned enum arguments. Fixes #38379.
Zoltan Varga [Wed, 3 Feb 2016 23:16:02 +0000 (18:16 -0500)]
[llvm] Zero extend unsigned enum arguments. Fixes #38379.

8 years agoAdd --exclude-test option to mono/mini test driver
Andi McClure [Wed, 3 Feb 2016 22:16:59 +0000 (17:16 -0500)]
Add --exclude-test option to mono/mini test driver

8 years agoMinor additions to comments around amd64 aot
Andi McClure [Wed, 3 Feb 2016 22:16:01 +0000 (17:16 -0500)]
Minor additions to comments around amd64 aot

8 years agoChanges to gsharedvt amd64 tests
Andi McClure [Wed, 3 Feb 2016 22:15:27 +0000 (17:15 -0500)]
Changes to gsharedvt amd64 tests

Re-enable tests, add a test for long/float returning gsharedvt->normal
for a static method, add tests for sign extension.

8 years ago[reflection] Use MonoError for mono_module_get_object
Aleksey Kliger [Fri, 29 Jan 2016 17:15:50 +0000 (12:15 -0500)]
[reflection] Use MonoError for mono_module_get_object

Mark mono_module_get_object external only.
Runtime should use mono_module_get_object_checked.

8 years ago[reflection] Use MonoError in mono_image_get_{method,ctor}_on_inst_token
Aleksey Kliger [Fri, 29 Jan 2016 00:55:02 +0000 (19:55 -0500)]
[reflection] Use MonoError in mono_image_get_{method,ctor}_on_inst_token

8 years ago[reflection] Use MonoError for mono_image_get_{method,ctor}builder_token
Aleksey Kliger [Fri, 29 Jan 2016 00:14:22 +0000 (19:14 -0500)]
[reflection] Use MonoError for mono_image_get_{method,ctor}builder_token

8 years ago[reflection] Use MonoError in mono_image_create_pefile
Aleksey Kliger [Thu, 28 Jan 2016 23:56:30 +0000 (18:56 -0500)]
[reflection] Use MonoError in mono_image_create_pefile

8 years ago[reflection] Don't raise in mono_image_get_method_info
Aleksey Kliger [Thu, 28 Jan 2016 23:47:25 +0000 (18:47 -0500)]
[reflection] Don't raise in mono_image_get_method_info

8 years ago[reflection] Don't raise in reflection_methodbuilder_from_{method,ctor}_builder
Aleksey Kliger [Thu, 28 Jan 2016 23:32:18 +0000 (18:32 -0500)]
[reflection] Don't raise in reflection_methodbuilder_from_{method,ctor}_builder

8 years ago[reflection] Don't raise in mono_type_get_object_checked
Aleksey Kliger [Thu, 28 Jan 2016 23:20:46 +0000 (18:20 -0500)]
[reflection] Don't raise in mono_type_get_object_checked

8 years ago[reflection] Use MonoError for mono_image_create_method_token
Aleksey Kliger [Thu, 28 Jan 2016 23:18:08 +0000 (18:18 -0500)]
[reflection] Use MonoError for mono_image_create_method_token

8 years ago[reflection] Use MonoError for mono_image_build_metadata
Aleksey Kliger [Thu, 28 Jan 2016 22:57:53 +0000 (17:57 -0500)]
[reflection] Use MonoError for mono_image_build_metadata

8 years ago[reflection] Use MonoError in mono_image_create_token
Aleksey Kliger [Thu, 28 Jan 2016 22:35:52 +0000 (17:35 -0500)]
[reflection] Use MonoError in mono_image_create_token

8 years ago[reflection] Use MonoError in some static functions
Aleksey Kliger [Thu, 28 Jan 2016 22:21:15 +0000 (17:21 -0500)]
[reflection] Use MonoError in some static functions

Pass a MonoError argument to:
method_encode_code, mono_image_basic_method, mono_image_get_ctor_info

8 years agoMerge pull request #2542 from akoeplinger/remove-changelog
Alexander Köplinger [Wed, 3 Feb 2016 20:09:24 +0000 (21:09 +0100)]
Merge pull request #2542 from akoeplinger/remove-changelog

Remove ChangeLog files from the repo

8 years agoMerge pull request #2554 from ludovic-henry/coop-blocking-interrupt
Rodrigo Kumpera [Wed, 3 Feb 2016 20:08:35 +0000 (15:08 -0500)]
Merge pull request #2554 from ludovic-henry/coop-blocking-interrupt

[coop] Use signals for blocking syscall interrupt

8 years agoMerge pull request #2559 from lewurm/hazard-pointer-clear
Rodrigo Kumpera [Wed, 3 Feb 2016 19:53:55 +0000 (14:53 -0500)]
Merge pull request #2559 from lewurm/hazard-pointer-clear

[hazard pointers] add write barrier on clear as well

8 years ago[binary-reference-assemblies] Add a symlink from 4.0/mscorlib.dll to 4.0-api/mscorlib.dll
Alexander Köplinger [Wed, 3 Feb 2016 18:45:25 +0000 (19:45 +0100)]
[binary-reference-assemblies] Add a symlink from 4.0/mscorlib.dll to 4.0-api/mscorlib.dll

Some programs like NUnit check if a file exists there and break otherwise.

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

8 years ago[docs] remove a deleted file from EXTRA_DIST
Alexander Köplinger [Wed, 3 Feb 2016 18:04:36 +0000 (19:04 +0100)]
[docs] remove a deleted file from EXTRA_DIST