From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 53349 invoked by alias); 22 Mar 2018 18:42:45 -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 52863 invoked by uid 89); 22 Mar 2018 18:42:45 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.8 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-oi0-f54.google.com Received: from mail-oi0-f54.google.com (HELO mail-oi0-f54.google.com) (209.85.218.54) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 22 Mar 2018 18:42:43 +0000 Received: by mail-oi0-f54.google.com with SMTP id 71-v6so8242986oie.12 for ; Thu, 22 Mar 2018 11:42:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=PfqvSKTHZ0zw6UkX1WcQj8XXa0Ha8r/m8sN1MEBPpkI=; b=kUTdZ7g1PYa2qBuB7LqF4G0HQWS3Gj3tJM7+TYT7cIj7Yaxv/hGxux56s+3zj0LA8R F3mpB0FELrgM2mERM0nwYC6br2ltVgltlcixuf/r7wKJuv2nUnGPSRgXIJ2AmWIVaqcb /jQlAInzAIDnb+AV3OOCIv4hUGhulbePsmcn9XYnRN4Nqhn6krWwPtn81UvoqHglQfLW sG6Ydov8+QaOmaUkU0i7sS/Zf93cZnnkidPxycBf0Xt4Q6y3gcMS9fHIWuQzOm3RK1HR lIRa37042lhL+A/HEwns8DwGhFs1XPpJOHYwNRbql28cY4t3jEYXWGqAHjev0oH3lr8b fxEA== X-Gm-Message-State: AElRT7F8y5lzZiPk7Y5ISTB+FxlqZD4ZLL/dKZs9nQsDB9FQ9UhTTrTF qJ1K0d6yVXz+mr5cVzjylA9MqyH7QzYqJzI7aAE= X-Google-Smtp-Source: AIpwx48J0Wc+umR4nxM6GuxqZu1uXKhcOaGJhhg+1FaI3hJofnlEVNGr8Ew6GyfXA+wAYv2AF/2iRuWZZQ+BzASmDRg= X-Received: by 10.202.180.67 with SMTP id d64mr3887987oif.104.1521744161748; Thu, 22 Mar 2018 11:42:41 -0700 (PDT) MIME-Version: 1.0 Received: by 10.74.10.20 with HTTP; Thu, 22 Mar 2018 11:42:41 -0700 (PDT) In-Reply-To: <1521742138.18659.59.camel@cavium.com> References: <1521742138.18659.59.camel@cavium.com> From: "H.J. Lu" Date: Thu, 22 Mar 2018 18:42:00 -0000 Message-ID: Subject: Re: Can I use -Ofast without libmvec To: sellcey@cavium.com Cc: gcc Content-Type: text/plain; charset="UTF-8" X-IsSubscribed: yes X-SW-Source: 2018-03/txt/msg00220.txt.bz2 On Thu, Mar 22, 2018 at 11:08 AM, Steve Ellcey wrote: > I have a question about the math vector library routines in libmvec. > If I compile a program on x86 with -Ofast, something like: > > void foo(double * __restrict x, double * __restrict y, double * __restrict z) > { > for (int i = 0; i < 1000; i++) x[i] = sin(y[i]); > } > > I get a call to the vector sin routine _ZGVbN2v_sin. That is fine, but > is there some way to compile with -Ofast and not use the libmvec vector > routines? I have tried -fopenmp, -fopenmp-simd, -fno-openmp, and -fno- > openmp-simd and I always get a call to _ZGVbN2v_sin. Is there anyway > to stop the use of the vectorized calls (without turning off -Ofast)? Have you tried -lm? -- H.J.