Use a single lock and add a flag.
Using separate locks adds a little bit of overhead to the get method. Switch to a single lock to minimize the performance cost. Also add a control flag to disable caching in the future, if so desired. Bug: 257054989 Test: atest CorePerfTests:AccountManagerPerfTest Change-Id: I5bbcc54f28cbe3c434995af8b3452debfc68c4ee
Loading
Please register or sign in to comment