<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="/rss.xsl.xml"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
<channel>
    <title>Changes in comdat-selection.s</title>
    <description></description>
    <language>en</language>
    <copyright>Copyright 2015</copyright>
    <generator>Java</generator><item>
        <title>45b8a741 - [LLD][COFF] When using LLD-as-a-library, always prevent re-entrance on failures</title>
        <link>http://172.16.0.5:8080/history/llvm-project-15.0.7/lld/test/COFF/comdat-selection.s#45b8a741</link>
        <description>[LLD][COFF] When using LLD-as-a-library, always prevent re-entrance on failuresThis is a follow-up for D70378 (Cover usage of LLD as a library).While debugging an intermittent failure on a bot, I recalled this scenario whichcauses the issue:1.When executing lld/test/ELF/invalid/symtab-sh-info.s L45, we reach  lld::elf::Obj-File::ObjFile() which goes straight into its base ELFFileBase(),  then ELFFileBase::init().2.At that point fatal() is thrown in lld/ELF/InputFiles.cpp L381, leaving a  half-initialized ObjFile instance.3.We then end up in lld::exitLld() and since we are running with LLD_IN_TEST, we  hapily restore the control flow to CrashRecoveryContext::RunSafely() then back  in lld::safeLldMain().4.Before this patch, we called errorHandler().reset() just after, and this  attempted to reset the associated SpecificAlloc&lt;ObjFile&lt;ELF64LE&gt;&gt;. That tried  to free the half-initialized ObjFile instance, and more precisely its  ObjFile::dwarf member.Sometimes that worked, sometimes it failed and was catched by theCrashRecoveryContext. This scenario was the reason we callederrorHandler().reset() through a CrashRecoveryContext.But in some rare cases, the above repro somehow corrupted the heap, creating astack overflow. When the CrashRecoveryContext&apos;s filter (that is,__except (ExceptionFilter(GetExceptionInformation()))) tried to handle theexception, it crashed again since the stack was exhausted -- and that took thewhole application down. That is the issue seen on the bot. Locally it happensabout 1 times out of 15.Now this situation can happen anywhere in LLD. Since catching stack overflows isnot a reliable scenario ATM when using CrashRecoveryContext, we&apos;re nowpreventing further re-entrance when such failures occur, by signalinglld::SafeReturn::canRunAgain=false. When running with LLD_IN_TEST=2 (or above),only one iteration will be executed, instead of two.Differential Revision: https://reviews.llvm.org/D88348

            List of files:
            /llvm-project-15.0.7/lld/test/COFF/comdat-selection.s</description>
        <pubDate>Thu, 12 Nov 2020 13:14:20 +0000</pubDate>
        <dc:creator>Alexandre Ganea &lt;alexandre.ganea@ubisoft.com&gt;</dc:creator>
    </item>
<item>
        <title>04db8cb9 - lld/coff: Simplify error message for comdat selection mismatches</title>
        <link>http://172.16.0.5:8080/history/llvm-project-15.0.7/lld/test/COFF/comdat-selection.s#04db8cb9</link>
        <description>lld/coff: Simplify error message for comdat selection mismatchesTurns out nobody understands what &quot;conflicting comdat type&quot; is supposed tomean, so just emit a regular &quot;duplicate symbol&quot; error and move the comdatselection information into /verbose output.This also fixes a problem where the error output would depend on the order of.obj files passed. Before this patch:- If passed `one_only.obj discard.obj`, lld-link would only err &quot;conflicting  comdat type&quot;- If passed `discard.obj one_only.obj`, lld-link would err &quot;conflicting comdat  type&quot; and then &quot;duplicate symbol&quot;Now lld-link only errs &quot;duplicate symbol&quot; in both cases.I considered adding a &quot;Detail&quot; parameter to reportDuplicate() that&apos;s printed inparens at the end of the &quot;duplicate symbol&quot; diag if present, and then put thecomdat selection mismatch details there, but since users don&apos;t know what it&apos;ssupposed to mean decided against it. I also considered special-casing theDetail message for one_only/discard mismatches, which in practice means&quot;function defined as inline in TU 1 but as out-of-line in TU 2&quot;, but I wasn&apos;tsure how useful it is so I omitted that too.Differential Revision: https://reviews.llvm.org/D58180llvm-svn: 354006

            List of files:
            /llvm-project-15.0.7/lld/test/COFF/comdat-selection.s</description>
        <pubDate>Thu, 14 Feb 2019 03:16:44 +0000</pubDate>
        <dc:creator>Nico Weber &lt;nicolasweber@gmx.de&gt;</dc:creator>
    </item>
