Browse Source
fix wattOS
Signed-off-by: lizzie <lizzie@eden-emu.dev>
pull/2752/head
lizzie
5 months ago
No known key found for this signature in database
GPG Key ID: 287378CADCAB13
4 changed files with
23 additions and
28 deletions
-
docs/Deps.md
-
src/common/demangle.cpp
-
src/dynarmic/src/dynarmic/ir/dense_list.h
-
src/dynarmic/src/dynarmic/ir/opt_passes.cpp
|
|
|
@ -102,7 +102,7 @@ sudo pacman -Syu --needed base-devel boost catch2 cmake enet ffmpeg fmt git glsl |
|
|
|
<summary>Ubuntu, Debian, Mint Linux</summary> |
|
|
|
|
|
|
|
```sh |
|
|
|
sudo apt-get install autoconf cmake g++ gcc git glslang-tools libasound2t64 libboost-context-dev libglu1-mesa-dev libhidapi-dev libpulse-dev libtool libudev-dev libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-render-util0 libxcb-xinerama0 libxcb-xkb1 libxext-dev libxkbcommon-x11-0 mesa-common-dev nasm ninja-build qt6-base-private-dev libmbedtls-dev catch2 libfmt-dev liblz4-dev nlohmann-json3-dev libzstd-dev libssl-dev libavfilter-dev libavcodec-dev libswscale-dev pkg-config zlib1g-dev libva-dev libvdpau-dev qt6-tools-dev libzydis-dev zydis-tools libzycore-dev vulkan-utility-libraries-dev libvulkan-dev spirv-tools spirv-headers libusb-1.0-0-dev libxbyak-dev |
|
|
|
sudo apt-get install autoconf cmake g++ gcc git glslang-tools libboost-context-dev libglu1-mesa-dev libhidapi-dev libpulse-dev libtool libudev-dev libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-render-util0 libxcb-xinerama0 libxcb-xkb1 libxext-dev libxkbcommon-x11-0 mesa-common-dev nasm ninja-build qt6-base-private-dev libmbedtls-dev catch2 libfmt-dev liblz4-dev nlohmann-json3-dev libzstd-dev libssl-dev libavfilter-dev libavcodec-dev libswscale-dev pkg-config zlib1g-dev libva-dev libvdpau-dev qt6-tools-dev libzydis-dev zydis-tools libzycore-dev libvulkan-dev spirv-tools spirv-headers libusb-1.0-0-dev libxbyak-dev libboost-dev libboost-fiber-dev libbost-context-dev libsdl2-dev libopus-dev libasound2t64 vulkan-utility-libraries-dev |
|
|
|
``` |
|
|
|
|
|
|
|
* Ubuntu 22.04, Linux Mint 20, or Debian 12 or later is required. |
|
|
|
|
|
|
|
@ -1,6 +1,8 @@ |
|
|
|
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
|
|
|
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
|
|
|
#include <string>
|
|
|
|
#include <string_view>
|
|
|
|
#include <llvm/Demangle/Demangle.h>
|
|
|
|
|
|
|
|
#include "common/demangle.h"
|
|
|
|
@ -9,29 +11,22 @@ |
|
|
|
namespace Common { |
|
|
|
|
|
|
|
std::string DemangleSymbol(const std::string& mangled) { |
|
|
|
auto is_itanium = [](const std::string& name) -> bool { |
|
|
|
// A valid Itanium encoding requires 1-4 leading underscores, followed by 'Z'.
|
|
|
|
auto pos = name.find_first_not_of('_'); |
|
|
|
return pos > 0 && pos <= 4 && pos < name.size() && name[pos] == 'Z'; |
|
|
|
}; |
|
|
|
|
|
|
|
if (mangled.empty()) { |
|
|
|
return mangled; |
|
|
|
} |
|
|
|
|
|
|
|
char* demangled = nullptr; |
|
|
|
SCOPE_EXIT { |
|
|
|
std::free(demangled); |
|
|
|
}; |
|
|
|
|
|
|
|
if (is_itanium(mangled)) { |
|
|
|
demangled = llvm::itaniumDemangle(mangled.c_str()); |
|
|
|
} |
|
|
|
|
|
|
|
if (!demangled) { |
|
|
|
return mangled; |
|
|
|
if (mangled.size() > 0) { |
|
|
|
auto const is_itanium = [](std::string_view name) -> bool { |
|
|
|
// A valid Itanium encoding requires 1-4 leading underscores, followed by 'Z'.
|
|
|
|
auto const pos = name.find_first_not_of('_'); |
|
|
|
return pos > 0 && pos <= 4 && pos < name.size() && name[pos] == 'Z'; |
|
|
|
}; |
|
|
|
std::string ret = mangled; |
|
|
|
if (is_itanium(mangled)) { |
|
|
|
if (char* p = llvm::itaniumDemangle(mangled); p != nullptr) { |
|
|
|
ret = std::string{p}; |
|
|
|
std::free(p); |
|
|
|
} |
|
|
|
} |
|
|
|
return ret; |
|
|
|
} |
|
|
|
return demangled; |
|
|
|
return std::string{}; |
|
|
|
} |
|
|
|
|
|
|
|
} // namespace Common
|
|
|
|
@ -13,10 +13,10 @@ namespace Dynarmic { |
|
|
|
using const_pointer = const value_type*; |
|
|
|
using reference = value_type&; |
|
|
|
using const_reference = const value_type&; |
|
|
|
using iterator = std::deque<value_type>::iterator; |
|
|
|
using const_iterator = std::deque<value_type>::const_iterator; |
|
|
|
using reverse_iterator = std::reverse_iterator<iterator>; |
|
|
|
using const_reverse_iterator = std::reverse_iterator<const_iterator>; |
|
|
|
using iterator = typename std::deque<value_type>::iterator; |
|
|
|
using const_iterator = typename std::deque<value_type>::const_iterator; |
|
|
|
using reverse_iterator = typename std::reverse_iterator<iterator>; |
|
|
|
using const_reverse_iterator = typename std::reverse_iterator<const_iterator>; |
|
|
|
|
|
|
|
inline bool empty() const noexcept { return list.empty(); } |
|
|
|
inline size_type size() const noexcept { return list.size(); } |
|
|
|
|
|
|
|
@ -86,7 +86,7 @@ static void ConstantMemoryReads(IR::Block& block, A32::UserCallbacks* cb) { |
|
|
|
} |
|
|
|
|
|
|
|
static void FlagsPass(IR::Block& block) { |
|
|
|
using Iterator = std::reverse_iterator<IR::Block::iterator>; |
|
|
|
using Iterator = typename std::reverse_iterator<IR::Block::iterator>; |
|
|
|
|
|
|
|
struct FlagInfo { |
|
|
|
bool set_not_required = false; |
|
|
|
|