[time-trace] Add optimizer and codegen regions to NPM

Optimizer and codegen regions were only added to legacy PM. Add
them to NPM as well.

Differential Revision: https://reviews.llvm.org/D117605
1 job for llvm.org/main in 17 minutes and 43 seconds (queued for 4 seconds)