def _specialize_iet(cls, graph, **kwargs): options = kwargs['options'] platform = kwargs['platform'] # Flush denormal numbers avoid_denormals(graph) # Distributed-memory parallelism optimize_halospots(graph) if options['mpi']: mpiize(graph, mode=options['mpi']) # Tiling blocker = Blocker(options['blockinner'], options['blocklevels'] or cls.BLOCK_LEVELS) blocker.make_blocking(graph) # Shared-memory and SIMD-level parallelism ompizer = Ompizer() ompizer.make_simd(graph, simd_reg_size=platform.simd_reg_size) if options['openmp']: ompizer.make_parallel(graph) # Misc optimizations minimize_remainders(graph, simd_items_per_reg=platform.simd_items_per_reg) hoist_prodders(graph) # Symbol definitions data_manager = DataManager() data_manager.place_definitions(graph) data_manager.place_casts(graph) return graph
def _specialize_iet(cls, graph, **kwargs): # Symbol definitions data_manager = DataManager() data_manager.place_definitions(graph) data_manager.place_casts(graph) return graph
def _specialize_iet(cls, graph, **kwargs): options = kwargs['options'] passes = as_tuple(kwargs['mode']) # Fetch passes to be called passes_mapper = cls._make_passes_mapper(**kwargs) # Call passes for i in passes: try: passes_mapper[i](graph) except KeyError: raise InvalidOperator("Unknown passes `%s`" % str(passes)) # Force-call `mpi` if requested via global option if 'mpi' not in passes and options['mpi']: passes_mapper['mpi'](graph) # Force-call `openmp` if requested via global option if 'openmp' not in passes and options['openmp']: passes_mapper['openmp'](graph) # Symbol definitions data_manager = DataManager() data_manager.place_definitions(graph) data_manager.place_casts(graph) return graph
def _specialize_iet(cls, graph, **kwargs): """ Transform the Iteration/Expression tree to offload the computation of one or more loop nests onto YASK. This involves calling the YASK compiler to generate YASK code. Such YASK code is then called from within the transformed Iteration/Expression tree. """ options = kwargs['options'] yk_solns = kwargs['yk_solns'] # Flush denormal numbers avoid_denormals(graph) # Create YASK kernels make_yask_kernels(graph, yk_solns=yk_solns) # Shared-memory and SIMD-level parallelism if options['openmp']: YASKOmpizer().make_parallel(graph) # Misc optimizations loop_wrapping(graph) # Symbol definitions data_manager = DataManager() data_manager.place_definitions(graph) data_manager.place_casts(graph) return graph
def _specialize_iet(cls, graph, **kwargs): # Create OPS kernels make_ops_kernels(graph) # Symbol definitions data_manager = DataManager() data_manager.place_definitions(graph) data_manager.place_casts(graph) return graph
def _specialize_iet(cls, graph, **kwargs): yk_solns = kwargs['yk_solns'] # Create YASK kernels make_yask_kernels(graph, yk_solns=yk_solns) # Symbol definitions data_manager = DataManager() data_manager.place_definitions(graph) data_manager.place_casts(graph) return graph