diff options
author | Jesse Wilson <jessewilson@google.com> | 2010-02-24 17:38:13 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2010-02-24 17:38:13 -0800 |
commit | a09bb0d218d2ddb73b92b6dd4415456c9105cde8 (patch) | |
tree | 97b040f3cd552c615356b2bc84f8d10be0ead6f8 /tools | |
parent | 68aea82432574b7d9eac18729d61ffa04625109d (diff) | |
parent | e9fcaa0697dcb257d0288118347f721ce8806b55 (diff) | |
download | frameworks_base-a09bb0d218d2ddb73b92b6dd4415456c9105cde8.zip frameworks_base-a09bb0d218d2ddb73b92b6dd4415456c9105cde8.tar.gz frameworks_base-a09bb0d218d2ddb73b92b6dd4415456c9105cde8.tar.bz2 |
Merge "New update of preloaded classes for Froyo."
Diffstat (limited to 'tools')
-rw-r--r-- | tools/preload/20100223.compiled | bin | 0 -> 21723744 bytes | |||
-rw-r--r-- | tools/preload/MemoryUsage.java | 4 | ||||
-rw-r--r-- | tools/preload/Policy.java | 7 | ||||
-rw-r--r-- | tools/preload/Record.java | 17 |
4 files changed, 25 insertions, 3 deletions
diff --git a/tools/preload/20100223.compiled b/tools/preload/20100223.compiled Binary files differnew file mode 100644 index 0000000..3056388 --- /dev/null +++ b/tools/preload/20100223.compiled diff --git a/tools/preload/MemoryUsage.java b/tools/preload/MemoryUsage.java index bc21b6f..d8f95f4 100644 --- a/tools/preload/MemoryUsage.java +++ b/tools/preload/MemoryUsage.java @@ -166,7 +166,7 @@ class MemoryUsage implements Serializable { + ":/system/framework/loadclass.jar"; private static final String[] GET_DIRTY_PAGES = { - "adb", "-e", "shell", "dalvikvm", CLASS_PATH, "LoadClass" }; + "adb", "shell", "dalvikvm", CLASS_PATH, "LoadClass" }; /** * Measures memory usage for the given class. @@ -248,7 +248,7 @@ class MemoryUsage implements Serializable { String line = in.readLine(); if (line == null || !line.startsWith("DECAFBAD,")) { System.err.println("Got bad response for " + className - + ": " + line); + + ": " + line + "; command was " + Arrays.toString(commands)); errorCount += 1; return NOT_AVAILABLE; } diff --git a/tools/preload/Policy.java b/tools/preload/Policy.java index a8d761d..f557365 100644 --- a/tools/preload/Policy.java +++ b/tools/preload/Policy.java @@ -43,9 +43,14 @@ public class Policy { "system_server", "com.google.process.content", "android.process.media", + "com.android.bluetooth", + "com.android.calendar", + "com.android.inputmethod.latin", "com.android.phone", - "com.google.android.apps.maps.FriendService", + "com.google.android.apps.maps.FriendService", // pre froyo + "com.google.android.apps.maps:FriendService", // froyo "com.google.android.apps.maps.LocationFriendService", + "com.google.android.deskclock", "com.google.process.gapps", "android.tts" )); diff --git a/tools/preload/Record.java b/tools/preload/Record.java index b2be4d4..9d45a26 100644 --- a/tools/preload/Record.java +++ b/tools/preload/Record.java @@ -19,6 +19,19 @@ */ class Record { + /** + * The delimiter character we use, {@code :}, conflicts with some other + * names. In that case, manually replace the delimiter with something else. + */ + private static final String[] REPLACE_CLASSES = { + "com.google.android.apps.maps:FriendService", + "com.google.android.apps.maps\\u003AFriendService", + "com.google.android.apps.maps:driveabout", + "com.google.android.apps.maps\\u003Adriveabout", + "com.google.android.apps.maps:LocationFriendService", + "com.google.android.apps.maps\\u003ALocationFriendService", + }; + enum Type { /** Start of initialization. */ START_LOAD, @@ -74,6 +87,10 @@ class Record { } sourceLineNumber = lineNum; + + for (int i = 0; i < REPLACE_CLASSES.length; i+= 2) { + line = line.replace(REPLACE_CLASSES[i], REPLACE_CLASSES[i+1]); + } line = line.substring(1); String[] parts = line.split(":"); |