#pragma once #include #include #include #include #include #include #include #include struct IPIN { std::string symbol; std::size_t local_target; std::size_t field_offset; std::size_t imm_size; }; struct DPIN { struct COMPONENT { std::size_t offset; std::size_t level; std::size_t target; // local pin -> local target }; std::string symbol; std::list components; }; struct FIELD { std::size_t offset; std::size_t size; std::size_t alignment; std::size_t flags; std::size_t idx; }; struct TARGET { std::string name; std::size_t size; std::map fields; }; struct CU { std::unordered_map local_targets; std::unordered_map ipins; std::unordered_map dpins; }; extern std::unordered_map targets; extern std::unordered_map units; bool accumulate(const std::vector& spslr_files, bool no_new_targets); bool dump_target_map(const std::string& path); bool load_target_map(const std::string& path);