// // Copyright (c) rev.ng Srls. See LICENSE.md for details. // #include "revng-c/Decompiler/DLAPass.h" #include "DLAStep.h" #include "DLATypeSystem.h" char DLAPass::ID = 0; using Register = llvm::RegisterPass; static Register X("dla", "Data Layout Analysis Pass", false, false); bool DLAPass::runOnModule(llvm::Module &M) { dla::StepManager SM; // Front-end Steps, that create initial nodes and edges revng_check(SM.addStep()); revng_check(SM.addStep()); // Middle-end Steps, that manipulate nodes and edges revng_check(SM.addStep()); revng_check(SM.addStep()); revng_check(SM.addStep()); revng_check(SM.addStep()); revng_check(SM.addStep()); // Back-end Steps, that build Layouts from LayoutTypeSystem nodes revng_check(SM.addStep()); revng_check(SM.addStep()); dla::LayoutTypeSystem TS(M); SM.run(TS); return true; }