<!-- 
RSS generated by JIRA (9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66) at Thu Feb 08 05:22:39 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>MongoDB Jira</title>
    <link>https://jira.mongodb.org</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.7.1</version>
        <build-number>970001</build-number>
        <build-date>13-04-2023</build-date>
    </build-info>


<item>
            <title>[SERVER-50434] exceptions violating noexcept can be invisible to terminate handler</title>
                <link>https://jira.mongodb.org/browse/SERVER-50434</link>
                <project id="10000" key="SERVER">Core Server</project>
                    <description>&lt;p&gt;When an exception propagates out of a &lt;tt&gt;noexcept&lt;/tt&gt; function, the &lt;tt&gt;std::terminate&lt;/tt&gt; and terminate handler are invoked. During that callback, we check for &lt;tt&gt;std::current_exception&lt;/tt&gt; and try to print a nice diagnostic about what exception was thrown, and we log it. However, we see that we reach the &lt;tt&gt;std::terminate&lt;/tt&gt; only to find that &lt;tt&gt;std::current_exception&lt;/tt&gt; is unexpectedly empty.&lt;/p&gt;

&lt;p&gt;( BF-17935 and others )&lt;/p&gt;

&lt;p&gt;This has the potential to be a very big support and testing problem, as we&apos;ll just have crashes in noexcept functions, with no hint as to the cause. I see a lot of effort in other tickets (e.g. &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-36434&quot; title=&quot;Switch try/catch to noexcept to get better stack traces in plan_stage and pipeline&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-36434&quot;&gt;&lt;del&gt;SERVER-36434&lt;/del&gt;&lt;/a&gt; ) toward noexcept explicitly to improve diagnostics, because the stack trace of a noexcept violation should better locate the problem. But noexcept will in these cases have the opposite effect, and causes the exception to not be logged at all. All we got in the case of BF-17935 was a partially unwound stack trace from the noexcept function and no logged exception details.&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;

&lt;p&gt;&lt;b&gt;Acceptance Criteria:&lt;/b&gt;&lt;/p&gt;

&lt;p&gt;Write crashing test that violates &lt;tt&gt;noexcept&lt;/tt&gt; and compare vs ordinary uncaught exception propagation on all buildvariants.&lt;br/&gt;
Propose a solution or describe rationale for why we can&apos;t fix.&lt;/p&gt;</description>
                <environment></environment>
        <key id="1448201">SERVER-50434</key>
            <summary>exceptions violating noexcept can be invisible to terminate handler</summary>
                <type id="1" iconUrl="https://jira.mongodb.org/secure/viewavatar?size=xsmall&amp;avatarId=14703&amp;avatarType=issuetype">Bug</type>
                                            <priority id="3" iconUrl="https://jira.mongodb.org/images/icons/priorities/major.svg">Major - P3</priority>
                        <status id="10038" iconUrl="https://jira.mongodb.org/images/icons/subtask.gif" description="">Backlog</status>
                    <statusCategory id="2" key="new" colorName="default"/>
                                    <resolution id="-1">Unresolved</resolution>
                                        <assignee username="-1">Unassigned</assignee>
                                    <reporter username="billy.donahue@mongodb.com">Billy Donahue</reporter>
                        <labels>
                            <label>6.1-targeted</label>
                            <label>sa-remove-fv-backlog-22</label>
                    </labels>
                <created>Thu, 20 Aug 2020 21:33:48 +0000</created>
                <updated>Fri, 2 Feb 2024 21:02:16 +0000</updated>
                                                                            <component>Internal Code</component>
                                        <votes>0</votes>
                                    <watches>16</watches>
                                                                                                                <comments>
                            <comment id="5621620" author="JIRAUSER1274045" created="Tue, 8 Aug 2023 20:49:35 +0000"  >&lt;p&gt;This will be addressed as part of the linked epic.&lt;/p&gt;</comment>
                            <comment id="5596104" author="jason.chan" created="Thu, 27 Jul 2023 16:59:03 +0000"  >&lt;p&gt;Assigning this to SDP for tracking purposes to make sure the next toolchain includes the patch for the gcc bug mentioned.&lt;/p&gt;

