(self, cfg=None, functions=None, loops=None, use_header=False,
                 bound=None, bound_reached=None, discard_stash='spinning',
                 limit_concrete_loops=True)
:param cfg:                   Normalized CFG is required.
        :param functions:             Function(s) containing the loop(s) to be analyzed.
        :param loops:                 Specific group of Loop(s) to be analyzed, if this is None we run the LoopFinder analysis.
        :param use_header:            Whether to use header based trip counter to compare with the bound limit.
        :param bound:                 Limit the number of iterations a loop may be executed.
        :param bound_reached:         If provided, should be a function that takes the LoopSeer and the succ_state.
                                      Will be called when loop execution reach the given bound.
                                      Default to moving states that exceed the loop limit to a discard stash.
        :param discard_stash:         Name of the stash containing states exceeding the loop limit.
        :param limit_concrete_loops:  If False, do not limit a loop back-edge if it is the only successor
                                      (Defaults to True to maintain the original behavior)
:param cfg:                   Normalized CFG is required.
        :param functions:             Function(s) containing the loop(s) to be analyzed.
        :param loops:                 Specific group of Loop(s) to be analyzed, if this is None we run the LoopFinder analysis.
        :param use_header:            Whether to use header based trip counter to compare with the bound limit.
        :param bound:                 Limit the number of iterations a loop may be executed.
        :param bound_reached:         If provided, should be a function that takes the LoopSeer and the succ_state.
                                      Will be called when loop execution reach the given bound.
                                      Default to moving states that exceed the loop limit to a discard stash.
        :param discard_stash:         Name of the stash containing states exceeding the loop limit.
        :param limit_concrete_loops:  If False, do not limit a loop back-edge if it is the only successor
                                      (Defaults to True to maintain the original behavior)
: param cfg : Normalized CFG is required . : param functions : Function ( s ) containing the loop ( s ) to be analyzed . : param loops : Specific group of Loop ( s ) to be analyzed if this is None we run the LoopFinder analysis . : param use_header : Whether to use header based trip counter to compare with the bound limit . : param bound : Limit the number of iterations a loop may be executed . : param bound_reached : If provided should be a function that takes the LoopSeer and the succ_state . Will be called when loop execution reach the given bound . Default to moving states that exceed the loop limit to a discard stash . : param discard_stash : Name of the stash containing states exceeding the loop limit . : param limit_concrete_loops : If False do not limit a loop back - edge if it is the only successor ( Defaults to True to maintain the original behavior )
def __init__(self, cfg=None, functions=None, loops=None, use_header=False,
                 bound=None, bound_reached=None, discard_stash='spinning',
                 limit_concrete_loops=True):
        """
        :param cfg:                   Normalized CFG is required.
        :param functions:             Function(s) containing the loop(s) to be analyzed.
        :param loops:                 Specific group of Loop(s) to be analyzed, if this is None we run the LoopFinder analysis.
        :param use_header:            Whether to use header based trip counter to compare with the bound limit.
        :param bound:                 Limit the number of iterations a loop may be executed.
        :param bound_reached:         If provided, should be a function that takes the LoopSeer and the succ_state.
                                      Will be called when loop execution reach the given bound.
                                      Default to moving states that exceed the loop limit to a discard stash.
        :param discard_stash:         Name of the stash containing states exceeding the loop limit.
        :param limit_concrete_loops:  If False, do not limit a loop back-edge if it is the only successor
                                      (Defaults to True to maintain the original behavior)
        """

        super(LoopSeer, self).__init__()
        self.cfg = cfg
        self.functions = functions
        self.bound = bound
        self.bound_reached = bound_reached
        self.discard_stash = discard_stash
        self.use_header = use_header
        self.limit_concrete_loops = limit_concrete_loops
        self.loops = {}
        self.cut_succs = []
        if type(loops) is Loop:
            loops = [loops]

        if type(loops) in (list, tuple) and all(type(l) is Loop for l in loops):
            for loop in loops:
                if loop.entry_edges:
                    self.loops[loop.entry_edges[0][1].addr] = loop

        elif loops is not None:
            raise TypeError("Invalid type for 'loops' parameter!")
def __init__ ( self , cfg = None , functions = None , loops = None , use_header = False , bound = None , bound_reached = None , discard_stash = 'spinning' , limit_concrete_loops = True ) : super ( LoopSeer , self ) . __init__ ( ) self . cfg = cfg self . functions = functions self . bound = bound self . bound_reached = bound_reached self . discard_stash = discard_stash self . use_header = use_header self . limit_concrete_loops = limit_concrete_loops self . loops = { } self . cut_succs = [ ] if type ( loops ) is Loop : loops = [ loops ] if type ( loops ) in ( list , tuple ) and all ( type ( l ) is Loop for l in loops ) : for loop in loops : if loop . entry_edges : self . loops [ loop . entry_edges [ 0 ] [ 1 ] . addr ] = loop elif loops is not None : raise TypeError ( "Invalid type for 'loops' parameter!" )