mstorsjo added a comment.

In https://reviews.llvm.org/D48626#1146282, @simon_tatham wrote:

> Although, come to think of it, that's not good enough, because if you have 
> multiple directories on your include //path// then you expect a lot of 
> lookups to fail for reasons that have nothing to do with case. Say, if you 
> compile with `-Ifoo -Ibar`, then every include of a file intended to be found 
> in `bar` will force lots of pointless directory enumeration in `foo` when the 
> initial lookup there doesn't find the file. Hmmm. That suggests to me that 
> perhaps this ought not to be a //global// `-ffudge-my-paths` type option 
> applying to all include directories, and instead perhaps it should be a new 
> kind of `-I` option, so that only lookups relative to that particular 
> include-path directory would get the unusual semantics. What do people think?


The cases where I would have needed this (the windows sdk), I'm not specifying 
that path explicitly via `-I` directives, but implicitly via the `INCLUDE` env 
variable, but perhaps limiting this to the directories known to have 
problematic case could be helpful performance wise.

Otherwise I guess this would need to go on a higher level in the algorithm; 
first check all directories in a fully case sensitive manner, just like today. 
And if that fails (and we'd have a real failure that we'd otherwise return to 
the caller), redo it all with case insensitivity. I think that would be the 
best performance wise, but that makes for much messier integration...


Repository:
  rC Clang

https://reviews.llvm.org/D48626



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to