From: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org> |
Subject: | Re: [HACKERS] Changing oidvector length |
Date: | 2000-01-11 01:25:14 |
Message-ID: | 200001110125.UAA01288@candle.pha.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
> You have:
>
> #define FUNC_MAX_ARGS (INDEX_MAX_KEYS+1)
>
> This is WRONG, I'm pretty sure --- FUNC_MAX_ARGS should be the same
> as the length of oidvector.
>
> User-declared functions can definitely only have as many args as there
> are slots in oidvector, because that's all the room there is to declare
> them in pg_proc.
I was going to ask about that. The original value for this was 9, while
oid8 was only 8 long. When I went to 16, FUNC_MAX_ARGS has to 17 or
initdb fails on int4in. No idea why, and want to ask if anyone knows
why this is required. I know it should be 16, but I can't figure out
why it doesn't work at 16, only at 17.
>
> You may have gotten confused because fmgr.c allowed 9 args to be passed,
> even though there's no way to declare such a function; I think this was
> a hack to support some special system usage --- possibly selectivity
btbuild, I believe.
> estimators had 9 args at one time. (They don't now, so the 9th-arg
> support was dead code as far as I can tell.) But if we are going to
> increase the default MAX_ARGS above 8 then the issue goes away anyway,
> and there's no need for fmgr.c to support more args than can normally
> be declared.
--
Bruce Momjian | http://www.op.net/~candle
maillist(at)candle(dot)pha(dot)pa(dot)us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026
From | Date | Subject | |
---|---|---|---|
Next Message | Hiroshi Inoue | 2000-01-11 01:58:27 | RE: [HACKERS] Potential vacuum bug? |
Previous Message | Tom Lane | 2000-01-11 00:52:46 | Re: [HACKERS] Changing oidvector length |