Re: Printing bitmap objects in the debugger

Поиск
Список
Период
Сортировка
От Pavan Deolasee
Тема Re: Printing bitmap objects in the debugger
Дата
Msg-id CABOikdPyW+0Fi9VHE1Q5ivhrfVpgK4d_abAr=s+bmv-OSk2uCw@mail.gmail.com
обсуждение исходный текст
Ответ на Printing bitmap objects in the debugger  (Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>)
Ответы Re: Printing bitmap objects in the debugger  (Pavan Deolasee <pavan.deolasee@gmail.com>)
Список pgsql-hackers


On Wed, Sep 14, 2016 at 3:43 PM, Ashutosh Bapat <ashutosh.bapat@enterprisedb.com> wrote:
Hi All,
While working on partition-wise join, I had to examine Relids objects
many times. Printing the Bitmapset::words[] in binary format and then
inferring the relids takes time and is error prone. Instead I wrote a
function bms_to_char() which allocates a StringInfo, calls
outBitmapset() to decode Bitmapset as a set of integers and returns
the string. In order to examine a Relids object all one has to do is
execute 'p bms_to_char(bms_object) under gdb.


Can we not do this as gdb macros? My knowledge is rusty in this area and lately I'm using LVM debugger (which probably does not have something equivalent), but I believe gdb allows you to write useful macros. As a bonus, you can then use them even for inspecting core files.

Thanks,
Pavan 

--
 Pavan Deolasee                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services

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

Предыдущее
От: Julien Rouhaud
Дата:
Сообщение: Re: [PATCH] SortSupport for macaddr type
Следующее
От: valeriof
Дата:
Сообщение: Error running custom plugin: “output plugins have to declare the _PG_output_plugin_init symbol”