&lt;p&gt;In the meantime, Service Arch will focus on &lt;a href=&quot;https://jira.mongodb.org/browse/SERVER-70148&quot; title=&quot;Document proper noexcept usage&quot; class=&quot;issue-link&quot; data-issue-key=&quot;SERVER-70148&quot;&gt;SERVER-70148&lt;/a&gt; to come up with guidelines in noexcept usage in order to minimize this happening.&lt;/p&gt;</comment>
                            <comment id="5596097" author="JIRAUSER1268551" created="Thu, 27 Jul 2023 16:56:14 +0000"  >&lt;p&gt;I am nervous to try and port this into the v4 toolchain.&lt;/p&gt;

&lt;p&gt;This patch is a non-zero amount of work for our team since it does not apply cleanly. Our gcc is so old that it is missing&#160;&lt;tt&gt;&lt;b&gt;cp-gimplify.cc&lt;/b&gt;&lt;/tt&gt;&lt;b&gt;,&lt;/b&gt;&#160;&lt;tt&gt;&lt;b&gt;except.cc&lt;/b&gt;&lt;/tt&gt;&#160;&lt;b&gt;,&lt;/b&gt;&#160;&lt;tt&gt;tree-eh.cc&lt;/tt&gt; which means additional patches would be required. Furthermore this has ABI changes (I think) which also increases the risk. I would rather punt this for our next toolchain rollout. If this is included in gcc14 then we will get it next toolchain rollout. We can put this ticket in that epic if you would like to hand it off to us.&lt;/p&gt;</comment>
                            <comment id="5587753" author="billy.donahue" created="Mon, 24 Jul 2023 20:18:05 +0000"  >&lt;p&gt;GCC seems to have fixed the bug referenced above, slated for gcc v14.0.&lt;br/&gt;
&lt;a href=&quot;https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97720&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97720&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Perhaps toolchain could experiment with a cherry-pick of his patch.&lt;br/&gt;
&lt;a href=&quot;https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=2415024e0f81f8c09bf08f947c790b43de9d0bbc&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=2415024e0f81f8c09bf08f947c790b43de9d0bbc&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thx &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=tyler.brock%40mongodb.com&quot; class=&quot;user-hover&quot; rel=&quot;tyler.brock@mongodb.com&quot;&gt;tyler.brock@mongodb.com&lt;/a&gt; for checking up on this.&lt;/p&gt;

</comment>
                            <comment id="5548704" author="JIRAUSER1273619" created="Thu, 6 Jul 2023 19:51:35 +0000"  >&lt;p&gt;Phoebe will create a PM ticket for this work and &lt;a href=&quot;https://jira.mongodb.org/secure/ViewProfile.jspa?name=blake.oler%40mongodb.com&quot; class=&quot;user-hover&quot; rel=&quot;blake.oler@mongodb.com&quot;&gt;blake.oler@mongodb.com&lt;/a&gt; will need to provide summary and motivation&lt;/p&gt;

&lt;p&gt;The issue will be addressed in&#160; &lt;a href=&quot;https://jira.mongodb.org/browse/PM-3425&quot; class=&quot;external-link&quot; rel=&quot;nofollow&quot;&gt;https://jira.mongodb.org/browse/PM-3425&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;For better visibility, sending this ticket into backlog and linking this ticket to the project&lt;/p&gt;

&lt;p&gt;&#160;&lt;/p&gt;</comment>
                            <comment id="4869876" author="JIRAUSER1253381" created="Fri, 30 Sep 2022 19:54:40 +0000"  >&lt;p&gt;I just want to add that in BF-26507 we have run into a very similar situation as BF-17935.&#160; We are calling the terminate handler with zero helpful log messages.&#160; We are seeing the &quot;no exception active&quot; message due to the gcc bug.&#160;&#160;&lt;/p&gt;

&lt;p&gt;Our use of noexcept, combined with this gcc bug, is a big problem.&lt;/p&gt;

&lt;p&gt;In most of the places where we use noexcept, we would be better off catching the exception, logging a message, and calling std::terminate.&lt;/p&gt;

&lt;p&gt;(I am assuming in all this that the reason why we are in the terminate handler is because we violated a noexcept specification.)&lt;/p&gt;</comment>
                            <comment id="4570942" author="billy.donahue" created="Tue, 24 May 2022 22:30:43 +0000"  >&lt;p&gt;Seems to confirm this gcc bug:&lt;br/&gt;
