void dump_header(dictionary_header_t *header) { printk("EvangelionBIOS dictionary:\n"); printk(" version: %d\n", header->version); printk(" cellsize: %d\n", header->cellsize); printk(" endianess: %s\n", header->endianess?"big":"little"); printk(" compression: %s\n", header->compression?"yes":"no"); printk(" relocation: %s\n", header->relocation?"yes":"no"); printk(" checksum: %08x\n", target_long(header->checksum)); printk(" length: %08x\n", target_long(header->length)); printk(" last: %0" FMT_CELL_x "\n", target_cell(header->last)); }
int * saucy_search(void) { int i; /* Do initialization steps if necessary */ if (!init) { init = 1; /* Initialize stats */ stats->grpsize_base = 1.0; stats->grpsize_exp = stats->nodes = stats->bads = stats->gens = 0; /* Preprocessing after initial coloring */ refine(); } /* Keep going while there are tree nodes to expand */ while (lev) { if (desc) { desc = 0; descend(); } /* Find a target cell */ ++stats->nodes; target_cell(); if (target != n+1) { descend_left(); continue; } /* We don't have a target, so we're discrete */ if (!have_zeta) { have_zeta = 1; for (i = 0; i < n; ++i) zeta[lab[i]] = i; if (canon != NULL) memcpy(canon, lab, n * sizeof(int)); } else { /* Prepare permutation and check */ for (i = 0; i < n; ++i) gamma[i] = lab[zeta[i]]; is_automorphism(); /* Do some stuff if we actually got an automorphism */ if (flag) { ++stats->gens; update_theta(); } /* Keep track of leaf nodes that are not automorphisms */ else { ++stats->bads; } } /* Since we're discrete, we need to backtrack */ backtrack(stats); desc = 1; if (flag) return gamma; } /* Normalize group size */ while (stats->grpsize_base >= 10.0) { stats->grpsize_base /= 10; ++stats->grpsize_exp; } /* All done */ return NULL; }