On Fri, 2024-09-06 at 08:44 -0400, Ben Boeckel via Gcc wrote: > On Tue, Sep 03, 2024 at 16:53:43 +0100, Iain Sandoe wrote: > > I think that might be a misunderstanding on the part of the author; > > AFAIU both GCC and MSVC _do_ require access to the sources at BMI > > consume-time to give decent diagnostics. I think that there might > > be > > confusion because the compilation would suceed on those toolchains > > without the sources - but with poorer diagnostic quality? > > Does this have (additional) implications for caching tools and > modules? > They cache diagnostic output, but if these other paths showing up or > disappearing affects the output, the cache key should incorporate > that > as well.
What kinds of caching tools are you thinking of? I'm curious about caching of diagnostics, and how the diagnostics are represented in the cache. FWIW, SARIF has a way of storing the source associated with a diagnostic (and/or hashes of the source), and GCC's SARIF output uses this to capture the source of any file referred to by path by a diagnostic in the SARIF output (but we don't yet capture hashes of source). Dave > Should there be a way for such tools to get this information > somehow? Ideally the paths would only matter if reported diagnostics > *would* look at the files, not just "there's a BMI that mentions a > source path X" kind of inspection. > > --Ben >