From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6865 invoked by alias); 29 Aug 2003 04:10:50 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 6797 invoked from network); 29 Aug 2003 04:10:37 -0000 Received: from unknown (HELO fencepost.gnu.org) (199.232.76.164) by sources.redhat.com with SMTP; 29 Aug 2003 04:10:37 -0000 Received: from monty-python.gnu.org ([199.232.76.173]) by fencepost.gnu.org with esmtp (Exim 4.20) id 19saXE-0004JR-Jx for gcc@gnu.org; Fri, 29 Aug 2003 00:06:52 -0400 Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.22) id 19saaW-0005OO-Pi for gcc@gnu.org; Fri, 29 Aug 2003 00:10:17 -0400 Received: from [210.212.228.4] (helo=cnet.nitc.ac.in) by monty-python.gnu.org with esmtp (Exim 4.22) id 19saZT-0004Y9-Gj for gcc@gnu.org; Fri, 29 Aug 2003 00:09:11 -0400 Received: from ebox.nitc.ac.in (ebox.nitc.ac.in [210.212.228.3]) by cnet.nitc.ac.in (8.12.8/8.12.8) with ESMTP id h7T42nJS004331; Fri, 29 Aug 2003 09:32:49 +0530 Received: from nitc.ac.in (cnc.nitc.ac.in [127.0.0.1]) by ebox.nitc.ac.in (8.11.6/8.11.6) with SMTP id h7T452f24407; Fri, 29 Aug 2003 09:35:15 +0530 Received: from 210.212.228.79 (nitc authenticated user csy2p100) by ebox.nitc.ac.in with HTTP; Fri, 29 Aug 2003 09:35:15 +0530 (IST) Message-ID: <2433.210.212.228.79.1062129915.webmail@ebox.nitc.ac.in> Date: Fri, 29 Aug 2003 14:41:00 -0000 Subject: RTL From: "SRUTHY C.N." To: , MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Status: No, hits=0.7 required=5.0 tests=FROM_ENDS_IN_NUMS version=2.55 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) X-SW-Source: 2003-08/txt/msg01728.txt.bz2 Message-ID: <20030829144100.IEJniRWDpASojgpnYaI_CJPITi6Mu7cvBhqi54mJ94k@z> Sir, 1: At first one of you have replied that int variable's declared will take 4 byte alignment. Then in the "System V ABI documentation for intel 386 " , it is given that aggregates like structures etc..take the alignment of most strictly aligned component..When I declare 2 int and one file pointer they took totally 12 bytes then a structure has declared in its declaration 3 int & 2 char variables are there int i,j; //8 bytes FILE *fp; //4 bytes struct node {int a; int b; char c; int d; char e; }nd; accordig to the ABI documentation (by considering tail & internal padding) it should take 20 bytes. And it is assigned at offset -48 (int a) to offset -32 (char e). In between 16 bytes has been skipped.Why is this happening? if I remove one var (for ex: int b) it will start from -32 to -20? why this alignment to multiple of 16? here target is pentium 3. 2: Is RTL representation dependent on GCC version? In linux 9 gcc version was 3.2.2 and in linux 7 GCC version was 2.96 and both system is using same target pentium 3. and there is slight variation in the RTL file generated. is it due to change in gcc version or anything else? Thanking you, SRUTHY C.N.