The Assignment Tracking debug-info feature is outlined in this RFC. This first series of patches adds documentation, the changes necessary to start emitting and using the new metadata, and updates clang with an option to enable the feature. Working with the new metadata in the middle and back end will come later. There are still a few rough edges but I'm putting these patches up now hoping to get feedback on the design and implementation from the upstream community.
This patch plumbs the AssignmentTrackingPass (AKA declare-to-assign), added in the previous patch in this set, into the optimisation pipeline from clang. clang/test/CodeGen/assignment-tracking/assignment-tracking.cpp is the main test for this patch.
Note: while clang (with the help of the declare-to-assign pass) can now emit Assignment Tracking metadata, the llvm middle and back ends don't yet understand it.
Small risk that this is running "too much" of LLVM, and spurious changes will cause clang tests to fail. To me, it feels alright though.
I suspect that if it's in the clang CodeGen dir, then you should be using %clang_cc1 or whatever the macro is, and the cc1 command line to run this test. Same with the other tests.