diff --git a/Utilities/Config.cpp b/Utilities/Config.cpp index f242bd6172..3abb14582c 100644 --- a/Utilities/Config.cpp +++ b/Utilities/Config.cpp @@ -253,10 +253,6 @@ bool try_to_float(f64* out, std::string_view value, f64 min, f64 max, std::strin bool try_to_string(std::string* out, f64 value, std::string_view name) { -#ifdef __APPLE__ - if (out) *out = std::to_string(value); - return true; -#else std::array str{}; if (auto [ptr, ec] = std::to_chars(str.data(), str.data() + str.size(), value, std::chars_format::fixed); ec == std::errc()) @@ -269,7 +265,6 @@ bool try_to_string(std::string* out, f64 value, std::string_view name) if (out) cfg_log.error("cfg::try_to_string('%s'): could not convert value '%f' to string. error='%s'", name, value, std::make_error_code(ec).message()); return false; } -#endif } bool cfg::try_to_enum_value(u64* out, decltype(&fmt_class_string::format) func, std::string_view value, std::string_view name) diff --git a/Utilities/File.cpp b/Utilities/File.cpp index 59ef528942..da29fba7bd 100644 --- a/Utilities/File.cpp +++ b/Utilities/File.cpp @@ -1112,15 +1112,13 @@ bool fs::is_symlink(const std::string& path) return true; } -bool fs::is_optical_raw_device(const std::string& path) +bool fs::is_optical_raw_device([[maybe_unused]] const std::string& path) { #ifdef _WIN32 if (path.starts_with("\\\\.\\")) { return true; } - - return false; #endif return false; } diff --git a/Utilities/sync.h b/Utilities/sync.h index 513a45ee51..e0b8c39cc5 100644 --- a/Utilities/sync.h +++ b/Utilities/sync.h @@ -74,7 +74,7 @@ enum }; #endif -inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* timeout = nullptr, uint mask = 0) +inline int futex(volatile void* uaddr, int futex_op, uint val, const timespec* timeout = nullptr, [[maybe_unused]] uint mask = 0) { #ifdef __linux__ return syscall(SYS_futex, uaddr, futex_op, static_cast(val), timeout, nullptr, static_cast(mask)); diff --git a/rpcs3/Emu/Cell/SPUCommonRecompiler.cpp b/rpcs3/Emu/Cell/SPUCommonRecompiler.cpp index 7c21ad7aab..8b4bd15e26 100644 --- a/rpcs3/Emu/Cell/SPUCommonRecompiler.cpp +++ b/rpcs3/Emu/Cell/SPUCommonRecompiler.cpp @@ -6625,7 +6625,7 @@ spu_program spu_recompiler_base::analyse(const be_t* ls, u32 entry_point, s bool found_loop_dictator = false; bool found_loop_argument_for_dictator = false; - u32 null_regs_found = 0; + //u32 null_regs_found = 0; for (u32 i = 0; i < reg->regs.size() && reduced_loop->active; i++) { @@ -6730,7 +6730,7 @@ spu_program spu_recompiler_base::analyse(const be_t* ls, u32 entry_point, s // break; // } - null_regs_found++; + //null_regs_found++; continue; } diff --git a/rpcs3/Emu/Cell/lv2/sys_fs.cpp b/rpcs3/Emu/Cell/lv2/sys_fs.cpp index 92e2011dc6..a34c0c301c 100644 --- a/rpcs3/Emu/Cell/lv2/sys_fs.cpp +++ b/rpcs3/Emu/Cell/lv2/sys_fs.cpp @@ -1101,7 +1101,7 @@ lv2_file::open_raw_result_t lv2_file::open_raw(const std::string& local_path, s3 return {.error = {}, .file = std::move(file)}; } -lv2_file::open_result_t lv2_file::open(std::string_view vpath, s32 flags, s32 mode, const void* arg, u64 size) +lv2_file::open_result_t lv2_file::open(std::string_view vpath, s32 flags, s32 /*mode*/, const void* arg, u64 size) { if (vpath.empty()) { diff --git a/rpcs3/Emu/RSX/Overlays/overlay_controls.cpp b/rpcs3/Emu/RSX/Overlays/overlay_controls.cpp index 5208efd747..21cdd69939 100644 --- a/rpcs3/Emu/RSX/Overlays/overlay_controls.cpp +++ b/rpcs3/Emu/RSX/Overlays/overlay_controls.cpp @@ -26,7 +26,7 @@ namespace rsx { namespace overlays { - static std::vector generate_unit_quadrant(int num_patch_points, const float offset[2], const float scale[2]) + [[maybe_unused]] static std::vector generate_unit_quadrant(int num_patch_points, const float offset[2], const float scale[2]) { ensure(num_patch_points >= 3); std::vector result(num_patch_points + 1); diff --git a/rpcs3/Emu/RSX/Program/CgBinaryProgram.cpp b/rpcs3/Emu/RSX/Program/CgBinaryProgram.cpp index d9c090addb..c565d21bda 100644 --- a/rpcs3/Emu/RSX/Program/CgBinaryProgram.cpp +++ b/rpcs3/Emu/RSX/Program/CgBinaryProgram.cpp @@ -170,7 +170,6 @@ void CgBinaryDisasm::BuildShaderBody(bool include_glsl) return; } - u32 unused; std::vector be_data; // Swap bytes. FP decompiler expects input in BE @@ -190,6 +189,7 @@ void CgBinaryDisasm::BuildShaderBody(bool include_glsl) rsx_prog.data = reinterpret_cast(be_data.data()) + metadata.program_start_offset; for (u32 i = 0; i < 16; ++i) rsx_prog.texture_state.set_dimension(rsx::texture_dimension_extended::texture_dimension_2d, i); #ifndef WITHOUT_OPENGL + u32 unused = 0; GLFragmentDecompilerThread(m_glsl_shader, param_array, rsx_prog, unused).Task(); #endif } diff --git a/rpcs3/Input/mm_joystick_handler.cpp b/rpcs3/Input/mm_joystick_handler.cpp index 0769d9db4d..710488a4f4 100644 --- a/rpcs3/Input/mm_joystick_handler.cpp +++ b/rpcs3/Input/mm_joystick_handler.cpp @@ -228,7 +228,6 @@ pad_preview_values mm_joystick_handler::get_preview_values(const std::unordered_ const auto get_key_value = [this, &data](const std::string& str) -> u16 { - bool pressed{}; u16 value{}; // The DS3 Button is considered pressed if any configured button combination is pressed @@ -256,7 +255,6 @@ pad_preview_values mm_joystick_handler::get_preview_values(const std::unordered_ if (combo_pressed) { value = std::max(value, combo_val); - pressed = value > 0; } } diff --git a/rpcs3/Loader/ISO.cpp b/rpcs3/Loader/ISO.cpp index 585e7d279c..175e2fde1d 100644 --- a/rpcs3/Loader/ISO.cpp +++ b/rpcs3/Loader/ISO.cpp @@ -266,9 +266,10 @@ iso_type_status iso_file_decryption::retrieve_key(iso_archive& archive, std::str for (const auto& magic : dec_magics) { - if (node = archive.retrieve(magic.first)) + if (iso_fs_node* _node = archive.retrieve(magic.first)) { magic_value = magic.second; + node = _node; break; } } diff --git a/rpcs3/Loader/iso_validation.cpp b/rpcs3/Loader/iso_validation.cpp index 2309fc43ae..31a82beaa7 100644 --- a/rpcs3/Loader/iso_validation.cpp +++ b/rpcs3/Loader/iso_validation.cpp @@ -11,7 +11,7 @@ LOG_CHANNEL(iso_log, "ISO"); -iso_integrity_status iso_file_validation::check_integrity(const std::string& path, const std::string& hash, std::string* game_name) +iso_integrity_status iso_file_validation::check_integrity(const std::string& hash, std::string* game_name) { // // Check for Redump db diff --git a/rpcs3/Loader/iso_validation.h b/rpcs3/Loader/iso_validation.h index f8a8d6948f..56ac659ce8 100644 --- a/rpcs3/Loader/iso_validation.h +++ b/rpcs3/Loader/iso_validation.h @@ -29,7 +29,7 @@ private: iso_hash_status m_status = iso_hash_status::INITIALIZED; public: - static iso_integrity_status check_integrity(const std::string& path, const std::string& hash, std::string* game_name = nullptr); + static iso_integrity_status check_integrity(const std::string& hash, std::string* game_name = nullptr); const std::string& get_path() const { return m_path; } u64 get_size() const { return m_size; } diff --git a/rpcs3/rpcs3qt/game_list_actions.cpp b/rpcs3/rpcs3qt/game_list_actions.cpp index a199c20e66..13e9d8d29d 100644 --- a/rpcs3/rpcs3qt/game_list_actions.cpp +++ b/rpcs3/rpcs3qt/game_list_actions.cpp @@ -393,7 +393,7 @@ void game_list_actions::ShowGameIntegrityDialog(const game_info& game) { text = "Integrity check completed!\n\n"; - switch (m_iso_validator->check_integrity(m_iso_validator->get_path(), hash, &game_name)) + switch (m_iso_validator->check_integrity(hash, &game_name)) { case iso_integrity_status::NO_MATCH: text += tr("Game check NOT PASSED\n\nNo match found on DB or game corrupted:\n - Hash: %0") diff --git a/rpcs3/rpcs3qt/game_list_context_menu.cpp b/rpcs3/rpcs3qt/game_list_context_menu.cpp index 849aa6c966..eb56a76ab1 100644 --- a/rpcs3/rpcs3qt/game_list_context_menu.cpp +++ b/rpcs3/rpcs3qt/game_list_context_menu.cpp @@ -613,7 +613,7 @@ void game_list_context_menu::show_single_selection_context_menu(const game_info& // That is to highlight a Redump ISO from a non Redump ISO if (iso_type != iso_type_status::NOT_ISO) { - const iso_integrity_status iso_integrity = iso_file_validation::check_integrity(current_game.path, ""); + const iso_integrity_status iso_integrity = iso_file_validation::check_integrity(""); QAction* check_integrity = addAction(tr("&Check ISO Integrity")); diff --git a/rpcs3/rpcs3qt/recording_settings_dialog.cpp b/rpcs3/rpcs3qt/recording_settings_dialog.cpp index befd14713a..cb16c06ff5 100644 --- a/rpcs3/rpcs3qt/recording_settings_dialog.cpp +++ b/rpcs3/rpcs3qt/recording_settings_dialog.cpp @@ -31,9 +31,6 @@ static std::vector get_video_codecs(const AVOutputFormat* fmt) void* opaque = nullptr; while (const AVCodec* codec = av_codec_iterate(&opaque)) { - if (!codec->pix_fmts) - continue; - if (codec->capabilities & AV_CODEC_CAP_EXPERIMENTAL) continue;