Skip to content

Ghidra is a software reverse engineering (SRE) framework

GP-3071: Remove stale 'commitByDefault' documentation GP-3071: Fix test compilation GP-3071: Certify GP-3071: Put lifecycle stuff in Emulation, not Utility GP-3071: Fix tests GP-3071: Mock language for framework tests GP-3071: WIP: Move tests and sort out dependencies GP-3071: Actually, not Generic, but Emulation GP-3071: Move both emulators into new Emulation module GP-3071: WIP: Move some tests GP-3071: NICK: Remove import/ref from PcodeEmulator javadoc GP-3071: WIP: Move stuff GP-3071: WIP: Move AnnotationUtilities GP-3071: NICK: Remove an import and ref in javadoc GP-3071: Create SysteEmulation feature. Move stuff. GP-3071: WIP: Move stuff GP-3071: Create emulation module

Dan362408a290e4
diff --git a/Ghidra/Debug/Framework-TraceModeling/build.gradle b/Ghidra/Debug/Framework-TraceModeling/build.gradle
index 0b6f4871d2..7aec2d3efb 100644
--- a/Ghidra/Debug/Framework-TraceModeling/build.gradle
+++ b/Ghidra/Debug/Framework-TraceModeling/build.gradle
@@ -24,6 +24,7 @@ eclipse.project.name = 'Debug Framework-TraceModeling'
dependencies {
api project(':Generic')
api project(':SoftwareModeling')
+ api project(':Emulation')
api project(':ProposedUtils')
api project(':Framework-Debugging')
annotationProcessor project(':AnnotationValidator')
diff --git a/Ghidra/Debug/TaintAnalysis/build.gradle b/Ghidra/Debug/TaintAnalysis/build.gradle
index 1c1fc7e82d..db93188943 100644
--- a/Ghidra/Debug/TaintAnalysis/build.gradle
+++ b/Ghidra/Debug/TaintAnalysis/build.gradle
@@ -23,6 +23,7 @@ eclipse.project.name = 'Debug TaintAnalysis'
dependencies {
api project(':Debugger')
+ api project(':SystemEmulation')
// Oof. Apparently, this doesn't work transitively....
testImplementation project(path: ':ProposedUtils', configuration: 'testArtifacts')
@@ -30,4 +31,5 @@ dependencies {
testImplementation project(path: ':Framework-Debugging', configuration: 'testArtifacts')
testImplementation project(path: ':Framework-TraceModeling', configuration: 'testArtifacts')
testImplementation project(path: ':Debugger', configuration: 'testArtifacts')
+ testImplementation project(path: ':SystemEmulation', configuration: 'testArtifacts')
}
diff --git a/Ghidra/Features/Base/build.gradle b/Ghidra/Features/Base/build.gradle
index b649a3cc12..d4cdd500a9 100644
--- a/Ghidra/Features/Base/build.gradle
+++ b/Ghidra/Features/Base/build.gradle
@@ -39,6 +39,7 @@ configurations {
dependencies {
api project(':SoftwareModeling')
+ api project(':Emulation')
api 'org.apache.felix:org.apache.felix.framework:7.0.3'
api 'com.github.rotty3000:phidias:0.3.7'
diff --git a/Ghidra/Features/SystemEmulation/Module.manifest b/Ghidra/Features/SystemEmulation/Module.manifest
new file mode 100644
index 0000000000..e69de29bb2
diff --git a/Ghidra/Features/SystemEmulation/build.gradle b/Ghidra/Features/SystemEmulation/build.gradle
new file mode 100644
index 0000000000..79814fad40
--- /dev/null
+++ b/Ghidra/Features/SystemEmulation/build.gradle
@@ -0,0 +1,29 @@
+/* ###
+ * IP: GHIDRA
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+apply from: "${rootProject.projectDir}/gradle/javaProject.gradle"
+apply from: "${rootProject.projectDir}/gradle/jacocoProject.gradle"
+apply from: "${rootProject.projectDir}/gradle/javaTestProject.gradle"
+apply from: "${rootProject.projectDir}/gradle/distributableGhidraModule.gradle"
+
+apply plugin: 'eclipse'
+eclipse.project.name = 'Features SystemEmulation'
+
+dependencies {
+ api project(':Base')
+ api project(':Debugger')
+ api project(':Emulation')
+ api project(':DB')
+}
diff --git a/Ghidra/Features/SystemEmulation/certification.manifest b/Ghidra/Features/SystemEmulation/certification.manifest
new file mode 100644
index 0000000000..895ac4b698
--- /dev/null
+++ b/Ghidra/Features/SystemEmulation/certification.manifest
@@ -0,0 +1,2 @@
+##VERSION: 2.0
+Module.manifest||GHIDRA||||END|
diff --git a/Ghidra/Debug/Debugger/ghidra_scripts/DebuggerEmuExampleScript.java b/Ghidra/Features/SystemEmulation/ghidra_scripts/DebuggerEmuExampleScript.java
similarity index 100%
rename from Ghidra/Debug/Debugger/ghidra_scripts/DebuggerEmuExampleScript.java
rename to Ghidra/Features/SystemEmulation/ghidra_scripts/DebuggerEmuExampleScript.java
diff --git a/Ghidra/Debug/Debugger/ghidra_scripts/DemoPcodeUseropLibrary.java b/Ghidra/Features/SystemEmulation/ghidra_scripts/DemoPcodeUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/Debugger/ghidra_scripts/DemoPcodeUseropLibrary.java
rename to Ghidra/Features/SystemEmulation/ghidra_scripts/DemoPcodeUseropLibrary.java
diff --git a/Ghidra/Debug/Debugger/ghidra_scripts/DemoSyscallLibrary.java b/Ghidra/Features/SystemEmulation/ghidra_scripts/DemoSyscallLibrary.java
similarity index 100%
rename from Ghidra/Debug/Debugger/ghidra_scripts/DemoSyscallLibrary.java
rename to Ghidra/Features/SystemEmulation/ghidra_scripts/DemoSyscallLibrary.java
diff --git a/Ghidra/Debug/Debugger/ghidra_scripts/EmuDeskCheckScript.java b/Ghidra/Features/SystemEmulation/ghidra_scripts/EmuDeskCheckScript.java
similarity index 100%
rename from Ghidra/Debug/Debugger/ghidra_scripts/EmuDeskCheckScript.java
rename to Ghidra/Features/SystemEmulation/ghidra_scripts/EmuDeskCheckScript.java
diff --git a/Ghidra/Debug/Debugger/ghidra_scripts/StandAloneEmuExampleScript.java b/Ghidra/Features/SystemEmulation/ghidra_scripts/StandAloneEmuExampleScript.java
similarity index 100%
rename from Ghidra/Debug/Debugger/ghidra_scripts/StandAloneEmuExampleScript.java
rename to Ghidra/Features/SystemEmulation/ghidra_scripts/StandAloneEmuExampleScript.java
diff --git a/Ghidra/Debug/Debugger/ghidra_scripts/StandAloneStructuredSleighScript.java b/Ghidra/Features/SystemEmulation/ghidra_scripts/StandAloneStructuredSleighScript.java
similarity index 100%
rename from Ghidra/Debug/Debugger/ghidra_scripts/StandAloneStructuredSleighScript.java
rename to Ghidra/Features/SystemEmulation/ghidra_scripts/StandAloneStructuredSleighScript.java
diff --git a/Ghidra/Debug/Debugger/ghidra_scripts/StandAloneSyscallEmuExampleScript.java b/Ghidra/Features/SystemEmulation/ghidra_scripts/StandAloneSyscallEmuExampleScript.java
similarity index 100%
rename from Ghidra/Debug/Debugger/ghidra_scripts/StandAloneSyscallEmuExampleScript.java
rename to Ghidra/Features/SystemEmulation/ghidra_scripts/StandAloneSyscallEmuExampleScript.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/linux/AbstractEmuLinuxSyscallUseropLibrary.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/linux/AbstractEmuLinuxSyscallUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/linux/AbstractEmuLinuxSyscallUseropLibrary.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/linux/AbstractEmuLinuxSyscallUseropLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibrary.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibrary.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibrary.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibrary.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/AnnotatedEmuSyscallUseropLibrary.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/AnnotatedEmuSyscallUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/AnnotatedEmuSyscallUseropLibrary.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/AnnotatedEmuSyscallUseropLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/BytesEmuFileContents.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/BytesEmuFileContents.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/BytesEmuFileContents.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/BytesEmuFileContents.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuFileContents.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuFileContents.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuFileContents.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuFileContents.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuIOException.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuIOException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuIOException.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuIOException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuInvalidSystemCallException.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuInvalidSystemCallException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuInvalidSystemCallException.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuInvalidSystemCallException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuProcessExitedException.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuProcessExitedException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuProcessExitedException.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuProcessExitedException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuSyscallLibrary.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuSyscallLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuSyscallLibrary.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuSyscallLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuSystemException.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuSystemException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/EmuSystemException.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/EmuSystemException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/PairedEmuFileContents.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/PairedEmuFileContents.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/PairedEmuFileContents.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/PairedEmuFileContents.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/UseropEmuSyscallDefinition.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/UseropEmuSyscallDefinition.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/sys/UseropEmuSyscallDefinition.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/sys/UseropEmuSyscallDefinition.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFile.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFile.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFile.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFile.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFileSystem.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFileSystem.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFileSystem.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixFileSystem.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixSyscallUseropLibrary.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixSyscallUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixSyscallUseropLibrary.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractEmuUnixSyscallUseropLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractStreamEmuUnixFileHandle.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractStreamEmuUnixFileHandle.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/AbstractStreamEmuUnixFileHandle.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/AbstractStreamEmuUnixFileHandle.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/BytesEmuUnixFileSystem.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/BytesEmuUnixFileSystem.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/BytesEmuUnixFileSystem.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/BytesEmuUnixFileSystem.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/DefaultEmuUnixFileHandle.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/DefaultEmuUnixFileHandle.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/DefaultEmuUnixFileHandle.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/DefaultEmuUnixFileHandle.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixException.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixException.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFile.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFile.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFile.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFile.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileDescriptor.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileDescriptor.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileDescriptor.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileDescriptor.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileStat.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileStat.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileStat.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileStat.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileSystem.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileSystem.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileSystem.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixFileSystem.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixUser.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixUser.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/EmuUnixUser.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/EmuUnixUser.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/IOStreamEmuUnixFileHandle.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/IOStreamEmuUnixFileHandle.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/unix/IOStreamEmuUnixFileHandle.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/unix/IOStreamEmuUnixFileHandle.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/x86/X86PcodeStateInitializer.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/x86/X86PcodeStateInitializer.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/x86/X86PcodeStateInitializer.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/emu/x86/X86PcodeStateInitializer.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/AbstractStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/AbstractStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/AbstractStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/AbstractStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ArithBinExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ArithBinExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ArithBinExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ArithBinExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/AssignStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/AssignStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/AssignStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/AssignStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/BinExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/BinExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/BinExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/BinExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/BlockStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/BlockStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/BlockStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/BlockStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/BreakStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/BreakStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/BreakStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/BreakStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/CallExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/CallExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/CallExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/CallExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/CmpExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/CmpExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/CmpExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/CmpExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ConditionalStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ConditionalStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ConditionalStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ConditionalStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ContinueStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ContinueStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ContinueStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ContinueStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DeclStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DeclStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DeclStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DeclStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DefaultUseropDecl.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DefaultUseropDecl.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DefaultUseropDecl.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DefaultUseropDecl.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DefaultVar.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DefaultVar.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DefaultVar.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DefaultVar.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DerefExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DerefExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/DerefExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/DerefExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/Expr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/Expr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/Expr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/Expr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/FieldExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/FieldExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/FieldExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/FieldExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ForStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ForStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ForStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ForStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/GotoStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/GotoStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/GotoStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/GotoStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/IfStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/IfStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/IfStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/IfStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/IndexExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/IndexExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/IndexExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/IndexExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/InvExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/InvExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/InvExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/InvExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LValInternal.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LValInternal.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LValInternal.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LValInternal.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LangVar.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LangVar.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LangVar.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LangVar.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LiteralExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LiteralExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LiteralExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LiteralExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LiteralFloatExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LiteralFloatExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LiteralFloatExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LiteralFloatExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LiteralLongExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LiteralLongExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LiteralLongExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LiteralLongExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LocalVar.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LocalVar.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LocalVar.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LocalVar.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LoopStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LoopStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LoopStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LoopStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LoopTruncateStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LoopTruncateStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/LoopTruncateStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/LoopTruncateStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/NotExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/NotExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/NotExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/NotExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RValInternal.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RValInternal.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RValInternal.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RValInternal.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RawExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RawExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RawExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RawExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RawStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RawStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RawStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RawStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ResultStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ResultStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ResultStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ResultStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ReturnStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ReturnStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/ReturnStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/ReturnStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RoutineStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RoutineStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/RoutineStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/RoutineStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/StringTree.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/StringTree.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/StringTree.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/StringTree.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/StructuredSleigh.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/StructuredSleigh.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/StructuredSleigh.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/StructuredSleigh.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/UnExpr.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/UnExpr.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/UnExpr.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/UnExpr.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/VoidExprStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/VoidExprStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/VoidExprStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/VoidExprStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/WhileStmt.java b/Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/WhileStmt.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/struct/WhileStmt.java
rename to Ghidra/Features/SystemEmulation/src/main/java/ghidra/pcode/struct/WhileStmt.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibraryTest.java b/Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibraryTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibraryTest.java
rename to Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/linux/EmuLinuxAmd64SyscallUseropLibraryTest.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibraryTest.java b/Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibraryTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibraryTest.java
rename to Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/linux/EmuLinuxX86SyscallUseropLibraryTest.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/sys/EmuAmd64SyscallUseropLibraryTest.java b/Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/sys/EmuAmd64SyscallUseropLibraryTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/sys/EmuAmd64SyscallUseropLibraryTest.java
rename to Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/sys/EmuAmd64SyscallUseropLibraryTest.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/sys/SyscallTestHelper.java b/Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/sys/SyscallTestHelper.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/sys/SyscallTestHelper.java
rename to Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/emu/sys/SyscallTestHelper.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/struct/sub/StructuredSleighTest.java b/Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/struct/sub/StructuredSleighTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/struct/sub/StructuredSleighTest.java
rename to Ghidra/Features/SystemEmulation/src/test/java/ghidra/pcode/struct/sub/StructuredSleighTest.java
diff --git a/Ghidra/Framework/Emulation/Module.manifest b/Ghidra/Framework/Emulation/Module.manifest
new file mode 100644
index 0000000000..e69de29bb2
diff --git a/Ghidra/Framework/Emulation/build.gradle b/Ghidra/Framework/Emulation/build.gradle
new file mode 100644
index 0000000000..0a638d0585
--- /dev/null
+++ b/Ghidra/Framework/Emulation/build.gradle
@@ -0,0 +1,28 @@
+/* ###
+ * IP: GHIDRA
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+apply from: "${rootProject.projectDir}/gradle/javaProject.gradle"
+apply from: "${rootProject.projectDir}/gradle/jacocoProject.gradle"
+apply from: "${rootProject.projectDir}/gradle/javaTestProject.gradle"
+apply from: "${rootProject.projectDir}/gradle/distributableGhidraModule.gradle"
+
+apply plugin: 'eclipse'
+eclipse.project.name = 'Framework Emulation'
+
+dependencies {
+ api project(':SoftwareModeling')
+ api project(':Generic')
+ api project(':Utility')
+}
diff --git a/Ghidra/Framework/Emulation/certification.manifest b/Ghidra/Framework/Emulation/certification.manifest
new file mode 100644
index 0000000000..90dcde061a
--- /dev/null
+++ b/Ghidra/Framework/Emulation/certification.manifest
@@ -0,0 +1,6 @@
+##VERSION: 2.0
+Module.manifest||GHIDRA||||END|
+src/test/resources/mock.cspec||GHIDRA||||END|
+src/test/resources/mock.ldefs||GHIDRA||||END|
+src/test/resources/mock.pspec||GHIDRA||||END|
+src/test/resources/mock.slaspec||GHIDRA||||END|
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/generic/RangeMapSetter.java b/Ghidra/Framework/Emulation/src/main/java/generic/RangeMapSetter.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/generic/RangeMapSetter.java
rename to Ghidra/Framework/Emulation/src/main/java/generic/RangeMapSetter.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/generic/Span.java b/Ghidra/Framework/Emulation/src/main/java/generic/Span.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/generic/Span.java
rename to Ghidra/Framework/Emulation/src/main/java/generic/Span.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/generic/ULongSpan.java b/Ghidra/Framework/Emulation/src/main/java/generic/ULongSpan.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/generic/ULongSpan.java
rename to Ghidra/Framework/Emulation/src/main/java/generic/ULongSpan.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/generic/Unique.java b/Ghidra/Framework/Emulation/src/main/java/generic/Unique.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/generic/Unique.java
rename to Ghidra/Framework/Emulation/src/main/java/generic/Unique.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/Emulator.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/Emulator.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/Emulator.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/Emulator.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/EmulatorConfiguration.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/EmulatorConfiguration.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/EmulatorConfiguration.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/EmulatorConfiguration.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/EmulatorHelper.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/EmulatorHelper.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/EmulatorHelper.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/EmulatorHelper.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/FilteredMemoryState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/FilteredMemoryState.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/FilteredMemoryState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/FilteredMemoryState.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/MemoryAccessFilter.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/MemoryAccessFilter.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/MemoryAccessFilter.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/MemoryAccessFilter.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/CompositeLoadImage.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/CompositeLoadImage.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/CompositeLoadImage.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/CompositeLoadImage.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/EmulatorLoadData.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/EmulatorLoadData.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/EmulatorLoadData.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/EmulatorLoadData.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/MemoryImage.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/MemoryImage.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/MemoryImage.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/MemoryImage.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/MemoryLoadImage.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/MemoryLoadImage.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/MemoryLoadImage.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/MemoryLoadImage.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/ProgramLoadImage.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/ProgramLoadImage.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/ProgramLoadImage.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/ProgramLoadImage.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/ProgramMappedLoadImage.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/ProgramMappedLoadImage.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/ProgramMappedLoadImage.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/ProgramMappedLoadImage.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/ProgramMappedMemory.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/ProgramMappedMemory.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/memory/ProgramMappedMemory.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/memory/ProgramMappedMemory.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/DumpMiscState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/DumpMiscState.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/DumpMiscState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/DumpMiscState.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/FilteredMemoryPageOverlay.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/FilteredMemoryPageOverlay.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/FilteredMemoryPageOverlay.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/FilteredMemoryPageOverlay.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/FilteredRegisterBank.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/FilteredRegisterBank.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/FilteredRegisterBank.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/FilteredRegisterBank.java
diff --git a/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/RegisterState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/RegisterState.java
similarity index 100%
rename from Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/app/emulator/state/RegisterState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/emulator/state/RegisterState.java
diff --git a/Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/AbstractAppender.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/AbstractAppender.java
similarity index 100%
rename from Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/AbstractAppender.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/AbstractAppender.java
diff --git a/Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/AbstractPcodeFormatter.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/AbstractPcodeFormatter.java
similarity index 100%
rename from Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/AbstractPcodeFormatter.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/AbstractPcodeFormatter.java
diff --git a/Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/Appender.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/Appender.java
similarity index 100%
rename from Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/Appender.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/Appender.java
diff --git a/Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/PcodeFormatter.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/PcodeFormatter.java
similarity index 100%
rename from Ghidra/Features/Base/src/main/java/ghidra/app/util/pcode/PcodeFormatter.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/app/util/pcode/PcodeFormatter.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/generic/util/datastruct/SemisparseByteArray.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/generic/util/datastruct/SemisparseByteArray.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/generic/util/datastruct/SemisparseByteArray.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/generic/util/datastruct/SemisparseByteArray.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Experimental.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Experimental.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Experimental.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Experimental.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Internal.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Internal.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Internal.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Internal.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Transitional.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Transitional.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Transitional.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Transitional.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Unfinished.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Unfinished.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/lifecycle/Unfinished.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/lifecycle/Unfinished.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/AbstractPcodeMachine.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/AbstractPcodeMachine.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/AbstractPcodeMachine.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/AbstractPcodeMachine.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/BytesPcodeThread.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/BytesPcodeThread.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/BytesPcodeThread.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/BytesPcodeThread.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/DefaultPcodeThread.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/DefaultPcodeThread.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/DefaultPcodeThread.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/DefaultPcodeThread.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/InstructionDecoder.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/InstructionDecoder.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/InstructionDecoder.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/InstructionDecoder.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/ModifiedPcodeThread.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/ModifiedPcodeThread.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/ModifiedPcodeThread.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/ModifiedPcodeThread.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeEmulator.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeEmulator.java
similarity index 97%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeEmulator.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeEmulator.java
index b0011f5493..34069f1c90 100644
--- a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeEmulator.java
+++ b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeEmulator.java
@@ -18,7 +18,6 @@ package ghidra.pcode.emu;
import java.util.List;
import ghidra.pcode.emu.auxiliary.AuxPcodeEmulator;
-import ghidra.pcode.emu.sys.EmuSyscallLibrary;
import ghidra.pcode.exec.*;
import ghidra.program.model.address.Address;
import ghidra.program.model.lang.Language;
@@ -96,8 +95,8 @@ import ghidra.program.model.lang.Language;
* The default userop library is empty. For many use cases, it will be necessary to override
* {@link #createUseropLibrary()} if only to implement the language-defined userops. If needed,
* simulation of the host operating system is typically achieved by implementing the {@code syscall}
- * userop. The fidelity of that simulation depends on the use case. See {@link EmuSyscallLibrary}
- * and its implementations to see what simulators are available "out of the box."
+ * userop. The fidelity of that simulation depends on the use case. See the SystemEmulation module
+ * to see what simulators are available "out of the box."
*
* <p>
* Alternatively, if the target program never invokes system calls directly, but rather via
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeMachine.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeMachine.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeMachine.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeMachine.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeStateInitializer.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeStateInitializer.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeStateInitializer.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeStateInitializer.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeThread.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeThread.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/PcodeThread.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/PcodeThread.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/SleighInstructionDecoder.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/SleighInstructionDecoder.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/SleighInstructionDecoder.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/SleighInstructionDecoder.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/SparseAddressRangeMap.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/SparseAddressRangeMap.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/SparseAddressRangeMap.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/SparseAddressRangeMap.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/ThreadPcodeExecutorState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/ThreadPcodeExecutorState.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/ThreadPcodeExecutorState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/ThreadPcodeExecutorState.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/auxiliary/AuxEmulatorPartsFactory.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/auxiliary/AuxEmulatorPartsFactory.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/auxiliary/AuxEmulatorPartsFactory.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/auxiliary/AuxEmulatorPartsFactory.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeEmulator.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeEmulator.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeEmulator.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeEmulator.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeThread.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeThread.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeThread.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/emu/auxiliary/AuxPcodeThread.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AbstractBytesPcodeExecutorStatePiece.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractBytesPcodeExecutorStatePiece.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AbstractBytesPcodeExecutorStatePiece.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractBytesPcodeExecutorStatePiece.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AbstractLongOffsetPcodeExecutorStatePiece.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AccessPcodeExecutionException.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AccessPcodeExecutionException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AccessPcodeExecutionException.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AccessPcodeExecutionException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AddressesReadPcodeArithmetic.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AddressesReadPcodeArithmetic.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AddressesReadPcodeArithmetic.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AddressesReadPcodeArithmetic.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibrary.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibrary.java
similarity index 99%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibrary.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibrary.java
index 944be75ddd..dd3fd1cf8e 100644
--- a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibrary.java
+++ b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibrary.java
@@ -26,7 +26,6 @@ import java.util.stream.Stream;
import org.apache.commons.lang3.reflect.TypeUtils;
-import ghidra.pcode.emu.linux.EmuLinuxAmd64SyscallUseropLibrary;
import ghidra.pcode.exec.PcodeExecutorStatePiece.Reason;
import ghidra.program.model.pcode.Varnode;
import utilities.util.AnnotationUtilities;
@@ -35,8 +34,7 @@ import utilities.util.AnnotationUtilities;
* A userop library wherein Java methods are exported via a special annotation
*
* <p>
- * See {@code StandAloneEmuExampleScript} for an example of implementing a userop library. A more
- * complex example is {@link EmuLinuxAmd64SyscallUseropLibrary}.
+ * See {@code StandAloneEmuExampleScript} for an example of implementing a userop library.
*
* @param <T> the type of data processed by the library
*/
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeArithmetic.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeArithmetic.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeArithmetic.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeArithmetic.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorState.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorState.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStatePiece.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStatePiece.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStatePiece.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStatePiece.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStateSpace.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStateSpace.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStateSpace.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/BytesPcodeExecutorStateSpace.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/ComposedPcodeUseropLibrary.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/ComposedPcodeUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/ComposedPcodeUseropLibrary.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/ComposedPcodeUseropLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/ConcretionError.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/ConcretionError.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/ConcretionError.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/ConcretionError.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/DefaultPcodeExecutorState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/DefaultPcodeExecutorState.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/DefaultPcodeExecutorState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/DefaultPcodeExecutorState.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/InjectionErrorPcodeExecutionException.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/InjectionErrorPcodeExecutionException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/InjectionErrorPcodeExecutionException.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/InjectionErrorPcodeExecutionException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/InterruptPcodeExecutionException.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/InterruptPcodeExecutionException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/InterruptPcodeExecutionException.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/InterruptPcodeExecutionException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/LocationPcodeArithmetic.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/LocationPcodeArithmetic.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/LocationPcodeArithmetic.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/LocationPcodeArithmetic.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/LocationPcodeExecutorStatePiece.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/LocationPcodeExecutorStatePiece.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/LocationPcodeExecutorStatePiece.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/LocationPcodeExecutorStatePiece.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PairedPcodeArithmetic.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PairedPcodeArithmetic.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PairedPcodeArithmetic.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PairedPcodeArithmetic.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorState.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorState.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorStatePiece.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorStatePiece.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorStatePiece.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PairedPcodeExecutorStatePiece.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeArithmetic.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeArithmetic.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeArithmetic.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeArithmetic.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutionException.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutionException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutionException.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutionException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutor.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutor.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutor.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutor.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutorState.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutorState.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutorState.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutorState.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutorStatePiece.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutorStatePiece.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExecutorStatePiece.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExecutorStatePiece.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExpression.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExpression.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeExpression.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeExpression.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeFrame.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeFrame.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeFrame.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeFrame.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeProgram.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeProgram.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeProgram.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeProgram.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeUseropLibrary.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeUseropLibrary.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/PcodeUseropLibrary.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/PcodeUseropLibrary.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighLinkException.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighLinkException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighLinkException.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighLinkException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighPcodeUseropDefinition.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighPcodeUseropDefinition.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighPcodeUseropDefinition.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighPcodeUseropDefinition.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighProgramCompiler.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighProgramCompiler.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighProgramCompiler.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighProgramCompiler.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighUtils.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighUtils.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SleighUtils.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SleighUtils.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SuspendedPcodeExecutionException.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SuspendedPcodeExecutionException.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/SuspendedPcodeExecutionException.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/SuspendedPcodeExecutionException.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/ValueLocation.java b/Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/ValueLocation.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/pcode/exec/ValueLocation.java
rename to Ghidra/Framework/Emulation/src/main/java/ghidra/pcode/exec/ValueLocation.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/utilities/util/AnnotationUtilities.java b/Ghidra/Framework/Emulation/src/main/java/utilities/util/AnnotationUtilities.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/utilities/util/AnnotationUtilities.java
rename to Ghidra/Framework/Emulation/src/main/java/utilities/util/AnnotationUtilities.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/generic/ULongSpanTest.java b/Ghidra/Framework/Emulation/src/test/java/generic/ULongSpanTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/generic/ULongSpanTest.java
rename to Ghidra/Framework/Emulation/src/test/java/generic/ULongSpanTest.java
diff --git a/Ghidra/Framework/Emulation/src/test/java/ghidra/app/plugin/processors/sleigh/SleighLanguageHelper.java b/Ghidra/Framework/Emulation/src/test/java/ghidra/app/plugin/processors/sleigh/SleighLanguageHelper.java
new file mode 100644
index 0000000000..3945a684bb
--- /dev/null
+++ b/Ghidra/Framework/Emulation/src/test/java/ghidra/app/plugin/processors/sleigh/SleighLanguageHelper.java
@@ -0,0 +1,63 @@
+/* ###
+ * IP: GHIDRA
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package ghidra.app.plugin.processors.sleigh;
+
+import java.io.IOException;
+import java.util.*;
+
+import org.xml.sax.SAXException;
+
+import generic.jar.ResourceFile;
+import ghidra.program.model.lang.*;
+import resources.ResourceManager;
+
+public class SleighLanguageHelper {
+ public static SleighLanguage getMockBE64Language()
+ throws UnknownInstructionException, SAXException, IOException {
+
+ ResourceFile cSpecFile =
+ new ResourceFile(ResourceManager.getResource("mock.cspec").getPath());
+ CompilerSpecDescription cSpecDesc =
+ new SleighCompilerSpecDescription(new CompilerSpecID("default"), "default", cSpecFile);
+
+ ResourceFile lDefsFile =
+ new ResourceFile(ResourceManager.getResource("mock.ldefs").getPath());
+ ResourceFile pSpecFile =
+ new ResourceFile(ResourceManager.getResource("mock.pspec").getPath());
+ ResourceFile slaFile =
+ new ResourceFile(ResourceManager.getResource("mock.sla").getPath());
+ SleighLanguageDescription langDesc = new SleighLanguageDescription(
+ new LanguageID("Mock:BE:64:default"),
+ "Mock language (64-bit BE)",
+ Processor.findOrPossiblyCreateProcessor("Mock"),
+ Endian.BIG, // endian
+ Endian.BIG, // instructionEndian
+ 64,
+ "default", // variant
+ 0, // major version
+ 0, // minor version
+ false, // deprecated
+ new HashMap<>(), // truncatedSpaceMap
+ new ArrayList<>(List.of(cSpecDesc)),
+ new HashMap<>() // externalNames
+ );
+ langDesc.setDefsFile(lDefsFile);
+ langDesc.setSpecFile(pSpecFile);
+ langDesc.setSlaFile(slaFile);
+
+ return new SleighLanguage(langDesc);
+ }
+}
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/generic/util/datastruct/SemisparseByteArrayTest.java b/Ghidra/Framework/Emulation/src/test/java/ghidra/generic/util/datastruct/SemisparseByteArrayTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/generic/util/datastruct/SemisparseByteArrayTest.java
rename to Ghidra/Framework/Emulation/src/test/java/ghidra/generic/util/datastruct/SemisparseByteArrayTest.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/SparseAddressRangeMapTest.java b/Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/emu/SparseAddressRangeMapTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/emu/SparseAddressRangeMapTest.java
rename to Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/emu/SparseAddressRangeMapTest.java
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibraryTest.java b/Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibraryTest.java
similarity index 93%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibraryTest.java
rename to Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibraryTest.java
index 690c60e698..230fbeb7c0 100644
--- a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibraryTest.java
+++ b/Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/AnnotatedPcodeUseropLibraryTest.java
@@ -18,21 +18,24 @@ package ghidra.pcode.exec;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
+import java.io.*;
import java.lang.invoke.MethodHandles;
import java.lang.invoke.MethodHandles.Lookup;
+import org.junit.Before;
import org.junit.Test;
-import ghidra.app.plugin.processors.sleigh.SleighException;
-import ghidra.app.plugin.processors.sleigh.SleighLanguage;
+import generic.test.AbstractGTest;
+import ghidra.GhidraTestApplicationLayout;
+import ghidra.app.plugin.processors.sleigh.*;
+import ghidra.framework.Application;
+import ghidra.framework.ApplicationConfiguration;
import ghidra.pcode.exec.PcodeExecutorStatePiece.Reason;
import ghidra.pcode.utils.Utils;
-import ghidra.program.model.lang.LanguageID;
import ghidra.program.model.lang.Register;
import ghidra.program.model.pcode.Varnode;
-import ghidra.test.AbstractGhidraHeadlessIntegrationTest;
-public class AnnotatedPcodeUseropLibraryTest extends AbstractGhidraHeadlessIntegrationTest {
+public class AnnotatedPcodeUseropLibraryTest extends AbstractGTest {
private class TestUseropLibrary extends AnnotatedPcodeUseropLibrary<byte[]> {
@Override
protected Lookup getMethodLookup() {
@@ -40,13 +43,20 @@ public class AnnotatedPcodeUseropLibraryTest extends AbstractGhidraHeadlessInteg
}
}
+ @Before
+ public void setUp() throws IOException {
+ if (!Application.isInitialized()) {
+ Application.initializeApplication(
+ new GhidraTestApplicationLayout(new File(getTestDirectoryPath())),
+ new ApplicationConfiguration());
+ }
+ }
+
protected PcodeExecutor<byte[]> createBytesExecutor() throws Exception {
- return createBytesExecutor("Toy:BE:64:default");
+ return createBytesExecutor(SleighLanguageHelper.getMockBE64Language());
}
- protected PcodeExecutor<byte[]> createBytesExecutor(String languageId) throws Exception {
- SleighLanguage language =
- (SleighLanguage) getLanguageService().getLanguage(new LanguageID(languageId));
+ protected PcodeExecutor<byte[]> createBytesExecutor(SleighLanguage language) throws Exception {
PcodeExecutorState<byte[]> state = new BytesPcodeExecutorState(language);
PcodeArithmetic<byte[]> arithmetic = BytesPcodeArithmetic.forLanguage(language);
return new PcodeExecutor<>(language, arithmetic, state, Reason.EXECUTE);
@@ -54,8 +64,9 @@ public class AnnotatedPcodeUseropLibraryTest extends AbstractGhidraHeadlessInteg
protected <T> void executeSleigh(PcodeExecutor<T> executor, PcodeUseropLibrary<T> library,
String source) {
- PcodeProgram program = SleighProgramCompiler.compileProgram(executor.getLanguage(), "test",
- source, library);
+ PcodeProgram program =
+ SleighProgramCompiler.compileProgram(executor.getLanguage(), getName(),
+ source, library);
executor.execute(program, library);
}
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/PcodeFrameTest.java b/Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/PcodeFrameTest.java
similarity index 83%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/PcodeFrameTest.java
rename to Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/PcodeFrameTest.java
index c54d1dd2b5..ec8cb09f69 100644
--- a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/PcodeFrameTest.java
+++ b/Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/PcodeFrameTest.java
@@ -17,14 +17,19 @@ package ghidra.pcode.exec;
import static org.junit.Assert.assertEquals;
+import java.io.File;
+
import org.junit.Before;
import org.junit.Test;
+import generic.test.AbstractGTest;
+import ghidra.GhidraTestApplicationLayout;
import ghidra.app.plugin.processors.sleigh.SleighLanguage;
-import ghidra.program.model.lang.LanguageID;
-import ghidra.test.AbstractGhidraHeadlessIntegrationTest;
+import ghidra.app.plugin.processors.sleigh.SleighLanguageHelper;
+import ghidra.framework.Application;
+import ghidra.framework.ApplicationConfiguration;
-public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
+public class PcodeFrameTest extends AbstractGTest {
static final String SAMPLE_ADD = """
r0 = r0 + r1;
""";
@@ -65,12 +70,16 @@ public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
@Before
public void setUp() throws Exception {
- language =
- (SleighLanguage) getLanguageService().getLanguage(new LanguageID("Toy:BE:64:default"));
+ if (!Application.isInitialized()) {
+ Application.initializeApplication(
+ new GhidraTestApplicationLayout(new File(getTestDirectoryPath())),
+ new ApplicationConfiguration());
+ }
+ language = SleighLanguageHelper.getMockBE64Language();
}
private PcodeProgram compile(String sample) {
- return SleighProgramCompiler.compileProgram(language, getName(), sample, library);
+ return SleighProgramCompiler.compileProgram(language, "test", sample, library);
}
private PcodeFrame frame(String sample) {
@@ -93,8 +102,8 @@ public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
PcodeProgram program = compile(SAMPLE_ADD2);
assertEquals("""
<PcodeProgram:
- $U2000:8 = INT_ADD r0, r1
- r0 = INT_ADD $U2000:8, r2
+ $U200:8 = INT_ADD r0, r1
+ r0 = INT_ADD $U200:8, r2
>""",
program.toString());
}
@@ -104,8 +113,8 @@ public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
PcodeProgram program = compile(SAMPLE_IF);
assertEquals("""
<PcodeProgram:
- $U2000:1 = INT_EQUAL r0, r1
- CBRANCH <0>, $U2000:1
+ $U200:1 = INT_EQUAL r0, r1
+ CBRANCH <0>, $U200:1
r2 = INT_ADD r2, 1:8
<0>
>""",
@@ -119,8 +128,8 @@ public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
<PcodeProgram:
<0>
r0 = INT_ADD r0, 1:8
- $U2080:1 = INT_EQUAL r0, r1
- CBRANCH <0>, $U2080:1
+ $U280:1 = INT_EQUAL r0, r1
+ CBRANCH <0>, $U280:1
>""",
program.toString());
}
@@ -178,8 +187,8 @@ public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
PcodeFrame frame = frame(SAMPLE_IF);
assertEquals("""
<p-code frame: index=0 {
- -> $U2000:1 = INT_EQUAL r0, r1
- CBRANCH <0>, $U2000:1
+ -> $U200:1 = INT_EQUAL r0, r1
+ CBRANCH <0>, $U200:1
r2 = INT_ADD r2, 1:8
<0>
}>""",
@@ -190,8 +199,8 @@ public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
frame.advance();
assertEquals("""
<p-code frame: index=3 {
- $U2000:1 = INT_EQUAL r0, r1
- CBRANCH <0>, $U2000:1
+ $U200:1 = INT_EQUAL r0, r1
+ CBRANCH <0>, $U200:1
r2 = INT_ADD r2, 1:8
<0>
*> fall-through
@@ -206,8 +215,8 @@ public class PcodeFrameTest extends AbstractGhidraHeadlessIntegrationTest {
<p-code frame: index=0 {
<0>
-> r0 = INT_ADD r0, 1:8
- $U2080:1 = INT_EQUAL r0, r1
- CBRANCH <0>, $U2080:1
+ $U280:1 = INT_EQUAL r0, r1
+ CBRANCH <0>, $U280:1
}>""",
frame.toString());
}
diff --git a/Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/SleighUtilsTest.java b/Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/SleighUtilsTest.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/test/java/ghidra/pcode/exec/SleighUtilsTest.java
rename to Ghidra/Framework/Emulation/src/test/java/ghidra/pcode/exec/SleighUtilsTest.java
diff --git a/Ghidra/Framework/Emulation/src/test/resources/mock.cspec b/Ghidra/Framework/Emulation/src/test/resources/mock.cspec
new file mode 100644
index 0000000000..e69de29bb2
diff --git a/Ghidra/Framework/Emulation/src/test/resources/mock.ldefs b/Ghidra/Framework/Emulation/src/test/resources/mock.ldefs
new file mode 100644
index 0000000000..e69de29bb2
diff --git a/Ghidra/Framework/Emulation/src/test/resources/mock.pspec b/Ghidra/Framework/Emulation/src/test/resources/mock.pspec
new file mode 100644
index 0000000000..be3ce4f3a4
--- /dev/null
+++ b/Ghidra/Framework/Emulation/src/test/resources/mock.pspec
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<processor_spec>
+</processor_spec>
+
diff --git a/Ghidra/Framework/Emulation/src/test/resources/mock.slaspec b/Ghidra/Framework/Emulation/src/test/resources/mock.slaspec
new file mode 100644
index 0000000000..5596dc9500
--- /dev/null
+++ b/Ghidra/Framework/Emulation/src/test/resources/mock.slaspec
@@ -0,0 +1,37 @@
+@define ENDIAN "big"
+
+@define RAMSIZE "8"
+
+define endian = $(ENDIAN);
+
+define alignment = 1;
+
+define space ram type=ram_space size=8 default;
+
+define space register type=register_space size=4;
+
+# # # # # # # # # # # # # # # # # # # # # # # # # # # #
+# AT LEAST ONE REGISTER, AND STACK POINTER ARE REQUIRED
+# # # # # # # # # # # # # # # # # # # # # # # # # # # #
+
+define register offset=0x0 size=8 [ sp r0 r1 r2 r3 r4 r5 r6 r7 ];
+
+# Define context bits
+define register offset=0x100 size=4 contextreg;
+
+define context contextreg
+ test=(0,0)
+;
+
+
+define pcodeop pcodeop_one;
+define pcodeop pcodeop_two;
+define pcodeop pcodeop_three;
+
+# # # # # # # # # # # # # # # # # # # # # # # # # # # #
+# AT LEAST ONE INSTRUCTION IS REQUIRED
+# # # # # # # # # # # # # # # # # # # # # # # # # # # #
+
+:nop is test=1 unimpl
+
+# # # # # # # # # # # # # # # # # # # # # # # # # # # #
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/program/model/mem/MemBufferAdapter.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/mem/MemBufferAdapter.java
similarity index 100%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/program/model/mem/MemBufferAdapter.java
rename to Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/mem/MemBufferAdapter.java
diff --git a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/util/database/UndoableTransaction.java b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/util/database/UndoableTransaction.java
similarity index 98%
rename from Ghidra/Debug/ProposedUtils/src/main/java/ghidra/util/database/UndoableTransaction.java
rename to Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/util/database/UndoableTransaction.java
index 6c43edc230..92bd08a97e 100644
--- a/Ghidra/Debug/ProposedUtils/src/main/java/ghidra/util/database/UndoableTransaction.java
+++ b/Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/util/database/UndoableTransaction.java
@@ -48,7 +48,7 @@ import ghidra.util.Msg;
* Can be expressed using an undoable transaction instead:
*
* <pre>
- * try (UndoableTransaction txid = UndoableTransaction.start(program, "Do a thing", true)) {
+ * try (UndoableTransaction txid = UndoableTransaction.start(program, "Do a thing")) {
* // ... Do that thing
* }
* </pre>
@@ -88,7 +88,6 @@ public interface UndoableTransaction extends AutoCloseable {
* @param domainObject the domain object
* @param description a description of the change
* @param listener a listener for aborted transactions
- * @param commitByDefault true to commit at the end of the block
* @return the transaction handle
*/
public static UndoableTransaction start(UndoableDomainObject domainObject, String description,
@@ -102,7 +101,6 @@ public interface UndoableTransaction extends AutoCloseable {
*
* @param dataTypeManager the data type manager
* @param description a description of the change
- * @param commitByDefault true to commit at the end of the block
* @return the transaction handle
*/
public static UndoableTransaction start(DataTypeManager dataTypeManager, String description) {