#include "gc.h" /* * code sequences for multiply by constant. * [a-l][0-3] * lsl $(A-'a'),r0,r1 * [+][0-7] * add r0,r1,r2 * [-][0-7] * sub r0,r1,r2 */ Multab multab[] = { 3, "b2+1", 5, "c2+1", 6, "b0b2+1", 7, "d2-2", 9, "d2+1", 10, "b0c2+1", 11, "b2+5c3-2", 12, "c0b2+1", 13, "b2+5c3+1", 14, "b0d2-2", 15, "e2-2", 17, "e2+1", 18, "b0d2+1", 19, "b2+5e0+1", 20, "c0c2+1", 21, "b2+5d1-1", 22, "b2+1d0-1", 23, "b2+5d3-2", 24, "d0b2+1", 25, "b2+5d3+1", 26, "b2+1d0+1", 27, "b2+5d1+1", 28, "c0d2-2", 29, "b2+5f0-1", 30, "b0e2-2", 31, "f2-2", 33, "f2+1", 34, "b0e2+1", 35, "b2+5f0+1", 36, "c0d2+1", 37, "c2+5f0+1", 38, "b0b2+5e0+1", 39, "c2+5d3-2", 40, "d0c2+1", 41, "c2+5d3+1", 42, "b0b2+5d1-1", 43, "b2+1+5d3+1", 44, "c2+1d0+1", 45, "b2+5e1-1", 46, "b2+1e0-1", 47, "b2+5e3-2", 48, "e0b2+1", 49, "b2+5e3+1", 50, "b2+1e0+1", 51, "b2+5e1+1", 52, "c2-2e0+1", 53, "b2+1+5e0+1", 54, "b0b2+5d1+1", 55, "d2+5g0-1", 56, "d0d2-2", 57, "d2-6d3+1", 58, "b0b2+5f0-1", 59, "c2+5g0-1", 60, "c0e2-2", 61, "b2+5g0-1", 62, "b0f2-2", 63, "g2-2", 65, "g2+1", 66, "b0f2+1", 67, "b2+5g0+1", 68, "c0e2+1", 69, "c2+5g0+1", 70, "b0b2+5f0+1", 71, "d2+5d3-2", 72, "d0d2+1", 73, "d2+5d3+1", 74, "b0c2+5f0+1", 75, "c2+5e1-1", 76, "c2+1e0-1", 77, "b2+1+5e3-2", 78, "b0c2+5d3-2", 79, "c2+5e3-2", 80, "e0c2+1", 81, "c2+5e3+1", 82, "b0c2+5d3+1", 83, "b2+1+5e3+1", 84, "c2+1e0+1", 85, "c2+5e1+1", 86, "c2+5+1e3+1", 87, "b2+5b1+5e0-1", 88, "b0c2+1d0+1", 89, "c2+1+5e0+1", 90, "b0b2+5e1-1", 91, "b2+1+5f0-1", 92, "c2-2f0-1", 93, "b2+5f1-1", 94, "b2+1f0-1", 95, "b2+5f3-2", 96, "f0b2+1", 97, "b2+5f3+1", 98, "b2+1f0+1", 99, "b2+5f1+1", 100, "c2-2f0+1", 101, "b2+1+5f0+1", 102, "b0b2+5e1+1", 103, "c2-2+5f0+1", 104, "d2-2e0-1", 105, "d2-6e1-1", 106, "d2-6-2e3-2", 107, "b2+5c3-2d3+1", 108, "c0b2+5d1+1", 109, "c2-2+5e3-2", 110, "b0d2+5g0-1", 111, "d2-6e3-2", 112, "e0d2-2", 113, "d2-6e3+1", 114, "b0d2-6d3+1", 115, "c2-2+5e3+1", 116, "c0b2+5f0-1", 117, "b2+5c1+1d0-1", 118, "b0c2+5g0-1", 119, "d2+5h0-1", 120, "d0e2-2", 121, "d2-6h0-1", 122, "b0b2+5g0-1", 123, "c2+5h0-1", 124, "c0f2-2", 125, "b2+5h0-1", 126, "b0g2-2", 127, "h2-2", 129, "h2+1", 130, "b0g2+1", 131, "b2+5h0+1", 132, "c0f2+1", 133, "c2+5h0+1", 134, "b0b2+5g0+1", 135, "d2+5e1-1", 136, "d0e2+1", 137, "d2+5h0+1", 138, "b0c2+5g0+1", 139, "c2+1+5e3-2", 140, "c0b2+5f0+1", 141, "b2+5b1+1e0-1", 142, "b0d2+5d3-2", 143, "d2+5e3-2", 144, "e0d2+1", 145, "d2+5e3+1", 146, "b0d2+5d3+1", 147, "b2+5b1+1e0+1", 148, "c0c2+5f0+1", 149, "c2+1+5e3+1", 150, "b0c2+5e1-1", 151, "c2+1+5f0-1", 152, "d2+1e0+1", 153, "d2+5e1+1", 154, "c2+5+1f3-2", 155, "c2+5f1-1", 156, "c2+1f0-1", 157, "b2+1+5f3-2", 158, "b0c2+5e3-2", 159, "c2+5f3-2", 160, "f0c2+1", 161, "c2+5f3+1", 162, "b0c2+5e3+1", 163, "b2+1+5f3+1", 164, "c2+1f0+1", 165, "c2+5f1+1", 166, "c2+5+1f3+1", 167, "b2+5d3+1d3-2", 168, "b0c2+1e0+1", 169, "c2+1+5f0+1", 170, "b0c2+5e1+1", 171, "b2+5d1-1g3-2", 172, "b0c2+5+1e3+1", 173, "b2+5d0+1e0-1", 174, "b2+1d0-1d0-1", 175, "b2+5c3-6e3-2", 176, "c0c2+1d0+1", 177, "b2+5c1+5e0-1", 178, "b0c2+1+5e0+1", 179, "b2+5c3+1e3-2", 180, "c0b2+5e1-1", 181, "b2+5c3-2e3-2", 182, "b0b2+1+5f0-1", 183, "b2+5b1+5f0-1", 184, "b0c2-2f0-1", 185, "c2-2+5g0-1", 186, "b0b2+5f1-1", 187, "b2+1+5g0-1", 188, "c2-2g0-1", 189, "b2+5g1-1", 190, "b2+1g0-1", 191, "b2+5g3-2", 192, "g0b2+1", 193, "b2+5g3+1", 194, "b2+1g0+1", 195, "b2+5g1+1", 196, "c2-2g0+1", 197, "b2+1+5g0+1", 198, "b0b2+5f1+1", 199, "c2-2+5g0+1", 200, "b0c2-2f0+1", 210, "b0d2-6e1-1", 220, "c0d2+5g0-1", 230, "d2-6-2f3+1", 240, "e0e2-2", 250, "b0b2+5h0-1", 260, "c0g2+1", 270, "b0d2+5e1-1", 280, "d2+1f0-1", 290, "b0d2+5e3+1", 300, "c0c2+5e1-1", 310, "b0c2+5f1-1", 320, "g0c2+1", 330, "b0c2+5f1+1", 340, "c0c2+5e1+1", 350, "b2+1d0-1e0-1", 360, "d0b2+5e1-1", 370, "b0c2-2+5g0-1", 380, "c2-2h0-1", 390, "b0b2+5g1+1", 400, "c0c2-2f0+1", 410, "b2+1d0+5e0+1", 420, "c0d2-6e1-1", 430, "b2+1e0-5d0+1", 440, "d2-2g0-1", 450, "b0d2-6f3+1", 460, "b0d2-6-2f3+1", 470, "b2+1f0-1c2+1", 480, "f0e2-2", 490, "b2+1d0-1i3-2", 500, "c0b2+5h0-1", 510, "b0i2-2", 520, "d0g2+1", 530, "b0d2+5i0+1", 540, "c0d2+5e1-1", 550, "d2+1b0+5f0-1", 560, "e2+1f0+1", 570, "b2+5b1+5g3-2", 580, "c0d2+5e3+1", 590, "c2+1+5+1g3+1", 600, "d0c2+5e1-1", 610, "b0d2+1+5f0+1", 620, "c0c2+5f1-1", 630, "b0c2+5g1-1", 640, "h0c2+1", 650, "b0c2+5g1+1", 660, "c0c2+5f1+1", 670, "b2+1f0+5d0-1", 680, "d0c2+5e1+1", 690, "b2+1e0-1e2-2", 700, "c2+1d0+1e0-1", 710, "c2+5+1+5g3+1", 720, "e0b2+5e1-1", 740, "c0c2-2+5g0-1", 750, "b2+1e0+5e1-1", 760, "b0c2-2h0-1", 770, "b2+1i0+1", 780, "c0b2+5g1+1", 790, "b2+1d0-5f0+1", 800, "d0c2-2f0+1", 820, "b2+5c3+1g0-1", 830, "b2+1d0+1f0-1", 840, "d0d2-6e1-1", 850, "b2+1e0+5e1+1", 860, "c2+1f0+1i3-2", 880, "b0d2-2g0-1", 890, "d2-6-2h3-2", 900, "c0d2-6f3+1", 910, "b0d2-6g1+1", 920, "c0d2-6-2f3+1", 930, "b0e2-6f1-1", 940, "c2+5c1-5g3-2", 950, "b2+1g0-1c2+1", 960, "g0e2-2", 970, "b2+1g0+5c1+1", 980, "c2+5c1-5g3+1", 990, "b0e2+5j0-1", 1000, "d0b2+5h0-1", 1050, "b2+1d0+1j3+1", 1100, "c2+1e0-1i3+1", 1150, "b0d2+5g3-2", 1200, "e0c2+5e1-1", 1300, "c0c2+5g1+1", 1400, "b2+5d0+5h3-2", 1500, "c2-2f0+5e1-1", 1550, "b0c2-2+5i0+1", 1600, "e0c2-2f0+1", 1650, "b2+1e0+5f1+1", 1700, "c2-2f0+5e1+1", 1800, "d2-2i0+1", 1900, "c2+5c1-5h3-2", 1950, "b0e2-6g1+1", 2000, "e0b2+5h0-1", 2050, "b0k2+1", 2100, "c2-2e0+1j3+1", 2150, "d2+1+5+1h3-2", 2200, "c2+5d1-5g3-2", 2300, "c0d2+5g3-2", 2400, "f0c2+5e1-1", 2450, "d2+5b3+1h0+1", 2500, "c2+1f0-1e0+1", 2550, "b0c2+5i1-1", 2600, "d0c2+5g1+1", 2800, "c2+5e1+5f3+1", 2850, "b2+1g0-1e2-2", 3050, "b2+1d0-5h0-1", 3100, "c0c2-2+5i0+1", 3150, "b2+1e0+5g1-1", 3200, "f0c2-2f0+1", 3250, "b2+1e0+5g1+1", 3300, "c2-2f0+5f1+1", 3600, "b0d2-2i0+1", 3800, "d2+1f0+1j3-2", 3850, "b2+1i0+5c1+1", 3900, "c0e2-6g1+1", 4000, "f2-2h0+1", 4050, "b2+1e0-1l3-2", 4100, "c0k2+1", 4200, "d2+1f0-1e2-2", 4300, "e2+1c0-5g0-1", 4350, "b0e2+5h3-2", 4400, "b2+5i0+5e3+1", 4600, "d2+1j0-1", 4700, "d2+5c3+1h0-1", 4800, "g0c2+5e1-1", 5000, "d2-2h0+1j3+1", 5100, "c0c2+5i1-1", 5200, "e0c2+5g1+1", 5400, "b2+5d1-5i3+1", 5700, "c2-2h0-1e2-2", 5800, "c2+5d1+5h3+1", 5950, "b2+1g0+5f0-1", 6000, "e2+1h0+1j3-2", 6050, "b2+1f0-5g0-1", 6100, "c2-2e0-5h0-1", 6150, "b0b2+5k1+1", 6200, "d0c2-2+5i0+1", 6300, "c2-2f0+5g1-1", 6350, "b2+1e0+5h1-1", 6400, "g0c2-2f0+1", 6450, "b2+1e0+5h1+1", 6500, "c2-2f0+5g1+1", 6600, "d2-2g0-1e2-2", 6650, "d2-6-2+5j3-2", 7200, "c0d2-2i0+1", 7400, "d2-2f0+5f0+1", 7600, "c2+5j0-5e3-2", 7650, "b0e2-6i1-1", 7700, "c2+5c1-5j3+1", 7800, "d0e2-6g1+1", 8000, "g2-2h0-1", 8100, "c2-2f0-1l3-2", 8200, "d0k2+1", 8350, "f2+1b0+5h0-1", 8400, "e2+5e3-2f0-1", 8450, "b0f2+5h3+1", 8700, "c0e2+5h3-2", 8900, "e2+5c3+1h0+1", 9000, "c2+5d1-5i3+1", 9200, "b0d2+1j0-1", 9250, "b0d2+1+5j0+1", 9600, "h0c2+5e1-1", 9800, "d2+1g0+5e0+1", }; int multabsize = sizeof(multab) / sizeof(multab[0]);