Extensions: Make it possible for permission parsing code to return a detailed error message.

BUG=337758

Review URL: https://codereview.chromium.org/141743005

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247624 0039d316-1c4b-4281-b951-d872f2087c98
SVN changes up to revision 247624
cc: Add useful TaskGraphRunner performance tests.

Current perf tests are not useful for profiling as output heavily
depends on kernel scheduling. An improvement in CPU time is not
guaranteed to result in a better result from these tests as they
mostly measure context switching cost.

This includes a small refactor to TaskGraphRunner that allow us
to run tests on a single thread. The result is more predictable
results and useful profiling output.

The number of tasks used in tests have also been adjusted to more
realistic values.

BUG=338355

Review URL: https://codereview.chromium.org/147883003

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247625 0039d316-1c4b-4281-b951-d872f2087c98
SVN changes up to revision 247625