Deleted Added
sdiff udiff text old ( 13137:a3750228268f ) new ( 13139:78d9cd67bbdf )
full compact
1#!/usr/bin/env python2
2#
3# Copyright 2018 Google, Inc.
4#
5# Redistribution and use in source and binary forms, with or without
6# modification, are permitted provided that the following conditions are
7# met: redistributions of source code must retain the above copyright
8# notice, this list of conditions and the following disclaimer;

--- 196 unchanged lines hidden (view full) ---

205 return tagged_filt('Info', num)
206
207class LogChecker(Checker):
208 def merge_filts(*filts):
209 filts = map(lambda f: '(' + f + ')', filts)
210 filts = '|'.join(filts)
211 return re.compile(filts, flags=re.MULTILINE)
212
213 ref_filt = merge_filts(
214 r'^\nInfo: /OSCI/SystemC: Simulation stopped by user.\n',
215 r'^SystemC Simulation\n',
216 r'^\nInfo: \(I804\) /IEEE_Std_1666/deprecated: ' +
217 r'You can turn off(.*\n){7}',
218 r'^\nInfo: \(I804\) /IEEE_Std_1666/deprecated: \n' +
219 r' sc_clock\(const char(.*\n){3}',
220 warning_filt(540),
221 warning_filt(569),
222 warning_filt(571),
223 error_filt(541),
224 error_filt(542),
225 error_filt(543),
226 info_filt(804),
227 )
228 test_filt = merge_filts(
229 r'^Global frequency set at \d* ticks per second\n',
230 info_filt(804),
231 )
232
233 def __init__(self, ref, test, tag, out_dir):
234 super(LogChecker, self).__init__(ref, test, tag)
235 self.out_dir = out_dir
236
237 def apply_filters(self, data, filts):
238 re.sub(filt, '', data)

--- 311 unchanged lines hidden ---