Add support for XFAILing valgrind runs with memory leak checking independently
of runs without leak checking.  We add -vg to the triple for non-checked runs,
or -vg_leak for checked runs.  Also use this to XFAIL the TableGen tests, since
tablegen leaks like a sieve.  This includes some valgrindArgs refactoring.

llvm-svn: 99103
diff --git a/llvm/test/TableGen/subst2.td b/llvm/test/TableGen/subst2.td
index 3366c9d..584266e 100644
--- a/llvm/test/TableGen/subst2.td
+++ b/llvm/test/TableGen/subst2.td
@@ -1,4 +1,5 @@
 // RUN: tblgen %s | FileCheck %s
+// XFAIL: vg_leak
 // CHECK: No subst
 // CHECK: No foo
 // CHECK: RECURSE foo