OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [tags/] [stable_0_2_0_rc1/] [or1ksim/] [cuc/] [cuc.c] - Diff between revs 898 and 902

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 898 Rev 902
Line 47... Line 47...
  cucdebug (2, "BB%i unroll %i times preroll %i times\n", b, j, i);
  cucdebug (2, "BB%i unroll %i times preroll %i times\n", b, j, i);
  func = preunroll_loop (f, b, i, j, bb_filename);
  func = preunroll_loop (f, b, i, j, bb_filename);
  if (cuc_debug >= 2) print_cuc_bb (func, "AFTER_PREUNROLL");
  if (cuc_debug >= 2) print_cuc_bb (func, "AFTER_PREUNROLL");
 
 
  log ("Optimizing.\n");
  log ("Optimizing.\n");
 
  optimize_cmovs (func);
 
  if (cuc_debug >= 6) print_cuc_bb (func, "AFTER_OPT_CMOVS");
  optimize_tree (func);
  optimize_tree (func);
  if (cuc_debug >= 6) //print_cuc_bb (func, "AFTER_OPT_TREE1");
  if (cuc_debug >= 6) print_cuc_bb (func, "AFTER_OPT_TREE1");
  remove_nops (func);
  remove_nops (func);
  if (cuc_debug >= 6) //print_cuc_bb (func, "NO_NOPS");
  if (cuc_debug >= 6) print_cuc_bb (func, "NO_NOPS");
  remove_dead (func);
  remove_dead (func);
  if (cuc_debug >= 5) print_cuc_bb (func, "AFTER_DEAD1");
  if (cuc_debug >= 5) print_cuc_bb (func, "AFTER_DEAD1");
  optimize_bb (func);
  optimize_bb (func);
  if (cuc_debug >= 5) print_cuc_bb (func, "AFTER_OPT_BB");
  if (cuc_debug >= 5) print_cuc_bb (func, "AFTER_OPT_BB");
  remove_dead_bb (func);
  remove_dead_bb (func);
Line 136... Line 138...
  if (cuc_debug >= 5) print_cuc_bb (func, "AFTER_BUILD_BB");
  if (cuc_debug >= 5) print_cuc_bb (func, "AFTER_BUILD_BB");
  reg_dep (func);
  reg_dep (func);
 
 
  log ("Detecting dependencies\n");
  log ("Detecting dependencies\n");
  if (cuc_debug >= 2) print_cuc_bb (func, "AFTER_REG_DEP");
  if (cuc_debug >= 2) print_cuc_bb (func, "AFTER_REG_DEP");
 
  optimize_cmovs (func);
 
  if (cuc_debug >= 6) print_cuc_bb (func, "AFTER_OPT_CMOVS");
  optimize_tree (func);
  optimize_tree (func);
  log ("Optimizing.\n");
  log ("Optimizing.\n");
  if (cuc_debug >= 2) print_cuc_bb (func, "AFTER_OPT_TREE1");
  if (cuc_debug >= 2) print_cuc_bb (func, "AFTER_OPT_TREE1");
  remove_nops (func);
  remove_nops (func);
  if (cuc_debug >= 6) print_cuc_bb (func, "NO_NOPS");
  if (cuc_debug >= 6) print_cuc_bb (func, "NO_NOPS");
Line 356... Line 360...
  assert (f = dup_func (rf));
  assert (f = dup_func (rf));
 
 
  log ("Generating function %s.\n", name);
  log ("Generating function %s.\n", name);
  printf ("Generating function %s.\n", name);
  printf ("Generating function %s.\n", name);
 
 
  print_cuc_bb (f, "BEFORE_GENERATE");
  if (cuc_debug >= 2) print_cuc_bb (f, "BEFORE_GENERATE");
  add_latches (f);
  add_latches (f);
  set_io (f);
  set_io (f);
  if (cuc_debug >= 1) print_cuc_bb (f, "AFTER_LATCHES");
  if (cuc_debug >= 1) print_cuc_bb (f, "AFTER_LATCHES");
 
 
  format_func_options (tmp, rf);
  format_func_options (tmp, rf);
  if (strlen (tmp)) printf ("Applying options: %s\n", tmp);
  if (strlen (tmp)) printf ("Applying options: %s\n", tmp);
  else printf ("Basic options.\n");
  else printf ("Using basic options.\n");
 
 
  /* Generate function as specified by options */
  /* Generate function as specified by options */
  for (b = 0; b < f->num_bb; b++) {
  for (b = 0; b < f->num_bb; b++) {
    cuc_timings *st;
    cuc_timings *st;
    if (rf->bb[b].selected_tim < 0) continue;
    if (rf->bb[b].selected_tim < 0) continue;
Line 624... Line 628...
          options_cmd (i, func[i]);
          options_cmd (i, func[i]);
          any = 1;
          any = 1;
        }
        }
      if (any) printf ("--------------------------------------------------------\n");
      if (any) printf ("--------------------------------------------------------\n");
      else printf ("Sorry. No available options.\n");
      else printf ("Sorry. No available options.\n");
 
    } else if (strcmp (tmp1, "") == 0) {
 
      /* Ignore empty string */
    } else {
    } else {
      /* help command */
      /* help command */
      if (strcmp (tmp1, "h") != 0 && strcmp (tmp1, "help") != 0)
      if (strcmp (tmp1, "h") != 0 && strcmp (tmp1, "help") != 0)
        printf ("Unknown command.\n");
        printf ("Unknown command.\n");
      printf ("OpenRISC Custom Unit Compiler command prompt\n");
      printf ("OpenRISC Custom Unit Compiler command prompt\n");

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.