summaryrefslogtreecommitdiff
path: root/Userland/Utilities/bt.cpp
AgeCommit message (Collapse)Author
2021-11-28Everywhere: Use default execpromises argument for Core::System::pledgeBrian Gianforcaro
2021-11-27bt: Port to LibMain :^)Kenneth Myhra
2021-07-22Userland: Use /proc/kernel_base to determine the kernel base addressGunnar Beutner
This removes all the hard-coded kernel base addresses from userspace tools. One downside for this is that e.g. Profiler no longer uses a different color for kernel symbols when run as a non-root user.
2021-07-20Userland: Hardcode the x86_64 kernel base address for nowGunnar Beutner
2021-06-30AK+Everywhere: Add and use static APIs for LexicalPathMax Wipfli
The LexicalPath instance methods dirname(), basename(), title() and extension() will be changed to return StringView const& in a further commit. Due to this, users creating temporary LexicalPath objects just to call one of those getters will recieve a StringView const& pointing to a possible freed buffer. To avoid this, static methods for those APIs have been added, which will return a String by value to avoid those problems. All cases where temporary LexicalPath objects have been used as described above haven been changed to use the static APIs.
2021-06-19LibSymbolication+Utilities: Show inlined functions for btGunnar Beutner
2021-06-01LibGUI+Shell+bt+ls: Use proper APIs for creating file URLsMax Wipfli
This patch replaces ad-hoc generation of file URL strings with using URL::create_with_file_scheme().
2021-05-23Userland: Tweak the visual display of the `bt` utilityBrian Gianforcaro
This patch adds a few minor visual features to the `bt` utility: - Number each frame of the back trace. - Color the address based on if it's in kernel or user space. - Add a "frames:" heading to visually seperate the thread id. - Rename "tid: <tid>" -> "thread: <tid>" as it's more visually appealing since it aligns vertically with "frames:" - Add a visual " | " seperate between the address and symbol name.
2021-05-22LibCore: Make all processes opt out of InspectorServer by defaultAndreas Kling
This functionality, while neat, isn't really something you need enabled all the time. Let's make it opt-in instead. Pass MakeInspectable::Yes to the Core::EventLoop constructor if you want your program to become inspectable.
2021-05-22LibSymbolication: Rename Client.{cpp,h} => Symbolication.{cpp,h}Andreas Kling
2021-05-22LibSymbolication+SystemMonitor+bt: Move symbolication back in-processAndreas Kling
Process-separated symbolication was cute, but ultimately the threat model is kinda silly. We're already *running* the binary, but we're afraid to parse its symbol table? :^) This commit makes SystemMonitor and bt do symbolication in-process. SymbolServer and the symbol user will be removed separately.
2021-05-22Userland: Rename LibSymbolClient => LibSymbolicationAndreas Kling
2021-05-13Userland: Remove no-longer-needed unveil()'s of /tmp/rpcAndreas Kling
2021-05-01bt: Enumerate all threads when symbolizing stacks in the bt utility.Brian Gianforcaro
Enumerate tid's from /proc/{pid}/stacks/ and use it to print the backtrace for all active threads in the specified process.
2021-05-01bt: Fix generation of click-able links for source files.Brian Gianforcaro
When the default build location was moved from /Build to the new architecture specific directory, /Build/i686, this code broke. All file names are now path relative one additional level up. So continue the hack, and introduce another dummy directory to make the relative paths resolve correctly.
2021-04-22Everything: Move to SPDX license identifiers in all files.Brian Gianforcaro
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-03-15bt: add source file number integrationElDonad
2021-03-12Everywhere: Remove klog(), dbg() and purge all LogStream usage :^)Andreas Kling
Good-bye LogStream. Long live AK::Format!
2021-02-05bt: Hyperlink filenames in backtraces if available :^)Andreas Kling
If we can find a matching filename in /usr/src/serenity, let's make the filenames in backtraces clickable to open that file.
2021-02-05bt: Show filenames and line numbers when available :^)Andreas Kling
2021-02-04LibSymbolClient+bt: Move bt logic to SymbolClient::symbolicate_thread()Andreas Kling
Since this is useful in many places, let's have a common implementation of walking the stack of a given thread via /proc and symbolicating each of the frames.
2021-02-04SymbolServer+bt: Symbolicate kernel addresses if /boot/Kernel availableAndreas Kling
The /boot directory is only accessible to root by default, but anyone wanting access to kernel symbols for development can get them by making /boot/Kernel accessible to the "symbol" user.
2021-02-04bt: Add a little backtrace program that uses SymbolServerAndreas Kling
Usage: bt <PID> This program will print a symbolicated backtrace for the main thread of the process with the given PID. It uses SymbolServer for the symbolication. There's a lot of room for improvement in this command, but it is pretty neat already. :^)