Commit
42ec584a8b4e604360b7a4d45a65c570d58b1bf9
by Raphael Isemann[lldb][NFC] Make CompilerDeclContext construction type safe The CompilerDeclContext constructor takes a void* pointer which means that all callers of this constructor need to first explicitly convert all pointers to clang::DeclContext*. This causes that we for example can't just pass a TranslationUnitDecl* to the constructor without first casting it to its parent class (as it inherits from both Decl and DeclContext so the void* pointer is actually a Decl*). This patch introduces a utility function in the ClangASTContext which gets rid of the requirement to cast all pointers to clang::DeclContext. Also moves all constructor calls to use this function instead which is NFC (beside the change in DWARFASTParserClangTests.cpp).
|
 | lldb/source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp |
 | lldb/source/Plugins/SymbolFile/NativePDB/PdbAstBuilder.cpp |
 | lldb/source/Symbol/ClangASTContext.cpp |
 | lldb/unittests/Symbol/TestClangASTContext.cpp |
 | lldb/include/lldb/Symbol/ClangASTContext.h |
 | lldb/source/Plugins/ExpressionParser/Clang/ClangExpressionDeclMap.cpp |
 | lldb/source/Plugins/SymbolFile/PDB/PDBASTParser.cpp |
 | lldb/source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp |
 | lldb/unittests/SymbolFile/DWARF/DWARFASTParserClangTests.cpp |
Commit
6df6edfd0a0b50195d56124b9e43bb7c29843b7f
by Raphael Isemann[lldb][NFC] Document CompilerDeclContext constructors
|
 | lldb/include/lldb/Symbol/CompilerDeclContext.h |
Commit
70fa4c4f88609044dd0cd9671139d02d578d0df9
by shengchen.kan[NFC] Style cleanups 1. Remove duplicate function for class name at the beginning of the comment. 2. Use auto where the type is already obvious from the context.
|
 | llvm/include/llvm/MC/MCFragment.h |
 | llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h |
 | llvm/lib/MC/MCFragment.cpp |
Commit
5dca0596a959217a1c18858a62ed35245a4c42b4
by Raphael Isemann[lldb] Add a SubsystemRAII that takes care of calling Initialize and Terminate in the unit tests Summary: Many of our tests need to initialize certain subsystems/plugins of LLDB such as `FileSystem` or `HostInfo` by calling their static `Initialize` functions before the test starts and then calling `::Terminate` after the test is done (in reverse order). This adds a lot of error-prone boilerplate code to our testing code. This patch adds a RAII called SubsystemRAII that ensures that we always call ::Initialize and then call ::Terminate after the test is done (and that the Terminate calls are always in the reverse order of the ::Initialize calls). It also gets rid of all of the boilerplate that we had for these calls. Per-fixture initialization is still not very nice with this approach as it would require some kind of static unique_ptr that gets manually assigned/reseted from the gtest SetUpTestCase/TearDownTestCase functions. Because of that I changed all per-fixture setup to now do per-test setup which can be done by just having the SubsystemRAII as a member of the test fixture. This change doesn't influence our normal test runtime as LIT anyway runs each test case separately (and the Initialize/Terminate calls are anyway not very expensive). It will however make running all tests in a single executable slightly slower. Reviewers: labath, JDevlieghere, martong, espindola, shafik Reviewed By: labath Subscribers: mgorny, rnkovacs, emaste, MaskRay, abidh, lldb-commits Tags: #lldb Differential Revision: https://reviews.llvm.org/D71630
|
 | lldb/unittests/Symbol/TestLineEntry.cpp |
 | lldb/unittests/SymbolFile/DWARF/DWARFASTParserClangTests.cpp |
 | lldb/unittests/Target/ModuleCacheTest.cpp |
 | lldb/unittests/Symbol/LocateSymbolFileTest.cpp |
 | lldb/unittests/SymbolFile/DWARF/SymbolFileDWARFTests.cpp |
 | lldb/unittests/Utility/SubsystemRAIITest.cpp |
 | lldb/unittests/Host/ConnectionFileDescriptorTest.cpp |
 | lldb/unittests/Expression/DWARFExpressionTest.cpp |
 | lldb/unittests/Core/MangledTest.cpp |
 | lldb/unittests/Process/minidump/MinidumpParserTest.cpp |
 | lldb/unittests/ObjectFile/ELF/TestObjectFileELF.cpp |
 | lldb/unittests/TestingSupport/SubsystemRAII.h |
 | lldb/unittests/Expression/CppModuleConfigurationTest.cpp |
 | lldb/unittests/Host/MainLoopTest.cpp |
 | lldb/unittests/Utility/CMakeLists.txt |
 | lldb/unittests/Host/SocketTest.cpp |
 | lldb/unittests/Interpreter/TestCompletion.cpp |
 | lldb/unittests/Symbol/TestDWARFCallFrameInfo.cpp |
 | lldb/unittests/Symbol/TestClangASTContext.cpp |
 | lldb/unittests/ObjectFile/PECOFF/TestPECallFrameInfo.cpp |
 | lldb/unittests/Expression/ClangExpressionDeclMapTest.cpp |
 | lldb/unittests/Symbol/TestClangASTImporter.cpp |
 | lldb/unittests/Host/HostInfoTest.cpp |
 | lldb/unittests/Expression/ClangParserTest.cpp |
 | lldb/unittests/Editline/EditlineTest.cpp |
 | lldb/unittests/Language/Highlighting/HighlighterTest.cpp |
 | lldb/unittests/Host/SocketAddressTest.cpp |
