Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

decompiler: fix loops with shifted structure offset #6718

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file not shown.
Binary file not shown.
Binary file not shown.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
PlatformToolSet=v143:VCToolArchitecture=Native64Bit:VCToolsVersion=14.41.34120:TargetPlatformVersion=10.0.22621.0:
Debug|x64|D:\Downloads\ghidrafork\ghidra\Ghidra\Features\Decompiler\Ghidra Decompiler New\|
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
^D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\ACTION.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\ADDRESS.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\ARCHITECTURE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\BLOCK.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\BLOCKACTION.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\CAPABILITY.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\CAST.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\COMMENT.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\COMMENT_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\CONDEXE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\CONSTSEQ.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\COREACTION.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\COVER.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\CPOOL.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\CPOOL_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\CRC32.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\DATABASE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\DATABASE_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\DOUBLE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\DYNAMIC.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\EMULATE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\EMULATEUTIL.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\FLOAT.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\FLOW.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\FSPEC.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\FUNCDATA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\FUNCDATA_BLOCK.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\FUNCDATA_OP.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\FUNCDATA_VARNODE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\GHIDRA_ARCH.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\GHIDRA_CONTEXT.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\GHIDRA_PROCESS.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\GHIDRA_TRANSLATE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\GLOBALCONTEXT.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\GRAPH.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\HERITAGE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\INJECT_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\JUMPTABLE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\LOADIMAGE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\LOADIMAGE_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\MARSHAL.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\MEMSTATE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\MERGE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\MODELRULES.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\MULTIPRECISION.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\OP.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\OPBEHAVIOR.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\OPCODES.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\OPTIONS.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\OVERRIDE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PARAMID.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PCODEINJECT.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PCODERAW.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PREFERSPLIT.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PRETTYPRINT.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PRINTC.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PRINTJAVA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\PRINTLANGUAGE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\RANGEUTIL.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\RULEACTION.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\SIGNATURE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\SIGNATURE_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\SPACE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\STRINGMANAGE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\STRING_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\SUBFLOW.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\TRANSFORM.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\TRANSLATE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\TYPE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\TYPEGRP_GHIDRA.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\TYPEOP.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\UNIONRESOLVE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\USEROP.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\VARIABLE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\VARMAP.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\VARNODE.OBJ|D:\DOWNLOADS\GHIDRAFORK\GHIDRA\GHIDRA\FEATURES\DECOMPILER\GHIDRA DECOMPILER NEW\GHIDRA D.F8FB6E02\X64\DEBUG\XML.OBJ
D:\Downloads\ghidrafork\ghidra\Ghidra\Features\Decompiler\Ghidra Decompiler New\Ghidra D.f8fb6e02\x64\Debug\Ghidra Decompiler New.ilk
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<Project>
<ProjectOutputs>
<ProjectOutput>
<FullPath>D:\Downloads\ghidrafork\ghidra\Ghidra\Features\Decompiler\Ghidra Decompiler New\x64\Debug\Ghidra Decompiler New.exe</FullPath>
</ProjectOutput>
</ProjectOutputs>
<ContentFiles />
<SatelliteDlls />
<NonRecipeFileRefs />
</Project>
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.10.35027.167
MinimumVisualStudioVersion = 10.0.40219.1
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Ghidra Decompiler New", "Ghidra Decompiler New.vcxproj", "{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
Debug|x86 = Debug|x86
Release|x64 = Release|x64
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Debug|x64.ActiveCfg = Debug|x64
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Debug|x64.Build.0 = Debug|x64
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Debug|x86.ActiveCfg = Debug|Win32
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Debug|x86.Build.0 = Debug|Win32
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Release|x64.ActiveCfg = Release|x64
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Release|x64.Build.0 = Release|x64
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Release|x86.ActiveCfg = Release|Win32
{F8FB6E02-1ABF-45E2-A7D9-2A5FF53B3670}.Release|x86.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {D6B7F69D-46D1-4B33-90F2-245CC3981FE9}
EndGlobalSection
EndGlobal
Loading