[clang][Dependency Scanning] Canonicalize Defines of a Compiler Invocation As Early As Possible (#159620)
Before this patch, we only perform `-D` canonicalization on the deep
copy of the `CompilerInvocation` instance, since the canonicalization
should have no impact on scanning.
However, in the presence of CAS, the content of the `builtin` macros are
included in the context hash. This patch makes sure that we canonicalize
the scanning `CompilerInvocation`'s `-D`s.
Part of work for rdar://136303612.
---------
Co-authored-by: Jan Svoboda <jan@svoboda.ai>