Cleaning up some line ending issues.

This commit is contained in:
Ben Vanik 2015-02-06 09:03:47 -08:00
parent 22c72544ad
commit 29719b8f4d
13 changed files with 276 additions and 276 deletions

0
private/runtest.sh Executable file → Normal file
View File

0
src/alloy/frontend/ppc/test/update.sh Executable file → Normal file
View File

View File

@ -1,22 +1,22 @@
/** /**
****************************************************************************** ******************************************************************************
* Xenia : Xbox 360 Emulator Research Project * * Xenia : Xbox 360 Emulator Research Project *
****************************************************************************** ******************************************************************************
* Copyright 2013 Ben Vanik. All rights reserved. * * Copyright 2013 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. * * Released under the BSD license - see LICENSE in the root for more details. *
****************************************************************************** ******************************************************************************
*/ */
#ifndef XENIA_GPU_PRIVATE_H_ #ifndef XENIA_GPU_PRIVATE_H_
#define XENIA_GPU_PRIVATE_H_ #define XENIA_GPU_PRIVATE_H_
#include <gflags/gflags.h> #include <gflags/gflags.h>
DECLARE_string(gpu); DECLARE_string(gpu);
DECLARE_bool(trace_ring_buffer); DECLARE_bool(trace_ring_buffer);
DECLARE_string(dump_shaders); DECLARE_string(dump_shaders);
DECLARE_bool(vsync); DECLARE_bool(vsync);
#endif // XENIA_GPU_PRIVATE_H_ #endif // XENIA_GPU_PRIVATE_H_

View File

