1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425
|
; flat assembler core
; Copyright (c) 1999-2021, Tomasz Grysztar.
; All rights reserved.
avx_single_source_pd_instruction_er_evex:
or [vex_required],8
avx_single_source_pd_instruction_er:
or [operand_flags],2+4+8
jmp avx_pd_instruction
avx_single_source_pd_instruction_sae_evex:
or [vex_required],8
or [operand_flags],2+4
jmp avx_pd_instruction
avx_pd_instruction_imm8:
mov [immediate_size],1
jmp avx_pd_instruction
avx_pd_instruction_er:
or [operand_flags],8
avx_pd_instruction_sae:
or [operand_flags],4
avx_pd_instruction:
mov [opcode_prefix],66h
or [rex_prefix],80h
mov cx,0800h
jmp avx_instruction_with_broadcast
avx_pd_instruction_38_evex:
or [vex_required],8
mov [supplemental_code],al
mov al,38h
jmp avx_pd_instruction
avx_cvtps2dq_instruction:
mov [opcode_prefix],66h
jmp avx_single_source_ps_instruction_er
avx_cvtudq2ps_instruction:
mov [opcode_prefix],0F2h
avx_single_source_ps_instruction_er_evex:
or [vex_required],8
avx_single_source_ps_instruction_er:
or [operand_flags],2+4+8
jmp avx_ps_instruction
avx_single_source_ps_instruction_noevex:
or [operand_flags],2
or [vex_required],2
jmp avx_ps_instruction
avx_ps_instruction_imm8:
mov [immediate_size],1
jmp avx_ps_instruction
avx_ps_instruction_er:
or [operand_flags],8
avx_ps_instruction_sae:
or [operand_flags],4
avx_ps_instruction:
mov cx,0400h
jmp avx_instruction_with_broadcast
avx_ps_instruction_66_38_evex:
or [vex_required],8
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,38h
jmp avx_ps_instruction
avx_sd_instruction_er:
or [operand_flags],8
avx_sd_instruction_sae:
or [operand_flags],4
avx_sd_instruction:
mov [opcode_prefix],0F2h
or [rex_prefix],80h
mov cl,8
jmp avx_instruction
avx_ss_instruction_er:
or [operand_flags],8
avx_ss_instruction_sae:
or [operand_flags],4
avx_ss_instruction:
mov [opcode_prefix],0F3h
mov cl,4
jmp avx_instruction
avx_ss_instruction_noevex:
or [vex_required],2
jmp avx_ss_instruction
avx_single_source_q_instruction_38_evex:
or [operand_flags],2
avx_q_instruction_38_evex:
or [vex_required],8
avx_q_instruction_38:
mov [supplemental_code],al
mov al,38h
jmp avx_q_instruction
avx_q_instruction_38_w1_evex:
or [vex_required],8
avx_q_instruction_38_w1:
or [rex_prefix],8
jmp avx_q_instruction_38
avx_q_instruction_3a_imm8_w1:
or [rex_prefix],8
jmp avx_q_instruction_3a_imm8
avx_q_instruction_3a_imm8_evex:
or [vex_required],8
avx_q_instruction_3a_imm8:
mov [immediate_size],1
mov [supplemental_code],al
mov al,3Ah
jmp avx_q_instruction
avx_q_instruction_evex:
or [vex_required],8
avx_q_instruction:
or [rex_prefix],80h
mov ch,8
jmp avx_pi_instruction
avx_single_source_d_instruction_38_evex_w1:
or [rex_prefix],8
avx_single_source_d_instruction_38_evex:
or [vex_required],8
avx_single_source_d_instruction_38:
or [operand_flags],2
jmp avx_d_instruction_38
avx_d_instruction_38_evex:
or [vex_required],8
avx_d_instruction_38:
mov [supplemental_code],al
mov al,38h
jmp avx_d_instruction
avx_d_instruction_3a_imm8_evex:
mov [immediate_size],1
or [vex_required],8
mov [supplemental_code],al
mov al,3Ah
jmp avx_d_instruction
avx_single_source_d_instruction_imm8:
or [operand_flags],2
mov [immediate_size],1
jmp avx_d_instruction
avx_d_instruction_evex:
or [vex_required],8
avx_d_instruction:
mov ch,4
jmp avx_pi_instruction
avx_bw_instruction_3a_imm8_w1_evex:
or [rex_prefix],8
avx_bw_instruction_3a_imm8_evex:
mov [immediate_size],1
or [vex_required],8
mov [supplemental_code],al
mov al,3Ah
jmp avx_bw_instruction
avx_single_source_bw_instruction_38:
or [operand_flags],2
avx_bw_instruction_38:
mov [supplemental_code],al
mov al,38h
avx_bw_instruction:
xor ch,ch
avx_pi_instruction:
mov [opcode_prefix],66h
xor cl,cl
jmp avx_instruction_with_broadcast
avx_bw_instruction_38_w1_evex:
or [rex_prefix],8
avx_bw_instruction_38_evex:
or [vex_required],8
jmp avx_bw_instruction_38
avx_pd_instruction_noevex:
xor cl,cl
or [vex_required],2
mov [opcode_prefix],66h
jmp avx_instruction
avx_ps_instruction_noevex:
or [vex_required],2
mov [opcode_prefix],0F2h
xor cl,cl
jmp avx_instruction
avx_instruction:
xor ch,ch
avx_instruction_with_broadcast:
mov [mmx_size],cl
mov [broadcast_size],ch
mov [base_code],0Fh
mov [extended_code],al
avx_xop_common:
or [vex_required],1
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
avx_reg:
lods byte [esi]
call convert_avx_register
mov [postbyte_register],al
call take_avx512_mask
avx_vex_reg:
test [operand_flags],2
jnz avx_vex_reg_ok
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
avx_vex_reg_ok:
mov al,[mmx_size]
or al,al
jz avx_regs_size_ok
mov ah,[operand_size]
or ah,ah
jz avx_regs_size_ok
cmp al,ah
je avx_regs_size_ok
ja invalid_operand_size
cmp ah,16
jne invalid_operand_size
avx_regs_size_ok:
lods byte [esi]
cmp al,','
jne invalid_operand
avx_regs_rm:
call take_avx_rm
jc avx_regs_reg
mov al,[immediate_size]
cmp al,1
je mmx_imm8
jb instruction_ready
cmp al,-4
je sse_cmp_mem_ok
cmp byte [esi],','
jne invalid_operand
inc esi
call take_avx_register
shl al,4
jc invalid_operand
or byte [value],al
test al,80h
jz avx_regs_mem_reg_store
cmp [code_type],64
jne invalid_operand
avx_regs_mem_reg_store:
call take_imm4_if_needed
call store_instruction_with_imm8
jmp instruction_assembled
avx_regs_reg:
mov bl,al
call take_avx512_rounding
mov al,[immediate_size]
cmp al,1
je mmx_nomem_imm8
jb nomem_instruction_ready
cmp al,-4
je sse_cmp_nomem_ok
lods byte [esi]
cmp al,','
jne invalid_operand
mov al,bl
shl al,4
jc invalid_operand
or byte [value],al
test al,80h
jz avx_regs_reg_
cmp [code_type],64
jne invalid_operand
avx_regs_reg_:
call take_avx_rm
jc avx_regs_reg_reg
cmp [immediate_size],-2
jg invalid_operand
or [rex_prefix],8
call take_imm4_if_needed
call store_instruction_with_imm8
jmp instruction_assembled
avx_regs_reg_reg:
shl al,4
jc invalid_operand
and byte [value],1111b
or byte [value],al
call take_imm4_if_needed
call store_nomem_instruction
mov al,byte [value]
stos byte [edi]
jmp instruction_assembled
take_avx_rm:
xor cl,cl
xchg cl,[operand_size]
lods byte [esi]
call get_size_operator
cmp al,'['
je take_avx_mem
cmp al,10h
jne invalid_operand
mov [operand_size],cl
lods byte [esi]
call convert_avx_register
or cl,cl
jnz avx_reg_ok
or cl,[mmx_size]
jz avx_reg_ok
cmp ah,cl
je avx_reg_ok
jb invalid_operand_size
cmp ah,16
jne invalid_operand_size
avx_reg_ok:
stc
ret
take_avx_mem:
push ecx
call get_address
cmp byte [esi],'{'
jne avx_mem_ok
inc esi
lods byte [esi]
cmp al,1Fh
jne invalid_operand
mov al,[esi]
shr al,4
cmp al,1
jne invalid_operand
mov al,[mmx_size]
or al,al
jnz avx_mem_broadcast_check
mov eax,[esp]
or al,al
jnz avx_mem_broadcast_check
mov al,[broadcast_size]
mov [mmx_size],al
mov ah,cl
lods byte [esi]
and al,1111b
mov cl,al
mov al,[broadcast_size]
shl al,cl
mov [esp],al
mov cl,ah
jmp avx_mem_broadcast_ok
avx_mem_broadcast_check:
bsf eax,eax
xchg al,[broadcast_size]
mov [mmx_size],al
bsf eax,eax
jz invalid_operand
mov ah,[broadcast_size]
sub ah,al
lods byte [esi]
and al,1111b
cmp al,ah
jne invalid_operand_size
avx_mem_broadcast_ok:
or [vex_required],40h
lods byte [esi]
cmp al,'}'
jne invalid_operand
avx_mem_ok:
pop eax
or al,al
jz avx_mem_size_deciding
xchg al,[operand_size]
cmp [mmx_size],0
jne avx_mem_size_enforced
or al,al
jz avx_mem_size_ok
cmp al,[operand_size]
jne operand_sizes_do_not_match
avx_mem_size_ok:
clc
ret
avx_mem_size_deciding:
mov al,[operand_size]
cmp [mmx_size],0
jne avx_mem_size_enforced
cmp al,16
je avx_mem_size_ok
cmp al,32
je avx_mem_size_ok
cmp al,64
je avx_mem_size_ok
or al,al
jnz invalid_operand_size
call recoverable_unknown_size
avx_mem_size_enforced:
or al,al
jz avx_mem_size_ok
cmp al,[mmx_size]
je avx_mem_size_ok
jmp invalid_operand_size
take_imm4_if_needed:
cmp [immediate_size],-3
jne imm4_ok
push ebx ecx edx
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
cmp al,'('
jne invalid_operand
call get_byte_value
test al,11110000b
jnz value_out_of_range
or byte [value],al
pop edx ecx ebx
imm4_ok:
ret
take_avx512_mask:
cmp byte [esi],'{'
jne avx512_masking_ok
test [operand_flags],10h
jnz invalid_operand
inc esi
lods byte [esi]
cmp al,14h
jne invalid_operand
lods byte [esi]
mov ah,al
shr ah,4
cmp ah,5
jne invalid_operand
and al,111b
or al,al
jz invalid_operand
mov [mask_register],al
or [vex_required],20h
lods byte [esi]
cmp al,'}'
jne invalid_operand
cmp byte [esi],'{'
jne avx512_masking_ok
test [operand_flags],20h
jnz invalid_operand
inc esi
lods byte [esi]
cmp al,1Fh
jne invalid_operand
lods byte [esi]
or al,al
jnz invalid_operand
or [mask_register],80h
lods byte [esi]
cmp al,'}'
jne invalid_operand
avx512_masking_ok:
retn
take_avx512_rounding:
test [operand_flags],4+8
jz avx512_rounding_done
test [operand_flags],8
jz avx512_rounding_allowed
cmp [mmx_size],0
jne avx512_rounding_allowed
cmp [operand_size],64
jne avx512_rounding_done
avx512_rounding_allowed:
cmp byte [esi],','
jne avx512_rounding_done
cmp byte [esi+1],'{'
jne avx512_rounding_done
add esi,2
mov [rounding_mode],0
or [vex_required],40h
test [operand_flags],8
jz take_sae
or [vex_required],80h
lods byte [esi]
cmp al,1Fh
jne invalid_operand
lods byte [esi]
mov ah,al
shr ah,4
cmp ah,2
jne invalid_operand
and al,11b
mov [rounding_mode],al
lods byte [esi]
cmp al,'-'
jne invalid_operand
take_sae:
lods byte [esi]
cmp al,1Fh
jne invalid_operand
lods byte [esi]
cmp al,30h
jne invalid_operand
lods byte [esi]
cmp al,'}'
jne invalid_operand
avx512_rounding_done:
retn
avx_movdqu_instruction:
mov ah,0F3h
jmp avx_movdq_instruction
avx_movdqa_instruction:
mov ah,66h
avx_movdq_instruction:
mov [opcode_prefix],ah
or [vex_required],2
jmp avx_movps_instruction
avx512_movdqu16_instruction:
or [rex_prefix],8
avx512_movdqu8_instruction:
mov ah,0F2h
jmp avx_movdq_instruction_evex
avx512_movdqu64_instruction:
or [rex_prefix],8
avx512_movdqu32_instruction:
mov ah,0F3h
jmp avx_movdq_instruction_evex
avx512_movdqa64_instruction:
or [rex_prefix],8
avx512_movdqa32_instruction:
mov ah,66h
avx_movdq_instruction_evex:
mov [opcode_prefix],ah
or [vex_required],8
jmp avx_movps_instruction
avx_movpd_instruction:
mov [opcode_prefix],66h
or [rex_prefix],80h
avx_movps_instruction:
or [operand_flags],2
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
xor al,al
mov [mmx_size],al
mov [broadcast_size],al
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_reg
inc [extended_code]
test [extended_code],1
jnz avx_mem
add [extended_code],-1+10h
avx_mem:
cmp al,'['
jne invalid_operand
call get_address
or [operand_flags],20h
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [postbyte_register],al
jmp instruction_ready
avx_movntpd_instruction:
or [rex_prefix],80h
avx_movntdq_instruction:
mov [opcode_prefix],66h
avx_movntps_instruction:
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
or [operand_flags],10h
mov [mmx_size],0
lods byte [esi]
call get_size_operator
jmp avx_mem
avx_compress_q_instruction:
or [rex_prefix],8
avx_compress_d_instruction:
or [vex_required],8
mov [mmx_size],0
call setup_66_0f_38
lods byte [esi]
call get_size_operator
cmp al,10h
jne avx_mem
lods byte [esi]
call convert_avx_register
mov bl,al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [postbyte_register],al
jmp nomem_instruction_ready
avx_lddqu_instruction:
mov ah,0F2h
or [vex_required],2
avx_load_instruction:
mov [opcode_prefix],ah
mov [base_code],0Fh
mov [extended_code],al
mov [mmx_size],0
or [vex_required],1
call take_avx_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,'['
jne invalid_operand
call get_address
jmp instruction_ready
avx_movntdqa_instruction:
mov [supplemental_code],al
mov al,38h
mov ah,66h
jmp avx_load_instruction
avx_movq_instruction:
or [rex_prefix],8
mov [mmx_size],8
jmp avx_mov_instruction
avx_movd_instruction:
mov [mmx_size],4
avx_mov_instruction:
or [vex_required],1
mov [opcode_prefix],66h
mov [base_code],0Fh
mov [extended_code],7Eh
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_movd_reg
cmp al,'['
jne invalid_operand
call get_address
mov al,[mmx_size]
not al
and [operand_size],al
jnz invalid_operand_size
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_avx_register
cmp ah,16
jne invalid_operand_size
mov [postbyte_register],al
cmp [mmx_size],8
jne instruction_ready
and [rex_prefix],not 8
or [rex_prefix],80h
mov [extended_code],0D6h
jmp instruction_ready
avx_movd_reg:
lods byte [esi]
cmp al,0C0h
jae avx_movd_xmmreg
call convert_register
cmp ah,[mmx_size]
jne invalid_operand_size
mov [operand_size],0
mov bl,al
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_avx_register
cmp ah,16
jne invalid_operand_size
mov [postbyte_register],al
avx_movd_reg_ready:
test [rex_prefix],8
jz nomem_instruction_ready
cmp [code_type],64
jne illegal_instruction
jmp nomem_instruction_ready
avx_movd_xmmreg:
sub [extended_code],10h
call convert_avx_register
cmp ah,16
jne invalid_operand_size
mov [postbyte_register],al
mov [operand_size],0
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_movd_xmmreg_reg
cmp al,'['
jne invalid_operand
call get_address
mov al,[mmx_size]
cmp al,8
jne avx_movd_xmmreg_mem_ready
call avx_movq_xmmreg_xmmreg_opcode
avx_movd_xmmreg_mem_ready:
not al
test [operand_size],al
jnz invalid_operand_size
jmp instruction_ready
avx_movd_xmmreg_reg:
lods byte [esi]
cmp al,0C0h
jae avx_movq_xmmreg_xmmreg
call convert_register
cmp ah,[mmx_size]
jne invalid_operand_size
mov bl,al
jmp avx_movd_reg_ready
avx_movq_xmmreg_xmmreg:
cmp [mmx_size],8
jne invalid_operand
call avx_movq_xmmreg_xmmreg_opcode
call convert_avx_register
cmp ah,16
jne invalid_operand_size
mov bl,al
jmp nomem_instruction_ready
avx_movq_xmmreg_xmmreg_opcode:
and [rex_prefix],not 8
or [rex_prefix],80h
add [extended_code],10h
mov [opcode_prefix],0F3h
ret
avx_movddup_instruction:
or [vex_required],1
mov [opcode_prefix],0F2h
mov [base_code],0Fh
mov [extended_code],al
or [rex_prefix],80h
xor al,al
mov [mmx_size],al
mov [broadcast_size],al
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_avx_register
mov [postbyte_register],al
cmp ah,16
ja avx_movddup_size_ok
mov [mmx_size],8
avx_movddup_size_ok:
call take_avx512_mask
jmp avx_vex_reg_ok
avx_movlpd_instruction:
mov [opcode_prefix],66h
or [rex_prefix],80h
avx_movlps_instruction:
mov [base_code],0Fh
mov [extended_code],al
mov [mmx_size],8
mov [broadcast_size],0
or [vex_required],1
lods byte [esi]
call get_size_operator
cmp al,10h
jne avx_movlps_mem
lods byte [esi]
call convert_avx_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
cmp [operand_size],16
jne invalid_operand
mov [operand_size],0
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_rm
jc invalid_operand
jmp instruction_ready
avx_movlps_mem:
cmp al,'['
jne invalid_operand
call get_address
avx_movlps_mem_:
mov al,[operand_size]
or al,al
jz avx_movlps_mem_size_ok
cmp al,[mmx_size]
jne invalid_operand_size
mov [operand_size],0
avx_movlps_mem_size_ok:
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
cmp ah,16
jne invalid_operand
mov [postbyte_register],al
inc [extended_code]
jmp instruction_ready
avx_movhlps_instruction:
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
call take_avx_register
cmp ah,16
jne invalid_operand
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov bl,al
jmp nomem_instruction_ready
avx_movsd_instruction:
mov al,0F2h
mov cl,8
or [rex_prefix],80h
jmp avx_movs_instruction
avx_movss_instruction:
mov al,0F3h
mov cl,4
avx_movs_instruction:
mov [opcode_prefix],al
mov [mmx_size],cl
or [vex_required],1
mov [base_code],0Fh
mov [extended_code],10h
lods byte [esi]
call get_size_operator
cmp al,10h
jne avx_movs_mem
lods byte [esi]
call convert_avx_register
cmp ah,16
jne invalid_operand
mov [postbyte_register],al
call take_avx512_mask
xor cl,cl
xchg cl,[operand_size]
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
jne avx_movs_reg_mem
mov [operand_size],cl
lods byte [esi]
call convert_avx_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov bl,al
cmp bl,8
jb nomem_instruction_ready
inc [extended_code]
xchg bl,[postbyte_register]
jmp nomem_instruction_ready
avx_movs_reg_mem:
cmp al,'['
jne invalid_operand
call get_address
mov al,[operand_size]
or al,al
jz avx_movs_reg_mem_ok
cmp al,[mmx_size]
jne invalid_operand_size
avx_movs_reg_mem_ok:
jmp instruction_ready
avx_movs_mem:
cmp al,'['
jne invalid_operand
call get_address
or [operand_flags],20h
call take_avx512_mask
jmp avx_movlps_mem_
avx_comiss_instruction:
or [operand_flags],2+4+10h
mov cl,4
jmp avx_instruction
avx_comisd_instruction:
or [operand_flags],2+4+10h
mov [opcode_prefix],66h
or [rex_prefix],80h
mov cl,8
jmp avx_instruction
avx_movshdup_instruction:
or [operand_flags],2
mov [opcode_prefix],0F3h
xor cl,cl
jmp avx_instruction
avx_cvtqq2pd_instruction:
mov [opcode_prefix],0F3h
or [vex_required],8
or [operand_flags],2+4+8
or [rex_prefix],8
mov cx,0800h
jmp avx_instruction_with_broadcast
avx_pshuf_w_instruction:
mov [opcode_prefix],al
or [operand_flags],2
mov [immediate_size],1
mov al,70h
xor cl,cl
jmp avx_instruction
avx_single_source_128bit_instruction_38_noevex:
or [operand_flags],2
avx_128bit_instruction_38_noevex:
mov cl,16
jmp avx_instruction_38_noevex
avx_single_source_instruction_38_noevex:
or [operand_flags],2
jmp avx_pi_instruction_38_noevex
avx_pi_instruction_38_noevex:
xor cl,cl
avx_instruction_38_noevex:
or [vex_required],2
avx_instruction_38:
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,38h
jmp avx_instruction
avx_ss_instruction_3a_imm8_noevex:
mov cl,4
jmp avx_instruction_3a_imm8_noevex
avx_sd_instruction_3a_imm8_noevex:
mov cl,8
jmp avx_instruction_3a_imm8_noevex
avx_single_source_128bit_instruction_3a_imm8_noevex:
or [operand_flags],2
avx_128bit_instruction_3a_imm8_noevex:
mov cl,16
jmp avx_instruction_3a_imm8_noevex
avx_triple_source_instruction_3a_noevex:
xor cl,cl
mov [immediate_size],-1
mov byte [value],0
jmp avx_instruction_3a_noevex
avx_single_source_instruction_3a_imm8_noevex:
or [operand_flags],2
avx_pi_instruction_3a_imm8_noevex:
xor cl,cl
avx_instruction_3a_imm8_noevex:
mov [immediate_size],1
avx_instruction_3a_noevex:
or [vex_required],2
avx_instruction_3a:
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,3Ah
jmp avx_instruction
avx_pi_instruction_3a_imm8:
xor cl,cl
mov [immediate_size],1
jmp avx_instruction_3a
avx_pclmulqdq_instruction:
mov byte [value],al
mov [immediate_size],-4
xor cl,cl
mov al,44h
or [operand_flags],10h
jmp avx_instruction_3a
avx_instruction_38_nomask:
or [operand_flags],10h
xor cl,cl
jmp avx_instruction_38
avx512_single_source_pd_instruction_sae_imm8:
or [operand_flags],2
avx512_pd_instruction_sae_imm8:
or [rex_prefix],8
mov cx,0800h
jmp avx512_instruction_sae_imm8
avx512_single_source_ps_instruction_sae_imm8:
or [operand_flags],2
avx512_ps_instruction_sae_imm8:
mov cx,0400h
jmp avx512_instruction_sae_imm8
avx512_sd_instruction_sae_imm8:
or [rex_prefix],8
mov cx,0008h
jmp avx512_instruction_sae_imm8
avx512_ss_instruction_sae_imm8:
mov cx,0004h
avx512_instruction_sae_imm8:
or [operand_flags],4
avx512_instruction_imm8:
or [vex_required],8
mov [opcode_prefix],66h
mov [immediate_size],1
mov [supplemental_code],al
mov al,3Ah
jmp avx_instruction_with_broadcast
avx512_pd_instruction_er:
or [operand_flags],4+8
jmp avx512_pd_instruction
avx512_single_source_pd_instruction_sae:
or [operand_flags],4
avx512_single_source_pd_instruction:
or [operand_flags],2
avx512_pd_instruction:
or [rex_prefix],8
mov cx,0800h
jmp avx512_instruction
avx512_ps_instruction_er:
or [operand_flags],4+8
jmp avx512_ps_instruction
avx512_single_source_ps_instruction_sae:
or [operand_flags],4
avx512_single_source_ps_instruction:
or [operand_flags],2
avx512_ps_instruction:
mov cx,0400h
jmp avx512_instruction
avx512_sd_instruction_er:
or [operand_flags],8
avx512_sd_instruction_sae:
or [operand_flags],4
avx512_sd_instruction:
or [rex_prefix],8
mov cx,0008h
jmp avx512_instruction
avx512_ss_instruction_er:
or [operand_flags],8
avx512_ss_instruction_sae:
or [operand_flags],4
avx512_ss_instruction:
mov cx,0004h
avx512_instruction:
or [vex_required],8
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,38h
jmp avx_instruction_with_broadcast
avx512_exp2pd_instruction:
or [rex_prefix],8
or [operand_flags],2+4
mov cx,0840h
jmp avx512_instruction
avx512_exp2ps_instruction:
or [operand_flags],2+4
mov cx,0440h
jmp avx512_instruction
fma_instruction_pd:
or [rex_prefix],8
mov cx,0800h
jmp fma_instruction
fma_instruction_ps:
mov cx,0400h
jmp fma_instruction
fma_instruction_sd:
or [rex_prefix],8
mov cx,0008h
jmp fma_instruction
fma_instruction_ss:
mov cx,0004h
fma_instruction:
or [operand_flags],4+8
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,38h
jmp avx_instruction_with_broadcast
fma4_instruction_p:
xor cl,cl
jmp fma4_instruction
fma4_instruction_sd:
mov cl,8
jmp fma4_instruction
fma4_instruction_ss:
mov cl,4
fma4_instruction:
mov [immediate_size],-2
mov byte [value],0
jmp avx_instruction_3a_noevex
avx_cmp_pd_instruction:
mov [opcode_prefix],66h
or [rex_prefix],80h
mov cx,0800h
jmp avx_cmp_instruction
avx_cmp_ps_instruction:
mov cx,0400h
jmp avx_cmp_instruction
avx_cmp_sd_instruction:
mov [opcode_prefix],0F2h
or [rex_prefix],80h
mov cx,0008h
jmp avx_cmp_instruction
avx_cmp_ss_instruction:
mov [opcode_prefix],0F3h
mov cx,0004h
avx_cmp_instruction:
mov byte [value],al
mov [immediate_size],-4
or [operand_flags],4+20h
mov al,0C2h
jmp avx_cmp_common
avx_cmpeqq_instruction:
or [rex_prefix],80h
mov ch,8
mov [supplemental_code],al
mov al,38h
jmp avx_cmp_pi_instruction
avx_cmpeqd_instruction:
mov ch,4
jmp avx_cmp_pi_instruction
avx_cmpeqb_instruction:
xor ch,ch
jmp avx_cmp_pi_instruction
avx512_cmp_uq_instruction:
or [rex_prefix],8
mov ch,8
mov ah,1Eh
jmp avx_cmp_pi_instruction_evex
avx512_cmp_ud_instruction:
mov ch,4
mov ah,1Eh
jmp avx_cmp_pi_instruction_evex
avx512_cmp_q_instruction:
or [rex_prefix],8
mov ch,8
mov ah,1Fh
jmp avx_cmp_pi_instruction_evex
avx512_cmp_d_instruction:
mov ch,4
mov ah,1Fh
jmp avx_cmp_pi_instruction_evex
avx512_cmp_uw_instruction:
or [rex_prefix],8
avx512_cmp_ub_instruction:
xor ch,ch
mov ah,3Eh
jmp avx_cmp_pi_instruction_evex
avx512_cmp_w_instruction:
or [rex_prefix],8
avx512_cmp_b_instruction:
xor ch,ch
mov ah,3Fh
avx_cmp_pi_instruction_evex:
mov byte [value],al
mov [immediate_size],-4
mov [supplemental_code],ah
mov al,3Ah
or [vex_required],8
avx_cmp_pi_instruction:
xor cl,cl
or [operand_flags],20h
mov [opcode_prefix],66h
avx_cmp_common:
mov [mmx_size],cl
mov [broadcast_size],ch
mov [extended_code],al
mov [base_code],0Fh
lods byte [esi]
call get_size_operator
cmp al,14h
je avx_maskreg
cmp al,10h
jne invalid_operand
or [vex_required],2
jmp avx_reg
avx_maskreg:
cmp [operand_size],0
jne invalid_operand_size
or [vex_required],8
lods byte [esi]
call convert_mask_register
mov [postbyte_register],al
call take_avx512_mask
jmp avx_vex_reg
avx512_fpclasspd_instruction:
or [rex_prefix],8
mov cx,0800h
jmp avx_fpclass_instruction
avx512_fpclassps_instruction:
mov cx,0400h
jmp avx_fpclass_instruction
avx512_fpclasssd_instruction:
or [rex_prefix],8
mov cx,0008h
jmp avx_fpclass_instruction
avx512_fpclassss_instruction:
mov cx,0004h
avx_fpclass_instruction:
mov [broadcast_size],ch
mov [mmx_size],cl
or [operand_flags],2
call setup_66_0f_3a
mov [immediate_size],1
lods byte [esi]
cmp al,14h
je avx_maskreg
jmp invalid_operand
avx512_ptestnmd_instruction:
mov ch,4
jmp avx512_ptestnm_instruction
avx512_ptestnmq_instruction:
or [rex_prefix],8
mov ch,8
jmp avx512_ptestnm_instruction
avx512_ptestnmw_instruction:
or [rex_prefix],8
avx512_ptestnmb_instruction:
xor ch,ch
avx512_ptestnm_instruction:
mov ah,0F3h
jmp avx512_ptest_instruction
avx512_ptestmd_instruction:
mov ch,4
jmp avx512_ptestm_instruction
avx512_ptestmq_instruction:
or [rex_prefix],8
mov ch,8
jmp avx512_ptestm_instruction
avx512_ptestmw_instruction:
or [rex_prefix],8
avx512_ptestmb_instruction:
xor ch,ch
avx512_ptestm_instruction:
mov ah,66h
avx512_ptest_instruction:
xor cl,cl
mov [opcode_prefix],ah
mov [supplemental_code],al
mov al,38h
or [vex_required],8
jmp avx_cmp_common
mask_shift_instruction_q:
or [rex_prefix],8
mask_shift_instruction_d:
or [operand_flags],2
or [immediate_size],1
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,3Ah
jmp mask_instruction
mask_instruction_single_source_b:
mov [opcode_prefix],66h
jmp mask_instruction_single_source_w
mask_instruction_single_source_d:
mov [opcode_prefix],66h
mask_instruction_single_source_q:
or [rex_prefix],8
mask_instruction_single_source_w:
or [operand_flags],2
jmp mask_instruction
mask_instruction_b:
mov [opcode_prefix],66h
jmp mask_instruction_w
mask_instruction_d:
mov [opcode_prefix],66h
mask_instruction_q:
or [rex_prefix],8
mask_instruction_w:
mov [operand_size],32
mask_instruction:
or [vex_required],1
mov [base_code],0Fh
mov [extended_code],al
call take_mask_register
mov [postbyte_register],al
test [operand_flags],2
jnz mask_instruction_nds_ok
lods byte [esi]
cmp al,','
jne invalid_operand
call take_mask_register
mov [vex_register],al
mask_instruction_nds_ok:
lods byte [esi]
cmp al,','
jne invalid_operand
call take_mask_register
mov bl,al
cmp [immediate_size],0
jne mmx_nomem_imm8
jmp nomem_instruction_ready
take_mask_register:
lods byte [esi]
cmp al,14h
jne invalid_operand
lods byte [esi]
convert_mask_register:
mov ah,al
shr ah,4
cmp ah,5
jne invalid_operand
and al,1111b
ret
kmov_instruction:
mov [mmx_size],al
or [vex_required],1
mov [base_code],0Fh
mov [extended_code],90h
lods byte [esi]
cmp al,14h
je kmov_maskreg
cmp al,10h
je kmov_reg
call get_size_operator
inc [extended_code]
cmp al,'['
jne invalid_argument
call get_address
lods byte [esi]
cmp al,','
jne invalid_operand
call take_mask_register
mov [postbyte_register],al
kmov_with_mem:
mov ah,[mmx_size]
mov al,[operand_size]
or al,al
jz kmov_mem_size_ok
cmp al,ah
jne invalid_operand_size
kmov_mem_size_ok:
call setup_kmov_prefix
jmp instruction_ready
setup_kmov_prefix:
cmp ah,4
jb kmov_w_ok
or [rex_prefix],8
kmov_w_ok:
test ah,1 or 4
jz kmov_prefix_ok
mov [opcode_prefix],66h
kmov_prefix_ok:
ret
kmov_maskreg:
lods byte [esi]
call convert_mask_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
cmp al,14h
je kmov_maskreg_maskreg
cmp al,10h
je kmov_maskreg_reg
call get_size_operator
cmp al,'['
jne invalid_argument
call get_address
jmp kmov_with_mem
kmov_maskreg_maskreg:
lods byte [esi]
call convert_mask_register
mov bl,al
mov ah,[mmx_size]
call setup_kmov_prefix
jmp nomem_instruction_ready
kmov_maskreg_reg:
add [extended_code],2
lods byte [esi]
call convert_register
kmov_with_reg:
mov bl,al
mov al,[mmx_size]
mov ah,4
cmp al,ah
jbe kmov_reg_size_check
mov ah,al
kmov_reg_size_check:
cmp ah,[operand_size]
jne invalid_operand_size
cmp al,8
je kmov_f2_w1
cmp al,2
ja kmov_f2
je nomem_instruction_ready
mov [opcode_prefix],66h
jmp nomem_instruction_ready
kmov_f2_w1:
or [rex_prefix],8
cmp [code_type],64
jne illegal_instruction
kmov_f2:
mov [opcode_prefix],0F2h
jmp nomem_instruction_ready
kmov_reg:
add [extended_code],3
lods byte [esi]
call convert_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_mask_register
jmp kmov_with_reg
avx512_pmov_m2_instruction_w1:
or [rex_prefix],8
avx512_pmov_m2_instruction:
or [vex_required],8
call setup_f3_0f_38
call take_avx_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_mask_register
mov bl,al
jmp nomem_instruction_ready
avx512_pmov_2m_instruction_w1:
or [rex_prefix],8
avx512_pmov_2m_instruction:
or [vex_required],8
call setup_f3_0f_38
call take_mask_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov bl,al
jmp nomem_instruction_ready
setup_f3_0f_38:
mov [extended_code],38h
mov [supplemental_code],al
mov [base_code],0Fh
mov [opcode_prefix],0F3h
ret
vzeroall_instruction:
mov [operand_size],32
vzeroupper_instruction:
mov [base_code],0Fh
mov [extended_code],al
and [displacement_compression],0
call store_vex_instruction_code
jmp instruction_assembled
vstmxcsr_instruction:
or [vex_required],2
jmp stmxcsr_instruction
avx_perm2f128_instruction:
or [vex_required],2
xor ch,ch
avx_instruction_imm8_without_128bit:
mov [immediate_size],1
mov ah,3Ah
jmp avx_instruction_without_128bit
avx512_shuf_q_instruction:
or [rex_prefix],8
or [vex_required],8
mov ch,8
jmp avx_instruction_imm8_without_128bit
avx512_shuf_d_instruction:
or [vex_required],8
mov ch,4
jmp avx_instruction_imm8_without_128bit
avx_permd_instruction:
mov ah,38h
mov ch,4
avx_instruction_without_128bit:
xor cl,cl
call setup_avx_66_supplemental
call take_avx_register
cmp ah,32
jb invalid_operand_size
mov [postbyte_register],al
call take_avx512_mask
jmp avx_vex_reg
setup_avx_66_supplemental:
mov [opcode_prefix],66h
mov [broadcast_size],ch
mov [mmx_size],cl
mov [base_code],0Fh
mov [extended_code],ah
mov [supplemental_code],al
or [vex_required],1
ret
avx_permq_instruction:
or [rex_prefix],8
mov ch,8
jmp avx_permil_instruction
avx_permilpd_instruction:
or [rex_prefix],80h
mov ch,8
jmp avx_permil_instruction
avx_permilps_instruction:
mov ch,4
avx_permil_instruction:
or [operand_flags],2
xor cl,cl
mov ah,3Ah
call setup_avx_66_supplemental
call take_avx_register
cmp [supplemental_code],4
jae avx_permil_size_ok
cmp ah,32
jb invalid_operand_size
avx_permil_size_ok:
mov [postbyte_register],al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_rm
jnc mmx_imm8
mov bl,al
cmp byte [esi],','
jne invalid_operand
mov al,[esi+1]
cmp al,11h
jne avx_permil_rm_or_imm8
mov al,[esi+3]
avx_permil_rm_or_imm8:
cmp al,'('
je mmx_nomem_imm8
mov [vex_register],bl
inc esi
mov [extended_code],38h
mov al,[supplemental_code]
cmp al,4
jb avx_permq_rm
add [supplemental_code],8
jmp avx_regs_rm
avx_permq_rm:
or [vex_required],8
shl al,5
neg al
add al,36h
mov [supplemental_code],al
jmp avx_regs_rm
vpermil_2pd_instruction:
mov [immediate_size],-2
mov byte [value],al
mov al,49h
jmp vpermil2_instruction_setup
vpermil_2ps_instruction:
mov [immediate_size],-2
mov byte [value],al
mov al,48h
jmp vpermil2_instruction_setup
vpermil2_instruction:
mov [immediate_size],-3
mov byte [value],0
vpermil2_instruction_setup:
or [vex_required],2
mov [base_code],0Fh
mov [supplemental_code],al
mov al,3Ah
xor cl,cl
jmp avx_instruction
avx_shift_q_instruction_evex:
or [vex_required],8
avx_shift_q_instruction:
or [rex_prefix],80h
mov cl,8
jmp avx_shift_instruction
avx_shift_d_instruction:
mov cl,4
jmp avx_shift_instruction
avx_shift_bw_instruction:
xor cl,cl
avx_shift_instruction:
mov [broadcast_size],cl
mov [mmx_size],0
mov [opcode_prefix],66h
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
call take_avx_register
mov [postbyte_register],al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
xor cl,cl
xchg cl,[operand_size]
lods byte [esi]
call get_size_operator
cmp al,'['
je avx_shift_reg_mem
mov [operand_size],cl
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_avx_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
push esi
xor cl,cl
xchg cl,[operand_size]
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_shift_reg_reg_reg
pop esi
cmp al,'['
je avx_shift_reg_reg_mem
xchg cl,[operand_size]
test cl,not 1
jnz invalid_operand_size
dec esi
call convert_avx_shift_opcode
mov bl,al
jmp mmx_nomem_imm8
convert_avx_shift_opcode:
mov al,[extended_code]
mov ah,al
and ah,1111b
add ah,70h
mov [extended_code],ah
shr al,4
sub al,0Ch
shl al,1
xchg al,[postbyte_register]
xchg al,[vex_register]
ret
avx_shift_reg_reg_reg:
pop eax
lods byte [esi]
call convert_xmm_register
xchg cl,[operand_size]
mov bl,al
jmp nomem_instruction_ready
avx_shift_reg_reg_mem:
mov [mmx_size],16
push ecx
lods byte [esi]
call get_size_operator
call get_address
pop eax
xchg al,[operand_size]
test al,al
jz instruction_ready
cmp al,16
jne invalid_operand_size
jmp instruction_ready
avx_shift_reg_mem:
or [vex_required],8
call take_avx_mem
call convert_avx_shift_opcode
jmp mmx_imm8
avx_shift_dq_instruction:
mov [postbyte_register],al
mov [opcode_prefix],66h
mov [base_code],0Fh
mov [extended_code],73h
or [vex_required],1
mov [mmx_size],0
call take_avx_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,'['
je avx_shift_dq_reg_mem
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_avx_register
mov bl,al
jmp mmx_nomem_imm8
avx_shift_dq_reg_mem:
or [vex_required],8
call get_address
jmp mmx_imm8
avx512_rotate_q_instruction:
mov cl,8
or [rex_prefix],cl
jmp avx512_rotate_instruction
avx512_rotate_d_instruction:
mov cl,4
avx512_rotate_instruction:
mov [broadcast_size],cl
mov [postbyte_register],al
mov [opcode_prefix],66h
mov [base_code],0Fh
mov [extended_code],72h
or [vex_required],8
mov [mmx_size],0
mov [immediate_size],1
call take_avx_register
mov [vex_register],al
call take_avx512_mask
jmp avx_vex_reg_ok
avx_pmovsxbq_instruction:
mov cl,2
jmp avx_pmovsx_instruction
avx_pmovsxbd_instruction:
mov cl,4
jmp avx_pmovsx_instruction
avx_pmovsxbw_instruction:
mov cl,8
avx_pmovsx_instruction:
mov [mmx_size],cl
or [vex_required],1
call setup_66_0f_38
call take_avx_register
mov [postbyte_register],al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
xor al,al
xchg al,[operand_size]
bsf ecx,eax
sub cl,4
shl [mmx_size],cl
push eax
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_pmovsx_reg_reg
cmp al,'['
jne invalid_operand
call get_address
pop eax
xchg al,[operand_size]
or al,al
jz instruction_ready
cmp al,[mmx_size]
jne invalid_operand_size
jmp instruction_ready
avx_pmovsx_reg_reg:
lods byte [esi]
call convert_avx_register
mov bl,al
cmp ah,[mmx_size]
je avx_pmovsx_xmmreg_reg_size_ok
jb invalid_operand_size
cmp ah,16
jne invalid_operand_size
avx_pmovsx_xmmreg_reg_size_ok:
pop eax
mov [operand_size],al
jmp nomem_instruction_ready
avx512_pmovqb_instruction:
mov cl,2
jmp avx512_pmov_instruction
avx512_pmovdb_instruction:
mov cl,4
jmp avx512_pmov_instruction
avx512_pmovwb_instruction:
mov cl,8
avx512_pmov_instruction:
mov [mmx_size],cl
or [vex_required],8
mov [extended_code],38h
mov [supplemental_code],al
mov [base_code],0Fh
mov [opcode_prefix],0F3h
lods byte [esi]
call get_size_operator
cmp al,10h
je avx512_pmov_reg
cmp al,'['
jne invalid_operand
call get_address
or [operand_flags],20h
call avx512_pmov_common
or al,al
jz instruction_ready
cmp al,[mmx_size]
jne invalid_operand_size
jmp instruction_ready
avx512_pmov_common:
call take_avx512_mask
xor al,al
xchg al,[operand_size]
push eax
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [postbyte_register],al
mov al,ah
mov ah,cl
bsf ecx,eax
sub cl,4
shl [mmx_size],cl
mov cl,ah
pop eax
ret
avx512_pmov_reg:
lods byte [esi]
call convert_avx_register
mov bl,al
call avx512_pmov_common
cmp al,[mmx_size]
je nomem_instruction_ready
jb invalid_operand_size
cmp al,16
jne invalid_operand_size
jmp nomem_instruction_ready
avx_broadcast_128_instruction_noevex:
or [vex_required],2
mov cl,10h
jmp avx_broadcast_instruction
avx512_broadcast_32x2_instruction:
mov cl,08h
jmp avx_broadcast_instruction_evex
avx512_broadcast_32x4_instruction:
mov cl,10h
jmp avx_broadcast_instruction_evex
avx512_broadcast_32x8_instruction:
mov cl,20h
jmp avx_broadcast_instruction_evex
avx512_broadcast_64x2_instruction:
mov cl,10h
jmp avx_broadcast_instruction_w1_evex
avx512_broadcast_64x4_instruction:
mov cl,20h
avx_broadcast_instruction_w1_evex:
or [rex_prefix],8
avx_broadcast_instruction_evex:
or [vex_required],8
jmp avx_broadcast_instruction
avx_broadcastss_instruction:
mov cl,4
jmp avx_broadcast_instruction
avx_broadcastsd_instruction:
or [rex_prefix],80h
mov cl,8
jmp avx_broadcast_instruction
avx_pbroadcastb_instruction:
mov cl,1
jmp avx_broadcast_pi_instruction
avx_pbroadcastw_instruction:
mov cl,2
jmp avx_broadcast_pi_instruction
avx_pbroadcastd_instruction:
mov cl,4
jmp avx_broadcast_pi_instruction
avx_pbroadcastq_instruction:
mov cl,8
or [rex_prefix],80h
avx_broadcast_pi_instruction:
or [operand_flags],40h
avx_broadcast_instruction:
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,38h
mov [mmx_size],cl
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
call take_avx_register
cmp ah,[mmx_size]
je invalid_operand_size
test [operand_flags],40h
jnz avx_broadcast_destination_size_ok
cmp [mmx_size],4
je avx_broadcast_destination_size_ok
cmp [supplemental_code],59h
je avx_broadcast_destination_size_ok
cmp ah,16
je invalid_operand_size
avx_broadcast_destination_size_ok:
xor ah,ah
xchg ah,[operand_size]
push eax
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_broadcast_reg_reg
cmp al,'['
jne invalid_operand
call get_address
pop eax
xchg ah,[operand_size]
mov [postbyte_register],al
mov al,[broadcast_size]
mov al,[mmx_size]
cmp al,ah
je instruction_ready
or al,al
jz instruction_ready
or ah,ah
jz instruction_ready
jmp invalid_operand_size
avx_broadcast_reg_reg:
lods byte [esi]
test [operand_flags],40h
jz avx_broadcast_reg_avx_reg
cmp al,60h
jb avx_broadcast_reg_general_reg
cmp al,80h
jb avx_broadcast_reg_avx_reg
cmp al,0C0h
jb avx_broadcast_reg_general_reg
avx_broadcast_reg_avx_reg:
call convert_avx_register
mov bl,al
mov al,[mmx_size]
or al,al
jz avx_broadcast_reg_avx_reg_size_ok
cmp ah,16
jne invalid_operand_size
cmp al,ah
jae invalid_operand
avx_broadcast_reg_avx_reg_size_ok:
pop eax
xchg ah,[operand_size]
mov [postbyte_register],al
test [vex_required],2
jnz invalid_operand
jmp nomem_instruction_ready
avx_broadcast_reg_general_reg:
call convert_register
mov bl,al
mov al,[mmx_size]
or al,al
jz avx_broadcast_reg_general_reg_size_ok
cmp al,ah
je avx_broadcast_reg_general_reg_size_ok
ja invalid_operand_size
cmp ah,4
jne invalid_operand_size
avx_broadcast_reg_general_reg_size_ok:
cmp al,4
jb avx_broadcast_reg_general_reg_ready
cmp al,8
mov al,3
jne avx_broadcast_reg_general_reg_ready
or [rex_prefix],8
avx_broadcast_reg_general_reg_ready:
add al,7Ah-1
mov [supplemental_code],al
or [vex_required],8
pop eax
xchg ah,[operand_size]
mov [postbyte_register],al
jmp nomem_instruction_ready
avx512_extract_64x4_instruction:
or [rex_prefix],8
avx512_extract_32x8_instruction:
or [vex_required],8
mov cl,32
jmp avx_extractf_instruction
avx512_extract_64x2_instruction:
or [rex_prefix],8
avx512_extract_32x4_instruction:
or [vex_required],8
mov cl,16
jmp avx_extractf_instruction
avx_extractf128_instruction:
or [vex_required],2
mov cl,16
avx_extractf_instruction:
mov [mmx_size],cl
call setup_66_0f_3a
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_extractf_reg
cmp al,'['
jne invalid_operand
call get_address
xor al,al
xchg al,[operand_size]
or al,al
jz avx_extractf_mem_size_ok
cmp al,[mmx_size]
jne invalid_operand_size
avx_extractf_mem_size_ok:
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
cmp ah,[mmx_size]
jbe invalid_operand_size
mov [postbyte_register],al
jmp mmx_imm8
avx_extractf_reg:
lods byte [esi]
call convert_avx_register
cmp ah,[mmx_size]
jne invalid_operand_size
push eax
call take_avx512_mask
mov [operand_size],0
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
cmp ah,[mmx_size]
jbe invalid_operand_size
mov [postbyte_register],al
pop ebx
jmp mmx_nomem_imm8
avx512_insert_64x4_instruction:
or [rex_prefix],8
avx512_insert_32x8_instruction:
or [vex_required],8
mov cl,32
jmp avx_insertf_instruction
avx512_insert_64x2_instruction:
or [rex_prefix],8
avx512_insert_32x4_instruction:
or [vex_required],8
mov cl,16
jmp avx_insertf_instruction
avx_insertf128_instruction:
or [vex_required],2
mov cl,16
avx_insertf_instruction:
mov [mmx_size],cl
mov [broadcast_size],0
call setup_66_0f_3a
call take_avx_register
cmp ah,[mmx_size]
jbe invalid_operand
mov [postbyte_register],al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
mov al,[mmx_size]
xchg al,[operand_size]
push eax
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_insertf_reg_reg_reg
cmp al,'['
jne invalid_operand
call get_address
pop eax
mov [operand_size],al
jmp mmx_imm8
avx_insertf_reg_reg_reg:
lods byte [esi]
call convert_avx_register
mov bl,al
pop eax
mov [operand_size],al
jmp mmx_nomem_imm8
avx_extract_b_instruction:
mov cl,1
jmp avx_extract_instruction
avx_extract_w_instruction:
mov cl,2
jmp avx_extract_instruction
avx_extract_q_instruction:
or [rex_prefix],8
mov cl,8
jmp avx_extract_instruction
avx_extract_d_instruction:
mov cl,4
avx_extract_instruction:
mov [mmx_size],cl
call setup_66_0f_3a
or [vex_required],1
lods byte [esi]
call get_size_operator
cmp al,10h
je avx_extractps_reg
cmp al,'['
jne invalid_operand
call get_address
mov al,[mmx_size]
not al
and [operand_size],al
jnz invalid_operand_size
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_avx_register
cmp ah,16
jne invalid_operand_size
mov [postbyte_register],al
jmp mmx_imm8
avx_extractps_reg:
lods byte [esi]
call convert_register
mov bl,al
mov al,[mmx_size]
cmp ah,al
jb invalid_operand_size
cmp ah,4
je avx_extractps_reg_size_ok
cmp ah,8
jne invalid_operand_size
cmp [code_type],64
jne invalid_operand
cmp al,4
jae avx_extractps_reg_size_ok
or [rex_prefix],8
avx_extractps_reg_size_ok:
mov [operand_size],0
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_avx_register
cmp ah,16
jne invalid_operand_size
mov [postbyte_register],al
cmp [supplemental_code],15h
jne mmx_nomem_imm8
mov [extended_code],0C5h
xchg bl,[postbyte_register]
jmp mmx_nomem_imm8
avx_insertps_instruction:
mov [immediate_size],1
or [operand_flags],10h
mov [opcode_prefix],66h
mov [supplemental_code],al
mov al,3Ah
mov cl,4
jmp avx_instruction
avx_pinsrb_instruction:
mov cl,1
jmp avx_pinsr_instruction_3a
avx_pinsrw_instruction:
mov cl,2
jmp avx_pinsr_instruction
avx_pinsrd_instruction:
mov cl,4
jmp avx_pinsr_instruction_3a
avx_pinsrq_instruction:
cmp [code_type],64
jne illegal_instruction
mov cl,8
or [rex_prefix],8
avx_pinsr_instruction_3a:
mov [supplemental_code],al
mov al,3Ah
avx_pinsr_instruction:
mov [opcode_prefix],66h
mov [base_code],0Fh
mov [extended_code],al
mov [mmx_size],cl
or [vex_required],1
call take_avx_register
cmp ah,16
jne invalid_operand_size
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
jmp pinsr_xmmreg
avx_cvtudq2pd_instruction:
or [vex_required],8
avx_cvtdq2pd_instruction:
mov [opcode_prefix],0F3h
mov cl,4
jmp avx_cvt_d_instruction
avx_cvtps2qq_instruction:
or [operand_flags],8
avx_cvttps2qq_instruction:
or [operand_flags],4
or [vex_required],8
mov [opcode_prefix],66h
mov cl,4
jmp avx_cvt_d_instruction
avx_cvtps2pd_instruction:
or [operand_flags],4
mov cl,4
avx_cvt_d_instruction:
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
mov [broadcast_size],cl
call take_avx_register
mov [postbyte_register],al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
xor ecx,ecx
xchg cl,[operand_size]
mov al,cl
shr al,1
mov [mmx_size],al
lods byte [esi]
call get_size_operator
cmp al,'['
je avx_cvt_d_reg_mem
cmp al,10h
jne invalid_operand
mov [operand_size],0
lods byte [esi]
call convert_avx_register
cmp ah,[mmx_size]
je avx_cvt_d_reg_reg_size_ok
jb invalid_operand_size
cmp ah,16
jne invalid_operand_size
avx_cvt_d_reg_reg_size_ok:
mov bl,al
mov [operand_size],cl
call take_avx512_rounding
jmp nomem_instruction_ready
avx_cvt_d_reg_mem:
call take_avx_mem
jmp instruction_ready
avx_cvtpd2dq_instruction:
or [operand_flags],4+8
mov [opcode_prefix],0F2h
jmp avx_cvt_q_instruction
avx_cvtuqq2ps_instruction:
mov [opcode_prefix],0F2h
avx_cvtpd2udq_instruction:
or [operand_flags],8
avx_cvttpd2udq_instruction:
or [operand_flags],4
or [vex_required],8
jmp avx_cvt_q_instruction
avx_cvtpd2ps_instruction:
or [operand_flags],8
avx_cvttpd2dq_instruction:
or [operand_flags],4
mov [opcode_prefix],66h
avx_cvt_q_instruction:
mov [broadcast_size],8
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
or [rex_prefix],80h
call take_avx_register
mov [postbyte_register],al
push eax
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
xor al,al
mov [operand_size],al
mov [mmx_size],al
call take_avx_rm
jnc avx_cvt_q_reg_mem
mov bl,al
pop eax
call avx_cvt_q_check_size
call take_avx512_rounding
jmp nomem_instruction_ready
avx_cvt_q_reg_mem:
pop eax
call avx_cvt_q_check_size
jmp instruction_ready
avx_cvt_q_check_size:
mov al,[operand_size]
or al,al
jz avx_cvt_q_size_not_specified
cmp al,64
ja invalid_operand_size
shr al,1
cmp al,ah
je avx_cvt_q_size_ok
ja invalid_operand_size
cmp ah,16
jne invalid_operand_size
avx_cvt_q_size_ok:
ret
avx_cvt_q_size_not_specified:
cmp ah,64 shr 1
jne recoverable_unknown_size
mov [operand_size],64
ret
avx_cvttps2udq_instruction:
or [vex_required],8
or [operand_flags],2+4
mov cx,0400h
jmp avx_instruction_with_broadcast
avx_cvttps2dq_instruction:
mov [opcode_prefix],0F3h
or [operand_flags],2+4
mov cx,0400h
jmp avx_instruction_with_broadcast
avx_cvtph2ps_instruction:
mov [opcode_prefix],66h
mov [supplemental_code],al
or [operand_flags],4
mov al,38h
xor cl,cl
jmp avx_cvt_d_instruction
avx_cvtps2ph_instruction:
call setup_66_0f_3a
or [vex_required],1
or [operand_flags],4
lods byte [esi]
call get_size_operator
cmp al,10h
je vcvtps2ph_reg
cmp al,'['
jne invalid_operand
call get_address
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
shl [operand_size],1
call take_avx_register
mov [postbyte_register],al
shr ah,1
mov [mmx_size],ah
jmp mmx_imm8
vcvtps2ph_reg:
lods byte [esi]
call convert_avx_register
mov bl,al
call take_avx512_mask
xor cl,cl
xchg cl,[operand_size]
shl cl,1
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [postbyte_register],al
or cl,cl
jz vcvtps2ph_reg_size_ok
cmp cl,ah
je vcvtps2ph_reg_size_ok
jb invalid_operand_size
cmp ah,16
jne invalid_operand_size
vcvtps2ph_reg_size_ok:
call take_avx512_rounding
jmp mmx_nomem_imm8
avx_cvtsd2usi_instruction:
or [operand_flags],8
avx_cvttsd2usi_instruction:
or [vex_required],8
jmp avx_cvttsd2si_instruction
avx_cvtsd2si_instruction:
or [operand_flags],8
avx_cvttsd2si_instruction:
mov ah,0F2h
mov cl,8
jmp avx_cvt_2si_instruction
avx_cvtss2usi_instruction:
or [operand_flags],8
avx_cvttss2usi_instruction:
or [vex_required],8
jmp avx_cvttss2si_instruction
avx_cvtss2si_instruction:
or [operand_flags],8
avx_cvttss2si_instruction:
mov ah,0F3h
mov cl,4
avx_cvt_2si_instruction:
or [operand_flags],2+4
mov [mmx_size],cl
mov [broadcast_size],0
mov [opcode_prefix],ah
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
mov [postbyte_register],al
mov [operand_size],0
cmp ah,4
je avx_cvt_2si_reg
cmp ah,8
jne invalid_operand_size
call operand_64bit
avx_cvt_2si_reg:
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_rm
jnc instruction_ready
mov bl,al
call take_avx512_rounding
jmp nomem_instruction_ready
avx_cvtusi2sd_instruction:
or [vex_required],8
avx_cvtsi2sd_instruction:
mov ah,0F2h
mov cl,8
jmp avx_cvtsi_instruction
avx_cvtusi2ss_instruction:
or [vex_required],8
avx_cvtsi2ss_instruction:
mov ah,0F3h
mov cl,4
avx_cvtsi_instruction:
or [operand_flags],2+4+8
mov [mmx_size],cl
mov [opcode_prefix],ah
mov [base_code],0Fh
mov [extended_code],al
or [vex_required],1
call take_avx_register
cmp ah,16
jne invalid_operand_size
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
mov [operand_size],0
lods byte [esi]
call get_size_operator
cmp al,'['
je avx_cvtsi_reg_reg_mem
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
mov bl,al
cmp ah,4
je avx_cvtsi_reg_reg_reg32
cmp ah,8
jne invalid_operand_size
call operand_64bit
avx_cvtsi_rounding:
call take_avx512_rounding
jmp nomem_instruction_ready
avx_cvtsi_reg_reg_reg32:
cmp [mmx_size],8
jne avx_cvtsi_rounding
jmp nomem_instruction_ready
avx_cvtsi_reg_reg_mem:
call get_address
mov al,[operand_size]
mov [mmx_size],al
or al,al
jz single_mem_nosize
cmp al,4
je instruction_ready
cmp al,8
jne invalid_operand_size
call operand_64bit
jmp instruction_ready
avx_maskmov_w1_instruction:
or [rex_prefix],8
avx_maskmov_instruction:
call setup_66_0f_38
mov [mmx_size],0
or [vex_required],2
lods byte [esi]
call get_size_operator
cmp al,10h
jne avx_maskmov_mem
lods byte [esi]
call convert_avx_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,'['
jne invalid_operand
call get_address
jmp instruction_ready
avx_maskmov_mem:
cmp al,'['
jne invalid_operand
call get_address
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [postbyte_register],al
add [supplemental_code],2
jmp instruction_ready
avx_movmskpd_instruction:
mov [opcode_prefix],66h
avx_movmskps_instruction:
mov [base_code],0Fh
mov [extended_code],50h
or [vex_required],2
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
mov [postbyte_register],al
cmp ah,4
je avx_movmskps_reg_ok
cmp ah,8
jne invalid_operand_size
cmp [code_type],64
jne invalid_operand
avx_movmskps_reg_ok:
mov [operand_size],0
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov bl,al
jmp nomem_instruction_ready
avx_maskmovdqu_instruction:
or [vex_required],2
jmp maskmovdqu_instruction
avx_pmovmskb_instruction:
or [vex_required],2
mov [opcode_prefix],66h
mov [base_code],0Fh
mov [extended_code],al
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
cmp ah,4
je avx_pmovmskb_reg_size_ok
cmp [code_type],64
jne invalid_operand_size
cmp ah,8
jnz invalid_operand_size
avx_pmovmskb_reg_size_ok:
mov [postbyte_register],al
mov [operand_size],0
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov bl,al
jmp nomem_instruction_ready
gather_pd_instruction:
or [rex_prefix],8
gather_ps_instruction:
call setup_66_0f_38
or [vex_required],4
or [operand_flags],20h
call take_avx_register
mov [postbyte_register],al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
xor cl,cl
xchg cl,[operand_size]
push ecx
lods byte [esi]
call get_size_operator
cmp al,'['
jne invalid_argument
call get_address
pop eax
xchg al,[operand_size]
gather_mem_size_check:
mov ah,4
test [rex_prefix],8
jz gather_elements_size_ok
add ah,ah
gather_elements_size_ok:
mov [mmx_size],ah
test al,al
jz gather_mem_size_ok
cmp al,ah
jne invalid_operand_size
gather_mem_size_ok:
cmp byte [esi],','
je gather_reg_mem_reg
test [vex_required],20h
jz invalid_operand
mov ah,[operand_size]
mov al,80h
jmp gather_arguments_ok
gather_reg_mem_reg:
or [vex_required],2
inc esi
call take_avx_register
gather_arguments_ok:
mov [vex_register],al
cmp al,[postbyte_register]
je disallowed_combination_of_registers
mov al,bl
and al,11111b
cmp al,[postbyte_register]
je disallowed_combination_of_registers
cmp al,[vex_register]
je disallowed_combination_of_registers
mov al,bl
shr al,5
cmp al,0Ch shr 1
je gather_vr128
mov ah,32
cmp al,6 shr 1
jne gather_regular
add ah,ah
gather_regular:
mov al,[rex_prefix]
shr al,3
xor al,[supplemental_code]
test al,1
jz gather_uniform
test [supplemental_code],1
jz gather_double
mov al,ah
xchg al,[operand_size]
add al,al
cmp al,ah
jne invalid_operand_size
jmp instruction_ready
gather_double:
add ah,ah
gather_uniform:
cmp ah,[operand_size]
jne invalid_operand_size
jmp instruction_ready
gather_vr128:
cmp ah,16
je instruction_ready
cmp ah,32
jne invalid_operand_size
test [supplemental_code],1
jnz invalid_operand_size
test [rex_prefix],8
jz invalid_operand_size
jmp instruction_ready
scatter_pd_instruction:
or [rex_prefix],8
scatter_ps_instruction:
call setup_66_0f_38
or [vex_required],4+8
or [operand_flags],20h
lods byte [esi]
call get_size_operator
cmp al,'['
jne invalid_argument
call get_address
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
xor al,al
xchg al,[operand_size]
push eax
call take_avx_register
mov [postbyte_register],al
pop eax
jmp gather_mem_size_check
gatherpf_qpd_instruction:
mov ah,0C7h
jmp gatherpf_pd_instruction
gatherpf_dpd_instruction:
mov ah,0C6h
gatherpf_pd_instruction:
or [rex_prefix],8
mov cl,8
jmp gatherpf_instruction
gatherpf_qps_instruction:
mov ah,0C7h
jmp gatherpf_ps_instruction
gatherpf_dps_instruction:
mov ah,0C6h
gatherpf_ps_instruction:
mov cl,4
gatherpf_instruction:
mov [mmx_size],cl
mov [postbyte_register],al
mov al,ah
call setup_66_0f_38
or [vex_required],4+8
or [operand_flags],20h
lods byte [esi]
call get_size_operator
cmp al,'['
jne invalid_argument
call get_address
call take_avx512_mask
mov ah,[mmx_size]
mov al,[operand_size]
or al,al
jz gatherpf_mem_size_ok
cmp al,ah
jne invalid_operand_size
gatherpf_mem_size_ok:
mov [operand_size],64
mov al,6 shr 1
cmp ah,4
je gatherpf_check_vsib
cmp [supplemental_code],0C6h
jne gatherpf_check_vsib
mov al,0Eh shr 1
gatherpf_check_vsib:
mov ah,bl
shr ah,5
cmp al,ah
jne invalid_operand
jmp instruction_ready
bmi_instruction:
mov [base_code],0Fh
mov [extended_code],38h
mov [supplemental_code],0F3h
mov [postbyte_register],al
bmi_reg:
or [vex_required],2
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
je bmi_reg_reg
cmp al,'['
jne invalid_argument
call get_address
call operand_32or64
jmp instruction_ready
bmi_reg_reg:
lods byte [esi]
call convert_register
mov bl,al
call operand_32or64
jmp nomem_instruction_ready
operand_32or64:
mov al,[operand_size]
cmp al,4
je operand_32or64_ok
cmp al,8
jne invalid_operand_size
cmp [code_type],64
jne invalid_operand
or [rex_prefix],8
operand_32or64_ok:
ret
pdep_instruction:
mov [opcode_prefix],0F2h
jmp andn_instruction
pext_instruction:
mov [opcode_prefix],0F3h
andn_instruction:
mov [base_code],0Fh
mov [extended_code],38h
mov [supplemental_code],al
or [vex_required],2
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
jmp bmi_reg
sarx_instruction:
mov [opcode_prefix],0F3h
jmp bzhi_instruction
shrx_instruction:
mov [opcode_prefix],0F2h
jmp bzhi_instruction
shlx_instruction:
mov [opcode_prefix],66h
bzhi_instruction:
mov [base_code],0Fh
mov [extended_code],38h
mov [supplemental_code],al
or [vex_required],2
call get_reg_mem
jc bzhi_reg_reg
call get_vex_source_register
jc invalid_operand
call operand_32or64
jmp instruction_ready
bzhi_reg_reg:
call get_vex_source_register
jc invalid_operand
call operand_32or64
jmp nomem_instruction_ready
get_vex_source_register:
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,10h
jne no_vex_source_register
lods byte [esi]
call convert_register
mov [vex_register],al
clc
ret
no_vex_source_register:
stc
ret
bextr_instruction:
mov [base_code],0Fh
mov [extended_code],38h
mov [supplemental_code],al
or [vex_required],2
call get_reg_mem
jc bextr_reg_reg
call get_vex_source_register
jc bextr_reg_mem_imm32
call operand_32or64
jmp instruction_ready
bextr_reg_reg:
call get_vex_source_register
jc bextr_reg_reg_imm32
call operand_32or64
jmp nomem_instruction_ready
setup_bextr_imm_opcode:
mov [xop_opcode_map],0Ah
mov [base_code],10h
call operand_32or64
ret
bextr_reg_mem_imm32:
call get_imm32
call setup_bextr_imm_opcode
jmp store_instruction_with_imm32
bextr_reg_reg_imm32:
call get_imm32
call setup_bextr_imm_opcode
store_nomem_instruction_with_imm32:
call store_nomem_instruction
mov eax,dword [value]
call mark_relocation
stos dword [edi]
jmp instruction_assembled
get_imm32:
cmp al,'('
jne invalid_operand
push edx ebx ecx
call get_dword_value
mov dword [value],eax
pop ecx ebx edx
ret
rorx_instruction:
mov [opcode_prefix],0F2h
mov [base_code],0Fh
mov [extended_code],3Ah
mov [supplemental_code],al
or [vex_required],2
call get_reg_mem
jc rorx_reg_reg
call operand_32or64
jmp mmx_imm8
rorx_reg_reg:
call operand_32or64
jmp mmx_nomem_imm8
tbm_instruction:
mov [xop_opcode_map],9
mov ah,al
shr ah,4
and al,111b
mov [base_code],ah
mov [postbyte_register],al
jmp bmi_reg
llwpcb_instruction:
or [vex_required],2
mov [xop_opcode_map],9
mov [base_code],12h
mov [postbyte_register],al
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
mov bl,al
call operand_32or64
jmp nomem_instruction_ready
lwpins_instruction:
or [vex_required],2
mov [xop_opcode_map],0Ah
mov [base_code],12h
mov [vex_register],al
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_register
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
xor cl,cl
xchg cl,[operand_size]
lods byte [esi]
call get_size_operator
cmp al,10h
je lwpins_reg_reg
cmp al,'['
jne invalid_argument
push ecx
call get_address
pop eax
xchg al,[operand_size]
test al,al
jz lwpins_reg_mem_size_ok
cmp al,4
jne invalid_operand_size
lwpins_reg_mem_size_ok:
call prepare_lwpins
jmp store_instruction_with_imm32
lwpins_reg_reg:
lods byte [esi]
call convert_register
cmp ah,4
jne invalid_operand_size
mov [operand_size],cl
mov bl,al
call prepare_lwpins
jmp store_nomem_instruction_with_imm32
prepare_lwpins:
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_imm32
call operand_32or64
mov al,[vex_register]
xchg al,[postbyte_register]
mov [vex_register],al
ret
xop_single_source_sd_instruction:
or [operand_flags],2
mov [mmx_size],8
jmp xop_instruction_9
xop_single_source_ss_instruction:
or [operand_flags],2
mov [mmx_size],4
jmp xop_instruction_9
xop_single_source_instruction:
or [operand_flags],2
mov [mmx_size],0
xop_instruction_9:
mov [base_code],al
mov [xop_opcode_map],9
jmp avx_xop_common
xop_single_source_128bit_instruction:
or [operand_flags],2
mov [mmx_size],16
jmp xop_instruction_9
xop_triple_source_128bit_instruction:
mov [immediate_size],-1
mov byte [value],0
mov [mmx_size],16
jmp xop_instruction_8
xop_128bit_instruction:
mov [immediate_size],-2
mov byte [value],0
mov [mmx_size],16
xop_instruction_8:
mov [base_code],al
mov [xop_opcode_map],8
jmp avx_xop_common
xop_pcom_b_instruction:
mov ah,0CCh
jmp xop_pcom_instruction
xop_pcom_d_instruction:
mov ah,0CEh
jmp xop_pcom_instruction
xop_pcom_q_instruction:
mov ah,0CFh
jmp xop_pcom_instruction
xop_pcom_w_instruction:
mov ah,0CDh
jmp xop_pcom_instruction
xop_pcom_ub_instruction:
mov ah,0ECh
jmp xop_pcom_instruction
xop_pcom_ud_instruction:
mov ah,0EEh
jmp xop_pcom_instruction
xop_pcom_uq_instruction:
mov ah,0EFh
jmp xop_pcom_instruction
xop_pcom_uw_instruction:
mov ah,0EDh
xop_pcom_instruction:
mov byte [value],al
mov [immediate_size],-4
mov [mmx_size],16
mov [base_code],ah
mov [xop_opcode_map],8
jmp avx_xop_common
vpcmov_instruction:
or [vex_required],2
mov [immediate_size],-2
mov byte [value],0
mov [mmx_size],0
mov [base_code],al
mov [xop_opcode_map],8
jmp avx_xop_common
xop_shift_instruction:
mov [base_code],al
or [vex_required],2
mov [xop_opcode_map],9
call take_avx_register
cmp ah,16
jne invalid_operand
mov [postbyte_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
lods byte [esi]
call get_size_operator
cmp al,'['
je xop_shift_reg_mem
cmp al,10h
jne invalid_operand
lods byte [esi]
call convert_xmm_register
mov [vex_register],al
lods byte [esi]
cmp al,','
jne invalid_operand
push esi
xor cl,cl
xchg cl,[operand_size]
lods byte [esi]
call get_size_operator
pop esi
xchg cl,[operand_size]
cmp al,'['
je xop_shift_reg_reg_mem
cmp al,10h
jne xop_shift_reg_reg_imm
call take_avx_register
mov bl,al
xchg bl,[vex_register]
jmp nomem_instruction_ready
xop_shift_reg_reg_mem:
or [rex_prefix],8
lods byte [esi]
call get_size_operator
call get_address
jmp instruction_ready
xop_shift_reg_reg_imm:
xor bl,bl
xchg bl,[vex_register]
cmp [base_code],94h
jae invalid_operand
add [base_code],30h
mov [xop_opcode_map],8
dec esi
jmp mmx_nomem_imm8
xop_shift_reg_mem:
call get_address
lods byte [esi]
cmp al,','
jne invalid_operand
push esi
xor cl,cl
xchg cl,[operand_size]
lods byte [esi]
call get_size_operator
pop esi
xchg cl,[operand_size]
cmp al,10h
jne xop_shift_reg_mem_imm
call take_avx_register
mov [vex_register],al
jmp instruction_ready
xop_shift_reg_mem_imm:
cmp [base_code],94h
jae invalid_operand
add [base_code],30h
mov [xop_opcode_map],8
dec esi
jmp mmx_imm8
avx512_4vnniw_instruction:
mov [opcode_prefix],0F2h
mov [base_code],0Fh
mov [extended_code],38h
mov [supplemental_code],al
mov [mmx_size],16
mov [broadcast_size],0
or [vex_required],8
call take_avx_register
mov [postbyte_register],al
call take_avx512_mask
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_register
mov [vex_register],al
cmp byte [esi],'+'
jne reg4_ok
inc esi
cmp dword [esi],29030128h
jne invalid_operand
lods dword [esi]
reg4_ok:
cmp [operand_size],64
jne invalid_operand_size
mov [operand_size],0
lods byte [esi]
cmp al,','
jne invalid_operand
call take_avx_rm
jc invalid_operand
mov [operand_size],64
jmp instruction_ready
set_evex_mode:
mov [evex_mode],al
jmp instruction_assembled
take_avx_register:
lods byte [esi]
call get_size_operator
cmp al,10h
jne invalid_operand
lods byte [esi]
convert_avx_register:
mov ah,al
and al,1Fh
and ah,0E0h
sub ah,60h
jb invalid_operand
jz avx512_register_size
sub ah,60h
jb invalid_operand
jnz avx_register_size_ok
mov ah,16
jmp avx_register_size_ok
avx512_register_size:
mov ah,64
avx_register_size_ok:
cmp al,8
jb match_register_size
cmp [code_type],64
jne invalid_operand
jmp match_register_size
store_vex_instruction_code:
test [rex_prefix],10h
jnz invalid_operand
test [vex_required],0F8h
jnz store_evex_instruction_code
test [vex_register],10000b
jnz store_evex_instruction_code
cmp [operand_size],64
je store_evex_instruction_code
mov al,[base_code]
cmp al,0Fh
jne store_xop_instruction_code
test [vex_required],2
jnz prepare_vex
cmp [evex_mode],0
je prepare_vex
cmp [displacement_compression],1
jne prepare_vex
cmp edx,80h
jb prepare_vex
cmp edx,-80h
jae prepare_vex
mov al,bl
or al,bh
shr al,4
cmp al,2
je prepare_vex
call compress_displacement
cmp [displacement_compression],2
ja prepare_evex
jb prepare_vex
dec [displacement_compression]
mov edx,[uncompressed_displacement]
prepare_vex:
mov ah,[extended_code]
cmp ah,38h
je store_vex_0f38_instruction_code
cmp ah,3Ah
je store_vex_0f3a_instruction_code
test [rex_prefix],1011b
jnz store_vex_0f_instruction_code
mov [edi+2],ah
mov byte [edi],0C5h
mov al,[vex_register]
not al
shl al,3
mov ah,[rex_prefix]
shl ah,5
and ah,80h
xor al,ah
call get_vex_lpp_bits
mov [edi+1],al
call check_vex
add edi,3
ret
get_vex_lpp_bits:
cmp [operand_size],32
jne get_vex_pp_bits
or al,100b
get_vex_pp_bits:
mov ah,[opcode_prefix]
cmp ah,66h
je vex_66
cmp ah,0F3h
je vex_f3
cmp ah,0F2h
je vex_f2
test ah,ah
jnz disallowed_combination_of_registers
ret
vex_f2:
or al,11b
ret
vex_f3:
or al,10b
ret
vex_66:
or al,1
ret
store_vex_0f38_instruction_code:
mov al,11100010b
mov ah,[supplemental_code]
jmp make_c4_vex
store_vex_0f3a_instruction_code:
mov al,11100011b
mov ah,[supplemental_code]
jmp make_c4_vex
store_vex_0f_instruction_code:
mov al,11100001b
make_c4_vex:
mov [edi+3],ah
mov byte [edi],0C4h
mov ah,[rex_prefix]
shl ah,5
xor al,ah
mov [edi+1],al
call check_vex
mov al,[vex_register]
xor al,1111b
shl al,3
mov ah,[rex_prefix]
shl ah,4
and ah,80h
or al,ah
call get_vex_lpp_bits
mov [edi+2],al
add edi,4
ret
check_vex:
cmp [code_type],64
je vex_ok
not al
test al,11000000b
jnz invalid_operand
test [rex_prefix],40h
jnz invalid_operand
vex_ok:
ret
store_xop_instruction_code:
mov [edi+3],al
mov byte [edi],8Fh
mov al,[xop_opcode_map]
mov ah,[rex_prefix]
test ah,40h
jz xop_ok
cmp [code_type],64
jne invalid_operand
xop_ok:
not ah
shl ah,5
xor al,ah
mov [edi+1],al
mov al,[vex_register]
xor al,1111b
shl al,3
mov ah,[rex_prefix]
shl ah,4
and ah,80h
or al,ah
call get_vex_lpp_bits
mov [edi+2],al
add edi,4
ret
store_evex_instruction_code:
test [vex_required],2
jnz invalid_operand
cmp [base_code],0Fh
jne invalid_operand
cmp [displacement_compression],1
jne prepare_evex
call compress_displacement
prepare_evex:
mov ah,[extended_code]
cmp ah,38h
je store_evex_0f38_instruction_code
cmp ah,3Ah
je store_evex_0f3a_instruction_code
mov al,11110001b
make_evex:
mov [edi+4],ah
mov byte [edi],62h
mov ah,[rex_prefix]
shl ah,5
xor al,ah
mov ah,[vex_required]
and ah,10h
xor al,ah
mov [edi+1],al
call check_vex
mov al,[vex_register]
not al
and al,1111b
shl al,3
mov ah,[rex_prefix]
shl ah,4
or ah,[rex_prefix]
and ah,80h
or al,ah
or al,100b
call get_vex_pp_bits
mov [edi+2],al
mov al,[vex_register]
not al
shr al,1
and al,1000b
test [vex_required],80h
jne evex_rounding
mov ah,[operand_size]
cmp ah,16
jbe evex_l_ok
or al,ah
jmp evex_l_ok
evex_rounding:
mov ah,[rounding_mode]
shl ah,5
or al,ah
evex_l_ok:
test [vex_required],20h
jz evex_zaaa_ok
or al,[mask_register]
evex_zaaa_ok:
test [vex_required],40h
jz evex_b_ok
or al,10h
evex_b_ok:
mov [edi+3],al
add edi,5
ret
store_evex_0f38_instruction_code:
mov al,11110010b
mov ah,[supplemental_code]
jmp make_evex
store_evex_0f3a_instruction_code:
mov al,11110011b
mov ah,[supplemental_code]
jmp make_evex
compress_displacement:
mov ebp,ecx
mov [uncompressed_displacement],edx
or edx,edx
jz displacement_compressed
xor ecx,ecx
mov cl,[mmx_size]
test cl,cl
jnz calculate_displacement_scale
mov cl,[operand_size]
calculate_displacement_scale:
bsf ecx,ecx
jz displacement_compression_ok
xor eax,eax
shrd eax,edx,cl
jnz displacement_not_compressed
sar edx,cl
cmp edx,80h
jb displacement_compressed
cmp edx,-80h
jnb displacement_compressed
shl edx,cl
displacement_not_compressed:
inc [displacement_compression]
jmp displacement_compression_ok
displacement_compressed:
add [displacement_compression],2
displacement_compression_ok:
mov ecx,ebp
ret
|