[all-commits] [llvm/llvm-project] a59004: [RISCV][test] Make PATH empty when testing --gcc-t...

luxufan via All-commits all-commits at lists.llvm.org
Mon Mar 28 23:52:28 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a5900401b1475cdf98dbd210ac4bc362563cebbf
      https://github.com/llvm/llvm-project/commit/a5900401b1475cdf98dbd210ac4bc362563cebbf
  Author: luxufan <luxufan at iscas.ac.cn>
  Date:   2022-03-29 (Tue, 29 Mar 2022)

  Changed paths:
    M clang/test/Driver/riscv32-toolchain.c
    M clang/test/Driver/riscv64-toolchain.c

  Log Message:
  -----------
  [RISCV][test] Make PATH empty when testing --gcc-toolchain is multilib_riscv_elf_sdk

Due to D79842, clang dirver would search possible tool name in both possible
locations, then moving to the next name. The gcc toolchain `llvm-project/clang/test/Driver/
Inputs/multilib_riscv_elf_sdk` don't have a `riscv64-unknown-elf-ld` executable in
`llvm-project/clang/test/Driver/Inputs/multilib_riscv_elf_sdk/bin/`. So when searching
`riscv64-unknown-elf-ld`, if there is a `riscv64-unknown-elf-ld` in `PATH`, the
test would fail.

This patch makes the `PATH` empty when testing it.

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




More information about the All-commits mailing list