summaryrefslogtreecommitdiffstats
path: root/src/android
diff options
context:
space:
mode:
authorGPUCode <geoster3d@gmail.com>2023-11-18 15:10:39 +0100
committert895 <clombardo169@gmail.com>2023-11-25 06:47:28 +0100
commit8fab363237083a8130a7b2a023cd9c5dd83f8f4f (patch)
treefa94b90be48a5debe83b414119da5b8419dd463c /src/android
parentarm: Implement native code execution backend (diff)
downloadyuzu-8fab363237083a8130a7b2a023cd9c5dd83f8f4f.tar
yuzu-8fab363237083a8130a7b2a023cd9c5dd83f8f4f.tar.gz
yuzu-8fab363237083a8130a7b2a023cd9c5dd83f8f4f.tar.bz2
yuzu-8fab363237083a8130a7b2a023cd9c5dd83f8f4f.tar.lz
yuzu-8fab363237083a8130a7b2a023cd9c5dd83f8f4f.tar.xz
yuzu-8fab363237083a8130a7b2a023cd9c5dd83f8f4f.tar.zst
yuzu-8fab363237083a8130a7b2a023cd9c5dd83f8f4f.zip
Diffstat (limited to 'src/android')
-rw-r--r--src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/IntSetting.kt1
-rw-r--r--src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/view/SettingsItem.kt9
-rw-r--r--src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/SettingsFragmentPresenter.kt1
-rw-r--r--src/android/app/src/main/res/values/arrays.xml10
-rw-r--r--src/android/app/src/main/res/values/strings.xml5
5 files changed, 26 insertions, 0 deletions
diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/IntSetting.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/IntSetting.kt
index 151362124..ef10b209f 100644
--- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/IntSetting.kt
+++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/IntSetting.kt
@@ -10,6 +10,7 @@ enum class IntSetting(
override val category: Settings.Category,
override val androidDefault: Int? = null
) : AbstractIntSetting {
+ CPU_BACKEND("cpu_backend", Settings.Category.Cpu),
CPU_ACCURACY("cpu_accuracy", Settings.Category.Cpu),
REGION_INDEX("region_index", Settings.Category.System),
LANGUAGE_INDEX("language_index", Settings.Category.System),
diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/view/SettingsItem.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/view/SettingsItem.kt
index 6aba69dbe..1f090424b 100644
--- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/view/SettingsItem.kt
+++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/model/view/SettingsItem.kt
@@ -79,6 +79,15 @@ abstract class SettingsItem(
)
put(
SingleChoiceSetting(
+ IntSetting.CPU_BACKEND,
+ R.string.cpu_backend,
+ 0,
+ R.array.cpuBackendNames,
+ R.array.cpuBackendValues
+ )
+ )
+ put(
+ SingleChoiceSetting(
IntSetting.CPU_ACCURACY,
R.string.cpu_accuracy,
0,
diff --git a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/SettingsFragmentPresenter.kt b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/SettingsFragmentPresenter.kt
index 8b71e32f3..7425728c6 100644
--- a/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/SettingsFragmentPresenter.kt
+++ b/src/android/app/src/main/java/org/yuzu/yuzu_emu/features/settings/ui/SettingsFragmentPresenter.kt
@@ -269,6 +269,7 @@ class SettingsFragmentPresenter(
add(BooleanSetting.RENDERER_DEBUG.key)
add(HeaderSetting(R.string.cpu))
+ add(IntSetting.CPU_BACKEND.key)
add(IntSetting.CPU_ACCURACY.key)
add(BooleanSetting.CPU_DEBUG_MODE.key)
add(SettingsItem.FASTMEM_COMBINED)
diff --git a/src/android/app/src/main/res/values/arrays.xml b/src/android/app/src/main/res/values/arrays.xml
index 51bcc49a3..2756e5cc9 100644
--- a/src/android/app/src/main/res/values/arrays.xml
+++ b/src/android/app/src/main/res/values/arrays.xml
@@ -175,6 +175,16 @@
<item>2</item>
</integer-array>
+ <string-array name="cpuBackendNames">
+ <item>@string/cpu_backend_dynarmic</item>
+ <item>@string/cpu_backend_nce</item>
+ </string-array>
+
+ <integer-array name="cpuBackendValues">
+ <item>0</item>
+ <item>1</item>
+ </integer-array>
+
<string-array name="cpuAccuracyNames">
<item>@string/auto</item>
<item>@string/cpu_accuracy_accurate</item>
diff --git a/src/android/app/src/main/res/values/strings.xml b/src/android/app/src/main/res/values/strings.xml
index 471af8795..f07121f6a 100644
--- a/src/android/app/src/main/res/values/strings.xml
+++ b/src/android/app/src/main/res/values/strings.xml
@@ -185,6 +185,7 @@
<string name="frame_limit_enable_description">Limits emulation speed to a specified percentage of normal speed.</string>
<string name="frame_limit_slider">Limit speed percent</string>
<string name="frame_limit_slider_description">Specifies the percentage to limit emulation speed. 100% is the normal speed. Values higher or lower will increase or decrease the speed limit.</string>
+ <string name="cpu_backend">CPU Backend</string>
<string name="cpu_accuracy">CPU accuracy</string>
<string name="value_with_units">%1$s%2$s</string>
@@ -416,6 +417,10 @@
<string name="ratio_force_sixteen_ten">Force 16:10</string>
<string name="ratio_stretch">Stretch to window</string>
+ <!-- CPU Backend -->
+ <string name="cpu_backend_dynarmic">Dynarmic (Slow)</string>
+ <string name="cpu_backend_nce">Native code execution (NCE)</string>
+
<!-- CPU Accuracy -->
<string name="cpu_accuracy_accurate">Accurate</string>
<string name="cpu_accuracy_unsafe">Unsafe</string>