Thread: typedefs for indent
OK, I have spent some time generating and filtering typdefs via objdump on various platforms. I filtered them and Bruce's list to eliminate items not actually found in the sources thus: while read line ; do grep -q -w -r --exclude="*.data" --exclude="*.out" --exclude="*.sql" --exclude="*.po" --exclude='*akefile' $line pgsql.head/src/backend pgsql.head/src/include pgsql.head/src/bin pgsql.head/src/interfaces pgsql.head/src/pl pgsql.head/src/port pgsql.head/src/timezone/*.[ch] pgsql.head/src/test/regress/*.[ch] pgsql.head/contrib && echo $line; done (This filter runs a lot faster than the one Alvaro posted.) If someone can point me where to get objdump for OSX I'll look at generating a list there too. The results can be seen at: http://developer.postgresql.org/~adunstan/linux-found http://developer.postgresql.org/~adunstan/mingw-found http://developer.postgresql.org/~adunstan/cygwin-found http://developer.postgresql.org/~adunstan/bruce-bsdos-found counts: 2010 bruce-bsdos-found 2036 cygwin-found 1979 linux-found 2125 mingw-found It seems clear (as we expected) that this process is sensitive to both the build system and build options used. It's not just additive, though. Bruce has some symbols that my linux build doesn't have because he didn't build with openssh. So I continue to think the best way to generate a list will be to consolidate lists generated from the buildfarm which represents a wide variety of build scenarios. Is anyone else looking at GNU indent to see if it has improved enough to meet our needs? cheers andrew
Andrew Dunstan wrote: > So I continue to think the best way to generate a list will be to > consolidate lists generated from the buildfarm which represents a wide > variety of build scenarios. > > Is anyone else looking at GNU indent to see if it has improved enough to > meet our needs? I am not going to be able to test GNU indent for a few months so I hope someone else tests it sooner than that. Just checking, but you remembered that GNU indent needs a typedef list too, right? Also, there are scripts in pgindent surrounding the indent binary that should also be reviewed. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > Andrew Dunstan wrote: > >> So I continue to think the best way to generate a list will be to >> consolidate lists generated from the buildfarm which represents a wide >> variety of build scenarios. >> >> Is anyone else looking at GNU indent to see if it has improved enough to >> meet our needs? >> > > I am not going to be able to test GNU indent for a few months so I hope > someone else tests it sooner than that. > > Just checking, but you remembered that GNU indent needs a typedef list > too, right? Also, there are scripts in pgindent surrounding the indent > binary that should also be reviewed. > > Right now I am addressing the very specific problem of coming up with a better typedef list to use with whatever indenter we use, given that it seems a task well suited to the buildfarm. If I do get to looking at GNU indent it will be a way down the track for me too. In fact, this seems a task that might be well suited to someone who is not spending what time they have available for Postgres on hacking (currently I'm trying to remove bitrot from the column level privs patch). cheers andrew
Andrew Dunstan wrote: > > OK, I have spent some time generating and filtering typdefs via objdump > on various platforms. I filtered them and Bruce's list to eliminate > items not actually found in the sources thus: Did this go anywhere? -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Alvaro Herrera wrote: > Andrew Dunstan wrote: > >> OK, I have spent some time generating and filtering typdefs via objdump >> on various platforms. I filtered them and Bruce's list to eliminate >> items not actually found in the sources thus: >> > > Did this go anywhere? > I'm still trying to get a working objdump for OSX. Automating this is difficult because we need to make sure we get all (or pretty close to all) the typedefs we can get on each platform for various build configurations. cheers andrew
Andrew Dunstan wrote: > > > Alvaro Herrera wrote: > > Andrew Dunstan wrote: > > > >> OK, I have spent some time generating and filtering typdefs via objdump > >> on various platforms. I filtered them and Bruce's list to eliminate > >> items not actually found in the sources thus: > >> > > > > Did this go anywhere? > > > > > I'm still trying to get a working objdump for OSX. Automating this is > difficult because we need to make sure we get all (or pretty close to > all) the typedefs we can get on each platform for various build > configurations. At this point I would like to get a typedef list into CVS, even if it is not perfect --- it is better than what we have now. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > Andrew Dunstan wrote: > >> Alvaro Herrera wrote: >> >>> Andrew Dunstan wrote: >>> >>> >>>> OK, I have spent some time generating and filtering typdefs via objdump >>>> on various platforms. I filtered them and Bruce's list to eliminate >>>> items not actually found in the sources thus: >>>> >>>> >>> Did this go anywhere? >>> >>> >> I'm still trying to get a working objdump for OSX. Automating this is >> difficult because we need to make sure we get all (or pretty close to >> all) the typedefs we can get on each platform for various build >> configurations. >> > > At this point I would like to get a typedef list into CVS, even if it is > not perfect --- it is better than what we have now. > > Well, you can start with this one: http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=dungbeetle&dt=2008-07-21%20204856&stg=typedefs After I have a number of buildfarm machines producing them, I'll work on a stored proc to consolidate them and make them available, probably via a SOAP call (c.f. http://people.planetpostgresql.org/andrew/index.php?/archives/14-SOAP-server-for-Buildfarm-dashboard.html ) cheers andrew
Andrew Dunstan wrote: > > > Alvaro Herrera wrote: > > Andrew Dunstan wrote: > > > >> OK, I have spent some time generating and filtering typdefs via objdump > >> on various platforms. I filtered them and Bruce's list to eliminate > >> items not actually found in the sources thus: > >> > > > > Did this go anywhere? > > > > > I'm still trying to get a working objdump for OSX. Automating this is > difficult because we need to make sure we get all (or pretty close to > all) the typedefs we can get on each platform for various build > configurations. I need to run pgindent in a few months. What typedef list am I going to use? -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > Andrew Dunstan wrote: > >> Alvaro Herrera wrote: >> >>> Andrew Dunstan wrote: >>> >>> >>>> OK, I have spent some time generating and filtering typdefs via objdump >>>> on various platforms. I filtered them and Bruce's list to eliminate >>>> items not actually found in the sources thus: >>>> >>>> >>> Did this go anywhere? >>> >>> >> I'm still trying to get a working objdump for OSX. Automating this is >> difficult because we need to make sure we get all (or pretty close to >> all) the typedefs we can get on each platform for various build >> configurations. >> > > I need to run pgindent in a few months. What typedef list am I going to > use? > > This URL <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> gives a typedef list that is (currently) the combined result from three fairly different buildfarm members: dungbeetle | 2009-03-22 06:44:01 brown_bat | 2009-03-21 13:00:58 dawn_bat | 2009-03-21 14:23:40 These are respectively my Linux, Cygwin and MinGW buildfarm members. I don't have a BSD machine of any flavor to test on, and I don't know how to extract the typedefs on OSX. Anyone running a buildfarm member should be able to do this and add to the results, if they are up to date with release 3.2. I have my linux crontab set up to do one typedefs run on the HEAD branch each day. cheers andrew
Andrew Dunstan <andrew@dunslane.net> writes: > Bruce Momjian wrote: >> I need to run pgindent in a few months. What typedef list am I going to >> use? > This URL <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> gives a > typedef list that is (currently) the combined result from three fairly > different buildfarm members: > dungbeetle | 2009-03-22 06:44:01 > brown_bat | 2009-03-21 13:00:58 > dawn_bat | 2009-03-21 14:23:40 > These are respectively my Linux, Cygwin and MinGW buildfarm members. > I don't have a BSD machine of any flavor to test on, and I don't know > how to extract the typedefs on OSX. Could we get diffs of the lists produced by those machines individually? That would provide a bit of evidence about how severe the platform dependence issue really is for this, and thereby help us guess how urgent it is to gather more data. regards, tom lane
Tom Lane wrote: > Andrew Dunstan <andrew@dunslane.net> writes: > >> Bruce Momjian wrote: >> >>> I need to run pgindent in a few months. What typedef list am I going to >>> use? >>> > > >> This URL <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> gives a >> typedef list that is (currently) the combined result from three fairly >> different buildfarm members: >> > > >> dungbeetle | 2009-03-22 06:44:01 >> brown_bat | 2009-03-21 13:00:58 >> dawn_bat | 2009-03-21 14:23:40 >> > > >> These are respectively my Linux, Cygwin and MinGW buildfarm members. >> > > >> I don't have a BSD machine of any flavor to test on, and I don't know >> how to extract the typedefs on OSX. >> > > Could we get diffs of the lists produced by those machines individually? > That would provide a bit of evidence about how severe the platform > dependence issue really is for this, and thereby help us guess how > urgent it is to gather more data. > > > Yes. I'll set it up with a query. For now, they are here: Linux: <http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=dungbeetle&dt=2009-03-22%20064401&stg=typedefs> Cygwin: <http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=brown_bat&dt=2009-03-21%20130058&stg=typedefs> MinGW: <http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=dawn_bat&dt=2009-03-21%20142340&stg=typedefs> cheers andrew
Andrew Dunstan wrote: > > > Tom Lane wrote: >> Andrew Dunstan <andrew@dunslane.net> writes: >> >>> Bruce Momjian wrote: >>> >>>> I need to run pgindent in a few months. What typedef list am I >>>> going to >>>> use? >>>> >> >> >>> This URL <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> gives a >>> typedef list that is (currently) the combined result from three >>> fairly different buildfarm members: >>> >> >> >>> dungbeetle | 2009-03-22 06:44:01 >>> brown_bat | 2009-03-21 13:00:58 >>> dawn_bat | 2009-03-21 14:23:40 >>> >> >> >>> These are respectively my Linux, Cygwin and MinGW buildfarm members. >>> >> >> >>> I don't have a BSD machine of any flavor to test on, and I don't >>> know how to extract the typedefs on OSX. >>> >> >> Could we get diffs of the lists produced by those machines individually? >> That would provide a bit of evidence about how severe the platform >> dependence issue really is for this, and thereby help us guess how >> urgent it is to gather more data. >> >> >> > > Yes. I'll set it up with a query. > > For now, they are here: > > Linux: > <http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=dungbeetle&dt=2009-03-22%20064401&stg=typedefs> > > Cygwin: > <http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=brown_bat&dt=2009-03-21%20130058&stg=typedefs> > > MinGW: > <http://www.pgbuildfarm.org/cgi-bin/show_stage_log.pl?nm=dawn_bat&dt=2009-03-21%20142340&stg=typedefs> > Or from now on, use this for the individual URL list: <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl?show_list=1> cheers andrew
Andrew Dunstan <andrew@dunslane.net> writes: > [ typedef lists ] Hmm ... the windows members are claiming that "int", "char", "float", "double" etc are typedefs, which doesn't exactly match up with my mental model of C. On the other hand, dungbeetle is failing to report a whole bunch of typedefs that it should report, for example AfterTriggerEventDataOneCtid which comes from entirely non platform specific code in commands/trigger.c. In short, I don't think I trust this data at all... regards, tom lane
Tom Lane wrote: > Andrew Dunstan <andrew@dunslane.net> writes: > >> [ typedef lists ] >> > > Hmm ... the windows members are claiming that "int", "char", "float", > "double" etc are typedefs, which doesn't exactly match up with my > mental model of C. On the other hand, dungbeetle is failing to report > a whole bunch of typedefs that it should report, for example > AfterTriggerEventDataOneCtid which comes from entirely non platform > specific code in commands/trigger.c. > > In short, I don't think I trust this data at all... > > > Well, the procedure for generating it is quite public. The relevant piece of perl is this - feel free to suggest improvements: if (@err == 1) # Linux { @dumpout = `objdump -W $bin 2>/dev/null | egrep -A3 '(DW_TAG_typedef|DW_TAG_structure_type|DW_TAG_union_type)' 2>/dev/null`; foreach (@dumpout) { @flds = split; next if ($flds[0] ne 'DW_AT_name' || $flds[-1] =~ /^DW_FORM_str/); $syms{$flds[-1]} =1; } } else { @dumpout = `objdump--stabs $bin 2>/dev/null`; foreach (@dumpout) { @flds = split; nextif (@flds < 7); next if ($flds[1] ne 'LSYM' || $flds[6] !~ /([^:]+):[tT]/); $syms{$1} =1; } } cheers andrew
Tom Lane wrote: > Andrew Dunstan <andrew@dunslane.net> writes: > > [ typedef lists ] > > Hmm ... the windows members are claiming that "int", "char", "float", > "double" etc are typedefs, which doesn't exactly match up with my > mental model of C. I don't think this is a problem, because the whole point is telling indent what names should be considered type names, which of course those should all be. > On the other hand, dungbeetle is failing to report > a whole bunch of typedefs that it should report, for example > AfterTriggerEventDataOneCtid which comes from entirely non platform > specific code in commands/trigger.c. This was probably optimized out by the compiler. I tend to think that having this list is much better than no list at all (the current situation), and it's better than the old list we used to have. -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Alvaro Herrera <alvherre@commandprompt.com> writes: > Tom Lane wrote: >> On the other hand, dungbeetle is failing to report >> a whole bunch of typedefs that it should report, > I tend to think that having this list is much better than no list at all > (the current situation), and it's better than the old list we used to > have. Well, AIUI the old list was essentially the result of this code as run on Bruce's BSD machine. We had supposed that the obvious omissions in the old list were caused by platform-specific decisions to not build code that referenced particular typedef names, but now I wonder. It certainly appears that the technique has got some significant bug on dungbeetle. regards, tom lane
After doing some further digging I've concluded that the typedefs that are missing from dungbeetle's list are those that are declared, but are never used as the type of anything. For instance AfterTriggerEventDataOneCtid is only used in a sizeof() computation, and there are quite a few enums for which no variable is ever declared as being of the enum type. So Alvaro seems to be right that these are getting optimized out of the debug info. The good news is that as far as I can think at the moment, that means we don't really care whether pg_indent knows they are typedef names or not --- they aren't getting used in any contexts where it would matter for indenting purposes. However, this does complicate the matter of comparing the typedef lists to identify how many symbols are platform-specific or compile-option-specific typedefs. BTW, is dungbeetle still running Fedora 6? On my F-10 machine the output of objdump seems to be formatted differently than your script is expecting, eg $ objdump -W postgres | egrep -A3 '(DW_TAG_typedef|DW_TAG_structure_type|DW_TAG_union_type)' | grep AfterTriggerEvent <19ac75> DW_AT_name : (indirect string, offset: 0x1c1ad): AfterTriggerEvent <19ac87> DW_AT_name : (indirectstring, offset: 0x1bffc): AfterTriggerEventData <19acc2> DW_AT_name : (indirect string, offset: 0x1bffc):AfterTriggerEventData <19acce> DW_AT_name : (indirect string, offset: 0x1c891): AfterTriggerEventChunk <19ad1e> DW_AT_name : (indirect string, offset: 0x1c891): AfterTriggerEventChunk <19ad2a> DW_AT_name : (indirect string, offset: 0x1c166): AfterTriggerEventList <19ad6b> DW_AT_name :(indirect string, offset: 0x1c166): AfterTriggerEventList regards, tom lane
Tom Lane wrote: > > BTW, is dungbeetle still running Fedora 6? yes. Upgrading it is on my long TODO list. I wish Fedora had a bit longer release cycles. > On my F-10 machine the > output of objdump seems to be formatted differently than your script > is expecting > I guess that will make upgrading a bit more urgent ;-) cheers andrew
Andrew Dunstan wrote: > This URL <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> gives a > typedef list that is (currently) the combined result from three fairly > different buildfarm members: > > dungbeetle | 2009-03-22 06:44:01 > brown_bat | 2009-03-21 13:00:58 > dawn_bat | 2009-03-21 14:23:40 > > These are respectively my Linux, Cygwin and MinGW buildfarm members. > > I don't have a BSD machine of any flavor to test on, and I don't know > how to extract the typedefs on OSX. > > Anyone running a buildfarm member should be able to do this and add to > the results, if they are up to date with release 3.2. I have my linux > crontab set up to do one typedefs run on the HEAD branch each day. [ Discussion deleted.] Andrew, this is disappointing news. When you talked about generating an typedef list from the buildfarm, you were saying how great it would be --- now a year later you post: It'd be nice to get that dealt with before we run pg_indent, but it'snot like we'd be any worse off than before if we don't.In any case it'ssurely no blocker for 8.4beta. We can't have the system-supplied typedef list changing from release to release because that affects the indenting from release to release, which affects backpatching and other stuff. And even if you get a more complete list then we have used in the past, what are the odds you are going to supply a typedef that is a typedef on some operating system that matches an identifier in our code that _isn't_ used as a typedef by us? We only have a few weeks until I have to run pgindent so I would like this resolved one way or another soon. Unless I hear otherwise I assume we are going to just use the an updated list of our defined typedefs that gets generated from our code, which includes my BSD typedefs. One other approach would be to include in pg_indent a hard-coded list of non-BSD system-defined typedefs that we reference from our code. One way to find those would be to run pg_indent with and without Andrew's list of typedefs and see how the formatting changes. Or just use a Linux list of system typedefs from now on. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
bruce wrote: > Andrew Dunstan wrote: > > This URL <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> gives a > > typedef list that is (currently) the combined result from three fairly > > different buildfarm members: > > > > dungbeetle | 2009-03-22 06:44:01 > > brown_bat | 2009-03-21 13:00:58 > > dawn_bat | 2009-03-21 14:23:40 > > > > These are respectively my Linux, Cygwin and MinGW buildfarm members. > > > > I don't have a BSD machine of any flavor to test on, and I don't know > > how to extract the typedefs on OSX. > > > > Anyone running a buildfarm member should be able to do this and add to > > the results, if they are up to date with release 3.2. I have my linux > > crontab set up to do one typedefs run on the HEAD branch each day. > > [ Discussion deleted.] > > Andrew, this is disappointing news. When you talked about generating an > typedef list from the buildfarm, you were saying how great it would be > --- now a year later you post: > > It'd be nice to get that dealt with before we run pg_indent, but it's > not like we'd be any worse off than before if we don't. In any case it's > surely no blocker for 8.4beta. My apologies; the above are Tom's words, not Andrews. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > bruce wrote: > >> Andrew Dunstan wrote: >> >>> This URL <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> gives a >>> typedef list that is (currently) the combined result from three fairly >>> different buildfarm members: >>> >>> dungbeetle | 2009-03-22 06:44:01 >>> brown_bat | 2009-03-21 13:00:58 >>> dawn_bat | 2009-03-21 14:23:40 >>> >>> These are respectively my Linux, Cygwin and MinGW buildfarm members. >>> >>> I don't have a BSD machine of any flavor to test on, and I don't know >>> how to extract the typedefs on OSX. >>> >>> Anyone running a buildfarm member should be able to do this and add to >>> the results, if they are up to date with release 3.2. I have my linux >>> crontab set up to do one typedefs run on the HEAD branch each day. >>> >> [ Discussion deleted.] >> >> Andrew, this is disappointing news. When you talked about generating an >> typedef list from the buildfarm, you were saying how great it would be >> --- now a year later you post: >> >> It'd be nice to get that dealt with before we run pg_indent, but it's >> not like we'd be any worse off than before if we don't. In any case it's >> surely no blocker for 8.4beta. >> > > My apologies; the above are Tom's words, not Andrews. > > Apology accepted. What I promised was a list that was more comprehensive than what we were using. I think I've already delivered on that, but I would like to do better by including some other Operating Systems: particularly some BSD flavors. Buildfarm owners with non-Linux non-Windows members please take note. Email me if you need help with this. Unless we come up with some tolerably correct and maintainable code analysis tool for identifying typedefs, using the current heuristic methods is apparently the best we can do. Nobody has suggested even an outline for such a tool. I don't think using the buildfarm for this heuristic method is great, and never suggested it would be. I do think it's an improvement, which is what I promised. I'm sorry if you find the result disappointing. cheers andrew
Andrew Dunstan wrote: > >> Andrew, this is disappointing news. When you talked about generating an > >> typedef list from the buildfarm, you were saying how great it would be > >> --- now a year later you post: > >> > >> It'd be nice to get that dealt with before we run pg_indent, but it's > >> not like we'd be any worse off than before if we don't. In any case it's > >> surely no blocker for 8.4beta. > >> > > > > My apologies; the above are Tom's words, not Andrews. > > > > > > Apology accepted. > > What I promised was a list that was more comprehensive than what we were > using. I think I've already delivered on that, but I would like to do > better by including some other Operating Systems: particularly some BSD > flavors. Buildfarm owners with non-Linux non-Windows members please > take note. Email me if you need help with this. > > Unless we come up with some tolerably correct and maintainable code > analysis tool for identifying typedefs, using the current heuristic > methods is apparently the best we can do. Nobody has suggested even an > outline for such a tool. I don't think using the buildfarm for this > heuristic method is great, and never suggested it would be. I do think > it's an improvement, which is what I promised. I'm sorry if you find the > result disappointing. Well, as you, I was hoping for a clear solution, and it seems we don't have one. I think the false-positives problem is real and might make the greater code coverage of the buildfarm worse than what we did for 8.3. I think our only fallback is to find places that our BSD items miss, perhaps Win32 cases, see what is different with those lists, and just hard-code them in, because then we aren't importing a huge number of additional typedefs that have uncertain consequences. Frankly, I don't remember anyone complaining we didn't find any typedefs in pgindent, though I think there might have been a few EXEC_BACKEND cases, and maybe we can just hardcode those. Frankly, pgindent has larger problems than an imcomplete typedef list. :-( When I am ready to run pgindent I will ask for your typedef list and see what the diff shows when I use your list and we can figure something out then. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian <bruce@momjian.us> writes: > Frankly, I don't remember anyone complaining we didn't find any typedefs > in pgindent, There are lots and lots of places where it's obvious that pgindent was misinformed on the subject, because it puts in a space where there should not be one, eg "typename * ptr" instead of "typename *ptr". Maybe I'm just being too anal in worrying about a space here or a space there ... but then why do we run the thing at all? This is the first time I've heard anyone suggest that false positives could be a problem. What exactly would be the results of a false match? Would it look worse than the false negatives do? regards, tom lane
Bruce Momjian wrote: > Well, as you, I was hoping for a clear solution, and it seems we don't > have one. I think the false-positives problem is real and might make > the greater code coverage of the buildfarm worse than what we did for > 8.3. Huh? What false positive problem? -- Alvaro Herrera http://www.CommandPrompt.com/ The PostgreSQL Company - Command Prompt, Inc.
Tom Lane wrote: > Bruce Momjian <bruce@momjian.us> writes: > > Frankly, I don't remember anyone complaining we didn't find any typedefs > > in pgindent, > > There are lots and lots of places where it's obvious that pgindent > was misinformed on the subject, because it puts in a space where there > should not be one, eg "typename * ptr" instead of "typename *ptr". > Maybe I'm just being too anal in worrying about a space here or a space > there ... but then why do we run the thing at all? Sure, why not make it as good as we can. > This is the first time I've heard anyone suggest that false positives > could be a problem. What exactly would be the results of a false > match? Would it look worse than the false negatives do? Well, I assume a false positive would do the opposite, meaning it would not have a space where it should have one. I am also worried about a typedef list that changes from release to release as buildfarm members change; variability might be worse than correctness in this case. Anyway, I think a diff of using my list and Andrew's list will show us which one gets things clearest; the diff is going to highlight only cases where the typedef lists change formatting. Andrew, where exactly is the list I should try? -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Alvaro Herrera wrote: > Bruce Momjian wrote: > > > Well, as you, I was hoping for a clear solution, and it seems we don't > > have one. I think the false-positives problem is real and might make > > the greater code coverage of the buildfarm worse than what we did for > > 8.3. > > Huh? What false positive problem? typedefs listed on platforms that match identifiers in our code that are _not_ typedefs. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > Alvaro Herrera wrote: > > Bruce Momjian wrote: > > > > > Well, as you, I was hoping for a clear solution, and it seems we don't > > > have one. I think the false-positives problem is real and might make > > > the greater code coverage of the buildfarm worse than what we did for > > > 8.3. > > > > Huh? What false positive problem? > > typedefs listed on platforms that match identifiers in our code that are > _not_ typedefs. Does this actually happen anywhere? -- Alvaro Herrera http://www.CommandPrompt.com/ The PostgreSQL Company - Command Prompt, Inc.
Alvaro Herrera wrote: > Bruce Momjian wrote: > > Alvaro Herrera wrote: > > > Bruce Momjian wrote: > > > > > > > Well, as you, I was hoping for a clear solution, and it seems we don't > > > > have one. I think the false-positives problem is real and might make > > > > the greater code coverage of the buildfarm worse than what we did for > > > > 8.3. > > > > > > Huh? What false positive problem? > > > > typedefs listed on platforms that match identifiers in our code that are > > _not_ typedefs. > > Does this actually happen anywhere? No idea; it was more a theoretical issue to say that having more typedefs is not necessarily a good thing; they should ideally be the typedefs we use, and Windows adds a lot of typedefs we don't use. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > Anyway, I think a diff of using my list and Andrew's list will show us > which one gets things clearest; the diff is going to highlight only > cases where the typedef lists change formatting. > > Andrew, where exactly is the list I should try? > > fetch it from <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> cheers andrew
Andrew Dunstan wrote: > > > Bruce Momjian wrote: > > Anyway, I think a diff of using my list and Andrew's list will show us > > which one gets things clearest; the diff is going to highlight only > > cases where the typedef lists change formatting. > > > > Andrew, where exactly is the list I should try? > > > > > > fetch it from <http://www.pgbuildfarm.org/cgi-bin/typedefs.pl> Thanks. I will run tests when we are ready for pg_indent and we can then make a decision. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > Alvaro Herrera wrote: > > Bruce Momjian wrote: > > > Alvaro Herrera wrote: > > > > Huh? What false positive problem? > > > > > > typedefs listed on platforms that match identifiers in our code that are > > > _not_ typedefs. > > > > Does this actually happen anywhere? > > No idea; it was more a theoretical issue to say that having more > typedefs is not necessarily a good thing; they should ideally be the > typedefs we use, and Windows adds a lot of typedefs we don't use. Okay, so I went over the mingw list a bit (not exhaustively) and found no typedef that's used as an identifier in our code. Huh ... just found one. It's called "timezone", but it's used as an identifier only in the function declaration (dt2local), not in the function definition, which uses "tz" instead. There's also ACL, but we only use it in macro definitions. There are a bunch of other typedefs that the mingw port adds, but several of them are actually used in our code (HANDLE, BOOL, etc). I think this is minor enough that it should be ignored. -- Alvaro Herrera http://www.CommandPrompt.com/ The PostgreSQL Company - Command Prompt, Inc.
Bruce Momjian wrote: > Thanks. I will run tests when we are ready for pg_indent and we can > then make a decision. FWIW I was looking at this code for unrelated reasons and found a couple of symbols that pgindent considers to be typedefs but it clearly are not -- BufferHitCount and LocalBufferHitCount. It can be seen in ShowBufferUsage(). -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Alvaro Herrera wrote: > Bruce Momjian wrote: > > > Thanks. I will run tests when we are ready for pg_indent and we can > > then make a decision. > > FWIW I was looking at this code for unrelated reasons and found a couple > of symbols that pgindent considers to be typedefs but it clearly are not > -- BufferHitCount and LocalBufferHitCount. It can be seen in > ShowBufferUsage(). Are you saying you saw this in Andrew's typedef output, or from the 8.3 run of pg_indent? -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. +
Bruce Momjian wrote: > Alvaro Herrera wrote: > > Bruce Momjian wrote: > > > > > Thanks. I will run tests when we are ready for pg_indent and we can > > > then make a decision. > > > > FWIW I was looking at this code for unrelated reasons and found a couple > > of symbols that pgindent considers to be typedefs but it clearly are not > > -- BufferHitCount and LocalBufferHitCount. It can be seen in > > ShowBufferUsage(). > > Are you saying you saw this in Andrew's typedef output, or from the 8.3 > run of pg_indent? This is on the 8.3 code. Notice how this is formatted: hitrate = (float) BufferHitCount *100.0 / ReadBufferCount; (line 1465) -- Alvaro Herrera http://www.CommandPrompt.com/ The PostgreSQL Company - Command Prompt, Inc.
Alvaro Herrera wrote: > Bruce Momjian wrote: > >> Alvaro Herrera wrote: >> >>> Bruce Momjian wrote: >>> >>> >>>> Thanks. I will run tests when we are ready for pg_indent and we can >>>> then make a decision. >>>> >>> FWIW I was looking at this code for unrelated reasons and found a couple >>> of symbols that pgindent considers to be typedefs but it clearly are not >>> -- BufferHitCount and LocalBufferHitCount. It can be seen in >>> ShowBufferUsage(). >>> >> Are you saying you saw this in Andrew's typedef output, or from the 8.3 >> run of pg_indent? >> > > This is on the 8.3 code. Notice how this is formatted: > > hitrate = (float) BufferHitCount *100.0 / ReadBufferCount; > > > > These symbols are not in the buildfarm's list of typedefs. cheers andrew
Alvaro Herrera wrote: > This is on the 8.3 code. Notice how this is formatted: > > hitrate = (float) BufferHitCount *100.0 / ReadBufferCount; Hmm, I just noticed that this is mentioned as a "known bug" in pgindent. Nevermind ... -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Andrew Dunstan wrote: > >>> FWIW I was looking at this code for unrelated reasons and found a couple > >>> of symbols that pgindent considers to be typedefs but it clearly are not > >>> -- BufferHitCount and LocalBufferHitCount. It can be seen in > >>> ShowBufferUsage(). > >>> > >> Are you saying you saw this in Andrew's typedef output, or from the 8.3 > >> run of pg_indent? > >> > > > > This is on the 8.3 code. Notice how this is formatted: > > > > hitrate = (float) BufferHitCount *100.0 / ReadBufferCount; > > > > > > > > > > > These symbols are not in the buildfarm's list of typedefs. The good news is that LocalBufferHitCount isn't in my list of typedefs from CVS HEAD, and probably not in 8.3 either. The bad news is that pgindent pushes the '*' next to the 100.0 in my testing. :-( I tested BSD indent alone with no arguments or typedef list and got the same output, even after adding the space in the C file, so something wrong must be happening in the binary. -- Bruce Momjian <bruce@momjian.us> http://momjian.us EnterpriseDB http://enterprisedb.com + If your life is a hard drive, Christ can be your backup. + AES_KEY AFFIX ARRAY_TYPE ASN1_BIT_STRING ASN1_BMPSTRING ASN1_BOOLEAN ASN1_CTX ASN1_ENCODING ASN1_ENCODING_st ASN1_ENUMERATED ASN1_GENERALIZEDTIME ASN1_GENERALSTRING ASN1_HEADER ASN1_IA5STRING ASN1_INTEGER ASN1_ITEM ASN1_ITEM_EXP ASN1_METHOD ASN1_NULL ASN1_OBJECT ASN1_OCTET_STRING ASN1_PRINTABLESTRING ASN1_STRING ASN1_STRING_TABLE ASN1_T61STRING ASN1_TEMPLATE ASN1_TIME ASN1_TLC ASN1_TYPE ASN1_UNIVERSALSTRING ASN1_UTCTIME ASN1_UTF8STRING ASN1_VALUE ASN1_VISIBLESTRING A_ArrayExpr A_Const A_Expr A_Expr_Kind A_Indices A_Indirection A_Star AbsoluteTime AccessPriv Acl AclItem AclMaskHow AclMode AclObjectKind AclResult ActiveSnapshotElt AffixNode AffixNodeData AfterTriggerEvent AfterTriggerEventChunk AfterTriggerEventData AfterTriggerEventDataOneCtid AfterTriggerEventList AfterTriggerShared AfterTriggerSharedData AfterTriggers AfterTriggersData Agg AggClauseCounts AggHashEntry AggHashEntryData AggInfo AggState AggStatePerAgg AggStatePerAggData AggStatePerGroup AggStatePerGroupData AggStrategy Aggref AggrefExprState Alias AllocBlock AllocBlockData AllocChunk AllocChunkData AllocPointer AllocSet AllocSetContext AllocateDesc AllocateDescKind AlterDatabaseSetStmt AlterDatabaseStmt AlterDomainStmt AlterFdwStmt AlterForeignServerStmt AlterFunctionStmt AlterObjectSchemaStmt AlterOpFamilyStmt AlterOptionOp AlterOwnerStmt AlterRoleSetStmt AlterRoleStmt AlterSeqStmt AlterTSConfigurationStmt AlterTSDictionaryStmt AlterTableCmd AlterTableStmt AlterTableType AlterUserMappingStmt AlteredTableInfo AlternativeSubPlan AlternativeSubPlanState AnalyzeAttrFetchFunc AnlIndexData Append AppendPath AppendRelInfo AppendState Archive ArchiveEntryPtr ArchiveFormat ArchiveHandle ArchiveMode ArchiverStage ArrayBuildState ArrayCoerceExpr ArrayCoerceExprState ArrayConstIterState ArrayExpr ArrayExprIterState ArrayExprState ArrayMapState ArrayMetaState ArrayParseState ArrayRef ArrayRefExprState ArrayTuple ArrayType AttInMetadata AttrDefInfo AttrDefault AttrNumber AuthRequest AutoVacOpts AutoVacuumShmemStruct AutoVacuumSignal AuxProcType BF_KEY BIGNUM BIO BIO_F_BUFFER_CTX BIO_METHOD BIO_dummy BITVEC BITVECP BIT_STRING_BITNAME BIT_STRING_BITNAME_st BMS_Membership BN_BLINDING BN_CTX BN_MONT_CTX BN_RECP_CTX BOX BTBuildState BTCycleId BTMetaPageData BTOneVacInfo BTPageOpaque BTPageOpaqueData BTPageState BTScanOpaque BTScanOpaqueData BTScanPos BTScanPosData BTScanPosItem BTSpool BTStack BTStackData BTVacInfo BTVacState BTWriteState BUF_MEM Backend BackendId BackslashQuoteType BgWriterRequest BgWriterShmemStruct BitmapAnd BitmapAndPath BitmapAndState BitmapHeapPath BitmapHeapScan BitmapHeapScanState BitmapIndexScan BitmapIndexScanState BitmapOr BitmapOrPath BitmapOrState Bitmapset BkpBlock Block BlockId BlockIdData BlockNumber BlockSampler BlockSamplerData BoolExpr BoolExprState BoolExprType BoolPtr BoolTestType BooleanTest BpChar Bucket BufFile BufFlags Buffer BufferAccessStrategy BufferAccessStrategyData BufferAccessStrategyType BufferDesc BufferLookupEnt BufferStrategyControl BufferTag BuildAccumulator BulkInsertState BulkInsertStateData Byte Bytef CACHESIGN CAC_state CAST_KEY CFuncHashTabEntry CHKVAL CIRCLE CMPDAffix COMPAT_MODE COMP_CTX COMP_METHOD CONF CONF_IMODULE CONF_METHOD CONF_MODULE CONF_VALUE CPFunction CPPFunction CRYPTO_EX_DATA CRYPTO_EX_DATA_FUNCS CRYPTO_EX_DATA_IMPL CRYPTO_EX_dup CRYPTO_EX_free CRYPTO_EX_new CRYPTO_MEM_LEAK_CB CRYPTO_dynlock CachedPlan CachedPlanSource CancelRequestPacket CaseExpr CaseExprState CaseTestExpr CaseWhen CaseWhenState Cash CastInfo CatCList CatCTup CatCache CatCacheHeader CatalogId CatalogIndexState ChangeVarNodes_context CheckPoint CheckPointStmt CheckpointStatsData Chromosome City ClonePtr ClosePortalStmt ClosePtr ClusterStmt CmdType CoalesceExpr CoalesceExprState CoerceToDomain CoerceToDomainState CoerceToDomainValue CoerceViaIO CoerceViaIOState CoercionCodes CoercionContext CoercionForm CoercionMethod CoercionPathType ColumnCompareData ColumnDef ColumnIOData ColumnRef ComboCidEntry ComboCidEntryData ComboCidKey ComboCidKeyData CommandDest CommandId CommentItem CommentStmt CommonTableExpr CompareScalarsContext CompositeTypeStmt ConnStatusType ConnType ConnectionOption Const ConstrCheck ConstrType Constraint ConstraintCategory ConstraintExclusionType ConstraintInfo ConstraintsSetStmt ControlFileData ConvInfo ConvertRowtypeExpr ConvertRowtypeExprState CookedConstraint CopyDest CopyState CopyStateData CopyStmt Cost CostSelector CoverPos CreateCastStmt CreateConversionStmt CreateDomainStmt CreateEnumStmt CreateFdwStmt CreateForeignServerStmt CreateFunctionStmt CreateOpClassItem CreateOpClassStmt CreateOpFamilyStmt CreatePLangStmt CreateRoleStmt CreateSchemaStmt CreateSchemaStmtContext CreateSeqStmt CreateStmt CreateStmtContext CreateStmtLikeOption CreateTableSpaceStmt CreateTrigStmt CreateUserMappingStmt CreatedbStmt Cred CteItem CteScan CteScanState CteState CtlCommand CurrentOfExpr CustomOutPtr CycleCtr DBState DCHCacheEntry DCH_poz DEADLOCK_INFO DES_cblock DES_key_schedule DES_ks DH DH_METHOD DIR DR_copy DR_intorel DR_printtup DR_sqlfunction DSA DSA_METHOD DSA_SIG DSA_SIG_st DataDumperPtr DataPageDeleteStack DateADT Datum DatumArray DatumPtr DatumTupleFields DeClonePtr DeadLockState DeallocateStmt DeclareCursorStmt DefElem DefineStmt DeleteStmt DependencyType DestReceiver DictISpell DictSimple DictSubState DictSyn DictThesaurus DiscardMode DiscardStmt DistinctExpr Dl_info Dlelem Dllist DocRepresentation DomainConstraintState DomainConstraintType DomainIOData DropBehavior DropCastStmt DropFdwStmt DropForeignServerStmt DropOwnedStmt DropPLangStmt DropPropertyStmt DropRoleStmt DropStmt DropTableSpaceStmt DropUserMappingStmt DropdbStmt DumpId DumpableObject DumpableObjectType DynamicFileList ECPG_statement_type ECPGdtype ECPGgeneric_varchar ECPGstruct_member ECPGtemp_type ECPGttype ECPGtype ECPGtype_information_cache EDGE ENGINE ERR_FNS ERR_STATE ERR_STRING_DATA ERR_string_data_st EState EVP_CIPHER EVP_CIPHER_CTX EVP_CIPHER_INFO EVP_ENCODE_CTX EVP_MD EVP_MD_CTX EVP_PBE_KEYGEN EVP_PKEY Edge EndBlobPtr EndBlobsPtr EndDataPtr EntryAccumulator EolType EquivalenceClass EquivalenceMember ErrorContextCallback ErrorData ExecContext ExecContextData ExecRowMark ExecScanAccessMtd ExecStatus ExecStatusType ExecuteStmt ExecutorEnd_hook_type ExecutorRun_hook_type ExecutorStart_hook_type ExplainOneQuery_hook_type ExplainState ExplainStmt Expr ExprContext ExprContextCallbackFunction ExprContext_CB ExprDoneCond ExprState ExprStateEvalFunc ExtensionBehavior Extention FILE FSMAddress FSMPage FSMPageData FUNMAP FakeRelCacheEntry FakeRelCacheEntryData FdwInfo FetchDirection FetchStmt FieldSelect FieldSelectState FieldStore FieldStoreState File FileName FindSplitData FkConstraint FmgrBuiltin FmgrInfo ForeignDataWrapper ForeignServer ForeignServerInfo ForkNumber FormData_pg_aggregate FormData_pg_am FormData_pg_amop FormData_pg_amproc FormData_pg_attrdef FormData_pg_attribute FormData_pg_auth_members FormData_pg_authid FormData_pg_cast FormData_pg_class FormData_pg_constraint FormData_pg_conversion FormData_pg_database FormData_pg_depend FormData_pg_description FormData_pg_enum FormData_pg_foreign_data_wrapper FormData_pg_foreign_server FormData_pg_index FormData_pg_inherits FormData_pg_language FormData_pg_largeobject FormData_pg_listener FormData_pg_namespace FormData_pg_opclass FormData_pg_operator FormData_pg_opfamily FormData_pg_pltemplate FormData_pg_proc FormData_pg_rewrite FormData_pg_sequence FormData_pg_shdepend FormData_pg_shdescription FormData_pg_statistic FormData_pg_tablespace FormData_pg_trigger FormData_pg_ts_config FormData_pg_ts_config_map FormData_pg_ts_dict FormData_pg_ts_parser FormData_pg_ts_template FormData_pg_type FormData_pg_user_mapping Form_pg_aggregate Form_pg_am Form_pg_amop Form_pg_amproc Form_pg_attrdef Form_pg_attribute Form_pg_auth_members Form_pg_authid Form_pg_cast Form_pg_class Form_pg_constraint Form_pg_conversion Form_pg_database Form_pg_depend Form_pg_description Form_pg_enum Form_pg_foreign_data_wrapper Form_pg_foreign_server Form_pg_index Form_pg_inherits Form_pg_language Form_pg_largeobject Form_pg_listener Form_pg_namespace Form_pg_opclass Form_pg_operator Form_pg_opfamily Form_pg_pltemplate Form_pg_proc Form_pg_rewrite Form_pg_sequence Form_pg_shdepend Form_pg_shdescription Form_pg_statistic Form_pg_tablespace Form_pg_trigger Form_pg_ts_config Form_pg_ts_config_map Form_pg_ts_dict Form_pg_ts_parser Form_pg_ts_template Form_pg_type Form_pg_user_mapping FormatNode FromCharDateMode FromExpr FuncCall FuncCallContext FuncCandidateList FuncDetailCode FuncExpr FuncExprState FuncInfo FuncWithArgs Function FunctionCallInfo FunctionCallInfoData FunctionParameter FunctionParameterMode FunctionScan FunctionScanState GEN_SESSION_CB GISTBuildState GISTENTRY GISTInsertStack GISTInsertState GISTPageOpaque GISTPageOpaqueData GISTSTATE GISTScanOpaque GISTScanOpaqueData GISTSearchStack GIST_SPLITVEC Gene GenericExprState GenericOptionFlags GeqoEvalData GinBtree GinBtreeData GinBtreeStack GinBuildState GinChkVal GinMetaPageData GinOptions GinPageOpaque GinPageOpaqueData GinPostingTreeScan GinScanEntry GinScanEntryData GinScanKey GinScanKeyData GinScanOpaque GinScanOpaqueData GinState GinTupleCollector GinVacuumState GistBDItem GistBulkDeleteResult GistEntryVector GistNSN GistSplitUnion GistSplitVector GistVacuum GlobalTransaction GlobalTransactionData GrantObjectType GrantRoleStmt GrantStmt Group GroupState GroupVarInfo GucAction GucBoolAssignHook GucContext GucEnumAssignHook GucIntAssignHook GucRealAssignHook GucShowHook GucSource GucStack GucStackState GucStringAssignHook HASHACTION HASHBUCKET HASHCTL HASHELEMENT HASHHDR HASHSEGMENT HASH_SEQ_STATUS HISTORY_STATE HIST_ENTRY HSpool HTAB HTSU_Result HTSV_Result Hash HashAllocFunc HashBuildState HashCompareFunc HashCopyFunc HashJoin HashJoinState HashJoinTable HashJoinTableData HashJoinTuple HashJoinTupleData HashMetaPage HashMetaPageData HashPageOpaque HashPageOpaqueData HashPath HashScanList HashScanListData HashScanOpaque HashScanOpaqueData HashSkewBucket HashState HashValueFunc HbaLine HeadlineParsedText HeadlineWordEntry HeapScanDesc HeapScanDescData HeapTuple HeapTupleData HeapTupleFields HeapTupleHeader HeapTupleHeaderData HistControl INFIX IOFuncSelector IncrementVarSublevelsUp_context Index IndexArrayKeyInfo IndexAttributeBitMap IndexAttributeBitMapData IndexBuildCallback IndexBuildResult IndexBulkDeleteCallback IndexBulkDeleteResult IndexElem IndexInfo IndexList IndexOptInfo IndexPath IndexRuntimeKeyInfo IndexScan IndexScanDesc IndexScanDescData IndexScanState IndexStmt IndexTuple IndexTupleData IndexVacuumInfo IndirectBlock IndxInfo InfoItem InhInfo InhOption InhPaths InhRelation InnerIndexscanInfo InsertStmt Instrumentation Int8TransTypeData IntArray InternalGrant Interval IntoClause InvalidationChunk InvalidationListHeader IpcMemoryId IpcMemoryKey IpcSemaphoreId IpcSemaphoreKey IspellDict Item ItemId ItemIdData ItemLength ItemOffset ItemPointer ItemPointerData ItemResult Join JoinExpr JoinHashEntry JoinPath JoinState JoinType JunkFilter KEYMAP_ENTRY KEYMAP_ENTRY_ARRAY KeySuffix KeyWord Keymap LHASH LHASH_COMP_FN_TYPE LHASH_DOALL_ARG_FN_TYPE LHASH_DOALL_FN_TYPE LHASH_HASH_FN_TYPE LHASH_NODE LINE LOCALLOCK LOCALLOCKOWNER LOCALLOCKTAG LOCK LOCKMASK LOCKMETHODID LOCKMODE LOCKTAG LSEG LVRelStats LWLock LWLockId LWLockMode LWLockPadded LargeObjectDesc LexDescr LexemeEntry LexemeHashKey LexemeInfo LexemeKey LexizeData Limit LimitState LimitStateCond List ListCell ListDictionary ListParsedLex ListenAction ListenActionKind ListenStmt LoadStmt LocalBufferLookupEnt LocalTransactionId LocationIndex LockAcquireResult LockData LockInfo LockInfoData LockMethod LockMethodData LockRelId LockStmt LockTagType LockTupleMode LockingClause LogStmtLevel LogicalTape LogicalTapeSet MD2_CTX MD2state_st MD4_CTX MD4state_st MD5_CTX MD5state_st MDC2_CTX Material MaterialPath MaterialState MdfdVec MemoryContext MemoryContextData MemoryContextMethods MergeJoin MergeJoinClause MergeJoinClauseData MergeJoinState MergePath MergeScanSelCache MinMaxAggInfo MinMaxExpr MinMaxExprState MinMaxOp MinimalTuple MinimalTupleData MsgType MultiXactId MultiXactOffset MultiXactStateData NETSCAPE_CERT_SEQUENCE NETSCAPE_SPKAC NETSCAPE_SPKI NODE NUMCacheEntry NUMDesc NUMProc NUM_poz Name NameData NamespaceInfo NestLoop NestLoopState NestPath Netscape_certificate_sequence Netscape_spkac_st Netscape_spki_st NewColumnValue NewConstraint NewPage Node NodeTag NotifyStmt NullIfExpr NullTest NullTestState NullTestType Numeric NumericData NumericDigit NumericVar OBJ_NAME ONEXIT ObjectAddress ObjectAddressExtra ObjectAddressStack ObjectAddresses ObjectClass ObjectType Offset OffsetNumber OffsetVarNodes_context Oid OidOptions OldToNewMapping OldToNewMappingData OldTriggerInfo Oldstyle_fnextra OnCommitAction OnCommitItem OpClassCacheEnt OpExpr OpFamilyMember OpclassInfo Operator OpfamilyInfo OprCacheEntry OprCacheKey OprInfo OprProofCacheEntry OprProofCacheKey OptionDefElem OutputContext OverrideSearchPath OverrideStackEntry PATH PBE2PARAM PBE2PARAM_st PBEPARAM PBEPARAM_st PBKDF2PARAM PBKDF2PARAM_st PEM_CTX PEM_ENCODE_SEAL_CTX PEM_Encode_Seal_st PEM_USER PGErrorVerbosity PGFInfoFunction PGFunction PGLZ_Header PGLZ_HistEntry PGLZ_Strategy PGModuleMagicFunction PGPROC PGRUsage PGSemaphore PGSemaphoreData PGShmemHeader PGTransactionStatusType PGVerbosity PG_Lock_Status PG_fini_t PG_init_t PGcancel PGconn PGnotify PGresAttDesc PGresult PKCS7 PKCS7_DIGEST PKCS7_ENCRYPT PKCS7_ENC_CONTENT PKCS7_ENVELOPE PKCS7_ISSUER_AND_SERIAL PKCS7_RECIP_INFO PKCS7_SIGNED PKCS7_SIGNER_INFO PKCS7_SIGN_ENVELOPE PKCS8_PRIV_KEY_INFO PLAINTREE PLTemplate PMSignalReason PMState POLYGON PQArgBlock PQExpBuffer PQExpBufferData PQconninfoOption PQnoticeProcessor PQnoticeReceiver PQprintOpt PROCLOCK PROCLOCKTAG PROC_HDR PROC_QUEUE PSQL_ECHO PSQL_ECHO_HIDDEN PSQL_ERROR_ROLLBACK PacketLen Page PageHeader PageHeaderData PageSplitRecord PageUpdateRecord PagetableEntry ParallelSlot Param ParamExecData ParamExternData ParamKind ParamListInfo ParamListInfoData ParamRef ParseCallbackState ParseState ParsedLex ParsedText ParsedWord Path PathClauseUsage PathKey PathKeysComparison Pattern_Prefix_Status Pattern_Type PendingOperationEntry PendingOperationTag PendingRelDelete PendingUnlinkEntry PgBackendStatus PgStat_BackendFunctionEntry PgStat_Counter PgStat_FunctionCallUsage PgStat_FunctionCounts PgStat_FunctionEntry PgStat_GlobalStats PgStat_Msg PgStat_MsgAnalyze PgStat_MsgAutovacStart PgStat_MsgBgWriter PgStat_MsgDropdb PgStat_MsgDummy PgStat_MsgFuncpurge PgStat_MsgFuncstat PgStat_MsgHdr PgStat_MsgInquiry PgStat_MsgResetcounter PgStat_MsgTabpurge PgStat_MsgTabstat PgStat_MsgVacuum PgStat_StatDBEntry PgStat_StatFuncEntry PgStat_StatTabEntry PgStat_SubXactStatus PgStat_TableCounts PgStat_TableEntry PgStat_TableStatus PgStat_TableXactStatus Pg_finfo_record Pg_magic_struct PipeProtoChunk PipeProtoHeader PlaceHolderInfo PlaceHolderVar Plan PlanInvalItem PlanState PlannedStmt PlannerGlobal PlannerInfo PlannerParamItem Point Pointer Pool Port Portal PortalData PortalHashEnt PortalStatus PortalStrategy PostgresPollingStatusType PostingItem PredClass PredIterInfo PredIterInfoData PrepareStmt PreparedStatement PrintExtraTocPtr PrintTocDataPtr PrinttupAttrInfo PrivGrantee PrivTarget ProcArrayStruct ProcLangInfo ProcState ProcessingMode ProjectionInfo ProtocolVersion PrsStorage PruneState PsqlScanResult PsqlScanState PsqlScanStateData PsqlSettings PushFunction QTN2QTState QTNode QualCost QualItem Query QueryDesc QueryItem QueryItemType QueryOperand QueryOperator QueryRepresentation QuerySource RC2_KEY RC4_KEY RELCACHECALLBACK RIPEMD160_CTX RIPEMD160state_st RI_CompareHashEntry RI_CompareKey RI_ConstraintInfo RI_QueryHashEntry RI_QueryKey RSA RSA_METHOD RTEKind RUHashEntry RUHashEntryData RangeFunction RangeQueryClause RangeSubselect RangeTblEntry RangeTblRef RangeVar RawColumnDefault ReadBufPtr ReadBufferMode ReadBytePtr ReadExtraTocPtr ReassignOwnedStmt RecordCacheEntry RecordCompareData RecordIOData RecursionContext RecursiveUnion RecursiveUnionState RegProcedure Regis RegisNode ReindexStmt RelFileNode RelIdCacheEnt RelOptInfo RelOptKind RelToCheck RelToCluster RelabelType Relation RelationAmInfo RelationData RelationPtr RelativeTime RelcacheCallbackFunction Relids ReloptElem RemoveFuncStmt RemoveOpClassStmt RemoveOpFamilyStmt RenameStmt ReopenPtr ResTarget ResolveNew_context ResourceOwner ResourceOwnerData ResourceReleaseCallback ResourceReleaseCallbackItem ResourceReleasePhase RestoreArgs RestoreOptions RestrictInfo Result ResultPath ResultRelInfo ResultState ReturnSetInfo RewriteRule RewriteState RewriteStateData RmgrData RmgrId RoleStmtType RowCompareExpr RowCompareExprState RowCompareType RowExpr RowExprState RowMarkClause RuleInfo RuleLock RuleStmt SHA_CTX SHAstate_st SHM_QUEUE SISeg SMgrRelation SMgrRelationData SPELL SPIPlanPtr SPITupleTable SPLITCOST SPNode SPNodeData SQLFunctionCache SQLFunctionCachePtr SSL SSL2_STATE SSL3_BUFFER SSL3_RECORD SSL3_STATE SSL_CIPHER SSL_COMP SSL_CTX SSL_METHOD SSL_SESSION STACK SYSCACHECALLBACK SaOpControl SaveArchivePtr ScalarArrayOpExpr ScalarArrayOpExprState ScalarItem ScalarMCVItem Scan ScanDirection ScanKey ScanKeyData ScanKeyword ScanState ScanTypeControl SchemaQuery SelectStmt Selectivity SeqScan SeqScanState SeqTable SeqTableData SetConstraintState SetConstraintStateData SetConstraintTrigger SetConstraintTriggerData SetFunctionReturnMode SetOp SetOpCmd SetOpHashEntry SetOpHashEntryData SetOpState SetOpStatePerGroup SetOpStatePerGroupData SetOpStrategy SetOperation SetOperationStmt SetToDefault SharedDependencyType SharedInvalCatcacheMsg SharedInvalRelcacheMsg SharedInvalSmgrMsg SharedInvalidationMessage ShellTypeInfo ShmemIndexEnt ShutdownMode SigHandler SignTSVector SimpleOidList SimpleOidListCell SimpleStringList SimpleStringListCell Size SlruCtl SlruCtlData SlruErrorCause SlruFlush SlruFlushData SlruPageStatus SlruShared SlruSharedData Snapshot SnapshotData SnapshotSatisfiesFunc SockAddr Sort SortBy SortByDir SortByNulls SortGroupClause SortState SortTuple SpecialJoinInfo SplitVar SplitedPageLayout StackElem StandardChunkHeader StartBlobPtr StartBlobsPtr StartDataPtr StartupPacket StatEntry StatMsgType StdAnalyzeData StdRdOptions StopList StrategyNumber StringInfo StringInfoData SubLink SubLinkType SubPlan SubPlanState SubTransactionId SubXactCallback SubXactCallbackItem SubXactEvent SubqueryScan SubqueryScanState Syn SysCacheIdentifier SysScanDesc SysScanDescData SyscacheCallbackFunction TAR_MEMBER TBMIterateResult TBMIterator TBMStatus TBlockState TIDBitmap TParser TParserCharTest TParserPosition TParserSpecial TParserState TParserStateAction TParserStateActionItem TSAnyCacheEntry TSConfigCacheEntry TSConfigInfo TSDictInfo TSDictionaryCacheEntry TSLexeme TSParserCacheEntry TSParserInfo TSQuery TSQueryData TSQueryParserState TSQueryParserStateData TSQuerySign TSReadPointer TSTemplateInfo TSTokenTypeStorage TSVector TSVectorData TSVectorParseState TSVectorParseStateData TSVectorStat TStoreState TYPCATEGORY TabStatusArray TableDataInfo TableInfo TargetEntry TextFreq TextPositionState TheLexeme TheSubstitute ThingFile TidHashKey TidPath TidScan TidScanState TimeADT TimeInterval TimeIntervalData TimeLineID TimeOffset TimeTzADT Timestamp TimestampTz TmFromChar TmToChar TocEntry TrackFunctionsLevel TrackItem TransInvalidationInfo TransState TransactionId TransactionState TransactionStateData TransactionStmt TransactionStmtKind Trigger TriggerData TriggerDesc TriggerEvent TriggerFlags TriggerInfo TruncateStmt TupOutputState TupSortStatus TupStoreStatus TupleConstr TupleDesc TupleHashEntry TupleHashEntryData TupleHashIterator TupleHashTable TupleHashTableData TupleTable TupleTableData TupleTableSlot Tuplesortstate Tuplestorestate TwoPhaseCallback TwoPhaseFileHeader TwoPhaseLockRecord TwoPhasePgStatRecord TwoPhaseRecordOnDisk TwoPhaseRmgrId TwoPhaseStateData TxidEpoch TxidSnapshot Type TypeCacheEntry TypeCast TypeFuncClass TypeInfo TypeName UI UI_METHOD UI_STRING UI_string_types UNDO_LIST Unique UniquePath UniquePathMethod UniqueState UnlistenStmt UnresolvedTup UnresolvedTupData UpdateStmt UserAuth UserMapping VFunction VRelStats VTupleLink VTupleLinkData VTupleMove VTupleMoveData VacAttrStats VacAttrStatsP VacPage VacPageData VacPageList VacPageListData VacuumStmt ValUnion Value ValuesScan ValuesScanState Var VarBit VarChar VariableAssignHook VariableCache VariableCacheData VariableSetKind VariableSetStmt VariableShowStmt VariableSpace VariableStatData Vfd ViewStmt VirtualTransactionId WAIT_ORDER WHEN_TYPE WindowAgg WindowAggState WindowClause WindowDef WindowFunc WindowFuncExprState WindowFuncLists WindowObject WindowObjectData WindowStatePerAgg WindowStatePerAggData WindowStatePerFunc WindowStatePerFuncData WithClause WordEntry WordEntryIN WordEntryPos WordEntryPosVector WorkTableScan WorkTableScanState WorkerInfo WorkerInfoData Working_State WriteBufPtr WriteBytePtr WriteDataPtr WriteExtraTocPtr X509 X509_ALGOR X509_ATTRIBUTE X509_CERT_AUX X509_CERT_FILE_CTX X509_CINF X509_CRL X509_CRL_INFO X509_EXTENSION X509_HASH_DIR_CTX X509_INFO X509_LOOKUP X509_LOOKUP_METHOD X509_NAME X509_NAME_ENTRY X509_OBJECT X509_OBJECTS X509_PKEY X509_PUBKEY X509_REQ X509_REQ_INFO X509_REVOKED X509_SIG X509_STORE X509_STORE_CTX X509_TRUST X509_VAL X509_algor_st X509_crl_info_st X509_crl_st X509_extension_st X509_info_st X509_name_entry_st X509_name_st X509_objects_st X509_pubkey_st X509_req_info_st X509_req_st X509_revoked_st X509_sig_st X509_val_st XLogContRecord XLogCtlData XLogCtlInsert XLogCtlWrite XLogLongPageHeader XLogLongPageHeaderData XLogPageHeader XLogPageHeaderData XLogRecData XLogRecPtr XLogRecord XLogwrtResult XLogwrtRqst XactCallback XactCallbackItem XactEvent XidCache XidStatus XmlBinaryType XmlExpr XmlExprOp XmlExprState XmlOptionType XmlSerialize XmlStandaloneType YYLTYPE YYSTYPE YY_BUFFER_STATE YY_CHAR _Archive _DestReceiver _FuncCandidateList _IndexList _InhPaths _LIB_VERSION_TYPE _MdfdVec _OidOptions _PQconninfoOption _PQprintOpt _RuneEntry _RuneLocale _RuneRange _SPI_connection _SPI_plan __jmp_buf __sFILE __sbuf __va_type_classes _actions _aggInfo _archiveFormat _archiveHandle _archiveMode _attrDefInfo _backslashResult _castInfo _cfgInfo _constraintInfo _convInfo _defines _dictInfo _dirdesc _dumpableObject _fdwInfo _foreignServerInfo _funcInfo _funmap _helpStruct _hist_entry _hist_state _if_value _include_path _indxInfo _inhInfo _keymap_entry _namespaceInfo _opclassInfo _opfamilyInfo _oprInfo _ossl_old_des_cblock _ossl_old_des_key_schedule _ossl_old_des_ks_struct _outputContext _parallel_slot _procLangInfo _promptStatus _prsInfo _psqlSettings _restoreOptions _restore_args _ruleInfo _shellTypeInfo _tableDataInfo _tableInfo _tc_string _teSection _tmplInfo _tocEntry _triggerInfo _typeInfo _variable _yy_buffer aclitem addrinfo adhoc_opts aes_key_st aff_struct alloc_func arc arcbatch arcp arguments array_unnest_fctx asn1_ctx_st asn1_header_st asn1_method_st asn1_object_st asn1_string_st asn1_string_table_st asn1_type_st assignment assoc_list attrDefault attribute_used_context auth_entry authmem_entry autovac_table av_relation avl_dbase avw_dbase backslashResult bf_key_st bignum_st bio_f_buffer_ctx_struct bio_info_cb bio_method_st bio_st bitmapword bits16 bits32 bits8 bkend bn_blinding_st bn_mont_ctx_st bn_recp_ctx_st bool bt_incomplete_action buf_mem_st buftag bytea cached_re_str cachedesc caddr_t carc cast_key_st catcache catcacheheader catclist catctup cc_t celt char charf check_ungrouped_columns_context chr classes clock_t clockid_t clockinfo cmpEntriesData cmsghdr cname cnfa color colordesc colormap colors comp_ctx_st comp_method_st conf_finish_func conf_init_func conf_method_st conf_st config_bool config_enum config_enum_entry config_generic config_group config_int config_real config_string config_type config_var_value connection const_DES_cblock constrCheck contain_aggs_of_level_context convert_testexpr_context copy_options cost_qual_eval_context createdb_failure_params crypto_ex_data_func_st crypto_ex_data_st cursor cvec daddr_t datetkn deparse_context deparse_namespace descriptor descriptor_item dev_t df_files dfa dh_method dh_st directory_fctx dirent div_t double dropmsgstrings ds_state dsa_method dsa_st encoding_match env_md_ctx_st env_md_st err_state_st errortype evalPlanQual eval_const_expressions_context evp_Encode_Ctx_st evp_cipher_ctx_st evp_cipher_info_st evp_cipher_st evp_pkey_st exception execution_state explain_get_index_name_hook_type f_smgr fcred fd_mask fd_set fdversion fetch_desc finalize_primnode_context find_expr_references_context find_minimum_var_level_context fix_join_expr_context fix_scan_expr_context fix_upper_expr_context fixpt_t flatten_join_alias_vars_context float float4 float8 flock fmNodePtr fmStringInfo fmgr_security_definer_cache fns fp_info fpos_t free_func fsec_t func_ptr generate_series_fctx generate_series_timestamp_fctx generate_series_timestamptz_fctx generate_subscripts_fctx get_attavgwidth_hook_type get_index_stats_hook_type get_relation_info_hook_type get_relation_stats_hook_type gid_t ginIncompleteSplit ginxlogCreatePostingTree ginxlogDeleteListPages ginxlogDeletePage ginxlogInsert ginxlogInsertListPage ginxlogSplit ginxlogUpdateMeta ginxlogVacuumPage gistIncompleteInsert gistxlogInsertComplete gistxlogPage gistxlogPageDelete gistxlogPageSplit gistxlogPageUpdate group guc_stack guts gzFile hashnode hbaPort help_handler hlCheck hostent in6_addr in6_pktinfo in_addr in_addr_t in_multiaddr in_port_t index indexed_tlist inet inet_struct ino_t instr_time int int16 int16_t int16m_t int2 int2vector int32 int32_t int32m_t int4 int64 int64_t int64m_t int8 int8_t int8m_t internal_state intf iovec ip6_mtuinfo ip_mreq ip_opts ipc_perm ipv6_mreq itemIdSort itemIdSortData itimerspec itimerval jmp_buf join_search_hook_type key_t lc_time_T lclContext lclTocEntry lconv ldiv_t lhash_node_st lhash_st lineptr linger loadavg locate_agg_of_level_context locate_var_of_level_context locate_var_of_relation_context locate_windowfunc_context lsinfo mXactCacheEnt macaddr mb2wchar_with_len_converter mbdisplaylen_converter mbinterval mblen_converter mbverifier mdc2_ctx_st mixedStruct mode_t movedb_failure_params msghdr nameData name_value_pair netent nfa nlink_t ntile_context obj_name_st objectType off_t oidvector omsghdr opclasscacheent optType option orlimit osockaddr ostat passwd pcolor pem_ctx_st pem_password_cb pem_recip_st pendingPosition pgNotify pg_crc32 pg_enc pg_enc2name pg_encname pg_encoding pg_local_to_utf pg_local_to_utf_combined pg_on_exit_callback pg_re_flags pg_time_t pg_tm pg_tz pg_tz_cache pg_tzenum pg_utf_to_local pg_utf_to_local_combined pg_uuid_t pg_wchar pg_wchar_tbl pgpid_t pgresAttDesc pgsql_thing_t pgthreadlock_t pid_t pkcs7_digest_st pkcs7_enc_content_st pkcs7_encrypted_st pkcs7_enveloped_st pkcs7_issuer_and_serial_st pkcs7_recip_info_st pkcs7_signed_st pkcs7_signedandenveloped_st pkcs7_signer_info_st pkcs7_st pkcs8_priv_key_info_st planner_hook_type portalhashent pqbool pqsigfunc prep printFormat printQueryOpt printTableContent printTableFooter printTableOpt priv_map private_key_st process_sublinks_context promptStatus_t protoent pthread_attr pthread_attr_t pthread_cond pthread_cond_attr pthread_cond_t pthread_condattr_t pthread_key_t pthread_mutex pthread_mutex_attr pthread_mutex_t pthread_mutexattr_t pthread_once pthread_once_t pthread_queue pthread_t ptrdiff_t ptrs pull_var_clause_context pull_varnos_context q128_t qaddr_t qsort_arg_comparator quad_t rangeTableEntry_used_context rank_context rc2_key_st rc4_key_st reduce_outer_joins_state regex_t regexp_matches_ctx register_t regmatch_t regoff_t regproc relidcacheent relopt_bool relopt_gen relopt_int relopt_kind relopt_parse_elt relopt_real relopt_string relopt_type relopt_value remoteDep rendezvousHashEntry rerr rewrite_event rlimit rm_detail_t rsa_meth_st rsa_st rule rune_t rusage sa_family_t save_buffer saved_macro sbufdesc sched_param segsz_t selinfo sem sembuf semid_ds semun sequence_magic servent shmem_startup_hook_type shmid_ds sig_atomic_t sig_t sigaction sigaltstack sigcontext sighandler_cxt sigjmp_buf signedbitmapword sigset_t sigstack sigvec simplelock size_t slash_option_type slock_t smalldfa smgrid sockaddr sockaddr_in sockaddr_in6 sockaddr_storage sockaddr_un socklen_t sockproto speed_t spell_struct sqlca_t sqlparseInfo sqlparseState ss_lru_item_t ss_scan_location_t ss_scan_locations_t sset ssize_t ssl2_state_st ssl3_buffer_st ssl3_record_st ssl3_state_st ssl_cipher_st ssl_comp_st ssl_crock_st ssl_ctx_st ssl_method_st ssl_session_st ssl_st stack_st stack_t stat stat32 state statement su_symbol subre substitute_actual_parameters_context substitute_actual_srf_parameters_context substitute_multiple_relids_context swblk_t tcflag_t tcp_seq tcphdr teReqs teSection termios text this_type time_t timespec timeval timezone tlist_vinfo tm tree trivalue ts_db_fctx ts_tokentype tsearch_config_match tsearch_readline_state ttinfo ttysize tupleConstr tupleDesc txid typedefs typinfo typmap tzEntry tzhead tztry uInt uIntf uLong uLongf u_char u_int u_int16_t u_int16m_t u_int32_t u_int32m_t u_int64_t u_int64m_t u_int8_t u_int8m_t u_long u_quad_t u_short uchr ucred uid_t uint uint16 uint32 uint64 uint8 uio_rw uio_seg undo_code undo_list unknown ushort utimbuf v_i_state va_list validate_string_relopt varatt_external varattrib_1b varattrib_1b_e varattrib_4b variable varlena vars vfd vm_offset_t vm_size_t void voidp voidpf wait wchar_t wctype_t when winsize wint_t x509_attributes_st x509_cert_aux_st x509_cinf_st x509_file_st x509_hash_dir_st x509_lookup_method_st x509_lookup_st x509_object_st x509_st x509_store_ctx_st x509_store_st x509_trust_st xl_btree_delete xl_btree_delete_page xl_btree_insert xl_btree_metadata xl_btree_newroot xl_btree_split xl_btreetid xl_dbase_create_rec xl_dbase_create_rec_old xl_dbase_drop_rec xl_dbase_drop_rec_old xl_heap_clean xl_heap_delete xl_heap_freeze xl_heap_header xl_heap_inplace xl_heap_insert xl_heap_lock xl_heap_newpage xl_heap_update xl_heaptid xl_invalid_page xl_invalid_page_key xl_multixact_create xl_seq_rec xl_smgr_create xl_smgr_truncate xl_tblspc_create_rec xl_tblspc_drop_rec xl_xact_abort xl_xact_abort_prepared xl_xact_commit xl_xact_commit_prepared xllist xmltype yy_buffer_state yy_size_t yy_state_type yy_trans_info yyalloc yysigned_char yytokentype z_stream z_stream_s z_streamp
Bruce Momjian <bruce@momjian.us> writes: > Andrew Dunstan wrote: >> This is on the 8.3 code. Notice how this is formatted: >> >> hitrate = (float) BufferHitCount *100.0 / ReadBufferCount; > The good news is that LocalBufferHitCount isn't in my list of typedefs > from CVS HEAD, and probably not in 8.3 either. The bad news is that > pgindent pushes the '*' next to the 100.0 in my testing. :-( It's the (float), possibly in combination with the *, that does that. There are many occurrences of this with other type names, eg (double). I think it's too dumb to figure out that this is a cast and not a variable declaration. regards, tom lane