-
Type:
Bug
-
Resolution: Unresolved
-
Priority:
Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
DevProd Build
-
ALL
-
None
-
None
-
None
-
None
-
None
-
None
-
None
The relevant error results during the pretty printer test when this line is uncommented.
In pretty_printer_test_program.cpp, testClass::static_member is an initialized static under the O0 pragma that isn't currently recognized in GDB. GDB outputs this error message:
Missing ELF symbol "_ZN9testClass13static_memberE".
Note that this was only reproducible using a spawn host and the bazel build invocation for the "archive_dist_test" task:
"bazel" build --verbose_failures --define=MONGO_VERSION=8.3.0-alpha3-142-gf87fded-patch-697cbb132db594000701d20d --config=evg --config=opt_profiled --define=MONGO_DISTMOD=amazon2023 archive-dist-test-debug install-dist-test
When building locally using --config=dbg --fission=no, there were no issues with missing debug symbols. Perhaps some flag has some negative interaction with GDB reading debug symbols?
Printing variables in gdb (testClass::static_member is not found):
File ./src/mongo/util/pretty_printer_test_program.cpp: 123: MyDecorable d1; 116: mongo::Decorable<MyDecorable>::Decoration<std::vector<int> > intVec; 117: mongo::Decorable<MyDecorable>::Decoration<std::__cxx11::basic_string<char> > str1[abi:cxx11]; 118: mongo::Decorable<MyDecorable>::Decoration<std::__cxx11::basic_string<char> > str2[abi:cxx11]; 121: static const mongo::NamespaceString kConstNs; 120: static const std::array<char, 15ul> testData;