From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31390 invoked by alias); 10 Nov 2002 09:10:56 -0000 Mailing-List: contact libc-hacker-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-hacker-owner@sources.redhat.com Received: (qmail 31372 invoked from network); 10 Nov 2002 09:10:55 -0000 Received: from unknown (HELO Cantor.suse.de) (213.95.15.193) by sources.redhat.com with SMTP; 10 Nov 2002 09:10:55 -0000 Received: from Hermes.suse.de (Charybdis.suse.de [213.95.15.201]) by Cantor.suse.de (Postfix) with ESMTP id CF471146C3 for ; Sun, 10 Nov 2002 10:10:54 +0100 (MET) Received: from aj by arthur.inka.de with local (Exim 3.34 #1) id 18Ao7J-0006gh-00 for libc-hacker@sources.redhat.com; Sun, 10 Nov 2002 10:10:53 +0100 To: GNU libc hacker Subject: FYI: GCC warnings about strict-aliasing violation in glibc From: Andreas Jaeger Date: Sun, 10 Nov 2002 01:10:00 -0000 Message-ID: User-Agent: Gnus/5.090008 (Oort Gnus v0.08) XEmacs/21.4 (Artificial Intelligence, i386-suse-linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2002-11/txt/msg00045.txt.bz2 I got the appended warnings (just a quick grep) about violation of strict-aliasing rules with a GCC 3.3 CVS compiler. The majority comes from the NSS code. I suggest to get these fixed and will work on some of them myself, Andreas wctob.c:65: warning: dereferencing type-punned pointer will break strict-aliasing rules wcsrtombs.c:85: warning: dereferencing type-punned pointer will break strict-aliasing rules wcsnrtombs.c:88: warning: dereferencing type-punned pointer will break strict-aliasing rules wctob.c:65: warning: dereferencing type-punned pointer will break strict-aliasing rules wcsrtombs.c:85: warning: dereferencing type-punned pointer will break strict-aliasing rules wcsnrtombs.c:88: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../sysdeps/unix/sysv/linux/getsysstats.c:88: warning: dereferencing type-punned pointer will break strict-aliasing rules ../sysdeps/unix/sysv/linux/getsysstats.c:88: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:68: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:80: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:107: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:117: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:150: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:171: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:183: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:68: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:80: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:107: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:117: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:150: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:171: warning: dereferencing type-punned pointer will break strict-aliasing rules getnssent_r.c:183: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_hton.c:49: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_hton.c:70: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_ntoh.c:50: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_ntoh.c:71: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:105: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:111: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:168: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:175: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:209: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:265: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:318: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:330: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:392: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:397: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_hton.c:49: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_hton.c:70: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_ntoh.c:50: warning: dereferencing type-punned pointer will break strict-aliasing rules ether_ntoh.c:71: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:105: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:111: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:168: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:175: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:209: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:265: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:318: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:330: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:392: warning: dereferencing type-punned pointer will break strict-aliasing rules getnetgrent_r.c:397: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXent.c:82: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:51: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:70: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:90: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:109: warning: dereferencing type-punned pointer will break strict-aliasing rules netname.c:156: warning: dereferencing type-punned pointer will break strict-aliasing rules netname.c:175: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:51: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:70: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:90: warning: dereferencing type-punned pointer will break strict-aliasing rules publickey.c:109: warning: dereferencing type-punned pointer will break strict-aliasing rules netname.c:156: warning: dereferencing type-punned pointer will break strict-aliasing rules netname.c:175: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:612: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:629: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:948: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:984: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:1173: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:1328: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:3048: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:3311: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:3320: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:3337: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:3522: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:3576: warning: dereferencing type-punned pointer will break strict-aliasing rules programs/ld-collate.c:3584: warning: dereferencing type-punned pointer will break strict-aliasing rules gethnamaddr.c:622: warning: dereferencing type-punned pointer will break strict-aliasing rules gethnamaddr.c:712: warning: dereferencing type-punned pointer will break strict-aliasing rules gethnamaddr.c:717: warning: dereferencing type-punned pointer will break strict-aliasing rules res_send.c:565: warning: dereferencing type-punned pointer will break strict-aliasing rules gethnamaddr.c:622: warning: dereferencing type-punned pointer will break strict-aliasing rules gethnamaddr.c:712: warning: dereferencing type-punned pointer will break strict-aliasing rules gethnamaddr.c:717: warning: dereferencing type-punned pointer will break strict-aliasing rules res_send.c:565: warning: dereferencing type-punned pointer will break strict-aliasing rules nss_dns/dns-host.c:176: warning: dereferencing type-punned pointer will break strict-aliasing rules nss_dns/dns-host.c:193: warning: dereferencing type-punned pointer will break strict-aliasing rules nss_dns/dns-host.c:311: warning: dereferencing type-punned pointer will break strict-aliasing rules nss_dns/dns-host.c:317: warning: dereferencing type-punned pointer will break strict-aliasing rules nss_dns/dns-network.c:126: warning: dereferencing type-punned pointer will break strict-aliasing rules nss_dns/dns-network.c:196: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:178: warning: dereferencing type-punned pointer will break strict-aliasing rules ../nss/getXXbyYY_r.c:230: warning: dereferencing type-punned pointer will break strict-aliasing rules -- Andreas Jaeger SuSE Labs aj@suse.de private aj@arthur.inka.de http://www.suse.de/~aj