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

SPI not ready for public consumption due to the problem of using dyninst internal #4

Open
tylergu opened this issue Oct 2, 2020 · 0 comments
Labels
future improvement Issues that have a work around right now, but can be better solved in the future

Comments

@tylergu
Copy link
Contributor

tylergu commented Oct 2, 2020

SPI is using one of the dyninst internal header file.

In particular, SPI is using arch-x86.h under common/src. As this file is platform specific, dyninst is not supposed to expose this.

Right now, a custom built dyninst is used. To build this customized dyninst:

  1. Move arch-x86.h from common/src to common/h
  2. Remove the include statement of #include "common/src/Types.h" inside the new arch-x86.h, add include statement to include dyntypes.h, and manually add the missing definitions to arch-x86.h
  3. Add COMMON_EXPORT before class and function names
  4. Change the include statements #include "common/src/arch-x86.h" in other files inside dyninst to #include "arch-x86.h". Current files that need to be changed are:
    • common/src/arch-x86.C
    • common/src/arch.h
    • instructionAPI/src/Instruction.C
    • instructionAPI/src/InstructionDecoder-x86.C
    • instructionAPI/src/Operation.C

A long term solution would be to expose codegenAPI from dyninst, so that SPI can directly use emit-* functions.

@tylergu tylergu added the future improvement Issues that have a work around right now, but can be better solved in the future label Apr 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
future improvement Issues that have a work around right now, but can be better solved in the future
Projects
None yet
Development

No branches or pull requests

1 participant