This is the mail archive of the
mailing list for the GCC project.
Re: [tree-ssa] libbanshee seems to be not 64-bit clean
- From: Daniel Berlin <dberlin at dberlin dot org>
- To: Andreas Jaeger <aj at suse dot de>
- Cc: gcc at gcc dot gnu dot org,Daniel Berlin <dan at cgsoftware dot org>
- Date: Sun, 17 Aug 2003 12:37:42 -0400
- Subject: Re: [tree-ssa] libbanshee seems to be not 64-bit clean
- References: <email@example.com>
On Sunday, August 17, 2003, at 6:41 AM, Andreas Jaeger wrote:
Actually, it does, except when you have different sized pointers and
The following piece of code cannot work correctly IMO:
If this function didn't work, all hell would break loose.
It's just assigning integers to unique strings.
stamp stamp_string(const char *str) deletes
assert(str_hash != NULL);
if (! hash_table_lookup(str_hash,(hash_key)str, (hash_data *) &st))
st = stamp_fresh();
hash_data is a pointer. Daniel, can you look at the code? I don't
fully understand it so I'm not sure how to fix it properly.
Make the stamps use integers the same size as pointers.
Either that, or have it use pointers to integers (and allocate space
for the integers).
Btw. GCC complains about this on a 64-bit platform with:
warning: cast to pointer from integer of different size
There's a similar warning which can be avoided with some extra
cast, the code itself looks correct - but the function is not used
anywhere, we can remove ptr_hash as far as I can see:
Probably, but libbanshee is an external library, so i'd rather #if 0 it
out, than flat out remove it.
warning: cast from pointer to integer of different size
Andreas Jaeger, firstname.lastname@example.org, http://www.suse.de/~aj
SuSE Linux AG, Deutschherrnstr. 15-19, 90429 Nürnberg, Germany
GPG fingerprint = 93A3 365E CE47 B889 DF7F FED1 389A 563C C272 A126