Merge branch 'master' into d3d12
This commit is contained in:
commit
f7ea93148a
|
@ -34,7 +34,7 @@ pull_requests:
|
|||
#---------------------------------#
|
||||
|
||||
# Operating system (build VM template)
|
||||
os: Visual Studio 2017
|
||||
os: Visual Studio 2019
|
||||
|
||||
# scripts that are called at very beginning, before repo cloning
|
||||
init:
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
patreon: xenia_project
|
|
@ -79,7 +79,9 @@ filter("configurations:Release")
|
|||
"NDEBUG",
|
||||
"_NO_DEBUG_HEAP=1",
|
||||
})
|
||||
optimize("On")
|
||||
optimize("speed")
|
||||
inlining("Auto")
|
||||
floatingpoint("Fast")
|
||||
flags({
|
||||
"LinkTimeOptimization",
|
||||
})
|
||||
|
@ -88,6 +90,9 @@ filter({"configurations:Release", "platforms:Windows"})
|
|||
linkoptions({
|
||||
"/NODEFAULTLIB:MSVCRTD",
|
||||
})
|
||||
buildoptions({
|
||||
"/GT", -- enable fiber-safe optimizations
|
||||
})
|
||||
|
||||
filter("platforms:Linux")
|
||||
system("linux")
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,33 @@
|
|||
/**
|
||||
******************************************************************************
|
||||
* Xenia : Xbox 360 Emulator Research Project *
|
||||
******************************************************************************
|
||||
* Copyright 2015 Ben Vanik. All rights reserved. *
|
||||
* Released under the BSD license - see LICENSE in the root for more details. *
|
||||
******************************************************************************
|
||||
*/
|
||||
|
||||
#ifndef XENIA_CPU_PPC_PPC_OPCODE_DISASM_H_
|
||||
#define XENIA_CPU_PPC_PPC_OPCODE_DISASM_H_
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
#include "xenia/base/string_buffer.h"
|
||||
#include "xenia/cpu/ppc/ppc_opcode.h"
|
||||
|
||||
namespace xe {
|
||||
namespace cpu {
|
||||
namespace ppc {
|
||||
|
||||
constexpr size_t kNamePad = 11;
|
||||
const uint8_t kSpaces[kNamePad] = {0x20, 0x20, 0x20, 0x20, 0x20,
|
||||
0x20, 0x20, 0x20, 0x20, 0x20};
|
||||
void PadStringBuffer(StringBuffer* str, size_t base, size_t pad);
|
||||
|
||||
void PrintDisasm_bcx(const PPCDecodeData& d, StringBuffer* str);
|
||||
|
||||
} // namespace ppc
|
||||
} // namespace cpu
|
||||
} // namespace xe
|
||||
|
||||
#endif // XENIA_CPU_PPC_PPC_OPCODE_DISASM_H_
|
File diff suppressed because it is too large
Load Diff
|
@ -17,6 +17,9 @@ import sys
|
|||
from xml.etree.ElementTree import ElementTree, Element, SubElement, tostring, dump
|
||||
|
||||
|
||||
custom_disasm = ['bcx']
|
||||
|
||||
|
||||
self_path = os.path.dirname(os.path.abspath(__file__))
|
||||
|
||||
|
||||
|
@ -286,19 +289,13 @@ def generate_disasm(insns):
|
|||
w0('#include "xenia/base/assert.h"')
|
||||
w0('#include "xenia/cpu/ppc/ppc_decode_data.h"')
|
||||
w0('#include "xenia/cpu/ppc/ppc_opcode.h"')
|
||||
w0('#include "xenia/cpu/ppc/ppc_opcode_disasm.h"')
|
||||
w0('#include "xenia/cpu/ppc/ppc_opcode_info.h"')
|
||||
w0('')
|
||||
w0('namespace xe {')
|
||||
w0('namespace cpu {')
|
||||
w0('namespace ppc {')
|
||||
w0('')
|
||||
w0('constexpr size_t kNamePad = 11;')
|
||||
w0('const uint8_t kSpaces[kNamePad] = {0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20};')
|
||||
w0('void PadStringBuffer(StringBuffer* str, size_t base, size_t pad) {')
|
||||
w1('size_t added_len = str->length() - base;')
|
||||
w1('if (added_len < pad) str->AppendBytes(kSpaces, kNamePad - added_len);')
|
||||
w0('}')
|
||||
w0('')
|
||||
|
||||
for i in insns:
|
||||
i.mnem = '"' + c_mnem(i.mnem) + '"'
|
||||
|
@ -319,7 +316,7 @@ def generate_disasm(insns):
|
|||
# TODO(benvanik): support alts:
|
||||
# <disasm cond="![RA]">li [RD], [SIMM]</disasm>
|
||||
for i in insns:
|
||||
if not i.disasm_str:
|
||||
if not i.disasm_str or literal_mnem(i.mnem) in custom_disasm:
|
||||
continue
|
||||
w0('void PrintDisasm_%s(const PPCDecodeData& d, StringBuffer* str) {' % (literal_mnem(i.mnem)))
|
||||
w1('// ' + i.disasm_str)
|
||||
|
@ -519,11 +516,11 @@ if __name__ == '__main__':
|
|||
with open(os.path.join(ppc_src_path, 'ppc_opcode.h'), 'w') as f:
|
||||
f.write(generate_opcodes(insns))
|
||||
insns = parse_insns(os.path.join(self_path, 'ppc-instructions.xml'))
|
||||
with open(os.path.join(ppc_src_path, 'ppc_opcode_table.cc'), 'w') as f:
|
||||
with open(os.path.join(ppc_src_path, 'ppc_opcode_table_gen.cc'), 'w') as f:
|
||||
f.write(generate_table(insns))
|
||||
insns = parse_insns(os.path.join(self_path, 'ppc-instructions.xml'))
|
||||
with open(os.path.join(ppc_src_path, 'ppc_opcode_disasm.cc'), 'w') as f:
|
||||
with open(os.path.join(ppc_src_path, 'ppc_opcode_disasm_gen.cc'), 'w') as f:
|
||||
f.write(generate_disasm(insns))
|
||||
insns = parse_insns(os.path.join(self_path, 'ppc-instructions.xml'))
|
||||
with open(os.path.join(ppc_src_path, 'ppc_opcode_lookup.cc'), 'w') as f:
|
||||
with open(os.path.join(ppc_src_path, 'ppc_opcode_lookup_gen.cc'), 'w') as f:
|
||||
f.write(generate_lookup(insns))
|
||||
|
|
Loading…
Reference in New Issue