Remove advisory registerNativeAllocation().
After consulting with the ART team, we learned that sending them detailed advisory native allocation sizes isn't as useful when the overall lifecycle of the object is tightly managed, which is the case with Parcel objects. (Because Parcel users use explicit obtain() and recycle() methods, any variable-sized native allocations have already been freed by the time a Parcel instance is considered for GC.) The Parcel benchmarks referenced below are showing a uniform ~3% performance improvement across 1, 4, and 16 thread cases. Note that this is in addition to the improvements recently made with the shift to a linked-list pooling design. Bug: 165032569 Test: ./frameworks/base/libs/hwui/tests/scripts/prep_generic.sh little && atest CorePerfTests:android.os.ParcelObtainPerfTest Change-Id: Id0ce9b3bff1d0ffb426a9f105c7a54eb00060f85
Loading
Please register or sign in to comment