On Mon, Jul 4, 2022 at 10:42 AM Eric Botcazou <botca...@adacore.com> wrote:
>
> > For late generated vector types this might result in inconsistencies with
> > early (user) generated types when using LTO.
>
> Is that a problem?  That's no different with regular array types.

I'm not sure - almost all types the user can actually inspect should have early
debug info.

> > Is there context available somehow so we can do like the is_<LANG> overloads
> > on a decl and use a default according to that?
>
> Not sure, the only safe thing to do would be to return -1 as the default lower
> bound if flag_generate_lto.

Rather if in_lto_p, but yes, this sounds like a good thing to do.  OTOH if
the used language is uniform LTO will pick that, it will "merge" C/C++
and otherwise use C as fallback in a mixed environment.

So the patch is quite likely OK as-is.

Which means .. OK.

Thanks,
Richard.

> --
> Eric Botcazou
>
>

Reply via email to