hms-unity-plugin icon indicating copy to clipboard operation
hms-unity-plugin copied to clipboard

[HUP-848] Perf: Update HMSIAPManager.cs to include product information retrieval and logging, and also updated HuaweiMobileService.dll file.

Open Andronovo-bit opened this issue 1 year ago • 0 comments

Performance Improves

  • Optimize product info filtering using HashSet

  • Refactor product info handling for performance optimization. Replace O(n^2) nested loop structure with O(n) HashSet-based lookup.

Imagine productInfoList has 1000 items.

Before: Might perform on the order of 1000 * 1000 = 1,000,000 checks. After: Likely performs around 1000 checks (hashset lookups) + 1000 iterations/inserts at most.

Test

This feature was tested on Android 14 and didn't result in any errors.

Reviewer

@alihan98ersoy

Andronovo-bit avatar Apr 26 '24 12:04 Andronovo-bit