What is exactly counted as pipeline time taken

I’m trying to understand all the times which are included in gitlab pipeline run

According to a pipeline I ran, time taken should be less than actual time shown.

So the pipeline took 20m 26sec.
Now if I take a look at jobs that ran:

Time taken should be: (build + Integration tests): ~19min(build, static analysis and unit test run in parallel and integration test only needs build).

So where is this discrepancy coming from?

  • If a manual job is waiting is that time counted?*
  • If a job is waiting on resources is the time counted(job is in waiting state).