================ @@ -1366,6 +1367,43 @@ TEST_F(DILocationTest, discriminatorSpecialCases) { EXPECT_EQ(std::nullopt, L4->cloneByMultiplyingDuplicationFactor(0x1000)); } +TEST_F(DILocationTest, KeyInstructions) { + Context.pImpl->NextAtomGroup = 1; + + EXPECT_EQ(Context.pImpl->NextAtomGroup, 1u); + DILocation *A1 = DILocation::get(Context, 1, 0, getSubprogram(), nullptr, false, 1, 2); + // The group is only applied to the DILocation if the build has opted into + // the additional DILocation fields needed for the feature. ---------------- jmorse wrote:
Style nit: I feel "the build has opted into" is a bit too abstract, and is like the code referring to itself in the third person. "if we have been built with..." feels a lot cleaner IMHO, YMMV. https://github.com/llvm/llvm-project/pull/133478 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits