lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 20 Sep 2018 15:18:54 -0300
From:   Arnaldo Carvalho de Melo <acme@...nel.org>
To:     Adrian Hunter <adrian.hunter@...el.com>
Cc:     Jiri Olsa <jolsa@...hat.com>, Andi Kleen <ak@...ux.intel.com>,
        linux-kernel@...r.kernel.org
Subject: Re: RFC/error: Re: [PATCH 3/6] perf tools: Improve
 thread_stack__event() for trace begin / end

Em Thu, Sep 20, 2018 at 03:13:52PM -0300, Arnaldo Carvalho de Melo escreveu:
> Em Wed, Sep 19, 2018 at 02:23:35PM +0300, Adrian Hunter escreveu:
> > +		return thread_stack__push(thread->ts, ret_addr,
> > +					  flags && PERF_IP_FLAG_TRACE_END);
> > +	} else if (flags & PERF_IP_FLAG_TRACE_BEGIN) {
> 
> Some of the build containers caught this:
> 
> util/thread-stack.c:274:14: error: use of logical '&&' with constant operand [-Werror,-Wconstant-logical-operand]
>                                           flags && PERF_IP_FLAG_TRACE_END);
>                                                 ^  ~~~~~~~~~~~~~~~~~~~~~~
> util/thread-stack.c:274:14: note: use '&' for a bitwise operation
>                                           flags && PERF_IP_FLAG_TRACE_END);
>                                                 ^~
>                                                 &
> util/thread-stack.c:274:14: note: remove constant to silence this warning
>                                           flags && PERF_IP_FLAG_TRACE_END);
>                                                ~^~~~~~~~~~~~~~~~~~~~~~~~~
> 1 error generated.
> 
> 
> --------------------------
> 
> Should be a '&' as suggested by: 
> 
>   16   146.45 debian:9                      : FAIL gcc (Debian 6.3.0-18+deb9u1) 6.3.0 20170516
>   17   138.35 debian:experimental           : FAIL gcc (Debian 8.2.0-4) 8.2.0

Ok, the compilers that caught this was:

debian:9:            clang version 3.8.1-24 (tags/RELEASE_381/final)
debian:experimental: clang version 6.0.1-6 (tags/RELEASE_601/final)


Those gcc versions (6.3 and 8.2) compiled it without warnings.

- Arnaldo
 
> 
> I'm changing this here, please Ack.
> 
> - Arnaldo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