[DebugInfo] Add Verifier check for duplicate arg indices in SP's retainedNodes list (#186225)
DwarfFile asserts if two arguments of the same subprogram with the same
index are present in a DISubprogram scope:
https://github.com/llvm/llvm-project/blob/5d7a502a9d923784abe4382ec479ee1c0667d743/llvm/lib/CodeGen/AsmPrinter/DwarfFile.cpp#L110
This patch adds a check to the Verifier to detect such invalid IR
earlier. It can be helpful for finding reproducers for bugs like
https://issues.chromium.org/issues/40288032.
The incorrect args field of DILocalVariable in
llvm/test/DebugInfo/MIR/X86/live-debug-values-reg-copy.mir is fixed.