Re: [HACKERS] Current sources?

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: [HACKERS] Current sources?
Дата
Msg-id 199805250359.XAA24772@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: [HACKERS] Current sources?  (dg@illustra.com (David Gould))
Список pgsql-hackers
> This is a very nice way to do this. In general, if we can count on having
> GCC we should use the GCC inlines.
>
> Hmmmm, on that note, the current sources are factored:
>
>     #if defined(linux)
>         #if defined(x86)
>             // x86 code
>         #else if defined(sparc)
>            // sparc code
>         #endif
>     #else
>         // all non linux
>         ...
>     #endif
>
> I think that the real commonality might better be expressed as:
>
>     #if defined(gcc)
>         // all gcc variants
>     #else
>        // no gcc
>     #endif
>
> As GCC has a unique (but common to gcc!) "asm" facility. This would allow
> all the free unixes and many of the comercial ones to share the same
> asm implementation which should make it easier to get it right on all the
> platforms.
>
> Since I am planning another revision, does anyone object to this?

Sounds great.

>
> > On the weird side, after I updated to the current sources, the backend
> > dies on me whenever I try to delete a database, whether from psql with
> > 'drop database test' or from the command line with 'destroydb test'.
>
> Try making the 's_lock_test' target in src/backend/storage/buffer/Makefile.
> It will let you be sure that spinlocks are working.
>
> Just btw, I have been doing some testing based on Bruce's reservations about
> the inline vs call implementation of spinlocks, and will be posting an updated
> set of patches and the results of my testing "real soon now".
>
> Now that I have at least anoncvs access to the current tree, I think I can
> do this with fewer iterations (crossing fingers...).


--
Bruce Momjian                          |  830 Blythe Avenue
maillist@candle.pha.pa.us              |  Drexel Hill, Pennsylvania 19026
  +  If your life is a hard drive,     |  (610) 353-9879(w)
  +  Christ can be your backup.        |  (610) 853-3000(h)

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] Query cancel and OOB data
Следующее
От: Tom Ivar Helbekkmo
Дата:
Сообщение: Re: [HACKERS] Current sources?