From e747ac15906621a75d97f4d2cb7437e01ce1ae6d Mon Sep 17 00:00:00 2001 From: "Xamarin Public Jenkins (auto-signing)" Date: Sat, 30 Jun 2018 08:22:57 +0000 Subject: [PATCH] Imported Upstream version 5.14.0.156 Former-commit-id: ce0a73a36728a56d19f47892a92fda2d0d642f64 --- configure.REMOVED.git-id | 2 +- configure.ac.REMOVED.git-id | 2 +- .../linker/linker/Linker.Steps/MarkStep.cs | 159 +++++++++++++++++- .../linker/Linker.Steps/ResolveFromXmlStep.cs | 5 + .../linker/linker/Linker.Steps/SweepStep.cs | 6 +- external/linker/linker/Linker/Driver.cs | 32 +++- external/linker/linker/Linker/LinkContext.cs | 19 ++- .../linker/Linker/TypeReferenceExtensions.cs | 5 + mcs/build/common/Consts.cs | 2 +- mcs/build/tests.make | 9 +- .../Mono.Security.dll.REMOVED.git-id | 2 +- .../System.Configuration.dll.REMOVED.git-id | 2 +- .../System.Numerics.dll.REMOVED.git-id | 2 +- .../System.Security.dll.REMOVED.git-id | 2 +- .../1051400003/System.Xml.dll.REMOVED.git-id | 2 +- .../1051400003/mcs.exe.REMOVED.git-id | 2 +- .../1051400003/mscorlib.dll.REMOVED.git-id | 2 +- .../Mono.Security.dll.REMOVED.git-id | 2 +- .../System.Configuration.dll.REMOVED.git-id | 2 +- .../System.Numerics.dll.REMOVED.git-id | 2 +- .../System.Security.dll.REMOVED.git-id | 2 +- .../1051400003/System.Xml.dll.REMOVED.git-id | 2 +- .../1051400003/mcs.exe.REMOVED.git-id | 2 +- .../1051400003/mscorlib.dll.REMOVED.git-id | 2 +- .../Mono.Security.dll.REMOVED.git-id | 2 +- .../System.Configuration.dll.REMOVED.git-id | 2 +- .../System.Numerics.dll.REMOVED.git-id | 2 +- .../System.Security.dll.REMOVED.git-id | 2 +- .../1051400003/System.Xml.dll.REMOVED.git-id | 2 +- .../1051400003/mcs.exe.REMOVED.git-id | 2 +- .../1051400003/mscorlib.dll.REMOVED.git-id | 2 +- mono/mini/interp/transform.c.REMOVED.git-id | 2 +- mono/mini/mini.c.REMOVED.git-id | 2 +- mono/mini/objects.cs | 16 ++ mono/mini/version.h | 2 +- mono/utils/mono-merp.c | 13 +- po/mcs/de.gmo | Bin 5406 -> 5406 bytes po/mcs/de.po.REMOVED.git-id | 2 +- po/mcs/es.gmo | Bin 16329 -> 16329 bytes po/mcs/es.po.REMOVED.git-id | 2 +- po/mcs/ja.gmo | Bin 20863 -> 20863 bytes po/mcs/ja.po.REMOVED.git-id | 2 +- po/mcs/mcs.pot | 4 +- po/mcs/pt_BR.gmo | Bin 72806 -> 72806 bytes po/mcs/pt_BR.po.REMOVED.git-id | 2 +- 45 files changed, 271 insertions(+), 59 deletions(-) diff --git a/configure.REMOVED.git-id b/configure.REMOVED.git-id index e989f30700..76d8487add 100644 --- a/configure.REMOVED.git-id +++ b/configure.REMOVED.git-id @@ -1 +1 @@ -e789bf066e17b66380a6d80f845e05195c813c63 \ No newline at end of file +e94257dd53848925d89adc796d930eb14b964280 \ No newline at end of file diff --git a/configure.ac.REMOVED.git-id b/configure.ac.REMOVED.git-id index 71c5002309..f8a0e01d19 100644 --- a/configure.ac.REMOVED.git-id +++ b/configure.ac.REMOVED.git-id @@ -1 +1 @@ -af067b29dfbfeb81540f1127a7bd9613dd7b0bfa \ No newline at end of file +e3c358a667ccdb5f92cd6fd71f750b3abb8359c5 \ No newline at end of file diff --git a/external/linker/linker/Linker.Steps/MarkStep.cs b/external/linker/linker/Linker.Steps/MarkStep.cs index e74382f53d..f93c75bf18 100644 --- a/external/linker/linker/Linker.Steps/MarkStep.cs +++ b/external/linker/linker/Linker.Steps/MarkStep.cs @@ -253,6 +253,10 @@ namespace Mono.Linker.Steps { Tracer.Push (provider); try { foreach (CustomAttribute ca in provider.CustomAttributes) { + if (IsUserDependencyMarker (ca.AttributeType)) { + MarkUserDependency (provider as MethodReference, ca); + continue; + } if (_context.KeepUsedAttributeTypesOnly) { _lateMarkedAttributes.Enqueue (new AttributeProviderPair (ca, provider)); @@ -268,6 +272,151 @@ namespace Mono.Linker.Steps { } } + protected virtual bool IsUserDependencyMarker (TypeReference type) + { + return type.Name == "PreserveDependencyAttribute" && + type.Namespace == "System.Runtime.CompilerServices"; + } + + protected virtual void MarkUserDependency (MethodReference context, CustomAttribute ca) + { + var args = ca.ConstructorArguments; + if (args.Count == 2 && args[1].Value is string condition) { + switch (condition) { + case "": + case null: + break; + case "DEBUG": + if (!_context.KeepMembersForDebugger) + return; + + break; + default: + // Don't have yet a way to match the general condition so everything is excluded + return; + } + } + + if (args.Count >= 1 && args[0].Value is string dependency) { + string member = null; + string type = null; + string[] signature = null; + TypeDefinition td = null; + + var sign_start = dependency.IndexOf ('('); + var sign_end = dependency.LastIndexOf (')'); + if (sign_start > 0 && sign_end > sign_start) { + var parameters = dependency.Substring (sign_start + 1, sign_end - sign_start - 1).Replace (" ", ""); + signature = string.IsNullOrEmpty (parameters) ? Array.Empty () : parameters.Split (','); + var idx = dependency.LastIndexOf ('.', sign_start); + if (idx > 0) { + member = dependency.Substring (idx + 1, sign_start - idx - 1).TrimEnd (); + type = dependency.Substring (0, idx); + } else { + member = dependency.Substring (0, sign_start - 1); + td = context.DeclaringType.Resolve (); + } + } else if (sign_start < 0) { + var idx = dependency.LastIndexOf ('.'); + if (idx > 0) { + member = dependency.Substring (idx + 1); + type = dependency.Substring (0, idx); + } else { + member = dependency; + td = context.DeclaringType.Resolve (); + } + } + + if (td == null) { + if (type == null) { + _context.Logger.LogMessage (MessageImportance.Low, $"Could not resolve '{dependency}' dependency"); + return; + } + + td = FindType (context.Module.Assembly, type); + if (td == null) { + _context.Logger.LogMessage (MessageImportance.Low, $"Could not find '{dependency}' dependency"); + return; + } + } + + if (MarkDependencyMethod (td, member, signature)) + return; + + if (MarkDependencyField (td, member)) + return; + + _context.Logger.LogMessage (MessageImportance.High, $"Could not resolve dependency member '{member}' declared in type '{dependency}'"); + } + } + + static TypeDefinition FindType (AssemblyDefinition assembly, string fullName) + { + fullName = fullName.ToCecilName (); + + var type = assembly.MainModule.GetType (fullName); + return type?.Resolve (); + } + + bool MarkDependencyMethod (TypeDefinition type, string name, string[] signature) + { + bool marked = false; + int arity; + + int arity_marker = name.IndexOf ('`'); + if (arity_marker < 1 || !int.TryParse (name.Substring (arity_marker + 1), out arity)) { + arity = 0; + } else { + name = name.Substring (0, arity_marker); + } + + foreach (var m in type.Methods) { + if (m.Name != name) + continue; + + if (m.GenericParameters.Count != arity) + continue; + + if (signature == null) { + MarkMethod (m); + marked = true; + continue; + } + + var mp = m.Parameters; + if (mp.Count != signature.Length) + continue; + + int i = 0; + for (; i < signature.Length; ++i) { + if (mp [i].ParameterType.FullName != signature [i].Trim ().ToCecilName ()) { + i = -1; + break; + } + } + + if (i < 0) + continue; + + MarkMethod (m); + marked = true; + } + + return marked; + } + + bool MarkDependencyField (TypeDefinition type, string name) + { + foreach (var f in type.Fields) { + if (f.Name == name) { + MarkField (f); + return true; + } + } + + return false; + } + void LazyMarkCustomAttributes (ICustomAttributeProvider provider, AssemblyDefinition assembly) { if (!provider.HasCustomAttributes) @@ -303,15 +452,17 @@ namespace Mono.Linker.Steps { protected virtual bool ShouldMarkCustomAttribute (CustomAttribute ca, ICustomAttributeProvider provider) { + var attr_type = ca.AttributeType; + if (_context.KeepUsedAttributeTypesOnly) { - switch (ca.AttributeType.FullName) { + switch (attr_type.FullName) { // [ThreadStatic] and [ContextStatic] are required by the runtime case "System.ThreadStaticAttribute": case "System.ContextStaticAttribute": return true; } - if (!Annotations.IsMarked (ca.AttributeType.Resolve ())) + if (!Annotations.IsMarked (attr_type.Resolve ())) return false; } @@ -872,7 +1023,7 @@ namespace Mono.Linker.Steps { void MarkTypeWithDebuggerDisplayAttribute (TypeDefinition type, CustomAttribute attribute) { - if (_context.KeepMembersForDebuggerAttributes) { + if (_context.KeepMembersForDebugger) { string displayString = (string) attribute.ConstructorArguments[0].Value; @@ -926,7 +1077,7 @@ namespace Mono.Linker.Steps { void MarkTypeWithDebuggerTypeProxyAttribute (TypeDefinition type, CustomAttribute attribute) { - if (_context.KeepMembersForDebuggerAttributes) { + if (_context.KeepMembersForDebugger) { object constructorArgument = attribute.ConstructorArguments[0].Value; TypeReference proxyTypeReference = constructorArgument as TypeReference; if (proxyTypeReference == null) { diff --git a/external/linker/linker/Linker.Steps/ResolveFromXmlStep.cs b/external/linker/linker/Linker.Steps/ResolveFromXmlStep.cs index f7406435ab..3a0d89f96e 100644 --- a/external/linker/linker/Linker.Steps/ResolveFromXmlStep.cs +++ b/external/linker/linker/Linker.Steps/ResolveFromXmlStep.cs @@ -154,6 +154,11 @@ namespace Mono.Linker.Steps { { while (iterator.MoveNext ()) { XPathNavigator nav = iterator.Current; + + var feature = GetAttribute (nav, "feature"); + if (Context.IsFeatureExcluded (feature)) + continue; + string fullname = GetFullName (nav); if (IsTypePattern (fullname)) { diff --git a/external/linker/linker/Linker.Steps/SweepStep.cs b/external/linker/linker/Linker.Steps/SweepStep.cs index 9eb6311a7f..695e2c220b 100644 --- a/external/linker/linker/Linker.Steps/SweepStep.cs +++ b/external/linker/linker/Linker.Steps/SweepStep.cs @@ -178,8 +178,9 @@ namespace Mono.Linker.Steps { if (!AreSameReference (r.Name, target.Name)) continue; - ReferenceRemoved (assembly, references [i]); - references.RemoveAt (i); + ReferenceRemoved (assembly, reference); + // removal from `references` requires an adjustment to `i` + references.RemoveAt (i--); // Removing the reference does not mean it will be saved back to disk! // That depends on the AssemblyAction set for the `assembly` switch (Annotations.GetAction (assembly)) { @@ -208,7 +209,6 @@ namespace Mono.Linker.Steps { } break; } - return; } } diff --git a/external/linker/linker/Linker/Driver.cs b/external/linker/linker/Linker/Driver.cs index aec8059fee..6c49e2537c 100644 --- a/external/linker/linker/Linker/Driver.cs +++ b/external/linker/linker/Linker/Driver.cs @@ -89,6 +89,7 @@ namespace Mono.Linker { I18nAssemblies assemblies = I18nAssemblies.All; var custom_steps = new List (); + var excluded_features = new HashSet (); bool dumpDependencies = false; bool resolver = false; @@ -136,7 +137,7 @@ namespace Mono.Linker { context.KeepUsedAttributeTypesOnly = bool.Parse (GetParam ()); continue; } - + if (token == "--strip-security") { if (bool.Parse (GetParam ())) p.AddStepBefore (typeof (MarkStep), new RemoveSecurityStep ()); @@ -148,6 +149,13 @@ namespace Mono.Linker { continue; } + if (token == "--exclude-feature") { + var name = GetParam (); + if (!excluded_features.Contains (name)) + excluded_features.Add (name); + continue; + } + switch (token [2]) { case 'v': Version (); @@ -162,11 +170,10 @@ namespace Mono.Linker { } switch (token [1]) { - case 'd': { + case 'd': DirectoryInfo info = new DirectoryInfo (GetParam ()); context.Resolver.AddSearchDirectory (info.FullName); - break; - } + break; case 'o': context.OutputDirectory = GetParam (); break; @@ -219,11 +226,11 @@ namespace Mono.Linker { p.RemoveStep (typeof (RegenerateGuidStep)); break; case 'z': - if (!bool.Parse (GetParam ())) - p.RemoveStep (typeof (BlacklistStep)); - break; + if (!bool.Parse (GetParam ())) + p.RemoveStep (typeof (BlacklistStep)); + break; case 'v': - context.KeepMembersForDebuggerAttributes = bool.Parse (GetParam ()); + context.KeepMembersForDebugger = bool.Parse (GetParam ()); break; default: Usage ("Unknown option: `" + token [1] + "'"); @@ -246,6 +253,12 @@ namespace Mono.Linker { p.AddStepAfter (typeof (SweepStep), new AddBypassNGenStep ()); } + if (excluded_features.Count > 0) { + var excluded = new string [excluded_features.Count]; + excluded_features.CopyTo (excluded); + context.ExcludedFeatures = excluded; + } + try { p.Process (context); } @@ -375,6 +388,7 @@ namespace Mono.Linker { Console.WriteLine (" --used-attrs-only Attributes on types, methods, etc will be removed if the attribute type is not used"); Console.WriteLine (" --strip-security In linked assemblies, attributes on assemblies, types, and methods related to security will be removed"); Console.WriteLine (" --strip-resources Remove link xml resources that were processed (true or false), default to true"); + Console.WriteLine (" --exclude-feature Any code which has feature-name dependency will be removed"); Console.WriteLine (" -out Specify the output directory, default to `output'"); Console.WriteLine (" -c Action on the core assemblies, skip, copy, copyused, addbypassngen, addbypassngenused or link, default to skip"); Console.WriteLine (" -u Action on the user assemblies, skip, copy, copyused, addbypassngen, addbypassngenused or link, default to link"); @@ -384,7 +398,7 @@ namespace Mono.Linker { Console.WriteLine (" -d Add a directory where the linker will look for assemblies"); Console.WriteLine (" -b Generate debug symbols for each linked module (true or false)"); Console.WriteLine (" -g Generate a new unique guid for each linked module (true or false)"); - Console.WriteLine (" -v Keep memebers needed by debugger attributes (true or false)"); + Console.WriteLine (" -v Keep members needed by debugger (true or false)"); Console.WriteLine (" -l List of i18n assemblies to copy to the output directory"); Console.WriteLine (" separated with a comma: none,all,cjk,mideast,other,rare,west"); Console.WriteLine (" default is all"); diff --git a/external/linker/linker/Linker/LinkContext.cs b/external/linker/linker/Linker/LinkContext.cs index b310931ef1..23b62bf8bd 100644 --- a/external/linker/linker/Linker/LinkContext.cs +++ b/external/linker/linker/Linker/LinkContext.cs @@ -50,7 +50,7 @@ namespace Mono.Linker { readonly Dictionary _parameters; bool _linkSymbols; bool _keepTypeForwarderOnlyAssemblies; - bool _keepMembersForDebuggerAttributes; + bool _keepMembersForDebugger; bool _ignoreUnresolved; AssemblyResolver _resolver; @@ -95,10 +95,10 @@ namespace Mono.Linker { set { _keepTypeForwarderOnlyAssemblies = value; } } - public bool KeepMembersForDebuggerAttributes + public bool KeepMembersForDebugger { - get { return _keepMembersForDebuggerAttributes; } - set { _keepMembersForDebuggerAttributes = value; } + get { return _keepMembersForDebugger; } + set { _keepMembersForDebugger = value; } } public bool IgnoreUnresolved @@ -135,7 +135,7 @@ namespace Mono.Linker { set { _symbolWriterProvider = value; } } - public bool LogMessages { get; set; } = false; + public bool LogMessages { get; set; } public ILogger Logger { get; set; } = new ConsoleLogger (); @@ -143,6 +143,8 @@ namespace Mono.Linker { public Tracer Tracer { get; private set; } + public string[] ExcludedFeatures { get; set; } + public LinkContext (Pipeline pipeline) : this (pipeline, new AssemblyResolver ()) { @@ -179,7 +181,7 @@ namespace Mono.Linker { public TypeDefinition GetType (string fullName) { int pos = fullName.IndexOf (","); - fullName = fullName.Replace ("+", "/"); + fullName = TypeReferenceExtensions.ToCecilName (fullName); if (pos == -1) { foreach (AssemblyDefinition asm in GetAssemblies ()) { var type = asm.MainModule.GetType (fullName); @@ -353,6 +355,11 @@ namespace Mono.Linker { _resolver.Dispose (); } + public bool IsFeatureExcluded (string featureName) + { + return ExcludedFeatures != null && Array.IndexOf (ExcludedFeatures, featureName) >= 0; + } + public void LogMessage (string message, params object[] values) { LogMessage (MessageImportance.Normal, message, values); diff --git a/external/linker/linker/Linker/TypeReferenceExtensions.cs b/external/linker/linker/Linker/TypeReferenceExtensions.cs index 033326dbf0..bb84457487 100644 --- a/external/linker/linker/Linker/TypeReferenceExtensions.cs +++ b/external/linker/linker/Linker/TypeReferenceExtensions.cs @@ -195,5 +195,10 @@ namespace Mono.Linker return method; } + + public static string ToCecilName (this string fullTypeName) + { + return fullTypeName.Replace ('+', '/'); + } } } diff --git a/mcs/build/common/Consts.cs b/mcs/build/common/Consts.cs index be239caf6c..c919d46286 100644 --- a/mcs/build/common/Consts.cs +++ b/mcs/build/common/Consts.cs @@ -34,7 +34,7 @@ static class Consts // Use these assembly version constants to make code more maintainable. // - public const string MonoVersion = "5.14.0.148"; + public const string MonoVersion = "5.14.0.156"; public const string MonoCompany = "Mono development team"; public const string MonoProduct = "Mono Common Language Infrastructure"; public const string MonoCopyright = "(c) Various Mono authors"; diff --git a/mcs/build/tests.make b/mcs/build/tests.make index 63ecdd818a..2ed5f0ce5b 100644 --- a/mcs/build/tests.make +++ b/mcs/build/tests.make @@ -27,11 +27,16 @@ xunit_src := $(patsubst %,$(topdir)/../external/xunit-binaries/%,BenchmarkAttri ifeq ($(USE_XTEST_REMOTE_EXECUTOR), YES) XTEST_REMOTE_EXECUTOR = $(topdir)/class/lib/$(PROFILE)/RemoteExecutorConsoleApp.exe xunit_src += $(topdir)/../mcs/class/test-helpers/AdminHelper.cs \ -$(topdir)/../mcs/class/test-helpers/RemoteExecutorTestBase.Mono.cs \ $(topdir)/../external/corefx/src/CoreFx.Private.TestUtilities/src/System/IO/FileCleanupTestBase.cs \ -$(topdir)/../external/corefx/src/CoreFx.Private.TestUtilities/src/System/Diagnostics/RemoteExecutorTestBase.Process.cs \ $(topdir)/../external/corefx/src/CoreFx.Private.TestUtilities/src/System/Diagnostics/RemoteExecutorTestBase.cs \ $(topdir)/../external/corefx/src/Common/src/System/PasteArguments.cs + +ifeq ($(PROFILE),monodroid) +xunit_src += $(topdir)/../mcs/class/test-helpers/RemoteExecutorTestBase.Mobile.cs +else +xunit_src += $(topdir)/../mcs/class/test-helpers/RemoteExecutorTestBase.Mono.cs \ +$(topdir)/../external/corefx/src/CoreFx.Private.TestUtilities/src/System/Diagnostics/RemoteExecutorTestBase.Process.cs +endif endif xunit_class_deps := diff --git a/mcs/class/lib/monolite-darwin/1051400003/Mono.Security.dll.REMOVED.git-id b/mcs/class/lib/monolite-darwin/1051400003/Mono.Security.dll.REMOVED.git-id index 4ac7a7eb9a..64ee6e83b7 100644 --- a/mcs/class/lib/monolite-darwin/1051400003/Mono.Security.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-darwin/1051400003/Mono.Security.dll.REMOVED.git-id @@ -1 +1 @@ -b81e5105b4a226b866e9d4b525c04d6024ed558b \ No newline at end of file +6196c069b0580d9adc346e2dffa9e1fbc0b6e4f6 \ No newline at end of file diff --git a/mcs/class/lib/monolite-darwin/1051400003/System.Configuration.dll.REMOVED.git-id b/mcs/class/lib/monolite-darwin/1051400003/System.Configuration.dll.REMOVED.git-id index f757b3cf9b..f829e518e5 100644 --- a/mcs/class/lib/monolite-darwin/1051400003/System.Configuration.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-darwin/1051400003/System.Configuration.dll.REMOVED.git-id @@ -1 +1 @@ -d562da103406d82c4e5700336bbb136672c0b595 \ No newline at end of file +7cd4ce8794c209e26f59d0c354d93fb9ae1f95db \ No newline at end of file diff --git a/mcs/class/lib/monolite-darwin/1051400003/System.Numerics.dll.REMOVED.git-id b/mcs/class/lib/monolite-darwin/1051400003/System.Numerics.dll.REMOVED.git-id index dfb01f7d83..879e6787d9 100644 --- a/mcs/class/lib/monolite-darwin/1051400003/System.Numerics.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-darwin/1051400003/System.Numerics.dll.REMOVED.git-id @@ -1 +1 @@ -8e12b0c40d4b90a82ade721f380a924720127548 \ No newline at end of file +40ab52f347643403188c38498f42091ef9f00d9c \ No newline at end of file diff --git a/mcs/class/lib/monolite-darwin/1051400003/System.Security.dll.REMOVED.git-id b/mcs/class/lib/monolite-darwin/1051400003/System.Security.dll.REMOVED.git-id index 69ad94c197..6ee82825d0 100644 --- a/mcs/class/lib/monolite-darwin/1051400003/System.Security.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-darwin/1051400003/System.Security.dll.REMOVED.git-id @@ -1 +1 @@ -1f42617e7b8e00a04125fc85967729855b0bbd3c \ No newline at end of file +14839a10498c41b5b2bc637ff264e816bd2d87d0 \ No newline at end of file diff --git a/mcs/class/lib/monolite-darwin/1051400003/System.Xml.dll.REMOVED.git-id b/mcs/class/lib/monolite-darwin/1051400003/System.Xml.dll.REMOVED.git-id index f4aad084fd..b5cacae632 100644 --- a/mcs/class/lib/monolite-darwin/1051400003/System.Xml.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-darwin/1051400003/System.Xml.dll.REMOVED.git-id @@ -1 +1 @@ -fda09093e5973afedf30878b4b04bcdb9ce7302f \ No newline at end of file +79b791d700de0970735b209e0d091d1a21787896 \ No newline at end of file diff --git a/mcs/class/lib/monolite-darwin/1051400003/mcs.exe.REMOVED.git-id b/mcs/class/lib/monolite-darwin/1051400003/mcs.exe.REMOVED.git-id index 1a728a3d83..fb5b1d602a 100644 --- a/mcs/class/lib/monolite-darwin/1051400003/mcs.exe.REMOVED.git-id +++ b/mcs/class/lib/monolite-darwin/1051400003/mcs.exe.REMOVED.git-id @@ -1 +1 @@ -6cd85b1ade15d3d15c5d45f15729344bfc58f191 \ No newline at end of file +03f9e0b46c10b5712398a929c279cd9654a0393d \ No newline at end of file diff --git a/mcs/class/lib/monolite-darwin/1051400003/mscorlib.dll.REMOVED.git-id b/mcs/class/lib/monolite-darwin/1051400003/mscorlib.dll.REMOVED.git-id index 9d30413107..a5a78db8d1 100644 --- a/mcs/class/lib/monolite-darwin/1051400003/mscorlib.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-darwin/1051400003/mscorlib.dll.REMOVED.git-id @@ -1 +1 @@ -9aca22f64e9b0800a2247930d7d53ddb4570059f \ No newline at end of file +9a030f23563302ff603ffee74a0dd6f89a4f8b15 \ No newline at end of file diff --git a/mcs/class/lib/monolite-linux/1051400003/Mono.Security.dll.REMOVED.git-id b/mcs/class/lib/monolite-linux/1051400003/Mono.Security.dll.REMOVED.git-id index 4ac7a7eb9a..64ee6e83b7 100644 --- a/mcs/class/lib/monolite-linux/1051400003/Mono.Security.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-linux/1051400003/Mono.Security.dll.REMOVED.git-id @@ -1 +1 @@ -b81e5105b4a226b866e9d4b525c04d6024ed558b \ No newline at end of file +6196c069b0580d9adc346e2dffa9e1fbc0b6e4f6 \ No newline at end of file diff --git a/mcs/class/lib/monolite-linux/1051400003/System.Configuration.dll.REMOVED.git-id b/mcs/class/lib/monolite-linux/1051400003/System.Configuration.dll.REMOVED.git-id index f757b3cf9b..f829e518e5 100644 --- a/mcs/class/lib/monolite-linux/1051400003/System.Configuration.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-linux/1051400003/System.Configuration.dll.REMOVED.git-id @@ -1 +1 @@ -d562da103406d82c4e5700336bbb136672c0b595 \ No newline at end of file +7cd4ce8794c209e26f59d0c354d93fb9ae1f95db \ No newline at end of file diff --git a/mcs/class/lib/monolite-linux/1051400003/System.Numerics.dll.REMOVED.git-id b/mcs/class/lib/monolite-linux/1051400003/System.Numerics.dll.REMOVED.git-id index dfb01f7d83..879e6787d9 100644 --- a/mcs/class/lib/monolite-linux/1051400003/System.Numerics.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-linux/1051400003/System.Numerics.dll.REMOVED.git-id @@ -1 +1 @@ -8e12b0c40d4b90a82ade721f380a924720127548 \ No newline at end of file +40ab52f347643403188c38498f42091ef9f00d9c \ No newline at end of file diff --git a/mcs/class/lib/monolite-linux/1051400003/System.Security.dll.REMOVED.git-id b/mcs/class/lib/monolite-linux/1051400003/System.Security.dll.REMOVED.git-id index 69ad94c197..6ee82825d0 100644 --- a/mcs/class/lib/monolite-linux/1051400003/System.Security.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-linux/1051400003/System.Security.dll.REMOVED.git-id @@ -1 +1 @@ -1f42617e7b8e00a04125fc85967729855b0bbd3c \ No newline at end of file +14839a10498c41b5b2bc637ff264e816bd2d87d0 \ No newline at end of file diff --git a/mcs/class/lib/monolite-linux/1051400003/System.Xml.dll.REMOVED.git-id b/mcs/class/lib/monolite-linux/1051400003/System.Xml.dll.REMOVED.git-id index f4aad084fd..b5cacae632 100644 --- a/mcs/class/lib/monolite-linux/1051400003/System.Xml.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-linux/1051400003/System.Xml.dll.REMOVED.git-id @@ -1 +1 @@ -fda09093e5973afedf30878b4b04bcdb9ce7302f \ No newline at end of file +79b791d700de0970735b209e0d091d1a21787896 \ No newline at end of file diff --git a/mcs/class/lib/monolite-linux/1051400003/mcs.exe.REMOVED.git-id b/mcs/class/lib/monolite-linux/1051400003/mcs.exe.REMOVED.git-id index 1a728a3d83..fb5b1d602a 100644 --- a/mcs/class/lib/monolite-linux/1051400003/mcs.exe.REMOVED.git-id +++ b/mcs/class/lib/monolite-linux/1051400003/mcs.exe.REMOVED.git-id @@ -1 +1 @@ -6cd85b1ade15d3d15c5d45f15729344bfc58f191 \ No newline at end of file +03f9e0b46c10b5712398a929c279cd9654a0393d \ No newline at end of file diff --git a/mcs/class/lib/monolite-linux/1051400003/mscorlib.dll.REMOVED.git-id b/mcs/class/lib/monolite-linux/1051400003/mscorlib.dll.REMOVED.git-id index 9d30413107..a5a78db8d1 100644 --- a/mcs/class/lib/monolite-linux/1051400003/mscorlib.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-linux/1051400003/mscorlib.dll.REMOVED.git-id @@ -1 +1 @@ -9aca22f64e9b0800a2247930d7d53ddb4570059f \ No newline at end of file +9a030f23563302ff603ffee74a0dd6f89a4f8b15 \ No newline at end of file diff --git a/mcs/class/lib/monolite-win32/1051400003/Mono.Security.dll.REMOVED.git-id b/mcs/class/lib/monolite-win32/1051400003/Mono.Security.dll.REMOVED.git-id index 4ac7a7eb9a..64ee6e83b7 100644 --- a/mcs/class/lib/monolite-win32/1051400003/Mono.Security.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-win32/1051400003/Mono.Security.dll.REMOVED.git-id @@ -1 +1 @@ -b81e5105b4a226b866e9d4b525c04d6024ed558b \ No newline at end of file +6196c069b0580d9adc346e2dffa9e1fbc0b6e4f6 \ No newline at end of file diff --git a/mcs/class/lib/monolite-win32/1051400003/System.Configuration.dll.REMOVED.git-id b/mcs/class/lib/monolite-win32/1051400003/System.Configuration.dll.REMOVED.git-id index f757b3cf9b..f829e518e5 100644 --- a/mcs/class/lib/monolite-win32/1051400003/System.Configuration.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-win32/1051400003/System.Configuration.dll.REMOVED.git-id @@ -1 +1 @@ -d562da103406d82c4e5700336bbb136672c0b595 \ No newline at end of file +7cd4ce8794c209e26f59d0c354d93fb9ae1f95db \ No newline at end of file diff --git a/mcs/class/lib/monolite-win32/1051400003/System.Numerics.dll.REMOVED.git-id b/mcs/class/lib/monolite-win32/1051400003/System.Numerics.dll.REMOVED.git-id index dfb01f7d83..879e6787d9 100644 --- a/mcs/class/lib/monolite-win32/1051400003/System.Numerics.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-win32/1051400003/System.Numerics.dll.REMOVED.git-id @@ -1 +1 @@ -8e12b0c40d4b90a82ade721f380a924720127548 \ No newline at end of file +40ab52f347643403188c38498f42091ef9f00d9c \ No newline at end of file diff --git a/mcs/class/lib/monolite-win32/1051400003/System.Security.dll.REMOVED.git-id b/mcs/class/lib/monolite-win32/1051400003/System.Security.dll.REMOVED.git-id index 69ad94c197..6ee82825d0 100644 --- a/mcs/class/lib/monolite-win32/1051400003/System.Security.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-win32/1051400003/System.Security.dll.REMOVED.git-id @@ -1 +1 @@ -1f42617e7b8e00a04125fc85967729855b0bbd3c \ No newline at end of file +14839a10498c41b5b2bc637ff264e816bd2d87d0 \ No newline at end of file diff --git a/mcs/class/lib/monolite-win32/1051400003/System.Xml.dll.REMOVED.git-id b/mcs/class/lib/monolite-win32/1051400003/System.Xml.dll.REMOVED.git-id index f4aad084fd..b5cacae632 100644 --- a/mcs/class/lib/monolite-win32/1051400003/System.Xml.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-win32/1051400003/System.Xml.dll.REMOVED.git-id @@ -1 +1 @@ -fda09093e5973afedf30878b4b04bcdb9ce7302f \ No newline at end of file +79b791d700de0970735b209e0d091d1a21787896 \ No newline at end of file diff --git a/mcs/class/lib/monolite-win32/1051400003/mcs.exe.REMOVED.git-id b/mcs/class/lib/monolite-win32/1051400003/mcs.exe.REMOVED.git-id index 1a728a3d83..fb5b1d602a 100644 --- a/mcs/class/lib/monolite-win32/1051400003/mcs.exe.REMOVED.git-id +++ b/mcs/class/lib/monolite-win32/1051400003/mcs.exe.REMOVED.git-id @@ -1 +1 @@ -6cd85b1ade15d3d15c5d45f15729344bfc58f191 \ No newline at end of file +03f9e0b46c10b5712398a929c279cd9654a0393d \ No newline at end of file diff --git a/mcs/class/lib/monolite-win32/1051400003/mscorlib.dll.REMOVED.git-id b/mcs/class/lib/monolite-win32/1051400003/mscorlib.dll.REMOVED.git-id index 9d30413107..a5a78db8d1 100644 --- a/mcs/class/lib/monolite-win32/1051400003/mscorlib.dll.REMOVED.git-id +++ b/mcs/class/lib/monolite-win32/1051400003/mscorlib.dll.REMOVED.git-id @@ -1 +1 @@ -9aca22f64e9b0800a2247930d7d53ddb4570059f \ No newline at end of file +9a030f23563302ff603ffee74a0dd6f89a4f8b15 \ No newline at end of file diff --git a/mono/mini/interp/transform.c.REMOVED.git-id b/mono/mini/interp/transform.c.REMOVED.git-id index 8e753b746b..ad748d1cd8 100644 --- a/mono/mini/interp/transform.c.REMOVED.git-id +++ b/mono/mini/interp/transform.c.REMOVED.git-id @@ -1 +1 @@ -9a373e74e3e122d1bcbac0be019806e52aac57b2 \ No newline at end of file +ebf1987abc74203d6caadcbc3789e810e096cc07 \ No newline at end of file diff --git a/mono/mini/mini.c.REMOVED.git-id b/mono/mini/mini.c.REMOVED.git-id index 74cad7c7f7..6d707cc32d 100644 --- a/mono/mini/mini.c.REMOVED.git-id +++ b/mono/mini/mini.c.REMOVED.git-id @@ -1 +1 @@ -597d734e479aed50e4f157f42882c34019c3b62c \ No newline at end of file +29fd7afd5944eff3d752cc8fbd292cedd4744fd0 \ No newline at end of file diff --git a/mono/mini/objects.cs b/mono/mini/objects.cs index 82d3e8de23..067d41b76f 100644 --- a/mono/mini/objects.cs +++ b/mono/mini/objects.cs @@ -1907,6 +1907,22 @@ ncells ) { return dataPtr [0] == 1.0f ? 0 : 1; } + class SimpleContainer { + public Simple simple1; + public Simple simple2; + + public static Simple constsimple; + + public int SetFields () { + constsimple.a = 0x1337; + simple1 = simple2 = constsimple; + return simple1.a - simple2.a; + } + } + + public static int test_0_dup_vtype () { + return new SimpleContainer ().SetFields (); + } } #if __MOBILE__ diff --git a/mono/mini/version.h b/mono/mini/version.h index 571394611d..a7318a08a9 100644 --- a/mono/mini/version.h +++ b/mono/mini/version.h @@ -1 +1 @@ -#define FULL_VERSION "explicit/d0bb0ce" +#define FULL_VERSION "explicit/5a3352a" diff --git a/mono/utils/mono-merp.c b/mono/utils/mono-merp.c index 3c44d340ce..73031ab86e 100644 --- a/mono/utils/mono-merp.c +++ b/mono/utils/mono-merp.c @@ -99,6 +99,8 @@ typedef struct { const char systemModel [100]; const char *systemManufacturer; + const char *eventType; + MonoStackHash hashes; } MERPStruct; @@ -225,6 +227,7 @@ mono_encode_merp_params (MERPStruct *merp) g_string_append_printf (output, "LanguageID: 0x%x\n", merp->uiLidArg); g_string_append_printf (output, "SystemManufacturer: %s\n", merp->systemManufacturer); g_string_append_printf (output, "SystemModel: %s\n", merp->systemModel); + g_string_append_printf (output, "EventType: %s\n", merp->eventType); return g_string_free (output, FALSE); } @@ -266,7 +269,7 @@ mono_merp_send (const char *merpFile, const char *crashLog, const char *werXml) write_file (crashLog, crashLogPath); g_free (crashLogPath); - char *werXmlPath = g_strdup_printf ("%s/Library/Group Containers/UBF8T346G9.ms/WERInternalMetadata.txt", home); + char *werXmlPath = g_strdup_printf ("%s/Library/Group Containers/UBF8T346G9.ms/CustomLogsMetadata.xml", home); write_file (werXml, werXmlPath); g_free (werXmlPath); @@ -339,6 +342,8 @@ mono_init_merp (const intptr_t crashed_pid, const char *signal, MonoStackHash *h merp->systemManufacturer = "apple"; get_apple_model ((char *) merp->systemModel, sizeof (merp->systemModel)); + merp->eventType = "MonoAppCrash"; + merp->hashes = *hashes; } @@ -415,6 +420,10 @@ mono_merp_fingerprint_payload (const char *non_param_data, const MERPStruct *mer mono_json_writer_object_key(&writer, "SystemModel:"); mono_json_writer_printf (&writer, "\"%s\"\n", merp->systemModel); + mono_json_writer_indent (&writer); + mono_json_writer_object_key(&writer, "EventType:"); + mono_json_writer_printf (&writer, "\"%s\"\n", merp->eventType); + // End of payload mono_json_writer_indent (&writer); mono_json_writer_object_end (&writer); @@ -444,7 +453,7 @@ mono_wer_template (MERPStruct *merp) g_string_append_printf (output, "\n"); g_string_append_printf (output, "\n"); g_string_append_printf (output, "\n"); - g_string_append_printf (output, "MonoAppCrash\n"); + g_string_append_printf (output, "%s\n", merp->eventType); int i=0; diff --git a/po/mcs/de.gmo b/po/mcs/de.gmo index 18502c60f3e767e3b3aea78e96dda6e64a320a37..1a7f84012ebd8e4266370522644bc6bd5c32370a 100644 GIT binary patch delta 21 ccmbQIHBW296D|&80|f&MD+7zoZ@7%O08lXosQ>@~ delta 21 ccmbQIHBW296D|%T3k3rUD+A-rZ@7%O08nNIs{jB1 diff --git a/po/mcs/de.po.REMOVED.git-id b/po/mcs/de.po.REMOVED.git-id index 5d72dbd3b7..33dec1481a 100644 --- a/po/mcs/de.po.REMOVED.git-id +++ b/po/mcs/de.po.REMOVED.git-id @@ -1 +1 @@ -cf13e946b0ca24c9f81b985f48bfb79ad4be4145 \ No newline at end of file +89149d8dba318f0c744dbc08dceae0c7d65bcc34 \ No newline at end of file diff --git a/po/mcs/es.gmo b/po/mcs/es.gmo index 0952855d1c88b6c18c68815850541dc07dd95167..be6eafc07c449f82f0030121d672b167ab2fb65b 100644 GIT binary patch delta 21 ccmX?Ef3kjqt|EuAfr5dBm4U@(Q^hHA09UaF-v9sr delta 21 ccmX?Ef3kjqt|Et#g@S>Fm4WeQQ^hHA09WP);Q#;t diff --git a/po/mcs/es.po.REMOVED.git-id b/po/mcs/es.po.REMOVED.git-id index 89687d7862..0ca2c06c93 100644 --- a/po/mcs/es.po.REMOVED.git-id +++ b/po/mcs/es.po.REMOVED.git-id @@ -1 +1 @@ -fd513a0cf57ccca8719e734438ca1c504ef26132 \ No newline at end of file +61f8dcbd5fbac920ac25a5b524d039a8099fa638 \ No newline at end of file diff --git a/po/mcs/ja.gmo b/po/mcs/ja.gmo index 62142c57df10d5db560eb5201fca7ea399a6b0b2..7971f2996a084112f952c7b566bd57df867a27a3 100644 GIT binary patch delta 23 ecmeyri1Gg-#trQ19L5F;1{PKZ7MuCi3$y@dmj^ol delta 23 ecmeyri1Gg-#trQ197Yxj1{PKZ#+&)o3$y@d%m+OH diff --git a/po/mcs/ja.po.REMOVED.git-id b/po/mcs/ja.po.REMOVED.git-id index fbe97b0570..644feb4633 100644 --- a/po/mcs/ja.po.REMOVED.git-id +++ b/po/mcs/ja.po.REMOVED.git-id @@ -1 +1 @@ -3607588cbe016ea6780d62dbb000dd8f275929d2 \ No newline at end of file +999726fdcea18744c7110fc65c2296b4a1fcbff1 \ No newline at end of file diff --git a/po/mcs/mcs.pot b/po/mcs/mcs.pot index 3bbaa7c34a..ac66721a9f 100644 --- a/po/mcs/mcs.pot +++ b/po/mcs/mcs.pot @@ -6,9 +6,9 @@ #, fuzzy msgid "" msgstr "" -"Project-Id-Version: mono 5.14.0.148\n" +"Project-Id-Version: mono 5.14.0.156\n" "Report-Msgid-Bugs-To: http://www.mono-project.com/Bugs\n" -"POT-Creation-Date: 2018-06-28 08:03+0000\n" +"POT-Creation-Date: 2018-06-30 08:08+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" diff --git a/po/mcs/pt_BR.gmo b/po/mcs/pt_BR.gmo index ba9dda89bd2a1bb69dee86178ac57c1fa76e3227..cb9fae838a938fb93e8ab0e72cc0879f208da5ab 100644 GIT binary patch delta 23 fcmaF1gXP%{mJP8}IgAYy3@oe+EH