Skip to content
Commit c2080995 authored by Jeff Sharkey's avatar Jeff Sharkey
Browse files

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
parent 95e32f0f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment