diff options
author | Yurii Zubrytskyi <zyy@google.com> | 2020-04-07 15:35:21 -0700 |
---|---|---|
committer | Yurii Zubrytskyi <zyy@google.com> | 2020-04-10 12:30:49 -0700 |
commit | da208016d65c331218ed3a1acd2f45d5ca4ce006 (patch) | |
tree | 8ebc8a5a7a7d400e5e9ef3988331ac7043b54d17 /services/incremental/BinderIncrementalService.h | |
parent | b78a0f462e20676e4758a3f966c6f898cf95a2a7 (diff) |
[incfs] Make native library extraction async
IncrementalService can create the library files beforehand, but
delay filling in their data. As it takes quite a while in
general (over a second in cases when the phone is busy), it's
better to run the unzipping and filling in a separate thread
and only make sure it finishes before the whole installation
process is complete.
This speeds up the megacity.apk installation by ~250-300ms,
1000-1100ms -> 750-800ms
Bug: 153513507
Test: adb install megacity.apk
Change-Id: Ia44f7e45b9e0abaebdfb6fe5352f9dcf29ab4ece
Diffstat (limited to 'services/incremental/BinderIncrementalService.h')
-rw-r--r-- | services/incremental/BinderIncrementalService.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/services/incremental/BinderIncrementalService.h b/services/incremental/BinderIncrementalService.h index 28613e101b7c..aca10ab6d591 100644 --- a/services/incremental/BinderIncrementalService.h +++ b/services/incremental/BinderIncrementalService.h @@ -38,7 +38,10 @@ public: void onInvalidStorage(int mountId); binder::Status openStorage(const std::string& path, int32_t* _aidl_return) final; - binder::Status createStorage(const ::std::string& path, const ::android::content::pm::DataLoaderParamsParcel& params, const ::android::sp<::android::content::pm::IDataLoaderStatusListener>& listener, int32_t createMode, int32_t* _aidl_return) final; + binder::Status createStorage( + const ::std::string& path, const ::android::content::pm::DataLoaderParamsParcel& params, + const ::android::sp<::android::content::pm::IDataLoaderStatusListener>& listener, + int32_t createMode, int32_t* _aidl_return) final; binder::Status createLinkedStorage(const std::string& path, int32_t otherStorageId, int32_t createMode, int32_t* _aidl_return) final; binder::Status makeBindMount(int32_t storageId, const std::string& sourcePath, @@ -68,9 +71,11 @@ public: std::vector<uint8_t>* _aidl_return) final; binder::Status startLoading(int32_t storageId, bool* _aidl_return) final; binder::Status deleteStorage(int32_t storageId) final; + binder::Status configureNativeBinaries(int32_t storageId, const std::string& apkFullPath, const std::string& libDirRelativePath, const std::string& abi, bool* _aidl_return) final; + binder::Status waitForNativeBinariesExtraction(int storageId, bool* _aidl_return) final; private: android::incremental::IncrementalService mImpl; |