[IRPrinting] Improve module pass printer to work better with -filter-print-funcs
Summary: Previously module pass printer pass prints the banner even when the module doesn't include any function provided with -filter-print-funcs option. This introduced a lot of noise, especailly with ThinLTO. This diff addresses the issue and makes the banner printed only when the module includes functions in -filter-print-funcs list.
Subscribers: mehdi_amini, hiraditya, dexonsmith, llvm-commits
Differential Revision: https://reviews.llvm.org/D66560