Clean up cvars (rename, recategorize).

This commit is contained in:
gibbed 2019-08-03 22:53:58 -05:00
parent 9d924950cc
commit b2f62b1982
10 changed files with 21 additions and 21 deletions

View File

@ -43,19 +43,19 @@
#include "third_party/xbyak/xbyak/xbyak_util.h" #include "third_party/xbyak/xbyak/xbyak_util.h"
DEFINE_string(apu, "any", "Audio system. Use: [any, nop, xaudio2]", "General"); DEFINE_string(apu, "any", "Audio system. Use: [any, nop, xaudio2]", "APU");
DEFINE_string(gpu, "any", "Graphics system. Use: [any, d3d12, vulkan, null]", DEFINE_string(gpu, "any", "Graphics system. Use: [any, d3d12, vulkan, null]",
"General"); "GPU");
DEFINE_string(hid, "any", "Input system. Use: [any, nop, winkey, xinput]", DEFINE_string(hid, "any", "Input system. Use: [any, nop, winkey, xinput]",
"General"); "HID");
DEFINE_bool(fullscreen, false, "Toggles fullscreen", "General"); DEFINE_bool(fullscreen, false, "Toggles fullscreen", "GPU");
DEFINE_string(content_root, "", "Root path for content (save/etc) storage.", DEFINE_string(content_root, "", "Root path for content (save/etc) storage.",
"General"); "Storage");
DEFINE_bool(mount_scratch, false, "Enable scratch mount", "General"); DEFINE_bool(mount_scratch, false, "Enable scratch mount", "Storage");
DEFINE_bool(mount_cache, false, "Enable cache mount", "General"); DEFINE_bool(mount_cache, false, "Enable cache mount", "Storage");
CmdVar(target, "", "Specifies the target .xex or .iso to execute."); CmdVar(target, "", "Specifies the target .xex or .iso to execute.");
DECLARE_bool(debug); DECLARE_bool(debug);

View File

@ -9,4 +9,4 @@
#include "xenia/apu/apu_flags.h" #include "xenia/apu/apu_flags.h"
DEFINE_bool(mute, false, "Mutes all audio output.", "Audio") DEFINE_bool(mute, false, "Mutes all audio output.", "APU")

View File

