summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authoreadler <eadler@FreeBSD.org>2012-10-22 02:12:02 +0000
committereadler <eadler@FreeBSD.org>2012-10-22 02:12:02 +0000
commitfb692da3979a13fe7c7dd41cba6fba91d0193366 (patch)
tree29d4d02217e83c84346365579d0edbdefd533c44 /tools
parent23c67e54cea6dd9bbe306361ed5d5150210b1ca9 (diff)
downloadFreeBSD-src-fb692da3979a13fe7c7dd41cba6fba91d0193366.zip
FreeBSD-src-fb692da3979a13fe7c7dd41cba6fba91d0193366.tar.gz
Covert to python 3
Approved by: cperciva MFC after: 3 days
Diffstat (limited to 'tools')
-rwxr-xr-xtools/test/hwpmc/pmctest.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/test/hwpmc/pmctest.py b/tools/test/hwpmc/pmctest.py
index 6495e6a..fb4a977 100755
--- a/tools/test/hwpmc/pmctest.py
+++ b/tools/test/hwpmc/pmctest.py
@@ -68,14 +68,14 @@ def main():
(options, args) = parser.parse_args()
if (options.program == None):
- print "specify program, such as ls, with -p/--program"
+ print("specify program, such as ls, with -p/--program")
sys.exit()
p = subprocess.Popen(["pmccontrol", "-L"], stdout=PIPE)
counters = p.communicate()[0]
if len(counters) <= 0:
- print "no counters found"
+ print("no counters found")
sys.exit()
for counter in counters.split():
@@ -84,10 +84,10 @@ def main():
p = subprocess.Popen(["pmcstat", "-p", counter, options.program],
stdout=PIPE)
result = p.communicate()[0]
- print result
+ print(result)
if (options.wait == True):
try:
- value = raw_input("next?")
+ value = input("next?")
except EOFError:
sys.exit()
OpenPOWER on IntegriCloud