Lines Matching defs:sections
248 set_section (unsigned int *sections, size_t ndx)
250 sections[ndx / WORD_BITS] |= (1U << (ndx % WORD_BITS));
254 get_section (unsigned int *sections, size_t ndx)
256 return (sections[ndx / WORD_BITS] & (1U << (ndx % WORD_BITS))) != 0;
259 /* How many sections are we going to change? */
261 get_sections (unsigned int *sections, size_t shnum)
265 s += __builtin_popcount (sections[i]);
296 /* Which sections match and need to be (un)compressed. */
297 unsigned int *sections = NULL;
299 /* How many sections are we talking about? */
352 /* How many sections are we talking about? */
355 error (0, 0, "Couldn't get number of sections in %s: %s",
362 error (0, 0, "ELF file %s has no sections", fname);
366 sections = xcalloc (shnum / 8 + 1, sizeof (unsigned int));
381 allocated sections in the file. */
384 /* While going through all sections keep track of last section data
397 /* We do three passes over all sections.
400 data needs to be copied and/or transformed, which sections need a
407 Second a collection pass that creates the Elf sections and copies
415 new sizes of the sections if necessary. This pass is optional if
471 set_section (sections, ndx);
520 if (foutput == NULL && get_sections (sections, shnum) == 0)
631 symbol tables. If so, and those sections are to be compressed
646 /* Collection pass. Copy over the sections, (de)compresses matching
647 sections, collect names of sections and symbol table if
658 if (get_section (sections, ndx))
682 data in later passes. Skip those sections for now and
1094 /* Set this after the sections have been created, otherwise section
1119 /* Keep the offset of allocated sections so they are at the
1230 sections precisely as in the original file. In that case we are
1321 free (sections);
1359 .doc = N_("Compress or decompress sections in an ELF file.")