[PATCH] D31096: LTO, Support: Add a safeguard against pruning a directory that is not a cache directory.

Peter Collingbourne via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 17 13:58:43 PDT 2017


pcc added a comment.

In https://reviews.llvm.org/D31096#704217, @mehdi_amini wrote:

> In https://reviews.llvm.org/D31096#704183, @pcc wrote:
>
> > Ivan suggested that we can just use a hidden directory inside the user-supplied directory as the cache directory. I like that approach better, so I'm abandoning this.
>
>
> Not sure how it'll look like...
>
> What about pattern-matching the list of files to see if any don't  have the expected name structure? The linker could warn (or error) when supplied such a directory as cache).


Thinking about it a little more, that does seem a little less surprising. We can require all files to have the prefix `llvmcache-` or something.


https://reviews.llvm.org/D31096





More information about the llvm-commits mailing list