Skip to content

Instantly share code, notes, and snippets.

View mkrueger's full-sized avatar

Mike Krüger mkrueger

View GitHub Profile
namespace BenchmarkGameBTrees
{
/*
The Computer Language Benchmarks Game
http://benchmarksgame.alioth.debian.org/
contributed by Marek Safar
optimized by kasthack
*/
using System;
/* The Computer Language Benchmarks Game
* http://benchmarksgame.alioth.debian.org/
contributed by Kevin Carson
compilation:
gcc -O3 -fomit-frame-pointer -funroll-loops -static binary-trees.c -lm
icc -O3 -ip -unroll -static binary-trees.c -lm
*/
#include <malloc.h>
/**
* The Computer Language Benchmarks Game
* http://benchmarksgame.alioth.debian.org/
*
* Loosely based on Jarkko Miettinen's implementation. Requires Java 8.
*
* contributed by Heikki Salokanto.
* modified by Chandra Sekar
*/
namespace BenchmarkGameBTrees
{
/*
The Computer Language Benchmarks Game
http://benchmarksgame.alioth.debian.org/
contributed by Marek Safar
optimized by kasthack
*/
using System;
/**
* The Computer Language Benchmarks Game
* http://benchmarksgame.alioth.debian.org/
*
* Loosely based on Jarkko Miettinen's implementation. Requires Java 8.
*
* contributed by Heikki Salokanto.
* modified by Chandra Sekar
*/
ERROR [2015-06-19 18:53:43Z]: An unhandled exception has occured. Terminating MonoDevelop? False
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NotImplementedException: The requested feature is not implemented.
at System.Threading.ThreadLocal`1[System.Collections.Generic.List`1[Microsoft.CodeAnalysis.Formatting.Rules.IndentBlockOperation]]..ctor (System.Func`1 valueFactory, Boolean trackAllValues) [0x00000] in <filename unknown>:0
at Microsoft.CodeAnalysis.Formatting.AbstractFormatEngine.AddOperations[IndentBlockOperation] (System.Collections.Generic.List`1 nodes, System.Action`2 addOperations, CancellationToken cancellationToken) [0x00000] in <filename unknown>:0
at Microsoft.CodeAnalysis.Formatting.AbstractFormatEngine+<>c__DisplayClass16_0.<CreateNodeOperationTasks>b__1 (System.Threading.Tasks.Task`1 task) [0x00000] in <filename unknown>:0
at Microsoft.CodeAnalysis.Formatting.TaskExecutor+SynchronousExecutor.ContinueWith[List`1,
This file has been truncated, but you can view the full file.
Mono log profiler data
Profiler version: 0.4
Data version: 10
Mean timer overhead: 20 nanoseconds
Program startup: Thu Jun 11 12:58:29 2015
Program ID: 9136
JIT summary
Compiled methods: 126427
diff --git a/mcs/class/System.Core/System.IO.MemoryMappedFiles/MemoryMappedViewAccessor.cs b/mcs/class/System.Core/System.IO.MemoryMappedFiles/MemoryMappedViewAccessor.cs
index 783aa91..4a2bd99 100644
--- a/mcs/class/System.Core/System.IO.MemoryMappedFiles/MemoryMappedViewAccessor.cs
+++ b/mcs/class/System.Core/System.IO.MemoryMappedFiles/MemoryMappedViewAccessor.cs
@@ -37,10 +37,37 @@ namespace System.IO.MemoryMappedFiles
public sealed class MemoryMappedViewAccessor : UnmanagedMemoryAccessor, IDisposable {
IntPtr mmap_handle;
SafeMemoryMappedViewHandle safe_handle;
+
+ MSShouldNotUseInternalAPIWrapper m_view;
while (true) {
var button = new Gtk.Button ();
button.Destroy ();
// button.Dispose ();
System.GC.Collect ();
}
private static long GetPrivateOffset (MemoryMappedViewAccessor stream)
{
object value = typeof(MemoryMappedViewAccessor).GetField ("m_view", BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.GetField).GetValue (stream);
return (long)value.GetType ().GetProperty ("PointerOffset", BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.GetProperty).GetValue (value);
}