<div dir="ltr">We don't need this behavior for non-ELF ports. Maybe we should document that the symbols are ordered in outputs as they are resolved.</div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Mar 4, 2015 at 11:38 AM, Shankar Easwaran <span dir="ltr"><<a href="mailto:shankare@codeaurora.org" target="_blank">shankare@codeaurora.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On 3/4/2015 1:25 PM, Rui Ueyama wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Wed, Mar 4, 2015 at 11:22 AM, Shankar Kalpathi Easwaran <<br>
<a href="mailto:shankarke@gmail.com" target="_blank">shankarke@gmail.com</a>> wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
================<br>
Comment at: lib/Core/Resolver.cpp:84<br>
@@ -83,3 +83,3 @@<br>
      if (const File *member = archiveFile->find(undefName,<br>
dataSymbolOnly)) {<br>
-      member->setOrdinal(_ctx.<u></u>getNextOrdinalAndIncrement());<br>
+      member->setOrdinal(<u></u>archiveFile->ordinal() + _memberOrdinal++);<br>
        const_cast<File *>(member)->beforeLink();<br>
----------------<br>
The member ordinal seems wrong, it should be the next ordinal available<br>
for GNU.<br>
</blockquote>
<br>
Why do you think so?<br>
</blockquote></div></div>
As that is how the input files were picked by the resolver. If a different behavior is needed, may be add a linkingContext function to return the ordinal by passing a file ?<div class="HOEnZb"><div class="h5"><br>
<br>
Shankar Easwaran<br>
<br>
-- <br>
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by the Linux Foundation<br>
<br>
</div></div></blockquote></div><br></div>