/**
   * The main function called when started through the zygote process. This
   * could be unified with main(), if the native code in nativeFinishInit()
   * were rationalized with Zygote startup.<p>
   *
   * Current recognized args:
   * <ul>
   *   <li> <code> [--] &lt;start class name&gt;  &lt;args&gt;
   * </ul>
   *
   * @param targetSdkVersion target SDK version
   * @param argv arg strings
   */
  public static final void zygoteInit(int targetSdkVersion, String[] argv, ClassLoader classLoader)
      throws ZygoteInit.MethodAndArgsCaller {
    if (DEBUG) Slog.d(TAG, "RuntimeInit: Starting application from zygote");

    Trace.traceBegin(Trace.TRACE_TAG_ACTIVITY_MANAGER, "RuntimeInit");
    redirectLogStreams();

    commonInit();
    nativeZygoteInit();
    applicationInit(targetSdkVersion, argv, classLoader);
  }
  /**
   * The main function called when an application is started through a wrapper process.
   *
   * <p>When the wrapper starts, the runtime starts {@link RuntimeInit#main} which calls {@link
   * WrapperInit#main} which then calls this method. So we don't need to call commonInit() here.
   *
   * @param targetSdkVersion target SDK version
   * @param argv arg strings
   */
  public static void wrapperInit(int targetSdkVersion, String[] argv)
      throws ZygoteInit.MethodAndArgsCaller {
    if (DEBUG) Slog.d(TAG, "RuntimeInit: Starting application from wrapper");

    applicationInit(targetSdkVersion, argv, null);
  }