Loading cmds/am/src/com/android/commands/am/Am.java +1 −4 Original line number Diff line number Diff line Loading @@ -120,7 +120,7 @@ public class Am extends BaseCommand { out.println( "usage: am [subcommand] [options]\n" + "usage: am start [-D] [-W] [-P <FILE>] [--start-profiler <FILE>]\n" + " [--sampling INTERVAL] [-R COUNT] [-S] [--opengl-trace]\n" + " [--sampling INTERVAL] [-R COUNT] [-S]\n" + " [--track-allocation] [--user <USER_ID> | current] <INTENT>\n" + " am startservice [--user <USER_ID> | current] <INTENT>\n" + " am stopservice [--user <USER_ID> | current] <INTENT>\n" + Loading Loading @@ -182,7 +182,6 @@ public class Am extends BaseCommand { " -R: repeat the activity launch <COUNT> times. Prior to each repeat,\n" + " the top activity will be finished.\n" + " -S: force stop the target app before starting the activity\n" + " --opengl-trace: enable tracing of OpenGL functions\n" + " --track-allocation: enable tracking of object allocations\n" + " --user <USER_ID> | current: Specify which user to run as; if not\n" + " specified then run as the current user.\n" + Loading Loading @@ -739,8 +738,6 @@ public class Am extends BaseCommand { mRepeat = Integer.parseInt(nextArgRequired()); } else if (opt.equals("-S")) { mStopOption = true; } else if (opt.equals("--opengl-trace")) { mStartFlags |= ActivityManager.START_FLAG_OPENGL_TRACES; } else if (opt.equals("--track-allocation")) { mStartFlags |= ActivityManager.START_FLAG_TRACK_ALLOCATION; } else if (opt.equals("--user")) { Loading core/java/android/app/ActivityManager.java +1 −8 Original line number Diff line number Diff line Loading @@ -202,19 +202,12 @@ public class ActivityManager { */ public static final int START_FLAG_DEBUG = 1<<1; /** * Flag for IActivityManaqer.startActivity: launch the app for * OpenGL tracing. * @hide */ public static final int START_FLAG_OPENGL_TRACES = 1<<2; /** * Flag for IActivityManaqer.startActivity: launch the app for * allocation tracking. * @hide */ public static final int START_FLAG_TRACK_ALLOCATION = 1<<3; public static final int START_FLAG_TRACK_ALLOCATION = 1<<2; /** * Result for IActivityManaqer.broadcastIntent: success! Loading core/java/android/app/ActivityThread.java +3 −11 Original line number Diff line number Diff line Loading @@ -469,7 +469,6 @@ public final class ActivityThread { IUiAutomationConnection instrumentationUiAutomationConnection; int debugMode; boolean enableBinderTracking; boolean enableOpenGlTrace; boolean trackAllocation; boolean restrictedBackupMode; boolean persistent; Loading Loading @@ -805,10 +804,9 @@ public final class ActivityThread { ProfilerInfo profilerInfo, Bundle instrumentationArgs, IInstrumentationWatcher instrumentationWatcher, IUiAutomationConnection instrumentationUiConnection, int debugMode, boolean enableBinderTracking, boolean enableOpenGlTrace, boolean trackAllocation, boolean isRestrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) { boolean enableBinderTracking, boolean trackAllocation, boolean isRestrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) { if (services != null) { // Setup the service cache in the ServiceManager Loading Loading @@ -864,7 +862,6 @@ public final class ActivityThread { data.instrumentationUiAutomationConnection = instrumentationUiConnection; data.debugMode = debugMode; data.enableBinderTracking = enableBinderTracking; data.enableOpenGlTrace = enableOpenGlTrace; data.trackAllocation = trackAllocation; data.restrictedBackupMode = isRestrictedBackupMode; data.persistent = persistent; Loading Loading @@ -4776,11 +4773,6 @@ public final class ActivityThread { } } // Enable OpenGL tracing if required if (data.enableOpenGlTrace) { GLUtils.setTracingLevel(1); } // Allow application-generated systrace messages if we're debuggable. boolean isAppDebuggable = (data.appInfo.flags & ApplicationInfo.FLAG_DEBUGGABLE) != 0; Trace.setAppTracingAllowed(isAppDebuggable); Loading core/java/android/app/ApplicationThreadNative.java +5 −8 Original line number Diff line number Diff line Loading @@ -294,7 +294,6 @@ public abstract class ApplicationThreadNative extends Binder IUiAutomationConnection.Stub.asInterface(binder); int testMode = data.readInt(); boolean enableBinderTracking = data.readInt() != 0; boolean openGlTrace = data.readInt() != 0; boolean trackAllocation = data.readInt() != 0; boolean restrictedBackupMode = (data.readInt() != 0); boolean persistent = (data.readInt() != 0); Loading @@ -304,8 +303,8 @@ public abstract class ApplicationThreadNative extends Binder Bundle coreSettings = data.readBundle(); bindApplication(packageName, info, providers, testName, profilerInfo, testArgs, testWatcher, uiAutomationConnection, testMode, enableBinderTracking, openGlTrace, trackAllocation, restrictedBackupMode, persistent, config, compatInfo, services, coreSettings); trackAllocation, restrictedBackupMode, persistent, config, compatInfo, services, coreSettings); return true; } Loading Loading @@ -1020,10 +1019,9 @@ class ApplicationThreadProxy implements IApplicationThread { List<ProviderInfo> providers, ComponentName testName, ProfilerInfo profilerInfo, Bundle testArgs, IInstrumentationWatcher testWatcher, IUiAutomationConnection uiAutomationConnection, int debugMode, boolean enableBinderTracking, boolean openGlTrace, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException { boolean enableBinderTracking, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException { Parcel data = Parcel.obtain(); data.writeInterfaceToken(IApplicationThread.descriptor); data.writeString(packageName); Loading @@ -1046,7 +1044,6 @@ class ApplicationThreadProxy implements IApplicationThread { data.writeStrongInterface(uiAutomationConnection); data.writeInt(debugMode); data.writeInt(enableBinderTracking ? 1 : 0); data.writeInt(openGlTrace ? 1 : 0); data.writeInt(trackAllocation ? 1 : 0); data.writeInt(restrictedBackupMode ? 1 : 0); data.writeInt(persistent ? 1 : 0); Loading core/java/android/app/IApplicationThread.java +4 −4 Original line number Diff line number Diff line Loading @@ -96,10 +96,10 @@ public interface IApplicationThread extends IInterface { void bindApplication(String packageName, ApplicationInfo info, List<ProviderInfo> providers, ComponentName testName, ProfilerInfo profilerInfo, Bundle testArguments, IInstrumentationWatcher testWatcher, IUiAutomationConnection uiAutomationConnection, int debugMode, boolean enableBinderTracking, boolean openGlTrace, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException; int debugMode, boolean enableBinderTracking, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException; void scheduleExit() throws RemoteException; void scheduleSuicide() throws RemoteException; void scheduleConfigurationChanged(Configuration config) throws RemoteException; Loading Loading
cmds/am/src/com/android/commands/am/Am.java +1 −4 Original line number Diff line number Diff line Loading @@ -120,7 +120,7 @@ public class Am extends BaseCommand { out.println( "usage: am [subcommand] [options]\n" + "usage: am start [-D] [-W] [-P <FILE>] [--start-profiler <FILE>]\n" + " [--sampling INTERVAL] [-R COUNT] [-S] [--opengl-trace]\n" + " [--sampling INTERVAL] [-R COUNT] [-S]\n" + " [--track-allocation] [--user <USER_ID> | current] <INTENT>\n" + " am startservice [--user <USER_ID> | current] <INTENT>\n" + " am stopservice [--user <USER_ID> | current] <INTENT>\n" + Loading Loading @@ -182,7 +182,6 @@ public class Am extends BaseCommand { " -R: repeat the activity launch <COUNT> times. Prior to each repeat,\n" + " the top activity will be finished.\n" + " -S: force stop the target app before starting the activity\n" + " --opengl-trace: enable tracing of OpenGL functions\n" + " --track-allocation: enable tracking of object allocations\n" + " --user <USER_ID> | current: Specify which user to run as; if not\n" + " specified then run as the current user.\n" + Loading Loading @@ -739,8 +738,6 @@ public class Am extends BaseCommand { mRepeat = Integer.parseInt(nextArgRequired()); } else if (opt.equals("-S")) { mStopOption = true; } else if (opt.equals("--opengl-trace")) { mStartFlags |= ActivityManager.START_FLAG_OPENGL_TRACES; } else if (opt.equals("--track-allocation")) { mStartFlags |= ActivityManager.START_FLAG_TRACK_ALLOCATION; } else if (opt.equals("--user")) { Loading
core/java/android/app/ActivityManager.java +1 −8 Original line number Diff line number Diff line Loading @@ -202,19 +202,12 @@ public class ActivityManager { */ public static final int START_FLAG_DEBUG = 1<<1; /** * Flag for IActivityManaqer.startActivity: launch the app for * OpenGL tracing. * @hide */ public static final int START_FLAG_OPENGL_TRACES = 1<<2; /** * Flag for IActivityManaqer.startActivity: launch the app for * allocation tracking. * @hide */ public static final int START_FLAG_TRACK_ALLOCATION = 1<<3; public static final int START_FLAG_TRACK_ALLOCATION = 1<<2; /** * Result for IActivityManaqer.broadcastIntent: success! Loading
core/java/android/app/ActivityThread.java +3 −11 Original line number Diff line number Diff line Loading @@ -469,7 +469,6 @@ public final class ActivityThread { IUiAutomationConnection instrumentationUiAutomationConnection; int debugMode; boolean enableBinderTracking; boolean enableOpenGlTrace; boolean trackAllocation; boolean restrictedBackupMode; boolean persistent; Loading Loading @@ -805,10 +804,9 @@ public final class ActivityThread { ProfilerInfo profilerInfo, Bundle instrumentationArgs, IInstrumentationWatcher instrumentationWatcher, IUiAutomationConnection instrumentationUiConnection, int debugMode, boolean enableBinderTracking, boolean enableOpenGlTrace, boolean trackAllocation, boolean isRestrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) { boolean enableBinderTracking, boolean trackAllocation, boolean isRestrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) { if (services != null) { // Setup the service cache in the ServiceManager Loading Loading @@ -864,7 +862,6 @@ public final class ActivityThread { data.instrumentationUiAutomationConnection = instrumentationUiConnection; data.debugMode = debugMode; data.enableBinderTracking = enableBinderTracking; data.enableOpenGlTrace = enableOpenGlTrace; data.trackAllocation = trackAllocation; data.restrictedBackupMode = isRestrictedBackupMode; data.persistent = persistent; Loading Loading @@ -4776,11 +4773,6 @@ public final class ActivityThread { } } // Enable OpenGL tracing if required if (data.enableOpenGlTrace) { GLUtils.setTracingLevel(1); } // Allow application-generated systrace messages if we're debuggable. boolean isAppDebuggable = (data.appInfo.flags & ApplicationInfo.FLAG_DEBUGGABLE) != 0; Trace.setAppTracingAllowed(isAppDebuggable); Loading
core/java/android/app/ApplicationThreadNative.java +5 −8 Original line number Diff line number Diff line Loading @@ -294,7 +294,6 @@ public abstract class ApplicationThreadNative extends Binder IUiAutomationConnection.Stub.asInterface(binder); int testMode = data.readInt(); boolean enableBinderTracking = data.readInt() != 0; boolean openGlTrace = data.readInt() != 0; boolean trackAllocation = data.readInt() != 0; boolean restrictedBackupMode = (data.readInt() != 0); boolean persistent = (data.readInt() != 0); Loading @@ -304,8 +303,8 @@ public abstract class ApplicationThreadNative extends Binder Bundle coreSettings = data.readBundle(); bindApplication(packageName, info, providers, testName, profilerInfo, testArgs, testWatcher, uiAutomationConnection, testMode, enableBinderTracking, openGlTrace, trackAllocation, restrictedBackupMode, persistent, config, compatInfo, services, coreSettings); trackAllocation, restrictedBackupMode, persistent, config, compatInfo, services, coreSettings); return true; } Loading Loading @@ -1020,10 +1019,9 @@ class ApplicationThreadProxy implements IApplicationThread { List<ProviderInfo> providers, ComponentName testName, ProfilerInfo profilerInfo, Bundle testArgs, IInstrumentationWatcher testWatcher, IUiAutomationConnection uiAutomationConnection, int debugMode, boolean enableBinderTracking, boolean openGlTrace, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException { boolean enableBinderTracking, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException { Parcel data = Parcel.obtain(); data.writeInterfaceToken(IApplicationThread.descriptor); data.writeString(packageName); Loading @@ -1046,7 +1044,6 @@ class ApplicationThreadProxy implements IApplicationThread { data.writeStrongInterface(uiAutomationConnection); data.writeInt(debugMode); data.writeInt(enableBinderTracking ? 1 : 0); data.writeInt(openGlTrace ? 1 : 0); data.writeInt(trackAllocation ? 1 : 0); data.writeInt(restrictedBackupMode ? 1 : 0); data.writeInt(persistent ? 1 : 0); Loading
core/java/android/app/IApplicationThread.java +4 −4 Original line number Diff line number Diff line Loading @@ -96,10 +96,10 @@ public interface IApplicationThread extends IInterface { void bindApplication(String packageName, ApplicationInfo info, List<ProviderInfo> providers, ComponentName testName, ProfilerInfo profilerInfo, Bundle testArguments, IInstrumentationWatcher testWatcher, IUiAutomationConnection uiAutomationConnection, int debugMode, boolean enableBinderTracking, boolean openGlTrace, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException; int debugMode, boolean enableBinderTracking, boolean trackAllocation, boolean restrictedBackupMode, boolean persistent, Configuration config, CompatibilityInfo compatInfo, Map<String, IBinder> services, Bundle coreSettings) throws RemoteException; void scheduleExit() throws RemoteException; void scheduleSuicide() throws RemoteException; void scheduleConfigurationChanged(Configuration config) throws RemoteException; Loading