Re: [HACKERS] A worst case for qsort

2014-08-07 Thread John Cochran
On Thu, Aug 7, 2014 at 11:07 AM, Robert Haas wrote: > On Tue, Aug 5, 2014 at 8:15 PM, Peter Geoghegan wrote: > > "The adversarial method works for almost any polymorphic program > > recognizable as quicksort. The subject quicksort may copy values at > > will, or work with lists rather than array

Re: [HACKERS] A worst case for qsort

2014-08-06 Thread John Cochran
I just browsed the paper linked by Peter and it looks like the attack has to be active against a currently executing qsort. In the paper, what happens is the comparison function is supplied by the attacker and effectively lies about the result of a comparison. It keeps the lies consistent in a very

[HACKERS] Looked at TODO:Considering improving performance of computing CHAR() value lengths

2014-08-02 Thread John Cochran
Greetings, I took at look at the TODO list and got interested in the possible optimization of the bcTruelen() function. Read the archived messages about that subject and decided to see what could be done. I tested the performance of 5 different versions of bcTruelen(). 1. The code as it exists in

Re: [HACKERS] Proposal for updating src/timezone

2014-07-19 Thread John Cochran
On Sat, Jul 19, 2014 at 11:58 AM, Michael Banck wrote: SNIP > > Maybe if you pgindent the IANA code as well, you can more easily diff > the actual changes between the two, did you try that? > > > Michael > Unfortunately, pgindent doesn't work well with the IANA code as evident by some previous ch

Re: [HACKERS] Proposal for updating src/timezone

2014-07-19 Thread John Cochran
that pgindent not be used again on the IANA code so future maintainers can easily perform a diff between the IANA code and the postgres code to determine the actual differences. I'll then see about doing the same with the other source files in timezone. On Fri, Jul 18, 2014 at 4:27 PM, Tom Lan

Re: [HACKERS] Proposal for updating src/timezone

2014-07-18 Thread John Cochran
On Fri, Jul 18, 2014 at 1:21 PM, Tom Lane wrote: > John Cochran writes: > > My proposal is the have the following directory structure > > ... > > 1. I would have liked to recommend 2 sub-directories underneath > ... > > I have exactly zero expectation of using

[HACKERS] Proposal for updating src/timezone

2014-07-18 Thread John Cochran
unk" files into the directory. The files would mainly consist of man pages and html files containing documentation for the timezone code. The extra files would consume approximately 500 kilobytes above what's actually needed, but otherwise wouldn't have any adverse effects. Thank you

[HACKERS] Question about src/timezone/zic.c

2014-07-16 Thread John Cochran
assignment of an int to a long?" Or to put it another way, "Are there any C compilers that fail to properly perform integer promotion from int to long?" As things stand, it looks to me like that function eitol() can be simply deleted and the 22 calls to that function also removed. Shorter, simpler,faster code is always a good thing after all. Thank you for reading, John Cochran

Re: [HACKERS] regression failure - horology

2003-03-02 Thread John Cochran
In article <[EMAIL PROTECTED]>, Tom Lane <[EMAIL PROTECTED]> wrote: >Joe Conway <[EMAIL PROTECTED]> writes: >> Tom Lane wrote: >>> Hm, I just had regression tests pass earlier this evening on RHL 8.0 >>> (also HPUX 10.20). Are you using default config, or >>> --enable-integer-datetimes? > >> I'm u