From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19685 invoked by alias); 22 Apr 2003 19:25:16 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 19672 invoked from network); 22 Apr 2003 19:25:16 -0000 Received: from unknown (HELO hub.ott.qnx.com) (209.226.137.76) by sources.redhat.com with SMTP; 22 Apr 2003 19:25:16 -0000 Received: from smtp.ott.qnx.com (smtp.ott.qnx.com [10.0.2.158]) by hub.ott.qnx.com (8.9.3p2/8.9.3) with ESMTP id PAA05907; Tue, 22 Apr 2003 15:23:50 -0400 Received: from catdog ([10.4.2.2]) by smtp.ott.qnx.com (8.8.8/8.6.12) with SMTP id PAA11066; Tue, 22 Apr 2003 15:25:14 -0400 Message-ID: <081f01c30904$ea5b7f90$0202040a@catdog> From: "Kris Warkentin" To: "Kris Warkentin" , "Daniel Jacobowitz" Cc: References: <076701c308f6$2f017eb0$0202040a@catdog> <20030422174522.GA728@nevyn.them.org> <080801c30903$2dc0ae60$0202040a@catdog> Subject: Re: long long considered harmful? Date: Tue, 22 Apr 2003 19:25:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 X-SW-Source: 2003-04/txt/msg00255.txt.bz2 > > > typedef struct mips_cpu_registers > > > { > > > unsigned regs[74]; > > > unsigned long long regs_alignment; > > > } MIPS_CPU_REGISTERS; > > > > What's the purpose of the alignment entry? I doubt it does what you > > want it to. > > I was more or less correct on this one. Apparently this was not even > defined by us but by one of our very large chip vendors who shall remain > nameless. Rather than the nicer solution of just defining an array of 64 > bit regs, they did this which necessitates some nastiness when dealing with > different endians. The alignment field ensures that the overall structure > is 64 bit aligned which is a handy thing to be on mips. Pardon me, by overall structure, I mean the starting address of the structure. Having a 64 bit entry causes the compiler to align the structure on a 64 bit boundary. cheers, Kris