[mono/mono] [3 commits] 6ebf8e36: Fix inacurrate reference
| Newsgroups | gmane.comp.gnome.mono.patches |
|---|---|
| Message-ID | <000001418561e5ca-9ab8c248-0a64-4fa9-8c5d-0a527a1f3a76-000000@email.amazonses.com> |
Branch: refs/heads/xamarin/monodroid-4.8.2-branch
Home: https://github.com/mono/mono
Compare: https://github.com/mono/mono/compare/c93df1b7ca0a...3618f98f4516
Commit: 6ebf8e36b13126a805011225bde318e7e8e065e8
Author: Miguel de Icaza <[email protected]> (migueldeicaza)
Committer: Jonathan Pryor <[email protected]> (jonpryor)
Date: 2013-10-04 21:23:01 GMT
URL: https://github.com/mono/mono/commit/6ebf8e36b13126a805011225bde318e7e8e065e8
Fix inacurrate reference
Changed paths:
M mcs/class/corlib/System.IO/Path.cs
Modified: mcs/class/corlib/System.IO/Path.cs
===================================================================
@@ -289,9 +289,8 @@ public static string GetFullPath (string path)
return fullpath;
}
- [DllImport("Kernel32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
// http://msdn.microsoft.com/en-us/library/windows/desktop/aa364963%28v=vs.85%29.aspx
- // http://www.codeproject.com/Tips/223321/Win32-API-GetFullPathName
+ [DllImport("Kernel32.dll", SetLastError = true, CharSet = CharSet.Unicode)]
private static extern int GetFullPathName(string path, int numBufferChars, StringBuilder buffer, ref IntPtr lpFilePartOrNull);
internal static string GetFullPathName(string path)
Commit: 8f90d9a7a16650c432cd0bf4bafb619f5b038512
Author: Miguel de Icaza <[email protected]> (migueldeicaza)
Committer: Jonathan Pryor <[email protected]> (jonpryor)
Date: 2013-10-04 21:23:05 GMT
URL: https://github.com/mono/mono/commit/8f90d9a7a16650c432cd0bf4bafb619f5b038512
Add actual source
Changed paths:
M mcs/tools/mkbundle/template_z.c
Modified: mcs/tools/mkbundle/template_z.c
===================================================================
@@ -13,7 +13,8 @@
memset (&stream, 0, sizeof (z_stream));
stream.next_in = (Byte *) compr;
stream.avail_in = (uInt) compr_len;
- /* To decompress gzip format: http://stackoverflow.com/a/1838702/83444 */
+
+ // http://www.zlib.net/manual.html
err = inflateInit2 (&stream, 16+MAX_WBITS);
if (err != Z_OK)
return 1;
Commit: 3618f98f45163b850d9702fb8ae7f126ba01e5c5
Author: Zoltan Varga <[email protected]> (vargaz)
Committer: Jonathan Pryor <[email protected]> (jonpryor)
Date: 2013-10-04 21:24:41 GMT
URL: https://github.com/mono/mono/commit/3618f98f45163b850d9702fb8ae7f126ba01e5c5
[sgen] Use gcc bitcount intrinsics where appropriate.
Changed paths:
M mono/metadata/sgen-marksweep.c
Modified: mono/metadata/sgen-marksweep.c
===================================================================
@@ -1574,22 +1574,20 @@ struct _MSBlockInfo {
static inline int
bitcount (mword d)
{
-#if SIZEOF_VOID_P == 8
- /* http://www.jjj.de/bitwizardry/bitwizardrypage.html */
- d -= (d>>1) & 0x5555555555555555;
- d = ((d>>2) & 0x3333333333333333) + (d & 0x3333333333333333);
- d = ((d>>4) + d) & 0x0f0f0f0f0f0f0f0f;
- d *= 0x0101010101010101;
- return d >> 56;
+ int count = 0;
+
+#ifdef __GNUC__
+ if (sizeof (mword) == sizeof (unsigned long))
+ count += __builtin_popcountl (d);
+ else
+ count += __builtin_popcount (d);
#else
- /* http://aggregate.org/MAGIC/ */
- d -= ((d >> 1) & 0x55555555);
- d = (((d >> 2) & 0x33333333) + (d & 0x33333333));
- d = (((d >> 4) + d) & 0x0f0f0f0f);
- d += (d >> 8);
- d += (d >> 16);
- return (d & 0x0000003f);
+ while (d) {
+ count ++;
+ d &= (d - 1);
+ }
#endif
+ return count;
}
static void
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches