Add a few fine-grained locks in the ActivityManagerService

To reduce the lock contention in ActivityManagerService,
this CL added a few fine-grained locks, such as process profiling,
UID state change dispatching, etc.

Other changes include using inclusive languages, moving the code of
dumping processes to ProcessList.

Bug: 162450085
Test: atest CtsAppTestCases
Test: atest FrameworksMockingServicesTests
Test: atest FrameworksServicesTests
Change-Id: Id86fee25031679456e753f1158da2c7852e85e91
32 files changed