From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 93798 invoked by alias); 30 Oct 2017 11:31:05 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 93772 invoked by uid 89); 30 Oct 2017 11:31:05 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=H*r:sk:static. X-HELO: mail-wm0-f47.google.com Received: from mail-wm0-f47.google.com (HELO mail-wm0-f47.google.com) (74.125.82.47) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 30 Oct 2017 11:31:02 +0000 Received: by mail-wm0-f47.google.com with SMTP id t139so15740928wmt.1 for ; Mon, 30 Oct 2017 04:31:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version:content-transfer-encoding; bh=c5mvRy54bdziaVjHKpfLXBG1gijHcFOn4ruBqJjw1GA=; b=LI0mU5kdKscWx7XQ4QzBFeCnkXrP/8BDeTvmskP40oRR+/i3TTtEDpf6BmCoczxzJh kImYP7lFw5W3BKcVhdu6/3YHrCfCgESTA7n0I2t0OG54uL9YbOiOrziqgRwklTqFVxUP xDnZ+1akpo35YWFKLjzHIjai10eD1g29YNdi0/Sk1aw3tzPbOCg+yls3rMRegTCJJIBP bkyWHksTVMcj3Hq4E8+ihAh5FWJstXrqPa8SXtZU5bx3rm8Av/zMEJe7/deXxLdx1jof I2usvBI/JcN4RUDEw2iXoPnogOA+QDi/2TsKBBu6Yjvs08ddaiOBV/Au+Ek2dp/VeIYy X/+A== X-Gm-Message-State: AMCzsaUgZNX5rr0JQC7WVh9KuACmBvE75XBPlzpd6bFTNy+y8I2pZSd0 r6yi6ctud7UMLYeUcQgs/rLjSA== X-Google-Smtp-Source: ABhQp+R5P4V5zbMZK4ZqdVcalU3tS/OdtPE/zG8RFxJVmTtS86DYGCLYWzpIfmN1CGRMyxeBwtJp0A== X-Received: by 10.28.31.21 with SMTP id f21mr3196035wmf.18.1509363060684; Mon, 30 Oct 2017 04:31:00 -0700 (PDT) Received: from E107787-LIN (static.42.136.251.148.clients.your-server.de. [148.251.136.42]) by smtp.gmail.com with ESMTPSA id v35sm22234604wrc.13.2017.10.30.04.30.59 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Mon, 30 Oct 2017 04:31:00 -0700 (PDT) From: Yao Qi To: Jan Kratochvil Cc: gdb-patches@sourceware.org Subject: Re: ping#2: [patch] aarch64: PR 19806: watchpoints: false negatives + PR 20207 contiguous ones References: <20170327210753.GA29656@host1.jankratochvil.net> <20171018195237.GA19714@host1.jankratochvil.net> Date: Mon, 30 Oct 2017 11:31:00 -0000 In-Reply-To: <20171018195237.GA19714@host1.jankratochvil.net> (Jan Kratochvil's message of "Wed, 18 Oct 2017 21:52:37 +0200") Message-ID: <863760zxcg.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2017-10/txt/msg00879.txt.bz2 Jan Kratochvil writes: Forget to mention in my last email, > +// TRUE means this kernel has fixed PR external/20207. > +// Fixed kernel supports any contiguous range of bits in 8-bit byte > +// DR_CONTROL_MASK. Buggy kernel supports only 0x01, 0x03, 0x0f and 0xf= f. > +static bool have_any_contiguous (true); We still use /* */ for multi-line comments... > + > +// Return starting byte (0..7) of a watchpoint encoded by CTRL. > + ... and function comment. > +unsigned int > +aarch64_watchpoint_offset (unsigned int ctrl) > +{ > + uint8_t mask =3D DR_CONTROL_MASK (ctrl); > + unsigned retval; > + > + // Shift out bottom zeroes. > + for (retval =3D 0; mask && (mask & 1) =3D=3D 0; ++retval) > + mask >>=3D 1; > + > + return retval; > +} > + --=20 Yao (=E9=BD=90=E5=B0=A7)