Merge pull request #5560 from kumpera/wasm-work-p3
authorRodrigo Kumpera <kumpera@users.noreply.github.com>
Thu, 28 Sep 2017 22:06:02 +0000 (18:06 -0400)
committerGitHub <noreply@github.com>
Thu, 28 Sep 2017 22:06:02 +0000 (18:06 -0400)
More WASM fixes, with this I can get half of the mini test suite to run without crashing.

156 files changed:
Makefile.am
acceptance-tests/SUBMODULES.json
acceptance-tests/ms-test-suite.mk
external/api-snapshot
external/bockbuild
external/ikdasm
man/mono.1
man/mprof-report.1
mcs/class/Mono.Data.Tds/Test/bug-4786.cs
mcs/class/Mono.Posix/Mono.Unix/UnixMarshal.cs
mcs/class/Mono.Posix/Test/Mono.Unix/UnixMarshalTest.cs
mcs/class/Mono.Profiler.Log/Mono.Profiler.Log/LogEnums.cs
mcs/class/Mono.Profiler.Log/Mono.Profiler.Log/LogProcessor.cs
mcs/class/Mono.Profiler.Log/Mono.Profiler.Log/LogReader.cs
mcs/class/Mono.Profiler.Log/Mono.Profiler.Log/LogStream.cs
mcs/class/Mono.Profiler.Log/Mono.Profiler.Log/LogStreamHeader.cs
mcs/class/Mono.Security/Mono.Security.Interface/IMonoSslStream.cs
mcs/class/Mono.Security/Mono.Security.Interface/MonoTlsProviderFactory.cs
mcs/class/System.Runtime.Remoting/Makefile
mcs/class/System.Windows.Forms/System.Windows.Forms.Layout/TableLayoutSettingsTypeConverter.cs
mcs/class/System.Windows.Forms/System.Windows.Forms/TableLayoutStyleCollection.cs
mcs/class/System/Mono.Net.Security/MobileAuthenticatedStream.cs
mcs/class/System/System.Net.Security/SslStream.cs
mcs/class/WindowsBase/System.Windows.Converters/Int32RectValueSerializer.cs
mcs/class/WindowsBase/System.Windows.Converters/PointValueSerializer.cs
mcs/class/WindowsBase/System.Windows.Converters/RectValueSerializer.cs
mcs/class/WindowsBase/System.Windows.Converters/SizeValueSerializer.cs
mcs/class/WindowsBase/System.Windows.Converters/VectorValueSerializer.cs
mcs/class/WindowsBase/System.Windows.Media/Matrix.cs
mcs/class/WindowsBase/System.Windows/Int32Rect.cs
mcs/class/WindowsBase/System.Windows/NumericListTokenizer.cs [new file with mode: 0644]
mcs/class/WindowsBase/System.Windows/Point.cs
mcs/class/WindowsBase/System.Windows/Rect.cs
mcs/class/WindowsBase/System.Windows/Size.cs
mcs/class/WindowsBase/System.Windows/Vector.cs
mcs/class/WindowsBase/Test/System.Windows.Media/MatrixConverterTest.cs
mcs/class/WindowsBase/Test/System.Windows.Media/MatrixTest.cs
mcs/class/WindowsBase/Test/System.Windows/Int32RectConverterTest.cs
mcs/class/WindowsBase/Test/System.Windows/Int32RectTest.cs
mcs/class/WindowsBase/Test/System.Windows/Int32RectValueSerializerTest.cs [new file with mode: 0644]
mcs/class/WindowsBase/Test/System.Windows/PointConverterTest.cs
mcs/class/WindowsBase/Test/System.Windows/PointTest.cs
mcs/class/WindowsBase/Test/System.Windows/PointValueSerializerTest.cs [new file with mode: 0644]
mcs/class/WindowsBase/Test/System.Windows/RectConverterTest.cs
mcs/class/WindowsBase/Test/System.Windows/RectTest.cs
mcs/class/WindowsBase/Test/System.Windows/RectValueSerializerTest.cs [new file with mode: 0644]
mcs/class/WindowsBase/Test/System.Windows/SizeConverterTest.cs
mcs/class/WindowsBase/Test/System.Windows/SizeTest.cs
mcs/class/WindowsBase/Test/System.Windows/SizeValueSerializerTest.cs
mcs/class/WindowsBase/Test/System.Windows/VectorConverterTest.cs
mcs/class/WindowsBase/Test/System.Windows/VectorTest.cs
mcs/class/WindowsBase/Test/System.Windows/VectorValueSerializerTest.cs [new file with mode: 0644]
mcs/class/WindowsBase/WindowsBase-net_4_x.csproj
mcs/class/WindowsBase/WindowsBase.dll.sources
mcs/class/WindowsBase/WindowsBase_test.dll.sources
mcs/class/corlib/System.Reflection.Emit/AssemblyBuilder.cs
mcs/class/corlib/System.Security.Cryptography/DSACryptoServiceProvider.cs
mcs/class/corlib/System.Security.Cryptography/RSACryptoServiceProvider.cs
mcs/class/corlib/System/TimeZoneInfo.Serialization.cs
mcs/class/corlib/System/TimeZoneInfo.cs
mcs/class/corlib/Test/System.Globalization/NumberFormatInfoTest.cs
mcs/class/corlib/Test/System.IO/FileTest.cs
mcs/class/corlib/Test/System.Reflection.Emit/DynamicMethodTest.cs
mcs/class/corlib/Test/System.Security.Cryptography/DSACryptoServiceProviderTest.cs
mcs/class/corlib/Test/System.Security.Cryptography/RSACryptoServiceProviderTest.cs
mcs/class/corlib/Test/System/TimeZoneInfo.SerializationTest.cs
mcs/class/corlib/Test/System/TypeTest.cs
mcs/class/test-helpers/NetworkHelpers.cs
mcs/tools/linker-analyzer/README.md [new file with mode: 0644]
mcs/tools/mkbundle/mkbundle.cs
mcs/tools/mono-api-html/ConstructorComparer.cs
mcs/tools/mono-api-html/mono-api-html.sln [new file with mode: 0644]
mono/arch/ppc/ppc-codegen.h
mono/metadata/class-internals.h
mono/metadata/class.c
mono/metadata/class.h
mono/metadata/culture-info-tables.h
mono/metadata/gc.c
mono/metadata/icall-def.h
mono/metadata/icall.c
mono/metadata/loader.c
mono/metadata/metadata-verify.c
mono/metadata/monitor.c
mono/metadata/mono-hash.c
mono/metadata/mono-hash.h
mono/metadata/object-internals.h
mono/metadata/object-offsets.h
mono/metadata/object.c
mono/metadata/remoting.c
mono/metadata/sgen-mono.c
mono/metadata/sre.c
mono/metadata/threadpool.c
mono/metadata/threads-types.h
mono/metadata/threads.c
mono/metadata/verify.c
mono/metadata/w32error-unix.c
mono/metadata/w32handle.c
mono/metadata/w32process-unix.c
mono/metadata/w32socket-win32.c
mono/metadata/w32socket.c
mono/metadata/w32socket.h
mono/mini/aot-compiler.c
mono/mini/cpu-arm64.md
mono/mini/cpu-ppc.md
mono/mini/cpu-ppc64.md
mono/mini/debugger-agent.c
mono/mini/gshared.cs
mono/mini/iltests.il
mono/mini/jit-icalls.c
mono/mini/method-to-ir.c
mono/mini/mini-amd64.c
mono/mini/mini-amd64.h
mono/mini/mini-arm.c
mono/mini/mini-arm64.c
mono/mini/mini-arm64.h
mono/mini/mini-exceptions.c
mono/mini/mini-llvm.c
mono/mini/mini-ppc.c
mono/mini/mini-runtime.c
mono/mini/mini-trampolines.c
mono/mini/mini.h
mono/profiler/Makefile.am
mono/profiler/coverage.c [new file with mode: 0644]
mono/profiler/log-args.c
mono/profiler/log.c
mono/profiler/log.h
mono/profiler/mprof-report.c
mono/tests/Makefile.am
mono/tests/appdomain-unload-exception.cs [new file with mode: 0644]
mono/tests/appdomain-unload.cs
mono/tests/bug-59281.cs [new file with mode: 0644]
mono/tests/recursive-struct-arrays.cs [new file with mode: 0644]
mono/tests/runtime-invoke.cs
mono/tests/unhandled-exception-9.cs [new file with mode: 0644]
mono/tests/verifier/unverifiable_ref_return_stack_merge.il [new file with mode: 0644]
mono/tests/verifier/valid_ref_return.cs [new file with mode: 0644]
mono/tests/verifier/valid_ref_return_stack_merge.il [new file with mode: 0644]
mono/utils/Makefile.am
mono/utils/mono-os-semaphore.h
mono/utils/mono-os-wait-win32.c [new file with mode: 0644]
mono/utils/mono-os-wait.h [new file with mode: 0644]
mono/utils/mono-threads-windows.c
mono/utils/mono-threads.h
mono/utils/os-event-win32.c
mono/utils/unlocked.h
msvc/libmonoruntime.vcxproj.filters
msvc/libmonoutils.vcxproj
msvc/libmonoutils.vcxproj.filters
msvc/scripts/genproj.cs
packaging/MacSDK/fsharp.py
packaging/MacSDK/msbuild.py
packaging/MacSDK/patches/fsharp-install-netsdk-targets.patch [new file with mode: 0644]
scripts/ci/clang-thread-sanitizer-blacklist
tools/locale-builder/Driver.cs
tools/locale-builder/Makefile.am
tools/pedump/Makefile.am

index c322d249127837da530f6c936ee1f98df0ed6540..12b27f14b08425ea15bae3ce0d3af13287c02368 100644 (file)
@@ -145,4 +145,7 @@ update-llvm-version:
 update-solution-files:
        make update-csproj
        make package-inputs
-       (cd msvc/scripts; make genproj.exe; mono genproj.exe)
+       (cd msvc/scripts; make genproj.exe; mono genproj.exe $(GENPROJ_ARGS))
+
+update-solution-files-with-tests:
+       make "GENPROJ_ARGS=2012 true true" update-solution-files
index e641e67e70cab7b90ef2aef4f564a360c03d3367..4d70a4150a0ae9adc977373137ee3ab153277754 100644 (file)
@@ -18,7 +18,7 @@
   {
     "name": "ms-test-suite", 
     "url": "git@github.com:xamarin/ms-test-suite.git", 
-    "rev": "73c155f76b55839f26ba707d6d40091060e4f5d8", 
+    "rev": "25f495326e141163d59e52ef499227a2f38fe036", 
     "remote-branch": "origin/master", 
     "branch": "master", 
     "directory": "ms-test-suite"
index 7ed072e797d59c86766cf1d57f878e9d851e0926..202e635594240a2235d3aaa8fb6d01f5aa881ee7 100644 (file)
@@ -1,9 +1,11 @@
 check-ms-test-suite: $(CLASS)/nunitlite.dll
        @if $(MAKE) validate-ms-test-suite RESET_VERSIONS=1; then \
                $(MAKE) -C $(MSTESTSUITE_PATH)/conformance build MCS="$(MCS) -debug:portable -t:library -warn:1 -r:$(CLASS)/nunitlite.dll" && \
+               $(MAKE) -C $(MSTESTSUITE_PATH)/systemruntimebringup build MCS="$(MCS) -debug:portable -t:library -warn:1 -r:$(CLASS)/nunitlite.dll" && \
+               $(MAKE) -C $(MSTESTSUITE_PATH)/System.Linq.Expressions build MCS="$(MCS) -debug:portable -t:library -warn:1 -r:$(CLASS)/nunitlite.dll" && \
                $(MAKE) -C $(MSTESTSUITE_PATH)/conformance run NUNIT-CONSOLE="$(RUNTIME) $(CLASS)/nunit-lite-console.exe -exclude=MonoBug,BadTest -format:nunit2" NUNIT_XML_RESULT="-result:$(abs_top_builddir)/acceptance-tests/TestResult-ms-test-suite-conformance.xml" || EXIT_CODE=1; \
-               $(MAKE) -C $(MSTESTSUITE_PATH)/systemruntimebringup build MCS="$(MCS) -debug:portable -warn:1" && \
-               $(MAKE) -C $(MSTESTSUITE_PATH)/systemruntimebringup run MONO="$(RUNTIME)" || EXIT_CODE=1; \
+               $(MAKE) -C $(MSTESTSUITE_PATH)/systemruntimebringup run NUNIT-CONSOLE="$(RUNTIME) $(CLASS)/nunit-lite-console.exe -exclude=MonoBug,BadTest -format:nunit2" NUNIT_XML_RESULT="-result:$(abs_top_builddir)/acceptance-tests/TestResult-ms-test-suite-systemruntimebringup.xml" || EXIT_CODE=1; \
+               $(MAKE) -C $(MSTESTSUITE_PATH)/System.Linq.Expressions run NUNIT-CONSOLE="$(RUNTIME) $(CLASS)/nunit-lite-console.exe -exclude=MonoBug,BadTest -format:nunit2" NUNIT_XML_RESULT="-result:$(abs_top_builddir)/acceptance-tests/TestResult-ms-test-suite-systemlinqexpressions.xml" || EXIT_CODE=1; \
                exit $$EXIT_CODE; \
        else \
                echo "*** [ms-test-suite] Getting the repository failed, you probably don't have access to this Xamarin-internal resource. Skipping."; \
index 08ec62bbd349c042a40f959f242db7a54412e916..090c95d755f8112db5cf6c30df92a9941d9124a4 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 08ec62bbd349c042a40f959f242db7a54412e916
+Subproject commit 090c95d755f8112db5cf6c30df92a9941d9124a4
index f2c8f2e7fb17e8a55b6679c7d13e3634ec45c639..29022af5d8a94651b2eece93f910559b254ec3f0 160000 (submodule)
@@ -1 +1 @@
-Subproject commit f2c8f2e7fb17e8a55b6679c7d13e3634ec45c639
+Subproject commit 29022af5d8a94651b2eece93f910559b254ec3f0
index 3aef9cdd6013fc0620a1817f0b11d8fb90ed2e0f..465c0815558fd43c0110f8d00fc186ac0044ac6a 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 3aef9cdd6013fc0620a1817f0b11d8fb90ed2e0f
+Subproject commit 465c0815558fd43c0110f8d00fc186ac0044ac6a
index 7d2f14c151e5a42709de29d68df5022822d01667..5ac6ea81002aa08bca26649d78f1ea3288f0fe8e 100644 (file)
@@ -908,8 +908,11 @@ your profiler.
 For a sample of how to write your own custom profiler look in the
 Mono source tree for in the samples/profiler.c.
 .SH CODE COVERAGE
-Mono ships with a code coverage module in the \f[I]log\f[] profiler.
-Check the `coverage' option on the mprof-report(1) page for more details.
+Mono ships with a code coverage module in the \f[I]coverage\f[] profiler.
+To enable it, pass \fB--profile=coverage\fR to your mono invocation. It
+will by default output a coverage.xml in the current directory. Use
+\fBmono --profile=coverage:help sample.exe\fR for more information on the
+different options.
 .SH AOT PROFILING
 You can improve startup performance by using the AOT profiler.
 .PP
index 56663251bf8e0066c83fd9f700eb835d724a2ff2..45ea4f77b8825258569dafb600aa9461d41a6b5e 100644 (file)
@@ -213,9 +213,6 @@ The following commands are available:
 .IP \[bu] 2
 \f[I]nocounters\f[]: disables sampling of runtime and performance
 counters, which is normally done every 1 second.
-.IP \[bu] 2
-\f[I]coverage\f[]: collect code coverage data. This implies enabling
-the \f[I]calls\f[] option.
 .RE
 .SS Analyzing the profile data
 .PP
@@ -338,8 +335,6 @@ version
 .IP \[bu] 2
 \f[I]counters\f[]: counters samples
 .IP \[bu] 2
-\f[I]coverage\f[]: code coverage data
-.IP \[bu] 2
 \f[I]stats\f[]: event statistics
 .PP
 It is possible to limit some of the data displayed to a timeframe
@@ -411,13 +406,6 @@ By default mprof-report will print the summary data to the console.
 To print it to a file, instead, use the option:
 .PP
 \f[B]--out=FILENAME\f[]
-.SS Processing code coverage data
-.PP
-If you ran the profiler with the \f[I]coverage\f[] option, you can
-process the collected coverage data into an XML file by running
-mprof-report like this:
-.PP
-\f[B]mprof-report --coverage-out=coverage.xml output.mlpd\f[]
 .SS Dealing with profiler slowness
 .PP
 If the profiler needs to collect lots of data, the execution of the
index ed44567b40d019b14b7198a20c623f98a82449b1..dbb28b32af08f4e9ea0ff21471e1cf8f948c8499 100644 (file)
@@ -45,6 +45,8 @@ namespace MonoTests.Mono.Data.Tds
     public void CheckNullException() 
     {
 
+    TcpListener Listener = null;
+
        //set up dummy sql listener, if there is a real sql server on this
        //machine at that port, in theory this part will fail, but that's ok
        //becuase something will be listening on the port and that's all we
@@ -53,7 +55,7 @@ namespace MonoTests.Mono.Data.Tds
        try{
                IPAddress hostIP =Dns.GetHostEntry("localhost").AddressList[0];
         IPEndPoint ep = new IPEndPoint(hostIP, 1433);
-        TcpListener Listener = new TcpListener (ep);
+        Listener = new TcpListener (ep);
         Listener.Start ();
        } catch (Exception){
                //ignore
index 0b01eb19ad40fc1592cd78c2ed3aa74f6a1c6a7e..7d39fd4c43ffad92bcf2f284a542482b63f0c4eb 100644 (file)
@@ -309,6 +309,9 @@ namespace Mono.Unix {
 
                public static IntPtr StringToHeap (string s, Encoding encoding)
                {
+                       if (s == null)
+                               return IntPtr.Zero;
+
                        return StringToHeap (s, 0, s.Length, encoding);
                }
 
index 8ae50b98c977fa9af5531e7dbae9227c8d8586cd..9b0ce35d9614123b25bf97468dbdb3a68be03bfd 100644 (file)
@@ -40,6 +40,13 @@ namespace MonoTests.Mono.Unix {
                }
 #endif
 
+               [Test]
+               public void BXC10074 ()
+               {
+                       var result = UnixMarshal.StringToHeap (null, Encoding.ASCII);
+                       Assert.AreEqual (IntPtr.Zero, result, "This used to crash due to a NullReferenceException");
+               }
+
                [Test]
                public void TestStringToHeap ()
                {
index 9772f224ff6cb7c1a9a2915906f3c8ff944e04cc..a204195730d0b763517044c5dd6afeb04029d9c0 100644 (file)
@@ -173,6 +173,15 @@ namespace Mono.Profiler.Log {
                PreStartWorld = 8,
                PostStartWorld = 9,
                PostStartWorldUnlocked = 11,
+               // Following are v13 and older only
+               [Obsolete ("This event is no longer produced.")]
+               MarkBegin = 1,
+               [Obsolete ("This event is no longer produced.")]
+               MarkEnd = 2,
+               [Obsolete ("This event is no longer produced.")]
+               ReclaimBegin = 3,
+               [Obsolete ("This event is no longer produced.")]
+               ReclaimEnd = 4
        }
 
        // mono/metadata/mono-gc.h : MonoGCHandleType
index 7e8111b6c29cd941988d7aa6d2cf24bc9bea11d7..d40897c3a7e60a8e1a8307a09b6f90b4755b68b9 100644 (file)
@@ -12,7 +12,7 @@ namespace Mono.Profiler.Log {
 
        public sealed class LogProcessor {
 
-               public LogReader Reader { get; }
+               public LogStream Stream { get; }
 
                public LogEventVisitor ImmediateVisitor { get; }
 
@@ -20,18 +20,20 @@ namespace Mono.Profiler.Log {
 
                public LogStreamHeader StreamHeader { get; private set; }
 
+               LogReader _reader;
+
                LogBufferHeader _bufferHeader;
 
                ulong _time;
 
                bool _used;
 
-               public LogProcessor (LogReader reader, LogEventVisitor immediateVisitor, LogEventVisitor sortedVisitor)
+               public LogProcessor (LogStream stream, LogEventVisitor immediateVisitor, LogEventVisitor sortedVisitor)
                {
-                       if (reader == null)
-                               throw new ArgumentNullException (nameof (reader));
+                       if (stream == null)
+                               throw new ArgumentNullException (nameof (stream));
 
-                       Reader = reader;
+                       Stream = stream;
                        ImmediateVisitor = immediateVisitor;
                        SortedVisitor = sortedVisitor;
                }
@@ -66,29 +68,44 @@ namespace Mono.Profiler.Log {
                                throw new InvalidOperationException ("This log processor cannot be reused.");
 
                        _used = true;
-                       StreamHeader = new LogStreamHeader (Reader);
+                       _reader = new LogReader (Stream, true);
+
+                       StreamHeader = new LogStreamHeader (_reader);
 
                        var events = new List<LogEvent> (Environment.ProcessorCount * 1000);
 
-                       while (!Reader.BaseStream.EndOfStream) {
+                       while (!Stream.EndOfStream) {
                                token.ThrowIfCancellationRequested ();
 
-                               _bufferHeader = new LogBufferHeader (StreamHeader, Reader);
+                               _bufferHeader = new LogBufferHeader (StreamHeader, _reader);
+
+                               // Read the entire buffer into a MemoryStream ahead of time to
+                               // reduce the amount of I/O system calls we do. This should be
+                               // fine since the profiler tries to keep buffers small and
+                               // flushes them every second at minimum. This also has the
+                               // advantage that we can use the Position and Length properties
+                               // even if the stream we read the buffer from is actually
+                               // non-seekable.
+                               var stream = new MemoryStream (_reader.ReadBytes (_bufferHeader.Length), false);
+
+                               using (var reader = new LogReader (stream, false)) {
+                                       var oldReader = _reader;
 
-                               // Use the manual position tracking in LogReader so we're
-                               // compatible with non-seekable streams.
-                               var goal = Reader.Position + _bufferHeader.Length;
+                                       _reader = reader;
 
-                               while (Reader.Position < goal) {
-                                       token.ThrowIfCancellationRequested ();
+                                       while (stream.Position < stream.Length) {
+                                               token.ThrowIfCancellationRequested ();
 
-                                       var ev = ReadEvent ();
+                                               var ev = ReadEvent ();
 
-                                       ProcessEvent (ImmediateVisitor, ev);
-                                       events.Add (ev);
+                                               ProcessEvent (ImmediateVisitor, ev);
+                                               events.Add (ev);
 
-                                       if (ev is SynchronizationPointEvent)
-                                               ProcessEvents (events, token);
+                                               if (ev is SynchronizationPointEvent)
+                                                       ProcessEvents (events, token);
+                                       }
+
+                                       _reader = oldReader;
                                }
                        }
 
@@ -97,7 +114,7 @@ namespace Mono.Profiler.Log {
 
                LogEvent ReadEvent ()
                {
-                       var type = Reader.ReadByte ();
+                       var type = _reader.ReadByte ();
                        var basicType = (LogEventType) (type & 0xf);
                        var extType = (LogEventType) (type & 0xf0);
 
@@ -112,7 +129,7 @@ namespace Mono.Profiler.Log {
                                        ev = new AllocationEvent {
                                                ClassPointer = ReadPointer (),
                                                ObjectPointer = ReadObject (),
-                                               ObjectSize = (long) Reader.ReadULeb128 (),
+                                               ObjectSize = (long) _reader.ReadULeb128 (),
                                                Backtrace = ReadBacktrace (extType == LogEventType.AllocationBacktrace),
                                        };
                                        break;
@@ -124,17 +141,17 @@ namespace Mono.Profiler.Log {
                                switch (extType) {
                                case LogEventType.GCEvent:
                                        ev = new GCEvent {
-                                               Type = (LogGCEvent) Reader.ReadByte (),
-                                               Generation = Reader.ReadByte (),
+                                               Type = (LogGCEvent) _reader.ReadByte (),
+                                               Generation = _reader.ReadByte (),
                                        };
                                        break;
                                case LogEventType.GCResize:
                                        ev = new GCResizeEvent {
-                                               NewSize = (long) Reader.ReadULeb128 (),
+                                               NewSize = (long) _reader.ReadULeb128 (),
                                        };
                                        break;
                                case LogEventType.GCMove: {
-                                       var list = new long [(int) Reader.ReadULeb128 ()];
+                                       var list = new long [(int) _reader.ReadULeb128 ()];
 
                                        for (var i = 0; i < list.Length; i++)
                                                list [i] = ReadObject ();
@@ -148,8 +165,8 @@ namespace Mono.Profiler.Log {
                                case LogEventType.GCHandleCreationNoBacktrace:
                                case LogEventType.GCHandleCreationBacktrace:
                                        ev = new GCHandleCreationEvent {
-                                               Type = (LogGCHandleType) Reader.ReadULeb128 (),
-                                               Handle = (long) Reader.ReadULeb128 (),
+                                               Type = (LogGCHandleType) _reader.ReadULeb128 (),
+                                               Handle = (long) _reader.ReadULeb128 (),
                                                ObjectPointer = ReadObject (),
                                                Backtrace = ReadBacktrace (extType == LogEventType.GCHandleCreationBacktrace),
                                        };
@@ -157,8 +174,8 @@ namespace Mono.Profiler.Log {
                                case LogEventType.GCHandleDeletionNoBacktrace:
                                case LogEventType.GCHandleDeletionBacktrace:
                                        ev = new GCHandleDeletionEvent {
-                                               Type = (LogGCHandleType) Reader.ReadULeb128 (),
-                                               Handle = (long) Reader.ReadULeb128 (),
+                                               Type = (LogGCHandleType) _reader.ReadULeb128 (),
+                                               Handle = (long) _reader.ReadULeb128 (),
                                                Backtrace = ReadBacktrace (extType == LogEventType.GCHandleDeletionBacktrace),
                                        };
                                        break;
@@ -199,7 +216,7 @@ namespace Mono.Profiler.Log {
                                        throw new LogException ($"Invalid extended event type ({extType}).");
                                }
 
-                               var metadataType = (LogMetadataType) Reader.ReadByte ();
+                               var metadataType = (LogMetadataType) _reader.ReadByte ();
 
                                switch (metadataType) {
                                case LogMetadataType.Class:
@@ -207,7 +224,7 @@ namespace Mono.Profiler.Log {
                                                ev = new ClassLoadEvent {
                                                        ClassPointer = ReadPointer (),
                                                        ImagePointer = ReadPointer (),
-                                                       Name = Reader.ReadCString (),
+                                                       Name = _reader.ReadCString (),
                                                };
                                        } else
                                                throw new LogException ("Invalid class metadata event.");
@@ -216,12 +233,12 @@ namespace Mono.Profiler.Log {
                                        if (load) {
                                                ev = new ImageLoadEvent {
                                                        ImagePointer = ReadPointer (),
-                                                       Name = Reader.ReadCString (),
+                                                       Name = _reader.ReadCString (),
                                                };
                                        } else if (unload) {
                                                ev = new ImageUnloadEvent {
                                                        ImagePointer = ReadPointer (),
-                                                       Name = Reader.ReadCString (),
+                                                       Name = _reader.ReadCString (),
                                                };
                                        } else
                                                throw new LogException ("Invalid image metadata event.");
@@ -230,14 +247,14 @@ namespace Mono.Profiler.Log {
                                        if (load) {
                                                ev = new AssemblyLoadEvent {
                                                        AssemblyPointer = ReadPointer (),
-                                                       ImagePointer = ReadPointer (),
-                                                       Name = Reader.ReadCString (),
+                                                       ImagePointer = StreamHeader.FormatVersion >= 14 ? ReadPointer () : 0,
+                                                       Name = _reader.ReadCString (),
                                                };
                                        } else if (unload) {
                                                ev = new AssemblyUnloadEvent {
                                                        AssemblyPointer = ReadPointer (),
-                                                       ImagePointer = ReadPointer (),
-                                                       Name = Reader.ReadCString (),
+                                                       ImagePointer = StreamHeader.FormatVersion >= 14 ? ReadPointer () : 0,
+                                                       Name = _reader.ReadCString (),
                                                };
                                        } else
                                                throw new LogException ("Invalid assembly metadata event.");
@@ -254,7 +271,7 @@ namespace Mono.Profiler.Log {
                                        } else {
                                                ev = new AppDomainNameEvent {
                                                        AppDomainId = ReadPointer (),
-                                                       Name = Reader.ReadCString (),
+                                                       Name = _reader.ReadCString (),
                                                };
                                        }
                                        break;
@@ -270,7 +287,7 @@ namespace Mono.Profiler.Log {
                                        } else {
                                                ev = new ThreadNameEvent {
                                                        ThreadId = ReadPointer (),
-                                                       Name = Reader.ReadCString (),
+                                                       Name = _reader.ReadCString (),
                                                };
                                        }
                                        break;
@@ -314,8 +331,8 @@ namespace Mono.Profiler.Log {
                                        ev = new JitEvent {
                                                MethodPointer = ReadMethod (),
                                                CodePointer = ReadPointer (),
-                                               CodeSize = (long) Reader.ReadULeb128 (),
-                                               Name = Reader.ReadCString (),
+                                               CodeSize = (long) _reader.ReadULeb128 (),
+                                               Name = _reader.ReadCString (),
                                        };
                                        break;
                                default:
@@ -333,10 +350,10 @@ namespace Mono.Profiler.Log {
                                        break;
                                case LogEventType.ExceptionClause:
                                        ev = new ExceptionClauseEvent {
-                                               Type = (LogExceptionClause) Reader.ReadByte (),
-                                               Index = (long) Reader.ReadULeb128 (),
+                                               Type = (LogExceptionClause) _reader.ReadByte (),
+                                               Index = (long) _reader.ReadULeb128 (),
                                                MethodPointer = ReadMethod (),
-                                               ObjectPointer = ReadObject (),
+                                               ObjectPointer = StreamHeader.FormatVersion >= 14 ? ReadObject () : 0,
                                        };
                                        break;
                                default:
@@ -344,11 +361,20 @@ namespace Mono.Profiler.Log {
                                }
                                break;
                        case LogEventType.Monitor:
+                               if (StreamHeader.FormatVersion < 14) {
+                                       if (extType.HasFlag (LogEventType.MonitorBacktrace)) {
+                                               extType = LogEventType.MonitorBacktrace;
+                                       } else {
+                                               extType = LogEventType.MonitorNoBacktrace;
+                                       }
+                               }
                                switch (extType) {
                                case LogEventType.MonitorNoBacktrace:
                                case LogEventType.MonitorBacktrace:
                                        ev = new MonitorEvent {
-                                               Event = (LogMonitorEvent) Reader.ReadByte (),
+                                               Event = StreamHeader.FormatVersion >= 14 ?
+                                                                   (LogMonitorEvent) _reader.ReadByte () :
+                                                                   (LogMonitorEvent) ((((byte) type & 0xf0) >> 4) & 0x3),
                                                ObjectPointer = ReadObject (),
                                                Backtrace = ReadBacktrace (extType == LogEventType.MonitorBacktrace),
                                        };
@@ -369,14 +395,14 @@ namespace Mono.Profiler.Log {
                                        HeapObjectEvent hoe = new HeapObjectEvent {
                                                ObjectPointer = ReadObject (),
                                                ClassPointer = ReadPointer (),
-                                               ObjectSize = (long) Reader.ReadULeb128 (),
+                                               ObjectSize = (long) _reader.ReadULeb128 (),
                                        };
 
-                                       var list = new HeapObjectEvent.HeapObjectReference [(int) Reader.ReadULeb128 ()];
+                                       var list = new HeapObjectEvent.HeapObjectReference [(int) _reader.ReadULeb128 ()];
 
                                        for (var i = 0; i < list.Length; i++) {
                                                list [i] = new HeapObjectEvent.HeapObjectReference {
-                                                       Offset = (long) Reader.ReadULeb128 (),
+                                                       Offset = (long) _reader.ReadULeb128 (),
                                                        ObjectPointer = ReadObject (),
                                                };
                                        }
@@ -390,15 +416,15 @@ namespace Mono.Profiler.Log {
                                case LogEventType.HeapRoots: {
                                        // TODO: This entire event makes no sense.
                                        var hre = new HeapRootsEvent ();
-                                       var list = new HeapRootsEvent.HeapRoot [(int) Reader.ReadULeb128 ()];
+                                       var list = new HeapRootsEvent.HeapRoot [(int) _reader.ReadULeb128 ()];
 
-                                       hre.MaxGenerationCollectionCount = (long) Reader.ReadULeb128 ();
+                                       hre.MaxGenerationCollectionCount = (long) _reader.ReadULeb128 ();
 
                                        for (var i = 0; i < list.Length; i++) {
                                                list [i] = new HeapRootsEvent.HeapRoot {
                                                        ObjectPointer = ReadObject (),
-                                                       Attributes = (LogHeapRootAttributes) Reader.ReadByte (),
-                                                       ExtraInfo = (long) Reader.ReadULeb128 (),
+                                                       Attributes = StreamHeader.FormatVersion == 13 ? (LogHeapRootAttributes) _reader.ReadByte () : (LogHeapRootAttributes) _reader.ReadULeb128 (),
+                                                       ExtraInfo = (long) _reader.ReadULeb128 (),
                                                };
                                        }
 
@@ -414,42 +440,46 @@ namespace Mono.Profiler.Log {
                        case LogEventType.Sample:
                                switch (extType) {
                                case LogEventType.SampleHit:
+                                       if (StreamHeader.FormatVersion < 14) {
+                                               // Read SampleType (always set to .Cycles) for versions < 14
+                                               _reader.ReadByte ();
+                                       }
                                        ev = new SampleHitEvent {
                                                ThreadId = ReadPointer (),
                                                UnmanagedBacktrace = ReadBacktrace (true, false),
-                                               ManagedBacktrace = ReadBacktrace (true),
+                                               ManagedBacktrace = ReadBacktrace (true).Reverse ().ToArray (),
                                        };
                                        break;
                                case LogEventType.SampleUnmanagedSymbol:
                                        ev = new UnmanagedSymbolEvent {
                                                CodePointer = ReadPointer (),
-                                               CodeSize = (long) Reader.ReadULeb128 (),
-                                               Name = Reader.ReadCString (),
+                                               CodeSize = (long) _reader.ReadULeb128 (),
+                                               Name = _reader.ReadCString (),
                                        };
                                        break;
                                case LogEventType.SampleUnmanagedBinary:
                                        ev = new UnmanagedBinaryEvent {
-                                               SegmentPointer = ReadPointer (),
-                                               SegmentOffset = (long) Reader.ReadULeb128 (),
-                                               SegmentSize = (long) Reader.ReadULeb128 (),
-                                               FileName = Reader.ReadCString (),
+                                               SegmentPointer = StreamHeader.FormatVersion >= 14 ? ReadPointer () : _reader.ReadSLeb128 (),
+                                               SegmentOffset = (long) _reader.ReadULeb128 (),
+                                               SegmentSize = (long) _reader.ReadULeb128 (),
+                                               FileName = _reader.ReadCString (),
                                        };
                                        break;
                                case LogEventType.SampleCounterDescriptions: {
                                        var cde = new CounterDescriptionsEvent ();
-                                       var list = new CounterDescriptionsEvent.CounterDescription [(int) Reader.ReadULeb128 ()];
+                                       var list = new CounterDescriptionsEvent.CounterDescription [(int) _reader.ReadULeb128 ()];
 
                                        for (var i = 0; i < list.Length; i++) {
-                                               var section = (LogCounterSection) Reader.ReadULeb128 ();
+                                               var section = (LogCounterSection) _reader.ReadULeb128 ();
 
                                                list [i] = new CounterDescriptionsEvent.CounterDescription {
                                                        Section = section,
-                                                       SectionName = section == LogCounterSection.User ? Reader.ReadCString () : string.Empty,
-                                                       CounterName = Reader.ReadCString (),
-                                                       Type = (LogCounterType) Reader.ReadByte (),
-                                                       Unit = (LogCounterUnit) Reader.ReadByte (),
-                                                       Variance = (LogCounterVariance) Reader.ReadByte (),
-                                                       Index = (long) Reader.ReadULeb128 (),
+                                                       SectionName = section == LogCounterSection.User ? _reader.ReadCString () : null,
+                                                       CounterName = _reader.ReadCString (),
+                                                       Type = (LogCounterType) _reader.ReadByte (),
+                                                       Unit = (LogCounterUnit) _reader.ReadByte (),
+                                                       Variance = (LogCounterVariance) _reader.ReadByte (),
+                                                       Index = (long) _reader.ReadULeb128 (),
                                                };
                                        }
 
@@ -463,31 +493,31 @@ namespace Mono.Profiler.Log {
                                        var list = new List<CounterSamplesEvent.CounterSample> ();
 
                                        while (true) {
-                                               var index = (long) Reader.ReadULeb128 ();
+                                               var index = (long) _reader.ReadULeb128 ();
 
                                                if (index == 0)
                                                        break;
 
-                                               var counterType = (LogCounterType) Reader.ReadByte ();
+                                               var counterType = (LogCounterType) _reader.ReadByte ();
 
                                                object value = null;
 
                                                switch (counterType) {
                                                case LogCounterType.String:
-                                                       value = Reader.ReadByte () == 1 ? Reader.ReadCString () : null;
+                                                       value = _reader.ReadByte () == 1 ? _reader.ReadCString () : null;
                                                        break;
                                                case LogCounterType.Int32:
                                                case LogCounterType.Word:
                                                case LogCounterType.Int64:
                                                case LogCounterType.Interval:
-                                                       value = Reader.ReadSLeb128 ();
+                                                       value = _reader.ReadSLeb128 ();
                                                        break;
                                                case LogCounterType.UInt32:
                                                case LogCounterType.UInt64:
-                                                       value = Reader.ReadULeb128 ();
+                                                       value = _reader.ReadULeb128 ();
                                                        break;
                                                case LogCounterType.Double:
-                                                       value = Reader.ReadDouble ();
+                                                       value = _reader.ReadDouble ();
                                                        break;
                                                default:
                                                        throw new LogException ($"Invalid counter type ({counterType}).");
@@ -512,13 +542,13 @@ namespace Mono.Profiler.Log {
                        case LogEventType.Runtime:
                                switch (extType) {
                                case LogEventType.RuntimeJitHelper: {
-                                       var helperType = (LogJitHelper) Reader.ReadByte ();
+                                       var helperType = (LogJitHelper) _reader.ReadByte ();
 
                                        ev = new JitHelperEvent {
                                                Type = helperType,
                                                BufferPointer = ReadPointer (),
-                                               BufferSize = (long) Reader.ReadULeb128 (),
-                                               Name = helperType == LogJitHelper.SpecificTrampoline ? Reader.ReadCString () : string.Empty,
+                                               BufferSize = (long) _reader.ReadULeb128 (),
+                                               Name = helperType == LogJitHelper.SpecificTrampoline ? _reader.ReadCString () : null,
                                        };
                                        break;
                                }
@@ -530,7 +560,7 @@ namespace Mono.Profiler.Log {
                                switch (extType) {
                                case LogEventType.MetaSynchronizationPoint:
                                        ev = new SynchronizationPointEvent {
-                                               Type = (LogSynchronizationPoint) Reader.ReadByte (),
+                                               Type = (LogSynchronizationPoint) _reader.ReadByte (),
                                        };
                                        break;
                                default:
@@ -549,24 +579,24 @@ namespace Mono.Profiler.Log {
 
                long ReadPointer ()
                {
-                       var ptr = Reader.ReadSLeb128 () + _bufferHeader.PointerBase;
+                       var ptr = _reader.ReadSLeb128 () + _bufferHeader.PointerBase;
 
                        return StreamHeader.PointerSize == sizeof (long) ? ptr : ptr & 0xffffffffL;
                }
 
                long ReadObject ()
                {
-                       return Reader.ReadSLeb128 () + _bufferHeader.ObjectBase << 3;
+                       return _reader.ReadSLeb128 () + _bufferHeader.ObjectBase << 3;
                }
 
                long ReadMethod ()
                {
-                       return _bufferHeader.CurrentMethod += Reader.ReadSLeb128 ();
+                       return _bufferHeader.CurrentMethod += _reader.ReadSLeb128 ();
                }
 
                ulong ReadTime ()
                {
-                       return _bufferHeader.CurrentTime += Reader.ReadULeb128 ();
+                       return _bufferHeader.CurrentTime += _reader.ReadULeb128 ();
                }
 
                IReadOnlyList<long> ReadBacktrace (bool actuallyRead, bool managed = true)
@@ -574,7 +604,7 @@ namespace Mono.Profiler.Log {
                        if (!actuallyRead)
                                return Array.Empty<long> ();
 
-                       var list = new long [(int) Reader.ReadULeb128 ()];
+                       var list = new long [(int) _reader.ReadULeb128 ()];
 
                        for (var i = 0; i < list.Length; i++)
                                list [i] = managed ? ReadMethod () : ReadPointer ();
index 4b241ba155d11db44c5850a67b56d7438057bf09..a58211a1510642ca2a0d8eaa9eabc507598f490b 100644 (file)
@@ -3,27 +3,22 @@
 // See the LICENSE file in the project root for more information.
 
 using System;
-using System.Collections.Generic;
 using System.IO;
 using System.Text;
 
 namespace Mono.Profiler.Log {
 
-       public sealed class LogReader : IDisposable {
+       sealed class LogReader : IDisposable {
 
-               public static Encoding Encoding { get; } = Encoding.UTF8;
-
-               public LogStream BaseStream => (LogStream) _reader.BaseStream;
-
-               public long Position { get; private set; }
+               static readonly Encoding _encoding = Encoding.UTF8;
 
                readonly BinaryReader _reader;
 
                byte[] _stringBuffer = new byte [1024];
 
-               public LogReader (LogStream stream, bool leaveOpen)
+               public LogReader (Stream stream, bool leaveOpen)
                {
-                       _reader = new BinaryReader (stream, Encoding, leaveOpen);
+                       _reader = new BinaryReader (stream, _encoding, leaveOpen);
                }
 
                public void Dispose ()
@@ -31,73 +26,54 @@ namespace Mono.Profiler.Log {
                        _reader.Dispose ();
                }
 
-               internal byte ReadByte ()
+               public byte[] ReadBytes (int count)
                {
-                       var b = _reader.ReadByte ();
+                       var bytes = new byte [count];
 
-                       Position += sizeof (byte);
+                       // BinaryReader.ReadBytes doesn't necessarily read the specified
+                       // amount of bytes, so just do it this way.
+                       for (var i = 0; i < bytes.Length; i++)
+                               bytes [i] = ReadByte ();
 
-                       return b;
+                       return bytes;
                }
 
-               internal ushort ReadUInt16 ()
+               public byte ReadByte ()
                {
-                       var i = _reader.ReadUInt16 ();
-
-                       Position += sizeof (ushort);
-
-                       return i;
+                       return _reader.ReadByte ();
                }
 
-               internal int ReadInt32 ()
+               public ushort ReadUInt16 ()
                {
-                       var i = _reader.ReadInt32 ();
-
-                       Position += sizeof (int);
-
-                       return i;
+                       return _reader.ReadUInt16 ();
                }
 
-               internal long ReadInt64 ()
+               public int ReadInt32 ()
                {
-                       var i = _reader.ReadInt64 ();
-
-                       Position += sizeof (long);
-
-                       return i;
+                       return _reader.ReadInt32 ();
                }
 
-               internal ulong ReadUInt64 ()
+               public long ReadInt64 ()
                {
-                       var i = _reader.ReadUInt64 ();
-
-                       Position += sizeof (ulong);
-
-                       return i;
+                       return _reader.ReadInt64 ();
                }
 
-               internal double ReadDouble ()
+               public ulong ReadUInt64 ()
                {
-                       var d = _reader.ReadDouble ();
-
-                       Position += sizeof (double);
-
-                       return d;
+                       return _reader.ReadUInt64 ();
                }
 
-               internal string ReadHeaderString ()
+               public double ReadDouble ()
                {
-                       var bytes = new byte [ReadInt32 ()];
-
-                       // ReadBytes doesn't necessarily read the specified amount of
-                       // bytes, so just do it this way.
-                       for (var i = 0; i < bytes.Length; i++)
-                               bytes [i] = ReadByte ();
+                       return _reader.ReadDouble ();
+               }
 
-                       return Encoding.GetString (bytes);
+               public string ReadHeaderString ()
+               {
+                       return _encoding.GetString (ReadBytes (ReadInt32 ()));
                }
 
-               internal string ReadCString ()
+               public string ReadCString ()
                {
                        var pos = 0;
 
@@ -110,10 +86,10 @@ namespace Mono.Profiler.Log {
                                _stringBuffer [pos++] = val;
                        }
 
-                       return Encoding.GetString (_stringBuffer, 0, pos);
+                       return _encoding.GetString (_stringBuffer, 0, pos);
                }
 
-               internal long ReadSLeb128 ()
+               public long ReadSLeb128 ()
                {
                        long result = 0;
                        var shift = 0;
@@ -135,7 +111,7 @@ namespace Mono.Profiler.Log {
                        return result;
                }
 
-               internal ulong ReadULeb128 ()
+               public ulong ReadULeb128 ()
                {
                        ulong result = 0;
                        var shift = 0;
index 4fd0daf227d415e4cdfd69fa2f5e6a910a31a95b..b52402a91d43e23a359acfadb0fb14a61d7ffae2 100644 (file)
@@ -26,6 +26,8 @@ namespace Mono.Profiler.Log {
                        set => throw new NotSupportedException ();
                }
 
+               readonly byte[] _byteBuffer = new byte [1];
+
                public LogStream (Stream baseStream)
                {
                        if (baseStream == null)
@@ -48,6 +50,14 @@ namespace Mono.Profiler.Log {
                        throw new NotSupportedException ();
                }
 
+               public override int ReadByte ()
+               {
+                       // The base method on Stream is extremely inefficient in that it
+                       // allocates a 1-byte array for every call. Simply use a private
+                       // buffer instead.
+                       return Read (_byteBuffer, 0, sizeof (byte)) == 0 ? -1 : _byteBuffer [0];
+               }
+
                public override int Read (byte[] buffer, int offset, int count)
                {
                        return BaseStream.Read (buffer, offset, count);
index b8eb4413fd7884dfbd6409a8a5d38def590d5bcb..44575028a7a38613d59d698f2c282e06d4ff6100 100644 (file)
@@ -7,6 +7,9 @@ using System;
 namespace Mono.Profiler.Log {
 
        public sealed class LogStreamHeader {
+               
+               const int MinVersion = 13;
+               const int MaxVersion = 14;
 
                const int Id = 0x4d505a01;
 
@@ -41,6 +44,10 @@ namespace Mono.Profiler.Log {
 
                        Version = new Version (reader.ReadByte (), reader.ReadByte ());
                        FormatVersion = reader.ReadByte ();
+
+                       if (FormatVersion < MinVersion || FormatVersion > MaxVersion)
+                               throw new LogException ($"Unsupported MLPD version {FormatVersion}. Should be >= {MinVersion} and <= {MaxVersion}.");
+                       
                        PointerSize = reader.ReadByte ();
                        StartupTime = reader.ReadUInt64 ();
                        TimerOverhead = reader.ReadInt32 ();
index 0b64495fc5f209631711c8c91187269d3bc4c29e..131ebab00e64944cb787202945540d24243dec24 100644 (file)
@@ -71,8 +71,6 @@ namespace Mono.Security.Interface
 
                Task AuthenticateAsServerAsync (X509Certificate serverCertificate, bool clientCertificateRequired, SSA.SslProtocols enabledSslProtocols, bool checkCertificateRevocation);
 
-               void Flush ();
-
                int Read (byte[] buffer, int offset, int count);
 
                void Write (byte[] buffer);
index 1ed77bbebdf94332edfa5155c83650c9027f5f46..977d433fc6c846cda90b8daf939fc46c08b9034d 100644 (file)
@@ -167,6 +167,21 @@ namespace Mono.Security.Interface
                }
 
                #endregion
+
+               #region Internal Version
+
+               /*
+                * Internal version number (not in any way related to the TLS Version).
+                *
+                * Used by the web-tests to check whether
+                * the current Mono contains certain features or bug fixes.
+                *
+                * Negative version numbers are reserved for martin work branches.
+                *
+                */
+               internal const int InternalVersion = 1;
+
+               #endregion
        }
 }
 
index 25d474679f9508a1f1766d09ed4aa9de96fa4fb7..4dc2f64f9d2f527f91944065facbeb97f970a8eb 100644 (file)
@@ -13,7 +13,7 @@ LIB_REFS += System.Web
 endif
 
 TEST_MCS_FLAGS = -nowarn:618
-TEST_LIB_REFS = System System.Xml
+TEST_LIB_REFS = System System.Xml System.Core
 
 TEST_MONO_PATH = .
 
index 575c0fe753e93b495544fca17d481f0b17195325..b4e90d4c43af79171e8c4bd7e3295d42dfc00c6f 100644 (file)
@@ -118,7 +118,7 @@ namespace System.Windows.Forms.Layout
 \r
                        XmlDocument xmldoc = new XmlDocument();\r
                        xmldoc.LoadXml (value as string);\r
-                       TableLayoutSettings settings = new TableLayoutSettings(new TableLayoutPanel());\r
+                       TableLayoutSettings settings = new TableLayoutSettings(null);
                        int count = ParseControl (xmldoc, settings);\r
                        ParseColumnStyle (xmldoc, settings);\r
                        ParseRowStyle (xmldoc, settings);\r
index 090ba92ecf7adafc75b7a0bed0ff14e87293dda3..df0558da9331360d69c3d81fbb4916ecba6a796d 100644 (file)
@@ -38,9 +38,6 @@ namespace System.Windows.Forms {
                
                internal TableLayoutStyleCollection (TableLayoutPanel table)
                {
-                       if (table == null)
-                               throw new ArgumentNullException("table");
-                       
                        this.table = table;
                }
                
@@ -54,7 +51,8 @@ namespace System.Windows.Forms {
                        foreach (TableLayoutStyle style in al)
                                style.Owner = null;
                        al.Clear ();
-                       table.PerformLayout ();
+                       if (table != null)
+                               table.PerformLayout ();
                }
                
                public int Count {
@@ -65,7 +63,8 @@ namespace System.Windows.Forms {
                {
                        ((TableLayoutStyle)al[index]).Owner = null;
                        al.RemoveAt (index);
-                       table.PerformLayout ();
+                       if (table != null)
+                               table.PerformLayout ();
                }
                
 #region IList methods
@@ -103,14 +102,16 @@ namespace System.Windows.Forms {
                                throw new ArgumentException ("Style is already owned");
                        ((TableLayoutStyle)style).Owner = table;
                        al.Insert (index, (TableLayoutStyle) style);
-                       table.PerformLayout ();
+                       if (table != null)
+                               table.PerformLayout ();
                }
 
                void IList.Remove (object style)
                {
                        ((TableLayoutStyle)style).Owner = null;
                        al.Remove ((TableLayoutStyle) style);
-                       table.PerformLayout ();
+                       if (table != null)
+                               table.PerformLayout ();
                }
 
                bool IList.IsFixedSize {
@@ -134,7 +135,8 @@ namespace System.Windows.Forms {
                                        throw new ArgumentException ("Style is already owned");
                                ((TableLayoutStyle)value).Owner = table;
                                al [index] = value;
-                               table.PerformLayout ();
+                               if (table != null)
+                                       table.PerformLayout ();
                        }
                }
 #endregion
index 95ecb8fd64a2d1e8a4a59296eba02dd660a86bea..ee3aa44c49e66e731c5b7e5d00f6e7c68f1dc3d3 100644 (file)
@@ -707,7 +707,7 @@ namespace Mono.Net.Security
 
                public override void Flush ()
                {
-                       // Write() automatically flushes the underlying stream.
+                       InnerStream.Flush ();
                }
 
                public SslProtocols SslProtocol {
index c0b702fde1b2f92798271fdf943402e1460eb27a..a536f3bb8224edc5cd599737bca41c05631efc3e 100644 (file)
@@ -293,15 +293,15 @@ namespace System.Net.Security
                }
 
                public override bool CanRead {
-                       get { return Impl.CanRead; }
+                       get { return impl != null && impl.CanRead; }
                }
 
                public override bool CanTimeout {
-                       get { return Impl.CanTimeout; }
+                       get { return InnerStream.CanTimeout; }
                }
 
                public override bool CanWrite {
-                       get { return Impl.CanWrite; }
+                       get { return impl != null && impl.CanWrite; }
                }
 
                public override int ReadTimeout {
@@ -337,7 +337,7 @@ namespace System.Net.Security
 
                public override void Flush ()
                {
-                       Impl.Flush ();
+                       InnerStream.Flush ();
                }
 
                void CheckDisposed ()
index a6681780275aaf59355fe2336cfd717b03fc97b9..acaa7b2852a9a32556a45e55886f5e1a426795c3 100644 (file)
@@ -23,7 +23,7 @@
 //     Chris Toshok (toshok@ximian.com)
 //
 
-using System;
+using System.Globalization;
 using System.Windows.Markup;
 
 namespace System.Windows.Converters {
@@ -32,22 +32,26 @@ namespace System.Windows.Converters {
        {
                public override bool CanConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return true;
                }
 
                public override bool CanConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return value is Int32Rect;
                }
 
                public override object ConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value == null)
+                               throw new NotSupportedException ("value != null");
+                       return Int32Rect.Parse (value);
                }
 
                public override string ConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value is Int32Rect int32Rect)
+                               return int32Rect.ToString (CultureInfo.InvariantCulture);
+                       return base.ConvertToString (value, context);
                }
        }
 
index 86f5ae77d167c799798c289b31dee975f34f8d13..150c2e8304cd8b2ca2a54e135f3a9fa05b1a77de 100644 (file)
@@ -23,7 +23,7 @@
 //     Chris Toshok (toshok@ximian.com)
 //
 
-using System;
+using System.Globalization;
 using System.Windows.Markup;
 
 namespace System.Windows.Converters {
@@ -32,22 +32,26 @@ namespace System.Windows.Converters {
        {
                public override bool CanConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return true;
                }
 
                public override bool CanConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return value is Point;
                }
 
                public override object ConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value == null)
+                               throw new NotSupportedException ("value != null");
+                       return Point.Parse (value);
                }
 
                public override string ConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value is Point point)
+                               return point.ToString (CultureInfo.InvariantCulture);
+                       return base.ConvertToString (value, context);
                }
        }
 
index 1a607763929e75cb8b38c589a91ea12f85a2c0bd..623c0d688bb1ad969dabf21ff18341ca01456f34 100644 (file)
@@ -22,8 +22,7 @@
 // Authors:
 //     Chris Toshok (toshok@ximian.com)
 //
-
-using System;
+using System.Globalization;
 using System.Windows.Markup;
 
 namespace System.Windows.Converters {
@@ -32,22 +31,26 @@ namespace System.Windows.Converters {
        {
                public override bool CanConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return true;
                }
 
                public override bool CanConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return value is Rect;
                }
 
                public override object ConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value == null)
+                               throw new NotSupportedException ("value != null");
+                       return Rect.Parse (value);
                }
 
                public override string ConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value is Rect rect)
+                               return rect.ToString (CultureInfo.InvariantCulture);
+                       return base.ConvertToString (value, context);
                }
        }
 
index 0a46f1d1e9710cbe798a64e28df4027daddc73a6..2765b7397f80ef7de361872ebad9acbc3ed2d87d 100644 (file)
@@ -45,7 +45,7 @@ namespace System.Windows.Converters {
                public override object ConvertFromString (string value, IValueSerializerContext context)
                {
                        if (value == null)
-                               throw new ArgumentNullException ("value");
+                               throw new NotSupportedException ("value != null");
                        return Size.Parse (value);
                }
 
index c9feb17a7d4cb556da962234341b70cf3a3f0074..6ec7ae6f5899c86be5ff97dd25a8c39516fb61fb 100644 (file)
@@ -23,7 +23,7 @@
 //     Chris Toshok (toshok@ximian.com)
 //
 
-using System;
+using System.Globalization;
 using System.Windows.Markup;
 
 namespace System.Windows.Converters {
@@ -32,22 +32,26 @@ namespace System.Windows.Converters {
        {
                public override bool CanConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return true;
                }
 
                public override bool CanConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       return value is Vector;
                }
 
                public override object ConvertFromString (string value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value == null)
+                               throw new NotSupportedException ("value != null");
+                       return Vector.Parse (value);
                }
 
                public override string ConvertToString (object value, IValueSerializerContext context)
                {
-                       throw new NotImplementedException ();
+                       if (value is Vector vector)
+                               return vector.ToString (CultureInfo.InvariantCulture);
+                       return base.ConvertToString (value, context);
                }
        }
 
index e9c60b528db3bbaa88eab8cad06d50165b7df2c8..49e0548887875bd81ec0f23cf7ac2ccfcc2aeb2c 100644 (file)
@@ -186,22 +186,24 @@ namespace System.Windows.Media {
                        }
                        else
                        {
-                               var parts = source.Split (',');
-                               if (parts.Length != 6)
-                                       throw new FormatException (string.Format ("Invalid Matrix format: {0}", source));
+                               var tokenizer = new NumericListTokenizer (source, CultureInfo.InvariantCulture);
                                double m11;
                                double m12;
                                double m21;
                                double m22;
                                double offsetX;
                                double offsetY;
-                               if (double.TryParse (parts[0], NumberStyles.Float, CultureInfo.InvariantCulture, out m11)
-                                   && double.TryParse (parts[1], NumberStyles.Float, CultureInfo.InvariantCulture, out m12)
-                                   && double.TryParse (parts[2], NumberStyles.Float, CultureInfo.InvariantCulture, out m21)
-                                   && double.TryParse (parts[3], NumberStyles.Float, CultureInfo.InvariantCulture, out m22)
-                                   && double.TryParse (parts[4], NumberStyles.Float, CultureInfo.InvariantCulture, out offsetX)
-                                   && double.TryParse (parts[5], NumberStyles.Float, CultureInfo.InvariantCulture, out offsetY))
+                               if (double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out m11)
+                                   && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out m12)
+                                   && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out m21)
+                                   && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out m22)
+                                   && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out offsetX)
+                                   && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out offsetY))
                                {
+                                       if (!tokenizer.HasNoMoreTokens ())
+                                       {
+                                               throw new InvalidOperationException ("Invalid Matrix format: " + source);
+                                       }
                                        value = new Matrix (m11, m12, m21, m22, offsetX, offsetY);
                                }
                                else
@@ -336,12 +338,6 @@ namespace System.Windows.Media {
                        Prepend (m);
                }
 
-               string IFormattable.ToString (string format,
-                                             IFormatProvider provider)
-               {
-                       return ToString (provider);
-               }
-
                public override string ToString ()
                {
                        return ToString (null);
@@ -349,9 +345,33 @@ namespace System.Windows.Media {
 
                public string ToString (IFormatProvider provider)
                {
-                       return IsIdentity
-                               ? "Identity"
-                               : string.Concat (_m11, ",", _m12, ",", _m21, ",", _m22, ",", _offsetX, ",", _offsetY);
+                       return ToString (null, provider);
+               }
+
+               string IFormattable.ToString (string format,
+                       IFormatProvider provider)
+               {
+                       return ToString (provider);
+               }
+
+               private string ToString (string format, IFormatProvider provider)
+               {
+                       if (IsIdentity)
+                               return "Identity";
+
+                       if (provider == null)
+                               provider = CultureInfo.CurrentCulture;
+
+                       if (format == null)
+                               format = string.Empty;
+
+                       var separator = NumericListTokenizer.GetSeparator (provider);
+
+                       var matrixFormat = string.Format (
+                               "{{0:{0}}}{1}{{1:{0}}}{1}{{2:{0}}}{1}{{3:{0}}}{1}{{4:{0}}}{1}{{5:{0}}}",
+                               format, separator);
+                       return string.Format (provider, matrixFormat,
+                               _m11, _m12, _m21, _m22, _offsetX, _offsetY);
                }
 
                public Point Transform (Point point)
index f2b464be1e5b68808a2d0b9f6168842dae539650..815fee0b1b20146ec6afbcfa9b764aa50df63f04 100644 (file)
@@ -26,8 +26,8 @@
 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 //
 
-using System;
 using System.ComponentModel;
+using System.Globalization;
 using System.Windows.Converters;
 using System.Windows.Markup;
 
@@ -109,29 +109,84 @@ namespace System.Windows {
 
                public override int GetHashCode ()
                {
-                       throw new NotImplementedException ();
+                       unchecked
+                       {
+                               var hashCode = _x;
+                               hashCode = (hashCode * 397) ^ _y;
+                               hashCode = (hashCode * 397) ^ _width;
+                               hashCode = (hashCode * 397) ^ _height;
+                               return hashCode;
+                       }
                }
 
                public static Int32Rect Parse (string source)
                {
-                       throw new NotImplementedException ();
+                       if (source == null)
+                               throw new ArgumentNullException ("source");
+                       Int32Rect value;
+                       if (source.Trim () == "Empty")
+                       {
+                               value = Empty;
+                       }
+                       else
+                       {
+                               var tokenizer = new NumericListTokenizer (source, CultureInfo.InvariantCulture);
+                               int x;
+                               int y;
+                               int width;
+                               int height;
+                               if (int.TryParse (tokenizer.GetNextToken (), NumberStyles.Integer, CultureInfo.InvariantCulture, out x)
+                                   && int.TryParse (tokenizer.GetNextToken (), NumberStyles.Integer, CultureInfo.InvariantCulture, out y)
+                                   && int.TryParse (tokenizer.GetNextToken (), NumberStyles.Integer, CultureInfo.InvariantCulture, out width)
+                                   && int.TryParse (tokenizer.GetNextToken (), NumberStyles.Integer, CultureInfo.InvariantCulture, out height))
+                               {
+                                       if (!tokenizer.HasNoMoreTokens ())
+                                       {
+                                               throw new InvalidOperationException ("Invalid Int32Rect format: " + source);
+                                       }
+                                       value = new Int32Rect (x, y, width, height);
+                               }
+                               else
+                               {
+                                       throw new FormatException (string.Format ("Invalid Int32Rect format: {0}", source));
+                               }
+                       }
+                       return value;
                }
 
                public override string ToString ()
                {
-                       if (IsEmpty)
-                               return "Empty";
-                       return String.Format ("{0},{1},{2},{3}", _x, _y, _width, _height);
+                       return ToString (null);
                }
 
                public string ToString (IFormatProvider provider)
                {
-                       throw new NotImplementedException ();
+                       return ToString (null, provider);
                }
 
                string IFormattable.ToString (string format, IFormatProvider provider)
                {
-                       throw new NotImplementedException ();
+                       return ToString (provider);
+               }
+
+               private string ToString (string format, IFormatProvider provider)
+               {
+                       if (IsEmpty)
+                               return "Empty";
+
+                       if (provider == null)
+                               provider = CultureInfo.CurrentCulture;
+
+                       if (format == null)
+                               format = string.Empty;
+
+                       var separator = NumericListTokenizer.GetSeparator (provider);
+
+                       var rectFormat = string.Format (
+                               "{{0:{0}}}{1}{{1:{0}}}{1}{{2:{0}}}{1}{{3:{0}}}",
+                               format, separator);
+                       return string.Format (provider, rectFormat,
+                               _x, _y, _width, _height);
                }
        }
 }
diff --git a/mcs/class/WindowsBase/System.Windows/NumericListTokenizer.cs b/mcs/class/WindowsBase/System.Windows/NumericListTokenizer.cs
new file mode 100644 (file)
index 0000000..81905ec
--- /dev/null
@@ -0,0 +1,102 @@
+using System.Globalization;
+
+namespace System.Windows
+{
+       /// <summary>
+       /// Helper class for parsing serialized data structures from the System.Windows namespace.
+       /// </summary>
+       internal class NumericListTokenizer
+       {
+               private readonly string _str;
+               private readonly char _separator;
+               private int _position;
+
+               private enum Symbol
+               {
+                       Token,
+                       Separator,
+                       Whitspace,
+                       EndOfLine
+               }
+
+               public NumericListTokenizer (string str, IFormatProvider formatProvider)
+               {
+                       _str = str ?? throw new ArgumentNullException (nameof(str));
+                       _separator = GetSeparator (formatProvider ?? throw new ArgumentNullException (nameof(formatProvider)));
+               }
+
+               public static char GetSeparator (IFormatProvider formatProvider)
+               {
+                       // By convention, string representations of target classes always use ';' as a separator
+                       // if the decimal number separator is ','. Otherwise, the separator is ','.
+                       return NumberFormatInfo.GetInstance (formatProvider).NumberDecimalSeparator != "," ? ',' : ';';
+               }
+
+               private Symbol GetCurrentSymbol ()
+               {
+                       if (_position >= _str.Length)
+                               return Symbol.EndOfLine;
+                       if (_str[_position] == _separator)
+                               return Symbol.Separator;
+                       if (char.IsWhiteSpace (_str, _position))
+                               return Symbol.Whitspace;
+                       return Symbol.Token;
+               }
+
+               private void SkipAllWhitespaces ()
+               {
+                       while (GetCurrentSymbol () == Symbol.Whitspace)
+                       {
+                               _position++;
+                       }
+               }
+
+               private void SkipNextDelimeter ()
+               {
+                       SkipAllWhitespaces ();
+                       switch (GetCurrentSymbol ())
+                       {
+                               case Symbol.Token:
+                                       return;
+                               case Symbol.Separator:
+                                       _position++;
+                                       SkipAllWhitespaces ();
+                                       return;
+                               default:
+                                       throw new InvalidOperationException ("Separator not found");
+                       }
+               }
+
+               public bool HasNoMoreTokens ()
+               {
+                       SkipAllWhitespaces ();
+                       return GetCurrentSymbol () == Symbol.EndOfLine;
+               }
+
+               public string GetNextToken ()
+               {
+                       var length = 0;
+                       if (_position == 0)
+                       {
+                               SkipAllWhitespaces ();
+                       }
+                       else
+                       {
+                               SkipNextDelimeter ();
+                       }
+
+                       while (GetCurrentSymbol () == Symbol.Token)
+                       {
+                               _position++;
+                               length++;
+                       }
+
+                       if (length == 0)
+                       {
+                               throw new InvalidOperationException ("Next token not found");
+                       }
+
+                       return _str.Substring (_position - length, length);
+               }
+       }
+}
\ No newline at end of file
index 206b0edd3ab7302b161d03cd78e98c01758da003..af57f92829d43bcffa045a95f4e6dafa3eaff50e 100644 (file)
@@ -147,15 +147,21 @@ namespace System.Windows {
 
                public static Point Parse (string source)
                {
-                       string[] points = source.Split(',');
-
-                       if (points.Length<2)
-                               throw new InvalidOperationException ("source does not contain two numbers");
-                       if (points.Length > 2)
-                               throw new InvalidOperationException ("source contains too many delimiters");
-
-                       CultureInfo ci = CultureInfo.InvariantCulture;
-                       return new Point (Convert.ToDouble(points[0],ci), Convert.ToDouble(points[1],ci));      
+                       if (source == null)
+                               throw new ArgumentNullException ("source");
+                       var tokenizer = new NumericListTokenizer (source, CultureInfo.InvariantCulture);
+                       double x;
+                       double y;
+                       if (!double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out x) ||
+                           !double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out y))
+                       {
+                               throw new FormatException (string.Format ("Invalid Point format: {0}", source));
+                       }
+                       if (!tokenizer.HasNoMoreTokens ())
+                       {
+                               throw new InvalidOperationException ("Invalid Point format: " + source);
+                       }
+                       return new Point(x, y);
                }
 
                public override string ToString ()
@@ -170,18 +176,13 @@ namespace System.Windows {
 
                private string ToString(string format,IFormatProvider formatProvider)
                {
-                       CultureInfo ci = (CultureInfo)formatProvider;
-
-                       if (ci == null)
-                               ci = CultureInfo.CurrentCulture;
-                       string seperator = ci.NumberFormat.NumberDecimalSeparator;
-                       if (seperator.Equals(","))
-                               seperator = ";";
-                       else
-                               seperator = ",";
-                       object[] ob = { this._x, seperator, this._y };
-
-                       return string.Format(formatProvider, "{0:" + format + "}{1}{2:" + format + "}", ob);
+                       if (formatProvider == null)
+                               formatProvider = CultureInfo.CurrentCulture;
+                       if (format == null)
+                               format = string.Empty;
+                       var separator = NumericListTokenizer.GetSeparator (formatProvider);
+                       var pointFormat  = string.Format ("{{0:{0}}}{1}{{1:{0}}}", format, separator);
+                       return string.Format (formatProvider, pointFormat, _x, _y);
                }
 
                string IFormattable.ToString (string format, IFormatProvider formatProvider)
index fd38ec6c25ed169cbff90534070b583eb93b99be..6e2e3d9adbcf1e0b69d3189f4535b5fcc47c11a5 100644 (file)
 //     Sebastien Pouliot  <sebastien@ximian.com>
 //
 
-using System;
 using System.ComponentModel;
 using System.Globalization;
-using System.Text;
 using System.Windows.Converters;
 using System.Windows.Markup;
 using System.Windows.Media;
@@ -121,7 +119,14 @@ namespace System.Windows {
 
                public override int GetHashCode ()
                {
-                       throw new NotImplementedException ();
+                       unchecked
+                       {
+                               var hashCode = _x.GetHashCode ();
+                               hashCode = (hashCode * 397) ^ _y.GetHashCode ();
+                               hashCode = (hashCode * 397) ^ _width.GetHashCode ();
+                               hashCode = (hashCode * 397) ^ _height.GetHashCode ();
+                               return hashCode;
+                       }
                }
 
                public bool Contains (Rect rect)
@@ -296,7 +301,37 @@ namespace System.Windows {
 
                public static Rect Parse (string source)
                {
-                       throw new NotImplementedException ();
+                       if (source == null)
+                               throw new ArgumentNullException ("source");
+                       Rect value;
+                       if (source.Trim () == "Empty")
+                       {
+                               value = Empty;
+                       }
+                       else
+                       {
+                               var tokenizer = new NumericListTokenizer (source, CultureInfo.InvariantCulture);
+                               double x;
+                               double y;
+                               double width;
+                               double height;
+                               if (double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out x)
+                                       && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out y)
+                                       && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out width)
+                                       && double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out height))
+                               {
+                                       if (!tokenizer.HasNoMoreTokens ())
+                                       {
+                                               throw new InvalidOperationException ("Invalid Rect format: " + source);
+                                       }
+                                       value = new Rect (x, y, width, height);
+                               }
+                               else
+                               {
+                                       throw new FormatException (string.Format ("Invalid Rect format: {0}", source));
+                               }
+                       }
+                       return value;
                }
 
                public override string ToString ()
@@ -325,17 +360,12 @@ namespace System.Windows {
                        if (format == null)
                                format = string.Empty;
 
-                       string separator = ",";
-                       NumberFormatInfo numberFormat =
-                               provider.GetFormat (typeof (NumberFormatInfo)) as NumberFormatInfo;
-                       if (numberFormat != null &&
-                           numberFormat.NumberDecimalSeparator == separator)
-                               separator = ";";
+                       var separator = NumericListTokenizer.GetSeparator (provider);
 
-                       string rectFormat = String.Format (
+                       var rectFormat = string.Format (
                                "{{0:{0}}}{1}{{1:{0}}}{1}{{2:{0}}}{1}{{3:{0}}}",
                                format, separator);
-                       return String.Format (provider, rectFormat,
+                       return string.Format (provider, rectFormat,
                                _x, _y, _width, _height);
                }
 
index d42beb95b7388ddf4ccaa2307d76d4af27784fcd..69f497228f0031f609b98b33e9a7896a2074063d 100644 (file)
@@ -78,46 +78,50 @@ namespace System.Windows {
                        Size value;
                        if (source.Trim () == "Empty")
                        {
-                               value = Empty;
+                               return Empty;
                        }
-                       else
+                       var tokenizer = new NumericListTokenizer (source, CultureInfo.InvariantCulture);
+                       double width;
+                       double height;
+                       if (!double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out width) ||
+                           !double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out height))
                        {
-                               var parts = source.Split (',');
-                               if (parts.Length != 2)
-                                       throw new FormatException (string.Format ("Invalid Size format: {0}", source));
-                               double width;
-                               double height;
-                               if (double.TryParse (parts[0], NumberStyles.Float, CultureInfo.InvariantCulture, out width)
-                                       && double.TryParse (parts[1], NumberStyles.Float, CultureInfo.InvariantCulture, out height))
-                               {
-                                       value = new Size (width, height);
-                               }
-                               else
-                               {
-                                       throw new FormatException (string.Format ("Invalid Size format: {0}", source));
-                               }
+                               throw new FormatException (string.Format ("Invalid Size format: {0}", source));
                        }
-                       return value;
+                       if (!tokenizer.HasNoMoreTokens ())
+                       {
+                               throw new InvalidOperationException ("Invalid Size format: " + source);
+                       }
+                       return new Size(width, height);
                }
 
                public override string ToString ()
                {
-                       return ConvertToString (null);
+                       return ConvertToString (null, null);
                }
 
                public string ToString (IFormatProvider provider)
                {
-                       return ConvertToString (provider);
+                       return ConvertToString (null, provider);
                }
 
                string IFormattable.ToString (string format, IFormatProvider provider)
                {
-                       return ConvertToString (provider);
+                       return ConvertToString (format, provider);
                }
 
-               private string ConvertToString (IFormatProvider provider)
+               private string ConvertToString (string format, IFormatProvider provider)
                {
-                       return IsEmpty ? "Empty" : string.Concat (_width, ",", _height);
+                       if (IsEmpty)
+                               return "Empty";
+
+                       if (provider == null)
+                               provider = CultureInfo.CurrentCulture;
+                       if (format == null)
+                               format = string.Empty;
+                       var separator = NumericListTokenizer.GetSeparator (provider);
+                       var vectorFormat  = string.Format ("{{0:{0}}}{1}{{1:{0}}}", format, separator);
+                       return string.Format (provider, vectorFormat, _width, _height);
                }
 
                public bool IsEmpty {
index 5ed53c3e249cbab2c7ca461a8082147f3b16218a..88b23054fdb220d7613a848e75a4096bdce2ed03 100644 (file)
@@ -23,8 +23,8 @@
 //     Chris Toshok (toshok@novell.com)
 //
 
-using System;
 using System.ComponentModel;
+using System.Globalization;
 using System.Windows.Converters;
 using System.Windows.Markup;
 using System.Windows.Media;
@@ -57,12 +57,10 @@ namespace System.Windows {
 
                public override int GetHashCode ()
                {
-                       throw new NotImplementedException ();
-               }
-
-               string IFormattable.ToString (string format, IFormatProvider provider)
-               {
-                       return string.Format (provider, "{0:" + format + "},{1:" + format + "}", _x, _y);
+                       unchecked
+                       {
+                               return (_x.GetHashCode () * 397) ^ _y.GetHashCode ();
+                       }
                }
 
                public static bool Equals (Vector vector1, Vector vector2)
@@ -150,17 +148,47 @@ namespace System.Windows {
 
                public static Vector Parse (string source)
                {
-                       throw new NotImplementedException ();
+                       if (source == null)
+                               throw new ArgumentNullException ("source");
+                       var tokenizer = new NumericListTokenizer (source, CultureInfo.InvariantCulture);
+                       double x;
+                       double y;
+                       if (!double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out x) ||
+                           !double.TryParse (tokenizer.GetNextToken (), NumberStyles.Float, CultureInfo.InvariantCulture, out y))
+                       {
+                               throw new FormatException (string.Format ("Invalid Vector format: {0}", source));
+                       }
+                       if (!tokenizer.HasNoMoreTokens ())
+                       {
+                               throw new InvalidOperationException("Invalid Vector format: " + source);
+                       }
+                       return new Vector(x, y);
                }
 
                public override string ToString ()
                {
-                       return String.Format ("{0},{1}", _x, _y);
+                       return ToString(null);
                }
 
                public string ToString (IFormatProvider provider)
                {
-                       throw new NotImplementedException ();
+                       return ToString (null, provider);
+               }
+
+               string IFormattable.ToString (string format, IFormatProvider provider)
+               {
+                       return ToString (format, provider);
+               }
+
+               private string ToString(string format,IFormatProvider formatProvider)
+               {
+                       if (formatProvider == null)
+                               formatProvider = CultureInfo.CurrentCulture;
+                       if (format == null)
+                               format = string.Empty;
+                       var separator = NumericListTokenizer.GetSeparator (formatProvider);
+                       var vectorFormat  = string.Format ("{{0:{0}}}{1}{{1:{0}}}", format, separator);
+                       return string.Format (formatProvider, vectorFormat, _x, _y);
                }
 
                public double Length {
index 9134aec4b47c67cb6f1198a52a4a826691e684b0..f9e15374908dab1488945271b314cdac024eda4b 100644 (file)
@@ -1,5 +1,6 @@
 using NUnit.Framework;
 using System;
+using System.Globalization;
 using System.Windows.Media;
 
 namespace MonoTests.System.Windows.Media {
@@ -56,7 +57,7 @@ namespace MonoTests.System.Windows.Media {
                {
                        var conv = new MatrixConverter ();
                        var matrix = new Matrix (1, 2, 3, 4, 5, 6);
-                       object obj = conv.ConvertTo (matrix, typeof (string));
+                       object obj = conv.ConvertTo (null, CultureInfo.InvariantCulture, matrix, typeof (string));
                        Assert.AreEqual (typeof (string), obj.GetType ());
                        Assert.AreEqual ("1,2,3,4,5,6", (string)obj);
                }
index cbccb4339bb10d2facce83d497a179b8f504f779..29503407fb18a21579ff502910de5f7849662fcf 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -347,7 +348,7 @@ namespace MonoTests.System.Windows.Media {
                public void ToStringTest ()
                {
                        Matrix m = new Matrix (1, 2, 3, 4, 5, 6);
-                       Assert.AreEqual ("1,2,3,4,5,6", m.ToString());
+                       Assert.AreEqual ("1,2,3,4,5,6", m.ToString(CultureInfo.InvariantCulture));
                        m = Matrix.Identity;
                        Assert.AreEqual ("Identity", m.ToString());
                }
index a5519a462d2e23d384c69cb475d3ecb18a201e7d..2aecc932a3ad0637006c1940bd916f69e40124b8 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -54,7 +55,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertFrom ()
                {
                        Int32RectConverter r = new Int32RectConverter ();
@@ -79,7 +79,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertFrom_negative ()
                {
                        Int32RectConverter r = new Int32RectConverter ();
@@ -90,14 +89,13 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertTo ()
                {
                        Int32RectConverter r = new Int32RectConverter ();
 
                        Int32Rect rect = new Int32Rect (0, 0, 1, 2);
 
-                       object o = r.ConvertTo (rect, typeof (string));
+                       object o = r.ConvertTo (null, CultureInfo.InvariantCulture, rect, typeof (string));
                        
                        Assert.AreEqual (typeof (string), o.GetType());
                        Assert.AreEqual ("0,0,1,2", (string)o);
index 8275f1813b8611bd88151fe3406cc6502b8b4e5d..d65da4e23f20216618d1730912f3680fb7d8c953 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -136,13 +137,12 @@ namespace MonoTests.System.Windows {
                public void ToStringTest ()
                {
                        Int32Rect r = new Int32Rect (1, 2, 3, 4);
-                       Assert.AreEqual ("1,2,3,4", r.ToString());
+                       Assert.AreEqual ("1,2,3,4", r.ToString(CultureInfo.InvariantCulture));
 
                        Assert.AreEqual ("Empty", Int32Rect.Empty.ToString());
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void Parse ()
                {
                        Int32Rect r = Int32Rect.Parse ("1, 2, 3, 4");
@@ -150,7 +150,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ParseNegative ()
                {
                        Int32Rect.Parse ("1, 2, -3, -4");
diff --git a/mcs/class/WindowsBase/Test/System.Windows/Int32RectValueSerializerTest.cs b/mcs/class/WindowsBase/Test/System.Windows/Int32RectValueSerializerTest.cs
new file mode 100644 (file)
index 0000000..222b35c
--- /dev/null
@@ -0,0 +1,69 @@
+using System;
+using System.Windows;
+using System.Windows.Converters;
+using NUnit.Framework;
+
+namespace MonoTests.System.Windows {
+
+       [TestFixture]
+       public class Int32RectValueSerializerTest
+       {
+               [Test]
+               public void CanConvertFromString ()
+               {
+                       var serializer = new Int32RectValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertFromString ("", null));
+               }
+
+               [Test]
+               public void CanConvertToString ()
+               {
+                       var serializer = new Int32RectValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertToString (new Int32Rect (0, 0, 0, 0), null));
+                       Assert.IsFalse (serializer.CanConvertToString ("", null));
+               }
+
+               [Test]
+               public void ConvertFromString ()
+               {
+                       var serializer = new Int32RectValueSerializer ();
+                       object obj = serializer.ConvertFromString ("3,4,5,6", null);
+                       Assert.AreEqual (typeof (Int32Rect), obj.GetType ());
+                       Assert.AreEqual (new Int32Rect (3, 4, 5, 6), obj);
+               }
+
+               [Test]
+               public void RoundTripConvert()
+               {
+                       var serializer = new Int32RectValueSerializer ();
+                       var size = new Int32Rect (7, 8, 9, 10);
+                       var obj = serializer.ConvertFromString (serializer.ConvertToString (size, null), null);
+                       Assert.AreEqual (size, obj);
+               }
+
+               [Test]
+               [ExpectedException (typeof (FormatException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringHasInvalidFormat ()
+               {
+                       var serializer = new Int32RectValueSerializer ();
+                       serializer.ConvertFromString ("a,b,c,d", null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringIsNull ()
+               {
+                       var serializer = new Int32RectValueSerializer ();
+                       serializer.ConvertFromString (null, null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertToStringShouldThrowExceptionWhenInvalidType ()
+               {
+                       var serializer = new Int32RectValueSerializer ();
+                       serializer.ConvertToString (10, null);
+               }
+       }
+
+}
index a5c335953d57b70bc1db0ea14800089143d6a2d5..9e80eb1dedf9531a9f651a4e23ac6b3ef752dbcf 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -52,7 +53,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertFrom ()
                {
                        PointConverter r = new PointConverter ();
@@ -77,14 +77,13 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertTo ()
                {
                        PointConverter r = new PointConverter ();
 
                        Point rect = new Point (1, 2);
 
-                       object o = r.ConvertTo (rect, typeof (string));
+                       object o = r.ConvertTo (null, CultureInfo.InvariantCulture, rect, typeof (string));
                        
                        Assert.AreEqual (typeof (string), o.GetType());
                        Assert.AreEqual ("1,2", (string)o);
index 521b227d046854591251f6704e13ae443e447460..001f74243eefba11f5d1cde942bef415d7527cec 100644 (file)
@@ -51,20 +51,18 @@ namespace MonoTests.System.Windows {
                        Assert.IsFalse (p.Equals (new object()));
                }
 
-        [Test]
-               [Category ("NotWorking")]
-        public void getHashCodeTest()
-        {
-                       Point p1 = new Point(-5, -4);
-                       Point p2 = new Point(5, 4);
-                       Point p3 = new Point(5, 4);
-
-                       Assert.AreEqual(p2.GetHashCode(), p3.GetHashCode());
-                       Assert.AreEqual(p1.GetHashCode(),p2.GetHashCode());
-        }
+                       [Test]
+                       public void GetHashCodeTest()
+                       {
+                               Point p1 = new Point(-5, -4);
+                               Point p2 = new Point(5, 4);
+                               Point p3 = new Point(5, 4);
+
+                               Assert.AreEqual (p2.GetHashCode (), p3.GetHashCode ());
+                               Assert.AreEqual (p1.GetHashCode (),p2.GetHashCode ());
+                       }
 
                [Test]
-               [Category ("NotWorking")]
                public void ToStringTest ()
                {
                        Thread.CurrentThread.CurrentCulture = CultureInfo.GetCultureInfo("en-us");
@@ -85,7 +83,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void Parse ()
                {
                        Thread.CurrentThread.CurrentCulture = CultureInfo.GetCultureInfo("fr-fr");
diff --git a/mcs/class/WindowsBase/Test/System.Windows/PointValueSerializerTest.cs b/mcs/class/WindowsBase/Test/System.Windows/PointValueSerializerTest.cs
new file mode 100644 (file)
index 0000000..679cd74
--- /dev/null
@@ -0,0 +1,69 @@
+using System;
+using System.Windows;
+using System.Windows.Converters;
+using NUnit.Framework;
+
+namespace MonoTests.System.Windows {
+
+       [TestFixture]
+       public class PointValueSerializerTest
+       {
+               [Test]
+               public void CanConvertFromString ()
+               {
+                       var serializer = new PointValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertFromString ("", null));
+               }
+
+               [Test]
+               public void CanConvertToString ()
+               {
+                       var serializer = new PointValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertToString (new Point (0, 0), null));
+                       Assert.IsFalse (serializer.CanConvertToString ("", null));
+               }
+
+               [Test]
+               public void ConvertFromString ()
+               {
+                       var serializer = new PointValueSerializer ();
+                       object obj = serializer.ConvertFromString ("3.14,4.15", null);
+                       Assert.AreEqual (typeof (Point), obj.GetType ());
+                       Assert.AreEqual (new Point (3.14, 4.15), obj);
+               }
+
+               [Test]
+               public void RoundTripConvert()
+               { 
+                       var serializer = new PointValueSerializer ();
+                       var Point = new Point (1.234, 2.678);
+                       var obj = serializer.ConvertFromString (serializer.ConvertToString (Point, null), null);
+                       Assert.AreEqual (Point, obj);
+               }
+
+               [Test]
+               [ExpectedException (typeof (FormatException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringHasInvalidFormat ()
+               {
+                       var serializer = new PointValueSerializer ();
+                       serializer.ConvertFromString ("a,b", null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringIsNull ()
+               {
+                       var serializer = new PointValueSerializer ();
+                       serializer.ConvertFromString (null, null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertToStringShouldThrowExceptionWhenInvalidType ()
+               {
+                       var serializer = new PointValueSerializer ();
+                       serializer.ConvertToString (10, null);
+               }
+       }
+
+}
index 0fa463fe71e49bcc9a4ca2a53c879646f854672f..0e1161c9dca8921b133010f28d07e3c4eb483a79 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -54,7 +55,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertFrom ()
                {
                        RectConverter r = new RectConverter ();
@@ -79,7 +79,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (ArgumentException))]
                public void ConvertFrom_negative ()
                {
@@ -88,14 +87,13 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertTo ()
                {
                        RectConverter r = new RectConverter ();
 
                        Rect rect = new Rect (0, 0, 1, 2);
 
-                       object o = r.ConvertTo (rect, typeof (string));
+                       object o = r.ConvertTo (null, CultureInfo.InvariantCulture, rect, typeof (string));
                        
                        Assert.AreEqual (typeof (string), o.GetType());
                        Assert.AreEqual ("0,0,1,2", (string)o);
index 6fddadb2f9167de43dcc81e91ce1875d9548c3f6..c1d0dae4d7b56044ff08b2b2cffaaa5edcea08fb 100644 (file)
@@ -327,7 +327,6 @@ namespace MonoTests.System.Windows {
                }
                
                [Test]
-               [Category ("NotWorking")]
                public void ToString_FormatException ()
                {
                        // This test does not currently work because
@@ -343,7 +342,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void Parse ()
                {
                        Rect r = Rect.Parse ("1 , 2, 3, 4");
@@ -351,7 +349,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void Parse2 ()
                {
                        Rect r = Rect.Parse ("1 2 3 4");
@@ -359,7 +356,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void Parse3 ()
                {
                        Rect r = Rect.Parse ("  1 2 3 4  ");
@@ -367,14 +363,12 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ParseWithBothSeparators ()
                {
                        Rect.Parse ("1.0, 3 2.0, 5.0");
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (ArgumentException))]
                public void ParseNegative ()
                {
@@ -382,7 +376,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (InvalidOperationException))] // "Premature string termination encountered."
                public void Parse3Doubles ()
                {
@@ -390,7 +383,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (FormatException))]
                public void ParseInvalidString1 ()
                {
@@ -398,7 +390,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (InvalidOperationException))]
                public void ParseInvalidString3 ()
                {
@@ -406,7 +397,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (FormatException))]
                public void ParseInvalidString4 ()
                {
@@ -414,7 +404,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (InvalidOperationException))]
                public void ParseInvalidString5 ()
                {
@@ -422,14 +411,12 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ParseInvalidString6 ()
                {
                        Rect.Parse ("\n1.0, 2.0, 5.0, 2");
                }
 
                [Test]
-               [Category ("NotWorking")]
                [ExpectedException (typeof (InvalidOperationException))]
                public void ParseInvalidString7 ()
                {
diff --git a/mcs/class/WindowsBase/Test/System.Windows/RectValueSerializerTest.cs b/mcs/class/WindowsBase/Test/System.Windows/RectValueSerializerTest.cs
new file mode 100644 (file)
index 0000000..3a549c3
--- /dev/null
@@ -0,0 +1,77 @@
+using System;
+using System.Windows;
+using System.Windows.Converters;
+using NUnit.Framework;
+
+namespace MonoTests.System.Windows {
+
+       [TestFixture]
+       public class RectValueSerializerTest
+       {
+               [Test]
+               public void CanConvertFromString ()
+               {
+                       var serializer = new RectValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertFromString ("", null));
+               }
+
+               [Test]
+               public void CanConvertToString ()
+               {
+                       var serializer = new RectValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertToString (new Rect (0, 0, 0, 0), null));
+                       Assert.IsFalse (serializer.CanConvertToString ("", null));
+               }
+
+               [Test]
+               public void ConvertFromString ()
+               {
+                       var serializer = new RectValueSerializer ();
+                       object obj = serializer.ConvertFromString ("3.14,4.15,5.16,6.17", null);
+                       Assert.AreEqual (typeof (Rect), obj.GetType ());
+                       Assert.AreEqual (new Rect (3.14, 4.15, 5.16, 6.17), obj);
+               }
+
+               [Test]
+               public void RoundTripConvert()
+               { 
+                       var serializer = new RectValueSerializer ();
+                       var rect = new Rect (1.234, 2.678, 3.123, 4.567);
+                       var obj = serializer.ConvertFromString (serializer.ConvertToString (rect, null), null);
+                       Assert.AreEqual (rect, obj);
+               }
+
+               [Test]
+               [ExpectedException (typeof (FormatException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringHasInvalidFormat ()
+               {
+                       var serializer = new RectValueSerializer ();
+                       serializer.ConvertFromString ("a,b,c,d", null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringIsNull ()
+               {
+                       var serializer = new RectValueSerializer ();
+                       serializer.ConvertFromString (null, null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertToStringShouldThrowExceptionWhenInvalidType ()
+               {
+                       var serializer = new RectValueSerializer ();
+                       serializer.ConvertToString (10, null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (ArgumentException))]
+               public void ConvertToStringShouldThrowExceptionWhenHeightOrWidthIsNegative ()
+               {
+                       var serializer = new RectValueSerializer ();
+                       var result = serializer.ConvertFromString ("1,2,-1,-2", null);
+               }
+       }
+
+}
index d320100f1a074164c6c944b3ef4d970ba7506ce6..74a0f0b3be1be941591c224aa9415a23fd52f294 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -86,7 +87,7 @@ namespace MonoTests.System.Windows {
 
                        Size rect = new Size (1, 2);
 
-                       object o = r.ConvertTo (rect, typeof (string));
+                       object o = r.ConvertTo (null, CultureInfo.InvariantCulture, rect, typeof (string));
                        
                        Assert.AreEqual (typeof (string), o.GetType());
                        Assert.AreEqual ("1,2", (string)o);
index 6c04fd244d4877230928612956991331737e2277..e9bb8d925c02ea90c4b756afcb747a2e5e266b69 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -158,7 +159,7 @@ namespace MonoTests.System.Windows {
                [Test]
                public void ToStringTest ()
                {
-                       Assert.AreEqual ("1,2", (new Size (1, 2)).ToString ());
+                       Assert.AreEqual ("1,2", (new Size (1, 2)).ToString (CultureInfo.InvariantCulture));
                }
 
                [Test]
index 003e9fc0505f5487032772b4dfd28068d71ff3f9..368085d00cf45b4c73ea4660a6a3b29ce911c392 100644 (file)
@@ -50,7 +50,7 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [ExpectedException (typeof (ArgumentNullException))]
+               [ExpectedException (typeof (NotSupportedException))]
                public void ConvertFromStringShouldThrowExceptionWhenStringIsNull ()
                {
                        var serializer = new SizeValueSerializer ();
index 2e394a88152e07d1952ff1022e9b9c659f5d45d0..af6dd725aeaad74c2cf6b3548ab45163bc6baf48 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -52,7 +53,6 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertFrom ()
                {
                        VectorConverter r = new VectorConverter ();
@@ -77,14 +77,13 @@ namespace MonoTests.System.Windows {
                }
 
                [Test]
-               [Category ("NotWorking")]
                public void ConvertTo ()
                {
                        VectorConverter r = new VectorConverter ();
 
                        Vector rect = new Vector (1, 2);
 
-                       object o = r.ConvertTo (rect, typeof (string));
+                       object o = r.ConvertTo (null, CultureInfo.InvariantCulture, rect, typeof (string));
                        
                        Assert.AreEqual (typeof (string), o.GetType());
                        Assert.AreEqual ("1,2", (string)o);
index 2f203729adf21c3f8fe9e8ed17f5303fa284fd7b..20e64e3134ee603583331ea904071c2af11c9acd 100644 (file)
@@ -24,6 +24,7 @@
 //
 
 using System;
+using System.Globalization;
 using System.Windows;
 using System.Windows.Media;
 using NUnit.Framework;
@@ -56,7 +57,7 @@ namespace MonoTests.System.Windows {
                public void ToStringTest ()
                {
                        Vector v = new Vector (4, 5);
-                       Assert.AreEqual ("4,5", v.ToString());
+                       Assert.AreEqual ("4,5", v.ToString(CultureInfo.InvariantCulture));
                }
 
                [Test]
diff --git a/mcs/class/WindowsBase/Test/System.Windows/VectorValueSerializerTest.cs b/mcs/class/WindowsBase/Test/System.Windows/VectorValueSerializerTest.cs
new file mode 100644 (file)
index 0000000..3b79a99
--- /dev/null
@@ -0,0 +1,69 @@
+using System;
+using System.Windows;
+using System.Windows.Converters;
+using NUnit.Framework;
+
+namespace MonoTests.System.Windows {
+
+       [TestFixture]
+       public class VectorValueSerializerTest
+       {
+               [Test]
+               public void CanConvertFromString ()
+               {
+                       var serializer = new VectorValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertFromString ("", null));
+               }
+
+               [Test]
+               public void CanConvertToString ()
+               {
+                       var serializer = new VectorValueSerializer ();
+                       Assert.IsTrue (serializer.CanConvertToString (new Vector (0, 0), null));
+                       Assert.IsFalse (serializer.CanConvertToString ("", null));
+               }
+
+               [Test]
+               public void ConvertFromString ()
+               {
+                       var serializer = new VectorValueSerializer ();
+                       object obj = serializer.ConvertFromString ("3.14,4.15", null);
+                       Assert.AreEqual (typeof (Vector), obj.GetType ());
+                       Assert.AreEqual (new Vector (3.14, 4.15), obj);
+               }
+
+               [Test]
+               public void RoundTripConvert()
+               { 
+                       var serializer = new VectorValueSerializer ();
+                       var Vector = new Vector (1.234, 2.678);
+                       var obj = serializer.ConvertFromString (serializer.ConvertToString (Vector, null), null);
+                       Assert.AreEqual (Vector, obj);
+               }
+
+               [Test]
+               [ExpectedException (typeof (FormatException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringHasInvalidFormat ()
+               {
+                       var serializer = new VectorValueSerializer ();
+                       serializer.ConvertFromString ("a,b", null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertFromStringShouldThrowExceptionWhenStringIsNull ()
+               {
+                       var serializer = new VectorValueSerializer ();
+                       serializer.ConvertFromString (null, null);
+               }
+
+               [Test]
+               [ExpectedException (typeof (NotSupportedException))]
+               public void ConvertToStringShouldThrowExceptionWhenInvalidType ()
+               {
+                       var serializer = new VectorValueSerializer ();
+                       serializer.ConvertToString (10, null);
+               }
+       }
+
+}
index daf139486885cd34858f23dffb38efdebdcceef1..e672ffb286ea4120bd869a6406de9fdd0f2a440e 100644 (file)
     <Compile Include="System.Windows\IWeakEventListener.cs" />\r
     <Compile Include="System.Windows\LocalValueEntry.cs" />\r
     <Compile Include="System.Windows\LocalValueEnumerator.cs" />\r
+    <Compile Include="System.Windows\NumericListTokenizer.cs" />\r
     <Compile Include="System.Windows\Point.cs" />\r
     <Compile Include="System.Windows\PointConverter.cs" />\r
     <Compile Include="System.Windows\PropertyChangedCallback.cs" />\r
index c36c7ce5608ab796e4a659abf9e57fae4d39ae48..649a1a450e38295eec0186b80bef937683b5918e 100644 (file)
@@ -102,6 +102,7 @@ System.Windows/RectConverter.cs
 System.Windows/Size.cs
 System.Windows/SizeConverter.cs
 System.Windows/SplashScreen.cs
+System.Windows/NumericListTokenizer.cs
 System.Windows/ValidateValueCallback.cs
 System.Windows/Vector.cs
 System.Windows/VectorConverter.cs
index 5fba4fc771069f5e0a6d9d4a0e42338e1ab55547..fa7855a690f33613fb46449ff29d8e919b2e5664 100644 (file)
@@ -25,16 +25,20 @@ System.Windows/DependencyObjectTypeTest.cs
 System.Windows/DependencyPropertyTest.cs
 System.Windows/Int32RectTest.cs
 System.Windows/Int32RectConverterTest.cs
+System.Windows/Int32RectValueSerializerTest.cs
 System.Windows/PointTest.cs
 System.Windows/PointConverterTest.cs
+System.Windows/PointValueSerializerTest.cs
 System.Windows/PropertyMetadataTest.cs
 System.Windows/RectTest.cs
 System.Windows/RectConverterTest.cs
+System.Windows/RectValueSerializerTest.cs
 System.Windows/SizeTest.cs
 System.Windows/SizeConverterTest.cs
 System.Windows/SizeValueSerializerTest.cs
 System.Windows/VectorTest.cs
 System.Windows/VectorConverterTest.cs
+System.Windows/VectorValueSerializerTest.cs
 System.Windows.Markup/ConstructorArgumentAttributeTest.cs
 System.Windows.Markup/ContentPropertyAttributeTest.cs
 System.Windows.Markup/ContentWrapperAttributeTest.cs
index 9312f1da9fe53725d40125713af0238d09eeb27a..9c642ffa0062445fd98db4fe2ef938197a3fade6 100644 (file)
@@ -257,6 +257,9 @@ namespace System.Reflection.Emit
                [MethodImplAttribute(MethodImplOptions.InternalCall)]
                private static extern void basic_init (AssemblyBuilder ab);
 
+               [MethodImplAttribute(MethodImplOptions.InternalCall)]
+               static extern void UpdateNativeCustomAttributes (AssemblyBuilder ab);
+
                /* Keep this in sync with codegen.cs in mcs */
                private const AssemblyBuilderAccess COMPILER_ACCESS = (AssemblyBuilderAccess) 0x800;
 
@@ -949,6 +952,12 @@ namespace System.Reflection.Emit
                                cattrs = new CustomAttributeBuilder [1];
                                cattrs [0] = customBuilder;
                        }
+
+                       /*
+                       Only update the native list of custom attributes if we're adding one that is known to change dynamic execution behavior.
+                       */
+                       if (customBuilder.Ctor != null && customBuilder.Ctor.DeclaringType == typeof (System.Runtime.CompilerServices.RuntimeCompatibilityAttribute))
+                               UpdateNativeCustomAttributes (this);
                }
 
                [ComVisible (true)]
index ceef9625fe5ae26c34889a8bdeffc8f5ee47d38b..07200f28b4e90e0b126da82922e3c8aa6cbf1619 100644 (file)
@@ -114,6 +114,7 @@ namespace System.Security.Cryptography {
                                persisted = true;
                                this.FromXmlString (store.KeyValue);
                        }
+                       privateKeyExportable = (parameters.Flags & CspProviderFlags.UseNonExportableKey) == 0;
                }
 
                ~DSACryptoServiceProvider ()
index a8ebc812da3aff1068f07cb3114b0099cdc870a0..16fdfa15e5eb7a9d3b191fa793c83a036e558b7b 100644 (file)
@@ -111,6 +111,7 @@ namespace System.Security.Cryptography {
                        store = new KeyPairPersistence (p);
                        bool exists = store.Load ();
                        bool required = (p.Flags & CspProviderFlags.UseExistingKey) != 0;
+                       privateKeyExportable = (p.Flags & CspProviderFlags.UseNonExportableKey) == 0;
 
                        if (required && !exists)
                                throw new CryptographicException ("Keyset does not exist");
index b272a20f00cf4bf1ed0c970d89779cac3f9ae511..b78b5536b8e4522a1992eacf85c1affea0975326 100644 (file)
@@ -42,12 +42,14 @@ namespace System
                        var displayName = DeserializeString (ref input);
                        var standardName = DeserializeString (ref input);
                        var daylightName = DeserializeString (ref input);
-                       var rules = new List<TimeZoneInfo.AdjustmentRule> ();
+                       List<TimeZoneInfo.AdjustmentRule> rules = null;
                        while (input [0] != ';') {
+                               if (rules == null)
+                                       rules = new List<TimeZoneInfo.AdjustmentRule> ();
                                rules.Add (DeserializeAdjustmentRule (ref input));
                        }
                        var offsetSpan = TimeSpan.FromMinutes (offset);
-                       return TimeZoneInfo.CreateCustomTimeZone (tzId, offsetSpan, displayName, standardName, daylightName, rules.ToArray ());
+                       return TimeZoneInfo.CreateCustomTimeZone (tzId, offsetSpan, displayName, standardName, daylightName, rules?.ToArray ());
                }
 
                public string ToSerializedString ()
index 1c5cdd3ae820dc363687a19efbfe553ca31b6b20..25d9e9a39becbcd5e395d7c057ecaf11afc3d312 100644 (file)
@@ -624,7 +624,7 @@ namespace System
                        else
                                ParseRegTzi(adjustmentRules, 1, 9999, reg_tzi);
 
-                       return CreateCustomTimeZone (id, baseUtcOffset, display_name, standard_name, daylight_name, ValidateRules (adjustmentRules).ToArray ());
+                       return CreateCustomTimeZone (id, baseUtcOffset, display_name, standard_name, daylight_name, ValidateRules (adjustmentRules));
                }
 
                private static void ParseRegTzi (List<AdjustmentRule> adjustmentRules, int start_year, int end_year, byte [] buffer)
@@ -1231,8 +1231,11 @@ namespace System
                        return new DateTime (year, transition.Month, day) + transition.TimeOfDay.TimeOfDay;
                }
 
-               static List<AdjustmentRule> ValidateRules (List<AdjustmentRule> adjustmentRules)
+               static AdjustmentRule[] ValidateRules (List<AdjustmentRule> adjustmentRules)
                {
+                       if (adjustmentRules == null || adjustmentRules.Count == 0)
+                               return null;
+
                        AdjustmentRule prev = null;
                        foreach (AdjustmentRule current in adjustmentRules.ToArray ()) {
                                if (prev != null && prev.DateEnd > current.DateStart) {
@@ -1240,7 +1243,7 @@ namespace System
                                }
                                prev = current;
                        }
-                       return adjustmentRules;
+                       return adjustmentRules.ToArray ();
                }
 
 #if LIBC || MONOTOUCH
@@ -1404,13 +1407,13 @@ namespace System
                                }
                                tz = CreateCustomTimeZone (id, baseUtcOffset, id, standardDisplayName);
                        } else {
-                               tz = CreateCustomTimeZone (id, baseUtcOffset, id, standardDisplayName, daylightDisplayName, ValidateRules (adjustmentRules).ToArray ());
+                               tz = CreateCustomTimeZone (id, baseUtcOffset, id, standardDisplayName, daylightDisplayName, ValidateRules (adjustmentRules));
                        }
 
                        if (storeTransition && transitions.Count > 0) {
                                tz.transitions = transitions;
-                               tz.supportsDaylightSavingTime = true;
                        }
+                       tz.supportsDaylightSavingTime = adjustmentRules.Count > 0;
 
                        return tz;
                }
index a195c28f726b4606acdd030a68a4486914db0f5f..dc8bbdd27e60124cdda15956ab1156fb23db0212 100644 (file)
@@ -49,9 +49,15 @@ namespace MonoTests.System.Globalization
 
                        c = CultureInfo.InvariantCulture;
                        Assert.AreEqual (2, c.NumberFormat.CurrencyDecimalDigits, "#3");
+               }
 
+               [Test]
+               public void AllCulturesCanParseNegativeNumber ()
+               {
+                       foreach (var c in CultureInfo.GetCultures (CultureTypes.AllCultures))
+                       {
+                               int.Parse ("-1", c);
+                       }
                }
        }
 }
-
-
index 4528027b24e9bc730bcb914ef0f2573189f1cc90..7e01ce544d7240a073f1ca6fbc32d2cf3cb54c71 100644 (file)
@@ -2709,8 +2709,10 @@ namespace MonoTests.System.IO
                        File.Delete (path2);
 
                        try {
-                               symlink (path1, path2);
-                               symlink (path2, path1);
+                               if (symlink (path1, path2) != 0)
+                                       Assert.Fail ("symlink #1 failed with errno={0}", Marshal.GetLastWin32Error ());
+                               if (symlink (path2, path1) != 0)
+                                       Assert.Fail ("symlink #2 failed with errno={0}", Marshal.GetLastWin32Error ());
 
                                Assert.IsTrue (File.Exists (path1), "File.Exists must return true for path1 symlink loop");
                                Assert.IsTrue (File.Exists (path2), "File.Exists must return true for path2 symlink loop");
index fcf6284a00e429177e7982527ec5d406ba9eb426..f8c898d2f00095dc76ad39d04fed5704732b807f 100644 (file)
@@ -610,6 +610,102 @@ namespace MonoTests.System.Reflection.Emit
                        invoke (444);
                }
 
+               static Func<int> EmitDelegate (DynamicMethod dm) {
+                       ILGenerator il = dm.GetILGenerator ();
+                       var ret_val = il.DeclareLocal (typeof (int));
+                       var leave_label = il.DefineLabel ();
+
+                       //ret = 1;
+                       il.Emit (OpCodes.Ldc_I4, 1);
+                       il.Emit (OpCodes.Stloc, ret_val);
+
+                       // try {
+                       il.BeginExceptionBlock ();
+                       //      throw "hello";
+                       il.Emit (OpCodes.Ldstr, "hello");
+                       il.Emit (OpCodes.Throw, typeof (string));
+                       //      ret = 2
+                       il.Emit (OpCodes.Ldc_I4, 2);
+                       il.Emit (OpCodes.Stloc, ret_val);
+                       // }
+                       il.Emit (OpCodes.Leave, leave_label);
+                       //catch (string)
+                       il.BeginCatchBlock (typeof (string));
+                       il.Emit (OpCodes.Pop);
+                       //      ret = 3
+                       il.Emit (OpCodes.Ldc_I4, 3);
+                       il.Emit (OpCodes.Stloc, ret_val);
+                       //}
+                       il.Emit (OpCodes.Leave, leave_label);
+                       il.EndExceptionBlock ();
+
+                       il.MarkLabel (leave_label);
+                       //return ret;
+                       il.Emit (OpCodes.Ldloc, ret_val);
+                       il.Emit (OpCodes.Ret);
+
+                       var dele = (Func<int>)dm.CreateDelegate (typeof (Func<int>));
+                       return dele;
+               }
+
+               [Test] //see bxc #59334
+               public void ExceptionWrapping ()
+               {
+                       AssemblyBuilder ab = AppDomain.CurrentDomain.DefineDynamicAssembly (new AssemblyName ("ehatevfheiw"), AssemblyBuilderAccess.Run);
+                       AssemblyBuilder ab2 = AppDomain.CurrentDomain.DefineDynamicAssembly (new AssemblyName ("ddf4234"), AssemblyBuilderAccess.Run);
+                       CustomAttributeBuilder cab = new CustomAttributeBuilder (
+                                       typeof (RuntimeCompatibilityAttribute).GetConstructor (new Type [0]),
+                                       new object [0],
+                                       new PropertyInfo[] { typeof (RuntimeCompatibilityAttribute).GetProperty ("WrapNonExceptionThrows") },
+                                       new object[] { true });
+                       ab2.SetCustomAttribute (cab);
+
+                       AssemblyBuilder ab3 = AppDomain.CurrentDomain.DefineDynamicAssembly (new AssemblyName ("frfhfher"), AssemblyBuilderAccess.Run);
+                       //1 NamedArg. Property name: WrapNonExceptionThrows value: true (0x01) 
+                       byte[] blob = new byte[] { 0x01, 0x00, 0x01, 0x00, 0x54, 0x02, 0x16, 0x57, 0x72, 0x61, 0x70, 0x4E, 0x6F, 0x6E, 0x45, 0x78,
+                               0x63, 0x65, 0x70, 0x74, 0x69, 0x6F, 0x6E, 0x54, 0x68, 0x72, 0x6F, 0x77, 0x73, 0x01 };
+                       ab3.SetCustomAttribute (typeof (RuntimeCompatibilityAttribute).GetConstructor (new Type [0]), blob);
+               
+                       DynamicMethod invoke_no_module = new DynamicMethod("throw_1", typeof (int), new Type [0]);
+                       DynamicMethod invoke_with_module = new DynamicMethod("throw_2", typeof (int), new Type [0], typeof (DynamicMethodTest).Module);
+                       DynamicMethod invoke_with_ab = new DynamicMethod("throw_3", typeof (int), new Type [0], ab.ManifestModule);
+                       DynamicMethod invoke_with_ab2 = new DynamicMethod("throw_4", typeof (int), new Type [0], ab2.ManifestModule);
+                       DynamicMethod invoke_with_ab3 = new DynamicMethod("throw_5", typeof (int), new Type [0], ab3.ManifestModule);
+
+                       int result = 0;
+                       try {
+                               int res = EmitDelegate (invoke_no_module)();
+                               Assert.AreEqual (3, res, "invoke_no_module bad return value");
+                       } catch (RuntimeWrappedException e) {
+                               Assert.Fail ("invoke_no_module threw RWE");
+                       }
+
+                       try {
+                               int res = EmitDelegate (invoke_with_module)();
+                               Assert.Fail ("invoke_with_module did not throw RWE");
+                       } catch (RuntimeWrappedException e) {
+                       }
+
+                       try {
+                               int res = EmitDelegate (invoke_with_ab)();
+                               Assert.AreEqual (3, res, "invoke_with_ab bad return value");
+                       } catch (RuntimeWrappedException e) {
+                               Assert.Fail ("invoke_with_ab threw RWE");
+                       }
+
+                       try {
+                               int res = EmitDelegate (invoke_with_ab2)();
+                               Assert.Fail ("invoke_with_ab2 did not throw RWE");
+                       } catch (RuntimeWrappedException e) {
+                       }
+
+                       try {
+                               int res = EmitDelegate (invoke_with_ab3)();
+                               Assert.Fail ("invoke_with_a3 did not throw RWE");
+                       } catch (RuntimeWrappedException e) {
+                       }                       
+               }
+
 #if !MONODROID
                // RUNTIME: crash
                [Test]
index e56a20c75cd3ce2c0797c843aad267d91a7354f0..ac005e2711ad4262a087e309e7924682803f47bc 100644 (file)
@@ -1046,6 +1046,16 @@ public class DSACryptoServiceProviderTest {
                dsa = new DSACryptoServiceProvider (minKeySize);
                dsa.ImportCspBlob (blob);
        }
+
+       [Test] //bug 38054
+       public void NonExportableKeysAreNonExportable ()
+       {
+               var cspParams = new CspParameters (13, null, "Mono1024");
+               cspParams.KeyContainerName = "TestDSAKey";
+               cspParams.Flags = CspProviderFlags.UseNonExportableKey;
+               var rsa = new DSACryptoServiceProvider(cspParams);
+               Assert.Throws<CryptographicException>(() => rsa.ExportParameters(true));
+       }
 }
 
 }
index 6e44e3235b24061c7626bc48311a4cacbf686184..c9011cb41f6f9a37736eb9d0ba9e89d39e203b67 100644 (file)
@@ -1403,6 +1403,16 @@ public class RSACryptoServiceProviderTest {
                rsa = new RSACryptoServiceProvider (minKeySize);
                rsa.ImportCspBlob (blob);
        }
+
+       [Test] //bug 38054
+       public void NonExportableKeysAreNonExportable ()
+       {
+               var cspParams = new CspParameters();
+               cspParams.KeyContainerName = "TestRSAKey";
+               cspParams.Flags = CspProviderFlags.UseNonExportableKey;
+               var rsa = new RSACryptoServiceProvider(cspParams);
+               Assert.Throws<CryptographicException>(() => rsa.ExportParameters(true));
+       }
 }
 
 }
index f4d0cfa1e8c915d7de6b518eed18934222c91a58..b53a8d4496aaf50d01f99c4b9e29363b5f2b80d0 100644 (file)
@@ -1,5 +1,6 @@
 using System;
 using System.IO;
+using System.Linq;
 using NUnit.Framework;
 
 namespace MonoTests.System
@@ -24,6 +25,20 @@ namespace MonoTests.System
                        Assert.AreEqual (0, utc.GetAdjustmentRules ().Length);
                }
 
+               [Test] // Bug-44255
+               public void SystemTimeZoneSerializationTests ()
+               {
+                       foreach (var tmz in TimeZoneInfo.GetSystemTimeZones ())
+                       {
+                               var tmzClone = TimeZoneInfo.FromSerializedString (tmz.ToSerializedString ());
+                               Assert.AreEqual (tmz, tmzClone);
+                               Assert.AreEqual (tmz.DisplayName, tmzClone.DisplayName);
+                               Assert.AreEqual (tmz.StandardName, tmzClone.StandardName);
+                               Assert.AreEqual (tmz.SupportsDaylightSavingTime, tmzClone.SupportsDaylightSavingTime);
+                               Assert.AreEqual (tmz.DaylightName, tmzClone.DaylightName);
+                       }
+               }
+
                [Test]
                public void SerializeCustomUtcZoneWithOddNaming ()
                {
index d03e4c21f2af694ee1ea2bf45fa97fad43341c19..72c2cb41923870747b317d5a06907fe1da14446c 100644 (file)
@@ -296,6 +296,14 @@ namespace MonoTests.System
                {
                }
 
+               private void GenericMethod2<A, B, C, D> ()
+                       where C : Duper
+                       where A : B, IFace
+                       where B : C
+                       where D : Baz<object>
+               {
+               }
+
                public class Nested
                {
 
@@ -369,6 +377,54 @@ namespace MonoTests.System
                        // Tests for parameters with generic constraints
                        mi = typeof (TypeTest).GetMethod ("GenericMethod", BindingFlags.Instance|BindingFlags.NonPublic);
                        Assert.IsTrue (typeof (IFace).IsAssignableFrom (mi.GetParameters ()[1].ParameterType));
+
+                       // Transitivity of IsAssignableFrom for type parameters
+                       mi = typeof (TypeTest).GetMethod ("GenericMethod2", BindingFlags.Instance|BindingFlags.NonPublic);
+                       var gparams = mi.GetGenericArguments ();
+                       // B : Duper since B : C and C : Duper
+                       Assert.IsTrue (typeof (Duper).IsAssignableFrom (gparams[1]), "#36");
+                       // A : Duper since A : B and B : Duper
+                       Assert.IsTrue (typeof (Duper).IsAssignableFrom (gparams[0]), "#37a");
+                       // A : IFace since A : IFace
+                       Assert.IsTrue (typeof (IFace).IsAssignableFrom (gparams[0]), "#37b");
+                       // B : Super since B : Duper and Duper : Super
+                       Assert.IsTrue (typeof (Super).IsAssignableFrom (gparams[1]), "#38");
+                       // A : Super since A : B and B : Super
+                       Assert.IsTrue (typeof (Super).IsAssignableFrom (gparams[0]), "#39");
+                       // D : IBar<object> since D : Baz<object> and Baz<object> : IBar<object>
+                       Assert.IsTrue (typeof (IBar<object>).IsAssignableFrom (gparams [3]), "#40");
+                       // A not assignable from B since A : B
+                       Assert.IsFalse (gparams[0].IsAssignableFrom (gparams [1]), "#41");
+                       Assert.IsFalse (gparams[0].IsAssignableFrom (gparams [2]), "#42");
+
+                       // A is not assignable from Array and Delegate and vice versa
+                       Assert.IsFalse (gparams[0].IsAssignableFrom (typeof (Array)), "#43");
+                       Assert.IsFalse (gparams[0].IsAssignableFrom (typeof (Delegate)), "#44");
+                       Assert.IsFalse (typeof (Array).IsAssignableFrom (gparams[0]), "#45");
+                       Assert.IsFalse (typeof (Delegate).IsAssignableFrom (gparams[0]), "#46");
+
+               }
+
+               [Test]
+               public void GenericParameterBaseType ()
+               {
+                       var mi = typeof (TypeTest).GetMethod ("GenericMethod2", BindingFlags.Instance|BindingFlags.NonPublic);
+                       var gparams = mi.GetGenericArguments ();
+
+                       // From the .NET documentation: BaseType property of a
+                       // gparam is "object" if its only constraints are other
+                       // gparams or interfaces, otherwise if it has a class
+                       // constraint that class is the BaseType.
+
+                       // A : B where B is a gparam, and A : IFace which is an
+                       // interface, so A.BaseType is object
+                       Assert.AreEqual (typeof (object), gparams[0].BaseType, "#1");
+                       // B : C where C is a gparam, so B.BaseType is object
+                       Assert.AreEqual (typeof (object), gparams[1].BaseType, "#2");
+                       // C : Duper where Duper is a class, so A.BaseType is Duper
+                       Assert.AreEqual (typeof (Duper), gparams[2].BaseType, "#3");
+                       // D : Baz<object>
+                       Assert.AreEqual (typeof (Baz<object>), gparams[3].BaseType, "#4");
                }
 
                [Test]
@@ -3619,6 +3675,38 @@ namespace MonoTests.System
                        public int field;
                }
 
+               [Test]
+               public void IsAssignableFromGenericArgumentsWithConstraints ()
+               {
+                       // Regression test for #58809
+
+                       // Generic Parameters of a gtd should have their
+                       // constraints respected even when those constraints
+                       // are other generic parameters themselves.
+
+                       var ps = typeof (GenericWithParamConstraints<,,>).GetGenericArguments ();
+
+                       var a = ps[0];
+                       var b = ps[1];
+                       var c = ps[2];
+
+                       // Foo<C>
+                       var fooOfC = typeof (Foo<>).MakeGenericType (c);
+
+                       // constraint B : Foo <C>
+                       Assert.IsTrue (fooOfC.IsAssignableFrom (b), "#1");
+
+                       // constraint A : B
+                       Assert.IsTrue (b.IsAssignableFrom (a), "#2");
+
+                       // A : Foo<C> since A : B and B : Foo<C>
+                       Assert.IsTrue (fooOfC.IsAssignableFrom (a), "#3");
+               }
+
+               class GenericWithParamConstraints<A, B, C> where B : Foo<C> where A : B
+               {
+               }
+
                [Test] // Bug #612780
                public void CannotMakeDerivedTypesFromTypedByRef ()
                {
index 9d5eb1140816690a5d1ab6c03e97b8a94935da32..262b8d33232459be06ddde9a7b9e8f9bfbd7befc 100644 (file)
@@ -1,12 +1,14 @@
 using System;
 using System.Net;
 using System.Net.Sockets;
+using System.Collections.Generic;
 
 namespace MonoTests.Helpers {
 
        public static class NetworkHelpers
        {
                static Random rndPort = new Random ();
+               static HashSet<int> portsTable = new HashSet<int> ();
 
                public static int FindFreePort ()
                {
@@ -15,17 +17,32 @@ namespace MonoTests.Helpers {
 
                public static IPEndPoint LocalEphemeralEndPoint ()
                {
-                       while (true) {
-                               var ep = new IPEndPoint (IPAddress.Loopback, rndPort.Next (10000, 60000));
-
-                               try {
-                                       using (var socket = new Socket (ep.AddressFamily, SocketType.Stream, ProtocolType.Tcp)) {
-                                               socket.Bind (ep);
-                                               socket.Close ();
-                                       }
-                                       return ep;
-                               } catch (SocketException) { }
+                       int counter = 0;
+
+                       while (counter < 1000) {
+                               var testingPort = rndPort.Next (10000, 60000);
+
+                               var ep = new IPEndPoint (IPAddress.Loopback, testingPort);
+
+                               lock (portsTable) {
+                                       if (portsTable.Contains (testingPort))
+                                               continue;
+
+                                       ++counter;
+
+                                       try {
+                                               using (var socket = new Socket (ep.AddressFamily, SocketType.Stream, ProtocolType.Tcp)) {
+                                                       socket.Bind (ep);
+                                                       socket.Close ();
+                                               }
+
+                                               portsTable.Add (testingPort);
+                                               return ep;
+                                       } catch (SocketException) { }
+                               }
                        }
+
+                       throw new ApplicationException ($"Could not find available local port after {counter} retries");
                }
        }
 }
diff --git a/mcs/tools/linker-analyzer/README.md b/mcs/tools/linker-analyzer/README.md
new file mode 100644 (file)
index 0000000..a848021
--- /dev/null
@@ -0,0 +1,125 @@
+Linker analyzer is a command line tool to analyze dependencies, which
+were recorded during linker processing, and led linker to mark an item
+to keep it in the resulting linked assembly.
+
+It works on an oriented graph of dependencies, which are collected and
+dumped during the linker run. The vertices of this graph are the items
+of interest like assemblies, types, methods, fields, linker steps,
+etc. The edges represent the dependencies.
+
+How to dump dependencies
+------------------------
+
+The linker analyzer needs a linker dependencies file as an input. It
+can be retrieved by enabling dependencies dumping during linking of a
+Xamarin.Android or a Xamarin.iOS project.
+
+That can be done on the command line by setting
+`LinkerDumpDependencies` property to `true` and building the
+project. (make sure the LinkAssemblies task is called, it might
+require cleaning the project sometimes) Usually it is enough to build
+the project like this:
+
+```msbuild /p:LinkerDumpDependencies=true /p:Configuration=Release YourAppProject.csproj```
+
+After a successful build, there will be a linker-dependencies.xml.gz
+file created, containing the information for the analyzer.
+
+How to use the analyzer
+-----------------------
+
+Let say you would like to know, why a type, Android.App.Activity for
+example, was marked by the linker. So run the analyzer like this:
+
+```mono linkeranalyzer.exe -t Android.App.Activity linker-dependencies.xml.gz```
+
+Output:
+
+```
+Loading dependency tree from: linker-dependencies.xml.gz
+
+--- Type dependencies: 'Android.App.Activity' -----------------------
+
+--- TypeDef:Android.App.Activity dependencies -----------------------
+Dependency #1
+       TypeDef:Android.App.Activity
+       | TypeDef:XA.App.MainActivity [2 deps]
+       | Assembly:XA.App, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null [3 deps]
+       | Other:Mono.Linker.Steps.ResolveFromAssemblyStep
+```
+
+The output contains dependencies string(s), starting with the type and
+continuing with the item of interest, which depends on the type. The
+dependency could be result of multiple reasons. For example the type
+was referenced from a method, or the type was listed in the linker xml
+file to be protected.
+
+In our example there is only one dependency string called `Dependency
+#1`. It shows us that the type `Android.App.Activity` was marked
+during processing of type `XA.App.MainActivity` by the linker. In this
+case because the `MainActivity` type is based on the `Activity` type
+and thus the linker marked it and kept it in the linked assembly. We
+can also see that there are 2 dependencies for the `MainActivity`
+class. Note that in the string (above) we see only 1st dependency of
+the 2, the dependency on the assembly `XA.App`. And finally the
+assembly vertex depends on the `ResolveFromAssemblyStep` vertex. So we
+see that the assembly was processed in the `ResolveFromAssembly`
+linker step.
+
+Now we might want to see the `MainActivity` dependencies. That could
+be done by the following analyzer run:
+
+```mono linkeranalyzer.exe -r TypeDef:XA.App.MainActivity linker-dependencies.xml.gz```
+
+Output:
+
+```
+Loading dependency tree from: linker-dependencies.xml.gz
+
+--- Raw dependencies: 'TypeDef:XA.App.MainActivity' -----------------
+
+--- TypeDef:XA.App.MainActivity dependencies ------------------------
+Dependency #1
+       TypeDef:XA.App.MainActivity
+       | Assembly:XA.App, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null [3 deps]
+       | Other:Mono.Linker.Steps.ResolveFromAssemblyStep
+Dependency #2
+       TypeDef:XA.App.MainActivity
+       | TypeDef:XA.App.MainActivity/<>c__DisplayClass1_0 [2 deps]
+       | TypeDef:XA.App.MainActivity [2 deps]
+       | Assembly:XA.App, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null [3 deps]
+       | Other:Mono.Linker.Steps.ResolveFromAssemblyStep
+```
+
+Known issues
+------------
+
+Sometimes the linker processing is not straight forward and the
+marking is postponed, like processing of some of the methods. They are
+queued to be processed later. In such case the dependencies are
+"interrupted" and the dependecy string for the method usually shows
+just dependency on the Mark step.
+
+Command line help
+-----------------
+```
+Usage:
+
+       linkeranalyzer [Options] <linker-dependency-file.xml.gz>
+
+Options:
+
+  -a, --alldeps              show all dependencies
+  -h, --help                 show this message and exit.
+  -r, --rawdeps=VALUE        show raw vertex dependencies. Raw vertex VALUE is
+                               in the raw format written by linker to the
+                               dependency XML file. VALUE can be regular
+                               expression
+      --roots                show root dependencies.
+      --stat                 show statistic of loaded dependencies.
+      --tree                 reduce the dependency graph to the tree.
+      --types                show all types dependencies.
+  -t, --typedeps=VALUE       show type dependencies. The VALUE can be regular
+                               expression
+  -v, --verbose              be more verbose. Enables stat and roots options.
+```
index 8680e0bbf8160f8f502a3705956eb7ebc06b88cb..d4ef1cbb5520e4f8c493fdcce14d61e2b21730f1 100755 (executable)
@@ -1009,6 +1009,7 @@ void          mono_register_config_for_assembly (const char* assembly_name, cons
                        else
                        {
                                string zlib = (compress ? "-lz" : "");
+                               string objc = (style == "osx" ? "-framework CoreFoundation -lobjc" : "");
                                string debugging = "-g";
                                string cc = GetEnv("CC", "cc");
                                string cmd = null;
@@ -1022,16 +1023,16 @@ void          mono_register_config_for_assembly (const char* assembly_name, cons
                                                smonolib = "`pkg-config --variable=libdir mono-2`/libmono-2.0.a ";
                                        else
                                                smonolib = "-Wl,-Bstatic -lmono-2.0 -Wl,-Bdynamic ";
-                                       cmd = String.Format("{4} -o '{2}' -Wall `pkg-config --cflags mono-2` {0} {3} " +
+                                       cmd = String.Format("{4} -o '{2}' -Wall {5} `pkg-config --cflags mono-2` {0} {3} " +
                                                "`pkg-config --libs-only-L mono-2` " + smonolib +
                                                "`pkg-config --libs-only-l mono-2 | sed -e \"s/\\-lmono-2.0 //\"` {1}",
-                                               temp_c, temp_o, output, zlib, cc);
+                                               temp_c, temp_o, output, zlib, cc, objc);
                                }
                                else
                                {
 
-                                       cmd = String.Format("{4} " + debugging + " -o '{2}' -Wall {0} `pkg-config --cflags --libs mono-2` {3} {1}",
-                                               temp_c, temp_o, output, zlib, cc);
+                                       cmd = String.Format("{4} " + debugging + " -o '{2}' -Wall {5} {0} `pkg-config --cflags --libs mono-2` {3} {1}",
+                                               temp_c, temp_o, output, zlib, cc, objc);
                                }
                                Execute (cmd);
                        }
index 9bd837e241fe94065b70d30a15c2d6acc82bdfb6..e322d4ef556875ee0a770cdb2808f6a371f2ef37 100644 (file)
@@ -133,10 +133,15 @@ namespace Xamarin.ApiDiff {
                        if (parameters != null) {
                                var list = new List<string> ();
                                foreach (var p in parameters.Elements ("parameter")) {
-                                       var pTypeName   = p.GetTypeName ("type");
-                                       list.Add (State.IgnoreParameterNameChanges
-                                               ? pTypeName
-                                               : pTypeName + " " + p.GetAttribute ("name"));
+                                       var param = p.GetTypeName ("type");
+                                       if (!State.IgnoreParameterNameChanges)
+                                               param += " " + p.GetAttribute ("name");
+
+                                       var direction = p.GetAttribute ("direction");
+                                       if (direction?.Length > 0)
+                                               param = direction + " " + param;
+                                               
+                                       list.Add (param);
                                }
                                sb.Append (String.Join (", ", list));
                        }
diff --git a/mcs/tools/mono-api-html/mono-api-html.sln b/mcs/tools/mono-api-html/mono-api-html.sln
new file mode 100644 (file)
index 0000000..265e4fa
--- /dev/null
@@ -0,0 +1,17 @@
+\r
+Microsoft Visual Studio Solution File, Format Version 12.00\r
+# Visual Studio 2012\r
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "mono-api-html", "mono-api-html.csproj", "{D25986E2-7A41-4966-A26D-5614BAC7B8A7}"\r
+EndProject\r
+Global\r
+       GlobalSection(SolutionConfigurationPlatforms) = preSolution\r
+               Debug|Any CPU = Debug|Any CPU\r
+               Release|Any CPU = Release|Any CPU\r
+       EndGlobalSection\r
+       GlobalSection(ProjectConfigurationPlatforms) = postSolution\r
+               {D25986E2-7A41-4966-A26D-5614BAC7B8A7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU\r
+               {D25986E2-7A41-4966-A26D-5614BAC7B8A7}.Debug|Any CPU.Build.0 = Debug|Any CPU\r
+               {D25986E2-7A41-4966-A26D-5614BAC7B8A7}.Release|Any CPU.ActiveCfg = Release|Any CPU\r
+               {D25986E2-7A41-4966-A26D-5614BAC7B8A7}.Release|Any CPU.Build.0 = Release|Any CPU\r
+       EndGlobalSection\r
+EndGlobal\r
index 869365b4bccd9b3d93d99dd1184dfbc049253d8f..98fed7525fb2937dea3a7cc334c33c026d596503 100644 (file)
@@ -333,7 +333,7 @@ my and Ximian's copyright to this code. ;)
 #define ppc_andid(c,S,A,ui) ppc_emit32(c, (28 << 26) | ((S) << 21 ) | ((A) << 16) | ((guint16)(ui)))
 #define ppc_andisd(c,S,A,ui) ppc_emit32(c, (29 << 26) | ((S) << 21 ) | ((A) << 16) | ((guint16)(ui)))
 
-#define ppc_bcx(c,BO,BI,BD,AA,LK) ppc_emit32(c, (16 << 26) | (BO << 21 )| (BI << 16) | (BD << 2) | ((AA) << 1) | LK)
+#define ppc_bcx(c,BO,BI,BD,AA,LK) ppc_emit32(c, (16 << 26) | ((BO) << 21 )| ((BI) << 16) | (BD << 2) | ((AA) << 1) | LK)
 #define ppc_bc(c,BO,BI,BD) ppc_bcx(c,BO,BI,BD,0,0) 
 #define ppc_bca(c,BO,BI,BD) ppc_bcx(c,BO,BI,BD,1,0)
 #define ppc_bcl(c,BO,BI,BD) ppc_bcx(c,BO,BI,BD,0,1)
index 2b3a0b42aa31a9359c2bd01ed41803e6beda8942..e3d9e18741752ec88e7136cda18776ea7d25c736 100644 (file)
@@ -27,6 +27,7 @@ extern gboolean mono_align_small_structs;
 typedef struct _MonoMethodWrapper MonoMethodWrapper;
 typedef struct _MonoMethodInflated MonoMethodInflated;
 typedef struct _MonoMethodPInvoke MonoMethodPInvoke;
+typedef struct _MonoDynamicMethod MonoDynamicMethod;
 
 /* Properties that applies to a group of structs should better use a higher number
  * to avoid colision with type specific properties.
@@ -100,6 +101,11 @@ struct _MonoMethodWrapper {
        void *method_data;
 };
 
+struct _MonoDynamicMethod {
+       MonoMethodWrapper method;
+       MonoAssembly *assembly;
+};
+
 struct _MonoMethodPInvoke {
        MonoMethod method;
        gpointer addr;
@@ -1170,6 +1176,8 @@ GENERATE_GET_CLASS_WITH_CACHE_DECL (variant)
 
 #endif
 
+GENERATE_GET_CLASS_WITH_CACHE_DECL (appdomain_unloaded_exception)
+
 extern MonoDefaults mono_defaults;
 
 void
index 8df8cb531d4a88faed3a3591ff7afbd5a3a88453..e1539de106cd4bb92eaa32c27f30e5795facc6cd 100644 (file)
@@ -1513,6 +1513,7 @@ mono_class_set_type_load_failure_causedby_class (MonoClass *klass, const MonoCla
  * Sets the following fields in \p klass:
  *  - all the fields initialized by mono_class_init_sizes ()
  *  - element_class/cast_class (for enums)
+ *  - sizes:element_size (for arrays)
  *  - field->type/offset for all fields
  *  - fields_inited
  *
@@ -1772,6 +1773,7 @@ mono_class_layout_fields (MonoClass *klass, int base_instance_size, int packing_
        MonoClassField *field;
        gboolean blittable;
        int instance_size = base_instance_size;
+       int element_size = -1;
        int class_size, min_align;
        int *field_offsets;
        gboolean *fields_has_references;
@@ -2101,6 +2103,9 @@ mono_class_layout_fields (MonoClass *klass, int base_instance_size, int packing_
        else if (klass->byval_arg.type == MONO_TYPE_PTR)
                instance_size = sizeof (MonoObject) + sizeof (gpointer);
 
+       if (klass->byval_arg.type == MONO_TYPE_SZARRAY || klass->byval_arg.type == MONO_TYPE_ARRAY)
+               element_size = mono_class_array_element_size (klass->element_class);
+
        /* Publish the data */
        mono_loader_lock ();
        if (klass->instance_size && !klass->image->dynamic) {
@@ -2131,6 +2136,9 @@ mono_class_layout_fields (MonoClass *klass, int base_instance_size, int packing_
                        klass->fields [i].offset = field_offsets [i];
        }
 
+       if (klass->byval_arg.type == MONO_TYPE_SZARRAY || klass->byval_arg.type == MONO_TYPE_ARRAY)
+               klass->sizes.element_size = element_size;
+
        mono_memory_barrier ();
        klass->size_inited = 1;
        mono_loader_unlock ();
@@ -2918,6 +2926,10 @@ collect_implemented_interfaces_aux (MonoClass *klass, GPtrArray **res, GHashTabl
                        *ifaces = g_hash_table_new (NULL, NULL);
                if (g_hash_table_lookup (*ifaces, ic))
                        continue;
+               /* A gparam is not an implemented interface for the purposes of
+                * mono_class_get_implemented_interfaces */
+               if (mono_class_is_gparam (ic))
+                       continue;
                g_ptr_array_add (*res, ic);
                g_hash_table_insert (*ifaces, ic, ic);
                mono_class_init (ic);
@@ -3308,7 +3320,9 @@ setup_interface_offsets (MonoClass *klass, int cur_slot, gboolean overwrite)
                for (i = 0; i < k->interface_count; i++) {
                        ic = k->interfaces [i];
 
-                       mono_class_init (ic);
+                       /* A gparam does not have any interface_id set. */
+                       if (! mono_class_is_gparam (ic))
+                               mono_class_init (ic);
 
                        if (max_iid < ic->interface_id)
                                max_iid = ic->interface_id;
@@ -4880,7 +4894,7 @@ mono_class_init (MonoClass *klass)
        GSList *init_list = (GSList *)mono_native_tls_get_value (init_pending_tls_id);
        if (g_slist_find (init_list, klass)) {
                mono_class_set_type_load_failure (klass, "Recursive type definition detected");
-               goto leave;
+               goto leave_no_init_pending;
        }
        init_list = g_slist_prepend (init_list, klass);
        mono_native_tls_set_value (init_pending_tls_id, init_list);
@@ -5079,10 +5093,12 @@ mono_class_init (MonoClass *klass)
 
        goto leave;
 
- leave:
+leave:
+       init_list = mono_native_tls_get_value (init_pending_tls_id);
        init_list = g_slist_remove (init_list, klass);
        mono_native_tls_set_value (init_pending_tls_id, init_list);
 
+leave_no_init_pending:
        if (locked)
                mono_loader_unlock ();
 
@@ -6596,7 +6612,7 @@ mono_bounded_array_class_get (MonoClass *eclass, guint32 rank, gboolean bounded)
                /* element_size -1 is ok as this is not an instantitable type*/
                klass->sizes.element_size = -1;
        } else
-               klass->sizes.element_size = mono_class_array_element_size (eclass);
+               klass->sizes.element_size = -1;
 
        mono_class_setup_supertypes (klass);
 
@@ -8210,22 +8226,31 @@ mono_class_is_assignable_from (MonoClass *klass, MonoClass *oklass)
                return mono_gparam_is_assignable_from (klass, oklass);
        }
 
-       if (MONO_CLASS_IS_INTERFACE (klass)) {
-               if ((oklass->byval_arg.type == MONO_TYPE_VAR) || (oklass->byval_arg.type == MONO_TYPE_MVAR)) {
-                       MonoGenericParam *gparam = oklass->byval_arg.data.generic_param;
-                       MonoClass **constraints = mono_generic_container_get_param_info (gparam->owner, gparam->num)->constraints;
-                       int i;
+       /* This can happen if oklass is a tyvar that has a constraint which is another tyvar which in turn
+        * has a constraint which is a class type:
+        *
+        *  class Foo { }
+        *  class G<T1, T2> where T1 : T2 where T2 : Foo { }
+        *
+        * In this case, Foo is assignable from T1.
+        */
+       if ((oklass->byval_arg.type == MONO_TYPE_VAR) || (oklass->byval_arg.type == MONO_TYPE_MVAR)) {
+               MonoGenericParam *gparam = oklass->byval_arg.data.generic_param;
+               MonoClass **constraints = mono_generic_container_get_param_info (gparam->owner, gparam->num)->constraints;
+               int i;
 
-                       if (constraints) {
-                               for (i = 0; constraints [i]; ++i) {
-                                       if (mono_class_is_assignable_from (klass, constraints [i]))
-                                               return TRUE;
-                               }
+               if (constraints) {
+                       for (i = 0; constraints [i]; ++i) {
+                               if (mono_class_is_assignable_from (klass, constraints [i]))
+                                       return TRUE;
                        }
-
-                       return FALSE;
                }
 
+               return mono_class_has_parent (oklass, klass);
+       }
+
+       if (MONO_CLASS_IS_INTERFACE (klass)) {
+
                /* interface_offsets might not be set for dynamic classes */
                if (mono_class_get_ref_info_handle (oklass) && !oklass->interface_bitmap) {
                        /* 
@@ -8634,11 +8659,16 @@ handle_enum:
  * \param ac pointer to a \c MonoArrayClass
  *
  * \returns The size of single array element.
+ *
+ * LOCKING: Acquires the loader lock.
  */
 gint32
 mono_array_element_size (MonoClass *ac)
 {
        g_assert (ac->rank);
+       if (G_UNLIKELY (!ac->size_inited)) {
+               mono_class_setup_fields (ac);
+       }
        return ac->sizes.element_size;
 }
 
index f79cd9bff99e928cd3b8c9834b69311126c43fcd..565dac59e4f215b0ac4c2dd7a5abf35b10b62195 100644 (file)
@@ -45,6 +45,7 @@ mono_class_from_typeref    (MonoImage *image, uint32_t type_token);
 MONO_API MonoClass *
 mono_class_from_typeref_checked (MonoImage *image, uint32_t type_token, MonoError *error);
 
+MONO_RT_EXTERNAL_ONLY
 MONO_API MonoClass *
 mono_class_from_generic_parameter (MonoGenericParam *param, MonoImage *image, mono_bool is_mvar);
 
index 4d8cab37139d108d86dc723fcd8c0eb72b798b86..15ee88d5ccbf6f966af4f5bb8825d3f2b2d0f2d3 100644 (file)
@@ -352,1311 +352,1311 @@ static const DateTimeFormatEntry datetime_format_entries [] = {
 
 
 static const NumberFormatEntry number_format_entries [] = {
-       {11, 1264, 11, 1264, 1266, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1331, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1363, 1372, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1380, 1337, 1339, 1296, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1380, 1337, 1339, 1296, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1383, 1337, 0, 1343, 1387, 1399, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1411, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1415, 1426, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1437, 1451, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 0, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1466, 1476, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1485, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1513, 1337, 1339, 1343, 1347, 1311, 55, 1517, 2, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1522, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1525, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1466, 1529, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1539, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1543, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1296, 1547, 1557, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 0, 1276, 1339, 1296, 1347, 1311, 55, 1324, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1566, 1337, 1339, 1343, 1570, 1589, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1608, 1337, 1339, 1343, 1466, 1529, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1611, 11, 1611, 1615, 1337, 1339, 1343, 1619, 1628, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1637, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1641, 1337, 1645, 1343, 1662, 1690, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1717, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1387, 1399, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1720, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 1328, 1726, 1337, 1729, 1736, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1742, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1746, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 2, 2, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1750, 1337, 1339, 1343, 1753, 1311, 1769, 1777, 3, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1785, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1788, 1337, 1339, 1343, 1347, 1311, 55, 1357, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1792, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1795, 1811, 1824, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1828, 1343, 1831, 1843, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {2, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1854, 1865, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 0, 1337, 0, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1, 1264, 1, 1264, 1875, 1494, 0, 1296, 1347, 1311, 55, 1357, 3, 0, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1884, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1888, 1337, 1891, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 0, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1898, 1908, 55, 1357, 8, 3, 7, 3, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1917, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1328, 11, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1924, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1926, 1337, 1930, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1726, 1337, 1339, 1343, 1347, 1311, 55, 1357, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1729, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1975, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1978, 1337, 1982, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1999, 1337, 2006, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2023, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2027, 1337, 2031, 1343, 1347, 1311, 55, 1357, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 0, 1494, 2041, 1296, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2060, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 1, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 0, 1494, 1339, 1296, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 2, 2, 1, 2, 2, {3, -1}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
-       {2067, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 0, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1380, 1337, 1339, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, 0}, {3, -1}},
-       {11, 1264, 11, 1264, 2069, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2072, 1337, 1339, 1343, 1347, 1311, 55, 1357, 5, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2076, 1337, 2080, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2126, 1337, 2128, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 2168, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 0, 1337, 1339, 1343, 1347, 1311, 55, 1357, 0, 0, 1, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2176, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 1, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 0, 1337, 0, 1343, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2183, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, 2}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 11, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2190, 1494, 1339, 1296, 1753, 1311, 1769, 1777, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2193, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 0, 1337, 0, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 0, 1337, 0, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2197, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1328, 11, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1411, 1337, 1729, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 0}, {3, -1}},
-       {11, 1264, 11, 1264, 2197, 1337, 1339, 1296, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1792, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2201, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2205, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1380, 1337, 0, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 0, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1539, 1337, 1339, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1641, 1337, 2207, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2236, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2069, 1494, 1339, 1296, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1266, 1494, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1331, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1363, 1372, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 2239, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1383, 1337, 0, 1343, 1387, 1399, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1411, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1415, 1426, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1437, 1451, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 0, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1485, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1513, 1337, 1339, 1343, 1347, 1311, 55, 1517, 2, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1522, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1525, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1466, 1529, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1539, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1543, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1296, 1547, 1557, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1726, 1276, 1339, 1296, 1347, 1311, 55, 1324, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1566, 1337, 1339, 1343, 1570, 1589, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1608, 1337, 1339, 1343, 1466, 1529, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1611, 11, 1611, 1615, 1337, 1339, 1343, 1619, 1628, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1637, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1641, 1337, 1645, 1343, 1662, 1690, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2249, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1387, 1399, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1720, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 1328, 1726, 1337, 1729, 1736, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1742, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1746, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 2, 2, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1750, 1337, 1339, 1343, 1753, 1311, 1769, 1777, 3, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1785, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1788, 1337, 1339, 1343, 1347, 1311, 55, 1357, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1792, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1795, 1811, 1824, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1828, 1343, 1831, 1843, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {2, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1854, 1865, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1999, 1337, 0, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1, 1264, 1, 1264, 1875, 1494, 0, 1296, 1347, 1311, 55, 1357, 3, 0, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1884, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1888, 1337, 1891, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2253, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1898, 1908, 55, 1357, 8, 3, 7, 3, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1917, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1328, 11, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1924, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1926, 1337, 1930, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1726, 1337, 1339, 1343, 1347, 1311, 55, 1357, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1726, 1337, 1729, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1975, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1978, 1337, 1982, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1999, 1337, 2006, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2023, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2027, 1337, 2031, 1343, 1347, 1311, 55, 1357, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2257, 1494, 2041, 1296, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 1, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 2, 2, 1, 2, 2, {3, -1}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
-       {2067, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 2263, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1380, 1337, 1339, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, 0}, {3, -1}},
-       {11, 1264, 11, 1264, 2069, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2072, 1337, 1339, 1343, 1347, 1311, 55, 1357, 5, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2076, 1337, 2080, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2126, 1337, 2128, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1971, 1337, 0, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 2168, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2176, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 1, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2267, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, 2}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 11, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2190, 1494, 1339, 1296, 1753, 1311, 1769, 1777, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2193, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2197, 1337, 0, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2197, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1328, 11, 1328, 1924, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1411, 1337, 1729, 1343, 1347, 1311, 55, 1357, 12, 2, 0, 0, 1, 2, 2, {3, 0}, {3, -1}},
-       {11, 1264, 11, 1264, 2197, 1337, 1339, 1296, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1792, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1792, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2205, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1380, 1337, 0, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 0, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1539, 1337, 1339, 1343, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1641, 1337, 2207, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2236, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2069, 1494, 1339, 1296, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2280, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1363, 1372, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1539, 1337, 1339, 1296, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 2290, 11, 2290, 1615, 1337, 1339, 1343, 1415, 1426, 55, 1357, 2, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2069, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 2290, 11, 2290, 1615, 1337, 1339, 1343, 1466, 1529, 55, 1357, 2, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 1328, 1359, 1337, 1339, 1296, 1547, 1557, 55, 1357, 12, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1726, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1339, 1343, 1466, 1529, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2292, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2292, 1337, 1645, 1343, 1662, 1690, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1729, 1736, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1753, 1311, 1769, 1777, 1, 0, 1, 2, 1, 2, 2, {3, 2}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2253, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1328, 11, 1328, 2294, 1337, 0, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 1328, 1726, 1337, 1729, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2296, 1494, 2303, 1296, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2336, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 1, 0, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 2340, 1494, 1339, 1296, 1347, 1311, 55, 1517, 9, 2, 9, 3, 2, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2343, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2201, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2347, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2357, 1337, 2239, 1343, 1347, 1311, 55, 1357, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1415, 1426, 55, 1357, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1466, 1476, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1464, 1494, 1339, 1296, 1497, 1505, 55, 1357, 15, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 1729, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2361, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 0, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1296, 1347, 1311, 55, 1357, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1415, 1426, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2371, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1328, 11, 1328, 1615, 1494, 1339, 1296, 1497, 1505, 55, 1357, 2, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2373, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2376, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2386, 1337, 2239, 1343, 1347, 1311, 55, 1357, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 2290, 11, 2290, 1615, 1337, 1339, 1343, 1415, 1426, 55, 1357, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2391, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2373, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2395, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2405, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2373, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2409, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1924, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2419, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2423, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2428, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2438, 1337, 1339, 1343, 1466, 1476, 55, 1357, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2423, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2442, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2452, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2455, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 2459, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2467, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2477, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2480, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2455, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2484, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2494, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2499, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2480, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2509, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2193, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 2, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2480, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2519, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2529, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2533, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2357, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2543, 1337, 1339, 1343, 1466, 1476, 55, 1357, 12, 2, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2547, 1494, 1339, 1296, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2549, 1276, 1281, 1296, 1299, 1311, 1320, 1324, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1971, 1337, 1339, 1343, 1347, 1311, 55, 1357, 12, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
-       {1264, 11, 1264, 11, 2559, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1975, 1337, 1339, 1343, 1347, 1311, 55, 1357, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1347, 1311, 55, 1357, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2292, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2562, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1464, 1337, 1339, 1343, 1466, 1476, 55, 1357, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2423, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2373, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2565, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2573, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1359, 1337, 2459, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2253, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 1380, 1337, 1339, 1296, 1347, 1311, 55, 1357, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1726, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2373, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2253, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2296, 1494, 2303, 1296, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2263, 1337, 1339, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2357, 1337, 2239, 1343, 1347, 1311, 55, 1357, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2357, 1337, 2239, 1343, 1347, 1311, 55, 1357, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1726, 1276, 1339, 1296, 1347, 1311, 55, 1324, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 2573, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 1999, 1337, 0, 1343, 1347, 1311, 55, 1357, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 11, 1264, 11, 1359, 1337, 1339, 1343, 1347, 1311, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 2257, 1494, 2041, 1296, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2340, 1494, 1339, 1296, 1347, 1311, 55, 1517, 9, 2, 9, 3, 2, 2, 2, {3, -1}, {3, -1}},
-       {1264, 1328, 1264, 1328, 0, 1337, 0, 1343, 1497, 1505, 55, 1357, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
-       {11, 1264, 11, 1264, 2197, 1337, 0, 1343, 1347, 1311, 55, 1357, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}}
+       {11, 1264, 11, 1264, 1266, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1325, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1347, 1356, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1364, 1331, 1333, 1296, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1364, 1331, 1333, 1296, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1367, 1331, 0, 1337, 1371, 1383, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1395, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1399, 1410, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1421, 1435, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 0, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1450, 1460, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1469, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1497, 1331, 1333, 1337, 1299, 1309, 55, 1501, 2, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1506, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1509, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1450, 1513, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1523, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1527, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1296, 1531, 1541, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 0, 1276, 1333, 1296, 1299, 1309, 55, 1318, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1550, 1331, 1333, 1337, 1554, 1573, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1592, 1331, 1333, 1337, 1450, 1513, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1595, 11, 1595, 1599, 1331, 1333, 1337, 1603, 1612, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1621, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1625, 1331, 1629, 1337, 1646, 1674, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1701, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1371, 1383, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1704, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 1322, 1710, 1331, 1713, 1720, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1726, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1730, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 2, 2, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1734, 1331, 1333, 1337, 1299, 1309, 55, 1737, 3, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1745, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1748, 1331, 1333, 1337, 1299, 1309, 55, 1341, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1752, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1755, 1769, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1782, 1337, 1785, 1797, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {2, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1808, 1819, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 0, 1331, 0, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1, 1264, 1, 1264, 1829, 1478, 0, 1296, 1299, 1309, 55, 1341, 3, 0, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1838, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1842, 1331, 1845, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 0, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1852, 1862, 55, 1341, 8, 3, 7, 3, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1871, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1322, 11, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1878, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1880, 1331, 1884, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1710, 1331, 1333, 1337, 1299, 1309, 55, 1341, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1713, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1929, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1932, 1331, 1936, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1953, 1331, 1960, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1977, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1981, 1331, 1985, 1337, 1299, 1309, 55, 1341, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 0, 1478, 1995, 1296, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2014, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 1, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 0, 1478, 1333, 1296, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 2, 2, 1, 2, 2, {3, -1}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
+       {2021, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 0, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1364, 1331, 1333, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, 0}, {3, -1}},
+       {11, 1264, 11, 1264, 2023, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2026, 1331, 1333, 1337, 1299, 1309, 55, 1341, 5, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2030, 1331, 2034, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2080, 1331, 2082, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 2122, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 0, 1331, 1333, 1337, 1299, 1309, 55, 1341, 0, 0, 1, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2130, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 1, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 0, 1331, 0, 1337, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2137, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, 2}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 11, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2144, 1478, 1333, 1296, 1299, 1309, 55, 1737, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2147, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 0, 1331, 0, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 0, 1331, 0, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2151, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1322, 11, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1395, 1331, 1713, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 0}, {3, -1}},
+       {11, 1264, 11, 1264, 2151, 1331, 1333, 1296, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1752, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2155, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2159, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1364, 1331, 0, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 0, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1523, 1331, 1333, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1625, 1331, 2161, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2190, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2023, 1478, 1333, 1296, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1266, 1478, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1325, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1347, 1356, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 2193, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1367, 1331, 0, 1337, 1371, 1383, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1395, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1399, 1410, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1421, 1435, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 0, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1469, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1497, 1331, 1333, 1337, 1299, 1309, 55, 1501, 2, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1506, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1509, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1450, 1513, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1523, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1527, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1296, 1531, 1541, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1710, 1276, 1333, 1296, 1299, 1309, 55, 1318, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1550, 1331, 1333, 1337, 1554, 1573, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1592, 1331, 1333, 1337, 1450, 1513, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1595, 11, 1595, 1599, 1331, 1333, 1337, 1603, 1612, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1621, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1625, 1331, 1629, 1337, 1646, 1674, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2203, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1371, 1383, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1704, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 1322, 1710, 1331, 1713, 1720, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1726, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1730, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 2, 2, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1734, 1331, 1333, 1337, 1299, 1309, 55, 1737, 3, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1745, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1748, 1331, 1333, 1337, 1299, 1309, 55, 1341, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1752, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1755, 1769, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1782, 1337, 1785, 1797, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {2, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1808, 1819, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1953, 1331, 0, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1, 1264, 1, 1264, 1829, 1478, 0, 1296, 1299, 1309, 55, 1341, 3, 0, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1838, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1842, 1331, 1845, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2207, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1852, 1862, 55, 1341, 8, 3, 7, 3, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1871, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1322, 11, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1878, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1880, 1331, 1884, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1710, 1331, 1333, 1337, 1299, 1309, 55, 1341, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1710, 1331, 1713, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1929, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1932, 1331, 1936, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1953, 1331, 1960, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1977, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1981, 1331, 1985, 1337, 1299, 1309, 55, 1341, 5, 1, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2211, 1478, 1995, 1296, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 1, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 2, 2, 1, 2, 2, {3, -1}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
+       {2021, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 2217, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1364, 1331, 1333, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, 0}, {3, -1}},
+       {11, 1264, 11, 1264, 2023, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2026, 1331, 1333, 1337, 1299, 1309, 55, 1341, 5, 1, 1, 1, 2, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2030, 1331, 2034, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2080, 1331, 2082, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1925, 1331, 0, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 2122, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2130, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 1, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2221, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, 2}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 11, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2144, 1478, 1333, 1296, 1299, 1309, 55, 1737, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2147, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2151, 1331, 0, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2151, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1322, 11, 1322, 1878, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1395, 1331, 1713, 1337, 1299, 1309, 55, 1341, 12, 2, 0, 0, 1, 2, 2, {3, 0}, {3, -1}},
+       {11, 1264, 11, 1264, 2151, 1331, 1333, 1296, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1752, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1752, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2159, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1364, 1331, 0, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 0, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1523, 1331, 1333, 1337, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1625, 1331, 2161, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2190, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2023, 1478, 1333, 1296, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2234, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1347, 1356, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1523, 1331, 1333, 1296, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 2244, 11, 2244, 1599, 1331, 1333, 1337, 1399, 1410, 55, 1341, 2, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2023, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 2244, 11, 2244, 1599, 1331, 1333, 1337, 1450, 1513, 55, 1341, 2, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 1322, 1343, 1331, 1333, 1296, 1531, 1541, 55, 1341, 12, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1710, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1333, 1337, 1450, 1513, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2246, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2246, 1331, 1629, 1337, 1646, 1674, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1713, 1720, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1737, 1, 0, 1, 2, 1, 2, 2, {3, 2}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2207, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1322, 11, 1322, 2248, 1331, 0, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 1322, 1710, 1331, 1713, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2250, 1478, 2257, 1296, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2290, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 1, 0, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 2294, 1478, 1333, 1296, 1299, 1309, 55, 1501, 9, 2, 9, 3, 2, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2297, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2155, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2301, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2311, 1331, 2193, 1337, 1299, 1309, 55, 1341, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1399, 1410, 55, 1341, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1450, 1460, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1448, 1478, 1333, 1296, 1481, 1489, 55, 1341, 15, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 1713, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2315, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 0, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1296, 1299, 1309, 55, 1341, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1399, 1410, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2325, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1322, 11, 1322, 1599, 1478, 1333, 1296, 1481, 1489, 55, 1341, 2, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2327, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2330, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2340, 1331, 2193, 1337, 1299, 1309, 55, 1341, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 2244, 11, 2244, 1599, 1331, 1333, 1337, 1399, 1410, 55, 1341, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2345, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2327, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2349, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2359, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2327, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2363, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1878, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2373, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2377, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2382, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2392, 1331, 1333, 1337, 1450, 1460, 55, 1341, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2377, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2396, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2406, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2409, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 2413, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2421, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2431, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2434, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2409, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2438, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2448, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2453, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 2, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2434, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2463, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2147, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 2, 0, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2434, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2473, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2483, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2487, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 3, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2311, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2497, 1331, 1333, 1337, 1450, 1460, 55, 1341, 12, 2, 0, 0, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2501, 1478, 1333, 1296, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2503, 1276, 1281, 1296, 1299, 1309, 55, 1318, 3, 2, 0, 0, 3, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1925, 1331, 1333, 1337, 1299, 1309, 55, 1341, 12, 2, 1, 1, 1, 2, 2, {3, 2}, {3, 2}},
+       {1264, 11, 1264, 11, 2513, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1929, 1331, 1333, 1337, 1299, 1309, 55, 1341, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1299, 1309, 55, 1341, 1, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2246, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2516, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1448, 1331, 1333, 1337, 1450, 1460, 55, 1341, 1, 0, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2377, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2327, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2519, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2527, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1343, 1331, 2413, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2207, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 1364, 1331, 1333, 1296, 1299, 1309, 55, 1341, 2, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1710, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2327, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2207, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2250, 1478, 2257, 1296, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2217, 1331, 1333, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2311, 1331, 2193, 1337, 1299, 1309, 55, 1341, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2311, 1331, 2193, 1337, 1299, 1309, 55, 1341, 0, 0, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1710, 1276, 1333, 1296, 1299, 1309, 55, 1318, 9, 2, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 2527, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 1953, 1331, 0, 1337, 1299, 1309, 55, 1341, 8, 3, 1, 1, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 11, 1264, 11, 1343, 1331, 1333, 1337, 1299, 1309, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 2211, 1478, 1995, 1296, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 0, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2294, 1478, 1333, 1296, 1299, 1309, 55, 1501, 9, 2, 9, 3, 2, 2, 2, {3, -1}, {3, -1}},
+       {1264, 1322, 1264, 1322, 0, 1331, 0, 1337, 1481, 1489, 55, 1341, 8, 3, 0, 0, 1, 2, 2, {3, -1}, {3, -1}},
+       {11, 1264, 11, 1264, 2151, 1331, 0, 1337, 1299, 1309, 55, 1341, 9, 2, 1, 1, 1, 2, 2, {3, -1}, {3, -1}}
 };
 
 
 static const CultureInfoEntry culture_entries [] = {
-       {0x0001, 0x007F, 768, -1, 2578, 2581, 2588, 2603, 2607, 2578, 0, {0, 0, 36669, 0}, 0, 0, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x0002, 0x007F, 257, -1, 2611, 2614, 2624, 2643, 2647, 2611, 0, {36697, 0, 0, 0}, 1, 1, { 1251, 21025, 10007, 866, 0, ';' }},
-       {0x0003, 0x007F, 257, -1, 2651, 2654, 2662, 2670, 2674, 2651, 0, {36739, 0, 0, 0}, 2, 2, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0004, 0x7804, 257, -1, 2678, 2686, 2707, 2714, 2718, 2722, 0, {36759, 0, 0, 0}, 3, 3, { 936, 500, 10008, 936, 0, ',' }},
-       {0x0004, 0x0004, 257, -1, 2725, 2732, 2707, 2714, 2718, 2722, 0, {36759, 0, 0, 0}, 4, 4, { 936, 500, 10008, 936, 0, ',' }},
-       {0x0005, 0x007F, 257, -1, 2760, 2763, 2769, 2779, 2783, 2760, 0, {36766, 0, 0, 0}, 5, 5, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x0006, 0x007F, 257, -1, 2787, 2790, 2797, 2803, 2807, 2787, 0, {36792, 0, 0, 0}, 6, 6, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x0007, 0x007F, 257, -1, 2811, 2814, 2821, 2829, 2833, 2811, 0, {36813, 0, 0, 0}, 7, 7, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x0008, 0x007F, 257, -1, 2837, 2840, 2846, 2863, 2867, 2837, 0, {36838, 0, 0, 0}, 8, 8, { 1253, 20273, 10006, 737, 0, ';' }},
-       {0x0009, 0x007F, 257, -1, 2871, 2874, 2874, 2882, 2886, 2871, 0, {36880, 0, 0, 0}, 9, 9, { 1252, 37, 10000, 437, 0, ',' }},
-       {0x000A, 0x007F, 257, -1, 2890, 2893, 2901, 2910, 2914, 2890, 0, {36899, 0, 0, 0}, 10, 10, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x000B, 0x007F, 257, -1, 2918, 2921, 2929, 2935, 2939, 2918, 0, {36921, 0, 0, 0}, 11, 11, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x000C, 0x007F, 257, -1, 2943, 2946, 2953, 2963, 2967, 2943, 0, {36946, 0, 0, 0}, 12, 12, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x000D, 0x007F, 257, -1, 2971, 2974, 2981, 2992, 2996, 2971, 0, {36968, 0, 0, 0}, 13, 13, { 1255, 500, 10005, 862, 1, ',' }},
-       {0x000E, 0x007F, 257, -1, 3000, 3003, 3013, 3020, 3024, 3000, 0, {37005, 0, 0, 0}, 14, 14, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x000F, 0x007F, 257, -1, 3028, 3031, 3041, 3051, 3055, 3028, 0, {37021, 0, 0, 0}, 15, 15, { 1252, 20871, 10079, 850, 0, ';' }},
-       {0x0010, 0x007F, 257, -1, 3059, 3062, 3070, 3079, 3083, 3059, 0, {37041, 0, 0, 0}, 16, 16, { 1252, 20280, 10000, 850, 0, ';' }},
-       {0x0011, 0x007F, 257, -1, 3087, 3090, 3099, 3109, 3113, 3087, 0, {37063, 0, 0, 0}, 17, 17, { 932, 20290, 10001, 932, 0, ',' }},
-       {0x0012, 0x007F, 257, -1, 3117, 3120, 3127, 3137, 3141, 3117, 0, {37090, 0, 0, 0}, 18, 18, { 949, 20833, 10003, 949, 0, ',' }},
-       {0x0013, 0x007F, 257, -1, 3145, 3148, 3154, 3165, 3169, 3145, 0, {37097, 0, 0, 0}, 19, 19, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0014, 0x007F, 257, -1, 3173, 3176, 3186, 3192, 3196, 3200, 0, {36792, 0, 0, 0}, 20, 20, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x0015, 0x007F, 257, -1, 3203, 3206, 3213, 3220, 3224, 3203, 0, {37119, 0, 0, 0}, 21, 21, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0016, 0x007F, 257, -1, 3228, 3231, 3242, 3253, 3257, 3228, 0, {37143, 0, 0, 0}, 22, 22, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0017, 0x007F, 257, -1, 3261, 3264, 3272, 3282, 3286, 3261, 0, {37166, 0, 0, 0}, 23, 23, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x0018, 0x007F, 257, -1, 3290, 3293, 3302, 3311, 3315, 3290, 0, {37186, 0, 0, 0}, 24, 24, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0019, 0x007F, 257, -1, 3319, 3322, 3330, 3345, 3349, 3319, 0, {37205, 0, 0, 0}, 25, 25, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x001A, 0x007F, 257, -1, 3353, 3356, 3365, 3374, 3378, 3353, 0, {37251, 0, 0, 0}, 26, 26, { 1250, 500, 10082, 852, 0, ';' }},
-       {0x001B, 0x007F, 257, -1, 3382, 3385, 3392, 3404, 3408, 3382, 0, {37274, 0, 0, 0}, 27, 27, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x001C, 0x007F, 257, -1, 3412, 3415, 3424, 3430, 3434, 3412, 0, {37298, 0, 0, 0}, 28, 28, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x001D, 0x007F, 257, -1, 3438, 3441, 3449, 3457, 3461, 3438, 0, {36792, 0, 0, 0}, 29, 29, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x001E, 0x007F, 512, -1, 3465, 3468, 3473, 3483, 3487, 3465, 0, {0, 37317, 0, 0}, 30, 30, { 874, 20838, 10021, 874, 0, ',' }},
-       {0x001F, 0x007F, 257, -1, 3491, 3494, 3502, 3511, 3515, 3491, 0, {37348, 0, 0, 0}, 31, 31, { 1254, 20905, 10081, 857, 0, ';' }},
-       {0x0020, 0x007F, 257, -1, 3519, 3522, 3527, 3536, 3540, 3519, 0, {37362, 0, 0, 0}, 32, 32, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x0021, 0x007F, 257, -1, 3544, 3547, 3558, 3568, 3572, 3544, 0, {37392, 0, 0, 0}, 33, 33, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0022, 0x007F, 257, -1, 3576, 3579, 3589, 3610, 3614, 3576, 0, {37411, 0, 0, 0}, 34, 34, { 1251, 500, 10017, 866, 0, ';' }},
-       {0x0023, 0x007F, 257, -1, 3618, 3621, 3632, 3653, 3657, 3618, 0, {37457, 0, 0, 0}, 35, 35, { 1251, 500, 10007, 866, 0, ';' }},
-       {0x0024, 0x007F, 257, -1, 3661, 3664, 3674, 3688, 3692, 3661, 0, {37499, 0, 0, 0}, 36, 36, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0025, 0x007F, 257, -1, 3696, 3699, 3708, 3714, 3718, 3696, 0, {37521, 0, 0, 0}, 37, 37, { 1257, 500, 10029, 775, 0, ';' }},
-       {0x0026, 0x007F, 257, -1, 3722, 3725, 3733, 3743, 3747, 3722, 0, {37541, 0, 0, 0}, 38, 38, { 1257, 500, 10029, 775, 0, ';' }},
-       {0x0027, 0x007F, 257, -1, 3751, 3754, 3765, 3775, 3779, 3751, 0, {37560, 0, 0, 0}, 39, 39, { 1257, 500, 10029, 775, 0, ';' }},
-       {0x0028, 0x007F, 257, -1, 3783, 3786, 3792, 3805, 3809, 3783, 0, {0, 0, 0, 0}, 40, 40, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0029, 0x007F, 257, -1, 3813, 3816, 3824, 3835, 3839, 3813, 0, {37583, 0, 0, 0}, 41, 41, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x002A, 0x007F, 257, -1, 3843, 3846, 3857, 3872, 3876, 3843, 0, {37607, 0, 0, 0}, 42, 42, { 1258, 500, 10000, 1258, 0, ',' }},
-       {0x002B, 0x007F, 257, -1, 3880, 3883, 3892, 3907, 3911, 3880, 0, {37622, 0, 0, 0}, 43, 43, { 0, 500, 2, 1, 0, ',' }},
-       {0x002C, 0x007F, 257, -1, 3915, 3918, 3930, 3942, 3946, 3915, 0, {37652, 0, 0, 0}, 44, 44, { 1254, 20905, 10081, 857, 0, ';' }},
-       {0x002D, 0x007F, 257, -1, 3950, 3953, 3960, 3968, 3972, 3950, 0, {37671, 0, 0, 0}, 45, 45, { 1252, 500, 2, 850, 0, ';' }},
-       {0x002E, 0x007F, 257, -1, 3976, 3980, 3994, 4012, 3976, 3976, 0, {37691, 0, 0, 0}, 46, 46, { 1252, 870, 10000, 850, 0, ';' }},
-       {0x002F, 0x007F, 257, -1, 4016, 4019, 4030, 4051, 4055, 4016, 0, {37712, 0, 0, 0}, 47, 47, { 1251, 500, 10007, 866, 0, ';' }},
-       {0x0030, 0x007F, 257, -1, 4059, 4062, 4077, 4085, 4089, 4059, 0, {0, 0, 0, 0}, 48, 48, { 0, 500, 2, 1, 0, ';' }},
-       {0x0031, 0x007F, 257, -1, 4093, 4096, 4103, 4112, 4116, 4093, 0, {0, 0, 0, 0}, 49, 49, { 0, 500, 2, 1, 0, ';' }},
-       {0x0032, 0x007F, 257, -1, 4120, 4123, 4130, 4139, 4143, 4120, 0, {0, 0, 0, 0}, 50, 50, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0034, 0x007F, 257, -1, 4147, 4150, 4156, 4165, 4169, 4147, 0, {0, 0, 0, 0}, 51, 51, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0035, 0x007F, 257, -1, 4173, 4176, 4181, 4189, 4193, 4173, 0, {37756, 0, 0, 0}, 52, 52, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0036, 0x007F, 257, -1, 4197, 4200, 4200, 4210, 4214, 4197, 0, {37781, 0, 0, 0}, 53, 53, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0037, 0x007F, 257, -1, 4218, 4221, 4230, 4252, 4256, 4218, 0, {37801, 0, 0, 0}, 54, 54, { 0, 500, 2, 1, 0, ';' }},
-       {0x0038, 0x007F, 257, -1, 4260, 4263, 4271, 4281, 4285, 4260, 0, {37866, 0, 0, 0}, 55, 55, { 1252, 20277, 10079, 850, 0, ';' }},
-       {0x0039, 0x007F, 257, -1, 4289, 4292, 4298, 4317, 4321, 4289, 0, {37890, 0, 0, 0}, 56, 56, { 0, 500, 2, 1, 0, ',' }},
-       {0x003A, 0x007F, 257, -1, 4325, 4328, 4336, 4342, 4346, 4325, 0, {37943, 0, 0, 0}, 57, 57, { 0, 500, 2, 1, 0, ';' }},
-       {0x003B, 0x007F, 257, -1, 4350, 4353, 4367, 4384, 4388, 4350, 0, {37964, 0, 0, 0}, 58, 58, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x003C, 0x007F, 257, -1, 4392, 4395, 4401, 4409, 4413, 4392, 0, {37983, 0, 0, 0}, 59, 59, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x003E, 0x007F, 257, -1, 4417, 4420, 4426, 4440, 4444, 4417, 0, {38004, 0, 0, 0}, 60, 60, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x003F, 0x007F, 257, -1, 4448, 4451, 4458, 4478, 4482, 4448, 0, {38021, 0, 0, 0}, 61, 61, { 0, 500, 2, 1, 0, ';' }},
-       {0x0040, 0x007F, 257, -1, 4486, 4489, 4496, 4513, 4517, 4486, 0, {38063, 0, 0, 0}, 62, 62, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0041, 0x007F, 257, -1, 4521, 4524, 4532, 4542, 4546, 4521, 0, {38103, 0, 0, 0}, 63, 63, { 1252, 500, 10000, 437, 0, ';' }},
-       {0x0042, 0x007F, 257, -1, 4550, 4553, 4561, 4573, 4577, 4550, 0, {38124, 0, 0, 0}, 64, 64, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0043, 0x007F, 257, -1, 4581, 4584, 4590, 4599, 4603, 4581, 0, {38146, 0, 0, 0}, 65, 65, { 1254, 500, 10029, 857, 0, ';' }},
-       {0x0045, 0x007F, 257, -1, 4607, 4610, 4617, 4633, 4637, 4607, 0, {38164, 0, 0, 0}, 66, 66, { 0, 500, 2, 1, 0, ',' }},
-       {0x0046, 0x007F, 257, -1, 4641, 4644, 4652, 4671, 4675, 4641, 0, {38235, 0, 0, 0}, 67, 67, { 0, 500, 2, 1, 0, ',' }},
-       {0x0047, 0x007F, 257, -1, 4679, 4682, 4691, 4713, 4717, 4679, 0, {38282, 0, 0, 0}, 68, 68, { 0, 500, 2, 1, 0, ',' }},
-       {0x0048, 0x007F, 257, -1, 4721, 4724, 4729, 4745, 4749, 4721, 0, {0, 0, 0, 0}, 69, 69, { 0, 500, 2, 1, 0, ',' }},
-       {0x0049, 0x007F, 257, -1, 4753, 4756, 4762, 4778, 4782, 4753, 0, {38338, 0, 0, 0}, 70, 70, { 0, 500, 2, 1, 0, ',' }},
-       {0x004A, 0x007F, 257, -1, 4786, 4789, 4796, 4815, 4819, 4786, 0, {38403, 0, 0, 0}, 71, 71, { 0, 500, 2, 1, 0, ',' }},
-       {0x004B, 0x007F, 257, -1, 1717, 4823, 4831, 4847, 4851, 1717, 0, {38468, 0, 0, 0}, 72, 72, { 0, 500, 2, 1, 0, ',' }},
-       {0x004C, 0x007F, 257, -1, 4855, 4858, 4868, 4887, 4891, 4855, 0, {38533, 0, 0, 0}, 73, 73, { 0, 500, 2, 1, 0, ',' }},
-       {0x004D, 0x007F, 257, -1, 4895, 4898, 4907, 4929, 4933, 4895, 0, {38577, 0, 0, 0}, 74, 74, { 0, 500, 2, 1, 0, ',' }},
-       {0x004E, 0x007F, 257, -1, 4937, 4940, 4948, 4964, 4968, 4937, 0, {38630, 0, 0, 0}, 75, 75, { 0, 500, 2, 1, 0, ',' }},
-       {0x0050, 0x007F, 257, -1, 4972, 4975, 4985, 4998, 5002, 4972, 0, {38692, 0, 0, 0}, 76, 76, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0051, 0x007F, 257, -1, 5006, 5009, 5017, 5042, 5046, 5006, 0, {0, 0, 0, 0}, 77, 77, { 0, 500, 2, 1, 0, ',' }},
-       {0x0052, 0x007F, 257, -1, 5050, 5053, 5059, 5067, 5071, 5050, 0, {38724, 0, 0, 0}, 78, 78, { 1252, 20285, 10000, 850, 0, ';' }},
-       {0x0053, 0x007F, 257, -1, 5075, 5078, 5084, 5100, 5104, 5075, 0, {38740, 0, 0, 0}, 79, 79, { 0, 500, 2, 1, 0, ',' }},
-       {0x0054, 0x007F, 257, -1, 5108, 5111, 5115, 5125, 5129, 5108, 0, {38795, 0, 0, 0}, 80, 80, { 0, 500, 2, 1, 0, ';' }},
-       {0x0055, 0x007F, 257, -1, 5133, 5136, 5144, 5163, 5167, 5133, 0, {38841, 0, 0, 0}, 81, 81, { 0, 500, 2, 1, 0, ';' }},
-       {0x0056, 0x007F, 257, -1, 5171, 5174, 5183, 5190, 5194, 5171, 0, {36899, 0, 0, 0}, 82, 82, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0057, 0x007F, 257, -1, 5198, 5202, 5210, 5229, 5198, 5198, 0, {0, 0, 0, 0}, 83, 83, { 0, 500, 2, 1, 0, ',' }},
-       {0x005B, 0x007F, 257, -1, 5233, 5236, 5244, 5260, 5264, 5233, 0, {38912, 0, 0, 0}, 84, 84, { 0, 500, 2, 1, 0, ';' }},
-       {0x005C, 0x007F, 257, -1, 5268, 5272, 5281, 5291, 5268, 5268, 0, {38978, 0, 0, 0}, 85, 85, { 0, 500, 2, 1, 0, ',' }},
-       {0x005E, 0x007F, 257, -1, 5, 5295, 5303, 5316, 5320, 5, 0, {39017, 0, 0, 0}, 86, 86, { 0, 500, 2, 1, 0, ';' }},
-       {0x005F, 0x007F, 257, -1, 5324, 5328, 5352, 5375, 5324, 5324, 0, {0, 0, 0, 0}, 87, 87, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0061, 0x007F, 257, -1, 5379, 5382, 5389, 5408, 5412, 5379, 0, {39065, 0, 0, 0}, 88, 88, { 0, 500, 2, 1, 0, ',' }},
-       {0x0062, 0x007F, 257, -1, 5416, 5419, 5435, 5446, 5450, 5416, 0, {39115, 0, 0, 0}, 89, 89, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0063, 0x007F, 1024, -1, 5454, 5457, 5464, 5473, 5477, 5454, 0, {0, 0, 0, 0}, 90, 90, { 0, 500, 2, 1, 1, ';' }},
-       {0x0064, 0x007F, 257, -1, 5481, 5485, 5485, 5494, 5481, 5481, 0, {39138, 0, 0, 0}, 91, 91, { 1252, 500, 10000, 437, 0, ';' }},
-       {0x0067, 0x007F, 257, -1, 5498, 5501, 5507, 5514, 5518, 5498, 0, {0, 0, 0, 0}, 92, 92, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0068, 0x007F, 257, -1, 5522, 5525, 5525, 5531, 5535, 5522, 0, {0, 0, 0, 0}, 93, 93, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x006A, 0x007F, 257, -1, 5539, 5542, 5549, 5564, 5568, 5539, 0, {0, 0, 0, 0}, 94, 94, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x006C, 0x007F, 257, -1, 5572, 5576, 5591, 5608, 5572, 5572, 0, {0, 0, 0, 0}, 95, 95, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x006E, 0x007F, 257, -1, 5612, 5615, 5629, 5645, 5649, 5612, 0, {39162, 0, 0, 0}, 96, 96, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x006F, 0x007F, 257, -1, 5653, 5656, 5668, 5680, 5684, 5653, 0, {39186, 0, 0, 0}, 97, 97, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x0070, 0x007F, 257, -1, 5688, 5691, 5691, 5696, 5700, 5688, 0, {0, 0, 0, 0}, 98, 98, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x0072, 0x007F, 257, -1, 5704, 5707, 5713, 5720, 5724, 5704, 0, {0, 0, 0, 0}, 99, 99, { 0, 500, 2, 1, 0, ';' }},
-       {0x0073, 0x007F, 257, -1, 5728, 5731, 5740, 5753, 5757, 5728, 0, {0, 0, 0, 0}, 100, 100, { 0, 500, 2, 1, 0, ';' }},
-       {0x0075, 0x007F, 257, -1, 5761, 5765, 5774, 5792, 5761, 5761, 0, {0, 0, 0, 0}, 101, 101, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x0077, 0x007F, 257, -1, 5796, 5799, 5806, 5815, 5819, 5796, 0, {0, 0, 0, 0}, 102, 102, { 0, 500, 2, 1, 0, ';' }},
-       {0x0078, 0x007F, 257, -1, 5823, 5826, 5837, 5847, 5851, 5823, 0, {39213, 0, 0, 0}, 103, 103, { 0, 500, 2, 1, 0, ';' }},
-       {0x007E, 0x007F, 257, -1, 5855, 5858, 5865, 5875, 5879, 5855, 0, {39226, 0, 0, 0}, 104, 104, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0080, 0x007F, 257, -1, 5883, 5886, 5893, 5910, 5914, 5883, 0, {39246, 0, 0, 0}, 105, 105, { 1256, 20420, 10004, 720, 1, ',' }},
-       {0x0084, 0x007F, 257, -1, 5918, 5922, 5935, 5954, 5918, 5918, 0, {39282, 0, 0, 0}, 106, 106, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0085, 0x007F, 257, -1, 5958, 5962, 5968, 5986, 5958, 5958, 0, {0, 0, 0, 0}, 107, 107, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0087, 0x007F, 257, -1, 5990, 5993, 5993, 6005, 6009, 5990, 0, {0, 0, 0, 0}, 108, 108, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x0091, 0x007F, 257, -1, 6013, 6016, 6032, 6042, 6046, 6013, 0, {39307, 0, 0, 0}, 109, 109, { 1252, 20285, 10000, 850, 0, ';' }},
-       {0x0401, 0x0001, 768, 111, 6050, 6056, 6078, 2603, 2607, 2578, 297, {0, 0, 36669, 0}, 110, 110, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x0402, 0x0002, 257, 11, 6142, 6148, 6169, 2643, 2647, 2611, 6207, {36697, 0, 0, 0}, 111, 111, { 1251, 21025, 10007, 866, 0, ';' }},
-       {0x0403, 0x0003, 257, 38, 6210, 6216, 6232, 2670, 2674, 2651, 6250, {36739, 0, 0, 0}, 112, 112, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0404, 0x7C04, 257, 126, 6253, 6259, 6281, 6297, 2718, 2722, 6301, {39332, 0, 0, 0}, 113, 113, { 950, 500, 10002, 950, 0, ',' }},
-       {0x0405, 0x0005, 257, 29, 6304, 6310, 6333, 2779, 2783, 2760, 6363, {36766, 0, 0, 0}, 114, 114, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x0406, 0x0006, 257, 31, 6366, 6372, 6389, 2803, 2807, 2787, 6405, {36792, 0, 0, 0}, 115, 115, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x0407, 0x0007, 257, 30, 6408, 6414, 6431, 2829, 2833, 2811, 6453, {36813, 0, 0, 0}, 116, 116, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x0408, 0x0008, 257, 46, 6456, 6462, 6477, 2863, 2867, 2837, 6509, {36838, 0, 0, 0}, 117, 117, { 1253, 20273, 10006, 737, 0, ';' }},
-       {0x0409, 0x0009, 257, 128, 6512, 6518, 6518, 2882, 2886, 2871, 6542, {36880, 0, 0, 0}, 118, 118, { 1252, 37, 10000, 437, 0, ',' }},
-       {0x040B, 0x000B, 257, 40, 6545, 6551, 6569, 2935, 2939, 2918, 6583, {36921, 0, 0, 0}, 119, 119, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x040C, 0x000C, 257, 42, 6586, 6592, 6608, 2963, 2967, 2943, 6627, {36946, 0, 0, 0}, 120, 120, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x040D, 0x000D, 257, 55, 6630, 6636, 6652, 2992, 2996, 2971, 6676, {36968, 0, 0, 0}, 121, 121, { 1255, 500, 10005, 862, 1, ',' }},
-       {0x040E, 0x000E, 257, 52, 6679, 6685, 6705, 3020, 3024, 3000, 6728, {37005, 0, 0, 0}, 122, 122, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x040F, 0x000F, 257, 59, 6731, 6737, 6757, 3051, 3055, 3028, 6777, {37021, 0, 0, 0}, 123, 123, { 1252, 20871, 10079, 850, 0, ';' }},
-       {0x0410, 0x0010, 257, 60, 6780, 6786, 6802, 3079, 3083, 3059, 6820, {37041, 0, 0, 0}, 124, 124, { 1252, 20280, 10000, 850, 0, ';' }},
-       {0x0411, 0x0011, 257, 63, 6823, 6829, 6846, 3109, 3113, 3087, 6865, {37063, 0, 0, 0}, 125, 125, { 932, 20290, 10001, 932, 0, ',' }},
-       {0x0412, 0x0012, 257, 67, 6868, 6874, 6895, 3137, 3141, 3117, 6920, {37090, 0, 0, 0}, 126, 126, { 949, 20833, 10003, 949, 0, ',' }},
-       {0x0413, 0x0013, 257, 92, 6923, 6929, 6949, 3165, 3169, 3145, 6972, {37097, 0, 0, 0}, 127, 127, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0414, 0x7C14, 257, 93, 6975, 6981, 7008, 3192, 3196, 3200, 7030, {36792, 0, 0, 0}, 128, 128, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x0415, 0x0015, 257, 101, 7033, 7039, 7055, 3220, 3224, 3203, 7071, {37119, 0, 0, 0}, 129, 129, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0416, 0x0016, 257, 15, 7074, 7080, 7100, 3253, 3257, 3228, 7120, {37143, 0, 0, 0}, 130, 130, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0417, 0x0017, 257, 21, 7123, 7129, 7151, 3282, 3286, 3261, 300, {37166, 0, 0, 0}, 131, 131, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x0418, 0x0018, 257, 107, 7170, 7176, 7195, 3311, 3315, 3290, 7215, {37186, 0, 0, 0}, 132, 132, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0419, 0x0019, 257, 109, 7218, 7224, 7241, 3345, 3349, 3319, 7271, {37205, 0, 0, 0}, 133, 133, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x041A, 0x001A, 257, 50, 7274, 7280, 7299, 3374, 3378, 3353, 7319, {37251, 0, 0, 0}, 134, 134, { 1250, 500, 10082, 852, 0, ';' }},
-       {0x041B, 0x001B, 257, 115, 7322, 7328, 7346, 3404, 3408, 3382, 7370, {37274, 0, 0, 0}, 135, 135, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x041C, 0x001C, 257, 2, 7373, 7379, 7398, 3430, 3434, 3412, 7416, {37298, 0, 0, 0}, 136, 136, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x041D, 0x001D, 257, 112, 7419, 7425, 7442, 3457, 3461, 3438, 7460, {36792, 0, 0, 0}, 137, 137, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x041E, 0x001E, 512, 120, 7463, 7469, 7485, 3483, 3487, 3465, 7507, {0, 37317, 0, 0}, 138, 138, { 874, 20838, 10021, 874, 0, ',' }},
-       {0x041F, 0x001F, 257, 124, 7510, 7516, 7533, 3511, 3515, 3491, 7553, {37348, 0, 0, 0}, 139, 139, { 1254, 20905, 10081, 857, 0, ';' }},
-       {0x0420, 0x0020, 257, 100, 7556, 7562, 7578, 3536, 3540, 3519, 7604, {37362, 0, 0, 0}, 140, 140, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x0421, 0x0021, 257, 53, 7607, 7613, 7636, 3568, 3572, 3544, 7658, {37392, 0, 0, 0}, 141, 141, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0422, 0x0022, 257, 127, 7661, 7667, 7687, 3610, 3614, 3576, 7725, {37411, 0, 0, 0}, 142, 142, { 1251, 500, 10017, 866, 0, ';' }},
-       {0x0423, 0x0023, 257, 17, 7728, 7734, 7755, 3653, 3657, 3618, 7795, {37457, 0, 0, 0}, 143, 143, { 1251, 500, 10007, 866, 0, ';' }},
-       {0x0424, 0x0024, 257, 114, 7798, 7804, 7825, 3688, 3692, 3661, 7851, {37499, 0, 0, 0}, 144, 144, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0425, 0x0025, 257, 35, 7854, 7860, 7879, 3714, 3718, 3696, 7893, {37521, 0, 0, 0}, 145, 145, { 1257, 500, 10029, 775, 0, ';' }},
-       {0x0426, 0x0026, 257, 76, 7896, 7902, 7919, 3743, 3747, 3722, 7939, {37541, 0, 0, 0}, 146, 146, { 1257, 500, 10029, 775, 0, ';' }},
-       {0x0427, 0x0027, 257, 74, 7942, 7948, 7971, 3775, 3779, 3751, 7991, {37560, 0, 0, 0}, 147, 147, { 1257, 500, 10029, 775, 0, ';' }},
-       {0x0428, 0x7C28, 257, 121, 7994, 8005, 8034, 3805, 3809, 3783, 8070, {0, 0, 0, 0}, 148, 148, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0429, 0x0029, 257, 58, 8073, 8079, 8094, 3835, 3839, 3813, 8118, {37583, 0, 0, 0}, 149, 149, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x042A, 0x002A, 257, 132, 8121, 8127, 8148, 3872, 3876, 3843, 8176, {37607, 0, 0, 0}, 150, 150, { 1258, 500, 10000, 1258, 0, ',' }},
-       {0x042B, 0x002B, 257, 3, 8179, 8185, 8204, 3907, 3911, 3880, 49, {37622, 0, 0, 0}, 151, 151, { 0, 500, 2, 1, 0, ',' }},
-       {0x042C, 0x782C, 257, 7, 8238, 8249, 8281, 3942, 3946, 3915, 8307, {37652, 0, 0, 0}, 152, 152, { 1254, 20905, 10081, 857, 0, ';' }},
-       {0x042D, 0x002D, 257, 38, 8310, 8316, 8331, 3968, 3972, 3950, 6250, {37671, 0, 0, 0}, 153, 153, { 1252, 500, 2, 850, 0, ';' }},
-       {0x042E, 0x002E, 257, 30, 8350, 8357, 8381, 4012, 3976, 3976, 6453, {37691, 0, 0, 0}, 154, 154, { 1252, 870, 10000, 850, 0, ';' }},
-       {0x042F, 0x002F, 257, 82, 8409, 8415, 8438, 4051, 4055, 4016, 8482, {37712, 0, 0, 0}, 155, 155, { 1251, 500, 10007, 866, 0, ';' }},
-       {0x0430, 0x0030, 257, 134, 8485, 8491, 4077, 4085, 4089, 4059, 8521, {0, 0, 0, 0}, 156, 156, { 0, 500, 2, 1, 0, ';' }},
-       {0x0431, 0x0031, 257, 134, 8524, 8530, 4103, 4112, 4116, 4093, 8521, {0, 0, 0, 0}, 157, 157, { 0, 500, 2, 1, 0, ';' }},
-       {0x0432, 0x0032, 257, 134, 8552, 8558, 4130, 4139, 4143, 4120, 8521, {0, 0, 0, 0}, 158, 158, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0434, 0x0034, 257, 134, 8580, 8586, 4156, 4165, 4169, 4147, 8521, {0, 0, 0, 0}, 159, 159, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0435, 0x0035, 257, 134, 8607, 8613, 8633, 4189, 4193, 4173, 8521, {37756, 0, 0, 0}, 160, 160, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0436, 0x0036, 257, 134, 8658, 8664, 8689, 4210, 4214, 4197, 8521, {37781, 0, 0, 0}, 161, 161, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0437, 0x0037, 257, 44, 8713, 8719, 8738, 4252, 4256, 4218, 8793, {37801, 0, 0, 0}, 162, 162, { 0, 500, 2, 1, 0, ';' }},
-       {0x0438, 0x0038, 257, 41, 8796, 8802, 8826, 4281, 4285, 4260, 8847, {37866, 0, 0, 0}, 163, 163, { 1252, 20277, 10079, 850, 0, ';' }},
-       {0x0439, 0x0039, 257, 56, 8850, 8856, 8870, 4317, 4321, 4289, 8904, {37890, 0, 0, 0}, 164, 164, { 0, 500, 2, 1, 0, ',' }},
-       {0x043A, 0x003A, 257, 87, 8907, 8913, 8929, 4342, 4346, 4325, 8943, {37943, 0, 0, 0}, 165, 165, { 0, 500, 2, 1, 0, ';' }},
-       {0x043B, 0x003B, 257, 93, 8946, 8952, 8975, 4384, 4388, 4350, 7030, {37964, 0, 0, 0}, 166, 166, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x043E, 0x003E, 257, 89, 9000, 9006, 9023, 4440, 4444, 4417, 9048, {38004, 0, 0, 0}, 167, 167, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x043F, 0x003F, 257, 69, 9051, 9057, 9077, 4478, 4482, 4448, 9118, {38021, 0, 0, 0}, 168, 168, { 0, 500, 2, 1, 0, ';' }},
-       {0x0440, 0x0040, 257, 65, 9121, 9127, 9147, 4513, 4517, 4486, 9187, {38063, 0, 0, 0}, 169, 169, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0441, 0x0041, 257, 64, 9190, 9196, 9212, 4542, 4546, 4521, 9230, {38103, 0, 0, 0}, 170, 170, { 1252, 500, 10000, 437, 0, ';' }},
-       {0x0442, 0x0042, 257, 122, 9233, 9239, 9262, 4573, 4577, 4550, 9290, {38124, 0, 0, 0}, 171, 171, { 1250, 20880, 10029, 852, 0, ';' }},
-       {0x0443, 0x7C43, 257, 130, 9293, 9304, 9330, 4599, 4603, 4581, 9354, {38146, 0, 0, 0}, 172, 172, { 1254, 500, 10029, 857, 0, ';' }},
-       {0x0445, 0x0045, 257, 56, 9357, 9363, 9378, 4633, 4637, 4607, 8904, {38164, 0, 0, 0}, 173, 173, { 0, 500, 2, 1, 0, ',' }},
-       {0x0447, 0x0047, 257, 56, 9409, 9415, 9432, 4713, 4717, 4679, 8904, {38282, 0, 0, 0}, 174, 174, { 0, 500, 2, 1, 0, ',' }},
-       {0x0448, 0x0048, 257, 56, 9469, 9475, 9488, 4745, 4749, 4721, 8904, {0, 0, 0, 0}, 175, 175, { 0, 500, 2, 1, 0, ',' }},
-       {0x0449, 0x0049, 257, 56, 9519, 9525, 9539, 4778, 4782, 4753, 8904, {38338, 0, 0, 0}, 176, 176, { 0, 500, 2, 1, 0, ',' }},
-       {0x044A, 0x004A, 257, 56, 9579, 9585, 9600, 4815, 4819, 4786, 8904, {38403, 0, 0, 0}, 177, 177, { 0, 500, 2, 1, 0, ',' }},
-       {0x044B, 0x004B, 257, 56, 9647, 9653, 9669, 4847, 4851, 1717, 8904, {38468, 0, 0, 0}, 178, 178, { 0, 500, 2, 1, 0, ',' }},
-       {0x044C, 0x004C, 257, 56, 9700, 9706, 9724, 4887, 4891, 4855, 8904, {38533, 0, 0, 0}, 179, 179, { 0, 500, 2, 1, 0, ',' }},
-       {0x044D, 0x004D, 257, 56, 9764, 9770, 9787, 4929, 4933, 4895, 8904, {38577, 0, 0, 0}, 180, 180, { 0, 500, 2, 1, 0, ',' }},
-       {0x044E, 0x004E, 257, 56, 9824, 9830, 9846, 4964, 4968, 4937, 8904, {38630, 0, 0, 0}, 181, 181, { 0, 500, 2, 1, 0, ',' }},
-       {0x0450, 0x7850, 257, 85, 9877, 9883, 9904, 9932, 5002, 4972, 9936, {38692, 0, 0, 0}, 182, 182, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0451, 0x0051, 257, 25, 9939, 9945, 9961, 5042, 5046, 5006, 10007, {0, 0, 0, 0}, 183, 183, { 0, 500, 2, 1, 0, ',' }},
-       {0x0452, 0x0052, 257, 43, 10010, 10016, 10039, 5067, 5071, 5050, 10066, {38724, 0, 0, 0}, 184, 184, { 1252, 20285, 10000, 850, 0, ';' }},
-       {0x0453, 0x0053, 257, 66, 10069, 10075, 10092, 5100, 5104, 5075, 10132, {38740, 0, 0, 0}, 185, 185, { 0, 500, 2, 1, 0, ',' }},
-       {0x0454, 0x0054, 257, 70, 10135, 10141, 10152, 5125, 5129, 5108, 10174, {38795, 0, 0, 0}, 186, 186, { 0, 500, 2, 1, 0, ';' }},
-       {0x0455, 0x0055, 257, 84, 10177, 10183, 10209, 5163, 5167, 5133, 10249, {38841, 0, 0, 0}, 187, 187, { 0, 500, 2, 1, 0, ';' }},
-       {0x0456, 0x0056, 257, 38, 10252, 10258, 10275, 5190, 5194, 5171, 6250, {36899, 0, 0, 0}, 188, 188, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0457, 0x0057, 257, 56, 10292, 10299, 10315, 5229, 5198, 5198, 8904, {0, 0, 0, 0}, 189, 189, { 0, 500, 2, 1, 0, ',' }},
-       {0x045B, 0x005B, 257, 73, 10349, 10355, 10375, 5260, 5264, 5233, 10425, {38912, 0, 0, 0}, 190, 190, { 0, 500, 2, 1, 0, ';' }},
-       {0x045E, 0x005E, 257, 39, 10428, 10434, 10453, 5316, 5320, 5, 10484, {39017, 0, 0, 0}, 191, 191, { 0, 500, 2, 1, 0, ';' }},
-       {0x0461, 0x0061, 257, 94, 10487, 10493, 10508, 5408, 5412, 5379, 10545, {39065, 0, 0, 0}, 192, 192, { 0, 500, 2, 1, 0, ',' }},
-       {0x0462, 0x0062, 257, 92, 10548, 10554, 10584, 5446, 5450, 5416, 6972, {39115, 0, 0, 0}, 193, 193, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0463, 0x0063, 1024, 1, 10607, 10613, 10634, 5473, 5477, 5454, 10664, {0, 0, 0, 0}, 194, 194, { 0, 500, 2, 1, 1, ';' }},
-       {0x0464, 0x0064, 257, 99, 10667, 10674, 10697, 5494, 5481, 5481, 10718, {39138, 0, 0, 0}, 195, 195, { 1252, 500, 10000, 437, 0, ';' }},
-       {0x0468, 0x7C68, 257, 90, 10721, 10732, 10755, 5531, 5535, 5522, 10772, {0, 0, 0, 0}, 196, 196, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x046A, 0x006A, 257, 90, 10775, 10781, 10798, 5564, 5568, 5539, 10772, {0, 0, 0, 0}, 197, 197, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x046C, 0x006C, 257, 134, 10844, 10851, 5591, 5608, 5572, 5572, 8521, {0, 0, 0, 0}, 198, 198, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x046E, 0x006E, 257, 75, 10881, 10887, 10914, 5645, 5649, 5612, 10944, {39162, 0, 0, 0}, 199, 199, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x046F, 0x006F, 257, 45, 10947, 10953, 10977, 5680, 5684, 5653, 11008, {39186, 0, 0, 0}, 200, 200, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x0470, 0x0070, 257, 90, 11011, 11017, 11017, 5696, 5700, 5688, 10772, {0, 0, 0, 0}, 201, 201, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x0472, 0x0072, 257, 39, 11032, 11038, 11055, 5720, 5724, 5704, 10484, {0, 0, 0, 0}, 202, 202, { 0, 500, 2, 1, 0, ';' }},
-       {0x0473, 0x0073, 257, 39, 11075, 11081, 11101, 11132, 5757, 5728, 10484, {0, 0, 0, 0}, 203, 203, { 0, 500, 2, 1, 0, ';' }},
-       {0x0475, 0x0075, 257, 128, 11136, 11143, 11168, 5792, 5761, 5761, 6542, {0, 0, 0, 0}, 204, 204, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x0477, 0x0077, 257, 117, 11211, 11217, 11234, 5815, 5819, 5796, 11256, {0, 0, 0, 0}, 205, 205, { 0, 500, 2, 1, 0, ';' }},
-       {0x0478, 0x0078, 257, 25, 11259, 11265, 11284, 5847, 5851, 5823, 10007, {39213, 0, 0, 0}, 206, 206, { 0, 500, 2, 1, 0, ';' }},
-       {0x047E, 0x007E, 257, 42, 11303, 11309, 11325, 5875, 5879, 5855, 6627, {39226, 0, 0, 0}, 207, 207, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0480, 0x0080, 257, 25, 11344, 11350, 11365, 5910, 5914, 5883, 10007, {39246, 0, 0, 0}, 208, 208, { 1256, 20420, 10004, 720, 1, ',' }},
-       {0x0484, 0x0084, 257, 42, 11395, 11402, 11424, 5954, 5918, 5918, 6627, {39282, 0, 0, 0}, 209, 209, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0485, 0x0085, 257, 109, 11456, 11463, 11478, 5986, 5958, 5958, 7271, {0, 0, 0, 0}, 210, 210, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0487, 0x0087, 257, 110, 11517, 11523, 11523, 6005, 6009, 5990, 11544, {0, 0, 0, 0}, 211, 211, { 1252, 37, 10000, 437, 0, ';' }},
-       {0x0491, 0x0091, 257, 43, 11547, 11553, 11586, 6042, 6046, 6013, 10066, {39307, 0, 0, 0}, 212, 212, { 1252, 20285, 10000, 850, 0, ';' }},
-       {0x0801, 0x0001, 257, 57, 11622, 11628, 11642, 11672, 2607, 2578, 11676, {39339, 0, 0, 0}, 213, 213, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x0803, 0x0403, 257, 38, 11679, 6216, 6232, 11694, 2674, 2651, 6250, {36739, 0, 0, 0}, 214, 214, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0804, 0x0004, 257, 25, 11698, 2686, 11704, 2714, 2718, 2722, 10007, {36759, 0, 0, 0}, 215, 215, { 936, 500, 10008, 936, 0, ',' }},
-       {0x0807, 0x0007, 257, 21, 11720, 11726, 11747, 11765, 2833, 2811, 300, {36813, 0, 0, 0}, 216, 216, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x0809, 0x0009, 257, 43, 11769, 11775, 11775, 11800, 2886, 2871, 10066, {36880, 0, 0, 0}, 217, 217, { 1252, 20285, 10000, 850, 0, ',' }},
-       {0x080A, 0x000A, 257, 88, 11804, 11810, 11827, 11846, 2914, 2890, 11850, {37041, 0, 0, 0}, 218, 218, { 1252, 20284, 10000, 850, 0, ',' }},
-       {0x080C, 0x000C, 257, 10, 11853, 11859, 11876, 11897, 2967, 2943, 11901, {36946, 0, 0, 0}, 219, 219, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0810, 0x0010, 257, 21, 11904, 11910, 11932, 11952, 3083, 3059, 300, {37041, 0, 0, 0}, 220, 220, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0813, 0x0013, 257, 10, 11956, 11962, 11978, 11999, 3169, 3145, 11901, {37097, 0, 0, 0}, 221, 221, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0814, 0x7814, 257, 93, 12003, 12009, 12036, 12052, 12056, 12060, 7030, {36792, 0, 0, 0}, 222, 222, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x0816, 0x0016, 257, 103, 12063, 12069, 12091, 430, 3257, 3228, 12113, {39371, 0, 0, 0}, 223, 223, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0818, 0x0018, 257, 80, 12116, 12122, 12141, 12170, 3315, 3290, 12174, {37186, 0, 0, 0}, 224, 224, { 1250, 500, 2, 852, 0, ';' }},
-       {0x0819, 0x0019, 257, 80, 12177, 12183, 12201, 12233, 3349, 3319, 12174, {37205, 0, 0, 0}, 225, 225, { 1251, 500, 2, 866, 0, ';' }},
-       {0x081D, 0x001D, 257, 40, 12237, 12243, 12261, 12279, 3461, 3438, 6583, {36792, 0, 0, 0}, 226, 226, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x0820, 0x0020, 257, 56, 12283, 12289, 12302, 12324, 3540, 3519, 8904, {37362, 0, 0, 0}, 227, 227, { 1256, 500, 2, 720, 1, ';' }},
-       {0x082C, 0x742C, 257, 7, 12328, 12339, 8281, 12374, 3946, 3915, 8307, {37652, 0, 0, 0}, 228, 228, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x082E, 0x7C2E, 257, 30, 12378, 12385, 12409, 12435, 12439, 12439, 6453, {39394, 0, 0, 0}, 229, 229, { 1252, 870, 10000, 850, 0, ';' }},
-       {0x0832, 0x0032, 257, 16, 12443, 12449, 4130, 12467, 4143, 4120, 12471, {0, 0, 0, 0}, 230, 230, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x083B, 0x003B, 257, 112, 12474, 12480, 12503, 12531, 4388, 4350, 7460, {37964, 0, 0, 0}, 231, 231, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x083C, 0x003C, 257, 54, 12535, 12541, 12557, 4409, 4413, 4392, 12573, {37983, 0, 0, 0}, 232, 232, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x083E, 0x003E, 257, 13, 12576, 12582, 12597, 12620, 4444, 4417, 12624, {38004, 0, 0, 0}, 233, 233, { 1252, 500, 10000, 850, 0, ';' }},
-       {0x0843, 0x7843, 257, 130, 12627, 12638, 9330, 12667, 4603, 4581, 9354, {39417, 0, 0, 0}, 234, 234, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x0845, 0x0045, 257, 9, 12671, 12677, 12697, 12740, 4637, 4607, 12744, {38164, 0, 0, 0}, 235, 235, { 0, 500, 2, 1, 0, ',' }},
-       {0x0846, 0x7C46, 257, 100, 12747, 12758, 12785, 12831, 4675, 4641, 7604, {38235, 0, 0, 0}, 236, 236, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x0849, 0x0049, 257, 73, 12835, 12841, 12859, 12896, 4782, 4753, 10425, {38338, 0, 0, 0}, 237, 237, { 0, 500, 2, 1, 0, ';' }},
-       {0x0861, 0x0061, 257, 56, 12900, 12906, 12921, 12955, 5412, 5379, 8904, {39065, 0, 0, 0}, 238, 238, { 0, 500, 2, 1, 0, ';' }},
-       {0x0873, 0x0073, 257, 37, 12959, 12965, 12984, 5753, 5757, 5728, 13012, {0, 0, 0, 0}, 239, 239, { 0, 500, 2, 1, 0, ';' }},
-       {0x0C01, 0x0001, 257, 36, 13015, 13021, 13036, 13060, 2607, 2578, 13064, {39339, 0, 0, 0}, 240, 240, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x0C04, 0x7C04, 257, 48, 13067, 13073, 13116, 13153, 2718, 2722, 13157, {39332, 0, 0, 0}, 241, 241, { 950, 500, 10002, 950, 0, ',' }},
-       {0x0C07, 0x0007, 257, 5, 13160, 13166, 13183, 13205, 2833, 2811, 13209, {36813, 0, 0, 0}, 242, 242, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x0C09, 0x0009, 257, 6, 13212, 13218, 13218, 13238, 2886, 2871, 13242, {36880, 0, 0, 0}, 243, 243, { 1252, 500, 10000, 850, 0, ',' }},
-       {0x0C0A, 0x000A, 257, 38, 13245, 13251, 13267, 13286, 2914, 2890, 6250, {36899, 0, 0, 0}, 244, 244, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x0C0C, 0x000C, 257, 19, 13290, 13296, 13312, 13331, 2967, 2943, 13335, {36946, 0, 0, 0}, 245, 245, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x0C3B, 0x003B, 257, 40, 13338, 13344, 13368, 13394, 4388, 4350, 6583, {39455, 0, 0, 0}, 246, 246, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x1001, 0x0001, 257, 77, 13398, 13404, 13419, 13447, 2607, 2578, 13451, {39339, 0, 0, 0}, 247, 247, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x1004, 0x0004, 257, 113, 13454, 13460, 13492, 13511, 2718, 2722, 13515, {36759, 0, 0, 0}, 248, 248, { 936, 500, 10008, 936, 0, ',' }},
-       {0x1007, 0x0007, 257, 75, 13518, 13524, 13544, 13564, 2833, 2811, 10944, {36813, 0, 0, 0}, 249, 249, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x1009, 0x0009, 257, 19, 13568, 13574, 13574, 13591, 2886, 2871, 13335, {36880, 0, 0, 0}, 250, 250, { 1252, 37, 10000, 850, 0, ',' }},
-       {0x100A, 0x000A, 257, 47, 13595, 13601, 13621, 13642, 2914, 2890, 13646, {36899, 0, 0, 0}, 251, 251, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x100C, 0x000C, 257, 21, 13649, 13655, 13676, 13695, 2967, 2943, 300, {36946, 0, 0, 0}, 252, 252, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x101A, 0x001A, 257, 8, 13699, 13705, 13737, 13768, 3378, 3353, 13772, {37251, 0, 0, 0}, 253, 253, { 1250, 870, 10082, 852, 0, ';' }},
-       {0x1401, 0x0001, 257, 33, 13775, 13781, 13798, 13830, 2607, 2578, 13834, {39339, 0, 0, 0}, 254, 254, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x1404, 0x7C04, 257, 86, 13837, 13843, 13882, 13919, 2718, 2722, 13923, {39332, 0, 0, 0}, 255, 255, { 950, 500, 10002, 950, 0, ',' }},
-       {0x1407, 0x0007, 257, 72, 13926, 13932, 13955, 13979, 2833, 2811, 13983, {36813, 0, 0, 0}, 256, 256, { 1252, 20273, 10000, 850, 0, ';' }},
-       {0x1409, 0x0009, 257, 95, 13986, 13992, 13992, 14014, 2886, 2871, 14018, {36880, 0, 0, 0}, 257, 257, { 1252, 500, 10000, 850, 0, ',' }},
-       {0x140A, 0x000A, 257, 27, 14021, 14027, 14048, 14070, 2914, 2890, 14074, {36899, 0, 0, 0}, 258, 258, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x140C, 0x000C, 257, 75, 14077, 14083, 14103, 14126, 2967, 2943, 10944, {36946, 0, 0, 0}, 259, 259, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x141A, 0x681A, 257, 8, 14130, 14141, 14179, 14210, 14214, 14218, 13772, {37251, 0, 0, 0}, 260, 260, { 1250, 870, 10082, 852, 0, ';' }},
-       {0x1801, 0x0001, 257, 78, 14221, 14227, 14244, 14274, 2607, 2578, 14278, {39339, 0, 0, 0}, 261, 261, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x1809, 0x0009, 257, 54, 14281, 14287, 14287, 14305, 2886, 2871, 12573, {36880, 0, 0, 0}, 262, 262, { 1252, 500, 10000, 850, 0, ',' }},
-       {0x180A, 0x000A, 257, 97, 14309, 14315, 14332, 14351, 2914, 2890, 14355, {36899, 0, 0, 0}, 263, 263, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x180C, 0x000C, 257, 79, 14358, 14364, 14380, 14399, 2967, 2943, 14403, {36946, 0, 0, 0}, 264, 264, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x181A, 0x701A, 257, 8, 14406, 14417, 14455, 14507, 14511, 14515, 13772, {37251, 0, 0, 0}, 265, 265, { 1250, 870, 10082, 852, 0, ';' }},
-       {0x1C01, 0x0001, 257, 123, 14518, 14524, 14541, 14567, 2607, 2578, 14571, {39339, 0, 0, 0}, 266, 266, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x1C09, 0x0009, 257, 134, 14574, 14580, 14580, 14603, 2886, 2871, 8521, {36880, 0, 0, 0}, 267, 267, { 1252, 500, 10000, 437, 0, ',' }},
-       {0x1C0A, 0x000A, 257, 32, 14607, 14613, 14642, 14675, 2914, 2890, 14679, {36899, 0, 0, 0}, 268, 268, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x1C1A, 0x6C1A, 257, 8, 14682, 14693, 14455, 14734, 14511, 14515, 13772, {39477, 0, 0, 0}, 269, 269, { 1251, 21025, 10007, 855, 0, ';' }},
-       {0x2001, 0x0001, 257, 96, 14738, 14744, 14758, 14786, 2607, 2578, 14790, {39339, 0, 0, 0}, 270, 270, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x2009, 0x0009, 257, 61, 14793, 14799, 14799, 14817, 2886, 2871, 14821, {36880, 0, 0, 0}, 271, 271, { 1252, 500, 10000, 850, 0, ',' }},
-       {0x200A, 0x000A, 257, 131, 14824, 14830, 14850, 14871, 2914, 2890, 14875, {36899, 0, 0, 0}, 272, 272, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x200C, 0x000C, 257, 106, 14878, 14884, 14902, 14926, 2967, 2943, 14930, {36946, 0, 0, 0}, 273, 273, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x201A, 0x641A, 257, 8, 14933, 14944, 14179, 14985, 14214, 14218, 13772, {37712, 0, 0, 0}, 274, 274, { 1251, 870, 10082, 855, 0, ';' }},
-       {0x2401, 0x0001, 257, 133, 14989, 14995, 15010, 15038, 2607, 2578, 15042, {39339, 0, 0, 0}, 275, 275, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x240A, 0x000A, 257, 26, 15045, 15051, 15070, 15090, 2914, 2890, 15094, {36899, 0, 0, 0}, 276, 276, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x240C, 0x000C, 257, 20, 15097, 15103, 15129, 15156, 2967, 2943, 15160, {36946, 0, 0, 0}, 277, 277, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x241A, 0x701A, 257, 108, 15163, 15174, 15198, 15226, 14511, 14515, 15230, {37251, 0, 0, 0}, 278, 278, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x243B, 0x703B, 257, 40, 15233, 15240, 15261, 15285, 15289, 15289, 6583, {0, 0, 0, 0}, 279, 279, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x2801, 0x0001, 257, 119, 15293, 15299, 15314, 15342, 2607, 2578, 15346, {39339, 0, 0, 0}, 280, 280, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x2809, 0x0009, 257, 18, 15349, 15355, 15355, 15372, 2886, 2871, 15376, {36880, 0, 0, 0}, 281, 281, { 1252, 500, 10000, 850, 0, ',' }},
-       {0x280A, 0x000A, 257, 98, 15379, 15385, 15400, 15417, 2914, 2890, 15421, {36899, 0, 0, 0}, 282, 282, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x280C, 0x000C, 257, 116, 15424, 15430, 15447, 15469, 2967, 2943, 15473, {36946, 0, 0, 0}, 283, 283, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x281A, 0x6C1A, 257, 108, 15476, 15487, 15198, 15514, 14511, 14515, 15230, {39477, 0, 0, 0}, 284, 284, { 1251, 21025, 10007, 855, 0, ';' }},
-       {0x2C01, 0x0001, 257, 62, 15518, 15524, 15540, 15570, 2607, 2578, 15574, {39339, 0, 0, 0}, 285, 285, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x2C09, 0x0009, 257, 125, 15577, 15583, 15583, 15611, 2886, 2871, 15615, {36880, 0, 0, 0}, 286, 286, { 1252, 500, 10000, 850, 0, ',' }},
-       {0x2C0A, 0x000A, 257, 4, 15618, 15624, 15644, 15665, 2914, 2890, 15669, {36899, 0, 0, 0}, 287, 287, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x2C0C, 0x000C, 257, 24, 15672, 15678, 15696, 15717, 2967, 2943, 15721, {36946, 0, 0, 0}, 288, 288, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x2C1A, 0x701A, 257, 81, 15724, 15735, 15763, 15796, 14511, 14515, 15800, {37251, 0, 0, 0}, 289, 289, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x3001, 0x0001, 257, 71, 15803, 15809, 15826, 15854, 2607, 2578, 15858, {39339, 0, 0, 0}, 290, 290, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x3009, 0x0009, 257, 135, 15861, 15867, 15867, 15886, 2886, 2871, 15890, {36880, 0, 0, 0}, 291, 291, { 1252, 500, 10000, 437, 0, ',' }},
-       {0x300A, 0x000A, 257, 34, 15893, 15899, 15917, 15936, 2914, 2890, 15940, {36899, 0, 0, 0}, 292, 292, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x300C, 0x000C, 257, 22, 15943, 15949, 15975, 16004, 2967, 2943, 16008, {36946, 0, 0, 0}, 293, 293, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x301A, 0x6C1A, 257, 81, 16011, 16022, 15763, 16053, 14511, 14515, 15800, {39477, 0, 0, 0}, 294, 294, { 1251, 21025, 10007, 855, 0, ';' }},
-       {0x3401, 0x0001, 257, 68, 16057, 16063, 16079, 16109, 2607, 2578, 16113, {39339, 0, 0, 0}, 295, 295, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x3409, 0x0009, 257, 99, 16116, 16122, 16122, 16144, 2886, 2871, 10718, {36880, 0, 0, 0}, 296, 296, { 1252, 500, 10000, 437, 0, ',' }},
-       {0x340A, 0x000A, 257, 23, 16148, 16154, 16170, 16187, 2914, 2890, 16191, {36899, 0, 0, 0}, 297, 297, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x340C, 0x000C, 257, 83, 16194, 16200, 16214, 16231, 2967, 2943, 16235, {36946, 0, 0, 0}, 298, 298, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x3801, 0x0001, 257, 0, 16238, 16244, 16274, 16338, 2607, 2578, 16342, {39339, 0, 0, 0}, 299, 299, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x380A, 0x000A, 257, 129, 16345, 16351, 16369, 16388, 2914, 2890, 16392, {36899, 0, 0, 0}, 300, 300, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x380C, 0x000C, 257, 78, 16395, 16401, 16418, 16436, 2967, 2943, 14278, {36946, 0, 0, 0}, 301, 301, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x3C01, 0x0001, 257, 12, 16440, 16446, 16463, 16495, 2607, 2578, 16499, {39339, 0, 0, 0}, 302, 302, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x3C09, 0x0009, 257, 48, 16502, 16508, 16508, 16538, 2886, 2871, 13157, {36880, 0, 0, 0}, 303, 303, { 1252, 500, 10000, 850, 0, ',' }},
-       {0x3C0A, 0x000A, 257, 104, 16542, 16548, 16567, 16587, 2914, 2890, 16591, {36899, 0, 0, 0}, 304, 304, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x3C0C, 0x000C, 257, 51, 16594, 16600, 16615, 16634, 2967, 2943, 16638, {36946, 0, 0, 0}, 305, 305, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x4001, 0x0001, 257, 105, 16641, 16647, 16662, 16686, 2607, 2578, 16690, {39339, 0, 0, 0}, 306, 306, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x4009, 0x0009, 257, 56, 16693, 16699, 16699, 16715, 2886, 2871, 8904, {36880, 0, 0, 0}, 307, 307, { 1252, 37, 10000, 437, 0, ',' }},
-       {0x400A, 0x000A, 257, 14, 16719, 16725, 16743, 16762, 2914, 2890, 16766, {36899, 0, 0, 0}, 308, 308, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x4409, 0x0009, 257, 89, 16769, 16775, 16775, 16794, 2886, 2871, 9048, {36880, 0, 0, 0}, 309, 309, { 1252, 37, 10000, 437, 0, ',' }},
-       {0x440A, 0x000A, 257, 118, 16798, 16804, 16826, 16849, 2914, 2890, 16853, {36899, 0, 0, 0}, 310, 310, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x4809, 0x0009, 257, 113, 16856, 16862, 16862, 16882, 2886, 2871, 13515, {36880, 0, 0, 0}, 311, 311, { 1252, 37, 10000, 437, 0, ',' }},
-       {0x480A, 0x000A, 257, 49, 16886, 16892, 16911, 16931, 2914, 2890, 16935, {36899, 0, 0, 0}, 312, 312, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x4C0A, 0x000A, 257, 91, 16938, 16944, 16964, 16985, 2914, 2890, 16989, {36899, 0, 0, 0}, 313, 313, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x500A, 0x000A, 257, 102, 16992, 16998, 17020, 17043, 2914, 2890, 17047, {36899, 0, 0, 0}, 314, 314, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x540A, 0x000A, 257, 128, 17050, 17056, 17080, 17106, 2914, 2890, 6542, {36899, 0, 0, 0}, 315, 315, { 1252, 20284, 10000, 850, 0, ',' }},
-       {0x5C0A, 0x000A, 257, 28, 17110, 17116, 17131, 17147, 2914, 2890, 17151, {36899, 0, 0, 0}, 316, 316, { 1252, 20284, 10000, 850, 0, ';' }},
-       {0x641A, 0x781A, 257, -1, 17154, 17162, 17181, 14985, 14214, 14218, 0, {37712, 0, 0, 0}, 317, 317, { 1251, 870, 10082, 855, 0, ';' }},
-       {0x681A, 0x781A, 257, -1, 17190, 17198, 17181, 14210, 14214, 14218, 0, {37251, 0, 0, 0}, 318, 318, { 1250, 870, 10082, 852, 0, ';' }},
-       {0x6C1A, 0x7C1A, 257, -1, 17214, 17222, 17241, 15514, 14511, 14515, 0, {39477, 0, 0, 0}, 319, 319, { 1251, 21025, 10007, 855, 0, ';' }},
-       {0x701A, 0x7C1A, 257, -1, 17254, 17262, 17241, 15226, 14511, 14515, 0, {37251, 0, 0, 0}, 320, 320, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x703B, 0x003B, 257, -1, 15289, 17278, 17289, 15285, 15289, 15289, 0, {0, 0, 0, 0}, 321, 321, { 1252, 20278, 10000, 850, 0, ';' }},
-       {0x742C, 0x002C, 257, -1, 17304, 17312, 3930, 12374, 3946, 3915, 0, {37652, 0, 0, 0}, 322, 322, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x7804, 0x007F, 257, -1, 2722, 2686, 2707, 2714, 2718, 2722, 0, {36759, 0, 0, 0}, 323, 323, { 936, 500, 10008, 936, 0, ',' }},
-       {0x7814, 0x0014, 257, -1, 12060, 17335, 17353, 12052, 12056, 12060, 0, {36792, 0, 0, 0}, 324, 324, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x781A, 0x007F, 257, -1, 14218, 17361, 17181, 14210, 14214, 14218, 0, {37251, 0, 0, 0}, 325, 325, { 1250, 870, 10082, 852, 0, ';' }},
-       {0x782C, 0x002C, 257, -1, 17369, 17377, 3930, 3942, 3946, 3915, 0, {37652, 0, 0, 0}, 326, 326, { 1254, 20905, 10081, 857, 0, ';' }},
-       {0x7843, 0x0043, 257, -1, 17397, 17405, 4590, 12667, 4603, 4581, 0, {39417, 0, 0, 0}, 327, 327, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x7850, 0x0050, 257, -1, 17422, 17430, 4985, 9932, 5002, 4972, 0, {38692, 0, 0, 0}, 328, 328, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x7C04, 0x7804, 257, -1, 17451, 6259, 2707, 6297, 2718, 2722, 0, {39332, 0, 0, 0}, 329, 329, { 950, 500, 10002, 950, 0, ',' }},
-       {0x7C04, 0x7C04, 257, -1, 17459, 17466, 2707, 6297, 2718, 2722, 0, {39332, 0, 0, 0}, 330, 330, { 950, 500, 10002, 950, 0, ',' }},
-       {0x7C14, 0x0014, 257, -1, 3200, 17495, 17513, 3192, 3196, 3200, 0, {36792, 0, 0, 0}, 331, 331, { 1252, 20277, 10000, 850, 0, ';' }},
-       {0x7C1A, 0x007F, 257, -1, 14515, 17527, 17241, 17535, 14511, 14515, 0, {39477, 0, 0, 0}, 332, 332, { 1250, 500, 10029, 852, 0, ';' }},
-       {0x7C28, 0x0028, 257, -1, 17539, 17547, 3792, 3805, 3809, 3783, 0, {0, 0, 0, 0}, 333, 333, { 1251, 20880, 10007, 866, 0, ';' }},
-       {0x7C2E, 0x002E, 257, -1, 12439, 17564, 17578, 12435, 12439, 12439, 0, {39394, 0, 0, 0}, 334, 334, { 1252, 870, 10000, 850, 0, ';' }},
-       {0x7C43, 0x0043, 257, -1, 17595, 17603, 4590, 4599, 4603, 4581, 0, {38146, 0, 0, 0}, 335, 335, { 1254, 500, 10029, 857, 0, ';' }},
-       {0x7C46, 0x0046, 257, -1, 17617, 17625, 4652, 12831, 4675, 4641, 0, {38235, 0, 0, 0}, 336, 336, { 1256, 20420, 10004, 720, 1, ';' }},
-       {0x7C5F, 0x005F, 257, -1, 17642, 17651, 5352, 5375, 5324, 5324, 0, {0, 0, 0, 0}, 337, 337, { 1252, 20297, 10000, 850, 0, ';' }},
-       {0x7C68, 0x0068, 257, -1, 17683, 17691, 5525, 5531, 5535, 5522, 0, {0, 0, 0, 0}, 338, 338, { 1252, 37, 10000, 437, 0, ';' }}
+       {0x0001, 0x007F, 768, -1, 2532, 2535, 2542, 2557, 2561, 2532, 0, {0, 0, 36669, 0}, 0, 0, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0002, 0x007F, 257, -1, 2565, 2568, 2578, 2597, 2601, 2565, 0, {36697, 0, 0, 0}, 1, 1, { 1251, 21025, 10007, 866, 0, ';' }},
+       {0x0003, 0x007F, 257, -1, 2605, 2608, 2616, 2624, 2628, 2605, 0, {36739, 0, 0, 0}, 2, 2, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0004, 0x7804, 257, -1, 2632, 2640, 2661, 2668, 2672, 2676, 0, {36759, 0, 0, 0}, 3, 3, { 936, 500, 10008, 936, 0, ',' }},
+       {0x0004, 0x0004, 257, -1, 2679, 2686, 2661, 2668, 2672, 2676, 0, {36759, 0, 0, 0}, 4, 4, { 936, 500, 10008, 936, 0, ',' }},
+       {0x0005, 0x007F, 257, -1, 2714, 2717, 2723, 2733, 2737, 2714, 0, {36766, 0, 0, 0}, 5, 5, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x0006, 0x007F, 257, -1, 2741, 2744, 2751, 2757, 2761, 2741, 0, {36792, 0, 0, 0}, 6, 6, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0007, 0x007F, 257, -1, 2765, 2768, 2775, 2783, 2787, 2765, 0, {36813, 0, 0, 0}, 7, 7, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0008, 0x007F, 257, -1, 2791, 2794, 2800, 2817, 2821, 2791, 0, {36838, 0, 0, 0}, 8, 8, { 1253, 20273, 10006, 737, 0, ';' }},
+       {0x0009, 0x007F, 257, -1, 2825, 2828, 2828, 2836, 2840, 2825, 0, {36880, 0, 0, 0}, 9, 9, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x000A, 0x007F, 257, -1, 2844, 2847, 2855, 2864, 2868, 2844, 0, {36899, 0, 0, 0}, 10, 10, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x000B, 0x007F, 257, -1, 2872, 2875, 2883, 2889, 2893, 2872, 0, {36921, 0, 0, 0}, 11, 11, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x000C, 0x007F, 257, -1, 2897, 2900, 2907, 2917, 2921, 2897, 0, {36946, 0, 0, 0}, 12, 12, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x000D, 0x007F, 257, -1, 2925, 2928, 2935, 2946, 2950, 2925, 0, {36968, 0, 0, 0}, 13, 13, { 1255, 500, 10005, 862, 1, ',' }},
+       {0x000E, 0x007F, 257, -1, 2954, 2957, 2967, 2974, 2978, 2954, 0, {37005, 0, 0, 0}, 14, 14, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x000F, 0x007F, 257, -1, 2982, 2985, 2995, 3005, 3009, 2982, 0, {37021, 0, 0, 0}, 15, 15, { 1252, 20871, 10079, 850, 0, ';' }},
+       {0x0010, 0x007F, 257, -1, 3013, 3016, 3024, 3033, 3037, 3013, 0, {37041, 0, 0, 0}, 16, 16, { 1252, 20280, 10000, 850, 0, ';' }},
+       {0x0011, 0x007F, 257, -1, 3041, 3044, 3053, 3063, 3067, 3041, 0, {37063, 0, 0, 0}, 17, 17, { 932, 20290, 10001, 932, 0, ',' }},
+       {0x0012, 0x007F, 257, -1, 3071, 3074, 3081, 3091, 3095, 3071, 0, {37090, 0, 0, 0}, 18, 18, { 949, 20833, 10003, 949, 0, ',' }},
+       {0x0013, 0x007F, 257, -1, 3099, 3102, 3108, 3119, 3123, 3099, 0, {37097, 0, 0, 0}, 19, 19, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0014, 0x007F, 257, -1, 3127, 3130, 3140, 3146, 3150, 3154, 0, {36792, 0, 0, 0}, 20, 20, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0015, 0x007F, 257, -1, 3157, 3160, 3167, 3174, 3178, 3157, 0, {37119, 0, 0, 0}, 21, 21, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0016, 0x007F, 257, -1, 3182, 3185, 3196, 3207, 3211, 3182, 0, {37143, 0, 0, 0}, 22, 22, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0017, 0x007F, 257, -1, 3215, 3218, 3226, 3236, 3240, 3215, 0, {37166, 0, 0, 0}, 23, 23, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0018, 0x007F, 257, -1, 3244, 3247, 3256, 3265, 3269, 3244, 0, {37186, 0, 0, 0}, 24, 24, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0019, 0x007F, 257, -1, 3273, 3276, 3284, 3299, 3303, 3273, 0, {37205, 0, 0, 0}, 25, 25, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x001A, 0x007F, 257, -1, 3307, 3310, 3319, 3328, 3332, 3307, 0, {37251, 0, 0, 0}, 26, 26, { 1250, 500, 10082, 852, 0, ';' }},
+       {0x001B, 0x007F, 257, -1, 3336, 3339, 3346, 3358, 3362, 3336, 0, {37274, 0, 0, 0}, 27, 27, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x001C, 0x007F, 257, -1, 3366, 3369, 3378, 3384, 3388, 3366, 0, {37298, 0, 0, 0}, 28, 28, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x001D, 0x007F, 257, -1, 3392, 3395, 3403, 3411, 3415, 3392, 0, {36792, 0, 0, 0}, 29, 29, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x001E, 0x007F, 512, -1, 3419, 3422, 3427, 3437, 3441, 3419, 0, {0, 37317, 0, 0}, 30, 30, { 874, 20838, 10021, 874, 0, ',' }},
+       {0x001F, 0x007F, 257, -1, 3445, 3448, 3456, 3465, 3469, 3445, 0, {37348, 0, 0, 0}, 31, 31, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x0020, 0x007F, 257, -1, 3473, 3476, 3481, 3490, 3494, 3473, 0, {37362, 0, 0, 0}, 32, 32, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0021, 0x007F, 257, -1, 3498, 3501, 3512, 3522, 3526, 3498, 0, {37392, 0, 0, 0}, 33, 33, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0022, 0x007F, 257, -1, 3530, 3533, 3543, 3564, 3568, 3530, 0, {37411, 0, 0, 0}, 34, 34, { 1251, 500, 10017, 866, 0, ';' }},
+       {0x0023, 0x007F, 257, -1, 3572, 3575, 3586, 3607, 3611, 3572, 0, {37457, 0, 0, 0}, 35, 35, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0024, 0x007F, 257, -1, 3615, 3618, 3628, 3642, 3646, 3615, 0, {37499, 0, 0, 0}, 36, 36, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0025, 0x007F, 257, -1, 3650, 3653, 3662, 3668, 3672, 3650, 0, {37521, 0, 0, 0}, 37, 37, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0026, 0x007F, 257, -1, 3676, 3679, 3687, 3697, 3701, 3676, 0, {37541, 0, 0, 0}, 38, 38, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0027, 0x007F, 257, -1, 3705, 3708, 3719, 3729, 3733, 3705, 0, {37560, 0, 0, 0}, 39, 39, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0028, 0x007F, 257, -1, 3737, 3740, 3746, 3759, 3763, 3737, 0, {0, 0, 0, 0}, 40, 40, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0029, 0x007F, 257, -1, 3767, 3770, 3778, 3789, 3793, 3767, 0, {37583, 0, 0, 0}, 41, 41, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x002A, 0x007F, 257, -1, 3797, 3800, 3811, 3826, 3830, 3797, 0, {37607, 0, 0, 0}, 42, 42, { 1258, 500, 10000, 1258, 0, ',' }},
+       {0x002B, 0x007F, 257, -1, 3834, 3837, 3846, 3861, 3865, 3834, 0, {37622, 0, 0, 0}, 43, 43, { 0, 500, 2, 1, 0, ',' }},
+       {0x002C, 0x007F, 257, -1, 3869, 3872, 3884, 3896, 3900, 3869, 0, {37652, 0, 0, 0}, 44, 44, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x002D, 0x007F, 257, -1, 3904, 3907, 3914, 3922, 3926, 3904, 0, {37671, 0, 0, 0}, 45, 45, { 1252, 500, 2, 850, 0, ';' }},
+       {0x002E, 0x007F, 257, -1, 3930, 3934, 3948, 3966, 3930, 3930, 0, {37691, 0, 0, 0}, 46, 46, { 1252, 870, 10000, 850, 0, ';' }},
+       {0x002F, 0x007F, 257, -1, 3970, 3973, 3984, 4005, 4009, 3970, 0, {37712, 0, 0, 0}, 47, 47, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0030, 0x007F, 257, -1, 4013, 4016, 4031, 4039, 4043, 4013, 0, {0, 0, 0, 0}, 48, 48, { 0, 500, 2, 1, 0, ';' }},
+       {0x0031, 0x007F, 257, -1, 4047, 4050, 4057, 4066, 4070, 4047, 0, {0, 0, 0, 0}, 49, 49, { 0, 500, 2, 1, 0, ';' }},
+       {0x0032, 0x007F, 257, -1, 4074, 4077, 4084, 4093, 4097, 4074, 0, {0, 0, 0, 0}, 50, 50, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0034, 0x007F, 257, -1, 4101, 4104, 4110, 4119, 4123, 4101, 0, {0, 0, 0, 0}, 51, 51, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0035, 0x007F, 257, -1, 4127, 4130, 4135, 4143, 4147, 4127, 0, {37756, 0, 0, 0}, 52, 52, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0036, 0x007F, 257, -1, 4151, 4154, 4154, 4164, 4168, 4151, 0, {37781, 0, 0, 0}, 53, 53, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0037, 0x007F, 257, -1, 4172, 4175, 4184, 4206, 4210, 4172, 0, {37801, 0, 0, 0}, 54, 54, { 0, 500, 2, 1, 0, ';' }},
+       {0x0038, 0x007F, 257, -1, 4214, 4217, 4225, 4235, 4239, 4214, 0, {37866, 0, 0, 0}, 55, 55, { 1252, 20277, 10079, 850, 0, ';' }},
+       {0x0039, 0x007F, 257, -1, 4243, 4246, 4252, 4271, 4275, 4243, 0, {37890, 0, 0, 0}, 56, 56, { 0, 500, 2, 1, 0, ',' }},
+       {0x003A, 0x007F, 257, -1, 4279, 4282, 4290, 4296, 4300, 4279, 0, {37943, 0, 0, 0}, 57, 57, { 0, 500, 2, 1, 0, ';' }},
+       {0x003B, 0x007F, 257, -1, 4304, 4307, 4321, 4338, 4342, 4304, 0, {37964, 0, 0, 0}, 58, 58, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x003C, 0x007F, 257, -1, 4346, 4349, 4355, 4363, 4367, 4346, 0, {37983, 0, 0, 0}, 59, 59, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x003E, 0x007F, 257, -1, 4371, 4374, 4380, 4394, 4398, 4371, 0, {38004, 0, 0, 0}, 60, 60, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x003F, 0x007F, 257, -1, 4402, 4405, 4412, 4432, 4436, 4402, 0, {38021, 0, 0, 0}, 61, 61, { 0, 500, 2, 1, 0, ';' }},
+       {0x0040, 0x007F, 257, -1, 4440, 4443, 4450, 4467, 4471, 4440, 0, {38063, 0, 0, 0}, 62, 62, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0041, 0x007F, 257, -1, 4475, 4478, 4486, 4496, 4500, 4475, 0, {38103, 0, 0, 0}, 63, 63, { 1252, 500, 10000, 437, 0, ';' }},
+       {0x0042, 0x007F, 257, -1, 4504, 4507, 4515, 4527, 4531, 4504, 0, {38124, 0, 0, 0}, 64, 64, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0043, 0x007F, 257, -1, 4535, 4538, 4544, 4553, 4557, 4535, 0, {38146, 0, 0, 0}, 65, 65, { 1254, 500, 10029, 857, 0, ';' }},
+       {0x0045, 0x007F, 257, -1, 4561, 4564, 4571, 4587, 4591, 4561, 0, {38164, 0, 0, 0}, 66, 66, { 0, 500, 2, 1, 0, ',' }},
+       {0x0046, 0x007F, 257, -1, 4595, 4598, 4606, 4625, 4629, 4595, 0, {38235, 0, 0, 0}, 67, 67, { 0, 500, 2, 1, 0, ',' }},
+       {0x0047, 0x007F, 257, -1, 4633, 4636, 4645, 4667, 4671, 4633, 0, {38282, 0, 0, 0}, 68, 68, { 0, 500, 2, 1, 0, ',' }},
+       {0x0048, 0x007F, 257, -1, 4675, 4678, 4683, 4699, 4703, 4675, 0, {0, 0, 0, 0}, 69, 69, { 0, 500, 2, 1, 0, ',' }},
+       {0x0049, 0x007F, 257, -1, 4707, 4710, 4716, 4732, 4736, 4707, 0, {38338, 0, 0, 0}, 70, 70, { 0, 500, 2, 1, 0, ',' }},
+       {0x004A, 0x007F, 257, -1, 4740, 4743, 4750, 4769, 4773, 4740, 0, {38403, 0, 0, 0}, 71, 71, { 0, 500, 2, 1, 0, ',' }},
+       {0x004B, 0x007F, 257, -1, 1701, 4777, 4785, 4801, 4805, 1701, 0, {38468, 0, 0, 0}, 72, 72, { 0, 500, 2, 1, 0, ',' }},
+       {0x004C, 0x007F, 257, -1, 4809, 4812, 4822, 4841, 4845, 4809, 0, {38533, 0, 0, 0}, 73, 73, { 0, 500, 2, 1, 0, ',' }},
+       {0x004D, 0x007F, 257, -1, 4849, 4852, 4861, 4883, 4887, 4849, 0, {38577, 0, 0, 0}, 74, 74, { 0, 500, 2, 1, 0, ',' }},
+       {0x004E, 0x007F, 257, -1, 4891, 4894, 4902, 4918, 4922, 4891, 0, {38630, 0, 0, 0}, 75, 75, { 0, 500, 2, 1, 0, ',' }},
+       {0x0050, 0x007F, 257, -1, 4926, 4929, 4939, 4952, 4956, 4926, 0, {38692, 0, 0, 0}, 76, 76, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0051, 0x007F, 257, -1, 4960, 4963, 4971, 4996, 5000, 4960, 0, {0, 0, 0, 0}, 77, 77, { 0, 500, 2, 1, 0, ',' }},
+       {0x0052, 0x007F, 257, -1, 5004, 5007, 5013, 5021, 5025, 5004, 0, {38724, 0, 0, 0}, 78, 78, { 1252, 20285, 10000, 850, 0, ';' }},
+       {0x0053, 0x007F, 257, -1, 5029, 5032, 5038, 5054, 5058, 5029, 0, {38740, 0, 0, 0}, 79, 79, { 0, 500, 2, 1, 0, ',' }},
+       {0x0054, 0x007F, 257, -1, 5062, 5065, 5069, 5079, 5083, 5062, 0, {38795, 0, 0, 0}, 80, 80, { 0, 500, 2, 1, 0, ';' }},
+       {0x0055, 0x007F, 257, -1, 5087, 5090, 5098, 5117, 5121, 5087, 0, {38841, 0, 0, 0}, 81, 81, { 0, 500, 2, 1, 0, ';' }},
+       {0x0056, 0x007F, 257, -1, 5125, 5128, 5137, 5144, 5148, 5125, 0, {36899, 0, 0, 0}, 82, 82, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0057, 0x007F, 257, -1, 5152, 5156, 5164, 5183, 5152, 5152, 0, {0, 0, 0, 0}, 83, 83, { 0, 500, 2, 1, 0, ',' }},
+       {0x005B, 0x007F, 257, -1, 5187, 5190, 5198, 5214, 5218, 5187, 0, {38912, 0, 0, 0}, 84, 84, { 0, 500, 2, 1, 0, ';' }},
+       {0x005C, 0x007F, 257, -1, 5222, 5226, 5235, 5245, 5222, 5222, 0, {38978, 0, 0, 0}, 85, 85, { 0, 500, 2, 1, 0, ',' }},
+       {0x005E, 0x007F, 257, -1, 5, 5249, 5257, 5270, 5274, 5, 0, {39017, 0, 0, 0}, 86, 86, { 0, 500, 2, 1, 0, ';' }},
+       {0x005F, 0x007F, 257, -1, 5278, 5282, 5306, 5329, 5278, 5278, 0, {0, 0, 0, 0}, 87, 87, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0061, 0x007F, 257, -1, 5333, 5336, 5343, 5362, 5366, 5333, 0, {39065, 0, 0, 0}, 88, 88, { 0, 500, 2, 1, 0, ',' }},
+       {0x0062, 0x007F, 257, -1, 5370, 5373, 5389, 5400, 5404, 5370, 0, {39115, 0, 0, 0}, 89, 89, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0063, 0x007F, 1024, -1, 5408, 5411, 5418, 5427, 5431, 5408, 0, {0, 0, 0, 0}, 90, 90, { 0, 500, 2, 1, 1, ';' }},
+       {0x0064, 0x007F, 257, -1, 5435, 5439, 5439, 5448, 5435, 5435, 0, {39138, 0, 0, 0}, 91, 91, { 1252, 500, 10000, 437, 0, ';' }},
+       {0x0067, 0x007F, 257, -1, 5452, 5455, 5461, 5468, 5472, 5452, 0, {0, 0, 0, 0}, 92, 92, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0068, 0x007F, 257, -1, 5476, 5479, 5479, 5485, 5489, 5476, 0, {0, 0, 0, 0}, 93, 93, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x006A, 0x007F, 257, -1, 5493, 5496, 5503, 5518, 5522, 5493, 0, {0, 0, 0, 0}, 94, 94, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x006C, 0x007F, 257, -1, 5526, 5530, 5545, 5562, 5526, 5526, 0, {0, 0, 0, 0}, 95, 95, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x006E, 0x007F, 257, -1, 5566, 5569, 5583, 5599, 5603, 5566, 0, {39162, 0, 0, 0}, 96, 96, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x006F, 0x007F, 257, -1, 5607, 5610, 5622, 5634, 5638, 5607, 0, {39186, 0, 0, 0}, 97, 97, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0070, 0x007F, 257, -1, 5642, 5645, 5645, 5650, 5654, 5642, 0, {0, 0, 0, 0}, 98, 98, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0072, 0x007F, 257, -1, 5658, 5661, 5667, 5674, 5678, 5658, 0, {0, 0, 0, 0}, 99, 99, { 0, 500, 2, 1, 0, ';' }},
+       {0x0073, 0x007F, 257, -1, 5682, 5685, 5694, 5707, 5711, 5682, 0, {0, 0, 0, 0}, 100, 100, { 0, 500, 2, 1, 0, ';' }},
+       {0x0075, 0x007F, 257, -1, 5715, 5719, 5728, 5746, 5715, 5715, 0, {0, 0, 0, 0}, 101, 101, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0077, 0x007F, 257, -1, 5750, 5753, 5760, 5769, 5773, 5750, 0, {0, 0, 0, 0}, 102, 102, { 0, 500, 2, 1, 0, ';' }},
+       {0x0078, 0x007F, 257, -1, 5777, 5780, 5791, 5801, 5805, 5777, 0, {39213, 0, 0, 0}, 103, 103, { 0, 500, 2, 1, 0, ';' }},
+       {0x007E, 0x007F, 257, -1, 5809, 5812, 5819, 5829, 5833, 5809, 0, {39226, 0, 0, 0}, 104, 104, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0080, 0x007F, 257, -1, 5837, 5840, 5847, 5864, 5868, 5837, 0, {39246, 0, 0, 0}, 105, 105, { 1256, 20420, 10004, 720, 1, ',' }},
+       {0x0084, 0x007F, 257, -1, 5872, 5876, 5889, 5908, 5872, 5872, 0, {39282, 0, 0, 0}, 106, 106, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0085, 0x007F, 257, -1, 5912, 5916, 5922, 5940, 5912, 5912, 0, {0, 0, 0, 0}, 107, 107, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0087, 0x007F, 257, -1, 5944, 5947, 5947, 5959, 5963, 5944, 0, {0, 0, 0, 0}, 108, 108, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0091, 0x007F, 257, -1, 5967, 5970, 5986, 5996, 6000, 5967, 0, {39307, 0, 0, 0}, 109, 109, { 1252, 20285, 10000, 850, 0, ';' }},
+       {0x0401, 0x0001, 768, 111, 6004, 6010, 6032, 2557, 2561, 2532, 297, {0, 0, 36669, 0}, 110, 110, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0402, 0x0002, 257, 11, 6096, 6102, 6123, 2597, 2601, 2565, 6161, {36697, 0, 0, 0}, 111, 111, { 1251, 21025, 10007, 866, 0, ';' }},
+       {0x0403, 0x0003, 257, 38, 6164, 6170, 6186, 2624, 2628, 2605, 6204, {36739, 0, 0, 0}, 112, 112, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0404, 0x7C04, 257, 126, 6207, 6213, 6235, 6251, 2672, 2676, 6255, {39332, 0, 0, 0}, 113, 113, { 950, 500, 10002, 950, 0, ',' }},
+       {0x0405, 0x0005, 257, 29, 6258, 6264, 6287, 2733, 2737, 2714, 6317, {36766, 0, 0, 0}, 114, 114, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x0406, 0x0006, 257, 31, 6320, 6326, 6343, 2757, 2761, 2741, 6359, {36792, 0, 0, 0}, 115, 115, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0407, 0x0007, 257, 30, 6362, 6368, 6385, 2783, 2787, 2765, 6407, {36813, 0, 0, 0}, 116, 116, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0408, 0x0008, 257, 46, 6410, 6416, 6431, 2817, 2821, 2791, 6463, {36838, 0, 0, 0}, 117, 117, { 1253, 20273, 10006, 737, 0, ';' }},
+       {0x0409, 0x0009, 257, 128, 6466, 6472, 6472, 2836, 2840, 2825, 6496, {36880, 0, 0, 0}, 118, 118, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x040B, 0x000B, 257, 40, 6499, 6505, 6523, 2889, 2893, 2872, 6537, {36921, 0, 0, 0}, 119, 119, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x040C, 0x000C, 257, 42, 6540, 6546, 6562, 2917, 2921, 2897, 6581, {36946, 0, 0, 0}, 120, 120, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x040D, 0x000D, 257, 55, 6584, 6590, 6606, 2946, 2950, 2925, 6630, {36968, 0, 0, 0}, 121, 121, { 1255, 500, 10005, 862, 1, ',' }},
+       {0x040E, 0x000E, 257, 52, 6633, 6639, 6659, 2974, 2978, 2954, 6682, {37005, 0, 0, 0}, 122, 122, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x040F, 0x000F, 257, 59, 6685, 6691, 6711, 3005, 3009, 2982, 6731, {37021, 0, 0, 0}, 123, 123, { 1252, 20871, 10079, 850, 0, ';' }},
+       {0x0410, 0x0010, 257, 60, 6734, 6740, 6756, 3033, 3037, 3013, 6774, {37041, 0, 0, 0}, 124, 124, { 1252, 20280, 10000, 850, 0, ';' }},
+       {0x0411, 0x0011, 257, 63, 6777, 6783, 6800, 3063, 3067, 3041, 6819, {37063, 0, 0, 0}, 125, 125, { 932, 20290, 10001, 932, 0, ',' }},
+       {0x0412, 0x0012, 257, 67, 6822, 6828, 6849, 3091, 3095, 3071, 6874, {37090, 0, 0, 0}, 126, 126, { 949, 20833, 10003, 949, 0, ',' }},
+       {0x0413, 0x0013, 257, 92, 6877, 6883, 6903, 3119, 3123, 3099, 6926, {37097, 0, 0, 0}, 127, 127, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0414, 0x7C14, 257, 93, 6929, 6935, 6962, 3146, 3150, 3154, 6984, {36792, 0, 0, 0}, 128, 128, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0415, 0x0015, 257, 101, 6987, 6993, 7009, 3174, 3178, 3157, 7025, {37119, 0, 0, 0}, 129, 129, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0416, 0x0016, 257, 15, 7028, 7034, 7054, 3207, 3211, 3182, 7074, {37143, 0, 0, 0}, 130, 130, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0417, 0x0017, 257, 21, 7077, 7083, 7105, 3236, 3240, 3215, 300, {37166, 0, 0, 0}, 131, 131, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0418, 0x0018, 257, 107, 7124, 7130, 7149, 3265, 3269, 3244, 7169, {37186, 0, 0, 0}, 132, 132, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0419, 0x0019, 257, 109, 7172, 7178, 7195, 3299, 3303, 3273, 7225, {37205, 0, 0, 0}, 133, 133, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x041A, 0x001A, 257, 50, 7228, 7234, 7253, 3328, 3332, 3307, 7273, {37251, 0, 0, 0}, 134, 134, { 1250, 500, 10082, 852, 0, ';' }},
+       {0x041B, 0x001B, 257, 115, 7276, 7282, 7300, 3358, 3362, 3336, 7324, {37274, 0, 0, 0}, 135, 135, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x041C, 0x001C, 257, 2, 7327, 7333, 7352, 3384, 3388, 3366, 7370, {37298, 0, 0, 0}, 136, 136, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x041D, 0x001D, 257, 112, 7373, 7379, 7396, 3411, 3415, 3392, 7414, {36792, 0, 0, 0}, 137, 137, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x041E, 0x001E, 512, 120, 7417, 7423, 7439, 3437, 3441, 3419, 7461, {0, 37317, 0, 0}, 138, 138, { 874, 20838, 10021, 874, 0, ',' }},
+       {0x041F, 0x001F, 257, 124, 7464, 7470, 7487, 3465, 3469, 3445, 7507, {37348, 0, 0, 0}, 139, 139, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x0420, 0x0020, 257, 100, 7510, 7516, 7532, 3490, 3494, 3473, 7558, {37362, 0, 0, 0}, 140, 140, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0421, 0x0021, 257, 53, 7561, 7567, 7590, 3522, 3526, 3498, 7612, {37392, 0, 0, 0}, 141, 141, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0422, 0x0022, 257, 127, 7615, 7621, 7641, 3564, 3568, 3530, 7679, {37411, 0, 0, 0}, 142, 142, { 1251, 500, 10017, 866, 0, ';' }},
+       {0x0423, 0x0023, 257, 17, 7682, 7688, 7709, 3607, 3611, 3572, 7749, {37457, 0, 0, 0}, 143, 143, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0424, 0x0024, 257, 114, 7752, 7758, 7779, 3642, 3646, 3615, 7805, {37499, 0, 0, 0}, 144, 144, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0425, 0x0025, 257, 35, 7808, 7814, 7833, 3668, 3672, 3650, 7847, {37521, 0, 0, 0}, 145, 145, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0426, 0x0026, 257, 76, 7850, 7856, 7873, 3697, 3701, 3676, 7893, {37541, 0, 0, 0}, 146, 146, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0427, 0x0027, 257, 74, 7896, 7902, 7925, 3729, 3733, 3705, 7945, {37560, 0, 0, 0}, 147, 147, { 1257, 500, 10029, 775, 0, ';' }},
+       {0x0428, 0x7C28, 257, 121, 7948, 7959, 7988, 3759, 3763, 3737, 8024, {0, 0, 0, 0}, 148, 148, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0429, 0x0029, 257, 58, 8027, 8033, 8048, 3789, 3793, 3767, 8072, {37583, 0, 0, 0}, 149, 149, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x042A, 0x002A, 257, 132, 8075, 8081, 8102, 3826, 3830, 3797, 8130, {37607, 0, 0, 0}, 150, 150, { 1258, 500, 10000, 1258, 0, ',' }},
+       {0x042B, 0x002B, 257, 3, 8133, 8139, 8158, 3861, 3865, 3834, 49, {37622, 0, 0, 0}, 151, 151, { 0, 500, 2, 1, 0, ',' }},
+       {0x042C, 0x782C, 257, 7, 8192, 8203, 8235, 3896, 3900, 3869, 8261, {37652, 0, 0, 0}, 152, 152, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x042D, 0x002D, 257, 38, 8264, 8270, 8285, 3922, 3926, 3904, 6204, {37671, 0, 0, 0}, 153, 153, { 1252, 500, 2, 850, 0, ';' }},
+       {0x042E, 0x002E, 257, 30, 8304, 8311, 8335, 3966, 3930, 3930, 6407, {37691, 0, 0, 0}, 154, 154, { 1252, 870, 10000, 850, 0, ';' }},
+       {0x042F, 0x002F, 257, 82, 8363, 8369, 8392, 4005, 4009, 3970, 8436, {37712, 0, 0, 0}, 155, 155, { 1251, 500, 10007, 866, 0, ';' }},
+       {0x0430, 0x0030, 257, 134, 8439, 8445, 4031, 4039, 4043, 4013, 8475, {0, 0, 0, 0}, 156, 156, { 0, 500, 2, 1, 0, ';' }},
+       {0x0431, 0x0031, 257, 134, 8478, 8484, 4057, 4066, 4070, 4047, 8475, {0, 0, 0, 0}, 157, 157, { 0, 500, 2, 1, 0, ';' }},
+       {0x0432, 0x0032, 257, 134, 8506, 8512, 4084, 4093, 4097, 4074, 8475, {0, 0, 0, 0}, 158, 158, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0434, 0x0034, 257, 134, 8534, 8540, 4110, 4119, 4123, 4101, 8475, {0, 0, 0, 0}, 159, 159, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0435, 0x0035, 257, 134, 8561, 8567, 8587, 4143, 4147, 4127, 8475, {37756, 0, 0, 0}, 160, 160, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0436, 0x0036, 257, 134, 8612, 8618, 8643, 4164, 4168, 4151, 8475, {37781, 0, 0, 0}, 161, 161, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0437, 0x0037, 257, 44, 8667, 8673, 8692, 4206, 4210, 4172, 8747, {37801, 0, 0, 0}, 162, 162, { 0, 500, 2, 1, 0, ';' }},
+       {0x0438, 0x0038, 257, 41, 8750, 8756, 8780, 4235, 4239, 4214, 8801, {37866, 0, 0, 0}, 163, 163, { 1252, 20277, 10079, 850, 0, ';' }},
+       {0x0439, 0x0039, 257, 56, 8804, 8810, 8824, 4271, 4275, 4243, 8858, {37890, 0, 0, 0}, 164, 164, { 0, 500, 2, 1, 0, ',' }},
+       {0x043A, 0x003A, 257, 87, 8861, 8867, 8883, 4296, 4300, 4279, 8897, {37943, 0, 0, 0}, 165, 165, { 0, 500, 2, 1, 0, ';' }},
+       {0x043B, 0x003B, 257, 93, 8900, 8906, 8929, 4338, 4342, 4304, 6984, {37964, 0, 0, 0}, 166, 166, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x043E, 0x003E, 257, 89, 8954, 8960, 8977, 4394, 4398, 4371, 9002, {38004, 0, 0, 0}, 167, 167, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x043F, 0x003F, 257, 69, 9005, 9011, 9031, 4432, 4436, 4402, 9072, {38021, 0, 0, 0}, 168, 168, { 0, 500, 2, 1, 0, ';' }},
+       {0x0440, 0x0040, 257, 65, 9075, 9081, 9101, 4467, 4471, 4440, 9141, {38063, 0, 0, 0}, 169, 169, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0441, 0x0041, 257, 64, 9144, 9150, 9166, 4496, 4500, 4475, 9184, {38103, 0, 0, 0}, 170, 170, { 1252, 500, 10000, 437, 0, ';' }},
+       {0x0442, 0x0042, 257, 122, 9187, 9193, 9216, 4527, 4531, 4504, 9244, {38124, 0, 0, 0}, 171, 171, { 1250, 20880, 10029, 852, 0, ';' }},
+       {0x0443, 0x7C43, 257, 130, 9247, 9258, 9284, 4553, 4557, 4535, 9308, {38146, 0, 0, 0}, 172, 172, { 1254, 500, 10029, 857, 0, ';' }},
+       {0x0445, 0x0045, 257, 56, 9311, 9317, 9332, 4587, 4591, 4561, 8858, {38164, 0, 0, 0}, 173, 173, { 0, 500, 2, 1, 0, ',' }},
+       {0x0447, 0x0047, 257, 56, 9363, 9369, 9386, 4667, 4671, 4633, 8858, {38282, 0, 0, 0}, 174, 174, { 0, 500, 2, 1, 0, ',' }},
+       {0x0448, 0x0048, 257, 56, 9423, 9429, 9442, 4699, 4703, 4675, 8858, {0, 0, 0, 0}, 175, 175, { 0, 500, 2, 1, 0, ',' }},
+       {0x0449, 0x0049, 257, 56, 9473, 9479, 9493, 4732, 4736, 4707, 8858, {38338, 0, 0, 0}, 176, 176, { 0, 500, 2, 1, 0, ',' }},
+       {0x044A, 0x004A, 257, 56, 9533, 9539, 9554, 4769, 4773, 4740, 8858, {38403, 0, 0, 0}, 177, 177, { 0, 500, 2, 1, 0, ',' }},
+       {0x044B, 0x004B, 257, 56, 9601, 9607, 9623, 4801, 4805, 1701, 8858, {38468, 0, 0, 0}, 178, 178, { 0, 500, 2, 1, 0, ',' }},
+       {0x044C, 0x004C, 257, 56, 9654, 9660, 9678, 4841, 4845, 4809, 8858, {38533, 0, 0, 0}, 179, 179, { 0, 500, 2, 1, 0, ',' }},
+       {0x044D, 0x004D, 257, 56, 9718, 9724, 9741, 4883, 4887, 4849, 8858, {38577, 0, 0, 0}, 180, 180, { 0, 500, 2, 1, 0, ',' }},
+       {0x044E, 0x004E, 257, 56, 9778, 9784, 9800, 4918, 4922, 4891, 8858, {38630, 0, 0, 0}, 181, 181, { 0, 500, 2, 1, 0, ',' }},
+       {0x0450, 0x7850, 257, 85, 9831, 9837, 9858, 9886, 4956, 4926, 9890, {38692, 0, 0, 0}, 182, 182, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0451, 0x0051, 257, 25, 9893, 9899, 9915, 4996, 5000, 4960, 9961, {0, 0, 0, 0}, 183, 183, { 0, 500, 2, 1, 0, ',' }},
+       {0x0452, 0x0052, 257, 43, 9964, 9970, 9993, 5021, 5025, 5004, 10020, {38724, 0, 0, 0}, 184, 184, { 1252, 20285, 10000, 850, 0, ';' }},
+       {0x0453, 0x0053, 257, 66, 10023, 10029, 10046, 5054, 5058, 5029, 10086, {38740, 0, 0, 0}, 185, 185, { 0, 500, 2, 1, 0, ',' }},
+       {0x0454, 0x0054, 257, 70, 10089, 10095, 10106, 5079, 5083, 5062, 10128, {38795, 0, 0, 0}, 186, 186, { 0, 500, 2, 1, 0, ';' }},
+       {0x0455, 0x0055, 257, 84, 10131, 10137, 10163, 5117, 5121, 5087, 10203, {38841, 0, 0, 0}, 187, 187, { 0, 500, 2, 1, 0, ';' }},
+       {0x0456, 0x0056, 257, 38, 10206, 10212, 10229, 5144, 5148, 5125, 6204, {36899, 0, 0, 0}, 188, 188, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0457, 0x0057, 257, 56, 10246, 10253, 10269, 5183, 5152, 5152, 8858, {0, 0, 0, 0}, 189, 189, { 0, 500, 2, 1, 0, ',' }},
+       {0x045B, 0x005B, 257, 73, 10303, 10309, 10329, 5214, 5218, 5187, 10379, {38912, 0, 0, 0}, 190, 190, { 0, 500, 2, 1, 0, ';' }},
+       {0x045E, 0x005E, 257, 39, 10382, 10388, 10407, 5270, 5274, 5, 10438, {39017, 0, 0, 0}, 191, 191, { 0, 500, 2, 1, 0, ';' }},
+       {0x0461, 0x0061, 257, 94, 10441, 10447, 10462, 5362, 5366, 5333, 10499, {39065, 0, 0, 0}, 192, 192, { 0, 500, 2, 1, 0, ',' }},
+       {0x0462, 0x0062, 257, 92, 10502, 10508, 10538, 5400, 5404, 5370, 6926, {39115, 0, 0, 0}, 193, 193, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0463, 0x0063, 1024, 1, 10561, 10567, 10588, 5427, 5431, 5408, 10618, {0, 0, 0, 0}, 194, 194, { 0, 500, 2, 1, 1, ';' }},
+       {0x0464, 0x0064, 257, 99, 10621, 10628, 10651, 5448, 5435, 5435, 10672, {39138, 0, 0, 0}, 195, 195, { 1252, 500, 10000, 437, 0, ';' }},
+       {0x0468, 0x7C68, 257, 90, 10675, 10686, 10709, 5485, 5489, 5476, 10726, {0, 0, 0, 0}, 196, 196, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x046A, 0x006A, 257, 90, 10729, 10735, 10752, 5518, 5522, 5493, 10726, {0, 0, 0, 0}, 197, 197, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x046C, 0x006C, 257, 134, 10798, 10805, 5545, 5562, 5526, 5526, 8475, {0, 0, 0, 0}, 198, 198, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x046E, 0x006E, 257, 75, 10835, 10841, 10868, 5599, 5603, 5566, 10898, {39162, 0, 0, 0}, 199, 199, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x046F, 0x006F, 257, 45, 10901, 10907, 10931, 5634, 5638, 5607, 10962, {39186, 0, 0, 0}, 200, 200, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0470, 0x0070, 257, 90, 10965, 10971, 10971, 5650, 5654, 5642, 10726, {0, 0, 0, 0}, 201, 201, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0472, 0x0072, 257, 39, 10986, 10992, 11009, 5674, 5678, 5658, 10438, {0, 0, 0, 0}, 202, 202, { 0, 500, 2, 1, 0, ';' }},
+       {0x0473, 0x0073, 257, 39, 11029, 11035, 11055, 11086, 5711, 5682, 10438, {0, 0, 0, 0}, 203, 203, { 0, 500, 2, 1, 0, ';' }},
+       {0x0475, 0x0075, 257, 128, 11090, 11097, 11122, 5746, 5715, 5715, 6496, {0, 0, 0, 0}, 204, 204, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0477, 0x0077, 257, 117, 11165, 11171, 11188, 5769, 5773, 5750, 11210, {0, 0, 0, 0}, 205, 205, { 0, 500, 2, 1, 0, ';' }},
+       {0x0478, 0x0078, 257, 25, 11213, 11219, 11238, 5801, 5805, 5777, 9961, {39213, 0, 0, 0}, 206, 206, { 0, 500, 2, 1, 0, ';' }},
+       {0x047E, 0x007E, 257, 42, 11257, 11263, 11279, 5829, 5833, 5809, 6581, {39226, 0, 0, 0}, 207, 207, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0480, 0x0080, 257, 25, 11298, 11304, 11319, 5864, 5868, 5837, 9961, {39246, 0, 0, 0}, 208, 208, { 1256, 20420, 10004, 720, 1, ',' }},
+       {0x0484, 0x0084, 257, 42, 11349, 11356, 11378, 5908, 5872, 5872, 6581, {39282, 0, 0, 0}, 209, 209, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0485, 0x0085, 257, 109, 11410, 11417, 11432, 5940, 5912, 5912, 7225, {0, 0, 0, 0}, 210, 210, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0487, 0x0087, 257, 110, 11471, 11477, 11477, 5959, 5963, 5944, 11498, {0, 0, 0, 0}, 211, 211, { 1252, 37, 10000, 437, 0, ';' }},
+       {0x0491, 0x0091, 257, 43, 11501, 11507, 11540, 5996, 6000, 5967, 10020, {39307, 0, 0, 0}, 212, 212, { 1252, 20285, 10000, 850, 0, ';' }},
+       {0x0801, 0x0001, 257, 57, 11576, 11582, 11596, 11626, 2561, 2532, 11630, {39339, 0, 0, 0}, 213, 213, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0803, 0x0403, 257, 38, 11633, 6170, 6186, 11648, 2628, 2605, 6204, {36739, 0, 0, 0}, 214, 214, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0804, 0x0004, 257, 25, 11652, 2640, 11658, 2668, 2672, 2676, 9961, {36759, 0, 0, 0}, 215, 215, { 936, 500, 10008, 936, 0, ',' }},
+       {0x0807, 0x0007, 257, 21, 11674, 11680, 11701, 11719, 2787, 2765, 300, {36813, 0, 0, 0}, 216, 216, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0809, 0x0009, 257, 43, 11723, 11729, 11729, 11754, 2840, 2825, 10020, {36880, 0, 0, 0}, 217, 217, { 1252, 20285, 10000, 850, 0, ',' }},
+       {0x080A, 0x000A, 257, 88, 11758, 11764, 11781, 11800, 2868, 2844, 11804, {37041, 0, 0, 0}, 218, 218, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x080C, 0x000C, 257, 10, 11807, 11813, 11830, 11851, 2921, 2897, 11855, {36946, 0, 0, 0}, 219, 219, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0810, 0x0010, 257, 21, 11858, 11864, 11886, 11906, 3037, 3013, 300, {37041, 0, 0, 0}, 220, 220, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0813, 0x0013, 257, 10, 11910, 11916, 11932, 11953, 3123, 3099, 11855, {37097, 0, 0, 0}, 221, 221, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0814, 0x7814, 257, 93, 11957, 11963, 11990, 12006, 12010, 12014, 6984, {36792, 0, 0, 0}, 222, 222, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x0816, 0x0016, 257, 103, 12017, 12023, 12045, 430, 3211, 3182, 12067, {39371, 0, 0, 0}, 223, 223, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0818, 0x0018, 257, 80, 12070, 12076, 12095, 12124, 3269, 3244, 12128, {37186, 0, 0, 0}, 224, 224, { 1250, 500, 2, 852, 0, ';' }},
+       {0x0819, 0x0019, 257, 80, 12131, 12137, 12155, 12187, 3303, 3273, 12128, {37205, 0, 0, 0}, 225, 225, { 1251, 500, 2, 866, 0, ';' }},
+       {0x081D, 0x001D, 257, 40, 12191, 12197, 12215, 12233, 3415, 3392, 6537, {36792, 0, 0, 0}, 226, 226, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x0820, 0x0020, 257, 56, 12237, 12243, 12256, 12278, 3494, 3473, 8858, {37362, 0, 0, 0}, 227, 227, { 1256, 500, 2, 720, 1, ';' }},
+       {0x082C, 0x742C, 257, 7, 12282, 12293, 8235, 12328, 3900, 3869, 8261, {37652, 0, 0, 0}, 228, 228, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x082E, 0x7C2E, 257, 30, 12332, 12339, 12363, 12389, 12393, 12393, 6407, {39394, 0, 0, 0}, 229, 229, { 1252, 870, 10000, 850, 0, ';' }},
+       {0x0832, 0x0032, 257, 16, 12397, 12403, 4084, 12421, 4097, 4074, 12425, {0, 0, 0, 0}, 230, 230, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x083B, 0x003B, 257, 112, 12428, 12434, 12457, 12485, 4342, 4304, 7414, {37964, 0, 0, 0}, 231, 231, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x083C, 0x003C, 257, 54, 12489, 12495, 12511, 4363, 4367, 4346, 12527, {37983, 0, 0, 0}, 232, 232, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x083E, 0x003E, 257, 13, 12530, 12536, 12551, 12574, 4398, 4371, 12578, {38004, 0, 0, 0}, 233, 233, { 1252, 500, 10000, 850, 0, ';' }},
+       {0x0843, 0x7843, 257, 130, 12581, 12592, 9284, 12621, 4557, 4535, 9308, {39417, 0, 0, 0}, 234, 234, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x0845, 0x0045, 257, 9, 12625, 12631, 12651, 12694, 4591, 4561, 12698, {38164, 0, 0, 0}, 235, 235, { 0, 500, 2, 1, 0, ',' }},
+       {0x0846, 0x7C46, 257, 100, 12701, 12712, 12739, 12785, 4629, 4595, 7558, {38235, 0, 0, 0}, 236, 236, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0849, 0x0049, 257, 73, 12789, 12795, 12813, 12850, 4736, 4707, 10379, {38338, 0, 0, 0}, 237, 237, { 0, 500, 2, 1, 0, ';' }},
+       {0x0861, 0x0061, 257, 56, 12854, 12860, 12875, 12909, 5366, 5333, 8858, {39065, 0, 0, 0}, 238, 238, { 0, 500, 2, 1, 0, ';' }},
+       {0x0873, 0x0073, 257, 37, 12913, 12919, 12938, 5707, 5711, 5682, 12966, {0, 0, 0, 0}, 239, 239, { 0, 500, 2, 1, 0, ';' }},
+       {0x0C01, 0x0001, 257, 36, 12969, 12975, 12990, 13014, 2561, 2532, 13018, {39339, 0, 0, 0}, 240, 240, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x0C04, 0x7C04, 257, 48, 13021, 13027, 13070, 13107, 2672, 2676, 13111, {39332, 0, 0, 0}, 241, 241, { 950, 500, 10002, 950, 0, ',' }},
+       {0x0C07, 0x0007, 257, 5, 13114, 13120, 13137, 13159, 2787, 2765, 13163, {36813, 0, 0, 0}, 242, 242, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x0C09, 0x0009, 257, 6, 13166, 13172, 13172, 13192, 2840, 2825, 13196, {36880, 0, 0, 0}, 243, 243, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x0C0A, 0x000A, 257, 38, 13199, 13205, 13221, 13240, 2868, 2844, 6204, {36899, 0, 0, 0}, 244, 244, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x0C0C, 0x000C, 257, 19, 13244, 13250, 13266, 13285, 2921, 2897, 13289, {36946, 0, 0, 0}, 245, 245, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x0C3B, 0x003B, 257, 40, 13292, 13298, 13322, 13348, 4342, 4304, 6537, {39455, 0, 0, 0}, 246, 246, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x1001, 0x0001, 257, 77, 13352, 13358, 13373, 13401, 2561, 2532, 13405, {39339, 0, 0, 0}, 247, 247, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1004, 0x0004, 257, 113, 13408, 13414, 13446, 13465, 2672, 2676, 13469, {36759, 0, 0, 0}, 248, 248, { 936, 500, 10008, 936, 0, ',' }},
+       {0x1007, 0x0007, 257, 75, 13472, 13478, 13498, 13518, 2787, 2765, 10898, {36813, 0, 0, 0}, 249, 249, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x1009, 0x0009, 257, 19, 13522, 13528, 13528, 13545, 2840, 2825, 13289, {36880, 0, 0, 0}, 250, 250, { 1252, 37, 10000, 850, 0, ',' }},
+       {0x100A, 0x000A, 257, 47, 13549, 13555, 13575, 13596, 2868, 2844, 13600, {36899, 0, 0, 0}, 251, 251, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x100C, 0x000C, 257, 21, 13603, 13609, 13630, 13649, 2921, 2897, 300, {36946, 0, 0, 0}, 252, 252, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x101A, 0x001A, 257, 8, 13653, 13659, 13691, 13722, 3332, 3307, 13726, {37251, 0, 0, 0}, 253, 253, { 1250, 870, 10082, 852, 0, ';' }},
+       {0x1401, 0x0001, 257, 33, 13729, 13735, 13752, 13784, 2561, 2532, 13788, {39339, 0, 0, 0}, 254, 254, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1404, 0x7C04, 257, 86, 13791, 13797, 13836, 13873, 2672, 2676, 13877, {39332, 0, 0, 0}, 255, 255, { 950, 500, 10002, 950, 0, ',' }},
+       {0x1407, 0x0007, 257, 72, 13880, 13886, 13909, 13933, 2787, 2765, 13937, {36813, 0, 0, 0}, 256, 256, { 1252, 20273, 10000, 850, 0, ';' }},
+       {0x1409, 0x0009, 257, 95, 13940, 13946, 13946, 13968, 2840, 2825, 13972, {36880, 0, 0, 0}, 257, 257, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x140A, 0x000A, 257, 27, 13975, 13981, 14002, 14024, 2868, 2844, 14028, {36899, 0, 0, 0}, 258, 258, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x140C, 0x000C, 257, 75, 14031, 14037, 14057, 14080, 2921, 2897, 10898, {36946, 0, 0, 0}, 259, 259, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x141A, 0x681A, 257, 8, 14084, 14095, 14133, 14164, 14168, 14172, 13726, {37251, 0, 0, 0}, 260, 260, { 1250, 870, 10082, 852, 0, ';' }},
+       {0x1801, 0x0001, 257, 78, 14175, 14181, 14198, 14228, 2561, 2532, 14232, {39339, 0, 0, 0}, 261, 261, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1809, 0x0009, 257, 54, 14235, 14241, 14241, 14259, 2840, 2825, 12527, {36880, 0, 0, 0}, 262, 262, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x180A, 0x000A, 257, 97, 14263, 14269, 14286, 14305, 2868, 2844, 14309, {36899, 0, 0, 0}, 263, 263, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x180C, 0x000C, 257, 79, 14312, 14318, 14334, 14353, 2921, 2897, 14357, {36946, 0, 0, 0}, 264, 264, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x181A, 0x701A, 257, 8, 14360, 14371, 14409, 14461, 14465, 14469, 13726, {37251, 0, 0, 0}, 265, 265, { 1250, 870, 10082, 852, 0, ';' }},
+       {0x1C01, 0x0001, 257, 123, 14472, 14478, 14495, 14521, 2561, 2532, 14525, {39339, 0, 0, 0}, 266, 266, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x1C09, 0x0009, 257, 134, 14528, 14534, 14534, 14557, 2840, 2825, 8475, {36880, 0, 0, 0}, 267, 267, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x1C0A, 0x000A, 257, 32, 14561, 14567, 14596, 14629, 2868, 2844, 14633, {36899, 0, 0, 0}, 268, 268, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x1C1A, 0x6C1A, 257, 8, 14636, 14647, 14409, 14688, 14465, 14469, 13726, {39477, 0, 0, 0}, 269, 269, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x2001, 0x0001, 257, 96, 14692, 14698, 14712, 14740, 2561, 2532, 14744, {39339, 0, 0, 0}, 270, 270, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x2009, 0x0009, 257, 61, 14747, 14753, 14753, 14771, 2840, 2825, 14775, {36880, 0, 0, 0}, 271, 271, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x200A, 0x000A, 257, 131, 14778, 14784, 14804, 14825, 2868, 2844, 14829, {36899, 0, 0, 0}, 272, 272, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x200C, 0x000C, 257, 106, 14832, 14838, 14856, 14880, 2921, 2897, 14884, {36946, 0, 0, 0}, 273, 273, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x201A, 0x641A, 257, 8, 14887, 14898, 14133, 14939, 14168, 14172, 13726, {37712, 0, 0, 0}, 274, 274, { 1251, 870, 10082, 855, 0, ';' }},
+       {0x2401, 0x0001, 257, 133, 14943, 14949, 14964, 14992, 2561, 2532, 14996, {39339, 0, 0, 0}, 275, 275, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x240A, 0x000A, 257, 26, 14999, 15005, 15024, 15044, 2868, 2844, 15048, {36899, 0, 0, 0}, 276, 276, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x240C, 0x000C, 257, 20, 15051, 15057, 15083, 15110, 2921, 2897, 15114, {36946, 0, 0, 0}, 277, 277, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x241A, 0x701A, 257, 108, 15117, 15128, 15152, 15180, 14465, 14469, 15184, {37251, 0, 0, 0}, 278, 278, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x243B, 0x703B, 257, 40, 15187, 15194, 15215, 15239, 15243, 15243, 6537, {0, 0, 0, 0}, 279, 279, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x2801, 0x0001, 257, 119, 15247, 15253, 15268, 15296, 2561, 2532, 15300, {39339, 0, 0, 0}, 280, 280, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x2809, 0x0009, 257, 18, 15303, 15309, 15309, 15326, 2840, 2825, 15330, {36880, 0, 0, 0}, 281, 281, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x280A, 0x000A, 257, 98, 15333, 15339, 15354, 15371, 2868, 2844, 15375, {36899, 0, 0, 0}, 282, 282, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x280C, 0x000C, 257, 116, 15378, 15384, 15401, 15423, 2921, 2897, 15427, {36946, 0, 0, 0}, 283, 283, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x281A, 0x6C1A, 257, 108, 15430, 15441, 15152, 15468, 14465, 14469, 15184, {39477, 0, 0, 0}, 284, 284, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x2C01, 0x0001, 257, 62, 15472, 15478, 15494, 15524, 2561, 2532, 15528, {39339, 0, 0, 0}, 285, 285, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x2C09, 0x0009, 257, 125, 15531, 15537, 15537, 15565, 2840, 2825, 15569, {36880, 0, 0, 0}, 286, 286, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x2C0A, 0x000A, 257, 4, 15572, 15578, 15598, 15619, 2868, 2844, 15623, {36899, 0, 0, 0}, 287, 287, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x2C0C, 0x000C, 257, 24, 15626, 15632, 15650, 15671, 2921, 2897, 15675, {36946, 0, 0, 0}, 288, 288, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x2C1A, 0x701A, 257, 81, 15678, 15689, 15717, 15750, 14465, 14469, 15754, {37251, 0, 0, 0}, 289, 289, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x3001, 0x0001, 257, 71, 15757, 15763, 15780, 15808, 2561, 2532, 15812, {39339, 0, 0, 0}, 290, 290, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x3009, 0x0009, 257, 135, 15815, 15821, 15821, 15840, 2840, 2825, 15844, {36880, 0, 0, 0}, 291, 291, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x300A, 0x000A, 257, 34, 15847, 15853, 15871, 15890, 2868, 2844, 15894, {36899, 0, 0, 0}, 292, 292, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x300C, 0x000C, 257, 22, 15897, 15903, 15929, 15958, 2921, 2897, 15962, {36946, 0, 0, 0}, 293, 293, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x301A, 0x6C1A, 257, 81, 15965, 15976, 15717, 16007, 14465, 14469, 15754, {39477, 0, 0, 0}, 294, 294, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x3401, 0x0001, 257, 68, 16011, 16017, 16033, 16063, 2561, 2532, 16067, {39339, 0, 0, 0}, 295, 295, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x3409, 0x0009, 257, 99, 16070, 16076, 16076, 16098, 2840, 2825, 10672, {36880, 0, 0, 0}, 296, 296, { 1252, 500, 10000, 437, 0, ',' }},
+       {0x340A, 0x000A, 257, 23, 16102, 16108, 16124, 16141, 2868, 2844, 16145, {36899, 0, 0, 0}, 297, 297, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x340C, 0x000C, 257, 83, 16148, 16154, 16168, 16185, 2921, 2897, 16189, {36946, 0, 0, 0}, 298, 298, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x3801, 0x0001, 257, 0, 16192, 16198, 16228, 16292, 2561, 2532, 16296, {39339, 0, 0, 0}, 299, 299, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x380A, 0x000A, 257, 129, 16299, 16305, 16323, 16342, 2868, 2844, 16346, {36899, 0, 0, 0}, 300, 300, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x380C, 0x000C, 257, 78, 16349, 16355, 16372, 16390, 2921, 2897, 14232, {36946, 0, 0, 0}, 301, 301, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x3C01, 0x0001, 257, 12, 16394, 16400, 16417, 16449, 2561, 2532, 16453, {39339, 0, 0, 0}, 302, 302, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x3C09, 0x0009, 257, 48, 16456, 16462, 16462, 16492, 2840, 2825, 13111, {36880, 0, 0, 0}, 303, 303, { 1252, 500, 10000, 850, 0, ',' }},
+       {0x3C0A, 0x000A, 257, 104, 16496, 16502, 16521, 16541, 2868, 2844, 16545, {36899, 0, 0, 0}, 304, 304, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x3C0C, 0x000C, 257, 51, 16548, 16554, 16569, 16588, 2921, 2897, 16592, {36946, 0, 0, 0}, 305, 305, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x4001, 0x0001, 257, 105, 16595, 16601, 16616, 16640, 2561, 2532, 16644, {39339, 0, 0, 0}, 306, 306, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x4009, 0x0009, 257, 56, 16647, 16653, 16653, 16669, 2840, 2825, 8858, {36880, 0, 0, 0}, 307, 307, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x400A, 0x000A, 257, 14, 16673, 16679, 16697, 16716, 2868, 2844, 16720, {36899, 0, 0, 0}, 308, 308, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x4409, 0x0009, 257, 89, 16723, 16729, 16729, 16748, 2840, 2825, 9002, {36880, 0, 0, 0}, 309, 309, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x440A, 0x000A, 257, 118, 16752, 16758, 16780, 16803, 2868, 2844, 16807, {36899, 0, 0, 0}, 310, 310, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x4809, 0x0009, 257, 113, 16810, 16816, 16816, 16836, 2840, 2825, 13469, {36880, 0, 0, 0}, 311, 311, { 1252, 37, 10000, 437, 0, ',' }},
+       {0x480A, 0x000A, 257, 49, 16840, 16846, 16865, 16885, 2868, 2844, 16889, {36899, 0, 0, 0}, 312, 312, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x4C0A, 0x000A, 257, 91, 16892, 16898, 16918, 16939, 2868, 2844, 16943, {36899, 0, 0, 0}, 313, 313, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x500A, 0x000A, 257, 102, 16946, 16952, 16974, 16997, 2868, 2844, 17001, {36899, 0, 0, 0}, 314, 314, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x540A, 0x000A, 257, 128, 17004, 17010, 17034, 17060, 2868, 2844, 6496, {36899, 0, 0, 0}, 315, 315, { 1252, 20284, 10000, 850, 0, ',' }},
+       {0x5C0A, 0x000A, 257, 28, 17064, 17070, 17085, 17101, 2868, 2844, 17105, {36899, 0, 0, 0}, 316, 316, { 1252, 20284, 10000, 850, 0, ';' }},
+       {0x641A, 0x781A, 257, -1, 17108, 17116, 17135, 14939, 14168, 14172, 0, {37712, 0, 0, 0}, 317, 317, { 1251, 870, 10082, 855, 0, ';' }},
+       {0x681A, 0x781A, 257, -1, 17144, 17152, 17135, 14164, 14168, 14172, 0, {37251, 0, 0, 0}, 318, 318, { 1250, 870, 10082, 852, 0, ';' }},
+       {0x6C1A, 0x7C1A, 257, -1, 17168, 17176, 17195, 15468, 14465, 14469, 0, {39477, 0, 0, 0}, 319, 319, { 1251, 21025, 10007, 855, 0, ';' }},
+       {0x701A, 0x7C1A, 257, -1, 17208, 17216, 17195, 15180, 14465, 14469, 0, {37251, 0, 0, 0}, 320, 320, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x703B, 0x003B, 257, -1, 15243, 17232, 17243, 15239, 15243, 15243, 0, {0, 0, 0, 0}, 321, 321, { 1252, 20278, 10000, 850, 0, ';' }},
+       {0x742C, 0x002C, 257, -1, 17258, 17266, 3884, 12328, 3900, 3869, 0, {37652, 0, 0, 0}, 322, 322, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7804, 0x007F, 257, -1, 2676, 2640, 2661, 2668, 2672, 2676, 0, {36759, 0, 0, 0}, 323, 323, { 936, 500, 10008, 936, 0, ',' }},
+       {0x7814, 0x0014, 257, -1, 12014, 17289, 17307, 12006, 12010, 12014, 0, {36792, 0, 0, 0}, 324, 324, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x781A, 0x007F, 257, -1, 14172, 17315, 17135, 14164, 14168, 14172, 0, {37251, 0, 0, 0}, 325, 325, { 1250, 870, 10082, 852, 0, ';' }},
+       {0x782C, 0x002C, 257, -1, 17323, 17331, 3884, 3896, 3900, 3869, 0, {37652, 0, 0, 0}, 326, 326, { 1254, 20905, 10081, 857, 0, ';' }},
+       {0x7843, 0x0043, 257, -1, 17351, 17359, 4544, 12621, 4557, 4535, 0, {39417, 0, 0, 0}, 327, 327, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7850, 0x0050, 257, -1, 17376, 17384, 4939, 9886, 4956, 4926, 0, {38692, 0, 0, 0}, 328, 328, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7C04, 0x7804, 257, -1, 17405, 6213, 2661, 6251, 2672, 2676, 0, {39332, 0, 0, 0}, 329, 329, { 950, 500, 10002, 950, 0, ',' }},
+       {0x7C04, 0x7C04, 257, -1, 17413, 17420, 2661, 6251, 2672, 2676, 0, {39332, 0, 0, 0}, 330, 330, { 950, 500, 10002, 950, 0, ',' }},
+       {0x7C14, 0x0014, 257, -1, 3154, 17449, 17467, 3146, 3150, 3154, 0, {36792, 0, 0, 0}, 331, 331, { 1252, 20277, 10000, 850, 0, ';' }},
+       {0x7C1A, 0x007F, 257, -1, 14469, 17481, 17195, 17489, 14465, 14469, 0, {39477, 0, 0, 0}, 332, 332, { 1250, 500, 10029, 852, 0, ';' }},
+       {0x7C28, 0x0028, 257, -1, 17493, 17501, 3746, 3759, 3763, 3737, 0, {0, 0, 0, 0}, 333, 333, { 1251, 20880, 10007, 866, 0, ';' }},
+       {0x7C2E, 0x002E, 257, -1, 12393, 17518, 17532, 12389, 12393, 12393, 0, {39394, 0, 0, 0}, 334, 334, { 1252, 870, 10000, 850, 0, ';' }},
+       {0x7C43, 0x0043, 257, -1, 17549, 17557, 4544, 4553, 4557, 4535, 0, {38146, 0, 0, 0}, 335, 335, { 1254, 500, 10029, 857, 0, ';' }},
+       {0x7C46, 0x0046, 257, -1, 17571, 17579, 4606, 12785, 4629, 4595, 0, {38235, 0, 0, 0}, 336, 336, { 1256, 20420, 10004, 720, 1, ';' }},
+       {0x7C5F, 0x005F, 257, -1, 17596, 17605, 5306, 5329, 5278, 5278, 0, {0, 0, 0, 0}, 337, 337, { 1252, 20297, 10000, 850, 0, ';' }},
+       {0x7C68, 0x0068, 257, -1, 17637, 17645, 5479, 5485, 5489, 5476, 0, {0, 0, 0, 0}, 338, 338, { 1252, 37, 10000, 437, 0, ';' }}
 };
 
 
 static const CultureInfoNameEntry culture_name_entries [] = {
-       {4197, 53},      /* af */
-       {17705, 161},    /* af-za */
+       {4151, 53},      /* af */
+       {17659, 161},    /* af-za */
        {5, 86},         /* am */
-       {17711, 191},    /* am-et */
-       {2578, 0},       /* ar */
-       {17717, 299},    /* ar-ae */
-       {17723, 302},    /* ar-bh */
-       {17729, 254},    /* ar-dz */
-       {17735, 240},    /* ar-eg */
-       {17741, 213},    /* ar-iq */
-       {17747, 285},    /* ar-jo */
-       {17753, 295},    /* ar-kw */
-       {17759, 290},    /* ar-lb */
-       {17765, 247},    /* ar-ly */
-       {17771, 261},    /* ar-ma */
-       {17777, 270},    /* ar-om */
-       {17783, 306},    /* ar-qa */
-       {17789, 110},    /* ar-sa */
-       {17795, 280},    /* ar-sy */
-       {17801, 266},    /* ar-tn */
-       {17807, 275},    /* ar-ye */
-       {4895, 74},      /* as */
-       {17813, 180},    /* as-in */
-       {3915, 44},      /* az */
-       {17819, 322},    /* az-cyrl */
-       {17827, 228},    /* az-cyrl-az */
-       {17838, 326},    /* az-latn */
-       {17846, 152},    /* az-latn-az */
-       {3618, 35},      /* be */
-       {17857, 143},    /* be-by */
-       {2611, 1},       /* bg */
-       {17863, 111},    /* bg-bg */
-       {4607, 66},      /* bn */
-       {17869, 235},    /* bn-bd */
-       {17875, 173},    /* bn-in */
-       {5006, 77},      /* bo */
-       {17881, 183},    /* bo-cn */
-       {5855, 104},     /* br */
-       {17887, 207},    /* br-fr */
-       {14218, 325},    /* bs */
-       {17893, 317},    /* bs-cyrl */
-       {17901, 274},    /* bs-cyrl-ba */
-       {17912, 318},    /* bs-latn */
-       {17920, 260},    /* bs-latn-ba */
-       {2651, 2},       /* ca */
-       {17931, 112},    /* ca-es */
-       {17937, 214},    /* ca-es-valencia */
-       {5268, 85},      /* chr */
-       {2760, 5},       /* cs */
-       {17952, 114},    /* cs-cz */
-       {5050, 78},      /* cy */
-       {17958, 184},    /* cy-gb */
-       {2787, 6},       /* da */
-       {17964, 115},    /* da-dk */
-       {2811, 7},       /* de */
-       {17970, 242},    /* de-at */
-       {17976, 216},    /* de-ch */
-       {17982, 116},    /* de-de */
-       {17988, 256},    /* de-li */
-       {17994, 249},    /* de-lu */
-       {12439, 334},    /* dsb */
-       {18000, 229},    /* dsb-de */
-       {2837, 8},       /* el */
-       {18007, 117},    /* el-gr */
-       {2871, 9},       /* en */
-       {18013, 243},    /* en-au */
-       {18019, 281},    /* en-bz */
-       {18025, 250},    /* en-ca */
-       {18031, 217},    /* en-gb */
-       {18037, 303},    /* en-hk */
-       {18043, 262},    /* en-ie */
-       {18049, 307},    /* en-in */
-       {18055, 271},    /* en-jm */
-       {18061, 309},    /* en-my */
-       {18067, 257},    /* en-nz */
-       {18073, 296},    /* en-ph */
-       {18079, 311},    /* en-sg */
-       {18085, 286},    /* en-tt */
-       {18091, 118},    /* en-us */
-       {18097, 267},    /* en-za */
-       {18103, 291},    /* en-zw */
-       {2890, 10},      /* es */
-       {18109, 287},    /* es-ar */
-       {18115, 308},    /* es-bo */
-       {18121, 297},    /* es-cl */
-       {18127, 276},    /* es-co */
-       {18133, 258},    /* es-cr */
-       {18139, 316},    /* es-cu */
-       {18145, 268},    /* es-do */
-       {18151, 292},    /* es-ec */
-       {18157, 244},    /* es-es */
-       {18163, 251},    /* es-gt */
-       {18169, 312},    /* es-hn */
-       {18175, 218},    /* es-mx */
-       {18181, 313},    /* es-ni */
-       {18187, 263},    /* es-pa */
-       {18193, 282},    /* es-pe */
-       {18199, 314},    /* es-pr */
-       {18205, 304},    /* es-py */
-       {18211, 310},    /* es-sv */
-       {18217, 315},    /* es-us */
-       {18223, 300},    /* es-uy */
-       {18229, 272},    /* es-ve */
-       {3696, 37},      /* et */
-       {18235, 145},    /* et-ee */
-       {3950, 45},      /* eu */
-       {18241, 153},    /* eu-es */
-       {3813, 41},      /* fa */
-       {18247, 149},    /* fa-ir */
-       {5498, 92},      /* ff */
-       {2918, 11},      /* fi */
-       {18253, 119},    /* fi-fi */
-       {5481, 91},      /* fil */
-       {18259, 195},    /* fil-ph */
-       {4260, 55},      /* fo */
-       {18266, 163},    /* fo-fo */
-       {2943, 12},      /* fr */
-       {18272, 219},    /* fr-be */
-       {18278, 245},    /* fr-ca */
-       {18284, 277},    /* fr-cd */
-       {18290, 252},    /* fr-ch */
-       {18296, 293},    /* fr-ci */
-       {18302, 288},    /* fr-cm */
-       {18308, 120},    /* fr-fr */
-       {18314, 305},    /* fr-ht */
-       {18320, 259},    /* fr-lu */
-       {18326, 301},    /* fr-ma */
-       {18332, 264},    /* fr-mc */
-       {18338, 298},    /* fr-ml */
-       {18344, 273},    /* fr-re */
-       {18350, 283},    /* fr-sn */
-       {5416, 89},      /* fy */
-       {18356, 193},    /* fy-nl */
-       {4392, 59},      /* ga */
-       {18362, 232},    /* ga-ie */
-       {6013, 109},     /* gd */
-       {18368, 212},    /* gd-gb */
-       {5171, 82},      /* gl */
-       {18374, 188},    /* gl-es */
-       {5918, 106},     /* gsw */
-       {18380, 209},    /* gsw-fr */
-       {4679, 68},      /* gu */
-       {18387, 174},    /* gu-in */
-       {5522, 93},      /* ha */
-       {18393, 338},    /* ha-latn */
-       {18401, 196},    /* ha-latn-ng */
-       {5761, 101},     /* haw */
-       {18412, 204},    /* haw-us */
-       {2971, 13},      /* he */
-       {18419, 121},    /* he-il */
-       {4289, 56},      /* hi */
-       {18425, 164},    /* hi-in */
-       {3353, 26},      /* hr */
-       {18431, 253},    /* hr-ba */
-       {18437, 134},    /* hr-hr */
-       {3976, 46},      /* hsb */
-       {18443, 154},    /* hsb-de */
-       {3000, 14},      /* hu */
-       {18450, 122},    /* hu-hu */
-       {3880, 43},      /* hy */
-       {18456, 151},    /* hy-am */
-       {3544, 33},      /* id */
-       {18462, 141},    /* id-id */
-       {5688, 98},      /* ig */
-       {18468, 201},    /* ig-ng */
-       {5823, 103},     /* ii */
-       {18474, 206},    /* ii-cn */
-       {3028, 15},      /* is */
-       {18480, 123},    /* is-is */
-       {3059, 16},      /* it */
-       {18486, 220},    /* it-ch */
-       {18492, 124},    /* it-it */
-       {3087, 17},      /* ja */
-       {18498, 125},    /* ja-jp */
-       {4218, 54},      /* ka */
-       {18504, 162},    /* ka-ge */
-       {4448, 61},      /* kk */
-       {18510, 168},    /* kk-kz */
-       {5653, 97},      /* kl */
-       {18516, 200},    /* kl-gl */
-       {5075, 79},      /* km */
-       {18522, 185},    /* km-kh */
-       {1717, 72},      /* kn */
-       {18528, 178},    /* kn-in */
-       {3117, 18},      /* ko */
-       {18534, 126},    /* ko-kr */
-       {5198, 83},      /* kok */
-       {18540, 189},    /* kok-in */
-       {4486, 62},      /* ky */
-       {18547, 169},    /* ky-kg */
-       {5612, 96},      /* lb */
-       {18553, 199},    /* lb-lu */
-       {5108, 80},      /* lo */
-       {18559, 186},    /* lo-la */
-       {3751, 39},      /* lt */
-       {18565, 147},    /* lt-lt */
-       {3722, 38},      /* lv */
-       {18571, 146},    /* lv-lv */
-       {4016, 47},      /* mk */
-       {18577, 155},    /* mk-mk */
-       {4855, 73},      /* ml */
-       {18583, 179},    /* ml-in */
-       {4972, 76},      /* mn */
-       {18589, 328},    /* mn-cyrl */
-       {18597, 182},    /* mn-mn */
-       {4937, 75},      /* mr */
-       {18603, 181},    /* mr-in */
-       {4417, 60},      /* ms */
-       {18609, 233},    /* ms-bn */
-       {18615, 167},    /* ms-my */
-       {4325, 57},      /* mt */
-       {18621, 165},    /* mt-mt */
-       {5133, 81},      /* my */
-       {18627, 187},    /* my-mm */
-       {3200, 331},     /* nb */
-       {18633, 128},    /* nb-no */
-       {5379, 88},      /* ne */
-       {18639, 238},    /* ne-in */
-       {18645, 192},    /* ne-np */
-       {3145, 19},      /* nl */
-       {18651, 221},    /* nl-be */
-       {18657, 127},    /* nl-nl */
-       {12060, 324},    /* nn */
-       {18663, 222},    /* nn-no */
-       {3173, 20},      /* no */
-       {5572, 95},      /* nso */
-       {18669, 198},    /* nso-za */
-       {5704, 99},      /* om */
-       {18676, 202},    /* om-et */
-       {4721, 69},      /* or */
-       {18682, 175},    /* or-in */
-       {4641, 67},      /* pa */
-       {18688, 336},    /* pa-arab */
-       {18696, 236},    /* pa-arab-pk */
-       {3203, 21},      /* pl */
-       {18707, 129},    /* pl-pl */
-       {5454, 90},      /* ps */
-       {18713, 194},    /* ps-af */
-       {3228, 22},      /* pt */
-       {18719, 130},    /* pt-br */
-       {18725, 223},    /* pt-pt */
-       {3261, 23},      /* rm */
-       {18731, 131},    /* rm-ch */
-       {3290, 24},      /* ro */
-       {18737, 224},    /* ro-md */
-       {18743, 132},    /* ro-ro */
-       {3319, 25},      /* ru */
-       {18749, 225},    /* ru-md */
-       {18755, 133},    /* ru-ru */
-       {5990, 108},     /* rw */
-       {18761, 211},    /* rw-rw */
-       {5958, 107},     /* sah */
-       {18767, 210},    /* sah-ru */
-       {4350, 58},      /* se */
-       {18774, 246},    /* se-fi */
-       {18780, 166},    /* se-no */
-       {18786, 231},    /* se-se */
-       {5233, 84},      /* si */
-       {18792, 190},    /* si-lk */
-       {3382, 27},      /* sk */
-       {18798, 135},    /* sk-sk */
-       {3661, 36},      /* sl */
-       {18804, 144},    /* sl-si */
-       {15289, 321},    /* smn */
-       {18810, 279},    /* smn-fi */
-       {5796, 102},     /* so */
-       {18817, 205},    /* so-so */
-       {3412, 28},      /* sq */
-       {18823, 136},    /* sq-al */
-       {14515, 332},    /* sr */
-       {18829, 319},    /* sr-cyrl */
-       {18837, 269},    /* sr-cyrl-ba */
-       {18848, 294},    /* sr-cyrl-me */
-       {18859, 284},    /* sr-cyrl-rs */
-       {18870, 320},    /* sr-latn */
-       {18878, 265},    /* sr-latn-ba */
-       {18889, 289},    /* sr-latn-me */
-       {18900, 278},    /* sr-latn-rs */
-       {4059, 48},      /* st */
-       {18911, 156},    /* st-za */
-       {3438, 29},      /* sv */
-       {18917, 226},    /* sv-fi */
-       {18923, 137},    /* sv-se */
-       {4521, 63},      /* sw */
-       {18929, 170},    /* sw-ke */
-       {4753, 70},      /* ta */
-       {18935, 176},    /* ta-in */
-       {18941, 237},    /* ta-lk */
-       {4786, 71},      /* te */
-       {18947, 177},    /* te-in */
-       {3783, 40},      /* tg */
-       {18953, 333},    /* tg-cyrl */
-       {18961, 148},    /* tg-cyrl-tj */
-       {3465, 30},      /* th */
-       {18972, 138},    /* th-th */
-       {5728, 100},     /* ti */
-       {18978, 239},    /* ti-er */
-       {18984, 203},    /* ti-et */
-       {4550, 64},      /* tk */
-       {18990, 171},    /* tk-tm */
-       {4120, 50},      /* tn */
-       {18996, 230},    /* tn-bw */
-       {19002, 158},    /* tn-za */
-       {3491, 31},      /* tr */
-       {19008, 139},    /* tr-tr */
-       {4093, 49},      /* ts */
-       {19014, 157},    /* ts-za */
-       {5324, 87},      /* tzm */
-       {19020, 337},    /* tzm-latn */
-       {5883, 105},     /* ug */
-       {19029, 208},    /* ug-cn */
-       {3576, 34},      /* uk */
-       {19035, 142},    /* uk-ua */
-       {3519, 32},      /* ur */
-       {19041, 227},    /* ur-in */
-       {19047, 140},    /* ur-pk */
-       {4581, 65},      /* uz */
-       {19053, 327},    /* uz-cyrl */
-       {19061, 234},    /* uz-cyrl-uz */
-       {19072, 335},    /* uz-latn */
-       {19080, 172},    /* uz-latn-uz */
-       {3843, 42},      /* vi */
-       {19091, 150},    /* vi-vn */
-       {4147, 51},      /* xh */
-       {19097, 159},    /* xh-za */
-       {5539, 94},      /* yo */
-       {19103, 197},    /* yo-ng */
-       {2722, 323},     /* zh */
-       {19109, 4},      /* zh-chs */
-       {19116, 330},    /* zh-cht */
-       {19123, 215},    /* zh-cn */
-       {19129, 3},      /* zh-hans */
-       {19137, 329},    /* zh-hant */
-       {19145, 241},    /* zh-hk */
-       {19151, 255},    /* zh-mo */
-       {19157, 248},    /* zh-sg */
-       {19163, 113},    /* zh-tw */
-       {4173, 52},      /* zu */
-       {19169, 160}     /* zu-za */
+       {17665, 191},    /* am-et */
+       {2532, 0},       /* ar */
+       {17671, 299},    /* ar-ae */
+       {17677, 302},    /* ar-bh */
+       {17683, 254},    /* ar-dz */
+       {17689, 240},    /* ar-eg */
+       {17695, 213},    /* ar-iq */
+       {17701, 285},    /* ar-jo */
+       {17707, 295},    /* ar-kw */
+       {17713, 290},    /* ar-lb */
+       {17719, 247},    /* ar-ly */
+       {17725, 261},    /* ar-ma */
+       {17731, 270},    /* ar-om */
+       {17737, 306},    /* ar-qa */
+       {17743, 110},    /* ar-sa */
+       {17749, 280},    /* ar-sy */
+       {17755, 266},    /* ar-tn */
+       {17761, 275},    /* ar-ye */
+       {4849, 74},      /* as */
+       {17767, 180},    /* as-in */
+       {3869, 44},      /* az */
+       {17773, 322},    /* az-cyrl */
+       {17781, 228},    /* az-cyrl-az */
+       {17792, 326},    /* az-latn */
+       {17800, 152},    /* az-latn-az */
+       {3572, 35},      /* be */
+       {17811, 143},    /* be-by */
+       {2565, 1},       /* bg */
+       {17817, 111},    /* bg-bg */
+       {4561, 66},      /* bn */
+       {17823, 235},    /* bn-bd */
+       {17829, 173},    /* bn-in */
+       {4960, 77},      /* bo */
+       {17835, 183},    /* bo-cn */
+       {5809, 104},     /* br */
+       {17841, 207},    /* br-fr */
+       {14172, 325},    /* bs */
+       {17847, 317},    /* bs-cyrl */
+       {17855, 274},    /* bs-cyrl-ba */
+       {17866, 318},    /* bs-latn */
+       {17874, 260},    /* bs-latn-ba */
+       {2605, 2},       /* ca */
+       {17885, 112},    /* ca-es */
+       {17891, 214},    /* ca-es-valencia */
+       {5222, 85},      /* chr */
+       {2714, 5},       /* cs */
+       {17906, 114},    /* cs-cz */
+       {5004, 78},      /* cy */
+       {17912, 184},    /* cy-gb */
+       {2741, 6},       /* da */
+       {17918, 115},    /* da-dk */
+       {2765, 7},       /* de */
+       {17924, 242},    /* de-at */
+       {17930, 216},    /* de-ch */
+       {17936, 116},    /* de-de */
+       {17942, 256},    /* de-li */
+       {17948, 249},    /* de-lu */
+       {12393, 334},    /* dsb */
+       {17954, 229},    /* dsb-de */
+       {2791, 8},       /* el */
+       {17961, 117},    /* el-gr */
+       {2825, 9},       /* en */
+       {17967, 243},    /* en-au */
+       {17973, 281},    /* en-bz */
+       {17979, 250},    /* en-ca */
+       {17985, 217},    /* en-gb */
+       {17991, 303},    /* en-hk */
+       {17997, 262},    /* en-ie */
+       {18003, 307},    /* en-in */
+       {18009, 271},    /* en-jm */
+       {18015, 309},    /* en-my */
+       {18021, 257},    /* en-nz */
+       {18027, 296},    /* en-ph */
+       {18033, 311},    /* en-sg */
+       {18039, 286},    /* en-tt */
+       {18045, 118},    /* en-us */
+       {18051, 267},    /* en-za */
+       {18057, 291},    /* en-zw */
+       {2844, 10},      /* es */
+       {18063, 287},    /* es-ar */
+       {18069, 308},    /* es-bo */
+       {18075, 297},    /* es-cl */
+       {18081, 276},    /* es-co */
+       {18087, 258},    /* es-cr */
+       {18093, 316},    /* es-cu */
+       {18099, 268},    /* es-do */
+       {18105, 292},    /* es-ec */
+       {18111, 244},    /* es-es */
+       {18117, 251},    /* es-gt */
+       {18123, 312},    /* es-hn */
+       {18129, 218},    /* es-mx */
+       {18135, 313},    /* es-ni */
+       {18141, 263},    /* es-pa */
+       {18147, 282},    /* es-pe */
+       {18153, 314},    /* es-pr */
+       {18159, 304},    /* es-py */
+       {18165, 310},    /* es-sv */
+       {18171, 315},    /* es-us */
+       {18177, 300},    /* es-uy */
+       {18183, 272},    /* es-ve */
+       {3650, 37},      /* et */
+       {18189, 145},    /* et-ee */
+       {3904, 45},      /* eu */
+       {18195, 153},    /* eu-es */
+       {3767, 41},      /* fa */
+       {18201, 149},    /* fa-ir */
+       {5452, 92},      /* ff */
+       {2872, 11},      /* fi */
+       {18207, 119},    /* fi-fi */
+       {5435, 91},      /* fil */
+       {18213, 195},    /* fil-ph */
+       {4214, 55},      /* fo */
+       {18220, 163},    /* fo-fo */
+       {2897, 12},      /* fr */
+       {18226, 219},    /* fr-be */
+       {18232, 245},    /* fr-ca */
+       {18238, 277},    /* fr-cd */
+       {18244, 252},    /* fr-ch */
+       {18250, 293},    /* fr-ci */
+       {18256, 288},    /* fr-cm */
+       {18262, 120},    /* fr-fr */
+       {18268, 305},    /* fr-ht */
+       {18274, 259},    /* fr-lu */
+       {18280, 301},    /* fr-ma */
+       {18286, 264},    /* fr-mc */
+       {18292, 298},    /* fr-ml */
+       {18298, 273},    /* fr-re */
+       {18304, 283},    /* fr-sn */
+       {5370, 89},      /* fy */
+       {18310, 193},    /* fy-nl */
+       {4346, 59},      /* ga */
+       {18316, 232},    /* ga-ie */
+       {5967, 109},     /* gd */
+       {18322, 212},    /* gd-gb */
+       {5125, 82},      /* gl */
+       {18328, 188},    /* gl-es */
+       {5872, 106},     /* gsw */
+       {18334, 209},    /* gsw-fr */
+       {4633, 68},      /* gu */
+       {18341, 174},    /* gu-in */
+       {5476, 93},      /* ha */
+       {18347, 338},    /* ha-latn */
+       {18355, 196},    /* ha-latn-ng */
+       {5715, 101},     /* haw */
+       {18366, 204},    /* haw-us */
+       {2925, 13},      /* he */
+       {18373, 121},    /* he-il */
+       {4243, 56},      /* hi */
+       {18379, 164},    /* hi-in */
+       {3307, 26},      /* hr */
+       {18385, 253},    /* hr-ba */
+       {18391, 134},    /* hr-hr */
+       {3930, 46},      /* hsb */
+       {18397, 154},    /* hsb-de */
+       {2954, 14},      /* hu */
+       {18404, 122},    /* hu-hu */
+       {3834, 43},      /* hy */
+       {18410, 151},    /* hy-am */
+       {3498, 33},      /* id */
+       {18416, 141},    /* id-id */
+       {5642, 98},      /* ig */
+       {18422, 201},    /* ig-ng */
+       {5777, 103},     /* ii */
+       {18428, 206},    /* ii-cn */
+       {2982, 15},      /* is */
+       {18434, 123},    /* is-is */
+       {3013, 16},      /* it */
+       {18440, 220},    /* it-ch */
+       {18446, 124},    /* it-it */
+       {3041, 17},      /* ja */
+       {18452, 125},    /* ja-jp */
+       {4172, 54},      /* ka */
+       {18458, 162},    /* ka-ge */
+       {4402, 61},      /* kk */
+       {18464, 168},    /* kk-kz */
+       {5607, 97},      /* kl */
+       {18470, 200},    /* kl-gl */
+       {5029, 79},      /* km */
+       {18476, 185},    /* km-kh */
+       {1701, 72},      /* kn */
+       {18482, 178},    /* kn-in */
+       {3071, 18},      /* ko */
+       {18488, 126},    /* ko-kr */
+       {5152, 83},      /* kok */
+       {18494, 189},    /* kok-in */
+       {4440, 62},      /* ky */
+       {18501, 169},    /* ky-kg */
+       {5566, 96},      /* lb */
+       {18507, 199},    /* lb-lu */
+       {5062, 80},      /* lo */
+       {18513, 186},    /* lo-la */
+       {3705, 39},      /* lt */
+       {18519, 147},    /* lt-lt */
+       {3676, 38},      /* lv */
+       {18525, 146},    /* lv-lv */
+       {3970, 47},      /* mk */
+       {18531, 155},    /* mk-mk */
+       {4809, 73},      /* ml */
+       {18537, 179},    /* ml-in */
+       {4926, 76},      /* mn */
+       {18543, 328},    /* mn-cyrl */
+       {18551, 182},    /* mn-mn */
+       {4891, 75},      /* mr */
+       {18557, 181},    /* mr-in */
+       {4371, 60},      /* ms */
+       {18563, 233},    /* ms-bn */
+       {18569, 167},    /* ms-my */
+       {4279, 57},      /* mt */
+       {18575, 165},    /* mt-mt */
+       {5087, 81},      /* my */
+       {18581, 187},    /* my-mm */
+       {3154, 331},     /* nb */
+       {18587, 128},    /* nb-no */
+       {5333, 88},      /* ne */
+       {18593, 238},    /* ne-in */
+       {18599, 192},    /* ne-np */
+       {3099, 19},      /* nl */
+       {18605, 221},    /* nl-be */
+       {18611, 127},    /* nl-nl */
+       {12014, 324},    /* nn */
+       {18617, 222},    /* nn-no */
+       {3127, 20},      /* no */
+       {5526, 95},      /* nso */
+       {18623, 198},    /* nso-za */
+       {5658, 99},      /* om */
+       {18630, 202},    /* om-et */
+       {4675, 69},      /* or */
+       {18636, 175},    /* or-in */
+       {4595, 67},      /* pa */
+       {18642, 336},    /* pa-arab */
+       {18650, 236},    /* pa-arab-pk */
+       {3157, 21},      /* pl */
+       {18661, 129},    /* pl-pl */
+       {5408, 90},      /* ps */
+       {18667, 194},    /* ps-af */
+       {3182, 22},      /* pt */
+       {18673, 130},    /* pt-br */
+       {18679, 223},    /* pt-pt */
+       {3215, 23},      /* rm */
+       {18685, 131},    /* rm-ch */
+       {3244, 24},      /* ro */
+       {18691, 224},    /* ro-md */
+       {18697, 132},    /* ro-ro */
+       {3273, 25},      /* ru */
+       {18703, 225},    /* ru-md */
+       {18709, 133},    /* ru-ru */
+       {5944, 108},     /* rw */
+       {18715, 211},    /* rw-rw */
+       {5912, 107},     /* sah */
+       {18721, 210},    /* sah-ru */
+       {4304, 58},      /* se */
+       {18728, 246},    /* se-fi */
+       {18734, 166},    /* se-no */
+       {18740, 231},    /* se-se */
+       {5187, 84},      /* si */
+       {18746, 190},    /* si-lk */
+       {3336, 27},      /* sk */
+       {18752, 135},    /* sk-sk */
+       {3615, 36},      /* sl */
+       {18758, 144},    /* sl-si */
+       {15243, 321},    /* smn */
+       {18764, 279},    /* smn-fi */
+       {5750, 102},     /* so */
+       {18771, 205},    /* so-so */
+       {3366, 28},      /* sq */
+       {18777, 136},    /* sq-al */
+       {14469, 332},    /* sr */
+       {18783, 319},    /* sr-cyrl */
+       {18791, 269},    /* sr-cyrl-ba */
+       {18802, 294},    /* sr-cyrl-me */
+       {18813, 284},    /* sr-cyrl-rs */
+       {18824, 320},    /* sr-latn */
+       {18832, 265},    /* sr-latn-ba */
+       {18843, 289},    /* sr-latn-me */
+       {18854, 278},    /* sr-latn-rs */
+       {4013, 48},      /* st */
+       {18865, 156},    /* st-za */
+       {3392, 29},      /* sv */
+       {18871, 226},    /* sv-fi */
+       {18877, 137},    /* sv-se */
+       {4475, 63},      /* sw */
+       {18883, 170},    /* sw-ke */
+       {4707, 70},      /* ta */
+       {18889, 176},    /* ta-in */
+       {18895, 237},    /* ta-lk */
+       {4740, 71},      /* te */
+       {18901, 177},    /* te-in */
+       {3737, 40},      /* tg */
+       {18907, 333},    /* tg-cyrl */
+       {18915, 148},    /* tg-cyrl-tj */
+       {3419, 30},      /* th */
+       {18926, 138},    /* th-th */
+       {5682, 100},     /* ti */
+       {18932, 239},    /* ti-er */
+       {18938, 203},    /* ti-et */
+       {4504, 64},      /* tk */
+       {18944, 171},    /* tk-tm */
+       {4074, 50},      /* tn */
+       {18950, 230},    /* tn-bw */
+       {18956, 158},    /* tn-za */
+       {3445, 31},      /* tr */
+       {18962, 139},    /* tr-tr */
+       {4047, 49},      /* ts */
+       {18968, 157},    /* ts-za */
+       {5278, 87},      /* tzm */
+       {18974, 337},    /* tzm-latn */
+       {5837, 105},     /* ug */
+       {18983, 208},    /* ug-cn */
+       {3530, 34},      /* uk */
+       {18989, 142},    /* uk-ua */
+       {3473, 32},      /* ur */
+       {18995, 227},    /* ur-in */
+       {19001, 140},    /* ur-pk */
+       {4535, 65},      /* uz */
+       {19007, 327},    /* uz-cyrl */
+       {19015, 234},    /* uz-cyrl-uz */
+       {19026, 335},    /* uz-latn */
+       {19034, 172},    /* uz-latn-uz */
+       {3797, 42},      /* vi */
+       {19045, 150},    /* vi-vn */
+       {4101, 51},      /* xh */
+       {19051, 159},    /* xh-za */
+       {5493, 94},      /* yo */
+       {19057, 197},    /* yo-ng */
+       {2676, 323},     /* zh */
+       {19063, 4},      /* zh-chs */
+       {19070, 330},    /* zh-cht */
+       {19077, 215},    /* zh-cn */
+       {19083, 3},      /* zh-hans */
+       {19091, 329},    /* zh-hant */
+       {19099, 241},    /* zh-hk */
+       {19105, 255},    /* zh-mo */
+       {19111, 248},    /* zh-sg */
+       {19117, 113},    /* zh-tw */
+       {4127, 52},      /* zu */
+       {19123, 160}     /* zu-za */
 };
 
 
 static const RegionInfoEntry region_entries [] = {
-       { 224,16342,13060,13060,19175,19196,2519,19243,19247,19275},
-       { 3,10664,19299,19299,19303,19315,2190,19334,19338,19353},
-       { 6,7416,19366,19366,19370,19378,1720,19388,19392,19405},
-       { 7,49,14274,14274,19419,19427,1888,19444,19448,19462},
-       { 11,15669,13830,13830,19488,19488,1464,15342,19498,19513},
-       { 14,13209,19528,19528,19532,19540,1359,19552,19556,19556},
-       { 12,13242,19561,19561,19565,19565,1464,19575,19579,19579},
-       { 5,8307,3942,3942,19597,19608,2253,19620,19624,19642},
-       { 25,13772,19662,19662,19666,19687,2373,19707,19711,19747},
-       { 23,12744,19767,19767,19771,19782,2336,19807,19811,19828},
-       { 21,11901,3653,3653,19869,19877,1359,19552,19556,19886},
-       { 35,6207,2643,2643,19891,19900,1331,19917,19921,19935},
-       { 17,16499,19961,19961,19965,19973,2533,19988,19992,20007},
-       { 37,12624,20031,20031,20035,20035,1464,20042,20046,20060},
-       { 26,16766,20073,20073,20077,20077,2559,5042,20085,20104},
-       { 32,7120,20114,20114,20118,20125,1608,20132,20136,20151},
-       { 19,12471,20167,20167,20171,0,2294,20180,20184,0},
-       { 29,7795,20199,20199,20203,20211,1792,20228,20232,20249},
-       { 24,15376,20281,20281,20285,20285,1464,20292,20296,20296},
-       { 39,13335,20310,20310,20314,20314,1464,20321,20325,20341},
-       { 44,15160,20357,20357,20361,20378,2452,20393,20397,20413},
-       { 223,300,20429,20429,20433,20445,1615,1615,20452,20464},
-       { 119,16008,20478,20478,20482,20482,2480,20499,20503,20526},
-       { 46,16191,20544,20544,20548,20548,1464,20554,20558,20571},
-       { 49,15721,20584,20584,20588,20597,2494,20606,20610,20636},
-       { 45,10007,20653,20653,20657,20663,1380,20682,20686,20699},
-       { 51,15094,20718,20718,20722,20722,1464,20731,20735,20750},
-       { 54,14074,20766,20766,20770,20770,2391,20781,20785,20804},
-       { 56,17151,20825,20825,20829,20829,1464,20834,20838,20849},
-       { 75,6363,20861,20861,20865,20880,1383,20898,20902,20924},
-       { 94,6453,2829,2829,20939,20947,1359,19552,19556,19556},
-       { 61,6405,20959,20959,20963,20971,1411,20979,20983,20996},
-       { 65,14679,21008,21008,21012,21031,2419,21053,21057,21072},
-       { 4,13834,21088,21088,21092,21100,2376,21115,21119,21134},
-       { 66,15940,21158,21158,21162,21162,1464,21170,21174,21184},
-       { 70,7893,17106,17106,21206,21214,1359,19552,19556,19886},
-       { 67,13064,21220,21220,21224,21230,2347,21237,21241,21256},
-       { 71,13012,21274,21274,21278,21286,2201,21299,21303,0},
-       { 217,6250,2910,2910,21318,21324,1359,19552,19556,19886},
-       { 73,10484,21332,21332,21336,21345,2176,21361,21365,21380},
-       { 77,6583,2935,2935,21406,21414,1359,19552,19556,19886},
-       { 81,8847,16436,16436,21420,21434,1726,20979,20983,21443},
-       { 84,6627,2963,2963,21456,21456,1359,19552,19556,19886},
-       { 242,10066,21463,21463,21467,21482,2069,21499,21503,21517},
-       { 88,8793,21530,21530,21534,21542,1926,21573,21577,21591},
-       { 93,11008,21626,21626,21630,21640,1411,20979,20983,21657},
-       { 98,6509,21677,21677,21681,21688,1359,19552,19556,21701},
-       { 99,13646,21710,21710,21714,21714,2371,21724,21728,21747},
-       { 104,13157,21755,21755,21759,21779,2357,21807,21811,21828},
-       { 106,16935,21835,21835,21839,21839,2292,21848,21852,21869},
-       { 108,7319,3374,3374,21888,21896,2249,2249,21905,21919},
-       { 103,16638,21933,21933,21937,21943,2547,21950,21954,21969},
-       { 109,6728,3020,3020,21987,21995,1522,22009,22013,22030},
-       { 111,7658,22044,22044,3558,3558,1785,22048,22052,22070},
-       { 68,12573,22087,22087,22091,22099,1359,19552,19556,19556},
-       { 117,6676,22105,22105,22109,22116,1513,22127,22131,22150},
-       { 113,8904,3568,3568,22164,22170,1971,22183,22187,22200},
-       { 121,11676,22235,22235,22239,22244,2280,22257,22261,22273},
-       { 116,8118,22295,22295,22299,22304,1875,22315,22319,22332},
-       { 110,6777,3051,3051,22352,22360,1525,1525,22368,22385},
-       { 118,6820,3079,3079,22401,22407,1359,19552,19556,19886},
-       { 124,14821,22414,22414,22418,22418,1464,22426,22430,22430},
-       { 126,15574,22446,22446,22450,22457,2484,22470,22474,22490},
-       { 122,6865,3109,3109,22512,22518,1539,22525,22529,22542},
-       { 129,9230,22552,22552,22556,22556,2023,22562,22566,22582},
-       { 130,9187,22600,22600,22604,22615,1999,22636,22640,22655},
-       { 40,10132,5100,5100,22685,22694,2072,22716,22720,22735},
-       { 134,6920,3137,3137,22769,22781,1543,22794,22798,22815},
-       { 136,16113,22832,22832,22836,22843,2509,22856,22860,22874},
-       { 137,9118,22896,22896,22900,22911,1978,22930,22934,22952},
-       { 138,10174,5125,5125,22986,5115,2076,22991,22995,23007},
-       { 139,15858,23027,23027,23031,23039,2499,23050,23054,23069},
-       { 145,13983,23091,23091,23095,23095,1615,1615,20452,23109},
-       { 42,10425,23127,23127,23131,23141,2168,23173,23177,23194},
-       { 141,7991,23242,23242,23246,23256,1359,19552,19556,23264},
-       { 147,10944,23270,23270,23274,23285,1359,19552,19556,19556},
-       { 140,7939,23297,23297,23301,23308,1359,19552,19556,23316},
-       { 148,13451,23321,23321,23325,23331,2361,23342,23346,23359},
-       { 159,14278,4964,4964,23379,23387,2395,2529,23400,23416},
-       { 158,14403,23436,23436,23440,23440,1359,19552,19556,19886},
-       { 152,12174,23447,23447,23451,23459,2292,23477,23481,23494},
-       { 270,15800,23510,23510,23514,23525,1359,19552,19556,23543},
-       { 19618,8482,23548,23548,23552,23562,1917,23548,23583,23600},
-       { 157,16235,23632,23632,23636,23636,2480,20499,20503,20526},
-       { 27,10249,23641,23641,23645,5144,2126,23661,23665,23678},
-       { 154,9936,23709,23709,23713,23722,2263,23735,23739,23756},
-       { 151,13923,23769,23769,23773,23789,2386,23817,23821,23837},
-       { 163,8943,4342,4342,23847,23847,1359,19552,19556,23853},
-       { 166,11850,23858,23858,23862,23869,1464,23877,23881,23894},
-       { 167,9048,23908,23908,23912,23912,1975,23921,23925,23943},
-       { 175,10772,23960,23960,23964,23972,2197,23981,23985,24000},
-       { 182,16989,24006,24006,24010,24010,2562,24020,24024,24044},
-       { 176,6972,3165,3165,24067,24079,1359,19552,19556,19556},
-       { 177,7030,3192,3192,24089,24096,1726,24102,24106,24122},
-       { 178,10545,24136,24136,24140,24146,2267,24162,24166,24181},
-       { 183,14018,24222,24222,24226,24226,1464,24238,24242,24242},
-       { 164,14790,24261,24261,24265,24270,2428,24281,24285,24296},
-       { 192,14355,4671,4671,24316,24323,2405,24331,24335,24353},
-       { 187,15421,24370,24370,24374,24379,2477,24385,24389,24402},
-       { 201,10718,24420,24420,24424,24436,2193,24446,24450,24466},
-       { 190,7604,24484,24484,24488,24497,1750,24512,24516,24532},
-       { 191,7071,24560,24560,24564,24571,1566,24578,24582,24595},
-       { 202,17047,24609,24609,24613,24613,1464,21170,21174,21184},
-       { 193,12113,24625,24625,24629,24629,1359,19552,19556,19556},
-       { 185,16591,24638,24638,24642,24642,2543,24651,24655,24674},
-       { 197,16690,24693,24693,24697,24703,2549,24710,24714,24726},
-       { 198,14930,24744,24744,24748,24757,1359,19552,19556,19886},
-       { 200,7215,24769,24769,24773,24781,1637,1637,24790,24803},
-       { 271,15230,17535,17535,24817,24824,2455,2455,24837,24851},
-       { 203,7271,3345,3345,24864,24871,1641,24884,24888,24902},
-       { 204,11544,24934,24934,24938,24938,2236,24945,24949,0},
-       { 205,297,24963,24963,24967,24980,1266,25027,25031,25043},
-       { 221,7460,25063,25063,25067,25074,1726,25082,25086,25100},
-       { 215,13515,25113,25113,25117,25127,1464,25137,25141,25158},
-       { 212,7851,25171,25171,25175,25184,1359,19552,19556,25194},
-       { 143,7370,25199,25199,25203,25212,1359,19552,19556,19886},
-       { 210,15473,25222,25222,25226,25234,2480,20499,20503,20526},
-       { 216,11256,5815,5815,25244,25252,2205,25263,25267,25283},
-       { 72,16853,3688,3688,25299,25299,1464,21170,21174,21184},
-       { 222,15346,25311,25311,25315,25321,2467,25332,25336,25349},
-       { 227,7507,3483,3483,25369,3473,1742,1742,25378,25388},
-       { 228,8070,25407,25407,25411,25422,1999,25443,25447,25466},
-       { 238,9290,25479,25479,25483,25496,2027,2027,25510,25530},
-       { 234,14571,25546,25546,25550,25558,2409,25567,25571,25586},
-       { 235,7553,25608,25608,25612,25619,1746,25628,25632,25645},
-       { 225,15615,25659,25659,25663,25663,1464,25681,25685,25685},
-       { 237,6301,25710,25710,25714,25721,1464,25728,25732,25750},
-       { 241,7725,3610,3610,25760,25768,1788,25783,25787,25805},
-       { 244,6542,25839,25839,25843,25843,1464,21170,21174,21174},
-       { 246,16392,25857,25857,25861,25861,1464,25869,25873,25888},
-       { 247,9354,4599,4599,25902,25913,2257,25926,25930,25946},
-       { 249,14875,25968,25968,25972,25972,2438,25982,25986,26006},
-       { 251,8176,26026,26026,26030,26038,1884,26049,26053,26069},
-       { 261,15042,26088,26088,26092,26098,2442,26109,26113,26125},
-       { 209,8521,26143,26143,26147,0,1924,26160,26164,0},
-       { 264,15890,26183,26183,26187,26187,1464,21170,21174,21174}
+       { 224,16296,13014,13014,19129,19150,2473,19197,19201,19229},
+       { 3,10618,19253,19253,19257,19269,2144,19288,19292,19307},
+       { 6,7370,19320,19320,19324,19332,1704,19342,19346,19359},
+       { 7,49,14228,14228,19373,19381,1842,19398,19402,19416},
+       { 11,15623,13784,13784,19442,19442,1448,15296,19452,19467},
+       { 14,13163,19482,19482,19486,19494,1343,19506,19510,19510},
+       { 12,13196,19515,19515,19519,19519,1448,19529,19533,19533},
+       { 5,8261,3896,3896,19551,19562,2207,19574,19578,19596},
+       { 25,13726,19616,19616,19620,19641,2327,19661,19665,19701},
+       { 23,12698,19721,19721,19725,19736,2290,19761,19765,19782},
+       { 21,11855,3607,3607,19823,19831,1343,19506,19510,19840},
+       { 35,6161,2597,2597,19845,19854,1325,19871,19875,19889},
+       { 17,16453,19915,19915,19919,19927,2487,19942,19946,19961},
+       { 37,12578,19985,19985,19989,19989,1448,19996,20000,20014},
+       { 26,16720,20027,20027,20031,20031,2513,4996,20039,20058},
+       { 32,7074,20068,20068,20072,20079,1592,20086,20090,20105},
+       { 19,12425,20121,20121,20125,0,2248,20134,20138,0},
+       { 29,7749,20153,20153,20157,20165,1752,20182,20186,20203},
+       { 24,15330,20235,20235,20239,20239,1448,20246,20250,20250},
+       { 39,13289,20264,20264,20268,20268,1448,20275,20279,20295},
+       { 44,15114,20311,20311,20315,20332,2406,20347,20351,20367},
+       { 223,300,20383,20383,20387,20399,1599,1599,20406,20418},
+       { 119,15962,20432,20432,20436,20436,2434,20453,20457,20480},
+       { 46,16145,20498,20498,20502,20502,1448,20508,20512,20525},
+       { 49,15675,20538,20538,20542,20551,2448,20560,20564,20590},
+       { 45,9961,20607,20607,20611,20617,1364,20636,20640,20653},
+       { 51,15048,20672,20672,20676,20676,1448,20685,20689,20704},
+       { 54,14028,20720,20720,20724,20724,2345,20735,20739,20758},
+       { 56,17105,20779,20779,20783,20783,1448,20788,20792,20803},
+       { 75,6317,20815,20815,20819,20834,1367,20852,20856,20878},
+       { 94,6407,2783,2783,20893,20901,1343,19506,19510,19510},
+       { 61,6359,20913,20913,20917,20925,1395,20933,20937,20950},
+       { 65,14633,20962,20962,20966,20985,2373,21007,21011,21026},
+       { 4,13788,21042,21042,21046,21054,2330,21069,21073,21088},
+       { 66,15894,21112,21112,21116,21116,1448,21124,21128,21138},
+       { 70,7847,17060,17060,21160,21168,1343,19506,19510,19840},
+       { 67,13018,21174,21174,21178,21184,2301,21191,21195,21210},
+       { 71,12966,21228,21228,21232,21240,2155,21253,21257,0},
+       { 217,6204,2864,2864,21272,21278,1343,19506,19510,19840},
+       { 73,10438,21286,21286,21290,21299,2130,21315,21319,21334},
+       { 77,6537,2889,2889,21360,21368,1343,19506,19510,19840},
+       { 81,8801,16390,16390,21374,21388,1710,20933,20937,21397},
+       { 84,6581,2917,2917,21410,21410,1343,19506,19510,19840},
+       { 242,10020,21417,21417,21421,21436,2023,21453,21457,21471},
+       { 88,8747,21484,21484,21488,21496,1880,21527,21531,21545},
+       { 93,10962,21580,21580,21584,21594,1395,20933,20937,21611},
+       { 98,6463,21631,21631,21635,21642,1343,19506,19510,21655},
+       { 99,13600,21664,21664,21668,21668,2325,21678,21682,21701},
+       { 104,13111,21709,21709,21713,21733,2311,21761,21765,21782},
+       { 106,16889,21789,21789,21793,21793,2246,21802,21806,21823},
+       { 108,7273,3328,3328,21842,21850,2203,2203,21859,21873},
+       { 103,16592,21887,21887,21891,21897,2501,21904,21908,21923},
+       { 109,6682,2974,2974,21941,21949,1506,21963,21967,21984},
+       { 111,7612,21998,21998,3512,3512,1745,22002,22006,22024},
+       { 68,12527,22041,22041,22045,22053,1343,19506,19510,19510},
+       { 117,6630,22059,22059,22063,22070,1497,22081,22085,22104},
+       { 113,8858,3522,3522,22118,22124,1925,22137,22141,22154},
+       { 121,11630,22189,22189,22193,22198,2234,22211,22215,22227},
+       { 116,8072,22249,22249,22253,22258,1829,22269,22273,22286},
+       { 110,6731,3005,3005,22306,22314,1509,1509,22322,22339},
+       { 118,6774,3033,3033,22355,22361,1343,19506,19510,19840},
+       { 124,14775,22368,22368,22372,22372,1448,22380,22384,22384},
+       { 126,15528,22400,22400,22404,22411,2438,22424,22428,22444},
+       { 122,6819,3063,3063,22466,22472,1523,22479,22483,22496},
+       { 129,9184,22506,22506,22510,22510,1977,22516,22520,22536},
+       { 130,9141,22554,22554,22558,22569,1953,22590,22594,22609},
+       { 40,10086,5054,5054,22639,22648,2026,22670,22674,22689},
+       { 134,6874,3091,3091,22723,22735,1527,22748,22752,22769},
+       { 136,16067,22786,22786,22790,22797,2463,22810,22814,22828},
+       { 137,9072,22850,22850,22854,22865,1932,22884,22888,22906},
+       { 138,10128,5079,5079,22940,5069,2030,22945,22949,22961},
+       { 139,15812,22981,22981,22985,22993,2453,23004,23008,23023},
+       { 145,13937,23045,23045,23049,23049,1599,1599,20406,23063},
+       { 42,10379,23081,23081,23085,23095,2122,23127,23131,23148},
+       { 141,7945,23196,23196,23200,23210,1343,19506,19510,23218},
+       { 147,10898,23224,23224,23228,23239,1343,19506,19510,19510},
+       { 140,7893,23251,23251,23255,23262,1343,19506,19510,23270},
+       { 148,13405,23275,23275,23279,23285,2315,23296,23300,23313},
+       { 159,14232,4918,4918,23333,23341,2349,2483,23354,23370},
+       { 158,14357,23390,23390,23394,23394,1343,19506,19510,19840},
+       { 152,12128,23401,23401,23405,23413,2246,23431,23435,23448},
+       { 270,15754,23464,23464,23468,23479,1343,19506,19510,23497},
+       { 19618,8436,23502,23502,23506,23516,1871,23502,23537,23554},
+       { 157,16189,23586,23586,23590,23590,2434,20453,20457,20480},
+       { 27,10203,23595,23595,23599,5098,2080,23615,23619,23632},
+       { 154,9890,23663,23663,23667,23676,2217,23689,23693,23710},
+       { 151,13877,23723,23723,23727,23743,2340,23771,23775,23791},
+       { 163,8897,4296,4296,23801,23801,1343,19506,19510,23807},
+       { 166,11804,23812,23812,23816,23823,1448,23831,23835,23848},
+       { 167,9002,23862,23862,23866,23866,1929,23875,23879,23897},
+       { 175,10726,23914,23914,23918,23926,2151,23935,23939,23954},
+       { 182,16943,23960,23960,23964,23964,2516,23974,23978,23998},
+       { 176,6926,3119,3119,24021,24033,1343,19506,19510,19510},
+       { 177,6984,3146,3146,24043,24050,1710,24056,24060,24076},
+       { 178,10499,24090,24090,24094,24100,2221,24116,24120,24135},
+       { 183,13972,24176,24176,24180,24180,1448,24192,24196,24196},
+       { 164,14744,24215,24215,24219,24224,2382,24235,24239,24250},
+       { 192,14309,4625,4625,24270,24277,2359,24285,24289,24307},
+       { 187,15375,24324,24324,24328,24333,2431,24339,24343,24356},
+       { 201,10672,24374,24374,24378,24390,2147,24400,24404,24420},
+       { 190,7558,24438,24438,24442,24451,1734,24466,24470,24486},
+       { 191,7025,24514,24514,24518,24525,1550,24532,24536,24549},
+       { 202,17001,24563,24563,24567,24567,1448,21124,21128,21138},
+       { 193,12067,24579,24579,24583,24583,1343,19506,19510,19510},
+       { 185,16545,24592,24592,24596,24596,2497,24605,24609,24628},
+       { 197,16644,24647,24647,24651,24657,2503,24664,24668,24680},
+       { 198,14884,24698,24698,24702,24711,1343,19506,19510,19840},
+       { 200,7169,24723,24723,24727,24735,1621,1621,24744,24757},
+       { 271,15184,17489,17489,24771,24778,2409,2409,24791,24805},
+       { 203,7225,3299,3299,24818,24825,1625,24838,24842,24856},
+       { 204,11498,24888,24888,24892,24892,2190,24899,24903,0},
+       { 205,297,24917,24917,24921,24934,1266,24981,24985,24997},
+       { 221,7414,25017,25017,25021,25028,1710,25036,25040,25054},
+       { 215,13469,25067,25067,25071,25081,1448,25091,25095,25112},
+       { 212,7805,25125,25125,25129,25138,1343,19506,19510,25148},
+       { 143,7324,25153,25153,25157,25166,1343,19506,19510,19840},
+       { 210,15427,25176,25176,25180,25188,2434,20453,20457,20480},
+       { 216,11210,5769,5769,25198,25206,2159,25217,25221,25237},
+       { 72,16807,3642,3642,25253,25253,1448,21124,21128,21138},
+       { 222,15300,25265,25265,25269,25275,2421,25286,25290,25303},
+       { 227,7461,3437,3437,25323,3427,1726,1726,25332,25342},
+       { 228,8024,25361,25361,25365,25376,1953,25397,25401,25420},
+       { 238,9244,25433,25433,25437,25450,1981,1981,25464,25484},
+       { 234,14525,25500,25500,25504,25512,2363,25521,25525,25540},
+       { 235,7507,25562,25562,25566,25573,1730,25582,25586,25599},
+       { 225,15569,25613,25613,25617,25617,1448,25635,25639,25639},
+       { 237,6255,25664,25664,25668,25675,1448,25682,25686,25704},
+       { 241,7679,3564,3564,25714,25722,1748,25737,25741,25759},
+       { 244,6496,25793,25793,25797,25797,1448,21124,21128,21128},
+       { 246,16346,25811,25811,25815,25815,1448,25823,25827,25842},
+       { 247,9308,4553,4553,25856,25867,2211,25880,25884,25900},
+       { 249,14829,25922,25922,25926,25926,2392,25936,25940,25960},
+       { 251,8130,25980,25980,25984,25992,1838,26003,26007,26023},
+       { 261,14996,26042,26042,26046,26052,2396,26063,26067,26079},
+       { 209,8475,26097,26097,26101,0,1878,26114,26118,0},
+       { 264,15844,26137,26137,26141,26141,1448,21124,21128,21128}
 };
 
 
 static const RegionInfoNameEntry region_name_entries [] = {
-       {16342, 0},      /* AE */
-       {10664, 1},      /* AF */
-       {7416, 2},       /* AL */
+       {16296, 0},      /* AE */
+       {10618, 1},      /* AF */
+       {7370, 2},       /* AL */
        {49, 3},         /* AM */
-       {15669, 4},      /* AR */
-       {13209, 5},      /* AT */
-       {13242, 6},      /* AU */
-       {8307, 7},       /* AZ */
-       {13772, 8},      /* BA */
-       {12744, 9},      /* BD */
-       {11901, 10},     /* BE */
-       {6207, 11},      /* BG */
-       {16499, 12},     /* BH */
-       {12624, 13},     /* BN */
-       {16766, 14},     /* BO */
-       {7120, 15},      /* BR */
-       {12471, 16},     /* BW */
-       {7795, 17},      /* BY */
-       {15376, 18},     /* BZ */
-       {13335, 19},     /* CA */
-       {15160, 20},     /* CD */
+       {15623, 4},      /* AR */
+       {13163, 5},      /* AT */
+       {13196, 6},      /* AU */
+       {8261, 7},       /* AZ */
+       {13726, 8},      /* BA */
+       {12698, 9},      /* BD */
+       {11855, 10},     /* BE */
+       {6161, 11},      /* BG */
+       {16453, 12},     /* BH */
+       {12578, 13},     /* BN */
+       {16720, 14},     /* BO */
+       {7074, 15},      /* BR */
+       {12425, 16},     /* BW */
+       {7749, 17},      /* BY */
+       {15330, 18},     /* BZ */
+       {13289, 19},     /* CA */
+       {15114, 20},     /* CD */
        {300, 21},       /* CH */
-       {16008, 22},     /* CI */
-       {16191, 23},     /* CL */
-       {15721, 24},     /* CM */
-       {10007, 25},     /* CN */
-       {15094, 26},     /* CO */
-       {14074, 27},     /* CR */
-       {17151, 28},     /* CU */
-       {6363, 29},      /* CZ */
-       {6453, 30},      /* DE */
-       {6405, 31},      /* DK */
-       {14679, 32},     /* DO */
-       {13834, 33},     /* DZ */
-       {15940, 34},     /* EC */
-       {7893, 35},      /* EE */
-       {13064, 36},     /* EG */
-       {13012, 37},     /* ER */
-       {6250, 38},      /* ES */
-       {10484, 39},     /* ET */
-       {6583, 40},      /* FI */
-       {8847, 41},      /* FO */
-       {6627, 42},      /* FR */
-       {10066, 43},     /* GB */
-       {8793, 44},      /* GE */
-       {11008, 45},     /* GL */
-       {6509, 46},      /* GR */
-       {13646, 47},     /* GT */
-       {13157, 48},     /* HK */
-       {16935, 49},     /* HN */
-       {7319, 50},      /* HR */
-       {16638, 51},     /* HT */
-       {6728, 52},      /* HU */
-       {7658, 53},      /* ID */
-       {12573, 54},     /* IE */
-       {6676, 55},      /* IL */
-       {8904, 56},      /* IN */
-       {11676, 57},     /* IQ */
-       {8118, 58},      /* IR */
-       {6777, 59},      /* IS */
-       {6820, 60},      /* IT */
-       {14821, 61},     /* JM */
-       {15574, 62},     /* JO */
-       {6865, 63},      /* JP */
-       {9230, 64},      /* KE */
-       {9187, 65},      /* KG */
-       {10132, 66},     /* KH */
-       {6920, 67},      /* KR */
-       {16113, 68},     /* KW */
-       {9118, 69},      /* KZ */
-       {10174, 70},     /* LA */
-       {15858, 71},     /* LB */
-       {13983, 72},     /* LI */
-       {10425, 73},     /* LK */
-       {7991, 74},      /* LT */
-       {10944, 75},     /* LU */
-       {7939, 76},      /* LV */
-       {13451, 77},     /* LY */
-       {14278, 78},     /* MA */
-       {14403, 79},     /* MC */
-       {12174, 80},     /* MD */
-       {15800, 81},     /* ME */
-       {8482, 82},      /* MK */
-       {16235, 83},     /* ML */
-       {10249, 84},     /* MM */
-       {9936, 85},      /* MN */
-       {13923, 86},     /* MO */
-       {8943, 87},      /* MT */
-       {11850, 88},     /* MX */
-       {9048, 89},      /* MY */
-       {10772, 90},     /* NG */
-       {16989, 91},     /* NI */
-       {6972, 92},      /* NL */
-       {7030, 93},      /* NO */
-       {10545, 94},     /* NP */
-       {14018, 95},     /* NZ */
-       {14790, 96},     /* OM */
-       {14355, 97},     /* PA */
-       {15421, 98},     /* PE */
-       {10718, 99},     /* PH */
-       {7604, 100},     /* PK */
-       {7071, 101},     /* PL */
-       {17047, 102},    /* PR */
-       {12113, 103},    /* PT */
-       {16591, 104},    /* PY */
-       {16690, 105},    /* QA */
-       {14930, 106},    /* RE */
-       {7215, 107},     /* RO */
-       {15230, 108},    /* RS */
-       {7271, 109},     /* RU */
-       {11544, 110},    /* RW */
+       {15962, 22},     /* CI */
+       {16145, 23},     /* CL */
+       {15675, 24},     /* CM */
+       {9961, 25},      /* CN */
+       {15048, 26},     /* CO */
+       {14028, 27},     /* CR */
+       {17105, 28},     /* CU */
+       {6317, 29},      /* CZ */
+       {6407, 30},      /* DE */
+       {6359, 31},      /* DK */
+       {14633, 32},     /* DO */
+       {13788, 33},     /* DZ */
+       {15894, 34},     /* EC */
+       {7847, 35},      /* EE */
+       {13018, 36},     /* EG */
+       {12966, 37},     /* ER */
+       {6204, 38},      /* ES */
+       {10438, 39},     /* ET */
+       {6537, 40},      /* FI */
+       {8801, 41},      /* FO */
+       {6581, 42},      /* FR */
+       {10020, 43},     /* GB */
+       {8747, 44},      /* GE */
+       {10962, 45},     /* GL */
+       {6463, 46},      /* GR */
+       {13600, 47},     /* GT */
+       {13111, 48},     /* HK */
+       {16889, 49},     /* HN */
+       {7273, 50},      /* HR */
+       {16592, 51},     /* HT */
+       {6682, 52},      /* HU */
+       {7612, 53},      /* ID */
+       {12527, 54},     /* IE */
+       {6630, 55},      /* IL */
+       {8858, 56},      /* IN */
+       {11630, 57},     /* IQ */
+       {8072, 58},      /* IR */
+       {6731, 59},      /* IS */
+       {6774, 60},      /* IT */
+       {14775, 61},     /* JM */
+       {15528, 62},     /* JO */
+       {6819, 63},      /* JP */
+       {9184, 64},      /* KE */
+       {9141, 65},      /* KG */
+       {10086, 66},     /* KH */
+       {6874, 67},      /* KR */
+       {16067, 68},     /* KW */
+       {9072, 69},      /* KZ */
+       {10128, 70},     /* LA */
+       {15812, 71},     /* LB */
+       {13937, 72},     /* LI */
+       {10379, 73},     /* LK */
+       {7945, 74},      /* LT */
+       {10898, 75},     /* LU */
+       {7893, 76},      /* LV */
+       {13405, 77},     /* LY */
+       {14232, 78},     /* MA */
+       {14357, 79},     /* MC */
+       {12128, 80},     /* MD */
+       {15754, 81},     /* ME */
+       {8436, 82},      /* MK */
+       {16189, 83},     /* ML */
+       {10203, 84},     /* MM */
+       {9890, 85},      /* MN */
+       {13877, 86},     /* MO */
+       {8897, 87},      /* MT */
+       {11804, 88},     /* MX */
+       {9002, 89},      /* MY */
+       {10726, 90},     /* NG */
+       {16943, 91},     /* NI */
+       {6926, 92},      /* NL */
+       {6984, 93},      /* NO */
+       {10499, 94},     /* NP */
+       {13972, 95},     /* NZ */
+       {14744, 96},     /* OM */
+       {14309, 97},     /* PA */
+       {15375, 98},     /* PE */
+       {10672, 99},     /* PH */
+       {7558, 100},     /* PK */
+       {7025, 101},     /* PL */
+       {17001, 102},    /* PR */
+       {12067, 103},    /* PT */
+       {16545, 104},    /* PY */
+       {16644, 105},    /* QA */
+       {14884, 106},    /* RE */
+       {7169, 107},     /* RO */
+       {15184, 108},    /* RS */
+       {7225, 109},     /* RU */
+       {11498, 110},    /* RW */
        {297, 111},      /* SA */
-       {7460, 112},     /* SE */
-       {13515, 113},    /* SG */
-       {7851, 114},     /* SI */
-       {7370, 115},     /* SK */
-       {15473, 116},    /* SN */
-       {11256, 117},    /* SO */
-       {16853, 118},    /* SV */
-       {15346, 119},    /* SY */
-       {7507, 120},     /* TH */
-       {8070, 121},     /* TJ */
-       {9290, 122},     /* TM */
-       {14571, 123},    /* TN */
-       {7553, 124},     /* TR */
-       {15615, 125},    /* TT */
-       {6301, 126},     /* TW */
-       {7725, 127},     /* UA */
-       {6542, 128},     /* US */
-       {16392, 129},    /* UY */
-       {9354, 130},     /* UZ */
-       {14875, 131},    /* VE */
-       {8176, 132},     /* VN */
-       {15042, 133},    /* YE */
-       {8521, 134},     /* ZA */
-       {15890, 135}     /* ZW */
+       {7414, 112},     /* SE */
+       {13469, 113},    /* SG */
+       {7805, 114},     /* SI */
+       {7324, 115},     /* SK */
+       {15427, 116},    /* SN */
+       {11210, 117},    /* SO */
+       {16807, 118},    /* SV */
+       {15300, 119},    /* SY */
+       {7461, 120},     /* TH */
+       {8024, 121},     /* TJ */
+       {9244, 122},     /* TM */
+       {14525, 123},    /* TN */
+       {7507, 124},     /* TR */
+       {15569, 125},    /* TT */
+       {6255, 126},     /* TW */
+       {7679, 127},     /* UA */
+       {6496, 128},     /* US */
+       {16346, 129},    /* UY */
+       {9308, 130},     /* UZ */
+       {14829, 131},    /* VE */
+       {8130, 132},     /* VN */
+       {14996, 133},    /* YE */
+       {8475, 134},     /* ZA */
+       {15844, 135}     /* ZW */
 };
 
 
@@ -1814,16 +1814,14 @@ static const char locale_strings [] = {
        "\xd9\xaa\xd8\x9c\0"
        "\xd9\x84\xd9\x8a\xd8\xb3\xc2\xa0\xd8\xb1\xd9\x82\xd9\x85\0"
        "\xd8\x89\0"
-       "\xd8\x9c-Infinity\0"
+       "-Infinity\0"
        "Infinity\0"
-       "\xd8\x9c-\0"
        "\xd8\x9c+\0"
        "\xc2\xa0\0"
        "\xd0\xbb\xd0\xb2.\0"
        "%\0"
        "NaN\0"
        "\xe2\x80\xb0\0"
-       "-Infinity\0"
        "+\0"
        "\xe2\x82\xac\0"
        "-Infinit\0"
@@ -1874,15 +1872,12 @@ static const char locale_strings [] = {
        "THB\0"
        "\xe2\x82\xba\0"
        "Rs\0"
-       "\xe2\x80\x8e-\xe2\x80\x8eInfinity\0"
-       "\xe2\x80\x8e-\xe2\x80\x8e\0"
        "\xe2\x80\x8e+\xe2\x80\x8e\0"
        "Rp\0"
        "\xe2\x82\xb4\0"
        "Br\0"
-       "\xe2\x80\x93neskon\xc4\x8dnost\0"
+       "-neskon\xc4\x8dnost\0"
        "neskon\xc4\x8dnost\0"
-       "\xe2\x80\x93\0"
        "NS\0"
        "-bezgal\xc4\xab\x62\x61\0"
        "bezgal\xc4\xab\x62\x61\0"
index 3c78b6153c23f4d56966de04b7c5dba586f11911..4cda6ddb320b7b922fc56033c80a6b3594322aed 100644 (file)
@@ -44,6 +44,8 @@
 #include <mono/utils/mono-coop-semaphore.h>
 #include <mono/utils/hazard-pointer.h>
 #include <mono/utils/w32api.h>
+#include <mono/utils/unlocked.h>
+#include <mono/utils/mono-os-wait.h>
 
 #ifndef HOST_WIN32
 #include <pthread.h>
@@ -597,7 +599,7 @@ ves_icall_System_GC_WaitForPendingFinalizers (void)
        mono_gc_finalize_notify ();
        /* g_print ("Waiting for pending finalizers....\n"); */
        MONO_ENTER_GC_SAFE;
-       WaitForSingleObjectEx (pending_done_event, INFINITE, TRUE);
+       mono_win32_wait_for_single_object_ex (pending_done_event, INFINITE, TRUE);
        MONO_EXIT_GC_SAFE;
        /* g_print ("Done pending....\n"); */
 #else
@@ -780,7 +782,7 @@ finalize_domain_objects (void)
        DomainFinalizationReq *req = NULL;
        MonoDomain *domain;
 
-       if (domains_to_finalize) {
+       if (UnlockedReadPointer ((gpointer)&domains_to_finalize)) {
                mono_finalizer_lock ();
                if (domains_to_finalize) {
                        req = (DomainFinalizationReq *)domains_to_finalize->data;
@@ -995,7 +997,7 @@ mono_gc_cleanup (void)
                                        ret = guarded_wait (gc_thread->handle, MONO_INFINITE_WAIT, FALSE);
                                        g_assert (ret == MONO_THREAD_INFO_WAIT_RET_SUCCESS_0);
 
-                                       mono_threads_add_joinable_thread (GUINT_TO_POINTER (gc_thread->tid));
+                                       mono_threads_add_joinable_thread ((gpointer)(MONO_UINT_TO_NATIVE_THREAD_ID (gc_thread->tid)));
                                        break;
                                }
 
@@ -1008,7 +1010,7 @@ mono_gc_cleanup (void)
                                        mono_gc_suspend_finalizers ();
 
                                        /* Try to abort the thread, in the hope that it is running managed code */
-                                       mono_thread_internal_abort (gc_thread);
+                                       mono_thread_internal_abort (gc_thread, FALSE);
 
                                        /* Wait for it to stop */
                                        ret = guarded_wait (gc_thread->handle, 100, FALSE);
@@ -1020,7 +1022,7 @@ mono_gc_cleanup (void)
 
                                        g_assert (ret == MONO_THREAD_INFO_WAIT_RET_SUCCESS_0);
 
-                                       mono_threads_add_joinable_thread (GUINT_TO_POINTER (gc_thread->tid));
+                                       mono_threads_add_joinable_thread ((gpointer)(MONO_UINT_TO_NATIVE_THREAD_ID (gc_thread->tid)));
                                        break;
                                }
 
index 28615d8c1a986bb9eacb71051805387e20e365f0..47fbefe2cda02b7ebb2a3794a02be0e393c5e3ae 100644 (file)
@@ -535,7 +535,8 @@ ICALL(ASSEMN_2, "get_public_token", mono_digest_get_public_token)
 ICALL_TYPE(CATTR_DATA, "System.Reflection.CustomAttributeData", CATTR_DATA_1)
 ICALL(CATTR_DATA_1, "ResolveArgumentsInternal", ves_icall_System_Reflection_CustomAttributeData_ResolveArgumentsInternal)
 
-ICALL_TYPE(ASSEMB, "System.Reflection.Emit.AssemblyBuilder", ASSEMB_2)
+ICALL_TYPE(ASSEMB, "System.Reflection.Emit.AssemblyBuilder", ASSEMB_1)
+HANDLES(ICALL(ASSEMB_1, "UpdateNativeCustomAttributes", ves_icall_AssemblyBuilder_UpdateNativeCustomAttributes))
 ICALL(ASSEMB_2, "basic_init", ves_icall_AssemblyBuilder_basic_init)
 
 #ifndef DISABLE_REFLECTION_EMIT
index 2e485848486d0363b3b7d0929849fcec894b26b6..f55ed1f1847600caf96c9aced596651945e01320 100644 (file)
@@ -1014,7 +1014,7 @@ ves_icall_System_Runtime_CompilerServices_RuntimeHelpers_SufficientExecutionStac
 {
 #if defined(TARGET_WIN32) || defined(HOST_WIN32)
        // It does not work on win32
-#elif defined(TARGET_ANDROID)
+#elif defined(TARGET_ANDROID) || defined(__linux__)
        // No need for now
 #else
        guint8 *stack_addr;
index 85b5639384b1e70c1ac590fc5dd5d3108ea336d0..a5ef34da2d6e5901cd3c2e704b90bb3fdeeeb3b6 100644 (file)
@@ -74,6 +74,10 @@ static gint32 signatures_size;
 MonoNativeTlsKey loader_lock_nest_id;
 
 static void dllmap_cleanup (void);
+static void cached_module_cleanup(void);
+
+/* Class lazy loading functions */
+GENERATE_GET_CLASS_WITH_CACHE (appdomain_unloaded_exception, "System", "AppDomainUnloadedException")
 
 static void
 global_loader_data_lock (void)
@@ -117,6 +121,7 @@ void
 mono_loader_cleanup (void)
 {
        dllmap_cleanup ();
+       cached_module_cleanup ();
 
        mono_native_tls_free (loader_lock_nest_id);
 
@@ -312,9 +317,17 @@ mono_field_from_token_checked (MonoImage *image, guint32 token, MonoClass **retk
                mono_class_init (k);
                if (retklass)
                        *retklass = k;
-               field = mono_class_get_field (k, token);
-               if (!field) {
-                       mono_error_set_bad_image (error, image, "Could not resolve field token 0x%08x", token);
+               if (mono_class_has_failure (k)) {
+                       MonoError causedby_error;
+                       error_init (&causedby_error);
+                       mono_error_set_for_class_failure (&causedby_error, k);
+                       mono_error_set_bad_image (error, image, "Could not resolve field token 0x%08x, due to: %s", token, mono_error_get_message (&causedby_error));
+                       mono_error_cleanup (&causedby_error);
+               } else {
+                       field = mono_class_get_field (k, token);
+                       if (!field) {
+                               mono_error_set_bad_image (error, image, "Could not resolve field token 0x%08x", token);
+                       }
                }
        }
 
@@ -1137,6 +1150,23 @@ mono_loader_register_module (const char *name, MonoDl *module)
        g_hash_table_insert (global_module_map, g_strdup (name), module);
 }
 
+static void
+remove_cached_module(gpointer key, gpointer value, gpointer user_data)
+{
+       mono_dl_close((MonoDl*)value);
+}
+
+static void
+cached_module_cleanup(void)
+{
+       if (global_module_map != NULL) {
+               g_hash_table_foreach(global_module_map, remove_cached_module, NULL);
+
+               g_hash_table_destroy(global_module_map);
+               global_module_map = NULL;
+       }
+}
+
 static MonoDl *internal_module;
 
 static gboolean
index 666c158332e59a59b3bcbb48ea0328defc7a9dd5..e898178e00a1532a253acbf3adea8e23787c6fd9 100644 (file)
@@ -1514,6 +1514,7 @@ parse_method_signature (VerifyContext *ctx, const char **_ptr, const char *end,
 static gboolean
 parse_property_signature (VerifyContext *ctx, const char **_ptr, const char *end)
 {
+       unsigned type = 0;
        unsigned sig = 0;
        unsigned param_count = 0, i;
        const char *ptr = *_ptr;
@@ -1530,6 +1531,13 @@ parse_property_signature (VerifyContext *ctx, const char **_ptr, const char *end
        if (!parse_custom_mods (ctx, &ptr, end))
                return FALSE;
 
+       if (!safe_read8 (type, ptr, end))
+               FAIL (ctx, g_strdup ("PropertySig: Not enough room for the type"));
+
+       //check if it's a byref. safe_read8 did update ptr, so we rollback if it's not a byref
+       if (type != MONO_TYPE_BYREF)
+               --ptr;
+
        if (!parse_type (ctx, &ptr, end))
                FAIL (ctx, g_strdup ("PropertySig: Could not parse property type"));
 
index c371f0f3c476c0e6756c97460e5c37e9cd3e1bc5..d3b51abfc80247f536fdb2410f28edf528411200 100644 (file)
@@ -32,6 +32,7 @@
 #include <mono/utils/mono-time.h>
 #include <mono/utils/atomic.h>
 #include <mono/utils/w32api.h>
+#include <mono/utils/mono-os-wait.h>
 
 /*
  * Pull the list of opcodes
@@ -1387,7 +1388,7 @@ ves_icall_System_Threading_Monitor_Monitor_wait (MonoObject *obj, guint32 ms)
         */
        MONO_ENTER_GC_SAFE;
 #ifdef HOST_WIN32
-       ret = mono_w32handle_convert_wait_ret (WaitForSingleObjectEx (event, ms, TRUE), 1);
+       ret = mono_w32handle_convert_wait_ret (mono_win32_wait_for_single_object_ex (event, ms, TRUE), 1);
 #else
        ret = mono_w32handle_wait_one (event, ms, TRUE);
 #endif /* HOST_WIN32 */
@@ -1416,7 +1417,7 @@ ves_icall_System_Threading_Monitor_Monitor_wait (MonoObject *obj, guint32 ms)
                 */
                MONO_ENTER_GC_SAFE;
 #ifdef HOST_WIN32
-               ret = mono_w32handle_convert_wait_ret (WaitForSingleObjectEx (event, 0, FALSE), 1);
+               ret = mono_w32handle_convert_wait_ret (mono_win32_wait_for_single_object_ex (event, 0, FALSE), 1);
 #else
                ret = mono_w32handle_wait_one (event, 0, FALSE);
 #endif /* HOST_WIN32 */
index 1b558370d02c12c4bfc3ce7d7394a0ffff774f8d..4ef79e7385c5d70efaeddd8d5aa7109d53675382 100644 (file)
@@ -34,8 +34,9 @@
 #include "metadata/gc-internals.h"
 #include <mono/utils/checked-build.h>
 #include <mono/utils/mono-threads-coop.h>
+#include <mono/utils/unlocked.h>
 
-int mono_g_hash_table_max_chain_length;
+gint32 mono_g_hash_table_max_chain_length;
 
 #ifdef HAVE_BOEHM_GC
 #define mg_new0(type,n)  ((type *) GC_MALLOC(sizeof(type) * (n)))
@@ -136,10 +137,12 @@ static inline int mono_g_hash_table_find_slot (MonoGHashTable *hash, const MonoO
                }
        }
 
-       if (i > start && (i - start) > mono_g_hash_table_max_chain_length)
-               mono_g_hash_table_max_chain_length = i - start;
-       else if (i < start && (hash->table_size - (start - i)) > mono_g_hash_table_max_chain_length)
-               mono_g_hash_table_max_chain_length = hash->table_size - (start - i);
+       gint32 max_length = UnlockedRead (&mono_g_hash_table_max_chain_length);
+       if (i > start && (i - start) > max_length)
+               UnlockedWrite (&mono_g_hash_table_max_chain_length, i - start);
+       else if (i < start && (hash->table_size - (start - i)) > max_length)
+               UnlockedWrite (&mono_g_hash_table_max_chain_length, hash->table_size - (start - i));
+
        return i;
 }
 
index 7f778e50bd10445a9413a184e4f9683235358af2..10e3ca390eda833103f4c7b5d8787a631e0f7d2b 100644 (file)
@@ -22,7 +22,7 @@ typedef enum {
        MONO_HASH_KEY_VALUE_GC = MONO_HASH_KEY_GC | MONO_HASH_VALUE_GC,
 } MonoGHashGCType;
 
-extern int mono_g_hash_table_max_chain_length;
+extern gint32 mono_g_hash_table_max_chain_length;
 
 typedef struct _MonoGHashTable MonoGHashTable;
 
index 07aaee6830005ba3f2df4103838289d2820a772a..26b11d77371cea4845516ba3b19805a7f4390335 100644 (file)
@@ -376,6 +376,7 @@ typedef struct {
 typedef enum {
        MONO_THREAD_FLAG_DONT_MANAGE = 1, // Don't wait for or abort this thread
        MONO_THREAD_FLAG_NAME_SET = 2, // Thread name set from managed code
+       MONO_THREAD_FLAG_APPDOMAIN_ABORT = 4, // Current requested abort originates from appdomain unload
 } MonoThreadFlags;
 
 struct _MonoInternalThread {
@@ -1925,8 +1926,8 @@ ves_icall_ModuleBuilder_GetRegisteredToken (MonoReflectionModuleBuilderHandle mb
 void
 ves_icall_AssemblyBuilder_basic_init (MonoReflectionAssemblyBuilder *assemblyb);
 
-MonoReflectionModule*
-ves_icall_AssemblyBuilder_InternalAddModule (MonoReflectionAssemblyBuilder *ab, MonoString *fileName);
+void
+ves_icall_AssemblyBuilder_UpdateNativeCustomAttributes (MonoReflectionAssemblyBuilderHandle assemblyb, MonoError *error);
 
 MonoArray*
 ves_icall_CustomAttributeBuilder_GetBlob (MonoReflectionAssembly *assembly, MonoObject *ctor, MonoArray *ctorArgs, MonoArray *properties, MonoArray *propValues, MonoArray *fields, MonoArray* fieldValues);
index 233f9528ed90ca0a34cdf5377989320fe0dc61c7..8968bf737f5b1a9219671cdf4d0473e92777e330 100644 (file)
@@ -232,6 +232,7 @@ DECL_OFFSET(MonoLMF, pc)
 DECL_OFFSET(MonoLMF, gregs)
 DECL_OFFSET(DynCallArgs, regs)
 DECL_OFFSET(DynCallArgs, fpregs)
+DECL_OFFSET(DynCallArgs, n_stackargs)
 DECL_OFFSET(DynCallArgs, n_fpargs)
 DECL_OFFSET(DynCallArgs, n_fpret)
 #endif
index 7d373ae382b85fbfc9190bbd80388ecbc7dc6119..457c50e02cc115b4deeeaa547ff0453ef9df24c5 100644 (file)
@@ -4587,7 +4587,14 @@ mono_unhandled_exception_checked (MonoObjectHandle exc, MonoError *error)
        MonoObjectHandle current_appdomain_delegate = MONO_HANDLE_NEW (MonoObject, NULL);
 
        MonoClass *klass = mono_handle_class (exc);
-       if (mono_class_has_parent (klass, mono_defaults.threadabortexception_class))
+       /*
+        * AppDomainUnloadedException don't behave like unhandled exceptions unless thrown from 
+        * a thread started in unmanaged world.
+        * https://msdn.microsoft.com/en-us/library/system.appdomainunloadedexception(v=vs.110).aspx#Anchor_6
+        */
+       if (klass == mono_defaults.threadabortexception_class ||
+                       (klass == mono_class_get_appdomain_unloaded_exception_class () &&
+                       mono_thread_info_current ()->runtime_thread))
                return;
 
        field = mono_class_get_field_from_name (mono_defaults.appdomain_class, "UnhandledException");
index ea2ff0c3d7b2fc029d42a882f828d220bee6258f..dccb077b4f72cc41ccf1b0a47e9dee452794ad3d 100644 (file)
@@ -21,6 +21,7 @@
 #include "mono/metadata/exception.h"
 #include "mono/metadata/debug-helpers.h"
 #include "mono/metadata/reflection-internals.h"
+#include "mono/metadata/assembly.h"
 
 typedef enum {
        MONO_MARSHAL_NONE,                      /* No marshalling needed */
@@ -52,6 +53,9 @@ typedef struct _MonoRemotingMethods MonoRemotingMethods;
 static MonoObject *
 mono_remoting_wrapper (MonoMethod *method, gpointer *params);
 
+static MonoException *
+mono_remoting_update_exception (MonoException *exc);
+
 static gint32
 mono_marshal_set_domain_by_id (gint32 id, MonoBoolean push);
 
@@ -206,6 +210,7 @@ mono_remoting_marshal_init (void)
                register_icall (ves_icall_mono_marshal_xdomain_copy_value, "ves_icall_mono_marshal_xdomain_copy_value", "object object", FALSE);
                register_icall (mono_marshal_xdomain_copy_out_value, "mono_marshal_xdomain_copy_out_value", "void object object", FALSE);
                register_icall (mono_remoting_wrapper, "mono_remoting_wrapper", "object ptr ptr", FALSE);
+               register_icall (mono_remoting_update_exception, "mono_remoting_update_exception", "object object", FALSE);
                register_icall (mono_upgrade_remote_class_wrapper, "mono_upgrade_remote_class_wrapper", "void object object", FALSE);
 
 #ifndef DISABLE_JIT
@@ -425,6 +430,7 @@ mono_remoting_wrapper (MonoMethod *method, gpointer *params)
 
        if (exc) {
                error_init (&error);
+               exc = (MonoObject*) mono_remoting_update_exception ((MonoException*)exc);
                mono_error_set_exception_instance (&error, (MonoException *)exc);
                goto fail;
        }
@@ -444,6 +450,37 @@ fail:
        return NULL;
 } 
 
+/*
+ * Handles exception transformation at appdomain call boundary.
+ * Note this is called from target appdomain inside xdomain wrapper, but from
+ * source domain in the mono_remoting_wrapper slowpath.
+ */
+static MonoException *
+mono_remoting_update_exception (MonoException *exc)
+{
+       MonoInternalThread *thread;
+       MonoClass *klass = mono_object_get_class ((MonoObject*)exc);
+
+       /* Serialization error can only happen when still in the target appdomain */
+       if (!(mono_class_get_flags (klass) & TYPE_ATTRIBUTE_SERIALIZABLE)) {
+               MonoException *ret;
+               char *aname = mono_stringify_assembly_name (&klass->image->assembly->aname);
+               char *message = g_strdup_printf ("Type '%s' in Assembly '%s' is not marked as serializable", klass->name, aname);
+               ret =  mono_get_exception_serialization (message);
+               g_free (aname);
+               g_free (message);
+               return ret;
+       }
+
+       thread = mono_thread_internal_current ();
+       if (mono_object_get_class ((MonoObject*)exc) == mono_defaults.threadabortexception_class &&
+                       thread->flags & MONO_THREAD_FLAG_APPDOMAIN_ABORT) {
+               mono_thread_internal_reset_abort (thread);
+               return mono_get_exception_appdomain_unloaded ();
+       }
+
+       return exc;
+}
 
 /**
  * mono_marshal_get_remoting_invoke:
@@ -671,8 +708,8 @@ mono_marshal_get_xappdomain_dispatch (MonoMethod *method, int *marshal_types, in
        int i, j, param_index, copy_locals_base;
        MonoClass *ret_class = NULL;
        int loc_array=0, loc_return=0, loc_serialized_exc=0;
-       MonoExceptionClause *clauses, *main_clause, *serialization_clause;
-       int pos, pos_leave, pos_leave_serialization;
+       MonoExceptionClause *main_clause;
+       int pos, pos_leave;
        gboolean copy_return;
        WrapperInfo *info;
 
@@ -714,8 +751,7 @@ mono_marshal_get_xappdomain_dispatch (MonoMethod *method, int *marshal_types, in
 
        /* try */
 
-       clauses = (MonoExceptionClause *)mono_image_alloc0 (method->klass->image, 2 * sizeof (MonoExceptionClause));
-       main_clause = &clauses [0];
+       main_clause = (MonoExceptionClause *)mono_image_alloc0 (method->klass->image, sizeof (MonoExceptionClause));
        main_clause->try_offset = mono_mb_get_label (mb);
 
        /* Clean the call context */
@@ -896,33 +932,8 @@ mono_marshal_get_xappdomain_dispatch (MonoMethod *method, int *marshal_types, in
        /* handler code */
        main_clause->handler_offset = mono_mb_get_label (mb);
 
-       /*
-        * We deserialize the exception in another try-catch so we can catch
-        * serialization failure exceptions.
-        */
-       serialization_clause = &clauses [1];
-       serialization_clause->try_offset = mono_mb_get_label (mb);
-
-       mono_mb_emit_managed_call (mb, method_rs_serialize_exc, NULL);
-       mono_mb_emit_stloc (mb, loc_serialized_exc);
-       mono_mb_emit_ldarg (mb, 2);
-       mono_mb_emit_ldloc (mb, loc_serialized_exc);
-       mono_mb_emit_byte (mb, CEE_STIND_REF);
-       pos_leave_serialization = mono_mb_emit_branch (mb, CEE_LEAVE);
-
-       /* Serialization exception catch */
-       serialization_clause->flags = MONO_EXCEPTION_CLAUSE_NONE;
-       serialization_clause->try_len = mono_mb_get_pos (mb) - serialization_clause->try_offset;
-       serialization_clause->data.catch_class = mono_defaults.object_class;
-
-       /* handler code */
-       serialization_clause->handler_offset = mono_mb_get_label (mb);
-
-       /*
-        * If the serialization of the original exception failed we serialize the newly
-        * thrown exception, which should always succeed, passing it over to the calling
-        * domain.
-        */
+       mono_mb_emit_icall (mb, mono_remoting_update_exception);
+       mono_mb_emit_op (mb, CEE_CASTCLASS, mono_defaults.exception_class);
        mono_mb_emit_managed_call (mb, method_rs_serialize_exc, NULL);
        mono_mb_emit_stloc (mb, loc_serialized_exc);
        mono_mb_emit_ldarg (mb, 2);
@@ -930,13 +941,8 @@ mono_marshal_get_xappdomain_dispatch (MonoMethod *method, int *marshal_types, in
        mono_mb_emit_byte (mb, CEE_STIND_REF);
        mono_mb_emit_branch (mb, CEE_LEAVE);
 
-       /* end serialization exception catch */
-       serialization_clause->handler_len = mono_mb_get_pos (mb) - serialization_clause->handler_offset;
-       mono_mb_patch_branch (mb, pos_leave_serialization);
-
-       mono_mb_emit_branch (mb, CEE_LEAVE);
-       /* end main catch */
        main_clause->handler_len = mono_mb_get_pos (mb) - main_clause->handler_offset;
+       /* end catch */
        mono_mb_patch_branch (mb, pos_leave);
        
        if (copy_return)
@@ -944,7 +950,7 @@ mono_marshal_get_xappdomain_dispatch (MonoMethod *method, int *marshal_types, in
 
        mono_mb_emit_byte (mb, CEE_RET);
 
-       mono_mb_set_clauses (mb, 2, clauses);
+       mono_mb_set_clauses (mb, 1, main_clause);
 #endif
 
        info = mono_wrapper_info_create (mb, WRAPPER_SUBTYPE_NONE);
index df39ea5c5676d099098001fde4f2b65e9abf026d..4f8a285f4993c05e2bf1a4a90c99967917841032 100644 (file)
@@ -398,6 +398,7 @@ get_array_fill_vtable (void)
                klass.rank = 1;
                klass.instance_size = MONO_SIZEOF_MONO_ARRAY;
                klass.sizes.element_size = 1;
+               klass.size_inited = 1;
                klass.name = "array_filler_type";
 
                vtable->klass = &klass;
@@ -2260,8 +2261,7 @@ sgen_client_thread_detach_with_lock (SgenThreadInfo *p)
 
        tid = mono_thread_info_get_tid (p);
 
-       if (p->client_info.info.runtime_thread)
-               mono_threads_add_joinable_thread ((gpointer)tid);
+       mono_threads_add_joinable_runtime_thread (&p->client_info.info);
 
        if (mono_gc_get_gc_callbacks ()->thread_detach_func) {
                mono_gc_get_gc_callbacks ()->thread_detach_func (p->client_info.runtime_data);
index 649791e7beafcb4104a181e0c720a2509ea53d4b..3bcba2bf0cf75267ab34d01c3f47a62cd6bf50cc 100644 (file)
@@ -374,6 +374,12 @@ mono_save_custom_attrs (MonoImage *image, void *obj, MonoArray *cattrs)
        mono_image_property_insert (image, obj, MONO_PROP_DYNAMIC_CATTR, ainfo);
        mono_loader_unlock ();
 
+}
+#else
+//FIXME some code compiled under DISABLE_REFLECTION_EMIT depends on this function, we should be more aggressively disabling things
+static void
+mono_save_custom_attrs (MonoImage *image, void *obj, MonoArray *cattrs)
+{
 }
 #endif
 
@@ -2777,7 +2783,7 @@ reflection_methodbuilder_to_mono_method (MonoClass *klass,
                        (rmb->iattrs & METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL))
                m = (MonoMethod *)image_g_new0 (image, MonoMethodPInvoke, 1);
        else
-               m = (MonoMethod *)image_g_new0 (image, MonoMethodWrapper, 1);
+               m = (MonoMethod *)image_g_new0 (image, MonoDynamicMethod, 1);
 
        wrapperm = (MonoMethodWrapper*)m;
 
@@ -2872,6 +2878,8 @@ reflection_methodbuilder_to_mono_method (MonoClass *klass,
                }
 
                wrapperm->header = header;
+               MonoDynamicMethod *dm = (MonoDynamicMethod*)wrapperm;
+               dm->assembly = klass->image->assembly;
        }
 
        if (rmb->generic_params) {
@@ -3908,6 +3916,7 @@ reflection_create_dynamic_method (MonoReflectionDynamicMethodHandle ref_mb, Mono
                rmb.refs [i + 1] = handle_class;
        }               
 
+       MonoAssembly *ass = NULL;
        if (mb->owner) {
                MonoType *owner_type = mono_reflection_type_get_handle ((MonoReflectionType*)mb->owner, error);
                if (!is_ok (error)) {
@@ -3915,11 +3924,14 @@ reflection_create_dynamic_method (MonoReflectionDynamicMethodHandle ref_mb, Mono
                        return FALSE;
                }
                klass = mono_class_from_mono_type (owner_type);
+               ass = klass->image->assembly;
        } else {
                klass = mono_defaults.object_class;
+               ass = (mb->module && mb->module->image) ? mb->module->image->assembly : NULL;
        }
 
        mb->mhandle = handle = reflection_methodbuilder_to_mono_method (klass, &rmb, sig, error);
+       ((MonoDynamicMethod*)handle)->assembly = ass;
        g_free (rmb.refs);
        return_val_if_nok (error, FALSE);
 
@@ -4371,6 +4383,18 @@ ves_icall_AssemblyBuilder_basic_init (MonoReflectionAssemblyBuilder *assemblyb)
        mono_reflection_dynimage_basic_init (assemblyb);
 }
 
+void
+ves_icall_AssemblyBuilder_UpdateNativeCustomAttributes (MonoReflectionAssemblyBuilderHandle assemblyb, MonoError *error)
+{
+       MonoArrayHandle cattrs = MONO_HANDLE_NEW_GET (MonoArray, assemblyb, cattrs);
+
+       MonoReflectionAssemblyHandle assembly_handle = MONO_HANDLE_CAST (MonoReflectionAssembly, assemblyb);
+       MonoAssembly *assembly = MONO_HANDLE_GETVAL (assembly_handle, assembly);
+       g_assert (assembly);
+
+       mono_save_custom_attrs (assembly->image, assembly, MONO_HANDLE_RAW (cattrs));
+}
+
 void
 ves_icall_EnumBuilder_setup_enum_type (MonoReflectionTypeHandle enumtype,
                                       MonoReflectionTypeHandle t,
index 1c8c1f401a8fb0a49c3f0cdb8b9f1abeeedeeda4..a1424beaebaea483723c7cda7050bed4182730f6 100644 (file)
@@ -46,6 +46,7 @@
 #include <mono/utils/mono-threads.h>
 #include <mono/utils/mono-time.h>
 #include <mono/utils/refcount.h>
+#include <mono/utils/mono-os-wait.h>
 
 typedef struct {
        MonoDomain *domain;
@@ -495,7 +496,7 @@ mono_threadpool_end_invoke (MonoAsyncResult *ares, MonoArray **out_args, MonoObj
                mono_monitor_exit ((MonoObject*) ares);
                MONO_ENTER_GC_SAFE;
 #ifdef HOST_WIN32
-               WaitForSingleObjectEx (wait_event, INFINITE, TRUE);
+               mono_win32_wait_for_single_object_ex (wait_event, INFINITE, TRUE);
 #else
                mono_w32handle_wait_one (wait_event, MONO_INFINITE_WAIT, TRUE);
 #endif
index ced0ac516efbf9a8e91c47df9fbef6ceec645bc6..2feb0ba4f8488713a117dd3a8156fb28de455e03 100644 (file)
@@ -189,7 +189,7 @@ void ves_icall_System_Runtime_Remoting_Contexts_Context_ReleaseContext (MonoAppC
 
 MonoInternalThread *mono_thread_internal_current (void);
 
-void mono_thread_internal_abort (MonoInternalThread *thread);
+void mono_thread_internal_abort (MonoInternalThread *thread, gboolean appdomain_unload);
 void mono_thread_internal_suspend_for_shutdown (MonoInternalThread *thread);
 
 gboolean mono_thread_internal_has_appdomain_ref (MonoInternalThread *thread, MonoDomain *domain);
@@ -242,6 +242,7 @@ gboolean
 mono_thread_create_checked (MonoDomain *domain, gpointer func, gpointer arg, MonoError *error);
 
 /* Can't include utils/mono-threads.h because of the THREAD_INFO_TYPE wizardry */
+void mono_threads_add_joinable_runtime_thread (gpointer thread_info);
 void mono_threads_add_joinable_thread (gpointer tid);
 void mono_threads_join_threads (void);
 void mono_thread_join (gpointer tid);
index 3eb6b3b623c8994cf3b2442b79a4270c2eebcc0b..43c8a61d9ab8159f75591149aa572c470dc52227 100644 (file)
@@ -54,6 +54,7 @@
 #include <mono/metadata/abi-details.h>
 #include <mono/metadata/w32error.h>
 #include <mono/utils/w32api.h>
+#include <mono/utils/mono-os-wait.h>
 
 #ifdef HAVE_SIGNAL_H
 #include <signal.h>
@@ -61,6 +62,9 @@
 
 #if defined(HOST_WIN32)
 #include <objbase.h>
+
+extern gboolean
+mono_native_thread_join_handle (HANDLE thread_handle, gboolean close_handle);
 #endif
 
 #if defined(HOST_ANDROID) && !defined(TARGET_ARM64) && !defined(TARGET_AMD64)
@@ -199,9 +203,6 @@ static gboolean shutting_down = FALSE;
 
 static gint32 managed_thread_id_counter = 0;
 
-/* Class lazy loading functions */
-static GENERATE_GET_CLASS_WITH_CACHE (appdomain_unloaded_exception, "System", "AppDomainUnloadedException")
-
 static void
 mono_threads_lock (void)
 {
@@ -760,6 +761,15 @@ mono_thread_detach_internal (MonoInternalThread *thread)
        thread->abort_exc = NULL;
        thread->current_appcontext = NULL;
 
+       /*
+       * Prevent race condition between execution of this method and runtime shutdown.
+       * Adding runtime thread to the joinable threads list will make sure runtime shutdown
+       * won't complete until added runtime thread have exited. Owner of threads attached to the
+       * runtime but not identified as runtime threads needs to make sure thread detach calls won't
+       * race with runtime shutdown.
+       */
+       mono_threads_add_joinable_runtime_thread (thread->thread_info);
+
        /*
         * thread->synch_cs can be NULL if this was called after
         * ves_icall_System_Threading_InternalThread_Thread_free_internal.
@@ -1023,9 +1033,7 @@ static guint32 WINAPI start_wrapper_internal(StartInfo *start_info, gsize *stack
 
        mono_thread_detach_internal (internal);
 
-       internal->tid = 0;
-
-       return(0);
+       return 0;
 }
 
 static gsize WINAPI
@@ -1119,7 +1127,7 @@ create_thread (MonoThread *thread, MonoInternalThread *internal, MonoObject *sta
        else
                stack_set_size = 0;
 
-       if (!mono_thread_platform_create_thread (start_wrapper, start_info, &stack_set_size, &tid)) {
+       if (!mono_thread_platform_create_thread ((MonoThreadStart)start_wrapper, start_info, &stack_set_size, &tid)) {
                /* The thread couldn't be created, so set an exception */
                mono_threads_lock ();
                mono_g_hash_table_remove (threads_starting_up, thread);
@@ -1593,6 +1601,8 @@ ves_icall_System_Threading_Thread_GetName_internal (MonoInternalThread *this_obj
 void 
 mono_thread_set_name_internal (MonoInternalThread *this_obj, MonoString *name, gboolean permanent, gboolean reset, MonoError *error)
 {
+       MonoNativeThreadId tid = 0;
+
        LOCK_THREAD (this_obj);
 
        error_init (error);
@@ -1619,14 +1629,16 @@ mono_thread_set_name_internal (MonoInternalThread *this_obj, MonoString *name, g
        else
                this_obj->name = NULL;
 
-       
+       if (!(this_obj->state & ThreadState_Stopped))
+               tid = thread_get_tid (this_obj);
+
        UNLOCK_THREAD (this_obj);
 
-       if (this_obj->name && this_obj->tid) {
+       if (this_obj->name && tid) {
                char *tname = mono_string_to_utf8_checked (name, error);
                return_if_nok (error);
-               MONO_PROFILER_RAISE (thread_name, (this_obj->tid, tname));
-               mono_native_thread_set_name (thread_get_tid (this_obj), tname);
+               MONO_PROFILER_RAISE (thread_name, ((uintptr_t)tid, tname));
+               mono_native_thread_set_name (tid, tname);
                mono_free (tname);
        }
 }
@@ -1822,8 +1834,6 @@ ves_icall_System_Threading_Thread_Join_internal (MonoThread *this_obj, int ms)
                return FALSE;
        }
 
-       MonoNativeThreadId tid = thread_get_tid (thread);
-
        UNLOCK_THREAD (thread);
 
        if (ms == -1)
@@ -1841,16 +1851,9 @@ ves_icall_System_Threading_Thread_Join_internal (MonoThread *this_obj, int ms)
        if (ret == MONO_THREAD_INFO_WAIT_RET_SUCCESS_0) {
                THREAD_DEBUG (g_message ("%s: join successful", __func__));
 
-#ifdef HOST_WIN32
-               /* TODO: Do this on Unix platforms as well. See PR #5454 for context.  */
                /* Wait for the thread to really exit */
-               MONO_ENTER_GC_SAFE;
-               /* This shouldn't block */
-               mono_threads_join_lock ();
-               mono_native_thread_join (tid);
-               mono_threads_join_unlock ();
-               MONO_EXIT_GC_SAFE;
-#endif
+               MonoNativeThreadId tid = thread_get_tid (thread);
+               mono_thread_join (tid);
 
                return TRUE;
        }
@@ -1909,9 +1912,9 @@ ves_icall_System_Threading_WaitHandle_Wait_internal (gpointer *handles, gint32 n
                MONO_ENTER_GC_SAFE;
 #ifdef HOST_WIN32
                if (numhandles != 1)
-                       ret = mono_w32handle_convert_wait_ret (WaitForMultipleObjectsEx (numhandles, handles, waitall, timeoutLeft, TRUE), numhandles);
+                       ret = mono_w32handle_convert_wait_ret (mono_win32_wait_for_multiple_objects_ex(numhandles, handles, waitall, timeoutLeft, TRUE), numhandles);
                else
-                       ret = mono_w32handle_convert_wait_ret (WaitForSingleObjectEx (handles [0], timeoutLeft, TRUE), 1);
+                       ret = mono_w32handle_convert_wait_ret (mono_win32_wait_for_single_object_ex (handles [0], timeoutLeft, TRUE), 1);
 #else
                /* mono_w32handle_wait_multiple optimizes the case for numhandles == 1 */
                ret = mono_w32handle_wait_multiple (handles, numhandles, waitall, timeoutLeft, TRUE);
@@ -1961,7 +1964,7 @@ ves_icall_System_Threading_WaitHandle_SignalAndWait_Internal (gpointer toSignal,
        
        MONO_ENTER_GC_SAFE;
 #ifdef HOST_WIN32
-       ret = mono_w32handle_convert_wait_ret (SignalObjectAndWait (toSignal, toWait, ms, TRUE), 1);
+       ret = mono_w32handle_convert_wait_ret (mono_win32_signal_object_and_wait (toSignal, toWait, ms, TRUE), 1);
 #else
        ret = mono_w32handle_signal_and_wait (toSignal, toWait, ms, TRUE);
 #endif
@@ -2294,7 +2297,7 @@ mono_thread_current_check_pending_interrupt (void)
 }
 
 static gboolean
-request_thread_abort (MonoInternalThread *thread, MonoObject *state)
+request_thread_abort (MonoInternalThread *thread, MonoObject *state, gboolean appdomain_unload)
 {
        LOCK_THREAD (thread);
        
@@ -2311,6 +2314,11 @@ request_thread_abort (MonoInternalThread *thread, MonoObject *state)
        }
 
        thread->state |= ThreadState_AbortRequested;
+       if (appdomain_unload)
+               thread->flags |= MONO_THREAD_FLAG_APPDOMAIN_ABORT;
+       else
+               thread->flags &= ~MONO_THREAD_FLAG_APPDOMAIN_ABORT;
+
        if (thread->abort_state_handle)
                mono_gchandle_free (thread->abort_state_handle);
        if (state) {
@@ -2335,7 +2343,7 @@ request_thread_abort (MonoInternalThread *thread, MonoObject *state)
 void
 ves_icall_System_Threading_Thread_Abort (MonoInternalThread *thread, MonoObject *state)
 {
-       if (!request_thread_abort (thread, state))
+       if (!request_thread_abort (thread, state, FALSE))
                return;
 
        if (thread == mono_thread_internal_current ()) {
@@ -2353,11 +2361,11 @@ ves_icall_System_Threading_Thread_Abort (MonoInternalThread *thread, MonoObject
  * \p thread MUST NOT be the current thread.
  */
 void
-mono_thread_internal_abort (MonoInternalThread *thread)
+mono_thread_internal_abort (MonoInternalThread *thread, gboolean appdomain_unload)
 {
        g_assert (thread != mono_thread_internal_current ());
 
-       if (!request_thread_abort (thread, NULL))
+       if (!request_thread_abort (thread, NULL, appdomain_unload))
                return;
        async_abort_internal (thread, TRUE);
 }
@@ -2366,17 +2374,23 @@ void
 ves_icall_System_Threading_Thread_ResetAbort (MonoThread *this_obj)
 {
        MonoInternalThread *thread = mono_thread_internal_current ();
-       gboolean was_aborting;
+       gboolean was_aborting, is_domain_abort;
 
        LOCK_THREAD (thread);
        was_aborting = thread->state & ThreadState_AbortRequested;
-       thread->state &= ~ThreadState_AbortRequested;
+       is_domain_abort = thread->flags & MONO_THREAD_FLAG_APPDOMAIN_ABORT; 
+
+       if (was_aborting && !is_domain_abort)
+               thread->state &= ~ThreadState_AbortRequested;
        UNLOCK_THREAD (thread);
 
        if (!was_aborting) {
                const char *msg = "Unable to reset abort because no abort was requested";
                mono_set_pending_exception (mono_get_exception_thread_state (msg));
                return;
+       } else if (is_domain_abort) {
+               /* Silently ignore abort resets in unloading appdomains */
+               return;
        }
 
        mono_get_eh_callbacks ()->mono_clear_abort_threshold ();
@@ -2576,7 +2590,7 @@ mono_thread_stop (MonoThread *thread)
 {
        MonoInternalThread *internal = thread->internal_thread;
 
-       if (!request_thread_abort (internal, NULL))
+       if (!request_thread_abort (internal, NULL, FALSE))
                return;
 
        if (internal == mono_thread_internal_current ()) {
@@ -2999,7 +3013,7 @@ thread_detach (MonoThreadInfo *info)
 static void
 thread_detach_with_lock (MonoThreadInfo *info)
 {
-       return mono_gc_thread_detach_with_lock (info);
+       mono_gc_thread_detach_with_lock (info);
 }
 
 static gboolean
@@ -3224,7 +3238,7 @@ remove_and_abort_threads (gpointer key, gpointer value, gpointer user)
                wait->num++;
 
                THREAD_DEBUG (g_print ("%s: Aborting id: %"G_GSIZE_FORMAT"\n", __func__, (gsize)thread->tid));
-               mono_thread_internal_abort (thread);
+               mono_thread_internal_abort (thread, FALSE);
        }
 
        return TRUE;
@@ -3939,7 +3953,7 @@ mono_threads_abort_appdomain_threads (MonoDomain *domain, int timeout)
                if (user_data.wait.num > 0) {
                        /* Abort the threads outside the threads lock */
                        for (i = 0; i < user_data.wait.num; ++i)
-                               mono_thread_internal_abort (user_data.wait.threads [i]);
+                               mono_thread_internal_abort (user_data.wait.threads [i], TRUE);
 
                        /*
                         * We should wait for the threads either to abort, or to leave the
@@ -4449,8 +4463,9 @@ mono_thread_execute_interruption (void)
 
        /* this will consume pending APC calls */
 #ifdef HOST_WIN32
-       WaitForSingleObjectEx (GetCurrentThread(), 0, TRUE);
+       mono_win32_wait_for_single_object_ex (GetCurrentThread (), 0, TRUE);
 #endif
+
        /* Clear the interrupted flag of the thread so it can wait again */
        mono_thread_info_clear_self_interrupt ();
 
@@ -4518,9 +4533,8 @@ mono_thread_request_interruption (gboolean running_managed)
 
                /* this will awake the thread if it is in WaitForSingleObject 
                   or similar */
-               /* Our implementation of this function ignores the func argument */
 #ifdef HOST_WIN32
-               QueueUserAPC ((PAPCFUNC)dummy_apc, thread->native_handle, (ULONG_PTR)NULL);
+               mono_win32_interrupt_wait (thread->thread_info, thread->native_handle, (DWORD)thread->tid);
 #else
                mono_thread_info_self_interrupt ();
 #endif
@@ -4996,6 +5010,78 @@ mono_thread_is_foreign (MonoThread *thread)
        return info->runtime_thread == FALSE;
 }
 
+#ifndef HOST_WIN32
+static void
+threads_native_thread_join_lock (gpointer tid, gpointer value)
+{
+       pthread_t thread = (pthread_t)tid;
+       if (thread != pthread_self ()) {
+               MONO_ENTER_GC_SAFE;
+               /* This shouldn't block */
+               mono_threads_join_lock ();
+               mono_native_thread_join (thread);
+               mono_threads_join_unlock ();
+               MONO_EXIT_GC_SAFE;
+       }
+}
+static void
+threads_native_thread_join_nolock (gpointer tid, gpointer value)
+{
+       pthread_t thread = (pthread_t)tid;
+       MONO_ENTER_GC_SAFE;
+       mono_native_thread_join (thread);
+       MONO_EXIT_GC_SAFE;
+}
+
+static void
+threads_add_joinable_thread_nolock (gpointer tid)
+{
+       g_hash_table_insert (joinable_threads, tid, tid);
+}
+#else
+static void
+threads_native_thread_join_lock (gpointer tid, gpointer value)
+{
+       MonoNativeThreadId thread_id = (MonoNativeThreadId)(guint64)tid;
+       HANDLE thread_handle = (HANDLE)value;
+       if (thread_id != GetCurrentThreadId () && thread_handle != NULL && thread_handle != INVALID_HANDLE_VALUE) {
+               MONO_ENTER_GC_SAFE;
+               /* This shouldn't block */
+               mono_threads_join_lock ();
+               mono_native_thread_join_handle (thread_handle, TRUE);
+               mono_threads_join_unlock ();
+               MONO_EXIT_GC_SAFE;
+       }
+}
+
+static void
+threads_native_thread_join_nolock (gpointer tid, gpointer value)
+{
+       HANDLE thread_handle = (HANDLE)value;
+       MONO_ENTER_GC_SAFE;
+       mono_native_thread_join_handle (thread_handle, TRUE);
+       MONO_EXIT_GC_SAFE;
+}
+
+static void
+threads_add_joinable_thread_nolock (gpointer tid)
+{
+       g_hash_table_insert (joinable_threads, tid, (gpointer)OpenThread (SYNCHRONIZE, TRUE, (MonoNativeThreadId)(guint64)tid));
+}
+#endif
+
+void
+mono_threads_add_joinable_runtime_thread (gpointer thread_info)
+{
+       g_assert (thread_info);
+       MonoThreadInfo *mono_thread_info = (MonoThreadInfo*)thread_info;
+
+       if (mono_thread_info->runtime_thread) {
+               if (InterlockedCompareExchange (&mono_thread_info->thread_pending_native_join, TRUE, FALSE) == FALSE)
+                       mono_threads_add_joinable_thread ((gpointer)(MONO_UINT_TO_NATIVE_THREAD_ID (mono_thread_info_get_tid (mono_thread_info))));
+       }
+}
+
 /*
  * mono_add_joinable_thread:
  *
@@ -5005,21 +5091,24 @@ mono_thread_is_foreign (MonoThread *thread)
 void
 mono_threads_add_joinable_thread (gpointer tid)
 {
-#ifndef HOST_WIN32
        /*
         * We cannot detach from threads because it causes problems like
         * 2fd16f60/r114307. So we collect them and join them when
-        * we have time (in he finalizer thread).
+        * we have time (in the finalizer thread).
         */
        joinable_threads_lock ();
        if (!joinable_threads)
                joinable_threads = g_hash_table_new (NULL, NULL);
-       g_hash_table_insert (joinable_threads, tid, tid);
-       UnlockedIncrement (&joinable_thread_count);
+
+       gpointer orig_key;
+       gpointer value;
+       if (!g_hash_table_lookup_extended (joinable_threads, tid, &orig_key, &value)) {
+               threads_add_joinable_thread_nolock (tid);
+               UnlockedIncrement (&joinable_thread_count);
+       }
        joinable_threads_unlock ();
 
        mono_gc_finalize_notify ();
-#endif
 }
 
 /*
@@ -5031,11 +5120,9 @@ mono_threads_add_joinable_thread (gpointer tid)
 void
 mono_threads_join_threads (void)
 {
-#ifndef HOST_WIN32
        GHashTableIter iter;
        gpointer key;
-       gpointer tid;
-       pthread_t thread;
+       gpointer value;
        gboolean found;
 
        /* Fastpath */
@@ -5047,27 +5134,17 @@ mono_threads_join_threads (void)
                found = FALSE;
                if (g_hash_table_size (joinable_threads)) {
                        g_hash_table_iter_init (&iter, joinable_threads);
-                       g_hash_table_iter_next (&iter, &key, (void**)&tid);
-                       thread = (pthread_t)tid;
+                       g_hash_table_iter_next (&iter, &key, (void**)&value);
                        g_hash_table_remove (joinable_threads, key);
                        UnlockedDecrement (&joinable_thread_count);
                        found = TRUE;
                }
                joinable_threads_unlock ();
-               if (found) {
-                       if (thread != pthread_self ()) {
-                               MONO_ENTER_GC_SAFE;
-                               /* This shouldn't block */
-                               mono_threads_join_lock ();
-                               mono_native_thread_join (thread);
-                               mono_threads_join_unlock ();
-                               MONO_EXIT_GC_SAFE;
-                       }
-               } else {
+               if (found)
+                       threads_native_thread_join_lock (key, value);
+               else
                        break;
-               }
        }
-#endif
 }
 
 /*
@@ -5079,26 +5156,25 @@ mono_threads_join_threads (void)
 void
 mono_thread_join (gpointer tid)
 {
-#ifndef HOST_WIN32
-       pthread_t thread;
        gboolean found = FALSE;
+       gpointer orig_key;
+       gpointer value;
 
        joinable_threads_lock ();
        if (!joinable_threads)
                joinable_threads = g_hash_table_new (NULL, NULL);
-       if (g_hash_table_lookup (joinable_threads, tid)) {
+
+       if (g_hash_table_lookup_extended (joinable_threads, tid, &orig_key, &value)) {
                g_hash_table_remove (joinable_threads, tid);
                UnlockedDecrement (&joinable_thread_count);
                found = TRUE;
        }
        joinable_threads_unlock ();
+
        if (!found)
                return;
-       thread = (pthread_t)tid;
-       MONO_ENTER_GC_SAFE;
-       mono_native_thread_join (thread);
-       MONO_EXIT_GC_SAFE;
-#endif
+
+       threads_native_thread_join_nolock (tid, value);
 }
 
 void
index fa38edffc031b768aa6ef39b683e33ace1408eae..e509ed680c13c646aedb4b49a84abf321204d2f3 100644 (file)
@@ -190,6 +190,7 @@ typedef struct {
 
        int num_locals;
        MonoType **locals;
+       char *locals_verification_state;
 
        /*TODO get rid of target here, need_merge in mono_method_verify and hoist the merging code in the branching code*/
        int target;
@@ -283,6 +284,9 @@ enum {
 
        /*This is an unitialized this ref*/
        UNINIT_THIS_MASK = 0x2000,
+
+       /* This is a safe to return byref */
+       SAFE_BYREF_MASK = 0x4000,
 };
 
 static const char* const
@@ -1109,12 +1113,38 @@ stack_slot_is_boxed_value (ILStackDesc *value)
        return (value->stype & BOXED_MASK) == BOXED_MASK;
 }
 
+/* stack_slot_is_safe_byref:
+ *
+ * Returns TRUE is @value is a safe byref
+ */
+static gboolean
+stack_slot_is_safe_byref (ILStackDesc *value)
+{
+       return (value->stype & SAFE_BYREF_MASK) == SAFE_BYREF_MASK;
+}
+
 static const char *
 stack_slot_get_name (ILStackDesc *value)
 {
        return type_names [value->stype & TYPE_MASK];
 }
 
+enum {
+       SAFE_BYREF_LOCAL = 1,
+       UNSAFE_BYREF_LOCAL = 2
+};
+static gboolean
+local_is_safe_byref (VerifyContext *ctx, unsigned int arg)
+{
+       return ctx->locals_verification_state [arg] == SAFE_BYREF_LOCAL;
+}
+
+static gboolean
+local_is_unsafe_byref (VerifyContext *ctx, unsigned int arg)
+{
+       return ctx->locals_verification_state [arg] == UNSAFE_BYREF_LOCAL;
+}
+
 #define APPEND_WITH_PREDICATE(PRED,NAME) do {\
        if (PRED (value)) { \
                if (!first) \
@@ -1137,6 +1167,7 @@ stack_slot_stack_type_full_name (ILStackDesc *value)
                APPEND_WITH_PREDICATE (stack_slot_is_null_literal, "null");
                APPEND_WITH_PREDICATE (stack_slot_is_managed_mutability_pointer, "cmmp");
                APPEND_WITH_PREDICATE (stack_slot_is_managed_pointer, "mp");
+               APPEND_WITH_PREDICATE (stack_slot_is_safe_byref, "safe-byref");
                has_pred = TRUE;
        }
 
@@ -1805,6 +1836,9 @@ dump_stack_value (ILStackDesc *value)
        if (stack_slot_is_managed_pointer (value))
                printf ("Managed Pointer to: ");
 
+       if (stack_slot_is_safe_byref (value))
+               printf ("Safe ByRef to: ");
+
        switch (stack_slot_get_underlying_type (value)) {
                case TYPE_INV:
                        printf ("invalid type]"); 
@@ -2788,6 +2822,18 @@ verify_delegate_compatibility (VerifyContext *ctx, MonoClass *delegate, ILStackD
 #undef IS_LOAD_FUN_PTR
 }
 
+static gboolean
+is_this_arg_of_struct_instance_method (unsigned int arg, VerifyContext *ctx)
+{
+       if (arg != 0)
+               return FALSE;
+       if (ctx->method->flags & METHOD_ATTRIBUTE_STATIC)
+               return FALSE;
+       if (!ctx->method->klass->valuetype)
+               return FALSE;
+       return TRUE;
+}
+
 /* implement the opcode checks*/
 static void
 push_arg (VerifyContext *ctx, unsigned int arg, int take_addr) 
@@ -2819,6 +2865,8 @@ push_arg (VerifyContext *ctx, unsigned int arg, int take_addr)
                        if (mono_method_is_constructor (ctx->method) && !ctx->super_ctor_called && !ctx->method->klass->valuetype)
                                top->stype |= UNINIT_THIS_MASK;
                }
+               if (!take_addr && ctx->params [arg]->byref && !is_this_arg_of_struct_instance_method (arg, ctx))
+                       top->stype |= SAFE_BYREF_MASK;
        } 
 }
 
@@ -2833,8 +2881,11 @@ push_local (VerifyContext *ctx, guint32 arg, int take_addr)
                if (ctx->locals [arg]->byref && take_addr)
                        CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("ByRef of ByRef at 0x%04x", ctx->ip_offset));
 
-               set_stack_value (ctx, stack_push (ctx), ctx->locals [arg], take_addr);
-       } 
+               ILStackDesc *value = stack_push (ctx);
+               set_stack_value (ctx, value, ctx->locals [arg], take_addr);
+               if (local_is_safe_byref (ctx, arg))
+                       value->stype |= SAFE_BYREF_MASK;
+       }
 }
 
 static void
@@ -2873,9 +2924,20 @@ store_local (VerifyContext *ctx, guint32 arg)
                return;
 
        value = stack_pop (ctx);
-       if (ctx->locals [arg]->byref && stack_slot_is_managed_mutability_pointer (value))
-               CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Cannot use a readonly managed reference when storing on a local variable at 0x%04x", ctx->ip_offset));
-                       
+       if (ctx->locals [arg]->byref) {
+               if (stack_slot_is_managed_mutability_pointer (value))
+                       CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Cannot use a readonly managed reference when storing on a local variable at 0x%04x", ctx->ip_offset));
+
+               if (local_is_safe_byref (ctx, arg) && !stack_slot_is_safe_byref (value))
+                       CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Cannot store an unsafe ret byref to a local that was previously stored a save ret byref value at 0x%04x", ctx->ip_offset));
+
+               if (stack_slot_is_safe_byref (value) && !local_is_unsafe_byref (ctx, arg))
+                       ctx->locals_verification_state [arg] |= SAFE_BYREF_LOCAL;
+
+               if (!stack_slot_is_safe_byref (value))
+                       ctx->locals_verification_state [arg] |= UNSAFE_BYREF_LOCAL;
+
+       }
        if (!verify_stack_type_compatibility (ctx, ctx->locals [arg], value)) {
                char *expected = mono_type_full_name (ctx->locals [arg]);
                char *found = stack_slot_full_name (value);
@@ -3127,7 +3189,10 @@ do_ret (VerifyContext *ctx)
                        return;
                }
 
-               if (ret->byref || ret->type == MONO_TYPE_TYPEDBYREF || mono_type_is_value_type (ret, "System", "ArgIterator") || mono_type_is_value_type (ret, "System", "RuntimeArgumentHandle"))
+               if (ret->byref && !stack_slot_is_safe_byref (top))
+                       CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Method returns byref and return value is not a safe-to-return-byref at 0x%04x", ctx->ip_offset));
+
+               if (ret->type == MONO_TYPE_TYPEDBYREF || mono_type_is_value_type (ret, "System", "ArgIterator") || mono_type_is_value_type (ret, "System", "RuntimeArgumentHandle"))
                        CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Method returns byref, TypedReference, ArgIterator or RuntimeArgumentHandle at 0x%04x", ctx->ip_offset));
        }
 
@@ -3193,6 +3258,8 @@ do_invoke_method (VerifyContext *ctx, int method_token, gboolean virtual_)
        if (!check_underflow (ctx, param_count))
                return;
 
+       gboolean is_safe_byref_call = TRUE;
+
        for (i = sig->param_count - 1; i >= 0; --i) {
                VERIFIER_DEBUG ( printf ("verifying argument %d\n", i); );
                value = stack_pop (ctx);
@@ -3211,6 +3278,8 @@ do_invoke_method (VerifyContext *ctx, int method_token, gboolean virtual_)
                        ADD_VERIFY_ERROR (ctx, g_strdup_printf ("Cannot  pass a byref argument to a tail %s at 0x%04x", virtual_ ? "callvirt" : "call",  ctx->ip_offset));
                        return;
                }
+               if (stack_slot_is_managed_pointer (value) && !stack_slot_is_safe_byref (value))
+                       is_safe_byref_call = FALSE;
        }
 
        if (sig->hasthis) {
@@ -3296,6 +3365,8 @@ do_invoke_method (VerifyContext *ctx, int method_token, gboolean virtual_)
                                ctx->prefix_set &= ~PREFIX_READONLY;
                                value->stype |= CMMP_MASK;
                        }
+                       if (sig->ret->byref && is_safe_byref_call)
+                               value->stype |= SAFE_BYREF_MASK;
                }
        }
 
@@ -3333,7 +3404,10 @@ do_push_static_field (VerifyContext *ctx, int token, gboolean take_addr)
        if (!IS_SKIP_VISIBILITY (ctx) && !mono_method_can_access_field_full (ctx->method, field, NULL))
                CODE_NOT_VERIFIABLE2 (ctx, g_strdup_printf ("Type at stack is not accessible at 0x%04x", ctx->ip_offset), MONO_EXCEPTION_FIELD_ACCESS);
 
-       set_stack_value (ctx, stack_push (ctx), field->type, take_addr);
+       ILStackDesc *value = stack_push (ctx);
+       set_stack_value (ctx, value, field->type, take_addr);
+       if (take_addr)
+               value->stype |= SAFE_BYREF_MASK;
 }
 
 static void
@@ -3432,6 +3506,7 @@ do_push_field (VerifyContext *ctx, int token, gboolean take_addr)
 {
        ILStackDesc *obj;
        MonoClassField *field;
+       gboolean is_safe_byref = FALSE;
 
        if (!take_addr)
                CLEAR_PREFIX (ctx, PREFIX_UNALIGNED | PREFIX_VOLATILE);
@@ -3450,7 +3525,14 @@ do_push_field (VerifyContext *ctx, int token, gboolean take_addr)
                !(field->parent == ctx->method->klass && mono_method_is_constructor (ctx->method)))
                CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Cannot take the address of a init-only field at 0x%04x", ctx->ip_offset));
 
-       set_stack_value (ctx, stack_push (ctx), field->type, take_addr);
+       //must do it here cuz stack_push will return the same slot as obj above
+       is_safe_byref = take_addr && (stack_slot_is_reference_value (obj) || stack_slot_is_safe_byref (obj));
+
+       ILStackDesc *value = stack_push (ctx);
+       set_stack_value (ctx, value, field->type, take_addr);
+
+       if (is_safe_byref)
+               value->stype |= SAFE_BYREF_MASK;
 }
 
 static void
@@ -4116,6 +4198,8 @@ do_ldelema (VerifyContext *ctx, int klass_token)
                ctx->prefix_set &= ~PREFIX_READONLY;
                res->stype |= CMMP_MASK;
        }
+
+       res->stype |= SAFE_BYREF_MASK;
 }
 
 /*
@@ -4590,6 +4674,12 @@ merge_stacks (VerifyContext *ctx, ILCodeDesc *from, ILCodeDesc *to, gboolean sta
                MonoClass *new_class = mono_class_from_mono_type (new_type);
                MonoClass *match_class = NULL;
 
+               // check for safe byref before the next steps override new_slot
+               if (stack_slot_is_safe_byref (old_slot) ^ stack_slot_is_safe_byref (new_slot)) {
+                       CODE_NOT_VERIFIABLE (ctx, g_strdup_printf ("Cannot merge stack at depth %d byref types are safe byref incompatible at %0x04x ", i, ctx->ip_offset));
+                       goto end_verify;
+               }
+
                // S := T then U = S (new value is compatible with current value, keep current)
                if (verify_stack_type_compatibility (ctx, old_type, new_slot)) {
                        copy_stack_value (new_slot, old_slot);
@@ -4891,6 +4981,7 @@ mono_method_verify (MonoMethod *method, int level)
        ctx.num_locals = ctx.header->num_locals;
        ctx.locals = (MonoType **)g_memdup (ctx.header->locals, sizeof (MonoType*) * ctx.header->num_locals);
        _MEM_ALLOC (sizeof (MonoType*) * ctx.header->num_locals);
+       ctx.locals_verification_state = g_new0 (char, ctx.num_locals);
 
        if (ctx.num_locals > 0 && !ctx.header->init_locals)
                CODE_NOT_VERIFIABLE (&ctx, g_strdup_printf ("Method with locals variable but without init locals set"));
@@ -6008,6 +6099,7 @@ cleanup:
        if (ctx.code)
                g_free (ctx.code);
        g_free (ctx.locals);
+       g_free (ctx.locals_verification_state);
        g_free (ctx.params);
        mono_basic_block_free (original_bb);
        mono_metadata_free_mh (ctx.header);
index d25681126a4be13107c66a64fc52b24bb9dadcca..67fde9c8c1dcb764b6a36ee73c4a5a967c55ed73 100644 (file)
@@ -69,6 +69,9 @@ mono_w32error_unix_to_win32 (guint32 error)
 #ifdef ENODEV
        case ENODEV: return ERROR_DEV_NOT_EXIST;
 #endif
+#ifdef ENXIO
+       case ENXIO: return ERROR_DEV_NOT_EXIST;
+#endif
 
        default:
                g_error ("%s: unknown error (%d) \"%s\"", __FILE__, error, g_strerror (error));
index 98d4ace6d62593b62e3b0e1be6ace694f8333ff6..654b215538d800de195db57afeca5ccaaa9176e9 100644 (file)
@@ -1218,8 +1218,13 @@ mono_w32handle_wait_multiple (gpointer *handles, gsize nhandles, gboolean waital
                signalled = (waitall && count == nhandles) || (!waitall && count > 0);
 
                if (signalled) {
-                       for (i = 0; i < nhandles; i++)
-                               own_if_signalled (handles [i], &abandoned [i]);
+                       for (i = 0; i < nhandles; i++) {
+                               if (own_if_signalled (handles [i], &abandoned [i]) && !waitall) {
+                                       /* if we are calling WaitHandle.WaitAny, .NET only owns the first one; it matters for Mutex which
+                                        * throw AbandonedMutexException in case we owned it but didn't release it */
+                                       break;
+                               }
+                       }
                }
 
                mono_w32handle_unlock_handles (handles, nhandles);
index 8a55844b6e08884068d95bb62ce3a0037eed9578..f71dc34bdb758365d5b4d928476d27255c164a97 100644 (file)
@@ -2580,8 +2580,8 @@ ves_icall_Microsoft_Win32_NativeMethods_GetProcessTimes (gpointer handle, gint64
                        &start_ticks, &user_ticks, &kernel_ticks);
 
                ticks_to_processtime (start_ticks, creation_processtime);
-               ticks_to_processtime (user_ticks, kernel_processtime);
-               ticks_to_processtime (kernel_ticks, user_processtime);
+               ticks_to_processtime (kernel_ticks, kernel_processtime);
+               ticks_to_processtime (user_ticks, user_processtime);
                return TRUE;
        }
 
index 4f7cc8cdcf555f28ffbf37a6a7c6807192bdeaf6..076500687baeea45d32e1f247532c8a83b43e684 100644 (file)
@@ -23,6 +23,7 @@
 #include "w32socket-internals.h"
 
 #include "utils/w32api.h"
+#include "utils/mono-os-wait.h"
 
 #define LOGDEBUG(...)  
 
@@ -76,10 +77,10 @@ static gboolean alertable_socket_wait (SOCKET sock, int event_bit)
        WSAEVENT event = WSACreateEvent ();
        if (event != WSA_INVALID_EVENT) {
                if (WSAEventSelect (sock, event, (1 << event_bit) | FD_CLOSE) != SOCKET_ERROR) {
-                       LOGDEBUG (g_message ("%06d - Calling WSAWaitForMultipleEvents () on socket %d", GetCurrentThreadId (), sock));
-                       DWORD ret = WSAWaitForMultipleEvents (1, &event, TRUE, timeout, TRUE);
+                       LOGDEBUG (g_message ("%06d - Calling mono_win32_wsa_wait_for_multiple_events () on socket %d", GetCurrentThreadId (), sock));
+                       DWORD ret = mono_win32_wsa_wait_for_multiple_events (1, &event, TRUE, timeout, TRUE);
                        if (ret == WSA_WAIT_IO_COMPLETION) {
-                               LOGDEBUG (g_message ("%06d - WSAWaitForMultipleEvents () returned WSA_WAIT_IO_COMPLETION for socket %d", GetCurrentThreadId (), sock));
+                               LOGDEBUG (g_message ("%06d - mono_win32_wsa_wait_for_multiple_events () returned WSA_WAIT_IO_COMPLETION for socket %d", GetCurrentThreadId (), sock));
                                error = WSAEINTR;
                        } else if (ret == WSA_WAIT_TIMEOUT) {
                                error = WSAETIMEDOUT;
@@ -229,9 +230,9 @@ BOOL mono_w32socket_transmit_file (SOCKET hSocket, gpointer hFile, TRANSMIT_FILE
                        if (error == WSA_IO_PENDING) {
                                error = 0;
                                // NOTE: .NET's Socket.SendFile() doesn't honor the Socket's SendTimeout so we shouldn't either
-                               DWORD ret = WaitForSingleObjectEx (overlapped.hEvent, INFINITE, TRUE);
+                               DWORD ret = mono_win32_wait_for_single_object_ex (overlapped.hEvent, INFINITE, TRUE);
                                if (ret == WAIT_IO_COMPLETION) {
-                                       LOGDEBUG (g_message ("%06d - WaitForSingleObjectEx () returned WSA_WAIT_IO_COMPLETION for socket %d", GetCurrentThreadId (), hSocket));
+                                       LOGDEBUG (g_message ("%06d - mono_win32_wait_for_single_object_ex () returned WSA_WAIT_IO_COMPLETION for socket %d", GetCurrentThreadId (), hSocket));
                                        error = WSAEINTR;
                                } else if (ret == WAIT_TIMEOUT) {
                                        error = WSAETIMEDOUT;
index 43df41bfdc717181022977d5bbc39853e43bdb87..bf789f1d00da93972c6b897f42d51c2f75a73071 100644 (file)
@@ -208,7 +208,7 @@ mono_w32socket_close (SOCKET sock)
 {
        gboolean ret;
        MONO_ENTER_GC_SAFE;
-       ret = CloseHandle (sock);
+       ret = closesocket (sock);
        MONO_EXIT_GC_SAFE;
        return ret;
 }
index 5d5aa4adc53b472f35e448cf21e01bacc80e1829..b03ac936738b3a38ed3d8a0d430e1c160baa1ffd 100644 (file)
 
 #include <mono/metadata/object-internals.h>
 
+#ifndef HOST_WIN32
 #define INVALID_SOCKET ((SOCKET)(guint32)(~0))
 #define SOCKET_ERROR (-1)
 
-#ifndef HOST_WIN32
 typedef gint SOCKET;
 
 typedef struct {
index 125110303adc583d0bf57c0457bfd357e021114b..6b91543a56b6bbfd9e7f6a4c32f6bdb29911f289 100644 (file)
@@ -2897,7 +2897,7 @@ encode_klass_ref_inner (MonoAotCompile *acfg, MonoClass *klass, guint8 *buf, gui
                if (par->gshared_constraint) {
                        MonoGSharedGenericParam *gpar = (MonoGSharedGenericParam*)par;
                        encode_type (acfg, par->gshared_constraint, p, &p);
-                       encode_klass_ref (acfg, mono_class_from_generic_parameter (gpar->parent, NULL, klass->byval_arg.type == MONO_TYPE_MVAR), p, &p);
+                       encode_klass_ref (acfg, mono_class_from_generic_parameter_internal (gpar->parent), p, &p);
                } else {
                        encode_value (klass->byval_arg.type, p, &p);
                        encode_value (mono_type_get_generic_param_num (&klass->byval_arg), p, &p);
index 230a975dbe348bc43711c24276613744530c5e0f..8b1cf4118cc32f1f5a222e71fa92832c1523fec7 100644 (file)
@@ -360,7 +360,7 @@ long_conv_to_ovf_i4_2: dest:i src1:i src2:i len:36
 vcall2: len:40 clob:c
 vcall2_reg: src1:i len:40 clob:c
 vcall2_membase: src1:b len:40 clob:c
-dyn_call: src1:i src2:i len:192 clob:c
+dyn_call: src1:i src2:i len:216 clob:c
 
 # This is different from the original JIT opcodes
 float_beq: len:32
index 65cdc9b149dd3c28f06edd9b80af305577919846..0baa0fe3c993261b2366ed0c5b15e6c864c556de 100644 (file)
@@ -198,6 +198,9 @@ float_cgt_un: dest:i src1:f src2:f len:20
 float_clt: dest:i src1:f src2:f len:16
 float_clt_un: dest:i src1:f src2:f len:20
 float_conv_to_u: dest:i src1:f len:36
+float_cneq: dest:i src1:f src2:f len:16
+float_cge: dest:i src1:f src2:f len:16
+float_cle: dest:i src1:f src2:f len:16
 call_handler: len:12 clob:c
 endfilter: src1:i len:32
 aot_const: dest:i len:8
@@ -289,6 +292,12 @@ int_cgt_un: dest:i len:12
 int_clt: dest:i len:12
 int_clt_un: dest:i len:12
 
+int_cneq: dest:i len:12
+int_cge: dest:i len:12
+int_cle: dest:i len:12
+int_cge_un: dest:i len:12
+int_cle_un: dest:i len:12
+
 cond_exc_ieq: len:8
 cond_exc_ine_un: len:8
 cond_exc_ilt: len:8
index 31119afdafc47395de492839c77c5a16efd0ab9e..2c28e7dca7cd78c0d539da4e1b08306beee76472 100644 (file)
@@ -201,6 +201,9 @@ float_cgt_un: dest:i src1:f src2:f len:20
 float_clt: dest:i src1:f src2:f len:16
 float_clt_un: dest:i src1:f src2:f len:20
 float_conv_to_u: dest:i src1:f len:36
+float_cneq: dest:i src1:f src2:f len:16
+float_cge: dest:i src1:f src2:f len:16
+float_cle: dest:i src1:f src2:f len:16
 call_handler: len:12 clob:c
 endfilter: src1:i len:20
 aot_const: dest:i len:8
@@ -293,6 +296,12 @@ int_cgt_un: dest:i len:12
 int_clt: dest:i len:12
 int_clt_un: dest:i len:12
 
+int_cneq: dest:i len:12
+int_cge: dest:i len:12
+int_cle: dest:i len:12
+int_cge_un: dest:i len:12
+int_cle_un: dest:i len:12
+
 cond_exc_ieq: len:8
 cond_exc_ine_un: len:8
 cond_exc_ilt: len:8
index cb0600828e9c4116eccd38a44843358bd263666c..29f94ba1e06e0b4870e9d4bda438e4ab39a9718d 100644 (file)
@@ -7691,7 +7691,7 @@ vm_commands (int command, int id, guint8 *p, guint8 *end, Buffer *buf)
 
                tls->abort_requested = TRUE;
 
-               mono_thread_internal_abort (THREAD_TO_INTERNAL (thread));
+               mono_thread_internal_abort (THREAD_TO_INTERNAL (thread), FALSE);
                mono_loader_unlock ();
                break;
        }
index 6b5bc95f134ca449ac6306ed403d3ee321c920ef..75ea14aad6a91463ecc7f3ba0eb2769e97f7be1d 100644 (file)
@@ -1823,6 +1823,19 @@ public class Tests
                }
        }
 
+       struct StructTest : IFaceTest {
+
+               int i;
+
+               public StructTest (int arg) {
+                       i = arg;
+               }
+
+               public int iface_method () {
+                       return i;
+               }
+       }
+
        // Test constrained calls on an interface made from gsharedvt methods
        public static int test_42_gsharedvt_constrained_iface () {
                IFaceConstrainedIFace obj = new ConstrainedIFace ();
@@ -1830,6 +1843,12 @@ public class Tests
                return obj.foo<IFaceTest, int> (ref t);
        }
 
+       public static int test_42_gsharedvt_constrained_iface_vtype () {
+               IFaceConstrainedIFace obj = new ConstrainedIFace ();
+               IFaceTest t = new StructTest (42);
+               return obj.foo<IFaceTest, int> (ref t);
+       }
+
        // Sign extension tests
        // 0x55   == 85    == 01010101
        // 0xAA   == 170   == 10101010
index b2d92af2cc6213805c3944fc37174168b125aa99..b5796520341be55f2ba19929cf8b695cde1a2395 100644 (file)
@@ -3023,4 +3023,25 @@ L_3:
                ldc.i4.0
                ret
     }
+
+       .method public static bool llvm_regress_59436 () {
+               // Code size       41 (0x29)
+               .maxstack  3
+               .locals init (float64 V_0,
+                                         float64 V_1,
+                                         valuetype [mscorlib]System.Decimal V_2)
+               IL_0000:  ldc.r8         1
+               IL_0009:  stloc.0
+               IL_000a:  ldc.r8         2
+               IL_0013:  stloc.1
+               IL_0014:  ldloc.0
+               IL_0015:  newobj         instance void [mscorlib]System.Decimal::.ctor(float64)
+               IL_001a:  ldloca.s   V_2
+               IL_001c:  ldloc.1
+               IL_001d:  call     instance void [mscorlib]System.Decimal::.ctor(float64)
+               IL_0022:  ldloc.2
+               IL_0023:  call     bool [mscorlib]System.Decimal::op_LessThanOrEqual(valuetype [mscorlib]System.Decimal,
+                                                                                                                                                          valuetype [mscorlib]System.Decimal)
+               IL_0028:  ret
+       }
 }
index 56c7bc8169f76b54e7f1f01caa0e23471a01a259..fa3d7a4681971e74fafa19d297ab476de42c470d 100644 (file)
@@ -1328,12 +1328,15 @@ constrained_gsharedvt_call_setup (gpointer mp, MonoMethod *cmethod, MonoClass *k
 {
        MonoMethod *m;
        int vt_slot, iface_offset;
+       gboolean is_iface = FALSE;
 
        error_init (error);
 
        if (mono_class_is_interface (klass)) {
                MonoObject *this_obj;
 
+               is_iface = TRUE;
+
                /* Have to use the receiver's type instead of klass, the receiver is a ref type */
                this_obj = *(MonoObject**)mp;
                g_assert (this_obj);
@@ -1359,21 +1362,33 @@ constrained_gsharedvt_call_setup (gpointer mp, MonoMethod *cmethod, MonoClass *k
                        m = mono_class_inflate_generic_method (m, mono_method_get_context (cmethod));
        }
 
-       if (klass->valuetype && (m->klass == mono_defaults.object_class || m->klass == mono_defaults.enum_class->parent || m->klass == mono_defaults.enum_class))
+       if (klass->valuetype && (m->klass == mono_defaults.object_class || m->klass == mono_defaults.enum_class->parent || m->klass == mono_defaults.enum_class)) {
                /*
                 * Calling a non-vtype method with a vtype receiver, has to box.
                 */
                *this_arg = mono_value_box_checked (mono_domain_get (), klass, mp, error);
-       else if (klass->valuetype)
-               /*
-                * Calling a vtype method with a vtype receiver
-                */
-               *this_arg = mp;
-       else
+       } else if (klass->valuetype) {
+               if (is_iface) {
+                       /*
+                        * The original type is an interface, so the receiver is a ref,
+                          the called method is a vtype method, need to unbox.
+                       */
+                       MonoObject *this_obj = *(MonoObject**)mp;
+
+                       *this_arg = mono_object_unbox (this_obj);
+               } else {
+                       /*
+                        * Calling a vtype method with a vtype receiver
+                        */
+                       *this_arg = mp;
+               }
+       } else {
                /*
                 * Calling a non-vtype method
                 */
                *this_arg = *(gpointer*)mp;
+       }
+
        return m;
 }
 
index 442ec3c0a5c9005eab5da957140d8c8851189215..3ac76cdfd8da9c4ea1327993de1364edac13c075 100644 (file)
@@ -11838,7 +11838,7 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                        cfg->dyn_call_var->flags |= MONO_INST_VOLATILE;
                                }
 
-                               /* Has to use a call inst since it local regalloc expects it */
+                               /* Has to use a call inst since local regalloc expects it */
                                MONO_INST_NEW_CALL (cfg, call, OP_DYN_CALL);
                                ins = (MonoInst*)call;
                                sp -= 2;
@@ -11847,6 +11847,8 @@ mono_method_to_ir (MonoCompile *cfg, MonoMethod *method, MonoBasicBlock *start_b
                                MONO_ADD_INS (cfg->cbb, ins);
 
                                cfg->param_area = MAX (cfg->param_area, cfg->backend->dyn_call_param_area);
+                               /* OP_DYN_CALL might need to allocate a dynamically sized param area */
+                               cfg->flags |= MONO_CFG_HAS_ALLOCA;
 
                                ip += 2;
                                inline_costs += 10 * num_calls++;
index 949f8946ddd1c73cf2a3d56a303448eff7115656..43d0e17babbd6c4d5fa6509eac2eb389aade1999 100644 (file)
@@ -2374,6 +2374,7 @@ mono_arch_emit_setret (MonoCompile *cfg, MonoMethod *method, MonoInst *val)
 typedef struct {
        MonoMethodSignature *sig;
        CallInfo *cinfo;
+       int nstack_args;
 } ArchDynCallInfo;
 
 static gboolean
@@ -2400,10 +2401,7 @@ dyn_call_supported (MonoMethodSignature *sig, CallInfo *cinfo)
                case ArgInFloatSSEReg:
                case ArgInDoubleSSEReg:
                case ArgValuetypeInReg:
-                       break;
                case ArgOnStack:
-                       if (!(ainfo->offset + (ainfo->arg_size / 8) <= DYN_CALL_STACK_ARGS))
-                               return FALSE;
                        break;
                default:
                        return FALSE;
@@ -2426,6 +2424,7 @@ mono_arch_dyn_call_prepare (MonoMethodSignature *sig)
 {
        ArchDynCallInfo *info;
        CallInfo *cinfo;
+       int i;
 
        cinfo = get_call_info (NULL, sig);
 
@@ -2438,6 +2437,21 @@ mono_arch_dyn_call_prepare (MonoMethodSignature *sig)
        // FIXME: Preprocess the info to speed up get_dyn_call_args ().
        info->sig = sig;
        info->cinfo = cinfo;
+       info->nstack_args = 0;
+
+       for (i = 0; i < cinfo->nargs; ++i) {
+               ArgInfo *ainfo = &cinfo->args [i];
+               switch (ainfo->storage) {
+               case ArgOnStack:
+                       info->nstack_args = MAX (info->nstack_args, ainfo->offset + (ainfo->arg_size / 8));
+                       break;
+               default:
+                       break;
+               }
+       }
+       /* Align to 16 bytes */
+       if (info->nstack_args & 1)
+               info->nstack_args ++;
        
        return (MonoDynCallInfo*)info;
 }
@@ -2456,6 +2470,15 @@ mono_arch_dyn_call_free (MonoDynCallInfo *info)
        g_free (ainfo);
 }
 
+int
+mono_arch_dyn_call_get_buf_size (MonoDynCallInfo *info)
+{
+       ArchDynCallInfo *ainfo = (ArchDynCallInfo*)info;
+
+       /* Extend the 'regs' field dynamically */
+       return sizeof (DynCallArgs) + (ainfo->nstack_args * sizeof (mgreg_t));
+}
+
 #define PTR_TO_GREG(ptr) (mgreg_t)(ptr)
 #define GREG_TO_PTR(greg) (gpointer)(greg)
 
@@ -2474,7 +2497,7 @@ mono_arch_dyn_call_free (MonoDynCallInfo *info)
  * libffi.
  */
 void
-mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf, int buf_len)
+mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf)
 {
        ArchDynCallInfo *dinfo = (ArchDynCallInfo*)info;
        DynCallArgs *p = (DynCallArgs*)buf;
@@ -2491,10 +2514,9 @@ mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, g
                param_reg_to_index_inited = 1;
        }
 
-       g_assert (buf_len >= sizeof (DynCallArgs));
-
        p->res = 0;
        p->ret = ret;
+       p->nstack_args = dinfo->nstack_args;
 
        arg_index = 0;
        greg = 0;
@@ -4649,9 +4671,10 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                        code = emit_move_return_value (cfg, ins, code);
                        break;
                case OP_DYN_CALL: {
-                       int i;
+                       int i, limit_reg, index_reg, src_reg, dst_reg;
                        MonoInst *var = cfg->dyn_call_var;
                        guint8 *label;
+                       guint8 *buf [16];
 
                        g_assert (var->opcode == OP_REGOFFSET);
 
@@ -4672,15 +4695,38 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                                amd64_sse_movsd_reg_membase (code, i, AMD64_R11, MONO_STRUCT_OFFSET (DynCallArgs, fregs) + (i * sizeof (double)));
                        amd64_patch (label, code);
 
+                       /* Allocate param area */
+                       /* This doesn't need to be freed since OP_DYN_CALL is never called in a loop */
+                       amd64_mov_reg_membase (code, AMD64_RAX, AMD64_R11, MONO_STRUCT_OFFSET (DynCallArgs, nstack_args), 8);
+                       amd64_shift_reg_imm (code, X86_SHL, AMD64_RAX, 3);
+                       amd64_alu_reg_reg (code, X86_SUB, AMD64_RSP, AMD64_RAX);
                        /* Set stack args */
-                       for (i = 0; i < DYN_CALL_STACK_ARGS; ++i) {
-                               amd64_mov_reg_membase (code, AMD64_RAX, AMD64_R11, MONO_STRUCT_OFFSET (DynCallArgs, regs) + ((PARAM_REGS + i) * sizeof(mgreg_t)), sizeof(mgreg_t));
-                               amd64_mov_membase_reg (code, AMD64_RSP, i * sizeof (mgreg_t), AMD64_RAX, sizeof (mgreg_t));
-                       }
+                       /* rax/rcx/rdx/r8/r9 is scratch */
+                       limit_reg = AMD64_RAX;
+                       index_reg = AMD64_RCX;
+                       src_reg = AMD64_R8;
+                       dst_reg = AMD64_R9;
+                       amd64_mov_reg_membase (code, limit_reg, AMD64_R11, MONO_STRUCT_OFFSET (DynCallArgs, nstack_args), 8);
+                       amd64_mov_reg_imm (code, index_reg, 0);
+                       amd64_lea_membase (code, src_reg, AMD64_R11, MONO_STRUCT_OFFSET (DynCallArgs, regs) + ((PARAM_REGS) * sizeof(mgreg_t)));
+                       amd64_mov_reg_reg (code, dst_reg, AMD64_RSP, 8);
+                       buf [0] = code;
+                       x86_jump8 (code, 0);
+                       buf [1] = code;
+                       amd64_mov_reg_membase (code, AMD64_RDX, src_reg, 0, 8);
+                       amd64_mov_membase_reg (code, dst_reg, 0, AMD64_RDX, 8);
+                       amd64_alu_reg_imm (code, X86_ADD, index_reg, 1);
+                       amd64_alu_reg_imm (code, X86_ADD, src_reg, 8);
+                       amd64_alu_reg_imm (code, X86_ADD, dst_reg, 8);
+                       amd64_patch (buf [0], code);
+                       amd64_alu_reg_reg (code, X86_CMP, index_reg, limit_reg);
+                       buf [2] = code;
+                       x86_branch8 (code, X86_CC_LT, 0, FALSE);
+                       amd64_patch (buf [2], buf [1]);
 
                        /* Set argument registers */
                        for (i = 0; i < PARAM_REGS; ++i)
-                               amd64_mov_reg_membase (code, param_regs [i], AMD64_R11, i * sizeof(mgreg_t), sizeof(mgreg_t));
+                               amd64_mov_reg_membase (code, param_regs [i], AMD64_R11, MONO_STRUCT_OFFSET (DynCallArgs, regs) + (i * sizeof(mgreg_t)), sizeof(mgreg_t));
                        
                        /* Make the call */
                        amd64_call_reg (code, AMD64_R10);
index f09f285a17bb26b132a9e30ff6710db8b37ad020..ba8466dfebeaa1d47b59d994c7b2995cb48e3929 100644 (file)
@@ -270,15 +270,15 @@ typedef struct {
        gpointer bp_addrs [MONO_ZERO_LEN_ARRAY];
 } SeqPointInfo;
 
-#define DYN_CALL_STACK_ARGS 6
-
 typedef struct {
-       mgreg_t regs [PARAM_REGS + DYN_CALL_STACK_ARGS];
        mgreg_t res;
        guint8 *ret;
        double fregs [8];
        mgreg_t has_fp;
+       mgreg_t nstack_args;
        guint8 buffer [256];
+       /* This should come last as the structure is dynamically extended */
+       mgreg_t regs [PARAM_REGS];
 } DynCallArgs;
 
 typedef enum {
@@ -429,7 +429,7 @@ typedef struct {
 
 #define MONO_ARCH_GSHARED_SUPPORTED 1
 #define MONO_ARCH_DYN_CALL_SUPPORTED 1
-#define MONO_ARCH_DYN_CALL_PARAM_AREA (DYN_CALL_STACK_ARGS * 8)
+#define MONO_ARCH_DYN_CALL_PARAM_AREA 0
 
 #define MONO_ARCH_LLVM_SUPPORTED 1
 #define MONO_ARCH_HAVE_CARD_TABLE_WBARRIER 1
index 1e56345f03d271d03e69ab814e3cfef87f2f2243..44626141830fe9f5ff2c42f28ae54de1c668f0ee 100644 (file)
@@ -2753,16 +2753,20 @@ mono_arch_dyn_call_free (MonoDynCallInfo *info)
        g_free (ainfo);
 }
 
+int
+mono_arch_dyn_call_get_buf_size (MonoDynCallInfo *info)
+{
+       return sizeof (DynCallArgs);
+}
+
 void
-mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf, int buf_len)
+mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf)
 {
        ArchDynCallInfo *dinfo = (ArchDynCallInfo*)info;
        DynCallArgs *p = (DynCallArgs*)buf;
        int arg_index, greg, i, j, pindex;
        MonoMethodSignature *sig = dinfo->sig;
 
-       g_assert (buf_len >= sizeof (DynCallArgs));
-
        p->res = 0;
        p->ret = ret;
        p->has_fpregs = 0;
index 9edb57aa9ef87da6594dea1b82e87867f7ee5dfe..6192f26b9cf042e653ad287c859bb881aafebca0 100644 (file)
@@ -1381,9 +1381,6 @@ dyn_call_supported (CallInfo *cinfo, MonoMethodSignature *sig)
 {
        int i;
 
-       if (sig->hasthis + sig->param_count > PARAM_REGS + DYN_CALL_STACK_ARGS)
-               return FALSE;
-
        // FIXME: Add more cases
        switch (cinfo->ret.storage) {
        case ArgNone:
@@ -1412,10 +1409,7 @@ dyn_call_supported (CallInfo *cinfo, MonoMethodSignature *sig)
                case ArgInFRegR4:
                case ArgHFA:
                case ArgVtypeByRef:
-                       break;
                case ArgOnStack:
-                       if (ainfo->offset >= DYN_CALL_STACK_ARGS * sizeof (mgreg_t))
-                               return FALSE;
                        break;
                default:
                        return FALSE;
@@ -1473,6 +1467,15 @@ mono_arch_dyn_call_free (MonoDynCallInfo *info)
        g_free (ainfo);
 }
 
+int
+mono_arch_dyn_call_get_buf_size (MonoDynCallInfo *info)
+{
+       ArchDynCallInfo *ainfo = (ArchDynCallInfo*)info;
+
+       g_assert (ainfo->cinfo->stack_usage % MONO_ARCH_FRAME_ALIGNMENT == 0);
+       return sizeof (DynCallArgs) + ainfo->cinfo->stack_usage;
+}
+
 static double
 bitcast_r4_to_r8 (float f)
 {
@@ -1490,7 +1493,7 @@ bitcast_r8_to_r4 (double f)
 }
 
 void
-mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf, int buf_len)
+mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf)
 {
        ArchDynCallInfo *dinfo = (ArchDynCallInfo*)info;
        DynCallArgs *p = (DynCallArgs*)buf;
@@ -1499,12 +1502,11 @@ mono_arch_start_dyn_call (MonoDynCallInfo *info, gpointer **args, guint8 *ret, g
        CallInfo *cinfo = dinfo->cinfo;
        int buffer_offset = 0;
 
-       g_assert (buf_len >= sizeof (DynCallArgs));
-
        p->res = 0;
        p->ret = ret;
        p->n_fpargs = dinfo->n_fpargs;
        p->n_fpret = dinfo->n_fpret;
+       p->n_stackargs = cinfo->stack_usage / sizeof (mgreg_t);
 
        arg_index = 0;
        greg = 0;
@@ -4175,14 +4177,35 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                                code = emit_ldrfpx (code, ARMREG_D0 + i, ARMREG_LR, MONO_STRUCT_OFFSET (DynCallArgs, fpregs) + (i * 8));
                        arm_patch_rel (labels [0], code, MONO_R_ARM64_BCC);
 
+                       /* Allocate callee area */
+                       code = emit_ldrx (code, ARMREG_R0, ARMREG_LR, MONO_STRUCT_OFFSET (DynCallArgs, n_stackargs));
+                       arm_lslw (code, ARMREG_R0, ARMREG_R0, 3);
+                       arm_movspx (code, ARMREG_R1, ARMREG_SP);
+                       arm_subx (code, ARMREG_R1, ARMREG_R1, ARMREG_R0);
+                       arm_movspx (code, ARMREG_SP, ARMREG_R1);
+
                        /* Set stack args */
-                       for (i = 0; i < DYN_CALL_STACK_ARGS; ++i) {
-                               code = emit_ldrx (code, ARMREG_R0, ARMREG_LR, MONO_STRUCT_OFFSET (DynCallArgs, regs) + ((PARAM_REGS + 1 + i) * sizeof (mgreg_t)));
-                               code = emit_strx (code, ARMREG_R0, ARMREG_SP, i * sizeof (mgreg_t));
-                       }
+                       /* R1 = limit */
+                       code = emit_ldrx (code, ARMREG_R1, ARMREG_LR, MONO_STRUCT_OFFSET (DynCallArgs, n_stackargs));
+                       /* R2 = pointer into 'regs' */
+                       code = emit_imm (code, ARMREG_R2, MONO_STRUCT_OFFSET (DynCallArgs, regs) + ((PARAM_REGS + 1) * sizeof (mgreg_t)));
+                       arm_addx (code, ARMREG_R2, ARMREG_LR, ARMREG_R2);
+                       /* R3 = pointer to stack */
+                       arm_movspx (code, ARMREG_R3, ARMREG_SP);
+                       labels [0] = code;
+                       arm_b (code, code);
+                       labels [1] = code;
+                       code = emit_ldrx (code, ARMREG_R5, ARMREG_R2, 0);
+                       code = emit_strx (code, ARMREG_R5, ARMREG_R3, 0);
+                       code = emit_addx_imm (code, ARMREG_R2, ARMREG_R2, sizeof (mgreg_t));
+                       code = emit_addx_imm (code, ARMREG_R3, ARMREG_R3, sizeof (mgreg_t));
+                       code = emit_subx_imm (code, ARMREG_R1, ARMREG_R1, 1);
+                       arm_patch_rel (labels [0], code, MONO_R_ARM64_B);
+                       arm_cmpw (code, ARMREG_R1, ARMREG_RZR);
+                       arm_bcc (code, ARMCOND_GT, labels [1]);
 
                        /* Set argument registers + r8 */
-                       code = mono_arm_emit_load_regarray (code, 0x1ff, ARMREG_LR, 0);
+                       code = mono_arm_emit_load_regarray (code, 0x1ff, ARMREG_LR, MONO_STRUCT_OFFSET (DynCallArgs, regs));
 
                        /* Make the call */
                        arm_blrx (code, ARMREG_IP1);
index 6268a1064de9266f034eaa7b72f1a3b34a722560..d14301ace80d56e480a728f919b7d198351d05af 100644 (file)
@@ -89,16 +89,15 @@ typedef struct {
 #define PARAM_REGS 8
 #define FP_PARAM_REGS 8
 
-#define DYN_CALL_STACK_ARGS 6
-
 typedef struct {
-       /* The +1 is for r8 */
-       mgreg_t regs [PARAM_REGS + 1 + DYN_CALL_STACK_ARGS];
        mgreg_t res, res2;
        guint8 *ret;
        double fpregs [FP_PARAM_REGS];
-       int n_fpargs, n_fpret;
+       int n_fpargs, n_fpret, n_stackargs;
        guint8 buffer [256];
+       /* This should come last as the structure is dynamically extended */
+       /* The +1 is for r8 */
+       mgreg_t regs [PARAM_REGS + 1];
 } DynCallArgs;
 
 typedef struct {
@@ -141,7 +140,7 @@ typedef struct {
 #define MONO_ARCH_HAVE_EXCEPTIONS_INIT 1
 #define MONO_ARCH_HAVE_GET_TRAMPOLINES 1
 #define MONO_ARCH_DYN_CALL_SUPPORTED 1
-#define MONO_ARCH_DYN_CALL_PARAM_AREA (DYN_CALL_STACK_ARGS * 8)
+#define MONO_ARCH_DYN_CALL_PARAM_AREA 0
 #define MONO_ARCH_SOFT_DEBUG_SUPPORTED 1
 #define MONO_ARCH_GSHAREDVT_SUPPORTED 1
 #define MONO_ARCH_HAVE_SETUP_RESUME_FROM_SIGNAL_HANDLER_CTX 1
index 0a2691f663860f40e62a4d3442200b2c9a59b77e..707951af02e15c807e7eccced069307a22af527b 100644 (file)
@@ -1415,6 +1415,11 @@ wrap_non_exception_throws (MonoMethod *m)
        int i;
        gboolean val = FALSE;
 
+       if (m->wrapper_type == MONO_WRAPPER_DYNAMIC_METHOD) {
+               MonoDynamicMethod *dm = (MonoDynamicMethod *)m;
+               if (dm->assembly)
+                       ass = dm->assembly;
+       }
        g_assert (ass);
        if (ass->wrap_non_exception_throws_inited)
                return ass->wrap_non_exception_throws;
index 8a0b622da281a5d7917e799a7f247b72fc70c0b3..0b996be7f1838ee8a684725105b03d1d60afe7b5 100644 (file)
@@ -467,6 +467,9 @@ create_llvm_type_for_type (MonoLLVMModule *module, MonoClass *klass)
 static LLVMTypeRef
 type_to_llvm_type (EmitContext *ctx, MonoType *t)
 {
+       if (t->byref)
+               return ThisType ();
+
        t = mini_get_underlying_type (t);
 
        switch (t->type) {
@@ -1226,10 +1229,10 @@ sig_to_llvm_sig_no_cinfo (EmitContext *ctx, MonoMethodSignature *sig)
        int i, pindex;
        MonoType *rtype;
 
-       rtype = mini_get_underlying_type (sig->ret);
-       ret_type = type_to_llvm_type (ctx, rtype);
+       ret_type = type_to_llvm_type (ctx, sig->ret);
        if (!ctx_ok (ctx))
                return NULL;
+       rtype = mini_get_underlying_type (sig->ret);
 
        param_types = g_new0 (LLVMTypeRef, (sig->param_count * 8) + 3);
        pindex = 0;
@@ -1269,10 +1272,10 @@ sig_to_llvm_sig_full (EmitContext *ctx, MonoMethodSignature *sig, LLVMCallInfo *
        if (!cinfo)
                return sig_to_llvm_sig_no_cinfo (ctx, sig);
 
-       rtype = mini_get_underlying_type (sig->ret);
-       ret_type = type_to_llvm_type (ctx, rtype);
+       ret_type = type_to_llvm_type (ctx, sig->ret);
        if (!ctx_ok (ctx))
                return NULL;
+       rtype = mini_get_underlying_type (sig->ret);
 
        switch (cinfo->ret.storage) {
        case LLVMArgVtypeInReg:
index 1a947639a241d3692584586ae0a099a69ecc9856..4ba20cc2257e31ff9ad4e154ca7267b2b939d124 100644 (file)
@@ -1005,8 +1005,7 @@ get_call_info (MonoMethodSignature *sig)
        fr = PPC_FIRST_FPARG_REG;
        gr = PPC_FIRST_ARG_REG;
 
-       /* FIXME: handle returning a struct */
-       if (MONO_TYPE_ISSTRUCT (sig->ret)) {
+       if (mini_type_is_vtype (sig->ret)) {
                cinfo->vtype_retaddr = TRUE;
        }
 
@@ -4126,6 +4125,11 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                        ppc_mtctr (code, ins->sreg1);
                        ppc_bcctr (code, PPC_BR_ALWAYS, 0);
                        break;
+               case OP_ICNEQ:
+                       ppc_li (code, ins->dreg, 0);
+                       ppc_bc (code, PPC_BR_TRUE, PPC_BR_EQ, 2);
+                       ppc_li (code, ins->dreg, 1);
+                       break;
                case OP_CEQ:
                case OP_ICEQ:
                CASE_PPC64 (OP_LCEQ)
@@ -4143,6 +4147,12 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                        ppc_bc (code, PPC_BR_TRUE, PPC_BR_LT, 2);
                        ppc_li (code, ins->dreg, 0);
                        break;
+               case OP_ICGE:
+               case OP_ICGE_UN:
+                       ppc_li (code, ins->dreg, 1);
+                       ppc_bc (code, PPC_BR_FALSE, PPC_BR_LT, 2);
+                       ppc_li (code, ins->dreg, 0);
+                       break;
                case OP_CGT:
                case OP_CGT_UN:
                case OP_ICGT:
@@ -4153,6 +4163,12 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                        ppc_bc (code, PPC_BR_TRUE, PPC_BR_GT, 2);
                        ppc_li (code, ins->dreg, 0);
                        break;
+               case OP_ICLE:
+               case OP_ICLE_UN:
+                       ppc_li (code, ins->dreg, 1);
+                       ppc_bc (code, PPC_BR_FALSE, PPC_BR_GT, 2);
+                       ppc_li (code, ins->dreg, 0);
+                       break;
                case OP_COND_EXC_EQ:
                case OP_COND_EXC_NE_UN:
                case OP_COND_EXC_LT:
@@ -4355,15 +4371,17 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                        ppc_fcmpu (code, 0, ins->sreg1, ins->sreg2);
                        break;
                case OP_FCEQ:
+               case OP_FCNEQ:
                        ppc_fcmpo (code, 0, ins->sreg1, ins->sreg2);
-                       ppc_li (code, ins->dreg, 0);
-                       ppc_bc (code, PPC_BR_FALSE, PPC_BR_EQ, 2);
                        ppc_li (code, ins->dreg, 1);
+                       ppc_bc (code, ins->opcode == OP_FCEQ ? PPC_BR_TRUE : PPC_BR_FALSE, PPC_BR_EQ, 2);
+                       ppc_li (code, ins->dreg, 0);
                        break;
                case OP_FCLT:
+               case OP_FCGE:
                        ppc_fcmpo (code, 0, ins->sreg1, ins->sreg2);
                        ppc_li (code, ins->dreg, 1);
-                       ppc_bc (code, PPC_BR_TRUE, PPC_BR_LT, 2);
+                       ppc_bc (code, ins->opcode == OP_FCLT ? PPC_BR_TRUE : PPC_BR_FALSE, PPC_BR_LT, 2);
                        ppc_li (code, ins->dreg, 0);
                        break;
                case OP_FCLT_UN:
@@ -4374,9 +4392,10 @@ mono_arch_output_basic_block (MonoCompile *cfg, MonoBasicBlock *bb)
                        ppc_li (code, ins->dreg, 0);
                        break;
                case OP_FCGT:
+               case OP_FCLE:
                        ppc_fcmpo (code, 0, ins->sreg1, ins->sreg2);
                        ppc_li (code, ins->dreg, 1);
-                       ppc_bc (code, PPC_BR_TRUE, PPC_BR_GT, 2);
+                       ppc_bc (code, ins->opcode == OP_FCGT ? PPC_BR_TRUE : PPC_BR_FALSE, PPC_BR_GT, 2);
                        ppc_li (code, ins->dreg, 0);
                        break;
                case OP_FCGT_UN:
index a79c535ad3e883ae1f8bb6fe3aafdde5b4066451..2eeb5f34d6e3de1fb09db5496e922816efd868ad 100644 (file)
@@ -890,7 +890,9 @@ mono_thread_abort (MonoObject *obj)
        g_free (jit_tls);*/
 
        if ((mono_runtime_unhandled_exception_policy_get () == MONO_UNHANDLED_POLICY_LEGACY) ||
-                       (obj->vtable->klass == mono_defaults.threadabortexception_class)) {
+                       (obj->vtable->klass == mono_defaults.threadabortexception_class) ||
+                       ((obj->vtable->klass) == mono_class_get_appdomain_unloaded_exception_class () &&
+                       mono_thread_info_current ()->runtime_thread)) {
                mono_thread_exit ();
        } else {
                mono_invoke_unhandled_exception_hook (obj);
@@ -2429,8 +2431,11 @@ create_runtime_invoke_info (MonoDomain *domain, MonoMethod *method, gpointer com
                if (mono_class_is_contextbound (method->klass) || !info->compiled_method)
                        supported = FALSE;
 
-               if (supported)
+               if (supported) {
                        info->dyn_call_info = mono_arch_dyn_call_prepare (sig);
+                       if (debug_options.dyn_runtime_invoke)
+                               g_assert (info->dyn_call_info);
+               }
        }
 #endif
 
@@ -2732,8 +2737,8 @@ mono_jit_runtime_invoke (MonoMethod *method, void *obj, void **params, MonoObjec
                MonoMethodSignature *sig = mono_method_signature (method);
                gpointer *args;
                static RuntimeInvokeDynamicFunction dyn_runtime_invoke;
-               int i, pindex;
-               guint8 buf [512];
+               int i, pindex, buf_size;
+               guint8 *buf;
                guint8 retval [256];
 
                if (!dyn_runtime_invoke) {
@@ -2762,7 +2767,11 @@ mono_jit_runtime_invoke (MonoMethod *method, void *obj, void **params, MonoObjec
 
                //printf ("M: %s\n", mono_method_full_name (method, TRUE));
 
-               mono_arch_start_dyn_call (info->dyn_call_info, (gpointer**)args, retval, buf, sizeof (buf));
+               buf_size = mono_arch_dyn_call_get_buf_size (info->dyn_call_info);
+               buf = g_alloca (buf_size);
+               g_assert (buf);
+
+               mono_arch_start_dyn_call (info->dyn_call_info, (gpointer**)args, retval, buf);
 
                dyn_runtime_invoke (buf, exc, info->compiled_method);
                mono_arch_finish_dyn_call (info->dyn_call_info, buf);
index a11911e5c47985a582e0fe4eee35ec362d44fe04..e0402664a964f9fcf5b675446e92841c7642b2e4 100644 (file)
@@ -17,6 +17,7 @@
 #include <mono/utils/mono-membar.h>
 #include <mono/utils/mono-compiler.h>
 #include <mono/utils/mono-threads-coop.h>
+#include <mono/utils/unlocked.h>
 
 #include "mini.h"
 #include "lldb.h"
@@ -33,7 +34,13 @@ guint8* mono_trampoline_code [MONO_TRAMPOLINE_NUM];
 
 static GHashTable *rgctx_lazy_fetch_trampoline_hash;
 static GHashTable *rgctx_lazy_fetch_trampoline_hash_addr;
-static guint32 trampoline_calls, jit_trampolines, unbox_trampolines, static_rgctx_trampolines;
+
+static gint32 trampoline_calls;
+static gint32 jit_trampolines;
+static gint32 unbox_trampolines;
+static gint32 static_rgctx_trampolines;
+static gint32 rgctx_unmanaged_lookups;
+static gint32 rgctx_num_lazy_fetch_trampolines;
 
 #define mono_trampolines_lock() mono_os_mutex_lock (&trampolines_mutex)
 #define mono_trampolines_unlock() mono_os_mutex_unlock (&trampolines_mutex)
@@ -128,9 +135,9 @@ mono_create_static_rgctx_trampoline (MonoMethod *m, gpointer addr)
        info->m = m;
        info->addr = addr;
        g_hash_table_insert (domain_jit_info (domain)->static_rgctx_trampoline_hash, info, res);
-       mono_domain_unlock (domain);
 
-       static_rgctx_trampolines ++;
+       UnlockedIncrement (&static_rgctx_trampolines);
+       mono_domain_unlock (domain);
 
        return res;
 }
@@ -834,7 +841,7 @@ mono_magic_trampoline (mgreg_t *regs, guint8 *code, gpointer arg, guint8* tramp)
 
        g_assert (mono_thread_is_gc_unsafe_mode ());
 
-       trampoline_calls ++;
+       UnlockedIncrement (&trampoline_calls);
 
        res = common_call_trampoline (regs, code, (MonoMethod *)arg, NULL, NULL, &error);
        if (!is_ok (&error)) {
@@ -862,7 +869,7 @@ mono_vcall_trampoline (mgreg_t *regs, guint8 *code, int slot, guint8 *tramp)
        MonoError error;
        gpointer addr, res = NULL;
 
-       trampoline_calls ++;
+       UnlockedIncrement (&trampoline_calls);
 
        /*
         * We need to obtain the following pieces of information:
@@ -936,7 +943,7 @@ mono_generic_virtual_remoting_trampoline (mgreg_t *regs, guint8 *code, MonoMetho
        MonoMethod *imt_method, *declaring;
        gpointer addr;
 
-       trampoline_calls ++;
+       UnlockedIncrement (&trampoline_calls);
 
        g_assert (m->is_generic);
 
@@ -988,7 +995,7 @@ mono_aot_trampoline (mgreg_t *regs, guint8 *code, guint8 *token_info,
        guint8 *plt_entry;
        MonoError error;
 
-       trampoline_calls ++;
+       UnlockedIncrement (&trampoline_calls);
 
        image = (MonoImage *)*(gpointer*)(gpointer)token_info;
        token_info += sizeof (gpointer);
@@ -1032,7 +1039,7 @@ mono_aot_plt_trampoline (mgreg_t *regs, guint8 *code, guint8 *aot_module,
        gpointer res;
        MonoError error;
 
-       trampoline_calls ++;
+       UnlockedIncrement (&trampoline_calls);
 
        res = mono_aot_plt_resolve (aot_module, plt_info_offset, code, &error);
        if (!res) {
@@ -1053,8 +1060,6 @@ mono_rgctx_lazy_fetch_trampoline (mgreg_t *regs, guint8 *code, gpointer data, gu
 {
        MONO_REQ_GC_UNSAFE_MODE;
 
-       static gboolean inited = FALSE;
-       static int num_lookups = 0;
        guint32 slot = GPOINTER_TO_UINT (data);
        mgreg_t *r = (mgreg_t*)regs;
        gpointer arg = (gpointer)(gssize)r [MONO_ARCH_VTABLE_REG];
@@ -1063,14 +1068,8 @@ mono_rgctx_lazy_fetch_trampoline (mgreg_t *regs, guint8 *code, gpointer data, gu
        MonoError error;
        gpointer res;
 
-       trampoline_calls ++;
-
-       if (!inited) {
-               mono_counters_register ("RGCTX unmanaged lookups", MONO_COUNTER_GENERICS | MONO_COUNTER_INT, &num_lookups);
-               inited = TRUE;
-       }
-
-       num_lookups++;
+       UnlockedIncrement (&trampoline_calls);
+       UnlockedIncrement (&rgctx_unmanaged_lookups);
 
        if (mrgctx)
                res = mono_method_fill_runtime_generic_context ((MonoMethodRuntimeGenericContext *)arg, index, &error);
@@ -1113,7 +1112,7 @@ mono_delegate_trampoline (mgreg_t *regs, guint8 *code, gpointer *arg, guint8* tr
        gpointer addr, compiled_method;
        gboolean is_remote = FALSE;
 
-       trampoline_calls ++;
+       UnlockedIncrement (&trampoline_calls);
 
        /* Obtain the delegate object according to the calling convention */
        delegate = (MonoDelegate *)mono_arch_get_this_arg_from_call (regs, code);
@@ -1352,6 +1351,8 @@ mono_trampolines_init (void)
        mono_counters_register ("JIT trampolines", MONO_COUNTER_JIT | MONO_COUNTER_INT, &jit_trampolines);
        mono_counters_register ("Unbox trampolines", MONO_COUNTER_JIT | MONO_COUNTER_INT, &unbox_trampolines);
        mono_counters_register ("Static rgctx trampolines", MONO_COUNTER_JIT | MONO_COUNTER_INT, &static_rgctx_trampolines);
+       mono_counters_register ("RGCTX unmanaged lookups", MONO_COUNTER_GENERICS | MONO_COUNTER_INT, &rgctx_unmanaged_lookups);
+       mono_counters_register ("RGCTX num lazy fetch trampolines", MONO_COUNTER_GENERICS | MONO_COUNTER_INT, &rgctx_num_lazy_fetch_trampolines);
 }
 
 void
@@ -1496,10 +1497,9 @@ mono_create_jit_trampoline (MonoDomain *domain, MonoMethod *method, MonoError *e
        
        mono_domain_lock (domain);
        g_hash_table_insert (domain_jit_info (domain)->jit_trampoline_hash, method, tramp);
+       UnlockedIncrement (&jit_trampolines);
        mono_domain_unlock (domain);
 
-       jit_trampolines++;
-
        return tramp;
 }      
 
@@ -1519,7 +1519,7 @@ mono_create_jit_trampoline_from_token (MonoImage *image, guint32 token)
 
        tramp = mono_create_specific_trampoline (start, MONO_TRAMPOLINE_AOT, domain, NULL);
 
-       jit_trampolines++;
+       UnlockedIncrement (&jit_trampolines);
 
        return tramp;
 }      
@@ -1602,10 +1602,7 @@ mono_create_delegate_virtual_trampoline (MonoDomain *domain, MonoClass *klass, M
 gpointer
 mono_create_rgctx_lazy_fetch_trampoline (guint32 offset)
 {
-       static gboolean inited = FALSE;
-       static int num_trampolines = 0;
        MonoTrampInfo *info;
-
        gpointer tramp, ptr;
 
        mono_trampolines_lock ();
@@ -1633,15 +1630,9 @@ mono_create_rgctx_lazy_fetch_trampoline (guint32 offset)
        g_hash_table_insert (rgctx_lazy_fetch_trampoline_hash, GUINT_TO_POINTER (offset), ptr);
        g_assert (offset != -1);
        g_hash_table_insert (rgctx_lazy_fetch_trampoline_hash_addr, ptr, GUINT_TO_POINTER (offset + 1));
+       rgctx_num_lazy_fetch_trampolines ++;
        mono_trampolines_unlock ();
 
-       if (!inited) {
-               mono_counters_register ("RGCTX num lazy fetch trampolines",
-                               MONO_COUNTER_GENERICS | MONO_COUNTER_INT, &num_trampolines);
-               inited = TRUE;
-       }
-       num_trampolines++;
-
        return ptr;
 }
 
index fe5071f8d8acbc05fc135ab5aba17d404ea1523e..f8d052627cd72c45b10e5563471039bbb43eb0b9 100644 (file)
@@ -552,7 +552,7 @@ extern MonoMethodDesc *mono_break_at_bb_method;
 extern int mono_break_at_bb_bb_num;
 extern gboolean mono_verify_all;
 extern gboolean mono_do_x86_stack_align;
-extern const char *mono_build_date;
+extern MONO_API const char *mono_build_date;
 extern gboolean mono_do_signal_chaining;
 extern gboolean mono_do_crash_chaining;
 extern MONO_API gboolean mono_use_llvm;
@@ -2783,7 +2783,8 @@ void      mono_arch_emit_outarg_vt              (MonoCompile *cfg, MonoInst *ins
 void      mono_arch_emit_setret                 (MonoCompile *cfg, MonoMethod *method, MonoInst *val);
 MonoDynCallInfo *mono_arch_dyn_call_prepare     (MonoMethodSignature *sig);
 void      mono_arch_dyn_call_free               (MonoDynCallInfo *info);
-void      mono_arch_start_dyn_call              (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf, int buf_len);
+int       mono_arch_dyn_call_get_buf_size       (MonoDynCallInfo *info);
+void      mono_arch_start_dyn_call              (MonoDynCallInfo *info, gpointer **args, guint8 *ret, guint8 *buf);
 void      mono_arch_finish_dyn_call             (MonoDynCallInfo *info, guint8 *buf);
 MonoInst *mono_arch_emit_inst_for_method        (MonoCompile *cfg, MonoMethod *cmethod, MonoMethodSignature *fsig, MonoInst **args);
 void      mono_arch_decompose_opts              (MonoCompile *cfg, MonoInst *ins);
index 88cd9d37a1a2851aa5944c04a5feb265f5651767..212278b57e407b178b84e22766c55e864084e043 100644 (file)
@@ -25,6 +25,8 @@ lib_LTLIBRARIES = \
        libmono-profiler-iomap-static.la \
        libmono-profiler-log.la \
        libmono-profiler-log-static.la \
+       libmono-profiler-coverage.la \
+       libmono-profiler-coverage-static.la \
        $(vtune_libs)
 
 suppressiondir = $(datadir)/mono-$(API_VER)/mono/profiler
@@ -83,6 +85,12 @@ libmono_profiler_log_la_LDFLAGS = $(prof_ldflags)
 libmono_profiler_log_static_la_SOURCES = log.c log-args.c
 libmono_profiler_log_static_la_LDFLAGS = -static
 
+libmono_profiler_coverage_la_SOURCES = coverage.c
+libmono_profiler_coverage_la_LIBADD = $(libmono_dep) $(GLIB_LIBS) $(Z_LIBS)
+libmono_profiler_coverage_la_LDFLAGS = $(prof_ldflags)
+libmono_profiler_coverage_static_la_SOURCES = coverage.c
+libmono_profiler_coverage_static_la_LDFLAGS = -static
+
 if HAVE_VTUNE
 libmono_profiler_vtune_la_SOURCES = vtune.c
 libmono_profiler_vtune_la_CFLAGS = $(VTUNE_CFLAGS)
diff --git a/mono/profiler/coverage.c b/mono/profiler/coverage.c
new file mode 100644 (file)
index 0000000..5a9d5b6
--- /dev/null
@@ -0,0 +1,923 @@
+/*
+ * coverage.c: mono coverage profiler
+ *
+ * Authors:
+ *   Paolo Molaro (lupus@ximian.com)
+ *   Alex Rønne Petersen (alexrp@xamarin.com)
+ *   Ludovic Henry (ludovic@xamarin.com)
+ *
+ * Licensed under the MIT license. See LICENSE file in the project root for full license information.
+ */
+
+/*
+ * The Coverage XML output schema
+ * <coverage>
+ *   <assembly/>
+ *   <class/>
+ *   <method>
+ *     <statement/>
+ *   </method>
+ * </coverage>
+ *
+ * Elements:
+ *   <coverage> - The root element of the documentation. It can contain any number of
+ *                <assembly>, <class> or <method> elements.
+ *                Attributes:
+ *                   - version: The version number for the file format - (eg: "0.3")
+ *   <assembly> - Contains data about assemblies. Has no child elements
+ *                Attributes:
+ *                   - name: The name of the assembly - (eg: "System.Xml")
+ *                   - guid: The GUID of the assembly
+ *                   - filename: The filename of the assembly
+ *                   - method-count: The number of methods in the assembly
+ *                   - full: The number of fully covered methods
+ *                   - partial: The number of partially covered methods
+ *   <class> - Contains data about classes. Has no child elements
+ *             Attributes:
+ *                - name: The name of the class
+ *                - method-count: The number of methods in the class
+ *                - full: The number of fully covered methods
+ *                - partial: The number of partially covered methods
+ *   <method> - Contains data about methods. Can contain any number of <statement> elements
+ *              Attributes:
+ *                 - assembly: The name of the parent assembly
+ *                 - class: The name of the parent class
+ *                 - name: The name of the method, with all it's parameters
+ *                 - filename: The name of the source file containing this method
+ *                 - token
+ *   <statement> - Contains data about IL statements. Has no child elements
+ *                 Attributes:
+ *                    - offset: The offset of the statement in the IL code after the previous
+ *                              statement's offset
+ *                    - counter: 1 if the line was covered, 0 if it was not
+ *                    - line: The line number in the parent method's file
+ *                    - column: The column on the line
+ */
+
+#include <config.h>
+#include <glib.h>
+
+#include <stdio.h>
+
+#ifdef HAVE_DLFCN_H
+#include <dlfcn.h>
+#endif
+#include <fcntl.h>
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+#ifdef HAVE_SYS_MMAN_H
+#include <sys/mman.h>
+#endif
+#if defined (HAVE_SYS_ZLIB)
+#include <zlib.h>
+#endif
+
+#include <mono/metadata/assembly.h>
+#include <mono/metadata/debug-helpers.h>
+#include <mono/metadata/profiler.h>
+#include <mono/metadata/tabledefs.h>
+#include <mono/metadata/metadata-internals.h>
+
+#include <mono/utils/atomic.h>
+#include <mono/utils/hazard-pointer.h>
+#include <mono/utils/lock-free-queue.h>
+#include <mono/utils/mono-conc-hashtable.h>
+#include <mono/utils/mono-os-mutex.h>
+#include <mono/utils/mono-logger-internals.h>
+#include <mono/utils/mono-counters.h>
+
+// Statistics for profiler events.
+static gint32 coverage_methods_ctr,
+              coverage_statements_ctr,
+              coverage_classes_ctr,
+              coverage_assemblies_ctr;
+
+struct _MonoProfiler {
+       MonoProfilerHandle handle;
+
+       FILE* file;
+
+       char *args;
+
+       mono_mutex_t mutex;
+       GPtrArray *data;
+
+       GPtrArray *filters;
+       MonoConcurrentHashTable *filtered_classes;
+       MonoConcurrentHashTable *suppressed_assemblies;
+
+       MonoConcurrentHashTable *methods;
+       MonoConcurrentHashTable *assemblies;
+       MonoConcurrentHashTable *classes;
+
+       MonoConcurrentHashTable *image_to_methods;
+
+       guint32 previous_offset;
+};
+
+typedef struct {
+       //Where to compress the output file
+       gboolean use_zip;
+
+       //Name of the generated xml file
+       const char *output_filename;
+
+       //Filter files used by the code coverage mode
+       GPtrArray *cov_filter_files;
+} ProfilerConfig;
+
+static ProfilerConfig coverage_config;
+static struct _MonoProfiler coverage_profiler;
+
+/* This is a very basic escape function that escapes < > and &
+   Ideally we'd use g_markup_escape_string but that function isn't
+        available in Mono's eglib. This was written without looking at the
+        source of that function in glib. */
+static char *
+escape_string_for_xml (const char *string)
+{
+       GString *string_builder = g_string_new (NULL);
+       const char *start, *p;
+
+       start = p = string;
+       while (*p) {
+               while (*p && *p != '&' && *p != '<' && *p != '>')
+                       p++;
+
+               g_string_append_len (string_builder, start, p - start);
+
+               if (*p == '\0')
+                       break;
+
+               switch (*p) {
+               case '<':
+                       g_string_append (string_builder, "&lt;");
+                       break;
+
+               case '>':
+                       g_string_append (string_builder, "&gt;");
+                       break;
+
+               case '&':
+                       g_string_append (string_builder, "&amp;");
+                       break;
+
+               default:
+                       break;
+               }
+
+               p++;
+               start = p;
+       }
+
+       return g_string_free (string_builder, FALSE);
+}
+
+typedef struct {
+       MonoLockFreeQueueNode node;
+       MonoMethod *method;
+} MethodNode;
+
+typedef struct {
+       int offset;
+       int counter;
+       char *filename;
+       int line;
+       int column;
+} CoverageEntry;
+
+static void
+free_coverage_entry (gpointer data, gpointer userdata)
+{
+       CoverageEntry *entry = (CoverageEntry *)data;
+       g_free (entry->filename);
+       g_free (entry);
+}
+
+static void
+obtain_coverage_for_method (MonoProfiler *prof, const MonoProfilerCoverageData *entry)
+{
+       g_assert (prof == &coverage_profiler);
+
+       int offset = entry->il_offset - coverage_profiler.previous_offset;
+       CoverageEntry *e = g_new (CoverageEntry, 1);
+
+       coverage_profiler.previous_offset = entry->il_offset;
+
+       e->offset = offset;
+       e->counter = entry->counter;
+       e->filename = g_strdup(entry->file_name ? entry->file_name : "");
+       e->line = entry->line;
+       e->column = entry->column;
+
+       g_ptr_array_add (coverage_profiler.data, e);
+}
+
+static char *
+parse_generic_type_names(char *name)
+{
+       char *new_name, *ret;
+       int within_generic_declaration = 0, generic_members = 1;
+
+       if (name == NULL || *name == '\0')
+               return g_strdup ("");
+
+       if (!(ret = new_name = (char *) g_calloc (strlen (name) * 4 + 1, sizeof (char))))
+               return NULL;
+
+       do {
+               switch (*name) {
+                       case '<':
+                               within_generic_declaration = 1;
+                               break;
+
+                       case '>':
+                               within_generic_declaration = 0;
+
+                               if (*(name - 1) != '<') {
+                                       *new_name++ = '`';
+                                       *new_name++ = '0' + generic_members;
+                               } else {
+                                       memcpy (new_name, "&lt;&gt;", 8);
+                                       new_name += 8;
+                               }
+
+                               generic_members = 0;
+                               break;
+
+                       case ',':
+                               generic_members++;
+                               break;
+
+                       default:
+                               if (!within_generic_declaration)
+                                       *new_name++ = *name;
+
+                               break;
+               }
+       } while (*name++);
+
+       return ret;
+}
+
+static void
+dump_method (gpointer key, gpointer value, gpointer userdata)
+{
+       MonoMethod *method = (MonoMethod *)value;
+       MonoClass *klass;
+       MonoImage *image;
+       char *class_name, *escaped_image_name, *escaped_class_name, *escaped_method_name, *escaped_method_signature, *escaped_method_filename;
+       const char *image_name, *method_name, *method_signature, *method_filename;
+       guint i;
+
+       coverage_profiler.previous_offset = 0;
+       coverage_profiler.data = g_ptr_array_new ();
+
+       mono_profiler_get_coverage_data (coverage_profiler.handle, method, obtain_coverage_for_method);
+
+       klass = mono_method_get_class (method);
+       image = mono_class_get_image (klass);
+       image_name = mono_image_get_name (image);
+
+       method_signature = mono_signature_get_desc (mono_method_signature (method), TRUE);
+       class_name = parse_generic_type_names (mono_type_get_name (mono_class_get_type (klass)));
+       method_name = mono_method_get_name (method);
+
+       if (coverage_profiler.data->len != 0) {
+               CoverageEntry *entry = (CoverageEntry *)coverage_profiler.data->pdata[0];
+               method_filename = entry->filename ? entry->filename : "";
+       } else
+               method_filename = "";
+
+       image_name = image_name ? image_name : "";
+       method_signature = method_signature ? method_signature : "";
+       method_name = method_name ? method_name : "";
+
+       escaped_image_name = escape_string_for_xml (image_name);
+       escaped_class_name = escape_string_for_xml (class_name);
+       escaped_method_name = escape_string_for_xml (method_name);
+       escaped_method_signature = escape_string_for_xml (method_signature);
+       escaped_method_filename = escape_string_for_xml (method_filename);
+
+       fprintf (coverage_profiler.file, "\t<method assembly=\"%s\" class=\"%s\" name=\"%s (%s)\" filename=\"%s\" token=\"%d\">\n",
+               escaped_image_name, escaped_class_name, escaped_method_name, escaped_method_signature, escaped_method_filename, mono_method_get_token (method));
+
+       g_free (escaped_image_name);
+       g_free (escaped_class_name);
+       g_free (escaped_method_name);
+       g_free (escaped_method_signature);
+       g_free (escaped_method_filename);
+
+       for (i = 0; i < coverage_profiler.data->len; i++) {
+               CoverageEntry *entry = (CoverageEntry *)coverage_profiler.data->pdata[i];
+
+               fprintf (coverage_profiler.file, "\t\t<statement offset=\"%d\" counter=\"%d\" line=\"%d\" column=\"%d\"/>\n",
+                       entry->offset, entry->counter, entry->line, entry->column);
+       }
+
+       fprintf (coverage_profiler.file, "\t</method>\n");
+
+       g_free (class_name);
+
+       g_ptr_array_foreach (coverage_profiler.data, free_coverage_entry, NULL);
+       g_ptr_array_free (coverage_profiler.data, TRUE);
+}
+
+/* This empties the queue */
+static guint
+count_queue (MonoLockFreeQueue *queue)
+{
+       MonoLockFreeQueueNode *node;
+       guint count = 0;
+
+       while ((node = mono_lock_free_queue_dequeue (queue))) {
+               count++;
+               mono_thread_hazardous_try_free (node, g_free);
+       }
+
+       return count;
+}
+
+static void
+dump_classes_for_image (gpointer key, gpointer value, gpointer userdata)
+{
+       MonoClass *klass = (MonoClass *)key;
+       MonoLockFreeQueue *class_methods = (MonoLockFreeQueue *)value;
+       MonoImage *image;
+       char *class_name, *escaped_class_name;
+       const char *image_name;
+       int number_of_methods, partially_covered;
+       guint fully_covered;
+
+       image = mono_class_get_image (klass);
+       image_name = mono_image_get_name (image);
+
+       if (!image_name || strcmp (image_name, mono_image_get_name (((MonoImage*) userdata))) != 0)
+               return;
+
+       class_name = mono_type_get_name (mono_class_get_type (klass));
+
+       number_of_methods = mono_class_num_methods (klass);
+       fully_covered = count_queue (class_methods);
+       /* We don't handle partial covered yet */
+       partially_covered = 0;
+
+       escaped_class_name = escape_string_for_xml (class_name);
+
+       fprintf (coverage_profiler.file, "\t<class name=\"%s\" method-count=\"%d\" full=\"%d\" partial=\"%d\"/>\n",
+               escaped_class_name, number_of_methods, fully_covered, partially_covered);
+
+       g_free (escaped_class_name);
+
+       g_free (class_name);
+
+}
+
+static void
+get_coverage_for_image (MonoImage *image, int *number_of_methods, guint *fully_covered, int *partially_covered)
+{
+       MonoLockFreeQueue *image_methods = (MonoLockFreeQueue *)mono_conc_hashtable_lookup (coverage_profiler.image_to_methods, image);
+
+       *number_of_methods = mono_image_get_table_rows (image, MONO_TABLE_METHOD);
+       if (image_methods)
+               *fully_covered = count_queue (image_methods);
+       else
+               *fully_covered = 0;
+
+       // FIXME: We don't handle partially covered yet.
+       *partially_covered = 0;
+}
+
+static void
+dump_assembly (gpointer key, gpointer value, gpointer userdata)
+{
+       MonoAssembly *assembly = (MonoAssembly *)value;
+       MonoImage *image = mono_assembly_get_image (assembly);
+       const char *image_name, *image_guid, *image_filename;
+       char *escaped_image_name, *escaped_image_filename;
+       int number_of_methods = 0, partially_covered = 0;
+       guint fully_covered = 0;
+
+       image_name = mono_image_get_name (image);
+       image_guid = mono_image_get_guid (image);
+       image_filename = mono_image_get_filename (image);
+
+       image_name = image_name ? image_name : "";
+       image_guid = image_guid ? image_guid : "";
+       image_filename = image_filename ? image_filename : "";
+
+       get_coverage_for_image (image, &number_of_methods, &fully_covered, &partially_covered);
+
+       escaped_image_name = escape_string_for_xml (image_name);
+       escaped_image_filename = escape_string_for_xml (image_filename);
+
+       fprintf (coverage_profiler.file, "\t<assembly name=\"%s\" guid=\"%s\" filename=\"%s\" method-count=\"%d\" full=\"%d\" partial=\"%d\"/>\n",
+               escaped_image_name, image_guid, escaped_image_filename, number_of_methods, fully_covered, partially_covered);
+
+       g_free (escaped_image_name);
+       g_free (escaped_image_filename);
+
+       mono_conc_hashtable_foreach (coverage_profiler.classes, dump_classes_for_image, image);
+}
+
+static void
+dump_coverage (void)
+{
+       fprintf (coverage_profiler.file, "<?xml version=\"1.0\"?>\n");
+       fprintf (coverage_profiler.file, "<coverage version=\"0.3\">\n");
+
+       mono_os_mutex_lock (&coverage_profiler.mutex);
+       mono_conc_hashtable_foreach (coverage_profiler.assemblies, dump_assembly, NULL);
+       mono_conc_hashtable_foreach (coverage_profiler.methods, dump_method, NULL);
+       mono_os_mutex_unlock (&coverage_profiler.mutex);
+
+       fprintf (coverage_profiler.file, "</coverage>\n");
+}
+
+static MonoLockFreeQueueNode *
+create_method_node (MonoMethod *method)
+{
+       MethodNode *node = (MethodNode *) g_malloc (sizeof (MethodNode));
+       mono_lock_free_queue_node_init ((MonoLockFreeQueueNode *) node, FALSE);
+       node->method = method;
+
+       return (MonoLockFreeQueueNode *) node;
+}
+
+static gboolean
+coverage_filter (MonoProfiler *prof, MonoMethod *method)
+{
+       MonoError error;
+       MonoClass *klass;
+       MonoImage *image;
+       MonoAssembly *assembly;
+       MonoMethodHeader *header;
+       guint32 iflags, flags, code_size;
+       char *fqn, *classname;
+       gboolean has_positive, found;
+       MonoLockFreeQueue *image_methods, *class_methods;
+       MonoLockFreeQueueNode *node;
+
+       g_assert (prof == &coverage_profiler);
+
+       flags = mono_method_get_flags (method, &iflags);
+       if ((iflags & METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL) ||
+           (flags & METHOD_ATTRIBUTE_PINVOKE_IMPL))
+               return FALSE;
+
+       // Don't need to do anything else if we're already tracking this method
+       if (mono_conc_hashtable_lookup (coverage_profiler.methods, method))
+               return TRUE;
+
+       klass = mono_method_get_class (method);
+       image = mono_class_get_image (klass);
+
+       // Don't handle coverage for the core assemblies
+       if (mono_conc_hashtable_lookup (coverage_profiler.suppressed_assemblies, (gpointer) mono_image_get_name (image)) != NULL)
+               return FALSE;
+
+       if (coverage_profiler.filters) {
+               /* Check already filtered classes first */
+               if (mono_conc_hashtable_lookup (coverage_profiler.filtered_classes, klass))
+                       return FALSE;
+
+               classname = mono_type_get_name (mono_class_get_type (klass));
+
+               fqn = g_strdup_printf ("[%s]%s", mono_image_get_name (image), classname);
+
+               // Check positive filters first
+               has_positive = FALSE;
+               found = FALSE;
+               for (guint i = 0; i < coverage_profiler.filters->len; ++i) {
+                       char *filter = (char *)g_ptr_array_index (coverage_profiler.filters, i);
+
+                       if (filter [0] == '+') {
+                               filter = &filter [1];
+
+                               if (strstr (fqn, filter) != NULL)
+                                       found = TRUE;
+
+                               has_positive = TRUE;
+                       }
+               }
+
+               if (has_positive && !found) {
+                       mono_os_mutex_lock (&coverage_profiler.mutex);
+                       mono_conc_hashtable_insert (coverage_profiler.filtered_classes, klass, klass);
+                       mono_os_mutex_unlock (&coverage_profiler.mutex);
+                       g_free (fqn);
+                       g_free (classname);
+
+                       return FALSE;
+               }
+
+               for (guint i = 0; i < coverage_profiler.filters->len; ++i) {
+                       // FIXME: Is substring search sufficient?
+                       char *filter = (char *)g_ptr_array_index (coverage_profiler.filters, i);
+                       if (filter [0] == '+')
+                               continue;
+
+                       // Skip '-'
+                       filter = &filter [1];
+
+                       if (strstr (fqn, filter) != NULL) {
+                               mono_os_mutex_lock (&coverage_profiler.mutex);
+                               mono_conc_hashtable_insert (coverage_profiler.filtered_classes, klass, klass);
+                               mono_os_mutex_unlock (&coverage_profiler.mutex);
+                               g_free (fqn);
+                               g_free (classname);
+
+                               return FALSE;
+                       }
+               }
+
+               g_free (fqn);
+               g_free (classname);
+       }
+
+       header = mono_method_get_header_checked (method, &error);
+       mono_error_cleanup (&error);
+
+       mono_method_header_get_code (header, &code_size, NULL);
+
+       assembly = mono_image_get_assembly (image);
+
+       // Need to keep the assemblies around for as long as they are kept in the hashtable
+       // Nunit, for example, has a habit of unloading them before the coverage statistics are
+       // generated causing a crash. See https://bugzilla.xamarin.com/show_bug.cgi?id=39325
+       mono_assembly_addref (assembly);
+
+       mono_os_mutex_lock (&coverage_profiler.mutex);
+       mono_conc_hashtable_insert (coverage_profiler.methods, method, method);
+       mono_conc_hashtable_insert (coverage_profiler.assemblies, assembly, assembly);
+       mono_os_mutex_unlock (&coverage_profiler.mutex);
+
+       image_methods = (MonoLockFreeQueue *)mono_conc_hashtable_lookup (coverage_profiler.image_to_methods, image);
+
+       if (image_methods == NULL) {
+               image_methods = (MonoLockFreeQueue *) g_malloc (sizeof (MonoLockFreeQueue));
+               mono_lock_free_queue_init (image_methods);
+               mono_os_mutex_lock (&coverage_profiler.mutex);
+               mono_conc_hashtable_insert (coverage_profiler.image_to_methods, image, image_methods);
+               mono_os_mutex_unlock (&coverage_profiler.mutex);
+       }
+
+       node = create_method_node (method);
+       mono_lock_free_queue_enqueue (image_methods, node);
+
+       class_methods = (MonoLockFreeQueue *)mono_conc_hashtable_lookup (coverage_profiler.classes, klass);
+
+       if (class_methods == NULL) {
+               class_methods = (MonoLockFreeQueue *) g_malloc (sizeof (MonoLockFreeQueue));
+               mono_lock_free_queue_init (class_methods);
+               mono_os_mutex_lock (&coverage_profiler.mutex);
+               mono_conc_hashtable_insert (coverage_profiler.classes, klass, class_methods);
+               mono_os_mutex_unlock (&coverage_profiler.mutex);
+       }
+
+       node = create_method_node (method);
+       mono_lock_free_queue_enqueue (class_methods, node);
+
+       return TRUE;
+}
+
+#define LINE_BUFFER_SIZE 4096
+/* Max file limit of 128KB */
+#define MAX_FILE_SIZE 128 * 1024
+static char *
+get_file_content (const gchar *filename)
+{
+       char *buffer;
+       ssize_t bytes_read;
+       long filesize;
+       int res, offset = 0;
+       FILE *stream;
+
+       stream = fopen (filename, "r");
+       if (stream == NULL)
+               return NULL;
+
+       res = fseek (stream, 0, SEEK_END);
+       if (res < 0) {
+               fclose (stream);
+               return NULL;
+       }
+
+       filesize = ftell (stream);
+       if (filesize < 0) {
+               fclose (stream);
+               return NULL;
+       }
+
+       res = fseek (stream, 0, SEEK_SET);
+       if (res < 0) {
+               fclose (stream);
+               return NULL;
+       }
+
+       if (filesize > MAX_FILE_SIZE) {
+               fclose (stream);
+               return NULL;
+       }
+
+       buffer = (char *) g_malloc ((filesize + 1) * sizeof (char));
+       while ((bytes_read = fread (buffer + offset, 1, LINE_BUFFER_SIZE, stream)) > 0)
+               offset += bytes_read;
+
+       /* NULL terminate our buffer */
+       buffer[filesize] = '\0';
+
+       fclose (stream);
+       return buffer;
+}
+
+static char *
+get_next_line (char *contents, char **next_start)
+{
+       char *p = contents;
+
+       if (p == NULL || *p == '\0') {
+               *next_start = NULL;
+               return NULL;
+       }
+
+       while (*p != '\n' && *p != '\0')
+               p++;
+
+       if (*p == '\n') {
+               *p = '\0';
+               *next_start = p + 1;
+       } else
+               *next_start = NULL;
+
+       return contents;
+}
+
+static void
+init_suppressed_assemblies (void)
+{
+       char *content;
+       char *line;
+
+       coverage_profiler.suppressed_assemblies = mono_conc_hashtable_new (g_str_hash, g_str_equal);
+
+       /* Don't need to free content as it is referred to by the lines stored in @filters */
+       content = get_file_content (SUPPRESSION_DIR "/mono-profiler-coverage.suppression");
+       if (content == NULL)
+               content = get_file_content (SUPPRESSION_DIR "/mono-profiler-log.suppression");
+       if (content == NULL)
+               return;
+
+       while ((line = get_next_line (content, &content))) {
+               line = g_strchomp (g_strchug (line));
+               /* No locking needed as we're doing initialization */
+               mono_conc_hashtable_insert (coverage_profiler.suppressed_assemblies, line, line);
+       }
+}
+
+static void
+parse_cov_filter_file (GPtrArray *filters, const char *file)
+{
+       char *content;
+       char *line;
+
+       /* Don't need to free content as it is referred to by the lines stored in @filters */
+       content = get_file_content (file);
+       if (content == NULL) {
+               mono_profiler_printf_err ("Could not open coverage filter file '%s'.", file);
+               return;
+       }
+
+       while ((line = get_next_line (content, &content)))
+               g_ptr_array_add (filters, g_strchug (g_strchomp (line)));
+}
+
+static void
+unref_coverage_assemblies (gpointer key, gpointer value, gpointer userdata)
+{
+       MonoAssembly *assembly = (MonoAssembly *)value;
+       mono_assembly_close (assembly);
+}
+
+static void
+log_shutdown (MonoProfiler *prof)
+{
+       g_assert (prof == &coverage_profiler);
+
+       dump_coverage ();
+
+       mono_os_mutex_lock (&coverage_profiler.mutex);
+       mono_conc_hashtable_foreach (coverage_profiler.assemblies, unref_coverage_assemblies, NULL);
+       mono_os_mutex_unlock (&coverage_profiler.mutex);
+
+       mono_conc_hashtable_destroy (coverage_profiler.methods);
+       mono_conc_hashtable_destroy (coverage_profiler.assemblies);
+       mono_conc_hashtable_destroy (coverage_profiler.classes);
+       mono_conc_hashtable_destroy (coverage_profiler.filtered_classes);
+
+       mono_conc_hashtable_destroy (coverage_profiler.image_to_methods);
+       mono_conc_hashtable_destroy (coverage_profiler.suppressed_assemblies);
+       mono_os_mutex_destroy (&coverage_profiler.mutex);
+
+       if (*coverage_config.output_filename == '|') {
+               pclose (coverage_profiler.file);
+       } else if (*coverage_config.output_filename == '#') {
+               // do nothing
+       } else {
+               fclose (coverage_profiler.file);
+       }
+
+       g_free (coverage_profiler.args);
+}
+
+static void
+runtime_initialized (MonoProfiler *profiler)
+{
+       mono_counters_register ("Event: Coverage methods", MONO_COUNTER_UINT | MONO_COUNTER_PROFILER | MONO_COUNTER_MONOTONIC, &coverage_methods_ctr);
+       mono_counters_register ("Event: Coverage statements", MONO_COUNTER_UINT | MONO_COUNTER_PROFILER | MONO_COUNTER_MONOTONIC, &coverage_statements_ctr);
+       mono_counters_register ("Event: Coverage classes", MONO_COUNTER_UINT | MONO_COUNTER_PROFILER | MONO_COUNTER_MONOTONIC, &coverage_classes_ctr);
+       mono_counters_register ("Event: Coverage assemblies", MONO_COUNTER_UINT | MONO_COUNTER_PROFILER | MONO_COUNTER_MONOTONIC, &coverage_assemblies_ctr);
+}
+
+static void usage (void);
+
+static gboolean
+match_option (const char *arg, const char *opt_name, const char **rval)
+{
+       if (rval) {
+               const char *end = strchr (arg, '=');
+
+               *rval = NULL;
+               if (!end)
+                       return !strcmp (arg, opt_name);
+
+               if (strncmp (arg, opt_name, strlen (opt_name)) || (end - arg) > strlen (opt_name) + 1)
+                       return FALSE;
+               *rval = end + 1;
+               return TRUE;
+       } else {
+               //FIXME how should we handle passing a value to an arg that doesn't expect it?
+               return !strcmp (arg, opt_name);
+       }
+}
+
+static void
+parse_arg (const char *arg)
+{
+       const char *val;
+
+       if (match_option (arg, "help", NULL)) {
+               usage ();
+       // } else if (match_option (arg, "zip", NULL)) {
+       //      coverage_config.use_zip = TRUE;
+       } else if (match_option (arg, "output", &val)) {
+               coverage_config.output_filename = g_strdup (val);
+       // } else if (match_option (arg, "covfilter", &val)) {
+       //      g_error ("not supported");
+       } else if (match_option (arg, "covfilter-file", &val)) {
+               if (coverage_config.cov_filter_files == NULL)
+                       coverage_config.cov_filter_files = g_ptr_array_new ();
+               g_ptr_array_add (coverage_config.cov_filter_files, g_strdup (val));
+       } else {
+               mono_profiler_printf_err ("Could not parse argument: %s", arg);
+       }
+}
+
+static void
+parse_args (const char *desc)
+{
+       const char *p;
+       gboolean in_quotes = FALSE;
+       char quote_char = '\0';
+       char *buffer = malloc (strlen (desc));
+       int buffer_pos = 0;
+
+       for (p = desc; *p; p++){
+               switch (*p){
+               case ',':
+                       if (!in_quotes) {
+                               if (buffer_pos != 0){
+                                       buffer [buffer_pos] = 0;
+                                       parse_arg (buffer);
+                                       buffer_pos = 0;
+                               }
+                       } else {
+                               buffer [buffer_pos++] = *p;
+                       }
+                       break;
+
+               case '\\':
+                       if (p [1]) {
+                               buffer [buffer_pos++] = p[1];
+                               p++;
+                       }
+                       break;
+               case '\'':
+               case '"':
+                       if (in_quotes) {
+                               if (quote_char == *p)
+                                       in_quotes = FALSE;
+                               else
+                                       buffer [buffer_pos++] = *p;
+                       } else {
+                               in_quotes = TRUE;
+                               quote_char = *p;
+                       }
+                       break;
+               default:
+                       buffer [buffer_pos++] = *p;
+                       break;
+               }
+       }
+
+       if (buffer_pos != 0) {
+               buffer [buffer_pos] = 0;
+               parse_arg (buffer);
+       }
+
+       g_free (buffer);
+}
+
+static void
+usage (void)
+{
+       mono_profiler_printf ("Mono coverage profiler");
+       mono_profiler_printf ("Usage: mono --profile=coverage[:OPTION1[,OPTION2...]] program.exe\n");
+       mono_profiler_printf ("Options:");
+       mono_profiler_printf ("\thelp                 show this usage info");
+
+       // mono_profiler_printf ("\tcovfilter=ASSEMBLY   add ASSEMBLY to the code coverage filters");
+       // mono_profiler_printf ("\t                     prefix a + to include the assembly or a - to exclude it");
+       // mono_profiler_printf ("\t                     e.g. covfilter=-mscorlib");
+       mono_profiler_printf ("\tcovfilter-file=FILE  use FILE to generate the list of assemblies to be filtered");
+       mono_profiler_printf ("\toutput=FILENAME      write the data to file FILENAME (the file is always overwritten)");
+       mono_profiler_printf ("\toutput=+FILENAME     write the data to file FILENAME.pid (the file is always overwritten)");
+       mono_profiler_printf ("\toutput=|PROGRAM      write the data to the stdin of PROGRAM");
+       mono_profiler_printf ("\toutput=|PROGRAM      write the data to the stdin of PROGRAM");
+       // mono_profiler_printf ("\tzip                  compress the output data");
+}
+
+MONO_API void
+mono_profiler_init_coverage (const char *desc);
+
+void
+mono_profiler_init_coverage (const char *desc)
+{
+       GPtrArray *filters = NULL;
+
+       parse_args (desc [strlen("coverage")] == ':' ? desc + strlen ("coverage") + 1 : "");
+
+       if (coverage_config.cov_filter_files) {
+               filters = g_ptr_array_new ();
+               int i;
+               for (i = 0; i < coverage_config.cov_filter_files->len; ++i) {
+                       const char *name = coverage_config.cov_filter_files->pdata [i];
+                       parse_cov_filter_file (filters, name);
+               }
+       }
+
+       coverage_profiler.args = g_strdup (desc);
+
+       //If coverage_config.output_filename begin with +, append the pid at the end
+       if (!coverage_config.output_filename)
+               coverage_config.output_filename = "coverage.xml";
+       else if (*coverage_config.output_filename == '+')
+               coverage_config.output_filename = g_strdup_printf ("%s.%d", coverage_config.output_filename + 1, getpid ());
+
+       if (*coverage_config.output_filename == '|')
+               coverage_profiler.file = popen (coverage_config.output_filename + 1, "w");
+       else if (*coverage_config.output_filename == '#')
+               coverage_profiler.file = fdopen (strtol (coverage_config.output_filename + 1, NULL, 10), "a");
+       else
+               coverage_profiler.file = fopen (coverage_config.output_filename, "w");
+
+       if (!coverage_profiler.file) {
+               mono_profiler_printf_err ("Could not create coverage profiler output file '%s'.", coverage_config.output_filename);
+               exit (1);
+       }
+
+       mono_os_mutex_init (&coverage_profiler.mutex);
+       coverage_profiler.methods = mono_conc_hashtable_new (NULL, NULL);
+       coverage_profiler.assemblies = mono_conc_hashtable_new (NULL, NULL);
+       coverage_profiler.classes = mono_conc_hashtable_new (NULL, NULL);
+       coverage_profiler.filtered_classes = mono_conc_hashtable_new (NULL, NULL);
+       coverage_profiler.image_to_methods = mono_conc_hashtable_new (NULL, NULL);
+       init_suppressed_assemblies ();
+
+       coverage_profiler.filters = filters;
+
+       MonoProfilerHandle handle = coverage_profiler.handle = mono_profiler_create (&coverage_profiler);
+
+       /*
+        * Required callbacks. These are either necessary for the profiler itself
+        * to function, or provide metadata that's needed if other events (e.g.
+        * allocations, exceptions) are dynamically enabled/disabled.
+        */
+
+       mono_profiler_set_runtime_shutdown_end_callback (handle, log_shutdown);
+       mono_profiler_set_runtime_initialized_callback (handle, runtime_initialized);
+
+       mono_profiler_enable_coverage ();
+       mono_profiler_set_coverage_filter_callback (handle, coverage_filter);
+}
index 1b9c83586944fd6d007bec4655810afa0edf91bf..3cfadd1e5138ba73a8edc41cd0d618dceb975a53 100644 (file)
@@ -81,6 +81,7 @@ parse_arg (const char *arg, ProfilerConfig *config)
        } else if (match_option (arg, "calls", NULL)) {
                config->enter_leave = TRUE;
        } else if (match_option (arg, "coverage", NULL)) {
+               g_warning ("the log profiler support for code coverage is obsolete, use the \"coverage\" profiler");
                config->collect_coverage = TRUE;
        } else if (match_option (arg, "zip", NULL)) {
                config->use_zip = TRUE;
index 4f463c28b951ccbefe112d7063472abd352d3e76..f3dbc56cbad61ad5382d149c07877bdd0359877b 100644 (file)
@@ -1142,7 +1142,7 @@ sync_point_mark (MonoProfilerSyncPointType type)
 
        ENTER_LOG (&sync_points_ctr, logbuffer,
                EVENT_SIZE /* event */ +
-               LEB128_SIZE /* type */
+               BYTE_SIZE /* type */
        );
 
        emit_event (logbuffer, TYPE_META | TYPE_SYNC_POINT);
@@ -1219,7 +1219,7 @@ gc_roots (MonoProfiler *prof, MonoObject *const *objects, const MonoProfilerGCRo
 
        for (int i = 0; i < num; ++i) {
                emit_obj (logbuffer, objects [i]);
-               emit_byte (logbuffer, root_types [i]);
+               emit_value (logbuffer, root_types [i]);
                emit_value (logbuffer, extra_info [i]);
        }
 
@@ -1905,7 +1905,8 @@ clause_exc (MonoProfiler *prof, MonoMethod *method, uint32_t clause_num, MonoExc
                EVENT_SIZE /* event */ +
                BYTE_SIZE /* clause type */ +
                LEB128_SIZE /* clause num */ +
-               LEB128_SIZE /* method */
+               LEB128_SIZE /* method */ +
+               LEB128_SIZE /* exc */
        );
 
        emit_event (logbuffer, TYPE_EXCEPTION | TYPE_CLAUSE);
@@ -2268,7 +2269,7 @@ dump_ubin (const char *filename, uintptr_t load_addr, uint64_t offset, uintptr_t
                LEB128_SIZE /* load address */ +
                LEB128_SIZE /* offset */ +
                LEB128_SIZE /* size */ +
-               nlen /* file name */
+               len /* file name */
        );
 
        emit_event (logbuffer, TYPE_SAMPLE | TYPE_SAMPLE_UBIN);
@@ -2671,6 +2672,12 @@ counters_sample (uint64_t timestamp)
        ;
 
        for (agent = log_profiler.counters; agent; agent = agent->next) {
+               /*
+                * FIXME: This calculation is incorrect for string counters since
+                * mono_counter_get_size () just returns 0 in that case. We should
+                * address this if we ever actually add any string counters to Mono.
+                */
+
                size +=
                        LEB128_SIZE /* index */ +
                        BYTE_SIZE /* type */ +
index d8182d90ee27dfc7d3b266e31124bd7f3dae2baa..f0503e4a4e423f7c9bc43c131d9ba5a3d3537642 100644 (file)
@@ -70,6 +70,7 @@
                class unload events no longer exist (they were never emitted)
                removed type field from TYPE_SAMPLE_HIT
                removed MONO_GC_EVENT_{MARK,RECLAIM}_{START,END}
+               reverted the root_type field back to uleb128
  */
 
 /*
  *     [num_roots: uleb128] number of root references
  *     [num_gc: uleb128] number of major gcs
  *     [object: sleb128] the object as a difference from obj_base
- *     [root_type: byte] the root_type: MonoProfileGCRootType (profiler.h)
+ *     [root_type: uleb128] the root_type: MonoProfileGCRootType (profiler.h)
  *     [extra_info: uleb128] the extra_info value
  *     object, root_type and extra_info are repeated num_roots times
  *
index 4251a164ff56623acb10f147837edbf2b8b0b858..bc9971ad2320defc5c285f651207d8520d236c74 100644 (file)
@@ -2703,7 +2703,7 @@ decode_buffer (ProfContext *ctx)
                                for (i = 0; i < num; ++i) {
                                        intptr_t objdiff = decode_sleb128 (p, &p);
                                        int root_type;
-                                       if (ctx->data_version > 12)
+                                       if (ctx->data_version == 13)
                                                root_type = *p++;
                                        else
                                                root_type = decode_uleb128 (p, &p);
index 6088c5220d352a5cc132c96c52d9f84493360b71..77f06635dde8017a61e1b2cdf018e915e63a44d7 100755 (executable)
@@ -469,6 +469,7 @@ TESTS_CS_SRC=               \
        appdomain-unload-callback.cs    \
        appdomain-unload-doesnot-raise-pending-events.cs        \
        appdomain-unload-asmload.cs     \
+       appdomain-unload-exception.cs   \
        unload-appdomain-on-shutdown.cs \
        bug-47295.cs    \
        loader.cs       \
@@ -517,7 +518,9 @@ TESTS_CS_SRC=               \
        runtime-invoke.gen.cs \
        imt_big_iface_test.cs \
        bug-58782-plain-throw.cs \
-       bug-58782-capture-and-throw.cs
+       bug-58782-capture-and-throw.cs \
+       recursive-struct-arrays.cs \
+       bug-59281.cs
 
 if AMD64
 TESTS_CS_SRC += async-exc-compilation.cs finally_guard.cs finally_block_ending_in_dead_bb.cs
@@ -958,6 +961,7 @@ INTERP_DISABLED_TESTS = \
        array_load_exception.exe \
        assembly_append_ordering.exe \
        assemblyresolve_event4.exe \
+       assemblyresolve_event6.exe \
        async-exc-compilation.exe \
        async-with-cb-throws.exe \
        async_read.exe \
@@ -1905,7 +1909,8 @@ test-process-exit:
 
 # tests that expect a 1 exit code
 TESTS_UNHANDLED_EXCEPTION_1_SRC =      \
-       unhandled-exception-1.cs
+       unhandled-exception-1.cs        \
+       unhandled-exception-9.cs
 
 # tests that expect a 255 exit code
 TESTS_UNHANDLED_EXCEPTION_255_SRC =    \
diff --git a/mono/tests/appdomain-unload-exception.cs b/mono/tests/appdomain-unload-exception.cs
new file mode 100644 (file)
index 0000000..dc6bd38
--- /dev/null
@@ -0,0 +1,35 @@
+using System;
+using System.Diagnostics;
+using System.Threading;
+using System.Threading.Tasks;
+
+class Driver
+{
+       static void ThrowTP ()
+       {
+               ManualResetEvent mre = new ManualResetEvent (false);
+
+               ThreadPool.QueueUserWorkItem (_ => { try { throw new AppDomainUnloadedException (); } finally { mre.Set (); } });
+
+               if (!mre.WaitOne (5000))
+                       Environment.Exit (1);
+
+               /* Wait for exception unwinding */
+               Thread.Sleep (500);
+       }
+
+       static void ThrowThread ()
+       {
+               Thread thread = new Thread (_ => { throw new AppDomainUnloadedException (); });
+               thread.Start ();
+               thread.Join ();
+       }
+
+       static int Main (string[] args)
+       {
+               ThrowTP ();
+               ThrowThread ();
+
+               return 0;
+       }
+}
index e5ce63689219231bba99f26ef95eb35baafc8c1f..07cdf833e8cfafba1993b6111038c77c0da84ba8 100644 (file)
@@ -83,6 +83,40 @@ public class BThread : MarshalByRefObject {
        }
 }
 
+public interface IRunnable {
+       void Run ();
+}
+
+public class MBRObject : MarshalByRefObject, IRunnable {
+       /* XDomain wrappers for invocation */
+       public void Run () {
+               while (true) {
+                       try {
+                               while (true)
+                                       Thread.Sleep (100);
+                       }
+                       catch (ThreadAbortException ex) {
+                               Thread.ResetAbort ();
+                       }
+               }
+       }
+}
+
+public class CBObject : ContextBoundObject, IRunnable {
+       /* Slow corlib path for invocation */
+       public void Run () {
+               while (true) {
+                       try {
+                               while (true)
+                                       Thread.Sleep (100);
+                       }
+                       catch (ThreadAbortException ex) {
+                               Thread.ResetAbort ();
+                       }
+               }
+       }
+}
+
 public class UnloadThread {
 
        AppDomain domain;
@@ -191,6 +225,32 @@ public class Tests
        }
        */
 
+       public static void ThreadStart (object obj)
+       {
+               IRunnable runnable = (IRunnable)obj;
+
+               try {
+                       runnable.Run ();
+               } catch (AppDomainUnloadedException) {
+                       Console.WriteLine ("OK");
+               } catch (ThreadAbortException) {
+                       throw new Exception ();
+               }
+       }
+
+       public static int test_0_unload_reset_abort () {
+               AppDomain domain = AppDomain.CreateDomain ("test_0_unload_reset_abort");
+               MBRObject mbro = (MBRObject) domain.CreateInstanceFromAndUnwrap (typeof (Tests).Assembly.Location, "MBRObject");
+               CBObject cbo = (CBObject) domain.CreateInstanceFromAndUnwrap (typeof (Tests).Assembly.Location, "CBObject");
+
+               new Thread (ThreadStart).Start (mbro);
+               new Thread (ThreadStart).Start (cbo);
+               Thread.Sleep (100);
+
+               AppDomain.Unload (domain);
+               return 0;
+       }
+
        static void Worker (object x) {
                Thread.Sleep (100000);
        }
@@ -240,15 +300,18 @@ public class Tests
 
        public static int test_0_unload_inside_appdomain_sync () {
                AppDomain domain = AppDomain.CreateDomain ("Test3");
+               bool caught = false;
 
                try {
                        domain.DoCallBack (new CrossAppDomainDelegate (SyncCallback));
                }
-               catch (Exception ex) {
-                       /* Should throw a ThreadAbortException */
-                       Thread.ResetAbort ();
+               catch (AppDomainUnloadedException ex) {
+                       caught = true;
                }
 
+               if (!caught)
+                       return 1;
+
                return 0;
        }
 
diff --git a/mono/tests/bug-59281.cs b/mono/tests/bug-59281.cs
new file mode 100644 (file)
index 0000000..94250c2
--- /dev/null
@@ -0,0 +1,51 @@
+using System;
+using System.Threading;
+
+class Driver
+{
+
+       static readonly Mutex[] mutexes = new Mutex[2];
+
+       public static void Main(string[] args)
+       {
+               for (int i = 0; i < mutexes.Length; i++) {
+                       mutexes [i] = new Mutex();
+               }
+
+               Thread thread1 = new Thread(() => {
+                       for (int i = 0; i < 1; i++) {
+                               int idx = -1;
+                               try {
+                                       idx = WaitHandle.WaitAny (mutexes);
+                                       Console.WriteLine($"Thread 1 iter: {i} with mutex: {idx}");
+                               } finally {
+                                       if (idx != -1)
+                                               mutexes [idx].ReleaseMutex();
+                               }
+                       }
+
+                       Console.WriteLine("Thread 1 ended");
+               });
+
+               thread1.Start();
+               thread1.Join();
+
+               Thread thread2 = new Thread(() => {
+                       for (int i = 0; i < 1000; i++) {
+                               int idx = -1;
+                               try {
+                                       idx = WaitHandle.WaitAny (mutexes);
+                                       Console.WriteLine($"Thread 2 iter: {i} with mutex: {idx}");
+                               } finally {
+                                       if (idx != -1)
+                                               mutexes [idx].ReleaseMutex();
+                               }
+                       }
+
+                       Console.WriteLine("Thread 2 ended");
+               });
+
+               thread2.Start();
+               thread2.Join();
+       }
+}
\ No newline at end of file
diff --git a/mono/tests/recursive-struct-arrays.cs b/mono/tests/recursive-struct-arrays.cs
new file mode 100644 (file)
index 0000000..dd1c8b2
--- /dev/null
@@ -0,0 +1,65 @@
+using System;
+
+/* Test that the runtime can represent value types that have array fields that
+ * recursively refer to the same value type */
+
+struct S1 {
+       static S1[][] foo;
+}
+
+struct S2 {
+       static S2[] foo;
+}
+
+struct S3a {
+       static S3b[] foo;
+}
+
+struct S3b {
+       static S3a[][] foo;
+}
+
+struct P<X> where X : struct {
+       static P<X>[][] foo;
+}
+
+public struct S4
+{
+       private static S4[][] foo;
+
+       public static readonly S4 West = new S4(-1, 0);
+       public static readonly S4 East = new S4(1, 0);
+       public static readonly S4 North = new S4(0, 1);
+       public static readonly S4 South = new S4(0, -1);
+       public static readonly S4[] Directions = { North, South, East, West };
+
+       public readonly int x;
+       public readonly int z;
+
+       public S4(int x, int z)
+       {
+               this.x = x;
+               this.z = z;
+       }
+
+       public override string ToString()
+       {
+               return string.Format("[{0}, {1}]", x, z);
+       }
+}
+
+
+class Program {
+       static int Main() {
+               Console.WriteLine (typeof (S1).Name);
+               Console.WriteLine (typeof (S2).Name);
+               Console.WriteLine (typeof (S3a).Name);
+               Console.WriteLine (typeof (S3b).Name);
+               foreach (var s4 in S4.Directions) {
+                       Console.WriteLine (s4);
+               }
+               Console.WriteLine (typeof (P<S1>).Name);
+               Console.WriteLine (typeof (P<int>).Name);
+               return 0;
+       }
+}
index 23fec490693ff134df0462fe9125fc60160bbd86..2c34478f83d63d1931908c51f24d1384fbc2f1db 100644 (file)
@@ -29,6 +29,11 @@ enum Enum2
        D
 }
 
+struct AStruct {
+       public int a1, a2, a3, a4, a5, a6, a7, a8, a9, a10;
+       public int a11, a12, a13, a14, a15, a16, a17, a18, a19, a20;
+}
+
 class Tests
 {
        public static Enum1 return_enum1 () {
@@ -47,6 +52,10 @@ class Tests
                return UInt64.MaxValue - 5;
        }
 
+       public static object return_t<T> (T t) {
+               return (object)t;
+       }
+
        static int Main (string[] args)
        {
                return TestDriver.RunTests (typeof (Tests), args);
@@ -279,4 +288,19 @@ class Tests
         else
             return 1;
     }
+
+       public static int test_0_large_arg ()
+       {
+               var arg = new AStruct ();
+               arg.a1 = 1;
+               arg.a2 = 2;
+               arg.a3 = 3;
+               arg.a20 = 20;
+               var res = typeof (Tests).GetMethod ("return_t").MakeGenericMethod (new Type [] { typeof (AStruct) }).Invoke (null, new object [] { arg });
+               var arg2 = (AStruct)res;
+               if (arg2.a20 == 20)
+                       return 0;
+               else
+                       return 1;
+       }
 }
diff --git a/mono/tests/unhandled-exception-9.cs b/mono/tests/unhandled-exception-9.cs
new file mode 100644 (file)
index 0000000..7016b5d
--- /dev/null
@@ -0,0 +1,16 @@
+using System;
+using System.Diagnostics;
+using System.Threading;
+using System.Threading.Tasks;
+
+class Driver
+{
+       /* expected exit code: 1 */
+       static void Main (string[] args)
+       {
+               if (Environment.GetEnvironmentVariable ("TEST_UNHANDLED_EXCEPTION_HANDLER") != null)
+                       AppDomain.CurrentDomain.UnhandledException += (s, e) => {};
+
+               throw new AppDomainUnloadedException ();
+       }
+}
diff --git a/mono/tests/verifier/unverifiable_ref_return_stack_merge.il b/mono/tests/verifier/unverifiable_ref_return_stack_merge.il
new file mode 100644 (file)
index 0000000..f82539b
--- /dev/null
@@ -0,0 +1,59 @@
+.assembly extern mscorlib
+{
+  .ver 4:0:0:0
+  .publickeytoken = (B7 7A 5C 56 19 34 E0 89 ) // .z\V.4..
+}
+.assembly 'ref-return'
+{
+  .hash algorithm 0x00008004
+  .ver  0:0:0:0
+}
+.module 'ref-return.dll' // GUID = {09E5E448-CA90-49A5-AFBA-0AA241F72FBF}
+
+
+.class private auto ansi beforefieldinit Test extends [mscorlib]System.Object
+{
+       .field  private static  int32 X
+       .field  private static  int32 Y
+
+       .method private static hidebysig  default int32& invalid_branch1 (bool b)  cil managed 
+       {
+               .maxstack 1
+               .locals init (int32&, int32)
+               ldarg.0 
+               brtrue.s LABEL_1
+
+               ldsflda int32 Test::Y
+               br.s LABEL_2
+
+LABEL_1:
+               ldloca 1
+
+LABEL_2:
+               stloc.0 
+
+               ldloc.0 
+               ret 
+       }
+
+       .method private static hidebysig  default int32& invalid_branch2 (bool b)  cil managed 
+       {
+               .maxstack 1
+               .locals init (int32&, int32)
+               ldarg.0 
+               brtrue.s LABEL_1
+
+               ldloca 1
+               br.s LABEL_2
+
+LABEL_1:
+               ldsflda int32 Test::X
+
+LABEL_2:
+               stloc.0 
+
+               ldloc.0 
+               ret 
+       }
+}
+
diff --git a/mono/tests/verifier/valid_ref_return.cs b/mono/tests/verifier/valid_ref_return.cs
new file mode 100644 (file)
index 0000000..85e1f54
--- /dev/null
@@ -0,0 +1,77 @@
+using System;
+
+struct Point {
+    public int x;
+    public int y;
+}
+
+class Foo {
+       static int X = 10;
+       static int[] Arr = new int[1];
+       int y;
+
+       static void Main () {
+       }
+
+       static ref int ReturnStatic () {
+               return ref X;
+       }
+
+       ref int ReturnField () {
+               return ref this.y;
+       }
+
+       ref int ReturnArrayElement () {
+               return ref Arr [0];
+       }
+
+       ref int ReturnArg (ref int arg) {
+               return ref arg;
+       }
+
+       ref int TwoReturns (bool b) {
+               if (b) 
+                       return ref X;
+               else
+                       return ref Arr [0];
+       }
+
+       ref int LocalVarRet (bool b) {
+               ref int x = ref X;
+               ReturnArg (ref x);
+               return ref x;
+       }
+
+       ref int ReturnRet (ref int arg) {
+               return ref ReturnArg (ref arg);
+       }
+
+       ref int ReturnFromCatch () {
+               try {
+                       return ref X;
+               } catch (Exception) {
+                       return ref X;
+               } 
+       }
+
+       ref int ReturnFunc () {
+               return ref ReturnStatic ();
+       }
+
+    Point mp;
+
+    ref int Pick (bool b, ref Point p) {
+        if (b)
+            return ref p.x;
+        else
+            return ref p.y;
+    }
+
+    void F (bool b) {
+        Point lp = new Point {x = 3, y = 3};
+        ref int z = ref Pick (b, ref lp);
+        z = 4;
+        ref int z2 = ref Pick (b, ref mp);
+        z2 = 5;
+    }
+}
diff --git a/mono/tests/verifier/valid_ref_return_stack_merge.il b/mono/tests/verifier/valid_ref_return_stack_merge.il
new file mode 100644 (file)
index 0000000..a208308
--- /dev/null
@@ -0,0 +1,39 @@
+.assembly extern mscorlib
+{
+  .ver 4:0:0:0
+  .publickeytoken = (B7 7A 5C 56 19 34 E0 89 ) // .z\V.4..
+}
+.assembly 'ref-return'
+{
+  .hash algorithm 0x00008004
+  .ver  0:0:0:0
+}
+.module 'ref-return.dll' // GUID = {09E5E448-CA90-49A5-AFBA-0AA241F72FBF}
+
+
+.class private auto ansi beforefieldinit Test extends [mscorlib]System.Object
+{
+       .field  private static  int32 X
+       .field  private static  int32 Y
+
+       .method private static hidebysig  default int32& valid_branch (bool b)  cil managed 
+       {
+               .maxstack 1
+               .locals init (int32&    V_0)
+               ldarg.0 
+               brtrue.s LABEL_1
+
+               ldsflda int32 Test::Y
+               br.s LABEL_2
+
+LABEL_1:
+               ldsflda int32 Test::X
+
+LABEL_2:
+               stloc.0 
+
+               ldloc.0 
+               ret 
+       }
+}
+
index 118ab953d0e8bcc172995e3e797a268899737113..119d7c94c2cce1c8e2427211a53467708fc0eeb4 100644 (file)
@@ -13,7 +13,8 @@ endif
 
 if HOST_WIN32
 win32_sources = \
-       os-event-win32.c
+       os-event-win32.c \
+       mono-os-wait-win32.c
 
 platform_sources = $(win32_sources)
 else
@@ -61,6 +62,7 @@ monoutils_sources = \
        mono-mmap-windows-internals.h   \
        mono-os-mutex.h         \
        mono-os-mutex.c         \
+       mono-os-wait.h \
        mono-coop-mutex.h               \
        mono-once.h             \
        mono-lazy-init.h                \
index f766529201e3426bf1349b2f3020ad39d9a54932..0f8984ef9d9d2ef19f7a371feeb0726799351f0f 100644 (file)
@@ -31,8 +31,7 @@
 #elif !defined(HOST_WIN32) && defined(HAVE_SEMAPHORE_H)
 #include <semaphore.h>
 #else
-#include <winsock2.h>
-#include <windows.h>
+#include <mono/utils/mono-os-wait.h>
 #endif
 
 #define MONO_HAS_SEMAPHORES 1
@@ -318,9 +317,9 @@ mono_os_sem_timedwait (MonoSemType *sem, guint32 timeout_ms, MonoSemFlags flags)
        BOOL res;
 
 retry:
-       res = WaitForSingleObjectEx (*sem, timeout_ms, flags & MONO_SEM_FLAGS_ALERTABLE);
+       res = mono_win32_wait_for_single_object_ex (*sem, timeout_ms, flags & MONO_SEM_FLAGS_ALERTABLE);
        if (G_UNLIKELY (res != WAIT_OBJECT_0 && res != WAIT_IO_COMPLETION && res != WAIT_TIMEOUT))
-               g_error ("%s: WaitForSingleObjectEx failed with error %d", __func__, GetLastError ());
+               g_error ("%s: mono_win32_wait_for_single_object_ex failed with error %d", __func__, GetLastError ());
 
        if (res == WAIT_IO_COMPLETION && !(flags & MONO_SEM_FLAGS_ALERTABLE))
                goto retry;
diff --git a/mono/utils/mono-os-wait-win32.c b/mono/utils/mono-os-wait-win32.c
new file mode 100644 (file)
index 0000000..a302d97
--- /dev/null
@@ -0,0 +1,217 @@
+/**
+* \file
+* Win32 OS wait wrappers and interrupt/abort APC handling.
+*
+* Author:
+*   Johan Lorensson (lateralusx.github@gmail.com)
+*
+* Licensed under the MIT license. See LICENSE file in the project root for full license information.
+*/
+
+#include <mono/utils/mono-os-wait.h>
+#include <mono/utils/mono-threads.h>
+#include <mono/utils/mono-threads-debug.h>
+
+enum ThreadWaitInfo {
+       THREAD_WAIT_INFO_CLEARED = 0,
+       THREAD_WAIT_INFO_ALERTABLE_WAIT_SLOT = 1 << 0,
+       THREAD_WAIT_INFO_PENDING_INTERRUPT_APC_SLOT = 1 << 1,
+       THREAD_WAIT_INFO_PENDING_ABORT_APC_SLOT = 1 << 2
+};
+
+static inline void
+request_interrupt (gpointer thread_info, HANDLE native_thread_handle, gint32 pending_apc_slot, PAPCFUNC apc_callback, DWORD tid)
+{
+       /*
+       * On Windows platforms, an async interrupt/abort request queues an APC
+       * that needs to be processed by target thread before it can return from an
+       * alertable OS wait call and complete the mono interrupt/abort request.
+       * Uncontrolled queuing of APC's could flood the APC queue preventing the target thread
+       * to return from its alertable OS wait call, blocking the interrupt/abort requests to complete
+       * This check makes sure that only one APC per type gets queued, preventing potential flooding
+       * of the APC queue. NOTE, this code will execute regardless if targeted thread is currently in
+       * an alertable wait or not. This is done to prevent races between interrupt/abort requests and
+       * alertable wait calls. Threads already in an alertable wait should handle WAIT_IO_COMPLETION
+       * return scenarios and restart the alertable wait operation if needed or take other actions
+       * (like service the interrupt/abort request).
+       */
+       MonoThreadInfo *info = (MonoThreadInfo *)thread_info;
+       gint32 old_wait_info, new_wait_info;
+
+       do {
+               old_wait_info = InterlockedRead (&info->thread_wait_info);
+               if (old_wait_info & pending_apc_slot)
+                       return;
+
+               new_wait_info = old_wait_info | pending_apc_slot;
+       } while (InterlockedCompareExchange (&info->thread_wait_info, new_wait_info, old_wait_info) != old_wait_info);
+
+       THREADS_INTERRUPT_DEBUG ("%06d - Interrupting/Aborting syscall in thread %06d", GetCurrentThreadId (), tid);
+       QueueUserAPC (apc_callback, native_thread_handle, (ULONG_PTR)NULL);
+}
+
+static void CALLBACK
+interrupt_apc (ULONG_PTR param)
+{
+       THREADS_INTERRUPT_DEBUG ("%06d - interrupt_apc () called", GetCurrentThreadId ());
+}
+
+void
+mono_win32_interrupt_wait (PVOID thread_info, HANDLE native_thread_handle, DWORD tid)
+{
+       request_interrupt (thread_info, native_thread_handle, THREAD_WAIT_INFO_PENDING_INTERRUPT_APC_SLOT, interrupt_apc, tid);
+}
+
+static void CALLBACK
+abort_apc (ULONG_PTR param)
+{
+       THREADS_INTERRUPT_DEBUG ("%06d - abort_apc () called", GetCurrentThreadId ());
+}
+
+void
+mono_win32_abort_wait (PVOID thread_info, HANDLE native_thread_handle, DWORD tid)
+{
+       request_interrupt (thread_info, native_thread_handle, THREAD_WAIT_INFO_PENDING_ABORT_APC_SLOT, abort_apc, tid);
+}
+
+static inline void
+enter_alertable_wait (MonoThreadInfo *info)
+{
+       // Clear any previous flags. Set alertable wait flag.
+       InterlockedExchange (&info->thread_wait_info, THREAD_WAIT_INFO_ALERTABLE_WAIT_SLOT);
+}
+
+static inline void
+leave_alertable_wait (MonoThreadInfo *info)
+{
+       // Clear any previous flags. Thread is exiting alertable wait state, and info around pending interrupt/abort APC's
+       // can now be discarded as well, thread is out of wait operation and can proceed it's execution.
+       InterlockedExchange (&info->thread_wait_info, THREAD_WAIT_INFO_CLEARED);
+}
+
+DWORD
+mono_win32_sleep_ex (DWORD timeout, BOOL alertable)
+{
+       DWORD result = WAIT_FAILED;
+       MonoThreadInfo *info = mono_thread_info_current_unchecked ();
+
+       if (alertable && info) {
+               enter_alertable_wait (info);
+       }
+
+       result = SleepEx (timeout, alertable);
+
+       // NOTE, leave_alertable_wait should not affect GetLastError but
+       // if changed, GetLastError needs to be preserved and reset before returning.
+       if (alertable && info) {
+               leave_alertable_wait (info);
+       }
+
+       return result;
+}
+
+DWORD
+mono_win32_wait_for_single_object_ex (HANDLE handle, DWORD timeout, BOOL alertable)
+{
+       DWORD result = WAIT_FAILED;
+       MonoThreadInfo *info = mono_thread_info_current_unchecked ();
+
+       if (alertable && info) {
+               enter_alertable_wait (info);
+       }
+
+       result = WaitForSingleObjectEx (handle, timeout, alertable);
+
+       // NOTE, leave_alertable_wait should not affect GetLastError but
+       // if changed, GetLastError needs to be preserved and reset before returning.
+       if (alertable && info) {
+               leave_alertable_wait (info);
+       }
+
+       return result;
+}
+
+DWORD
+mono_win32_wait_for_multiple_objects_ex (DWORD count, CONST HANDLE *handles, BOOL waitAll, DWORD timeout, BOOL alertable)
+{
+       DWORD result = WAIT_FAILED;
+       MonoThreadInfo *info = mono_thread_info_current_unchecked ();
+
+       if (alertable && info) {
+               enter_alertable_wait (info);
+       }
+
+       result = WaitForMultipleObjectsEx (count, handles, waitAll, timeout, alertable);
+
+       // NOTE, leave_alertable_wait should not affect GetLastError but
+       // if changed, GetLastError needs to be preserved and reset before returning.
+       if (alertable && info) {
+               leave_alertable_wait (info);
+       }
+
+       return result;
+}
+
+DWORD
+mono_win32_signal_object_and_wait (HANDLE toSignal, HANDLE toWait, DWORD timeout, BOOL alertable)
+{
+       DWORD result = WAIT_FAILED;
+       MonoThreadInfo *info = mono_thread_info_current_unchecked ();
+
+       if (alertable && info) {
+               enter_alertable_wait (info);
+       }
+
+       result = SignalObjectAndWait (toSignal, toWait, timeout, alertable);
+
+       // NOTE, leave_alertable_wait should not affect GetLastError but
+       // if changed, GetLastError needs to be preserved and reset before returning.
+       if (alertable && info) {
+               leave_alertable_wait (info);
+       }
+
+       return result;
+}
+
+DWORD
+mono_win32_msg_wait_for_multiple_objects_ex (DWORD count, CONST HANDLE *handles, DWORD timeout, DWORD wakeMask, DWORD flags)
+{
+       DWORD result = WAIT_FAILED;
+       MonoThreadInfo *info = mono_thread_info_current_unchecked ();
+       BOOL alertable = flags & MWMO_ALERTABLE;
+
+       if (alertable && info) {
+               enter_alertable_wait (info);
+       }
+
+       result = MsgWaitForMultipleObjectsEx (count, handles, timeout, wakeMask, flags);
+
+       // NOTE, leave_alertable_wait should not affect GetLastError but
+       // if changed, GetLastError needs to be preserved and reset before returning.
+       if (alertable && info) {
+               leave_alertable_wait (info);
+       }
+
+       return result;
+}
+
+DWORD
+mono_win32_wsa_wait_for_multiple_events (DWORD count, const WSAEVENT FAR *handles, BOOL waitAll, DWORD timeout, BOOL alertable)
+{
+       DWORD result = WAIT_FAILED;
+       MonoThreadInfo *info = mono_thread_info_current_unchecked ();
+
+       if (alertable && info) {
+               enter_alertable_wait (info);
+       }
+
+       result = WSAWaitForMultipleEvents (count, handles, waitAll, timeout, alertable);
+
+       // NOTE, leave_alertable_wait should not affect GetLastError but
+       // if changed, GetLastError needs to be preserved and reset before returning.
+       if (alertable && info) {
+               leave_alertable_wait (info);
+       }
+
+       return result;
+}
diff --git a/mono/utils/mono-os-wait.h b/mono/utils/mono-os-wait.h
new file mode 100644 (file)
index 0000000..566ed97
--- /dev/null
@@ -0,0 +1,40 @@
+/**
+* \file
+*/
+
+#ifndef _MONO_UTILS_OS_WAIT_H_
+#define _MONO_UTILS_OS_WAIT_H_
+
+#include <config.h>
+#ifdef HOST_WIN32
+
+#include <winsock2.h>
+#include <windows.h>
+
+DWORD
+mono_win32_sleep_ex (DWORD timeout, BOOL alertable);
+
+DWORD
+mono_win32_wait_for_single_object_ex (HANDLE handle, DWORD timeout, BOOL alertable);
+
+DWORD
+mono_win32_wait_for_multiple_objects_ex (DWORD count, CONST HANDLE *handles, BOOL waitAll, DWORD timeout, BOOL alertable);
+
+DWORD
+mono_win32_signal_object_and_wait (HANDLE toSignal, HANDLE toWait, DWORD timeout, BOOL alertable);
+
+DWORD
+mono_win32_msg_wait_for_multiple_objects_ex (DWORD count, CONST HANDLE *handles, DWORD timeout, DWORD wakeMask, DWORD flags);
+
+DWORD
+mono_win32_wsa_wait_for_multiple_events (DWORD count, const WSAEVENT FAR *handles, BOOL waitAll, DWORD timeout, BOOL alertable);
+
+void
+mono_win32_interrupt_wait (PVOID thread_info, HANDLE native_thread_handle, DWORD tid);
+
+void
+mono_win32_abort_wait (PVOID thread_info, HANDLE native_thread_handle, DWORD tid);
+
+#endif
+
+#endif /* _MONO_UTILS_OS_WAIT_H_ */
index 9ef565ddf9107934b6c77054a3ecc44f5ad2dcb2..563d210e8ed5cfe9ef657e7aba24d77d0f0429cf 100644 (file)
 
 #include <mono/utils/mono-compiler.h>
 #include <mono/utils/mono-threads-debug.h>
+#include <mono/utils/mono-os-wait.h>
 #include <limits.h>
 
-
 void
 mono_threads_suspend_init (void)
 {
 }
 
-static void CALLBACK
-interrupt_apc (ULONG_PTR param)
-{
-}
-
 gboolean
 mono_threads_suspend_begin_async_suspend (MonoThreadInfo *info, gboolean interrupt_kernel)
 {
@@ -57,9 +52,8 @@ mono_threads_suspend_begin_async_suspend (MonoThreadInfo *info, gboolean interru
        info->suspend_can_continue = mono_threads_get_runtime_callbacks ()->thread_state_init_from_handle (&info->thread_saved_state [ASYNC_SUSPEND_STATE_INDEX], info);
        THREADS_SUSPEND_DEBUG ("thread state %p -> %d\n", (void*)id, res);
        if (info->suspend_can_continue) {
-               //FIXME do we need to QueueUserAPC on this case?
                if (interrupt_kernel)
-                       QueueUserAPC ((PAPCFUNC)interrupt_apc, handle, (ULONG_PTR)NULL);
+                       mono_win32_interrupt_wait (info, handle, id);
        } else {
                THREADS_SUSPEND_DEBUG ("FAILSAFE RESUME/2 %p -> %d\n", (void*)info->native_handle, 0);
        }
@@ -74,11 +68,7 @@ mono_threads_suspend_check_suspend_result (MonoThreadInfo *info)
        return info->suspend_can_continue;
 }
 
-static void CALLBACK
-abort_apc (ULONG_PTR param)
-{
-       THREADS_INTERRUPT_DEBUG ("%06d - abort_apc () called", GetCurrentThreadId ());
-}
+
 
 void
 mono_threads_suspend_abort_syscall (MonoThreadInfo *info)
@@ -89,8 +79,7 @@ mono_threads_suspend_abort_syscall (MonoThreadInfo *info)
        handle = OpenThread (THREAD_ALL_ACCESS, FALSE, id);
        g_assert (handle);
 
-       THREADS_INTERRUPT_DEBUG ("%06d - Aborting syscall in thread %06d", GetCurrentThreadId (), id);
-       QueueUserAPC ((PAPCFUNC)abort_apc, handle, (ULONG_PTR)NULL);
+       mono_win32_abort_wait (info, handle, id);
 
        CloseHandle (handle);
 }
@@ -229,19 +218,26 @@ mono_native_thread_create (MonoNativeThreadId *tid, gpointer func, gpointer arg)
        return CreateThread (NULL, 0, (func), (arg), 0, (tid)) != NULL;
 }
 
+gboolean
+mono_native_thread_join_handle (HANDLE thread_handle, gboolean close_handle)
+{
+       DWORD res = WaitForSingleObject (thread_handle, INFINITE);
+
+       if (close_handle)
+               CloseHandle (thread_handle);
+
+       return res != WAIT_FAILED;
+}
+
 gboolean
 mono_native_thread_join (MonoNativeThreadId tid)
 {
        HANDLE handle;
 
-       if (!(handle = OpenThread (THREAD_ALL_ACCESS, TRUE, tid)))
+       if (!(handle = OpenThread (SYNCHRONIZE, TRUE, tid)))
                return FALSE;
 
-       DWORD res = WaitForSingleObject (handle, INFINITE);
-
-       CloseHandle (handle);
-
-       return res != WAIT_FAILED;
+       return mono_native_thread_join_handle (handle, TRUE);
 }
 
 #if HAVE_DECL___READFSDWORD==0
index b95784fa6fd9ebeb5d69a5f94eba78e658ad4809..9a67fb863316e44896f975ef4d8f4e9c5e333367 100644 (file)
@@ -230,6 +230,13 @@ typedef struct {
         * handled a sampling signal before sending another one.
         */
        gint32 profiler_signal_ack;
+
+       gint32 thread_pending_native_join;
+
+#ifdef USE_WINDOWS_BACKEND
+       gint32 thread_wait_info;
+#endif
+
 } MonoThreadInfo;
 
 typedef struct {
index b63ec21a28f1a424f21ac6f1a8525a17395041ba..095669a0e4aebea91650beee4833ef795d97c8ca 100644 (file)
@@ -14,6 +14,7 @@
 #include <winbase.h>
 
 #include "atomic.h"
+#include "mono-os-wait.h"
 
 void
 mono_os_event_init (MonoOSEvent *event, gboolean initial)
@@ -72,7 +73,7 @@ mono_os_event_wait_one (MonoOSEvent *event, guint32 timeout, gboolean alertable)
        g_assert (event);
        g_assert (event->handle);
 
-       res = WaitForSingleObjectEx (event->handle, timeout, alertable);
+       res = mono_win32_wait_for_single_object_ex (event->handle, timeout, alertable);
        if (res == WAIT_OBJECT_0)
                return MONO_OS_EVENT_WAIT_RET_SUCCESS_0;
        else if (res == WAIT_IO_COMPLETION)
@@ -80,7 +81,7 @@ mono_os_event_wait_one (MonoOSEvent *event, guint32 timeout, gboolean alertable)
        else if (res == WAIT_TIMEOUT)
                return MONO_OS_EVENT_WAIT_RET_TIMEOUT;
        else if (res == WAIT_FAILED)
-               g_error ("%s: WaitForSingleObjectEx failed with error %d", __func__, GetLastError ());
+               g_error ("%s: mono_thread_win32_wait_one_handle failed with error %d", __func__, GetLastError ());
        else
                g_error ("%s: unknown res value %d", __func__, res);
 }
@@ -105,7 +106,7 @@ mono_os_event_wait_multiple (MonoOSEvent **events, gsize nevents, gboolean waita
                handles [i] = events [i]->handle;
        }
 
-       res = WaitForMultipleObjectsEx (nevents, handles, waitall, timeout, alertable);
+       res = mono_win32_wait_for_multiple_objects_ex ((DWORD)nevents, handles, waitall, timeout, alertable);
        if (res >= WAIT_OBJECT_0 && res < WAIT_OBJECT_0 + MONO_OS_EVENT_WAIT_MAXIMUM_OBJECTS)
                return MONO_OS_EVENT_WAIT_RET_SUCCESS_0 + (res - WAIT_OBJECT_0);
        else if (res == WAIT_IO_COMPLETION)
@@ -113,7 +114,7 @@ mono_os_event_wait_multiple (MonoOSEvent **events, gsize nevents, gboolean waita
        else if (res == WAIT_TIMEOUT)
                return MONO_OS_EVENT_WAIT_RET_TIMEOUT;
        else if (res == WAIT_FAILED)
-               g_error ("%s: WaitForSingleObjectEx failed with error %d", __func__, GetLastError ());
+               g_error ("%s: mono_thread_win32_wait_multiple_handle failed with error %d", __func__, GetLastError ());
        else
                g_error ("%s: unknown res value %d", __func__, res);
 }
index dedcc4e73cf066ad777e8bc0510f978b65c619a4..8a1e98bb2ee7068e6246e130b186c16abcca09d3 100644 (file)
@@ -20,6 +20,8 @@
 
 #if MONO_HAS_CLANG_THREAD_SANITIZER
 #define MONO_UNLOCKED_ATTRS MONO_NO_SANITIZE_THREAD MONO_NEVER_INLINE static
+#elif defined(_MSC_VER)
+#define MONO_UNLOCKED_ATTRS MONO_ALWAYS_INLINE static
 #else
 #define MONO_UNLOCKED_ATTRS MONO_ALWAYS_INLINE static inline
 #endif
@@ -122,4 +124,11 @@ UnlockedReadBool (gboolean *src)
        return *src;
 }
 
+MONO_UNLOCKED_ATTRS
+gpointer
+UnlockedReadPointer (volatile gpointer *src)
+{
+       return *src;
+}
+
 #endif /* _UNLOCKED_H_ */
index 554e61985bdb1745ac9df6d44d0c7d1423bdd6f3..ce8d2a1b1b14988b46efe31fc602ae100a5828fa 100644 (file)
     <ClInclude Include="..\mono\metadata\cominterop-win32-internals.h">\r
       <Filter>Header Files</Filter>\r
     </ClInclude>\r
+    <ClInclude Include="..\mono\metadata\appdomain-icalls.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Filter Include="Header Files">\r
index 350a54654e475e39aa163f1c125cbaff0c19b47b..beba4278b8e64cf515143a124e9b3f5b39c13b94 100644 (file)
@@ -1,4 +1,4 @@
-<?xml version="1.0" encoding="utf-8"?>\r
+<?xml version="1.0" encoding="utf-8"?>\r
 <Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">\r
   <ItemGroup Label="ProjectConfigurations">\r
     <ProjectConfiguration Include="Debug|Win32">\r
@@ -68,6 +68,7 @@
     <ClCompile Include="..\mono\utils\mono-mmap-windows.c" />\r
     <ClCompile Include="..\mono\utils\mono-mmap.c" />\r
     <ClCompile Include="..\mono\utils\mono-networkinterfaces.c" />\r
+    <ClCompile Include="..\mono\utils\mono-os-wait-win32.c" />\r
     <ClCompile Include="..\mono\utils\mono-proclib-windows.c" />\r
     <ClCompile Include="..\mono\utils\mono-rand-windows.c" />\r
     <ClCompile Include="..\mono\utils\mono-rand.c" />\r
     <ClInclude Include="..\mono\utils\mono-once.h" />\r
     <ClInclude Include="..\mono\utils\mono-os-mutex.h" />\r
     <ClInclude Include="..\mono\utils\mono-os-semaphore.h" />\r
+    <ClInclude Include="..\mono\utils\mono-os-wait.h" />\r
     <ClInclude Include="..\mono\utils\mono-path.h" />\r
     <ClInclude Include="..\mono\utils\mono-poll.h" />\r
     <ClInclude Include="..\mono\utils\mono-proclib-windows-internals.h" />\r
     <ClInclude Include="..\mono\utils\strenc.h" />\r
     <ClInclude Include="..\mono\utils\valgrind.h" />\r
     <ClInclude Include="..\mono\utils\atomic.h" />\r
-    <ClInclude Include="..\mono\utils\unlocked.h" />
+    <ClInclude Include="..\mono\utils\unlocked.h" />\r
     <ClInclude Include="..\mono\utils\mono-hwcap.h" />\r
     <ClInclude Include="..\mono\utils\mono-hwcap-x86.h" />\r
     <ClInclude Include="..\mono\utils\bsearch.h" />\r
index 30badee3648d03e88c2a0eec33f164a87902f672..e4b82690a1821a115451b8f47e75ab4f9aecaa44 100644 (file)
     <ClCompile Include="..\mono\utils\mono-threads-mach.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="..\mono\utils\mono-threads-mach-abort-syscall.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
     <ClCompile Include="..\mono\utils\mono-threads-posix.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="..\mono\utils\mono-threads-posix-abort-syscall.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
     <ClCompile Include="..\mono\utils\mono-threads-posix-signals.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="..\mono\utils\mono-threads-windows.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
-    <ClCompile Include="..\mono\utils\mono-threads-windows-abort-syscall.c">\r
-      <Filter>Source Files</Filter>\r
-    </ClCompile>\r
     <ClCompile Include="..\mono\utils\mono-time.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
     <ClCompile Include="..\mono\utils\os-event-win32.c">\r
       <Filter>Source Files</Filter>\r
     </ClCompile>\r
+    <ClCompile Include="..\mono\utils\mono-os-mutex.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
+    <ClCompile Include="..\mono\utils\mono-os-wait-win32.c">\r
+      <Filter>Source Files</Filter>\r
+    </ClCompile>\r
   </ItemGroup>\r
   <ItemGroup>\r
     <ClInclude Include="..\mono\utils\atomic.h">\r
     <ClInclude Include="..\mono\utils\mono-threads-coop.h">\r
       <Filter>Header Files</Filter>\r
     </ClInclude>\r
-    <ClInclude Include="..\mono\utils\mono-threads-posix-signals.h">\r
-      <Filter>Header Files</Filter>\r
-    </ClInclude>\r
     <ClInclude Include="..\mono\utils\mono-time.h">\r
       <Filter>Header Files</Filter>\r
     </ClInclude>\r
     <ClInclude Include="..\mono\utils\os-event.h">\r
       <Filter>Header Files</Filter>\r
     </ClInclude>\r
-    <ClInclude Include="..\mono\utils\unlocked.h">
-      <Filter>Header Files</Filter>
-    </ClInclude>
+    <ClInclude Include="..\mono\utils\unlocked.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
+    <ClInclude Include="..\mono\utils\mono-os-wait.h">\r
+      <Filter>Header Files</Filter>\r
+    </ClInclude>\r
   </ItemGroup>\r
   <ItemGroup>\r
     <Filter Include="Header Files">\r
index c60bc5397ce28ad027f8856df3061ebfad69d4f6..96337cadaaff450ce4e4e274987a19063fbedc2b 100644 (file)
@@ -794,12 +794,8 @@ class MsbuildGenerator {
 
                var refs = new StringBuilder ();
 
-               bool is_test = response.Contains ("_test_");
-               if (is_test) {
-                       // F:\src\mono\mcs\class\lib\net_2_0\nunit.framework.dll
-                       // F:\src\mono\mcs\class\SomeProject\SomeProject_test_-net_2_0.csproj
-                       var nunitLibPath = string.Format (@"..\lib\{0}\nunit.framework.dll", profile);
-                       refs.Append (string.Format ("    <Reference Include=\"{0}\" />" + NewLine, nunitLibPath));
+               if (response.Contains ("_test")) {
+                       refs.Append ($@"    <Reference Include=""..\lib\{profile}\nunitlite.dll"" />{NewLine}");
                }
 
                //
@@ -1049,7 +1045,7 @@ class MsbuildGenerator {
 
 public class Driver {
 
-       static IEnumerable<XElement> GetProjects (bool full = false)
+       static IEnumerable<XElement> GetProjects (bool withTests = false)
        {
                XDocument doc = XDocument.Load ("order.xml");
                foreach (XElement project in doc.Root.Elements ()) {
@@ -1071,12 +1067,6 @@ public class Driver {
                        //
                        if (!(dir.StartsWith ("class") || dir.StartsWith ("mcs") || dir.StartsWith ("basic")))
                                continue;
-
-                       if (full){
-                               if (!library.Contains ("tests"))
-                                       yield return project;
-                               continue;
-                       }
 #endif
                        //
                        // Do not do 2.1, it is not working yet
@@ -1094,11 +1084,12 @@ public class Driver {
                        if (dir.Contains ("nunit20"))
                                continue;
                        
-#if true
-                       if (profile != "net_4_x" || library.Contains ("tests")) 
+                       if (library.Contains ("tests") && !withTests)
                                continue;
-#endif
-                       //Console.WriteLine ("Going to handle {0}", library);
+
+                       if (profile != "net_4_x")
+                               continue;
+
                        yield return project;
                }
        }
@@ -1112,12 +1103,12 @@ public class Driver {
 
                if (args.Length == 1 && args [0].ToLower ().Contains ("-h")) {
                        Console.WriteLine ("Usage:");
-                       Console.WriteLine ("genproj.exe [visual_studio_release] [output_full_solutions]");
+                       Console.WriteLine ("genproj.exe [visual_studio_release] [output_full_solutions] [with_tests]");
                        Console.WriteLine ("If output_full_solutions is false, only the main System*.dll");
                        Console.WriteLine (" assemblies (and dependencies) is included in the solution.");
                        Console.WriteLine ("Example:");
-                       Console.WriteLine ("genproj.exe 2012 false");
-                       Console.WriteLine ("genproj.exe with no arguments is equivalent to 'genproj.exe 2012 true'\n\n");
+                       Console.WriteLine ("genproj.exe 2012 false false");
+                       Console.WriteLine ("genproj.exe with no arguments is equivalent to 'genproj.exe 2012 true false'\n\n");
                        Console.WriteLine ("genproj.exe deps");
                        Console.WriteLine ("Generates a Makefile dependency file from the projects input");
                        Environment.Exit (0);
@@ -1125,6 +1116,7 @@ public class Driver {
 
                var slnVersion = (args.Length > 0) ? args [0] : "2012";
                bool fullSolutions = (args.Length > 1) ? bool.Parse (args [1]) : true;
+               bool withTests = (args.Length > 2) ? bool.Parse (args [2]) : false;
 
                // To generate makefile depenedencies
                var makefileDeps =  (args.Length > 0 && args [0] == "deps");
@@ -1134,11 +1126,11 @@ public class Driver {
                var projects = new Dictionary<string,MsbuildGenerator> ();
 
                var duplicates = new List<string> ();
-               foreach (var project in GetProjects (makefileDeps)) {
+               foreach (var project in GetProjects (withTests)) {
                        var library_output = project.Element ("library_output").Value;
                        projects [library_output] = new MsbuildGenerator (project);
                }
-               foreach (var project in GetProjects (makefileDeps)){
+               foreach (var project in GetProjects (withTests)){
                        var library_output = project.Element ("library_output").Value;
                        //Console.WriteLine ("=== {0} ===", library_output);
                        var gen = projects [library_output];
index f2e7a9bcdb6fc2e4362f257c8ae9ae5ed4470ad6..4de097b5dc750879ef38fa79219b163cf5911a00 100644 (file)
@@ -8,7 +8,7 @@ class FsharpPackage(GitHubTarballPackage):
             override_properties={ 'make': 'make' })
 
         self.extra_stage_files = ['lib/mono/xbuild/Microsoft/VisualStudio/v/FSharp/Microsoft.FSharp.Targets']
-        self.sources.extend(['patches/fsharp-portable-pdb.patch', 'patches/fsharp-metadata-table-size-fix.patch'])
+        self.sources.extend(['patches/fsharp-portable-pdb.patch', 'patches/fsharp-metadata-table-size-fix.patch', 'patches/fsharp-install-netsdk-targets.patch'])
 
     def prep(self):
         Package.prep(self)
index 0eb54930aa06a576dfb14e9f8f3d4317f847168f..e769cf22bb5269e0fc8cffd2b6f009b4cf16b912 100644 (file)
@@ -3,7 +3,7 @@ import fileinput
 class MSBuild (GitHubPackage):
        def __init__ (self):
                GitHubPackage.__init__ (self, 'mono', 'msbuild', '15.4',
-                       revision = 'c907a5182a101624eb58e73fb24f97666abf477a')
+                       revision = '8b76a1d2b9ffc493349a861962e44540ea14eaac')
 
        def build (self):
                self.sh ('./cibuild.sh --scope Compile --target Mono --host Mono --config Release')
diff --git a/packaging/MacSDK/patches/fsharp-install-netsdk-targets.patch b/packaging/MacSDK/patches/fsharp-install-netsdk-targets.patch
new file mode 100644 (file)
index 0000000..796a007
--- /dev/null
@@ -0,0 +1,47 @@
+From 066a39a0ccd98222a0e372a443e59e28182def50 Mon Sep 17 00:00:00 2001
+From: nosami <jasonimison@gmail.com>
+Date: Thu, 14 Sep 2017 18:54:49 +0100
+Subject: [PATCH] Install Microsoft.FSharp.NetSdk.props and targets into Mono
+
+So that F# .NET Core 2.0 templates can be built with VS for Mac and
+Mono msbuild. Re: https://bugzilla.xamarin.com/show_bug.cgi?id=57771
+
+Searching the .NET Core sdk files we see:
+
+/Sdks/Microsoft.NET.Sdk/build/Microsoft.NET.Sdk.FSharp.props:
+
+```
+<FSharpPropsShim Condition = " '$(FSharpPropsShim)' == '' and Exists('$(MSBuildToolsPath)\FSharp\Microsoft.FSharp.NetSdk.props') ">$(MSBuildToolsPath)\FSharp\Microsoft.FSharp.NetSdk.props</FSharpPropsShim>
+
+<FSharpPropsShim Condition = " '$(FSharpPropsShim)' == '' and Exists('$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.NetSdk.props') ">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.NetSdk.props</FSharpPropsShim>
+
+<Import Condition=" '$(UseBundledFSharpTargets)' == 'true' and
+  Exists('$(FSharpPropsShim)') " Project="$(FSharpPropsShim)" />
+```
+---
+ mono/config.make.in | 12 ++++++++++++
+ 1 file changed, 12 insertions(+)
+
+diff --git a/mono/config.make.in b/mono/config.make.in
+index 6249aca46..573717208 100644
+--- a/mono/config.make.in
++++ b/mono/config.make.in
+@@ -194,6 +194,18 @@ install-sdk-lib:
+           $(INSTALL_LIB) $(tmpdir)Microsoft.Portable.FSharp.Targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v12.0/FSharp/; \
+           $(INSTALL_LIB) $(tmpdir)Microsoft.Portable.FSharp.Targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v14.0/FSharp/; \
+           $(INSTALL_LIB) $(tmpdir)Microsoft.Portable.FSharp.Targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v15.0/FSharp/; \
++          \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.props $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.props $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v11.0/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.props $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v12.0/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.props $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v14.0/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.props $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v15.0/FSharp/; \
++          \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v11.0/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v12.0/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v14.0/FSharp/; \
++          $(INSTALL_LIB) $(outdir)Microsoft.FSharp.NetSdk.targets $(DESTDIR)$(monodir)/xbuild/Microsoft/VisualStudio/v15.0/FSharp/; \
+       fi
+       @if test x-$(outsuffix) = x-net40; then \
+           if test -e $(outdir)$(NAME).dll; then \
index 5188f37291151780129e4e1fb41e9f4d9393f9ad..021fdae9424c4116bf85ff3410095456daf6b838 100644 (file)
@@ -7,6 +7,10 @@
 fun:monoeg_g_hash_table_iter_next
 fun:monoeg_g_hash_table_lookup_extended
 
+# gslist.c #
+
+fun:monoeg_g_slist_nth_data
+
 # sort.frag.h #
 
 fun:init_sort_info
@@ -19,16 +23,19 @@ fun:merge_lists
 
 # class-accessors.c #
 
+fun:mono_class_get_field_count
 fun:mono_class_get_first_method_idx
 fun:mono_class_get_flags
 fun:mono_class_get_generic_class
 fun:mono_class_get_method_count
 fun:mono_class_get_field_count
 fun:mono_class_set_first_method_idx
+fun:mono_class_set_flags
 fun:mono_class_set_method_count
 
 # class-inlines.h #
 
+fun:mono_class_has_static_metadata
 fun:mono_class_is_ginst
 fun:mono_class_is_gtd
 
@@ -44,10 +51,13 @@ fun:inflate_generic_context
 fun:inflate_generic_type
 fun:init_sizes_with_info
 fun:make_generic_param_class
+fun:mono_array_element_size
 fun:mono_bounded_array_class_get
 fun:mono_class_create_from_typedef
+fun:mono_class_enum_basetype
 fun:mono_class_from_generic_parameter_internal
 fun:mono_class_from_mono_type
+fun:mono_class_from_name_checked_aux
 fun:mono_class_get_cctor
 fun:mono_class_get_inflated_method
 fun:mono_class_get_method_from_name_flags
@@ -56,6 +66,7 @@ fun:mono_class_get_vtable_entry
 fun:mono_class_has_failure
 fun:mono_class_has_finalizer
 fun:mono_class_inflate_generic_method_full_checked
+fun:mono_class_inflate_generic_type_with_mempool
 fun:mono_class_init
 fun:mono_class_instance_size
 fun:mono_class_is_assignable_from
@@ -64,22 +75,23 @@ fun:mono_class_setup_basic_field_info
 fun:mono_class_setup_fields
 fun:mono_class_setup_interfaces
 fun:mono_class_setup_methods
+fun:mono_class_setup_mono_type
+fun:mono_class_setup_parent
 fun:mono_class_setup_supertypes
 fun:mono_class_setup_vtable_full
 fun:mono_class_setup_vtable_general
+fun:mono_class_value_size
+fun:mono_field_get_type_checked
 fun:mono_field_resolve_type
 fun:mono_generic_class_get_class
+fun:mono_ldtoken_checked
 fun:mono_method_get_context_general
 fun:mono_method_get_method_definition
-fun:mono_ptr_class_get
 fun:mono_type_get_basic_type_from_generic
+fun:mono_type_get_checked
 fun:mono_type_get_underlying_type
 fun:mono_type_has_exceptions
 
-# domain.c #
-
-fun:mono_domain_alloc0
-
 # gc.c #
 
 fun:finalize_domain_objects
@@ -100,19 +112,18 @@ fun:mono_stack_mark_pop
 
 # icall.c #
 
+fun:is_generic_parameter
 fun:vell_icall_get_method_attributes
 fun:ves_icall_InternalInvoke
+fun:ves_icall_RuntimeTypeHandle_GetBaseType
+fun:ves_icall_RuntimeTypeHandle_HasInstantiation
 fun:ves_icall_RuntimeTypeHandle_IsArray
+fun:ves_icall_RuntimeTypeHandle_IsGenericVariable
 fun:ves_icall_RuntimeType_GetConstructors_native
+fun:ves_icall_System_Array_ClearInternal
 fun:ves_icall_System_Array_FastCopy
 fun:ves_icall_System_Reflection_MonoMethodInfo_get_parameter_info
 
-# image.c #
-
-fun:mono_image_alloc
-fun:mono_image_alloc0
-fun:mono_image_strdup
-
 # jit-info.c #
 
 fun:jit_info_table_add
@@ -122,40 +133,51 @@ fun:jit_info_table_find
 fun:jit_info_table_index
 fun:jit_info_table_split_chunk
 fun:mono_jit_info_init
+fun:mono_jit_info_table_free
 
 # loader.c #
 
-fun:cache_memberref_sig
 fun:inflate_generic_signature_checked
+fun:mono_field_from_token_checked
+fun:mono_get_method_checked
 fun:mono_get_method_from_token
-fun:mono_method_get_signature_checked
+fun:mono_method_get_header_checked
 fun:mono_method_signature_checked
 
 # marshal.c #
 
 fun:mono_icall_start
 fun:mono_marshal_get_native_wrapper
+fun:mono_marshal_get_runtime_invoke_full
 fun:mono_marshal_isinst_with_cache
 
 # metadata.c #
 
 fun:_mono_metadata_generic_class_equal
+fun:add_image
+fun:collect_data_init
+fun:collect_ginst_images
 fun:collect_method_images
+fun:collect_type_images
 fun:do_mono_metadata_parse_type
-fun:img_set_cache_get
+fun:get_image_set
 fun:mono_metadata_decode_row
 fun:mono_metadata_get_canonical_generic_inst
 fun:mono_metadata_lookup_generic_class
+fun:mono_metadata_parse_mh_full
 fun:mono_metadata_parse_type_internal
+fun:mono_method_get_header_summary
 fun:mono_type_get_class
 fun:mono_type_get_type
 fun:mono_type_is_struct
+fun:typedef_locator
 
 # monitor.c #
 
 fun:mon_new
 fun:mono_monitor_ensure_owned
 fun:mono_monitor_enter_v4_fast
+fun:mono_monitor_exit
 fun:mono_monitor_exit_inflated
 fun:mono_monitor_inflate
 fun:mono_monitor_try_enter_inflated
@@ -166,8 +188,15 @@ fun:ves_icall_System_Threading_Monitor_Monitor_test_synchronised
 fun:ves_icall_System_Threading_Monitor_Monitor_try_enter_with_atomic_var
 fun:ves_icall_System_Threading_Monitor_Monitor_wait
 
+# mono-basic-block.c #
+
+fun:bb_formation_il_pass
+fun:mono_basic_block_split
+fun:mono_opcode_value_and_size
+
 # mono-conc-hash.c #
 
+fun:conc_table_new
 fun:expand_table
 fun:mono_conc_g_hash_table_lookup_extended
 fun:set_key
@@ -178,13 +207,17 @@ fun:mono_g_hash_table_find_slot
 
 # object.c #
 
+fun:class_get_virtual_method
 fun:mono_class_compute_gc_descriptor
 fun:mono_class_create_runtime_vtable
+fun:mono_class_try_get_vtable
 fun:mono_class_vtable_full
+fun:mono_delegate_ctor_with_method
 fun:mono_object_handle_get_virtual_method
 fun:mono_object_handle_isinst
 fun:mono_object_isinst_checked
 fun:mono_object_new_alloc_specific_checked
+fun:mono_object_new_mature
 fun:mono_object_new_specific_checked
 fun:mono_runtime_class_init_full
 fun:mono_runtime_invoke_array_checked
@@ -198,26 +231,23 @@ fun:cache_object_handle
 # reflection.c #
 
 fun:method_object_construct
+fun:mono_type_get_object_checked
 fun:reflected_equal
 
-# runtime.c #
-
-fun:mono_runtime_is_shutting_down
-fun:mono_runtime_try_shutdown
-
 # sgen-client-mono.h #
 
+fun:sgen_client_par_object_get_size
 fun:SGEN_LOAD_VTABLE_UNCHECKED
+fun:sgen_mono_array_size
 
 # sgen-mono.c #
 
 fun:mono_gchandle_free
 fun:mono_gc_alloc_string
 fun:mono_gc_alloc_vector
+fun:mono_gc_get_nursery
 fun:mono_gc_thread_in_critical_region
 fun:mono_gc_wbarrier_set_arrayref
-fun:sgen_client_gchandle_created
-fun:sgen_client_gchandle_destroyed
 
 # threadpool-worker-default.c #
 
@@ -228,8 +258,8 @@ fun:hill_climbing_change_thread_count
 fun:hill_climbing_force_change
 fun:hill_climbing_update
 fun:monitor_should_keep_running
-fun:monitor_thread
 fun:monitor_sufficient_delay_since_last_dequeue
+fun:monitor_thread
 
 # threadpool.c #
 
@@ -241,10 +271,9 @@ fun:worker_callback
 fun:build_wait_tids
 fun:create_thread
 fun:mono_thread_clr_state
+fun:mono_thread_create_internal
 fun:mono_thread_detach_internal
 fun:mono_thread_set_name_internal
-fun:mono_threads_add_joinable_thread
-fun:mono_threads_join_threads
 fun:remove_and_abort_threads
 fun:request_thread_abort
 
@@ -262,17 +291,36 @@ fun:mono_w32handle_unref_core
 
 # alias-analysis.c #
 
-fun:recompute_aliased_variables
+fun:lower_memory_access
 
 # aot-runtime.c #
 
 fun:mono_aot_get_cached_class_info
+fun:mono_aot_get_method_checked
 fun:mono_aot_get_method_from_vt_slot
 
+# branch-opts.c #
+
+fun:mono_if_conversion
+fun:mono_optimize_branches
+
+# cfold.c #
+
+fun:mono_constant_fold_ins
+
 # decompose.c #
 
 fun:mono_decompose_vtype_opts
 
+# dominators.c #
+
+fun:compute_dominators
+fun:mono_compute_natural_loops
+
+# jit-icalls.c #
+
+fun:ldvirtfn_internal
+
 # linear-scan.c #
 
 fun:mono_linear_scan
@@ -282,27 +330,56 @@ fun:mono_linear_scan
 fun:mono_analyze_liveness
 fun:mono_liveness_handle_exception_clauses
 
+# lldb.c #
+
+fun:mono_lldb_save_method_info
+
+# local-propagation.c #
+
+fun:mono_local_cprop
+fun:mono_local_deadce
+
+# memory-access.c #
+
+fun:mini_emit_memory_copy_internal
+
 # method-to-ir.c #
 
 fun:check_call_signature
+fun:check_method_sharing
 fun:emit_init_rvar
+fun:emit_stloc_ir
+fun:get_basic_blocks
 fun:inline_method
+fun:link_bblock
+fun:mini_emit_inst_for_method
+fun:mini_field_access_needs_cctor_run
+fun:mono_emit_call_args
+fun:mono_emit_method_call_full
+fun:mono_handle_global_vregs
 fun:mono_method_check_inlining
 fun:mono_method_to_ir
 fun:mono_spill_global_vars
+fun:target_type_is_incompatible
 
 # mini-amd64.c #
 
+fun:add_outarg_reg
 fun:get_call_info
-fun:mono_arch_allocate_vars
+fun:mono_arch_emit_call
 fun:mono_arch_emit_epilog
+fun:mono_arch_emit_exceptions
+fun:mono_arch_emit_inst_for_method
+fun:mono_arch_emit_outarg_vt
 fun:mono_arch_emit_prolog
 fun:mono_arch_get_delegate_invoke_impl
 fun:mono_arch_lowering_pass
+fun:mono_arch_output_basic_block
 fun:mono_arch_peephole_pass_2
 
 # mini-codegen.c #
 
+fun:create_spilled_store
 fun:mono_local_regalloc
 fun:mono_peephole_ins
 
@@ -312,7 +389,6 @@ fun:mono_thread_state_init_from_sigctx
 
 # mini-generic-sharing.c #
 
-fun:alloc_template
 fun:class_get_rgctx_template_oti
 fun:get_info_templates
 fun:inflate_info
@@ -321,6 +397,7 @@ fun:mini_get_basic_type_from_generic
 fun:mini_is_gsharedvt_type
 fun:mini_type_get_underlying_type
 fun:mono_class_fill_runtime_generic_context
+fun:mono_class_get_method_generic
 fun:mono_generic_context_check_used
 fun:mono_method_check_context_used
 fun:mono_method_fill_runtime_generic_context
@@ -339,17 +416,19 @@ fun:mini_native_type_replace_type
 fun:create_runtime_invoke_info
 fun:mini_imt_entry_inited
 fun:mono_jit_compile_method_with_opt
-fun:mono_jit_find_compiled_method_with_jit_info
 fun:mono_jit_runtime_invoke
+fun:mono_resolve_patch_target
 
 # mini-trampolines.c #
 
 fun:common_call_trampoline
+fun:is_generic_method_definition
 fun:mini_add_method_trampoline
 fun:mini_resolve_imt_method
 fun:mono_create_delegate_trampoline_info
 fun:mono_create_jit_trampoline
 fun:mono_create_jump_trampoline
+fun:mono_create_static_rgctx_trampoline
 fun:mono_delegate_trampoline
 fun:mono_magic_trampoline
 fun:mono_rgctx_lazy_fetch_trampoline
@@ -357,15 +436,19 @@ fun:mono_vcall_trampoline
 
 # mini.c #
 
+fun:create_jit_info
 fun:mini_method_compile
 fun:mono_allocate_stack_slots
+fun:mono_bb_ordering
 fun:mono_codegen
 fun:mono_compile_create_vars
+fun:mono_compile_create_var_for_vreg
+fun:mono_handle_out_of_line_bblock
 fun:mono_insert_branches_between_bblocks
 fun:mono_jit_compile_method_inner
-fun:mono_time_track_end
 fun:mono_type_to_load_membase
 fun:mono_type_to_store_membase
+fun:mono_unlink_bblock
 
 # seq-points.c #
 
@@ -373,6 +456,7 @@ fun:mono_save_seq_point_info
 
 # tramp-amd64.c #
 
+fun:mono_arch_create_specific_trampoline
 fun:mono_arch_patch_callsite
 
 # unwind.c #
@@ -401,11 +485,16 @@ fun:sgen_array_list_bucketize
 # sgen-cardtable.c #
 
 fun:sgen_card_table_wbarrier_range_copy
+fun:sgen_get_card_table_configuration
 
 # sgen-cardtable.h #
 
 fun:sgen_card_table_mark_address
 
+# sgen-copy-object.h #
+
+fun:copy_object_no_checks
+
 # sgen-fin-weak-hash.c #
 
 fun:add_stage_entry
@@ -413,6 +502,8 @@ fun:add_stage_entry
 # sgen-gc.c #
 
 fun:mono_gc_wbarrier_generic_store
+fun:pin_objects_from_nursery_pin_queue
+fun:sgen_conservatively_pin_objects_from
 
 # sgen-gc.h #
 
@@ -422,22 +513,32 @@ fun:sgen_set_nursery_scan_start
 
 fun:is_slot_set
 fun:link_get
+fun:sgen_gchandle_free
 fun:sgen_gchandle_iterate
 
 # sgen-marksweep.c #
 
+fun:alloc_obj
 fun:ensure_block_is_checked_for_sweeping
 fun:ensure_can_access_block_free_list
 fun:major_finish_sweep_checking
+fun:ms_alloc_block
 fun:set_block_state
 fun:sweep_block
 fun:sweep_block_for_size
 fun:unlink_slot_from_free_list_uncontested
 
+# sgen-minor-copy-object.h #
+
+fun:simple_nursery_serial_copy_object_from_obj
+
 # sgen-nursery-allocator.c #
 
+fun:fragment_list_reverse
+fun:par_alloc_from_fragment
 fun:sgen_fragment_allocator_add
 fun:sgen_fragment_allocator_alloc
+fun:sgen_fragment_allocator_par_alloc
 fun:sgen_fragment_allocator_par_range_alloc
 fun:sgen_fragment_allocator_release
 
@@ -451,6 +552,10 @@ fun:is_pointer_hazardous
 fun:mono_get_hazardous_pointer
 fun:mono_thread_small_id_alloc
 
+# lock-free-alloc.c #
+
+fun:alloc_from_new_sb
+
 # lock-free-array-queue.c #
 
 fun:mono_lock_free_array_queue_pop
@@ -461,8 +566,13 @@ fun:mono_lock_free_array_queue_push
 fun:mono_gc_bzero_aligned
 fun:mono_gc_memmove_aligned
 
+# mono-codeman.c #
+
+fun:mono_code_manager_reserve_align
+
 # mono-conc-hashtable.c #
 
+fun:conc_table_new
 fun:expand_table
 fun:mono_conc_hashtable_insert
 fun:mono_conc_hashtable_lookup
index b197c84e1699648515537dd447a8b2c6955d2d2d..635cef72d174bece12439df64b93557878f1a098 100644 (file)
@@ -1177,10 +1177,13 @@ namespace Mono.Tools.LocaleBuilder
                                if (el != null)
                                        ni.PositiveSign = el.InnerText;
 
+                               // CLDR uses unicode negative sign for some culture (e.g sv, is, lt, don't kwnow why) but .NET always
+                               // uses simple "-" sign and what is worse the parsing code cannot deal with non-ASCII values
+                               ni.NegativeSign = "-";
+
+                               /*
                                el = node.SelectSingleNode ("minusSign");
                                if (el != null) {
-                                       // CLDR uses unicode negative sign for some culture (e.g sv, is, lt, don't kwnow why) but .net always
-                                       // uses simple - sign
                                        switch (el.InnerText) {
                                        case "\u2212":
                                        case "\u200F\u002D": // Remove any right-to-left mark characters
@@ -1194,7 +1197,7 @@ namespace Mono.Tools.LocaleBuilder
                                                break;
                                        }
                                }
-
+                               */
                                el = node.SelectSingleNode ("infinity");
 
                                // We cannot use the value from CLDR because many broken
index 14186f12383ac2aa595080388af0b197617fab08..909fbc1d42f2f1e9b471e70e55b10ff17122cee6 100644 (file)
@@ -41,7 +41,7 @@ minimal: locale-builder.exe locale-data
        $(RUNTIME) locale-builder.exe --locales '$(MINIMAL_LOCALES)'
 
 locale-data:
-       if ! test -d CLDR/common ; then \
+       if ! test -e CLDR/common/supplemental/supplementalData.xml ; then \
                curl http://www.unicode.org/Public/cldr/30.0.2/core.zip -o core.zip ; \
                unzip core.zip -d CLDR ; \
        fi
index 7a2776c851421bcac377310c5bf2ac9627e7335c..788704a9cb9498fe3da408bed3daa0fb7d355f47 100644 (file)
@@ -28,3 +28,8 @@ pedump_LDADD =                        \
 if HOST_DARWIN
 pedump_LDFLAGS=-framework CoreFoundation -framework Foundation
 endif
+
+#Helper target to rebuild metadata as well, it's useful when working on the verifier as its source still on metadata
+md:
+       make -C ../../mono/metadata all
+       make -C . all
\ No newline at end of file