From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26273 invoked by alias); 9 Jul 2013 16:37:24 -0000 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 Received: (qmail 26222 invoked by uid 89); 9 Jul 2013 16:37:18 -0000 X-Spam-SWARE-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,SPF_PASS autolearn=ham version=3.3.1 Received: from mail-lb0-f173.google.com (HELO mail-lb0-f173.google.com) (209.85.217.173) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Tue, 09 Jul 2013 16:37:17 +0000 Received: by mail-lb0-f173.google.com with SMTP id v1so4883796lbd.4 for ; Tue, 09 Jul 2013 09:37:14 -0700 (PDT) MIME-Version: 1.0 X-Received: by 10.152.1.102 with SMTP id 6mr13149111lal.49.1373387834690; Tue, 09 Jul 2013 09:37:14 -0700 (PDT) Received: by 10.114.69.240 with HTTP; Tue, 9 Jul 2013 09:37:14 -0700 (PDT) Date: Tue, 09 Jul 2013 16:37:00 -0000 Message-ID: Subject: Pointer arithmetic From: Hendrik Greving To: gcc@gcc.gnu.org Content-Type: text/plain; charset=ISO-8859-1 X-SW-Source: 2013-07/txt/msg00130.txt.bz2 On a machine with ABI ILP32LL64: (insn 123 122 124 (nil) (set (reg:SI 392) (mem:SI (plus:SI (reg/v:SI 386) (reg/v:SI 349)) [0 sec 0 space 0, cmsmode 0 S4 A32])) -1 (nil) (nil)) If we support legitimate memory addresses like [r1+r2] (e.g. indexed addresses), can the above RTL match such a load? I am asking because of overflows, I am not sure how that part is defined, and where the Spec is. What do I need to check in the backend for such a definition? Is this POINTER_SIZE? E.g. what if the machine supports > 32 bits, who is responsible to make sure that there is no overflow > 32 bits in this case? Compiler? Assembler? Or even the user? Thanks, Hendrik