&lt;a href=&quot;https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97720&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97720&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;(Includes a repo similar to the one we&apos;d have written for the acceptance criteria above.)&lt;/p&gt;</comment>
                            <comment id="3364611" author="ben.caimano" created="Fri, 28 Aug 2020 17:53:36 +0000"  >&lt;p&gt;I think you may have simply chosen one of the few matrix entries that does it correctly, namely the Ubuntu 18.04 Debug variants which have either &lt;tt&gt;opt=off&lt;/tt&gt; or &lt;tt&gt;CC=clang&lt;/tt&gt;. For instance, &lt;a href=&quot;https://logkeeper.mongodb.org/lobster/build/cbd23d840fc067ba3a0971d11394126a/test/5f48323054f248159479f43b#bookmarks=0%2C42%2C61&amp;amp;l=1&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;this&lt;/a&gt; RHEL 6.2 patch shows &quot;No exception is active&quot;.&lt;/p&gt;

&lt;p&gt;Happily, I figured out my unittest failure, so I have a new run &lt;a href=&quot;https://evergreen.mongodb.com/version/5f490ef1306615105b75ab18&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;here&lt;/a&gt;. To my surprise, my set of DEATH_TESTs for this actually caught it in the cloud. The variants that pass util_test also give the correct failure in jscore.&lt;/p&gt;</comment>
                            <comment id="3363645" author="billy.donahue" created="Fri, 28 Aug 2020 07:50:27 +0000"  >&lt;p&gt;All the failed jsCore tests I&apos;m looking at are dying with this:&lt;/p&gt;

&lt;p&gt;&lt;a href=&quot;https://logkeeper.mongodb.org/lobster/build/9dc7744ff3a25cda9546b551c0f56cd4/test/5f4833999041306474af8a80#bookmarks=0%2C42%2C65&amp;amp;l=1&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;https://logkeeper.mongodb.org/lobster/build/9dc7744ff3a25cda9546b551c0f56cd4/test/5f4833999041306474af8a80#bookmarks=0%2C42%2C65&amp;amp;l=1&lt;/a&gt;&lt;br/&gt;
[ This was taken from Ubuntu18.04 DEBUG. ]&lt;/p&gt;

&lt;p/&gt;
&lt;div id=&quot;syntaxplugin&quot; class=&quot;syntaxplugin&quot; style=&quot;border: 1px dashed #bbb; border-radius: 5px !important; overflow: auto; max-height: 30em;&quot;&gt;
&lt;table cellspacing=&quot;0&quot; cellpadding=&quot;0&quot; border=&quot;0&quot; width=&quot;100%&quot; style=&quot;font-size: 1em; line-height: 1.4em !important; font-weight: normal; font-style: normal; color: black;&quot;&gt;
		&lt;tbody &gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;  margin-top: 10px;   width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;[MongoDFixture:job1] 2020-08-27T22:28:43.187+0000 | 2020-08-27T22:28:43.187+00:00 F  CONTROL  4757800 [initandlisten] &quot;Writing fatal message&quot;,&quot;attr&quot;:{&quot;message&quot;:&quot;DBException::toString(): InternalError: Violate before startup complete\nActual exception type: mongo::error_details::ExceptionForImpl&amp;lt;(mongo::ErrorCodes::Error)1, mongo::AssertionException&amp;gt;\n&quot;}&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
				&lt;tr id=&quot;syntaxplugin_code_and_gutter&quot;&gt;
						&lt;td  style=&quot; line-height: 1.4em !important; padding: 0em; vertical-align: top;&quot;&gt;
					&lt;pre style=&quot;font-size: 1em; margin: 0 10px;   margin-bottom: 10px;  width: auto; padding: 0;&quot;&gt;&lt;span style=&quot;color: black; font-family: &apos;Consolas&apos;, &apos;Bitstream Vera Sans Mono&apos;, &apos;Courier New&apos;, Courier, monospace !important;&quot;&gt;[MongoDFixture:job1] 2020-08-27T22:28:43.673+0000 Waiting to connect to mongod on port 20250.&lt;/span&gt;&lt;/pre&gt;
			&lt;/td&gt;
		&lt;/tr&gt;
			&lt;/tbody&gt;
&lt;/table&gt;
&lt;/div&gt;
&lt;p/&gt;
&lt;p&gt;... Followed by an expected stacktrace.&lt;/p&gt;

&lt;p&gt;All the jsCore fails seem to look likes this. That is, they&apos;re finding and dumping the exception correctly from the terminate handler.  Are there failures in the evergreen run that show a missing exception?&lt;/p&gt;

