7 package Nasm
::Regs
::Format
::VC
;
13 my $filename = $regs->filename;
16 /* automatically generated from $filename - do not edit */
20 const int nasm_regvals[] = {
24 my @names = $regs->names;
27 for my $name (@names){
28 my $reg = $regs->Register($name)->x86RegisterNumber;
29 $out .= sprintf(" %2d, /* %-5s */\n", $reg, $name)
41 print "/* automatically generated from $file - do not edit */\n\n";
42 print "#include \"tables.h\"\n\n";
43 print "const int nasm_regvals[] = {\n";
44 print " -1,\n"; # Dummy entry for 0
45 foreach $reg ( sort(keys(%regs)) ) {
46 # Print the x86 value of the register
47 printf " %2d, /* %-5s */\n", $regvals{$reg}, $reg;