[all-commits] [llvm/llvm-project] f65b0b: Revert "[VFS] RedirectingFileSystem only replace p...

Ben Barham via All-commits all-commits at lists.llvm.org
Tue Apr 5 14:25:06 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f65b0b5dcfeb04e9e6794b32a075432ce3de1ccd
      https://github.com/llvm/llvm-project/commit/f65b0b5dcfeb04e9e6794b32a075432ce3de1ccd
  Author: Ben Barham <ben_barham at apple.com>
  Date:   2022-04-05 (Tue, 05 Apr 2022)

  Changed paths:
    M clang/lib/Basic/FileManager.cpp
    R clang/test/VFS/external-names-multi-overlay.c
    M llvm/include/llvm/Support/VirtualFileSystem.h
    M llvm/lib/Support/VirtualFileSystem.cpp
    M llvm/unittests/Support/VirtualFileSystemTest.cpp

  Log Message:
  -----------
  Revert "[VFS] RedirectingFileSystem only replace path if not already mapped"

This reverts commit 3fda0edc51fd68192a30e302d45db081bb02d7f9, which
breaks crash reproducers in very specific circumstances. Specifically,
since crash reproducers have `UseExternalNames` set to false, the
`File->getFileEntry().getDir()->getName()` call in `DoFrameworkLookup`
would use the *cached* directory name instead of the directory of the
looked-up file.

The plan is to re-commit this patch but to *add*
`ExposesExternalVFSPath` rather than replace `IsVFSMapped`.

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




More information about the All-commits mailing list