mirror of
https://github.com/ARM-software/workload-automation.git
synced 2025-03-22 10:38:37 +00:00
Merge pull request #128 from ep1cman/glbench_logcat_fix
glbench: Fixed updated logcat format
This commit is contained in:
commit
8d13e1f341
@ -29,6 +29,10 @@ from wlauto.exceptions import WorkloadError
|
|||||||
|
|
||||||
|
|
||||||
DELAY = 2
|
DELAY = 2
|
||||||
|
OLD_RESULT_START_REGEX = re.compile(r'I/TfwActivity\s*\(\s*\d+\):\s+\S+\s+result: {')
|
||||||
|
NEW_RESULT_START_REGEX = re.compile(r'[\d\s:.-]+I\sTfwActivity(\s*\(\s*\d+\))?:\s+\S+\s+result: {')
|
||||||
|
OLD_PREAMBLE_REGEX = re.compile(r'I/TfwActivity\s*\(\s*\d+\):\s+')
|
||||||
|
NEW_PREAMBLE_REGEX = re.compile(r'[\d\s:.-]+I\sTfwActivity(\s*\(\s*\d+\))?:')
|
||||||
|
|
||||||
|
|
||||||
class GlbCorp(ApkWorkload):
|
class GlbCorp(ApkWorkload):
|
||||||
@ -44,8 +48,8 @@ class GlbCorp(ApkWorkload):
|
|||||||
package = 'net.kishonti.gfxbench'
|
package = 'net.kishonti.gfxbench'
|
||||||
activity = 'net.kishonti.benchui.TestActivity'
|
activity = 'net.kishonti.benchui.TestActivity'
|
||||||
|
|
||||||
result_start_regex = re.compile(r'I/TfwActivity\s*\(\s*\d+\):\s+\S+\s+result: {')
|
result_start_regex = None
|
||||||
preamble_regex = re.compile(r'I/TfwActivity\s*\(\s*\d+\):\s+')
|
preamble_regex = None
|
||||||
|
|
||||||
valid_test_ids = [
|
valid_test_ids = [
|
||||||
'gl_alu',
|
'gl_alu',
|
||||||
@ -131,7 +135,14 @@ class GlbCorp(ApkWorkload):
|
|||||||
line = fh.next()
|
line = fh.next()
|
||||||
result_lines = []
|
result_lines = []
|
||||||
while True:
|
while True:
|
||||||
if self.result_start_regex.search(line):
|
if OLD_RESULT_START_REGEX.search(line):
|
||||||
|
self.preamble_regex = OLD_PREAMBLE_REGEX
|
||||||
|
self.result_start_regex = OLD_RESULT_START_REGEX
|
||||||
|
elif NEW_RESULT_START_REGEX.search(line):
|
||||||
|
self.preamble_regex = NEW_PREAMBLE_REGEX
|
||||||
|
self.result_start_regex = NEW_RESULT_START_REGEX
|
||||||
|
|
||||||
|
if self.result_start_regex and self.result_start_regex.search(line):
|
||||||
result_lines.append('{')
|
result_lines.append('{')
|
||||||
line = fh.next()
|
line = fh.next()
|
||||||
while self.preamble_regex.search(line):
|
while self.preamble_regex.search(line):
|
||||||
@ -212,4 +223,3 @@ class GlbRunMonitor(threading.Thread):
|
|||||||
def wait_for_run_end(self, timeout):
|
def wait_for_run_end(self, timeout):
|
||||||
self.run_ended.wait(timeout)
|
self.run_ended.wait(timeout)
|
||||||
self.run_ended.clear()
|
self.run_ended.clear()
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user