generated-offsets-build.h 380 B

12345678910
  1. #ifndef GENERATED_OFFSETS_BUILD_H
  2. #define GENERATED_OFFSETS_BUILD_H
  3. #define DEFINE(name, value) \
  4. __asm__ volatile(".ascii \"GENERATED_INTEGER " #name " %p0 \"\n" ::"i"(value))
  5. #define OFFSET(name, str, member) DEFINE(name, offsetof(struct str, member))
  6. #define OFFSET_T(name, str_t, member) DEFINE(name, offsetof(str_t, member))
  7. #endif /* GENERATED_OFFSETS_BUILD_H */