2009-02-19 06:13:45 +08:00
|
|
|
#!/usr/bin/perl
|
|
|
|
%packed_insns = (
|
|
|
|
'vfmadd' => 0x98,
|
|
|
|
'vfmaddsub' => 0x96,
|
|
|
|
'vfmsubadd' => 0x97,
|
|
|
|
'vfmsub' => 0x9a,
|
|
|
|
'vfnmadd' => 0x9c,
|
|
|
|
'vfnmsub' => 0x9e
|
|
|
|
);
|
|
|
|
|
|
|
|
%scalar_insns = (
|
|
|
|
'vfmadd' => 0x99,
|
|
|
|
'vfmsub' => 0x9b,
|
2009-03-18 09:26:47 +08:00
|
|
|
'vfnmadd' => 0x9d,
|
2009-03-17 02:51:07 +08:00
|
|
|
'vfnmsub' => 0x9f
|
2009-02-19 06:13:45 +08:00
|
|
|
);
|
|
|
|
|
|
|
|
foreach $pi ( sort(keys(%packed_insns)) ) {
|
|
|
|
$op = $packed_insns{$pi};
|
|
|
|
foreach $order ('132', '213', '231') {
|
|
|
|
$xorder = substr($order,1,1).substr($order,0,1).substr($order,2,1);
|
|
|
|
foreach $o ($order, $xorder) {
|
|
|
|
for ($w = 0; $w < 2; $w++) {
|
2009-03-18 07:13:10 +08:00
|
|
|
$suf = $w ? 'pd' : 'ps';
|
|
|
|
for ($l = 128; $l <= 256; $l <<= 1) {
|
|
|
|
$sx = ($l == 256) ? 'SY' : 'SO';
|
|
|
|
$mm = ($l == 256) ? 'ymm' : 'xmm';
|
|
|
|
printf "%-15s %-31s %-8s%-39s %s\n",
|
|
|
|
"\U${pi}${o}${suf}",
|
|
|
|
"${mm}reg,${mm}reg,${mm}rm",
|
|
|
|
"[rvm:",
|
|
|
|
sprintf("vex.dds.%d.66.0f38.w%d %02x /r]",
|
|
|
|
$l, $w, $op),
|
|
|
|
"FMA,FUTURE,${sx}";
|
|
|
|
}
|
2009-02-19 06:13:45 +08:00
|
|
|
}
|
|
|
|
}
|
2009-03-18 09:26:47 +08:00
|
|
|
$op += 0x10;
|
2009-02-19 06:13:45 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
foreach $si ( sort(keys(%scalar_insns)) ) {
|
|
|
|
$op = $scalar_insns{$si};
|
|
|
|
foreach $order ('132', '213', '231') {
|
|
|
|
$xorder = substr($order,1,1).substr($order,0,1).substr($order,2,1);
|
|
|
|
foreach $o ($order, $xorder) {
|
|
|
|
for ($w = 0; $w < 2; $w++) {
|
|
|
|
$suf = $w ? 'sd' : 'ss';
|
|
|
|
$sx = $w ? 'SQ' : 'SD';
|
2009-03-18 07:13:10 +08:00
|
|
|
$l = 128;
|
|
|
|
$mm = 'xmm';
|
|
|
|
printf "%-15s %-31s %-8s%-39s %s\n",
|
2009-06-25 12:45:27 +08:00
|
|
|
"\U${si}${o}${suf}",
|
|
|
|
"${mm}reg,${mm}reg,${mm}rm",
|
|
|
|
'[rvm:',
|
|
|
|
sprintf("vex.dds.%d.66.0f38.w%d %02x /r]",
|
2009-03-18 07:13:10 +08:00
|
|
|
$l, $w, $op),
|
2009-02-22 08:43:48 +08:00
|
|
|
"FMA,FUTURE,${sx}";
|
2009-02-19 06:13:45 +08:00
|
|
|
}
|
|
|
|
}
|
2009-03-18 09:26:47 +08:00
|
|
|
$op += 0x10;
|
2009-02-19 06:13:45 +08:00
|
|
|
}
|
|
|
|
}
|