|
From: <sv...@va...> - 2013-09-19 10:05:09
|
Author: sewardj
Date: Thu Sep 19 10:04:59 2013
New Revision: 13567
Log:
Increase VG_N_SEGMENTS and VG_N_SEGNAMES by a factor of 6 on all
non-{phone/tablet} platforms. Possibly fixes #164485.
Modified:
trunk/coregrind/m_aspacemgr/aspacemgr-linux.c
Modified: trunk/coregrind/m_aspacemgr/aspacemgr-linux.c
==============================================================================
--- trunk/coregrind/m_aspacemgr/aspacemgr-linux.c (original)
+++ trunk/coregrind/m_aspacemgr/aspacemgr-linux.c Thu Sep 19 10:04:59 2013
@@ -264,11 +264,22 @@
/* ------ start of STATE for the address-space manager ------ */
-/* Max number of segments we can track. */
-#define VG_N_SEGMENTS 5000
+/* Max number of segments we can track. On Android, virtual address
+ space is limited, so keep a low limit -- 5000 x sizef(NSegment) is
+ 360KB. */
+#if defined(VGPV_arm_linux_android) || defined(VGPV_x86_linux_android)
+# define VG_N_SEGMENTS 5000
+#else
+# define VG_N_SEGMENTS 30000
+#endif
-/* Max number of segment file names we can track. */
-#define VG_N_SEGNAMES 1000
+/* Max number of segment file names we can track. These are big (1002
+ bytes) so on Android limit the space usage to ~1MB. */
+#if defined(VGPV_arm_linux_android) || defined(VGPV_x86_linux_android)
+# define VG_N_SEGNAMES 1000
+#else
+# define VG_N_SEGNAMES 6000
+#endif
/* Max length of a segment file name. */
#define VG_MAX_SEGNAMELEN 1000
|