Commit
fecb122cca254f565050559b349c8ff309194554
by Raphael Isemann[lldb][NFC] Simplify ClangASTContext::GetTranslationUnitDecl These two functions are just calling their equivalent function in ASTContext and implicitly convert the result to a DeclContext* (a parent class of TranslationUnitDecl). This leads to the absurd situation that we had to cast the result of GetTranslationUnitDecl to a TranslationUnitDecl*. The only reason we did this implicit conversion to the parent class was that the void* conversion for the CompilerDeclContext constructor was sound (which otherwise would receive a Decl* pointer when called with a TranslationUnitDecl*). Now that the CompilerDeclContext constructor is type safe we can properly implement these functions by actually returning the right type. Also deletes the static inconvenience method that was not used anywhere.
|
 | lldb/include/lldb/Symbol/ClangASTContext.h |
 | lldb/source/Symbol/ClangASTContext.cpp |
Commit
12a3d97cf68389a025b8a75b8ea660b11401a3c8
by pavel[lldb/lua] Fix bindings.test for lua-5.1 string.format("%s", true) only works since lua-5.2. Make the print statement more portable.
|
 | lldb/test/Shell/ScriptInterpreter/Lua/bindings.test |
Commit
fbccef6b2553a3e6a7183e259f5a911885d0ddea
by pavel[lldb] Fix a -Wreturn-type gcc warning in ScriptInterpreter.cpp
|
 | lldb/source/Interpreter/ScriptInterpreter.cpp |
Commit
cc522bc4e3e5e3c46ef34c94c64980957880f738
by grimar[llvm-readobj][test] - Stop using Inputs/trivial.obj.elf-x86-64. This rewrites a few tests to stop using the trivial.obj.elf-x86-64 precompiled object and removes it. Differential revision: https://reviews.llvm.org/D71662
|
 | llvm/test/tools/llvm-readobj/ELF/Inputs/trivial.ll |
 | llvm/test/tools/llvm-readobj/ELF/gnu-file-headers.test |
 | llvm/test/tools/llvm-readobj/ELF/gnu-section-mapping-no-phdrs.test |
 | llvm/test/tools/llvm-readobj/ELF/hex-dump.test |
 | llvm/test/tools/llvm-readobj/ELF/thin-archive-paths.test |
 | llvm/test/tools/llvm-readobj/ELF/Inputs/trivial.obj.elf-x86-64 |
Commit
86c9831bb40d2c50c36b748b08a75860c4640875
by martin[ItaniumCXXABI] Don't mark an extern_weak init function as dso_local on windows Since 6bf108d77a3c, we try to not mark extern_weak symbols as dso_local, to allow using COFF stubs for references to those symbols (as the symbol may be missing, resolving to an absolute address zero, outside of the current DSO). Differential Revision: https://reviews.llvm.org/D71716
|
 | clang/test/CodeGenCXX/mingw-thread-local.cpp |
 | clang/lib/CodeGen/ItaniumCXXABI.cpp |
Commit
b774aa1011a031b225624277178382bb2db7e26a
by martin[ARM] [Windows] Use COFF stubs for calls to extern_weak functions As the extern_weak target might be missing, resolving to the absolute address zero, we can't use the normal direct PC-relative branch instructions (as that would result in relocations out of range). Instead check the shouldAssumeDSOLocal method and load the address from a COFF stub. This matches what was done for X86 in 6bf108d77a3c. Differential Revision: https://reviews.llvm.org/D71720
|
 | llvm/test/CodeGen/ARM/tail-call-weak.ll |
 | llvm/lib/Target/ARM/ARMISelLowering.cpp |
Commit
5a751e747dbf2c267e944aa961e21de7a815e7eb
by martin[AArch64] [Windows] Use COFF stubs for calls to extern_weak functions As the extern_weak target might be missing, resolving to the absolute address zero, we can't use the normal direct PC-relative branch instructions (as that would result in relocations out of range). Improve the classifyGlobalFunctionReference method to set MO_DLLIMPORT/MO_COFFSTUB, and simplify the existing code in AArch64TargetLowering::LowerCall to use the return value from classifyGlobalFunctionReference for these cases. Add code in both AArch64FastISel and GlobalISel/IRTranslator to bail out for function calls to extern weak functions on windows, to let SelectionDAG handle them. This matches what was done for X86 in 6bf108d77a3c. Differential Revision: https://reviews.llvm.org/D71721
|
 | llvm/lib/Target/AArch64/AArch64ISelLowering.cpp |
 | llvm/test/CodeGen/AArch64/windows-extern-weak.ll |
 | llvm/lib/Target/AArch64/AArch64FastISel.cpp |
 | llvm/test/CodeGen/AArch64/GlobalISel/call-translator-tail-call.ll |
 | llvm/lib/Target/AArch64/AArch64Subtarget.cpp |
 | llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp |
 | llvm/test/CodeGen/AArch64/GlobalISel/call-translator-tail-call-weak.ll |