From patchwork Mon Sep 13 20:53:21 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 64653 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 9A154B70A6 for ; Tue, 14 Sep 2010 06:53:31 +1000 (EST) Received: (qmail 22956 invoked by alias); 13 Sep 2010 20:53:29 -0000 Received: (qmail 22948 invoked by uid 22791); 13 Sep 2010 20:53:28 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE X-Spam-Check-By: sourceware.org Received: from mail-vw0-f47.google.com (HELO mail-vw0-f47.google.com) (209.85.212.47) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 13 Sep 2010 20:53:23 +0000 Received: by vws9 with SMTP id 9so5276482vws.20 for ; Mon, 13 Sep 2010 13:53:21 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.128.200 with SMTP id l8mr2764387vcs.33.1284411201346; Mon, 13 Sep 2010 13:53:21 -0700 (PDT) Received: by 10.220.78.193 with HTTP; Mon, 13 Sep 2010 13:53:21 -0700 (PDT) In-Reply-To: References: Date: Mon, 13 Sep 2010 13:53:21 -0700 Message-ID: Subject: Re: PATCH: Fix bootstrap on x86 From: "H.J. Lu" To: Andrew Pinski Cc: Uros Bizjak , gcc-patches@gcc.gnu.org X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org On Mon, Sep 13, 2010 at 1:38 PM, Andrew Pinski wrote: > On Mon, Sep 13, 2010 at 1:35 PM, H.J. Lu wrote: >>>>        * config/i386/i386.h (ix86_tune_indices): Likewise. >>>>        (TARGET_VECTORIZE_DOUBLE): New. >>>>        (UNITS_PER_SIMD_WORD): Defined with ix86_units_per_simd_word. > > I think it is time to change UNITS_PER_SIMD_WORD into a target hook > rather than including tm_p.h everywhere. > I can change it to a target hook. BTW, I am enclosing the complete patch with ChangeLog. diff --git a/gcc/config/i386/i386-protos.h b/gcc/config/i386/i386-protos.h index 43c86e8..9004531 100644 --- a/gcc/config/i386/i386-protos.h +++ b/gcc/config/i386/i386-protos.h @@ -38,6 +38,8 @@ extern void ix86_output_addr_diff_elt (FILE *, int, int); extern enum calling_abi ix86_cfun_abi (void); extern enum calling_abi ix86_function_type_abi (const_tree); +extern unsigned int ix86_units_per_simd_word (enum machine_mode); + #ifdef RTX_CODE extern int standard_80387_constant_p (rtx); extern const char *standard_80387_constant_opcode (rtx); @@ -50,7 +52,6 @@ extern bool x86_extended_QIreg_mentioned_p (rtx); extern bool x86_extended_reg_mentioned_p (rtx); extern bool x86_maybe_negate_const_int (rtx *, enum machine_mode); extern enum machine_mode ix86_cc_mode (enum rtx_code, rtx, rtx); -extern unsigned int ix86_units_per_simd_word (enum machine_mode); extern int avx_vpermilp_parallel (rtx par, enum machine_mode mode); extern int avx_vperm2f128_parallel (rtx par, enum machine_mode mode); diff --git a/gcc/tree-vect-stmts.c b/gcc/tree-vect-stmts.c index 6d15bda..be5dec0 100644 --- a/gcc/tree-vect-stmts.c +++ b/gcc/tree-vect-stmts.c @@ -26,6 +26,7 @@ along with GCC; see the file COPYING3. If not see #include "tm.h" #include "ggc.h" #include "tree.h" +#include "tm_p.h" #include "target.h" #include "basic-block.h" #include "tree-pretty-print.h"