<item>
        <title>9aa55d3c - lld-link: Allow mixing &apos;discard&apos; and &apos;largest&apos; comdat selections</title>
        <link>http://172.16.0.5:8080/history/llvm-project-15.0.7/lld/test/COFF/comdat-selection.s#9aa55d3c</link>
        <description>lld-link: Allow mixing &apos;discard&apos; and &apos;largest&apos; comdat selectionscl.exe and clang-cl.exe put vftables in a &apos;discard&apos; comdat when building withRTTI disabled (/GR-) but in a &apos;largest&apos; comdat when building with RTTI enabled.To be able to link /GR- code with /GR code, lld-link needs to accept comdatsthat have this type of comdat selection conflict.For example, static libraries in the Visual Studio standard library are builtwith /GR, and without this it&apos;s impossible to build client code with /GR- andstill link to the standard library.link.exe also accepts merging &apos;discard&apos; with &apos;largest&apos;, and it accepts merging&apos;largest&apos; with any other selection type. lld-link is still a bit stricter sinceit only allows merging &apos;largest&apos; with &apos;discard&apos; for symmetry.Differential Revision: https://reviews.llvm.org/D57515llvm-svn: 352765

            List of files:
            /llvm-project-15.0.7/lld/test/COFF/comdat-selection.s</description>
        <pubDate>Thu, 31 Jan 2019 16:14:33 +0000</pubDate>
        <dc:creator>Nico Weber &lt;nicolasweber@gmx.de&gt;</dc:creator>
    </item>
<item>
        <title>48dc110e - lld/coff: Implement some support for the comdat selection field</title>
        <link>http://172.16.0.5:8080/history/llvm-project-15.0.7/lld/test/COFF/comdat-selection.s#48dc110e</link>
        <description>lld/coff: Implement some support for the comdat selection fieldLLD used to handle comdats as if the selection field was always set toIMAGE_COMDAT_SELECT_ANY. This means for obj files produced by `cl /Gy`, LLDwould never report a duplicate symbol error.This change:- adds validation for the Selection field (should make no difference in  practice for compiler-generated obj inputs)- rejects comdats that have different Selection fields in different obj files  (likewise). This is a bit more strict but also more self-consistent thank  link.exe (see comment in code)- implements handling for all the selection kindsIn practice, compilers only generate comdats withIMAGE_COMDAT_SELECT_NODUPLICATES (LLD now produces duplicate symbol errors forthese), IMAGE_COMDAT_SELECT_ANY (no behavior change), andIMAGE_COMDAT_SELECT_LARGEST (for RTTI data; here LLD should no longer createbroken executables when linking some TUs with RTTI enabled and some with itdisabled &#8211; but see below).The implementation of `IMAGE_COMDAT_SELECT_LARGEST` is incomplete: If oneSELECT_LARGEST comdat replaces an earlier one, the comdat symbol is replacedcorrectly, but the old section stays loaded and if /opt:ref is disabled (via/opt:noref or /debug) it&apos;s still written to the output. That&apos;s not ideal, butbetter than the current treatment of just picking any one of those comdats. Ihope to fix this better later.Fixes most of PR40094.Differential Revision: https://reviews.llvm.org/D57324llvm-svn: 352590

            List of files:
            /llvm-project-15.0.7/lld/test/COFF/comdat-selection.s</description>
        <pubDate>Wed, 30 Jan 2019 02:17:27 +0000</pubDate>
        <dc:creator>Nico Weber &lt;nicolasweber@gmx.de&gt;</dc:creator>
    </item>
</channel>
</rss>
