summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Platform/Android
Commit message (Collapse)AuthorAgeFilesLines
...
* Add check for non-null log instance in PlatformAndroid.Oleksiy Vyalov2016-07-211-1/+1
| | | | llvm-svn: 276303
* Use shell cat command as a workaround if ADB stat cannot lookup a file.Oleksiy Vyalov2016-07-083-14/+86
| | | | | | http://reviews.llvm.org/D22081 llvm-svn: 274895
* Respect ANDROID_SERIAL environment variable used by ADBLuke Drummond2016-07-071-6/+12
| | | | | | | | | | | When multiple Android devices are attached, the default behaviour of ADB is to resolve a device number based on the presence of ANDROID_SERIAL if the serial number is not explicitly passed by the -s parameter. This patch emulates that behaviour in lldb's ADB platform connector Differential Revision: http://reviews.llvm.org/D22052 llvm-svn: 274776
* Fix ADB client disconnect issues.Oleksiy Vyalov2016-07-064-25/+106
| | | | | | http://reviews.llvm.org/D22029 llvm-svn: 274638
* Add oat symbolization support for odex filesTamas Berghammer2016-07-061-2/+3
| | | | | | Differential revision: http://reviews.llvm.org/D22040 llvm-svn: 274635
* Fix for Windows builds.Adrian McCarthy2016-06-301-0/+6
| | | | llvm-svn: 274277
* Improve ADB utilization within Android platform.Oleksiy Vyalov2016-06-305-188/+242
| | | | | | http://reviews.llvm.org/D21770 llvm-svn: 274256
* Bump up adb timeout morePavel Labath2016-05-161-1/+1
| | | | | | still seeing very rare timeouts on the buildbot. llvm-svn: 269648
* Bump up timeout in AdbClientPavel Labath2016-05-051-1/+1
| | | | | | | now that the timeout actually means something, we see that sometimes adb is just really slow in replying to the DONE packet during file push. Give it more time to complete. llvm-svn: 268623
* Fix EOF handling in AdbClient (take 2)Pavel Labath2016-05-051-5/+16
| | | | | | | | | | | | | | Summary: AdbClient would spin in a loop in ReadAllBytes in case the remote end was closed before reading the requested number of bytes. Make sure we return an error in this case instead. Reviewers: ovyalov Subscribers: tberghammer, danalbert, lldb-commits Differential Revision: http://reviews.llvm.org/D19916 llvm-svn: 268617
* Revert "Add a read_full_buffer argument to ConnectionFileDescriptor::Read"Pavel Labath2016-05-031-11/+13
| | | | | | | This reverts commit r268380 as it breaks windows build (I forgot to make neccesary adjustments to ConnectionGenericFileWindows). llvm-svn: 268384
* Add a read_full_buffer argument to ConnectionFileDescriptor::ReadPavel Labath2016-05-031-13/+11
| | | | | | | | | | | | | | | | | | | | | Summary: AdbClient was attempting to handle the case where the socket input arrived in pieces, but it was failing to handle the case where the connection was closed before that happened. In this case, it would just spin in an infinite loop calling Connection::Read. (This was also the cause of the spurious timeouts on the darwin->android buildbot. The exact cause of the premature EOF remains to be investigated, but is likely a server bug.) Since this wait-for-a-certain-number-of-bytes seems like a useful functionality to have, I am moving it (with the infinite loop fixed) to the Connection class, and adding an appropriate test for it. Reviewers: clayborg, zturner, ovyalov Subscribers: tberghammer, danalbert, lldb-commits Differential Revision: http://reviews.llvm.org/D19533 llvm-svn: 268380
* [LLDB]{MIPS] Fix TestPlatformProcessConnect.pyMohit K. Bhakkad2016-03-222-18/+0
| | | | | | | | | | Patch by Nitesh Jain Reviewers: clayborg, labath. Subscribers: jaydeep, bhushan, mohit.bhakkad, sagar, lldb-commits. Differential Revision: http://reviews.llvm.org/D18082 llvm-svn: 264030
* Remove autoconf support from source directories.Eugene Zelenko2016-01-281-14/+0
| | | | | | Differential revision: http://reviews.llvm.org/D16662 llvm-svn: 259098
* Modify "platform connect" to connect to processes as wellTamas Berghammer2015-12-082-0/+60
| | | | | | | | | | | | | | | | | | | | | | | | The standard remote debugging workflow with gdb is to start the application on the remote host under gdbserver (e.g.: gdbserver :5039 a.out) and then connect to it with gdb. The same workflow is supported by debugserver/lldb-gdbserver with a very similar syntax but to access all features of lldb we need to be connected also to an lldb-platform instance running on the target. Before this change this had to be done manually with starting a separate lldb-platform on the target machine and then connecting to it with lldb before connecting to the process. This change modifies the behavior of "platform connect" with automatically connecting to the process instance if it was started by the remote platform. With this command replacing gdbserver in a gdb based worflow is usually as simple as replacing the command to execute gdbserver with executing lldb-platform. Differential revision: http://reviews.llvm.org/D14952 llvm-svn: 255016
* Remove some duplicated code from PlatformPOSIX/AndroidTamas Berghammer2015-12-032-93/+11
| | | | | | | | | | The code was duplicated to handle the custom symbol name for functions in libdl.so for android. This change modify the way we handle the issue to eliminate a lot of duplicated code. Differential revision: http://reviews.llvm.org/D15183 llvm-svn: 254608
* Fix "process load/unload" on androidTamas Berghammer2015-12-022-0/+98
| | | | | | | | | | | On android the symbols exposed by libdl (dlopen, dlclose, dlerror) prefixed by "__dl_". This change moves the handling of process load/unload to the platform object and override it for android to handle the special prefix. Differential revision: http://reviews.llvm.org/D11465 llvm-svn: 254504
* Provide ADB port forwarding support for abstract sockets.Oleksiy Vyalov2015-11-034-6/+43
| | | | | | http://reviews.llvm.org/D14262 llvm-svn: 251879
* Revert r251578. I was in the middle of editing the commit messageJason Molenda2015-10-281-1/+1
| | | | | | | | | | | | | and decided to not commit the change, but accidentally committed it anyway. This was based on a static analysis complaint; it thought there was a code path where AdbClient::PushFile would call AdbClient::ReadSyncHeader and AdbClient::ReadSyncHeader wouldn't set data_len. But in that case, the Error object returned will be Fail and we won't use the data_len or response_id contents. llvm-svn: 251580
* Initialize data_len to 0 in source/Plugins/Platform/Android/AdbClient.cppJason Molenda2015-10-281-1/+1
| | | | llvm-svn: 251578
* Treat hostname in android URL as device id unless it matches "localhost".Oleksiy Vyalov2015-10-272-2/+2
| | | | | | http://reviews.llvm.org/D14101 llvm-svn: 251422
* Fix Clang-tidy modernize-use-override warnings in ↵Eugene Zelenko2015-10-272-12/+8
| | | | | | source/Plugins/LanguageRuntime and Platform; other minor fixes. llvm-svn: 251374
* Set device_id to host value only in case of adb protocol.Oleksiy Vyalov2015-10-222-2/+4
| | | | llvm-svn: 251044
* Add domain socket support to gdb-remote protocol and lldb-server.Oleksiy Vyalov2015-10-215-51/+71
| | | | | | http://reviews.llvm.org/D13881 llvm-svn: 250933
* Increase default memory cache line size for androidPavel Labath2015-10-202-0/+10
| | | | | | | | | | | | | | | | Summary: ADB packets have a maximum size of 4k. This means the size of memory reads does not affect speed too much (as long as it fits in one packet). Therefore, I am increasing the default memory read size for android to 2k. This value is used only if the user has not modified the default memory-cache-line-size setting. Reviewers: clayborg, tberghammer Subscribers: tberghammer, danalbert, srhines, lldb-commits Differential Revision: http://reviews.llvm.org/D13812 llvm-svn: 250814
* Split Socket class into Tcp/Udp/DomainSocket subclasses.Oleksiy Vyalov2015-10-151-10/+10
| | | | | | http://reviews.llvm.org/D13754 llvm-svn: 250474
* Fix Android-SDK detection on API 10 deviceTamas Berghammer2015-10-011-11/+7
| | | | | | | | Run the getprop command with AdbClient::Shell instead of Platform::RunShellCommand because getting the output from getprop with Platform::RunShellCommand have some (currently unknown) issues. llvm-svn: 249014
* Restrict the scope of a hack in DYLDRendezvousTamas Berghammer2015-10-012-1/+13
| | | | | | | | | | The hack is there to work around an incorrect load address reported by the android linker on API 21 and 22 devices. This CL restricts the hack to those android API levels. Differential revision: http://reviews.llvm.org/D13288 llvm-svn: 249012
* Trim the output of mktem in PlatformAndroid::DownloadSymbolFileTamas Berghammer2015-10-011-1/+1
| | | | | | Differential revision: http://reviews.llvm.org/D13293 llvm-svn: 248998
* Change oat symbolization code for android to work on non-rooted devicesTamas Berghammer2015-09-293-26/+66
| | | | | | | | | | | | | | On android when debugging an apk we run lldb-server as application user because the sell user (on non-rooted device) can't attach to an application. The problem is that "adb pull" will run as a shell user what can't access to files created by lldb-server because they will be owned by the application user. This CL changes the oat symbolization code to run "oatdump --symbolize" to generate an output what is owned by the shell user. Differential revision: http://reviews.llvm.org/D13162 llvm-svn: 248788
* Bind listener to 127.0.0.1 to make sure that loopback address is used.Oleksiy Vyalov2015-09-281-1/+1
| | | | llvm-svn: 248722
* [cmake] Remove LLVM_NO_RTTI.Bruce Mitchener2015-09-031-2/+0
| | | | | | | | | | | | | | Summary: This doesn't exist in other LLVM projects any longer and doesn't do anything. Reviewers: chaoren, labath Subscribers: emaste, tberghammer, lldb-commits, danalbert Differential Revision: http://reviews.llvm.org/D12586 llvm-svn: 246749
* Make remote-android platform to use dynamic local tcp ports when forwarding ↵Oleksiy Vyalov2015-09-014-34/+85
| | | | | | | | device ports. http://reviews.llvm.org/D12510 llvm-svn: 246574
* Make UriParser to support [$HOSTNAME] notation.Oleksiy Vyalov2015-08-202-0/+23
| | | | | | http://reviews.llvm.org/D12025 llvm-svn: 245639
* Download symbol file for .oat files on androidTamas Berghammer2015-08-122-0/+81
| | | | | | | | | | | | | On android .oat files (compiled java code) don't have symbol information but on SDK 23+ it can be generated by the oatdump tool (based on the dex information). This CL adds logic to download this information and store it in the module cache. Differential revision: http://reviews.llvm.org/D11936 llvm-svn: 244738
* Fetch SDK version from PlatformAndroidTamas Berghammer2015-08-122-1/+54
| | | | | | | | | | The SDK version implies the features supported by a given android device. This version number will be used in future changes to execute the right command on the device. Differential revision: http://reviews.llvm.org/D11935 llvm-svn: 244737
* Rename `FileSpec::IsRelativeToCurrentWorkingDirectory` to `IsRelative`.Chaoren Lin2015-06-091-2/+2
| | | | | | | | | | | | | | | | | Summary: `IsRelativeToCurrentWorkingDirectory` was misleading, because relative paths are sometimes appended to other directories, not just the cwd. Plus, the new name is shorter. Also added `IsAbsolute` for completeness. Reviewers: clayborg, ovyalov Reviewed By: ovyalov Subscribers: tberghammer, lldb-commits Differential Revision: http://reviews.llvm.org/D10262 llvm-svn: 239419
* Fix error handling in AdbClient - PushFile and PullFile.Oleksiy Vyalov2015-06-052-10/+82
| | | | | | http://reviews.llvm.org/D10176 llvm-svn: 239130
* Fix PlatformAndroid::PutFile to support relative destination paths.Oleksiy Vyalov2015-06-021-7/+10
| | | | llvm-svn: 238860
* Use FileSpec::IsRelativeToCurrentWorkingDirectory instead of ↵Oleksiy Vyalov2015-05-291-8/+3
| | | | | | | | llvm::sys::path::is_relative in PlatformAndroid::GetFile. http://reviews.llvm.org/D10141 llvm-svn: 238624
* Fix build - GetRemoteWorkingDirectory returns FileSpec instead of ConstString.Oleksiy Vyalov2015-05-291-1/+1
| | | | llvm-svn: 238610
* Fix PlatformAndroid::GetFile - check for relative source path and ↵Oleksiy Vyalov2015-05-291-4/+12
| | | | | | concatenate it with current working directory if needed. llvm-svn: 238606
* Refactor AdbClient and make PlatformAndroid::GetFile to use "adb pull".Oleksiy Vyalov2015-05-284-33/+63
| | | | | | http://reviews.llvm.org/D10082 llvm-svn: 238442
* Implement and use adb push for PlatformAndroid::PutFileRobert Flack2015-05-274-2/+73
| | | | | | | | | | | | | Using the adb push protocol is significantly faster than the current method of sending the hex encoded file data for the remote to write to the file. Test Plan: Tests continue to pass - and much faster (e.g. TestSBValuePersist.py takes 10s down from 4m51s on mac -> android) Differential Revision: http://reviews.llvm.org/D9943 llvm-svn: 238274
* Use ADB pull to download modules from android target.Oleksiy Vyalov2015-05-184-35/+228
| | | | | | http://reviews.llvm.org/D9816 llvm-svn: 237640
* Fixed a ton of gcc compile warningsVince Harron2015-05-131-1/+1
| | | | | | | | | | Removed some unused variables, added some consts, changed some casts to const_cast. I don't think any of these changes are very controversial. Differential Revision: http://reviews.llvm.org/D9674 llvm-svn: 237218
* Support remote-android with multiple connected devices.Chaoren Lin2015-05-015-51/+62
| | | | | | | | | | | | | | | | | | Summary: This change introduces a new URL scheme for `platform connect`: ``` adb://device-id:port ``` Reviewers: vharron, tberghammer, clayborg, ovyalov Reviewed By: ovyalov Subscribers: tberghammer, lldb-commits Differential Revision: http://reviews.llvm.org/D9358 llvm-svn: 236321
* Remove 'z' modifier from printf/sscanf operations in AdbClient - the ↵Oleksiy Vyalov2015-04-101-5/+5
| | | | | | modifier isn't supported by MS C++ compiler. llvm-svn: 234562
* Delete port forwarding if ConnectRemote fails.Oleksiy Vyalov2015-04-072-15/+29
| | | | | | http://reviews.llvm.org/D8826 llvm-svn: 234332
* Fix ForwardPortWithAdb - update device_id variable if Android device has ↵Oleksiy Vyalov2015-04-011-1/+2
| | | | | | been found. llvm-svn: 233780
OpenPOWER on IntegriCloud