Commit Graph

41 Commits

Author SHA1 Message Date
Dragios
5d6f907e57 Revert "CPU JIT Part 2 (#4)"
This reverts commit 468a001a81.
2016-04-16 01:32:42 +08:00
Dragios
468a001a81 CPU JIT Part 2 (#4)
* ARM/Decoder: Initial implementation

* JitX64: Implement register allocator

* JitX64: Initial implementation of JitX64 compiler

* JitX64: Add accessors for ARMul_State::exclusive_tag and ARMul_State::exclusive_state

* JitX64: Implement ARM_Jit

ARM_Jit is the ARM_Interface for the x64 recompiler.

* tests: Infrastructure for unit tests

* dyncom: Implement Arm_DynCom::ClearCache()

* tests/JitX64: Fuzz ARM data processing instructions

* JitX64: Implement ARM_Jit::ClearCache()

* JitX64: Implement ADC_imm

* JitX64: Implement immediate data processing instructions

* fixup! Arm/ArmDecoder: Address comments regarding the arm decoder and check versions of all arm instructions

* fixup! Builds on OS X now

* fixup! Fix bugs in thumb decoder & have it use boost::optional

* JitX64/RegAlloc: Improve documentation and improve method names

* tests/JitX64: Improve tests

* tests/JitX64: Add tests for testing data processing instructions with Rd=R15

* fixup! JitX64/RegAlloc: Rename member functions to (Lock|Bind)ArmFor(Read|ReadWrite|Write).

* fixup! Addressed comments regarding JitX64::JitX64

* fixup! tests/JitX64: Address comments

* tests/JitX64: Initial thumb tests

* Common: Add MathUtil::SignExtend

* ARM_Disasm: Disassemble BLX

* JitX64: Implement branch instructions

* JitX64: Implement 32-bit thumb BL(X) instruction

* JitX64: Data Processing: Implement shift-by-immediate (_reg) instructions

* JitX64: Data Processing: Implement shift-by-register (_rsr) instructions

* x64 ABI: Be explicit about Gen:: namespace

* MMIO: UnmapRegion

* JitX64: Implement load/store instructions

* JitX64: Implement load and store multiple

* JitX64: Implement SETEND

* tests/JitX64: Improve thumb instruction test coverage

* fixup! Fix non-MSVC builds

* JitX64: Load/Store: Add UNPREDICTABLE ASSERTs, correct LDR R15 behavior

* tests/JitX64: Fix thumb tests

* JitX64: Implement synchronisation instructions

* JitX64: Implement exception-generating instructions

* ARM_Jit: ClearCache upon construct

* ARM/Decoder: Fill out more instructions

* JitX64: Removed old page table code

* fixup! ARM/Decoder: Various fixes

* Use C++14 std::integer_sequence.
* Split ArmDecoder::Instruction into ArmInstruction and ThumbInstruction
* Make Cond, Register, ShiftType and SignExtendRotation enum classes.
* ThumbMatcher is no longer allocated on the heap.
* JitX64::CondManager now uses Cond instead of SkyEye's ConditionCode.
* Add utility functions IsArmRegValid and MakeArmRegList.

* fixup! ARM/Decoder: Misc fixes

* fixup! Common: Move SignExtend and bits into BitUtil

* fixup! arm_dyncom_interpreter

* fixup! JitState: Should be final and should have initial values

* fixup! Make JitX64::CondManager::CurrentCond() const

* fixup! JitX64: Move thumb_BLX_* variables below ArmDecoder::Visitor functions

* fixup! RegAlloc: Simplify code

* fixup! MMIO: UnmapRegion

* fixup! Tests/JitX64: Use std::generate_n and factor pass-testing into DoesBehaviorMatch

* fixup! JitX64::LocationDescriptorHash: Use static_cast

* fixup! JitX64: Default values for primitive members

* fixup! JitX64: Add const to relevant member functions, add initialisers to members of CondManager

* fixup! Jit: Remove unnecessary headers

* fixup! RunJittedCode: Remove C-style casts

* fixup! Common: Common::make_unique -> std::make_unique

* fixup! BitUtils

* fixup! JitX64: reinterpret_cast<const void* const> -> reinterpret_cast<const void*>

* fixup! static -> inline in headers, moved instruction/helper/load_store.h function bodies into .cpp file

* fixup! Move public interface of JitX64 class to the top

* fixup! Rename JitX64::UpdateFlags* so flag names are in order (N, Z, C, V)

* fixup! BitUtil: Correct error messages, independent impl of Bit, correct SignExtend logic
2016-04-16 01:12:27 +08:00
Dragios
a8d0c51c69 Audio Core (#2)
* DSP: Implement Pipe 2

Pipe 2 is a DSP pipe that is used to initialize both the DSP hardware (the
application signals to the DSP to initialize) and the application (the DSP
provides the memory location of structures in the shared memory region).

* AudioCore: Implement codecs (DecodeADPCM, DecodePCM8, DecodePCM16)

* DSP Pipes: Implement as FIFO

* AudioCore: File structure

* AudioCore: More structure

* AudioCore: Buffer management

* DSP/Source: Reorganise Source's AdvanceFrame.

* Audio Output

* lolidk

* huh?

* interp

* More interp stuff

* oops

* Zero State

* Don't mix Source frame if it's not enabled

* DSP: Forgot to zero a buffer, adjusted thread synchronisation, adjusted format spec for buffers

* asdf

* Get it to compile and tweak stretching a bit.

* revert stretch test

* deleted accidental partial catch submodule commit

* new audio stretching algorithm

* update .gitmodule

* fix OS X build

* remove getopt from rubberband

* #include <stddef> to audio_core.h

* typo

* -framework Accelerate

* OptionTransientsSmooth -> OptionTransientsCrisp

* tweak stretch tempo smoothing coefficient. also switch back to smooth.

* tweak mroe

* remove printf

* sola

* #include <cmath>

* VERY QUICK MERGE TO GET IT WORKING DOESN'T ACTIVATE AUDIO FILTERS

* Reminder to self

* fix comparison

* common/thread: Correct code style

* Thread: Make Barrier reusable

* fix threading synchonisation code

* add profiling code

* print error to console when audio clips

* fix metallic sound

* reduce logspam
2016-04-16 01:10:29 +08:00
bunnei
0a1c73e396 Merge pull request #1517 from Lectem/fixSDLcmake
fix SDL2 detection for Visual
2016-03-23 13:35:16 -04:00
Jannik Vogel
0cdf8ff102 Update nihstro to latest master 2016-03-15 20:01:25 +01:00
Lectem
c8f8e70d31 fix SDL2 detection for Visual 2016-03-14 17:02:08 -04:00
bunnei
cf414db710 externals: Remove unused GLFW library from the repo. 2016-03-03 23:30:52 -05:00
MerryMage
ba2a54a9dd Dependencies: Remove GLFW, Add SDL2
citra: Remove GLFW, Add SDL2

FindSDL2: Do not CACHE SDL2_* variables if library is not found

EmuWindow_SDL2: Set minimal client area at initialisation time

EmuWindow_SDL2: Corrections

EmuWindow_SDL2: Fix no decorations on startup on OS X

cmake: windows_copy_files
2016-03-02 14:09:02 +00:00
Emmanuel Gil Peyrot
2e8a7a7a08 Externals: Regenerate GLAD with GL_KHR_debug support. 2015-10-17 17:09:07 +01:00
Yuri Kunde Schlesner
d8311e8365 CMake: Add missing library required by Linux for compiling glad 2015-09-06 19:45:46 -03:00
Yuri Kunde Schlesner
a1a5570e97 Replace the previous OpenGL loader with a glad-generated 3.3 one
The main advantage of switching to glad from glLoadGen is that, apart
from being actively maintained, it supports a customizable entrypoint
loader function, which makes it possible to also support OpenGL ES.
2015-08-30 08:45:56 -03:00
Yuri Kunde Schlesner
0fcabd2b11 Integrate the MicroProfile profiling library
This brings goodies such as a configurable user interface and
multi-threaded timeline view.
2015-08-24 22:16:28 -03:00
Yuri Kunde Schlesner
3007d0c651 Update boost external to v1.59.0 2015-08-16 21:20:48 -03:00
bunnei
094ae6fadb Shader: Initial implementation of x86_x64 JIT compiler for Pica vertex shaders.
- Config: Add an option for selecting to use shader JIT or interpreter.
- Qt: Add a menu option for enabling/disabling the shader JIT.
2015-08-15 18:01:07 -04:00
Yuri Kunde Schlesner
a25d1814d5 Update nihstro to latest master 2015-07-26 07:12:28 -03:00
Yuri Kunde Schlesner
5161699452 getopt: Fix macro redefinition warning
We already define _CRT_SECURE_NO_WARNINGS
2015-07-13 19:47:08 -03:00
Yuri Kunde Schlesner
1bf030f4af getopt: Fix compilation settings
INTERFACE doesn't define the symbol when compiling the library itself.
PUBLIC should be used when the definition is needed both by the library
and by the users.
2015-07-13 19:47:04 -03:00
Greg Wicks
9930ef72dd Implement new argument parsing using getopt and add the corresponding library to externals 2015-07-12 15:49:23 -04:00
Yuri Kunde Schlesner
33c57361a9 Update bundled GLFW to 3.1.1
It may be necessary to fix the CMake paths manually for an exsting CMake
cache after this change.
2015-05-25 00:42:21 -03:00
bunnei
f935130a0f vertex_shader: Implement MADI instruction.
nihstro: Update submodule to latest upstream/master to support MADI instruction decoding.
2015-05-09 22:12:34 -04:00
archshift
7d43aef4d0 Update nihstro submodule to the initial release version.
Includes more opcodes to implement in the future.
2015-03-08 13:52:38 -07:00
Yuri Kunde Schlesner
bf30dba6c2 Update ext-boost commit again which got reverted by #500 2015-02-12 12:14:14 -02:00
archshift
ef24e72b26 Asserts: break/crash program, fit to style guide; log.h->assert.h
Involves making asserts use printf instead of the log functions (log functions are asynchronous and, as such, the log won't be printed in time)
As such, the log type argument was removed (printf obviously can't use it, and it's made obsolete by the file and line printing)

Also removed some GEKKO cruft.
2015-02-10 18:30:31 -08:00
Yuri Kunde Schlesner
12232e0b08 Update boost external 2015-02-02 15:37:06 -02:00
Tony Wasserka
2b9a9a45b7 Pica/VertexShader: Implement JMPC/JMPU/CALLC/CALLU. 2015-01-12 15:47:21 -08:00
Yuri Kunde Schlesner
8ad41775cc Kernel: Start using boost::intrusive_ptr for lifetime management 2015-01-09 19:43:52 -02:00
Yuri Kunde Schlesner
a320d1a5b4 Clipper: Avoid dynamic allocations
The triangle clipper was allocating its temporary input, output and work
buffers using a std::vector. Since this is a hot path, it's desirable to
use stack allocation instead.
2014-12-29 02:08:09 -02:00
Tony Wasserka
056a8f9dfa Add nihstro (a 3DS shader tools suite) as a submodule. 2014-12-20 18:06:55 +01:00
Tony Wasserka
2db294306f externals: Add boost submodule. 2014-12-07 23:52:04 +01:00
archshift
e6594f9f53 Added configuration file system.
Uses QSettings on citra-qt, and inih on citra-cli.
2014-10-07 15:09:37 -07:00
Yuri Kunde Schlesner
45976da975 CMake cleanup
Several cleanups to the buildsystem:
 - Do better factoring of common libs between platforms.
 - Add support to building on Windows.
 - Remove Qt4 support.
 - Re-sort file lists and add missing headers.
2014-09-01 18:06:30 -03:00
Yuri Kunde Schlesner
523385955c Update GLFW to 3.0.4 and include x64 lib for MSVC 2014-09-01 17:41:56 -03:00
Yuri Kunde Schlesner
478289140d Replace GLEW with a glLoadGen loader.
This should fix the GL loading errors that occur in some drivers due to
the use of deprecated functions by GLEW. Side benefits are more accurate
auto-completion (deprecated function and symbols don't exist) and faster
pointer loading (less entrypoints to load). In addition it removes an
external library depency, simplifying the build system a bit and
eliminating one set of binary libraries for Windows.
2014-09-01 17:41:56 -03:00
Yuri Kunde Schlesner
04d53629db Remove documentation for external modules.
We don't need these and they clutter up the repository.
2014-08-23 11:48:58 -03:00
Sacha
90f23020f5 Add Qt5 option. Use Qt5 by default. 2014-08-19 21:34:00 +10:00
Sacha
b7ecc9543a CMake Cleanup 2014-08-18 14:35:44 +10:00
archshift
71b8789803 Indent fixes 2014-05-19 13:51:59 -07:00
archshift
1e729e7cae Added FindGLEW to cmake-modules 2014-05-16 23:03:10 -07:00
bunnei
80a040ac77 fixes to scm_rev generation to make it conistent with windows build 2014-04-23 19:13:00 -07:00
bunnei
4405a53cf3 added scm rev generation on Linux/cmake 2014-04-23 18:43:57 -07:00
ShizZy
27474060e1 adding initial project layout 2013-08-29 23:35:09 -04:00