@ -49,7 +49,7 @@ extern "C" {
// using the XMA* functions. // using the XMA* functions.
DEFINE_bool(libav_verbose, false, "Verbose libav output (debug and above)", DEFINE_bool(libav_verbose, false, "Verbose libav output (debug and above)",
"Audio"); "APU");
namespace xe { namespace xe {
namespace apu { namespace apu {

View File

@ -37,7 +37,7 @@ DEFINE_string(
log_file, "", log_file, "",
"Logs are written to the given file (specify stdout for command line)", "Logs are written to the given file (specify stdout for command line)",
"Logging"); "Logging");
DEFINE_bool(log_debugprint, false, "Dump the log to DebugPrint.", "Logging"); DEFINE_bool(log_to_debugprint, false, "Dump the log to DebugPrint.", "Logging");
DEFINE_bool(flush_log, true, "Flush log file after each log line batch.", DEFINE_bool(flush_log, true, "Flush log file after each log line batch.",
"Logging"); "Logging");
DEFINE_int32( DEFINE_int32(
@ -151,7 +151,7 @@ class Logger {
fwrite(buf, 1, size, file_); fwrite(buf, 1, size, file_);
} }
if (cvars::log_debugprint) { if (cvars::log_to_debugprint) {
debugging::DebugPrint("%.*s", size, buf); debugging::DebugPrint("%.*s", size, buf);
} }
} }

View File

@ -41,7 +41,7 @@
#include "xenia/ui/microprofile_drawer.h" #include "xenia/ui/microprofile_drawer.h"
#endif // XE_OPTION_PROFILING_UI #endif // XE_OPTION_PROFILING_UI
DEFINE_bool(show_profiler, false, "Show profiling UI by default.", "Other"); DEFINE_bool(show_profiler, false, "Show profiling UI by default.", "UI");
namespace xe { namespace xe {

View File

@ -27,8 +27,8 @@
#include "xenia/cpu/stack_walker.h" #include "xenia/cpu/stack_walker.h"
DEFINE_bool( DEFINE_bool(
enable_haswell_instructions, true, use_haswell_instructions, true,
"Uses the AVX2/FMA/etc instructions on Haswell processors, if available.", "Uses the AVX2/FMA/etc instructions on Haswell processors when available.",
"CPU"); "CPU");
namespace xe { namespace xe {
@ -84,7 +84,7 @@ bool X64Backend::Initialize(Processor* processor) {
} }
// Need movbe to do advanced LOAD/STORE tricks. // Need movbe to do advanced LOAD/STORE tricks.
if (cvars::enable_haswell_instructions) { if (cvars::use_haswell_instructions) {
machine_info_.supports_extended_load_store = machine_info_.supports_extended_load_store =
cpu.has(Xbyak::util::Cpu::tMOVBE); cpu.has(Xbyak::util::Cpu::tMOVBE);
} else { } else {

View File

@ -15,7 +15,7 @@
#include "xenia/base/cvar.h" #include "xenia/base/cvar.h"
#include "xenia/cpu/backend/backend.h" #include "xenia/cpu/backend/backend.h"
DECLARE_bool(enable_haswell_instructions); DECLARE_bool(use_haswell_instructions);
namespace xe { namespace xe {
class Exception; class Exception;

View File

@ -33,7 +33,7 @@
#include "xenia/cpu/symbol.h" #include "xenia/cpu/symbol.h"
#include "xenia/cpu/thread_state.h" #include "xenia/cpu/thread_state.h"
DEFINE_bool(enable_debugprint_log, false, DEFINE_bool(debugprint_trap_log, false,
"Log debugprint traps to the active debugger", "CPU"); "Log debugprint traps to the active debugger", "CPU");
DEFINE_bool(ignore_undefined_externs, true, DEFINE_bool(ignore_undefined_externs, true,
"Don't exit when an undefined extern is called.", "CPU"); "Don't exit when an undefined extern is called.", "CPU");
@ -70,7 +70,7 @@ X64Emitter::X64Emitter(X64Backend* backend, XbyakAllocator* allocator)
backend_(backend), backend_(backend),
code_cache_(backend->code_cache()), code_cache_(backend->code_cache()),
allocator_(allocator) { allocator_(allocator) {
if (cvars::enable_haswell_instructions) { if (cvars::use_haswell_instructions) {
feature_flags_ |= cpu_.has(Xbyak::util::Cpu::tAVX2) ? kX64EmitAVX2 : 0; feature_flags_ |= cpu_.has(Xbyak::util::Cpu::tAVX2) ? kX64EmitAVX2 : 0;
feature_flags_ |= cpu_.has(Xbyak::util::Cpu::tFMA) ? kX64EmitFMA : 0; feature_flags_ |= cpu_.has(Xbyak::util::Cpu::tFMA) ? kX64EmitFMA : 0;
feature_flags_ |= cpu_.has(Xbyak::util::Cpu::tLZCNT) ? kX64EmitLZCNT : 0; feature_flags_ |= cpu_.has(Xbyak::util::Cpu::tLZCNT) ? kX64EmitLZCNT : 0;
@ -298,7 +298,7 @@ uint64_t TrapDebugPrint(void* raw_context, uint64_t address) {
// TODO(benvanik): truncate to length? // TODO(benvanik): truncate to length?
XELOGD("(DebugPrint) %s", str); XELOGD("(DebugPrint) %s", str);
if (cvars::enable_debugprint_log) { if (cvars::debugprint_trap_log) {
debugging::DebugPrint("(DebugPrint) %s", str); debugging::DebugPrint("(DebugPrint) %s", str);
} }

View File

@ -33,7 +33,7 @@
#include "xenia/ui/graphics_provider.h" #include "xenia/ui/graphics_provider.h"
#include "xenia/ui/imgui_drawer.h" #include "xenia/ui/imgui_drawer.h"
DEFINE_bool(imgui_debug, false, "Show ImGui debugging tools.", "Other"); DEFINE_bool(imgui_debug, false, "Show ImGui debugging tools.", "UI");
namespace xe { namespace xe {
namespace debug { namespace debug {

View File

@ -11,6 +11,6 @@
DEFINE_bool(headless, false, DEFINE_bool(headless, false,
"Don't display any UI, using defaults for prompts as needed.", "Don't display any UI, using defaults for prompts as needed.",
"Other"); "UI");
DEFINE_bool(log_high_frequency_kernel_calls, false, DEFINE_bool(log_high_frequency_kernel_calls, false,
"Log kernel calls with the kHighFrequency tag.", "Kernel"); "Log kernel calls with the kHighFrequency tag.", "Kernel");