[llvm-commits] [PATCH 1/5] ELF entry size support.
Daniel Dunbar
daniel at zuster.org
Thu Aug 12 10:38:13 PDT 2010
OK!
- Daniel
On Wed, Aug 11, 2010 at 3:20 PM, Matt Fleming <matt at console-pimps.org> wrote:
> Some ELF sections contain fixed-sized entries. Provide a way to record
> the entry size of a section.
> ---
> include/llvm/MC/MCContext.h | 3 ++-
> include/llvm/MC/MCSectionELF.h | 5 +++++
> 2 files changed, 7 insertions(+), 1 deletions(-)
>
> diff --git a/include/llvm/MC/MCContext.h b/include/llvm/MC/MCContext.h
> index 4db0491..17e79fb 100644
> --- a/include/llvm/MC/MCContext.h
> +++ b/include/llvm/MC/MCContext.h
> @@ -129,7 +129,8 @@ namespace llvm {
>
> const MCSection *getELFSection(StringRef Section, unsigned Type,
> unsigned Flags, SectionKind Kind,
> - bool IsExplicit = false);
> + bool IsExplicit = false,
> + unsigned EntrySize = 0);
>
> const MCSection *getCOFFSection(StringRef Section, unsigned Characteristics,
> int Selection, SectionKind Kind);
> diff --git a/include/llvm/MC/MCSectionELF.h b/include/llvm/MC/MCSectionELF.h
> index 5fe8171..a90aa38 100644
> --- a/include/llvm/MC/MCSectionELF.h
> +++ b/include/llvm/MC/MCSectionELF.h
> @@ -35,6 +35,11 @@ class MCSectionELF : public MCSection {
> /// IsExplicit - Indicates that this section comes from globals with an
> /// explicit section specified.
> bool IsExplicit;
> +
> + /// EntrySize - The size of each entry in this section. This size only
> + /// makes sense for sections that contain fixed-sized entries. If a
> + /// section does not contain fixed-sized entries 'EntrySize' will be 0.
> + unsigned EntrySize;
>
> private:
> friend class MCContext;
> --
> 1.6.4.rc0
>
>
More information about the llvm-commits
mailing list