Format all code with new clang-format
This commit is contained in:
@@ -213,9 +213,8 @@ std::vector<object_ref<XObject>> ObjectTable::GetAllObjects() {
|
||||
|
||||
for (uint32_t slot = 0; slot < table_capacity_; slot++) {
|
||||
auto& entry = table_[slot];
|
||||
if (entry.object &&
|
||||
std::find(results.begin(), results.end(), entry.object) ==
|
||||
results.end()) {
|
||||
if (entry.object && std::find(results.begin(), results.end(),
|
||||
entry.object) == results.end()) {
|
||||
entry.object->Retain();
|
||||
results.push_back(object_ref<XObject>(entry.object));
|
||||
}
|
||||
|
||||
@@ -474,7 +474,9 @@ xe::cpu::Export* RegisterExport(R (*fn)(Ps&...), const char* name,
|
||||
static void Trampoline(PPCContext* ppc_context) {
|
||||
++export_entry->function_data.call_count;
|
||||
Param::Init init = {
|
||||
ppc_context, sizeof...(Ps), 0,
|
||||
ppc_context,
|
||||
sizeof...(Ps),
|
||||
0,
|
||||
};
|
||||
auto params = std::make_tuple<Ps...>(Ps(init)...);
|
||||
if (export_entry->tags & xe::cpu::ExportTag::kLog &&
|
||||
@@ -507,7 +509,8 @@ xe::cpu::Export* RegisterExport(void (*fn)(Ps&...), const char* name,
|
||||
static void Trampoline(PPCContext* ppc_context) {
|
||||
++export_entry->function_data.call_count;
|
||||
Param::Init init = {
|
||||
ppc_context, sizeof...(Ps),
|
||||
ppc_context,
|
||||
sizeof...(Ps),
|
||||
};
|
||||
auto params = std::make_tuple<Ps...>(Ps(init)...);
|
||||
if (export_entry->tags & xe::cpu::ExportTag::kLog &&
|
||||
|
||||
@@ -15,7 +15,9 @@
|
||||
|
||||
namespace xe {} // namespace xe
|
||||
|
||||
typedef struct { int reserved; } xe_xex2_options_t;
|
||||
typedef struct {
|
||||
int reserved;
|
||||
} xe_xex2_options_t;
|
||||
|
||||
struct xe_xex2;
|
||||
typedef struct xe_xex2* xe_xex2_ref;
|
||||
|
||||
@@ -24,7 +24,7 @@ dword_result_t XamAvatarInitialize(
|
||||
lpdword_t function_ptrs, // 20b, 5 pointers
|
||||
lpunknown_t unk5, // ptr in data segment
|
||||
dword_t unk6 // flags - 0x00300000, 0x30, etc
|
||||
) {
|
||||
) {
|
||||
// Negative to fail. Game should immediately call XamAvatarShutdown.
|
||||
return ~0u;
|
||||
}
|
||||
|
||||
@@ -47,6 +47,6 @@ DECLARE_XBDM_EXPORT(DmFindPdbSignature, ExportTag::kStub | ExportTag::kDebug);
|
||||
void RegisterMiscExports(xe::cpu::ExportResolver* export_resolver,
|
||||
KernelState* kernel_state) {}
|
||||
|
||||
} // namespace xboxkrnl
|
||||
} // namespace xbdm
|
||||
} // namespace kernel
|
||||
} // namespace xe
|
||||
|
||||
@@ -7,13 +7,13 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/apu/audio_system.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/emulator.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
#include "xenia/kernel/xboxkrnl/xboxkrnl_private.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -7,11 +7,11 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
#include "xenia/kernel/xboxkrnl/xboxkrnl_private.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
#include "third_party/crypto/TinySHA1.hpp"
|
||||
#include "third_party/crypto/des/des.cpp"
|
||||
|
||||
@@ -7,13 +7,13 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/debugging.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
#include "xenia/kernel/xboxkrnl/xboxkrnl_private.h"
|
||||
#include "xenia/kernel/xthread.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -7,11 +7,11 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
#include "xenia/kernel/xboxkrnl/xboxkrnl_private.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/base/memory.h"
|
||||
#include "xenia/cpu/processor.h"
|
||||
@@ -19,6 +18,7 @@
|
||||
#include "xenia/kernel/xiocompletion.h"
|
||||
#include "xenia/kernel/xthread.h"
|
||||
#include "xenia/vfs/device.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -7,12 +7,12 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
#include "xenia/kernel/xboxkrnl/xboxkrnl_private.h"
|
||||
#include "xenia/kernel/xthread.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/cpu/processor.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
@@ -15,6 +14,7 @@
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
#include "xenia/kernel/util/xex2.h"
|
||||
#include "xenia/kernel/xboxkrnl/xboxkrnl_private.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
@@ -15,6 +14,7 @@
|
||||
#include "xenia/kernel/xobject.h"
|
||||
#include "xenia/kernel/xsemaphore.h"
|
||||
#include "xenia/kernel/xthread.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -559,13 +559,12 @@ int32_t format_core(PPCContext* ppc_context, FormatData& data, ArgList& args,
|
||||
|
||||
if (!is_wide) {
|
||||
length = 0;
|
||||
for (auto s = (const uint8_t *)str; cap > 0 && *s; ++s, cap--) {
|
||||
for (auto s = (const uint8_t*)str; cap > 0 && *s; ++s, cap--) {
|
||||
length++;
|
||||
}
|
||||
} else {
|
||||
length = 0;
|
||||
for (auto s = (const uint16_t *)str; cap > 0 && *s;
|
||||
++s, cap--) {
|
||||
for (auto s = (const uint16_t*)str; cap > 0 && *s; ++s, cap--) {
|
||||
length++;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,11 +7,11 @@
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#include "xenia/xbox.h"
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/kernel/kernel_state.h"
|
||||
#include "xenia/kernel/util/shim_utils.h"
|
||||
#include "xenia/kernel/xboxkrnl/xboxkrnl_private.h"
|
||||
#include "xenia/xbox.h"
|
||||
|
||||
namespace xe {
|
||||
namespace kernel {
|
||||
|
||||
@@ -257,7 +257,7 @@ dword_result_t VdInitializeScalerCommandBuffer(
|
||||
lpvoid_t dest_ptr, // Points to the first 80000000h where the memcpy
|
||||
// sources from.
|
||||
dword_t dest_count // Count in words.
|
||||
) {
|
||||
) {
|
||||
// We could fake the commands here, but I'm not sure the game checks for
|
||||
// anything but success (non-zero ret).
|
||||
// For now, we just fill it with NOPs.
|
||||
|
||||
Reference in New Issue
Block a user