Skip to content
This repository was archived by the owner on Apr 2, 2020. It is now read-only.

Merge from master-next (i.e. upstream) #71

Merged
merged 329 commits into from
Nov 2, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
329 commits
Select commit Hold shift + click to select a range
1c5dad9
[CMake] Initial support for LLDB.framework
Sep 21, 2016
aa2a0b4
Fix -Wcovered-switch-default warning in StackFrame.cpp
emaste Sep 21, 2016
3679175
Fix integer sign warning from r282105
emaste Sep 21, 2016
d0a9a14
Fix an incorrect nullptr conversion.
Sep 21, 2016
29b9a82
Fix for loop sign fix in r282112 for column = 0
emaste Sep 21, 2016
838ae66
Fix typo in lldb --help
emaste Sep 21, 2016
72fbfcb
fix Args function broken in r281942
tfiala Sep 22, 2016
0450687
Fix parsing expressions to evaluate with spaces and optional args (MI)
k15tfu Sep 22, 2016
48439b2
Propagating prior merge from 'llvm.org/master'.
Sep 22, 2016
3fb8c44
Fix TestBreakpointSerialization on windows
labath Sep 22, 2016
2726411
added environment variable-related Args gtests
tfiala Sep 22, 2016
ec71ff1
fix DarwinLog no-info/no-debug case
tfiala Sep 22, 2016
a6107ad
The host version of lldb always builds for macosx
Sep 22, 2016
8be3d78
Actually, do it this way because I will want to know if I am in a hos…
Sep 22, 2016
d657b2d
Convert option tables to ArrayRefs.
Sep 22, 2016
90a7f02
Try to fix build errors on Android.
Sep 22, 2016
cd33f6b
[CMake] Fixing a small hack in add_lldb_library
Sep 22, 2016
343f44b
Serilize the thread options within the breakpoint options.
jimingham Sep 22, 2016
066a361
Add the ability to deserialize only breakpoints matching a given name.
jimingham Sep 22, 2016
8cf5e69
Add the ability to append breakpoints to the save file.
jimingham Sep 22, 2016
665663e
Fix windows build caused by mixing enum and enum class.
Sep 23, 2016
fec0b80
[gdb-remote] Remove the const char * version of SendPacketAndWaitForR…
labath Sep 23, 2016
12cfcf0
Propagating prior merge from 'llvm.org/master'.
Sep 23, 2016
ff4eb53
add hook for calling platform-dependent pre-kill action on a timed ou…
tfiala Sep 23, 2016
81cd8a4
Update OptionGroup::SetValue to take StringRef.
Sep 23, 2016
36732fd
Update the prompt related functions to use StringRefs.
Sep 23, 2016
a6f17e6
Try to fix failing TestDataFormatterSkipSummary test case.
Sep 23, 2016
cfa7f1a
Try again to match the logic of the code before re-writing.
Sep 23, 2016
8db3929
Change Module::RemapPath to use StringRef.
Sep 23, 2016
d4661da
Install only the manpage and only in the proper location
Sep 23, 2016
21b76cc
Allow for tests to be disabled at runtime
fjricci Sep 23, 2016
4f8dee2
Change FileAction::GetPath() to return a StringRef.
Sep 23, 2016
1a4e028
Fix build on Ubuntu.
Sep 23, 2016
2c2413b
Add an accessor to get the value of RC_PLATFORM_NAME at build time
Sep 23, 2016
9198783
Mutatis mutandis for char * -> StringRef.
jimingham Sep 23, 2016
cacc8fd
[CMake] Generate LLDB_REVISION at build time
Sep 23, 2016
15bfb6a
Propagating prior merge from 'llvm.org/master'.
Sep 23, 2016
312c158
Remove an ancient XFAIL from TestBuiltinTrap
labath Sep 26, 2016
5f76b03
Remove ancient icc decorators
labath Sep 26, 2016
d7d23b2
Fix serialization of Python breakpoint commands.
jimingham Sep 26, 2016
2e9f17c
Added a setting that enables saving all .o files from a given JIT exp…
scallanan Sep 26, 2016
451ded9
added Linux support for test timeout sampling
tfiala Sep 26, 2016
ceb5f6c
Fix an issue where LLDB would not accept the --description-verbosity …
Sep 26, 2016
d627bbb
Propagating prior merge from 'llvm.org/master'.
Sep 26, 2016
821ea08
xfail TestExec.py on macOS
tfiala Sep 27, 2016
035bd8d
convert TestFatArchives.py over to no-debug-info test
tfiala Sep 27, 2016
5453393
Adding a RegisterContextMinidump_x86_64 converter
dvlahovski Sep 27, 2016
bdcdf8e
Update FileSpec's interface to use StringRefs.
Sep 27, 2016
e767031
Refactor the x86 UnwindAssembly class into a separate class called
jasonmolenda Sep 28, 2016
a9cf082
Reverting r282565.
jasonmolenda Sep 28, 2016
7cffaaa
Propagating prior merge from 'llvm.org/master'.
Sep 28, 2016
5cc0f41
zorg Xcode python test suite target arch update
tfiala Sep 28, 2016
418660c
use assertEquals in TestSBTypeClassMembers
tfiala Sep 28, 2016
d8c5b32
Add the ability for the task port to change when a process execs.
Sep 28, 2016
a092616
Fix an issue where libc++ changed the type information we get for std…
Sep 28, 2016
aa78838
Introduced a null check to avoid a crash in a test on i386.
scallanan Sep 29, 2016
8c519ef
Fixed TestObjCStructArgument/i386; expressions can now call ObjC clas…
scallanan Sep 29, 2016
ed2d094
Re-commit the changes from r282565 that I had to back out because of
jasonmolenda Sep 29, 2016
0eaf50b
Add a unit test for an x86_64 assembly inspection of
jasonmolenda Sep 29, 2016
000b65b
Propagating prior merge from 'llvm.org/master'.
Sep 29, 2016
00ff0ce
To fix TestObjCMethods2/i386, allowed messaging nil ObjC objects as i…
scallanan Sep 29, 2016
cb4a482
Fix an issue where, in i386 mode, the wrong values were being copied …
Sep 29, 2016
c67b86a
This test will not work in i386 mode because we don't create interest…
Sep 29, 2016
4fd1888
Fixed TestObjCMethods2/i386 by separating out the portions that requi…
scallanan Sep 29, 2016
bba3289
Add a quick note about how to build lldb with debug info using
jasonmolenda Sep 29, 2016
5c6d397
Don't expect new-style Objective-C literals to work on i386 with the …
scallanan Sep 29, 2016
201ada5
[CMake] LLDB/Expression needs to depend on intrinsics_gen
Sep 29, 2016
d10c99a
Add some logging when trace is on. We're getting a bot failure on i3…
jimingham Sep 29, 2016
4923244
Switch to using TEST_EQ, TEST_FALSE where appropriate.
jasonmolenda Sep 29, 2016
fcafba5
Move UTF functions into namespace llvm.
Sep 30, 2016
5fef98e
Do not assume we will be able to discover the return type of this sel…
Sep 30, 2016
978ced8
Prefer skipping over x-failing
Sep 30, 2016
e468d3f
Add unit tests for simple frameless i386 and x86_64 function
jasonmolenda Sep 30, 2016
10099a4
Add the tracking radar on our end.
jimingham Sep 30, 2016
3215e03
Propagating prior merge from 'llvm.org/master'.
Sep 30, 2016
8644791
Fix PDB unittests on non-windows platforms
labath Sep 30, 2016
99511ff
XFAIL TestSBData for gcc-4.9 i386
labath Sep 30, 2016
ba30d54
Fixing windows build breakage caused by rL282822
dvlahovski Sep 30, 2016
252a7bd
Again fixing windows build breakage like in rL282862
dvlahovski Sep 30, 2016
ea5cf05
Skip TestRuntimeIvars on i386; the Objective-C V1 runtime doesn't lis…
scallanan Sep 30, 2016
5b005c0
Add namespace qualifiers for UTF functions that just moved.
amccarth-google Sep 30, 2016
39a7ae5
Fixed several i386 Objective-C tests by completing objects, not their…
scallanan Sep 30, 2016
0bf3669
Fix comment - Module::PrepareForFunctionNameLookup should be Module::…
Sep 30, 2016
77c7e7e
Adding ivars in class extensions isn't supported on i386; skip a test.
scallanan Sep 30, 2016
21acf5f
IsValid is the way to ask a breakpoint location whether it is valid.
jimingham Sep 30, 2016
909e033
Add the radar from our end to the bugreport string.
jimingham Sep 30, 2016
b12f83f
Add the radar on our end to the bugreport string.
jimingham Sep 30, 2016
539c43d
Fix up the test so it gets closer to passing.
jimingham Sep 30, 2016
d61911e
test infra: clear file-charged issues on rerun of file
tfiala Oct 1, 2016
249a0e1
Add support for some extended push instructions in i386/x86_64 like
jasonmolenda Oct 1, 2016
1315bcd
Fix up this test case.
jimingham Oct 1, 2016
1001c73
Add unit tests for specific instruction patterns that the x86
jasonmolenda Oct 1, 2016
58bff4a
Use StringRef instead of raw pointers in MCAsmInfo/MCInstrInfo APIs (…
joker-eph Oct 1, 2016
5a2db26
Propagating prior merge from 'llvm.org/master'.
Oct 1, 2016
991a9b7
[lldb-mi] Fix prompt which can get inserted in the middle of program …
Oct 1, 2016
bf04163
Propagating prior merge from 'llvm.org/master'.
Oct 1, 2016
9b30603
Revert "XFAIL TestSBData for gcc-4.9 i386"
labath Oct 2, 2016
5768bd5
[CMake] Fixing a few missing dependencies on intrinsics_gen
Oct 3, 2016
ec061a2
Fix regex in lldb lit test TestCallStopAndContinue
Oct 3, 2016
f917b09
Propagating prior merge from 'llvm.org/master'.
Oct 3, 2016
96cd3ed
add a simple test case to validate test id()
tfiala Oct 3, 2016
5539ea9
Refactor the Args class.
Oct 3, 2016
165c9ce
Modernize some code related to Args usage / implementation.
Oct 3, 2016
b25be25
Changes to the std::multimap formatter to make it work against trunk …
Oct 3, 2016
329e1e4
Fix the data formatter for std::multiset in libc++ - this is a trivia…
Oct 4, 2016
a19ed23
Try to fix failing tests when running remote test suite.
Oct 4, 2016
053beb2
Fix test when using remote debugging.
labath Oct 4, 2016
26a461c
Fix TestNestedAliases.py
Oct 4, 2016
05250d5
Finish adding the individual instruction tests to the x86 unwinder
jasonmolenda Oct 4, 2016
1dfef28
Propagating prior merge from 'llvm.org/master'.
Oct 4, 2016
e7f4898
Fix FixupEnvironment on Android after the Args refactor
Oct 4, 2016
11d1a49
Improvements to testing blacklist
fjricci Oct 4, 2016
b09a7e4
Adding a new Minidump post-mortem debugging plugin
dvlahovski Oct 4, 2016
40046c6
Fix the decorator of TestBreakpointCaseSensitivity
Oct 4, 2016
99311c0
xfailing tests for Minidump plugin
dvlahovski Oct 4, 2016
2f638a1
Add the new minidump files to the Xcode project.
jimingham Oct 5, 2016
c875d2d
Re-commit "Use StringRef in Support/Darf APIs (NFC)"
joker-eph Oct 5, 2016
0acd0fe
Revert "Re-commit "Use StringRef in Support/Darf APIs (NFC)""
joker-eph Oct 5, 2016
4efef69
This test is failing because there's a global symbol "C" in libsystem…
jimingham Oct 5, 2016
c4b0efb
The collision of class C and libsystem_c.dylib:C is a failure
jimingham Oct 5, 2016
973503c
Change Platform::GetRemoteSharedModule so if it's given a ModuleSpec
jasonmolenda Oct 5, 2016
995bc5a
Re-commit "Use StringRef in Support/Darf APIs (NFC)"
joker-eph Oct 5, 2016
947ee3e
Propagating prior merge from 'llvm.org/master'.
Oct 5, 2016
0a9893d
Delete unused global in ClangExpressionVariable.cpp
ldrumm Oct 5, 2016
8dbf836
cleanup RSCoordinate handling and factor out coordinate parser
ldrumm Oct 5, 2016
0dd93b3
Fixing new Minidump plugin tests
dvlahovski Oct 5, 2016
97eade0
xfailing minidump tests again ... :(
dvlahovski Oct 5, 2016
d023da3
[RenderScript] reflow/reword some comments and normalize names
ldrumm Oct 5, 2016
a7851a3
Disable warnings in LLDBWrapPython.cpp with -Werror.
Oct 5, 2016
8fe65c3
Make lldb -Werror clean on Windows.
Oct 5, 2016
e338241
Convert some breakpoint code to use StringRef.
Oct 5, 2016
2048691
Try to fix Android build.
Oct 5, 2016
26b587e
Removing the new Minidump plugin
dvlahovski Oct 5, 2016
ef86b63
Fix some test failures due to the recent Breakpoint patch.
Oct 5, 2016
f64d484
Add the ability to set breakpoints on named RenderScript reductions
ldrumm Oct 5, 2016
e0c743a
Convert various CommandInterpreter functions to StringRef.
Oct 5, 2016
98e5b01
Fixup the xfail situation on Windows.
Oct 5, 2016
054b31c
Convert CommandObject constructors to StringRef.
Oct 5, 2016
462fdd8
Update some command aliasing functions to use StringRef.
Oct 5, 2016
d947d95
Convert some more aliasing and CI functions to StringRef.
Oct 5, 2016
406e5a8
Fixes for libc++ std::unordered_map data formatter against trunk
Oct 5, 2016
e21e6ee
Add i386/x86_64 tests of the eh_frame augmentation code in the x86
jasonmolenda Oct 5, 2016
99e27b5
Convert some Args index-based iteration to range-style iteration.
Oct 5, 2016
c24fa14
Fix build error on Android again.
Oct 5, 2016
0affb95
Propagating prior merge from 'llvm.org/master'.
Oct 6, 2016
e3b0030
Improve test for Intel(R) MPX registers.
Oct 6, 2016
e1d0323
These test cases don't test different debug info formats.
jimingham Oct 6, 2016
9e77e69
Match printf field width arg and type
emaste Oct 6, 2016
9d081ae
Add bound violation handling for Intel(R) Memory Protection Extension…
Oct 6, 2016
c2b82c4
xfail TestDarwinLogBasic.py for i386 macOS
tfiala Oct 6, 2016
cc0fbf7
StringRef::front asserts on empty strings, causing "break modify -c '…
jimingham Oct 6, 2016
c598aaf
xfail TestDiagnoseDereferenceFunctionReturn.py on macOS i386
tfiala Oct 6, 2016
aed4d39
xfail TestExec.py on macOS i386
tfiala Oct 6, 2016
d52a4f6
xfail TestDataFormatterNSIndexPath.py on macOS i386
tfiala Oct 6, 2016
c702f5c
xfail TestSBTypeTypeClass.py on macOS i386
tfiala Oct 6, 2016
e2ffdce
Fix GetDisplayName when only a demangled name is available
fjricci Oct 6, 2016
a105e6c
xfail TestQueues on macOS
tfiala Oct 6, 2016
caaad45
xfail TestReportData.py on i386
tfiala Oct 6, 2016
45fb8d0
Convert UniqueCStringMap to use StringRef.
Oct 6, 2016
38e0dfc
disable TSAN tests on macOS i386
tfiala Oct 6, 2016
3f2a023
[lit] Don't assume you'll find debugserver
Oct 7, 2016
1d1fddc
Propagating prior merge from 'llvm.org/master'.
Oct 7, 2016
4e7339a
Fix build failure on lldb-amd64-ninja-freebsd11 error caused by rL283474
Oct 7, 2016
3d4af35
The PR that caused this test ot fail was fixed in July, removing the …
jimingham Oct 7, 2016
0e16856
Remove unused variable.
Oct 7, 2016
bcceb86
Remove a stray dump().
scallanan Oct 7, 2016
7a3fbe7
Fix a few warnings caught by clang.
Oct 7, 2016
7ebb3ec
Fix compiler warnings in PlatformDarwinTest.cpp
labath Oct 8, 2016
ad10239
Fix compiler warnings in TestClangASTContext.cpp
labath Oct 8, 2016
b8e7997
Propagating prior merge from 'llvm.org/master'.
Oct 8, 2016
393ea1e
[LLDB][MIPS] Fix register read/write for 32 bit big endian system
jainnk Oct 10, 2016
61cd6b2
[LLDB][MIPS] Fix TestReturnValue failure for MIPS
jainnk Oct 10, 2016
0e72769
Propagating prior merge from 'llvm.org/master'.
Oct 10, 2016
b1b512c
[LLDB][MIPS] Skip some test case which were causing LLDB to go into i…
jainnk Oct 10, 2016
c5582d5
[LLDB][MIPS] All tests get errors in dotest after this test.
jainnk Oct 10, 2016
4844a4f
Add the radar number on our end.
jimingham Oct 10, 2016
2fc4bbf
Add the related radar on our end for llvm.org/pr15824.
jimingham Oct 10, 2016
fa1f781
Adding radar number on our end for llvm.org/pr15824.
jimingham Oct 10, 2016
a746feb
This test was failing because /bin/ls is no longer debuggable on OS X.
jimingham Oct 11, 2016
34c4012
Fixing the bug number for darwin on this failure.
jimingham Oct 11, 2016
09c18fb
Add a first unit test for the arm64 instruction profiled unwind
jasonmolenda Oct 11, 2016
3056fee
Add a second, more complicated, arm64 example program to
jasonmolenda Oct 11, 2016
7bf3c9c
Propagating prior merge from 'llvm.org/master'.
Oct 11, 2016
0036095
Fix Arm64InstEmulation tests for windows
labath Oct 11, 2016
482cac9
Clarified the explanation of expr --top-level.
scallanan Oct 11, 2016
13817bd
Added a bugreport tracking the failure to get float return values
jimingham Oct 11, 2016
680bed2
This test now passes.
jimingham Oct 11, 2016
4d053a0
Add the radar number on our end.
jimingham Oct 11, 2016
a64c6ba
Added a radar on our end for this test's failure.
jimingham Oct 11, 2016
73c48f6
This was skipped due to a clang PR that has been fixed.
jimingham Oct 11, 2016
8d36a3f
This test now passes.
jimingham Oct 12, 2016
b642527
Add a simple frameless function test case to the arm64 unwind unit tests
jasonmolenda Oct 12, 2016
bb31439
Add an arm64 unit test where the function saves x20 in the
jasonmolenda Oct 12, 2016
b1273a0
Propagating prior merge from 'llvm.org/master'.
Oct 12, 2016
6bb0a14
[LLDB][MIPS] Fix qProcessInfo to return correct pointer size based on…
jainnk Oct 12, 2016
0a8263d
[LLDB][MIPS] fix Floating point register read/write for big endian
jainnk Oct 12, 2016
f7afdb7
Fix lookup path for lldb-mi
Oct 12, 2016
13c21eb
Fix building tests without system headers on Darwin
Oct 12, 2016
635521b
Fix test suite lookup path for LLDB.h
Oct 12, 2016
ec5c745
Use LLDB_SRC for relative paths
Oct 12, 2016
d1d9aa3
[CMake] Cleanup check-lldb targets
Oct 12, 2016
a0ec07b
Fix Python binding generation build step on Windows
enlight Oct 13, 2016
9849b48
Propagating prior merge from 'llvm.org/master'.
Oct 13, 2016
3c5d8d4
[lldb] Improve identification of Linux core dumps. Fix for bug #30485.
rnchamberlain Oct 13, 2016
a04f636
This test is passing on i386 now.
jimingham Oct 14, 2016
9e5f1d6
This test passes on i386 now.
jimingham Oct 14, 2016
2e112b1
Propagating prior merge from 'llvm.org/master'.
Oct 14, 2016
5590563
[LLDB-MI] Minor cleanup of CMICmnLLDBUtilSBValue class
enlight Oct 14, 2016
04bc152
[CMake] Populate LLDB.framework's headers directory
Oct 14, 2016
150510f
This test is no longer failing for gmodules.
jimingham Oct 15, 2016
af10e29
Propagating prior merge from 'llvm.org/master'.
Oct 15, 2016
a0fac3a
Interpreter: Don't return StringRef from functions whose return value…
bogner Oct 17, 2016
80d1e66
Propagating prior merge from 'llvm.org/master'.
Oct 17, 2016
713f69e
unittests: Specify types in a bunch of unittest EXPECT's
bogner Oct 17, 2016
5f8ab0c
[lldb] Read modules from memory when a local copy is not available
walter-erquinigo Oct 17, 2016
adc1653
Fix a crash in expressions with fixits in the dummy target.
jimingham Oct 17, 2016
bf6b75d
More testsuite xfail markings cleanup.
jimingham Oct 18, 2016
04f6ce3
Remove a debug print statement.
jimingham Oct 18, 2016
aa46b02
Propagating prior merge from 'llvm.org/master'.
Oct 18, 2016
d437a88
[cmake] Make dependencies of lldb libraries private, take 2
labath Oct 18, 2016
0b84414
Fixup r284466 - try to unbreak NetBSD
labath Oct 18, 2016
74cebec
xfail TestMiSyntax.py's test_lldbmi_output_grammar on macOS
tfiala Oct 18, 2016
56a8c0d
Use clang --driver-mode instead of guessing c++ compiler path
Oct 18, 2016
5774b1b
[CMake] Don't include LLDB_TEST_COMPILER in cached variable
Oct 18, 2016
2488616
When invoking Terminal, don't assume the default shell
Oct 18, 2016
63ab2ee
Fixing the linux bots I broke in r284550
Oct 19, 2016
a65fd36
Trying to fix a few more missing LDFLAGS.
Oct 19, 2016
b9b0249
Revert back to the state before r284550
Oct 19, 2016
4c1eaed
Propagating prior merge from 'llvm.org/master'.
Oct 19, 2016
ab730fe
Merge upstream LLVM.org LLDB (r284565) into swift-lldb/master-next
tfiala Oct 20, 2016
f42c727
Fixup NSDictionary_Additionals to use the new AdditionalFormatterMatc…
Sep 21, 2016
ff3400b
fixed up two areas of merge conflict that aren't part of the macOS build
tfiala Oct 21, 2016
394a8b3
[CMake] Fix standalone build
Oct 21, 2016
fd28115
fix up Ubuntu build
tfiala Oct 24, 2016
2c1ea7a
fix up gtest build issues on build-script-driven LLDB build
tfiala Oct 25, 2016
076ba14
fixup Xcode project, mark failing tests
tfiala Oct 26, 2016
8098b8a
Merge swift-lldb/master into master-next.
tfiala Oct 26, 2016
e891056
remove xfail from TestSwiftBridgedArray.py
tfiala Oct 26, 2016
4db61a9
update static Python swig bindings
tfiala Oct 26, 2016
ac64d3e
added bug-tracking numbers for two issues raised during the merge
tfiala Oct 27, 2016
daa19f2
disable lldb-mi until upstream issue with global constructor is resolved
Oct 28, 2016
e556fb1
add -fno-limit-debug-info for debug builds with build-swift-cmake.py
Oct 28, 2016
ab139c2
Limit LLDB_EXPORT_ALL_SYMBOLS symbol exporting
tfiala Oct 28, 2016
1e6ee20
Revert "disable lldb-mi until upstream issue with global constructor …
tfiala Oct 28, 2016
c285097
Revert "This test now passes."
tfiala Oct 28, 2016
7f027b4
Merge origin/master into master-next
tfiala Oct 31, 2016
d609a08
Revert "Move UTF functions into namespace llvm."
tfiala Nov 1, 2016
5e903e0
temporarily remove llvm namespace from UTF* functions
tfiala Nov 1, 2016
82b8e9b
Revert "Use StringRef instead of raw pointers in MCAsmInfo/MCInstrInf…
tfiala Nov 1, 2016
1995b66
fix up lldb-mi linkage on build-script-driven macOS build
tfiala Nov 1, 2016
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
# Byte compiled python modules.
*.pyc
*.pyproj
# pyenv settings
.python-version
*.sln
*.suo
# vim swap files
Expand Down
18 changes: 17 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,16 @@ endif()
# add_subdirectory(include)
add_subdirectory(docs)
if (NOT LLDB_DISABLE_PYTHON)
set(LLDB_PYTHON_TARGET_DIR ${LLDB_BINARY_DIR}/scripts)
if(LLDB_BUILD_FRAMEWORK)
set(LLDB_PYTHON_TARGET_DIR
${CMAKE_BINARY_DIR}/${CMAKE_CFG_INTDIR}/${LLDB_FRAMEWORK_INSTALL_DIR})
else()
# Don't set -m when building the framework.
set(FINISH_EXTRA_ARGS "-m")
endif()
set(LLDB_WRAP_PYTHON ${LLDB_PYTHON_TARGET_DIR}/LLDBWrapPython.cpp)

add_subdirectory(scripts)
endif ()
add_subdirectory(source)
Expand All @@ -37,7 +47,13 @@ add_subdirectory(lit)
if (NOT LLDB_DISABLE_PYTHON)
# Add a Post-Build Event to copy over Python files and create the symlink to liblldb.so for the Python API(hardlink on Windows)
add_custom_target( finish_swig ALL
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/scripts/finishSwigWrapperClasses.py "--srcRoot=${LLDB_SOURCE_DIR}" "--targetDir=${CMAKE_CURRENT_BINARY_DIR}/scripts" "--cfgBldDir=${CMAKE_CURRENT_BINARY_DIR}/scripts" "--prefix=${CMAKE_BINARY_DIR}" "--cmakeBuildConfiguration=${CMAKE_CFG_INTDIR}" "--lldbLibDir=lib${LLVM_LIBDIR_SUFFIX}" -m
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/scripts/finishSwigWrapperClasses.py
"--srcRoot=${LLDB_SOURCE_DIR}"
"--targetDir=${LLDB_PYTHON_TARGET_DIR}"
"--cfgBldDir=${CMAKE_CURRENT_BINARY_DIR}/scripts"
"--prefix=${CMAKE_BINARY_DIR}"
"--cmakeBuildConfiguration=${CMAKE_CFG_INTDIR}"
"--lldbLibDir=lib${LLVM_LIBDIR_SUFFIX}" ${FINISH_EXTRA_ARGS}
DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/scripts/finishSwigWrapperClasses.py
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/scripts/lldb.py
COMMENT "Python script sym-linking LLDB Python API")
Expand Down
2 changes: 0 additions & 2 deletions cmake/LLDBDependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -255,8 +255,6 @@ set(LLVM_LINK_COMPONENTS
)

if ( NOT LLDB_DISABLE_PYTHON )
set(LLDB_WRAP_PYTHON ${LLDB_BINARY_DIR}/scripts/LLDBWrapPython.cpp)

set_source_files_properties(${LLDB_WRAP_PYTHON} PROPERTIES GENERATED 1)
if (CLANG_CL)
set_source_files_properties(${LLDB_WRAP_PYTHON} PROPERTIES COMPILE_FLAGS -Wno-unused-function)
Expand Down
72 changes: 44 additions & 28 deletions cmake/modules/AddLLDB.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ function(lldb_link_common_libs name targetkind)
endif()

if(${targetkind} MATCHES "SHARED")
set(LINK_KEYWORD PUBLIC)
set(LINK_KEYWORD PRIVATE)
endif()

if(${targetkind} MATCHES "SHARED" OR ${targetkind} MATCHES "EXE")
Expand Down Expand Up @@ -56,32 +56,32 @@ macro(add_lldb_library name)
if (PARAM_OBJECT)
add_library(${name} ${libkind} ${srcs})
else()
llvm_add_library(${name} ${libkind} DISABLE_LLVM_LINK_LLVM_DYLIB ${srcs})

lldb_link_common_libs(${name} "${libkind}")

if (PARAM_SHARED)
if (LLDB_LINKER_SUPPORTS_GROUPS)
target_link_libraries(${name} PUBLIC
-Wl,--start-group ${SWIFT_ALL_LIBS} -Wl,--end-group)
target_link_libraries(${name} PUBLIC
-Wl,--start-group ${CLANG_ALL_LIBS} -Wl,--end-group)
target_link_libraries(${name} PUBLIC
-Wl,--start-group ${LLVM_ALL_LIBS} -Wl,--end-group)
llvm_add_library(${name} ${libkind} ${srcs} LINK_LIBS
-Wl,--start-group ${LLDB_USED_LIBS} -Wl,--end-group
-Wl,--start-group ${SWIFT_ALL_LIBS} -Wl,--end-group
-Wl,--start-group ${CLANG_ALL_LIBS} -Wl,--end-group
)
else()
target_link_libraries(${name} PUBLIC ${SWIFT_ALL_LIBS})
target_link_libraries(${name} PUBLIC ${CLANG_ALL_LIBS})
target_link_libraries(${name} PUBLIC ${LLVM_ALL_LIBS})
llvm_add_library(${name} ${libkind} ${srcs} LINK_LIBS
${LLDB_USED_LIBS} ${SWIFT_ALL_LIBS} ${CLANG_ALL_LIBS}
)
endif()
else()
llvm_add_library(${name} ${libkind} ${srcs})
endif()
llvm_config(${name} ${LLVM_LINK_COMPONENTS} ${LLVM_PRIVATE_LINK_COMPONENTS})

if (${name} STREQUAL "liblldb")
if (PARAM_SHARED)
set(out_dir lib${LLVM_LIBDIR_SUFFIX})
if(${name} STREQUAL "liblldb" AND LLDB_BUILD_FRAMEWORK)
set(out_dir ${LLDB_FRAMEWORK_INSTALL_DIR})
endif()
install(TARGETS ${name}
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
ARCHIVE DESTINATION lib${LLVM_LIBDIR_SUFFIX})
LIBRARY DESTINATION ${out_dir}
ARCHIVE DESTINATION ${out_dir})
else()
install(TARGETS ${name}
LIBRARY DESTINATION lib${LLVM_LIBDIR_SUFFIX}
Expand All @@ -93,23 +93,39 @@ macro(add_lldb_library name)
# Hack: only some LLDB libraries depend on the clang autogenerated headers,
# but it is simple enough to make all of LLDB depend on some of those
# headers without negatively impacting much of anything.
add_dependencies(${name} libclang)
get_property(CLANG_TABLEGEN_TARGETS GLOBAL PROPERTY CLANG_TABLEGEN_TARGETS)
if(CLANG_TABLEGEN_TARGETS)
add_dependencies(${name} ${CLANG_TABLEGEN_TARGETS})
endif()

set_target_properties(${name} PROPERTIES FOLDER "lldb libraries")
endmacro(add_lldb_library)

macro(add_lldb_executable name)
add_llvm_executable(${name} DISABLE_LLVM_LINK_LLVM_DYLIB ${ARGN})
set_target_properties(${name} PROPERTIES FOLDER "lldb executables")
# ELF and Mach-O loaders have different ways of expressing that an rpath
# should be relative to the binary being loaded. Mach-O uses @loader_path, and
# ELF uses $ORIGIN.
if(APPLE)
set(rpath_prefix "@loader_path")
else()
set(rpath_prefix "$ORIGIN")
cmake_parse_arguments(ARG "INCLUDE_IN_FRAMEWORK" "" "" ${ARGN})
add_llvm_executable(${name} DISABLE_LLVM_LINK_LLVM_DYLIB ${ARG_UNPARSED_ARGUMENTS})
set_target_properties(${name} PROPERTIES
FOLDER "lldb executables")

if(LLDB_BUILD_FRAMEWORK)
if(ARG_INCLUDE_IN_FRAMEWORK)
string(REGEX REPLACE "[^/]+" ".." _dots ${LLDB_FRAMEWORK_INSTALL_DIR})
set_target_properties(${name} PROPERTIES
RUNTIME_OUTPUT_DIRECTORY $<TARGET_FILE_DIR:liblldb>/Resources
BUILD_WITH_INSTALL_RPATH On
INSTALL_RPATH "@loader_path/../../../../${_dots}/${LLDB_FRAMEWORK_INSTALL_DIR}")

add_llvm_tool_symlink(${name} $<TARGET_FILE:${name}> ARG_ALWAYS_GENERATE)
else()
set_target_properties(${name} PROPERTIES
BUILD_WITH_INSTALL_RPATH On
INSTALL_RPATH "@loader_path/../${LLDB_FRAMEWORK_INSTALL_DIR}")
endif()
endif()
set_target_properties(${name} PROPERTIES INSTALL_RPATH "${rpath_prefix}/../lib")

# Might need the following in an else clause for above to cover non-Apple
# set(rpath_prefix "$ORIGIN")
# set_target_properties(${name} PROPERTIES INSTALL_RPATH "${rpath_prefix}/../lib")
endmacro(add_lldb_executable)

# Support appending linker flags to an existing target.
Expand Down
5 changes: 5 additions & 0 deletions cmake/modules/LLDBConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,11 @@ if (CMAKE_SYSTEM_NAME MATCHES "Darwin")
find_library(SECURITY_LIBRARY Security)
find_library(DEBUG_SYMBOLS_LIBRARY DebugSymbols PATHS "/System/Library/PrivateFrameworks")

set(LLDB_FRAMEWORK_INSTALL_DIR Library/Frameworks CACHE STRING "Output directory for LLDB.framework")
set(LLDB_FRAMEWORK_VERSION A CACHE STRING "LLDB.framework version (default is A)")
set(LLDB_FRAMEWORK_RESOURCE_DIR
LLDB.framework/Versions/${LLDB_FRAMEWORK_VERSION}/Resources)

add_definitions( -DLIBXML2_DEFINED )
list(APPEND system_libs xml2 ${CURSES_LIBRARIES})
list(APPEND system_libs ${CARBON_LIBRARY} ${FOUNDATION_LIBRARY}
Expand Down
38 changes: 38 additions & 0 deletions include/lldb/API/SBBreakpoint.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,10 @@ class LLDB_API SBBreakpoint {

void SetScriptCallbackFunction(const char *callback_function_name);

void SetCommandLineCommands(SBStringList &commands);

bool GetCommandLineCommands(SBStringList &commands);

SBError SetScriptCallbackBody(const char *script_body_text);

bool AddName(const char *new_name);
Expand All @@ -104,6 +108,8 @@ class LLDB_API SBBreakpoint {

bool GetDescription(lldb::SBStream &description);

bool GetDescription(lldb::SBStream &description, bool include_locations);

static bool EventIsBreakpointEvent(const lldb::SBEvent &event);

static lldb::BreakpointEventType
Expand All @@ -119,6 +125,7 @@ class LLDB_API SBBreakpoint {
GetNumBreakpointLocationsFromEvent(const lldb::SBEvent &event_sp);

private:
friend class SBBreakpointList;
friend class SBBreakpointLocation;
friend class SBTarget;

Expand All @@ -139,6 +146,37 @@ class LLDB_API SBBreakpoint {
lldb::BreakpointSP m_opaque_sp;
};

class SBBreakpointListImpl;

class LLDB_API SBBreakpointList {
public:
SBBreakpointList(SBTarget &target);

~SBBreakpointList();

size_t GetSize() const;

SBBreakpoint GetBreakpointAtIndex(size_t idx);

SBBreakpoint FindBreakpointByID(lldb::break_id_t);

void Append(const SBBreakpoint &sb_file);

bool AppendIfUnique(const SBBreakpoint &sb_file);

void AppendByID(lldb::break_id_t id);

void Clear();

protected:
friend class SBTarget;

void CopyToBreakpointIDList(lldb_private::BreakpointIDList &bp_id_list);

private:
std::shared_ptr<SBBreakpointListImpl> m_opaque_sp;
};

} // namespace lldb

#endif // LLDB_SBBreakpoint_h_
5 changes: 5 additions & 0 deletions include/lldb/API/SBSourceManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,11 @@ class LLDB_API SBSourceManager {
const lldb::SBFileSpec &file, uint32_t line, uint32_t context_before,
uint32_t context_after, const char *current_line_cstr, lldb::SBStream &s);

size_t DisplaySourceLinesWithLineNumbersAndColumn(
const lldb::SBFileSpec &file, uint32_t line, uint32_t column,
uint32_t context_before, uint32_t context_after,
const char *current_line_cstr, lldb::SBStream &s);

protected:
friend class SBCommandInterpreter;
friend class SBDebugger;
Expand Down
3 changes: 3 additions & 0 deletions include/lldb/API/SBStringList.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,12 @@ class LLDB_API SBStringList {
protected:
friend class SBCommandInterpreter;
friend class SBDebugger;
friend class SBBreakpoint;

SBStringList(const lldb_private::StringList *lldb_strings);

void AppendList(const lldb_private::StringList &strings);

const lldb_private::StringList *operator->() const;

const lldb_private::StringList &operator*() const;
Expand Down
79 changes: 79 additions & 0 deletions include/lldb/API/SBTarget.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
// Project includes
#include "lldb/API/SBAddress.h"
#include "lldb/API/SBAttachInfo.h"
#include "lldb/API/SBBreakpoint.h"
#include "lldb/API/SBBroadcaster.h"
#include "lldb/API/SBDefines.h"
#include "lldb/API/SBFileSpec.h"
Expand Down Expand Up @@ -563,6 +564,10 @@ class LLDB_API SBTarget {
BreakpointCreateByLocation(const lldb::SBFileSpec &file_spec, uint32_t line,
lldb::addr_t offset);

lldb::SBBreakpoint
BreakpointCreateByLocation(const lldb::SBFileSpec &file_spec, uint32_t line,
lldb::addr_t offset, SBFileSpecList &module_list);

lldb::SBBreakpoint BreakpointCreateByName(const char *symbol_name,
const char *module_name = nullptr);

Expand Down Expand Up @@ -652,6 +657,75 @@ class LLDB_API SBTarget {

lldb::SBBreakpoint BreakpointCreateBySBAddress(SBAddress &address);

//------------------------------------------------------------------
/// Read breakpoints from source_file and return the newly created
/// breakpoints in bkpt_list.
///
/// @param[in] source_file
/// The file from which to read the breakpoints.
///
/// @param[out] bkpt_list
/// A list of the newly created breakpoints.
///
/// @return
/// An SBError detailing any errors in reading in the breakpoints.
//------------------------------------------------------------------
lldb::SBError BreakpointsCreateFromFile(SBFileSpec &source_file,
SBBreakpointList &new_bps);

//------------------------------------------------------------------
/// Read breakpoints from source_file and return the newly created
/// breakpoints in bkpt_list.
///
/// @param[in] source_file
/// The file from which to read the breakpoints.
///
/// @param[in] matching_names
/// Only read in breakpoints whose names match one of the names in this
/// list.
///
/// @param[out] bkpt_list
/// A list of the newly created breakpoints.
///
/// @return
/// An SBError detailing any errors in reading in the breakpoints.
//------------------------------------------------------------------
lldb::SBError BreakpointsCreateFromFile(SBFileSpec &source_file,
SBStringList &matching_names,
SBBreakpointList &new_bps);

//------------------------------------------------------------------
/// Write breakpoints to dest_file.
///
/// @param[in] dest_file
/// The file to which to write the breakpoints.
///
/// @return
/// An SBError detailing any errors in writing in the breakpoints.
//------------------------------------------------------------------
lldb::SBError BreakpointsWriteToFile(SBFileSpec &dest_file);

//------------------------------------------------------------------
/// Write breakpoints listed in bkpt_list to dest_file.
///
/// @param[in] dest_file
/// The file to which to write the breakpoints.
///
/// @param[in] bkpt_list
/// Only write breakpoints from this list.
///
/// @param[in] append
/// If \btrue, append the breakpoints in bkpt_list to the others
/// serialized in dest_file. If dest_file doesn't exist, then a new
/// file will be created and the breakpoints in bkpt_list written to it.
///
/// @return
/// An SBError detailing any errors in writing in the breakpoints.
//------------------------------------------------------------------
lldb::SBError BreakpointsWriteToFile(SBFileSpec &dest_file,
SBBreakpointList &bkpt_list,
bool append = false);

uint32_t GetNumBreakpoints() const;

lldb::SBBreakpoint GetBreakpointAtIndex(uint32_t idx) const;
Expand All @@ -660,6 +734,10 @@ class LLDB_API SBTarget {

lldb::SBBreakpoint FindBreakpointByID(break_id_t break_id);

// Finds all breakpoints by name, returning the list in bkpt_list. Returns
// false if the name is not a valid breakpoint name, true otherwise.
bool FindBreakpointsByName(const char *name, SBBreakpointList &bkpt_list);

bool EnableAllBreakpoints();

bool DisableAllBreakpoints();
Expand Down Expand Up @@ -752,6 +830,7 @@ class LLDB_API SBTarget {
protected:
friend class SBAddress;
friend class SBBlock;
friend class SBBreakpointListImpl;
friend class SBDebugger;
friend class SBExecutionContext;
friend class SBFunction;
Expand Down
Loading