This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: gcc's symbol table
- To: gcc at gcc dot gnu dot org, intmktg at CAM dot ORG
- Subject: Re: gcc's symbol table
- From: Mike Stump <mrs at windriver dot com>
- Date: Wed, 2 Aug 2000 19:34:08 -0700 (PDT)
> Date: Wed, 2 Aug 2000 22:06:17 -0400 (EDT)
> From: Marc Tardif <intmktg@CAM.ORG>
> To: gcc@gcc.gnu.org
> I've heard that gcc uses gperf to create a perfect hash function for
> the symbol table. Once a key is hashed and retrieved from the table,
> is it necessary to strcmp in order to verify that the key matches
> the symbol?
Yes, it performs a strcmp after. If you would like to see it, check
out:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/~checkout~/egcs/gcc/cp/hash.h?rev=1.12&content-type=text/plain
Hope this helps.