@ -1,63 +1,63 @@
/** /**
****************************************************************************** ******************************************************************************
* Xenia : Xbox 360 Emulator Research Project * * Xenia : Xbox 360 Emulator Research Project *
****************************************************************************** ******************************************************************************
* Copyright 2013 Ben Vanik. All rights reserved. * * Copyright 2013 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. * * Released under the BSD license - see LICENSE in the root for more details. *
****************************************************************************** ******************************************************************************
*/ */
#include "xenia/gpu/graphics_system.h" #include "xenia/gpu/graphics_system.h"
#include "poly/poly.h" #include "poly/poly.h"
#include "xenia/emulator.h" #include "xenia/emulator.h"
#include "xenia/cpu/processor.h" #include "xenia/cpu/processor.h"
#include "xenia/gpu/gpu-private.h" #include "xenia/gpu/gpu-private.h"
namespace xe { namespace xe {
namespace gpu { namespace gpu {
GraphicsSystem::GraphicsSystem(Emulator* emulator) GraphicsSystem::GraphicsSystem(Emulator* emulator)
: emulator_(emulator), : emulator_(emulator),
memory_(emulator->memory()), memory_(emulator->memory()),
interrupt_callback_(0), interrupt_callback_(0),
interrupt_callback_data_(0) {} interrupt_callback_data_(0) {}
GraphicsSystem::~GraphicsSystem() {} GraphicsSystem::~GraphicsSystem() {}
X_STATUS GraphicsSystem::Setup() { X_STATUS GraphicsSystem::Setup() {
processor_ = emulator_->processor(); processor_ = emulator_->processor();
return X_STATUS_SUCCESS; return X_STATUS_SUCCESS;
} }
void GraphicsSystem::Shutdown() {} void GraphicsSystem::Shutdown() {}
void GraphicsSystem::SetInterruptCallback(uint32_t callback, void GraphicsSystem::SetInterruptCallback(uint32_t callback,
uint32_t user_data) { uint32_t user_data) {
interrupt_callback_ = callback; interrupt_callback_ = callback;
interrupt_callback_data_ = user_data; interrupt_callback_data_ = user_data;
XELOGGPU("SetInterruptCallback(%.4X, %.4X)", callback, user_data); XELOGGPU("SetInterruptCallback(%.4X, %.4X)", callback, user_data);
} }
void GraphicsSystem::DispatchInterruptCallback(uint32_t source, uint32_t cpu) { void GraphicsSystem::DispatchInterruptCallback(uint32_t source, uint32_t cpu) {
if (!interrupt_callback_) { if (!interrupt_callback_) {
return; return;
} }
// Pick a CPU, if needed. We're going to guess 2. Because. // Pick a CPU, if needed. We're going to guess 2. Because.
if (cpu == 0xFFFFFFFF) { if (cpu == 0xFFFFFFFF) {
cpu = 2; cpu = 2;
} }
XELOGGPU("Dispatching GPU interrupt at %.8X w/ mode %d on cpu %d", XELOGGPU("Dispatching GPU interrupt at %.8X w/ mode %d on cpu %d",
interrupt_callback_, source, cpu); interrupt_callback_, source, cpu);
// NOTE: we may be executing in some random thread. // NOTE: we may be executing in some random thread.
uint64_t args[] = {source, interrupt_callback_data_}; uint64_t args[] = {source, interrupt_callback_data_};
processor_->ExecuteInterrupt(cpu, interrupt_callback_, args, processor_->ExecuteInterrupt(cpu, interrupt_callback_, args,
poly::countof(args)); poly::countof(args));
} }
} // namespace gpu } // namespace gpu
} // namespace xe } // namespace xe

View File

@ -1,54 +1,54 @@
/** /**
****************************************************************************** ******************************************************************************
* Xenia : Xbox 360 Emulator Research Project * * Xenia : Xbox 360 Emulator Research Project *
****************************************************************************** ******************************************************************************
* Copyright 2013 Ben Vanik. All rights reserved. * * Copyright 2013 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. * * Released under the BSD license - see LICENSE in the root for more details. *
****************************************************************************** ******************************************************************************
*/ */
#ifndef XENIA_GPU_GRAPHICS_SYSTEM_H_ #ifndef XENIA_GPU_GRAPHICS_SYSTEM_H_
#define XENIA_GPU_GRAPHICS_SYSTEM_H_ #define XENIA_GPU_GRAPHICS_SYSTEM_H_
#include <atomic> #include <atomic>
#include <thread> #include <thread>
#include "xenia/common.h" #include "xenia/common.h"
#include "xenia/emulator.h" #include "xenia/emulator.h"
#include "xenia/xbox.h" #include "xenia/xbox.h"
namespace xe { namespace xe {
namespace gpu { namespace gpu {
class GraphicsSystem { class GraphicsSystem {
public: public:
virtual ~GraphicsSystem(); virtual ~GraphicsSystem();
Emulator* emulator() const { return emulator_; } Emulator* emulator() const { return emulator_; }
Memory* memory() const { return memory_; } Memory* memory() const { return memory_; }
cpu::Processor* processor() const { return processor_; } cpu::Processor* processor() const { return processor_; }
virtual X_STATUS Setup(); virtual X_STATUS Setup();
virtual void Shutdown(); virtual void Shutdown();
void SetInterruptCallback(uint32_t callback, uint32_t user_data); void SetInterruptCallback(uint32_t callback, uint32_t user_data);
virtual void InitializeRingBuffer(uint32_t ptr, uint32_t page_count) = 0; virtual void InitializeRingBuffer(uint32_t ptr, uint32_t page_count) = 0;
virtual void EnableReadPointerWriteBack(uint32_t ptr, uint32_t block_size) = 0; virtual void EnableReadPointerWriteBack(uint32_t ptr, uint32_t block_size) = 0;
void DispatchInterruptCallback(uint32_t source, uint32_t cpu); void DispatchInterruptCallback(uint32_t source, uint32_t cpu);
protected: protected:
GraphicsSystem(Emulator* emulator); GraphicsSystem(Emulator* emulator);
Emulator* emulator_; Emulator* emulator_;
Memory* memory_; Memory* memory_;
cpu::Processor* processor_; cpu::Processor* processor_;
uint32_t interrupt_callback_; uint32_t interrupt_callback_;
uint32_t interrupt_callback_data_; uint32_t interrupt_callback_data_;
}; };
} // namespace gpu } // namespace gpu
} // namespace xe } // namespace xe
#endif // XENIA_GPU_GRAPHICS_SYSTEM_H_ #endif // XENIA_GPU_GRAPHICS_SYSTEM_H_

View File

@ -1,14 +1,14 @@
/** /**
****************************************************************************** ******************************************************************************
* Xenia : Xbox 360 Emulator Research Project * * Xenia : Xbox 360 Emulator Research Project *
****************************************************************************** ******************************************************************************
* Copyright 2013 Ben Vanik. All rights reserved. * * Copyright 2013 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. * * Released under the BSD license - see LICENSE in the root for more details. *
****************************************************************************** ******************************************************************************
*/ */
// Post-include file for an export table. // Post-include file for an export table.
#undef FLAG #undef FLAG
#undef XE_EXPORT #undef XE_EXPORT

View File

@ -1,34 +1,34 @@
/** /**
****************************************************************************** ******************************************************************************
* Xenia : Xbox 360 Emulator Research Project * * Xenia : Xbox 360 Emulator Research Project *
****************************************************************************** ******************************************************************************
* Copyright 2013 Ben Vanik. All rights reserved. * * Copyright 2013 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. * * Released under the BSD license - see LICENSE in the root for more details. *
****************************************************************************** ******************************************************************************
*/ */
/** /**
* Pre-include file for an export table. * Pre-include file for an export table.
* Use this to build tables of exports: * Use this to build tables of exports:
* *
* // Build the export table used for resolution. * // Build the export table used for resolution.
* #include "xenia/kernel/util/export_table_pre.inc" * #include "xenia/kernel/util/export_table_pre.inc"
* static KernelExport my_module_export_table[] = { * static KernelExport my_module_export_table[] = {
* #include "xenia/kernel/my_module/my_module_table.inc" * #include "xenia/kernel/my_module/my_module_table.inc"
* }; * };
* #include "xenia/kernel/util/export_table_post.inc" * #include "xenia/kernel/util/export_table_post.inc"
* export_resolver_->RegisterTable( * export_resolver_->RegisterTable(
* "my_module.xex", * "my_module.xex",
* my_module_export_table, poly::countof(my_module_export_table)); * my_module_export_table, poly::countof(my_module_export_table));
*/ */
#define XE_EXPORT(module, ordinal, name, type, flags) \ #define XE_EXPORT(module, ordinal, name, type, flags) \
{ \ { \
ordinal, \ ordinal, \
KernelExport::type, \ KernelExport::type, \
flags, \ flags, \
#name, \ #name, \
} }
#define FLAG(t) kXEKernelExportFlag##t #define FLAG(t) kXEKernelExportFlag##t

View File

@ -1,13 +1,13 @@
/** /**
****************************************************************************** ******************************************************************************
* Xenia : Xbox 360 Emulator Research Project * * Xenia : Xbox 360 Emulator Research Project *
****************************************************************************** ******************************************************************************
* Copyright 2013 Ben Vanik. All rights reserved. * * Copyright 2013 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. * * Released under the BSD license - see LICENSE in the root for more details. *
****************************************************************************** ******************************************************************************
*/ */
// Post-include file for an ordinal table. // Post-include file for an ordinal table.
#undef XE_EXPORT #undef XE_EXPORT

View File

@ -1,27 +1,27 @@
/** /**
****************************************************************************** ******************************************************************************
* Xenia : Xbox 360 Emulator Research Project * * Xenia : Xbox 360 Emulator Research Project *
****************************************************************************** ******************************************************************************
* Copyright 2013 Ben Vanik. All rights reserved. * * Copyright 2013 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. * * Released under the BSD license - see LICENSE in the root for more details. *
****************************************************************************** ******************************************************************************
*/ */
/** /**
* Pre-include file for an ordinal table. * Pre-include file for an ordinal table.
* Use this to build tables of constants describing the ordinals: * Use this to build tables of constants describing the ordinals:
* *
* // Build an ordinal enum to make it easy to lookup ordinals. * // Build an ordinal enum to make it easy to lookup ordinals.
* #include "xenia/kernel/util/ordinal_table_pre.inc" * #include "xenia/kernel/util/ordinal_table_pre.inc"
* namespace ordinals { * namespace ordinals {
* enum { * enum {
* #include "xenia/kernel/my_module/my_module_table.inc" * #include "xenia/kernel/my_module/my_module_table.inc"
* }; * };
* } // namespace ordinals * } // namespace ordinals
* #include "xenia/kernel/util/ordinal_table_post.inc" * #include "xenia/kernel/util/ordinal_table_post.inc"
*/ */
#define XE_EXPORT(module, ordinal, name, type, flags) \ #define XE_EXPORT(module, ordinal, name, type, flags) \
name = ordinal name = ordinal

View File

@ -1,13 +1,13 @@
# Copyright 2013 Ben Vanik. All Rights Reserved. # Copyright 2013 Ben Vanik. All Rights Reserved.
{ {
'sources': [ 'sources': [
'export_table_post.inc', 'export_table_post.inc',
'export_table_pre.inc', 'export_table_pre.inc',
'ordinal_table_post.inc', 'ordinal_table_post.inc',
'ordinal_table_pre.inc', 'ordinal_table_pre.inc',
'shim_utils.h', 'shim_utils.h',
'xex2.cc', 'xex2.cc',
'xex2.h', 'xex2.h',
'xex2_info.h', 'xex2_info.h',
], ],
} }

View File

@ -1,36 +1,36 @@
# Copyright 2013 Ben Vanik. All Rights Reserved. # Copyright 2013 Ben Vanik. All Rights Reserved.
{ {
'targets': [ 'targets': [
{ {
'target_name': 'beaengine', 'target_name': 'beaengine',
'type': '<(library)', 'type': '<(library)',
'direct_dependent_settings': { 'direct_dependent_settings': {
'include_dirs': [ 'include_dirs': [
'beaengine/include/', 'beaengine/include/',
], ],
'defines': [ 'defines': [
'BEA_ENGINE_STATIC=1', 'BEA_ENGINE_STATIC=1',
], ],
}, },
'sources': [ 'sources': [
'beaengine/beaengineSources/BeaEngine.c', 'beaengine/beaengineSources/BeaEngine.c',
'beaengine/include/beaengine/basic_types.h', 'beaengine/include/beaengine/basic_types.h',
'beaengine/include/beaengine/BeaEngine.h', 'beaengine/include/beaengine/BeaEngine.h',
'beaengine/include/beaengine/export.h', 'beaengine/include/beaengine/export.h',
'beaengine/include/beaengine/macros.h', 'beaengine/include/beaengine/macros.h',
], ],
'include_dirs': [ 'include_dirs': [
'beaengine/beaengineSources/', 'beaengine/beaengineSources/',
'beaengine/include/', 'beaengine/include/',
], ],
'defines': [ 'defines': [
'BEA_ENGINE_STATIC=1', 'BEA_ENGINE_STATIC=1',
#'BEA_LIGHT_DISASSEMBLY=1', #'BEA_LIGHT_DISASSEMBLY=1',
], ],
} }
] ]
} }

0
third_party/binutils/build.sh vendored Executable file → Normal file
View File

0
xenia-build.py Executable file → Normal file
View File