This patch adds the SBReproducer macros needed to capture and reply the corresponding calls.
The patch was generated using the SBRepro tool (D56822).
Paths
| Differential D57475
[Reproducers] Add SBReproducer macros ClosedPublic Authored by JDevlieghere on Jan 30 2019, 2:39 PM.
Details Summary This patch adds the SBReproducer macros needed to capture and reply the corresponding calls. The patch was generated using the SBRepro tool (D56822).
Diff Detail Event TimelineJDevlieghere added a parent revision: D56322: [Reproducers] SBReproducer framework.Jan 30 2019, 2:39 PM Comment Actions BTW, it would be nice to mention somewhere how to use this tool. Do you just run it, or does it needs some special arguments, or something?
JDevlieghere added inline comments.
This revision is now accepted and ready to land.Feb 18 2019, 11:09 PM Closed by commit rLLDB355459: [Reproducers] Add SBReproducer macros (authored by JDevlieghere). · Explain WhyMar 5 2019, 4:07 PM This revision was automatically updated to reflect the committed changes. Comment Actions Run into a few compilation errors building on Windows with msvc.
Comment Actions This is still breaking NetBSD buildbot: http://lab.llvm.org:8011/builders/netbsd-amd64/builds/19339/steps/ninja%20build%20local/logs/stdio FAILED: tools/lldb/source/API/CMakeFiles/liblldb.dir/SBHostOS.cpp.o /usr/bin/g++ -DGTEST_HAS_RTTI=0 -DHAVE_ROUND -DLIBXML2_DEFINED -DLLDB_CONFIGURATION_RELEASE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -Itools/lldb/source/API -I/home/motus/netbsd8/netbsd8/llvm/tools/lldb/source/API -Itools/lldb/include -I/home/motus/netbsd8/netbsd8/llvm/tools/lldb/include -Iinclude -I/home/motus/netbsd8/netbsd8/llvm/include -I/usr/pkg/include/python2.7 -I/home/motus/netbsd8/netbsd8/llvm/tools/clang/include -Itools/lldb/../clang/include -I/usr/pkg/include/libxml2 -I/home/motus/netbsd8/netbsd8/llvm/tools/lldb/source/. -fPIC -fvisibility-inlines-hidden -Werror=date-time -std=c++11 -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wno-missing-field-initializers -pedantic -Wno-long-long -Wno-maybe-uninitialized -Wdelete-non-virtual-dtor -Wno-comment -fdiagnostics-color -ffunction-sections -fdata-sections -Wno-deprecated-declarations -Wno-unknown-pragmas -Wno-strict-aliasing -Wno-deprecated-register -Wno-vla-extension -O3 -DNDEBUG -fPIC -fno-exceptions -fno-rtti -MD -MT tools/lldb/source/API/CMakeFiles/liblldb.dir/SBHostOS.cpp.o -MF tools/lldb/source/API/CMakeFiles/liblldb.dir/SBHostOS.cpp.o.d -o tools/lldb/source/API/CMakeFiles/liblldb.dir/SBHostOS.cpp.o -c /home/motus/netbsd8/netbsd8/llvm/tools/lldb/source/API/SBHostOS.cpp In file included from /home/motus/netbsd8/netbsd8/llvm/tools/lldb/source/API/SBReproducerPrivate.h:18:0, from /home/motus/netbsd8/netbsd8/llvm/tools/lldb/source/API/SBHostOS.cpp:13: /home/motus/netbsd8/netbsd8/llvm/tools/lldb/include/lldb/Utility/ReproducerInstrumentation.h: In instantiation of 'void lldb_private::repro::Serializer::Serialize(T&) [with T = __pthread_st]': /home/motus/netbsd8/netbsd8/llvm/tools/lldb/include/lldb/Utility/ReproducerInstrumentation.h:518:7: required from 'void lldb_private::repro::Serializer::Serialize(T*) [with T = __pthread_st]' /home/motus/netbsd8/netbsd8/llvm/tools/lldb/include/lldb/Utility/ReproducerInstrumentation.h:506:5: required from 'void lldb_private::repro::Serializer::SerializeAll(const Head&, const Tail& ...) [with Head = __pthread_st*; Tail = {lldb::SBError*}]' /home/motus/netbsd8/netbsd8/llvm/tools/lldb/include/lldb/Utility/ReproducerInstrumentation.h:601:5: required from 'void lldb_private::repro::Recorder::Record(Result (*)(FArgs ...), const RArgs& ...) [with Result = bool; FArgs = {__pthread_st*, lldb::SBError*}; RArgs = {__pthread_st*, lldb::SBError*}]' /home/motus/netbsd8/netbsd8/llvm/tools/lldb/source/API/SBHostOS.cpp:135:3: required from here /home/motus/netbsd8/netbsd8/llvm/tools/lldb/include/lldb/Utility/ReproducerInstrumentation.h:530:64: error: invalid application of 'sizeof' to incomplete type '__pthread_st' m_stream.write(reinterpret_cast<const char *>(&t), sizeof(T)); ^ It looks like it's trying to serialize opaque types. Comment Actions Jonas, would it be possible to just not intercept the functions which work with thread IDs and similar stuff (an all OSs)?
Revision Contents
Diff 187287 lldb/source/API/SBAddress.cpp
lldb/source/API/SBAttachInfo.cpp
lldb/source/API/SBBlock.cpp
lldb/source/API/SBBreakpoint.cpp
lldb/source/API/SBBreakpointLocation.cpp
lldb/source/API/SBBreakpointName.cpp
lldb/source/API/SBBreakpointOptionCommon.cpp
lldb/source/API/SBBroadcaster.cpp
lldb/source/API/SBCommandInterpreter.cpp
lldb/source/API/SBCommandReturnObject.cpp
lldb/source/API/SBCommunication.cpp
lldb/source/API/SBCompileUnit.cpp
lldb/source/API/SBData.cpp
lldb/source/API/SBDebugger.cpp
lldb/source/API/SBDeclaration.cpp
lldb/source/API/SBError.cpp
lldb/source/API/SBEvent.cpp
lldb/source/API/SBExecutionContext.cpp
lldb/source/API/SBExpressionOptions.cpp
lldb/source/API/SBFileSpec.cpp
lldb/source/API/SBFileSpecList.cpp
lldb/source/API/SBFrame.cpp
lldb/source/API/SBFunction.cpp
lldb/source/API/SBHostOS.cpp
lldb/source/API/SBInitializerOptions.cpp
lldb/source/API/SBInstruction.cpp
lldb/source/API/SBInstructionList.cpp
lldb/source/API/SBLanguageRuntime.cpp
lldb/source/API/SBLaunchInfo.cpp
lldb/source/API/SBLineEntry.cpp
lldb/source/API/SBListener.cpp
lldb/source/API/SBMemoryRegionInfo.cpp
lldb/source/API/SBMemoryRegionInfoList.cpp
lldb/source/API/SBModule.cpp
lldb/source/API/SBModuleSpec.cpp
lldb/source/API/SBPlatform.cpp
lldb/source/API/SBProcess.cpp
lldb/source/API/SBProcessInfo.cpp
lldb/source/API/SBQueue.cpp
lldb/source/API/SBQueueItem.cpp
lldb/source/API/SBReproducer.cpp
lldb/source/API/SBSection.cpp
lldb/source/API/SBSourceManager.cpp
lldb/source/API/SBStream.cpp
lldb/source/API/SBStringList.cpp
lldb/source/API/SBStructuredData.cpp
lldb/source/API/SBSymbol.cpp
lldb/source/API/SBSymbolContext.cpp
lldb/source/API/SBSymbolContextList.cpp
lldb/source/API/SBTarget.cpp
lldb/source/API/SBThread.cpp
lldb/source/API/SBThreadCollection.cpp
lldb/source/API/SBThreadPlan.cpp
lldb/source/API/SBTrace.cpp
lldb/source/API/SBTraceOptions.cpp
lldb/source/API/SBType.cpp
lldb/source/API/SBTypeCategory.cpp
lldb/source/API/SBTypeEnumMember.cpp
lldb/source/API/SBTypeFilter.cpp
lldb/source/API/SBTypeFormat.cpp
lldb/source/API/SBTypeNameSpecifier.cpp
lldb/source/API/SBTypeSummary.cpp
lldb/source/API/SBTypeSynthetic.cpp
lldb/source/API/SBUnixSignals.cpp
lldb/source/API/SBValue.cpp
lldb/source/API/SBValueList.cpp
lldb/source/API/SBVariablesOptions.cpp
lldb/source/API/SBWatchpoint.cpp
|