Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 70 for getRegions (0.47 sec)

  1. tensorflow/compiler/mlir/tensorflow/utils/xla_rewrite_util.cc

        int new_idx = child_idx >= cluster_idx ? child_idx + num_cores_per_replica
                                               : child_idx;
        new_parallel_execute->getRegions()[new_idx].takeBody(
            old_parallel_execute.getRegions()[old_idx]);
      }
    
      return cluster_idx;
    }
    
    mlir::tf_device::LaunchOp WrapOpInLaunch(mlir::OpBuilder* builder,
                                             mlir::Location loc,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 13 03:57:18 UTC 2023
    - 4.4K bytes
    - Viewed (0)
  2. tensorflow/compiler/mlir/tensorflow/transforms/test_resource_alias_analysis.cc

          }
        };
    
        // Assign a unique ID to each value seen in this function.
        func.walk([&](Operation* op) {
          // For all attached regions, assign ID to the region arguments.
          for (Region& region : op->getRegions()) {
            for (auto region_arg : TF::filter_resources(region.getArguments()))
              assign_id(region_arg);
          }
    
          // Assign ID for all results.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Apr 19 00:13:50 UTC 2022
    - 4.4K bytes
    - Viewed (0)
  3. tensorflow/compiler/mlir/tensorflow/transforms/group_by_dialect.cc

            all_internal_results.insert(result);
          }
          // We treat block arguments of inner blocks as "results", too, in
          // the sense that they're values produced inside this op.
          for (Region& region : op->getRegions()) {
            for (Block& block : region.getBlocks()) {
              for (BlockArgument& arg : block.getArguments()) {
                all_internal_results.insert(arg);
              }
            }
          }
        });
      }
    
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Fri Mar 17 07:31:01 UTC 2023
    - 8K bytes
    - Viewed (0)
  4. tensorflow/compiler/mlir/quantization/stablehlo/passes/insert_calibration_statistics_saver.cc

    // Returns true if the op contains a `CalibrationStatisticsSaverOp`.
    bool ContainCalibrationStatisticsSaverOp(Operation* op) {
      // Check the region for CaseRegionOp, IfRegionOp and WhileRegionOp.
      for (Region& region : op->getRegions()) {
        if (!region.getOps<TF::CalibrationStatisticsSaverOp>().empty()) {
          return true;
        }
      }
    
      SymbolTable symbol_table(op->getParentOfType<ModuleOp>());
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue May 14 06:31:57 UTC 2024
    - 7.2K bytes
    - Viewed (0)
  5. tensorflow/compiler/mlir/tensorflow/transforms/resource_op_lifting_cleanup.cc

          op->getAttrs(), op->getPropertiesStorage(), op->getSuccessors(),
          op->getNumRegions());
      builder.insert(new_op);
    
      // Move region bodies to the new operation.
      for (auto it : llvm::zip(op->getRegions(), new_op->getRegions())) {
        Region &old_region = std::get<0>(it);
        Region &new_region = std::get<1>(it);
        new_region.takeBody(old_region);
      }
    
      // Replace used results and erase the old op.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Thu Apr 25 16:01:03 UTC 2024
    - 19.7K bytes
    - Viewed (0)
  6. tensorflow/compiler/mlir/tensorflow/transforms/tpu_parallel_execute_sink_resource_write.cc

      auto new_parallel_execute = builder.create<tf_device::ParallelExecuteOp>(
          parallel_execute.getLoc(), num_regions, new_result_types);
    
      for (auto region : llvm::zip(new_parallel_execute.getRegions(),
                                   parallel_execute.getRegions()))
        std::get<0>(region).takeBody(std::get<1>(region));
    
      for (auto result :
           llvm::zip(results_to_remap, new_parallel_execute.getResults()))
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Dec 06 04:46:18 UTC 2022
    - 6.6K bytes
    - Viewed (0)
  7. tensorflow/compiler/mlir/tensorflow/utils/parallel_execute_util.cc

      return parallel_execute;
    }
    
    LogicalResult RemoveSingletonParallelExecuteOp(
        tf_device::ParallelExecuteOp parallel_execute, OpBuilder* builder) {
      if (parallel_execute.getRegions().size() == 1) {
        builder->setInsertionPoint(parallel_execute);
        auto& block = parallel_execute.GetRegionBlockWithIndex(0);
        llvm::SmallVector<Operation*, 2> ops_move;
        for (Operation& op : block) {
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Jun 13 03:57:18 UTC 2023
    - 2.3K bytes
    - Viewed (0)
  8. tensorflow/compiler/mlir/tensorflow/transforms/move_tpu_compile_to_front.cc

      // Followed by everything else.
      return 0;
    }
    
    void MoveTpuCompileToFrontPass::runOnOperation() {
      MarkCompilationOps(getOperation());
      getOperation().walk([](Operation* op) {
        for (Region& region : op->getRegions()) {
          for (Block& block : region.getBlocks()) {
            if (block.empty()) continue;
            auto ops = SortBlockTopologically(block, OutsideCompilationOrdering);
            // Replace the block with the reordered block.
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Oct 17 00:26:18 UTC 2023
    - 3.2K bytes
    - Viewed (0)
  9. tensorflow/compiler/mlir/tensorflow/transforms/order_by_dialect.cc

          info =
              &getAnalysis<mlir::TF::SideEffectAnalysis>().GetAnalysisForFunc(func);
        }
        func->walk([&](Operation* function) {
          for (Region& region : function->getRegions()) {
            for (Block& block : region.getBlocks()) {
              if (block.empty()) continue;
              auto ops = SortBlockTopologically(
                  block, DialectOrdering,
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Tue Nov 08 17:01:11 UTC 2022
    - 3.5K bytes
    - Viewed (0)
  10. tensorflow/compiler/mlir/tensorflow/analysis/tf_dataflow.h

        if (auto cast = dyn_cast<TF::CastOp>(op)) {
          this->join(results[0], *operands[0]);
        } else if (auto while_op = dyn_cast<TF::WhileRegionOp>(op)) {
          for (auto &region : while_op->getRegions()) {
            for (auto [arg, value] :
                 llvm::zip(region.getArguments(), while_op->getOperands())) {
              this->join(getLatticeElement(arg), *getLatticeElement(value));
            }
          }
    Registered: Sun Jun 16 05:45:23 UTC 2024
    - Last Modified: Wed Mar 06 23:53:00 UTC 2024
    - 3.9K bytes
    - Viewed (0)
Back to top