summaryrefslogtreecommitdiffstats
path: root/src/core/arm/arm_interface.cpp (unfollow)
Commit message (Collapse)AuthorFilesLines
2023-12-23kernel: instantiate memory separately for each guest processLiam1-1/+1
2023-12-04core: refactor emulated cpu core activationLiam1-208/+9
2023-11-25arm: Print backtrace on data abortGPUCode1-0/+2
2023-11-13core: check for thread dpc before eretLiam1-8/+8
2023-10-22kernel: update KProcessLiam1-3/+3
2023-07-15Fixes and workarounds to make UBSan happier on macOScomex1-2/+2
There are still some other issues not addressed here, but it's a start. Workarounds for false-positive reports: - `RasterizerAccelerated`: Put a gigantic array behind a `unique_ptr`, because UBSan has a [hardcoded limit](https://stackoverflow.com/questions/64531383/c-runtime-error-using-fsanitize-undefined-object-has-a-possibly-invalid-vp) of how big it thinks objects can be, specifically when dealing with offset-to-top values used with multiple inheritance. Hopefully this doesn't have a performance impact. - `QueryCacheBase::QueryCacheBase`: Avoid an operation that UBSan thinks is UB even though it at least arguably isn't. See the link in the comment for more information. Fixes for correct reports: - `PageTable`, `Memory`: Use `uintptr_t` values instead of pointers to avoid UB from pointer overflow (when pointer arithmetic wraps around the address space). - `KScheduler::Reload`: `thread->GetOwnerProcess()` can be `nullptr`; avoid calling methods on it in this case. (The existing code returns a garbage reference to a field, which is then passed into `LoadWatchpointArray`, and apparently it's never used, so it's harmless in practice but still triggers UBSan.) - `KAutoObject::Close`: This function calls `this->Destroy()`, which overwrites the beginning of the object with junk (specifically a free list pointer). Then it calls `this->UnregisterWithKernel()`. UBSan complains about a type mismatch because the vtable has been overwritten, and I believe this is indeed UB. `UnregisterWithKernel` also loads `m_kernel` from the 'freed' object, which seems to be technically safe (the overwriting doesn't extend as far as that field), but seems dubious. Switch to a `static` method and load `m_kernel` in advance.
2023-07-09arm_interface: correct breakpoint rewind conditionLiam1-1/+1
2023-06-13core: decouple ARM interface from DynarmicLiam1-15/+69
2023-03-24memory: rename global memory references to application memoryLiam1-1/+1
2023-03-22kernel: use KTypedAddress for addressesLiam1-5/+5
2023-02-14general: rename CurrentProcess to ApplicationProcessLiam1-3/+3
2023-01-14Be careful of mangled out of bounds readKelebek11-4/+0
2023-01-14Add stacktrace symbol demanglingKelebek11-14/+4
2022-12-02core: add option to break on unmapped accessLiam1-2/+6
2022-10-19core: hle: kernel: k_thread: Implement thread termination DPC.bunnei1-0/+8
2022-07-15dynarmic: Abort watchpoints ASAPMerry1-1/+0
2022-07-15kernel: use KScheduler from mesosphereLiam1-1/+2
2022-06-25core/arm: better support for backtrace generationLiam1-0/+15
2022-06-23kernel: make current thread pointer thread localLiam1-1/+1
2022-06-22dynarmic: Stop ReadCode callbacks to unmapped addressesLiam1-5/+12
2022-06-16core/debugger: memory breakpoint supportLiam1-1/+40
2022-06-15core: centralize profile scope for DynarmicLiam1-0/+2
2022-06-01core/debugger: Improved stepping mechanism and misc fixesLiam1-2/+43
2022-06-01core/debugger: Implement new GDB stub debuggerLiam1-0/+5
2022-04-23general: Convert source file copyright comments over to SPDXMorph1-3/+2
This formats all copyright comments according to SPDX formatting guidelines. Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
2022-04-21core/arm: separate backtrace collectionLiam1-83/+14
2022-04-09core: extract symbol readingLiam1-129/+12
2020-10-30General: Resolve a few missing initializer warningsLioncash1-2/+10
Resolves a few -Wmissing-initializer warnings.
2020-10-21Revert "core: Fix clang build"bunnei1-20/+4
2020-10-18core: Fix clang buildLioncash1-4/+20
Recent changes to the build system that made more warnings be flagged as errors caused building via clang to break. Fixes #4795
2020-06-27ARM/WaitTree: Better track the CallStack for each thread.Fernando Sahmkow1-0/+57
2020-04-17core: memory: Move to Core::Memory namespace.bunnei1-1/+1
- helpful to disambiguate Kernel::Memory namespace.
2020-04-16CMakeLists: Specify -Wextra on linux buildsLioncash1-2/+2
Allows reporting more cases where logic errors may exist, such as implicit fallthrough cases, etc. We currently ignore unused parameters, since we currently have many cases where this is intentional (virtual interfaces). While we're at it, we can also tidy up any existing code that causes warnings. This also uncovered a few bugs as well.
2019-11-27core/memory: Migrate over Read{8, 16, 32, 64, Block} to the Memory classLioncash1-12/+12
With all of the trivial parts of the memory interface moved over, we can get right into moving over the bits that are used. Note that this does require the use of GetInstance from the global system instance to be used within hle_ipc.cpp and the gdbstub. This is fine for the time being, as they both already rely on the global system instance in other functions. These will be removed in a change directed at both of these respectively. For now, it's sufficient, as it still accomplishes the goal of de-globalizing the memory code.
2019-11-27core: Prepare various classes for memory read/write migrationLioncash1-2/+1
Amends a few interfaces to be able to handle the migration over to the new Memory class by passing the class by reference as a function parameter where necessary. Notably, within the filesystem services, this eliminates two ReadBlock() calls by using the helper functions of HLERequestContext to do that for us.
2019-05-26loader: Move NSO module tracking to AppLoaderZach Hilman1-8/+19
Also cleanup of general stuff
2019-05-25arm_interface: Expand backtrace generationZach Hilman1-7/+183
Returns results as a vector of entries for further processing. Logs addresses, offsets, and mangled name.
2018-12-31arm_interface: Make include path relative for arm_interface.hLioncash1-1/+1
Makes it consistent with the rest of the includes.
2018-12-31arm_interface: Make LogBacktrace() a const member functionLioncash1-1/+1
This function doesn't modify instance state, so it can be made const.
2018-12-31arm_interface: Mark variables as const where applicable in LogBacktrace()Lioncash1-3/+4
Two of these variables have fixed values, so we can make that immediately obvious from the get-go.
2018-12-31arm_interface: Remove unnecessary semicolonLioncash1-1/+1
Namespaces don't require the use of a semicolon. Silences a -Wextra-semi warning.
2018-12-29Moved log backtrace to arm_interface.cpp. Added printing of error code to fatalDavid Marcec1-0/+26