[LLVMdev] Clarification on the backward compatibility promises

Rafael Espíndola
2014-06-17T21:42:50Z

>> I think we have a special case for debug metadata (and should document
>> that), but otherwise I think we should hold metadata to the same
>> standard as the rest of the IR.
>>
>
> The idea with metadata is that it can be removed and everything still
> works. I'm definitely not ready to lock down the debug metadata format
> and I really don't think we should for any of the other uses since
> stripping already works. (Note, I don't consider function attributes
> etc as metadata)

I think we mean the same thing in the end. Since metadata can be
dropped, one particular way in which upgrade can be done for an old
format is to drop it. This would miss any optimization that the old
format was intended to allow, but we don't promise to keep
optimizations.

What would not be OK is for us to change the format (for example, make
range take a closed interval) and start miscompiling IR that had the
old format in it.

Debug metadata is special only in that we accept more than a missed
optimization when it is dropped, and I agree it should remain like
that for now.

Cheers,
Rafael