&lt;p&gt;Maybe I misunderstood? Should I be looking at the unittest failures for the repro instead of the jsCore failures?&lt;/p&gt;</comment>
                            <comment id="3363331" author="ben.caimano" created="Thu, 27 Aug 2020 22:40:15 +0000"  >&lt;p&gt;Alright, I&apos;ve been able to reproduce reliably in evergreen using &lt;a href=&quot;https://github.com/bcaimano/mongo/commits/ben_check_noexcept/src/mongo&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;this branch&lt;/a&gt;. (It also has some hacks in it to compile with C++20 just in case it was related to language standard somehow.) &lt;a href=&quot;https://evergreen.mongodb.com/version/5f4826c261837d6b478543e7&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;Here&lt;/a&gt; is a test run with a good cross-section. The jscore failures are intentional (so as to show the terminate messages). The unittest failure is sadly unintentional, apparently there is some strange magic in the template-requires for comparison operators.&lt;/p&gt;</comment>
                    </comments>
                <issuelinks>
                            <issuelinktype id="10011">
                    <name>Depends</name>
                                                                <inwardlinks description="is depended on by">
                                                        </inwardlinks>
                                    </issuelinktype>
                            <issuelinktype id="10012">
                    <name>Related</name>
                                            <outwardlinks description="related to">
                                        <issuelink>
            <issuekey id="2149341">SERVER-70148</issuekey>
        </issuelink>
                            </outwardlinks>
                                                        </issuelinktype>
                    </issuelinks>
                <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                <customfield id="customfield_10050" key="com.atlassian.jira.toolkit:comments">
                        <customfieldname># Replies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>10.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                <customfield id="customfield_12751" key="com.atlassian.jira.plugin.system.customfieldtypes:multiselect">
                        <customfieldname>Assigned Teams</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="25138"><![CDATA[Build]]></customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_10055" key="com.atlassian.jira.ext.charting:firstresponsedate">
                        <customfieldname>Date of 1st Reply</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>Sun, 23 Aug 2020 17:48:39 +0000</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10052" key="com.atlassian.jira.toolkit:dayslastcommented">
                        <customfieldname>Days since reply</customfieldname>
                        <customfieldvalues>
                                        26 weeks, 1 day ago
    
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_18254" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Dependencies</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue><![CDATA[]]></customfieldvalue>


                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_15850" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_10857" key="com.pyxis.greenhopper.jira:gh-epic-link">
                        <customfieldname>Epic Link</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>DEVPROD-260</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <customfield id="customfield_10057" key="com.atlassian.jira.toolkit:lastusercommented">
                        <customfieldname>Last comment by Customer</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>true</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_10056" key="com.atlassian.jira.toolkit:lastupdaterorcommenter">
                        <customfieldname>Last commenter</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>steve.gross@mongodb.com</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_11151" key="com.atlassian.jira.toolkit:LastCommentDate">
                        <customfieldname>Last public comment date</customfieldname>
                        <customfieldvalues>
                            26 weeks, 1 day ago
                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_16465" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Linked BF Score</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>130.0</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                        <customfield id="customfield_10032" key="com.atlassian.jira.plugin.system.customfieldtypes:select">
                        <customfieldname>Operating System</customfieldname>
                        <customfieldvalues>
                                <customfieldvalue key="10026"><![CDATA[ALL]]></customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_10051" key="com.atlassian.jira.toolkit:participants">
                        <customfieldname>Participants</customfieldname>
                        <customfieldvalues>
                                        <customfieldvalue>alex.neben@mongodb.com</customfieldvalue>
            <customfieldvalue>andrew.witten@mongodb.com</customfieldvalue>
            <customfieldvalue>ben.caimano@mongodb.com</customfieldvalue>
            <customfieldvalue>billy.donahue@mongodb.com</customfieldvalue>
            <customfieldvalue>jason.chan@mongodb.com</customfieldvalue>
            <customfieldvalue>phoebe.du@mongodb.com</customfieldvalue>
            <customfieldvalue>steve.gross@mongodb.com</customfieldvalue>
    
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                        <customfield id="customfield_14254" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Product Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hy1f5j:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                <customfield id="customfield_12550" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>2|hr1nc2:i</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10558" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>9223372036854775807</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                            <customfield id="customfield_23361" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Requested By</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10555" key="com.atlassian.jira.plugin.system.customfieldtypes:float">
                        <customfieldname>Story Points</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>4.0</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            <customfield id="customfield_22870" key="com.onresolve.jira.groovy.groovyrunner:scripted-field">
                        <customfieldname>Triagers</customfieldname>
                        <customfieldvalues>
                                

                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                    <customfield id="customfield_14350" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>serverRank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hy11ev:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                    </customfields>
    </item>
</channel>
</rss>