From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15807 invoked by alias); 16 Jun 2009 14:41:14 -0000 Received: (qmail 15788 invoked by uid 22791); 16 Jun 2009 14:41:12 -0000 X-SWARE-Spam-Status: No, hits=-2.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS X-Spam-Check-By: sourceware.org Received: from smtp-out.google.com (HELO smtp-out.google.com) (216.239.45.13) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 16 Jun 2009 14:41:03 +0000 Received: from spaceape12.eur.corp.google.com (spaceape12.eur.corp.google.com [172.28.16.146]) by smtp-out.google.com with ESMTP id n5GEexE1000670 for ; Tue, 16 Jun 2009 07:41:00 -0700 Received: from pxi42 (pxi42.prod.google.com [10.243.27.42]) by spaceape12.eur.corp.google.com with ESMTP id n5GEeubH011015 for ; Tue, 16 Jun 2009 07:40:56 -0700 Received: by pxi42 with SMTP id 42so1354341pxi.22 for ; Tue, 16 Jun 2009 07:40:55 -0700 (PDT) Received: by 10.114.144.11 with SMTP id r11mr13794821wad.227.1245163255789; Tue, 16 Jun 2009 07:40:55 -0700 (PDT) Received: from localhost.localdomain.google.com ([67.218.105.128]) by mx.google.com with ESMTPS id k21sm8443129waf.59.2009.06.16.07.40.54 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 16 Jun 2009 07:40:55 -0700 (PDT) To: Tomasz Francuz Cc: gcc@gcc.gnu.org Subject: Re: AVR C++ - how to move vtables into FLASH memory References: <4A376AFD.5020107@mp.pl> From: Ian Lance Taylor Date: Tue, 16 Jun 2009 14:41:00 -0000 In-Reply-To: <4A376AFD.5020107@mp.pl> (Tomasz Francuz's message of "Tue\, 16 Jun 2009 11\:50\:53 +0200") Message-ID: User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-System-Of-Record: true X-IsSubscribed: yes Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2009-06/txt/msg00370.txt.bz2 Tomasz Francuz writes: > I would like to change gcc so AVR C++ port will use FLASH memory > instead of SRAM to store virtual function pointers. Does anyone try to > do it? I have no experience as gcc developer, so can you head me to > appropriate files/literature about this particular problem? This question would be more appropriate for the mailing list gcc-help@gcc.gnu.org than for gcc@gcc.gnu.org. Please take any followups to gcc-help. Thanks. Virtual tables will normally be placed in the .rodata section which holds read-only data. All you should need to do it arrange for the .rodata section to be placed in FLASH rather than SRAM. This would normally be done in your linker script. Ian