#include "gtest/gtest.h"
#include <memory>
#include <vector>
#include "Plugins/UnwindAssembly/x86/x86AssemblyInspectionEngine.h"
#include "lldb/Core/Address.h"
#include "lldb/Core/AddressRange.h"
#include "lldb/Symbol/UnwindPlan.h"
#include "lldb/Utility/ArchSpec.h"
#include "lldb/Utility/StreamString.h"
#include "llvm/Support/TargetSelect.h"
usingnamespacelldb;
usingnamespacelldb_private;
class Testx86AssemblyInspectionEngine : public testing::Test { … };
void Testx86AssemblyInspectionEngine::SetUpTestCase() { … }
const char *x86_64_reg_names[] = …;
enum x86_64_regs { … };
const char *i386_reg_names[] = …;
enum i386_regs { … };
std::unique_ptr<x86AssemblyInspectionEngine> Getx86_64Inspector() { … }
std::unique_ptr<x86AssemblyInspectionEngine> Geti386Inspector() { … }
namespace lldb_private {
static std::ostream &operator<<(std::ostream &OS,
const UnwindPlan::Row::FAValue &CFA) { … }
}
TEST_F(Testx86AssemblyInspectionEngine, TestSimple64bitFrameFunction) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSimple32bitFrameFunction) { … }
TEST_F(Testx86AssemblyInspectionEngine, Test64bitFramelessBigStackFrame) { … }
TEST_F(Testx86AssemblyInspectionEngine, Test32bitFramelessBigStackFrame) { … }
TEST_F(Testx86AssemblyInspectionEngine, Test64bitFramelessSmallStackFrame) { … }
TEST_F(Testx86AssemblyInspectionEngine, Test32bitFramelessSmallStackFrame) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushRBP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushImm) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPush0) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushExtended) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushR15) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushR14) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushR13) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushR12) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushRBX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushEAX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushECX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushEDX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushEBX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushEBP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushRBPWithREX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushESI) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPushEDI) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestMovRSPtoRBP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSubRSP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSubESP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestAddRSP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestAddESP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestLEA_RSP_Pattern) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopRBX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopRBP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopR12) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopR13) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopR14) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopR15) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopEBX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopEBP) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopRBPWithREX) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopESI) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestPopEDI) { … }
TEST_F(Testx86AssemblyInspectionEngine, Testi386IgnoredRegisters) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestLEAVE) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestCALLNextInsn) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSpillRegToStackViaMOVx86_64) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSpillRegToStackViaMOVi386) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSpArithx86_64Augmented) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSimplex86_64Augmented) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestSimplei386ugmented) { … }
TEST_F(Testx86AssemblyInspectionEngine, Test32BitOnlyInstruction) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestStackRealign8BitDisp_i386) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestStackRealign32BitDisp_x86_64) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestStackRealignMSVC_i386) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestDisassemblyJunkBytes) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestReturnDetect) { … }
TEST_F(Testx86AssemblyInspectionEngine, TestDisassemblyMidFunctionEpilogues) { … }