<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Jul 31, 2015, at 11:28 AM, Mehdi Amini <<a href="mailto:mehdi.amini@apple.com" class="">mehdi.amini@apple.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><blockquote type="cite" class=""><div class=""><br class="Apple-interchange-newline">On Jul 31, 2015, at 10:56 AM, Eric Christopher <<a href="mailto:echristo@gmail.com" class="">echristo@gmail.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class=""><div class="gmail_quote"><div dir="ltr" class=""><br class=""></div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex;">On 30 July 2015 at 14:52, Daniel Sanders <<a href="mailto:Daniel.Sanders@imgtec.com" target="_blank" class="">Daniel.Sanders@imgtec.com</a>> wrote:<br class="">> We will need a string serialization of the TargetTuple so that we can store it in the IR and read it back.<br class=""><br class="">Why does it have to be in the IR? If every tool that deals with IR has<br class="">the same options and they mean the same thing I don't see why we'd<br class="">need that.<br class=""><br class=""></blockquote><div class=""><br class=""></div><div class="">I agree with the need for serializing information and options into the module.</div><div class=""> </div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex; border-left-width: 1px; border-left-color: rgb(204, 204, 204); border-left-style: solid; padding-left: 1ex;"><br class="">> Whether this is in one piece (e.g. 'target tuple = "...") or multiple pieces (e.g. 'target arch = "..."', 'target endian = "..."') doesn't matter too much at first but I can see the benefits of the latter being the end point. If we do choose that multiple pieces then I'd like to pass through the former first to keep the early steps of the migration to a TargetTuple as simple and mechanical as possible.<br class=""><br class="">Assuming we really need it, wouldn't it work if we put in metadata?<br class="">That way, it would bloat the IR of targets that really needed it and<br class="">not the ones that don't, at the same time as being non-critical to<br class="">parsing and validating the IR, so you could safely drop some<br class="">information without breaking the file.<br class=""><br class=""></blockquote><div class=""><br class=""></div><div class="">Metadata won't work. Metadata is defined to not affect code correctness and this obviously does.</div></div></div></div></blockquote><div class=""><br class=""></div><div class=""><br class=""></div></div><span style="font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; float: none; display: inline !important;" class="">Is it true for Module level Metadata and not only for instruction attached one?</span></div></blockquote><br class=""></div><div>There are examples of module-level metadata that impact the correctness of the generated code in the LangRef today:</div><div><br class=""></div><div><a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_docs_LangRef.html-23module-2Dflags-2Dmetadata&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=Mfk2qtn1LTDThVkh6-oGglNfMADXfJdty4_bhmuhMHA&m=Df2FVmIg_iCZcqaWD1PoOESqqAqFyCC2XBL86Q3a0Do&s=3Rd_gvHgetp-KpHnI0Dl83wJc-5e2WKur-C5OLCAzOQ&e=" class="">http://llvm.org/docs/LangRef.html#module-flags-metadata</a></div><div><a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_docs_LangRef.html-23objective-2Dc-2Dgarbage-2Dcollection-2Dmodule-2Dflags-2Dmetadata&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=Mfk2qtn1LTDThVkh6-oGglNfMADXfJdty4_bhmuhMHA&m=Df2FVmIg_iCZcqaWD1PoOESqqAqFyCC2XBL86Q3a0Do&s=dwqW64nc-YX_8l8BJ4UJm--QpQ6nEJyNl11im7ns4gM&e=" class="">http://llvm.org/docs/LangRef.html#objective-c-garbage-collection-module-flags-metadata</a></div><div><a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_docs_LangRef.html-23automatic-2Dlinker-2Dflags-2Dmodule-2Dflags-2Dmetadata&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=Mfk2qtn1LTDThVkh6-oGglNfMADXfJdty4_bhmuhMHA&m=Df2FVmIg_iCZcqaWD1PoOESqqAqFyCC2XBL86Q3a0Do&s=S6M_H7EIyw3upa1RiiPk8JSbXwff-LJXMZN0iO4Wo-8&e=" class="">http://llvm.org/docs/LangRef.html#automatic-linker-flags-module-flags-metadata</a></div><div><a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__llvm.org_docs_LangRef.html-23c-2Dtype-2Dwidth-2Dmodule-2Dflags-2Dmetadata&d=AwMFaQ&c=8hUWFZcy2Z-Za5rBPlktOQ&r=Mfk2qtn1LTDThVkh6-oGglNfMADXfJdty4_bhmuhMHA&m=Df2FVmIg_iCZcqaWD1PoOESqqAqFyCC2XBL86Q3a0Do&s=oWkxYYj8z-BPX5yyd568PUgpzFaXyLutC0fwLKfq2do&e=" class="">http://llvm.org/docs/LangRef.html#c-type-width-module-flags-metadata</a></div><div><br class=""></div><div>—Owen</div><br class=""></body></html>