Re: pgindent weirdnessf

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: pgindent weirdnessf
Date: 2011-04-20 15:48:49
Message-ID: 201104201548.p3KFmnA17137@momjian.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andrew Dunstan wrote:
> It's tagged as a structure type by objdump, but not as a typedef:
>
> <1><40055>: Abbrev Number: 4 (DW_TAG_typedef)
> <40056> DW_AT_name : (indirect string, offset: 0x6bf6):
> BulkInsertState
> <4005a> DW_AT_decl_file : 30
> <4005b> DW_AT_decl_line : 32
> <4005c> DW_AT_type : <0x40060>
> <1><40060>: Abbrev Number: 7 (DW_TAG_pointer_type)
> <40061> DW_AT_byte_size : 8
> <40062> DW_AT_type : <0x40066>
> <1><40066>: Abbrev Number: 13 (DW_TAG_structure_type)
> <40067> DW_AT_name : (indirect string, offset: 0x66bf):
> BulkInsertStateData
> <4006b> DW_AT_byte_size : 16
> <4006c> DW_AT_decl_file : 31
> <4006d> DW_AT_decl_line : 30
> <4006e> DW_AT_sibling : <0x4008b>
>
> I can pull out those too if you want them in the list, but it would
> possibly add a LOT of names to the list.
>
> I did carefully warn you about the need to check the effects of the
> changes when I committed the new list.
>
> It looks like quite a few of the deletions come into this category, for
> example just looking at the diff here
> <https://github.com/postgres/postgres/commit/fe1438da8aa8a45f2cee816eb54841f97d3b2f22#src/tools/pgindent/typedefs.list>
> I see AggHashEntryData, AggStatePerAggData, AllocBlockData, and
> AllocChunkData from among the first few that were deleted and all are in
> the same category.
>
> I wondered if this is some sort of optimizer effect, but building with
> -O0 doesn't seem to affect it.

I assume you are using -g, right?

The BulkInsertStateData typedef looks pretty normal:

typedef struct BulkInsertStateData
{
BufferAccessStrategy strategy; /* our BULKWRITE strategy object */
Buffer current_buf; /* current insertion target page */
} BulkInsertStateData;

I tested my BSD machine using src/tools/find_typedefs and it does show
BulkInsertStateData.

--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ It's impossible for everything to be true. +

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2011-04-20 15:50:59 Re: pgindent weirdness
Previous Message Greg Stark 2011-04-20 15:45:37 Re: REINDEX vs broken HOT chains, redux