<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Apr 20, 2016 at 12:28 PM, Rafael Espíndola <span dir="ltr"><<a href="mailto:rafael.espindola@gmail.com">rafael.espindola@gmail.com</a>></span> wrote:<br><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"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span class="gmail-"><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"><div style="word-wrap:break-word"><div><div><div><div><br></div></div></div><div>I understood from his description that he reversed the destination and source so that destination is the user code.</div><div>I assumed it was not lazy loaded, but that would explain the question then :)</div><div><br></div><div>Neil: can you clarify? If Teresa is right, why aren't you materializing the destination module entirely?</div><span><div><br></div></span></div></div></blockquote><div><br></div><div><br></div></span><div>I don't think it has ever been tried to use a lazy destination. Having said that, I don't think isMaterializable should return true for a declaration.</div></div></div></div></blockquote><div><br></div><div>Looking at isMaterializable, I'm now a little confused about Neil's case - the materializable bit is set to true only when the MODULE_CODE_FUNCTION indicated that it was !isproto, which means it should have a definition in that module. So I agree with you that isMaterializable shouldn't be returning true when the symbol is only available as a declaration. <br></div><div><br></div><div>Neil - what case are you trying to handle here? If there is a materializable definition in the dest module, wouldn't you want to use that instead of linking one in from the source module?</div><div><br></div><div>Teresa</div><div><br></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"><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><span class="gmail-"><div><br></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"><div style="word-wrap:break-word"><div><span><div><br></div></span><div>Even materializing functions from the source module on the fly isn't supported right now, is it?</div><span><font color="#888888"><div><br></div></font></span></div></div></blockquote><div> </div></span><div>It is.</div><div><br></div><div>Neil, the flag is linked to llvm-link's -only-needed command line option. At least for simple cases it seems to be working. Given</div><div><br></div><div><div>declare void @g()</div><div>define void @f() {</div><div> call void @g()</div><div> ret void</div><div>}</div></div><div><br></div><div>and</div><div><br></div><div><div>define void @g() {</div><div> ret void</div><div>}</div><div>define void @h() {</div><div> ret void</div><div>}</div></div><div><br></div><div><br></div><div>linking with "llvm-link -only-needed test1.bc test2.bc" will bring in g, but not h. Can you write a testcase showing what you were expecting it to do but it is not?</div><div><br></div><div>Cheers,</div><div>Rafael</div><div><br></div></div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><span style="font-family:times;font-size:medium"><table cellspacing="0" cellpadding="0"><tbody><tr style="color:rgb(85,85,85);font-family:sans-serif;font-size:small"><td nowrap style="border-top-style:solid;border-top-color:rgb(213,15,37);border-top-width:2px">Teresa Johnson |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(51,105,232);border-top-width:2px"> Software Engineer |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(0,153,57);border-top-width:2px"> <a href="mailto:tejohnson@google.com">tejohnson@google.com</a> |</td><td nowrap style="border-top-style:solid;border-top-color:rgb(238,178,17);border-top-width:2px"> 408-460-2413</td></tr></tbody></table></span></div>
</div></div>