Update IntentResolver snapshots

Bug: 179652745

Update IntentResolver snapshots to deep-copy the arrays that are part
of the maps.  This change makes copies of the IntentFilter arrays but
the IntentFilter elements are still copied by reference.  Therefore,
this change addresses the race condition of the bug but does not
address dynamic mime types as per the comment.

With this change, the steady-state overhead of a snapshot is
approximately 1.4Mb relative to not using snapshots at all.  This was
measured by comparing the rss (mean of five runs) and pss of three
images:
 * disabled - snapshots disabled
 * baseline - snapshots enabled, without this CL
 * proposed - snapshots enabled, with this CL

Test: atest
 * FrameworksServicesTests:AppsFilterTest
 * FrameworksServicesTests:PackageInstallerSessionTest
 * FrameworksServicesTests:PackageManagerServiceTest
 * FrameworksServicesTests:PackageManagerSettingsTests
 * FrameworksServicesTests:ScanTests
 * FrameworksServicesTests:UserSystemPackageInstallerTest
 * PackageManagerServiceBootTest
 * UserLifecycleTests#startUser
 * UserLifecycleTests#stopUser
 * UserLifecycleTests#switchUser
 * android.appsecurity.cts.EphemeralTest
 * android.appsecurity.cts.InstantAppUserTest

Change-Id: I704bf8e6c0888c2ffb9563e188ebd8ac91c2f597
1 file changed