Move generate_table from cranelift-codegen-shared to cranelift-codegen-meta
This commit is contained in:
@@ -553,9 +553,10 @@ fn gen_opcodes(all_inst: &AllInstructions, fmt: &mut Formatter) {
|
||||
fmt.empty_line();
|
||||
|
||||
// Generate an opcode hash table for looking up opcodes by name.
|
||||
let hash_table = constant_hash::generate_table(all_inst.iter(), all_inst.len(), |inst| {
|
||||
constant_hash::simple_hash(&inst.name)
|
||||
});
|
||||
let hash_table =
|
||||
crate::constant_hash::generate_table(all_inst.iter(), all_inst.len(), |inst| {
|
||||
constant_hash::simple_hash(&inst.name)
|
||||
});
|
||||
fmtln!(
|
||||
fmt,
|
||||
"const OPCODE_HASH_TABLE: [Option<Opcode>; {}] = [",
|
||||
|
||||
Reference in New Issue
Block a user