[all-commits] [llvm/llvm-project] 8bc2c6: [Utils] Add prefix parameter in update test checks...

Giorgis Georgakoudis via All-commits all-commits at lists.llvm.org
Fri Mar 26 11:50:00 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 8bc2c662d9c0f241fb8538979f8db1af7f2e353e
      https://github.com/llvm/llvm-project/commit/8bc2c662d9c0f241fb8538979f8db1af7f2e353e
  Author: Giorgis Georgakoudis <georgakoudis1 at llnl.gov>
  Date:   2021-03-26 (Fri, 26 Mar 2021)

  Changed paths:
    A clang/test/utils/update_cc_test_checks/Inputs/resolve-tmp-conflict.cpp
    A clang/test/utils/update_cc_test_checks/Inputs/resolve-tmp-conflict.cpp.expected
    A clang/test/utils/update_cc_test_checks/resolve-tmp-conflict.test
    M llvm/utils/UpdateTestChecks/common.py

  Log Message:
  -----------
  [Utils] Add prefix parameter in update test checks to avoid FileCheck conflicts

IR values convert to check prefix FileCheck variables for IR checks. For example, nameless values, e.g., %0, convert to check prefix TMP FileCheck variables, e.g., [[TMP0:%.*]]. This check prefix may clash with named values that have the same name and that causes auto-generated tests to fail. Currently a warning is emitted to change the names of the IR values but this is not always possible, if for example they are generated by clang. Manual intervention to fix the FileCheck variable names is too tedious. This patch add a parameter to prefix conflicting FileCheck variable names with a user-provided string to automate the process.

Reviewed By: jdoerfert

Differential Revision: https://reviews.llvm.org/D99415




More information about the All-commits mailing list