summaryrefslogtreecommitdiff
path: root/Userland/DevTools
AgeCommit message (Collapse)Author
2021-07-31HackStudio+TextEditor: Sync extensions from the FileIconProvider fileKarol Kosek
This adds more possible extensions for highlighting C/C++ files and JavaScript module files.
2021-07-31HackStudio: Don't use 'else' after 'return'Karol Kosek
2021-07-31HackStudio: Add syntax highlighting for HTML, Shell, and SQL filesKarol Kosek
.html files were recognised before -- the name was shown on the statusbar, but it didn't actually enable the syntax highlighting. This also sneaks a highlighting for JSON using JS highlighting. It isn't technically correct, but so does TextEditor. :^)
2021-07-29Profiler: Don't perform disassembly when disassembly view is hiddenAndreas Kling
2021-07-29HackStudio: Add GML Preview action tabConor Byrne
This allows us to show a GML Preview in realtime via HackStudio::GMLPreviewWidget! :^)
2021-07-29HackStudio: Add autocompletion for GML filesConor Byrne
2021-07-29LibGUI+Playground: Move GMLAutocompleteProvider to LibGUIConor Byrne
2021-07-28HackStudio: Tweak splitter spacings in the main UIAndreas Kling
The splitters all felt a little bit too small and hard-to-grab. This patch puts a little more fat on them.
2021-07-27Kernel: Support loading the kernel at almost arbitrary virtual addressesGunnar Beutner
This enables further work on implementing KASLR by adding relocation support to the pre-kernel and updating the kernel to be less dependent on specific virtual memory layouts.
2021-07-26HackStudio: Resize editors when removing panesNicholas Hollett
Splitter does weird things when you resize and then remove children. This works around the limitation by forcing at least one of the editors to fill the space. It's janky, but at least doesn't result in the last editor not filling the window.
2021-07-24GML Playground: Add Vim emulationPhoenix
2021-07-22UserspaceEmulator: Move to using the new SoftFPUHendiadyoin1
2021-07-22UserspaceEmulator: Implement SoftFPU instructionsHendiadyoin1
This implements almost all instructions related to the FPU, including all MMX instructions as well. A lot of these were copied and adjusted from the SoftCPU implementation. The next big milestone would be QNan detection and ShadowValue handling.
2021-07-22UserspaceEmulator: Sketch out a SoftFPU interfaceHendiadyoin1
2021-07-22LibX86: Add missing MovD and MovQ instructionsHendiadyoin1
These are placeholders for now
2021-07-22LibX86: Use names closer to the spec for the ModrmHendiadyoin1
This gets rid of a lot of magic number shifts and ands.
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-22Everywhere: Prefer using {:#x} over 0x{:x}Gunnar Beutner
We have a dedicated format specifier which adds the "0x" prefix, so let's use that instead of adding it manually.
2021-07-22Everywhere: Prefix hexadecimal numbers with 0xGunnar Beutner
Depending on the values it might be difficult to figure out whether a value is decimal or hexadecimal. So let's make this more obvious. Also this allows copying and pasting those numbers into GNOME calculator and probably also other apps which auto-detect the base.
2021-07-21Userland: Add GUI::Window::add_menu() and use it everywhereAndreas Kling
Applications previously had to create a GUI::Menubar object, add menus to it, and then call GUI::Window::set_menubar(). This patch introduces GUI::Window::add_menu() which creates the menubar automatically and adds items to it. Application code becomes slightly simpler as a result. :^)
2021-07-21LibGfx: Use "try_" prefix for static factory functionsAndreas Kling
Also mark them as [[nodiscard]].
2021-07-20LibX86: Add INT1 instruction (needed for disassembly)Andreas Kling
2021-07-20Profiler: Make profiler not truncate 64-bit addressesGunnar Beutner
2021-07-20Userland: Hardcode the x86_64 kernel base address for nowGunnar Beutner
2021-07-19Revert "Profiler: Configure the TimelineContainer to be shrink to fit"Brian Gianforcaro
This reverts commit cfef3040fb00127552158f233ebe4705bf242c25. It looks like although this does improve things, it also degrades the experience and messes with the usability, especially for large amounts of processes. Need to come back to this with a more holistic fix.
2021-07-18Everywhere: Improve CPU usage calculationTom
As threads come and go, we can't simply account for how many time slices the threads at any given point may have been using. We need to also account for threads that have since disappeared. This means we also need to track how many time slices we have expired globally. However, because this doesn't account for context switches outside of the system timer tick values may still be under-reported. To solve this we will need to track more accurate time information on each context switch. This also fixes top's cpu usage calculation which was still based on the number of context switches. Fixes #6473
2021-07-18LibRegex+Everywhere: Make LibRegex more unicode-awareAli Mohammad Pur
This commit makes LibRegex (mostly) capable of operating on any of the three main string views: - StringView for raw strings - Utf8View for utf-8 encoded strings - Utf32View for raw unicode strings As a result, regexps with unicode strings should be able to properly handle utf-8 and not stop in the middle of a code point. A future commit will update LibJS to use the correct type of string depending on the flags.
2021-07-18Kernel: Split debug symbols into a separate fileGunnar Beutner
This speeds up the boot process considerably when specifying the kernel image via -initrd.
2021-07-18HackStudio: Prevent crash when stepping through a programMaurice Hieronymus
The backtrace view expects that there is always a valid selection. This is not true when we execute a step in the debugger. Therefore we need to check if we have a valid selection in the on_selection_change handler.
2021-07-17Profiler: Configure the TimelineContainer to be shrink to fitBrian Gianforcaro
Today the profile viewer timeline view has a static size, which is computed as half the height of the window given it has two root widgets. Instead the timeline view should shrink to only consume the size that each process timeline consumes.
2021-07-17HackStudio: Continue removing files after failureKarol Kosek
2021-07-17HackStudio: Disable Delete action on insufficient permissionsKarol Kosek
Hack Studio will now disable the action when any parent of selected files do not have write permission.
2021-07-16HackStudio: Add statusbar with file and selected text informationry-sev
2021-07-14UserpaceEmulator: Handle possibly unaligned IOHendiadyoin1
We also should add some UB warnings for that in the future
2021-07-12HackStudio: Activate window only on file dropKarol Kosek
2021-07-12UserspaceEmulator: Fix stack for new processesGunnar Beutner
Fixes #8646.
2021-07-12IPCCompiler: Use GENERATE_DEBUG from AK/Debug instead of custom definesAndrew Kaster
The IPCCompiler was using GENERATE_DEBUG_CODE, which was missing from AK/Debug.h.in, and plain old DEBUG. Let's just use the one that was already in the debug header, but unused.
2021-07-12HackStudio: Disable debug specific context entriesMaurice Hieronymus
Context menu entries like evaluate expression and move execution to line action should only be enabled when a debug session is running. Otherwise they should be disabled.
2021-07-12HackStudio: Disable run button while debuggingMaurice Hieronymus
This commit disables the run button while we are in debug mode. Otherwise the stop button gets disabled when we run the program while we are in debug mode. This would prevent us from exiting the debug mode.
2021-07-10LibCpp: Use fast_is<T> and verify_cast<T> to replace C-style castsItamar
Thanks to @alimpfard for suggesting this :)
2021-07-10LibCpp: Make the fields of AST node types privateItamar
Previously almost all fields were public and were directly accessed by the Parser and CppComprehensionEngine. This commit makes all fields of AST node types private. They are now accessed via getters & setters.
2021-07-09LibThreading: Rename Lock => MutexAndreas Kling
2021-07-08UserspaceEmulator: Use long double in `FABS`Daniel Bertalan
`fpu_get` returns a long double and `fpu_set` expects a long double as its parameter, and the X87 FPU uses long doubles as its internal storage, meaning the `FABS` operates on them. This means the correct intrinsic function for implementing it is `__builtin_fabsl`.
2021-07-08Everywhere: Add break after the last case label before `default`Daniel Bertalan
We already do this in most places, so the style should be consistent. Also, Clang does not like it, as this could cause an unexpected compile error if some statements are added to the default label or a new label is added above it.
2021-07-08Everywhere: Forward declare structs as structsDaniel Bertalan
While structs being forward declared as classes is not strictly an issue, Clang complains as this is not portable code, since some ABIs treat classes declared as `class` and `struct` differently. It's easier to fix these than to reason about explicitly disabling another warning.
2021-07-08IPCCompiler+WindowServer: Fix deleted function warningDaniel Bertalan
It might be the case that we are passing non-movable/non-copyable things through IPC. In this case, Clang will emit a warning as it can't generate the requested default move/copy ctor for the IPC message. To fix this, we use a `#pragma` to make the compiler silently ignore our request. The same was the case with the three-way comparison in `Screen`. Since we don't use the three-way comparison operator anywhere else in our codebase, we simply use the `==` operator instead.
2021-07-08HackStudio: Do not check NonnullRefPtr for null valueDaniel Bertalan
2021-07-08Everywhere: Remove unused local variables and lambda capturesDaniel Bertalan
2021-07-06LibJS: Remove the non-standard put helper and replace it's usagesIdan Horowitz
This removes all usages of the non-standard put helper method and replaces all of it's usages with the specification required alternative or with define_direct_property where appropriate.
2021-07-04LibJS: Rewrite most of Object for spec compliance :^)Linus Groh
This is a huge patch, I know. In hindsight this perhaps could've been done slightly more incremental, but I started and then fixed everything until it worked, and here we are. I tried splitting of some completely unrelated changes into separate commits, however. Anyway. This is a rewrite of most of Object, and by extension large parts of Array, Proxy, Reflect, String, TypedArray, and some other things. What we already had worked fine for about 90% of things, but getting the last 10% right proved to be increasingly difficult with the current code that sort of grew organically and is only very loosely based on the spec - this became especially obvious when we started fixing a large number of test262 failures. Key changes include: - 1:1 matching function names and parameters of all object-related functions, to avoid ambiguity. Previously we had things like put(), which the spec doesn't have - as a result it wasn't always clear which need to be used. - Better separation between object abstract operations and internal methods - the former are always the same, the latter can be overridden (and are therefore virtual). The internal methods (i.e. [[Foo]] in the spec) are now prefixed with 'internal_' for clarity - again, it was previously not always clear which AO a certain method represents, get() could've been both Get and [[Get]] (I don't know which one it was closer to right now). Note that some of the old names have been kept until all code relying on them is updated, but they are now simple wrappers around the closest matching standard abstract operation. - Simplifications of the storage layer: functions that write values to storage are now prefixed with 'storage_' to make their purpose clear, and as they are not part of the spec they should not contain any steps specified by it. Much functionality is now covered by the layers above it and was removed (e.g. handling of accessors, attribute checks). - PropertyAttributes has been greatly simplified, and is being replaced by PropertyDescriptor - a concept similar to the current implementation, but more aligned with the actual spec. See the commit message of the previous commit where it was introduced for details. - As a bonus, and since I had to look at the spec a whole lot anyway, I introduced more inline comments with the exact steps from the spec - this makes it super easy to verify correctness. - East-const all the things. As a result of all of this, things are much more correct but a bit slower now. Retaining speed wasn't a consideration at all, I have done no profiling of the new code - there might be low hanging fruits, which we can then harvest separately. Special thanks to Idan for helping me with this by tracking down bugs, updating everything outside of LibJS to work with these changes (LibWeb, Spreadsheet, HackStudio), as well as providing countless patches to fix regressions I introduced - there still are very few (we got it down to 5), but we also get many new passing test262 tests in return. :^) Co-authored-by: Idan Horowitz <idan.horowitz@gmail.com>