mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-03 17:59:46 +02:00
GP-1633/GP-2308 Added ProgramArchitecture to datatype managers.
Refactored ProjectDataTypeManager to extend StandaloneDataTypeManager. Added actions to datatype tree to allow setting archive architecture. Added use of storage translators when switching architectures. Allow FunctionDefinition to accept arbitrary calling convention names and many other misc changes.
This commit is contained in:
parent
75a185aa9e
commit
a4776892bd
248 changed files with 6282 additions and 2935 deletions
|
@ -24,9 +24,7 @@ import ghidra.framework.model.*;
|
|||
import ghidra.framework.plugintool.PluginTool;
|
||||
import ghidra.program.model.address.AddressSpace;
|
||||
import ghidra.program.model.data.FunctionDefinitionDataType;
|
||||
import ghidra.program.model.data.GenericCallingConvention;
|
||||
import ghidra.program.model.lang.Language;
|
||||
import ghidra.program.model.lang.Register;
|
||||
import ghidra.program.model.lang.*;
|
||||
import ghidra.program.model.listing.*;
|
||||
import ghidra.program.model.pcode.Varnode;
|
||||
import ghidra.program.model.symbol.SourceType;
|
||||
|
@ -114,7 +112,12 @@ public class UpgradeDexToGhidra71Script extends GhidraScript {
|
|||
private void processFunction(Function func) {
|
||||
monitor.setMessage("Updating: "+func.getName());
|
||||
FunctionDefinitionDataType sig = new FunctionDefinitionDataType(func,false);
|
||||
sig.setGenericCallingConvention(GenericCallingConvention.stdcall);
|
||||
try {
|
||||
sig.setCallingConvention(CompilerSpec.CALLING_CONVENTION_stdcall);
|
||||
}
|
||||
catch (InvalidInputException e) {
|
||||
throw new AssertException(e);
|
||||
}
|
||||
func.setCustomVariableStorage(false);
|
||||
ApplyFunctionSignatureCmd cmd = new ApplyFunctionSignatureCmd(func.getEntryPoint(),sig,SourceType.ANALYSIS);
|
||||
cmd.applyTo(func.getProgram());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue