Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3816718imu; Fri, 18 Jan 2019 18:39:14 -0800 (PST) X-Google-Smtp-Source: ALg8bN771a+IG9goVcYgZdUR07JHu2X74OtYZhjULtJx1mUPlUTmYyfTYjiyWhW1d9gQ+ae/KwP7 X-Received: by 2002:a63:89c2:: with SMTP id v185mr18728823pgd.97.1547865554303; Fri, 18 Jan 2019 18:39:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547865554; cv=none; d=google.com; s=arc-20160816; b=x2UkLlqSUUHYAb/d12YzGdYTzXMX5RppI5/5Qt4DQ1oNxA2/0BSw/9J28q76L1Lwl6 DBATIPLUrq49ZN6A3FZ/exakpwJ/fKcNPewe6F9753x7aZrKk8n1DMNN8rDFGW1yDryd aGAMOMavHsniu5zeYEjJIblaO2Yt5w0gu9iKgQhgULLiLMt0eP3KAnP5YK0UcSvB8F0S P1oKE3EzrwpkvZf//SABTKDRUZTKHh9tq8qFjhkV+2hwzKY6lunFR5gJqPFeKHsuPVUg Jo9GWJtQcKOD+B6a6peCY8y7RAZN7XyybBCRYPFBg0vtit9jtaBXkJE+KdKlrMZq8XOR ISWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:autocrypt:openpgp:references:to:from:subject; bh=ZVNTDP3+zKUEY3VQg1RLH6k/7m+G8XdoOsnsQzMZj+8=; b=rP3bMbOCXkhopnc+NKc5vERXXWzZquxjtEdQtZRUccw9T3RwZSvTq7AKNbmuzdOC21 AK281x5br+co+yRaeVByWwpgaOU3cKrrs1hnfLfpafy++1CG4oHArefk0XqP1/VhVFrR 95GR2s+u2d7Bi34Y+OHYebGmaO+qNWhG52j8qwrWLiDw96K2CIixdrRhBEW31RESTBIo yxgjA2Rh2YLFu62wfSFKicSOn0Snf8OtEJTsDNkjzOCwe40uzAUwEr24xNpieFixDeOD uYvYmMygl7TqOTrtAXNPzsH7SGqICPf0ZoOM4jPPT+5vqXtPc3YmTISmm6Baf/OPi6oe r9OQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n12si5807640pgb.563.2019.01.18.18.38.55; Fri, 18 Jan 2019 18:39:14 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730388AbfASChk (ORCPT + 99 others); Fri, 18 Jan 2019 21:37:40 -0500 Received: from mx2.suse.de ([195.135.220.15]:44372 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1730318AbfASChk (ORCPT ); Fri, 18 Jan 2019 21:37:40 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 52536AD54; Sat, 19 Jan 2019 02:37:39 +0000 (UTC) Subject: Re: [PATCH v2] perf scripts python: Add Python 3 support to failed-syscalls-by-pid.py From: Tony Jones To: Seeteena Thoufeek , peterz@infradead.org, mingo@redhat.com, acme@kernel.org, alexander.shishkin@linux.intel.com, jolsa@redhat.com, namhyung@kernel.org, linux-kernel@vger.kernel.org References: <1547718344-27382-1-git-send-email-s1seetee@linux.vnet.ibm.com> <1547718344-27382-5-git-send-email-s1seetee@linux.vnet.ibm.com> <7f78e394-9cc3-e3fc-0497-d0ff0216d331@suse.de> Openpgp: preference=signencrypt Autocrypt: addr=tonyj@suse.de; prefer-encrypt=mutual; keydata= mQGiBEkQmbwRBACDch7wo/RzlNt2HA8jLICsO2w8yOkJ7UTzHYNn3Q83Ro0qev2KokfE3EDw il+vam9CDR7jIDmswHqaMe0/O+UnZtO5PlDgylZcrwNwbBzHfm/KGejbi1RBGAoETrvcfwGi w83bR/aDnoRXY5Ho1uphQ05/065EMpbJOOBdn9qQ4wCgv2Q6C/QeYDGsxJPRO+20nLu5K00D /Rde4OTZ5biM+vb6ObTmgPNeiMrTwGpMokN7audIl7njwvD+lYrlgQjmDzcaPFz29rYWwT7g 6t6hcFgjpU1he/v3qxeQlTJoi2+u5Mqj42z//49h6DqNjT859Z/6h5IwKBo/EZC17iBIlS2G VXAstNiZASGiaIlONozWJ/GSjUaRA/9wZTV1nXF/+xX+qmc7SvTg1w6jWyjxVumQLoq2SeA4 1Sy5X2IATkAGCCjbeoQGnFdbOnHRSJdlTazObgwreqGPlPnIROpr9QESkfxsaCkDiZfpl0xk 6X069QMZBEwGAWILHYXL9UqlOjniZaU2BkVA11JEdBhyQorC8T/ji1edc7QaVG9ueSBKb25l cyA8dG9ueWpAc3VzZS5kZT6IYAQTEQIAIAUCSRCZvAIbAwYLCQgHAwIEFQIIAwQWAgMBAh4B AheAAAoJELFYWyEf4koXGmYAoKCnbv9dhAB2vR6IvSJem1ws4HpfAJ9ZqTKiXcogBGfTPaJR GI9QhVUieLkCDQRJEJm8EAgAzr9Zd3v7B10ODtVc7XxbMe3W6o1FdClL9ZIgLv61zhWctafK DMu/MUSvxmYFq00pecD/SfX8oxArA02+sQ2E+/Zb4J7NAWIAxCfmy7VE0wDBrZH/hBapIx/L gVqYfZ9Rw+a4FXrlk1y8oQCwhvj+kWrm7V7olR0aPOy1NFGNUyTFSMj+pbmxiNOXdCxVUQe3 UE1k9yA+mILjyaRanwkiCLCjNvRPL88Q017BdhVBWZmz8qhwXN/RrjCcDHsPX5O0ev68MLyu sh5mfukuvCqzW1Y3Ql+iwfwEw5lNmQGdoV9csg7JP7saDicSFO2KcZvMbvDMqtPFipdF5UWo fZKZ3wADBQf/b5cVNyb5i8QI0G7BPGBNn4VlQX5n66TsPBnrRNOi3MhTTVEBCp8s+jqUjJjX EjjA+O4hIm7Qqdsozurw7GlcQ0A06dIzO/1RUglZZMoC0JL43ZQmJ+3+yFrLjWgGH6ev6AOb YLH7ZujgAB5n0Hy2ZIChzsKLKbHptFtBvpDKB8updq+GunsY4oN3wGa67h9sHqDvjyp64Czg n8G5uGLwx3f/edbECKz5kPUSzChEk3suK742SEP01v4ra5WX88Hn81NjGByQMz9acJLdC7Ff LzXvbNa0KgvDaSllYfsJIoGCz3eKVOuTWXOiaEIKuy833+3mr2PulLCyLKysAEddKohJBBgR AgAJBQJJEJm8AhsMAAoJELFYWyEf4koXhgQAn1EGATLZPS53At9t+p3S8BkNI9yRAJ9A0OmL liv+rwEesYGlGeGNaKHTJw== Message-ID: <463ab33a-7ba0-0358-0be9-c0bb17a02785@suse.de> Date: Fri, 18 Jan 2019 18:37:34 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 In-Reply-To: <7f78e394-9cc3-e3fc-0497-d0ff0216d331@suse.de> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 1/18/19 5:12 PM, Tony Jones wrote: > On 1/17/19 1:45 AM, Seeteena Thoufeek wrote: > >> +from __future__ import print_function > > You don't need this unless you're actually requiring functionality that only exists in v3. > For example, you need it to handle the suppress newline functionality such as "end=". Also, it brings up a question I had. What python versions are expected to be supported with PYTHON=python2? https://python-future.org/imports.html So importing from future (for end='' support) implies >= 2.6. The base release of 2.6 was October 2008 so maybe this is fine. Otherwise it may be preferable to use sys.stdout.write which has more consistent semantics (see tools/perf/scripts/python/compaction-times.py) Tony