Lines Matching refs:ABFD
95 #define COFF0_P(ABFD) (bfd_coff_filhsz(ABFD) == FILHSZ_V0) argument
96 #define COFF2_P(ABFD) (bfd_coff_scnhsz(ABFD) != SCNHSZ_V01) argument
225 #define GET_SCNHDR_NRELOC(ABFD, LOC) \ argument
226 (COFF2_P (ABFD) ? H_GET_32 (ABFD, LOC) : H_GET_16 (ABFD, LOC))
227 #define PUT_SCNHDR_NRELOC(ABFD, VAL, LOC) \ argument
228 (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, LOC) : H_PUT_16 (ABFD, VAL, LOC))
230 #define GET_SCNHDR_NLNNO(ABFD, LOC) \ argument
234 if (COFF2_P (ABFD)) \
235 nlnno = H_GET_32 (ABFD, ptr); \
237 nlnno = H_GET_16 (ABFD, ptr - 2); \
240 #define PUT_SCNHDR_NLNNO(ABFD, VAL, LOC) \ argument
244 if (COFF2_P (ABFD)) \
245 H_PUT_32 (ABFD, VAL, ptr); \
247 H_PUT_16 (ABFD, VAL, ptr - 2); \
250 #define GET_SCNHDR_FLAGS(ABFD, LOC) \ argument
254 if (COFF2_P (ABFD)) \
255 flags = H_GET_32 (ABFD, ptr); \
257 flags = H_GET_16 (ABFD, ptr - 4); \
260 #define PUT_SCNHDR_FLAGS(ABFD, VAL, LOC) \ argument
264 if (COFF2_P (ABFD)) \
265 H_PUT_32 (ABFD, VAL, ptr); \
267 H_PUT_16 (ABFD, VAL, ptr - 4); \
270 #define GET_SCNHDR_PAGE(ABFD, LOC) \ argument
274 if (COFF2_P (ABFD)) \
275 page = H_GET_16 (ABFD, ptr); \
277 page = (unsigned) H_GET_8 (ABFD, ptr - 7); \
281 #define PUT_SCNHDR_PAGE(ABFD, VAL, LOC) \ argument
285 if (COFF2_P (ABFD)) \
286 H_PUT_16 (ABFD, VAL, ptr); \
289 H_PUT_8 (ABFD, VAL, ptr - 7); \
290 H_PUT_8 (ABFD, 0, ptr - 8); \
295 #define GET_SCNHDR_NLNNO(ABFD, LOC) \ argument
296 (COFF2_P (ABFD) ? H_GET_32 (ABFD, LOC) : H_GET_16 (ABFD, (LOC) - 2))
297 #define PUT_SCNHDR_NLNNO(ABFD, VAL, LOC) \ argument
298 (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, LOC) : H_PUT_16 (ABFD, VAL, (LOC) - 2))
299 #define GET_SCNHDR_FLAGS(ABFD, LOC) \ argument
300 (COFF2_P (ABFD) ? H_GET_32 (ABFD, LOC) : H_GET_16 (ABFD, (LOC) - 4))
301 #define PUT_SCNHDR_FLAGS(ABFD, VAL, LOC) \ argument
302 (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, LOC) : H_PUT_16 (ABFD, VAL, (LOC) - 4))
303 #define GET_SCNHDR_PAGE(ABFD, LOC) \ argument
304 (COFF2_P (ABFD) ? H_GET_16 (ABFD, LOC) : (unsigned) H_GET_8 (ABFD, (LOC) - 7))
306 #define PUT_SCNHDR_PAGE(ABFD, VAL, LOC) \ argument
307 (COFF2_P (ABFD) \
308 ? H_PUT_16 (ABFD, VAL, LOC) \
309 : H_PUT_8 (ABFD, VAL, (LOC) - 7), H_PUT_8 (ABFD, 0, (LOC) - 8))
315 #define GET_SCNHDR_SIZE(ABFD, SZP) \ argument
316 (H_GET_32 (ABFD, SZP) * bfd_octets_per_byte (ABFD))
317 #define PUT_SCNHDR_SIZE(ABFD, SZ, SZP) \ argument
318 H_PUT_32 (ABFD, (SZ) / bfd_octets_per_byte (ABFD), SZP)
320 #define COFF_ADJUST_SCNHDR_IN_POST(ABFD, EXT, INT) \ argument
324 GET_SCNHDR_PAGE (ABFD, ((SCNHDR *)(EXT))->s_page); \
330 #define COFF_ADJUST_SCNHDR_OUT_PRE(ABFD, INT, EXT) \ argument
342 #define COFF_ADJUST_SCNHDR_OUT_POST(ABFD, INT, EXT) \ argument
345 PUT_SCNHDR_NLNNO (ABFD, ((struct internal_scnhdr *)(INT))->s_nlnno, \
347 PUT_SCNHDR_NRELOC (ABFD, ((struct internal_scnhdr *)(INT))->s_nreloc,\
349 PUT_SCNHDR_FLAGS (ABFD, ((struct internal_scnhdr *)(INT))->s_flags, \
351 PUT_SCNHDR_PAGE (ABFD, ((struct internal_scnhdr *)(INT))->s_page, \
473 #define GET_SCN_SCNLEN(ABFD, EXT) \ argument
474 (H_GET_32 (ABFD, (EXT)->x_scn.x_scnlen) * bfd_octets_per_byte (ABFD))
475 #define PUT_SCN_SCNLEN(ABFD, INT, EXT) \ argument
476 H_PUT_32 (ABFD, (INT) / bfd_octets_per_byte (ABFD), (EXT)->x_scn.x_scnlen)
493 #define COFF_ADJUST_SYM_IN_POST(ABFD, EXT, INT) \ argument
506 #define COFF_ADJUST_SYM_OUT_POST(ABFD, INT, EXT) \ argument