From patchwork Wed Jul 30 13:02:43 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Taras Kondratiuk X-Patchwork-Id: 34523 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-we0-f198.google.com (mail-we0-f198.google.com [74.125.82.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id EBBFB20DCC for ; Wed, 30 Jul 2014 13:03:00 +0000 (UTC) Received: by mail-we0-f198.google.com with SMTP id x48sf776876wes.9 for ; Wed, 30 Jul 2014 06:03:00 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:message-id:date:from:user-agent :mime-version:to:references:in-reply-to:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list:content-type :content-transfer-encoding; bh=Ud3xm9Wnkg0XUneYrsP0spb6Va3NFKuw9Ut+wEiOzUQ=; b=TQXHbHIYtUe/LdevKrjae5XflNxCue2Z8uNSS+nIcrWPPeywwZM/qIxduSe/byexMU bIYiBmTN3EFzDV8x84pCZpBqMoZyjUsEHZvAXAkaimXb8Ttv8cZdRcWJfrWHtQ3uan1L CXp1dPwdNGE/lBdloUuQNYTTaVpO/pwVQ4cX2QUAUAzCY5sWEEBIlwF4MW/8NWR5s2E9 BtPxzXzaNI2URxDweO9pFVvIjMBqeTG5X+lDXwOZ5Wjh39P1htYMUhUPnS9svGIGSuVJ u/K8ciVcn4kcJUpQREFekp2j8x6jiLCOO1LNnBGN0X/5Xy746NeZZUvkPgKMEdKL6sna mw+w== X-Gm-Message-State: ALoCoQlj/1U725airarUrcbHWI4QLEb9puN7h8YpTKECND1CObQ0M3jP1Pd/37tAoe9gsG4+janD X-Received: by 10.152.36.170 with SMTP id r10mr58603laj.9.1406725379362; Wed, 30 Jul 2014 06:02:59 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.88.199 with SMTP id t65ls556605qgd.93.gmail; Wed, 30 Jul 2014 06:02:59 -0700 (PDT) X-Received: by 10.52.243.10 with SMTP id wu10mr7590679vdc.45.1406725379141; Wed, 30 Jul 2014 06:02:59 -0700 (PDT) Received: from mail-vc0-f170.google.com (mail-vc0-f170.google.com [209.85.220.170]) by mx.google.com with ESMTPS id iw8si1533549vdb.59.2014.07.30.06.02.59 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 30 Jul 2014 06:02:59 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.170 as permitted sender) client-ip=209.85.220.170; Received: by mail-vc0-f170.google.com with SMTP id lf12so1680971vcb.15 for ; Wed, 30 Jul 2014 06:02:59 -0700 (PDT) X-Received: by 10.220.15.8 with SMTP id i8mr4142512vca.45.1406725379052; Wed, 30 Jul 2014 06:02:59 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp25839vcb; Wed, 30 Jul 2014 06:02:58 -0700 (PDT) X-Received: by 10.224.152.5 with SMTP id e5mr6539614qaw.65.1406725378157; Wed, 30 Jul 2014 06:02:58 -0700 (PDT) Received: from ip-10-141-164-156.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id i68si3819786qgd.15.2014.07.30.06.02.57 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Wed, 30 Jul 2014 06:02:58 -0700 (PDT) Received-SPF: none (google.com: lng-odp-bounces@lists.linaro.org does not designate permitted sender hosts) client-ip=54.225.227.206; Received: from localhost ([127.0.0.1] helo=ip-10-141-164-156.ec2.internal) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XCTWz-0006xI-5L; Wed, 30 Jul 2014 13:02:57 +0000 Received: from mail-lb0-f179.google.com ([209.85.217.179]) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1XCTWt-0006wm-PS for lng-odp@lists.linaro.org; Wed, 30 Jul 2014 13:02:51 +0000 Received: by mail-lb0-f179.google.com with SMTP id v6so837928lbi.38 for ; Wed, 30 Jul 2014 06:02:45 -0700 (PDT) X-Received: by 10.112.162.229 with SMTP id yd5mr4167328lbb.29.1406725365318; Wed, 30 Jul 2014 06:02:45 -0700 (PDT) Received: from [172.22.39.11] ([195.238.92.128]) by mx.google.com with ESMTPSA id q10sm1205267lal.37.2014.07.30.06.02.44 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 30 Jul 2014 06:02:44 -0700 (PDT) Message-ID: <53D8ECF3.20007@linaro.org> Date: Wed, 30 Jul 2014 16:02:43 +0300 From: Taras Kondratiuk User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.0 MIME-Version: 1.0 To: Ciprian Barbu , lng-odp References: In-Reply-To: Subject: Re: [lng-odp] ODP debug -O0 X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: lng-odp-bounces@lists.linaro.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: taras.kondratiuk@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.170 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 On 07/30/2014 03:55 PM, Ciprian Barbu wrote: > Hi, > > How would I be able to compile ODP with debug symbols and -O0? The > configure script is automatically generated to compile with -O2 and > passing additionally CFLAGS=-O0 doesn't really do the trick. We should > be able to remove -O2 from CFLAGS altogether if needed. Or maybe it's > already possible with autotools? I'm using following patch to control debug info and optimization level via --enable-debug. diff --git a/configure.ac b/configure.ac index a5b0241..1124299 100644 --- a/configure.ac +++ b/configure.ac @@ -76,12 +76,16 @@ AM_CONDITIONAL([ODP_NETMAP_ENABLED], [test x$netmap_support = xyes ]) # Enable/disable ODP_DEBUG_PRINT ########################################################################## ODP_DEBUG=1 +ODP_DEBUG_INFO="-ggdb3" +ODP_OPT_LEVEL="-O0" AC_ARG_ENABLE([debug], [ --enable-debug Enable/disable debug], [if ! test "x$enableval" = "xyes"; then ODP_DEBUG=0 + ODP_DEBUG_INFO="" + ODP_OPT_LEVEL="-O3" fi]) -ODP_CFLAGS="$ODP_CFLAGS -DODP_DEBUG_PRINT=$ODP_DEBUG" +ODP_CFLAGS="$ODP_CFLAGS -DODP_DEBUG_PRINT=$ODP_DEBUG $ODP_DEBUG_INFO $ODP_OPT_LEVEL" ########################################################################## # Check for pthreads availability