loopy/kernel/__init__.py
def recursive_insn_dep_map(self):
        """Returns a :class:`dict` mapping an instruction IDs *a*
        to all instruction IDs it directly or indirectly depends
        on.
        """

        result = {}

        def compute_deps(insn_id):
            try:
                return result[insn_id]
            except KeyError:
                pass

            insn = self.id_to_insn[insn_id]
            insn_result = set(insn.depends_on)

            for dep in list(insn.depends_on):
                insn_result.update(compute_deps(dep))

            result[insn_id] = frozenset(insn_result)
            return insn_result

        for insn in self.instructions:
            compute_deps(insn.id)

        return result
Returns a :class:`dict` mapping an instruction IDs *a*
        to all instruction IDs it directly or indirectly depends
        on.
        
Returns a :class:`dict` mapping an instruction IDs *a
to all instruction IDs it directly or indirectly depends
on.
Returns a : class : ` dict ` mapping an instruction IDs * a to all instruction IDs it directly or indirectly depends on .
def recursive_insn_dep_map(self):
        result = {}
        def compute_deps(insn_id):
            try:
                return result[insn_id]
            except KeyError:
                pass
            insn = self.id_to_insn[insn_id]
            insn_result = set(insn.depends_on)
            for dep in list(insn.depends_on):
                insn_result.update(compute_deps(dep))
            result[insn_id] = frozenset(insn_result)
            return insn_result
        for insn in self.instructions:
            compute_deps(insn.id)
        return result
def recursive_insn_dep_map ( self ) : result = { } def compute_deps ( insn_id ) : try : return result [ insn_id ] except KeyError : pass insn = self . id_to_insn [ insn_id ] insn_result = set ( insn . depends_on ) for dep in list ( insn . depends_on ) : insn_result . update ( compute_deps ( dep ) ) result [ insn_id ] = frozenset ( insn_result ) return insn_result for insn in self . instructions : compute_deps ( insn . id ) return result
Returns a :class:`dict` mapping an instruction IDs *a
to all instruction IDs it directly or indirectly depends
on.
Returns a : class : ` dict ` mapping an instruction IDs * a to all instruction IDs it directly or indirectly depends on .
"""Returns a :class:`dict` mapping an instruction IDs *a*
        to all instruction IDs it directly or indirectly depends
        on.
        """
self