From owner-freebsd-current@FreeBSD.ORG Fri Sep 5 02:39:28 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 563E016A4BF for ; Fri, 5 Sep 2003 02:39:28 -0700 (PDT) Received: from mailout08.sul.t-online.com (mailout08.sul.t-online.com [194.25.134.20]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1201143F3F for ; Fri, 5 Sep 2003 02:39:27 -0700 (PDT) (envelope-from Alexander@Leidinger.net) Received: from fwd02.aul.t-online.de by mailout08.sul.t-online.com with smtp id 19vD3m-0002oK-06; Fri, 05 Sep 2003 11:39:18 +0200 Received: from Andro-Beta.Leidinger.net (EkyLLwZageXIfnYEEm4fC0ZAHpBRY0k+ThzcoD4CKYu1nkB2I0nS8m@[217.83.31.76]) by fmrl02.sul.t-online.com with esmtp id 19vD3Z-1ATlFA0; Fri, 5 Sep 2003 11:39:05 +0200 Received: from Magelan.Leidinger.net (Magelan [192.168.1.1]) h859e6Nt017117; Fri, 5 Sep 2003 11:40:07 +0200 (CEST) (envelope-from Alexander@Leidinger.net) Received: from Magelan.Leidinger.net (netchild@localhost [127.0.0.1]) by Magelan.Leidinger.net (8.12.9/8.12.9) with SMTP id h859esvY001159; Fri, 5 Sep 2003 11:40:54 +0200 (CEST) (envelope-from Alexander@Leidinger.net) Date: Fri, 5 Sep 2003 11:40:53 +0200 From: Alexander Leidinger To: Terry Lambert Message-Id: <20030905114053.7bb91783.Alexander@Leidinger.net> In-Reply-To: <3F585230.6868CB64@mindspring.com> References: <20030904180448.021a1b6b.Alexander@Leidinger.net> <20030904162858.GI98381@dan.emsphone.com> <20030905001411.3a9030b3.Alexander@Leidinger.net> <20030904225123.GB39916@dan.emsphone.com> <3F584B85.AAC3A11D@mindspring.com> <20030905105507.51ba3183.Alexander@Leidinger.net> <3F585230.6868CB64@mindspring.com> X-Mailer: Sylpheed version 0.9.3claws (GTK+ 1.2.10; i386-portbld-freebsd5.1) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Seen: false X-ID: EkyLLwZageXIfnYEEm4fC0ZAHpBRY0k+ThzcoD4CKYu1nkB2I0nS8m@t-dialin.net cc: Dan Nelson cc: current@freebsd.org Subject: Re: Question about genassym, locore.s and 0-sizedarrays(showstopper for an icc compiled kernel) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Sep 2003 09:39:28 -0000 On Fri, 05 Sep 2003 02:06:56 -0700 Terry Lambert wrote: > Now try: > > struct foo { > char c; > int i; > long array[]; > }; > > struct foo foo;m > struct foo fee[1]; > struct foo fie[3]; > struct foo foe[0]; > struct foo fum[1]; > > on both compilers. If they end up the same, then Intel needs to > change to using the 0. If they end up different, then they are > broken relative to the C99 standard and zero length arrays a final > elements in structures. % icc -c terry.c terry.c(8): warning #1229: type containing an unknown-size array may alias another element struct foo fee[1]; ^ terry.c(9): warning #1229: type containing an unknown-size array may alias another element struct foo fie[3]; ^ terry.c(10): warning #1229: type containing an unknown-size array may alias another element struct foo foe[0]; ^ terry.c(11): warning #1229: type containing an unknown-size array may alias another element struct foo fum[1]; ^ icc: 00000008 C fee 00000018 C fie 00000008 C foe 00000008 C foo 00000008 C fum gcc: 00000008 C fee 00000018 C fie 00000000 C foe 00000008 C foo 00000008 C fum Bye, Alexander. -- Where do you think you're going today? http://www.Leidinger.net Alexander @ Leidinger.net GPG fingerprint = C518 BC70 E67F 143F BE91 3365 79E2 9C60 B006 3FE7