<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Thu, Jun 5, 2014 at 1:55 PM, Rafael Espíndola <span dir="ltr"><<a href="mailto:rafael.espindola@gmail.com" target="_blank">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 class="">On 5 June 2014 16:40, Reid Kleckner <<a href="mailto:rnk@google.com">rnk@google.com</a>> wrote:<br>

> This seems wrong for associative comdats.  Won't the comdat symbol<br>
> necessarily be in a different section?<br>
<br>
</div>Not if I am reading the spec correctly. It looks like this situation<br>
will look like:<br>
<br>
* Section foo has the following symbols in order:<br>
  * The symbol foo, which has an auxiliary symbol with a Seltion field<br>
with IMAGE_COMDAT_SELECT_ASSOCIATIVE and a Number field pointing to<br>
the associated section.<br>
  * The comdat symbol, which can be anything, lets say bar<br>
<br>
The associated section can have any name, lets say zed. It has the<br>
following symbols<br>
* The symbol zed. The only constraint being that it is not itself associative.<br>
* The comdat symbol, with can be any other symbol, bah for example.<br>
<br>
In summary, each section has a different comdat symbol. The link of<br>
associative sections is independent of the comdat, except that they<br>
probably cannot have the some comdat, otherwise we would be asking the<br>
linker to keep both and discard one at the same time :-)</blockquote><div><br></div><div>This patch looks good to me, but see my comment on <a href="http://llvm.org/PR19960">http://llvm.org/PR19960</a> for how I think we should deal with associative comdats.</div>
</div></div></div>