Re: Page layout footprint

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: Page layout footprint
Дата
Msg-id 48C10596.7060205@enterprisedb.com
обсуждение исходный текст
Ответ на Re: Page layout footprint  (Zdenek Kotala <Zdenek.Kotala@Sun.COM>)
Ответы Re: Page layout footprint
Список pgsql-hackers
Zdenek Kotala wrote:
> Heikki Linnakangas napsal(a):
>> I'm afraid I still fail to see the usefulness of this. gdb knows how 
>> to deal with structs,
> 
> If I correct that GDB knows structure only if you have debug version. 
> But usually you don't have debug version on production system. 

Using gdb without debug systems is pretty much a lost cause anyway.

> And 
> another small advantage is that --footprint switch is easy to use. It is 
> easier that work with gdb and you can easy get info from users who are 
> not familiar with gdb.

AFAICS you can get all the same information from pg_controldata. We have 
a pretty good idea of the alignments of all the usual platforms anyway. 
If someone says in a bug report that they're running on x86_64 or 32-bit 
Sparc, we know what the alignments on those platforms are.

>> And if you're working at such a low level, it's not that hard to 
>> calculate the offsets within the struct manually.
> 
> I'm not sure if it is so easy. Are you able do it for SPARC, PPC or 
> other non x86 CPUs?

Not off the top of my head. But I am able to do it on x86 and x86_64 
which are the platforms I work and debug on.

>> If we needed more information about the architectures, we could just 
>> collect the output of pg_controldata. But I think the configure logs 
>> already contains all the useful information.
> 
> It seems to be good idea. Only what we need is extend buildfarm to parse 
> config.log and shows this data for each build machine. 

Well, the information is already there. I'm not convinced it's such an 
important issue that it's worth the effort to add special handling to 
extract that information from the log. Of course, if someone feels 
otherwise and does it, I won't object.

> It could also report changes in alignment.

Huh? I would be pretty surprised if the alignment changed randomly on 
some platform.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Zdenek Kotala
Дата:
Сообщение: Re: Page layout footprint
Следующее
От: Simon Riggs
Дата:
Сообщение: Re: For what should pg_stop_backup wait?