mirror of
https://github.com/RPCS3/rpcs3.git
synced 2024-11-21 18:22:33 +01:00
Move Log.h to util/logs.hpp
This commit is contained in:
parent
a166d3680e
commit
e4a81b1d13
@ -2,7 +2,7 @@
|
||||
|
||||
#include "Utilities/types.h"
|
||||
#include "Utilities/StrFmt.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "util/atomic.hpp"
|
||||
#include "util/shared_cptr.hpp"
|
||||
|
||||
|
@ -2,7 +2,7 @@
|
||||
#include "JIT.h"
|
||||
#include "StrFmt.h"
|
||||
#include "File.h"
|
||||
#include "Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "mutex.h"
|
||||
#include "sysinfo.h"
|
||||
#include "VirtualMemory.h"
|
||||
|
@ -1,4 +1,4 @@
|
||||
#include "Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "File.h"
|
||||
#include "StrFmt.h"
|
||||
#include "sema.h"
|
||||
@ -279,9 +279,12 @@ void logs::listener::add(logs::listener* _new)
|
||||
std::lock_guard lock(g_mutex);
|
||||
|
||||
// Install new listener at the end of linked list
|
||||
while (lis->m_next || !lis->m_next.compare_and_swap_test(nullptr, _new))
|
||||
listener* null = nullptr;
|
||||
|
||||
while (lis->m_next || !lis->m_next.compare_exchange_strong(null, _new))
|
||||
{
|
||||
lis = lis->m_next;
|
||||
null = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -41,7 +41,7 @@
|
||||
#endif
|
||||
|
||||
#include "sync.h"
|
||||
#include "Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
LOG_CHANNEL(sig_log);
|
||||
LOG_CHANNEL(sys_log, "SYS");
|
||||
|
@ -1,5 +1,5 @@
|
||||
#include "stdafx.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "VirtualMemory.h"
|
||||
#ifdef _WIN32
|
||||
#include <Windows.h>
|
||||
|
@ -1,7 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "Utilities/types.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
#include "Utilities/types.h"
|
||||
#include "Utilities/File.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
LOG_CHANNEL(self_log, "SELF");
|
||||
|
||||
|
@ -2,7 +2,7 @@
|
||||
#error "XAudio2 can only be built on Windows."
|
||||
#endif
|
||||
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "Utilities/StrFmt.h"
|
||||
#include "Emu/System.h"
|
||||
#include "Emu/system_config.h"
|
||||
|
@ -28,7 +28,7 @@
|
||||
#include "Utilities/StrFmt.h"
|
||||
#include "Utilities/BEType.h"
|
||||
#include "Utilities/BitField.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "Utilities/JIT.h"
|
||||
|
||||
#include <unordered_map>
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include "PPUThread.h"
|
||||
#include "PPUInterpreter.h"
|
||||
|
||||
#include "../Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include <algorithm>
|
||||
|
||||
using namespace llvm;
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "stdafx.h"
|
||||
|
||||
#include "GDB.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "Utilities/StrUtil.h"
|
||||
#include "Emu/Memory/vm.h"
|
||||
#include "Emu/System.h"
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
#include "Utilities/hash.h"
|
||||
#include "Utilities/mutex.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "Utilities/span.h"
|
||||
|
||||
#include <deque>
|
||||
|
@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
/**
|
||||
* Ring buffer memory helper :
|
||||
@ -115,7 +115,7 @@ public:
|
||||
{
|
||||
return (m_put_pos > 0) ? m_put_pos - 1 : m_size - 1;
|
||||
}
|
||||
|
||||
|
||||
virtual bool is_critical() const
|
||||
{
|
||||
const size_t guard_length = std::max(m_min_guard_size, m_largest_allocated_pool);
|
||||
|
@ -2,7 +2,7 @@
|
||||
#include "GLHelpers.h"
|
||||
#include "GLTexture.h"
|
||||
#include "GLCompute.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
namespace gl
|
||||
{
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
#include "Emu/system_config.h"
|
||||
#include "Utilities/geometry.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
#define GL_FRAGMENT_TEXTURES_START 0
|
||||
#define GL_VERTEX_TEXTURES_START (GL_FRAGMENT_TEXTURES_START + 16)
|
||||
|
@ -5,7 +5,7 @@
|
||||
|
||||
#include "Emu/Io/pad_config.h"
|
||||
#include "evdev_joystick_handler.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
#include <functional>
|
||||
#include <algorithm>
|
||||
|
@ -459,7 +459,7 @@
|
||||
<ClInclude Include="..\Utilities\mutex.h" />
|
||||
<ClInclude Include="..\Utilities\sema.h" />
|
||||
<ClInclude Include="..\Utilities\sync.h" />
|
||||
<ClInclude Include="..\Utilities\Log.h" />
|
||||
<ClInclude Include="util\logs.hpp" />
|
||||
<ClInclude Include="..\Utilities\File.h" />
|
||||
<ClInclude Include="..\Utilities\Config.h" />
|
||||
<ClInclude Include="..\Utilities\rXml.h" />
|
||||
|
@ -1024,7 +1024,7 @@
|
||||
<ClInclude Include="..\Utilities\Timer.h">
|
||||
<Filter>Utilities</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\Utilities\Log.h">
|
||||
<ClInclude Include="util\logs.hpp">
|
||||
<Filter>Utilities</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="Emu\RSX\Null\NullGSRender.h">
|
||||
|
@ -1,7 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "settings.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
#include <QVariant>
|
||||
#include <QSize>
|
||||
|
@ -1,7 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "Utilities/File.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
#include "custom_dock_widget.h"
|
||||
#include "find_dialog.h"
|
||||
|
@ -7,7 +7,7 @@
|
||||
|
||||
#include "stdafx.h"
|
||||
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
#include "Utilities/StrUtil.h"
|
||||
#include "Emu/VFS.h"
|
||||
#include "Emu/System.h"
|
||||
|
@ -3,7 +3,7 @@
|
||||
#include "Emu/System.h"
|
||||
#include "Utilities/File.h"
|
||||
#include "Utilities/StrFmt.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
LOG_CHANNEL(gui_log, "GUI");
|
||||
|
||||
|
@ -12,7 +12,7 @@
|
||||
|
||||
#include "Utilities/StrUtil.h"
|
||||
#include "Utilities/File.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
#include <QRegExpValidator>
|
||||
#include <QInputDialog>
|
||||
|
@ -25,7 +25,7 @@ namespace std { inline namespace literals { inline namespace chrono_literals {}}
|
||||
#include "util/atomic.hpp"
|
||||
#include "Utilities/StrFmt.h"
|
||||
#include "Utilities/File.h"
|
||||
#include "Utilities/Log.h"
|
||||
#include "util/logs.hpp"
|
||||
|
||||
#include <cstdlib>
|
||||
#include <cstring>
|
||||
|
@ -1,14 +1,18 @@
|
||||
#pragma once
|
||||
|
||||
#include "types.h"
|
||||
#include "StrFmt.h"
|
||||
#include "util/atomic.hpp"
|
||||
#include <cstdint>
|
||||
#include <atomic>
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <initializer_list>
|
||||
#include "Utilities/StrFmt.h"
|
||||
|
||||
namespace logs
|
||||
{
|
||||
enum class level : uint
|
||||
using u64 = std::uint64_t;
|
||||
|
||||
enum class level : unsigned
|
||||
{
|
||||
always, // Highest log severity (unused, cannot be disabled)
|
||||
fatal,
|
||||
@ -46,7 +50,7 @@ namespace logs
|
||||
class listener
|
||||
{
|
||||
// Next listener (linked list)
|
||||
atomic_t<listener*> m_next{};
|
||||
std::atomic<listener*> m_next{};
|
||||
|
||||
friend struct message;
|
||||
|
||||
@ -84,7 +88,7 @@ namespace logs
|
||||
#if __cpp_char8_t >= 201811
|
||||
using char2 = char8_t;
|
||||
#else
|
||||
using char2 = uchar;
|
||||
using char2 = unsigned char;
|
||||
#endif
|
||||
|
||||
#define GEN_LOG_METHOD(_sev)\
|
Loading…
Reference in New Issue
Block a user