I thought that the consensus from the most recent LLVM Developer Conference was to not remove opcode support except on major releases. Deprecating an opcode (not using it further with BitcodeWriter) and generating new opcodes was considered reasonable. This would seem to go directly against that. I would prefer that changes like this get reverted before 3.2.<div>
<br></div><div>Steve<br><br><div class="gmail_quote">On Tue, May 22, 2012 at 2:01 PM, Bill Wendling <span dir="ltr"><<a href="mailto:wendling@apple.com" target="_blank">wendling@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On May 22, 2012, at 3:55 AM, Kuperstein, Michael M wrote:<br>
<br>
> Hello,<br>
><br>
> The commit below (156383) broke binary compatibility with LLVM 3.0.<br>
> The LLVM 3.1 branch generates bitcode files with the new TYPE_CODE_FUNCTION, and can read both. However, 3.0 still generated TYPE_CODE_FUNCTION_OLD (it is named TYPE_CODE_FUNCTION in 3.0, the change to OLD was made somewhere between 3.0 and the final 3.1 branch) records. This means 3.1 is still able to read 3.0 bitcode, but 3.2 will not be able to.<br>

><br>
> I'm attaching a small test-case. I will be happy to provide a proper patch that resurrects TYPE_CODE_FUNCTION_OLD, if that's helpful.<br>
><br>
</div>I'm not really in favor of reverting this behavior. The old code was in there by accident. It's unfortunate that some bitcodes were generated with the outdated codes, but it's not something we should wish to perpetuate. There is a workaround: use the 3.0 or 3.1 `llvm-dis' tool to create a text version of the bitcode file and then run the new `llvm-as' on it.<br>

<span class="HOEnZb"><font color="#888888"><br>
-bw<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
</div></div></blockquote></div><br></div>