[llvm] [AMDGPU][test]added remove duplicate options for update_mc_test_check script (PR #111769)

Brox Chen via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 15 06:27:05 PDT 2024


================
@@ -118,6 +119,19 @@ def main():
         default=None,
         help="Set a default -march for when neither triple nor arch are found in a RUN line",
     )
+    parser.add_argument(
+        "--remove-duplicate",
+        action="store_true",
+        default=False,
+        help="remove duplicated test line if found",
+    )
+    parser.add_argument(
+        "--sort",
+        action="store_true",
+        default=False,
+        help="sort testline in alphabetic order (keep run-lines on top), this option could be dangerous as it"
+        "could change the order of lines that are not expected",
----------------
broxigarchen wrote:

I think this might be hard to determine. i.e. the `//comment 2` can be a comment for the whole section bellow, and it should be kept even though the first testline is removed as a duplication. Thus I tried removing minimum lines when removing duplications and leave this to the user.

What do you think?

https://github.com/llvm/llvm-project/pull/111769


More information about the llvm-commits mailing list