Make perf.log output for ticking things opt-in
Both writing to perf.log frequently as well as GetTimestamp aren't free and hurt performance particularly on slower systems (which can have notably higher output to perf.log, further amplifying the problem). Therefore we make simulation perf logging opt-in. Additionally, logging of the current tick and tick type (local/net) is removed from debug.log, and some remnant debug logging for kills and pips is removed to keep performance-sensitive logging limited to perf.log.
This commit is contained in:
@@ -53,6 +53,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
SettingsUtils.BindCheckboxPref(panel, "REPLAY_COMMANDS_CHECKBOX", ds, "EnableDebugCommandsInReplays");
|
||||
SettingsUtils.BindCheckboxPref(panel, "CHECKUNSYNCED_CHECKBOX", ds, "SyncCheckUnsyncedCode");
|
||||
SettingsUtils.BindCheckboxPref(panel, "CHECKBOTSYNC_CHECKBOX", ds, "SyncCheckBotModuleCode");
|
||||
SettingsUtils.BindCheckboxPref(panel, "PERFLOGGING_CHECKBOX", ds, "EnableSimulationPerfLogging");
|
||||
|
||||
panel.Get("DEBUG_OPTIONS").IsVisible = () => ds.DisplayDeveloperSettings;
|
||||
panel.Get("DEBUG_HIDDEN_LABEL").IsVisible = () => !ds.DisplayDeveloperSettings;
|
||||
@@ -79,6 +80,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
ds.SendSystemInformation = dds.SendSystemInformation;
|
||||
ds.CheckVersion = dds.CheckVersion;
|
||||
ds.EnableDebugCommandsInReplays = dds.EnableDebugCommandsInReplays;
|
||||
ds.EnableSimulationPerfLogging = dds.EnableSimulationPerfLogging;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user