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 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202 7203 7204 7205 7206 7207 7208 7209 7210 7211 7212 7213 7214 7215 7216 7217 7218 7219 7220 7221 7222 7223 7224 7225 7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239 7240 7241 7242 7243 7244 7245 7246 7247 7248 7249 7250 7251 7252 7253 7254 7255 7256 7257 7258 7259 7260 7261 7262 7263 7264 7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 7377 7378 7379 7380 7381 7382 7383 7384 7385 7386 7387 7388 7389 7390 7391 7392 7393 7394 7395 7396 7397 7398 7399 7400 7401 7402 7403 7404 7405 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 7425 7426 7427 7428 7429 7430 7431 7432 7433 7434 7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 7446 7447 7448 7449 7450 7451 7452 7453 7454 7455 7456 7457 7458 7459 7460 7461 7462 7463 7464 7465 7466 7467 7468 7469 7470 7471 7472 7473 7474 7475 7476 7477 7478 7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 7490 7491 7492 7493 7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 7505 7506 7507 7508 7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 7520 7521 7522 7523 7524 7525 7526 7527 7528 7529 7530 7531 7532 7533 7534 7535 7536 7537 7538 7539 7540 7541 7542 7543 7544 7545 7546 7547 7548 7549 7550 7551 7552 7553 7554 7555 7556 7557 7558 7559 7560 7561 7562 7563 7564 7565 7566 7567 7568 7569 7570 7571 7572 7573 7574 7575 7576 7577 7578 7579 7580 7581 7582 7583 7584 7585 7586 7587 7588 7589 7590 7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 7668 7669 7670 7671 7672 7673 7674 7675 7676 7677 7678 7679 7680 7681 7682 7683 7684 7685 7686 7687 7688 7689 7690 7691 7692 7693 7694 7695 7696 7697 7698 7699 7700 7701 7702 7703 7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 7719 7720 7721 7722 7723 7724 7725 7726 7727 7728 7729 7730 7731 7732 7733 7734 7735 7736 7737 7738 7739 7740 7741 7742 7743 7744 7745 7746 7747 7748 7749 7750 7751 7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774 7775 7776 7777 7778 7779 7780 7781 7782 7783 7784 7785 7786 7787 7788 7789 7790 7791 7792 7793 7794 7795 7796 7797 7798 7799 7800 7801 7802 7803 7804 7805 7806 7807 7808 7809 7810 7811 7812 7813 7814 7815 7816 7817 7818 7819 7820 7821 7822 7823 7824 7825 7826 7827 7828 7829 7830 7831 7832 7833 7834 7835 7836 7837 7838 7839 7840 7841 7842 7843 7844 7845 7846 7847 7848 7849 7850 7851 7852 7853 7854 7855 7856 7857 7858 7859 7860 7861 7862 7863 7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 7892 7893 7894 7895 7896 7897 7898 7899 7900 7901 7902 7903 7904 7905 7906 7907 7908 7909 7910 7911 7912 7913 7914 7915 7916 7917 7918 7919 7920 7921 7922 7923 7924 7925 7926 7927 7928 7929 7930 7931 7932 7933 7934 7935 7936 7937 7938 7939 7940 7941 7942 7943 7944 7945 7946 7947 7948 7949 7950 7951 7952 7953 7954 7955 7956 7957 7958 7959 7960 7961 7962 7963 7964 7965 7966 7967 7968 7969 7970 7971 7972 7973 7974 7975 7976 7977 7978 7979 7980 7981 7982 7983 7984 7985 7986 7987 7988 7989 7990 7991 7992 7993 7994 7995 7996 7997 7998 7999 8000 8001 8002 8003 8004 8005 8006 8007 8008 8009 8010 8011 8012 8013 8014 8015 8016 8017 8018 8019 8020 8021 8022 8023 8024 8025 8026 8027 8028 8029 8030 8031 8032 8033 8034 8035 8036 8037 8038 8039 8040 8041 8042 8043 8044 8045 8046 8047 8048 8049 8050 8051 8052 8053 8054 8055 8056 8057 8058 8059 8060 8061 8062 8063 8064 8065 8066 8067 8068 8069 8070 8071 8072 8073 8074 8075 8076 8077 8078 8079 8080 8081 8082 8083 8084 8085 8086 8087 8088 8089 8090 8091 8092 8093 8094 8095 8096 8097 8098 8099 8100 8101 8102 8103 8104 8105 8106 8107 8108 8109 8110 8111 8112 8113 8114 8115 8116 8117 8118 8119 8120 8121 8122 8123 8124 8125 8126 8127 8128 8129 8130 8131 8132 8133 8134 8135 8136 8137 8138 8139 8140 8141 8142 8143 8144 8145 8146 8147 8148 8149 8150 8151 8152 8153 8154 8155 8156 8157 8158 8159 8160 8161 8162 8163 8164 8165 8166 8167 8168 8169 8170 8171 8172 8173 8174 8175 8176 8177 8178 8179 8180 8181 8182 8183 8184 8185 8186 8187 8188 8189 8190 8191 8192 8193 8194 8195 8196 8197 8198 8199 8200 8201 8202 8203 8204 8205 8206 8207 8208 8209 8210 8211 8212 8213 8214 8215 8216 8217 8218 8219 8220 8221 8222 8223 8224 8225 8226 8227 8228 8229 8230 8231 8232 8233 8234 8235 8236 8237 8238 8239 8240 8241 8242 8243 8244 8245 8246 8247 8248 8249 8250 8251 8252 8253 8254 8255 8256 8257 8258 8259 8260 8261 8262 8263 8264 8265 8266 8267 8268 8269 8270 8271 8272 8273 8274 8275 8276 8277 8278 8279 8280 8281 8282 8283 8284 8285 8286 8287 8288 8289 8290 8291 8292 8293 8294 8295 8296 8297 8298 8299 8300 8301 8302 8303 8304 8305 8306 8307 8308 8309 8310 8311 8312 8313 8314 8315 8316 8317 8318 8319 8320 8321 8322 8323 8324 8325 8326 8327 8328 8329 8330 8331 8332 8333 8334 8335 8336 8337 8338 8339 8340 8341 8342 8343 8344 8345 8346 8347 8348 8349 8350 8351 8352 8353 8354 8355 8356 8357 8358 8359 8360 8361 8362 8363 8364 8365 8366 8367 8368 8369 8370 8371 8372 8373 8374 8375 8376 8377 8378 8379 8380 8381 8382 8383 8384 8385 8386 8387 8388 8389 8390 8391 8392 8393 8394 8395 8396 8397 8398 8399 8400 8401 8402 8403 8404 8405 8406 8407 8408 8409 8410 8411 8412 8413 8414 8415 8416 8417 8418 8419 8420 8421 8422 8423 8424 8425 8426 8427 8428 8429 8430 8431 8432 8433 8434 8435 8436 8437 8438 8439 8440 8441 8442 8443 8444 8445 8446 8447 8448 8449 8450 8451 8452 8453 8454 8455 8456 8457 8458 8459 8460 8461 8462 8463 8464 8465 8466 8467 8468 8469 8470 8471 8472 8473 8474 8475 8476 8477 8478 8479 8480 8481 8482 8483 8484 8485 8486 8487 8488 8489 8490 8491 8492 8493 8494 8495 8496 8497 8498 8499 8500 8501 8502 8503 8504 8505 8506 8507 8508 8509 8510 8511 8512 8513 8514 8515 8516 8517 8518 8519 8520 8521 8522 8523 8524 8525 8526 8527 8528 8529 8530 8531 8532 8533 8534 8535 8536 8537 8538 8539 8540 8541 8542 8543 8544 8545 8546 8547 8548 8549 8550 8551 8552 8553 8554 8555 8556 8557 8558 8559 8560 8561 8562 8563 8564 8565 8566 8567 8568 8569 8570 8571 8572 8573 8574 8575 8576 8577 8578 8579 8580 8581 8582 8583 8584 8585 8586 8587 8588 8589 8590 8591 8592 8593 8594 8595 8596 8597 8598 8599 8600 8601 8602 8603 8604 8605 8606 8607 8608 8609 8610 8611 8612 8613 8614 8615 8616 8617 8618 8619 8620 8621 8622 8623 8624 8625 8626 8627 8628 8629 8630 8631 8632 8633 8634 8635 8636 8637 8638 8639 8640 8641 8642 8643 8644 8645 8646 8647 8648 8649 8650 8651 8652 8653 8654 8655 8656 8657 8658 8659 8660 8661 8662 8663 8664 8665 8666 8667 8668 8669 8670 8671 8672 8673 8674 8675 8676 8677 8678 8679 8680 8681 8682 8683 8684 8685 8686 8687 8688 8689 8690 8691 8692 8693 8694 8695 8696 8697 8698 8699 8700 8701 8702 8703 8704 8705 8706 8707 8708 8709 8710 8711 8712 8713 8714 8715 8716 8717 8718 8719 8720 8721 8722 8723 8724 8725 8726 8727 8728 8729 8730 8731 8732 8733 8734 8735 8736 8737 8738 8739 8740 8741 8742 8743 8744 8745 8746 8747 8748 8749 8750 8751 8752 8753 8754 8755 8756 8757 8758 8759 8760 8761 8762 8763 8764 8765 8766 8767 8768 8769 8770 8771 8772 8773 8774 8775 8776 8777 8778 8779 8780 8781 8782 8783 8784 8785 8786 8787 8788 8789 8790 8791 8792 8793 8794 8795 8796 8797 8798 8799 8800 8801 8802 8803 8804 8805 8806 8807 8808 8809 8810 8811 8812 8813 8814 8815 8816 8817 8818 8819 8820 8821 8822 8823 8824 8825 8826 8827 8828 8829 8830 8831 8832 8833 8834 8835 8836 8837 8838 8839 8840 8841 8842 8843 8844 8845 8846 8847 8848 8849 8850 8851 8852 8853 8854 8855 8856 8857 8858 8859 8860 8861 8862 8863 8864 8865 8866 8867 8868 8869 8870 8871 8872 8873 8874 8875 8876 8877 8878 8879 8880 8881 8882 8883 8884 8885 8886 8887 8888 8889 8890 8891 8892 8893 8894 8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913 8914 8915 8916 8917 8918 8919 8920 8921 8922 8923 8924 8925 8926 8927 8928 8929 8930 8931 8932 8933 8934 8935 8936 8937 8938 8939 8940 8941 8942 8943 8944 8945 8946 8947 8948 8949 8950 8951 8952 8953 8954 8955 8956 8957 8958 8959 8960 8961 8962 8963 8964 8965 8966 8967 8968 8969 8970 8971 8972 8973 8974 8975 8976 8977 8978 8979 8980 8981 8982 8983 8984 8985 8986 8987 8988 8989 8990 8991 8992 8993 8994 8995 8996 8997 8998 8999 9000 9001 9002 9003 9004 9005 9006 9007 9008 9009 9010 9011 9012 9013 9014 9015 9016 9017 9018 9019 9020 9021 9022 9023 9024 9025 9026 9027 9028 9029 9030 9031 9032 9033 9034 9035 9036 9037 9038 9039 9040 9041 9042 9043 9044 9045 9046 9047 9048 9049 9050 9051 9052 9053 9054 9055 9056 9057 9058 9059 9060 9061 9062 9063 9064 9065 9066 9067 9068 9069 9070 9071 9072 9073 9074 9075 9076 9077 9078 9079 9080 9081 9082 9083 9084 9085 9086 9087 9088 9089 9090 9091 9092 9093 9094 9095 9096 9097 9098 9099 9100 9101 9102 9103 9104 9105 9106 9107 9108 9109 9110 9111 9112 9113 9114 9115 9116 9117 9118 9119 9120 9121 9122 9123 9124 9125 9126 9127 9128 9129 9130 9131 9132 9133 9134 9135 9136 9137 9138 9139 9140 9141 9142 9143 9144 9145 9146 9147 9148 9149 9150 9151 9152 9153 9154 9155 9156 9157 9158 9159 9160 9161 9162 9163 9164 9165 9166 9167 9168 9169 9170 9171 9172 9173 9174 9175 9176 9177 9178 9179 9180 9181 9182 9183 9184 9185 9186 9187 9188 9189 9190 9191 9192 9193 9194 9195 9196 9197 9198 9199 9200 9201 9202 9203 9204 9205 9206 9207 9208 9209 9210 9211 9212 9213 9214 9215 9216 9217 9218 9219 9220 9221 9222 9223 9224 9225 9226 9227 9228 9229 9230 9231 9232 9233 9234 9235 9236 9237 9238 9239 9240 9241 9242 9243 9244 9245 9246 9247 9248 9249 9250 9251 9252 9253 9254 9255 9256 9257 9258 9259 9260 9261 9262 9263 9264 9265 9266 9267 9268 9269 9270 9271 9272 9273 9274 9275 9276 9277 9278 9279 9280 9281 9282 9283 9284 9285 9286 9287 9288 9289 9290 9291 9292 9293 9294 9295 9296 9297 9298 9299 9300 9301 9302 9303 9304 9305 9306 9307 9308 9309 9310 9311 9312 9313 9314 9315 9316 9317 9318 9319 9320 9321 9322 9323 9324 9325 9326 9327 9328 9329 9330 9331 9332 9333 9334 9335 9336 9337 9338 9339 9340 9341 9342 9343 9344 9345 9346 9347 9348 9349 9350 9351 9352 9353 9354 9355 9356 9357 9358 9359 9360 9361 9362 9363 9364 9365 9366 9367 9368 9369 9370 9371 9372 9373 9374 9375 9376 9377 9378 9379 9380 9381 9382 9383 9384 9385 9386 9387 9388 9389 9390 9391 9392 9393 9394 9395 9396 9397 9398 9399 9400 9401 9402 9403 9404 9405 9406 9407 9408 9409 9410 9411 9412 9413 9414 9415 9416 9417 9418 9419 9420 9421 9422 9423 9424 9425 9426 9427 9428 9429 9430 9431 9432 9433 9434 9435 9436 9437 9438 9439 9440 9441 9442 9443 9444 9445 9446 9447 9448 9449 9450 9451 9452 9453 9454 9455 9456 9457 9458 9459 9460 9461 9462 9463 9464 9465 9466 9467 9468 9469 9470 9471 9472 9473 9474 9475 9476 9477 9478 9479 9480 9481 9482 9483 9484 9485 9486 9487 9488 9489 9490 9491 9492 9493 9494 9495 9496 9497 9498 9499 9500 9501 9502 9503 9504 9505 9506 9507 9508 9509 9510 9511 9512 9513 9514 9515 9516 9517 9518 9519 9520 9521 9522 9523 9524 9525 9526 9527 9528 9529 9530 9531 9532 9533 9534 9535 9536 9537 9538 9539 9540 9541 9542 9543 9544 9545 9546 9547 9548 9549 9550 9551 9552 9553 9554 9555 9556 9557 9558 9559 9560 9561 9562 9563 9564 9565 9566 9567 9568 9569 9570 9571 9572 9573 9574 9575 9576 9577 9578 9579 9580 9581 9582 9583 9584 9585 9586 9587 9588 9589 9590 9591 9592 9593 9594 9595 9596 9597 9598 9599 9600 9601 9602 9603 9604 9605 9606 9607 9608 9609 9610 9611 9612 9613 9614 9615 9616 9617 9618 9619 9620 9621 9622 9623 9624 9625 9626 9627 9628 9629 9630 9631 9632 9633 9634 9635 9636 9637 9638 9639 9640 9641 9642 9643 9644 9645 9646 9647 9648 9649 9650 9651 9652 9653 9654 9655 9656 9657 9658 9659 9660 9661 9662 9663 9664 9665 9666 9667 9668 9669 9670 9671 9672 9673 9674 9675 9676 9677 9678 9679 9680 9681 9682 9683 9684 9685 9686 9687 9688 9689 9690 9691 9692 9693 9694 9695 9696 9697 9698 9699 9700 9701 9702 9703 9704 9705 9706 9707 9708 9709 9710 9711 9712 9713 9714 9715 9716 9717 9718 9719 9720 9721 9722 9723 9724 9725 9726 9727 9728 9729 9730 9731 9732 9733 9734 9735 9736 9737 9738 9739 9740 9741 9742 9743 9744 9745 9746 9747 9748 9749 9750 9751 9752 9753 9754 9755 9756 9757 9758 9759 9760 9761 9762 9763 9764 9765 9766 9767 9768 9769 9770 9771 9772 9773 9774 9775 9776 9777 9778 9779 9780 9781 9782 9783 9784 9785 9786 9787 9788 9789 9790 9791 9792 9793 9794 9795 9796 9797 9798 9799 9800 9801 9802 9803 9804 9805 9806 9807 9808 9809 9810 9811 9812 9813 9814 9815 9816 9817 9818 9819 9820 9821 9822 9823 9824 9825 9826 9827 9828 9829 9830 9831 9832 9833 9834 9835 9836 9837 9838 9839 9840 9841 9842 9843 9844 9845 9846 9847 9848 9849 9850 9851 9852 9853 9854 9855 9856 9857 9858 9859 9860 9861 9862 9863 9864 9865 9866 9867 9868 9869 9870 9871 9872 9873 9874 9875 9876 9877 9878 9879 9880 9881 9882 9883 9884 9885 9886 9887 9888 9889 9890 9891 9892 9893 9894 9895 9896 9897 9898 9899 9900 9901 9902 9903 9904 9905 9906 9907 9908 9909 9910 9911 9912 9913 9914 9915 9916 9917 9918 9919 9920 9921 9922 9923 9924 9925 9926 9927 9928 9929 9930 9931 9932 9933 9934 9935 9936 9937 9938 9939 9940 9941 9942 9943 9944 9945 9946 9947 9948 9949 9950 9951 9952 9953 9954 9955 9956 9957 9958 9959 9960 9961 9962 9963 9964 9965 9966 9967 9968 9969 9970 9971 9972 9973 9974 9975 9976 9977 9978 9979 9980 9981 9982 9983 9984 9985 9986 9987 9988 9989 9990 9991 9992 9993 9994 9995 9996 9997 9998 9999 10000 10001 10002 10003 10004 10005 10006 10007 10008 10009 10010 10011 10012 10013 10014 10015 10016 10017 10018 10019 10020 10021 10022 10023 10024 10025 10026 10027 10028 10029 10030 10031 10032 10033 10034 10035 10036 10037 10038 10039 10040 10041 10042 10043 10044 10045 10046 10047 10048 10049 10050 10051 10052 10053 10054 10055 10056 10057 10058 10059 10060 10061 10062 10063 10064 10065 10066 10067 10068 10069 10070 10071 10072 10073 10074 10075 10076 10077 10078 10079 10080 10081 10082 10083 10084 10085 10086 10087 10088 10089 10090 10091 10092 10093 10094 10095 10096 10097 10098 10099 10100 10101 10102 10103 10104 10105 10106 10107 10108 10109 10110 10111 10112 10113 10114 10115 10116 10117 10118 10119 10120 10121 10122 10123 10124 10125 10126 10127 10128 10129 10130 10131 10132 10133 10134 10135 10136 10137 10138 10139 10140 10141 10142 10143 10144 10145 10146 10147 10148 10149 10150 10151 10152 10153 10154 10155 10156 10157 10158 10159 10160 10161 10162 10163 10164 10165 10166 10167 10168 10169 10170 10171 10172 10173 10174 10175 10176 10177 10178 10179 10180 10181 10182 10183 10184 10185 10186 10187 10188 10189 10190 10191 10192 10193 10194 10195 10196 10197 10198 10199 10200 10201 10202 10203 10204 10205 10206 10207 10208 10209 10210 10211 10212 10213 10214 10215 10216 10217 10218 10219 10220 10221 10222 10223 10224 10225 10226 10227 10228 10229 10230 10231 10232 10233 10234 10235 10236 10237 10238 10239 10240 10241 10242 10243 10244 10245 10246 10247 10248 10249 10250 10251 10252 10253 10254 10255 10256 10257 10258 10259 10260 10261 10262 10263 10264 10265 10266 10267 10268 10269 10270 10271 10272 10273 10274 10275 10276 10277 10278 10279 10280 10281 10282 10283 10284 10285 10286 10287 10288 10289 10290 10291 10292 10293 10294 10295 10296 10297 10298 10299 10300 10301 10302 10303 10304 10305 10306 10307 10308 10309 10310 10311 10312 10313 10314 10315 10316 10317 10318 10319 10320 10321 10322 10323 10324 10325 10326 10327 10328 10329 10330 10331 10332 10333 10334 10335 10336 10337 10338 10339 10340 10341 10342 10343 10344 10345 10346 10347 10348 10349 10350 10351 10352 10353 10354 10355 10356 10357 10358 10359 10360 10361 10362 10363 10364 10365 10366 10367 10368 10369 10370 10371 10372 10373 10374 10375 10376 10377 10378 10379 10380 10381 10382 10383 10384 10385 10386 10387 10388 10389 10390 10391 10392 10393 10394 10395 10396 10397 10398 10399 10400 10401 10402 10403 10404 10405 10406 10407 10408 10409 10410 10411 10412 10413 10414 10415 10416 10417 10418 10419 10420 10421 10422 10423 10424 10425 10426 10427 10428 10429 10430 10431 10432 10433 10434 10435 10436 10437 10438 10439 10440 10441 10442 10443 10444 10445 10446 10447 10448 10449 10450 10451 10452 10453 10454 10455 10456 10457 10458 10459 10460 10461 10462 10463 10464 10465 10466 10467 10468 10469 10470 10471 10472 10473 10474 10475 10476 10477 10478 10479 10480 10481 10482 10483 10484 10485 10486 10487 10488 10489 10490 10491 10492 10493 10494 10495 10496 10497 10498 10499 10500 10501 10502 10503 10504 10505 10506 10507 10508 10509 10510 10511 10512 10513 10514 10515 10516 10517 10518 10519 10520 10521 10522 10523 10524 10525 10526 10527 10528 10529 10530 10531 10532 10533 10534 10535 10536 10537 10538 10539 10540 10541 10542 10543 10544 10545 10546 10547 10548 10549 10550 10551 10552 10553 10554 10555 10556 10557 10558 10559 10560 10561 10562 10563 10564 10565 10566 10567 10568 10569 10570 10571 10572 10573 10574 10575 10576 10577 10578 10579 10580 10581 10582 10583 10584 10585 10586 10587 10588 10589 10590 10591 10592 10593 10594 10595 10596 10597 10598 10599 10600 10601 10602 10603 10604 10605 10606 10607 10608 10609 10610 10611 10612 10613 10614 10615 10616 10617 10618 10619 10620 10621 10622 10623 10624 10625 10626 10627 10628 10629 10630 10631 10632 10633 10634 10635 10636 10637 10638 10639 10640 10641 10642 10643 10644 10645 10646 10647 10648 10649 10650 10651 10652 10653 10654 10655 10656 10657 10658 10659 10660 10661 10662 10663 10664 10665 10666 10667 10668 10669 10670 10671 10672 10673 10674 10675 10676 10677 10678 10679 10680 10681 10682 10683 10684 10685 10686 10687 10688 10689 10690 10691 10692 10693 10694 10695 10696 10697 10698 10699 10700 10701 10702 10703 10704 10705 10706 10707 10708 10709 10710 10711 10712 10713 10714 10715 10716 10717 10718 10719 10720 10721 10722 10723 10724 10725 10726 10727 10728 10729 10730 10731 10732 10733 10734 10735 10736 10737 10738 10739 10740 10741 10742 10743 10744 10745 10746 10747 10748 10749 10750 10751 10752 10753 10754 10755 10756 10757 10758 10759 10760 10761 10762 10763 10764 10765 10766 10767 10768 10769 10770 10771 10772 10773 10774 10775 10776 10777 10778 10779 10780 10781 10782 10783 10784 10785 10786 10787 10788 10789 10790 10791 10792 10793 10794 10795 10796 10797 10798 10799 10800 10801 10802 10803 10804 10805 10806 10807 10808 10809 10810 10811 10812 10813 10814 10815 10816 10817 10818 10819 10820 10821 10822 10823 10824 10825 10826 10827 10828 10829 10830 10831 10832 10833 10834 10835 10836 10837 10838 10839 10840 10841 10842 10843 10844 10845 10846 10847 10848 10849 10850 10851 10852 10853 10854 10855 10856 10857 10858 10859 10860 10861 10862 10863 10864 10865 10866 10867 10868 10869 10870 10871 10872 10873 10874 10875 10876 10877 10878 10879 10880 10881 10882 10883 10884 10885 10886 10887 10888 10889 10890 10891 10892 10893 10894 10895 10896 10897 10898 10899 10900 10901 10902 10903 10904 10905 10906 10907 10908 10909 10910 10911 10912 10913 10914 10915 10916 10917 10918 10919 10920 10921 10922 10923 10924 10925 10926 10927 10928 10929 10930 10931 10932 10933 10934 10935 10936 10937 10938 10939 10940 10941 10942 10943 10944 10945 10946 10947 10948 10949 10950 10951 10952 10953 10954 10955 10956 10957 10958 10959 10960 10961 10962 10963 10964 10965 10966 10967 10968 10969 10970 10971 10972 10973 10974 10975 10976 10977 10978 10979 10980 10981 10982 10983 10984 10985 10986 10987 10988 10989 10990 10991 10992 10993 10994 10995 10996 10997 10998 10999 11000 11001 11002 11003 11004 11005 11006 11007 11008 11009 11010 11011 11012 11013 11014 11015 11016 11017 11018 11019 11020 11021 11022 11023 11024 11025 11026 11027 11028 11029 11030 11031 11032 11033 11034 11035 11036 11037 11038 11039 11040 11041 11042 11043 11044 11045 11046 11047 11048 11049 11050 11051 11052 11053 11054 11055 11056 11057 11058 11059 11060 11061 11062 11063 11064 11065 11066 11067 11068 11069 11070 11071 11072 11073 11074 11075 11076 11077 11078 11079 11080 11081 11082 11083 11084 11085 11086 11087 11088 11089 11090 11091 11092 11093 11094 11095 11096 11097 11098 11099 11100 11101 11102 11103 11104 11105 11106 11107 11108 11109 11110 11111 11112 11113 11114 11115 11116 11117 11118 11119 11120 11121 11122 11123 11124 11125 11126 11127 11128 11129 11130 11131 11132 11133 11134 11135 11136 11137 11138 11139 11140 11141 11142 11143 11144 11145 11146 11147 11148 11149 11150 11151 11152 11153 11154 11155 11156 11157 11158 11159 11160 11161 11162 11163 11164 11165 11166 11167 11168 11169 11170 11171 11172 11173 11174 11175 11176 11177 11178 11179 11180 11181 11182 11183 11184 11185 11186 11187 11188 11189 11190 11191 11192 11193 11194 11195 11196 11197 11198 11199 11200 11201 11202 11203 11204 11205 11206 11207 11208 11209 11210 11211 11212 11213 11214 11215 11216 11217 11218 11219 11220 11221 11222 11223 11224 11225 11226 11227 11228 11229 11230 11231 11232 11233 11234 11235 11236 11237 11238 11239 11240 11241 11242 11243 11244 11245 11246 11247 11248 11249 11250 11251 11252 11253 11254 11255 11256 11257 11258 11259 11260 11261 11262 11263 11264 11265 11266 11267 11268 11269 11270 11271 11272 11273 11274 11275 11276 11277 11278 11279 11280 11281 11282 11283 11284 11285 11286 11287 11288 11289 11290 11291 11292 11293 11294 11295 11296 11297 11298 11299 11300 11301 11302 11303 11304 11305 11306 11307 11308 11309 11310 11311 11312 11313 11314 11315 11316 11317 11318 11319 11320 11321 11322 11323 11324 11325 11326 11327 11328 11329 11330 11331 11332 11333 11334 11335 11336 11337 11338 11339 11340 11341 11342 11343 11344 11345 11346 11347 11348 11349 11350 11351 11352 11353 11354 11355 11356 11357 11358 11359 11360 11361 11362 11363 11364 11365 11366 11367 11368 11369 11370 11371 11372 11373 11374 11375 11376 11377 11378 11379 11380 11381 11382 11383 11384 11385 11386 11387 11388 11389 11390 11391 11392 11393 11394 11395 11396 11397 11398 11399 11400 11401 11402 11403 11404 11405 11406 11407 11408 11409 11410 11411 11412 11413 11414 11415 11416 11417 11418 11419 11420 11421 11422 11423 11424 11425 11426 11427 11428 11429 11430 11431 11432 11433 11434 11435 11436 11437 11438 11439 11440 11441 11442 11443 11444 11445 11446 11447 11448 11449 11450 11451 11452 11453 11454 11455 11456 11457 11458 11459 11460 11461 11462 11463 11464 11465 11466 11467 11468 11469 11470 11471 11472 11473 11474 11475 11476 11477 11478 11479 11480 11481 11482 11483 11484 11485 11486 11487 11488 11489 11490 11491 11492 11493 11494 11495 11496 11497 11498 11499 11500 11501 11502 11503 11504 11505 11506 11507 11508 11509 11510 11511 11512 11513 11514 11515 11516 11517 11518 11519 11520 11521 11522 11523 11524 11525 11526 11527 11528 11529 11530 11531 11532 11533 11534 11535 11536 11537 11538 11539 11540 11541 11542 11543 11544 11545 11546 11547 11548 11549 11550 11551 11552 11553 11554 11555 11556 11557 11558 11559 11560 11561 11562 11563 11564 11565 11566 11567 11568 11569 11570 11571 11572 11573 11574 11575 11576 11577 11578 11579 11580 11581 11582 11583 11584 11585 11586 11587 11588 11589 11590 11591 11592 11593 11594 11595 11596 11597 11598 11599 11600 11601 11602 11603 11604 11605 11606 11607 11608 11609 11610 11611 11612 11613 11614 11615 11616 11617 11618 11619 11620 11621 11622 11623 11624 11625 11626 11627 11628 11629 11630 11631 11632 11633 11634 11635 11636 11637 11638 11639 11640 11641 11642 11643 11644 11645 11646 11647 11648 11649 11650 11651 11652 11653 11654 11655 11656 11657 11658 11659 11660 11661 11662 11663 11664 11665 11666 11667 11668 11669 11670 11671 11672 11673 11674 11675 11676 11677 11678 11679 11680 11681 11682 11683 11684 11685 11686 11687 11688 11689 11690 11691 11692 11693 11694 11695 11696 11697 11698 11699 11700 11701 11702 11703 11704 11705 11706 11707 11708 11709 11710 11711 11712 11713 11714 11715 11716 11717 11718 11719 11720 11721 11722 11723 11724 11725 11726 11727 11728 11729 11730 11731 11732 11733 11734 11735 11736 11737 11738 11739 11740 11741 11742 11743 11744 11745 11746 11747 11748 11749 11750 11751 11752 11753 11754 11755 11756 11757 11758 11759 11760 11761 11762 11763 11764 11765 11766 11767 11768 11769 11770 11771 11772 11773 11774 11775 11776 11777 11778 11779 11780 11781 11782 11783 11784 11785 11786 11787 11788 11789 11790 11791 11792 11793 11794 11795 11796 11797 11798 11799 11800 11801 11802 11803 11804 11805 11806 11807 11808 11809 11810 11811 11812 11813 11814 11815 11816 11817 11818 11819 11820 11821 11822 11823 11824 11825 11826 11827 11828 11829 11830 11831 11832 11833 11834 11835 11836 11837 11838 11839 11840 11841 11842 11843 11844 11845 11846 11847 11848 11849 11850 11851 11852 11853 11854 11855 11856 11857 11858 11859 11860 11861 11862 11863 11864 11865 11866 11867 11868 11869 11870 11871 11872 11873 11874 11875 11876 11877 11878 11879 11880 11881 11882 11883 11884 11885 11886 11887 11888 11889 11890 11891 11892 11893 11894 11895 11896 11897 11898 11899 11900 11901 11902 11903 11904 11905 11906 11907 11908 11909 11910 11911 11912 11913 11914 11915 11916 11917 11918 11919 11920 11921 11922 11923 11924 11925 11926 11927 11928 11929 11930 11931 11932 11933 11934 11935 11936 11937 11938 11939 11940 11941 11942 11943 11944 11945 11946 11947 11948 11949 11950 11951 11952 11953 11954 11955 11956 11957 11958 11959 11960 11961 11962 11963 11964 11965 11966 11967 11968 11969 11970 11971 11972 11973 11974 11975 11976 11977 11978 11979 11980 11981 11982 11983 11984 11985 11986 11987 11988 11989 11990 11991 11992 11993 11994 11995 11996 11997 11998 11999 12000 12001 12002 12003 12004 12005 12006 12007 12008 12009 12010 12011 12012 12013 12014 12015 12016 12017 12018 12019 12020 12021 12022 12023 12024 12025 12026 12027 12028 12029 12030 12031 12032 12033 12034 12035 12036 12037 12038 12039 12040 12041 12042 12043 12044 12045 12046 12047 12048 12049 12050 12051 12052 12053 12054 12055 12056 12057 12058 12059 12060 12061 12062 12063 12064 12065 12066 12067 12068 12069 12070 12071 12072 12073 12074 12075 12076 12077 12078 12079 12080 12081 12082 12083 12084 12085 12086 12087 12088 12089 12090 12091 12092 12093 12094 12095 12096 12097 12098 12099 12100 12101 12102 12103 12104 12105 12106 12107 12108 12109 12110 12111 12112 12113 12114 12115 12116 12117 12118 12119 12120 12121 12122 12123 12124 12125 12126 12127 12128 12129 12130 12131 12132 12133 12134 12135 12136 12137 12138 12139 12140 12141 12142 12143 12144 12145 12146 12147 12148 12149 12150 12151 12152 12153 12154 12155 12156 12157 12158 12159 12160 12161 12162 12163 12164 12165 12166 12167 12168 12169 12170 12171 12172 12173 12174 12175 12176 12177 12178 12179 12180 12181 12182 12183 12184 12185 12186 12187 12188 12189 12190 12191 12192 12193 12194 12195 12196 12197 12198 12199 12200 12201 12202 12203 12204 12205 12206 12207 12208 12209 12210 12211 12212 12213 12214 12215 12216 12217 12218 12219 12220 12221 12222 12223 12224 12225 12226 12227 12228 12229 12230 12231 12232 12233 12234 12235 12236 12237 12238 12239 12240 12241 12242 12243 12244 12245 12246 12247 12248 12249 12250 12251 12252 12253 12254 12255 12256 12257 12258 12259 12260 12261 12262 12263 12264 12265 12266 12267 12268 12269 12270 12271 12272 12273 12274 12275 12276 12277 12278 12279 12280 12281 12282 12283 12284 12285 12286 12287 12288 12289 12290 12291 12292 12293 12294 12295 12296 12297 12298 12299 12300 12301 12302 12303 12304 12305 12306 12307 12308 12309 12310 12311 12312 12313 12314 12315 12316 12317 12318 12319 12320 12321 12322 12323 12324 12325 12326 12327 12328 12329 12330 12331 12332 12333 12334 12335 12336 12337 12338 12339 12340 12341 12342 12343 12344 12345 12346 12347 12348 12349 12350 12351 12352 12353 12354 12355 12356 12357 12358 12359 12360 12361 12362 12363 12364 12365 12366 12367 12368 12369 12370 12371 12372 12373 12374 12375 12376 12377 12378 12379 12380 12381 12382 12383 12384 12385 12386 12387 12388 12389 12390 12391 12392 12393 12394 12395 12396 12397 12398 12399 12400 12401 12402 12403 12404 12405 12406 12407 12408 12409 12410 12411 12412 12413 12414 12415 12416 12417 12418 12419 12420 12421 12422 12423 12424 12425 12426 12427 12428 12429 12430 12431 12432 12433 12434 12435 12436 12437 12438 12439 12440 12441 12442 12443 12444 12445 12446 12447 12448 12449 12450 12451 12452 12453 12454 12455 12456 12457 12458 12459 12460 12461 12462 12463 12464 12465 12466 12467 12468 12469 12470 12471 12472 12473 12474 12475 12476 12477 12478 12479 12480 12481 12482 12483 12484 12485 12486 12487 12488 12489 12490 12491 12492 12493 12494 12495 12496 12497 12498 12499 12500 12501 12502 12503 12504 12505 12506 12507 12508 12509 12510 12511 12512 12513 12514 12515 12516 12517 12518 12519 12520 12521 12522 12523 12524 12525 12526 12527 12528 12529 12530 12531 12532 12533 12534 12535 12536 12537 12538 12539 12540 12541 12542 12543 12544 12545 12546 12547 12548 12549 12550 12551 12552 12553 12554 12555 12556 12557 12558 12559 12560 12561 12562 12563 12564 12565 12566 12567 12568 12569 12570 12571 12572 12573 12574 12575 12576 12577 12578 12579 12580 12581 12582 12583 12584 12585 12586 12587 12588 12589 12590 12591 12592 12593 12594 12595 12596 12597 12598 12599 12600 12601 12602 12603 12604 12605 12606 12607 12608 12609 12610 12611 12612 12613 12614 12615 12616 12617 12618 12619 12620 12621 12622 12623 12624 12625 12626 12627 12628 12629 12630 12631 12632 12633 12634 12635 12636 12637 12638 12639 12640 12641 12642 12643 12644 12645 12646 12647 12648 12649 12650 12651 12652 12653 12654 12655 12656 12657 12658 12659 12660 12661 12662 12663 12664 12665 12666 12667 12668 12669 12670 12671 12672 12673 12674 12675 12676 12677 12678 12679 12680 12681 12682 12683 12684 12685 12686 12687 12688 12689 12690 12691 12692 12693 12694 12695 12696 12697 12698 12699 12700 12701 12702 12703 12704 12705 12706 12707 12708 12709 12710 12711 12712 12713 12714 12715 12716 12717 12718 12719 12720 12721 12722 12723 12724 12725 12726 12727 12728 12729 12730 12731 12732 12733 12734 12735 12736 12737 12738 12739 12740 12741 12742 12743 12744 12745 12746 12747 12748 12749 12750 12751 12752 12753 12754 12755 12756 12757 12758 12759 12760 12761 12762 12763 12764 12765 12766 12767 12768 12769 12770 12771 12772 12773 12774 12775 12776 12777 12778 12779 12780 12781 12782 12783 12784 12785 12786 12787 12788 12789 12790 12791 12792 12793 12794 12795 12796 12797 12798 12799 12800 12801 12802 12803 12804 12805 12806 12807 12808 12809 12810 12811 12812 12813 12814 12815 12816 12817 12818 12819 12820 12821 12822 12823 12824 12825 12826 12827 12828 12829 12830 12831 12832 12833 12834 12835 12836 12837 12838 12839 12840 12841 12842 12843 12844 12845 12846 12847 12848 12849 12850 12851 12852 12853 12854 12855 12856 12857 12858 12859 12860 12861 12862 12863 12864 12865 12866 12867 12868 12869 12870 12871 12872 12873 12874 12875 12876 12877 12878 12879 12880 12881 12882 12883 12884 12885 12886 12887 12888 12889 12890 12891 12892 12893 12894 12895 12896 12897 12898 12899 12900 12901 12902 12903 12904 12905 12906 12907 12908 12909 12910 12911 12912 12913 12914 12915 12916 12917 12918 12919 12920 12921 12922 12923 12924 12925 12926 12927 12928 12929 12930 12931 12932 12933 12934 12935 12936 12937 12938 12939 12940 12941 12942 12943 12944 12945 12946 12947 12948 12949 12950 12951 12952 12953 12954 12955 12956 12957 12958 12959 12960 12961 12962 12963 12964 12965 12966 12967 12968 12969 12970 12971 12972 12973 12974 12975 12976 12977 12978 12979 12980 12981 12982 12983 12984 12985 12986 12987 12988 12989 12990 12991 12992 12993 12994 12995 12996 12997 12998 12999 13000 13001 13002 13003 13004 13005 13006 13007 13008 13009 13010 13011 13012 13013 13014 13015 13016 13017 13018 13019 13020 13021 13022 13023 13024 13025 13026 13027 13028 13029 13030 13031 13032 13033 13034 13035 13036 13037 13038 13039 13040 13041 13042 13043 13044 13045 13046 13047 13048 13049 13050 13051 13052 13053 13054 13055 13056 13057 13058 13059 13060 13061 13062 13063 13064 13065 13066 13067 13068 13069 13070 13071 13072 13073 13074 13075 13076 13077 13078 13079 13080 13081 13082 13083 13084 13085 13086 13087 13088 13089 13090 13091 13092 13093 13094 13095 13096 13097 13098 13099 13100 13101 13102 13103 13104 13105 13106 13107 13108 13109 13110 13111 13112 13113 13114 13115 13116 13117 13118 13119 13120 13121 13122 13123 13124 13125 13126 13127 13128 13129 13130 13131 13132 13133 13134 13135 13136 13137 13138 13139 13140 13141 13142 13143 13144 13145 13146 13147 13148 13149 13150 13151 13152 13153 13154 13155 13156 13157 13158 13159 13160 13161 13162 13163 13164 13165 13166 13167 13168 13169 13170 13171 13172 13173 13174 13175 13176 13177 13178 13179 13180 13181 13182 13183 13184 13185 13186 13187 13188 13189 13190 13191 13192 13193 13194 13195 13196 13197 13198 13199 13200 13201 13202 13203 13204 13205 13206 13207 13208 13209 13210 13211 13212 13213 13214 13215 13216 13217 13218 13219 13220 13221 13222 13223 13224 13225 13226 13227 13228 13229 13230 13231 13232 13233 13234 13235 13236 13237 13238 13239 13240 13241 13242 13243 13244 13245 13246 13247 13248 13249 13250 13251 13252 13253 13254 13255 13256 13257 13258 13259 13260 13261 13262 13263 13264 13265 13266 13267 13268 13269 13270 13271 13272 13273 13274 13275 13276 13277 13278 13279 13280 13281 13282 13283 13284 13285 13286 13287 13288 13289 13290 13291 13292 13293 13294 13295 13296 13297 13298 13299 13300 13301 13302 13303 13304 13305 13306 13307 13308 13309 13310 13311 13312 13313 13314 13315 13316 13317 13318 13319 13320 13321 13322 13323 13324 13325 13326 13327 13328 13329 13330 13331 13332 13333 13334 13335 13336 13337 13338 13339 13340 13341 13342 13343 13344 13345 13346 13347 13348 13349 13350 13351 13352 13353 13354 13355 13356 13357 13358 13359 13360 13361 13362 13363 13364 13365 13366 13367 13368 13369 13370 13371 13372 13373 13374 13375 13376 13377 13378 13379 13380 13381 13382 13383 13384 13385 13386 13387 13388 13389 13390 13391 13392 13393 13394 13395 13396 13397 13398 13399 13400 13401 13402 13403 13404 13405 13406 13407 13408 13409 13410 13411 13412 13413 13414 13415 13416 13417 13418 13419 13420 13421 13422 13423 13424 13425 13426 13427 13428 13429 13430 13431 13432 13433 13434 13435 13436 13437 13438 13439 13440 13441 13442 13443 13444 13445 13446 13447 13448 13449 13450 13451 13452 13453 13454 13455 13456 13457 13458 13459 13460 13461 13462 13463 13464 13465 13466 13467 13468 13469 13470 13471 13472 13473 13474 13475 13476 13477 13478 13479 13480 13481 13482 13483 13484 13485 13486 13487 13488 13489 13490 13491 13492 13493 13494 13495 13496 13497 13498 13499 13500 13501 13502 13503 13504 13505 13506 13507 13508 13509 13510 13511 13512 13513 13514 13515 13516 13517 13518 13519 13520 13521 13522 13523 13524 13525 13526 13527 13528 13529 13530 13531 13532 13533 13534 13535 13536 13537 13538 13539 13540 13541 13542 13543 13544 13545 13546 13547 13548 13549 13550 13551 13552 13553 13554 13555 13556 13557 13558 13559 13560 13561 13562 13563 13564 13565 13566 13567 13568 13569 13570 13571 13572 13573 13574 13575 13576 13577 13578 13579 13580 13581 13582 13583 13584 13585 13586 13587 13588 13589 13590 13591 13592 13593 13594 13595 13596 13597 13598 13599 13600 13601 13602 13603 13604 13605 13606 13607 13608 13609 13610 13611 13612 13613 13614 13615 13616 13617 13618 13619 13620 13621 13622 13623 13624 13625 13626 13627 13628 13629 13630 13631 13632 13633 13634 13635 13636 13637 13638 13639 13640 13641 13642 13643 13644 13645 13646 13647 13648 13649 13650 13651 13652 13653 13654 13655 13656 13657 13658 13659 13660 13661 13662 13663 13664 13665 13666 13667 13668 13669 13670 13671 13672 13673 13674 13675 13676 13677 13678 13679 13680 13681 13682 13683 13684 13685 13686 13687 13688 13689 13690 13691 13692 13693 13694 13695 13696 13697 13698 13699 13700 13701 13702 13703 13704 13705 13706 13707 13708 13709 13710 13711 13712 13713 13714 13715 13716 13717 13718 13719 13720 13721 13722 13723 13724 13725 13726 13727 13728 13729 13730 13731 13732 13733 13734 13735 13736 13737 13738 13739 13740 13741 13742 13743 13744 13745 13746 13747 13748 13749 13750 13751 13752 13753 13754 13755 13756 13757 13758 13759 13760 13761 13762 13763 13764 13765 13766 13767 13768 13769 13770 13771 13772 13773 13774 13775 13776 13777 13778 13779 13780 13781 13782 13783 13784 13785 13786 13787 13788 13789 13790 13791 13792 13793 13794 13795 13796 13797 13798 13799 13800 13801 13802 13803 13804 13805 13806 13807 13808 13809 13810 13811 13812 13813 13814 13815 13816 13817 13818 13819 13820 13821 13822 13823 13824 13825 13826 13827 13828 13829 13830 13831 13832 13833 13834 13835 13836 13837 13838 13839 13840 13841 13842 13843 13844 13845 13846 13847 13848 13849 13850 13851 13852 13853 13854 13855 13856 13857 13858 13859 13860 13861 13862 13863 13864 13865 13866 13867 13868 13869 13870 13871 13872 13873 13874 13875 13876 13877 13878 13879 13880 13881 13882 13883 13884 13885 13886 13887 13888 13889 13890 13891 13892 13893 13894 13895 13896 13897 13898 13899 13900 13901 13902 13903 13904 13905 13906 13907 13908 13909 13910 13911 13912 13913 13914 13915 13916 13917 13918 13919 13920 13921 13922 13923 13924 13925 13926 13927 13928 13929 13930 13931 13932 13933 13934 13935 13936 13937 13938 13939 13940 13941 13942 13943 13944 13945 13946 13947 13948 13949 13950 13951 13952 13953 13954 13955 13956 13957 13958 13959 13960 13961 13962 13963 13964 13965 13966 13967 13968 13969 13970 13971 13972 13973 13974 13975 13976 13977 13978 13979 13980 13981 13982 13983 13984 13985 13986 13987 13988 13989 13990 13991 13992 13993 13994 13995 13996 13997 13998 13999 14000 14001 14002 14003 14004 14005 14006 14007 14008 14009 14010 14011 14012 14013 14014 14015 14016 14017 14018 14019 14020 14021 14022 14023 14024 14025 14026 14027 14028 14029 14030 14031 14032 14033 14034 14035 14036 14037 14038 14039 14040 14041 14042 14043 14044 14045 14046 14047 14048 14049 14050 14051 14052 14053 14054 14055 14056 14057 14058 14059 14060 14061 14062 14063 14064 14065 14066 14067 14068 14069 14070 14071 14072 14073 14074 14075 14076 14077 14078 14079 14080 14081 14082 14083 14084 14085 14086 14087 14088 14089 14090 14091 14092 14093 14094 14095 14096 14097 14098 14099 14100 14101 14102 14103 14104 14105 14106 14107 14108 14109 14110 14111 14112 14113 14114 14115 14116 14117 14118 14119 14120 14121 14122 14123 14124 14125 14126 14127 14128 14129 14130 14131 14132 14133 14134 14135 14136 14137 14138 14139 14140 14141 14142 14143 14144 14145 14146 14147 14148 14149 14150 14151 14152 14153 14154 14155 14156 14157 14158 14159 14160 14161 14162 14163 14164 14165 14166 14167 14168 14169 14170 14171 14172 14173 14174 14175 14176 14177 14178 14179 14180 14181 14182 14183 14184 14185 14186 14187 14188 14189 14190 14191 14192 14193 14194 14195 14196 14197 14198 14199 14200 14201 14202 14203 14204 14205 14206 14207 14208 14209 14210 14211 14212 14213 14214 14215 14216 14217 14218 14219 14220 14221 14222 14223 14224 14225 14226 14227 14228 14229 14230 14231 14232 14233 14234 14235 14236 14237 14238 14239 14240 14241 14242 14243 14244 14245 14246 14247 14248 14249 14250 14251 14252 14253 14254 14255 14256 14257 14258 14259 14260 14261 14262 14263 14264 14265 14266 14267 14268 14269 14270 14271 14272 14273 14274 14275 14276 14277 14278 14279 14280 14281 14282 14283 14284 14285 14286 14287 14288 14289 14290 14291 14292 14293 14294 14295 14296 14297 14298 14299 14300 14301 14302 14303 14304 14305 14306 14307 14308 14309 14310 14311 14312 14313 14314 14315 14316 14317 14318 14319 14320 14321 14322 14323 14324 14325 14326 14327 14328 14329 14330 14331 14332 14333 14334 14335 14336 14337 14338 14339 14340 14341 14342 14343 14344 14345 14346 14347 14348 14349 14350 14351 14352 14353 14354 14355 14356 14357 14358 14359 14360 14361 14362 14363 14364 14365 14366 14367 14368 14369 14370 14371 14372 14373 14374 14375 14376 14377 14378 14379 14380 14381 14382 14383 14384 14385 14386 14387 14388 14389 14390 14391 14392 14393 14394 14395 14396 14397 14398 14399 14400 14401 14402 14403 14404 14405 14406 14407 14408 14409 14410 14411 14412 14413 14414 14415 14416 14417 14418 14419 14420 14421 14422 14423 14424 14425 14426 14427 14428 14429 14430 14431 14432 14433 14434 14435 14436 14437 14438 14439 14440 14441 14442 14443 14444 14445 14446 14447 14448 14449 14450 14451 14452 14453 14454 14455 14456 14457 14458 14459 14460 14461 14462 14463 14464 14465 14466 14467 14468 14469 14470 14471 14472 14473 14474 14475 14476 14477 14478 14479 14480 14481 14482 14483 14484 14485 14486 14487 14488 14489 14490 14491 14492 14493 14494 14495 14496 14497 14498 14499 14500 14501 14502 14503 14504 14505 14506 14507 14508 14509 14510 14511 14512 14513 14514 14515 14516 14517 14518 14519 14520 14521 14522 14523 14524 14525 14526 14527 14528 14529 14530 14531 14532 14533 14534 14535 14536 14537 14538 14539 14540 14541 14542 14543 14544 14545 14546 14547 14548 14549 14550 14551 14552 14553 14554 14555 14556 14557 14558 14559 14560 14561 14562 14563 14564 14565 14566 14567 14568 14569 14570 14571 14572 14573 14574 14575 14576 14577 14578 14579 14580 14581 14582 14583 14584 14585 14586 14587 14588 14589 14590 14591 14592 14593 14594 14595 14596 14597 14598 14599 14600 14601 14602 14603 14604 14605 14606 14607 14608 14609 14610 14611 14612 14613 14614 14615 14616 14617 14618 14619 14620 14621 14622 14623 14624 14625 14626 14627 14628 14629 14630 14631 14632 14633 14634 14635 14636 14637 14638 14639 14640 14641 14642 14643 14644 14645 14646 14647 14648 14649 14650 14651 14652 14653 14654 14655 14656 14657 14658 14659 14660 14661 14662 14663 14664 14665 14666 14667 14668 14669 14670 14671 14672 14673 14674 14675 14676 14677 14678 14679 14680 14681 14682 14683 14684 14685 14686 14687 14688 14689 14690 14691 14692 14693 14694 14695 14696 14697 14698 14699 14700 14701 14702 14703 14704 14705 14706 14707 14708 14709 14710 14711 14712 14713 14714 14715 14716 14717 14718 14719 14720 14721 14722 14723 14724 14725 14726 14727 14728 14729 14730 14731 14732 14733 14734 14735 14736 14737 14738 14739 14740 14741 14742 14743 14744 14745 14746 14747 14748 14749 14750 14751 14752 14753 14754 14755 14756 14757 14758 14759 14760 14761 14762 14763 14764 14765 14766 14767 14768 14769 14770 14771 14772 14773 14774 14775 14776 14777 14778 14779 14780 14781 14782 14783 14784 14785 14786 14787 14788 14789 14790 14791 14792 14793 14794 14795 14796 14797 14798 14799 14800 14801 14802 14803 14804 14805 14806 14807 14808 14809 14810 14811 14812 14813 14814 14815 14816 14817 14818 14819 14820 14821 14822 14823 14824 14825 14826 14827 14828 14829 14830 14831 14832 14833 14834 14835 14836 14837 14838 14839 14840 14841 14842 14843 14844 14845 14846 14847 14848 14849 14850 14851 14852 14853 14854 14855 14856 14857 14858 14859 14860 14861 14862 14863 14864 14865 14866 14867 14868 14869 14870 14871 14872 14873 14874 14875 14876 14877 14878 14879 14880 14881 14882 14883 14884 14885 14886 14887 14888 14889 14890 14891 14892 14893 14894 14895 14896 14897 14898 14899 14900 14901 14902 14903 14904 14905 14906 14907 14908 14909 14910 14911 14912 14913 14914 14915 14916 14917 14918 14919 14920 14921 14922 14923 14924 14925 14926 14927 14928 14929 14930 14931 14932 14933 14934 14935 14936 14937 14938 14939 14940 14941 14942 14943 14944 14945 14946 14947 14948 14949 14950 14951 14952 14953 14954 14955 14956 14957 14958 14959 14960 14961 14962 14963 14964 14965 14966 14967 14968 14969 14970 14971 14972 14973 14974 14975 14976 14977 14978 14979 14980 14981 14982 14983 14984 14985 14986 14987 14988 14989 14990 14991 14992 14993 14994 14995 14996 14997 14998 14999 15000 15001 15002 15003 15004 15005 15006 15007 15008 15009 15010 15011 15012 15013 15014 15015 15016 15017 15018 15019 15020 15021 15022 15023 15024 15025 15026 15027 15028 15029 15030 15031 15032 15033 15034 15035 15036 15037 15038 15039 15040 15041 15042 15043 15044 15045 15046 15047 15048 15049 15050 15051 15052 15053 15054 15055 15056 15057 15058 15059 15060 15061 15062 15063 15064 15065 15066 15067 15068 15069 15070 15071 15072 15073 15074 15075 15076 15077 15078 15079 15080 15081 15082 15083 15084 15085 15086 15087 15088 15089 15090 15091 15092 15093 15094 15095 15096 15097 15098 15099 15100 15101 15102 15103 15104 15105 15106 15107 15108 15109 15110 15111 15112 15113 15114 15115 15116 15117 15118 15119 15120 15121 15122 15123 15124 15125 15126 15127 15128 15129 15130 15131 15132 15133 15134 15135 15136 15137 15138 15139 15140 15141 15142 15143 15144 15145 15146 15147 15148 15149 15150 15151 15152 15153 15154 15155 15156 15157 15158 15159 15160 15161 15162 15163 15164 15165 15166 15167 15168 15169 15170 15171 15172 15173 15174 15175 15176 15177 15178 15179 15180 15181 15182 15183 15184 15185 15186 15187 15188 15189 15190 15191 15192 15193 15194 15195 15196 15197 15198 15199 15200 15201 15202 15203 15204 15205 15206 15207 15208 15209 15210 15211 15212 15213 15214 15215 15216 15217 15218 15219 15220 15221 15222 15223 15224 15225 15226 15227 15228 15229 15230 15231 15232 15233 15234 15235 15236 15237 15238 15239 15240 15241 15242 15243 15244 15245 15246 15247 15248 15249 15250 15251 15252 15253 15254 15255 15256 15257 15258 15259 15260 15261 15262 15263 15264 15265 15266 15267 15268 15269 15270 15271 15272 15273 15274 15275 15276 15277 15278 15279 15280 15281 15282 15283 15284 15285 15286 15287 15288 15289 15290 15291 15292 15293 15294 15295 15296 15297 15298 15299 15300 15301 15302 15303 15304 15305 15306 15307 15308 15309 15310 15311 15312 15313 15314 15315 15316 15317 15318 15319 15320 15321 15322 15323 15324 15325 15326 15327 15328 15329 15330 15331 15332 15333 15334 15335 15336 15337 15338 15339 15340 15341 15342 15343 15344 15345 15346 15347 15348 15349 15350 15351 15352 15353 15354 15355 15356 15357 15358 15359 15360 15361 15362 15363 15364 15365 15366 15367 15368 15369 15370 15371 15372 15373 15374 15375 15376 15377 15378 15379 15380 15381 15382 15383 15384 15385 15386 15387 15388 15389 15390 15391 15392 15393 15394 15395 15396 15397 15398 15399 15400 15401 15402 15403 15404 15405 15406 15407 15408 15409 15410 15411 15412 15413 15414 15415 15416 15417 15418 15419 15420 15421 15422 15423 15424 15425 15426 15427 15428 15429 15430 15431 15432 15433 15434 15435 15436 15437 15438 15439 15440 15441 15442 15443 15444 15445 15446 15447 15448 15449 15450 15451 15452 15453 15454 15455 15456 15457 15458 15459 15460 15461 15462 15463 15464 15465 15466 15467 15468 15469 15470 15471 15472 15473 15474 15475 15476 15477 15478 15479 15480 15481 15482 15483 15484 15485 15486 15487 15488 15489 15490 15491 15492 15493 15494 15495 15496 15497 15498 15499 15500 15501 15502 15503 15504 15505 15506 15507 15508 15509 15510 15511 15512 15513 15514 15515 15516 15517 15518 15519 15520 15521 15522 15523 15524 15525 15526 15527 15528 15529 15530 15531 15532 15533 15534 15535 15536 15537 15538 15539 15540 15541 15542 15543 15544 15545 15546 15547 15548 15549 15550 15551 15552 15553 15554 15555 15556 15557 15558 15559 15560 15561 15562 15563 15564 15565 15566 15567 15568 15569 15570 15571 15572 15573 15574 15575 15576 15577 15578 15579 15580 15581 15582 15583 15584 15585 15586 15587 15588 15589 15590 15591 15592 15593 15594 15595 15596 15597 15598 15599 15600 15601 15602 15603 15604 15605 15606 15607 15608 15609 15610 15611 15612 15613 15614 15615 15616 15617 15618 15619 15620 15621 15622 15623 15624 15625 15626 15627 15628 15629 15630 15631 15632 15633 15634 15635 15636 15637 15638 15639 15640 15641 15642 15643 15644 15645 15646 15647 15648 15649 15650 15651 15652 15653 15654 15655 15656 15657 15658 15659 15660 15661 15662 15663 15664 15665 15666 15667 15668 15669 15670 15671 15672 15673 15674 15675 15676 15677 15678 15679 15680 15681 15682 15683 15684 15685 15686 15687 15688 15689 15690 15691 15692 15693 15694 15695 15696 15697 15698 15699 15700 15701 15702 15703 15704 15705 15706 15707 15708 15709 15710 15711 15712 15713 15714 15715 15716 15717 15718 15719 15720 15721 15722 15723 15724 15725 15726 15727 15728 15729 15730 15731 15732 15733 15734 15735 15736 15737 15738 15739 15740 15741 15742 15743 15744 15745 15746 15747 15748 15749 15750 15751 15752 15753 15754 15755 15756 15757 15758 15759 15760 15761 15762 15763 15764 15765 15766 15767 15768 15769 15770 15771 15772 15773 15774 15775 15776 15777 15778 15779 15780 15781 15782 15783 15784 15785 15786 15787 15788 15789 15790 15791 15792 15793 15794 15795 15796 15797 15798 15799 15800 15801 15802 15803 15804 15805 15806 15807 15808 15809 15810 15811 15812 15813 15814 15815 15816 15817 15818 15819 15820 15821 15822 15823 15824 15825 15826 15827 15828 15829 15830 15831 15832 15833 15834 15835 15836 15837 15838 15839 15840 15841 15842 15843 15844 15845 15846 15847 15848 15849 15850 15851 15852 15853 15854 15855 15856 15857 15858 15859 15860 15861 15862 15863 15864 15865 15866 15867 15868 15869 15870 15871 15872 15873 15874 15875 15876 15877 15878 15879 15880 15881 15882 15883 15884 15885 15886 15887 15888 15889 15890 15891 15892 15893 15894 15895 15896 15897 15898 15899 15900 15901 15902 15903 15904 15905 15906 15907 15908 15909 15910 15911 15912 15913 15914 15915 15916 15917 15918 15919 15920 15921 15922 15923 15924 15925 15926 15927 15928 15929 15930 15931 15932 15933 15934 15935 15936 15937 15938 15939 15940 15941 15942 15943 15944 15945 15946 15947 15948 15949 15950 15951 15952 15953 15954 15955 15956 15957 15958 15959 15960 15961 15962 15963 15964 15965 15966 15967 15968 15969 15970 15971 15972 15973 15974 15975 15976 15977 15978 15979 15980 15981 15982 15983 15984 15985 15986 15987 15988 15989 15990 15991 15992 15993 15994 15995 15996 15997 15998 15999 16000 16001 16002 16003 16004 16005 16006 16007 16008 16009 16010 16011 16012 16013 16014 16015 16016 16017 16018 16019 16020 16021 16022 16023 16024 16025 16026 16027 16028 16029 16030 16031 16032 16033 16034 16035 16036 16037 16038 16039 16040 16041 16042 16043 16044 16045 16046 16047 16048 16049 16050 16051 16052 16053 16054 16055 16056 16057 16058 16059 16060 16061 16062 16063 16064 16065 16066 16067 16068 16069 16070 16071 16072 16073 16074 16075 16076 16077 16078 16079 16080 16081 16082 16083 16084 16085 16086 16087 16088 16089 16090 16091 16092 16093 16094 16095 16096 16097 16098 16099 16100 16101 16102 16103 16104 16105 16106 16107 16108 16109 16110 16111 16112 16113 16114 16115 16116 16117 16118 16119 16120 16121 16122 16123 16124 16125 16126 16127 16128 16129 16130 16131 16132 16133 16134 16135 16136 16137 16138 16139 16140 16141 16142 16143 16144 16145 16146 16147 16148 16149 16150 16151 16152 16153 16154 16155 16156 16157 16158 16159 16160 16161 16162 16163 16164 16165 16166 16167 16168 16169 16170 16171 16172 16173 16174 16175 16176 16177 16178 16179 16180 16181 16182 16183 16184 16185 16186 16187 16188 16189 16190 16191 16192 16193 16194 16195 16196 16197 16198 16199 16200 16201 16202 16203 16204 16205 16206 16207 16208 16209 16210 16211 16212 16213 16214 16215 16216 16217 16218 16219 16220 16221 16222 16223 16224 16225 16226 16227 16228 16229 16230 16231 16232 16233 16234 16235 16236 16237 16238 16239 16240 16241 16242 16243 16244 16245 16246 16247 16248 16249 16250 16251 16252 16253 16254 16255 16256 16257 16258 16259 16260 16261 16262 16263 16264 16265 16266 16267 16268 16269 16270 16271 16272 16273 16274 16275 16276 16277 16278 16279 16280 16281 16282 16283 16284 16285 16286 16287 16288 16289 16290 16291 16292 16293 16294 16295 16296 16297 16298 16299 16300 16301 16302 16303 16304 16305 16306 16307 16308 16309 16310 16311 16312 16313 16314 16315 16316 16317 16318 16319 16320 16321 16322 16323 16324 16325 16326 16327 16328 16329 16330 16331 16332 16333 16334 16335 16336 16337 16338 16339 16340 16341 16342 16343 16344 16345 16346 16347 16348 16349 16350 16351 16352 16353 16354 16355 16356 16357 16358 16359 16360 16361 16362 16363 16364 16365 16366 16367 16368 16369 16370 16371 16372 16373 16374 16375 16376 16377 16378 16379 16380 16381 16382 16383 16384 16385 16386 16387 16388 16389 16390 16391 16392 16393 16394 16395 16396 16397 16398 16399 16400 16401 16402 16403 16404 16405 16406 16407 16408 16409 16410 16411 16412 16413 16414 16415 16416 16417 16418 16419 16420 16421 16422 16423 16424 16425 16426 16427 16428 16429 16430 16431 16432 16433 16434 16435 16436 16437 16438 16439 16440 16441 16442 16443 16444 16445 16446 16447 16448 16449 16450 16451 16452 16453 16454 16455 16456 16457 16458 16459 16460 16461 16462 16463 16464 16465 16466 16467 16468 16469 16470 16471 16472 16473 16474 16475 16476 16477 16478 16479 16480 16481 16482 16483 16484 16485 16486 16487 16488 16489 16490 16491 16492 16493 16494 16495 16496 16497 16498 16499 16500 16501 16502 16503 16504 16505 16506 16507 16508 16509 16510 16511 16512 16513 16514 16515 16516 16517 16518 16519 16520 16521 16522 16523 16524 16525 16526 16527 16528 16529 16530 16531 16532 16533 16534 16535 16536 16537 16538 16539 16540 16541 16542 16543 16544 16545 16546 16547 16548 16549 16550 16551 16552 16553 16554 16555 16556 16557 16558 16559 16560 16561 16562 16563 16564 16565 16566 16567 16568 16569 16570 16571 16572 16573 16574 16575 16576 16577 16578 16579 16580 16581 16582 16583 16584 16585 16586 16587 16588 16589 16590 16591 16592 16593 16594 16595 16596 16597 16598 16599 16600 16601 16602 16603 16604 16605 16606 16607 16608 16609 16610 16611 16612 16613 16614 16615 16616 16617 16618 16619 16620 16621 16622 16623 16624 16625 16626 16627 16628 16629 16630 16631 16632 16633 16634 16635 16636 16637 16638 16639 16640 16641 16642 16643 16644 16645 16646 16647 16648 16649 16650 16651 16652 16653 16654 16655 16656 16657 16658 16659 16660 16661 16662 16663 16664 16665 16666 16667 16668 16669 16670 16671 16672 16673 16674 16675 16676 16677 16678 16679 16680 16681 16682 16683 16684 16685 16686 16687 16688 16689 16690 16691 16692 16693 16694 16695 16696 16697 16698 16699 16700 16701 16702 16703 16704 16705 16706 16707 16708 16709 16710 16711 16712 16713 16714 16715 16716 16717 16718 16719 16720 16721 16722 16723 16724 16725 16726 16727 16728 16729 16730 16731 16732 16733 16734 16735 16736 16737 16738 16739 16740 16741 16742 16743 16744 16745 16746 16747 16748 16749 16750 16751 16752 16753 16754 16755 16756 16757 16758 16759 16760 16761 16762 16763 16764 16765 16766 16767 16768 16769 16770 16771 16772 16773 16774 16775 16776 16777 16778 16779 16780 16781 16782 16783 16784 16785 16786 16787 16788 16789 16790 16791 16792 16793 16794 16795 16796 16797 16798 16799 16800 16801 16802 16803 16804 16805 16806 16807 16808 16809 16810 16811 16812 16813 16814 16815 16816 16817 16818 16819 16820 16821 16822 16823 16824 16825 16826 16827 16828 16829 16830 16831 16832 16833 16834 16835 16836 16837 16838 16839 16840 16841 16842 16843 16844 16845 16846 16847 16848 16849 16850 16851 16852 16853 16854 16855 16856 16857 16858 16859 16860 16861 16862 16863 16864 16865 16866 16867 16868 16869 16870 16871 16872 16873 16874 16875 16876 16877 16878 16879 16880 16881 16882 16883 16884 16885 16886 16887 16888 16889 16890 16891 16892 16893 16894 16895 16896 16897 16898 16899 16900 16901 16902 16903 16904 16905 16906 16907 16908 16909 16910 16911 16912 16913 16914 16915 16916 16917 16918 16919 16920 16921 16922 16923 16924 16925 16926 16927 16928 16929 16930 16931 16932 16933 16934 16935 16936 16937 16938 16939 16940 16941 16942 16943 16944 16945 16946 16947 16948 16949 16950 16951 16952 16953 16954 16955 16956 16957 16958 16959 16960 16961 16962 16963 16964 16965 16966 16967 16968 16969 16970 16971 16972 16973 16974 16975 16976 16977 16978 16979 16980 16981 16982 16983 16984 16985 16986 16987 16988 16989 16990 16991 16992 16993 16994 16995 16996 16997 16998 16999 17000 17001 17002 17003 17004 17005 17006 17007 17008 17009 17010 17011 17012 17013 17014 17015 17016 17017 17018 17019 17020 17021 17022 17023 17024 17025 17026 17027 17028 17029 17030 17031 17032 17033 17034 17035 17036 17037 17038 17039 17040 17041 17042 17043 17044 17045 17046 17047 17048 17049 17050 17051 17052 17053 17054 17055 17056 17057 17058 17059 17060 17061 17062 17063 17064 17065 17066 17067 17068 17069 17070 17071 17072 17073 17074 17075 17076 17077 17078 17079 17080 17081 17082 17083 17084 17085 17086 17087 17088 17089 17090 17091 17092 17093 17094 17095 17096 17097 17098 17099 17100 17101 17102 17103 17104 17105 17106 17107 17108 17109 17110 17111 17112 17113 17114 17115 17116 17117 17118 17119 17120 17121 17122 17123 17124 17125 17126 17127 17128 17129 17130 17131 17132 17133 17134 17135 17136 17137 17138 17139 17140 17141 17142 17143 17144 17145 17146 17147 17148 17149 17150 17151 17152 17153 17154 17155 17156 17157 17158 17159 17160 17161 17162 17163 17164 17165 17166 17167 17168 17169 17170 17171 17172 17173 17174 17175 17176 17177 17178 17179 17180 17181 17182 17183 17184 17185 17186 17187 17188 17189 17190 17191 17192 17193 17194 17195 17196 17197 17198 17199 17200 17201 17202 17203 17204 17205 17206 17207 17208 17209 17210 17211 17212 17213 17214 17215 17216 17217 17218 17219 17220 17221 17222 17223 17224 17225 17226 17227 17228 17229 17230 17231 17232 17233 17234 17235 17236 17237 17238 17239 17240 17241 17242 17243 17244 17245 17246 17247 17248 17249 17250 17251 17252 17253 17254 17255 17256 17257 17258 17259 17260 17261 17262 17263 17264 17265 17266 17267 17268 17269 17270 17271 17272 17273 17274 17275 17276 17277 17278 17279 17280 17281 17282 17283 17284 17285 17286 17287 17288 17289 17290 17291 17292 17293 17294 17295 17296 17297 17298 17299 17300 17301 17302 17303 17304 17305 17306 17307 17308 17309 17310 17311 17312 17313 17314 17315 17316 17317 17318 17319 17320 17321 17322 17323 17324 17325 17326 17327 17328 17329 17330 17331 17332 17333 17334 17335 17336 17337 17338 17339 17340 17341 17342 17343 17344 17345 17346 17347 17348 17349 17350 17351 17352 17353 17354 17355 17356 17357 17358 17359 17360 17361 17362 17363 17364 17365 17366 17367 17368 17369 17370 17371 17372 17373 17374 17375 17376 17377 17378 17379 17380 17381 17382 17383 17384 17385 17386 17387 17388 17389 17390 17391 17392 17393 17394 17395 17396 17397 17398 17399 17400 17401 17402 17403 17404 17405 17406 17407 17408 17409 17410 17411 17412 17413 17414 17415 17416 17417 17418 17419 17420 17421 17422 17423 17424 17425 17426 17427 17428 17429 17430 17431 17432 17433 17434 17435 17436 17437 17438 17439 17440 17441 17442 17443 17444 17445 17446 17447 17448 17449 17450 17451 17452 17453 17454 17455 17456 17457 17458 17459 17460 17461 17462 17463 17464 17465 17466 17467 17468 17469 17470 17471 17472 17473 17474 17475 17476 17477 17478 17479 17480 17481 17482 17483 17484 17485 17486 17487 17488 17489 17490 17491 17492 17493 17494 17495 17496 17497 17498 17499 17500 17501 17502 17503 17504 17505 17506 17507 17508 17509 17510 17511 17512 17513 17514 17515 17516 17517 17518 17519 17520 17521 17522 17523 17524 17525 17526 17527 17528 17529 17530 17531 17532 17533 17534 17535 17536 17537 17538 17539 17540 17541 17542 17543 17544 17545 17546 17547 17548 17549 17550 17551 17552 17553 17554 17555 17556 17557 17558 17559 17560 17561 17562 17563 17564 17565 17566 17567 17568 17569 17570 17571 17572 17573 17574 17575 17576 17577 17578 17579 17580 17581 17582 17583 17584 17585 17586 17587 17588 17589 17590 17591 17592 17593 17594 17595 17596 17597 17598 17599 17600 17601 17602 17603 17604 17605 17606 17607 17608 17609 17610 17611 17612 17613 17614 17615 17616 17617 17618 17619 17620 17621 17622 17623 17624 17625 17626 17627 17628 17629 17630 17631 17632 17633 17634 17635 17636 17637 17638 17639 17640 17641 17642 17643 17644 17645 17646 17647 17648 17649 17650 17651 17652 17653 17654 17655 17656 17657 17658 17659 17660 17661 17662 17663 17664 17665 17666 17667 17668 17669 17670 17671 17672 17673 17674 17675 17676 17677 17678 17679 17680 17681 17682 17683 17684 17685 17686 17687 17688 17689 17690 17691 17692 17693 17694 17695 17696 17697 17698 17699 17700 17701 17702 17703 17704 17705 17706 17707 17708 17709 17710 17711 17712 17713 17714 17715 17716 17717 17718 17719 17720 17721 17722 17723 17724 17725 17726 17727 17728 17729 17730 17731 17732 17733 17734 17735 17736 17737 17738 17739 17740 17741 17742 17743 17744 17745 17746 17747 17748 17749 17750 17751 17752 17753 17754 17755 17756 17757 17758 17759 17760 17761 17762 17763 17764 17765 17766 17767 17768 17769 17770 17771 17772 17773 17774 17775 17776 17777 17778 17779 17780 17781 17782 17783 17784 17785 17786 17787 17788 17789 17790 17791 17792 17793 17794 17795 17796 17797 17798 17799 17800 17801 17802 17803 17804 17805 17806 17807 17808 17809 17810 17811 17812 17813 17814 17815 17816 17817 17818 17819 17820 17821 17822 17823 17824 17825 17826 17827 17828 17829 17830 17831 17832 17833 17834 17835 17836 17837 17838 17839 17840 17841 17842 17843 17844 17845 17846 17847 17848 17849 17850 17851 17852 17853 17854 17855 17856 17857 17858 17859 17860 17861 17862 17863 17864 17865 17866 17867 17868 17869 17870 17871 17872 17873 17874 17875 17876 17877 17878 17879 17880 17881 17882 17883 17884 17885 17886 17887 17888 17889 17890 17891 17892 17893 17894 17895 17896 17897 17898 17899 17900 17901 17902 17903 17904 17905 17906 17907 17908 17909 17910 17911 17912 17913 17914 17915 17916 17917 17918 17919 17920 17921 17922 17923 17924 17925 17926 17927 17928 17929 17930 17931 17932 17933 17934 17935 17936 17937 17938 17939 17940 17941 17942 17943 17944 17945 17946 17947 17948 17949 17950 17951 17952 17953 17954 17955 17956 17957 17958 17959 17960 17961 17962 17963 17964 17965 17966 17967 17968 17969 17970 17971 17972 17973 17974 17975 17976 17977 17978 17979 17980 17981 17982 17983 17984 17985 17986 17987 17988 17989 17990 17991 17992 17993 17994 17995 17996 17997 17998 17999 18000 18001 18002 18003 18004 18005 18006 18007 18008 18009 18010 18011 18012 18013 18014 18015 18016 18017 18018 18019 18020 18021 18022 18023 18024 18025 18026 18027 18028 18029 18030 18031 18032 18033 18034 18035 18036 18037 18038 18039 18040 18041 18042 18043 18044 18045 18046 18047 18048 18049 18050 18051 18052 18053 18054 18055 18056 18057 18058 18059 18060 18061 18062 18063 18064 18065 18066 18067 18068 18069 18070 18071 18072 18073 18074 18075 18076 18077 18078 18079 18080 18081 18082 18083 18084 18085 18086 18087 18088 18089 18090 18091 18092 18093 18094 18095 18096 18097 18098 18099 18100 18101 18102 18103 18104 18105 18106 18107 18108 18109 18110 18111 18112 18113 18114 18115 18116 18117 18118 18119 18120 18121 18122 18123 18124 18125 18126 18127 18128 18129 18130 18131 18132 18133 18134 18135 18136 18137 18138 18139 18140 18141 18142 18143 18144 18145 18146 18147 18148 18149 18150 18151 18152 18153 18154 18155 18156 18157 18158 18159 18160 18161 18162 18163 18164 18165 18166 18167 18168 18169 18170 18171 18172 18173 18174 18175 18176 18177 18178 18179 18180 18181 18182 18183 18184 18185 18186 18187 18188 18189 18190 18191 18192 18193 18194 18195 18196 18197 18198 18199 18200 18201 18202 18203 18204 18205 18206 18207 18208 18209 18210 18211 18212 18213 18214 18215 18216 18217 18218 18219 18220 18221 18222 18223 18224 18225 18226 18227 18228 18229 18230 18231 18232 18233 18234 18235 18236 18237 18238 18239 18240 18241 18242 18243 18244 18245 18246 18247 18248 18249 18250 18251 18252 18253 18254 18255 18256 18257 18258 18259 18260 18261 18262 18263 18264 18265 18266 18267 18268 18269 18270 18271 18272 18273 18274 18275 18276 18277 18278 18279 18280 18281 18282 18283 18284 18285 18286 18287 18288 18289 18290 18291 18292 18293 18294 18295 18296 18297 18298 18299 18300 18301 18302 18303 18304 18305 18306 18307 18308 18309 18310 18311 18312 18313 18314 18315 18316 18317 18318 18319 18320 18321 18322 18323 18324 18325 18326 18327 18328 18329 18330 18331 18332 18333 18334 18335 18336 18337 18338 18339 18340 18341 18342 18343 18344 18345 18346 18347 18348 18349 18350 18351 18352 18353 18354 18355 18356 18357 18358 18359 18360 18361 18362 18363 18364 18365 18366 18367 18368 18369 18370 18371 18372 18373 18374 18375 18376 18377 18378 18379 18380 18381 18382 18383 18384 18385 18386 18387 18388 18389 18390 18391 18392 18393 18394 18395 18396 18397 18398 18399 18400 18401 18402 18403 18404 18405 18406 18407 18408 18409 18410 18411 18412 18413 18414 18415 18416 18417 18418 18419 18420 18421 18422 18423 18424 18425 18426 18427 18428 18429 18430 18431 18432 18433 18434 18435 18436 18437 18438 18439 18440 18441 18442 18443 18444 18445 18446 18447 18448 18449 18450 18451 18452 18453 18454 18455 18456 18457 18458 18459 18460 18461 18462 18463 18464 18465 18466 18467 18468 18469 18470 18471 18472 18473 18474 18475 18476 18477 18478 18479 18480 18481 18482 18483 18484 18485 18486 18487 18488 18489 18490 18491 18492 18493 18494 18495 18496 18497 18498 18499 18500 18501 18502 18503 18504 18505 18506 18507 18508 18509 18510 18511 18512 18513 18514 18515 18516 18517 18518 18519 18520 18521 18522 18523 18524 18525 18526 18527 18528 18529 18530 18531 18532 18533 18534 18535 18536 18537 18538 18539 18540 18541 18542 18543 18544 18545 18546 18547 18548 18549 18550 18551 18552 18553 18554 18555 18556 18557 18558 18559 18560 18561 18562 18563 18564 18565 18566 18567 18568 18569 18570 18571 18572 18573 18574 18575 18576 18577 18578 18579 18580 18581 18582 18583 18584 18585 18586 18587 18588 18589 18590 18591 18592 18593 18594 18595 18596 18597 18598 18599 18600 18601 18602 18603 18604 18605 18606 18607 18608 18609 18610 18611 18612 18613 18614 18615 18616 18617 18618 18619 18620 18621 18622 18623 18624 18625 18626 18627 18628 18629 18630 18631 18632 18633 18634 18635 18636 18637 18638 18639 18640 18641 18642 18643 18644 18645 18646 18647 18648 18649 18650 18651 18652 18653 18654 18655 18656 18657 18658 18659 18660 18661 18662 18663 18664 18665 18666 18667 18668 18669 18670 18671 18672 18673 18674 18675 18676 18677 18678 18679 18680 18681 18682 18683 18684 18685 18686 18687 18688 18689 18690 18691 18692 18693 18694 18695 18696 18697 18698 18699 18700 18701 18702 18703 18704 18705 18706 18707 18708 18709 18710 18711 18712 18713 18714 18715 18716 18717 18718 18719 18720 18721 18722 18723 18724 18725 18726 18727 18728 18729 18730 18731 18732 18733 18734 18735 18736 18737 18738 18739 18740 18741 18742 18743 18744 18745 18746 18747 18748 18749 18750 18751 18752 18753 18754 18755 18756 18757 18758 18759 18760 18761 18762 18763 18764 18765 18766 18767 18768 18769 18770 18771 18772 18773 18774 18775 18776 18777 18778 18779 18780 18781 18782 18783 18784 18785 18786 18787 18788 18789 18790 18791 18792 18793 18794 18795 18796 18797 18798 18799 18800 18801 18802 18803 18804 18805 18806 18807 18808 18809 18810 18811 18812 18813 18814 18815 18816 18817 18818 18819 18820 18821 18822 18823 18824 18825 18826 18827 18828 18829 18830 18831 18832 18833 18834 18835 18836 18837 18838 18839 18840 18841 18842 18843 18844 18845 18846 18847 18848 18849 18850 18851 18852 18853 18854 18855 18856 18857 18858 18859 18860 18861 18862 18863 18864 18865 18866 18867 18868 18869 18870 18871 18872 18873 18874 18875 18876 18877 18878 18879 18880 18881 18882 18883 18884 18885 18886 18887 18888 18889 18890 18891 18892 18893 18894 18895 18896 18897 18898 18899 18900 18901 18902 18903 18904 18905 18906 18907 18908 18909 18910 18911 18912 18913 18914 18915 18916 18917 18918 18919 18920 18921 18922 18923 18924 18925 18926 18927 18928 18929 18930 18931 18932 18933 18934 18935 18936 18937 18938 18939 18940 18941 18942 18943 18944 18945 18946 18947 18948 18949 18950 18951 18952 18953 18954 18955 18956 18957 18958 18959 18960 18961 18962 18963 18964 18965 18966 18967 18968 18969 18970 18971 18972 18973 18974 18975 18976 18977 18978 18979 18980 18981 18982 18983 18984 18985 18986 18987 18988 18989 18990 18991 18992 18993 18994 18995 18996 18997 18998 18999 19000 19001 19002 19003 19004 19005 19006 19007 19008 19009 19010 19011 19012 19013 19014 19015 19016 19017 19018 19019 19020 19021 19022 19023 19024 19025 19026 19027 19028 19029 19030 19031 19032 19033 19034 19035 19036 19037 19038 19039 19040 19041 19042 19043 19044 19045 19046 19047 19048 19049 19050 19051 19052 19053 19054 19055 19056 19057 19058 19059 19060 19061 19062 19063 19064 19065 19066 19067 19068 19069 19070 19071 19072 19073 19074 19075 19076 19077 19078 19079 19080 19081 19082 19083 19084 19085 19086 19087 19088 19089 19090 19091 19092 19093 19094 19095 19096 19097 19098 19099 19100 19101 19102 19103 19104 19105 19106 19107 19108 19109 19110 19111 19112 19113 19114 19115 19116 19117 19118 19119 19120 19121 19122 19123 19124 19125 19126 19127 19128 19129 19130 19131 19132 19133 19134 19135 19136 19137 19138 19139 19140 19141 19142 19143 19144 19145 19146 19147 19148 19149 19150 19151 19152 19153 19154 19155 19156 19157 19158 19159 19160 19161 19162 19163 19164 19165 19166 19167 19168 19169 19170 19171 19172 19173 19174 19175 19176 19177 19178 19179 19180 19181 19182 19183 19184 19185 19186 19187 19188 19189 19190 19191 19192 19193 19194 19195 19196 19197 19198 19199 19200 19201 19202 19203 19204 19205 19206 19207 19208 19209 19210 19211 19212 19213 19214 19215 19216 19217 19218 19219 19220 19221 19222 19223 19224 19225 19226 19227 19228 19229 19230 19231 19232 19233 19234 19235 19236 19237 19238 19239 19240 19241 19242 19243 19244 19245 19246 19247 19248 19249 19250 19251 19252 19253 19254 19255 19256 19257 19258 19259 19260 19261 19262 19263 19264 19265 19266 19267 19268 19269 19270 19271 19272 19273 19274 19275 19276 19277 19278 19279 19280 19281 19282 19283 19284 19285 19286 19287 19288 19289 19290 19291 19292 19293 19294 19295 19296 19297 19298 19299 19300 19301 19302 19303 19304 19305 19306 19307 19308 19309 19310 19311 19312 19313 19314 19315 19316 19317 19318 19319 19320 19321 19322 19323 19324 19325 19326 19327 19328 19329 19330 19331 19332 19333 19334 19335 19336 19337 19338 19339 19340 19341 19342 19343 19344 19345 19346 19347 19348 19349 19350 19351 19352 19353 19354 19355 19356 19357 19358 19359 19360 19361 19362 19363 19364 19365 19366 19367 19368 19369 19370 19371 19372 19373 19374 19375 19376 19377 19378 19379 19380 19381 19382 19383 19384 19385 19386 19387 19388 19389 19390 19391 19392 19393 19394 19395 19396 19397 19398 19399 19400 19401 19402 19403 19404 19405 19406 19407 19408 19409 19410 19411 19412 19413 19414 19415 19416 19417 19418 19419 19420 19421 19422 19423 19424 19425 19426 19427 19428 19429 19430 19431 19432 19433 19434 19435 19436 19437 19438 19439 19440 19441 19442 19443 19444 19445 19446 19447 19448 19449 19450 19451 19452 19453 19454 19455 19456 19457 19458 19459 19460 19461 19462 19463 19464 19465 19466 19467 19468 19469 19470 19471 19472 19473 19474 19475 19476 19477 19478 19479 19480 19481 19482 19483 19484 19485 19486 19487 19488 19489 19490 19491 19492 19493 19494 19495 19496 19497 19498 19499 19500 19501 19502 19503 19504 19505 19506 19507 19508 19509 19510 19511 19512 19513 19514 19515 19516 19517 19518 19519 19520 19521 19522 19523 19524 19525 19526 19527 19528 19529 19530 19531 19532 19533 19534 19535 19536 19537 19538 19539 19540 19541 19542 19543 19544 19545 19546 19547 19548 19549 19550 19551 19552 19553 19554 19555 19556 19557 19558 19559 19560 19561 19562 19563 19564 19565 19566 19567 19568 19569 19570 19571 19572 19573 19574 19575 19576 19577 19578 19579 19580 19581 19582 19583 19584 19585 19586 19587 19588 19589 19590 19591 19592 19593 19594 19595 19596 19597 19598 19599 19600 19601 19602 19603 19604 19605 19606 19607 19608 19609 19610 19611 19612 19613 19614 19615 19616 19617 19618 19619 19620 19621 19622 19623 19624 19625 19626 19627 19628 19629 19630 19631 19632 19633 19634 19635 19636 19637 19638 19639 19640 19641 19642 19643 19644 19645 19646 19647 19648 19649 19650 19651 19652 19653 19654 19655 19656 19657 19658 19659 19660 19661 19662 19663 19664 19665 19666 19667 19668 19669 19670 19671 19672 19673 19674 19675 19676 19677 19678 19679 19680 19681 19682 19683 19684 19685 19686 19687 19688 19689 19690 19691 19692 19693 19694 19695 19696 19697 19698 19699 19700 19701 19702 19703 19704 19705 19706 19707 19708 19709 19710 19711 19712 19713 19714 19715 19716 19717 19718 19719 19720 19721 19722 19723 19724 19725 19726 19727 19728 19729 19730 19731 19732 19733 19734 19735 19736 19737 19738 19739 19740 19741 19742 19743 19744 19745 19746 19747 19748 19749 19750 19751 19752 19753 19754 19755 19756 19757 19758 19759 19760 19761 19762 19763 19764 19765 19766 19767 19768 19769 19770 19771 19772 19773 19774 19775 19776 19777 19778 19779 19780 19781 19782 19783 19784 19785 19786 19787 19788 19789 19790 19791 19792 19793 19794 19795 19796 19797 19798 19799 19800 19801 19802 19803 19804 19805 19806 19807 19808 19809 19810 19811 19812 19813 19814 19815 19816 19817 19818 19819 19820 19821 19822 19823 19824 19825 19826 19827 19828 19829 19830 19831 19832 19833 19834 19835 19836 19837 19838 19839 19840 19841 19842 19843 19844 19845 19846 19847 19848 19849 19850 19851 19852 19853 19854 19855 19856 19857 19858 19859 19860 19861 19862 19863 19864 19865 19866 19867 19868 19869 19870 19871 19872 19873 19874 19875 19876 19877 19878 19879 19880 19881 19882 19883 19884 19885 19886 19887 19888 19889 19890 19891 19892 19893 19894 19895 19896 19897 19898 19899 19900 19901 19902 19903 19904 19905 19906 19907 19908 19909 19910 19911 19912 19913 19914 19915 19916 19917 19918 19919 19920 19921 19922 19923 19924 19925 19926 19927 19928 19929 19930 19931 19932 19933 19934 19935 19936 19937 19938 19939 19940 19941 19942 19943 19944 19945 19946 19947 19948 19949 19950 19951 19952 19953 19954 19955 19956 19957 19958 19959 19960 19961 19962 19963 19964 19965 19966 19967 19968 19969 19970 19971 19972 19973 19974 19975 19976 19977 19978 19979 19980 19981 19982 19983 19984 19985 19986 19987 19988 19989 19990 19991 19992 19993 19994 19995 19996 19997 19998 19999 20000 20001 20002 20003 20004 20005 20006 20007 20008 20009 20010 20011 20012 20013 20014 20015 20016 20017 20018 20019 20020 20021 20022 20023 20024 20025 20026 20027 20028 20029 20030 20031 20032 20033 20034 20035 20036 20037 20038 20039 20040 20041 20042 20043 20044 20045 20046 20047 20048 20049 20050 20051 20052 20053 20054 20055 20056 20057 20058 20059 20060 20061 20062 20063 20064 20065 20066 20067 20068 20069 20070 20071 20072 20073 20074 20075 20076 20077 20078 20079 20080 20081 20082 20083 20084 20085 20086 20087 20088 20089 20090 20091 20092 20093 20094 20095 20096 20097 20098 20099 20100 20101 20102 20103 20104 20105 20106 20107 20108 20109 20110 20111 20112 20113 20114 20115 20116 20117 20118 20119 20120 20121 20122 20123 20124 20125 20126 20127 20128 20129 20130 20131 20132 20133 20134 20135 20136 20137 20138 20139 20140 20141 20142 20143 20144 20145 20146 20147 20148 20149 20150 20151 20152 20153 20154 20155 20156 20157 20158 20159 20160 20161 20162 20163 20164 20165 20166 20167 20168 20169 20170 20171 20172 20173 20174 20175 20176 20177 20178 20179 20180 20181 20182 20183 20184 20185 20186 20187 20188 20189 20190 20191 20192 20193 20194 20195 20196 20197 20198 20199 20200 20201 20202 20203 20204 20205 20206 20207 20208 20209 20210 20211 20212 20213 20214 20215 20216 20217 20218 20219 20220 20221 20222 20223 20224 20225 20226 20227 20228 20229 20230 20231 20232 20233 20234 20235 20236 20237 20238 20239 20240 20241 20242 20243 20244 20245 20246 20247 20248 20249 20250 20251 20252 20253 20254 20255 20256 20257 20258 20259 20260 20261 20262 20263 20264 20265 20266 20267 20268 20269 20270 20271 20272 20273 20274 20275 20276 20277 20278 20279 20280 20281 20282 20283 20284 20285 20286 20287 20288 20289 20290 20291 20292 20293 20294 20295 20296 20297 20298 20299 20300 20301 20302 20303 20304 20305 20306 20307 20308 20309 20310 20311 20312 20313 20314 20315 20316 20317 20318 20319 20320 20321 20322 20323 20324 20325 20326 20327 20328 20329 20330 20331 20332 20333 20334 20335 20336 20337 20338 20339 20340 20341 20342 20343 20344 20345 20346 20347 20348 20349 20350 20351 20352 20353 20354 20355 20356 20357 20358 20359 20360 20361 20362 20363 20364 20365 20366 20367 20368 20369 20370 20371 20372 20373 20374 20375 20376 20377 20378 20379 20380 20381 20382 20383 20384 20385 20386 20387 20388 20389 20390 20391 20392 20393 20394 20395 20396 20397 20398 20399 20400 20401 20402 20403 20404 20405 20406 20407 20408 20409 20410 20411 20412 20413 20414 20415 20416 20417 20418 20419 20420 20421 20422 20423 20424 20425 20426 20427 20428 20429 20430 20431 20432 20433 20434 20435 20436 20437 20438 20439 20440 20441 20442 20443 20444 20445 20446 20447 20448 20449 20450 20451 20452 20453 20454 20455 20456 20457 20458 20459 20460 20461 20462 20463 20464 20465 20466 20467 20468 20469 20470 20471 20472 20473 20474 20475 20476 20477 20478 20479 20480 20481 20482 20483 20484 20485 20486 20487 20488 20489 20490 20491 20492 20493 20494 20495 20496 20497 20498 20499 20500 20501 20502 20503 20504 20505 20506 20507 20508 20509 20510 20511 20512 20513 20514 20515 20516 20517 20518 20519 20520 20521 20522 20523 20524 20525 20526 20527 20528 20529 20530 20531 20532 20533 20534 20535 20536 20537 20538 20539 20540 20541 20542 20543 20544 20545 20546 20547 20548 20549 20550 20551 20552 20553 20554 20555 20556 20557 20558 20559 20560 20561 20562 20563 20564 20565 20566 20567 20568 20569 20570 20571 20572 20573 20574 20575 20576 20577 20578 20579 20580 20581 20582 20583 20584 20585 20586 20587 20588 20589 20590 20591 20592 20593 20594 20595 20596 20597 20598 20599 20600 20601 20602 20603 20604 20605 20606 20607 20608 20609 20610 20611 20612 20613 20614 20615 20616 20617 20618 20619 20620 20621 20622 20623 20624 20625 20626 20627 20628 20629 20630 20631 20632 20633 20634 20635 20636 20637 20638 20639 20640 20641 20642 20643 20644 20645 20646 20647 20648 20649 20650 20651 20652 20653 20654 20655 20656 20657 20658 20659 20660 20661 20662 20663 20664 20665 20666 20667 20668 20669 20670 20671 20672 20673 20674 20675 20676 20677 20678 20679 20680 20681 20682 20683 20684 20685 20686 20687 20688 20689 20690 20691 20692 20693 20694 20695 20696 20697 20698 20699 20700 20701 20702 20703 20704 20705 20706 20707 20708 20709 20710 20711 20712 20713 20714 20715 20716 20717 20718 20719 20720 20721 20722 20723 20724 20725 20726 20727 20728 20729 20730 20731 20732 20733 20734 20735 20736 20737 20738 20739 20740 20741 20742 20743 20744 20745 20746 20747 20748 20749 20750 20751 20752 20753 20754 20755 20756 20757 20758 20759 20760 20761 20762 20763 20764 20765 20766 20767 20768 20769 20770 20771 20772 20773 20774 20775 20776 20777 20778 20779 20780 20781 20782 20783 20784 20785 20786 20787 20788 20789 20790 20791 20792 20793 20794 20795 20796 20797 20798 20799 20800 20801 20802 20803 20804 20805 20806 20807 20808 20809 20810 20811 20812 20813 20814 20815 20816 20817 20818 20819 20820 20821 20822 20823 20824 20825 20826 20827 20828 20829 20830 20831 20832 20833 20834 20835 20836 20837 20838 20839 20840 20841 20842 20843 20844 20845 20846 20847 20848 20849 20850 20851 20852 20853 20854 20855 20856 20857 20858 20859 20860 20861 20862 20863 20864 20865 20866 20867 20868 20869 20870 20871 20872 20873 20874 20875 20876 20877 20878 20879 20880 20881 20882 20883 20884 20885 20886 20887 20888 20889 20890 20891 20892 20893 20894 20895 20896 20897 20898 20899 20900 20901 20902 20903 20904 20905 20906 20907 20908 20909 20910 20911 20912 20913 20914 20915 20916 20917 20918 20919 20920 20921 20922 20923 20924 20925 20926 20927 20928 20929 20930 20931 20932 20933 20934 20935 20936 20937 20938 20939 20940 20941 20942 20943 20944 20945 20946 20947 20948 20949 20950 20951 20952 20953 20954 20955 20956 20957 20958 20959 20960 20961 20962 20963 20964 20965 20966 20967 20968 20969 20970 20971 20972 20973 20974 20975 20976 20977 20978 20979 20980 20981 20982 20983 20984 20985 20986 20987 20988 20989 20990 20991 20992 20993 20994 20995 20996 20997 20998 20999 21000 21001 21002 21003 21004 21005 21006 21007 21008 21009 21010 21011 21012 21013 21014 21015 21016 21017 21018 21019 21020 21021 21022 21023 21024 21025 21026 21027 21028 21029 21030 21031 21032 21033 21034 21035 21036 21037 21038 21039 21040 21041 21042 21043 21044 21045 21046 21047 21048 21049 21050 21051 21052 21053 21054 21055 21056 21057 21058 21059 21060 21061 21062 21063 21064 21065 21066 21067 21068 21069 21070 21071 21072 21073 21074 21075 21076 21077 21078 21079 21080 21081 21082 21083 21084 21085 21086 21087 21088 21089 21090 21091 21092 21093 21094 21095 21096 21097 21098 21099 21100 21101 21102 21103 21104 21105 21106 21107 21108 21109 21110 21111 21112 21113 21114 21115 21116 21117 21118 21119 21120 21121 21122 21123 21124 21125 21126 21127 21128 21129 21130 21131 21132 21133 21134 21135 21136 21137 21138 21139 21140 21141 21142 21143 21144 21145 21146 21147 21148 21149 21150 21151 21152 21153 21154 21155 21156 21157 21158 21159 21160 21161 21162 21163 21164 21165 21166 21167 21168 21169 21170 21171 21172 21173 21174 21175 21176 21177 21178 21179 21180 21181 21182 21183 21184 21185 21186 21187 21188 21189 21190 21191 21192 21193 21194 21195 21196 21197 21198 21199 21200 21201 21202 21203 21204 21205 21206 21207 21208 21209 21210 21211 21212 21213 21214 21215 21216 21217 21218 21219 21220 21221 21222 21223 21224 21225 21226 21227 21228 21229 21230 21231 21232 21233 21234 21235 21236 21237 21238 21239 21240 21241 21242 21243 21244 21245 21246 21247 21248 21249 21250 21251 21252 21253 21254 21255 21256 21257 21258 21259 21260 21261 21262 21263 21264 21265 21266 21267 21268 21269 21270 21271 21272 21273 21274 21275 21276 21277 21278 21279 21280 21281 21282 21283 21284 21285 21286 21287 21288 21289 21290 21291 21292 21293 21294 21295 21296 21297 21298 21299 21300 21301 21302 21303 21304 21305 21306 21307 21308 21309 21310 21311 21312 21313 21314 21315 21316 21317 21318 21319 21320 21321 21322 21323 21324 21325 21326 21327 21328 21329 21330 21331 21332 21333 21334 21335 21336 21337 21338 21339 21340 21341 21342 21343 21344 21345 21346 21347 21348 21349 21350 21351 21352 21353 21354 21355 21356 21357 21358 21359 21360 21361 21362 21363 21364 21365 21366 21367 21368 21369 21370 21371 21372 21373 21374 21375 21376 21377 21378 21379 21380 21381 21382 21383 21384 21385 21386 21387 21388 21389 21390 21391 21392 21393 21394 21395 21396 21397 21398 21399 21400 21401 21402 21403 21404 21405 21406 21407 21408 21409 21410 21411 21412 21413 21414 21415 21416 21417 21418 21419 21420 21421 21422 21423 21424 21425 21426 21427 21428 21429 21430 21431 21432 21433 21434 21435 21436 21437 21438 21439 21440 21441 21442 21443 21444 21445 21446 21447 21448 21449 21450 21451 21452 21453 21454 21455 21456 21457 21458 21459 21460 21461 21462 21463 21464 21465 21466 21467 21468 21469 21470 21471 21472 21473 21474 21475 21476 21477 21478 21479 21480 21481 21482 21483 21484 21485 21486 21487 21488 21489 21490 21491 21492 21493 21494 21495 21496 21497 21498 21499 21500 21501 21502 21503 21504 21505 21506 21507 21508 21509 21510 21511 21512 21513 21514 21515 21516 21517 21518 21519 21520 21521 21522 21523 21524 21525 21526 21527 21528 21529 21530 21531 21532 21533 21534 21535 21536 21537 21538 21539 21540 21541 21542 21543 21544 21545 21546 21547 21548 21549 21550 21551 21552 21553 21554 21555 21556 21557 21558 21559 21560 21561 21562 21563 21564 21565 21566 21567 21568 21569 21570 21571 21572 21573 21574 21575 21576 21577 21578 21579 21580 21581 21582 21583 21584 21585 21586 21587 21588 21589 21590 21591 21592 21593 21594 21595 21596 21597 21598 21599 21600 21601 21602 21603 21604 21605 21606 21607 21608 21609 21610 21611 21612 21613 21614 21615 21616 21617 21618 21619 21620 21621 21622 21623 21624 21625 21626 21627 21628 21629 21630 21631 21632 21633 21634 21635 21636 21637 21638 21639 21640 21641 21642 21643 21644 21645 21646 21647 21648 21649 21650 21651 21652 21653 21654 21655 21656 21657 21658 21659 21660 21661 21662 21663 21664 21665 21666 21667 21668 21669 21670 21671 21672 21673 21674 21675 21676 21677 21678 21679 21680 21681 21682 21683 21684 21685 21686 21687 21688 21689 21690 21691 21692 21693 21694 21695 21696 21697 21698 21699 21700 21701 21702 21703 21704 21705 21706 21707 21708 21709 21710 21711 21712 21713 21714 21715 21716 21717 21718 21719 21720 21721 21722 21723 21724 21725 21726 21727 21728 21729 21730 21731 21732 21733 21734 21735 21736 21737 21738 21739 21740 21741 21742 21743 21744 21745 21746 21747 21748 21749 21750 21751 21752 21753 21754 21755 21756 21757 21758 21759 21760 21761 21762 21763 21764 21765 21766 21767 21768 21769 21770 21771 21772 21773 21774 21775 21776 21777 21778 21779 21780 21781 21782 21783 21784 21785 21786 21787 21788 21789 21790 21791 21792 21793 21794 21795 21796 21797 21798 21799 21800 21801 21802 21803 21804 21805 21806 21807 21808 21809 21810 21811 21812 21813 21814 21815 21816 21817 21818 21819 21820 21821 21822 21823 21824 21825 21826 21827 21828 21829 21830 21831 21832 21833 21834 21835 21836 21837 21838 21839 21840 21841 21842 21843 21844 21845 21846 21847 21848 21849 21850 21851 21852 21853 21854 21855 21856 21857 21858 21859 21860 21861 21862 21863 21864 21865 21866 21867 21868 21869 21870 21871 21872 21873 21874 21875 21876 21877 21878 21879 21880 21881 21882 21883 21884 21885 21886 21887 21888 21889 21890 21891 21892 21893 21894 21895 21896 21897 21898 21899 21900 21901 21902 21903 21904 21905 21906 21907 21908 21909 21910 21911 21912 21913 21914 21915 21916 21917 21918 21919 21920 21921 21922 21923 21924 21925 21926 21927 21928 21929 21930 21931 21932 21933 21934 21935 21936 21937 21938 21939 21940 21941 21942 21943 21944 21945 21946 21947 21948 21949 21950 21951 21952 21953 21954 21955 21956 21957 21958 21959 21960 21961 21962 21963 21964 21965 21966 21967 21968 21969 21970 21971 21972 21973 21974 21975 21976 21977 21978 21979 21980 21981 21982 21983 21984 21985 21986 21987 21988 21989 21990 21991 21992 21993 21994 21995 21996 21997 21998 21999 22000 22001 22002 22003 22004 22005 22006 22007 22008 22009 22010 22011 22012 22013 22014 22015 22016 22017 22018 22019 22020 22021 22022 22023 22024 22025 22026 22027 22028 22029 22030 22031 22032 22033 22034 22035 22036 22037 22038 22039 22040 22041 22042 22043 22044 22045 22046 22047 22048 22049 22050 22051 22052 22053 22054 22055 22056 22057 22058 22059 22060 22061 22062 22063 22064 22065 22066 22067 22068 22069 22070 22071 22072 22073 22074 22075 22076 22077 22078 22079 22080 22081 22082 22083 22084 22085 22086 22087 22088 22089 22090 22091 22092 22093 22094 22095 22096 22097 22098 22099 22100 22101 22102 22103 22104 22105 22106 22107 22108 22109 22110 22111 22112 22113 22114 22115 22116 22117 22118 22119 22120 22121 22122 22123 22124 22125 22126 22127 22128 22129 22130 22131 22132 22133 22134 22135 22136 22137 22138 22139 22140 22141 22142 22143 22144 22145 22146 22147 22148 22149 22150 22151 22152 22153 22154 22155 22156 22157 22158 22159 22160 22161 22162 22163 22164 22165 22166 22167 22168 22169 22170 22171 22172 22173 22174 22175 22176 22177 22178 22179 22180 22181 22182 22183 22184 22185 22186 22187 22188 22189 22190 22191 22192 22193 22194 22195 22196 22197 22198 22199 22200 22201 22202 22203 22204 22205 22206 22207 22208 22209 22210 22211 22212 22213 22214 22215 22216 22217 22218 22219 22220 22221 22222 22223 22224 22225 22226 22227 22228 22229 22230 22231 22232 22233 22234 22235 22236 22237 22238 22239 22240 22241 22242 22243 22244 22245 22246 22247 22248 22249 22250 22251 22252 22253 22254 22255 22256 22257 22258 22259 22260 22261 22262 22263 22264 22265 22266 22267 22268 22269 22270 22271 22272 22273 22274 22275 22276 22277 22278 22279 22280 22281 22282 22283 22284 22285 22286 22287 22288 22289 22290 22291 22292 22293 22294 22295 22296 22297 22298 22299 22300 22301 22302 22303 22304 22305 22306 22307 22308 22309 22310 22311 22312 22313 22314 22315 22316 22317 22318 22319 22320 22321 22322 22323 22324 22325 22326 22327 22328 22329 22330 22331 22332 22333 22334 22335 22336 22337 22338 22339 22340 22341 22342 22343 22344 22345 22346 22347 22348 22349 22350 22351 22352 22353 22354 22355 22356 22357 22358 22359 22360 22361 22362 22363 22364 22365 22366 22367 22368 22369 22370 22371 22372 22373 22374 22375 22376 22377 22378 22379 22380 22381 22382 22383 22384 22385 22386 22387 22388 22389 22390 22391 22392 22393 22394 22395 22396 22397 22398 22399 22400 22401 22402 22403 22404 22405 22406 22407 22408 22409 22410 22411 22412 22413 22414 22415 22416 22417 22418 22419 22420 22421 22422 22423 22424 22425 22426 22427 22428 22429 22430 22431 22432 22433 22434 22435 22436 22437 22438 22439 22440 22441 22442 22443 22444 22445 22446 22447 22448 22449 22450 22451 22452 22453 22454 22455 22456 22457 22458 22459 22460 22461 22462 22463 22464 22465 22466 22467 22468 22469 22470 22471 22472 22473 22474 22475 22476 22477 22478 22479 22480 22481 22482 22483 22484 22485 22486 22487 22488 22489 22490 22491 22492 22493 22494 22495 22496 22497 22498 22499 22500 22501 22502 22503 22504 22505 22506 22507 22508 22509 22510 22511 22512 22513 22514 22515 22516 22517 22518 22519 22520 22521 22522 22523 22524 22525 22526 22527 22528 22529 22530 22531 22532 22533 22534 22535 22536 22537 22538 22539 22540 22541 22542 22543 22544 22545 22546 22547 22548 22549 22550 22551 22552 22553 22554 22555 22556 22557 22558 22559 22560 22561 22562 22563 22564 22565 22566 22567 22568 22569 22570 22571 22572 22573 22574 22575 22576 22577 22578 22579 22580 22581 22582 22583 22584 22585 22586 22587 22588 22589 22590 22591 22592 22593 22594 22595 22596 22597 22598 22599 22600 22601 22602 22603 22604 22605 22606 22607 22608 22609 22610 22611 22612 22613 22614 22615 22616 22617 22618 22619 22620 22621 22622 22623 22624 22625 22626 22627 22628 22629 22630 22631 22632 22633 22634 22635 22636 22637 22638 22639 22640 22641 22642 22643 22644 22645 22646 22647 22648 22649 22650 22651 22652 22653 22654 22655 22656 22657 22658 22659 22660 22661 22662 22663 22664 22665 22666 22667 22668 22669 22670 22671 22672 22673 22674 22675 22676 22677 22678 22679 22680 22681 22682 22683 22684 22685 22686 22687 22688 22689 22690 22691 22692 22693 22694 22695 22696 22697 22698 22699 22700 22701 22702 22703 22704 22705 22706 22707 22708 22709 22710 22711 22712 22713 22714 22715 22716 22717 22718 22719 22720 22721 22722 22723 22724 22725 22726 22727 22728 22729 22730 22731 22732 22733 22734 22735 22736 22737 22738 22739 22740 22741 22742 22743 22744 22745 22746 22747 22748 22749 22750 22751 22752 22753 22754 22755 22756 22757 22758 22759 22760 22761 22762 22763 22764 22765 22766 22767 22768 22769 22770 22771 22772 22773 22774 22775 22776 22777 22778 22779 22780 22781 22782 22783 22784 22785 22786 22787 22788 22789 22790 22791 22792 22793 22794 22795 22796 22797 22798 22799 22800 22801 22802 22803 22804 22805 22806 22807 22808 22809 22810 22811 22812 22813 22814 22815 22816 22817 22818 22819 22820 22821 22822 22823 22824 22825 22826 22827 22828 22829 22830 22831 22832 22833 22834 22835 22836 22837 22838 22839 22840 22841 22842 22843 22844 22845 22846 22847 22848 22849 22850 22851 22852 22853 22854 22855 22856 22857 22858 22859 22860 22861 22862 22863 22864 22865 22866 22867 22868 22869 22870 22871 22872 22873 22874 22875 22876 22877 22878 22879 22880 22881 22882 22883 22884 22885 22886 22887 22888 22889 22890 22891 22892 22893 22894 22895 22896 22897 22898 22899 22900 22901 22902 22903 22904 22905 22906 22907 22908 22909 22910 22911 22912 22913 22914 22915 22916 22917 22918 22919 22920 22921 22922 22923 22924 22925 22926 22927 22928 22929 22930 22931 22932 22933 22934 22935 22936 22937 22938 22939 22940 22941 22942 22943 22944 22945 22946 22947 22948 22949 22950 22951 22952 22953 22954 22955 22956 22957 22958 22959 22960 22961 22962 22963 22964 22965 22966 22967 22968 22969 22970 22971 22972 22973 22974 22975 22976 22977 22978 22979 22980 22981 22982 22983 22984 22985 22986 22987 22988 22989 22990 22991 22992 22993 22994 22995 22996 22997 22998 22999 23000 23001 23002 23003 23004 23005 23006 23007 23008 23009 23010 23011 23012 23013 23014 23015 23016 23017 23018 23019 23020 23021 23022 23023 23024 23025 23026 23027 23028 23029 23030 23031 23032 23033 23034 23035 23036 23037 23038 23039 23040 23041 23042 23043 23044 23045 23046 23047 23048 23049 23050 23051 23052 23053 23054 23055 23056 23057 23058 23059 23060 23061 23062 23063 23064 23065 23066 23067 23068 23069 23070 23071 23072 23073 23074 23075 23076 23077 23078 23079 23080 23081 23082 23083 23084 23085 23086 23087 23088 23089 23090 23091 23092 23093 23094 23095 23096 23097 23098 23099 23100 23101 23102 23103 23104 23105 23106 23107 23108 23109 23110 23111 23112 23113 23114 23115 23116 23117 23118 23119 23120 23121 23122 23123 23124 23125 23126 23127 23128 23129 23130 23131 23132 23133 23134 23135 23136 23137 23138 23139 23140 23141 23142 23143 23144 23145 23146 23147 23148 23149 23150 23151 23152 23153 23154 23155 23156 23157 23158 23159 23160 23161 23162 23163 23164 23165 23166 23167 23168 23169 23170 23171 23172 23173 23174 23175 23176 23177 23178 23179 23180 23181 23182 23183 23184 23185 23186 23187 23188 23189 23190 23191 23192 23193 23194 23195 23196 23197 23198 23199 23200 23201 23202 23203 23204 23205 23206 23207 23208 23209 23210 23211 23212 23213 23214 23215 23216 23217 23218 23219 23220 23221 23222 23223 23224 23225 23226 23227 23228 23229 23230 23231 23232 23233 23234 23235 23236 23237 23238 23239 23240 23241 23242 23243 23244 23245 23246 23247 23248 23249 23250 23251 23252 23253 23254 23255 23256 23257 23258 23259 23260 23261 23262 23263 23264 23265 23266 23267 23268 23269 23270 23271 23272 23273 23274 23275 23276 23277 23278 23279 23280 23281 23282 23283 23284 23285 23286 23287 23288 23289 23290 23291 23292 23293 23294 23295 23296 23297 23298 23299 23300 23301 23302 23303 23304 23305 23306 23307 23308 23309 23310 23311 23312 23313 23314 23315 23316 23317 23318 23319 23320 23321 23322 23323 23324 23325 23326 23327 23328 23329 23330 23331 23332 23333 23334 23335 23336 23337 23338 23339 23340 23341 23342 23343 23344 23345 23346 23347 23348 23349 23350 23351 23352 23353 23354 23355 23356 23357 23358 23359 23360 23361 23362 23363 23364 23365 23366 23367 23368 23369 23370 23371 23372 23373 23374 23375 23376 23377 23378 23379 23380 23381 23382 23383 23384 23385 23386 23387 23388 23389 23390 23391 23392 23393 23394 23395 23396 23397 23398 23399 23400 23401 23402 23403 23404 23405 23406 23407 23408 23409 23410 23411 23412 23413 23414 23415 23416 23417 23418 23419 23420 23421 23422 23423 23424 23425 23426 23427 23428 23429 23430 23431 23432 23433 23434 23435 23436 23437 23438 23439 23440 23441 23442 23443 23444 23445 23446 23447 23448 23449 23450 23451 23452 23453 23454 23455 23456 23457 23458 23459 23460 23461 23462 23463 23464 23465 23466 23467 23468 23469 23470 23471 23472 23473 23474 23475 23476 23477 23478 23479 23480 23481 23482 23483 23484 23485 23486 23487 23488 23489 23490 23491 23492 23493 23494 23495 23496 23497 23498 23499 23500 23501 23502 23503 23504 23505 23506 23507 23508 23509 23510 23511 23512 23513 23514 23515 23516 23517 23518 23519 23520 23521 23522 23523 23524 23525 23526 23527 23528 23529 23530 23531 23532 23533 23534 23535 23536 23537 23538 23539 23540 23541 23542 23543 23544 23545 23546 23547 23548 23549 23550 23551 23552 23553 23554 23555 23556 23557 23558 23559 23560 23561 23562 23563 23564 23565 23566 23567 23568 23569 23570 23571 23572 23573 23574 23575 23576 23577 23578 23579 23580 23581 23582 23583 23584 23585 23586 23587 23588 23589 23590 23591 23592 23593 23594 23595 23596 23597 23598 23599 23600 23601 23602 23603 23604 23605 23606 23607 23608 23609 23610 23611 23612 23613 23614 23615 23616 23617 23618 23619 23620 23621 23622 23623 23624 23625 23626 23627 23628 23629 23630 23631 23632 23633 23634 23635 23636 23637 23638 23639 23640 23641 23642 23643 23644 23645 23646 23647 23648 23649 23650 23651 23652 23653 23654 23655 23656 23657 23658 23659 23660 23661 23662 23663 23664 23665 23666 23667 23668 23669 23670 23671 23672 23673 23674 23675 23676 23677 23678 23679 23680 23681 23682 23683 23684 23685 23686 23687 23688 23689 23690 23691 23692 23693 23694 23695 23696 23697 23698 23699 23700 23701 23702 23703 23704 23705 23706 23707 23708 23709 23710 23711 23712 23713 23714 23715 23716 23717 23718 23719 23720 23721 23722 23723 23724 23725 23726 23727 23728 23729 23730 23731 23732 23733 23734 23735 23736 23737 23738 23739 23740 23741 23742 23743 23744 23745 23746 23747 23748 23749 23750 23751 23752 23753 23754 23755 23756 23757 23758 23759 23760 23761 23762 23763 23764 23765 23766 23767 23768 23769 23770 23771 23772 23773 23774 23775 23776 23777 23778 23779 23780 23781 23782 23783 23784 23785 23786 23787 23788 23789 23790 23791 23792 23793 23794 23795 23796 23797 23798 23799 23800 23801 23802 23803 23804 23805 23806 23807 23808 23809 23810 23811 23812 23813 23814 23815 23816 23817 23818 23819 23820 23821 23822 23823 23824 23825 23826 23827 23828 23829 23830 23831 23832 23833 23834 23835 23836 23837 23838 23839 23840 23841 23842 23843 23844 23845 23846 23847 23848 23849 23850 23851 23852 23853 23854 23855 23856 23857 23858 23859 23860 23861 23862 23863 23864 23865 23866 23867 23868 23869 23870 23871 23872 23873 23874 23875 23876 23877 23878 23879 23880 23881 23882 23883 23884 23885 23886 23887 23888 23889 23890 23891 23892 23893 23894 23895 23896 23897 23898 23899 23900 23901 23902 23903 23904 23905 23906 23907 23908 23909 23910 23911 23912 23913 23914 23915 23916 23917 23918 23919 23920 23921 23922 23923 23924 23925 23926 23927 23928 23929 23930 23931 23932 23933 23934 23935 23936 23937 23938 23939 23940 23941 23942 23943 23944 23945 23946 23947 23948 23949 23950 23951 23952 23953 23954 23955 23956 23957 23958 23959 23960 23961 23962 23963 23964 23965 23966 23967 23968 23969 23970 23971 23972 23973 23974 23975 23976 23977 23978 23979 23980 23981 23982 23983 23984 23985 23986 23987 23988 23989 23990 23991 23992 23993 23994 23995 23996 23997 23998 23999 24000 24001 24002 24003 24004 24005 24006 24007 24008 24009 24010 24011 24012 24013 24014 24015 24016 24017 24018 24019 24020 24021 24022 24023 24024 24025 24026 24027 24028 24029 24030 24031 24032 24033 24034 24035 24036 24037 24038 24039 24040 24041 24042 24043 24044 24045 24046 24047 24048 24049 24050 24051 24052 24053 24054 24055 24056 24057 24058 24059 24060 24061 24062 24063 24064 24065 24066 24067 24068 24069 24070 24071 24072 24073 24074 24075 24076 24077 24078 24079 24080 24081 24082 24083 24084 24085 24086 24087 24088 24089 24090 24091 24092 24093 24094 24095 24096 24097 24098 24099 24100 24101 24102 24103 24104 24105 24106 24107 24108 24109 24110 24111 24112 24113 24114 24115 24116 24117 24118 24119 24120 24121 24122 24123 24124 24125 24126 24127 24128 24129 24130 24131 24132 24133 24134 24135 24136 24137 24138 24139 24140 24141 24142 24143 24144 24145 24146 24147 24148 24149 24150 24151 24152 24153 24154 24155 24156 24157 24158 24159 24160 24161 24162 24163 24164 24165 24166 24167 24168 24169 24170 24171 24172 24173 24174 24175 24176 24177 24178 24179 24180 24181 24182 24183 24184 24185 24186 24187 24188 24189 24190 24191 24192 24193 24194 24195 24196 24197 24198 24199 24200 24201 24202 24203 24204 24205 24206 24207 24208 24209 24210 24211 24212 24213 24214 24215 24216 24217 24218 24219 24220 24221 24222 24223 24224 24225 24226 24227 24228 24229 24230 24231 24232 24233 24234 24235 24236 24237 24238 24239 24240 24241 24242 24243 24244 24245 24246 24247 24248 24249 24250 24251 24252 24253 24254 24255 24256 24257 24258 24259 24260 24261 24262 24263 24264 24265 24266 24267 24268 24269 24270 24271 24272 24273 24274 24275 24276 24277 24278 24279 24280 24281 24282 24283 24284 24285 24286 24287 24288 24289 24290 24291 24292 24293 24294 24295 24296 24297 24298 24299 24300 24301 24302 24303 24304 24305 24306 24307 24308 24309 24310 24311 24312 24313 24314 24315 24316 24317 24318 24319 24320 24321 24322 24323 24324 24325 24326 24327 24328 24329 24330 24331 24332 24333 24334 24335 24336 24337 24338 24339 24340 24341 24342 24343 24344 24345 24346 24347 24348 24349 24350 24351 24352 24353 24354 24355 24356 24357 24358 24359 24360 24361 24362 24363 24364 24365 24366 24367 24368 24369 24370 24371 24372 24373 24374 24375 24376 24377 24378 24379 24380 24381 24382 24383 24384 24385 24386 24387 24388 24389 24390 24391 24392 24393 24394 24395 24396 24397 24398 24399 24400 24401 24402 24403 24404 24405 24406 24407 24408 24409 24410 24411 24412 24413 24414 24415 24416 24417 24418 24419 24420 24421 24422 24423 24424 24425 24426 24427 24428 24429 24430 24431 24432 24433 24434 24435 24436 24437 24438 24439 24440 24441 24442 24443 24444 24445 24446 24447 24448 24449 24450 24451 24452 24453 24454 24455 24456 24457 24458 24459 24460 24461 24462 24463 24464 24465 24466 24467 24468 24469 24470 24471 24472 24473 24474 24475 24476 24477 24478 24479 24480 24481 24482 24483 24484 24485 24486 24487 24488 24489 24490 24491 24492 24493 24494 24495 24496 24497 24498 24499 24500 24501 24502 24503 24504 24505 24506 24507 24508 24509 24510 24511 24512 24513 24514 24515 24516 24517 24518 24519 24520 24521 24522 24523 24524 24525 24526 24527 24528 24529 24530 24531 24532 24533 24534 24535 24536 24537 24538 24539 24540 24541 24542 24543 24544 24545 24546 24547 24548 24549 24550 24551 24552 24553 24554 24555 24556 24557 24558 24559 24560 24561 24562 24563 24564 24565 24566 24567 24568 24569 24570 24571 24572 24573 24574 24575 24576 24577 24578 24579 24580 24581 24582 24583 24584 24585 24586 24587 24588 24589 24590 24591 24592 24593 24594 24595 24596 24597 24598 24599 24600 24601 24602 24603 24604 24605 24606 24607 24608 24609 24610 24611 24612 24613 24614 24615 24616 24617 24618 24619 24620 24621 24622 24623 24624 24625 24626 24627 24628 24629 24630 24631 24632 24633 24634 24635 24636 24637 24638 24639 24640 24641 24642 24643 24644 24645 24646 24647 24648 24649 24650 24651 24652 24653 24654 24655 24656 24657 24658 24659 24660 24661 24662 24663 24664 24665 24666 24667 24668 24669 24670 24671 24672 24673 24674 24675 24676 24677 24678 24679 24680 24681 24682 24683 24684 24685 24686 24687 24688 24689 24690 24691 24692 24693 24694 24695 24696 24697 24698 24699 24700 24701 24702 24703 24704 24705 24706 24707 24708 24709 24710 24711 24712 24713 24714 24715 24716 24717 24718 24719 24720 24721 24722 24723 24724 24725 24726 24727 24728 24729 24730 24731 24732 24733 24734 24735 24736 24737 24738 24739 24740 24741 24742 24743 24744 24745 24746 24747 24748 24749 24750 24751 24752 24753 24754 24755 24756 24757 24758 24759 24760 24761 24762 24763 24764 24765 24766 24767 24768 24769 24770 24771 24772 24773 24774 24775 24776 24777 24778 24779 24780 24781 24782 24783 24784 24785 24786 24787 24788 24789 24790 24791 24792 24793 24794 24795 24796 24797 24798 24799 24800 24801 24802 24803 24804 24805 24806 24807 24808 24809 24810 24811 24812 24813 24814 24815 24816 24817 24818 24819 24820 24821 24822 24823 24824 24825 24826 24827 24828 24829 24830 24831 24832 24833 24834 24835 24836 24837 24838 24839 24840 24841 24842 24843 24844 24845 24846 24847 24848 24849 24850 24851 24852 24853 24854 24855 24856 24857 24858 24859 24860 24861 24862 24863 24864 24865 24866 24867 24868 24869 24870 24871 24872 24873 24874 24875 24876 24877 24878 24879 24880 24881 24882 24883 24884 24885 24886 24887 24888 24889 24890 24891 24892 24893 24894 24895 24896 24897 24898 24899 24900 24901 24902 24903 24904 24905 24906 24907 24908 24909 24910 24911 24912 24913 24914 24915 24916 24917 24918 24919 24920 24921 24922 24923 24924 24925 24926 24927 24928 24929 24930 24931 24932 24933 24934 24935 24936 24937 24938 24939 24940 24941 24942 24943 24944 24945 24946 24947 24948 24949 24950 24951 24952 24953 24954 24955 24956 24957 24958 24959 24960 24961 24962 24963 24964 24965 24966 24967 24968 24969 24970 24971 24972 24973 24974 24975 24976 24977 24978 24979 24980 24981 24982 24983 24984 24985 24986 24987 24988 24989 24990 24991 24992 24993 24994 24995 24996 24997 24998 24999 25000 25001 25002 25003 25004 25005 25006 25007 25008 25009 25010 25011 25012 25013 25014 25015 25016 25017 25018 25019 25020 25021 25022 25023 25024 25025 25026 25027 25028 25029 25030 25031 25032 25033 25034 25035 25036 25037 25038 25039 25040 25041 25042 25043 25044 25045 25046 25047 25048 25049 25050 25051 25052 25053 25054 25055 25056 25057 25058 25059 25060 25061 25062 25063 25064 25065 25066 25067 25068 25069 25070 25071 25072 25073 25074 25075 25076 25077 25078 25079 25080 25081 25082 25083 25084 25085 25086 25087 25088 25089 25090 25091 25092 25093 25094 25095 25096 25097 25098 25099 25100 25101 25102 25103 25104 25105 25106 25107 25108 25109 25110 25111 25112 25113 25114 25115 25116 25117 25118 25119 25120 25121 25122 25123 25124 25125 25126 25127 25128 25129 25130 25131 25132 25133 25134 25135 25136 25137 25138 25139 25140 25141 25142 25143 25144 25145 25146 25147 25148 25149 25150 25151 25152 25153 25154 25155 25156 25157 25158 25159 25160 25161 25162 25163 25164 25165 25166 25167 25168 25169 25170 25171 25172 25173 25174 25175 25176 25177 25178 25179 25180 25181 25182 25183 25184 25185 25186 25187 25188 25189 25190 25191 25192 25193 25194 25195 25196 25197 25198 25199 25200 25201 25202 25203 25204 25205 25206 25207 25208 25209 25210 25211 25212 25213 25214 25215 25216 25217 25218 25219 25220 25221 25222 25223 25224 25225 25226 25227 25228 25229 25230 25231 25232 25233 25234 25235 25236 25237 25238 25239 25240 25241 25242 25243 25244 25245 25246 25247 25248 25249 25250 25251 25252 25253 25254 25255 25256 25257 25258 25259 25260 25261 25262 25263 25264 25265 25266 25267 25268 25269 25270 25271 25272 25273 25274 25275 25276 25277 25278 25279 25280 25281 25282 25283 25284 25285 25286 25287 25288 25289 25290 25291 25292 25293 25294 25295 25296 25297 25298 25299 25300 25301 25302 25303 25304 25305 25306 25307 25308 25309 25310 25311 25312 25313 25314 25315 25316 25317 25318 25319 25320 25321 25322 25323 25324 25325 25326 25327 25328 25329 25330 25331 25332 25333 25334 25335 25336 25337 25338 25339 25340 25341 25342 25343 25344 25345 25346 25347 25348 25349 25350 25351 25352 25353 25354 25355 25356 25357 25358 25359 25360 25361 25362 25363 25364 25365 25366 25367 25368 25369 25370 25371 25372 25373 25374 25375 25376 25377 25378 25379 25380 25381 25382 25383 25384 25385 25386 25387 25388 25389 25390 25391 25392 25393 25394 25395 25396 25397 25398 25399 25400 25401 25402 25403 25404 25405 25406 25407 25408 25409 25410 25411 25412 25413 25414 25415 25416 25417 25418 25419 25420 25421 25422 25423 25424 25425 25426 25427 25428 25429 25430 25431 25432 25433 25434 25435 25436 25437 25438 25439 25440 25441 25442 25443 25444 25445 25446 25447 25448 25449 25450 25451 25452 25453 25454 25455 25456 25457 25458 25459 25460 25461 25462 25463 25464 25465 25466 25467 25468 25469 25470 25471 25472 25473 25474 25475 25476 25477 25478 25479 25480 25481 25482 25483 25484 25485 25486 25487 25488 25489 25490 25491 25492 25493 25494 25495 25496 25497 25498 25499 25500 25501 25502 25503 25504 25505 25506 25507 25508 25509 25510 25511 25512 25513 25514 25515 25516 25517 25518 25519 25520 25521 25522 25523 25524 25525 25526 25527 25528 25529 25530 25531 25532 25533 25534 25535 25536 25537 25538 25539 25540 25541 25542 25543 25544 25545 25546 25547 25548 25549 25550 25551 25552 25553 25554 25555 25556 25557 25558 25559 25560 25561 25562 25563 25564 25565 25566 25567 25568 25569 25570 25571 25572 25573 25574 25575 25576 25577 25578 25579 25580 25581 25582 25583 25584 25585 25586 25587 25588 25589 25590 25591 25592 25593 25594 25595 25596 25597 25598 25599 25600 25601 25602 25603 25604 25605 25606 25607 25608 25609 25610 25611 25612 25613 25614 25615 25616 25617 25618 25619 25620 25621 25622 25623 25624 25625 25626 25627 25628 25629 25630 25631 25632 25633 25634 25635 25636 25637 25638 25639 25640 25641 25642 25643 25644 25645 25646 25647 25648 25649 25650 25651 25652 25653 25654 25655 25656 25657 25658 25659 25660 25661 25662 25663 25664 25665 25666 25667 25668 25669 25670 25671 25672 25673 25674 25675 25676 25677 25678 25679 25680 25681 25682 25683 25684 25685 25686 25687 25688 25689 25690 25691 25692 25693 25694 25695 25696 25697 25698 25699 25700 25701 25702 25703 25704 25705 25706 25707 25708 25709 25710 25711 25712 25713 25714 25715 25716 25717 25718 25719 25720 25721 25722 25723 25724 25725 25726 25727 25728 25729 25730 25731 25732 25733 25734 25735 25736 25737 25738 25739 25740 25741 25742 25743 25744 25745 25746 25747 25748 25749 25750 25751 25752 25753 25754 25755 25756 25757 25758 25759 25760 25761 25762 25763 25764 25765 25766 25767 25768 25769 25770 25771 25772 25773 25774 25775 25776 25777 25778 25779 25780 25781 25782 25783 25784 25785 25786 25787 25788 25789 25790 25791 25792 25793 25794 25795 25796 25797 25798 25799 25800 25801 25802 25803 25804 25805 25806 25807 25808 25809 25810 25811 25812 25813 25814 25815 25816 25817 25818 25819 25820 25821 25822 25823 25824 25825 25826 25827 25828 25829 25830 25831 25832 25833 25834 25835 25836 25837 25838 25839 25840 25841 25842 25843 25844 25845 25846 25847 25848 25849 25850 25851 25852 25853 25854 25855 25856 25857 25858 25859 25860 25861 25862 25863 25864 25865 25866 25867 25868 25869 25870 25871 25872 25873 25874 25875 25876 25877 25878 25879 25880 25881 25882 25883 25884 25885 25886 25887 25888 25889 25890 25891 25892 25893 25894 25895 25896 25897 25898 25899 25900 25901 25902 25903 25904 25905 25906 25907 25908 25909 25910 25911 25912 25913 25914 25915 25916 25917 25918 25919 25920 25921 25922 25923 25924 25925 25926 25927 25928 25929 25930 25931 25932 25933 25934 25935 25936 25937 25938 25939 25940 25941 25942 25943 25944 25945 25946 25947 25948 25949 25950 25951 25952 25953 25954 25955 25956 25957 25958 25959 25960 25961 25962 25963 25964 25965 25966 25967 25968 25969 25970 25971 25972 25973 25974 25975 25976 25977 25978 25979 25980 25981 25982 25983 25984 25985 25986 25987 25988 25989 25990 25991 25992 25993 25994 25995 25996 25997 25998 25999 26000 26001 26002 26003 26004 26005 26006 26007 26008 26009 26010 26011 26012 26013 26014 26015 26016 26017 26018 26019 26020 26021 26022 26023 26024 26025 26026 26027 26028 26029 26030 26031 26032 26033 26034 26035 26036 26037 26038 26039 26040 26041 26042 26043 26044 26045 26046 26047 26048 26049 26050 26051 26052 26053 26054 26055 26056 26057 26058 26059 26060 26061 26062 26063 26064 26065 26066 26067 26068 26069 26070 26071 26072 26073 26074 26075 26076 26077 26078 26079 26080 26081 26082 26083 26084 26085 26086 26087 26088 26089 26090 26091 26092 26093 26094 26095 26096 26097 26098 26099 26100 26101 26102 26103 26104 26105 26106 26107 26108 26109 26110 26111 26112 26113 26114 26115 26116 26117 26118 26119 26120 26121 26122 26123 26124 26125 26126 26127 26128 26129 26130 26131 26132 26133 26134 26135 26136 26137 26138 26139 26140 26141 26142 26143 26144 26145 26146 26147 26148 26149 26150 26151 26152 26153 26154 26155 26156 26157 26158 26159 26160 26161 26162 26163 26164 26165 26166 26167 26168 26169 26170 26171 26172 26173 26174 26175 26176 26177 26178 26179 26180 26181 26182 26183 26184 26185 26186 26187 26188 26189 26190 26191 26192 26193 26194 26195 26196 26197 26198 26199 26200 26201 26202 26203 26204 26205 26206 26207 26208 26209 26210 26211 26212 26213 26214 26215 26216 26217 26218 26219 26220 26221 26222 26223 26224 26225 26226 26227 26228 26229 26230 26231 26232 26233 26234 26235 26236 26237 26238 26239 26240 26241 26242 26243 26244 26245 26246 26247 26248 26249 26250 26251 26252 26253 26254 26255 26256 26257 26258 26259 26260 26261 26262 26263 26264 26265 26266 26267 26268 26269 26270 26271 26272 26273 26274 26275 26276 26277 26278 26279 26280 26281 26282 26283 26284 26285 26286 26287 26288 26289 26290 26291 26292 26293 26294 26295 26296 26297 26298 26299 26300 26301 26302 26303 26304 26305 26306 26307 26308 26309 26310 26311 26312 26313 26314 26315 26316 26317 26318 26319 26320 26321 26322 26323 26324 26325 26326 26327 26328 26329 26330 26331 26332 26333 26334 26335 26336 26337 26338 26339 26340 26341 26342 26343 26344 26345 26346 26347 26348 26349 26350 26351 26352 26353 26354 26355 26356 26357 26358 26359 26360 26361 26362 26363 26364 26365 26366 26367 26368 26369 26370 26371 26372 26373 26374 26375 26376 26377 26378 26379 26380 26381 26382 26383 26384 26385 26386 26387 26388 26389 26390 26391 26392 26393 26394 26395 26396 26397 26398 26399 26400 26401 26402 26403 26404 26405 26406 26407 26408 26409 26410 26411 26412 26413 26414 26415 26416 26417 26418 26419 26420 26421 26422 26423 26424 26425 26426 26427 26428 26429 26430 26431 26432 26433 26434 26435 26436 26437 26438 26439 26440 26441 26442 26443 26444 26445 26446 26447 26448 26449 26450 26451 26452 26453 26454 26455 26456 26457 26458 26459 26460 26461 26462 26463 26464 26465 26466 26467 26468 26469 26470 26471 26472 26473 26474 26475 26476 26477 26478 26479 26480 26481 26482 26483 26484 26485 26486 26487 26488 26489 26490 26491 26492 26493 26494 26495 26496 26497 26498 26499 26500 26501 26502 26503 26504 26505 26506 26507 26508 26509 26510 26511 26512 26513 26514 26515 26516 26517 26518 26519 26520 26521 26522 26523 26524 26525 26526 26527 26528 26529 26530 26531 26532 26533 26534 26535 26536 26537 26538 26539 26540 26541 26542 26543 26544 26545 26546 26547 26548 26549 26550 26551 26552 26553 26554 26555 26556 26557 26558 26559 26560 26561 26562 26563 26564 26565 26566 26567 26568 26569 26570 26571 26572 26573 26574 26575 26576 26577 26578 26579 26580 26581 26582 26583 26584 26585 26586 26587 26588 26589 26590 26591 26592 26593 26594 26595 26596 26597 26598 26599 26600 26601 26602 26603 26604 26605 26606 26607 26608 26609 26610 26611 26612 26613 26614 26615 26616 26617 26618 26619 26620 26621 26622 26623 26624 26625 26626 26627 26628 26629 26630 26631 26632 26633 26634 26635 26636 26637 26638 26639 26640 26641 26642 26643 26644 26645 26646 26647 26648 26649 26650 26651 26652 26653 26654 26655 26656 26657 26658 26659 26660 26661 26662 26663 26664 26665 26666 26667 26668 26669 26670 26671 26672 26673 26674 26675 26676 26677 26678 26679 26680 26681 26682 26683 26684 26685 26686 26687 26688 26689 26690 26691 26692 26693 26694 26695 26696 26697 26698 26699 26700 26701 26702 26703 26704 26705 26706 26707 26708 26709 26710 26711 26712 26713 26714 26715 26716 26717 26718 26719 26720 26721 26722 26723 26724 26725 26726 26727 26728 26729 26730 26731 26732 26733 26734 26735 26736 26737 26738 26739 26740 26741 26742 26743 26744 26745 26746 26747 26748 26749 26750 26751 26752 26753 26754 26755 26756 26757 26758 26759 26760 26761 26762 26763 26764 26765 26766 26767 26768 26769 26770 26771 26772 26773 26774 26775 26776 26777 26778 26779 26780 26781 26782 26783 26784 26785 26786 26787 26788 26789 26790 26791 26792 26793 26794 26795 26796 26797 26798 26799 26800 26801 26802 26803 26804 26805 26806 26807 26808 26809 26810 26811 26812 26813 26814 26815 26816 26817 26818 26819 26820 26821 26822 26823 26824 26825 26826 26827 26828 26829 26830 26831 26832 26833 26834 26835 26836 26837 26838 26839 26840 26841 26842 26843 26844 26845 26846 26847 26848 26849 26850 26851 26852 26853 26854 26855 26856 26857 26858 26859 26860 26861 26862 26863 26864 26865 26866 26867 26868 26869 26870 26871 26872 26873 26874 26875 26876 26877 26878 26879 26880 26881 26882 26883 26884 26885 26886 26887 26888 26889 26890 26891 26892 26893 26894 26895 26896 26897 26898 26899 26900 26901 26902 26903 26904 26905 26906 26907 26908 26909 26910 26911 26912 26913 26914 26915 26916 26917 26918 26919 26920 26921 26922 26923 26924 26925 26926 26927 26928 26929 26930 26931 26932 26933 26934 26935 26936 26937 26938 26939 26940 26941 26942 26943 26944 26945 26946 26947 26948 26949 26950 26951 26952 26953 26954 26955 26956 26957 26958 26959 26960 26961 26962 26963 26964 26965 26966 26967 26968 26969 26970 26971 26972 26973 26974 26975 26976 26977 26978 26979 26980 26981 26982 26983 26984 26985 26986 26987 26988 26989 26990 26991 26992 26993 26994 26995 26996 26997 26998 26999 27000 27001 27002 27003 27004 27005 27006 27007 27008 27009 27010 27011 27012 27013 27014 27015 27016 27017 27018 27019 27020 27021 27022 27023 27024 27025 27026 27027 27028 27029 27030 27031 27032 27033 27034 27035 27036 27037 27038 27039 27040 27041 27042 27043 27044 27045 27046 27047 27048 27049 27050 27051 27052 27053 27054 27055 27056 27057 27058 27059 27060 27061 27062 27063 27064 27065 27066 27067 27068 27069 27070 27071 27072 27073 27074 27075 27076 27077 27078 27079 27080 27081 27082 27083 27084 27085 27086 27087 27088 27089 27090 27091 27092 27093 27094 27095 27096 27097 27098 27099 27100 27101 27102 27103 27104 27105 27106 27107 27108 27109 27110 27111 27112 27113 27114 27115 27116 27117 27118 27119 27120 27121 27122 27123 27124 27125 27126 27127 27128 27129 27130 27131 27132 27133 27134 27135 27136 27137 27138 27139 27140 27141 27142 27143 27144 27145 27146 27147 27148 27149 27150 27151 27152 27153 27154 27155 27156 27157 27158 27159 27160 27161 27162 27163 27164 27165 27166 27167 27168 27169 27170 27171 27172 27173 27174 27175 27176 27177 27178 27179 27180 27181 27182 27183 27184 27185 27186 27187 27188 27189 27190 27191 27192 27193 27194 27195 27196 27197 27198 27199 27200 27201 27202 27203 27204 27205 27206 27207 27208 27209 27210 27211 27212 27213 27214 27215 27216 27217 27218 27219 27220 27221 27222 27223 27224 27225 27226 27227 27228 27229 27230 27231 27232 27233 27234 27235 27236 27237 27238 27239 27240 27241 27242 27243 27244 27245 27246 27247 27248 27249 27250 27251 27252 27253 27254 27255 27256 27257 27258 27259 27260 27261 27262 27263 27264 27265 27266 27267 27268 27269 27270 27271 27272 27273 27274 27275 27276 27277 27278 27279 27280 27281 27282 27283 27284 27285 27286 27287 27288 27289 27290 27291 27292 27293 27294 27295 27296 27297 27298 27299 27300 27301 27302 27303 27304 27305 27306 27307 27308 27309 27310 27311 27312 27313 27314 27315 27316 27317 27318 27319 27320 27321 27322 27323 27324 27325 27326 27327 27328 27329 27330 27331 27332 27333 27334 27335 27336 27337 27338 27339 27340 27341 27342 27343 27344 27345 27346 27347 27348 27349 27350 27351 27352 27353 27354 27355 27356 27357 27358 27359 27360 27361 27362 27363 27364 27365 27366 27367 27368 27369 27370 27371 27372 27373 27374 27375 27376 27377 27378 27379 27380 27381 27382 27383 27384 27385 27386 27387 27388 27389 27390 27391 27392 27393 27394 27395 27396 27397 27398 27399 27400 27401 27402 27403 27404 27405 27406 27407 27408 27409 27410 27411 27412 27413 27414 27415 27416 27417 27418 27419 27420 27421 27422 27423 27424 27425 27426 27427 27428 27429 27430 27431 27432 27433 27434 27435 27436 27437 27438 27439 27440 27441 27442 27443 27444 27445 27446 27447 27448 27449 27450 27451 27452 27453 27454 27455 27456 27457 27458 27459 27460 27461 27462 27463 27464 27465 27466 27467 27468 27469 27470 27471 27472 27473 27474 27475 27476 27477 27478 27479 27480 27481 27482 27483 27484 27485 27486 27487 27488 27489 27490 27491 27492 27493 27494 27495 27496 27497 27498 27499 27500 27501 27502 27503 27504 27505 27506 27507 27508 27509 27510 27511 27512 27513 27514 27515 27516 27517 27518 27519 27520 27521 27522 27523 27524 27525 27526 27527 27528 27529 27530 27531 27532 27533 27534 27535 27536 27537 27538 27539 27540 27541 27542 27543 27544 27545 27546 27547 27548 27549 27550 27551 27552 27553 27554 27555 27556 27557 27558 27559 27560 27561 27562 27563 27564 27565 27566 27567 27568 27569 27570 27571 27572 27573 27574 27575 27576 27577 27578 27579 27580 27581 27582 27583 27584 27585 27586 27587 27588 27589 27590 27591 27592 27593 27594 27595 27596 27597 27598 27599 27600 27601 27602 27603 27604 27605 27606 27607 27608 27609 27610 27611 27612 27613 27614 27615 27616 27617 27618 27619 27620 27621 27622 27623 27624 27625 27626 27627 27628 27629 27630 27631 27632 27633 27634 27635 27636 27637 27638 27639 27640 27641 27642 27643 27644 27645 27646 27647 27648 27649 27650 27651 27652 27653 27654 27655 27656 27657 27658 27659 27660 27661 27662 27663 27664 27665 27666 27667 27668 27669 27670 27671 27672 27673 27674 27675 27676 27677 27678 27679 27680 27681 27682 27683 27684 27685 27686 27687 27688 27689 27690 27691 27692 27693 27694 27695 27696 27697 27698 27699 27700 27701 27702 27703 27704 27705 27706 27707 27708 27709 27710 27711 27712 27713 27714 27715 27716 27717 27718 27719 27720 27721 27722 27723 27724 27725 27726 27727 27728 27729 27730 27731 27732 27733 27734 27735 27736 27737 27738 27739 27740 27741 27742 27743 27744 27745 27746 27747 27748 27749 27750 27751 27752 27753 27754 27755 27756 27757 27758 27759 27760 27761 27762 27763 27764 27765 27766 27767 27768 27769 27770 27771 27772 27773 27774 27775 27776 27777 27778 27779 27780 27781 27782 27783 27784 27785 27786 27787 27788 27789 27790 27791 27792 27793 27794 27795 27796 27797 27798 27799 27800 27801 27802 27803 27804 27805 27806 27807 27808 27809 27810 27811 27812 27813 27814 27815 27816 27817 27818 27819 27820 27821 27822 27823 27824 27825 27826 27827 27828 27829 27830 27831 27832 27833 27834 27835 27836 27837 27838 27839 27840 27841 27842 27843 27844 27845 27846 27847 27848 27849 27850 27851 27852 27853 27854 27855 27856 27857 27858 27859 27860 27861 27862 27863 27864 27865 27866 27867 27868 27869 27870 27871 27872 27873 27874 27875 27876 27877 27878 27879 27880 27881 27882 27883 27884 27885 27886 27887 27888 27889 27890 27891 27892 27893 27894 27895 27896 27897 27898 27899 27900 27901 27902 27903 27904 27905 27906 27907 27908 27909 27910 27911 27912 27913 27914 27915 27916 27917 27918 27919 27920 27921 27922 27923 27924 27925 27926 27927 27928 27929 27930 27931 27932 27933 27934 27935 27936 27937 27938 27939 27940 27941 27942 27943 27944 27945 27946 27947 27948 27949 27950 27951 27952 27953 27954 27955 27956 27957 27958 27959 27960 27961 27962 27963 27964 27965 27966 27967 27968 27969 27970 27971 27972 27973 27974 27975 27976 27977 27978 27979 27980 27981 27982 27983 27984 27985 27986 27987 27988 27989 27990 27991 27992 27993 27994 27995 27996 27997 27998 27999 28000 28001 28002 28003 28004 28005 28006 28007 28008 28009 28010 28011 28012 28013 28014 28015 28016 28017 28018 28019 28020 28021 28022 28023 28024 28025 28026 28027 28028 28029 28030 28031 28032 28033 28034 28035 28036 28037 28038 28039 28040 28041 28042 28043 28044 28045 28046 28047 28048 28049 28050 28051 28052 28053 28054 28055 28056 28057 28058 28059 28060 28061 28062 28063 28064 28065 28066 28067 28068 28069 28070 28071 28072 28073 28074 28075 28076 28077 28078 28079 28080 28081 28082 28083 28084 28085 28086 28087 28088 28089 28090 28091 28092 28093 28094 28095 28096 28097 28098 28099 28100 28101 28102 28103 28104 28105 28106 28107 28108 28109 28110 28111 28112 28113 28114 28115 28116 28117 28118 28119 28120 28121 28122 28123 28124 28125 28126 28127 28128 28129 28130 28131 28132 28133 28134 28135 28136 28137 28138 28139 28140 28141 28142 28143 28144 28145 28146 28147 28148 28149 28150 28151 28152 28153 28154 28155 28156 28157 28158 28159 28160 28161 28162 28163 28164 28165 28166 28167 28168 28169 28170 28171 28172 28173 28174 28175 28176 28177 28178 28179 28180 28181 28182 28183 28184 28185 28186 28187 28188 28189 28190 28191 28192 28193 28194 28195 28196 28197 28198 28199 28200 28201 28202 28203 28204 28205 28206 28207 28208 28209 28210 28211 28212 28213 28214 28215 28216 28217 28218 28219 28220 28221 28222 28223 28224 28225 28226 28227 28228 28229 28230 28231 28232 28233 28234 28235 28236 28237 28238 28239 28240 28241 28242 28243 28244 28245 28246 28247 28248 28249 28250 28251 28252 28253 28254 28255 28256 28257 28258 28259 28260 28261 28262 28263 28264 28265 28266 28267 28268 28269 28270 28271 28272 28273 28274 28275 28276 28277 28278 28279 28280 28281 28282 28283 28284 28285 28286 28287 28288 28289 28290 28291 28292 28293 28294 28295 28296 28297 28298 28299 28300 28301 28302 28303 28304 28305 28306 28307 28308 28309 28310 28311 28312 28313 28314 28315 28316 28317 28318 28319 28320 28321 28322 28323 28324 28325 28326 28327 28328 28329 28330 28331 28332 28333 28334 28335 28336 28337 28338 28339 28340 28341 28342 28343 28344 28345 28346 28347 28348 28349 28350 28351 28352 28353 28354 28355 28356 28357 28358 28359 28360 28361 28362 28363 28364 28365 28366 28367 28368 28369 28370 28371 28372 28373 28374 28375 28376 28377 28378 28379 28380 28381 28382 28383 28384 28385 28386 28387 28388 28389 28390 28391 28392 28393 28394 28395 28396 28397 28398 28399 28400 28401 28402 28403 28404 28405 28406 28407 28408 28409 28410 28411 28412 28413 28414 28415 28416 28417 28418 28419 28420 28421 28422 28423 28424 28425 28426 28427 28428 28429 28430 28431 28432 28433 28434 28435 28436 28437 28438 28439 28440 28441 28442 28443 28444 28445 28446 28447 28448 28449 28450 28451 28452 28453 28454 28455 28456 28457 28458 28459 28460 28461 28462 28463 28464 28465 28466 28467 28468 28469 28470 28471 28472 28473 28474 28475 28476 28477 28478 28479 28480 28481 28482 28483 28484 28485 28486 28487 28488 28489 28490 28491 28492 28493 28494 28495 28496 28497 28498 28499 28500 28501 28502 28503 28504 28505 28506 28507 28508 28509 28510 28511 28512 28513 28514 28515 28516 28517 28518 28519 28520 28521 28522 28523 28524 28525 28526 28527 28528 28529 28530 28531 28532 28533 28534 28535 28536 28537 28538 28539 28540 28541 28542 28543 28544 28545 28546 28547 28548 28549 28550 28551 28552 28553 28554 28555 28556 28557 28558 28559 28560 28561 28562 28563 28564 28565 28566 28567 28568 28569 28570 28571 28572 28573 28574 28575 28576 28577 28578 28579 28580 28581 28582 28583 28584 28585 28586 28587 28588 28589 28590 28591 28592 28593 28594 28595 28596 28597 28598 28599 28600 28601 28602 28603 28604 28605 28606 28607 28608 28609 28610 28611 28612 28613 28614 28615 28616 28617 28618 28619 28620 28621 28622 28623 28624 28625 28626 28627 28628 28629 28630 28631 28632 28633 28634 28635 28636 28637 28638 28639 28640 28641 28642 28643 28644 28645 28646 28647 28648 28649 28650 28651 28652 28653 28654 28655 28656 28657 28658 28659 28660 28661 28662 28663 28664 28665 28666 28667 28668 28669 28670 28671 28672 28673 28674 28675 28676 28677 28678 28679 28680 28681 28682 28683 28684 28685 28686 28687 28688 28689 28690 28691 28692 28693 28694 28695 28696 28697 28698 28699 28700 28701 28702 28703 28704 28705 28706 28707 28708 28709 28710 28711 28712 28713 28714 28715 28716 28717 28718 28719 28720 28721 28722 28723 28724 28725 28726 28727 28728 28729 28730 28731 28732 28733 28734 28735 28736 28737 28738 28739 28740 28741 28742 28743 28744 28745 28746 28747 28748 28749 28750 28751 28752 28753 28754 28755 28756 28757 28758 28759 28760 28761 28762 28763 28764 28765 28766 28767 28768 28769 28770 28771 28772 28773 28774 28775 28776 28777 28778 28779 28780 28781 28782 28783 28784 28785 28786 28787 28788 28789 28790 28791 28792 28793 28794 28795 28796 28797 28798 28799 28800 28801 28802 28803 28804 28805 28806 28807 28808 28809 28810 28811 28812 28813 28814 28815 28816 28817 28818 28819 28820 28821 28822 28823 28824 28825 28826 28827 28828 28829 28830 28831 28832 28833 28834 28835 28836 28837 28838 28839 28840 28841 28842 28843 28844 28845 28846 28847 28848 28849 28850 28851 28852 28853 28854 28855 28856 28857 28858 28859 28860 28861 28862 28863 28864 28865 28866 28867 28868 28869 28870 28871 28872 28873 28874 28875 28876 28877 28878 28879 28880 28881 28882 28883 28884 28885 28886 28887 28888 28889 28890 28891 28892 28893 28894 28895 28896 28897 28898 28899 28900 28901 28902 28903 28904 28905 28906 28907 28908 28909 28910 28911 28912 28913 28914 28915 28916 28917 28918 28919 28920 28921 28922 28923 28924 28925 28926 28927 28928 28929 28930 28931 28932 28933 28934 28935 28936 28937 28938 28939 28940 28941 28942 28943 28944 28945 28946 28947 28948 28949 28950 28951 28952 28953 28954 28955 28956 28957 28958 28959 28960 28961 28962 28963 28964 28965 28966 28967 28968 28969 28970 28971 28972 28973 28974 28975 28976 28977 28978 28979 28980 28981 28982 28983 28984 28985 28986 28987 28988 28989 28990 28991 28992 28993 28994 28995 28996 28997 28998 28999 29000 29001 29002 29003 29004 29005 29006 29007 29008 29009 29010 29011 29012 29013 29014 29015 29016 29017 29018 29019 29020 29021 29022 29023 29024 29025 29026 29027 29028 29029 29030 29031 29032 29033 29034 29035 29036 29037 29038 29039 29040 29041 29042 29043 29044 29045 29046 29047 29048 29049 29050 29051 29052 29053 29054 29055 29056 29057 29058 29059 29060 29061 29062 29063 29064 29065 29066 29067 29068 29069 29070 29071 29072 29073 29074 29075 29076 29077 29078 29079 29080 29081 29082 29083 29084 29085 29086 29087 29088 29089 29090 29091 29092 29093 29094 29095 29096 29097 29098 29099 29100 29101 29102 29103 29104 29105 29106 29107 29108 29109 29110 29111 29112 29113 29114 29115 29116 29117 29118 29119 29120 29121 29122 29123 29124 29125 29126 29127 29128 29129 29130 29131 29132 29133 29134 29135 29136 29137 29138 29139 29140 29141 29142 29143 29144 29145 29146 29147 29148 29149 29150 29151 29152 29153 29154 29155 29156 29157 29158 29159 29160 29161 29162 29163 29164 29165 29166 29167 29168 29169 29170 29171 29172 29173 29174 29175 29176 29177 29178 29179 29180 29181 29182 29183 29184 29185 29186 29187 29188 29189 29190 29191 29192 29193 29194 29195 29196 29197 29198 29199 29200 29201 29202 29203 29204 29205 29206 29207 29208 29209 29210 29211 29212 29213 29214 29215 29216 29217 29218 29219 29220 29221 29222 29223 29224 29225 29226 29227 29228 29229 29230 29231 29232 29233 29234 29235 29236 29237 29238 29239 29240 29241 29242 29243 29244 29245 29246 29247 29248 29249 29250 29251 29252 29253 29254 29255 29256 29257 29258 29259 29260 29261 29262 29263 29264 29265 29266 29267 29268 29269 29270 29271 29272 29273 29274 29275 29276 29277 29278 29279 29280 29281 29282 29283 29284 29285 29286 29287 29288 29289 29290 29291 29292 29293 29294 29295 29296 29297 29298 29299 29300 29301 29302 29303 29304 29305 29306 29307 29308 29309 29310 29311 29312 29313 29314 29315 29316 29317 29318 29319 29320 29321 29322 29323 29324 29325 29326 29327 29328 29329 29330 29331 29332 29333 29334 29335 29336 29337 29338 29339 29340 29341 29342 29343 29344 29345 29346 29347 29348 29349 29350 29351 29352 29353 29354 29355 29356 29357 29358 29359 29360 29361 29362 29363 29364 29365 29366 29367 29368 29369 29370 29371 29372 29373 29374 29375 29376 29377 29378 29379 29380 29381 29382 29383 29384 29385 29386 29387 29388 29389 29390 29391 29392 29393 29394 29395 29396 29397 29398 29399 29400 29401 29402 29403 29404 29405 29406 29407 29408 29409 29410 29411 29412 29413 29414 29415 29416 29417 29418 29419 29420 29421 29422 29423 29424 29425 29426 29427 29428 29429 29430 29431 29432 29433 29434 29435 29436 29437 29438 29439 29440 29441 29442 29443 29444 29445 29446 29447 29448 29449 29450 29451 29452 29453 29454 29455 29456 29457 29458 29459 29460 29461 29462 29463 29464 29465 29466 29467 29468 29469 29470 29471 29472 29473 29474 29475 29476 29477 29478 29479 29480 29481 29482 29483 29484 29485 29486 29487 29488 29489 29490 29491 29492 29493 29494 29495 29496 29497 29498 29499 29500 29501 29502 29503 29504 29505 29506 29507 29508 29509 29510 29511 29512 29513 29514 29515 29516 29517 29518 29519 29520 29521 29522 29523 29524 29525 29526 29527 29528 29529 29530 29531 29532 29533 29534 29535 29536 29537 29538 29539 29540 29541 29542 29543 29544 29545 29546 29547 29548 29549 29550 29551 29552 29553 29554 29555 29556 29557 29558 29559 29560 29561 29562 29563 29564 29565 29566 29567 29568 29569 29570 29571 29572 29573 29574 29575 29576 29577 29578 29579 29580 29581 29582 29583 29584 29585 29586 29587 29588 29589 29590 29591 29592 29593 29594 29595 29596 29597 29598 29599 29600 29601 29602 29603 29604 29605 29606 29607 29608 29609 29610 29611 29612 29613 29614 29615 29616 29617 29618 29619 29620 29621 29622 29623 29624 29625 29626 29627 29628 29629 29630 29631 29632 29633 29634 29635 29636 29637 29638 29639 29640 29641 29642 29643 29644 29645 29646 29647 29648 29649 29650 29651 29652 29653 29654 29655 29656 29657 29658 29659 29660 29661 29662 29663 29664 29665 29666 29667 29668 29669 29670 29671 29672 29673 29674 29675 29676 29677 29678 29679 29680 29681 29682 29683 29684 29685 29686 29687 29688 29689 29690 29691 29692 29693 29694 29695 29696 29697 29698 29699 29700 29701 29702 29703 29704 29705 29706 29707 29708 29709 29710 29711 29712 29713 29714 29715 29716 29717 29718 29719 29720 29721 29722 29723 29724 29725 29726 29727 29728 29729 29730 29731 29732 29733 29734 29735 29736 29737 29738 29739 29740 29741 29742 29743 29744 29745 29746 29747 29748 29749 29750 29751 29752 29753 29754 29755 29756 29757 29758 29759 29760 29761 29762 29763 29764 29765 29766 29767 29768 29769 29770 29771 29772 29773 29774 29775 29776 29777 29778 29779 29780 29781 29782 29783 29784 29785 29786 29787 29788 29789 29790 29791 29792 29793 29794 29795 29796 29797 29798 29799 29800 29801 29802 29803 29804 29805 29806 29807 29808 29809 29810 29811 29812 29813 29814 29815 29816 29817 29818 29819 29820 29821 29822 29823 29824 29825 29826 29827 29828 29829 29830 29831 29832 29833 29834 29835 29836 29837 29838 29839 29840 29841 29842 29843 29844 29845 29846 29847 29848 29849 29850 29851 29852 29853 29854 29855 29856 29857 29858 29859 29860 29861 29862 29863 29864 29865 29866 29867 29868 29869 29870 29871 29872 29873 29874 29875 29876 29877 29878 29879 29880 29881 29882 29883 29884 29885 29886 29887 29888 29889 29890 29891 29892 29893 29894 29895 29896 29897 29898 29899 29900 29901 29902 29903 29904 29905 29906 29907 29908 29909 29910 29911 29912 29913 29914 29915 29916 29917 29918 29919 29920 29921 29922 29923 29924 29925 29926 29927 29928 29929 29930 29931 29932 29933 29934 29935 29936 29937 29938 29939 29940 29941 29942 29943 29944 29945 29946 29947 29948 29949 29950 29951 29952 29953 29954 29955 29956 29957 29958 29959 29960 29961 29962 29963 29964 29965 29966 29967 29968 29969 29970 29971 29972 29973 29974 29975 29976 29977 29978 29979 29980 29981 29982 29983 29984 29985 29986 29987 29988 29989 29990 29991 29992 29993 29994 29995 29996 29997 29998 29999 30000 30001 30002 30003 30004 30005 30006 30007 30008 30009 30010 30011 30012 30013 30014 30015 30016 30017 30018 30019 30020 30021 30022 30023 30024 30025 30026 30027 30028 30029 30030 30031 30032 30033 30034 30035 30036 30037 30038 30039 30040 30041 30042 30043 30044 30045 30046 30047 30048 30049 30050 30051 30052 30053 30054 30055 30056 30057 30058 30059 30060 30061 30062 30063 30064 30065 30066 30067 30068 30069 30070 30071 30072 30073 30074 30075 30076 30077 30078 30079 30080 30081 30082 30083 30084 30085 30086 30087 30088 30089 30090 30091 30092 30093 30094 30095 30096 30097 30098 30099 30100 30101 30102 30103 30104 30105 30106 30107 30108 30109 30110 30111 30112 30113 30114 30115 30116 30117 30118 30119 30120 30121 30122 30123 30124 30125 30126 30127 30128 30129 30130 30131 30132 30133 30134 30135 30136 30137 30138 30139 30140 30141 30142 30143 30144 30145 30146 30147 30148 30149 30150 30151 30152 30153 30154 30155 30156 30157 30158 30159 30160 30161 30162 30163 30164 30165 30166 30167 30168 30169 30170 30171 30172 30173 30174 30175 30176 30177 30178 30179 30180 30181 30182 30183 30184 30185 30186 30187 30188 30189 30190 30191 30192 30193 30194 30195 30196 30197 30198 30199 30200 30201 30202 30203 30204 30205 30206 30207 30208 30209 30210 30211 30212 30213 30214 30215 30216 30217 30218 30219 30220 30221 30222 30223 30224 30225 30226 30227 30228 30229 30230 30231 30232 30233 30234 30235 30236 30237 30238 30239 30240 30241 30242 30243 30244 30245 30246 30247 30248 30249 30250 30251 30252 30253 30254 30255 30256 30257 30258 30259 30260 30261 30262 30263 30264 30265 30266 30267 30268 30269 30270 30271 30272 30273 30274 30275 30276 30277 30278 30279 30280 30281 30282 30283 30284 30285 30286 30287 30288 30289 30290 30291 30292 30293 30294 30295 30296 30297 30298 30299 30300 30301 30302 30303 30304 30305 30306 30307 30308 30309 30310 30311 30312 30313 30314 30315 30316 30317 30318 30319 30320 30321 30322 30323 30324 30325 30326 30327 30328 30329 30330 30331 30332 30333 30334 30335 30336 30337 30338 30339 30340 30341 30342 30343 30344 30345 30346 30347 30348 30349 30350 30351 30352 30353 30354 30355 30356 30357 30358 30359 30360 30361 30362 30363 30364 30365 30366 30367 30368 30369 30370 30371 30372 30373 30374 30375 30376 30377 30378 30379 30380 30381 30382 30383 30384 30385 30386 30387 30388 30389 30390 30391 30392 30393 30394 30395 30396 30397 30398 30399 30400 30401 30402 30403 30404 30405 30406 30407 30408 30409 30410 30411 30412 30413 30414 30415 30416 30417 30418 30419 30420 30421 30422 30423 30424 30425 30426 30427 30428 30429 30430 30431 30432 30433 30434 30435 30436 30437 30438 30439 30440 30441 30442 30443 30444 30445 30446 30447 30448 30449 30450 30451 30452 30453 30454 30455 30456 30457 30458 30459 30460 30461 30462 30463 30464 30465 30466 30467 30468 30469 30470 30471 30472 30473 30474 30475 30476 30477 30478 30479 30480 30481 30482 30483 30484 30485 30486 30487 30488 30489 30490 30491 30492 30493 30494 30495 30496 30497 30498 30499 30500 30501 30502 30503 30504 30505 30506 30507 30508 30509 30510 30511 30512 30513 30514 30515 30516 30517 30518 30519 30520 30521 30522 30523 30524 30525 30526 30527 30528 30529 30530 30531 30532 30533 30534 30535 30536 30537 30538 30539 30540 30541 30542 30543 30544 30545 30546 30547 30548 30549 30550 30551 30552 30553 30554 30555 30556 30557 30558 30559 30560 30561 30562 30563 30564 30565 30566 30567 30568 30569 30570 30571 30572 30573 30574 30575 30576 30577 30578 30579 30580 30581 30582 30583 30584 30585 30586 30587 30588 30589 30590 30591 30592 30593 30594 30595 30596 30597 30598 30599 30600 30601 30602 30603 30604 30605 30606 30607 30608 30609 30610 30611 30612 30613 30614 30615 30616 30617 30618 30619 30620 30621 30622 30623 30624 30625 30626 30627 30628 30629 30630 30631 30632 30633 30634 30635 30636 30637 30638 30639 30640 30641 30642 30643 30644 30645 30646 30647 30648 30649 30650 30651 30652 30653 30654 30655 30656 30657 30658 30659 30660 30661 30662 30663 30664 30665 30666 30667 30668 30669 30670 30671 30672 30673 30674 30675 30676 30677 30678 30679 30680 30681 30682 30683 30684 30685 30686 30687 30688 30689 30690 30691 30692 30693 30694 30695 30696 30697 30698 30699 30700 30701 30702 30703 30704 30705 30706 30707 30708 30709 30710 30711 30712 30713 30714 30715 30716 30717 30718 30719 30720 30721 30722 30723 30724 30725 30726 30727 30728 30729 30730 30731 30732 30733 30734 30735 30736 30737 30738 30739 30740 30741 30742 30743 30744 30745 30746 30747 30748 30749 30750 30751 30752 30753 30754 30755 30756 30757 30758 30759 30760 30761 30762 30763 30764 30765 30766 30767 30768 30769 30770 30771 30772 30773 30774 30775 30776 30777 30778 30779 30780 30781 30782 30783 30784 30785 30786 30787 30788 30789 30790 30791 30792 30793 30794 30795 30796 30797 30798 30799 30800 30801 30802 30803 30804 30805 30806 30807 30808 30809 30810 30811 30812 30813 30814 30815 30816 30817 30818 30819 30820 30821 30822 30823 30824 30825 30826 30827 30828 30829 30830 30831 30832 30833 30834 30835 30836 30837 30838 30839 30840 30841 30842 30843 30844 30845 30846 30847 30848 30849 30850 30851 30852 30853 30854 30855 30856 30857 30858 30859 30860 30861 30862 30863 30864 30865 30866 30867 30868 30869 30870 30871 30872 30873 30874 30875 30876 30877 30878 30879 30880 30881 30882 30883 30884 30885 30886 30887 30888 30889 30890 30891 30892 30893 30894 30895 30896 30897 30898 30899 30900 30901 30902 30903 30904 30905 30906 30907 30908 30909 30910 30911 30912 30913 30914 30915 30916 30917 30918 30919 30920 30921 30922 30923 30924 30925 30926 30927 30928 30929 30930 30931 30932 30933 30934 30935 30936 30937 30938 30939 30940 30941 30942 30943 30944 30945 30946 30947 30948 30949 30950 30951 30952 30953 30954 30955 30956 30957 30958 30959 30960 30961 30962 30963 30964 30965 30966 30967 30968 30969 30970 30971 30972 30973 30974 30975 30976 30977 30978 30979 30980 30981 30982 30983 30984 30985 30986 30987 30988 30989 30990 30991 30992 30993 30994 30995 30996 30997 30998 30999 31000 31001 31002 31003 31004 31005 31006 31007 31008 31009 31010 31011 31012 31013 31014 31015 31016 31017 31018 31019 31020 31021 31022 31023 31024 31025 31026 31027 31028 31029 31030 31031 31032 31033 31034 31035 31036 31037 31038 31039 31040 31041 31042 31043 31044 31045 31046 31047 31048 31049 31050 31051 31052 31053 31054 31055 31056 31057 31058 31059 31060 31061 31062 31063 31064 31065 31066 31067 31068 31069 31070 31071 31072 31073 31074 31075 31076 31077 31078 31079 31080 31081 31082 31083 31084 31085 31086 31087 31088 31089 31090 31091 31092 31093 31094 31095 31096 31097 31098 31099 31100 31101 31102 31103 31104 31105 31106 31107 31108 31109 31110 31111 31112 31113 31114 31115 31116 31117 31118 31119 31120 31121 31122 31123 31124 31125 31126 31127 31128 31129 31130 31131 31132 31133 31134 31135 31136 31137 31138 31139 31140 31141 31142 31143 31144 31145 31146 31147 31148 31149 31150 31151 31152 31153 31154 31155 31156 31157 31158 31159 31160 31161 31162 31163 31164 31165 31166 31167 31168 31169 31170 31171 31172 31173 31174 31175 31176 31177 31178 31179 31180 31181 31182 31183 31184 31185 31186 31187 31188 31189 31190 31191 31192 31193 31194 31195 31196 31197 31198 31199 31200 31201 31202 31203 31204 31205 31206 31207 31208 31209 31210 31211 31212 31213 31214 31215 31216 31217 31218 31219 31220 31221 31222 31223 31224 31225 31226 31227 31228 31229 31230 31231 31232 31233 31234 31235 31236 31237 31238 31239 31240 31241 31242 31243 31244 31245 31246 31247 31248 31249 31250 31251 31252 31253 31254 31255 31256 31257 31258 31259 31260 31261 31262 31263 31264 31265 31266 31267 31268 31269 31270 31271 31272 31273 31274 31275 31276 31277 31278 31279 31280 31281 31282 31283 31284 31285 31286 31287 31288 31289 31290 31291 31292 31293 31294 31295 31296 31297 31298 31299 31300 31301 31302 31303 31304 31305 31306 31307 31308 31309 31310 31311 31312 31313 31314 31315 31316 31317 31318 31319 31320 31321 31322 31323 31324 31325 31326 31327 31328 31329 31330 31331 31332 31333 31334 31335 31336 31337 31338 31339 31340 31341 31342 31343 31344 31345 31346 31347 31348 31349 31350 31351 31352 31353 31354 31355 31356 31357 31358 31359 31360 31361 31362 31363 31364 31365 31366 31367 31368 31369 31370 31371 31372 31373 31374 31375 31376 31377 31378 31379 31380 31381 31382 31383 31384 31385 31386 31387 31388 31389 31390 31391 31392 31393 31394 31395 31396 31397 31398 31399 31400 31401 31402 31403 31404 31405 31406 31407 31408 31409 31410 31411 31412 31413 31414 31415 31416 31417 31418 31419 31420 31421 31422 31423 31424 31425 31426 31427 31428 31429 31430 31431 31432 31433 31434 31435 31436 31437 31438 31439 31440 31441 31442 31443 31444 31445 31446 31447 31448 31449 31450 31451 31452 31453 31454 31455 31456 31457 31458 31459 31460 31461 31462 31463 31464 31465 31466 31467 31468 31469 31470 31471 31472 31473 31474 31475 31476 31477 31478 31479 31480 31481 31482 31483 31484 31485 31486 31487 31488 31489 31490 31491 31492 31493 31494 31495 31496 31497 31498 31499 31500 31501 31502 31503 31504 31505 31506 31507 31508 31509 31510 31511 31512 31513 31514 31515 31516 31517 31518 31519 31520 31521 31522 31523 31524 31525 31526 31527 31528 31529 31530 31531 31532 31533 31534 31535 31536 31537 31538 31539 31540 31541 31542 31543 31544 31545 31546 31547 31548 31549 31550 31551 31552 31553 31554 31555 31556 31557 31558 31559 31560 31561 31562 31563 31564 31565 31566 31567 31568 31569 31570 31571 31572 31573 31574 31575 31576 31577 31578 31579 31580 31581 31582 31583 31584 31585 31586 31587 31588 31589 31590 31591 31592 31593 31594 31595 31596 31597 31598 31599 31600 31601 31602 31603 31604 31605 31606 31607 31608 31609 31610 31611 31612 31613 31614 31615 31616 31617 31618 31619 31620 31621 31622 31623 31624 31625 31626 31627 31628 31629 31630 31631 31632 31633 31634 31635 31636 31637 31638 31639 31640 31641 31642 31643 31644 31645 31646 31647 31648 31649 31650 31651 31652 31653 31654 31655 31656 31657 31658 31659 31660 31661 31662 31663 31664 31665 31666 31667 31668 31669 31670 31671 31672 31673 31674 31675 31676 31677 31678 31679 31680 31681 31682 31683 31684 31685 31686 31687 31688 31689 31690 31691 31692 31693 31694 31695 31696 31697 31698 31699 31700 31701 31702 31703 31704 31705 31706 31707 31708 31709 31710 31711 31712 31713 31714 31715 31716 31717 31718 31719 31720 31721 31722 31723 31724 31725 31726 31727 31728 31729 31730 31731 31732 31733 31734 31735 31736 31737 31738 31739 31740 31741 31742 31743 31744 31745 31746 31747 31748 31749 31750 31751 31752 31753 31754 31755 31756 31757 31758 31759 31760 31761 31762 31763 31764 31765 31766 31767 31768 31769 31770 31771 31772 31773 31774 31775 31776 31777 31778 31779 31780 31781 31782 31783 31784 31785 31786 31787 31788 31789 31790 31791 31792 31793 31794 31795 31796 31797 31798 31799 31800 31801 31802 31803 31804 31805 31806 31807 31808 31809 31810 31811 31812 31813 31814 31815 31816 31817 31818 31819 31820 31821 31822 31823 31824 31825 31826 31827 31828 31829 31830 31831 31832 31833 31834 31835 31836 31837 31838 31839 31840 31841 31842 31843 31844 31845 31846 31847 31848 31849 31850 31851 31852 31853 31854 31855 31856 31857 31858 31859 31860 31861 31862 31863 31864 31865 31866 31867 31868 31869 31870 31871 31872 31873 31874 31875 31876 31877 31878 31879 31880 31881 31882 31883 31884 31885 31886 31887 31888 31889 31890 31891 31892 31893 31894 31895 31896 31897 31898 31899 31900 31901 31902 31903 31904 31905 31906 31907 31908 31909 31910 31911 31912 31913 31914 31915 31916 31917 31918 31919 31920 31921 31922 31923 31924 31925 31926 31927 31928 31929 31930 31931 31932 31933 31934 31935 31936 31937 31938 31939 31940 31941 31942 31943 31944 31945 31946 31947 31948 31949 31950 31951 31952 31953 31954 31955 31956 31957 31958 31959 31960 31961 31962 31963 31964 31965 31966 31967 31968 31969 31970 31971 31972 31973 31974 31975 31976 31977 31978 31979 31980 31981 31982 31983 31984 31985 31986 31987 31988 31989 31990 31991 31992 31993 31994 31995 31996 31997 31998 31999 32000 32001 32002 32003 32004 32005 32006 32007 32008 32009 32010 32011 32012 32013 32014 32015 32016 32017 32018 32019 32020 32021 32022 32023 32024 32025 32026 32027 32028 32029 32030 32031 32032 32033 32034 32035 32036 32037 32038 32039 32040 32041 32042 32043 32044 32045 32046 32047 32048 32049 32050 32051 32052 32053 32054 32055 32056 32057 32058 32059 32060 32061 32062 32063 32064 32065 32066 32067 32068 32069 32070 32071 32072 32073 32074 32075 32076 32077 32078 32079 32080 32081 32082 32083 32084 32085 32086 32087 32088 32089 32090 32091 32092 32093 32094 32095 32096 32097 32098 32099 32100 32101 32102 32103 32104 32105 32106 32107 32108 32109 32110 32111 32112 32113 32114 32115 32116 32117 32118 32119 32120 32121 32122 32123 32124 32125 32126 32127 32128 32129 32130 32131 32132 32133 32134 32135 32136 32137 32138 32139 32140 32141 32142 32143 32144 32145 32146 32147 32148 32149 32150 32151 32152 32153 32154 32155 32156 32157 32158 32159 32160 32161 32162 32163 32164 32165 32166 32167 32168 32169 32170 32171 32172 32173 32174 32175 32176 32177 32178 32179 32180 32181 32182 32183 32184 32185 32186 32187 32188 32189 32190 32191 32192 32193 32194 32195 32196 32197 32198 32199 32200 32201 32202 32203 32204 32205 32206 32207 32208 32209 32210 32211 32212 32213 32214 32215 32216 32217 32218 32219 32220 32221 32222 32223 32224 32225 32226 32227 32228 32229 32230 32231 32232 32233 32234 32235 32236 32237 32238 32239 32240 32241 32242 32243 32244 32245 32246 32247 32248 32249 32250 32251 32252 32253 32254 32255 32256 32257 32258 32259 32260 32261 32262 32263 32264 32265 32266 32267 32268 32269 32270 32271 32272 32273 32274 32275 32276 32277 32278 32279 32280 32281 32282 32283 32284 32285 32286 32287 32288 32289 32290 32291 32292 32293 32294 32295 32296 32297 32298 32299 32300 32301 32302 32303 32304 32305 32306 32307 32308 32309 32310 32311 32312 32313 32314 32315 32316 32317 32318 32319 32320 32321 32322 32323 32324 32325 32326 32327 32328 32329 32330 32331 32332 32333 32334 32335 32336 32337 32338 32339 32340 32341 32342 32343 32344 32345 32346 32347 32348 32349 32350 32351 32352 32353 32354 32355 32356 32357 32358 32359 32360 32361 32362 32363 32364 32365 32366 32367 32368 32369 32370 32371 32372 32373 32374 32375 32376 32377 32378 32379 32380 32381 32382 32383 32384 32385 32386 32387 32388 32389 32390 32391 32392 32393 32394 32395 32396 32397 32398 32399 32400 32401 32402 32403 32404 32405 32406 32407 32408 32409 32410 32411 32412 32413 32414 32415 32416 32417 32418 32419 32420 32421 32422 32423 32424 32425 32426 32427 32428 32429 32430 32431 32432 32433 32434 32435 32436 32437 32438 32439 32440 32441 32442 32443 32444 32445 32446 32447 32448 32449 32450 32451 32452 32453 32454 32455 32456 32457 32458 32459 32460 32461 32462 32463 32464 32465 32466 32467 32468 32469 32470 32471 32472 32473 32474 32475 32476 32477 32478 32479 32480 32481 32482 32483 32484 32485 32486 32487 32488 32489 32490 32491 32492 32493 32494 32495 32496 32497 32498 32499 32500 32501 32502 32503 32504 32505 32506 32507 32508 32509 32510 32511 32512 32513 32514 32515 32516 32517 32518 32519 32520 32521 32522 32523 32524 32525 32526 32527 32528 32529 32530 32531 32532 32533 32534 32535 32536 32537 32538 32539 32540 32541 32542 32543 32544 32545 32546 32547 32548 32549 32550 32551 32552 32553 32554 32555 32556 32557 32558 32559 32560 32561 32562 32563 32564 32565 32566 32567 32568 32569 32570 32571 32572 32573 32574 32575 32576 32577 32578 32579 32580 32581 32582 32583 32584 32585 32586 32587 32588 32589 32590 32591 32592 32593 32594 32595 32596 32597 32598 32599 32600 32601 32602 32603 32604 32605 32606 32607 32608 32609 32610 32611 32612 32613 32614 32615 32616 32617 32618 32619 32620 32621 32622 32623 32624 32625 32626 32627 32628 32629 32630 32631 32632 32633 32634 32635 32636 32637 32638 32639 32640 32641 32642 32643 32644 32645 32646 32647 32648 32649 32650 32651 32652 32653 32654 32655 32656 32657 32658 32659 32660 32661 32662 32663 32664 32665 32666 32667 32668 32669 32670 32671 32672 32673 32674 32675 32676 32677 32678 32679 32680 32681 32682 32683 32684 32685 32686 32687 32688 32689 32690 32691 32692 32693 32694 32695 32696 32697 32698 32699 32700 32701 32702 32703 32704 32705 32706 32707 32708 32709 32710 32711 32712 32713 32714 32715 32716 32717 32718 32719 32720 32721 32722 32723 32724 32725 32726 32727 32728 32729 32730 32731 32732 32733 32734 32735 32736 32737 32738 32739 32740 32741 32742 32743 32744 32745 32746 32747 32748 32749 32750 32751 32752 32753 32754 32755 32756 32757 32758 32759 32760 32761 32762 32763 32764 32765 32766 32767 32768 32769 32770 32771 32772 32773 32774 32775 32776 32777 32778 32779 32780 32781 32782 32783 32784 32785 32786 32787 32788 32789 32790 32791 32792 32793 32794 32795 32796 32797 32798 32799 32800 32801 32802 32803 32804 32805 32806 32807 32808 32809 32810 32811 32812 32813 32814 32815 32816 32817 32818 32819 32820 32821 32822 32823 32824 32825 32826 32827 32828 32829 32830 32831 32832 32833 32834 32835 32836 32837 32838 32839 32840 32841 32842 32843 32844 32845 32846 32847 32848 32849 32850 32851 32852 32853 32854 32855 32856 32857 32858 32859 32860 32861 32862 32863 32864 32865 32866 32867 32868 32869 32870 32871 32872 32873 32874 32875 32876 32877 32878 32879 32880 32881 32882 32883 32884 32885 32886 32887 32888 32889 32890 32891 32892 32893 32894 32895 32896 32897 32898 32899 32900 32901 32902 32903 32904 32905 32906 32907 32908 32909 32910 32911 32912 32913 32914 32915 32916 32917 32918 32919 32920 32921 32922 32923 32924 32925 32926 32927 32928 32929 32930 32931 32932 32933 32934 32935 32936 32937 32938 32939 32940 32941 32942 32943 32944 32945 32946 32947 32948 32949 32950 32951 32952 32953 32954 32955 32956 32957 32958 32959 32960 32961 32962 32963 32964 32965 32966 32967 32968 32969 32970 32971 32972 32973 32974 32975 32976 32977 32978 32979 32980 32981 32982 32983 32984 32985 32986 32987 32988 32989 32990 32991 32992 32993 32994 32995 32996 32997 32998 32999 33000 33001 33002 33003 33004 33005 33006 33007 33008 33009 33010 33011 33012 33013 33014 33015 33016 33017 33018 33019 33020 33021 33022 33023 33024 33025 33026 33027 33028 33029 33030 33031 33032 33033 33034 33035 33036 33037 33038 33039 33040 33041 33042 33043 33044 33045 33046 33047 33048 33049 33050 33051 33052 33053 33054 33055 33056 33057 33058 33059 33060 33061 33062 33063 33064 33065 33066 33067 33068 33069 33070 33071 33072 33073 33074 33075 33076 33077 33078 33079 33080 33081 33082 33083 33084 33085 33086 33087 33088 33089 33090 33091 33092 33093 33094 33095 33096 33097 33098 33099 33100 33101 33102 33103 33104 33105 33106 33107 33108 33109 33110 33111 33112 33113 33114 33115 33116 33117 33118 33119 33120 33121 33122 33123 33124 33125 33126 33127 33128 33129 33130 33131 33132 33133 33134 33135 33136 33137 33138 33139 33140 33141 33142 33143 33144 33145 33146 33147 33148 33149 33150 33151 33152 33153 33154 33155 33156 33157 33158 33159 33160 33161 33162 33163 33164 33165 33166 33167 33168 33169 33170 33171 33172 33173 33174 33175 33176 33177 33178 33179 33180 33181 33182 33183 33184 33185 33186 33187 33188 33189 33190 33191 33192 33193 33194 33195 33196 33197 33198 33199 33200 33201 33202 33203 33204 33205 33206 33207 33208 33209 33210 33211 33212 33213 33214 33215 33216 33217 33218 33219 33220 33221 33222 33223 33224 33225 33226 33227 33228 33229 33230 33231 33232 33233 33234 33235 33236 33237 33238 33239 33240 33241 33242 33243 33244 33245 33246 33247 33248 33249 33250 33251 33252 33253 33254 33255 33256 33257 33258 33259 33260 33261 33262 33263 33264 33265 33266 33267 33268 33269 33270 33271 33272 33273 33274 33275 33276 33277 33278 33279 33280 33281 33282 33283 33284 33285 33286 33287 33288 33289 33290 33291 33292 33293 33294 33295 33296 33297 33298 33299 33300 33301 33302 33303 33304 33305 33306 33307 33308 33309 33310 33311 33312 33313 33314 33315 33316 33317 33318 33319 33320 33321 33322 33323 33324 33325 33326 33327 33328 33329 33330 33331 33332 33333 33334 33335 33336 33337 33338 33339 33340 33341 33342 33343 33344 33345 33346 33347 33348 33349 33350 33351 33352 33353 33354 33355 33356 33357 33358 33359 33360 33361 33362 33363 33364 33365 33366 33367 33368 33369 33370 33371 33372 33373 33374 33375 33376 33377 33378 33379 33380 33381 33382 33383 33384 33385 33386 33387 33388 33389 33390 33391 33392 33393 33394 33395 33396 33397 33398 33399 33400 33401 33402 33403 33404 33405 33406 33407 33408 33409 33410 33411 33412 33413 33414 33415 33416 33417 33418 33419 33420 33421 33422 33423 33424 33425 33426 33427 33428 33429 33430 33431 33432 33433 33434 33435 33436 33437 33438 33439 33440 33441 33442 33443 33444 33445 33446 33447 33448 33449 33450 33451 33452 33453 33454 33455 33456 33457 33458 33459 33460 33461 33462 33463 33464 33465 33466 33467 33468 33469 33470 33471 33472 33473 33474 33475 33476 33477 33478 33479 33480 33481 33482 33483 33484 33485 33486 33487 33488 33489 33490 33491 33492 33493 33494 33495 33496 33497 33498 33499 33500 33501 33502 33503 33504 33505 33506 33507 33508 33509 33510 33511 33512 33513 33514 33515 33516 33517 33518 33519 33520 33521 33522 33523 33524 33525 33526 33527 33528 33529 33530 33531 33532 33533 33534 33535 33536 33537 33538 33539 33540 33541 33542 33543 33544 33545 33546 33547 33548 33549 33550 33551 33552 33553 33554 33555 33556 33557 33558 33559 33560 33561 33562 33563 33564 33565 33566 33567 33568 33569 33570 33571 33572 33573 33574 33575 33576 33577 33578 33579 33580 33581 33582 33583 33584 33585 33586 33587 33588 33589 33590 33591 33592 33593 33594 33595 33596 33597 33598 33599 33600 33601 33602 33603 33604 33605 33606 33607 33608 33609 33610 33611 33612 33613 33614 33615 33616 33617 33618 33619 33620 33621 33622 33623 33624 33625 33626 33627 33628 33629 33630 33631 33632 33633 33634 33635 33636 33637 33638 33639 33640 33641 33642 33643 33644 33645 33646 33647 33648 33649 33650 33651 33652 33653 33654 33655 33656 33657 33658 33659 33660 33661 33662 33663 33664 33665 33666 33667 33668 33669 33670 33671 33672 33673 33674 33675 33676 33677 33678 33679 33680 33681 33682 33683 33684 33685 33686 33687 33688 33689 33690 33691 33692 33693 33694 33695 33696 33697 33698 33699 33700 33701 33702 33703 33704 33705 33706 33707 33708 33709 33710 33711 33712 33713 33714 33715 33716 33717 33718 33719 33720 33721 33722 33723 33724 33725 33726 33727 33728 33729 33730 33731 33732 33733 33734 33735 33736 33737 33738 33739 33740 33741 33742 33743 33744 33745 33746 33747 33748 33749 33750 33751 33752 33753 33754 33755 33756 33757 33758 33759 33760 33761 33762 33763 33764 33765 33766 33767 33768 33769 33770 33771 33772 33773 33774 33775 33776 33777 33778 33779 33780 33781 33782 33783 33784 33785 33786 33787 33788 33789 33790 33791 33792 33793 33794 33795 33796 33797 33798 33799 33800 33801 33802 33803 33804 33805 33806 33807 33808 33809 33810 33811 33812 33813 33814 33815 33816 33817 33818 33819 33820 33821 33822 33823 33824 33825 33826 33827 33828 33829 33830 33831 33832 33833 33834 33835 33836 33837 33838 33839 33840 33841 33842 33843 33844 33845 33846 33847 33848 33849 33850 33851 33852 33853 33854 33855 33856 33857 33858 33859 33860 33861 33862 33863 33864 33865 33866 33867 33868 33869 33870 33871 33872 33873 33874 33875 33876 33877 33878 33879 33880 33881 33882 33883 33884 33885 33886 33887 33888 33889 33890 33891 33892 33893 33894 33895 33896 33897 33898 33899 33900 33901 33902 33903 33904 33905 33906 33907 33908 33909 33910 33911 33912 33913 33914 33915 33916 33917 33918 33919 33920 33921 33922 33923 33924 33925 33926 33927 33928 33929 33930 33931 33932 33933 33934 33935 33936 33937 33938 33939 33940 33941 33942 33943 33944 33945 33946 33947 33948 33949 33950 33951 33952 33953 33954 33955 33956 33957 33958 33959 33960 33961 33962 33963 33964 33965 33966 33967 33968 33969 33970 33971 33972 33973 33974 33975 33976 33977 33978 33979 33980 33981 33982 33983 33984 33985 33986 33987 33988 33989 33990 33991 33992 33993 33994 33995 33996 33997 33998 33999 34000 34001 34002 34003 34004 34005 34006 34007 34008 34009 34010 34011 34012 34013 34014 34015 34016 34017 34018 34019 34020 34021 34022 34023 34024 34025 34026 34027 34028 34029 34030 34031 34032 34033 34034 34035 34036 34037 34038 34039 34040 34041 34042 34043 34044 34045 34046 34047 34048 34049 34050 34051 34052 34053 34054 34055 34056 34057 34058 34059 34060 34061 34062 34063 34064 34065 34066 34067 34068 34069 34070 34071 34072 34073 34074 34075 34076 34077 34078 34079 34080 34081 34082 34083 34084 34085 34086 34087 34088 34089 34090 34091 34092 34093 34094 34095 34096 34097 34098 34099 34100 34101 34102 34103 34104 34105 34106 34107 34108 34109 34110 34111 34112 34113 34114 34115 34116 34117 34118 34119 34120 34121 34122 34123 34124 34125 34126 34127 34128 34129 34130 34131 34132 34133 34134 34135 34136 34137 34138 34139 34140 34141 34142 34143 34144 34145 34146 34147 34148 34149 34150 34151 34152 34153 34154 34155 34156 34157 34158 34159 34160 34161 34162 34163 34164 34165 34166 34167 34168 34169 34170 34171 34172 34173 34174 34175 34176 34177 34178 34179 34180 34181 34182 34183 34184 34185 34186 34187 34188 34189 34190 34191 34192 34193 34194 34195 34196 34197 34198 34199 34200 34201 34202 34203 34204 34205 34206 34207 34208 34209 34210 34211 34212 34213 34214 34215 34216 34217 34218 34219 34220 34221 34222 34223 34224 34225 34226 34227 34228 34229 34230 34231 34232 34233 34234 34235 34236 34237 34238 34239 34240 34241 34242 34243 34244 34245 34246 34247 34248 34249 34250 34251 34252 34253 34254 34255 34256 34257 34258 34259 34260 34261 34262 34263 34264 34265 34266 34267 34268 34269 34270 34271 34272 34273 34274 34275 34276 34277 34278 34279 34280 34281 34282 34283 34284 34285 34286 34287 34288 34289 34290 34291 34292 34293 34294 34295 34296 34297 34298 34299 34300 34301 34302 34303 34304 34305 34306 34307 34308 34309 34310 34311 34312 34313 34314 34315 34316 34317 34318 34319 34320 34321 34322 34323 34324 34325 34326 34327 34328 34329 34330 34331 34332 34333 34334 34335 34336 34337 34338 34339 34340 34341 34342 34343 34344 34345 34346 34347 34348 34349 34350 34351 34352 34353 34354 34355 34356 34357 34358 34359 34360 34361 34362 34363 34364 34365 34366 34367 34368 34369 34370 34371 34372 34373 34374 34375 34376 34377 34378 34379 34380 34381 34382 34383 34384 34385 34386 34387 34388 34389 34390 34391 34392 34393 34394 34395 34396 34397 34398 34399 34400 34401 34402 34403 34404 34405 34406 34407 34408 34409 34410 34411 34412 34413 34414 34415 34416 34417 34418 34419 34420 34421 34422 34423 34424 34425 34426 34427 34428 34429 34430 34431 34432 34433 34434 34435 34436 34437 34438 34439 34440 34441 34442 34443 34444 34445 34446 34447 34448 34449 34450 34451 34452 34453 34454 34455 34456 34457 34458 34459 34460 34461 34462 34463 34464 34465 34466 34467 34468 34469 34470 34471 34472 34473 34474 34475 34476 34477 34478 34479 34480 34481 34482 34483 34484 34485 34486 34487 34488 34489 34490 34491 34492 34493 34494 34495 34496 34497 34498 34499 34500 34501 34502 34503 34504 34505 34506 34507 34508 34509 34510 34511 34512 34513 34514 34515 34516 34517 34518 34519 34520 34521 34522 34523 34524 34525 34526 34527 34528 34529 34530 34531 34532 34533 34534 34535 34536 34537 34538 34539 34540 34541 34542 34543 34544 34545 34546 34547 34548 34549 34550 34551 34552 34553 34554 34555 34556 34557 34558 34559 34560 34561 34562 34563 34564 34565 34566 34567 34568 34569 34570 34571 34572 34573 34574 34575 34576 34577 34578 34579 34580 34581 34582 34583 34584 34585 34586 34587 34588 34589 34590 34591 34592 34593 34594 34595 34596 34597 34598 34599 34600 34601 34602 34603 34604 34605 34606 34607 34608 34609 34610 34611 34612 34613 34614 34615 34616 34617 34618 34619 34620 34621 34622 34623 34624 34625 34626 34627 34628 34629 34630 34631 34632 34633 34634 34635 34636 34637 34638 34639 34640 34641 34642 34643 34644 34645 34646 34647 34648 34649 34650 34651 34652 34653 34654 34655 34656 34657 34658 34659 34660 34661 34662 34663 34664 34665 34666 34667 34668 34669 34670 34671 34672 34673 34674 34675 34676 34677 34678 34679 34680 34681 34682 34683 34684 34685 34686 34687 34688 34689 34690 34691 34692 34693 34694 34695 34696 34697 34698 34699 34700 34701 34702 34703 34704 34705 34706 34707 34708 34709 34710 34711 34712 34713 34714 34715 34716 34717 34718 34719 34720 34721 34722 34723 34724 34725 34726 34727 34728 34729 34730 34731 34732 34733 34734 34735 34736 34737 34738 34739 34740 34741 34742 34743 34744 34745 34746 34747 34748 34749 34750 34751 34752 34753 34754 34755 34756 34757 34758 34759 34760 34761 34762 34763 34764 34765 34766 34767 34768 34769 34770 34771 34772 34773 34774 34775 34776 34777 34778 34779 34780 34781 34782 34783 34784 34785 34786 34787 34788 34789 34790 34791 34792 34793 34794 34795 34796 34797 34798 34799 34800 34801 34802 34803 34804 34805 34806 34807 34808 34809 34810 34811 34812 34813 34814 34815 34816 34817 34818 34819 34820 34821 34822 34823 34824 34825 34826 34827 34828 34829 34830 34831 34832 34833 34834 34835 34836 34837 34838 34839 34840 34841 34842 34843 34844 34845 34846 34847 34848 34849 34850 34851 34852 34853 34854 34855 34856 34857 34858 34859 34860 34861 34862 34863 34864 34865 34866 34867 34868 34869 34870 34871 34872 34873 34874 34875 34876 34877 34878 34879 34880 34881 34882 34883 34884 34885 34886 34887 34888 34889 34890 34891 34892 34893 34894 34895 34896 34897 34898 34899 34900 34901 34902 34903 34904 34905 34906 34907 34908 34909 34910 34911 34912 34913 34914 34915 34916 34917 34918 34919 34920 34921 34922 34923 34924 34925 34926 34927 34928 34929 34930 34931 34932 34933 34934 34935 34936 34937 34938 34939 34940 34941 34942 34943 34944 34945 34946 34947 34948 34949 34950 34951 34952 34953 34954 34955 34956 34957 34958 34959 34960 34961 34962 34963 34964 34965 34966 34967 34968 34969 34970 34971 34972 34973 34974 34975 34976 34977 34978 34979 34980 34981 34982 34983 34984 34985 34986 34987 34988 34989 34990 34991 34992 34993 34994 34995 34996 34997 34998 34999 35000 35001 35002 35003 35004 35005 35006 35007 35008 35009 35010 35011 35012 35013 35014 35015 35016 35017 35018 35019 35020 35021 35022 35023 35024 35025 35026 35027 35028 35029 35030 35031 35032 35033 35034 35035 35036 35037 35038 35039 35040 35041 35042 35043 35044 35045 35046 35047 35048 35049 35050 35051 35052 35053 35054 35055 35056 35057 35058 35059 35060 35061 35062 35063 35064 35065 35066 35067 35068 35069 35070 35071 35072 35073 35074 35075 35076 35077 35078 35079 35080 35081 35082 35083 35084 35085 35086 35087 35088 35089 35090 35091 35092 35093 35094 35095 35096 35097 35098 35099 35100 35101 35102 35103 35104 35105 35106 35107 35108 35109 35110 35111 35112 35113 35114 35115 35116 35117 35118 35119 35120 35121 35122 35123 35124 35125 35126 35127 35128 35129 35130 35131 35132 35133 35134 35135 35136 35137 35138 35139 35140 35141 35142 35143 35144 35145 35146 35147 35148 35149 35150 35151 35152 35153 35154 35155 35156 35157 35158 35159 35160 35161 35162 35163 35164 35165 35166 35167 35168 35169 35170 35171 35172 35173 35174 35175 35176 35177 35178 35179 35180 35181 35182 35183 35184 35185 35186 35187 35188 35189 35190 35191 35192 35193 35194 35195 35196 35197 35198 35199 35200 35201 35202 35203 35204 35205 35206 35207 35208 35209 35210 35211 35212 35213 35214 35215 35216 35217 35218 35219 35220 35221 35222 35223 35224 35225 35226 35227 35228 35229 35230 35231 35232 35233 35234 35235 35236 35237 35238 35239 35240 35241 35242 35243 35244 35245 35246 35247 35248 35249 35250 35251 35252 35253 35254 35255 35256 35257 35258 35259 35260 35261 35262 35263 35264 35265 35266 35267 35268 35269 35270 35271 35272 35273 35274 35275 35276 35277 35278 35279 35280 35281 35282 35283 35284 35285 35286 35287 35288 35289 35290 35291 35292 35293 35294 35295 35296 35297 35298 35299 35300 35301 35302 35303 35304 35305 35306 35307 35308 35309 35310 35311 35312 35313 35314 35315 35316 35317 35318 35319 35320 35321 35322 35323 35324 35325 35326 35327 35328 35329 35330 35331 35332 35333 35334 35335 35336 35337 35338 35339 35340 35341 35342 35343 35344 35345 35346 35347 35348 35349 35350 35351 35352 35353 35354 35355 35356 35357 35358 35359 35360 35361 35362 35363 35364 35365 35366 35367 35368 35369 35370 35371 35372 35373 35374 35375 35376 35377 35378 35379 35380 35381 35382 35383 35384 35385 35386 35387 35388 35389 35390 35391 35392 35393 35394 35395 35396 35397 35398 35399 35400 35401 35402 35403 35404 35405 35406 35407 35408 35409 35410 35411 35412 35413 35414 35415 35416 35417 35418 35419 35420 35421 35422 35423 35424 35425 35426 35427 35428 35429 35430 35431 35432 35433 35434 35435 35436 35437 35438 35439 35440 35441 35442 35443 35444 35445 35446 35447 35448 35449 35450 35451 35452 35453 35454 35455 35456 35457 35458 35459 35460 35461 35462 35463 35464 35465 35466 35467 35468 35469 35470 35471 35472 35473 35474 35475 35476 35477 35478 35479 35480 35481 35482 35483 35484 35485 35486 35487 35488 35489 35490 35491 35492 35493 35494 35495 35496 35497 35498 35499 35500 35501 35502 35503 35504 35505 35506 35507 35508 35509 35510 35511 35512 35513 35514 35515 35516 35517 35518 35519 35520 35521 35522 35523 35524 35525 35526 35527 35528 35529 35530 35531 35532 35533 35534 35535 35536 35537 35538 35539 35540 35541 35542 35543 35544 35545 35546 35547 35548 35549 35550 35551 35552 35553 35554 35555 35556 35557 35558 35559 35560 35561 35562 35563 35564 35565 35566 35567 35568 35569 35570 35571 35572 35573 35574 35575 35576 35577 35578 35579 35580 35581 35582 35583 35584 35585 35586 35587 35588 35589 35590 35591 35592 35593 35594 35595 35596 35597 35598 35599 35600 35601 35602 35603 35604 35605 35606 35607 35608 35609 35610 35611 35612 35613 35614 35615 35616 35617 35618 35619 35620 35621 35622 35623 35624 35625 35626 35627 35628 35629 35630 35631 35632 35633 35634 35635 35636 35637 35638 35639 35640 35641 35642 35643 35644 35645 35646 35647 35648 35649 35650 35651 35652 35653 35654 35655 35656 35657 35658 35659 35660 35661 35662 35663 35664 35665 35666 35667 35668 35669 35670 35671 35672 35673 35674 35675 35676 35677 35678 35679 35680 35681 35682 35683 35684 35685 35686 35687 35688 35689 35690 35691 35692 35693 35694 35695 35696 35697 35698 35699 35700 35701 35702 35703 35704 35705 35706 35707 35708 35709 35710 35711 35712 35713 35714 35715 35716 35717 35718 35719 35720 35721 35722 35723 35724 35725 35726 35727 35728 35729 35730 35731 35732 35733 35734 35735 35736 35737 35738 35739 35740 35741 35742 35743 35744 35745 35746 35747 35748 35749 35750 35751 35752 35753 35754 35755 35756 35757 35758 35759 35760 35761 35762 35763 35764 35765 35766 35767 35768 35769 35770 35771 35772 35773 35774 35775 35776 35777 35778 35779 35780 35781 35782 35783 35784 35785 35786 35787 35788 35789 35790 35791 35792 35793 35794 35795 35796 35797 35798 35799 35800 35801 35802 35803 35804 35805 35806 35807 35808 35809 35810 35811 35812 35813 35814 35815 35816 35817 35818 35819 35820 35821 35822 35823 35824 35825 35826 35827 35828 35829 35830 35831 35832 35833 35834 35835 35836 35837 35838 35839 35840 35841 35842 35843 35844 35845 35846 35847 35848 35849 35850 35851 35852 35853 35854 35855 35856 35857 35858 35859 35860 35861 35862 35863 35864 35865 35866 35867 35868 35869 35870 35871 35872 35873 35874 35875 35876 35877 35878 35879 35880 35881 35882 35883 35884 35885 35886 35887 35888 35889 35890 35891 35892 35893 35894 35895 35896 35897 35898 35899 35900 35901 35902 35903 35904 35905 35906 35907 35908 35909 35910 35911 35912 35913 35914 35915 35916 35917 35918 35919 35920 35921 35922 35923 35924 35925 35926 35927 35928 35929 35930 35931 35932 35933 35934 35935 35936 35937 35938 35939 35940 35941 35942 35943 35944 35945 35946 35947 35948 35949 35950 35951 35952 35953 35954 35955 35956 35957 35958 35959 35960 35961 35962 35963 35964 35965 35966 35967 35968 35969 35970 35971 35972 35973 35974 35975 35976 35977 35978 35979 35980 35981 35982 35983 35984 35985 35986 35987 35988 35989 35990 35991 35992 35993 35994 35995 35996 35997 35998 35999 36000 36001 36002 36003 36004 36005 36006 36007 36008 36009 36010 36011 36012 36013 36014 36015 36016 36017 36018 36019 36020 36021 36022 36023 36024 36025 36026 36027 36028 36029 36030 36031 36032 36033 36034 36035 36036 36037 36038 36039 36040 36041 36042 36043 36044 36045 36046 36047 36048 36049 36050 36051 36052 36053 36054 36055 36056 36057 36058 36059 36060 36061 36062 36063 36064 36065 36066 36067 36068 36069 36070 36071 36072 36073 36074 36075 36076 36077 36078 36079 36080 36081 36082 36083 36084 36085 36086 36087 36088 36089 36090 36091 36092 36093 36094 36095 36096 36097 36098 36099 36100 36101 36102 36103 36104 36105 36106 36107 36108 36109 36110 36111 36112 36113 36114 36115 36116 36117 36118 36119 36120 36121 36122 36123 36124 36125 36126 36127 36128 36129 36130 36131 36132 36133 36134 36135 36136 36137 36138 36139 36140 36141 36142 36143 36144 36145 36146 36147 36148 36149 36150 36151 36152 36153 36154 36155 36156 36157 36158 36159 36160 36161 36162 36163 36164 36165 36166 36167 36168 36169 36170 36171 36172 36173 36174 36175 36176 36177 36178 36179 36180 36181 36182 36183 36184 36185 36186 36187 36188 36189 36190 36191 36192 36193 36194 36195 36196 36197 36198 36199 36200 36201 36202 36203 36204 36205 36206 36207 36208 36209 36210 36211 36212 36213 36214 36215 36216 36217 36218 36219 36220 36221 36222 36223 36224 36225 36226 36227 36228 36229 36230 36231 36232 36233 36234 36235 36236 36237 36238 36239 36240 36241 36242 36243 36244 36245 36246 36247 36248 36249 36250 36251 36252 36253 36254 36255 36256 36257 36258 36259 36260 36261 36262 36263 36264 36265 36266 36267 36268 36269 36270 36271 36272 36273 36274 36275 36276 36277 36278 36279 36280 36281 36282 36283 36284 36285 36286 36287 36288 36289 36290 36291 36292 36293 36294 36295 36296 36297 36298 36299 36300 36301 36302 36303 36304 36305 36306 36307 36308 36309 36310 36311 36312 36313 36314 36315 36316 36317 36318 36319 36320 36321 36322 36323 36324 36325 36326 36327 36328 36329 36330 36331 36332 36333 36334 36335 36336 36337 36338 36339 36340 36341 36342 36343 36344 36345 36346 36347 36348 36349 36350 36351 36352 36353 36354 36355 36356 36357 36358 36359 36360 36361 36362 36363 36364 36365 36366 36367 36368 36369 36370 36371 36372 36373 36374 36375 36376 36377 36378 36379 36380 36381 36382 36383 36384 36385 36386 36387 36388 36389 36390 36391 36392 36393 36394 36395 36396 36397 36398 36399 36400 36401 36402 36403 36404 36405 36406 36407 36408 36409 36410 36411 36412 36413 36414 36415 36416 36417 36418 36419 36420 36421 36422 36423 36424 36425 36426 36427 36428 36429 36430 36431 36432 36433 36434 36435 36436 36437 36438 36439 36440 36441 36442 36443 36444 36445 36446 36447 36448 36449 36450 36451 36452 36453 36454 36455 36456 36457 36458 36459 36460 36461 36462 36463 36464 36465 36466 36467 36468 36469 36470 36471 36472 36473 36474 36475 36476 36477 36478 36479 36480 36481 36482 36483 36484 36485 36486 36487 36488 36489 36490 36491 36492 36493 36494 36495 36496 36497 36498 36499 36500 36501 36502 36503 36504 36505 36506 36507 36508 36509 36510 36511 36512 36513 36514 36515 36516 36517 36518 36519 36520 36521 36522 36523 36524 36525 36526 36527 36528 36529 36530 36531 36532 36533 36534 36535 36536 36537 36538 36539 36540 36541 36542 36543 36544 36545 36546 36547 36548 36549 36550 36551 36552 36553 36554 36555 36556 36557 36558 36559 36560 36561 36562 36563 36564 36565 36566 36567 36568 36569 36570 36571 36572 36573 36574 36575 36576 36577 36578 36579 36580 36581 36582 36583 36584 36585 36586 36587 36588 36589 36590 36591 36592 36593 36594 36595 36596 36597 36598 36599 36600 36601 36602 36603 36604 36605 36606 36607 36608 36609 36610 36611 36612 36613 36614 36615 36616 36617 36618 36619 36620 36621 36622 36623 36624 36625 36626 36627 36628 36629 36630 36631 36632 36633 36634 36635 36636 36637 36638 36639 36640 36641 36642 36643 36644 36645 36646 36647 36648 36649 36650 36651 36652 36653 36654 36655 36656 36657 36658 36659 36660 36661 36662 36663 36664 36665 36666 36667 36668 36669 36670 36671 36672 36673 36674 36675 36676 36677 36678 36679 36680 36681 36682 36683 36684 36685 36686 36687 36688 36689 36690 36691 36692 36693 36694 36695 36696 36697 36698 36699 36700 36701 36702 36703 36704 36705 36706 36707 36708 36709 36710 36711 36712 36713 36714 36715 36716 36717 36718 36719 36720 36721 36722 36723 36724 36725 36726 36727 36728 36729 36730 36731 36732 36733 36734 36735 36736 36737 36738 36739 36740 36741 36742 36743 36744 36745 36746 36747 36748 36749 36750 36751 36752 36753 36754 36755 36756 36757 36758 36759 36760 36761 36762 36763 36764 36765 36766 36767 36768 36769 36770 36771 36772 36773 36774 36775 36776 36777 36778 36779 36780 36781 36782 36783 36784 36785 36786 36787 36788 36789 36790 36791 36792 36793 36794 36795 36796 36797 36798 36799 36800 36801 36802 36803 36804 36805 36806 36807 36808 36809 36810 36811 36812 36813 36814 36815 36816 36817 36818 36819 36820 36821 36822 36823 36824 36825 36826 36827 36828 36829 36830 36831 36832 36833 36834 36835 36836 36837 36838 36839 36840 36841 36842 36843 36844 36845 36846 36847 36848 36849 36850 36851 36852 36853 36854 36855 36856 36857 36858 36859 36860 36861 36862 36863 36864 36865 36866 36867 36868 36869 36870 36871 36872 36873 36874 36875 36876 36877 36878 36879 36880 36881 36882 36883 36884 36885 36886 36887 36888 36889 36890 36891 36892 36893 36894 36895 36896 36897 36898 36899 36900 36901 36902 36903 36904 36905 36906 36907 36908 36909 36910 36911 36912 36913 36914 36915 36916 36917 36918 36919 36920 36921 36922 36923 36924 36925 36926 36927 36928 36929 36930 36931 36932 36933 36934 36935 36936 36937 36938 36939 36940 36941 36942 36943 36944 36945 36946 36947 36948 36949 36950 36951 36952 36953 36954 36955 36956 36957 36958 36959 36960 36961 36962 36963 36964 36965 36966 36967 36968 36969 36970 36971 36972 36973 36974 36975 36976 36977 36978 36979 36980 36981 36982 36983 36984 36985 36986 36987 36988 36989 36990 36991 36992 36993 36994 36995 36996 36997 36998 36999 37000 37001 37002 37003 37004 37005 37006 37007 37008 37009 37010 37011 37012 37013 37014 37015 37016 37017 37018 37019 37020 37021 37022 37023 37024 37025 37026 37027 37028 37029 37030 37031 37032 37033 37034 37035 37036 37037 37038 37039 37040 37041 37042 37043 37044 37045 37046 37047 37048 37049 37050 37051 37052 37053 37054 37055 37056 37057 37058 37059 37060 37061 37062 37063 37064 37065 37066 37067 37068 37069 37070 37071 37072 37073 37074 37075 37076 37077 37078 37079 37080 37081 37082 37083 37084 37085 37086 37087 37088 37089 37090 37091 37092 37093 37094 37095 37096 37097 37098 37099 37100 37101 37102 37103 37104 37105 37106 37107 37108 37109 37110 37111 37112 37113 37114 37115 37116 37117 37118 37119 37120 37121 37122 37123 37124 37125 37126 37127 37128 37129 37130 37131 37132 37133 37134 37135 37136 37137 37138 37139 37140 37141 37142 37143 37144 37145 37146 37147 37148 37149 37150 37151 37152 37153 37154 37155 37156 37157 37158 37159 37160 37161 37162 37163 37164 37165 37166 37167 37168 37169 37170 37171 37172 37173 37174 37175 37176 37177 37178 37179 37180 37181 37182 37183 37184 37185 37186 37187 37188 37189 37190 37191 37192 37193 37194 37195 37196 37197 37198 37199 37200 37201 37202 37203 37204 37205 37206 37207 37208 37209 37210 37211 37212 37213 37214 37215 37216 37217 37218 37219 37220 37221 37222 37223 37224 37225 37226 37227 37228 37229 37230 37231 37232 37233 37234 37235 37236 37237 37238 37239 37240 37241 37242 37243 37244 37245 37246 37247 37248 37249 37250 37251 37252 37253 37254 37255 37256 37257 37258 37259 37260 37261 37262 37263 37264 37265 37266 37267 37268 37269 37270 37271 37272 37273 37274 37275 37276 37277 37278 37279 37280 37281 37282 37283 37284 37285 37286 37287 37288 37289 37290 37291 37292 37293 37294 37295 37296 37297 37298 37299 37300 37301 37302 37303 37304 37305 37306 37307 37308 37309 37310 37311 37312 37313 37314 37315 37316 37317 37318 37319 37320 37321 37322 37323 37324 37325 37326 37327 37328 37329 37330 37331 37332 37333 37334 37335 37336 37337 37338 37339 37340 37341 37342 37343 37344 37345 37346 37347 37348 37349 37350 37351 37352 37353 37354 37355 37356 37357 37358 37359 37360 37361 37362 37363 37364 37365 37366 37367 37368 37369 37370 37371 37372 37373 37374 37375 37376 37377 37378 37379 37380 37381 37382 37383 37384 37385 37386 37387 37388 37389 37390 37391 37392 37393 37394 37395 37396 37397 37398 37399 37400 37401 37402 37403 37404 37405 37406 37407 37408 37409 37410 37411 37412 37413 37414 37415 37416 37417 37418 37419 37420 37421 37422 37423 37424 37425 37426 37427 37428 37429 37430 37431 37432 37433 37434 37435 37436 37437 37438 37439 37440 37441 37442 37443 37444 37445 37446 37447 37448 37449 37450 37451 37452 37453 37454 37455 37456 37457 37458 37459 37460 37461 37462 37463 37464 37465 37466 37467 37468 37469 37470 37471 37472 37473 37474 37475 37476 37477 37478 37479 37480 37481 37482 37483 37484 37485 37486 37487 37488 37489 37490 37491 37492 37493 37494 37495 37496 37497 37498 37499 37500 37501 37502 37503 37504 37505 37506 37507 37508 37509 37510 37511 37512 37513 37514 37515 37516 37517 37518 37519 37520 37521 37522 37523 37524 37525 37526 37527 37528 37529 37530 37531 37532 37533 37534 37535 37536 37537 37538 37539 37540 37541 37542 37543 37544 37545 37546 37547 37548 37549 37550 37551 37552 37553 37554 37555 37556 37557 37558 37559 37560 37561 37562 37563 37564 37565 37566 37567 37568 37569 37570 37571 37572 37573 37574 37575 37576 37577 37578 37579 37580 37581 37582 37583 37584 37585 37586 37587 37588 37589 37590 37591 37592 37593 37594 37595 37596 37597 37598 37599 37600 37601 37602 37603 37604 37605 37606 37607 37608 37609 37610 37611 37612 37613 37614 37615 37616 37617 37618 37619 37620 37621 37622 37623 37624 37625 37626 37627 37628 37629 37630 37631 37632 37633 37634 37635 37636 37637 37638 37639 37640 37641 37642 37643 37644 37645 37646 37647 37648 37649 37650 37651 37652 37653 37654 37655 37656 37657 37658 37659 37660 37661 37662 37663 37664 37665 37666 37667 37668 37669 37670 37671 37672 37673 37674 37675 37676 37677 37678 37679 37680 37681 37682 37683 37684 37685 37686 37687 37688 37689 37690 37691 37692 37693 37694 37695 37696 37697 37698 37699 37700 37701 37702 37703 37704 37705 37706 37707 37708 37709 37710 37711 37712 37713 37714 37715 37716 37717 37718 37719 37720 37721 37722 37723 37724 37725 37726 37727 37728 37729 37730 37731 37732 37733 37734 37735 37736 37737 37738 37739 37740 37741 37742 37743 37744 37745 37746 37747 37748 37749 37750 37751 37752 37753 37754 37755 37756 37757 37758 37759 37760 37761 37762 37763 37764 37765 37766 37767 37768 37769 37770 37771 37772 37773 37774 37775 37776 37777 37778 37779 37780 37781 37782 37783 37784 37785 37786 37787 37788 37789 37790 37791 37792 37793 37794 37795 37796 37797 37798 37799 37800 37801 37802 37803 37804 37805 37806 37807 37808 37809 37810 37811 37812 37813 37814 37815 37816 37817 37818 37819 37820 37821 37822 37823 37824 37825 37826 37827 37828 37829 37830 37831 37832 37833 37834 37835 37836 37837 37838 37839 37840 37841 37842 37843 37844 37845 37846 37847 37848 37849 37850 37851 37852 37853 37854 37855 37856 37857 37858 37859 37860 37861 37862 37863 37864 37865 37866 37867 37868 37869 37870 37871 37872 37873 37874 37875 37876 37877 37878 37879 37880 37881 37882 37883 37884 37885 37886 37887 37888 37889 37890 37891 37892 37893 37894 37895 37896 37897 37898 37899 37900 37901 37902 37903 37904 37905 37906 37907 37908 37909 37910 37911 37912 37913 37914 37915 37916 37917 37918 37919 37920 37921 37922 37923 37924 37925 37926 37927 37928 37929 37930 37931 37932 37933 37934 37935 37936 37937 37938 37939 37940 37941 37942 37943 37944 37945 37946 37947 37948 37949 37950 37951 37952 37953 37954 37955 37956 37957 37958 37959 37960 37961 37962 37963 37964 37965 37966 37967 37968 37969 37970 37971 37972 37973 37974 37975 37976 37977 37978 37979 37980 37981 37982 37983 37984 37985 37986 37987 37988 37989 37990 37991 37992 37993 37994 37995 37996 37997 37998 37999 38000 38001 38002 38003 38004 38005 38006 38007 38008 38009 38010 38011 38012 38013 38014 38015 38016 38017 38018 38019 38020 38021 38022 38023 38024 38025 38026 38027 38028 38029 38030 38031 38032 38033 38034 38035 38036 38037 38038 38039 38040 38041 38042 38043 38044 38045 38046 38047 38048 38049 38050 38051 38052 38053 38054 38055 38056 38057 38058 38059 38060 38061 38062 38063 38064 38065 38066 38067 38068 38069 38070 38071 38072 38073 38074 38075 38076 38077 38078 38079 38080 38081 38082 38083 38084 38085 38086 38087 38088 38089 38090 38091 38092 38093 38094 38095 38096 38097 38098 38099 38100 38101 38102 38103 38104 38105 38106 38107 38108 38109 38110 38111 38112 38113 38114 38115 38116 38117 38118 38119 38120 38121 38122 38123 38124 38125 38126 38127 38128 38129 38130 38131 38132 38133 38134 38135 38136 38137 38138 38139 38140 38141 38142 38143 38144 38145 38146 38147 38148 38149 38150 38151 38152 38153 38154 38155 38156 38157 38158 38159 38160 38161 38162 38163 38164 38165 38166 38167 38168 38169 38170 38171 38172 38173 38174 38175 38176 38177 38178 38179 38180 38181 38182 38183 38184 38185 38186 38187 38188 38189 38190 38191 38192 38193 38194 38195 38196 38197 38198 38199 38200 38201 38202 38203 38204 38205 38206 38207 38208 38209 38210 38211 38212 38213 38214 38215 38216 38217 38218 38219 38220 38221 38222 38223 38224 38225 38226 38227 38228 38229 38230 38231 38232 38233 38234 38235 38236 38237 38238 38239 38240 38241 38242 38243 38244 38245 38246 38247 38248 38249 38250 38251 38252 38253 38254 38255 38256 38257 38258 38259 38260 38261 38262 38263 38264 38265 38266 38267 38268 38269 38270 38271 38272 38273 38274 38275 38276 38277 38278 38279 38280 38281 38282 38283 38284 38285 38286 38287 38288 38289 38290 38291 38292 38293 38294 38295 38296 38297 38298 38299 38300 38301 38302 38303 38304 38305 38306 38307 38308 38309 38310 38311 38312 38313 38314 38315 38316 38317 38318 38319 38320 38321 38322 38323 38324 38325 38326 38327 38328 38329 38330 38331 38332 38333 38334 38335 38336 38337 38338 38339 38340 38341 38342 38343 38344 38345 38346 38347 38348 38349 38350 38351 38352 38353 38354 38355 38356 38357 38358 38359 38360 38361 38362 38363 38364 38365 38366 38367 38368 38369 38370 38371 38372 38373 38374 38375 38376 38377 38378 38379 38380 38381 38382 38383 38384 38385 38386 38387 38388 38389 38390 38391 38392 38393 38394 38395 38396 38397 38398 38399 38400 38401 38402 38403 38404 38405 38406 38407 38408 38409 38410 38411 38412 38413 38414 38415 38416 38417 38418 38419 38420 38421 38422 38423 38424 38425 38426 38427 38428 38429 38430 38431 38432 38433 38434 38435 38436 38437 38438 38439 38440 38441 38442 38443 38444 38445 38446 38447 38448 38449 38450 38451 38452 38453 38454 38455 38456 38457 38458 38459 38460 38461 38462 38463 38464 38465 38466 38467 38468 38469 38470 38471 38472 38473 38474 38475 38476 38477 38478 38479 38480 38481 38482 38483 38484 38485 38486 38487 38488 38489 38490 38491 38492 38493 38494 38495 38496 38497 38498 38499 38500 38501 38502 38503 38504 38505 38506 38507 38508 38509 38510 38511 38512 38513 38514 38515 38516 38517 38518 38519 38520 38521 38522 38523 38524 38525 38526 38527 38528 38529 38530 38531 38532 38533 38534 38535 38536 38537 38538 38539 38540 38541 38542 38543 38544 38545 38546 38547 38548 38549 38550 38551 38552 38553 38554 38555 38556 38557 38558 38559 38560 38561 38562 38563 38564 38565 38566 38567 38568 38569 38570 38571 38572 38573 38574 38575 38576 38577 38578 38579 38580 38581 38582 38583 38584 38585 38586 38587 38588 38589 38590 38591 38592 38593 38594 38595 38596 38597 38598 38599 38600 38601 38602 38603 38604 38605 38606 38607 38608 38609 38610 38611 38612 38613 38614 38615 38616 38617 38618 38619 38620 38621 38622 38623 38624 38625 38626 38627 38628 38629 38630 38631 38632 38633 38634 38635 38636 38637 38638 38639 38640 38641 38642 38643 38644 38645 38646 38647 38648 38649 38650 38651 38652 38653 38654 38655 38656 38657 38658 38659 38660 38661 38662 38663 38664 38665 38666 38667 38668 38669 38670 38671 38672 38673 38674 38675 38676 38677 38678 38679 38680 38681 38682 38683 38684 38685 38686 38687 38688 38689 38690 38691 38692 38693 38694 38695 38696 38697 38698 38699 38700 38701 38702 38703 38704 38705 38706 38707 38708 38709 38710 38711 38712 38713 38714 38715 38716 38717 38718 38719 38720 38721 38722 38723 38724 38725 38726 38727 38728 38729 38730 38731 38732 38733 38734 38735 38736 38737 38738 38739 38740 38741 38742 38743 38744 38745 38746 38747 38748 38749 38750 38751 38752 38753 38754 38755 38756 38757 38758 38759 38760 38761 38762 38763 38764 38765 38766 38767 38768 38769 38770 38771 38772 38773 38774 38775 38776 38777 38778 38779 38780 38781 38782 38783 38784 38785 38786 38787 38788 38789 38790 38791 38792 38793 38794 38795 38796 38797 38798 38799 38800 38801 38802 38803 38804 38805 38806 38807 38808 38809 38810 38811 38812 38813 38814 38815 38816 38817 38818 38819 38820 38821 38822 38823 38824 38825 38826 38827 38828 38829 38830 38831 38832 38833 38834 38835 38836 38837 38838 38839 38840 38841 38842 38843 38844 38845 38846 38847 38848 38849 38850 38851 38852 38853 38854 38855 38856 38857 38858 38859 38860 38861 38862 38863 38864 38865 38866 38867 38868 38869 38870 38871 38872 38873 38874 38875 38876 38877 38878 38879 38880 38881 38882 38883 38884 38885 38886 38887 38888 38889 38890 38891 38892 38893 38894 38895 38896 38897 38898 38899 38900 38901 38902 38903 38904 38905 38906 38907 38908 38909 38910 38911 38912 38913 38914 38915 38916 38917 38918 38919 38920 38921 38922 38923 38924 38925 38926 38927 38928 38929 38930 38931 38932 38933 38934 38935 38936 38937 38938 38939 38940 38941 38942 38943 38944 38945 38946 38947 38948 38949 38950 38951 38952 38953 38954 38955 38956 38957 38958 38959 38960 38961 38962 38963 38964 38965 38966 38967 38968 38969 38970 38971 38972 38973 38974 38975 38976 38977 38978 38979 38980 38981 38982 38983 38984 38985 38986 38987 38988 38989 38990 38991 38992 38993 38994 38995 38996 38997 38998 38999 39000 39001 39002 39003 39004 39005 39006 39007 39008 39009 39010 39011 39012 39013 39014 39015 39016 39017 39018 39019 39020 39021 39022 39023 39024 39025 39026 39027 39028 39029 39030 39031 39032 39033 39034 39035 39036 39037 39038 39039 39040 39041 39042 39043 39044 39045 39046 39047 39048 39049 39050 39051 39052 39053 39054 39055 39056 39057 39058 39059 39060 39061 39062 39063 39064 39065 39066 39067 39068 39069 39070 39071 39072 39073 39074 39075 39076 39077 39078 39079 39080 39081 39082 39083 39084 39085 39086 39087 39088 39089 39090 39091 39092 39093 39094 39095 39096 39097 39098 39099 39100 39101 39102 39103 39104 39105 39106 39107 39108 39109 39110 39111 39112 39113 39114 39115 39116 39117 39118 39119 39120 39121 39122 39123 39124 39125 39126 39127 39128 39129 39130 39131 39132 39133 39134 39135 39136 39137 39138 39139 39140 39141 39142 39143 39144 39145 39146 39147 39148 39149 39150 39151 39152 39153 39154 39155 39156 39157 39158 39159 39160 39161 39162 39163 39164 39165 39166 39167 39168 39169 39170 39171 39172 39173 39174 39175 39176 39177 39178 39179 39180 39181 39182 39183 39184 39185 39186 39187 39188 39189 39190 39191 39192 39193 39194 39195 39196 39197 39198 39199 39200 39201 39202 39203 39204 39205 39206 39207 39208 39209 39210 39211 39212 39213 39214 39215 39216 39217 39218 39219 39220 39221 39222 39223 39224 39225 39226 39227 39228 39229 39230 39231 39232 39233 39234 39235 39236 39237 39238 39239 39240 39241 39242 39243 39244 39245 39246 39247 39248 39249 39250 39251 39252 39253 39254 39255 39256 39257 39258 39259 39260 39261 39262 39263 39264 39265 39266 39267 39268 39269 39270 39271 39272 39273 39274 39275 39276 39277 39278 39279 39280 39281 39282 39283 39284 39285 39286 39287 39288 39289 39290 39291 39292 39293 39294 39295 39296 39297 39298 39299 39300 39301 39302 39303 39304 39305 39306 39307 39308 39309 39310 39311 39312 39313 39314 39315 39316 39317 39318 39319 39320 39321 39322 39323 39324 39325 39326 39327 39328 39329 39330 39331 39332 39333 39334 39335 39336 39337 39338 39339 39340 39341 39342 39343 39344 39345 39346 39347 39348 39349 39350 39351 39352 39353 39354 39355 39356 39357 39358 39359 39360 39361 39362 39363 39364 39365 39366 39367 39368 39369 39370 39371 39372 39373 39374 39375 39376 39377 39378 39379 39380 39381 39382 39383 39384 39385 39386 39387 39388 39389 39390 39391 39392 39393 39394 39395 39396 39397 39398 39399 39400 39401 39402 39403 39404 39405 39406 39407 39408 39409 39410 39411 39412 39413 39414 39415 39416 39417 39418 39419 39420 39421 39422 39423 39424 39425 39426 39427 39428 39429 39430 39431 39432 39433 39434 39435 39436 39437 39438 39439 39440 39441 39442 39443 39444 39445 39446 39447 39448 39449 39450 39451 39452 39453 39454 39455 39456 39457 39458 39459 39460 39461 39462 39463 39464 39465 39466 39467 39468 39469 39470 39471 39472 39473 39474 39475 39476 39477 39478 39479 39480 39481 39482 39483 39484 39485 39486 39487 39488 39489 39490 39491 39492 39493 39494 39495 39496 39497 39498 39499 39500 39501 39502 39503 39504 39505 39506 39507 39508 39509 39510 39511 39512 39513 39514 39515 39516 39517 39518 39519 39520 39521 39522 39523 39524 39525 39526 39527 39528 39529 39530 39531 39532 39533 39534 39535 39536 39537 39538 39539 39540 39541 39542 39543 39544 39545 39546 39547 39548 39549 39550 39551 39552 39553 39554 39555 39556 39557 39558 39559 39560 39561 39562 39563 39564 39565 39566 39567 39568 39569 39570 39571 39572 39573 39574 39575 39576 39577 39578 39579 39580 39581 39582 39583 39584 39585 39586 39587 39588 39589 39590 39591 39592 39593 39594 39595 39596 39597 39598 39599 39600 39601 39602 39603 39604 39605 39606 39607 39608 39609 39610 39611 39612 39613 39614 39615 39616 39617 39618 39619 39620 39621 39622 39623 39624 39625 39626 39627 39628 39629 39630 39631 39632 39633 39634 39635 39636 39637 39638 39639 39640 39641 39642 39643 39644 39645 39646 39647 39648 39649 39650 39651 39652 39653 39654 39655 39656 39657 39658 39659 39660 39661 39662 39663 39664 39665 39666 39667 39668 39669 39670 39671 39672 39673 39674 39675 39676 39677 39678 39679 39680 39681 39682 39683 39684 39685 39686 39687 39688 39689 39690 39691 39692 39693 39694 39695 39696 39697 39698 39699 39700 39701 39702 39703 39704 39705 39706 39707 39708 39709 39710 39711 39712 39713 39714 39715 39716 39717 39718 39719 39720 39721 39722 39723 39724 39725 39726 39727 39728 39729 39730 39731 39732 39733 39734 39735 39736 39737 39738 39739 39740 39741 39742 39743 39744 39745 39746 39747 39748 39749 39750 39751 39752 39753 39754 39755 39756 39757 39758 39759 39760 39761 39762 39763 39764 39765 39766 39767 39768 39769 39770 39771 39772 39773 39774 39775 39776 39777 39778 39779 39780 39781 39782 39783 39784 39785 39786 39787 39788 39789 39790 39791 39792 39793 39794 39795 39796 39797 39798 39799 39800 39801 39802 39803 39804 39805 39806 39807 39808 39809 39810 39811 39812 39813 39814 39815 39816 39817 39818 39819 39820 39821 39822 39823 39824 39825 39826 39827 39828 39829 39830 39831 39832 39833 39834 39835 39836 39837 39838 39839 39840 39841 39842 39843 39844 39845 39846 39847 39848 39849 39850 39851 39852 39853 39854 39855 39856 39857 39858 39859 39860 39861 39862 39863 39864 39865 39866 39867 39868 39869 39870 39871 39872 39873 39874 39875 39876 39877 39878 39879 39880 39881 39882 39883 39884 39885 39886 39887 39888 39889 39890 39891 39892 39893 39894 39895 39896 39897 39898 39899 39900 39901 39902 39903 39904 39905 39906 39907 39908 39909 39910 39911 39912 39913 39914 39915 39916 39917 39918 39919 39920 39921 39922 39923 39924 39925 39926 39927 39928 39929 39930 39931 39932 39933 39934 39935 39936 39937 39938 39939 39940 39941 39942 39943 39944 39945 39946 39947 39948 39949 39950 39951 39952 39953 39954 39955 39956 39957 39958 39959 39960 39961 39962 39963 39964 39965 39966 39967 39968 39969 39970 39971 39972 39973 39974 39975 39976 39977 39978 39979 39980 39981 39982 39983 39984 39985 39986 39987 39988 39989 39990 39991 39992 39993 39994 39995 39996 39997 39998 39999 40000 40001 40002 40003 40004 40005 40006 40007 40008 40009 40010 40011 40012 40013 40014 40015 40016 40017 40018 40019 40020 40021 40022 40023 40024 40025 40026 40027 40028 40029 40030 40031 40032 40033 40034 40035 40036 40037 40038 40039 40040 40041 40042 40043 40044 40045 40046 40047 40048 40049 40050 40051 40052 40053 40054 40055 40056 40057 40058 40059 40060 40061 40062 40063 40064 40065 40066 40067 40068 40069 40070 40071 40072 40073 40074 40075 40076 40077 40078 40079 40080 40081 40082 40083 40084 40085 40086 40087 40088 40089 40090 40091 40092 40093 40094 40095 40096 40097 40098 40099 40100 40101 40102 40103 40104 40105 40106 40107 40108 40109 40110 40111 40112 40113 40114 40115 40116 40117 40118 40119 40120 40121 40122 40123 40124 40125 40126 40127 40128 40129 40130 40131 40132 40133 40134 40135 40136 40137 40138 40139 40140 40141 40142 40143 40144 40145 40146 40147 40148 40149 40150 40151 40152 40153 40154 40155 40156 40157 40158 40159 40160 40161 40162 40163 40164 40165 40166 40167 40168 40169 40170 40171 40172 40173 40174 40175 40176 40177 40178 40179 40180 40181 40182 40183 40184 40185 40186 40187 40188 40189 40190 40191 40192 40193 40194 40195 40196 40197 40198 40199 40200 40201 40202 40203 40204 40205 40206 40207 40208 40209 40210 40211 40212 40213 40214 40215 40216 40217 40218 40219 40220 40221 40222 40223 40224 40225 40226 40227 40228 40229 40230 40231 40232 40233 40234 40235 40236 40237 40238 40239 40240 40241 40242 40243 40244 40245 40246 40247 40248 40249 40250 40251 40252 40253 40254 40255 40256 40257 40258 40259 40260 40261 40262 40263 40264 40265 40266 40267 40268 40269 40270 40271 40272 40273 40274 40275 40276 40277 40278 40279 40280 40281 40282 40283 40284 40285 40286 40287 40288 40289 40290 40291 40292 40293 40294 40295 40296 40297 40298 40299 40300 40301 40302 40303 40304 40305 40306 40307 40308 40309 40310 40311 40312 40313 40314 40315 40316 40317 40318 40319 40320 40321 40322 40323 40324 40325 40326 40327 40328 40329 40330 40331 40332 40333 40334 40335 40336 40337 40338 40339 40340 40341 40342 40343 40344 40345 40346 40347 40348 40349 40350 40351 40352 40353 40354 40355 40356 40357 40358 40359 40360 40361 40362 40363 40364 40365 40366 40367 40368 40369 40370 40371 40372 40373 40374 40375 40376 40377 40378 40379 40380 40381 40382 40383 40384 40385 40386 40387 40388 40389 40390 40391 40392 40393 40394 40395 40396 40397 40398 40399 40400 40401 40402 40403 40404 40405 40406 40407 40408 40409 40410 40411 40412 40413 40414 40415 40416 40417 40418 40419 40420 40421 40422 40423 40424 40425 40426 40427 40428 40429 40430 40431 40432 40433 40434 40435 40436 40437 40438 40439 40440 40441 40442 40443 40444 40445 40446 40447 40448 40449 40450 40451 40452 40453 40454 40455 40456 40457 40458 40459 40460 40461 40462 40463 40464 40465 40466 40467 40468 40469 40470 40471 40472 40473 40474 40475 40476 40477 40478 40479 40480 40481 40482 40483 40484 40485 40486 40487 40488 40489 40490 40491 40492 40493 40494 40495 40496 40497 40498 40499 40500 40501 40502 40503 40504 40505 40506 40507 40508 40509 40510 40511 40512 40513 40514 40515 40516 40517 40518 40519 40520 40521 40522 40523 40524 40525 40526 40527 40528 40529 40530 40531 40532 40533 40534 40535 40536 40537 40538 40539 40540 40541 40542 40543 40544 40545 40546 40547 40548 40549 40550 40551 40552 40553 40554 40555 40556 40557 40558 40559 40560 40561 40562 40563 40564 40565 40566 40567 40568 40569 40570 40571 40572 40573 40574 40575 40576 40577 40578 40579 40580 40581 40582 40583 40584 40585 40586 40587 40588 40589 40590 40591 40592 40593 40594 40595 40596 40597 40598 40599 40600 40601 40602 40603 40604 40605 40606 40607 40608 40609 40610 40611 40612 40613 40614 40615 40616 40617 40618 40619 40620 40621 40622 40623 40624 40625 40626 40627 40628 40629 40630 40631 40632 40633 40634 40635 40636 40637 40638 40639 40640 40641 40642 40643 40644 40645 40646 40647 40648 40649 40650 40651 40652 40653 40654 40655 40656 40657 40658 40659 40660 40661 40662 40663 40664 40665 40666 40667 40668 40669 40670 40671 40672 40673 40674 40675 40676 40677 40678 40679 40680 40681 40682 40683 40684 40685 40686 40687 40688 40689 40690 40691 40692 40693 40694 40695 40696 40697 40698 40699 40700 40701 40702 40703 40704 40705 40706 40707 40708 40709 40710 40711 40712 40713 40714 40715 40716 40717 40718 40719 40720 40721 40722 40723 40724 40725 40726 40727 40728 40729 40730 40731 40732 40733 40734 40735 40736 40737 40738 40739 40740 40741 40742 40743 40744 40745 40746 40747 40748 40749 40750 40751 40752 40753 40754 40755 40756 40757 40758 40759 40760 40761 40762 40763 40764 40765 40766 40767 40768 40769 40770 40771 40772 40773 40774 40775 40776 40777 40778 40779 40780 40781 40782 40783 40784 40785 40786 40787 40788 40789 40790 40791 40792 40793 40794 40795 40796 40797 40798 40799 40800 40801 40802 40803 40804 40805 40806 40807 40808 40809 40810 40811 40812 40813 40814 40815 40816 40817 40818 40819 40820 40821 40822 40823 40824 40825 40826 40827 40828 40829 40830 40831 40832 40833 40834 40835 40836 40837 40838 40839 40840 40841 40842 40843 40844 40845 40846 40847 40848 40849 40850 40851 40852 40853 40854 40855 40856 40857 40858 40859 40860 40861 40862 40863 40864 40865 40866 40867 40868 40869 40870 40871 40872 40873 40874 40875 40876 40877 40878 40879 40880 40881 40882 40883 40884 40885 40886 40887 40888 40889 40890 40891 40892 40893 40894 40895 40896 40897 40898 40899 40900 40901 40902 40903 40904 40905 40906 40907 40908 40909 40910 40911 40912 40913 40914 40915 40916 40917 40918 40919 40920 40921 40922 40923 40924 40925 40926 40927 40928 40929 40930 40931 40932 40933 40934 40935 40936 40937 40938 40939 40940 40941 40942 40943 40944 40945 40946 40947 40948 40949 40950 40951 40952 40953 40954 40955 40956 40957 40958 40959 40960 40961 40962 40963 40964 40965 40966 40967 40968 40969 40970 40971 40972 40973 40974 40975 40976 40977 40978 40979 40980 40981 40982 40983 40984 40985 40986 40987 40988 40989 40990 40991 40992 40993 40994 40995 40996 40997 40998 40999 41000 41001 41002 41003 41004 41005 41006 41007 41008 41009 41010 41011 41012 41013 41014 41015 41016 41017 41018 41019 41020 41021 41022 41023 41024 41025 41026 41027 41028 41029 41030 41031 41032 41033 41034 41035 41036 41037 41038 41039 41040 41041 41042 41043 41044 41045 41046 41047 41048 41049 41050 41051 41052 41053 41054 41055 41056 41057 41058 41059 41060 41061 41062 41063 41064 41065 41066 41067 41068 41069 41070 41071 41072 41073 41074 41075 41076 41077 41078 41079 41080 41081 41082 41083 41084 41085 41086 41087 41088 41089 41090 41091 41092 41093 41094 41095 41096 41097 41098 41099 41100 41101 41102 41103 41104 41105 41106 41107 41108 41109 41110 41111 41112 41113 41114 41115 41116 41117 41118 41119 41120 41121 41122 41123 41124 41125 41126 41127 41128 41129 41130 41131 41132 41133 41134 41135 41136 41137 41138 41139 41140 41141 41142 41143 41144 41145 41146 41147 41148 41149 41150 41151 41152 41153 41154 41155 41156 41157 41158 41159 41160 41161 41162 41163 41164 41165 41166 41167 41168 41169 41170 41171 41172 41173 41174 41175 41176 41177 41178 41179 41180 41181 41182 41183 41184 41185 41186 41187 41188 41189 41190 41191 41192 41193 41194 41195 41196 41197 41198 41199 41200 41201 41202 41203 41204 41205 41206 41207 41208 41209 41210 41211 41212 41213 41214 41215 41216 41217 41218 41219 41220 41221 41222 41223 41224 41225 41226 41227 41228 41229 41230 41231 41232 41233 41234 41235 41236 41237 41238 41239 41240 41241 41242 41243 41244 41245 41246 41247 41248 41249 41250 41251 41252 41253 41254 41255 41256 41257 41258 41259 41260 41261 41262 41263 41264 41265 41266 41267 41268 41269 41270 41271 41272 41273 41274 41275 41276 41277 41278 41279 41280 41281 41282 41283 41284 41285 41286 41287 41288 41289 41290 41291 41292 41293 41294 41295 41296 41297 41298 41299 41300 41301 41302 41303 41304 41305 41306 41307 41308 41309 41310 41311 41312 41313 41314 41315 41316 41317 41318 41319 41320 41321 41322 41323 41324 41325 41326 41327 41328 41329 41330 41331 41332 41333 41334 41335 41336 41337 41338 41339 41340 41341 41342 41343 41344 41345 41346 41347 41348 41349 41350 41351 41352 41353 41354 41355 41356 41357 41358 41359 41360 41361 41362 41363 41364 41365 41366 41367 41368 41369 41370 41371 41372 41373 41374 41375 41376 41377 41378 41379 41380 41381 41382 41383 41384 41385 41386 41387 41388 41389 41390 41391 41392 41393 41394 41395 41396 41397 41398 41399 41400 41401 41402 41403 41404 41405 41406 41407 41408 41409 41410 41411 41412 41413 41414 41415 41416 41417 41418 41419 41420 41421 41422 41423 41424 41425 41426 41427 41428 41429 41430 41431 41432 41433 41434 41435 41436 41437 41438 41439 41440 41441 41442 41443 41444 41445 41446 41447 41448 41449 41450 41451 41452 41453 41454 41455 41456 41457 41458 41459 41460 41461 41462 41463 41464 41465 41466 41467 41468 41469 41470 41471 41472 41473 41474 41475 41476 41477 41478 41479 41480 41481 41482 41483 41484 41485 41486 41487 41488 41489 41490 41491 41492 41493 41494 41495 41496 41497 41498 41499 41500 41501 41502 41503 41504 41505 41506 41507 41508 41509 41510 41511 41512 41513 41514 41515 41516 41517 41518 41519 41520 41521 41522 41523 41524 41525 41526 41527 41528 41529 41530 41531 41532 41533 41534 41535 41536 41537 41538 41539 41540 41541 41542 41543 41544 41545 41546 41547 41548 41549 41550 41551 41552 41553 41554 41555 41556 41557 41558 41559 41560 41561 41562 41563 41564 41565 41566 41567 41568 41569 41570 41571 41572 41573 41574 41575 41576 41577 41578 41579 41580 41581 41582 41583 41584 41585 41586 41587 41588 41589 41590 41591 41592 41593 41594 41595 41596 41597 41598 41599 41600 41601 41602 41603 41604 41605 41606 41607 41608 41609 41610 41611 41612 41613 41614 41615 41616 41617 41618 41619 41620 41621 41622 41623 41624 41625 41626 41627 41628 41629 41630 41631 41632 41633 41634 41635 41636 41637 41638 41639 41640 41641 41642 41643 41644 41645 41646 41647 41648 41649 41650 41651 41652 41653 41654 41655 41656 41657 41658 41659 41660 41661 41662 41663 41664 41665 41666 41667 41668 41669 41670 41671 41672 41673 41674 41675 41676 41677 41678 41679 41680 41681 41682 41683 41684 41685 41686 41687 41688 41689 41690 41691 41692 41693 41694 41695 41696 41697 41698 41699 41700 41701 41702 41703 41704 41705 41706 41707 41708 41709 41710 41711 41712 41713 41714 41715 41716 41717 41718 41719 41720 41721 41722 41723 41724 41725 41726 41727 41728 41729 41730 41731 41732 41733 41734 41735 41736 41737 41738 41739 41740 41741 41742 41743 41744 41745 41746 41747 41748 41749 41750 41751 41752 41753 41754 41755 41756 41757 41758 41759 41760 41761 41762 41763 41764 41765 41766 41767 41768 41769 41770 41771 41772 41773 41774 41775 41776 41777 41778 41779 41780 41781 41782 41783 41784 41785 41786 41787 41788 41789 41790 41791 41792 41793 41794 41795 41796 41797 41798 41799 41800 41801 41802 41803 41804 41805 41806 41807 41808 41809 41810 41811 41812 41813 41814 41815 41816 41817 41818 41819 41820 41821 41822 41823 41824 41825 41826 41827 41828 41829 41830 41831 41832 41833 41834 41835 41836 41837 41838 41839 41840 41841 41842 41843 41844 41845 41846 41847 41848 41849 41850 41851 41852 41853 41854 41855 41856 41857 41858 41859 41860 41861 41862 41863 41864 41865 41866 41867 41868 41869 41870 41871 41872 41873 41874 41875 41876 41877 41878 41879 41880 41881 41882 41883 41884 41885 41886 41887 41888 41889 41890 41891 41892 41893 41894 41895 41896 41897 41898 41899 41900 41901 41902 41903 41904 41905 41906 41907 41908 41909 41910 41911 41912 41913 41914 41915 41916 41917 41918 41919 41920 41921 41922 41923 41924 41925 41926 41927 41928 41929 41930 41931 41932 41933 41934 41935 41936 41937 41938 41939 41940 41941 41942 41943 41944 41945 41946 41947 41948 41949 41950 41951 41952 41953 41954 41955 41956 41957 41958 41959 41960 41961 41962 41963 41964 41965 41966 41967 41968 41969 41970 41971 41972 41973 41974 41975 41976 41977 41978 41979 41980 41981 41982 41983 41984 41985 41986 41987 41988 41989 41990 41991 41992 41993 41994 41995 41996 41997 41998 41999 42000 42001 42002 42003 42004 42005 42006 42007 42008 42009 42010 42011 42012 42013 42014 42015 42016 42017 42018 42019 42020 42021 42022 42023 42024 42025 42026 42027 42028 42029 42030 42031 42032 42033 42034 42035 42036 42037 42038 42039 42040 42041 42042 42043 42044 42045 42046 42047 42048 42049 42050 42051 42052 42053 42054 42055 42056 42057 42058 42059 42060 42061 42062 42063 42064 42065 42066 42067 42068 42069 42070 42071 42072 42073 42074 42075 42076 42077 42078 42079 42080 42081 42082 42083 42084 42085 42086 42087 42088 42089 42090 42091 42092 42093 42094 42095 42096 42097 42098 42099 42100 42101 42102 42103 42104 42105 42106 42107 42108 42109 42110 42111 42112 42113 42114 42115 42116 42117 42118 42119 42120 42121 42122 42123 42124 42125 42126 42127 42128 42129 42130 42131 42132 42133 42134 42135 42136 42137 42138 42139 42140 42141 42142 42143 42144 42145 42146 42147 42148 42149 42150 42151 42152 42153 42154 42155 42156 42157 42158 42159 42160 42161 42162 42163 42164 42165 42166 42167 42168 42169 42170 42171 42172 42173 42174 42175 42176 42177 42178 42179 42180 42181 42182 42183 42184 42185 42186 42187 42188 42189 42190 42191 42192 42193 42194 42195 42196 42197 42198 42199 42200 42201 42202 42203 42204 42205 42206 42207 42208 42209 42210 42211 42212 42213 42214 42215 42216 42217 42218 42219 42220 42221 42222 42223 42224 42225 42226 42227 42228 42229 42230 42231 42232 42233 42234 42235 42236 42237 42238 42239 42240 42241 42242 42243 42244 42245 42246 42247 42248 42249 42250 42251 42252 42253 42254 42255 42256 42257 42258 42259 42260 42261 42262 42263 42264 42265 42266 42267 42268 42269 42270 42271 42272 42273 42274 42275 42276 42277 42278 42279 42280 42281 42282 42283 42284 42285 42286 42287 42288 42289 42290 42291 42292 42293 42294 42295 42296 42297 42298 42299 42300 42301 42302 42303 42304 42305 42306 42307 42308 42309 42310 42311 42312 42313 42314 42315 42316 42317 42318 42319 42320 42321 42322 42323 42324 42325 42326 42327 42328 42329 42330 42331 42332 42333 42334 42335 42336 42337 42338 42339 42340 42341 42342 42343 42344 42345 42346 42347 42348 42349 42350 42351 42352 42353 42354 42355 42356 42357 42358 42359 42360 42361 42362 42363 42364 42365 42366 42367 42368 42369 42370 42371 42372 42373 42374 42375 42376 42377 42378 42379 42380 42381 42382 42383 42384 42385 42386 42387 42388 42389 42390 42391 42392 42393 42394 42395 42396 42397 42398 42399 42400 42401 42402 42403 42404 42405 42406 42407 42408 42409 42410 42411 42412 42413 42414 42415 42416 42417 42418 42419 42420 42421 42422 42423 42424 42425 42426 42427 42428 42429 42430 42431 42432 42433 42434 42435 42436 42437 42438 42439 42440 42441 42442 42443 42444 42445 42446 42447 42448 42449 42450 42451 42452 42453 42454 42455 42456 42457 42458 42459 42460 42461 42462 42463 42464 42465 42466 42467 42468 42469 42470 42471 42472 42473 42474 42475 42476 42477 42478 42479 42480 42481 42482 42483 42484 42485 42486 42487 42488 42489 42490 42491 42492 42493 42494 42495 42496 42497 42498 42499 42500 42501 42502 42503 42504 42505 42506 42507 42508 42509 42510 42511 42512 42513 42514 42515 42516 42517 42518 42519 42520 42521 42522 42523 42524 42525 42526 42527 42528 42529 42530 42531 42532 42533 42534 42535 42536 42537 42538 42539 42540 42541 42542 42543 42544 42545 42546 42547 42548 42549 42550 42551 42552 42553 42554 42555 42556 42557 42558 42559 42560 42561 42562 42563 42564 42565 42566 42567 42568 42569 42570 42571 42572 42573 42574 42575 42576 42577 42578 42579 42580 42581 42582 42583 42584 42585 42586 42587 42588 42589 42590 42591 42592 42593 42594 42595 42596 42597 42598 42599 42600 42601 42602 42603 42604 42605 42606 42607 42608 42609 42610 42611 42612 42613 42614 42615 42616 42617 42618 42619 42620 42621 42622 42623 42624 42625 42626 42627 42628 42629 42630 42631 42632 42633 42634 42635 42636 42637 42638 42639 42640 42641 42642 42643 42644 42645 42646 42647 42648 42649 42650 42651 42652 42653 42654 42655 42656 42657 42658 42659 42660 42661 42662 42663 42664 42665 42666 42667 42668 42669 42670 42671 42672 42673 42674 42675 42676 42677 42678 42679 42680 42681 42682 42683 42684 42685 42686 42687 42688 42689 42690 42691 42692 42693 42694 42695 42696 42697 42698 42699 42700 42701 42702 42703 42704 42705 42706 42707 42708 42709 42710 42711 42712 42713 42714 42715 42716 42717 42718 42719 42720 42721 42722 42723 42724 42725 42726 42727 42728 42729 42730 42731 42732 42733 42734 42735 42736 42737 42738 42739 42740 42741 42742 42743 42744 42745 42746 42747 42748 42749 42750 42751 42752 42753 42754 42755 42756 42757 42758 42759 42760 42761 42762 42763 42764 42765 42766 42767 42768 42769 42770 42771 42772 42773 42774 42775 42776 42777 42778 42779 42780 42781 42782 42783 42784 42785 42786 42787 42788 42789 42790 42791 42792 42793 42794 42795 42796 42797 42798 42799 42800 42801 42802 42803 42804 42805 42806 42807 42808 42809 42810 42811 42812 42813 42814 42815 42816 42817 42818 42819 42820 42821 42822 42823 42824 42825 42826 42827 42828 42829 42830 42831 42832 42833 42834 42835 42836 42837 42838 42839 42840 42841 42842 42843 42844 42845 42846 42847 42848 42849 42850 42851 42852 42853 42854 42855 42856 42857 42858 42859 42860 42861 42862 42863 42864 42865 42866 42867 42868 42869 42870 42871 42872 42873 42874 42875 42876 42877 42878 42879 42880 42881 42882 42883 42884 42885 42886 42887 42888 42889 42890 42891 42892 42893 42894 42895 42896 42897 42898 42899 42900 42901 42902 42903 42904 42905 42906 42907 42908 42909 42910 42911 42912 42913 42914 42915 42916 42917 42918 42919 42920 42921 42922 42923 42924 42925 42926 42927 42928 42929 42930 42931 42932 42933 42934 42935 42936 42937 42938 42939 42940 42941 42942 42943 42944 42945 42946 42947 42948 42949 42950 42951 42952 42953 42954 42955 42956 42957 42958 42959 42960 42961 42962 42963 42964 42965 42966 42967 42968 42969 42970 42971 42972 42973 42974 42975 42976 42977 42978 42979 42980 42981 42982 42983 42984 42985 42986 42987 42988 42989 42990 42991 42992 42993 42994 42995 42996 42997 42998 42999 43000 43001 43002 43003 43004 43005 43006 43007 43008 43009 43010 43011 43012 43013 43014 43015 43016 43017 43018 43019 43020 43021 43022 43023 43024 43025 43026 43027 43028 43029 43030 43031 43032 43033 43034 43035 43036 43037 43038 43039 43040 43041 43042 43043 43044 43045 43046 43047 43048 43049 43050 43051 43052 43053 43054 43055 43056 43057 43058 43059 43060 43061 43062 43063 43064 43065 43066 43067 43068 43069 43070 43071 43072 43073 43074 43075 43076 43077 43078 43079 43080 43081 43082 43083 43084 43085 43086 43087 43088 43089 43090 43091 43092 43093 43094 43095 43096 43097 43098 43099 43100 43101 43102 43103 43104 43105 43106 43107 43108 43109 43110 43111 43112 43113 43114 43115 43116 43117 43118 43119 43120 43121 43122 43123 43124 43125 43126 43127 43128 43129 43130 43131 43132 43133 43134 43135 43136 43137 43138 43139 43140 43141 43142 43143 43144 43145 43146 43147 43148 43149 43150 43151 43152 43153 43154 43155 43156 43157 43158 43159 43160 43161 43162 43163 43164 43165 43166 43167 43168 43169 43170 43171 43172 43173 43174 43175 43176 43177 43178 43179 43180 43181 43182 43183 43184 43185 43186 43187 43188 43189 43190 43191 43192 43193 43194 43195 43196 43197 43198 43199 43200 43201 43202 43203 43204 43205 43206 43207 43208 43209 43210 43211 43212 43213 43214 43215 43216 43217 43218 43219 43220 43221 43222 43223 43224 43225 43226 43227 43228 43229 43230 43231 43232 43233 43234 43235 43236 43237 43238 43239 43240 43241 43242 43243 43244 43245 43246 43247 43248 43249 43250 43251 43252 43253 43254 43255 43256 43257 43258 43259 43260 43261 43262 43263 43264 43265 43266 43267 43268 43269 43270 43271 43272 43273 43274 43275 43276 43277 43278 43279 43280 43281 43282 43283 43284 43285 43286 43287 43288 43289 43290 43291 43292 43293 43294 43295 43296 43297 43298 43299 43300 43301 43302 43303 43304 43305 43306 43307 43308 43309 43310 43311 43312 43313 43314 43315 43316 43317 43318 43319 43320 43321 43322 43323 43324 43325 43326 43327 43328 43329 43330 43331 43332 43333 43334 43335 43336 43337 43338 43339 43340 43341 43342 43343 43344 43345 43346 43347 43348 43349 43350 43351 43352 43353 43354 43355 43356 43357 43358 43359 43360 43361 43362 43363 43364 43365 43366 43367 43368 43369 43370 43371 43372 43373 43374 43375 43376 43377 43378 43379 43380 43381 43382 43383 43384 43385 43386 43387 43388 43389 43390 43391 43392 43393 43394 43395 43396 43397 43398 43399 43400 43401 43402 43403 43404 43405 43406 43407 43408 43409 43410 43411 43412 43413 43414 43415 43416 43417 43418 43419 43420 43421 43422 43423 43424 43425 43426 43427 43428 43429 43430 43431 43432 43433 43434 43435 43436 43437 43438 43439 43440 43441 43442 43443 43444 43445 43446 43447 43448 43449 43450 43451 43452 43453 43454 43455 43456 43457 43458 43459 43460 43461 43462 43463 43464 43465 43466 43467 43468 43469 43470 43471 43472 43473 43474 43475 43476 43477 43478 43479 43480 43481 43482 43483 43484 43485 43486 43487 43488 43489 43490 43491 43492 43493 43494 43495 43496 43497 43498 43499 43500 43501 43502 43503 43504 43505 43506 43507 43508 43509 43510 43511 43512 43513 43514 43515 43516 43517 43518 43519 43520 43521 43522 43523 43524 43525 43526 43527 43528 43529 43530 43531 43532 43533 43534 43535 43536 43537 43538 43539 43540 43541 43542 43543 43544 43545 43546 43547 43548 43549 43550 43551 43552 43553 43554 43555 43556 43557 43558 43559 43560 43561 43562 43563 43564 43565 43566 43567 43568 43569 43570 43571 43572 43573 43574 43575 43576 43577 43578 43579 43580 43581 43582 43583 43584 43585 43586 43587 43588 43589 43590 43591 43592 43593 43594 43595 43596 43597 43598 43599 43600 43601 43602 43603 43604 43605 43606 43607 43608 43609 43610 43611 43612 43613 43614 43615 43616 43617 43618 43619 43620 43621 43622 43623 43624 43625 43626 43627 43628 43629 43630 43631 43632 43633 43634 43635 43636 43637 43638 43639 43640 43641 43642 43643 43644 43645 43646 43647 43648 43649 43650 43651 43652 43653 43654 43655 43656 43657 43658 43659 43660 43661 43662 43663 43664 43665 43666 43667 43668 43669 43670 43671 43672 43673 43674 43675 43676 43677 43678 43679 43680 43681 43682 43683 43684 43685 43686 43687 43688 43689 43690 43691 43692 43693 43694 43695 43696 43697 43698 43699 43700 43701 43702 43703 43704 43705 43706 43707 43708 43709 43710 43711 43712 43713 43714 43715 43716 43717 43718 43719 43720 43721 43722 43723 43724 43725 43726 43727 43728 43729 43730 43731 43732 43733 43734 43735 43736 43737 43738 43739 43740 43741 43742 43743 43744 43745 43746 43747 43748 43749 43750 43751 43752 43753 43754 43755 43756 43757 43758 43759 43760 43761 43762 43763 43764 43765 43766 43767 43768 43769 43770 43771 43772 43773 43774 43775 43776 43777 43778 43779 43780 43781 43782 43783 43784 43785 43786 43787 43788 43789 43790 43791 43792 43793 43794 43795 43796 43797 43798 43799 43800 43801 43802 43803 43804 43805 43806 43807 43808 43809 43810 43811 43812 43813 43814 43815 43816 43817 43818 43819 43820 43821 43822 43823 43824 43825 43826 43827 43828 43829 43830 43831 43832 43833 43834 43835 43836 43837 43838 43839 43840 43841 43842 43843 43844 43845 43846 43847 43848 43849 43850 43851 43852 43853 43854 43855 43856 43857 43858 43859 43860 43861 43862 43863 43864 43865 43866 43867 43868 43869 43870 43871 43872 43873 43874 43875 43876 43877 43878 43879 43880 43881 43882 43883 43884 43885 43886 43887 43888 43889 43890 43891 43892 43893 43894 43895 43896 43897 43898 43899 43900 43901 43902 43903 43904 43905 43906 43907 43908 43909 43910 43911 43912 43913 43914 43915 43916 43917 43918 43919 43920 43921 43922 43923 43924 43925 43926 43927 43928 43929 43930 43931 43932 43933 43934 43935 43936 43937 43938 43939 43940 43941 43942 43943 43944 43945 43946 43947 43948 43949 43950 43951 43952 43953 43954 43955 43956 43957 43958 43959 43960 43961 43962 43963 43964 43965 43966 43967 43968 43969 43970 43971 43972 43973 43974 43975 43976 43977 43978 43979 43980 43981 43982 43983 43984 43985 43986 43987 43988 43989 43990 43991 43992 43993 43994 43995 43996 43997 43998 43999 44000 44001 44002 44003 44004 44005 44006 44007 44008 44009 44010 44011 44012 44013 44014 44015 44016 44017 44018 44019 44020 44021 44022 44023 44024 44025 44026 44027 44028 44029 44030 44031 44032 44033 44034 44035 44036 44037 44038 44039 44040 44041 44042 44043 44044 44045 44046 44047 44048 44049 44050 44051 44052 44053 44054 44055 44056 44057 44058 44059 44060 44061 44062 44063 44064 44065 44066 44067 44068 44069 44070 44071 44072 44073 44074 44075 44076 44077 44078 44079 44080 44081 44082 44083 44084 44085 44086 44087 44088 44089 44090 44091 44092 44093 44094 44095 44096 44097 44098 44099 44100 44101 44102 44103 44104 44105 44106 44107 44108 44109 44110 44111 44112 44113 44114 44115 44116 44117 44118 44119 44120 44121 44122 44123 44124 44125 44126 44127 44128 44129 44130 44131 44132 44133 44134 44135 44136 44137 44138 44139 44140 44141 44142 44143 44144 44145 44146 44147 44148 44149 44150 44151 44152 44153 44154 44155 44156 44157 44158 44159 44160 44161 44162 44163 44164 44165 44166 44167 44168 44169 44170 44171 44172 44173 44174 44175 44176 44177 44178 44179 44180 44181 44182 44183 44184 44185 44186 44187 44188 44189 44190 44191 44192 44193 44194 44195 44196 44197 44198 44199 44200 44201 44202 44203 44204 44205 44206 44207 44208 44209 44210 44211 44212 44213 44214 44215 44216 44217 44218 44219 44220 44221 44222 44223 44224 44225 44226 44227 44228 44229 44230 44231 44232 44233 44234 44235 44236 44237 44238 44239 44240 44241 44242 44243 44244 44245 44246 44247 44248 44249 44250 44251 44252 44253 44254 44255 44256 44257 44258 44259 44260 44261 44262 44263 44264 44265 44266 44267 44268 44269 44270 44271 44272 44273 44274 44275 44276 44277 44278 44279 44280 44281 44282 44283 44284 44285 44286 44287 44288 44289 44290 44291 44292 44293 44294 44295 44296 44297 44298 44299 44300 44301 44302 44303 44304 44305 44306 44307 44308 44309 44310 44311 44312 44313 44314 44315 44316 44317 44318 44319 44320 44321 44322 44323 44324 44325 44326 44327 44328 44329 44330 44331 44332 44333 44334 44335 44336 44337 44338 44339 44340 44341 44342 44343 44344 44345 44346 44347 44348 44349 44350 44351 44352 44353 44354 44355 44356 44357 44358 44359 44360 44361 44362 44363 44364 44365 44366 44367 44368 44369 44370 44371 44372 44373 44374 44375 44376 44377 44378 44379 44380 44381 44382 44383 44384 44385 44386 44387 44388 44389 44390 44391 44392 44393 44394 44395 44396 44397 44398 44399 44400 44401 44402 44403 44404 44405 44406 44407 44408 44409 44410 44411 44412 44413 44414 44415 44416 44417 44418 44419 44420 44421 44422 44423 44424 44425 44426 44427 44428 44429 44430 44431 44432 44433 44434 44435 44436 44437 44438 44439 44440 44441 44442 44443 44444 44445 44446 44447 44448 44449 44450 44451 44452 44453 44454 44455 44456 44457 44458 44459 44460 44461 44462 44463 44464 44465 44466 44467 44468 44469 44470 44471 44472 44473 44474 44475 44476 44477 44478 44479 44480 44481 44482 44483 44484 44485 44486 44487 44488 44489 44490 44491 44492 44493 44494 44495 44496 44497 44498 44499 44500 44501 44502 44503 44504 44505 44506 44507 44508 44509 44510 44511 44512 44513 44514 44515 44516 44517 44518 44519 44520 44521 44522 44523 44524 44525 44526 44527 44528 44529 44530 44531 44532 44533 44534 44535 44536 44537 44538 44539 44540 44541 44542 44543 44544 44545 44546 44547 44548 44549 44550 44551 44552 44553 44554 44555 44556 44557 44558 44559 44560 44561 44562 44563 44564 44565 44566 44567 44568 44569 44570 44571 44572 44573 44574 44575 44576 44577 44578 44579 44580 44581 44582 44583 44584 44585 44586 44587 44588 44589 44590 44591 44592 44593 44594 44595 44596 44597 44598 44599 44600 44601 44602 44603 44604 44605 44606 44607 44608 44609 44610 44611 44612 44613 44614 44615 44616 44617 44618 44619 44620 44621 44622 44623 44624 44625 44626 44627 44628 44629 44630 44631 44632 44633 44634 44635 44636 44637 44638 44639 44640 44641 44642 44643 44644 44645 44646 44647 44648 44649 44650 44651 44652 44653 44654 44655 44656 44657 44658 44659 44660 44661 44662 44663 44664 44665 44666 44667 44668 44669 44670 44671 44672 44673 44674 44675 44676 44677 44678 44679 44680 44681 44682 44683 44684 44685 44686 44687 44688 44689 44690 44691 44692 44693 44694 44695 44696 44697 44698 44699 44700 44701 44702 44703 44704 44705 44706 44707 44708 44709 44710 44711 44712 44713 44714 44715 44716 44717 44718 44719 44720 44721 44722 44723 44724 44725 44726 44727 44728 44729 44730 44731 44732 44733 44734 44735 44736 44737 44738 44739 44740 44741 44742 44743 44744 44745 44746 44747 44748 44749 44750 44751 44752 44753 44754 44755 44756 44757 44758 44759 44760 44761 44762 44763 44764 44765 44766 44767 44768 44769 44770 44771 44772 44773 44774 44775 44776 44777 44778 44779 44780 44781 44782 44783 44784 44785 44786 44787 44788 44789 44790 44791 44792 44793 44794 44795 44796 44797 44798 44799 44800 44801 44802 44803 44804 44805 44806 44807 44808 44809 44810 44811 44812 44813 44814 44815 44816 44817 44818 44819 44820 44821 44822 44823 44824 44825 44826 44827 44828 44829 44830 44831 44832 44833 44834 44835 44836 44837 44838 44839 44840 44841 44842 44843 44844 44845 44846 44847 44848 44849 44850 44851 44852 44853 44854 44855 44856 44857 44858 44859 44860 44861 44862 44863 44864 44865 44866 44867 44868 44869 44870 44871 44872 44873 44874 44875 44876 44877 44878 44879 44880 44881 44882 44883 44884 44885 44886 44887 44888 44889 44890 44891 44892 44893 44894 44895 44896 44897 44898 44899 44900 44901 44902 44903 44904 44905 44906 44907 44908 44909 44910 44911 44912 44913 44914 44915 44916 44917 44918 44919 44920 44921 44922 44923 44924 44925 44926 44927 44928 44929 44930 44931 44932 44933 44934 44935 44936 44937 44938 44939 44940 44941 44942 44943 44944 44945 44946 44947 44948 44949 44950 44951 44952 44953 44954 44955 44956 44957 44958 44959 44960 44961 44962 44963 44964 44965 44966 44967 44968 44969 44970 44971 44972 44973 44974 44975 44976 44977 44978 44979 44980 44981 44982 44983 44984 44985 44986 44987 44988 44989 44990 44991 44992 44993 44994 44995 44996 44997 44998 44999 45000 45001 45002 45003 45004 45005 45006 45007 45008 45009 45010 45011 45012 45013 45014 45015 45016 45017 45018 45019 45020 45021 45022 45023 45024 45025 45026 45027 45028 45029 45030 45031 45032 45033 45034 45035 45036 45037 45038 45039 45040 45041 45042 45043 45044 45045 45046 45047 45048 45049 45050 45051 45052 45053 45054 45055 45056 45057 45058 45059 45060 45061 45062 45063 45064 45065 45066 45067 45068 45069 45070 45071 45072 45073 45074 45075 45076 45077 45078 45079 45080 45081 45082 45083 45084 45085 45086 45087 45088 45089 45090 45091 45092 45093 45094 45095 45096 45097 45098 45099 45100 45101 45102 45103 45104 45105 45106 45107 45108 45109 45110 45111 45112 45113 45114 45115 45116 45117 45118 45119 45120 45121 45122 45123 45124 45125 45126 45127 45128 45129 45130 45131 45132 45133 45134 45135 45136 45137 45138 45139 45140 45141 45142 45143 45144 45145 45146 45147 45148 45149 45150 45151 45152 45153 45154 45155 45156 45157 45158 45159 45160 45161 45162 45163 45164 45165 45166 45167 45168 45169 45170 45171 45172 45173 45174 45175 45176 45177 45178 45179 45180 45181 45182 45183 45184 45185 45186 45187 45188 45189 45190 45191 45192 45193 45194 45195 45196 45197 45198 45199 45200 45201 45202 45203 45204 45205 45206 45207 45208 45209 45210 45211 45212 45213 45214 45215 45216 45217 45218 45219 45220 45221 45222 45223 45224 45225 45226 45227 45228 45229 45230 45231 45232 45233 45234 45235 45236 45237 45238 45239 45240 45241 45242 45243 45244 45245 45246 45247 45248 45249 45250 45251 45252 45253 45254 45255 45256 45257 45258 45259 45260 45261 45262 45263 45264 45265 45266 45267 45268 45269 45270 45271 45272 45273 45274 45275 45276 45277 45278 45279 45280 45281 45282 45283 45284 45285 45286 45287 45288 45289 45290 45291 45292 45293 45294 45295 45296 45297 45298 45299 45300 45301 45302 45303 45304 45305 45306 45307 45308 45309 45310 45311 45312 45313 45314 45315 45316 45317 45318 45319 45320 45321 45322 45323 45324 45325 45326 45327 45328 45329 45330 45331 45332 45333 45334 45335 45336 45337 45338 45339 45340 45341 45342 45343 45344 45345 45346 45347 45348 45349 45350 45351 45352 45353 45354 45355 45356 45357 45358 45359 45360 45361 45362 45363 45364 45365 45366 45367 45368 45369 45370 45371 45372 45373 45374 45375 45376 45377 45378 45379 45380 45381 45382 45383 45384 45385 45386 45387 45388 45389 45390 45391 45392 45393 45394 45395 45396 45397 45398 45399 45400 45401 45402 45403 45404 45405 45406 45407 45408 45409 45410 45411 45412 45413 45414 45415 45416 45417 45418 45419 45420 45421 45422 45423 45424 45425 45426 45427 45428 45429 45430 45431 45432 45433 45434 45435 45436 45437 45438 45439 45440 45441 45442 45443 45444 45445 45446 45447 45448 45449 45450 45451 45452 45453 45454 45455 45456 45457 45458 45459 45460 45461 45462 45463 45464 45465 45466 45467 45468 45469 45470 45471 45472 45473 45474 45475 45476 45477 45478 45479 45480 45481 45482 45483 45484 45485 45486 45487 45488 45489 45490 45491 45492 45493 45494 45495 45496 45497 45498 45499 45500 45501 45502 45503 45504 45505 45506 45507 45508 45509 45510 45511 45512 45513 45514 45515 45516 45517 45518 45519 45520 45521 45522 45523 45524 45525 45526 45527 45528 45529 45530 45531 45532 45533 45534 45535 45536 45537 45538 45539 45540 45541 45542 45543 45544 45545 45546 45547 45548 45549 45550 45551 45552 45553 45554 45555 45556 45557 45558 45559 45560 45561 45562 45563 45564 45565 45566 45567 45568 45569 45570 45571 45572 45573 45574 45575 45576 45577 45578 45579 45580 45581 45582 45583 45584 45585 45586 45587 45588 45589 45590 45591 45592 45593 45594 45595 45596 45597 45598 45599 45600 45601 45602 45603 45604 45605 45606 45607 45608 45609 45610 45611 45612 45613 45614 45615 45616 45617 45618 45619 45620 45621 45622 45623 45624 45625 45626 45627 45628 45629 45630 45631 45632 45633 45634 45635 45636 45637 45638 45639 45640 45641 45642 45643 45644 45645 45646 45647 45648 45649 45650 45651 45652 45653 45654 45655 45656 45657 45658 45659 45660 45661 45662 45663 45664 45665 45666 45667 45668 45669 45670 45671 45672 45673 45674 45675 45676 45677 45678 45679 45680 45681 45682 45683 45684 45685 45686 45687 45688 45689 45690 45691 45692 45693 45694 45695 45696 45697 45698 45699 45700 45701 45702 45703 45704 45705 45706 45707 45708 45709 45710 45711 45712 45713 45714 45715 45716 45717 45718 45719 45720 45721 45722 45723 45724 45725 45726 45727 45728 45729 45730 45731 45732 45733 45734 45735 45736 45737 45738 45739 45740 45741 45742 45743 45744 45745 45746 45747 45748 45749 45750 45751 45752 45753 45754 45755 45756 45757 45758 45759 45760 45761 45762 45763 45764 45765 45766 45767 45768 45769 45770 45771 45772 45773 45774 45775 45776 45777 45778 45779 45780 45781 45782 45783 45784 45785 45786 45787 45788 45789 45790 45791 45792 45793 45794 45795 45796 45797 45798 45799 45800 45801 45802 45803 45804 45805 45806 45807 45808 45809 45810 45811 45812 45813 45814 45815 45816 45817 45818 45819 45820 45821 45822 45823 45824 45825 45826 45827 45828 45829 45830 45831 45832 45833 45834 45835 45836 45837 45838 45839 45840 45841 45842 45843 45844 45845 45846 45847 45848 45849 45850 45851 45852 45853 45854 45855 45856 45857 45858 45859 45860 45861 45862 45863 45864 45865 45866 45867 45868 45869 45870 45871 45872 45873 45874 45875 45876 45877 45878 45879 45880 45881 45882 45883 45884 45885 45886 45887 45888 45889 45890 45891 45892 45893 45894 45895 45896 45897 45898 45899 45900 45901 45902 45903 45904 45905 45906 45907 45908 45909 45910 45911 45912 45913 45914 45915 45916 45917 45918 45919 45920 45921 45922 45923 45924 45925 45926 45927 45928 45929 45930 45931 45932 45933 45934 45935 45936 45937 45938 45939 45940 45941 45942 45943 45944 45945 45946 45947 45948 45949 45950 45951 45952 45953 45954 45955 45956 45957 45958 45959 45960 45961 45962 45963 45964 45965 45966 45967 45968 45969 45970 45971 45972 45973 45974 45975 45976 45977 45978 45979 45980 45981 45982 45983 45984 45985 45986 45987 45988 45989 45990 45991 45992 45993 45994 45995 45996 45997 45998 45999 46000 46001 46002 46003 46004 46005 46006 46007 46008 46009 46010 46011 46012 46013 46014 46015 46016 46017 46018 46019 46020 46021 46022 46023 46024 46025 46026 46027 46028 46029 46030 46031 46032 46033 46034 46035 46036 46037 46038 46039 46040 46041 46042 46043 46044 46045 46046 46047 46048 46049 46050 46051 46052 46053 46054 46055 46056 46057 46058 46059 46060 46061 46062 46063 46064 46065 46066 46067 46068 46069 46070 46071 46072 46073 46074 46075 46076 46077 46078 46079 46080 46081 46082 46083 46084 46085 46086 46087 46088 46089 46090 46091 46092 46093 46094 46095 46096 46097 46098 46099 46100 46101 46102 46103 46104 46105 46106 46107 46108 46109 46110 46111 46112 46113 46114 46115 46116 46117 46118 46119 46120 46121 46122 46123 46124 46125 46126 46127 46128 46129 46130 46131 46132 46133 46134 46135 46136 46137 46138 46139 46140 46141 46142 46143 46144 46145 46146 46147 46148 46149 46150 46151 46152 46153 46154 46155 46156 46157 46158 46159 46160 46161 46162 46163 46164 46165 46166 46167 46168 46169 46170 46171 46172 46173 46174 46175 46176 46177 46178 46179 46180 46181 46182 46183 46184 46185 46186 46187 46188 46189 46190 46191 46192 46193 46194 46195 46196 46197 46198 46199 46200 46201 46202 46203 46204 46205 46206 46207 46208 46209 46210 46211 46212 46213 46214 46215 46216 46217 46218 46219 46220 46221 46222 46223 46224 46225 46226 46227 46228 46229 46230 46231 46232 46233 46234 46235 46236 46237 46238 46239 46240 46241 46242 46243 46244 46245 46246 46247 46248 46249 46250 46251 46252 46253 46254 46255 46256 46257 46258 46259 46260 46261 46262 46263 46264 46265 46266 46267 46268 46269 46270 46271 46272 46273 46274 46275 46276 46277 46278 46279 46280 46281 46282 46283 46284 46285 46286 46287 46288 46289 46290 46291 46292 46293 46294 46295 46296 46297 46298 46299 46300 46301 46302 46303 46304 46305 46306 46307 46308 46309 46310 46311 46312 46313 46314 46315 46316 46317 46318 46319 46320 46321 46322 46323 46324 46325 46326 46327 46328 46329 46330 46331 46332 46333 46334 46335 46336 46337 46338 46339 46340 46341 46342 46343 46344 46345 46346 46347 46348 46349 46350 46351 46352 46353 46354 46355 46356 46357 46358 46359 46360 46361 46362 46363 46364 46365 46366 46367 46368 46369 46370 46371 46372 46373 46374 46375 46376 46377 46378 46379 46380 46381 46382 46383 46384 46385 46386 46387 46388 46389 46390 46391 46392 46393 46394 46395 46396 46397 46398 46399 46400 46401 46402 46403 46404 46405 46406 46407 46408 46409 46410 46411 46412 46413 46414 46415 46416 46417 46418 46419 46420 46421 46422 46423 46424 46425 46426 46427 46428 46429 46430 46431 46432 46433 46434 46435 46436 46437 46438 46439 46440 46441 46442 46443 46444 46445 46446 46447 46448 46449 46450 46451 46452 46453 46454 46455 46456 46457 46458 46459 46460 46461 46462 46463 46464 46465 46466 46467 46468 46469 46470 46471 46472 46473 46474 46475 46476 46477 46478 46479 46480 46481 46482 46483 46484 46485 46486 46487 46488 46489 46490 46491 46492 46493 46494 46495 46496 46497 46498 46499 46500 46501 46502 46503 46504 46505 46506 46507 46508 46509 46510 46511 46512 46513 46514 46515 46516 46517 46518 46519 46520 46521 46522 46523 46524 46525 46526 46527 46528 46529 46530 46531 46532 46533 46534 46535 46536 46537 46538 46539 46540 46541 46542 46543 46544 46545 46546 46547 46548 46549 46550 46551 46552 46553 46554 46555 46556 46557 46558 46559 46560 46561 46562 46563 46564 46565 46566 46567 46568 46569 46570 46571 46572 46573 46574 46575 46576 46577 46578 46579 46580 46581 46582 46583 46584 46585 46586 46587 46588 46589 46590 46591 46592 46593 46594 46595 46596 46597 46598 46599 46600 46601 46602 46603 46604 46605 46606 46607 46608 46609 46610 46611 46612 46613 46614 46615 46616 46617 46618 46619 46620 46621 46622 46623 46624 46625 46626 46627 46628 46629 46630 46631 46632 46633 46634 46635 46636 46637 46638 46639 46640 46641 46642 46643 46644 46645 46646 46647 46648 46649 46650 46651 46652 46653 46654 46655 46656 46657 46658 46659 46660 46661 46662 46663 46664 46665 46666 46667 46668 46669 46670 46671 46672 46673 46674 46675 46676 46677 46678 46679 46680 46681 46682 46683 46684 46685 46686 46687 46688 46689 46690 46691 46692 46693 46694 46695 46696 46697 46698 46699 46700 46701 46702 46703 46704 46705 46706 46707 46708 46709 46710 46711 46712 46713 46714 46715 46716 46717 46718 46719 46720 46721 46722 46723 46724 46725 46726 46727 46728 46729 46730 46731 46732 46733 46734 46735 46736 46737 46738 46739 46740 46741 46742 46743 46744 46745 46746 46747 46748 46749 46750 46751 46752 46753 46754 46755 46756 46757 46758 46759 46760 46761 46762 46763 46764 46765 46766 46767 46768 46769 46770 46771 46772 46773 46774 46775 46776 46777 46778 46779 46780 46781 46782 46783 46784 46785 46786 46787 46788 46789 46790 46791 46792 46793 46794 46795 46796 46797 46798 46799 46800 46801 46802 46803 46804 46805 46806 46807 46808 46809 46810 46811 46812 46813 46814 46815 46816 46817 46818 46819 46820 46821 46822 46823 46824 46825 46826 46827 46828 46829 46830 46831 46832 46833 46834 46835 46836 46837 46838 46839 46840 46841 46842 46843 46844 46845 46846 46847 46848 46849 46850 46851 46852 46853 46854 46855 46856 46857 46858 46859 46860 46861 46862 46863 46864 46865 46866 46867 46868 46869 46870 46871 46872 46873 46874 46875 46876 46877 46878 46879 46880 46881 46882 46883 46884 46885 46886 46887 46888 46889 46890 46891 46892 46893 46894 46895 46896 46897 46898 46899 46900 46901 46902 46903 46904 46905 46906 46907 46908 46909 46910 46911 46912 46913 46914 46915 46916 46917 46918 46919 46920 46921 46922 46923 46924 46925 46926 46927 46928 46929 46930 46931 46932 46933 46934 46935 46936 46937 46938 46939 46940 46941 46942 46943 46944 46945 46946 46947 46948 46949 46950 46951 46952 46953 46954 46955 46956 46957 46958 46959 46960 46961 46962 46963 46964 46965 46966 46967 46968 46969 46970 46971 46972 46973 46974 46975 46976 46977 46978 46979 46980 46981 46982 46983 46984 46985 46986 46987 46988 46989 46990 46991 46992 46993 46994 46995 46996 46997 46998 46999 47000 47001 47002 47003 47004 47005 47006 47007 47008 47009 47010 47011 47012 47013 47014 47015 47016 47017 47018 47019 47020 47021 47022 47023 47024 47025 47026 47027 47028 47029 47030 47031 47032 47033 47034 47035 47036 47037 47038 47039 47040 47041 47042 47043 47044 47045 47046 47047 47048 47049 47050 47051 47052 47053 47054 47055 47056 47057 47058 47059 47060 47061 47062 47063 47064 47065 47066 47067 47068 47069 47070 47071 47072 47073 47074 47075 47076 47077 47078 47079 47080 47081 47082 47083 47084 47085 47086 47087 47088 47089 47090 47091 47092 47093 47094 47095 47096 47097 47098 47099 47100 47101 47102 47103 47104 47105 47106 47107 47108 47109 47110 47111 47112 47113 47114 47115 47116 47117 47118 47119 47120 47121 47122 47123 47124 47125 47126 47127 47128 47129 47130 47131 47132 47133 47134 47135 47136 47137 47138 47139 47140 47141 47142 47143 47144 47145 47146 47147 47148 47149 47150 47151 47152 47153 47154 47155 47156 47157 47158 47159 47160 47161 47162 47163 47164 47165 47166 47167 47168 47169 47170 47171 47172 47173 47174 47175 47176 47177 47178 47179 47180 47181 47182 47183 47184 47185 47186 47187 47188 47189 47190 47191 47192 47193 47194 47195 47196 47197 47198 47199 47200 47201 47202 47203 47204 47205 47206 47207 47208 47209 47210 47211 47212 47213 47214 47215 47216 47217 47218 47219 47220 47221 47222 47223 47224 47225 47226 47227 47228 47229 47230 47231 47232 47233 47234 47235 47236 47237 47238 47239 47240 47241 47242 47243 47244 47245 47246 47247 47248 47249 47250 47251 47252 47253 47254 47255 47256 47257 47258 47259 47260 47261 47262 47263 47264 47265 47266 47267 47268 47269 47270 47271 47272 47273 47274 47275 47276 47277 47278 47279 47280 47281 47282 47283 47284 47285 47286 47287 47288 47289 47290 47291 47292 47293 47294 47295 47296 47297 47298 47299 47300 47301 47302 47303 47304 47305 47306 47307 47308 47309 47310 47311 47312 47313 47314 47315 47316 47317 47318 47319 47320 47321 47322 47323 47324 47325 47326 47327 47328 47329 47330 47331 47332 47333 47334 47335 47336 47337 47338 47339 47340 47341 47342 47343 47344 47345 47346 47347 47348 47349 47350 47351 47352 47353 47354 47355 47356 47357 47358 47359 47360 47361 47362 47363 47364 47365 47366 47367 47368 47369 47370 47371 47372 47373 47374 47375 47376 47377 47378 47379 47380 47381 47382 47383 47384 47385 47386 47387 47388 47389 47390 47391 47392 47393 47394 47395 47396 47397 47398 47399 47400 47401 47402 47403 47404 47405 47406 47407 47408 47409 47410 47411 47412 47413 47414 47415 47416 47417 47418 47419 47420 47421 47422 47423 47424 47425 47426 47427 47428 47429 47430 47431 47432 47433 47434 47435 47436 47437 47438 47439 47440 47441 47442 47443 47444 47445 47446 47447 47448 47449 47450 47451 47452 47453 47454 47455 47456 47457 47458 47459 47460 47461 47462 47463 47464 47465 47466 47467 47468 47469 47470 47471 47472 47473 47474 47475 47476 47477 47478 47479 47480 47481 47482 47483 47484 47485 47486 47487 47488 47489 47490 47491 47492 47493 47494 47495 47496 47497 47498 47499 47500 47501 47502 47503 47504 47505 47506 47507 47508 47509 47510 47511 47512 47513 47514 47515 47516 47517 47518 47519 47520 47521 47522 47523 47524 47525 47526 47527 47528 47529 47530 47531 47532 47533 47534 47535 47536 47537 47538 47539 47540 47541 47542 47543 47544 47545 47546 47547 47548 47549 47550 47551 47552 47553 47554 47555 47556 47557 47558 47559 47560 47561 47562 47563 47564 47565 47566 47567 47568 47569 47570 47571 47572 47573 47574 47575 47576 47577 47578 47579 47580 47581 47582 47583 47584 47585 47586 47587 47588 47589 47590 47591 47592 47593 47594 47595 47596 47597 47598 47599 47600 47601 47602 47603 47604 47605 47606 47607 47608 47609 47610 47611 47612 47613 47614 47615 47616 47617 47618 47619 47620 47621 47622 47623 47624 47625 47626 47627 47628 47629 47630 47631 47632 47633 47634 47635 47636 47637 47638 47639 47640 47641 47642 47643 47644 47645 47646 47647 47648 47649 47650 47651 47652 47653 47654 47655 47656 47657 47658 47659 47660 47661 47662 47663 47664 47665 47666 47667 47668 47669 47670 47671 47672 47673 47674 47675 47676 47677 47678 47679 47680 47681 47682 47683 47684 47685 47686 47687 47688 47689 47690 47691 47692 47693 47694 47695 47696 47697 47698 47699 47700 47701 47702 47703 47704 47705 47706 47707 47708 47709 47710 47711 47712 47713 47714 47715 47716 47717 47718 47719 47720 47721 47722 47723 47724 47725 47726 47727 47728 47729 47730 47731 47732 47733 47734 47735 47736 47737 47738 47739 47740 47741 47742 47743 47744 47745 47746 47747 47748 47749 47750 47751 47752 47753 47754 47755 47756 47757 47758 47759 47760 47761 47762 47763 47764 47765 47766 47767 47768 47769 47770 47771 47772 47773 47774 47775 47776 47777 47778 47779 47780 47781 47782 47783 47784 47785 47786 47787 47788 47789 47790 47791 47792 47793 47794 47795 47796 47797 47798 47799 47800 47801 47802 47803 47804 47805 47806 47807 47808 47809 47810 47811 47812 47813 47814 47815 47816 47817 47818 47819 47820 47821 47822 47823 47824 47825 47826 47827 47828 47829 47830 47831 47832 47833 47834 47835 47836 47837 47838 47839 47840 47841 47842 47843 47844 47845 47846 47847 47848 47849 47850 47851 47852 47853 47854 47855 47856 47857 47858 47859 47860 47861 47862 47863 47864 47865 47866 47867 47868 47869 47870 47871 47872 47873 47874 47875 47876 47877 47878 47879 47880 47881 47882 47883 47884 47885 47886 47887 47888 47889 47890 47891 47892 47893 47894 47895 47896 47897 47898 47899 47900 47901 47902 47903 47904 47905 47906 47907 47908 47909 47910 47911 47912 47913 47914 47915 47916 47917 47918 47919 47920 47921 47922 47923 47924 47925 47926 47927 47928 47929 47930 47931 47932 47933 47934 47935 47936 47937 47938 47939 47940 47941 47942 47943 47944 47945 47946 47947 47948 47949 47950 47951 47952 47953 47954 47955 47956 47957 47958 47959 47960 47961 47962 47963 47964 47965 47966 47967 47968 47969 47970 47971 47972 47973 47974 47975 47976 47977 47978 47979 47980 47981 47982 47983 47984 47985 47986 47987 47988 47989 47990 47991 47992 47993 47994 47995 47996 47997 47998 47999 48000 48001 48002 48003 48004 48005 48006 48007 48008 48009 48010 48011 48012 48013 48014 48015 48016 48017 48018 48019 48020 48021 48022 48023 48024 48025 48026 48027 48028 48029 48030 48031 48032 48033 48034 48035 48036 48037 48038 48039 48040 48041 48042 48043 48044 48045 48046 48047 48048 48049 48050 48051 48052 48053 48054 48055 48056 48057 48058 48059 48060 48061 48062 48063 48064 48065 48066 48067 48068 48069 48070 48071 48072 48073 48074 48075 48076 48077 48078 48079 48080 48081 48082 48083 48084 48085 48086 48087 48088 48089 48090 48091 48092 48093 48094 48095 48096 48097 48098 48099 48100 48101 48102 48103 48104 48105 48106 48107 48108 48109 48110 48111 48112 48113 48114 48115 48116 48117 48118 48119 48120 48121 48122 48123 48124 48125 48126 48127 48128 48129 48130 48131 48132 48133 48134 48135 48136 48137 48138 48139 48140 48141 48142 48143 48144 48145 48146 48147 48148 48149 48150 48151 48152 48153 48154 48155 48156 48157 48158 48159 48160 48161 48162 48163 48164 48165 48166 48167 48168 48169 48170 48171 48172 48173 48174 48175 48176 48177 48178 48179 48180 48181 48182 48183 48184 48185 48186 48187 48188 48189 48190 48191 48192 48193 48194 48195 48196 48197 48198 48199 48200 48201 48202 48203 48204 48205 48206 48207 48208 48209 48210 48211 48212 48213 48214 48215 48216 48217 48218 48219 48220 48221 48222 48223 48224 48225 48226 48227 48228 48229 48230 48231 48232 48233 48234 48235 48236 48237 48238 48239 48240 48241 48242 48243 48244 48245 48246 48247 48248 48249 48250 48251 48252 48253 48254 48255 48256 48257 48258 48259 48260 48261 48262 48263 48264 48265 48266 48267 48268 48269 48270 48271 48272 48273 48274 48275 48276 48277 48278 48279 48280 48281 48282 48283 48284 48285 48286 48287 48288 48289 48290 48291 48292 48293 48294 48295 48296 48297 48298 48299 48300 48301 48302 48303 48304 48305 48306 48307 48308 48309 48310 48311 48312 48313 48314 48315 48316 48317 48318 48319 48320 48321 48322 48323 48324 48325 48326 48327 48328 48329 48330 48331 48332 48333 48334 48335 48336 48337 48338 48339 48340 48341 48342 48343 48344 48345 48346 48347 48348 48349 48350 48351 48352 48353 48354 48355 48356 48357 48358 48359 48360 48361 48362 48363 48364 48365 48366 48367 48368 48369 48370 48371 48372 48373 48374 48375 48376 48377 48378 48379 48380 48381 48382 48383 48384 48385 48386 48387 48388 48389 48390 48391 48392 48393 48394 48395 48396 48397 48398 48399 48400 48401 48402 48403 48404 48405 48406 48407 48408 48409 48410 48411 48412 48413 48414 48415 48416 48417 48418 48419 48420 48421 48422 48423 48424 48425 48426 48427 48428 48429 48430 48431 48432 48433 48434 48435 48436 48437 48438 48439 48440 48441 48442 48443 48444 48445 48446 48447 48448 48449 48450 48451 48452 48453 48454 48455 48456 48457 48458 48459 48460 48461 48462 48463 48464 48465 48466 48467 48468 48469 48470 48471 48472 48473 48474 48475 48476 48477 48478 48479 48480 48481 48482 48483 48484 48485 48486 48487 48488 48489 48490 48491 48492 48493 48494 48495 48496 48497 48498 48499 48500 48501 48502 48503 48504 48505 48506 48507 48508 48509 48510 48511 48512 48513 48514 48515 48516 48517 48518 48519 48520 48521 48522 48523 48524 48525 48526 48527 48528 48529 48530 48531 48532 48533 48534 48535 48536 48537 48538 48539 48540 48541 48542 48543 48544 48545 48546 48547 48548 48549 48550 48551 48552 48553 48554 48555 48556 48557 48558 48559 48560 48561 48562 48563 48564 48565 48566 48567 48568 48569 48570 48571 48572 48573 48574 48575 48576 48577 48578 48579 48580 48581 48582 48583 48584 48585 48586 48587 48588 48589 48590 48591 48592 48593 48594 48595 48596 48597 48598 48599 48600 48601 48602 48603 48604 48605 48606 48607 48608 48609 48610 48611 48612 48613 48614 48615 48616 48617 48618 48619 48620 48621 48622 48623 48624 48625 48626 48627 48628 48629 48630 48631 48632 48633 48634 48635 48636 48637 48638 48639 48640 48641 48642 48643 48644 48645 48646 48647 48648 48649 48650 48651 48652 48653 48654 48655 48656 48657 48658 48659 48660 48661 48662 48663 48664 48665 48666 48667 48668 48669 48670 48671 48672 48673 48674 48675 48676 48677 48678 48679 48680 48681 48682 48683 48684 48685 48686 48687 48688 48689 48690 48691 48692 48693 48694 48695 48696 48697 48698 48699 48700 48701 48702 48703 48704 48705 48706 48707 48708 48709 48710 48711 48712 48713 48714 48715 48716 48717 48718 48719 48720 48721 48722 48723 48724 48725 48726 48727 48728 48729 48730 48731 48732 48733 48734 48735 48736 48737 48738 48739 48740 48741 48742 48743 48744 48745 48746 48747 48748 48749 48750 48751 48752 48753 48754 48755 48756 48757 48758 48759 48760 48761 48762 48763 48764 48765 48766 48767 48768 48769 48770 48771 48772 48773 48774 48775 48776 48777 48778 48779 48780 48781 48782 48783 48784 48785 48786 48787 48788 48789 48790 48791 48792 48793 48794 48795 48796 48797 48798 48799 48800 48801 48802 48803 48804 48805 48806 48807 48808 48809 48810 48811 48812 48813 48814 48815 48816 48817 48818 48819 48820 48821 48822 48823 48824 48825 48826 48827 48828 48829 48830 48831 48832 48833 48834 48835 48836 48837 48838 48839 48840 48841 48842 48843 48844 48845 48846 48847 48848 48849 48850 48851 48852 48853 48854 48855 48856 48857 48858 48859 48860 48861 48862 48863 48864 48865 48866 48867 48868 48869 48870 48871 48872 48873 48874 48875 48876 48877 48878 48879 48880 48881 48882 48883 48884 48885 48886 48887 48888 48889 48890 48891 48892 48893 48894 48895 48896 48897 48898 48899 48900 48901 48902 48903 48904 48905 48906 48907 48908 48909 48910 48911 48912 48913 48914 48915 48916 48917 48918 48919 48920 48921 48922 48923 48924 48925 48926 48927 48928 48929 48930 48931 48932 48933 48934 48935 48936 48937 48938 48939 48940 48941 48942 48943 48944 48945 48946 48947 48948 48949 48950 48951 48952 48953 48954 48955 48956 48957 48958 48959 48960 48961 48962 48963 48964 48965 48966 48967 48968 48969 48970 48971 48972 48973 48974 48975 48976 48977 48978 48979 48980 48981 48982 48983 48984 48985 48986 48987 48988 48989 48990 48991 48992 48993 48994 48995 48996 48997 48998 48999 49000 49001 49002 49003 49004 49005 49006 49007 49008 49009 49010 49011 49012 49013 49014 49015 49016 49017 49018 49019 49020 49021 49022 49023 49024 49025 49026 49027 49028 49029 49030 49031 49032 49033 49034 49035 49036 49037 49038 49039 49040 49041 49042 49043 49044 49045 49046 49047 49048 49049 49050 49051 49052 49053 49054 49055 49056 49057 49058 49059 49060 49061 49062 49063 49064 49065 49066 49067 49068 49069 49070 49071 49072 49073 49074 49075 49076 49077 49078 49079 49080 49081 49082 49083 49084 49085 49086 49087 49088 49089 49090 49091 49092 49093 49094 49095 49096 49097 49098 49099 49100 49101 49102 49103 49104 49105 49106 49107 49108 49109 49110 49111 49112 49113 49114 49115 49116 49117 49118 49119 49120 49121 49122 49123 49124 49125 49126 49127 49128 49129 49130 49131 49132 49133 49134 49135 49136 49137 49138 49139 49140 49141 49142 49143 49144 49145 49146 49147 49148 49149 49150 49151 49152 49153 49154 49155 49156 49157 49158 49159 49160 49161 49162 49163 49164 49165 49166 49167 49168 49169 49170 49171 49172 49173 49174 49175 49176 49177 49178 49179 49180 49181 49182 49183 49184 49185 49186 49187 49188 49189 49190 49191 49192 49193 49194 49195 49196 49197 49198 49199 49200 49201 49202 49203 49204 49205 49206 49207 49208 49209 49210 49211 49212 49213 49214 49215 49216 49217 49218 49219 49220 49221 49222 49223 49224 49225 49226 49227 49228 49229 49230 49231 49232 49233 49234 49235 49236 49237 49238 49239 49240 49241 49242 49243 49244 49245 49246 49247 49248 49249 49250 49251 49252 49253 49254 49255 49256 49257 49258 49259 49260 49261 49262 49263 49264 49265 49266 49267 49268 49269 49270 49271 49272 49273 49274 49275 49276 49277 49278 49279 49280 49281 49282 49283 49284 49285 49286 49287 49288 49289 49290 49291 49292 49293 49294 49295 49296 49297 49298 49299 49300 49301 49302 49303 49304 49305 49306 49307 49308 49309 49310 49311 49312 49313 49314 49315 49316 49317 49318 49319 49320 49321 49322 49323 49324 49325 49326 49327 49328 49329 49330 49331 49332 49333 49334 49335 49336 49337 49338 49339 49340 49341 49342 49343 49344 49345 49346 49347 49348 49349 49350 49351 49352 49353 49354 49355 49356 49357 49358 49359 49360 49361 49362 49363 49364 49365 49366 49367 49368 49369 49370 49371 49372 49373 49374 49375 49376 49377 49378 49379 49380 49381 49382 49383 49384 49385 49386 49387 49388 49389 49390 49391 49392 49393 49394 49395 49396 49397 49398 49399 49400 49401 49402 49403 49404 49405 49406 49407 49408 49409 49410 49411 49412 49413 49414 49415 49416 49417 49418 49419 49420 49421 49422 49423 49424 49425 49426 49427 49428 49429 49430 49431 49432 49433 49434 49435 49436 49437 49438 49439 49440 49441 49442 49443 49444 49445 49446 49447 49448 49449 49450 49451 49452 49453 49454 49455 49456 49457 49458 49459 49460 49461 49462 49463 49464 49465 49466 49467 49468 49469 49470 49471 49472 49473 49474 49475 49476 49477 49478 49479 49480 49481 49482 49483 49484 49485 49486 49487 49488 49489 49490 49491 49492 49493 49494 49495 49496 49497 49498 49499 49500 49501 49502 49503 49504 49505 49506 49507 49508 49509 49510 49511 49512 49513 49514 49515 49516 49517 49518 49519 49520 49521 49522 49523 49524 49525 49526 49527 49528 49529 49530 49531 49532 49533 49534 49535 49536 49537 49538 49539 49540 49541 49542 49543 49544 49545 49546 49547 49548 49549 49550 49551 49552 49553 49554 49555 49556 49557 49558 49559 49560 49561 49562 49563 49564 49565 49566 49567 49568 49569 49570 49571 49572 49573 49574 49575 49576 49577 49578 49579 49580 49581 49582 49583 49584 49585 49586 49587 49588 49589 49590 49591 49592 49593 49594 49595 49596 49597 49598 49599 49600 49601 49602 49603 49604 49605 49606 49607 49608 49609 49610 49611 49612 49613 49614 49615 49616 49617 49618 49619 49620 49621 49622 49623 49624 49625 49626 49627 49628 49629 49630 49631 49632 49633 49634 49635 49636 49637 49638 49639 49640 49641 49642 49643 49644 49645 49646 49647 49648 49649 49650 49651 49652 49653 49654 49655 49656 49657 49658 49659 49660 49661 49662 49663 49664 49665 49666 49667 49668 49669 49670 49671 49672 49673 49674 49675 49676 49677 49678 49679 49680 49681 49682 49683 49684 49685 49686 49687 49688 49689 49690 49691 49692 49693 49694 49695 49696 49697 49698 49699 49700 49701 49702 49703 49704 49705 49706 49707 49708 49709 49710 49711 49712 49713 49714 49715 49716 49717 49718 49719 49720 49721 49722 49723 49724 49725 49726 49727 49728 49729 49730 49731 49732 49733 49734 49735 49736 49737 49738 49739 49740 49741 49742 49743 49744 49745 49746 49747 49748 49749 49750 49751 49752 49753 49754 49755 49756 49757 49758 49759 49760 49761 49762 49763 49764 49765 49766 49767 49768 49769 49770 49771 49772 49773 49774 49775 49776 49777 49778 49779 49780 49781 49782 49783 49784 49785 49786 49787 49788 49789 49790 49791 49792 49793 49794 49795 49796 49797 49798 49799 49800 49801 49802 49803 49804 49805 49806 49807 49808 49809 49810 49811 49812 49813 49814 49815 49816 49817 49818 49819 49820 49821 49822 49823 49824 49825 49826 49827 49828 49829 49830 49831 49832 49833 49834 49835 49836 49837 49838 49839 49840 49841 49842 49843 49844 49845 49846 49847 49848 49849 49850 49851 49852 49853 49854 49855 49856 49857 49858 49859 49860 49861 49862 49863 49864 49865 49866 49867 49868 49869 49870 49871 49872 49873 49874 49875 49876 49877 49878 49879 49880 49881 49882 49883 49884 49885 49886 49887 49888 49889 49890 49891 49892 49893 49894 49895 49896 49897 49898 49899 49900 49901 49902 49903 49904 49905 49906 49907 49908 49909 49910 49911 49912 49913 49914 49915 49916 49917 49918 49919 49920 49921 49922 49923 49924 49925 49926 49927 49928 49929 49930 49931 49932 49933 49934 49935 49936 49937 49938 49939 49940 49941 49942 49943 49944 49945 49946 49947 49948 49949 49950 49951 49952 49953 49954 49955 49956 49957 49958 49959 49960 49961 49962 49963 49964 49965 49966 49967 49968 49969 49970 49971 49972 49973 49974 49975 49976 49977 49978 49979 49980 49981 49982 49983 49984 49985 49986 49987 49988 49989 49990 49991 49992 49993 49994 49995 49996 49997 49998 49999 50000 50001 50002 50003 50004 50005 50006 50007 50008 50009 50010 50011 50012 50013 50014 50015 50016 50017 50018 50019 50020 50021 50022 50023 50024 50025 50026 50027 50028 50029 50030 50031 50032 50033 50034 50035 50036 50037 50038 50039 50040 50041 50042 50043 50044 50045 50046 50047 50048 50049 50050 50051 50052 50053 50054 50055 50056 50057 50058 50059 50060 50061 50062 50063 50064 50065 50066 50067 50068 50069 50070 50071 50072 50073 50074 50075 50076 50077 50078 50079 50080 50081 50082 50083 50084 50085 50086 50087 50088 50089 50090 50091 50092 50093 50094 50095 50096 50097 50098 50099 50100 50101 50102 50103 50104 50105 50106 50107 50108 50109 50110 50111 50112 50113 50114 50115 50116 50117 50118 50119 50120 50121 50122 50123 50124 50125 50126 50127 50128 50129 50130 50131 50132 50133 50134 50135 50136 50137 50138 50139 50140 50141 50142 50143 50144 50145 50146 50147 50148 50149 50150 50151 50152 50153 50154 50155 50156 50157 50158 50159 50160 50161 50162 50163 50164 50165 50166 50167 50168 50169 50170 50171 50172 50173 50174 50175 50176 50177 50178 50179 50180 50181 50182 50183 50184 50185 50186 50187 50188 50189 50190 50191 50192 50193 50194 50195 50196 50197 50198 50199 50200 50201 50202 50203 50204 50205 50206 50207 50208 50209 50210 50211 50212 50213 50214 50215 50216 50217 50218 50219 50220 50221 50222 50223 50224 50225 50226 50227 50228 50229 50230 50231 50232 50233 50234 50235 50236 50237 50238 50239 50240 50241 50242 50243 50244 50245 50246 50247 50248 50249 50250 50251 50252 50253 50254 50255 50256 50257 50258 50259 50260 50261 50262 50263 50264 50265 50266 50267 50268 50269 50270 50271 50272 50273 50274 50275 50276 50277 50278 50279 50280 50281 50282 50283 50284 50285 50286 50287 50288 50289 50290 50291 50292 50293 50294 50295 50296 50297 50298 50299 50300 50301 50302 50303 50304 50305 50306 50307 50308 50309 50310 50311 50312 50313 50314 50315 50316 50317 50318 50319 50320 50321 50322 50323 50324 50325 50326 50327 50328 50329 50330 50331 50332 50333 50334 50335 50336 50337 50338 50339 50340 50341 50342 50343 50344 50345 50346 50347 50348 50349 50350 50351 50352 50353 50354 50355 50356 50357 50358 50359 50360 50361 50362 50363 50364 50365 50366 50367 50368 50369 50370 50371 50372 50373 50374 50375 50376 50377 50378 50379 50380 50381 50382 50383 50384 50385 50386 50387 50388 50389 50390 50391 50392 50393 50394 50395 50396 50397 50398 50399 50400 50401 50402 50403 50404 50405 50406 50407 50408 50409 50410 50411 50412 50413 50414 50415 50416 50417 50418 50419 50420 50421 50422 50423 50424 50425 50426 50427 50428 50429 50430 50431 50432 50433 50434 50435 50436 50437 50438 50439 50440 50441 50442 50443 50444 50445 50446 50447 50448 50449 50450 50451 50452 50453 50454 50455 50456 50457 50458 50459 50460 50461 50462 50463 50464 50465 50466 50467 50468 50469 50470 50471 50472 50473 50474 50475 50476 50477 50478 50479 50480 50481 50482 50483 50484 50485 50486 50487 50488 50489 50490 50491 50492 50493 50494 50495 50496 50497 50498 50499 50500 50501 50502 50503 50504 50505 50506 50507 50508 50509 50510 50511 50512 50513 50514 50515 50516 50517 50518 50519 50520 50521 50522 50523 50524 50525 50526 50527 50528 50529 50530 50531 50532 50533 50534 50535 50536 50537 50538 50539 50540 50541 50542 50543 50544 50545 50546 50547 50548 50549 50550 50551 50552 50553 50554 50555 50556 50557 50558 50559 50560 50561 50562 50563 50564 50565 50566 50567 50568 50569 50570 50571 50572 50573 50574 50575 50576 50577 50578 50579 50580 50581 50582 50583 50584 50585 50586 50587 50588 50589 50590 50591 50592 50593 50594 50595 50596 50597 50598 50599 50600 50601 50602 50603 50604 50605 50606 50607 50608 50609 50610 50611 50612 50613 50614 50615 50616 50617 50618 50619 50620 50621 50622 50623 50624 50625 50626 50627 50628 50629 50630 50631 50632 50633 50634 50635 50636 50637 50638 50639 50640 50641 50642 50643 50644 50645 50646 50647 50648 50649 50650 50651 50652 50653 50654 50655 50656 50657 50658 50659 50660 50661 50662 50663 50664 50665 50666 50667 50668 50669 50670 50671 50672 50673 50674 50675 50676 50677 50678 50679 50680 50681 50682 50683 50684 50685 50686 50687 50688 50689 50690 50691 50692 50693 50694 50695 50696 50697 50698 50699 50700 50701 50702 50703 50704 50705 50706 50707 50708 50709 50710 50711 50712 50713 50714 50715 50716 50717 50718 50719 50720 50721 50722 50723 50724 50725 50726 50727 50728 50729 50730 50731 50732 50733 50734 50735 50736 50737 50738 50739 50740 50741 50742 50743 50744 50745 50746 50747 50748 50749 50750 50751 50752 50753 50754 50755 50756 50757 50758 50759 50760 50761 50762 50763 50764 50765 50766 50767 50768 50769 50770 50771 50772 50773 50774 50775 50776 50777 50778 50779 50780 50781 50782 50783 50784 50785 50786 50787 50788 50789 50790 50791 50792 50793 50794 50795 50796 50797 50798 50799 50800 50801 50802 50803 50804 50805 50806 50807 50808 50809 50810 50811 50812 50813 50814 50815 50816 50817 50818 50819 50820 50821 50822 50823 50824 50825 50826 50827 50828 50829 50830 50831 50832 50833 50834 50835 50836 50837 50838 50839 50840 50841 50842 50843 50844 50845 50846 50847 50848 50849 50850 50851 50852 50853 50854 50855 50856 50857 50858 50859 50860 50861 50862 50863 50864 50865 50866 50867 50868 50869 50870 50871 50872 50873 50874 50875 50876 50877 50878 50879 50880 50881 50882 50883 50884 50885 50886 50887 50888 50889 50890 50891 50892 50893 50894 50895 50896 50897 50898 50899 50900 50901 50902 50903 50904 50905 50906 50907 50908 50909 50910 50911 50912 50913 50914 50915 50916 50917 50918 50919 50920 50921 50922 50923 50924 50925 50926 50927 50928 50929 50930 50931 50932 50933 50934 50935 50936 50937 50938 50939 50940 50941 50942 50943 50944 50945 50946 50947 50948 50949 50950 50951 50952 50953 50954 50955 50956 50957 50958 50959 50960 50961 50962 50963 50964 50965 50966 50967 50968 50969 50970 50971 50972 50973 50974 50975 50976 50977 50978 50979 50980 50981 50982 50983 50984 50985 50986 50987 50988 50989 50990 50991 50992 50993 50994 50995 50996 50997 50998 50999 51000 51001 51002 51003 51004 51005 51006 51007 51008 51009 51010 51011 51012 51013 51014 51015 51016 51017 51018 51019 51020 51021 51022 51023 51024 51025 51026 51027 51028 51029 51030 51031 51032 51033 51034 51035 51036 51037 51038 51039 51040 51041 51042 51043 51044 51045 51046 51047 51048 51049 51050 51051 51052 51053 51054 51055 51056 51057 51058 51059 51060 51061 51062 51063 51064 51065 51066 51067 51068 51069 51070 51071 51072 51073 51074 51075 51076 51077 51078 51079 51080 51081 51082 51083 51084 51085 51086 51087 51088 51089 51090 51091 51092 51093 51094 51095 51096 51097 51098 51099 51100 51101 51102 51103 51104 51105 51106 51107 51108 51109 51110 51111 51112 51113 51114 51115 51116 51117 51118 51119 51120 51121 51122 51123 51124 51125 51126 51127 51128 51129 51130 51131 51132 51133 51134 51135 51136 51137 51138 51139 51140 51141 51142 51143 51144 51145 51146 51147 51148 51149 51150 51151 51152 51153 51154 51155 51156 51157 51158 51159 51160 51161 51162 51163 51164 51165 51166 51167 51168 51169 51170 51171 51172 51173 51174 51175 51176 51177 51178 51179 51180 51181 51182 51183 51184 51185 51186 51187 51188 51189 51190 51191 51192 51193 51194 51195 51196 51197 51198 51199 51200 51201 51202 51203 51204 51205 51206 51207 51208 51209 51210 51211 51212 51213 51214 51215 51216 51217 51218 51219 51220 51221 51222 51223 51224 51225 51226 51227 51228 51229 51230 51231 51232 51233 51234 51235 51236 51237 51238 51239 51240 51241 51242 51243 51244 51245 51246 51247 51248 51249 51250 51251 51252 51253 51254 51255 51256 51257 51258 51259 51260 51261 51262 51263 51264 51265 51266 51267 51268 51269 51270 51271 51272 51273 51274 51275 51276 51277 51278 51279 51280 51281 51282 51283 51284 51285 51286 51287 51288 51289 51290 51291 51292 51293 51294 51295 51296 51297 51298 51299 51300 51301 51302 51303 51304 51305 51306 51307 51308 51309 51310 51311 51312 51313 51314 51315 51316 51317 51318 51319 51320 51321 51322 51323 51324 51325 51326 51327 51328 51329 51330 51331 51332 51333 51334 51335 51336 51337 51338 51339 51340 51341 51342 51343 51344 51345 51346 51347 51348 51349 51350 51351 51352 51353 51354 51355 51356 51357 51358 51359 51360 51361 51362 51363 51364 51365 51366 51367 51368 51369 51370 51371 51372 51373 51374 51375 51376 51377 51378 51379 51380 51381 51382 51383 51384 51385 51386 51387 51388 51389 51390 51391 51392 51393 51394 51395 51396 51397 51398 51399 51400 51401 51402 51403 51404 51405 51406 51407 51408 51409 51410 51411 51412 51413 51414 51415 51416 51417 51418 51419 51420 51421 51422 51423 51424 51425 51426 51427 51428 51429 51430 51431 51432 51433 51434 51435 51436 51437 51438 51439 51440 51441 51442 51443 51444 51445 51446 51447 51448 51449 51450 51451 51452 51453 51454 51455 51456 51457 51458 51459 51460 51461 51462 51463 51464 51465 51466 51467 51468 51469 51470 51471 51472 51473 51474 51475 51476 51477 51478 51479 51480 51481 51482 51483 51484 51485 51486 51487 51488 51489 51490 51491 51492 51493 51494 51495 51496 51497 51498 51499 51500 51501 51502 51503 51504 51505 51506 51507 51508 51509 51510 51511 51512 51513 51514 51515 51516 51517 51518 51519 51520 51521 51522 51523 51524 51525 51526 51527 51528 51529 51530 51531 51532 51533 51534 51535 51536 51537 51538 51539 51540 51541 51542 51543 51544 51545 51546 51547 51548 51549 51550 51551 51552 51553 51554 51555 51556 51557 51558 51559 51560 51561 51562 51563 51564 51565 51566 51567 51568 51569 51570 51571 51572 51573 51574 51575 51576 51577 51578 51579 51580 51581 51582 51583 51584 51585 51586 51587 51588 51589 51590 51591 51592 51593 51594 51595 51596 51597 51598 51599 51600 51601 51602 51603 51604 51605 51606 51607 51608 51609 51610 51611 51612 51613 51614 51615 51616 51617 51618 51619 51620 51621 51622 51623 51624 51625 51626 51627 51628 51629 51630 51631 51632 51633 51634 51635 51636 51637 51638 51639 51640 51641 51642 51643 51644 51645 51646 51647 51648 51649 51650 51651 51652 51653 51654 51655 51656 51657 51658 51659 51660 51661 51662 51663 51664 51665 51666 51667 51668 51669 51670 51671 51672 51673 51674 51675 51676 51677 51678 51679 51680 51681 51682 51683 51684 51685 51686 51687 51688 51689 51690 51691 51692 51693 51694 51695 51696 51697 51698 51699 51700 51701 51702 51703 51704 51705 51706 51707 51708 51709 51710 51711 51712 51713 51714 51715 51716 51717 51718 51719 51720 51721 51722 51723 51724 51725 51726 51727 51728 51729 51730 51731 51732 51733 51734 51735 51736 51737 51738 51739 51740 51741 51742 51743 51744 51745 51746 51747 51748 51749 51750 51751 51752 51753 51754 51755 51756 51757 51758 51759 51760 51761 51762 51763 51764 51765 51766 51767 51768 51769 51770 51771 51772 51773 51774 51775 51776 51777 51778 51779 51780 51781 51782 51783 51784 51785 51786 51787 51788 51789 51790 51791 51792 51793 51794 51795 51796 51797 51798 51799 51800 51801 51802 51803 51804 51805 51806 51807 51808 51809 51810 51811 51812 51813 51814 51815 51816 51817 51818 51819 51820 51821 51822 51823 51824 51825 51826 51827 51828 51829 51830 51831 51832 51833 51834 51835 51836 51837 51838 51839 51840 51841 51842 51843 51844 51845 51846 51847 51848 51849 51850 51851 51852 51853 51854 51855 51856 51857 51858 51859 51860 51861 51862 51863 51864 51865 51866 51867 51868 51869 51870 51871 51872 51873 51874 51875 51876 51877 51878 51879 51880 51881 51882 51883 51884 51885 51886 51887 51888 51889 51890 51891 51892 51893 51894 51895 51896 51897 51898 51899 51900 51901 51902 51903 51904 51905 51906 51907 51908 51909 51910 51911 51912 51913 51914 51915 51916 51917 51918 51919 51920 51921 51922 51923 51924 51925 51926 51927 51928 51929 51930 51931 51932 51933 51934 51935 51936 51937 51938 51939 51940 51941 51942 51943 51944 51945 51946 51947 51948 51949 51950 51951 51952 51953 51954 51955 51956 51957 51958 51959 51960 51961 51962 51963 51964 51965 51966 51967 51968 51969 51970 51971 51972 51973 51974 51975 51976 51977 51978 51979 51980 51981 51982 51983 51984 51985 51986 51987 51988 51989 51990 51991 51992 51993 51994 51995 51996 51997 51998 51999 52000 52001 52002 52003 52004 52005 52006 52007 52008 52009 52010 52011 52012 52013 52014 52015 52016 52017 52018 52019 52020 52021 52022 52023 52024 52025 52026 52027 52028 52029 52030 52031 52032 52033 52034 52035 52036 52037 52038 52039 52040 52041 52042 52043 52044 52045 52046 52047 52048 52049 52050 52051 52052 52053 52054 52055 52056 52057 52058 52059 52060 52061 52062 52063 52064 52065 52066 52067 52068 52069 52070 52071 52072 52073 52074 52075 52076 52077 52078 52079 52080 52081 52082 52083 52084 52085 52086 52087 52088 52089 52090 52091 52092 52093 52094 52095 52096 52097 52098 52099 52100 52101 52102 52103 52104 52105 52106 52107 52108 52109 52110 52111 52112 52113 52114 52115 52116 52117 52118 52119 52120 52121 52122 52123 52124 52125 52126 52127 52128 52129 52130 52131 52132 52133 52134 52135 52136 52137 52138 52139 52140 52141 52142 52143 52144 52145 52146 52147 52148 52149 52150 52151 52152 52153 52154 52155 52156 52157 52158 52159 52160 52161 52162 52163 52164 52165 52166 52167 52168 52169 52170 52171 52172 52173 52174 52175 52176 52177 52178 52179 52180 52181 52182 52183 52184 52185 52186 52187 52188 52189 52190 52191 52192 52193 52194 52195 52196 52197 52198 52199 52200 52201 52202 52203 52204 52205 52206 52207 52208 52209 52210 52211 52212 52213 52214 52215 52216 52217 52218 52219 52220 52221 52222 52223 52224 52225 52226 52227 52228 52229 52230 52231 52232 52233 52234 52235 52236 52237 52238 52239 52240 52241 52242 52243 52244 52245 52246 52247 52248 52249 52250 52251 52252 52253 52254 52255 52256 52257 52258 52259 52260 52261 52262 52263 52264 52265 52266 52267 52268 52269 52270 52271 52272 52273 52274 52275 52276 52277 52278 52279 52280 52281 52282 52283 52284 52285 52286 52287 52288 52289 52290 52291 52292 52293 52294 52295 52296 52297 52298 52299 52300 52301 52302 52303 52304 52305 52306 52307 52308 52309 52310 52311 52312 52313 52314 52315 52316 52317 52318 52319 52320 52321 52322 52323 52324 52325 52326 52327 52328 52329 52330 52331 52332 52333 52334 52335 52336 52337 52338 52339 52340 52341 52342 52343 52344 52345 52346 52347 52348 52349 52350 52351 52352 52353 52354 52355 52356 52357 52358 52359 52360 52361 52362 52363 52364 52365 52366 52367 52368 52369 52370 52371 52372 52373 52374 52375 52376 52377 52378 52379 52380 52381 52382 52383 52384 52385 52386 52387 52388 52389 52390 52391 52392 52393 52394 52395 52396 52397 52398 52399 52400 52401 52402 52403 52404 52405 52406 52407 52408 52409 52410 52411 52412 52413 52414 52415 52416 52417 52418 52419 52420 52421 52422 52423 52424 52425 52426 52427 52428 52429 52430 52431 52432 52433 52434 52435 52436 52437 52438 52439 52440 52441 52442 52443 52444 52445 52446 52447 52448 52449 52450 52451 52452 52453 52454 52455 52456 52457 52458 52459 52460 52461 52462 52463 52464 52465 52466 52467 52468 52469 52470 52471 52472 52473 52474 52475 52476 52477 52478 52479 52480 52481 52482 52483 52484 52485 52486 52487 52488 52489 52490 52491 52492 52493 52494 52495 52496 52497 52498 52499 52500 52501 52502 52503 52504 52505 52506 52507 52508 52509 52510 52511 52512 52513 52514 52515 52516 52517 52518 52519 52520 52521 52522 52523 52524 52525 52526 52527 52528 52529 52530 52531 52532 52533 52534 52535 52536 52537 52538 52539 52540 52541 52542 52543 52544 52545 52546 52547 52548 52549 52550 52551 52552 52553 52554 52555 52556 52557 52558 52559 52560 52561 52562 52563 52564 52565 52566 52567 52568 52569 52570 52571 52572 52573 52574 52575 52576 52577 52578 52579 52580 52581 52582 52583 52584 52585 52586 52587 52588 52589 52590 52591 52592 52593 52594 52595 52596 52597 52598 52599 52600 52601 52602 52603 52604 52605 52606 52607 52608 52609 52610 52611 52612 52613 52614 52615 52616 52617 52618 52619 52620 52621 52622 52623 52624 52625 52626 52627 52628 52629 52630 52631 52632 52633 52634 52635 52636 52637 52638 52639 52640 52641 52642 52643 52644 52645 52646 52647 52648 52649 52650 52651 52652 52653 52654 52655 52656 52657 52658 52659 52660 52661 52662 52663 52664 52665 52666 52667 52668 52669 52670 52671 52672 52673 52674 52675 52676 52677 52678 52679 52680 52681 52682 52683 52684 52685 52686 52687 52688 52689 52690 52691 52692 52693 52694 52695 52696 52697 52698 52699 52700 52701 52702 52703 52704 52705 52706 52707 52708 52709 52710 52711 52712 52713 52714 52715 52716 52717 52718 52719 52720 52721 52722 52723 52724 52725 52726 52727 52728 52729 52730 52731 52732 52733 52734 52735 52736 52737 52738 52739 52740 52741 52742 52743 52744 52745 52746 52747 52748 52749 52750 52751 52752 52753 52754 52755 52756 52757 52758 52759 52760 52761 52762 52763 52764 52765 52766 52767 52768 52769 52770 52771 52772 52773 52774 52775 52776 52777 52778 52779 52780 52781 52782 52783 52784 52785 52786 52787 52788 52789 52790 52791 52792 52793 52794 52795 52796 52797 52798 52799 52800 52801 52802 52803 52804 52805 52806 52807 52808 52809 52810 52811 52812 52813 52814 52815 52816 52817 52818 52819 52820 52821 52822 52823 52824 52825 52826 52827 52828 52829 52830 52831 52832 52833 52834 52835 52836 52837 52838 52839 52840 52841 52842 52843 52844 52845 52846 52847 52848 52849 52850 52851 52852 52853 52854 52855 52856 52857 52858 52859 52860 52861 52862 52863 52864 52865 52866 52867 52868 52869 52870 52871 52872 52873 52874 52875 52876 52877 52878 52879 52880 52881 52882 52883 52884 52885 52886 52887 52888 52889 52890 52891 52892 52893 52894 52895 52896 52897 52898 52899 52900 52901 52902 52903 52904 52905 52906 52907 52908 52909 52910 52911 52912 52913 52914 52915 52916 52917 52918 52919 52920 52921 52922 52923 52924 52925 52926 52927 52928 52929 52930 52931 52932 52933 52934 52935 52936 52937 52938 52939 52940 52941 52942 52943 52944 52945 52946 52947 52948 52949 52950 52951 52952 52953 52954 52955 52956 52957 52958 52959 52960 52961 52962 52963 52964 52965 52966 52967 52968 52969 52970 52971 52972 52973 52974 52975 52976 52977 52978 52979 52980 52981 52982 52983 52984 52985 52986 52987 52988 52989 52990 52991 52992 52993 52994 52995 52996 52997 52998 52999 53000 53001 53002 53003 53004 53005 53006 53007 53008 53009 53010 53011 53012 53013 53014 53015 53016 53017 53018 53019 53020 53021 53022 53023 53024 53025 53026 53027 53028 53029 53030 53031 53032 53033 53034 53035 53036 53037 53038 53039 53040 53041 53042 53043 53044 53045 53046 53047 53048 53049 53050 53051 53052 53053 53054 53055 53056 53057 53058 53059 53060 53061 53062 53063 53064 53065 53066 53067 53068 53069 53070 53071 53072 53073 53074 53075 53076 53077 53078 53079 53080 53081 53082 53083 53084 53085 53086 53087 53088 53089 53090 53091 53092 53093 53094 53095 53096 53097 53098 53099 53100 53101 53102 53103 53104 53105 53106 53107 53108 53109 53110 53111 53112 53113 53114 53115 53116 53117 53118 53119 53120 53121 53122 53123 53124 53125 53126 53127 53128 53129 53130 53131 53132 53133 53134 53135 53136 53137 53138 53139 53140 53141 53142 53143 53144 53145 53146 53147 53148 53149 53150 53151 53152 53153 53154 53155 53156 53157 53158 53159 53160 53161 53162 53163 53164 53165 53166 53167 53168 53169 53170 53171 53172 53173 53174 53175 53176 53177 53178 53179 53180 53181 53182 53183 53184 53185 53186 53187 53188 53189 53190 53191 53192 53193 53194 53195 53196 53197 53198 53199 53200 53201 53202 53203 53204 53205 53206 53207 53208 53209 53210 53211 53212 53213 53214 53215 53216 53217 53218 53219 53220 53221 53222 53223 53224 53225 53226 53227 53228 53229 53230 53231 53232 53233 53234 53235 53236 53237 53238 53239 53240 53241 53242 53243 53244 53245 53246 53247 53248 53249 53250 53251 53252 53253 53254 53255 53256 53257 53258 53259 53260 53261 53262 53263 53264 53265 53266 53267 53268 53269 53270 53271 53272 53273 53274 53275 53276 53277 53278 53279 53280 53281 53282 53283 53284 53285 53286 53287 53288 53289 53290 53291 53292 53293 53294 53295 53296 53297 53298 53299 53300 53301 53302 53303 53304 53305 53306 53307 53308 53309 53310 53311 53312 53313 53314 53315 53316 53317 53318 53319 53320 53321 53322 53323 53324 53325 53326 53327 53328 53329 53330 53331 53332 53333 53334 53335 53336 53337 53338 53339 53340 53341 53342 53343 53344 53345 53346 53347 53348 53349 53350 53351 53352 53353 53354 53355 53356 53357 53358 53359 53360 53361 53362 53363 53364 53365 53366 53367 53368 53369 53370 53371 53372 53373 53374 53375 53376 53377 53378 53379 53380 53381 53382 53383 53384 53385 53386 53387 53388 53389 53390 53391 53392 53393 53394 53395 53396 53397 53398 53399 53400 53401 53402 53403 53404 53405 53406 53407 53408 53409 53410 53411 53412 53413 53414 53415 53416 53417 53418 53419 53420 53421 53422 53423 53424 53425 53426 53427 53428 53429 53430 53431 53432 53433 53434 53435 53436 53437 53438 53439 53440 53441 53442 53443 53444 53445 53446 53447 53448 53449 53450 53451 53452 53453 53454 53455 53456 53457 53458 53459 53460 53461 53462 53463 53464 53465 53466 53467 53468 53469 53470 53471 53472 53473 53474 53475 53476 53477 53478 53479 53480 53481 53482 53483 53484 53485 53486 53487 53488 53489 53490 53491 53492 53493 53494 53495 53496 53497 53498 53499 53500 53501 53502 53503 53504 53505 53506 53507 53508 53509 53510 53511 53512 53513 53514 53515 53516 53517 53518 53519 53520 53521 53522 53523 53524 53525 53526 53527 53528 53529 53530 53531 53532 53533 53534 53535 53536 53537 53538 53539 53540 53541 53542 53543 53544 53545 53546 53547 53548 53549 53550 53551 53552 53553 53554 53555 53556 53557 53558 53559 53560 53561 53562 53563 53564 53565 53566 53567 53568 53569 53570 53571 53572 53573 53574 53575 53576 53577 53578 53579 53580 53581 53582 53583 53584 53585 53586 53587 53588 53589 53590 53591 53592 53593 53594 53595 53596 53597 53598 53599 53600 53601 53602 53603 53604 53605 53606 53607 53608 53609 53610 53611 53612 53613 53614 53615 53616 53617 53618 53619 53620 53621 53622 53623 53624 53625 53626 53627 53628 53629 53630 53631 53632 53633 53634 53635 53636 53637 53638 53639 53640 53641 53642 53643 53644 53645 53646 53647 53648 53649 53650 53651 53652 53653 53654 53655 53656 53657 53658 53659 53660 53661 53662 53663 53664 53665 53666 53667 53668 53669 53670 53671 53672 53673 53674 53675 53676 53677 53678 53679 53680 53681 53682 53683 53684 53685 53686 53687 53688 53689 53690 53691 53692 53693 53694 53695 53696 53697 53698 53699 53700 53701 53702 53703 53704 53705 53706 53707 53708 53709 53710 53711 53712 53713 53714 53715 53716 53717 53718 53719 53720 53721 53722 53723 53724 53725 53726 53727 53728 53729 53730 53731 53732 53733 53734 53735 53736 53737 53738 53739 53740 53741 53742 53743 53744 53745 53746 53747 53748 53749 53750 53751 53752 53753 53754 53755 53756 53757 53758 53759 53760 53761 53762 53763 53764 53765 53766 53767 53768 53769 53770 53771 53772 53773 53774 53775 53776 53777 53778 53779 53780 53781 53782 53783 53784 53785 53786 53787 53788 53789 53790 53791 53792 53793 53794 53795 53796 53797 53798 53799 53800 53801 53802 53803 53804 53805 53806 53807 53808 53809 53810 53811 53812 53813 53814 53815 53816 53817 53818 53819 53820 53821 53822 53823 53824 53825 53826 53827 53828 53829 53830 53831 53832 53833 53834 53835 53836 53837 53838 53839 53840 53841 53842 53843 53844 53845 53846 53847 53848 53849 53850 53851 53852 53853 53854 53855 53856 53857 53858 53859 53860 53861 53862 53863 53864 53865 53866 53867 53868 53869 53870 53871 53872 53873 53874 53875 53876 53877 53878 53879 53880 53881 53882 53883 53884 53885 53886 53887 53888 53889 53890 53891 53892 53893 53894 53895 53896 53897 53898 53899 53900 53901 53902 53903 53904 53905 53906 53907 53908 53909 53910 53911 53912 53913 53914 53915 53916 53917 53918 53919 53920 53921 53922 53923 53924 53925 53926 53927 53928 53929 53930 53931 53932 53933 53934 53935 53936 53937 53938 53939 53940 53941 53942 53943 53944 53945 53946 53947 53948 53949 53950 53951 53952 53953 53954 53955 53956 53957 53958 53959 53960 53961 53962 53963 53964 53965 53966 53967 53968 53969 53970 53971 53972 53973 53974 53975 53976 53977 53978 53979 53980 53981 53982 53983 53984 53985 53986 53987 53988 53989 53990 53991 53992 53993 53994 53995 53996 53997 53998 53999 54000 54001 54002 54003 54004 54005 54006 54007 54008 54009 54010 54011 54012 54013 54014 54015 54016 54017 54018 54019 54020 54021 54022 54023 54024 54025 54026 54027 54028 54029 54030 54031 54032 54033 54034 54035 54036 54037 54038 54039 54040 54041 54042 54043 54044 54045 54046 54047 54048 54049 54050 54051 54052 54053 54054 54055 54056 54057 54058 54059 54060 54061 54062 54063 54064 54065 54066 54067 54068 54069 54070 54071 54072 54073 54074 54075 54076 54077 54078 54079 54080 54081 54082 54083 54084 54085 54086 54087 54088 54089 54090 54091 54092 54093 54094 54095 54096 54097 54098 54099 54100 54101 54102 54103 54104 54105 54106 54107 54108 54109 54110 54111 54112 54113 54114 54115 54116 54117 54118 54119 54120 54121 54122 54123 54124 54125 54126 54127 54128 54129 54130 54131 54132 54133 54134 54135 54136 54137 54138 54139 54140 54141 54142 54143 54144 54145 54146 54147 54148 54149 54150 54151 54152 54153 54154 54155 54156 54157 54158 54159 54160 54161 54162 54163 54164 54165 54166 54167 54168 54169 54170 54171 54172 54173 54174 54175 54176 54177 54178 54179 54180 54181 54182 54183 54184 54185 54186 54187 54188 54189 54190 54191 54192 54193 54194 54195 54196 54197 54198 54199 54200 54201 54202 54203 54204 54205 54206 54207 54208 54209 54210 54211 54212 54213 54214 54215 54216 54217 54218 54219 54220 54221 54222 54223 54224 54225 54226 54227 54228 54229 54230 54231 54232 54233 54234 54235 54236 54237 54238 54239 54240 54241 54242 54243 54244 54245 54246 54247 54248 54249 54250 54251 54252 54253 54254 54255 54256 54257 54258 54259 54260 54261 54262 54263 54264 54265 54266 54267 54268 54269 54270 54271 54272 54273 54274 54275 54276 54277 54278 54279 54280 54281 54282 54283 54284 54285 54286 54287 54288 54289 54290 54291 54292 54293 54294 54295 54296 54297 54298 54299 54300 54301 54302 54303 54304 54305 54306 54307 54308 54309 54310 54311 54312 54313 54314 54315 54316 54317 54318 54319 54320 54321 54322 54323 54324 54325 54326 54327 54328 54329 54330 54331 54332 54333 54334 54335 54336 54337 54338 54339 54340 54341 54342 54343 54344 54345 54346 54347 54348 54349 54350 54351 54352 54353 54354 54355 54356 54357 54358 54359 54360 54361 54362 54363 54364 54365 54366 54367 54368 54369 54370 54371 54372 54373 54374 54375 54376 54377 54378 54379 54380 54381 54382 54383 54384 54385 54386 54387 54388 54389 54390 54391 54392 54393 54394 54395 54396 54397 54398 54399 54400 54401 54402 54403 54404 54405 54406 54407 54408 54409 54410 54411 54412 54413 54414 54415 54416 54417 54418 54419 54420 54421 54422 54423 54424 54425 54426 54427 54428 54429 54430 54431 54432 54433 54434 54435 54436 54437 54438 54439 54440 54441 54442 54443 54444 54445 54446 54447 54448 54449 54450 54451 54452 54453 54454 54455 54456 54457 54458 54459 54460 54461 54462 54463 54464 54465 54466 54467 54468 54469 54470 54471 54472 54473 54474 54475 54476 54477 54478 54479 54480 54481 54482 54483 54484 54485 54486 54487 54488 54489 54490 54491 54492 54493 54494 54495 54496 54497 54498 54499 54500 54501 54502 54503 54504 54505 54506 54507 54508 54509 54510 54511 54512 54513 54514 54515 54516 54517 54518 54519 54520 54521 54522 54523 54524 54525 54526 54527 54528 54529 54530 54531 54532 54533 54534 54535 54536 54537 54538 54539 54540 54541 54542 54543 54544 54545 54546 54547 54548 54549 54550 54551 54552 54553 54554 54555 54556 54557 54558 54559 54560 54561 54562 54563 54564 54565 54566 54567 54568 54569 54570 54571 54572 54573 54574 54575 54576 54577 54578 54579 54580 54581 54582 54583 54584 54585 54586 54587 54588 54589 54590 54591 54592 54593 54594 54595 54596 54597 54598 54599 54600 54601 54602 54603 54604 54605 54606 54607 54608 54609 54610 54611 54612 54613 54614 54615 54616 54617 54618 54619 54620 54621 54622 54623 54624 54625 54626 54627 54628 54629 54630 54631 54632 54633 54634 54635 54636 54637 54638 54639 54640 54641 54642 54643 54644 54645 54646 54647 54648 54649 54650 54651 54652 54653 54654 54655 54656 54657 54658 54659 54660 54661 54662 54663 54664 54665 54666 54667 54668 54669 54670 54671 54672 54673 54674 54675 54676 54677 54678 54679 54680 54681 54682 54683 54684 54685 54686 54687 54688 54689 54690 54691 54692 54693 54694 54695 54696 54697 54698 54699 54700 54701 54702 54703 54704 54705 54706 54707 54708 54709 54710 54711 54712 54713 54714 54715 54716 54717 54718 54719 54720 54721 54722 54723 54724 54725 54726 54727 54728 54729 54730 54731 54732 54733 54734 54735 54736 54737 54738 54739 54740 54741 54742 54743 54744 54745 54746 54747 54748 54749 54750 54751 54752 54753 54754 54755 54756 54757 54758 54759 54760 54761 54762 54763 54764 54765 54766 54767 54768 54769 54770 54771 54772 54773 54774 54775 54776 54777 54778 54779 54780 54781 54782 54783 54784 54785 54786 54787 54788 54789 54790 54791 54792 54793 54794 54795 54796 54797 54798 54799 54800 54801 54802 54803 54804 54805 54806 54807 54808 54809 54810 54811 54812 54813 54814 54815 54816 54817 54818 54819 54820 54821 54822 54823 54824 54825 54826 54827 54828 54829 54830 54831 54832 54833 54834 54835 54836 54837 54838 54839 54840 54841 54842 54843 54844 54845 54846 54847 54848 54849 54850 54851 54852 54853 54854 54855 54856 54857 54858 54859 54860 54861 54862 54863 54864 54865 54866 54867 54868 54869 54870 54871 54872 54873 54874 54875 54876 54877 54878 54879 54880 54881 54882 54883 54884 54885 54886 54887 54888 54889 54890 54891 54892 54893 54894 54895 54896 54897 54898 54899 54900 54901 54902 54903 54904 54905
|
2025-11-06 Dodji Seketeli <dodji@redhat.com>
configure: Bump soname b/c of ABI-incompatible changes
* configure.ac: Several changes, notably in include/abg-ir.h to
make function_decl be a scope, are ABI-incompatible. Thus, bump
the SONAME here.
2025-10-05 Dodji Seketeli <dodji@redhat.com>
symtab-reader: Fix comments of the undefined symbols data members
* src/abg-symtab-reader.h (symtab::{undefined_fn_symbols_,
undefined_var_symbols_}): Fix comments.
2025-10-03 Dodji Seketeli <dodji@redhat.com>
symtab-reader: Speedup lookup_undefined_{function,variable}_symbol
* src/abg-symtab-reader.h (symtab::undefined_{fn,var}_symbols_):
Add new data members.
* src/abg-symtab-reader.cc (symtab::load_): Populate the newly
introduced symtab::undefined_{fn,var}_symbols_ with undefined
function and variable symbols.
2025-08-25 Orion Poplawski <orion@nwra.com>
Bug 33264 - Add --ignore-soname to abipkgdiff
* doc/manuals/abipkgdiff.rst: Document the new option
--ignore-soname.
* tools/abipkgdiff.cc (options::options): Initialize ...
(options::ignore_soname): ... the new data member.
(parse_command_line): Parse the new --ignore-soname options ...
(display_usage): ... and document it.
(set_diff_context_from_opts): Set ctxt->show_soname_change
accordingly.
(package::convert_path_to_relative): Do not resolve symbolic links
to their target.
(compare_task::maybe_emit_pretty_error_message_to_output): Add
path of the binary for which no ABI change was detected.
(create_maps_of_package_set_content): If the user asked to ignore
SONAMEs, then take the same path as if the current shared library
has no SONAME. However, no not resolve symlink paths to their
target in that mode.
* tests/data/test-diff-pkg/PR33264/simdjson-3.12.3-2.el10.x86_64--simdjson-3.13.0-1.el10.x86_64-report-{1,2}.txt:
Add new reference test output.
* tests/data/test-diff-pkg/PR33264/simdjson-3.12.3/simdjson-3.12.3-2.el10.x86_64.rpm:
New binary test input.
* tests/data/test-diff-pkg/PR33264/simdjson-3.12.3/simdjson-debuginfo-3.12.3-2.el10.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR33264/simdjson-3.12.3/simdjson-devel-3.12.3-2.el10.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR33264/simdjson-3.13.0/simdjson-3.13.0-1.el10.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR33264/simdjson-3.13.0/simdjson-debuginfo-3.13.0-1.el10.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR33264/simdjson-3.13.0/simdjson-devel-3.13.0-1.el10.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/test-dbus-glib-0.80-3.fc12.x86_64-report-0.txt:
Adjust
* tests/data/test-fedabipkgdiff/vte291-0.39.1-1.fc22.x86_64--vte291-0.39.90-1.fc22.x86_64-report-0.txt:
Adjust.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new tests inputs
to this test harness.
2025-09-24 Dodji Seketeli <dodji@redhat.com>
tests/Makefile.am: Filter out more binaries when using valgrind --trace-children
* tests/Makefile.am: Add /usr/bin/sed,/usr/bin/diff,/usr/bin/ls to
the argument of the --trace-children-skip option.
2025-09-24 Dodji Seketeli <dodji@redhat.com>
abi{diff,dw}: Fix memory leak
* tools/abidiff.cc (parse_command_line): Use make_path_absolute
instead of make_path_absolute_to_be_freed.
* tools/abidw.cc (parse_command_line): Likewise.
* include/abg-tools-utils.h (make_path_absolute_to_be_freed):
Remove ...
* src/abg-tools-utils.cc (make_path_absolute_to_be_freed): ... the
Definition of this function.
2025-09-23 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Fix memory leak in lookup_symbol_in_ctf_archive
* tests/data/test-diff-pkg-ctf/test-rpm-report-1.txt: Adjust.
* tests/data/test-diff-pkg-ctf/test-rpm-report-2.txt: Likewise.
2025-09-23 Dodji Seketeli <dodji@redhat.com>
libxml-utils: Pass paramater to xml_char_sptr_to_string by reference
* include/abg-libxml-utils.h (xml_char_sptr_to_string): Pass the
xml_char_sptr parameter by ...
* src/abg-libxml-utils.cc (xml_char_sptr_to_string):
... reference.
2025-09-05 Frank Ch. Eigler <fche@redhat.com>
abidb --submit: add "--no-corpus-path" to abidw invocation
* tools/abidb: add "--no-corpus-path" to abidw invocation
2025-09-05 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Avoid adding declarations-only global vars to IR
* src/abg-dwarf-reader.cc (build_ir_node_from_die): When looking
at the DIE for a variable, create an IR for it if it has an ELF
symbol.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2025-09-05 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Merge static data members among classes of the same name
* include/abg-ir.h (copy_member_variable): Declare ...
* src/abg-ir.cc (copy_member_variable): ... new functions.
(maybe_adjust_canonical_type): Add an assert for
data members discrepancies among classes of the same name and same
corpus.
* src/abg-dwarf-reader.cc (reader::{copy_missing_member_variables,
merge_member_variables_of_classes}): Define new member functions.
(reader::merge_member_functions_and_variables_in_classes_of_same_names):
Renamed reader::merge_member_functions_in_classes_of_same_names
into this. Do not perform the merging on anonymous classes.
Perform merging of data members as well as merging of member
functions.
(reader::read_debug_info_into_corpus): Adjust to
merge_member_functions_in_classes_of_same_names into
merge_member_functions_and_variables_in_classes_of_same_names.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2025-09-05 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix reader::merge_member_functions_of_classes
* src/abg-dwarf-reader.cc
(reader::merge_member_functions_of_classes): Avoid merging member
functions across classes of different names.
2025-09-05 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir: Cleanup signatures of copy_member_function
* include/abg-ir.h (copy_member_function): Make the destination
class not be a const reference.
* src/abg-ir.cc (copy_member_function): Likewise.
* src/abg-dwarf-reader.cc (copy_missing_member_functions):
Likewise.
2025-09-02 Dodji Seketeli <dodji@redhat.com>
big-tests: Update big-tests to commit 54686ed675463e4e846d0d8a9bc8766abf2c517b
* big-tests: Update to commit
54686ed675463e4e846d0d8a9bc8766abf2c517b of repository
https://sourceware.org/git/libabigail-tests.git.
2025-08-07 Claudiu Zissulescu <claudiu.zissulescu-ianculescu@oracle.com>
abicompat: Add the ability to process abi corpus groups
* include/abg-corpus.h (corpus::lookup_{function,variable}s):
Make these member functions virtual.
(corpus_group::{lookup_{function,variable}s): Add new overloads.
* src/abg-corpus.cc (corpus_group::{lookup_{function,variable}s):
Define new virtual overloads that walk over each corpus, invokes
corpus::lookup_{functions,variables} on them and return the first
one that is non-nil.
* tests/data/test-abicompat/libtest11-fn-changed.xml: New test input.
* tests/data/test-abicompat/test11-fn-changed-app.xml: Likewise.
* tests/data/test-abicompat/test11-fn-changed.txt: Likewise.
* tests/test-abicompat.cc (in_out_specs): Add the new test
material above to this test harness.
* tools/abicompat.cc (read_corpus): Support
abigail::tools_utils::FILE_TYPE_XML_CORPUS_GROUP kind of input file.
2025-08-22 Dodji Seketeli <dodji@redhat.com>
tools-utils: Fix a memory leak in find_file_under_dir
* src/abg-tools-utils.cc (find_file_under_dir): Do not forget to
fts_close the file_hierarchy that was previously fts_open-ed.
2025-08-22 Dodji Seketeli <dodji@redhat.com>
elf-reader: Use -1 as a sentinel value for file descriptors
* src/abg-elf-reader.cc (reader::priv::alt_{ctd,dwarf}_fd):
Initialize to -1 instead of 0.
(reader::priv::{initialize, clear_alt_dwarf_debug_info_data,
clear_alt_ctf_debug_info_data}): Likewise.
2025-08-22 Dodji Seketeli <dodji@redhat.com>
Bug 33279 - elf-reader: Fix a file descriptor leak
* src/abg-elf-reader.cc (reader::priv::locate_alt_ctf_debug_info):
Do not leak the file descriptor initially stored in
reader::priv::alt_ctf_fd.
2025-08-22 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Fix thinko in reader::initialize
* src/abg-ctf-reader.cc (ctf::reader::initialize): Fix thinko.
2025-07-04 Dodji Seketeli <dodji@redhat.com>
Website: Update for 2.8 release
* doc/website/mainpage.txt: Update for 2.8 release
2025-08-21 Dodji Seketeli <dodji@redhat.com>
gen-changelog: Fix comments & cleanups
* gen-changelog.py (process_commit): Fix comments & cleanups.
2025-08-21 Dodji Seketeli <dodji@redhat.com>
gen-changelog: Add default description for missing ChangeLog entries
* gen-changelog.py (process_commit): Add a default entry made of
the content of the subject title.
2025-08-21 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix indentation
* src/abg-dwarf-reader.cc (build_function_decl): Fix indentation.
2025-08-19 Dodji Seketeli <dodji@redhat.com>
Bug 28642 - vtable offset position seems wrong
* src/abg-dwarf-reader.cc (die_virtual_function_index): Initialize
the default value of the vtable index of the function to 0.
* tests/data/test-abidiff-exit/PR33055/PR33055-report-2.txt:
Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-dwarf/test29-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2025-08-19 Dodji Seketeli <dodji@redhat.com>
ir: Avoid crashing canonicalizing anonymous types with member fns
* src/abg-ir.cc (maybe_adjust_canonical_type): Don't bother
detecting discrepancies between member functions of the
canonicalized class and member functions of the canonical class
for anonymous classes.
2025-08-19 Dodji Seketeli <dodji@redhat.com>
Fix compilation with Clang
* include/abg-comparison.h (class type_diff_base): Remove private
default constructor. Rather, declare it as a deleted default
constructor.
(class ptr_to_mbr_diff): The default contructor is deleted, not
defaulted.
* src/abg-dwarf-reader.cc (get_die_qualified_name): Remove unused
function.
(die_enum_flat_representation): Add missing parenthesis around
"?:" expression coming after the << operator.
* src/abg-ir.cc (collect_non_anonymous_data_members): Fix unused
variable.
* src/abg-suppression.cc (is_negated_suppression): Fix expression
that might not be evaluated.
* src/abg-tools-utils.cc (ANONYMOUS_SUBRANGE_INTERNAL_NAME_LEN):
Remove useless static variable.
2025-08-14 Frank Ch. Eigler <fche@redhat.com>
PR33278: abidb: fix -Zextension mode
* tools/abidb: fix -Zextension mode
2025-07-28 Dodji Seketeli <dodji@redhat.com>
Bug 33192 - Crash of "abidw --follow-dependencies <binary>"
* tools/abidw.cc (load_corpus_and_write_abixml): Make sure that
corp_group is non-NULL before de-referencing it.
* tests/data/test-read-dwarf/test0.deps.abi: New reference test
output.
* tests/data/Makefile.am: Add it to source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add a new test entry
that invokes abidw --follow-dependencies on the existing
tests/data/test-read-dwarf/test0
2025-07-04 Dodji Seketeli <dodji@redhat.com>
configure: Bump version number to 2.9
* configure.ac: Bump version number to 2.9
2025-07-04 Dodji Seketeli <dodji@redhat.com>
ChangeLog: Update for 2.8 release
* ChangeLog: Update automatically by using gen-changelog.py.
2025-07-04 Dodji Seketeli <dodji@redhat.com>
NEWS: Update for 2.8 release
* NEWS: Update for 2.8 release.
2025-07-04 Dodji Seketeli <dodji@redhat.com>
configure: Bump libabigail_so_current to 7
* configure.ac: bump libabigail_so_current to 7.
2025-07-02 Dodji Seketeli <dodji@redhat.com>
Bug 26021 - Upgrade the C++ standard to C++14
* configure.ac: Upgrade the code base to c++14. This is the
default in GCC 8.5, used in EL8, the oldest platform that we
currently support.
2025-06-30 Dodji Seketeli <dodji@redhat.com>
tests/data/test-read-dwarf/PR33090: Add missing test material
* tests/data/test-read-dwarf/PR33090/bug{1,2}.c: Really add this.
* tests/data/test-read-dwarf/PR33090/impl{1,2}.so: Likewise.
* tests/data/test-read-dwarf/PR33090/impl{1,2}.so.abi: Likewise.
* tests/data/test-read-dwarf/PR33090/interface.h: Likewise.
* tests/data/test-read-dwarf/PR33090/private.suppr: Likewise.
2025-06-30 Dodji Seketeli <dodji@redhat.com>
Bug 33090 - Implement abidw --force-early-suppression
* doc/manuals/abidw.rst: Add documentation for the new
--force-early-suppression. Adjust the docs for the
--drop-private-types, --headers-dir, --headers-file and
--suppressions.
* doc/manuals/suppression-specifications.rst: Adjust
documentation for early suppression mode.
* tools/abidw.cc (options::force_early_suppression): Define new
data member.
(options::options): Initialize the new
options::force_early_suppression.
(display_usage): Document the new --force-early-suppression.
(parse_command_line): Support the new --force-early-suppression.
Also, if --header-dirs or --header-file is set, then set
--drop-private-types.
(set_suppressions): If --force-early-suppression is provided, then
force suppressed IR node to be dropped from memory.
* tests/test-read-common.h
(test_task::set_in_public_headers_path): Reset the
in_public_headers_path by default.
(test_task::set_in_options): Define new member function.
* tests/test-read-dwarf.cc (in_out_specs): Add the new test input
binaries below to the test harness.
(test_task_dwarf::perform): Take the additional command line
options into account.
* tests/data/test-read-dwarf/PR33090/bug[12].c: Source code
for new test input binary.
* tests/data/test-read-dwarf/PR33090/impl{1,2}.so: Add new binary
test input.
* tests/data/test-read-dwarf/PR33090/impl{1,2}.so.abi: Add new
expected ABIXML output.
* tests/data/test-read-dwarf/PR33090/interface.h: Source code for
new test input binary.
* tests/data/test-read-dwarf/PR33090/private.suppr: Suppression
specification for new input test.
2025-06-30 Dodji Seketeli <dodji@redhat.com>
elf-reader,symtab-reader: Fix suppression of aliased symbols
* src/abg-elf-reader.cc (reader::symtab): Rewrite the closure that
determines if a symbol is suppressed. Make it so that all aliases
of a symbol has to be suppressed for the symbol to be suppressed.
* src/abg-symtab-reader.cc (symtab::load_): Wait until all symbols
aliases are constructed before determining if they are suppressed.
This is because aliases are now necessary to determine if a symbol
is suppressed.
* tests/test-read-common.h (test_task::set_in_suppr_spec_path):
Empty suppression specification shouldn't trigger us.
* tests/test-read-dwarf.cc (test_task_dwarf::perform): Take the
suppression specifications into account on the command line.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi:
Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
2025-06-30 Dodji Seketeli <dodji@redhat.com>
abidw: Sort options documentation alphabetically
* doc/manuals/abidw.rst: Sort items of options documentation
alphabetically.
* tools/abidw.cc (display_usage): Likewise.
2025-06-30 Dodji Seketeli <dodji@redhat.com>
symtab-reader: Add missing space
* src/abg-symtab-reader.cc (symtab::setup_symbol_lookup_tables):
Add a missing space to the comment.
2025-06-23 Dodji Seketeli <dodji@redhat.com>
abg-comparison: Fix indentation
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Fix
indentation.
2025-06-23 Dodji Seketeli <dodji@redhat.com>
abg-comparison: Do not abort when a static data member is deleted
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Do not choke
if a static data member is removed.
2025-06-16 Dodji Seketeli <dodji@redhat.com>
Bug 33055 - classes_have_same_layout & types_are_compatible enter in endless loop
* src/abg-ir-priv.h (class_or_union::priv): Add a set of
type_base* to record the classes which layouts are being compared
against this one.
* src/abg-ir.cc (classes_have_same_layout): If this type is
already involved in comparing class layouts using
classes_have_same_layout then do get out early to avoid calling
types_are_compatible.
* tests/data/test-abidiff-exit/PR33055/Makefile: New Makefile to
build the test input binaries.
* tests/data/test-abidiff-exit/PR33055/PR33055-report-[12].txt:
New expected reference test output.
* tests/data/test-abidiff-exit/PR33055/file.cpp: Source code of
the test binaries.
* tests/data/test-abidiff-exit/PR33055/{new,old}-lib.so: New test
input binaries.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new test
binary inputs to this harness.
2025-06-19 Dodji Seketeli <dodji@redhat.com>
Improve harmless integral type change filtering
* src/abg-comparison.cc (distinct_diff::compatible_child_diff):
Simplify and fix logic. If the diff subjects are entities are of
distinct kind and if they are compatible types then make this node
describe the actual changes between the peeled down subjects.
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for const distinct_diff, do not report the child diff
node describing the peeled down changes to avoid endless
recursion.
* src/abg-ir.cc (classes_have_same_layout): Fix a thinko in the
detection of compatible method types.
(integral_type_has_harmless_name_change): Simplify and fix
logic. Two integral types of the same size/alignment but with
different names are considered as a harmless change. Note that
for types with empty names, for now, detecting if they are
integral types is broken. So let's consider them as integral for
now. This will have to be changed when the DWARF reader is fixed
for better handling the case of integral types detection.
* tests/data/test-abidiff-exit/PR30048-test-report-0.txt: Adjust.
* tests/data/test-abidiff-exit/btf/test0-report-2.txt: Likewise.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Likewise
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v1-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v4-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v5-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v5-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/test-changed-var-1-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-loc-with-locs-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-loc-without-locs-report.txt:
Likewise.
* tests/data/test-diff-dwarf/test2-report.txt: Likewise.
* tests/data/test-diff-dwarf/test4-report.txt: Likewise.
* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
* tests/data/test-diff-filter/test18-report.txt: Likewise.
* tests/data/test-diff-filter/test24-compatible-vars-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test36-report-0.txt: Likewise.
* tests/data/test-diff-filter/test5-2-report.txt: Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-2-report.1.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-2-report.txt:
Likewise.
* tests/test-abidiff-exit.cc (in_out_specs): Now that several
benign integral type changes are considered harmless, adjust the
expected result of the tests.
2025-06-12 Dodji Seketeli <dodji@redhat.com>
test-abicompat: Fix color setting
* tests/test-abicompat.cc (main): Set the terminal default back.
2025-06-12 Dodji Seketeli <dodji@redhat.com>
Bug 33076 - abicompat doesn't filter out harmless diff nodes
* include/abg-comparison.h (is_diff): Add a new template function.
(apply_filters_and_categorize_diff_node_tree): Rename
apply_filters into this new function.
* src/abg-comparison.cc
(apply_filters_and_categorize_diff_node_tree): Rename
apply_filters into this. Make it apply suppression
specifications and all categorization filters.
* tests/data/test-abicompat/test-diff-ptr-to-void-ptr/0/libtest-diff-ptr-to-void-ptr-fn.so:
New binary test input.
* tests/data/test-abicompat/test-diff-ptr-to-void-ptr/0/test-diff-ptr-to-void-ptr-fn-v0.c:
Source code of binary test input.
* tests/data/test-abicompat/test-diff-ptr-to-void-ptr/1/libtest-diff-ptr-to-void-ptr-fn.so:
New binary test input.
* tests/data/test-abicompat/test-diff-ptr-to-void-ptr/1/test-diff-ptr-to-void-ptr-fn-v1.c:
Source code of binary test input.
* tests/data/test-abicompat/test-diff-ptr-to-void-ptr/test-diff-ptr-to-void-ptr-app:
New binary test input.
* tests/data/test-abicompat/test-diff-ptr-to-void-ptr/test-diff-ptr-to-void-ptr-app.c:
Source code of binary test input.
* tests/data/test-abicompat/test-diff-ptr-to-void-ptr/test-diff-ptr-to-void-ptr-report-[01].txt:
New reference test output.
* tests/data/Makefile.am: Add new test material to source
distribution.
* tests/test-abicompat.cc: Add new test input to this harness.
* tests/print-diff-tree.cc (main): Adjust.
* tools/abicompat.cc (create_diff_context): Filter out harmless
change categories by default.
(compare_expected_against_provided_{function,variable}s): Use the
new apply_filters_and_categorize_diff_node_tree.
2025-06-06 Dodji Seketeli <dodji@redhat.com>
Bug 30329 - Fix regression in support for absolute path to alt DWARF
* src/abg-elf-reader.cc (find_alt_dwarf_debug_info_path)
(find_alt_dwarf_debug_info): Remove static functions.
(reader::priv::find_alt_dwarf_debug_info): Remove member function.h
(reader::priv::{formated_di_root_paths,
raw_formated_di_root_paths}): Add new data members.
(reader::priv::initialize): Initialize the new data members.
(reader::priv::initialize_debug_info_root_paths): Define new
member function.
(reader::priv::crack_open_elf_file): Invoke the new
initialize_debug_info_root_paths above. Adjust the call to
elf_helpers::initialize_dwfl_callbacks to pass the new
raw_formated_di_root_paths.
(reader::priv::locate_dwarf_debug_info): Remove all the
unnecessary cruft. Just rely on elfutils finding the debug info,
now that it's been properly initialized. Use the dwarf_getalt
function that is now always present in the versions of elfutils
that we use.
That later fix actually temporarily broke the initial fix for "Bug
30329".
This patch handles the case of a DWZ-produced alternate DWARF being
referenced by an absolute path which happens to be under the root
debug info dir (e.g,
"/usr/lib/debug/dwz/components/sqlite.bst/x86_64-unknown-linux-gnu",
under the root dir "/usr/lib/debug").
The idea of the fix is to automatically add a
"/usr/lib/debug/dwz/components/sqlite.bst" as a debuginfo dir because
it is under the root dir /usr/lib/debug and because it contains a
file.
* include/abg-tools-utils.h (get_file_path_dirs_under_dir):
Declare ...
* src/abg-tools-utils.cc (get_file_path_dirs_under_dir): ... new
function.
(is_file): Define new static function.
* src/abg-elf-reader.cc
(reader::priv::initialize_debug_info_root_paths): Add
sub-directories (that contain files) of root debuginfo dirs to the
set of debug info root paths to be considered by elfutils.
* tests/test-abidiff-exit.cc (in_out_specs): Add a new test case
for
data/test-abidiff-exit/PR30329/old-image/usr/lib/x86_64-linux-gnu/libsqlite3.so.0.8.6
where two debuginfo root dirs are added.
(main): Support adding several comma-separated debuginfo root
dirs to InOutSpec::in_elfv[01]_debug_dir.
2025-06-06 Dodji Seketeli <dodji@redhat.com>
Change debuginfo root paths type from vector<char**> to vector<string>
* include/abg-btf-reader.h (btf::create_reader): Take
vector<string>& instead of vector<char**>& for
debug_info_root_paths.
* include/abg-ctf-reader.h (ctf::{create,reset}_reader):
Likewise.
* include/abg-dwarf-reader.h (dwarf::{create,reset}_reader)
(read_corpus_from_elf): Likewise.
* include/abg-elf-based-reader.h (elf_based_reader::initialize):
Likewise.
* include/abg-elf-reader.h (elf::reader::{reader, initialize,
debug_info_root_paths}): Likewise.
* include/abg-tools-utils.h (file_has_{dwarf,ctf,btf}_debug_info)
(create_best_elf_based_reader): Likewise.
(get_file_path_dirs_under_dir): Declare new function.
(make_path_absolute): Add an overload for string.
* src/abg-btf-reader.cc (btf::reader::{initialize, reader, create,
create_reader}): Take vector<string>& instead of vector<char**>&
for debug_info_root_paths.
* src/abg-ctf-reader.cc (ctf::reader::{reader, initialize,
create_reader, reset_reader}): Likewise.
* src/abg-dwarf-reader.cc (dwarf::reader::{reader, initialize,
create, create_reader, read_corpus_from_elf}): Likewise.
* src/abg-elf-based-reader.cc
(elf_based_reader::{elf_based_reader, initialize}): Likewise.
* src/abg-elf-reader.cc
(elf::reader::priv::debug_info_root_paths): Change the type of
this data member from vector<char**> to vector<string>.
(elf::reader::priv::{priv, initialize}): Take vector<string>&
instead of vector<char**>& for debug_info_root_paths and adjust
the body accordingly.
(elf::reader::{reader, initialize, debug_info_root_paths}): Take
or return vector<string>& instead of vector<char**>&
* src/abg-tools-utils.cc (file_has_{dwarf,ctf,btf}_debug_info)
(load_vmlinux_corpus, create_best_elf_based_reader): Likewise.
(make_path_absolute): New overload for const string&.
(build_corpus_group_from_kernel_dist_under): Adjust to using
vector<string> instead of vector<char**>.
* tests/print-diff-tree.cc (main): Likewise.
* tests/test-diff-dwarf.cc (main): Likewise.
* tests/test-ir-walker.cc (main): Likewise.
* tests/test-read-btf.cc (test_task_btf::perform(): Likewise.
* tests/test-read-ctf.cc (test_task_ctf::perform): Likewise.
* tests/test-symtab.cc (read_corpus): Likewise.
* tools/abicompat.cc (options::{app_di_root_path,
lib1_di_root_path, lib2_di_root_path}): Switch types of these data
member from shared_ptr<char> to string.
(parse_command_line): Adjust to using the string overload of
tools_utils::make_path_absolute.
(read_corpus): Take a vector<string> instead of vector<char**> for
debuginfo root dirs.
(main): Adjust to using string & vector<string> for debuginfo root
directories instead of char* and vector<char**>.
* tools/abidiff.cc (options::{di_root_paths[12]}): Change the
types of these data members from vector<char**> to vector<string>.
(options::prepared_di_root_paths[12]): Remove these data members.
(options::~options): Remove.
(parse_command_line): Adjust to using the string overload of
tools_utils::make_path_absolute.
(prepare_di_root_paths): Remove.
(handle_error): Adjust.
(main): Remove call to prepare_di_root_paths & adjust.
* tools/abidw.cc (options::di_root_paths): Adjust type to
vector<string> from vector<char**>
(options::prepared_di_root_paths1): Remove data member.
(options::~options): Remove.
(load_corpus_and_write_abixml): Adjust.
(prepare_di_root_paths): Remove.
* tools/abilint.cc (options::di_root_path): Change type from
shared_ptr<char> to string.
(parse_command_line): Adjust.
(main): Adjust.
* tools/abipkgdiff.cc (compare, compare_to_self): Adjust.
2025-06-06 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: Fix getting the latest RPM version of a given Fedora distro
* tools/fedabipkgdiff (get_distro_from_string): Make this properly
get the distro sub-string from the release string, even for
release strings like "1.eln123" and '1.2.fc40app2'. The distro
sub-strings returned for these two examples are 'eln123' and None.
None is returned in the later case because it doesn't follow the
"proper" Fedora scheme for distro sub-strings of the Release
string.
2025-06-06 Dodji Seketeli <dodji@redhat.com>
configure: Remove the unnecessary FOUND_DWARF_GETALT_IN_LIBDW variable
* configure.ac: Remove the FOUND_DWARF_GETALT_IN_LIBDW variable
and the LIBDW_HAS_DWARF_GETALT configuration C macro.
2025-06-06 Dodji Seketeli <dodji@redhat.com>
elf-reader: Fix elfutils initialization of debuginfo lookup paths
* src/abg-elf-reader.cc (find_alt_dwarf_debug_info_path)
(find_alt_dwarf_debug_info): Remove static functions.
(reader::priv::find_alt_dwarf_debug_info): Remove member function.
(reader::priv::{formated_di_root_paths,
raw_formated_di_root_paths}): Add new data members.
(reader::priv::initialize): Initialize the new data members.
(reader::priv::initialize_debug_info_root_paths): Define new
member function.
(reader::priv::crack_open_elf_file): Invoke the new
initialize_debug_info_root_paths above. Adjust the call to
elf_helpers::initialize_dwfl_callbacks to pass the new
raw_formated_di_root_paths.
(reader::priv::locate_dwarf_debug_info): Remove all the
unnecessary cruft. Just rely on elfutils finding the debug info,
now that it's been properly initialized. Use the dwarf_getalt
function that is now always present in the versions of elfutils
that we use.
2025-05-19 Dodji Seketeli <dodji@redhat.com>
Bug 32975 - Filter out replacing a data member with a compatible union
* include/abg-comp-filter.h
(is_type_to_compatible_anonymous_type_change)
(is_data_member_to_compatible_anonymous_dm_change): Declare ...
* src/abg-comp-filter.cc
(is_type_to_compatible_anonymous_type_change)
(is_data_member_to_compatible_anonymous_dm_change): ... new
functions.
(is_non_compatible_distinct_change): Use the new
is_type_to_compatible_anonymous_type_change.
(has_harmless_name_change): Use the new
is_type_to_compatible_anonymous_type_change and
is_data_member_to_compatible_anonymous_dm_change.
(has_anonymous_data_member_change): Tighten this up by making the
test more precise.
* tests/data/test-abidiff-exit/replace-dm-with-compatible-anon-dm-1-report-1.txt:
Add new reference test output.
* tests/data/test-abidiff-exit/replace-dm-with-compatible-anon-dm-1-v{0,1}.{c,o}:
Add new test binary output as well as its source code.
* tests/data/Makefile.am: Add the new test input material to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new test to
this harness.
2025-05-16 Mark Wielaard <mark@klomp.org>
tests/runtestfedabipkgdiffpy3.sh.in: Don't use which to find python3
* tests/runtestfedabipkgdiffpy3.sh.in: Replace which with
command -v.
2025-05-14 Dodji Seketeli <dodji@redhat.com>
libxml-utils,tools-utils: Add an I/O handler for XZ input in libxml2
* include/abg-libxml-utils.h (xml::initialize): Declare ...
* src/abg-libxml-utils.cc (xml::initialize): ... new function.
(xz_io_match_cb, xz_io_open_cb, xz_io_read_cb, xz_io_close_cb):
New static functions.
(struct xz_ctxt_type): New type.
* include/abg-tools-utils.h (tools_utils::guess_file_type): Add a
new look_through_compression parameter with a default argument.
* src/abg-tools-utils.cc (initialize): Call the new
xml::initialize instead of xmlInitParser.
(guess_file_type): Add a new look_through_compression parameter.
If that parameter is set to false, return FILE_TYPE_XZ compression
for an XZ-compressed file.
(xz_decompressor_type::priv::inbuf): Set the size of the input
buffer to 100K bytes instead of 10K. This reduces the number of
reads when looking at files that are bigger than 10k bytes.
(xz_decompressor_type::priv::outbuf): Likewise.
* tools/abicompat.cc (main): Call tools_utils::initialize here.
* tools/abidiff.cc (main): Likewise.
* tools/abidw.cc (main): Likewise.
* tools/abilint.cc (main): Likewise.
* tools/abipkgdiff.cc (main): Call tools_utils::initialize near
the beginning of the function.
2025-05-14 Dodji Seketeli <dodji@redhat.com>
tools-utils: Fix XZ decompression after all compression data is read
* src/abg-tools-utils.cc (xz_decompressor_type::underflow): Fix
comment. Decouple reading the compressed input and decompressing
it. Once all the compressed data is read, cycle over it to
decompress it in chunk.
2025-05-14 Dodji Seketeli <dodji@redhat.com>
tools-utils: Fix a comment
* include/abg-tools-utils.h (class xz_decompressor_type): Fix the
comment.
2025-05-09 Dodji Seketeli <dodji@redhat.com>
configure: Add --with-libxml2 option
* configure.ac: Add the --with-libxml2 option. Emit $XML_LIBS and
$XML_CFLAGS in the package configuration summary.
2025-04-30 Dodji Seketeli <dodji@redhat.com>
Bug 32902 - Recognize harmless type size increase
* include/abg-fwd.h (is_compatible_with_enum_type)
(is_compatible_with_class_type): Declare ...
* src/abg-ir.cc (is_compatible_with_enum_type)
(is_compatible_with_class_type): new functions.
(collect_non_anonymous_data_members): Fix comment.
* src/abg-comp-filter.cc (type_size_changed_with_impact)
(has_type_size_change_with_impact): Define static functions.
(there_is_a_decl_only_class): Add an overload for class_decl* and
make the overload for class_decl_sptr use it.
(there_is_a_decl_only_enum, type_size_changed)
(type_has_offset_changes): Likewise.
(non_static_data_member_type_size_changed_with_impact): Renamed
non_static_data_member_type_size_changed into this. Use the new
type_size_changed_with_impact instead of the old
type_size_changed.
(non_static_data_member_added_or_removed_with_impact):
non_static_data_member_added_or_removed renamed into this. If the
containing type is anonymous then adding a new non-static data
member to it might not have an impact outside on the declaration
that currently has that anonymous type as a type.
(has_harmful_change): Replace the use of type_size_changed with
has_type_size_change_with_impact. Adjust for the renaming of
non_static_data_member_added_or_removed, into
non_static_data_member_added_or_removed_with_impact as well as
non_static_data_member_added_or_removed into
non_static_data_member_type_size_changed_with_impact.
* tests/data/test-abicompat/test7-fn-changed-report-0.1.txt:
Adjust.
* tests/data/test-abicompat/test7-fn-changed-report-0.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-redundant-report.txt:
Likewise.
* tests/data/test-diff-dwarf/test22-changed-parm-c-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test-PR26309-report-0.txt: Likewise.
* tests/data/test-diff-filter/test-PR29387-report.txt: Likewise.
* tests/data/test-diff-filter/test29-finer-redundancy-marking-report-0.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-report-1.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-1.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-2.txt: Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1-report0.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-1.1.txt:
Likewise.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-1.txt:
Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/data/test-abidiff-exit/test-PR32902/test-PR32902-{1,2}-report-1.txt:
New reference output files.
* tests/data/test-abidiff-exit/test-PR32902/test-PR32902-{1,2}.v{0,1}.{c,o}:
New binaries and their source code.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new input
test binaries to this test harness.
2025-04-30 Dodji Seketeli <dodji@redhat.com>
{default,leaf}-reporter: Add incompatible changes to leaf reporter
* include/abg-comparison.h
(corpus_diff::diff_stats::{num_leaf_func_with_incompatible_changes,
net_num_leaf_func_non_incompatible_changes,
num_leaf_var_with_incompatible_changes,
net_num_leaf_var_non_incompatible_changes}): Declare new member
functions.
* src/abg-comparison-priv.h
(corpus_diff::diff_stats::priv::{num_leaf_func_with_incompatible_changes,
num_leaf_var_with_incompatible_changes}): Define new data members.
(corpus_diff::diff_stats::priv::priv): Initialize the new data
members.
* src/abg-comparison.cc
(corpus_diff::diff_stats::{num_leaf_func_with_incompatible_changes,
net_num_leaf_func_non_incompatible_changes,
num_leaf_var_with_incompatible_changes,
net_num_leaf_var_non_incompatible_changes}): Define new member
functions.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Set the
diff_stats::{num_leaf_func_with_incompatible_changes,
num_leaf_var_with_incompatible_changes} properties.
* src/abg-default-reporter.cc (emit_changed_fn_report)
(emit_changed_var_report): Moved these static functions ...
* src/abg-reporter-priv.cc (emit_changed_fn_report)
(emit_changed_var_report): ... here.
* src/abg-reporter-priv.h (emit_changed_fn_report)
(emit_changed_var_report): Declare them here.
* src/abg-leaf-reporter.cc (emit_changed_var_report): Remove this
static function.
(leaf_reporter::report): In the overload for corpus_diff, emit a
report for leaf functions with incompatible changes using the new
emit_changed_fn_report declared in src/abg-reporter-priv.h.
Likewise, use the emit_changed_var_report declared in
src/abg-reporter-priv.h to emit a report for leaf variables with
incompatible changes. Use
diff_stats::net_num_leaf_func_non_incompatible_changes to emit
changes to leaf functions that are not necessarily incompatible,
with the emit_changed_fn_report declared in
src/abg-reporter-priv.h. Similarly, use
diff_stats::net_num_leaf_var_non_incompatible_changes to emit
changes to leaf variables that are not necessarily incompatible.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-2.txt:
Adjust.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-more-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-redundant-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-stats-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-net-change-report2.txt:
Likewise.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test-PR26309-report-0.txt: Likewise.
2025-04-30 Dodji Seketeli <dodji@redhat.com>
comparison: Emit local diff node category in tree dump
* src/abg-comparison.cc (diff_node_printer::visit): Emit a dump of
the local category of the current diff node.
2025-04-22 Frank Ch. Eigler <fche@redhat.com>
tests/runtestabidb2.sh.in: Take more care while doing cleanup
* tests/runtestabidb2.sh.in (clean_env): Clean more carefully.
2024-07-18 Frank Ch. Eigler <fche@redhat.com>
PR31533: abidb: drop debuginfod-client verbosity env variables
* tools/abidb: del os.environment(stuff)
2025-04-11 Dodji Seketeli <dodji@redhat.com>
configure: Bump libabigail version to 2.8
* configure.ac: Now that 2.7 is out of the door, bump version
number to 2.8.
2025-04-11 Dodji Seketeli <dodji@redhat.com>
doc/website/mainpage.txt: Update to 2.7
* doc/website/mainpage.txt: Update to 2.7
2025-04-10 Dodji Seketeli <dodji@redhat.com>
NEWS: Update for 2.7 release
* NEWS: Update for 2.7 release.
2025-04-10 Dodji Seketeli <dodji@redhat.com>
ChangeLog: Update for 2.7 release
* ChangeLog: Update automatically by running "make
update-changelog".
2025-04-10 Dodji Seketeli <dodji@redhat.com>
configure: Bump libabigail_so_current to 6
* configure.ac: Bump libabigail_so_current version number to 6.
2025-04-09 Dodji Seketeli <dodji@redhat.com>
Bug 32794 - ir: avoid asserting in get_type_name
* src/abg-ir.cc (get_type_name): Be prepared for a type with nullptr
value and for types with no declaration.
2025-04-09 Dodji Seketeli <dodji@redhat.com>
manuals: Fix broken links
* doc/manuals/abi-artifacts.rst: Add forgotten link definition
for `ELF`_.
* doc/manuals/libabigail-concepts.rst: Remove unused link
definitions for `ELF_`, `Ini File Syntax`_ and `GNU C Library`_.
* doc/manuals/suppression-specifications.rst: Add forgotten link
definition for `Ini File Syntax`_, `GNU C Library`_.
2025-04-09 Dodji Seketeli <dodji@redhat.com>
abg-comp-filter: Fix some documentation thinko
* src/abg-comp-filter.cc (class_diff_has_only_harmless_changes)
(has_var_harmful_local_change, has_incompatible_fn_or_var_change):
Fix thinkos.
2025-04-09 Dodji Seketeli <dodji@redhat.com>
abg-comp-filter: Fix declaration of has_harmful_name_change
* include/abg-comp-filter.h (has_harmful_name_change): Add the
missing diff_context_sptr& parameter.
2025-03-31 Dodji Seketeli <dodji@redhat.com>
libabigail-concepts: Document the incompatible changes concept
* doc/manuals/abi-artifacts.rst: New file. Move the ABI artifacts
section in here.
* doc/manuals/abi-changes.rst: New file. Introduce the concept of
ABI change. Polish and move the section about harmless and
harmful changes here. Introduce a section about incompatible
changes.
* doc/manuals/suppression-specifications.rst: New file. Move the
content about suppression specifications in here.
* doc/manuals/Makefile.am: Add the new files above to source
distribution.
* doc/manuals/libabigail-concepts.rst: This file now only contains
a table of content linking to the three new files introduced
above.
* doc/manuals/abidiff.rst: Amend the documentation to include
examples showing incompatible changes being reported by abidiff.
* doc/manuals/index.rst: Change the depth of the table of content
to 3.
Thanks-to: Sam James <sam@gentoo.org>
2025-04-07 Dodji Seketeli <dodji@redhat.com>
abidiff.rst: Sort option documentation bullets in lexicographic order
* doc/manuals/abidiff.rst: Sort option documentation bullets in
lexicographic order.
2025-04-07 Dodji Seketeli <dodji@redhat.com>
manuals/conf.py: Update copyright years in the manuals
* doc/manuals/conf.py: Update copyright years.
2025-04-04 Dodji Seketeli <dodji@redhat.com>
rhbz2355363 - abipkgdiff: Don't abort when alternate debug info is not found
* tools/abipkgdiff.cc (emit_alt_debug_info_not_found_error): Avoid
asserting here.
2025-04-03 Dodji Seketeli <dodji@redhat.com>
default.abignore: Improve default suppression for krb5 libraries
* default.abignore: Recognize more SONAMEs for the different krb5
shared libraries, namely libk5crypto.so, libgssrpc.so, libkdb5.so,
libkrb5support.so and libgssapi_krb5.so. Suppress all function
changes to libraries with these sonames. Suppress functions (and
their symbols) starting with names k5_, in addition to krb5int_.
2025-04-01 Dodji Seketeli <dodji@redhat.com>
big-test: Update to e772c1e67aba14141dd16735ecdf19368b0cb29e
* include/abg-comparison.h (diff::is_categorized_as_suppressed):
Declare ...
* src/abg-comparison.cc (diff::is_categorized_as_suppressed):
... new member function.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Use the
new diff::is_categorized_as_suppressed. Look for incompatible fns
and vars changes among filtered-out (and non-suppressed) diff
nodes.
* tests/data/test-abidiff-exit/test1-voffset-change-report0.txt:
Adjust.
2025-03-31 Dodji Seketeli <dodji@redhat.com>
Bug 28505 - Fix a case of pointer to void* change filtering
* include/abg-comparison.h (print_category): Declare ...
* src/abg-comparison.cc (print_category): ... new debugging
function.
(category_propagation_visitor::visit_end): Clear
NON_COMPATIBLE_DISTINCT_CHANGE_CATEGORY
NON_COMPATIBLE_NAME_CHANGE_CATEGORY from the local category of
pointer/reference diff nodes when propagating those categorizing
bits from the underlying diff nodes of pointer/reference diff
nodes.
* tests/data/test-abidiff-exit/PR28505-test-report.txt: New test
reference output file.
* tests/data/test-abidiff-exit/PR28505-test-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/PR28505-test-v{0,1}.{c,o}: Source
code and binary test input files.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new input
tests to this test harness.
2025-03-27 Dodji Seketeli <dodji@redhat.com>
Bug 31642 - Don't forget filtered-out incompatible fns and var changes
* include/abg-comparison.h (diff::is_categorized_as_suppressed):
Declare ...
* src/abg-comparison.cc (diff::is_categorized_as_suppressed):
... new member function.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Use the
new diff::is_categorized_as_suppressed. Look for incompatible fns
and vars changes among filtered-out (and non-suppressed) diff
nodes.
* tests/data/test-abidiff-exit/test1-voffset-change-report0.txt:
Adjust.
2025-03-24 Dodji Seketeli <dodji@redhat.com>
Bug 31642 - Categorize incompatible changes on functions and variables
* include/abg-comp-filter.h (has_void_to_non_void_change)
(has_fn_return_or_parm_harmful_change)
(has_var_harmful_local_change, has_fn_with_virtual_offset_change)
(has_incompatible_fn_or_var_change): Declared new functions.
* include/abg-comparison.h (is_harmful_category): Declare new
function.
(corpus_diff::{changed_functions, changed_function_sorted}):
Consitify declarations.
(corpus_diff::{incompatible_changed_functions,
incompatible_changed_variables}): Declare new member functions.
(corpus_diff::diff_stats::{num_func_with_local_harmful_changes,
num_func_with_incompatible_changes, void
num_var_with_local_harmful_changes, void
num_var_with_incompatible_changes,
net_num_non_incompatible_var_changed}): Declare new accessors.
* include/abg-ir.h (change_kind::LOCAL_TYPE_CHANGE_KIND): Fix the
value of this enumerator.
(change_kind::{LOCAL_NON_TYPE_CHANGE,SUBTYPE_CHANGE_KIND}_KIND):
Adjust values of these enumerator as a consequence.
* src/abg-comp-filter.cc
(has_harmful_change, has_harmful_enum_change)
(has_harmless_enum_change, is_void_to_non_void): Define new static
functions.
(is_1_dim_unknown_size_array_change): Factorize this function out
of ...
(is_var_1_dim_unknown_size_array_change): ... this.
(has_fn_parm_type_cv_qual_change): Adjust to the use of
type_diff_has_typedef_cv_qual_change_only.
(has_added_or_removed_function_parameters): Fix indentation.
(has_fn_return_or_parm_harmful_change)
(has_fn_with_virtual_offset_change, has_var_harmful_local_change)
(has_var_harmful_local_change, has_incompatible_fn_or_var_change)
(has_void_to_non_void_change): Define new functions.
(categorize_harmful_diff_node): Improve documentation. Use the
new has_harmful_change which is a factorization of this function.
* src/abg-comparison-priv.h (is_less_than): Declare new function
that takes a pair of decl_diff_base. Remove the previous one that was
taking a pair of function_decl_diff.
(corpus_diff::priv::{incompatible_changed_fns_,
incompatible_changed_vars_}): Define new member variables.
(var_diff_sptr_comp::operator()): Adjust, make this use
is_less_than.
(corpus_diff::diff_stats::priv::{num_func_with_local_harmful_changes,
num_func_with_incompatible_changes,
num_var_with_local_harmful_changes,
num_var_with_incompatible_changes}): Define new member variables.
(corpus_diff::diff_stats::priv::priv): Initialize these new
member variables.
(sort_function_decl_diffs, sort_var_diffs): Declare new functions.
* src/abg-comparison.cc (get_symbol): Define new static function.
(is_less_than): Take decl_diff_base instead of function_decl_diff.
Adjust to use the new get_symbol function. Update comments. Add
a new overload.
(sort_function_decl_diffs, sort_var_diffs, is_harmful_category):
Define new functions.
(corpus_diff::diff_stats::{num_func_with_local_harmful_changes,
num_var_with_local_harmful_changes,
num_func_with_incompatible_changes,
num_var_with_incompatible_changes,
net_num_non_incompatible_func_changed,
net_num_non_incompatible_var_changed}): Define new member
functions.
(corpus_diff::{changed_functions, changed_functions_sorted}):
Constify this member function.
(corpus_diff::{incompatible_changed_functions,
incompatible_changed_variables}): Likewise.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Count
function diff node carrying virtual member changes and return or
parameter types harmful changes as functions with incompatible
changes. Likewise, count variable diff node carrying local
harmful changes as variables with incompatible changes.
(corpus_diff::has_incompatible_changes): Take into account
functions with virtual offset changes or with local harmful
changes, as well as variables with incompatible changes.
(redundancy_marking_visitor::visit_end): If the diff node has
local /harmful/ changes then it won't inherit redundancy from its
children nodes.
* src/abg-default-reporter.cc (emit_changed_fn_report)
(emit_changed_var_report): Define new static functions.
(default_reporter::report): In the overload for enum_diff, support
emitting a report about changed enumerator name. In the overload
for corpus_diff, emit a new section for incompatible changes to
functions and variables. Use the new emit_changed_fn_report and
emit_changed_var_report which have been factorized out of this
function anyway.
* src/abg-ir.cc (textually_equals): Add a change_kind* parameter
to tell the kind of change there are between two ELF symbols if
they are different.
(var_equals_modulo_types): Adjust to use textually_equals for a
more fined grained change_kind when it comes to ELF symbol
changes.
(decl_name_changed, integral_type_has_harmless_name_change):
Define new functions.
* src/abg-leaf-reporter.cc (emit_changed_var_report): Define new
static function.
(leaf_reporter::report): In the overload for corpus_diff, use the
new emit_changed_var_report as it's was factorized from there.
* src/abg-reporter-priv.cc (represent): In the overload for
var_diff, adjust the call to filtering::has_harmless_name_change.
(report_name_size_and_alignment_changes): Likewise.
* tests/data/test-abidiff-exit/incompatible-changes/1/report0.txt:
New test input.
* tests/data/test-abidiff-exit/incompatible-changes/1/test-1-v{0,1}.{cc,o}:
Likewise.
* tests/data/test-abidiff-exit/test-changed-var-1-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-changed-var-1-v{0,1}.cc:
Likewise.
* tests/data/test-abidiff-exit/test-changed-var-1-v{0,1}.o:
Likewise.
* tests/data/test-abidiff-exit/test-enumerator-changes{2,3,4,5,6}-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-enumerator-changes{2,3,4,5,6}-v{0,1}.cc:
Likewise.
* tests/data/test-abidiff-exit/test-enumerator-changes{2,3,4,5,6}-v{0,1}.o:
Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/data/test-abicompat/test7-fn-changed-report-0.1.txt:
Adjust.
* tests/data/test-abicompat/test7-fn-changed-report-0.txt:
Likewise.
* tests/data/test-abidiff-exit/PR30048-test-2-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/PR30048-test-report-0.txt:
Likewise.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/btf/test0-report-1.txt: Likewise.
* tests/data/test-abidiff-exit/btf/test0-report-2.txt: Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr1-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr2-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr3-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr4-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-crc-report.txt: Likewise.
* tests/data/test-abidiff-exit/test-ld-2.28-210.so--ld-2.28-211.so.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-more-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-stats-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-net-change-report0.txt:
Likewise.
* tests/data/test-abidiff-exit/test-net-change-report2.txt:
Likewise.
* tests/data/test-abidiff-exit/test1-voffset-change-report0.txt:
Likewise.
* tests/data/test-abidiff/test-crc-report-0-1.txt: Likewise.
* tests/data/test-abidiff/test-crc-report-1-0.txt: Likewise.
* tests/data/test-abidiff/test-crc-report-1-2.txt: Likewise.
* tests/data/test-abidiff/test-namespace-report.txt: Likewise.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test25-removed-fn-parms-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt:
Likewise.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Likewise.
* tests/data/test-diff-dwarf/test46-rust-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test9-report.txt: Likewise.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test-PR27569-report-0.txt: Likewise.
* tests/data/test-diff-filter/test-PR28013-fn-variadic.c.report.txt:
Likewise.
* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test5-2-report.txt: Likewise.
* tests/data/test-diff-filter/test6-report.txt: Likewise.
* tests/data/test-diff-filter/test7-report.txt: Likewise.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
Likewise.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/PR31646/test-PR31646-result-1.txt:
Likewise.
* tests/data/test-diff-suppr/PR31646/test-PR31646-result-3.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-between-1-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-between-1-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-between-1-report-4.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test10-changed-parm-c-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test30-report-0.txt: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-v{0,1}.o:
Recompile these using gcc -g -c.
2025-03-19 Dodji Seketeli <dodji@redhat.com>
Bug 21296 - Normalize declaration names read from DWARF
* include/abg-tools-utils.h (remove_white_spaces)
(normalize_litterals): Declare new functions.
* src/abg-tools-utils.cc (remove_white_spaces)
(normalize_litterals): Define new functions.
(get_litteral_regex): Define new static function.
* src/abg-dwarf-reader.cc (cleanup_decl_name): Define new static
function.
(add_or_update_class_type, add_or_update_union_type)
(build_function_decl): Use the new cleanup_decl_name.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-1.txt:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Adjust.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Adjust.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Adjust.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Adjust.
* tests/data/test-diff-filter/test41-report-0.txt: Adjust.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2025-03-24 Dodji Seketeli <dodji@redhat.com>
ir: Recognize classes of same layout as being compatible
* include/abg-fwd.h (classes_have_same_layout): Declare ...
* src/abg-ir.cc (classes_have_same_layout): ... new function.
(types_are_compatible): Use the new classes_have_same_layout.
* tests/data/test-diff-filter/test5-report.txt: Adjust.
* tests/data/test-diff-filter/test5-{2,3}-report.txt: Add new
reference test output.
* tests/data/test-diff-filter/test5-{2,3}-v{0,1}.{cc,o}: Add new
source code and binary test input.
* tests/test-diff-filter.cc (in_out_specs): Add the binary test
inputs to the test harness.
2025-03-24 Dodji Seketeli <dodji@redhat.com>
comp-filter,ir: Simplify logic of has_harmless_name_change
* include/abg-fwd.h (decl_name_changed)
(integral_type_has_harmless_name_change): Declare new functions.
* include/abg-ir.h (equals_modulo_cv_qualifier): Declare new
overloads for array_type_def_pstr and pointer_type_def_sptr.
* src/abg-comp-filter.cc
(type_diff_has_typedef_cv_qual_change_only): Rename
type_diff_has_cv_qual_change_only into this for better legibility.
Use equals_modulo_cv_qualifier rather than poorly open-coding its
functionality.
(has_fn_parm_type_cv_qual_change)
(has_fn_return_type_cv_qual_change, has_var_type_cv_qual_change):
Adjust the call to the new
type_diff_has_typedef_cv_qual_change_only.
(is_compatible_type_change): Declare new static function.
(is_non_compatible_distinct_change): Remove
type_diff_has_cv_qual_change_only and use the more generic
is_compatible_type_change.
(has_harmless_name_change): Remove the redundant and too much low
level messing up with typedefs, CV qualifiers and harmless
integral name changes. types_are_compatible should now take care
of that minutiae.
(decl_name_changed, integral_type_has_harmless_name_change): Move
these static function ...
* src/abg-ir.cc (decl_name_changed)
(integral_type_has_harmless_name_change): ... here and make them
non-static.
(types_are_compatible): Simplify logic. Look through qualified,
typedef, pointers, reference and array types.
(equals_modulo_cv_qualifier): Define new overloads for
array_type_def_sptr and pointer_type_def_sptr.
2025-03-24 Dodji Seketeli <dodji@redhat.com>
ir: Better handle int[5][2] changed into int[2][5]
* src/abg-ir.cc (types_have_similar_structure): Arrays of
dimensions of different sizes should not be considered as having a
similar structure.
* tests/data/test-diff-filter/test-multi-array1-v{0,1}.cc: Add new
source files for binary test input.
* tests/data/test-diff-filter/test-multi-array1-v{0,1}.o: Add new
binaries.
* tests/data/test-diff-filter/test-multi-array1.txt: Add new
reference output.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test input
above to the test harness.
2025-03-20 Dodji Seketeli <dodji@redhat.com>
comp-filter: Better detection of harmless/harmful enum changes
* include/abg-comp-filter.h (has_harmless_name_change): Take an
additional diff_context_sptr parameter.
* include/abg-ir.h (enum_type_decl::find_enumerator_by_{value,
name}): Declare new member functions.
* src/abg-comp-filter.cc (has_harmful_enum_change)
(has_harmless_enum_change)
(has_enumerator_change): Define new static functions.
(has_harmless_name_change): Take an
additional diff_context_sptr parameter. Use the new
has_harmless_enum_change instead of getting deep into minutiae
concerning enums. The diff_context_sptr argument is passed to
has_harmless_enum_change. Adjust the other overload.
(has_harmful_name_change): Take an additional diff_context_sptr
parameter and pass it to has_harmless_name_change. Adjust
comment. Adjust the overload for diff node.
(has_enumerator_removal_or_value_change): Rename
has_enumerator_removal_or_change into this. Walk the changed
enumerators to see if any of their value changed.
(has_harmful_enum_change): Adjust to use
has_enumerator_removal_or_value_change.
(categorize_harmless_diff_node): Adjust the use of
has_harmless_name_change. Also, use the new
has_harmless_enum_change instead of diving into minutiae to handle
enum changes.
* src/abg-comparison.cc
(enum_diff::ensure_lookup_tables_populated): Use the new
enum_type_decl::find_enumerator_by_{value,name} to populate
enum_diff::priv::changed_enumerators_ and remove the changed
enumerators from enum_diff::priv::{deleted,
inserted}_enumerators_.
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for enum_diff, report change of enumerator value or
change of enumerator name.
(default_reporter::report_non_type_typedef_changes): Adjust the
use of filtering::has_harmless_name_change.
* src/abg-ir.cc (enum_type_decl::find_enumerator_by_{value,
name}): Define new member functions.
* src/abg-reporter-priv.cc (represent): In the overload for
var_diff_sptr, adjust the use of
filtering::has_harmless_name_change.
(report_name_size_and_alignment_changes): Likewise.
* tests/data/test-abidiff/test-enum0-report.txt: Adjust.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Adjust.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Adjust.
2025-03-25 Dodji Seketeli <dodji@redhat.com>
reporter-priv: Fix a thinko in sub-range change report
* src/abg-reporter-priv.cc (represent): In the overload for
subranges, fix a thinko. We need to refer to the old subrange in
the change report.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-1.txt:
Adjust.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-array-v0--v1-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-array-v0--v3-report-1.txt:
Likewise.
* tests/data/test-abidiff/test-PR27985-report.txt: Likewise.
* tests/data/test-diff-dwarf/test10-report.txt: Likewise.
* tests/data/test-diff-dwarf/test11-report.txt: Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1-report-1.txt:
Likewise.
2025-03-13 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Avoid wrongly considering binaries being added/removed
* tools/abipkgdiff.cc (create_maps_of_package_set_content): Use
the SONAME when present as the key of the binary.
* tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64--dbus-glib-0.104-3.fc23.armv7hl-report-0.txt: Adjust.
2025-02-18 Dodji Seketeli <dodji@redhat.com>
big-tests: Sync with libabigail hashe 229682
* tools/abipkgdiff.cc
(compare_prepared_linux_kernel_package_sets): Use the base name of
input RPMs in the output message.
2025-02-17 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Don't use full Linux kernel pkg path in change reports
* tools/abipkgdiff.cc
(compare_prepared_linux_kernel_package_sets): Use the base name of
input RPMs in the output message.
2025-02-13 Dodji Seketeli <dodji@redhat.com>
configure.ac: Add a new --enable-inlined-xxhash option
* configure.ac: Recognize the --enable-inlined-xxhash option,
define the ENABLE_INLINED_XXHASH variable accordingly and use it to
determine when to set the -DXXH_INLINE_ALL=1 macro or when to link
against the xxhash shared library. Also, update the package
configuration report to reflect the status of the
--enable-inlined-xxhash option.
2025-02-12 Sam James <sam@gentoo.org>
configure.ac: fix typos for XXHASH_LIBS, LZMA_LIBS
* configure.ac: Fix typos for $XXHASH_LIBS and $LZMA_LIBS.
2025-02-12 Dodji Seketeli <dodji@redhat.com>
{ctf,dwarf}-reader.cc: Fix a virtual method name conflict in elf_base_reader
* src/abg-ctf-reader.cc (ctf::reader::initialize): Adjust.
(ctf::reader::reset): Rename ctf::reader::initialize into this.
* src/abg-dwarf-reader.cc (reader::initialize): Adjust.
(dwarf::reader::reset): Rename dwarf::reader::initialize into
this.
2025-02-06 Dodji Seketeli <dodji@redhat.com>
big-tests: Update to latest commit 2afebc4
* big-tests: Update to latest commit 2afebc4
2025-01-30 Dodji Seketeli <dodji@redhat.com>
Bug PR32476 - abipkgdiff: Support comparing sets of packages
* doc/manuals/abipkgdiff.rst: Add documentation for the new
--set{1,2} options. Update the documentation to describe
abipkgdiff as a tool to compare sets of packages.
* tools/abipkgdiff.cc (options::{package_set_paths1,
package_set_paths2, pkg_set1, pkg_set2}): New data members.
(options::{package1, package2, pkg1, pkg2}): Remove these data
members.
(get_interesting_files_under): Rename
get_interesting_files_under_dir into this. Add a new overload
that takes a package_set instead of a directory path.
(package::package): Make this destructor virtual, so that we can
RTTI to the package class.
(package::load_elf_file_paths): Adjust to calling
get_interesting_files_under.
(class package_set): Define new class.
(package_set_sptr): Define new typedef.
(class pkg_set_prepare_task): Rename pkg_prepare_task into this.
(pkg_set_prepare_task_sptr): Renamed pkg_prepare_task_sptr into
this.
(create_maps_of_package_set_content): Renamed
create_maps_of_package_content into this and adjust to make it
take a package_set_sptr.
(extract_package_set_and_map_its_content): Renamed
extract_package_and_map_its_content into this and adjust to make
it take a package_set_sptr.
(prepare_package_sets): Renamed prepare_packages into this and
adjust to make it take a package_set_sptr.
(compare_prepared_userspace_package_sets): Renamed
compare_prepared_userspace_packages into this and adjust to make
it take a package_set_sptr.
(self_compare_prepared_userspace_package_set)
(self_compare_prepared_package_set): Renamed
self_compare_prepared_userspace_package and
self_compare_prepared_package into these* and adjust to make it
take a package_set_sptr.
(compare_prepared_linux_kernel_package_sets): Renamed
compare_prepared_linux_kernel_packages into this and adjust to
make it take a package_set_sptr.
(compare_prepared_package_set): Renamed compare_prepared_package
into this and adjust to make it take a package_set_sptr.
(pkg_set_prepare_task::perform): Adjust.
(is_kernel_package, get_core_kernel_package, is_package_set):
Define new static functions.
(extract_package, maybe_erase_temp_dirs): Take a package_sptr
rather than a reference to a package.
(extract_package_set_and_map_its_content)
(erase_created_temporary_directories)
(create_private_types_suppressions)
(maybe_create_public_dso_sonames_set)
(must_compare_public_dso_only, maybe_handle_kabi_stablelist_pkg)
(compare, compare_to_self): Make these functions take a
package_set_sptr rather than a reference to a package.
(compare_to_self): Adjust.
(parse_command_line): Make this take --set{1,2} options and adjust
accordingly. Fix detection of non-existent file input by using
options::wrong_arg instead options::wrong_option.
(main): Adjust to using options::wrong_args to detect non-existing
or wrong input files. Adjust to consider only package sets to be
compared now.
2025-02-07 Dodji Seketeli <dodji@redhat.com>
configure: Disable abidb on python version < 3.9
* configure.ac: Disable abidb on systems that have python version
less than 3.9.
2025-01-16 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Rename whitelist into stablelist
* tools/abipkgdiff.cc (options::kabi_stablelist_{packages,paths}):
Renamed kabi_whitelist_* into these.
(package::KIND_KABI_STABLELIST): Renamed the KIND_KABI_WHITELIST
enumerator into this.
(package::kabi_stablelist_package_): Renamed
kabi_whitelist_package_ into this.
(package::kabi_stablelist_package): Likewise for the getter/setter
pair.
(package::erase_extraction_directories): Renamed whitelist into
stablelist here.
(maybe_check_suppression_files, maybe_collect_kabi_stablelists)
(get_kabi_stablelists_from_arch_under_dir)
(maybe_handle_kabi_stablelist_pkg)
(extract_package_and_map_its_content)
(compare_prepared_linux_kernel_packages): Likewise.
(parse_command_line): Adjust.
2025-01-29 Dodji Seketeli <dodji@redhat.com>
Add support for reading XZ-compressed files
* configure.ac: Detect the liblzma library.
* include/abg-tools-utils.h (enum file_type): Add a new
FILE_TYPE_XZ enumerator.
(class xz_decompressor_type): Declare a new custom std::streambuf
class.
* src/abg-elf-helpers.h: Include elfutils/libdwelf.h.
* src/abg-elf-reader.cc (get_type_of_elf_file): Use
dwelf_elf_begin instead of elf_begin to transparently handle
compressed input file.
* src/abg-tools-util*s.cc (struct xz_decompressor_type::priv):
Define private type.
(xz_decompressor_type::{xz_decompressor_type,
~xz_decompressor_type, underflow}): Define new methods for
xz_decompressor_type.
(operator<<(ostream&, file_type)): Add
support for the new FILE_TYPE_XZ enumerator.
(enum compression_kind): Define new enum.
(is_compressed_file_type, get_decompressed_streambuf): Define new
static functions.
(guess_file_type): In the overload for std::istream, detect the XZ file
type. In the overload for std::string, use the new
is_compressed_file_type and get_decompressed_streambuf to
decompress a compressed file on the fly and handing the resulting
decompressed istream to the overload for std::istream.
* tests/data/test-read-dwarf/test0.xz: New input binary test.
* tests/data/test-read-dwarf/test0.xzbinary: Likewise.
* tests/data/test-read-write/test28.xml.xz: Likewise.
* tests/data/test-read-write/test28.xml.xzed: Likewise.
* tests/data/Makefile.am: Add the new test input to source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the new test input
to this test harness.
* tests/test-read-write.cc (in_out_specs): Likewise.
* tools/abicompat.cc (read_corpus): Add support for the new
abigail::tools_utils::FILE_TYPE_XZ.
* tools/abidiff.cc (main): Likewise.
* tools/abilint.cc (main): Likewise.
2025-01-29 Dodji Seketeli <dodji@redhat.com>
configure: Add $ELF_CFLAGS and $DW_CFLAGS to DEPS_CPPFLAGS
* configure.ac: Add $ELF_CFLAGS and $DW_CFLAGS to DEPS_CPPFLAGS.
2025-01-28 Dodji Seketeli <dodji@redhat.com>
configure: Fix xxhash detection code
* configure.ac: Substitute XXHASH_CFLAGS and XXHASH_LIBS in the
Makefiles. Add XXHASH_CFLAGS to DEPS_CPPFLAGS and XXHASH_LIBS to
DEPS_LIBS.
2025-01-16 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Recognize stablelist files in their package
* tools/abipkgdiff.cc (maybe_collect_kabi_whitelists): Recognize
files with prefix "kabi_stablelist_" as being a stablelist file,
in addition to the old kabi_whitelist_ prefix.
2025-01-31 Dodji Seketeli <dodji@redhat.com>
abipkgdiff.rst: Sort options documentation items alphabetically
* abipkgdiff.rst: Sort the options alphabetically.
2025-01-16 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Add new --verbose-diff option
* doc/manuals/abipkgdiff.rst: Document the new --verbose-diff
option.
* tools/abipkgdiff.cc (options::verbose_diff): New data member.
(options::options): Initialize the new data member.
(set_diff_context_from_opts): Activate logging of the diffing
process when the user issues the --verbose-diff option.
(parse_command_line): Parse --verbose-diff. Activate --verbose
when --verbose-diff is given.
2025-01-15 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Add more verbose logging
* src/abg-tools-utils.cc (load_vmlinux_corpus): Log stable list
loading.
* tools/abipkgdiff.cc (compare_prepared_linux_kernel_packages):
Log building of corpora for Linux kernels and diffing them.
2025-01-30 Dodji Seketeli <dodji@redhat.com>
tools-utils: Add missing comment
* src/abg-tools-utils.cc (guess_file_type): Add comment for RPM
format magic number.
2025-01-30 Dodji Seketeli <dodji@redhat.com>
tools-utils: Fix indentation
* src/abg-tools-utils.cc (rpm_contains_file): Fix indentation.
2025-01-15 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Fix indentation
* tools/abipkgdiff.cc (compare_prepared_linux_kernel_packages):
Fix indentation.
2025-01-15 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Fix spacing in usage text output
* tools/abipkgdiff.cc (display_usage): Fix spacing.
2025-01-13 Dodji Seketeli <dodji@redhat.com>
configure.ac: Add a missing preamble
* configure.ac: Add missing preamble.
2025-01-13 Dodji Seketeli <dodji@redhat.com>
Update copyright years for 2025
* include/abg-btf-reader.h: Update copyright year to include 2025.
* include/abg-comp-filter.h: Likewise.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-ctf-reader.h: Likewise.
* include/abg-cxx-compat.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-elf-based-reader.h: Likewise.
* include/abg-elf-reader.h: Likewise.
* include/abg-fe-iface.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-btf-reader.cc: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-ctf-reader.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-elf-based-reader.cc: Likewise.
* src/abg-elf-helpers.cc: Likewise.
* src/abg-elf-helpers.h: Likewise.
* src/abg-elf-reader.cc: Likewise.
* src/abg-fe-iface.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-regex.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-symtab-reader.cc: Likewise.
* src/abg-symtab-reader.h: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-cxx-compat.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-dot.cc: Likewise.
* tests/test-elf-helpers.cc: Likewise.
* tests/test-ini.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-kmi-whitelist.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-btf.cc: Likewise.
* tests/test-read-ctf.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-svg.cc: Likewise.
* tests/test-symtab-reader.cc: Likewise.
* tests/test-symtab.cc: Likewise.
* tests/test-tools-utils.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/kmidiff.cc: Likewise.
* update-copyright.sh: Likewise.
2025-01-09 Dodji Seketeli <dodji@redhat.com>
Bug 32402 - dwarf-reader,ir: Recognize new DWARF 5 languages
* configure.ac: Detect the presence of DW_LANG_* language
enumerators that were not supported before and for new ones that
got introduced in DWARF 5.
* include/abg-ir.h (translation_unit::LANG_{C17, C23,
C_plus_plus_17, C_plus_plus_20, C_plus_plus_23, OCaml, D, Go,
Rust, Zig, Metal, Fortran18, Fortran23, Ada2005, Ada2012, Kotlin,
C_sharp, Ruby, Assembly, Crystal, HIP, Mojo, GLSL, GLSL_ES, HLSL,
OpenCL_CPP, CPP_for_OpenCL, SYCL, Odin, P4, Move, Hylo}): Add new
languages enumerators.
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language)
(get_default_array_lower_bound): Recognize & support the new
languages enumerators above.
* src/abg-ir.cc (translation_unit_language_to_string): Likewise.
(is_c_language): Recognize translation_unit::LANG_C{17,23}.
(is_cplus_plus_language): Recognize
translation_unit::LANG_C_plus_plus_{20,23}.
(is_ada_language): Recognize
translation_unit::LANG_Ada{95,2005,2012}.
2025-01-09 Dodji Seketeli <dodji@redhat.com>
configure: Support using custom builds of elfutils
* configure.ac: Add support for --with-libdw and --with-libelf.
Use pkg-config to detect the presence of libdw and libelf either
on the system or below the prefixes specified by the new
aforementionned options.
2024-12-05 Dodji Seketeli <dodji@redhat.com>
abidiff.rst: Fix typo in the doc for --kmi-whitelist
* doc/manuals/abidiff.rst: It's not -kaw, but -w.
2024-11-13 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: Add a new --private-dso option
* doc/manuals/fedabipkgdiff.rst: Add documentation for the new
--private-dso option.
* tools/fedabipkgdiff (abipkgdiff): Pass the --private-dso option
to abipkgdiff when asked by the user.
(build_commandline_args_parser): Support the new --private-dso
option.
2024-11-13 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff.rst: Sort options documentation alphabetically
* doc/manuals/fedabipkgdiff.rst: Sort the documentation of options
alphabetically.
2024-11-12 Dodji Seketeli <dodji@redhat.com>
SECURITY: New security policy text
* SECURITY: New security policy text file.
* Makefile.am: Add the new SECURITY file to the distribution.
Reviewed-by: Frank Ch. Eigler <fche@redhat.com>
2024-11-04 Dodji Seketeli <dodji@redhat.com>
configure.ac: Bump version number to 2.7
* configure.ac: Bump version number to 2.7
2024-11-01 Dodji Seketeli <dodji@redhat.com>
big-tests: Update to commit bd0c1f8909a7b2f5018d54b82f7d6829c4849b59
* big-tests: Update sub-module to upstream
bd0c1f8909a7b2f5018d54b82f7d6829c4849b59.
2024-11-01 Dodji Seketeli <dodji@redhat.com>
Makefile.am: Update tag-and-all rule to do a full-check
* Makefile.am: Make the tag-and-all rule do a full-check instead
of just a check-self-compare.
2024-11-01 Dodji Seketeli <dodji@redhat.com>
mainpage.txt: Update content for 2.6 release
* doc/website/mainpage.txt: Change reference to 2.5 into 2.6. Add
xxhash as a dependency.
2024-11-01 Dodji Seketeli <dodji@redhat.com>
NEWS: Update for 2.6 release
* NEWS: Update with the result of the command
"git shortlog libabigail-2.5..HEAD"
2024-11-01 Dodji Seketeli <dodji@redhat.com>
ChangeLog: Update ChangeLog in preparation for 2.6 release
* ChangeLog: Update with "make update-changelog".
2024-11-01 Dodji Seketeli <dodji@redhat.com>
configure: Bump LIBABIGAIL_SO_CURRENT version to 5
* configure.ac: Set LIBABIGAIL_SO_CURRENT to 5.
2024-10-03 Dodji Seketeli <dodji@redhat.com>
big-tests: Update to commit cc6747bb859f6a4d7a3e2198d65618aa5d718fc1
* big-tests: Update sub-module to commit
cc6747bb859f6a4d7a3e2198d65618aa5d718fc1
2024-10-03 Dodji Seketeli <dodji@redhat.com>
ir: Use canonical types in comparison when --enable-debug-type-canonicalization
* src/abg-ir.cc (try_canonical_compare): When
--enable-debug-type-canonicalization is activated use canonical
types for structural comparison.
2024-10-02 Dodji Seketeli <dodji@redhat.com>
writer: Fix emitting of some member types within their scope
* src/abg-writer.cc (write_decl_in_scope): Detect that emitting a
scope type T doesn't emit a particular member type MT that we are
looking at. In that case, the function still needs to emit the
tags of the scope of MT and then emit MT even though T was just
emitted.
2024-10-01 Dodji Seketeli <dodji@redhat.com>
hash: Use the faster XXH3 hashing algorithm from xxhash
* src/abg-hash.cc (hash): In the overload for uint64_t values, use
XXH3_64bits_withSeed instead of XXH64. In the overload for
string, use XXH3_64bits instead of XXH64.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test-pointer-to-member-1.o.annotated.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-read-btf/test0.o.abi: Likewise.
* tests/data/test-read-btf/test1.o.abi: Likewise.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-alias.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-array-mdimension.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-array-size.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield.abi: Likewise.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-const-array.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise.
* tests/data/test-read-ctf/test-fallback.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi:
Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.è
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/PR28584/PR28584-smv.clang.o.abi:
Likewise.
* tests/data/test-read-dwarf/PR29443-missing-xx.o.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-fallback.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-pointer-to-member-1.o.abi:
Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2024-10-01 Dodji Seketeli <dodji@redhat.com>
writer: Do not crash on ABI corpora that have no associated path
* src/abg-writer.cc (write_context::record_corpus_as_emitted):
Allow corpus without path.
2024-10-01 Dodji Seketeli <dodji@redhat.com>
hash: Implement full recursive hashing of artifacts
* include/abg-hash.h (enum hashing_state): Add better comments for
the enumerators.
(hashing_state::HASHING_SUBTYPE_STATE): Add new enumerator.
* src/abg-hash.cc
(MAYBE_RETURN_EARLY_FROM_HASHING_TO_AVOID_CYCLES): Consider the
new state hashing::HASHING_SUBTYPE_STATE when detecting cycles.
({typedef_decl, qualified_type_def, pointer_type_def,
reference_type_def, array_type_def, ptr_to_mbr_type,
enum_type_decl, function_type, method_type, class_decl::base_spec,
class_or_union, class_decl, union_decl}::hash::operator()): Invoke
type_or_decl_base::hash_decl on sub-types to compute their hash.
Prior to invoke that hashing function, set the state of the
artifact to the new hashing:HASHING_SUBTYPE_STATE so that
type_or_decl_base::hash_decl does *not* set the computed hash on
the sub-type.
* src/abg-ir-priv.h (type_or_decl_base::priv::set_hash_value): An
ABI artifact can now be in the hashing::HASHING_SUBTYPE_STATE
state.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test-pointer-to-member-1.o.annotated.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-read-btf/test0.o.abi: Likewise.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-array-mdimension.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-array-size.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield.abi: Likewise.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-const-array.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi:
Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/PR29443-missing-xx.o.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-pointer-to-member-1.o.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2024-09-30 Dodji Seketeli <dodji@redhat.com>
reader: Drop the hash values coming from older ABIXML files
* src/abg-reader.cc (reader::m_drop_hash_value): Define new data
member.
(reader::maybe_drop_hash_values): Define new function.
(reader::read_hash_and_stash): Make the static function
read_hash_and_stash a member function of reader. Make it so that
if m_drop_hash_value is define, then no hash value is read from
the XML node.
(read_type_hash_and_cti): Move declaration of static function
before the new reader::read_hash_and_stash.
(reader::read_corpus): Call the new maybe_drop_hash_values.
(build_function_decl, build_type_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_ptr_to_mbr_type, build_function_type, build_subrange_type)
(build_array_type_def, build_enum_type_decl, build_typedef_decl)
(build_class_decl, build_union_decl): Adjust call to
read_hash_and_stash to reader::read_hash_and_stash.
2024-09-30 Dodji Seketeli <dodji@redhat.com>
big-tests: Update to latest version of libabigail-tests.git
* big-tests: Update to latest version of libabigail-tests.git
2024-09-27 Dodji Seketeli <dodji@redhat.com>
ir: Don't strip typedefs when comparing pointers & references
* src/abg-ir.cc (equals): In the overload for pointer_type_def and
reference_type_def, do not peel typedefs from the pointed-to types
before comparing them.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2024-09-27 Dodji Seketeli <dodji@redhat.com>
ir: Always use canonical types in comparison when possible
* src/abg-ir.cc (maybe_get_canonical_type): Define new function
template.
(try_canonical_compare): Use the above function to always use
canonical types in comparison.
* tests/data/test-diff-pkg/infinipath-psm-3.3-26_g604758e_open.6.fc36.5.x86_64-self-check-report.txt:
New test reference output.
* tests/data/test-diff-pkg/infinipath-psm-3.3-26_g604758e_open.6.fc36.5.x86_64.rpm:
Add new binary input.
* tests/data/test-diff-pkg/infinipath-psm-debuginfo-3.3-26_g604758e_open.6.fc36.5.x86_64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
2024-09-17 Mark Wielaard <mark@klomp.org>
Use XXH_INLINE_ALL=1 to inline all xxhash functions
* configure: Don't AC_SUBST XXHASH_{VERSION,LIBS,CFLAGS}.
Remove XXHASH_LIBS from DEPS_LIBS. Add -DXXH_INLINE_ALL=1
to CFLAGS and CXXFLAGS.
2024-09-15 Dodji Seketeli <dodji@redhat.com>
big-tests: Update to commit bd0c1f8909a7b2f5018d54b82f7d6829c4849b59
* big-tests: Update to latest commit bcec65b53b8332710f8d74adf4d6a060a91ab5ee
2024-09-06 Dodji Seketeli <dodji@redhat.com>
ir: Use definition of decl-only parm type in function type names
* src/abg-ir.cc (stream_pretty_representation_of_fn_parms): Use
the definition of decl-only function parameter types in the
representation.
2024-09-06 Dodji Seketeli <dodji@redhat.com>
corpus: Allow several variables with same ID to be exported
* include/abg-corpus.h (corpus::lookup_variables): Replace
corpus::lookup_variable with this one which returns the set of
variables associated with a given ID of variable.
* src/abg-corpus-priv.h (istr_var_ptr_set_map_type): Define new
typedef.
(corpus::exported_decls_builder::priv::id_vars_map_): Replace
id_var_map_ with this new data member of type
istr_var_ptr_set_map_type.
(corpus::exported_decls_builder::priv::id_fns_map): Fix comment.
(corpus::exported_decls_builder::priv::id_vars_map): Replace
previous id_var_map with this member function.
(corpus::exported_decls_builder::priv::var_id_is_in_id_vars_map):
Replace the var_id_is_in_id_var_map member function.
(corpus::exported_decls_builder::priv::var_is_in_vars): Define new
static member function.
(corpus::exported_decls_builder::priv::{var_is_in_id_vars_map, add_var_to_id_vars_map}):
Define new member functions.
(corpus::exported_decls_builder::priv::add_var_to_map): Remove.
(corpus::exported_decls_builder::priv::add_var_to_exported):
Adjust by using the new var_is_in_id_vars_map and
add_var_to_id_vars_map.
* src/abg-corpus.cc
(corpus::exported_decls_builder::maybe_add_var_to_exported_vars):
Adjust, use the new
corpus::exported_decls_builder::priv::var_is_in_id_vars_map.
(corpus::lookup_variables): Replace corpus::lookup_variable with
this one which returns the set of variables associated with a
given ID of variable.
* tools/abicompat.cc
(compare_expected_against_provided_variables): Adjust.
2024-09-05 Dodji Seketeli <dodji@redhat.com>
ABIXML reader: Unconditionally map a pointer XML node to its decl
* src/abg-reader.cc (build_pointer_type_def): Unconditionally map
a pointer type XML node to its decl.
2024-09-05 Dodji Seketeli <dodji@redhat.com>
ir: Improve the checks done by 'abidw --debug-tc'
* src/abg-ir.cc (compare_types_during_canonicalization): Disable
type comparison result caching during type canonicalization
debugging.
2024-09-05 Dodji Seketeli <dodji@redhat.com>
ir: Strip typedefs from pointed-to-types during comparison
* src/abg-ir.cc (equals): In the overload for pointers and
reference types, strip typedefs off of pointed-to types before
comparing them.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2024-09-02 Dodji Seketeli <dodji@redhat.com>
hash,reader,writer: (De)Serialize hash values using the xxhash canonical form
* include/abg-hash.h (deserialize_hash, serialize_hash): Declare
new functions.
* src/abg-hash.cc (deserialize_hash, serialize_hash): Define them.
(char_to_int, int_to_char): Define static functions.
(hash): For the overload that hashes an integer, make it take a
second one as hashing seed. Also, lay out the integer value to
hash in big endian format before passing it to XH64.
(combine_hashes): Use the amended hash function above.
* src/abg-reader.cc (read_type_hash_and_cti): Use the new
deserialize_hash function.
* src/abg-writer.cc (write_type_hash_and_cti): Use the new
serialize_hash function.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test-pointer-to-member-1.o.annotated.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-read-btf/test0.o.abi: Likewise.
* tests/data/test-read-btf/test1.o.abi: Likewise.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-alias.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-array-mdimension.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-array-size.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield.abi: Likewise.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-const-array.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise.
* tests/data/test-read-ctf/test-fallback.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi:
Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/PR28584/PR28584-smv.clang.o.abi:
Likewise.
* tests/data/test-read-dwarf/PR29443-missing-xx.o.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-fallback.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-pointer-to-member-1.o.abi:
Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test15.xml: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test21.xml: Likewise.
* tests/data/test-read-write/test24.xml: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2024-08-30 Dodji Seketeli <dodji@redhat.com>
comparison: Sort anonymous types using their flat representation
* src/abg-comparison-priv.h (diff_comp::operator()): Use the
non-internal pretty representation for sorting.
* tests/data/test-abidiff-exit/test-anon-types-report-1.txt:
Adjust.
* tests/data/test-abidiff-exit/test-anonymous-enums-change-report-v1.txt:
Adjust.
2024-08-30 Claudiu Zissulescu <claudiu.zissulescu-ianculescu@oracle.com>
abg-tools-utils: Fix memory corruption when using CTF option
* src/abg-tools-utils.cc
(build_corpus_group_from_kernel_dist_under): change the scope of
di_root_ctf_ptr variable.
2024-08-28 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir,writer: Better support for static member variables
* include/abg-ir.h (class_or_union::get_static_data_members):
Declare new method.
* src/abg-dwarf-reader.cc (add_or_update_class_type): Do not
create any IR for the /declaration/ of static data member here.
Wait for its definition from a concrete instance DIE to create the
IR for it.
(build_ir_node_from_die): In the DW_TAG_variable case, if we are
looking at the concrete instance of a static variable (one that
has a DW_AT_abstract_origin pointing to a static data member) then
build the IR from it and add it to its class scope.
* src/abg-ir-priv.h (class_or_union::priv::static_data_members_):
Define new data member.
(class_or_union::priv::priv): Stick the static data members that
are in class_or_union::priv::data_members_ into
class_or_union::priv::static_data_members_.
* src/abg-ir.cc (maybe_adjust_canonical_type): Make sure static
data members of the canonical type has the same symbols set as the
data members of the canonicalized type.
(class_or_union::add_data_member): Update the new
class_or_union::priv::static_data_members_ when a data member is
added.
(class_or_union::get_non_static_data_members): Fix comments.
(class_or_union::get_static_data_members): Define new member
functions.
(set_member_is_static): Update the new
class_or_union::priv::static_data_members_ when static-ness is
changed.
* src/abg-writer.cc (write_decl_in_scope): Support writing pure
declarations (not types).
(write_translation_unit): Don't forget to write remaining global
variables.
(write_class_decl): Make sure to write static data members first,
before writing the non-static data members.
* tests/data/test-abidiff-exit/test-ld-2.28-210.so--ld-2.28-211.so.txt:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test10.xml: Likewise.
2024-08-27 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,reader.cc: Fix function virtuality setting
* include/abg-fwd.h (set_member_function_vtable_offset)
(set_member_function_is_virtual): Remove these function
declarations.
(set_member_function_virtuality): Declare new function.
* include/abg-ir.h (decl_base::get_context_rel): Make this public.
(set_member_function_is_virtual)
(set_member_function_vtable_offset): Remove these friend
declaration for the decl_base class.
* src/abg-dwarf-reader.cc (finish_member_function_reading): Use
the new set_member_function_virtuality in lieu of the previous
set_member_function_is_virtual and
set_member_function_vtable_offset.
* src/abg-ir.cc (set_member_function_vtable_offset)
(set_member_function_is_virtual): Make these functions static.
(set_member_function_virtuality): Define new functions.
(class_or_union::add_member_function): Use the new
set_member_function_virtuality in lieu of
set_member_function_is_virtual and
set_member_function_vtable_offset.
* src/abg-reader.cc (build_class_decl): Likewise.
2024-08-27 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Extract devel and main packages in the same directory
* tests/data/test-diff-pkg/gcc-debuginfo-14.2.1-1.fc40.x86_64.rpm:
Add missing debug info package.
* tests/data/Makefile.am: Add it to source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the debuginfo package
to the libgm2 test.
* tools/abipkgdiff.cc (main): Extract the devel packages into the
"package1" and "package2" directories.
(extract_package_and_map_its_content): Extract the main and devel
packages sequentially, not in parallel.
(self_compare_prepared_userspace_package): Add more logs.
* tests/data/test-fedabipkgdiff/test0-from-fc20-to-fc23-dbus-glib-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test1-from-fc20-to-dbus-glib-0.106-1.fc23.x86_64-report-0.txt:
Likewise
* tests/data/test-fedabipkgdiff/test2-dbus-glib-0.100.2-2.fc20--dbus-glib-0.106-1.fc23-report-0.txt:
Likewise
* tests/data/test-fedabipkgdiff/test3-dbus-glib-0.100.2-2.fc20.i686--dbus-glib-0.106-1.fc23.i686-report-0.txt:
Likewise
* tests/data/test-fedabipkgdiff/test4-glib-0.100.2-2.fc20.x86_64.rpm-glib-0.106-1.fc23.x86_64.rpm-report-0.txt:
Likewise
* tests/data/test-fedabipkgdiff/test7-self-compare-from-fc23-dbus-glib-report-0.txt:
Likewise
* tests/data/test-fedabipkgdiff/vte291-0.39.1-1.fc22.x86_64--vte291-0.39.90-1.fc22.x86_64-report-0.txt:
Likewise
2024-08-23 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir: Fix endless loop while analyzing DWARF from Modula-2
* src/abg-dwarf-reader.cc (die_qualified_type_name)
(die_qualified_decl_name, die_qualified_type_name_empty)
(die_function_signature, die_pretty_print_type)
(die_pretty_print_decl, die_pretty_print)
(reader::{get_die_qualified_type_name}): Take a new guard
parameter. Pass it to all the type name construction function,
all the way down to die_class_flat_representation and
die_return_and_parm_names_from_fn_type_die.
(die_qualified_name, die_type_name)
(die_class_or_enum_flat_representation)
(die_class_or_enum_flat_representation)
(reader::{get_die_pretty_type_representation,
get_die_pretty_representation}): Add an overload that takes a
guard parameter and rewrite the previous overload in terms of the
new one.
(die_class_flat_representation)
(die_return_and_parm_names_from_fn_type_die): Take a new guard
parameter. Use it to detect and avoid cycles during the
construction of the type name.
* src/abg-ir-priv.h
(class_or_union::priv::is_printing_flat_representation_): Define
new data member.
(class_or_union::priv::{set,unset,is}_printing_flat_representation):
Define member functions.
(function_type::priv::is_pretty_printing_): Define new data
member.
(function_type::priv::{set,unset,}_is_pretty_printing): Define
member functions.
* src/abg-ir.cc (get_class_or_union_flat_representation)
(add_outer_pointer_to_fn_type_expr): Implement cycle detection and
avoidance for recursive classes and function types.
* tests/data/test-diff-pkg/libgm2-14.2.1-1.fc40.x86_64-self-check-report.txt:
New test reference output.
* tests/data/test-diff-pkg/libgm2-14.2.1-1.fc40.x86_64.rpm: New
input RPM.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test inputs
to the test harness.
2024-08-22 Dodji Seketeli <dodji@redhat.com>
abidw: Add a --kmi-stablelist option alongside existing --kmi-whitelist
* doc/manuals/abidw.rst: Update the documentation.
* tools/abidw.cc (display_usage): Add a help string for the new
--kmi-stablelist.
(parse_command): Parse it.
2024-08-22 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,tools-utils: Add statistics about built/suppressed functions
* src/abg-dwarf-reader.cc (reader::stats): Define new struct.
(reader::stats_): Define a new data member of type stats.
(build_or_get_fn_decl_if_not_suppressed)
(build_or_get_var_decl_if_not_suppressed): Increments the stats.
(reader::read_debug_info_into_corpus): Emit the stats about number
of suppressed/kept functions and variables at the end of the
corpus building.
* src/abg-tools-utils.cc (load_vmlinux_corpus): Emit the status
about the number of functions/variables in the corpus.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
big-tests: Update git sub-module
* big-tests: Update to git commit d84f5ef7b490ffcd466be20052fed87635e6e148
2024-08-21 Dodji Seketeli <dodji@redhat.com>
abilint: Support --verbose option
* doc/manuals/abilint.rst: Document the new --verbose option.
* tools/abilint.cc (options::do_log): New data member.
(options::options): Initialize it.
(display_usage): Document it.
(set_reader_options): New static function to set the options of
the reader from user-provided options.
(main): Use the new set_reader_options.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
{btf,ctf,dwarf}-reader, ir: Fix self-comparison debugging for corpus groups
* src/abg-btf-reader.cc (reader::read_debug_info_into_corpus):
When reading an ELF binary, which is part of a corpus group, for
the purpose of self-comparison, set that corpus group as the
comparison input. Otherwise, if the ELF binary is not part of the
corpus group, set its corpus as the comparison input. This is
done only when we are debugging the self-comparison process by
doing abidw --debug-abidiff.
* src/abg-ctf-reader.cc (reader::read_corpus): Likewise.
* src/abg-dwarf-reader.cc (reader::read_debug_info_into_corpus):
Likewise.
* src/abg-ir-priv.h (type_originates_from_corpus): Declare ...
* src/abg-ir.cc (type_originates_from_corpus): ... new function.
(type_base::get_canonical_type_for): When debugging the
self-comparison process, use the new type_originates_from_corpus
to know if the current type being canonicalized originates from
the second corpus.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
{dwarf,btf,ctf}-reader: Set the origin of the corpus group
* src/abg-btf-reader.cc (reader::read_corpus): Set the origin of
the corpus group being read.
* src/abg-ctf-reader.cc (reader::read_corpus): Likewise.
* src/abg-dwarf-reader.cc (reader::read_debug_info_into_corpus):
Likewise.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix building of void, void* and variadic parm types
* src/abg-dwarf-reader.cc (build_ir_node_for_void_type)
(build_ir_node_for_void_pointer_type)
(build_ir_node_for_variadic_parameter_type): Add the type node to
its scope just once. Use
reader::schedule_type_for_late_canonicalization to canonicalize
it.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
tools-utils: Improve logging while reading a Linux kernel
* src/abg-tools-utils.cc (load_vmlinux_corpus)
(build_corpus_group_from_kernel_dist_under): Improve time logging.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
ir: Improve type logging during type canonicalization
* src/abg-ir-priv.h (canonicalize_types): Log the time taken by
type canonicalization.
2024-08-13 Dodji Seketeli <dodji@redhat.com>
reader: Improve logging in the ABIXML reader
* src/abg-reader.cc (reader::read_corpus)
(reader::perform_type_canonicalization)
(read_corpus_group_from_input): Improve logging.
2024-08-16 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support LLVM's lingo of declaration-ness
* src/abg-dwarf-reader.cc (die_is_declaration_only): A DIE is a
declaration if it has the DW_AT_declaration property and if it
either has no size attribute or no children DIE.
(reader:: maybe_schedule_decl_only_type_for_resolution): Define
new function.
(build_enum_type, add_or_update_class_type)
(add_or_update_union_type): Do not schedule a declaration for
declaration-to-definition-resolution pass here.
(build_typedef_type): If the typedef is a naming typedef, schedule
the underlying type for the declaration-to-definition-resolution
pass here.
(build_ir_node_from_die): Schedule the declaration for
declaration-to-definition-resolution pass here, after it's been
added to its scope.
* tests/data/test-diff-filter/test41-report-0.txt: Adjust.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
2024-08-16 Dodji Seketeli <dodji@redhat.com>
ir: Fix name setting of a ptr-to-mbr-type
* include/abg-ir.h (decl_base::{g,s}et_name): Make these member
functions virtual.
(ptr_to_mbr_type::get_name): Add new virtual overload.
* src/abg-ir.cc (ptr_to_mbr_type::ptr_to_mbr_type): Do not set the
name of the type here. Just say that it's not anonymous.
(ptr_to_mbr_type::get_name): Define new (virtual) member function.
2024-08-14 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Speed-up decl-only resolution
* src/abg-dwarf-reader.cc
(reader::compare_before_canonicalisation): If the two types being
compared are of the same kind and name, and are declared at the
same source location, then they ought to be equivalent.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
2024-08-13 Dodji Seketeli <dodji@redhat.com>
reader: Avoid duplicating recursive types
* src/abg-reader.cc (build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_ptr_to_mbr_type, build_subrange_type, build_array_type_def)
(build_enum_type_decl, build_typedef_decl): After a sub-type is
built, check if the complex type we are looking at is built too.
If it is, then return it.
2024-08-06 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Avoid duplicating anonymous member types
* include/abg-comp-filter.h (has_void_ptr_to_ptr_change)
(has_harmless_enum_to_int_change)
(has_benign_array_of_unknown_size_change): Declare new functions.
* include/abg-comparison.h (enum diff_category): Add
NON_COMPATIBLE_DISTINCT_CHANGE_CATEGORY,
NON_COMPATIBLE_NAME_CHANGE_CATEGORY enumerators. Update the other
enumerator values. Also, update the EVERYTHING_CATEGORY
enumerator value.
* include/abg-ir.h (class_decl::find_base_class): Document the
name of the parameter.
* src/abg-comp-filter.cc (type_diff_has_cv_qual_change_only)
(is_non_compatible_distinct_change, is_void_ptr_to_ptr): Define
new static functions.
(has_subtype_changes): Remove static function.
(class_diff_has_only_harmless_changes): Do not bother checking if
the class_diff has subtype changes. If there are, the category of
those changes is going to be propagated upward to this current
diff node. Update the comments.
(has_harmless_name_change): A diff node carrying compatible types
or types that differ only from their CV qualifiers should qualify
as having a harmless name change.
(has_harmless_enum_to_int_change): Make this function be
non-static.
(type_diff_has_cv_qual_change_only): Introduce an overload that
takes two ABI artifacts instead of one diff node. Make the diff
node overload use the new one. Simplify logic by essentially
peeling off qualified or typedefs first. Then if what remain is
pointer or array types, look at their underlying types. If the
remaining underlying types are equal then return true.
(has_void_ptr_to_ptr_change): Use the new is_void_ptr_to_ptr
function. This allows the function to detect void* -> pointer and
pointer -> void* changes. And it simplifies the logic.
* src/abg-comparison.cc (distinct_diff::compatible_child_diff):
Build a compatible child diff node iff the two diff subject are
actually compatible meaning, they are equal modulo a typedef.
(get_default_harmful_categories_bitmap): Add the new
abigail::comparison::{NON_COMPATIBLE_DISTINCT_CHANGE_CATEGORY,NON_COMPATIBLE_NAME_CHANGE_CATEGORY}
enumerators to the bitmap of harmful categories.
(operator<<(ostream& o, diff_category c)): Update this to support
emitting the new
abigail::comparison::{NON_COMPATIBLE_DISTINCT_CHANGE_CATEGORY,NON_COMPATIBLE_NAME_CHANGE_CATEGORY}
enumerators.
(class_or_union_diff::priv::count_filtered_{subtype_}changed_dm):
Fix logic for counting local changes.
diff::has_local_changes_to_be_reported is not reliable so do not
rely on it. We might want to remove that function in the end.
(category_propagation_visitor::visit_end): If the current diff
node has a harmless void pointer to pointer, enum to int, or a
benign array of unknown size change, do not propagate the
NON_COMPATIBLE_{NAME,DISTINCT}_CHANGE_CATEGORY that have
necessarily bubbled up from some of their distant children nodes.
* src/abg-dwarf-reader.cc
(maybe_set_member_type_access_specifier)
(get_next_member_sibling_die): Declare this pre-existing static
function.
(get_internal_anonymous_die_name)
(lookup_class_typedef_or_enum_type_from_corpus)
(lookup_class_typedef_or_enum_type_from_corpus): Remove.
(die_return_and_parm_names_from_fn_type_die): Add is_method_type
and return_type_name parameters. Fix the representation of member
functions.
(die_function_signature): Add qualified_name parameter. Adjust
call to die_return_and_parm_names_from_fn_type_die.
(die_type_name, die_enum_flat_representation)
(die_class_flat_representation)
(die_class_or_enum_flat_representation): Define new static
functions.
(reader::get_die_qualified_type_name, die_qualified_type_name):
For anonymous class or enum types, use the new
die_class_or_enum_flat_representation. Adjust the call to
die_return_and_parm_names_from_fn_type_die. For function types fix
the name representation.
(die_pretty_print_type): Adjust call to
die_return_and_parm_names_from_fn_type_die.
(die_pretty_print_decl): Take qualified_name and include_fns
parameters. Use the new die_type_name for variable type names.
Adjust call to die_function_signature.
(die_pretty_print): Adjust call die_pretty_print_decl.
(get_member_child_die): Remove useless vertical space.
(build_enum_underlying_type): Sort this enum underlying type (and
potentially hash it) before canonicalizing it.
(add_or_update_class_type): If an anonymous type is in the global
scope, take that into account when building its internal anonymous
die name. Lookup anonymous member types before adding them to the
class scope to avoid duplicating them in their scope.
(add_or_update_union_type): Likewise, lookup anonymous member
types before adding them to the union scope to avoid duplicating
them in their scope.
(build_subranges_from_array_type_die): Const-ify the input reader.
Adjust call to build_ir_node_from_die. Associate the subrange DIE
to the IR node built.
(build_ir_node_from_die): Get the current corpus from the reader
because it might be set for scope passed to this function, or the
scope might be nullptr. Schedule base types for canonicalization
like all the other types. Also, lookup all class/union types
before adding them to their class scope.
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
overload for class_or_union_diff, report changed data members and
their sub-types.
* tests/Makefile.am: Do not XFAIL the test runtestabidiffexit. No
more tests are XFAILED. All tests should now pass.
* tests/data/test-abidiff-exit/PR30503/libsdl/libsdl-1.2.60-1.2.64-report.txt:
Adjust.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Likewise.
* tests/data/test-diff-dwarf/test4-report.txt: Likewise.
* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
* tests/data/test-diff-filter/test-PR26739-2-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test5-report.txt: Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2024-08-08 Dodji Seketeli <dodji@redhat.com>
ir: Cache the result of scope_decl::get_sorted_member_types
* include/abg-ir.h
(environment::canonicalization_started): Define new member
functions.
* src/abg-ir-priv.h
(environment::priv::canonicalization_started_): Define new data
member.
(canonicalize_types): Call
environment::canonicalization_started(true) right before starting
type canonicalization and call
environment::canonicalization_started(false) right after type
canonicalization is done.
* src/abg-ir.cc (environment::canonicalization_started): Define
new methods.
(environment::canonicalization_is_done): Set the
new canonicalization_started flag to false when the
canonicalization is done.
(scope_decl::priv::clear_sorted_member_types_cache_): Declare new
data member.
(scope_decl::{add_member_decl, insert_member_type}): If we are
adding a type to the scope, then flag the scope as needing to
clear the sorted member types cache.
(scope_decl::get_sorted_member_types): If type canonicalization is
not yet started, then the sorted member types cache needs to be
cleared. If the sorted member types cache is to be cleared, then
clear it. If the cache is empty, fill it. Then return the
content of the cache.
2024-08-08 Dodji Seketeli <dodji@redhat.com>
reader: Avoid duplicating member types
* src/abg-reader.cc (read_name): New static function.
(build_class_decl, build_union_decl): If a member type already
exists in the class, do not add it.
2024-05-14 Dodji Seketeli <dodji@redhat.com>
Don't strip typedefs in fn names when pretty-printing and comparing
* src/abg-ir.cc (get_function_type_name, get_method_type_name): Do
not peel typedef from return type.
(equals): In the overload for function_type, do not peel typedef
before comparing return types. In the overload for
function_decl::parameter, do not peel typedef before comparing the
parameter type.
(stream_pretty_representation_of_fn_parms): Do not strip typedef
from parameter types.
(add_outer_pointer_to_fn_type_expr): Likewise for return type.
* tests/Makefile.am: XFAIL the test runtestabidiffexit.
* tests/data/test-abidiff-exit/PR30503/libsdl/libsdl-1.2.60-1.2.64-report.txt:
Adjust.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr2-output-1.txt:
Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2023-12-17 Dodji Seketeli <dodji@redhat.com>
comp-filter: Ignore ptr size when detecting void ptr to ptr change
* src/abg-comp-filter.cc (has_void_ptr_to_ptr_change): Ignore
pointer size when detecting void pointer to pointer change.
* tests/data/test-diff-filter/test47-filter-void-ptr-change-report-0.txt:
Adjust.
2023-12-17 Dodji Seketeli <dodji@redhat.com>
comp-filter: Consider lvalue-ness changes on references as harmful
* include/abg-comparison.h (enum diff_category): Add the new
REFERENCE_LVALUENESS_CHANGE_CATEGORY enumerator. Adjust the value
of the other enumerators.
* src/abg-comparison.cc (get_default_harmful_categories_bitmap):
Consider the new REFERENCE_LVALUENESS_CHANGE_CATEGORY as being
part of the default harmful categories bitmap.
(operator<<(ostream& o, diff_category c)): Support the new
REFERENCE_LVALUENESS_CHANGE_CATEGORY for me.
* include/abg-comp-filter.h (has_lvalue_reference_ness_change):
Declare new function.
* src/abg-comp-filter.cc (has_lvalue_reference_ness_change):
Define new function.
(categorize_harmful_diff_node): Use the new
has_lvalue_reference_ness_change to set the new
REFERENCE_LVALUENESS_CHANGE_CATEGORY.
* tests/Makefile.am: XFAIL runtestabidiffexit.
* tests/data/test-diff-filter/test3-report.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test47-filter-void-ptr-change-report-0.txt:
Likewise.
2024-03-27 Dodji Seketeli <dodji@redhat.com>
ir: decl-only classes don't equal fully defined classes under ODR
* src/abg-ir.cc (equals): In language supporting the ODR (just
like in all other languages), consider that a decl-only class is
different from its defined class counterpart.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
Adjust.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
ir: Remove the now useless type propagation optimization
* configure.ac: Remove the now useless --enable-ct-propagation
option.
* include/abg-ir.h (environment::do_on_the_fly_canonicalization):
Remove member function declaration.
* src/abg-ir-priv.h (type_base::priv::{depends_on_recursive_type_,
canonical_type_propagated_,
propagated_canonical_type_confirmed_}): Remove data members.
(type_base::priv::priv): Update.
(type_base::priv::{depends_on_recursive_type,
set_depends_on_recursive_type,
set_does_not_depend_on_recursive_type, canonical_type_propagated,
set_canonical_type_propagated,
propagated_canonical_type_confirmed,
set_propagated_canonical_type_confirmed,
clear_propagated_canonical_type}): Remove member functions.
(environment::priv::{types_with_non_confirmed_propagated_ct_,
recursive_types_, types_with_cleared_propagated_ct_,
do_on_the_fly_canonicalization_}): Remove data members.
(environment::priv::priv): Adjust.
(environment::priv::{mark_dependant_types,
mark_dependant_types_compared_until}): Update comment.
(environment::priv::{mark_dependant_types,
mark_dependant_types_compared_until, is_recursive_type,
propagate_ct, confirm_ct_propagation_for_types_dependant_on,
confirm_ct_propagation, confirm_ct_propagation,
types_with_cleared_propagated_ct,
types_with_cleared_propagated_ct,
record_type_with_cleared_propagated_canonical_type,
erase_type_with_cleared_propagated_canonical_type,
collect_types_that_depends_on,
cancel_ct_propagation_for_types_dependant_on,
cancel_ct_propagation, clear_propagated_canonical_type,
add_to_types_with_non_confirmed_propagated_ct,
remove_from_types_with_non_confirmed_propagated_ct,
cancel_all_non_confirmed_propagated_canonical_types}): Remove.
(canonicalize_types): Remove canonical type propagation debugging
code.
* src/abg-ir.cc (mark_dependant_types_compared_until): Remove function.
(RETURN_TRUE_IF_COMPARISON_CYCLE_DETECTED): Adjust, do not use the
removed mark_dependant_types_compared_until.
(return_comparison_result): Remove handling of the canonical type
propagation optimization.
(environment::do_on_the_fly_canonicalization): Remove member
functions.
(maybe_propagate_canonical_type, maybe_propagate_canonical_type)
(maybe_cancel_propagated_canonical_type, ): Remove functions.
(compare_canonical_type_against_candidate, canonicalize): Remove
handling of the canonical type propagation optimization.
(equals): In the overload for class_or_union, adjust call to
return_comparison_result. In the overload for class_decl, remove
call to maybe_cancel_propagated_canonical_type.
(OnTheFlyCanonicalization): Remove this doxygen documentation
module describing the canonical type propagation optimization.
2024-03-26 Dodji Seketeli <dodji@redhat.com>
Implement type hashing
* configure.ac: Bump ABIXML version to 4.0. Detect the new xxhash
dependency and require the 0.8.0 version at minimum.
* include/abg-fwd.h (look_through_decl_only_type): Declare new
functions.
(is_scope_decl): Const-ify the parameter and
the returned value. Also, do not include "abg-hash.h" here.
* include/abg-hash.h: Make this include cstdint (for uint64_t) and
abg-ir.h, instead of stdint.h.
(enum hashing_state): Define new enum in the abigail::hashing
namespace.
(combine_hashes, fnv_has, hash, get_hashing_state)
(set_hashing_state, is_recursive_artefact): Declare new functions
in the abigail::hashing namespace.
(struct {decl_base, type_base, type_decl, qualified_type_def,
pointer_type_def, reference_type_def, ptr_to_mbr_type,
array_type_def, enum_type_decl, typedef_decl, function_type,
method_type, member_base, class_or_union, class_decl::base_spec,
class_decl, union_decl}::hash): Declare new hash functors in the
abigail::ir namespace.
* include/abg-ir.h: Remove the inclusion of abg-hash.h from this
header.
(typedef hash_t): Define new type.
(peek_hash_value): Declare new function.
(get_canonical_types): Return a pointer to const vector.
({type_or_decl_base, type_base, qualified_type_def,
pointer_type_def, reference_type_def, ptr_to_mbr_type,
array_type_def::subrange_type, typedef_decl, function_type,
method_type, class_or_union, class_decl, class_decl::base_spec,
union_decl}::hash_value): Add new virtual member functions.
(type_or_decl_base::set_hash_value): Add new member function.
(type_or_decl_base::priv_): Make this data member public.
(peek_hash_value, set_or_get_cached_hash_value): Declare these
functions as friends of class type_or_decl_base.
({decl_base, scope_decl, var_decl, function_decl,
function_decl::parameter}::get_hash): Remove member functions.
* src/abg-comparison-priv.h (types_or_decls_hash::operator()):
Adjust to using the new hash_t type.
* src/abg-ctf-reader.cc
(reader::{additional_types_to_canonicalize, types}): Add new data
members.
(reader::add_type(): Add new member function.
(reader::canonicalize_all_types): Use the new types vector data
member to stash types to be canonicalized and pass them to
ir::hash_and_canonicalize_types for canonicalization.
(process_ctf_base_type)
(build_ir_node_for_variadic_parameter_type)
(build_ir_node_for_void_type, build_ir_node_for_void_pointer_type)
(build_array_ctf_range, process_ctf_enum_type): Do not use
canonicalize anymore. Rather, rely on reader::add_type to
schedule types for canonicalization, doing the generic sorting and
hashing before doing the actually canonicalization.
* src/abg-dwarf-reader.cc ({dwarf_offset_pair_hash,offset_hash,
offset_pair_hash}::operator()): Use the new hashing function.
(reader::read_debug_info_into_corpus): Improve logging. Use
ir::hash_and_canonicalize_types in lieu of ir::canonicalize_types.
(reader::types_to_canonicalize): Add
non-const overload.
(reader::canonicalize_types_scheduled): Add better logs & misc
obvious cleanup.
(maybe_canonicalize_type): Force scheduling canonicalization of
all types at the end of the DWARF processing.
* src/abg-hash.cc (combine_hashes, hash, get_hashing_state)
(set_hashing_state, is_recursive_artefact): Define new functions.
(MAYBE_RETURN_EARLY_FROM_HASHING_TO_AVOID_CYCLES)
(MAYBE_FLAG_TYPE_AS_RECURSIVE)
(MAYBE_RETURN_EARLY_IF_HASH_EXISTS): Define new macros.
(struct {decl_base, type_base, type_decl, qualified_type_def,
pointer_type_def, reference_type_def, ptr_to_mbr_type,
array_type_def, ptr_to_mbr_type, enum_type_decl, typedef_decl,
function_decl, function_type, method_type, member_base,
class_or_union, class_decl::base_spec, class_decl,
union_decl}::hash::operator): Define new hash functors.
({template_parameter, template_decl, non_type_tparameter,
template_tparameter, type_composition, type_composition,
function_tdecl}::{hash, dynamic_hash, shared_ptr_hash): Remove.
* src/abg-ir-priv.h: Don't include abg-ir.h anymore, rather
include abg-hash.h.
(struct type_or_decl_base::priv): Move this here, from abg-ir.cc.
(type_or_decl_base::priv::{hashing_state_, hash_value_,
is_recursive_artefact_}): Define new data members.
(type_or_decl_base::priv::{get_hashing_state, set_hashing_state,
set_hash_value, force_set_hash_value, is_recursive_artefact}):
Define new member functions.
(struct sort_for_hash_functor): Define new functor.
(do_hash_value, set_or_get_cached_hash_value)
(hash_and_canonicalize_types, sort_and_canonicalize_types): Define
new function templates.
(type_is_suitable_for_hash_computing)
(sort_types_for_hash_computing_and_c14n)
(get_canonical_type_index, get_decl_name_for_comparison): Declare
new functions.
(type_base::priv::canonical_type_index): New data member.
(type_base::priv::{priv, clear_propagated_canonical_type}):
Initialize it.
(uint64_t_pair_hash::operator()): Adjust.
(environment::priv::number_of_canonical_types): New data member.
(environment::priv::priv): Initialize it.
(environment::priv::get_new_canonical_type_index): New member
function.
(environment::priv::propagate_ct): Propagate the CTI too.
(environment::priv::{confirm_ct_propagation_for_types_dependant_on,
confirm_ct_propagation}): Assert that canonical type has been
propagated and thus we have a canonical type.
(struct type_topo_comp::operator()): Beef up sorting of types.
Take into account the absolute path of the TU, the hash value, the
CTI)
(struct sort_for_hash_functor): Define new functor.
(sort_types_for_hash_computing_and_c14n): Declare new function
template and new overload.
(canonicalize_types): Take new do_log and show_stats parameters.
Improve logging. Do not sort types in here.
(hash_and_canonicalize_types): Define new function template. This
one does the sorting before the hashing and the canonicalization.
(sort_and_canonicalize_types): Likewise, but this one does no
hashing.
(cache_type_comparison_result): Cache the result of the comparison
now, unconditionally. As we don't do canonical type propagation
anymore, we should not get canonical types and equality to
disagree anymore.
(* src/abg-ir.cc (try_canonical_compare): If hash values are
present and different then the two types are different.
(environment::get_canonical_types): Constify return value.
(environment::get_canonical_type): Adjust.
(struct type_or_decl_base::priv): Move this to abg-ir-priv.h.
(type_or_decl_base::hashing_started): Remove.
({decl_base, scope_decl, var_decl, function_decl,
function_decl::parameter, class_decl::base_spec,
non_type_tparameter, type_composition}::get_hash): Likewise.
({template_parameter}::get_hashing_has_started)
(template_parameter::set_hashing_has_started): Likewise.
(type_or_decl_base::{hash_value, set_hash_value})
({type_base, type_decl, qualified_type_def, pointer_type_def,
reference_type_def, ptr_to_mbr_type,
array_type_def::subrange_type, array_type_def, enum_type_decl,
typedef_decl, function_type, method_type, class_or_union,
class_decl::base_spec, class_decl, union_decl}::hash_value):
Define new member functions.
(type_or_decl_base::set_hash_value): Likewise.
(get_decl_name_for_comparison): Make this non-static.
(is_scope_decl): Constify.
(type_is_suitable_for_hash_computing)
(peek_hash_value, read_type_hash, read_hash_and_stash)
(look_through_decl_only_type)
(candidate_matches_a_canonical_type_hash)
(sort_types_for_hash_computing_and_c14n): Define new functions.
(lookup_pointer_type, lookup_reference_type)
(pointer_type_def::get_qualified_name)
(reference_type_def::get_qualified_name)
(reference_type_def::get_pretty_representation): Adjust.
(get_type_name): Better handle naming of anonymous type decls,
used for enums.
(get_debug_representation): Adjust to emit hashes & CTI of types
as well as member types while debugging.
(look_through_decl_only_type): Rename look_through_decl_only into
this.
(lookup_pointer_type, lookup_reference_type)
(reference_type_def::get_qualified_name): Adjust.
(compare_canonical_type_against_candidate): Stop doing canonical
type propagation during type canonicalization.
(type_base::get_canonical_type_for): Use the new
candidate_matches_a_canonical_type_hash. Set the canonical type
index for homophone canonical types. In debug mode, check that if
a type equals a canonical type, their hash value must match.
(canonicalize): Take new do_log and show_stats parameter. Improve
logging. Also, a type must have the same CTI as its canonical
type.
(hash_type_or_decl): Adjust to use the new type
hash_t.
(type_topo_comp::operator()): Add an overload for type_base_wptr.
If the two pointers are equal, get out early. Otherwise, if
everything else is equal, sort using the absolute path of the
containing translation unit.
(maybe_propagate_canonical_type): Propagate canonical type only if
their CTI match.
* src/abg-reader.cc (maybe_canonicalize_type): Improve logging.
Schedule all types for late canonicalization.
(reader::perform_type_canonicalization): Improve logging. Call
hash_and_canonicalize_types to hash and canonicalize types.
(read_type_hash_and_cti, read_hash_and_stash): Define new static
functions.
(build_function_decl, build_type_decl)
(build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_ptr_to_mbr_type, build_function_type, build_subrange_type)
(build_array_type_def, build_enum_type_decl, build_typedef_decl)
(build_class_decl, build_union_decl): Read and set the hash value
from ABIXML.
(build_function_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_function_type, build_subrange_type, build_array_type_def)
(build_enum_type_decl, build_typedef_decl, build_class_decl)
(build_union_decl): Read the hash and CTI and set them to the
type.
(build_reference_type_def): Build the referenced type before-hand.
(build_class_tdecl, build_type_tparameter, build_type_composition)
(build_template_tparameter, build_type, handle_type_decl)
(handle_qualified_type_decl, handle_pointer_type_def)
(handle_reference_type_def, handle_function_type)
(handle_array_type_def, handle_enum_type_decl)
(handle_typedef_decl, handle_class_decl, handle_union_decl):
Adjust to the use of the new maybe_canonicalize_type signature.
* src/abg-btf-reader.cc (reader::canonicalize_types): Use the new
hash_and_canonicalize_types defined above. Log the time taken by
type canonicalization.
* src/abg-ctf-reader.cc (reader::{types,
additional_types_to_canonicalize}): New data members
(reader::add_types): New member functions.
(reader::canonicalize_all_types): Use the new
hash_and_canonicalize_types defined above.
(process_ctf_base_type): Do not call canonicalize here.
(build_ir_node_for_variadic_parameter_type)
(build_ir_node_for_void_type)
(build_ir_node_for_void_pointer_type, process_ctf_enum_type):
Likewise, and call reader::add_type instead.
* src/abg-dwarf-reader.cc ({dwarf_offset_pair_hash, offset_hash,
offset_pair_hash}::operator()): Adjust to using the new hash_t
type.
(reader::canonicalize_types_scheduled): Use the new
hash_and_canonicalize_types above.
(maybe_canonicalize_type): Schedule all types for late
canonicalization.
* src/abg-writer.cc (reader::get_id_for_type): Constify the
parameter.
(write_type_hash_and_cti, write_common_type_info)
(write_fn_parm_and_return_types): Define new static functions.
(write_type_decl, write_qualified_type_def)
(write_pointer_type_def, write_reference_type_def)
(write_array_subrange_type, write_array_type_def)
(write_enum_type_decl, write_typedef_decl, write_function_decl)
(write_function_type, write_class_decl_opening_tag)
(write_union_decl_opening_tag): Emit hash value and CTI to the
ABIXML.
* tests/Makefile.am: XFAIL the tests runtestdifffilter and
runtestabidiffexit for now.
* tests/data/test-abidiff-exit/PR30329/PR30329-report-1.txt:
Adjust.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi:
Likewise.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test-pointer-to-member-1.o.annotated.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-filter/test-PR26739-2-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test3-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test43-decl-only-def-change-leaf-report-0.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-read-btf/test0.o.abi: Likewise.
* tests/data/test-read-btf/test1.o.abi: Likewise.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-alias.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-array-mdimension.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-array-size.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield.abi: Likewise.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-const-array.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise.
* tests/data/test-read-ctf/test-fallback.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi:
Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/PR28584/PR28584-smv.clang.o.abi:
Likewise.
* tests/data/test-read-dwarf/PR29443-missing-xx.o.abi: Likewise.
* tests/data/test-read-dwarf/PR29692-kdelibs3-libkjava.so.1.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-fallback.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-pointer-to-member-1.o.abi:
Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test-crc.xml: Likewise.
* tests/data/test-read-write/test0.xml: Likewise.
* tests/data/test-read-write/test1.xml: Likewise.
* tests/data/test-read-write/test10.xml: Likewise.
* tests/data/test-read-write/test11.xml: Likewise.
* tests/data/test-read-write/test12.xml: Likewise.
* tests/data/test-read-write/test13.xml: Likewise.
* tests/data/test-read-write/test14.xml: Likewise.
* tests/data/test-read-write/test15.xml: Likewise.
* tests/data/test-read-write/test16.xml: Likewise.
* tests/data/test-read-write/test17.xml: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test19.xml: Likewise.
* tests/data/test-read-write/test2.xml: Likewise.
* tests/data/test-read-write/test20.xml: Likewise.
* tests/data/test-read-write/test21.xml: Likewise.
* tests/data/test-read-write/test22.xml: Likewise.
* tests/data/test-read-write/test23.xml: Likewise.
* tests/data/test-read-write/test24.xml: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
* tests/data/test-read-write/test26.xml: Likewise.
* tests/data/test-read-write/test27.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
* tests/data/test-read-write/test3.xml: Likewise.
* tests/data/test-read-write/test4.xml: Likewise.
* tests/data/test-read-write/test5.xml: Likewise.
* tests/data/test-read-write/test6.xml: Likewise.
* tests/data/test-read-write/test7.xml: Likewise.
* tests/data/test-read-write/test8.xml: Likewise.
* tests/data/test-read-write/test9.xml: Likewise.
2024-08-29 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Make --verbose enable the library's logging
* tools/abipkgdiff.cc (set_generic_options): Make --verbose
trigger the logs of the library.
2024-08-28 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Do not fix ELF symbols for virtual destructors
* src/abg-dwarf-reader.cc (finish_member_function_reading): Do not
schedule virtual destructors for ELF symbol-related function
fixup.
2024-08-29 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Make logging more obvious
* src/abg-ctf-reader.cc (reader::read_corpus): Prefix the logs
with "CTF Reader".
2024-08-22 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix support of suppression specifications
* src/abg-dwarf-reader.cc (function_is_suppressed)
(variable_is_suppressed): Do not return too early when the
function doesn't seem suppressed, yet.
* tests/data/test-diff-suppr/test31-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test32-report-1.txt: Adjust.
2024-08-21 Dodji Seketeli <dodji@redhat.com>
btf-reader: Add logging methods
* src/abg-btf-reader.cc (reader::{do_log, show_stats}): Add new
methods.
2024-08-28 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Better support concrete instance functions DIEs
* src/abg-dwarf-reader.cc (build_ir_node_from_die): If the DIE is
a concrete instance of an abstract one, then get the IR from the
abstract one as it has all the types right.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
2024-08-08 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Enumerate dicts in the archive rather than using their name
* src/abg-ctf-reader.cc (reader::process_ctf_archive): Do not use
ctf_dict_open to open the dictionary by name. Rather, enumerate
the dictionaries of the current archive by using ctf_archive_next
just like what lookup_symbol_in_ctf_archive does. Set the
argument of the skip_parent parameter to "false" to ensure we get
the parent dictionary.
(lookup_symbol_in_ctf_archive): Clean this up to properly
initialize the parameters and to document the arguments to the
parameters of ctf_archive_next. Use nullptr instead of NULL.
* tests/data/test-diff-pkg-ctf/test-rpm-report-1.txt: Adjust.
* tests/data/test-diff-pkg-ctf/test-rpm-report-2.txt: Adjust.
2024-08-16 Dodji Seketeli <dodji@redhat.com>
ir: Handle ptr to fn type member with empty void return type
* src/abg-ir.cc (add_outer_ptr_to_mbr_type_expr): If the function
type has no return type, consider it as void type.
2024-08-16 Dodji Seketeli <dodji@redhat.com>
reader: Avoid empty return type node for a function type IR
* src/abg-reader.cc (build_function_type): If the return type node
is empty, use a void type node.
2024-08-16 Dodji Seketeli <dodji@redhat.com>
ir: Don't cache internal name of non-canonicalized function types
* src/abg-ir.cc (function_type::get_cached_name): Do not cache
internal name for non-canonicalized function types.
2024-08-16 Dodji Seketeli <dodji@redhat.com>
ir: Improve legibility of set_member_function_is_virtual
* src/abg-ir.cc (set_member_function_is_virtual): Remove
useless white space and use clearer helper function.
2024-08-06 Dodji Seketeli <dodji@redhat.com>
abidw: Make generic options like --verbose work with the ABIXML front-end
* tools/abidw.cc (set_generic_options): Take a fe_iface in
parameter, not an elf_based_reader.
(perform_self_comparison): Call set_generic_options.
2024-08-13 Dodji Seketeli <dodji@redhat.com>
reader: Fix building of reference type
* src/abg-reader.cc (build_reference_type_def): Remove unnecessary
condition.
2024-08-13 Dodji Seketeli <dodji@redhat.com>
reader: Avoid crashing on empty scopes in reader::push_decl_to_scope
* src/abg-reader.cc (reader::push_decl_to_scope): It's only if
there is a non-nil scope that the assert can be reached.
2024-08-06 Dodji Seketeli <dodji@redhat.com>
ir: Fix comment for translation_unit::get_global_scope
* src/abg-ir.cc (translation_unit::get_global_scope): Fix comment.
2024-08-06 Dodji Seketeli <dodji@redhat.com>
ir: Speed up enum comparison
* src/abg-ir.cc (equals): In the overload for enums, compare
enumerators naively for the case both enums are naively equal.
2024-08-05 Dodji Seketeli <dodji@redhat.com>
ir: Support comparing a class_decl against a class_or_union
* src/abg-ir.cc (class_decl::operator==): Support comparing
against a class_or_union.
2024-08-05 Dodji Seketeli <dodji@redhat.com>
ir: Support canonical type adjustments for decl-only class types
* src/abg-ir.cc (maybe_adjust_canonical_type): Look through
decl-only classes to get their definition.
2024-08-01 Dodji Seketeli <dodji@redhat.com>
ir: Make odr_is_relevant support support artifacts with no TU set yet
* src/abg-ir.cc (odr_is_relevant): Consider that an artifact with
no associated TU is not relevant for ODR considerations.
2024-08-01 Dodji Seketeli <dodji@redhat.com>
ir: add_decl_to_scope shouldn't abort on nullptr scopes
* src/abg-ir.cc (add_decl_to_scope): Do not abort on an empty
scope.
2024-08-01 Dodji Seketeli <dodji@redhat.com>
ir: Fix getting the translation unit for an ABI artifact
* include/abg-fwd.h (get_translation_unit): Take a
type_or_decl_base parameter, not a decl_base.
* src/abg-ir.cc (get_translation_unit): Likewise. If no
translation has yet been associated with the ABI artifact, get it
from its scope.
(type_or_decl_base::get_corpus): Use the new get_translation_unit.
(maybe_set_translation_unit): Assert that the translation unit is
non-nil.
2024-07-31 Dodji Seketeli <dodji@redhat.com>
Use smart pointers for variables exported from the ABI corpus
* include/abg-comparison.h (string_var_ptr_map): Use a
var_decl_sptr rather than a var_decl*.
* include/abg-corpus.h (corpus::{variable, variables_set}):
Likewise.
(corpus::lookup_variable): Return a var_decl_sptr not a var_decl*.
(corpus::exported_decls_builder::maybe_add_var_to_exported_vars):
Take a var_decl_sptr, not a var_decl*.
* include/abg-fe-iface.h
(fe_iface::add_var_to_exported_or_undefined_decls): Likewise.
* include/abg-ir.h (istring_var_decl_ptr_map_type): Use a
var_decl_sptr rather than a var_decl*.
* src/abg-btf-reader.cc (reader::build_ir_node_from_btf_type):
Adjust call to add_var_to_exported_or_undefined_decls.
* src/abg-comparison-priv.h (var_comp::operator()()): Add a new
overload for var_decl_sptr.
(corpus_diff::priv::{deleted_variable_is_suppressed,
deleted_variable_is_suppressed}): Take a var_decl_sptr not a
var_decl*.
(sort_string_var_ptr_map): Take ...
* src/abg-comparison.cc (sort_string_var_ptr_map): ... a
vector<var_decl_sptr> rather than a vector<var_decl*>.
(corpus_diff::priv::ensure_lookup_tables_populated): Adjust.
(variable_is_suppressed): Likewise.
(corpus_diff::priv::{deleted_variable_is_suppressed,
added_variable_is_suppressed}): Likewise.
* src/abg-corpus-priv.h (str_var_ptr_map_type)
(istr_var_ptr_map_type): Use a var_decl_sptr rather than a
var_decl*.
(corpus::exported_decls_builder::priv::{add_var_to_map,
keep_wrt_id_of_vars_to_keep, keep_wrt_regex_of_vars_to_suppress,
keep_wrt_regex_of_vars_to_keep}): Likewise.
(corpus::exported_decls_builder::priv::vars): Likewise.
* src/abg-corpus.cc
(corpus::exported_decls_builder::maybe_add_var_to_exported_vars):
Likewise.
(var_comp::operator()()): Add an overload for var_decl_sptr.
(corpus::lookup_variable): Return var_decl_sptr rather than
var_decl*.
* src/abg-ctf-reader.cc (reader::process_ctf_archive): Adjust.
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Adjust.
* src/abg-fe-iface.cc
(fe_iface::add_var_to_exported_or_undefined_decls): Take a
var_decl_sptr rather than a var_decl*.
* src/abg-reader.cc (build_class_decl, handle_var_decl): Adjust.
* src/abg-writer.cc (write_translation_unit): Likewise.
* tools/abicompat.cc (var_change::decl, var_change::var_change):
Likewise.
(compare_expected_against_provided_variables): Likewise.
2024-08-07 Dodji Seketeli <dodji@redhat.com>
configure.ac: Fix typo triggered when --enable-big-tests is used
* configure.ac: It's "cd $ac_abs_top_srcdir/big-tests", not
"cd ac_abs_top_srcdir/big-tests"
2024-07-04 Dodji Seketeli <dodji@redhat.com>
configure: Support the optional 'big-tests' sub-directory
* Makefile.am: Add big-tests,clean-big-tests and full-check
targets.
* configure.ac: Add an --enable-big-tests option. For now, this
option is mandatory to handle the optional 'big-tests' support.
If the --enable-big-tests option is provided and if the
'big-tests' sub-directory is present, configure the big-tests/
sub-package.
* .gitmodules: New sub-module configuration to get
git://sourceware.org/git/libabigail-tests and stick into ...
* big-tests: ... this directory as a sub-module.
* CONTRIBUTING: Update this to explain how to get the Big Tests
going.
* tests/Makefile.am: Update the test summary for the
check-self-compare target.
2024-07-09 Dodji Seketeli <dodji@redhat.com>
abidw: Support the --abidiff option for Linux Kernel trees
* include/abg-corpus.h (is_corpus_group): Declare ...
* src/abg-corpus.cc (is_corpus_group): ... new function.
* src/abg-ctf-reader.cc (create_reader): Support --debug-abidiff
when the package is configured with --enable-debug-self-comparison.
* tools/abidw.cc (load_corpus_and_write_abixml): Factorize self
comparison code out into ...
(perform_self_comparison): ... this.
(load_kernel_corpus_group_and_write_abixml): Use the new
perform_self_comparison to perform self comparison when the
--abidiff option is provided. Also, support --debug-abidiff when
the package is configured with --enable-debug-self-comparison.
2024-07-09 Dodji Seketeli <dodji@redhat.com>
ir,comparison,default-reporter: Consider sub-ranges in array diffs
* include/abg-comparison.h (array_diff::array_diff): Take a vector
of sub-range diffs as children diff nodes.
(array_diff::{subrange_diffs, any_subrange_diff_to_be_reported}):
Declare new methods.
(is_anonymous_subrange_diff): Declare new function.
* src/abg-comp-filter.cc (integral_type_has_harmless_name_change):
Define new function.
(has_harmless_name_change): Use the new
integral_type_has_harmless_name_change.
* src/abg-comparison-priv.h (array_diff::priv::subrange_diffs_):
Define new data member.
* src/abg-comparison.cc (is_anonymous_class_or_union_diff): Fix
comment.
(is_anonymous_subrange_diff): Define new function.
(array_diff::chain_into_hierarchy): Append sub-range diffs as
children nodes of the array_diff node.
(array_diff::array_diff): Take a vector of sub-range diffs as
children diff nodes.
(array_diff::{subrange_diffs, any_subrange_diff_to_be_reported}):
Define new methods.
(array_diff::has_changes): Take sub-range diffs into account.
(compute_diff): In the overload for array_type_def, compute diffs
for sub-ranges as part of the diff for array_type_defs.
(leaf_diff_node_marker_visitor::visit_begin): Do not consider an
anonymous sub-range diff node as being a leaf diff node to report
about.
(redundancy_marking_visitor::visit_end): Report all sub-range diff
nodes changes; do not propagate their (potential) redundancy to
their array_diff node parent.
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for array_diff, if there is a sub-range change to be
reported, then report it.
* src/abg-ir-priv.h (real_type::base_type): Add SIZE_BASE_TYPE,
SSIZE_BASE_TYPE, BIT_SIZE_BASE_TYPE, SBIT_SIZE_BASE_TYPE,
ARRAY_SIZE_BASE_TYPE enumerators to this enum.
* src/abg-ir.cc (parse_base_real_type): Support parsing real type
names that are __ARRAY_SIZE_TYPE__, sizetype, ssizetype,
bitsizetype and sbitsizetype.
(real_type::to_string): Support IZE_BASE_TYPE, SSIZE_BASE_TYPE,
BIT_SIZE_BASE_TYPE, SBIT_SIZE_BASE_TYPE and ARRAY_SIZE_BASE_TYPE
enumerators.
(equals): In the overload for array_type_def::subrange_type,
compare the underlying types of the sub-ranged. In the overload
for array_type_def, consider sub-range changes mismatch as a local
non-type change. This is so that changes to sub-ranges don't get
filtered out because changes to element types are redundant.
* src/abg-reporter-priv.cc (represent): In the overload for
subrange_diff, clean up reporting of change of bound values.
Also, add reports of changes from non-finite to finite size.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-1.txt:
Adjust.
* Tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-array-v0--v1-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-array-v0--v3-report-1.txt:
Likewise.
* tests/data/test-abidiff/test-PR27985-report.txt: Likewise.
* tests/data/test-diff-dwarf/test10-report.txt: Likewise.
* tests/data/test-diff-dwarf/test11-report.txt: Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc-report-0.txt:
Likewise.
* tests/data/test-diff-filter/PR24430-fold-qualified-array-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test-PR29811-0-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-report-2.txt:
Likewise.
2024-07-08 Dodji Seketeli <dodji@redhat.com>
ir: Rename integral_type into real_type
* include/abg-fwd.h (is_real_type): Declare new function.
* src/abg-ctf-reader.cc (process_ctf_base_type): Adjust.
* src/abg-dwarf-reader.cc (die_qualified_type_name)
(build_type_decl): Adjust.
* src/abg-ir-priv.h (class real_type): Rename class integral_type
into this.
* src/abg-ir.cc (get_internal_real_type_name, operator|)
(operator&, operator~, operator|=, operator&=)
(parse_real_type_modifier, parse_base_real_type, parse_real_type)
(real_type::{real_type, get_base_type, get_modifiers,
set_modifiers, to_string, operator string()}):
s/integral_type/real_type.
(type_decl::{type_decl, get_qualified_name,
get_pretty_representation}): Adjust.
(is_real_type): Define new function.
(is_integral_type): Use the new is_real_type.
2024-07-08 Dodji Seketeli <dodji@redhat.com>
ir: Don't strip typedefs from parms and return type when comparing fns
* src/abg-ir.cc (equals): In the overloads from function_type and
function_decl::parameter, do not strip typedefs off of types
becore comparing them.
* tests/data/test-abidiff-exit/PR30329/PR30329-report-1.txt:
Adjust.
* tests/data/test-abidiff-exit/PR30503/libsdl/libsdl-1.2.60-1.2.64-report.txt:
Adjust.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-1.txt:
Adjust.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-2.txt:
Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-diff-dwarf/test2-report.txt: Adjust.
* tests/data/test-diff-filter/test3-report.txt: Adjust.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt:
Adjust.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
2024-07-05 Dodji Seketeli <dodji@redhat.com>
reader: Fix building of variadic parameter type
* src/abg-ir-priv.h (type_topo_comp::operator()): Do not compare
types using their location anymore. It's unnecessary (now that
types are sorted before canonicalization) and it wreaks havoc with
the new properly constructed variadic parameter types.
* src/abg-reader.cc (build_ir_node_for_variadic_parameter_type):
Define new function. Add variadic parameter type to the global
scope of the current translation unit.
(build_function_parameter, build_type_decl): Use the new
build_ir_node_for_variadic_parameter_type.
* tests/data/test-read-write/test17.xml: Adjust.
* tests/data/test-read-write/test19.xml: Likewise.
* tests/data/test-read-write/test20.xml: Likewise.
* tests/data/test-read-write/test21.xml: Likewise.
* tests/data/test-read-write/test22.xml: Likewise.
* tests/data/test-read-write/test23.xml: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
* tests/data/test-read-write/test26.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2024-07-05 Dodji Seketeli <dodji@redhat.com>
reader: Fix building of void and void pointer types
* src/abg-reader.cc (build_ir_node_for_void_pointer_type)
(build_ir_node_for_void_type): Add the type to its scope and
schedule it for canonicalization just once.
2024-07-05 Dodji Seketeli <dodji@redhat.com>
reader: Simplify logic of get_or_read_and_add_translation_unit
* src/abg-reader.cc (get_or_read_and_add_translation_unit):
Simplify logic.
2024-07-05 Dodji Seketeli <dodji@redhat.com>
reader: Simplify type canonicalization invocation
* src/abg-reader.cc (reader::maybe_canonicalize_type): Remove.
(reader::schedule_type_for_canonicalization): Do not schedule
nullptr types for canonicalization.
(reader::perform_type_canonicalization): Rename
perform_late_type_canonicalizing into this.
(reader::{read_corpus, build_or_get_type_decl}): Adjust call to
maybe_canonicalize_type into schedule_type_for_canonicalization.
(read_translation_unit_from_file)
(read_translation_unit_from_buffer, read_translation_unit)
(build_function_decl, build_ir_node_for_void_type)
(build_array_type_def, build_ir_node_for_void_pointer_type)
(build_class_decl, build_union_decl)
(build_class_tdecl, build_type_tparameter, build_type_composition)
(build_template_tparameter, build_type, handle_type_decl)
(handle_qualified_type_decl, handle_pointer_type_def)
(handle_reference_type_def, handle_function_type)
(handle_array_type_def, handle_enum_type_decl)
(handle_typedef_decl, handle_class_decl, handle_union_decl):
Likewise.
2024-07-05 Dodji Seketeli <dodji@redhat.com>
reader: Fix corpus group reading
* src/abg-fe-iface.cc (fe_iface::priv::initialize): Do not clear
the corpus group upon initialization.
* src/abg-reader.cc (reader::initialize): Define new function.
Make it call fe_iface::initialize.
(reader::clear_per_corpus_data): Remove.
(reader::read_corpus): Remove call to clear_per_corpus_data.
(reader::read_corpus_group_from_input): After calling
reader::read_corpus and adding the resulting corpus to the group,
get the next sibling XML element node. If it's an "abi-corpus"
node then re-initialize the reader by invoking the new
reader::initialize and move on to read it by invoking
reader::read_corpus again.
* tests/data/test-diff-suppr/test45-abi-report-1.txt: Adjust.
2024-07-10 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Fix analyzing single kernel binaries
* src/abg-ctf-reader.cc (reader::slurp_elf_info): Do not crash on
a kernel binary that has no CTF section because the CTF
information is in a .ctfa file in the same directory.
(reader::read_corpus): Support loading a CTF archive for a single
kernel binary. Also, support loading the CTF archive from the CTF
sections in the binary itself not necessarily from a .ctfa file in
the same directory.
2024-06-28 Dodji Seketeli <dodji@redhat.com>
ctf-reader: During re-initialization, only clear canonicalize-able types
* src/abg-ctf-reader.cc (reader::types_to_canonicalize): Add data
member.
(reader::add_type): Add the new type to the vector of types to be
canonicalized. Update comment.
(reader::canonicalize_all_types): Now that the reader maintains
the vector of types to be canonicalized, just pass that vector to
canonicalize_types. reader::types_map contains all the types that
have been created in all the binaries processed by this reader so
far. Many of these types have already been canonicalized at the
end of the analysis of binaries that have already been processed.
Only the types created during the processing of the current binary
have not yet be canonicalized and reader::types_to_canonicalize is
where they are maintained. So reader::types_map should be left
alone by this function.
(reader::initialize): Do not close the CTF archive here. Do not
clear reader::{types_map, corpus_group} either.
(reader::read_corpus): Use nullptr, not NULL. Make sure to not
re-open an archive that has already been opened.
(reader::~reader): Mark a closed archive. This is more cosmetic
than anything else.
2024-07-15 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Do not set data member offsets for unions
* src/abg-ctf-reader.cc (process_ctf_sou_members): Do not set any
union data member offset.
2024-07-09 Dodji Seketeli <dodji@redhat.com>
corpus: Support adding translation units with empty path
* src/abg-corpus.cc (corpus::add): Do not require that the path of
the translation unit be non-empty.
2024-07-15 Dodji Seketeli <dodji@redhat.com>
tools-utils,btf-reader: Take modules into account for corpus group
*type* with libabigail IR artifact.
With this changes, abidw can now analyze and emit the ABIXML for a
linux kernel tree in 28 seconds, using BTF. It can self-compare a
kernel tree in 36 seconds.
* src/abg-btf-reader.cc (btf_type_to_abi_artifact_map_type):
Rename btf_type_id_to_abi_artifact_map_type into this. Make it
associate a btf_type* to a libabigail IR, rather than a type ID to
a libabigail IR.
(reader::{base_btf_handle_, base_btf_file_name_,
split_btf_handle_, split_btf_file_name_, split_btfs_to_free_}):
Define new data members.
(reader::{btf_handle_}): Remove.
(reader::base_btf_handle): Renamed btf_handle into this. Create
the BTF object using btf__parse. Store the name of the binary
into reader::base_btf_file_name_.
(reader::read_split_btf): Define new member function.
(reader::btf_handle): This is new code for an existing member
function name. Return the current split BTF object handle if
applicable, otherwise create the base BTF object handle.
(reader::btf_type_to_artifacts_): Renamed
btf_type_id_to_artifacts into this.
(reader::associate_artifact_to_btf_type): Renamed
associate_artifact_to_btf_type_id into this.
(reader::schedule_type_for_canonicalization): Do not schedule a
type that has already been canonicalized.
(reader::nr_btf_types): Take a BTF* parameter.
(reader::~reader): Free all the allocated split BTF objects.
(reader::read_debug_info_into_corpus): If we are looking at a
split BTF, then set the first type ID as the one right after the
last type ID of the base BTF.
(reader::build_ir_node_from_btf_type): Clean-up the logic for
building type void type.
(reader::{build_ir_node_for_void_type,
build_ir_node_for_void_pointer_type,
build_ir_node_for_variadic_parameter_type,
build_enum_underlying_type, build_array_type}): Schedule type for
canonicalization at the end of the IR construction, not right
away.
* src/abg-tools-utils.cc (create_best_elf_based_reader): Pass
show_all_types and linux_kernel_mode arguments to
btf::create_reader.
2024-07-09 Dodji Seketeli <dodji@redhat.com>
elf-based-reader: Clean up logic of elf_based_reader::read_and_add_corpus_to_group
* src/abg-elf-based-reader.cc
(elf_based_reader::read_and_add_corpus_to_group): Fix logic.
2024-07-09 Dodji Seketeli <dodji@redhat.com>
ir: Fix a potential crash in canonicalize_types
* src/abg-ir-priv.h (canonicalize_types): Avoid crashing when
de-referencing an iterator to a nullptr type.
2024-07-10 Ross Burton <ross.burton@arm.com>
configure.ac: improve fts checks
* configure.ac: Use AC_SEARCH_LIBS to look for fts_open in libc
and in libfts if necessary. Remove the use of FTS_LIBS which is
now unnecessary.
* src/Makefile.am: Do not use FTF_LIBS as it's now unnecessary.
* tools/Makefile.am: Likewise.
2024-06-21 Dodji Seketeli <dodji@redhat.com>
btf-reader: Add missing data members reset to reader::initialize
* src/abg-btf-reader.cc (btf::reader::initialize): Clear
types_to_canonicalize_, btf_type_id_to_artifacts_ and cur_tu_.
2024-06-21 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix reader::initialize to clear per corpus data
* src/abg-dwarf-reader.cc (reader::initialize): Call
clear_per_corpus_data.
(reader::read_debug_info_into_corpus): Remove the call to
clear_per_corpus_data from here.
2024-06-21 Dodji Seketeli <dodji@redhat.com>
ir: Cache the pretty representation used during pre-canonicalization type sorting
* include/abg-ir.h (decl_base::get_cached_pretty_representation):
Declare new member function.
* src/abg-ir-priv.h ({type,decl}_topo_comp::operator()): Use
{type,decl}_base::get_cached_pretty_representation instead of
get_pretty_representation.:
* src/abg-ir.cc (decl_base::priv::{internal_cached_repr_,
cached_repr}): Define new data members.
(decl_base::get_cached_pretty_representation):
Define new member function.
(type_base::get_cached_pretty_representation): Cache pretty
representation even for non-canonicalized types. Fix comments.
2024-06-21 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Fix re-initialization of the CTF reader
* src/abg-ctf-reader.cc (reader::reader): Initialize ctfa,
ctf_sect, symtab_sect and strtab_sect data members.
(reader::initialize): In the overload taking no argument, make
sure to free the ctfa data member before setting it to nullptr.
In the overload that takes arguments, make sure to invoke
reader::initialize() to really free the data used. Also, improve
the comments.
2024-06-19 Claudiu Zissulescu <claudiu.zissulescu-ianculescu@oracle.com>
ctf-reader: Add time logging to CTF reader
* src/abg-ctf-reader.cc (do_log()): Getter of the do_log flag.
(read_corpus()): Add time logging.
2024-06-19 Claudiu Zissulescu <claudiu.zissulescu-ianculescu@oracle.com>
ctf-reader: Optimize calling sorting function for functions and variables.
* abg-ctf-reader.cc (process_ctf_archive()): Move
canonicalize_all_types(), sort_functions() and sort_variables()...
(read_corpus()): ...here, just after calling process_ctf_archive().
2024-06-12 Romain Geissler <romain.geissler@amadeus.com>
leaf-reporter: Fix build with gcc 4.9.
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
overload for corpus_diff, avoid using auto type deduction in
for-each loop.
2024-05-31 Dodji Seketeli <dodji@redhat.com>
btf-reader: Fix re-use of the BTF reader for several binaries in a row
* src/abg-btf-reader.cc (reader::initialize): Free the btf handle
first thing as part of the re-initialization.
(reader::~reader): Once the BTF handle has been freed, set it to
nil to show that it's been deleted.
(reader::read_debug_info_into_corpus): If no BTF handle could be
retrieved then it means no BTF data was found on the binary.
Thus, return an empty corpus.
2024-05-31 Dodji Seketeli <dodji@redhat.com>
abidw: make the --lt option support --btf
* tools/abidw.cc (load_kernel_corpus_group_and_write_abixml):
Support --btf.
2024-05-31 Dodji Seketeli <dodji@redhat.com>
tools-utils.cc: Support collecting kernel binary paths build from sources
* src/abg-tools-utils.cc (get_binary_paths_from_kernel_dist): Look
for kernel modules under the root directory by default.
2024-05-31 Dodji Seketeli <dodji@redhat.com>
Bug 31793 - tools-utils: Avoid endless loop in is_regular_file for directories
* src/abg-tools-utils.cc (is_regular_file): Loop on symbolic links
only.
2024-05-15 Dodji Seketeli <dodji@redhat.com>
{btf,dwarf,ctf,abixml}-reader: Fix size of subrange type
* by the size of the base type designated by the DW_AT_type
attribute.
* or by the DW_AT_byte_size or DW_AT_bit_size attribute that might
be present on the DIE.
That is different from the length property carried by the subrange
type.
The patch updates the four front-rends (DWARF, BTF, CTF and ABIXML) to
fix the setting process of the size of the subrange type and adjusts
the testsuite accordingly.
* src/abg-btf-reader.cc (reader::build_array_type): The size of
the subrange is not defined specifically. Let's set it to the
default address size of the translation unit.
* src/abg-ctf-reader.cc (build_array_ctf_range): If no basis type
was found, then set the size of the subrange type to the default
address size of the translation unit.
* src/abg-dwarf-reader.cc (build_subrange_type): Consider the
DW_AT_byte_size and DW_AT_bit_size attribute of
DW_TAG_subrange_type if present. Otherwise, if the basis type is
present, its size as the size of the subrange type. Otherwise,
use the default address size of the translation unit as the size
of the subrange type.
* src/abg-ir.cc (array_type_def::subrange_type::subrange_type): If
the underlying (basis) type is present, then use its size as the
size of the subrange type. Otherwise the size is zero.
(array_type_def::subrange_type::set_underlying_type): Update the
size of the subrange when setting a new underlying (basis) type.
* src/abg-reader.cc (build_subrange_type): Read and set the size
of the subrange.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-1.txt:
Adjust.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/GtkAda-gl-2.24.2-29.fc29.x86_64--2.24.2-30.fc30.x86_64-report-0.txt:
Likewise.
2024-05-15 Dodji Seketeli <dodji@redhat.com>
configure: Fix detection of BTF header to enable the BTF front-end
* configure.ac: Use a new HAS_BTF_HEADERS to store the detection
status for the btf.h header. Emit a better notice message when
the BTF header file is found.
Tested-by: Cestmir Kalina <ckalina@redhat.com>
2024-05-10 Dodji Seketeli <dodji@redhat.com>
btf-reader: Ignore BTF nodes that ought to be ignored
* src/abg-btf-reader.cc (build_ir_node_from_btf_type): Ignore and
return nil for node of kind BTF_KIND_DECL_TAG, BTF_KIND_DATASEC,
and BTF_KIND_UNKN. For all other nodes, abort.
# Veuillez saisir le message de validation pour vos
modifications. Les lignes # commençant par '#' seront ignorées, et
un message vide abandonne la validation. # # Sur la branche
master # Votre branche est à jour avec 'origin/master'. # #
Modifications qui seront validées : # modifié :
src/abg-btf-reader.cc # # Fichiers non suivis: #
doc/api/libabigail.doxy.bak # patches/ # prtests/ # #
------------------------ >8 ------------------------ # Ne touchez
pas à la ligne ci-dessus. # Tout ce qui suit sera éliminé.
diff --git a/src/abg-btf-reader.cc b/src/abg-btf-reader.cc
index f22e92bf..67206bb4 100644
--- a/src/abg-btf-reader.cc
+++ b/src/abg-btf-reader.cc
@@ -486,12 +486,16 @@ public:
#ifdef WITH_BTF_KIND_TYPE_TAG
case BTF_KIND_TYPE_TAG/* Type Tag */:
+ break;
#endif
#ifdef WITH_BTF_KIND_DECL_TAG
case BTF_KIND_DECL_TAG/* Decl Tag */:
+ break;
#endif
case BTF_KIND_DATASEC/* Section */:
+ break;
case BTF_KIND_UNKN/* Unknown */:
+ break;
default:
ABG_ASSERT_NOT_REACHED;
break;
2024-05-07 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir: Unify type sorting & sort types before c14n
* src/abg-ctf-reader.cc (reader::canonicalize_all_types): Use a
temporary vector as input for ir::canonicalize_types because it
needs an ordered container as it now sorts types before
canonicalizing them.
* src/abg-dwarf-reader.cc (reader::types_to_canonicalize): Add a
non-const overload for this accessor.
* src/abg-ir-priv.h (compare_using_locations)
(is_ptr_ref_or_qual_type): Add a declaration for these functions
defined in abg-ir.cc.
(struct decl_topo_comp, struct type_topo_comp): Move these here,
from abg-ir.cc.
(canonicalize_types): Sort the types before canonicalizing them.
* src/abg-ir.cc (compare_using_locations): Turn this from static
to non-static, now that it's declared in abg-ir-priv.h.
(struct decl_topo_comp, struct type_topo_comp): Move these into
abg-ir-priv.h.
* src/abg-reader.cc: Include abg-ir-priv.h.
(reader::perform_late_type_canonicalizing): Use
ir::canonicalize_types, rather than canonicalizing types one by
one.
* src/abg-writer.cc: Include abg-ir-priv.h.
(struct type_topo_comp): Remove.
(write_context::sort_types): Use type_topo_comp from abg-ir-priv.h
instead of type_topo_comp that was removed.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2024-05-09 Dodji Seketeli <dodji@redhat.com>
elf-reader: Avoid crashing when looking at non-existing variable symbol
* src/abg-elf-reader.cc (reader::variable_symbol_is_exported): Do
not crash when the symbol we are looking at is non-present.
2024-05-06 Dodji Seketeli <dodji@redhat.com>
Suppress patch file that was wrongly added to the repository
* patches/0001-WIP-Emit-read-undefined-interfaces-to-from-ABIXML.patch:
Remove from the repository.
2024-03-26 Dodji Seketeli <dodji@redhat.com>
test-read-common: Fix error message
* tests/test-read-common.cc (test_task::run_abidw): Fix error
message and emit it to stderr directly.
2024-03-27 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir: Merge member fns of classes
* src/abg-dwarf-reader.cc (reader::{copy_missing_member_functions,
contains_anonymous_class, merge_member_functions_of_classes,
merge_member_functions_in_classes_of_same_names}): Define new
member functions.
(reader::read_debug_info_into_corpus): Call the reader::new
merge_member_functions_in_classes_of_same_names.
* src/abg-ir.cc (maybe_adjust_canonical_type): When looking at the
canonical type C of a type T, if they both come from the same
corpus, assert that C has all the member functions of T. This
because the DWARF reader now ensures that all types have the same
name in a given corpus have the same member functions.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2024-05-03 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir: Improve detection of method types & implicit parms
* include/abg-ir.h (method_type::get_is_for_static_method): Add
new method.
* src/abg-dwarf-reader.cc (fn_die_first_parameter_die)
(member_fn_die_has_this_pointer, die_peel_typedef): Define new
static functions.
(die_this_pointer_is_const): Make this support DIEs representing
const pointers.
(die_function_type_is_method_type): Use the new
member_fn_die_has_this_pointer function rather than (wrongly) open
coding its functionality. If the (member) function DIE has no
this pointer DIE and if the function is at class scope, then we
are looking a static member function.
(finish_member_function_reading): Use the new
method::get_is_for_static_method method rather than open-coding
its functionality.
* src/abg-ir.cc (method_type::get_is_for_static_method): Define
new method.
(type_topo_comp::operator()): In this comparison
operator for types, if two method types have the same string
representation then if one method type is for a static method,
then make the non-static method type come first.
(function_type::get_first_non_implicit_parm): The first parameter
of a function can only carry the "this pointer" if it's
artificial.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-1.txt:
Adjust.
* tests/data/test-abidiff/test-struct1-report.txt: Likewise.
* tests/data/test-abidiff/test-struct1-v0.cc.bi: Likewise.
* tests/data/test-abidiff/test-struct1-v1.cc.bi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2024-03-26 Dodji Seketeli <dodji@redhat.com>
writer: Fix control of emitting parm names in function types
* src/abg-writer.cc (write_function_type): Control emitting of
parameter names with the write_context::get_write_parameter_names
property.
* tests/test-annotate.cc (main): Do not emit function parameter
names.
* tests/test-read-dwarf.cc (main): Likewise.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2024-05-03 Dodji Seketeli <dodji@redhat.com>
ir: Make IR node visitor aware of non-canonicalized types
* src/abg-ir.cc (ir_node_visitor::{mark_type_node_as_visited,
type_node_has_been_visited}): Invoke is_non_canonicalized_type to
know if we should expect a type to have a canonical type or not.
2024-04-26 Dodji Seketeli <dodji@redhat.com>
ir,writer: Fix function type naming & fn type annotation in ABIXML
* src/abg-ir.cc (get_function_type_name, get_method_type_name):
Use get_type_name in lieu of get_pretty_representation.
* src/abg-writer.cc (annotate): In the overload for function_type,
use get_function_name instead of open coding function type
representations.
* tests/data/test-annotate/test-pointer-to-member-1.o.annotated.abi: Adjust.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt: Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
2024-04-19 Sam James <sam@gentoo.org>
tests/runtestabidb?.sh.in: Use bash shebang
* tests/runtestabidb[1-2].sh.in: Use bash shebang.
2024-04-29 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: Cleanup output of ABI comparison
* tools/fedabipkgdiff: Adjust copyright year
(abipkgdiff): Strip out trailing spaces from the stdout
string. Emit a clear message when no ABI change was found.
* tests/data/test-fedabipkgdiff/test0-from-fc20-to-fc23-dbus-glib-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test1-from-fc20-to-dbus-glib-0.106-1.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test2-dbus-glib-0.100.2-2.fc20--dbus-glib-0.106-1.fc23-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test3-dbus-glib-0.100.2-2.fc20.i686--dbus-glib-0.106-1.fc23.i686-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test4-glib-0.100.2-2.fc20.x86_64.rpm-glib-0.106-1.fc23.x86_64.rpm-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test5-same-dir-dbus-glib-0.100.2-2.fc20.x86_64--dbus-glib-0.106-1.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test6-nss-util-3.12.6-1.fc14.x86_64--nss-util-3.24.0-2.0.fc25.x86_64-report-0.txt:
Adjust.
* tests/data/test-fedabipkgdiff/test7-self-compare-from-fc23-dbus-glib-report-0.txt:
Adjust.
2024-04-26 Frank Ch. Eigler <fche@redhat.com>
configure,abidb: Make the libarchive python module optional for abidb
* configure.ac: Detect the libarchive python module as an optional
dependency for the abidb program. So far, only the git python
module remains a hard dependency.
* tools/abidb (main): Do not support the '--archive' command line
option if the libarchive python module is not present.
2024-04-26 Dodji Seketeli <dodji@redhat.com>
Update Copyright for year 2024
* update-copyright.sh: Update the date in this script. Running
the script then yields the changes below.
* include/abg-btf-reader.h: Update copyright year as a result of
running update-copyright.sh above.
* include/abg-comp-filter.h: Likewise.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-ctf-reader.h: Likewise.
* include/abg-cxx-compat.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-elf-based-reader.h: Likewise.
* include/abg-elf-reader.h: Likewise.
* include/abg-fe-iface.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-btf-reader.cc: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-ctf-reader.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-elf-based-reader.cc: Likewise.
* src/abg-elf-helpers.cc: Likewise.
* src/abg-elf-helpers.h: Likewise.
* src/abg-elf-reader.cc: Likewise.
* src/abg-fe-iface.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-regex.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-symtab-reader.cc: Likewise.
* src/abg-symtab-reader.h: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-cxx-compat.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-dot.cc: Likewise.
* tests/test-elf-helpers.cc: Likewise.
* tests/test-ini.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-kmi-whitelist.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-btf.cc: Likewise.
* tests/test-read-ctf.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-svg.cc: Likewise.
* tests/test-symtab-reader.cc: Likewise.
* tests/test-symtab.cc: Likewise.
* tests/test-tools-utils.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/fedabipkgdiff: Likewise.
* tools/kmidiff.cc: Likewise.
2024-04-22 Dodji Seketeli <dodji@redhat.com>
configure.ac: Update version to 2.6
* configure.ac: Update version to 2.6
2024-04-18 Dodji Seketeli <dodji@redhat.com>
{ctf,btf}-reader: Document the namespace for nicer apidoc
* include/abg-btf-reader.h (namespace btf): Add doxygen comment.
Just adding it to the *.cc won't cut it, I am not sure why.
* include/abg-ctf-reader.h (namespace ctf): Likewise.
* src/abg-btf-reader.cc (namespace btf): Add doxygen comment.
* src/abg-ctf-reader.cc (namespace ctf): Add doxygen commit.
(create_reader, reset_reader): Fix doxygen comments.
2024-04-18 Dodji Seketeli <dodji@redhat.com>
doc/api/libabigail.doxy: Update to newer version.
* doc/api/libabigail.doxy: Update using doxygen -u.
2024-04-18 Dodji Seketeli <dodji@redhat.com>
doc/website/mainpage.txt: Update for 2.5 release
* doc/website/mainpage.txt: Update for 2.5 release
2024-04-17 Dodji Seketeli <dodji@redhat.com>
ChangeLog: Update for 2.5 release
* ChangeLog: Update for 2.5 release by running the "make
update-changelog" command.
2024-04-17 Dodji Seketeli <dodji@redhat.com>
NEWS: Update for 2.5 release
* NEWS: Update for the 2.5 release with the command git
shortlog libabigail-2.4..HEAD.
2024-04-18 Dodji Seketeli <dodji@redhat.com>
configure: Add option to disable abidb
* configure.ac: Add a --disable-abidb option to configure to
disable the abidb tool and related tests.
2024-04-17 Dodji Seketeli <dodji@redhat.com>
tests/runtestabidb?.sh.in: Fix git initialization
* tests/runtestabidb[1-2].sh.in: Initialize email & user name
for the local git repository.
2024-04-15 Dodji Seketeli <dodji@redhat.com>
Bug 31646: Fix type suppression tactics for webkit2gtk3
* default.abignore: Split the libwebkit2gtk suppression
specification for types whose names match the regexp
^std::.*|WebCore::.*|WebKit::.* into two. One that drops type
with names being ^std::.* and another one that turns type being
WebCore::.*|WebKit::.* into opaque types.
* doc/manuals/libabigail-concepts.rst: Add documentation for the
new special label libabigail::OPAQUE_TYPE_LABEL that transforms
types matching a [suppress_type] into opaque types.
* include/abg-suppression.h (is_opaque_type_suppr_spec): Renamed
is_private_type_suppr_spec into this.
(get_opaque_types_suppr_spec_label): Renamed
get_private_types_suppr_spec_label.
* src/abg-comparison.cc (diff::is_suppressed): Adjust.
* src/abg-dwarf-reader.cc (type_is_suppressed): Adjust. Change the
name of the type_is_private parameter into type_is_opaque.
(get_opaque_version_of_type): Do not return early if the type has
no associated location. What was I thinking.
(build_ir_node_from_die): For enums, struct and classes adjust
call to type_is_suppressed.
* src/abg-suppression.cc (type_suppression::suppresses_diff):
Adjust to using is_opaque_type_suppr_spec and
get_opaque_version_of_type in lieu of is_private_type_suppr_spec
and get_private_types_suppr_spec_label.
(get_opaque_types_suppr_spec_label): Rename
get_private_types_suppr_spec_label into this. Also, rename the
name of the special label that specifies opaque types from
"Artificial private types suppression specification" to
"libabigail::OPAQUE_TYPE_LABEL".
(is_opaque_type_suppr_spec): Rename is_private_type_suppr_spec
into this.
(is_type_suppressed): Rename the "type_is_private" parameter into
"type_is_opaque".
* src/abg-tools-utils.cc (handle_file_entry): Adjust to using
get_opaque_types_suppr_spec_label rather than
get_private_types_suppr_spec_label.
* tools/abipkgdiff.cc (compare): Use the supprs variable where all
the suppression specifications got accumulated, not just the
priv_types_supprs1.
(compare_to_self): Add a suppression specifications variable for
private types. Add those private types specs to the user-provided
ones.
* tools/fedabipkgdiff (abipkgdiff): In the self comparison mode,
take into account devel packages and suppression specifications.
Pass those to the abipkgdiff tool's invocation.
* tests/data/test-diff-suppr/PR31646/test-PR31646-result-[1-3].txt:
New reference test output files.
* tests/data/test-diff-suppr/PR31646/test-PR31646-v{0,1}.cc:
Source code of binary inputs below.
* tests/data/test-diff-suppr/PR31646/test-PR31646-v{0,1}.o: Binary
input files.
* tests/data/test-diff-suppr/PR31646/test-PR31646.2.abignore:
Suppression specification file.
* tests/data/test-diff-suppr/PR31646/test-PR31646.abignore:
Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
to this harness.
2024-04-03 Dodji Seketeli <dodji@redhat.com>
Bug 29160 - support fn symbol aliasing a var symbol
* src/abg-reader.cc (typedef string_strings_map_type): Define new
typedef.
(resolve_symbol_aliases): Define new function.
(build_elf_symbol_db): Add two new parameters to carry unresolved
function and variable symbol aliases. When a symbol alias can't
resolve to any of the symbols of its kind (function or variable)
then stage the alias away in the set of unresolved aliases. That
set is then going to be resolved later.
(read_symbol_db_from_input): Add two new parameters to carry
unresolved function and variable symbol aliases. Pass them down
to build_elf_symbol_db.
(reader::read_corpus): Adjust the invocation of
read_symbol_db_from_input to get the sets of unresolved function &
variable symbol aliases. Invoke the new resolve_symbol_aliases
the unresolved function & variable aliases.
* tests/data/test-diff-pkg/PR29610/guestfs-tools-1.51.6-2.el9.s390x-self-check-report.txt:
New test reference output.
* tests/data/test-diff-pkg/PR29610/guestfs-tools-1.51.6-2.el9.s390x.rpm:
New binary test input.
* tests/data/test-diff-pkg/PR29610/guestfs-tools-debuginfo-1.51.6-2.el9.s390x.rpm:
Likewise.
* tests/data/Makefile.am: Add this new test material to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test input to
this test harness.
2024-04-03 Dodji Seketeli <dodji@redhat.com>
Bug 31513 - Fix fallout of initial patch
* src/abg-comp-filter.cc (has_subtype_changes): Reset s_member in
the loop, just like f_member.
* tests/data/test-abidiff-exit/PR31513/non-regr/report1.txt: Adjust.
* tests/data/test-abidiff-exit/PR31513/non-regr/report2.txt: Adjust.
* tests/test-abidiff-exit.cc (in_out_specs): Adjust.
2024-03-29 Dodji Seketeli <dodji@redhat.com>
comparison: Fix erroneous detection of deleted anonymous data members
* src/abg-comparison.cc
(class_or_union_diff::ensure_lookup_tables_populated): If leaf
data members of an anonymous data member are still present in the
new version of the class, then the anonymous data member cannot be
considered as being removed from the second version of the class.
* tests/data/test-abidiff-exit/non-del-anon-dm/non-regr/report0.txt:
Reference test output.
* tests/data/test-abidiff-exit/non-del-anon-dm/non-regr/test0-v{0,1}.c:
Source code of the binary input below.
* tests/data/test-abidiff-exit/non-del-anon-dm/non-regr/test0-v{0,1}.o:
New binary test input.
* tests/data/test-abidiff-exit/non-del-anon-dm/reported/binaries-origin.txt:
File mentioning the origin of the reported binary.
* tests/data/test-abidiff-exit/non-del-anon-dm/reported/librte_graph.so.24.{0,1}:
Binary test input.
* tests/data/test-abidiff-exit/non-del-anon-dm/reported/report0.txt:
Reference test output.
* tests/data/Makefile.am: Add the test material above to source
distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add test material
above to this harness.
2024-03-28 Dodji Seketeli <dodji@redhat.com>
Bug 31513 - abidiff considers data members moved to base class as harmful
* include/abg-comparison.h (typedef string_decl_base_sptr_map):
Move this typedef to include/abg-fwd.h:
(HARMLESS_UNION_OR_CLASS_CHANGE_CATEGORY): Inside the enum
diff_category, rename the enumerator
HARMLESS_UNION_CHANGE_CATEGORY into this.
(EVERYTHING_CATEGORY): Adjust this enum to refer to
HARMLESS_UNION_OR_CLASS_CHANGE_CATEGORY, no more HARMLESS_UNION_CHANGE_CATEGORY
* include/abg-fwd.h (typedef string_decl_base_sptr_map): Move this
typedef here from abg-comparison.h
(collect_non_anonymous_data_members): Declare new function.
* src/abg-comp-filter.cc (has_offset_changes)
(type_has_offset_changes, has_offset_changes)
(has_subtype_changes, class_diff_has_only_harmless_changes):
Define new static functions.
(base_classes_removed): Rename base_classes_added_or_removed into
this and update comment.
(categorize_harmless_diff_node): Changes that were categorized as
HARMLESS_UNION_CHANGE_CATEGORY is now categorized as
HARMLESS_UNION_OR_CLASS_CHANGE_CATEGORY. Also, a diff that
satisfies either union_diff_has_harmless_changes or
class_diff_has_only_harmless_changes is categorized as
HARMLESS_UNION_OR_CLASS_CHANGE_CATEGORY.
(categorize_harmful_diff_node): Adjust to invoke
base_classes_removed instead of base_classes_added_or_removed. An
added base class doesn't necessarily qualifies as a harmful change
anymore. Rather, a diff node that carries an offset change as
detected by type_has_offset_changes is categorized as
SIZE_OR_OFFSET_CHANGE_CATEGORY.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Adjust to use
abigail::comparison::HARMLESS_UNION_OR_CLASS_CHANGE_CATEGORY
rather than abigail::comparison::HARMLESS_UNION_CHANGE_CATEGORY.
(operator<<(ostream& o, diff_category c)): Likewise.
(class_diff::ensure_lookup_tables_populated): Detect data members
that are moved into base classes to avoid considering those data
members as being removed from the class.
* src/abg-default-reporter.cc (default_reporter::report): Adjust
to use HARMLESS_UNION_OR_CLASS_CHANGE_CATEGORY rather than
HARMLESS_UNION_CHANGE_CATEGORY.
* src/abg-ir.cc (collect_non_anonymous_data_members): Define
function overloads.
* tests/data/test-abidiff-exit/PR31513/non-regr/libtest[1-4]-v{0,1}.so:
New binary test input files.
* tests/data/test-abidiff-exit/PR31513/non-regr/report[1-4.txt:
New reference output files.
* tests/data/test-abidiff-exit/PR31513/non-regr/test[1-4]-v{0,1}.cc:
Source code of the binary input files above.
* tests/data/test-abidiff-exit/PR31513/reported/PR31513-reported-report-{1,2}.txt:
New reference output files.
* tests/data/test-abidiff-exit/PR31513/reported/libloremipsum_gcc{7,11}.so:
New binary test input files.
* tests/data/test-abidiff-exit/PR31513/reported/libstdcpp.suppr:
New test suppression file.
* tests/data/Makefile.am: Add new test files above to source
distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new input
test files to this test harness.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
2024-03-28 Dodji Seketeli <dodji@redhat.com>
abidiff: Fix indentation of help string
* tools/abidiff.cc (display_usage): Fix indentation of help string
2024-03-29 Dodji Seketeli <dodji@redhat.com>
suppression: Fix indentation
* src/abg-suppression.cc
(function_suppression::suppresses_function_symbol): Fix
indentation.
2024-03-28 Dodji Seketeli <dodji@redhat.com>
comparison: Fix typo
* src/abg-comparison.cc
(class_or_union_diff::ensure_lookup_tables_populated): Fix a
comment typo.
2024-03-28 Dodji Seketeli <dodji@redhat.com>
ir: Fix Emacs C++ mode header
* src/abg-ir.cc: Fix the Emacs C++ mode header.
2024-03-22 Frank Ch. Eigler <fche@redhat.com>
abidb: drop the TODO items from the python script
* tools/abidb: drop the TODO items from the python script
2023-12-05 Frank Ch. Eigler <fche@redhat.com>
abidb: Introduce a tool to manage the ABI of a Linux distribution
* configure.ac: Condition building abidb on the presence of python
and the required modules.
* doc/manuals/Makefile.am: Add the abidb.rst documentation to
source distribution. Distribute the abidb.1 manpage file as well.
* doc/manuals/abidb.rst: New documentation file.
* doc/manuals/conf.py: Configure the generation of the abidb.1
manage from the abidb.rst file above.
* doc/manuals/libabigail-tools.rst: Add a reference to the new
abidb tool.
* tests/Makefile.am: Register runabidb1.sh and runabidb2.sh as
tests for abidb. Register runabidb1.sh.in and runabidb2.sh.in as
input files for autoconf generated runabidb1.sh and runabidb2.sh.
* tests/data/Makefile.am: Add abidb2client.c, abidb2so.c and
abidb2soBAD.c to source distribution.
* tests/data/abidb2client.c: New source file for test input binaries.
* tests/data/abidb2so.c: Likewise.
* tests/data/abidb2soBAD.c: Likewise.
* tests/runtestabidb1.sh.in: New test script input for autoconf generation.
* tests/runtestabidb2.sh.in: Likewise.
* tools/Makefile.am: Add the new abidb tool to the set of tools.
* tools/abidb: The New Tool, ladies and gentlemen!
2024-03-15 Dodji Seketeli <dodji@redhat.com>
abicompat: Fix exit code in weak mode
* tools/abicompat.cc (perform_compat_check_in_weak_mode): Do not
override the status code when doing the comparison in the reverse
direction.
(compare_expected_against_provided_functions)
(compare_expected_against_provided_variables): Set the status code
close to the detected diff. In the future, this might help us
provide finer grained status.
* tests/test-abicompat.cc (InOutSpec::status): Add a new data
member to represent the expected exit code.
(in_out_specs): Adjust the array of tests.
(main): If the actual exit code is different from the expected
one, then the test failed so let's report it.
2024-03-08 Dodji Seketeli <dodji@redhat.com>
Emit & read undefined interfaces to & from ABIXML
* include/abg-writer.h (set_write_undefined_symbols): Declare new
function.
(set_common_options): Use the new set_write_undefined_symbols in
this function template.
* src/abg-dwarf-reader.cc (reader::{get_die_language, die_is_in_c,
die_is_in_cplus_plus, die_is_in_c_or_cplusplus}): Move these
member functions into ...
(get_die_language, die_is_in_c, die_is_in_cplus_plus)
(die_is_in_c_or_cplusplus): ... these static non-member functions.
(fn_die_equal_by_linkage_name): Adjust and remove the now useless
reader parameter.
(compare_dies, get_scope_die, function_is_suppressed)
(variable_is_suppressed): Adjust.
(build_translation_unit_and_add_to_ir): When we are asked to load
undefined symbol, make sure to also analyze top-level class types
and if we are in C++, also analyze top-level unions and structs as
these might also have some undefined interfaces.
* src/abg-reader.cc (build_elf_symbol_db): Let's not construct and
return the symbol DB anymore. Rather, let's let the caller
construct it, so we can just update it with the input gathered.
(read_symbol_db_from_input): Support getting undefined function
and variable symbols from the new undefined-elf-function-symbols
and undefined-elf-variable-symbols elements. Note that undefined
and defined function symbols go into the same symbol DB whereas
undefined and defined variable symbols go into another symbol DB.
Now, we suppose that the variable & symbol DBs are allocated by
the caller. We pass it down to build_elf_symbol_db that populates
it. Maybe we should rename build_elf_symbol_db into
populate_elf_symbol_db.
(reader::read_corpus): Allocate the function
and variable symbol DB and let read_symbol_db_from_input populate
it. Sort functions and variables after reading the whole ABIXML.
* src/abg-writer.cc (write_context::write_context): Define new
data member.
(write_context::write_context): Initialize it.
(write_context::{get,set}::write_undefined_symbols): Define
accessors.
(set_write_undefined_symbols): Define a new function.
(write_context::decl_is_emitted): Add a new overload.
(write_elf_symbol_reference): Add a writer context and a corpus
parameter. If the symbol is not in the corpus or if the symbol is
undefined and we were not asked to emit undefined symbols then do
not emit any reference to it.
(write_translation_unit): Emit the undefined functions and
variables that belong to the current translation unit, along with
their reference to the undefined ELF symbol they are associated
to.
(write_var_decl, write_function_decl): Let
write_elf_symbol_reference decide whether it should emit the
reference to ELF symbol or not, as it now know how to make that
decision.
(write_corpus): Write the undefined function & variable ELF symbol
data bases. These in the new 'undefined-elf-function-symbols' and
'undefined-elf-variable-symbols' elements.
* tools/abidw.cc (options::load_undefined_interfaces): Define new
data member.
(options:options): Initialize it.
(display_usage): Add a help string for the
--no-load-undefined-interfaces option.
(parse_command_line): Parse the --no-load-undefined-interfaces
option.
(set_generic_options): Set the
fe_iface::option_type::load_undefined_interfaces option.
* doc/manuals/abidw.rst: Document the new
--no-load-undefined-interfaces of abidw.
* tests/data/test-abicompat/test10/libtest10-with-exported-symbols.so:
New binary input file.
* tests/data/test-abicompat/test10/libtest10-with-incompatible-exported-symbols.so:
New binary input file.
* tests/data/test-abicompat/test10/libtest10-with-incompatible-exported-symbols.so.abi:
New abixml input file.
* tests/data/test-abicompat/test10/test10-app-with-undefined-symbols:
New binary input file.
* tests/data/test-abicompat/test10/test10-app-with-undefined-symbols.abi:
New abixml input file.
* tests/data/test-abicompat/test10/test10-app-with-undefined-symbols.cc:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-fn-changed-report-0.txt:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-fn-changed-report-1.txt:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-fn-changed-report-2.txt:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-fn-changed-report-3.txt:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-fn-changed-report-4.txt:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-with-exported-symbols.cc:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-with-exported-symbols.h:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-with-incompatible-exported-symbols.cc:
New source file for binary test input
* tests/data/test-abicompat/test10/test10-with-incompatible-exported-symbols.h:
New source file for binary test input.
* tests/data/Makefile.am: Add new test input files to source
distribution.
* tests/test-abicompat.cc (in_out_specs): Add the new test inputs
to this test harness.
* tests/test-annotate.cc (main): Use the new
--no-load-undefined-interfaces option of abidw to keep the old
behavior.
* tests/test-read-common.cc (test_task::serialize_corpus): Do not
emit undefined symbols.
* tests/test-read-dwarf.cc (test_task_dwarf::perform): Likewise.
2024-03-12 Dodji Seketeli <dodji@redhat.com>
Add support for undefined symbols in the BTF reader
* doc/manuals/abicompat.rst: Update documentation for the --btf
option of abicompat.
* include/abg-elf-reader.h
(elf::reader::{function,variable}_symbol_is_undefined): Declare
new member functions.
* src/abg-btf-reader.cc
(reader::read_debug_info_into_corpus): Sort functions &
variables after canonicalization.
(reader::build_ir_node_from_btf_type): Always call
fe_iface::add_{fn,var}_to_exported_or_undefined_decls with the
decl that was constructed.
(reader::build_function_decl): Support setting an undefined symbol
to the function decl.
(reader::build_var_decl): Likewise, support setting undefined
symbol the variable decl.
* src/abg-elf-reader.cc
((elf::reader::{function,variable}_symbol_is_undefined): Declare
new member functions.): Define new member functions.
* src/abg-symtab-reader.cc
(symtab::{function,variable}_symbol_is_undefined): Return the
undefined symbol that was found.
* src/abg-symtab-reader.h
(symtab::{function,variable}_symbol_is_undefined): Return an
undefined symbol rather than just a boolean value.
* tools/abicompat.cc: Add support for BTF here.
(options::use_btf): Define new data member ...
(options::options): ... and initialize it.
(display_usage): Add a help string for the --btf option.
(parse_command_line): Parse the --btf option.
* tests/data/test-abicompat/test7-fn-changed-report-0.1.txt: New
reference test output file.
* tests/data/test-abicompat/test7-fn-changed-report-2.1.txt:
Likewise.
* tests/data/test-abicompat/libtest7-fn-changed-libapp-btf-v0.so:
New binary input file.
* tests/data/test-abicompat/libtest7-fn-changed-libapp-btf-v1.so:
Likewise.
* tests/data/test-abicompat/test7-fn-changed-app.btf: Likewise.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-abicompat.cc (in_out_specs): Add the new test input
to the test harness.
* tests/data/test-abicompat/test7-fn-changed-app.c: Adjust.
* tests/data/test-abicompat/test7-fn-changed-libapp-v0.c:
Likewise.
* tests/data/test-abicompat/test7-fn-changed-libapp-v1.c: Likewise
2024-03-12 Dodji Seketeli <dodji@redhat.com>
Factorize elf-reader::{variable,function}_symbol_is_exported into symtab
* src/abg-elf-reader.cc (reader::function_symbol_is_exported): Use
the new symtab::function_symbol_is_exported.
(reader::variable_symbol_is_exported): Use the new
symtab::variable_symbol_is_exported.
* src/abg-symtab-reader.cc
(symtab::{function,variable}_symbol_is_exported): Factorize
elf::reader::{function,variable}_symbol_is_exported into this.
* src/abg-symtab-reader.h
(symtab::{function,variable}_symbol_is_exported): Declare new
member functions.
2024-02-21 Dodji Seketeli <dodji@redhat.com>
Represent undefined corpus interfaces to analyze app compatibility
* include/abg-corpus.h (corpus::{lookup_variable,
get_undefined_functions, get_undefined_variables}): Declare new
member functions.
(corpus::exported_decls_builder::maybe_add_{fn,var}_to_exported_fns):
Make this return a boolean.
* include/abg-fe-iface.h (fe_iface::options_type): Add a new
load_undefined_interfaces enumerator.
(fe_iface::add_fn_to_exported_or_undefined_decls): Rename
maybe_add_fn_to_exported_decls into this.
(fe_iface::add_var_to_exported_or_undefined_decls): Rename
maybe_add_var_to_exported_decls into this.
* src/abg-btf-reader.cc (reader::build_ir_node_from_btf_type):
Adjust call to maybe_add_fn_to_exported_decls as
add_fn_to_exported_or_undefined_decls. Similarly, adjust call to
maybe_add_var_to_exported_decls as
add_var_to_exported_or_undefined_decls.
* src/abg-corpus-priv.h (corpus::priv::undefined_{fns,vars}): Add
new member variables.
* src/abg-corpus.cc
(corpus::exported_decls_builder::maybe_add_{fn,var}_to_exported_fns):
Return a bool iff the decl was added to the set of exported decls.
(corpus::{lookup_variable, get_undefined_functions,
get_undefined_variables}): Define new member functions.
(corpus::sort_{functions,variables}): Sort the undefined decls
too.
* (corpus::lookup_{function,variable}_symbol): Lookup the symbol
also among undefined symbols, not just among defined symbols.
* src/abg-ctf-reader.cc (reader::process_ctf_archive): Adjust call
to maybe_add_fn_to_exported_decls as
add_fn_to_exported_or_undefined_decls. Similarly, adjust call to
maybe_add_var_to_exported_decls as
add_var_to_exported_or_undefined_decls. Also, sort functions &
variables in the corpus.
* src/abg-dwarf-reader.cc (die_name_and_linkage_name): Define new
static function.
(reader::fixup_functions_with_no_symbols): Adjust call to
maybe_add_fn_to_exported_decls as
add_fn_to_exported_or_undefined_decls.
(reader::{is_decl_die_with_undefined_symbol,
load_undefined_interfaces}): Define new member functions.
(build_translation_unit_and_add_to_ir): Analyze DIEs of interfaces
that have undefined symbols if we were asked to load undefined
interfaces.
(variable_is_suppressed): Add a boolean parameter to tell if the
var is decl-only. Use that decl-only flag to determine if the
variable is suppressed. A non-member decl-only variable won't be
suppressed if we were asked to load undefined interfaces.
(build_or_get_var_decl_if_not_suppressed): Add a boolean parameter
to tell if the var is decl-only.
(potential_member_fn_should_be_dropped): A potential non-virtual
member function with no symbol is now dropped on the floor
regardless of it has a mangled name or not.
(build_var_decl): If the var has an undefined symbol, then set
that symbol.
(build_function_decl): If the function has an undefined symbol,
then set that symbol.
(build_ir_node_from_die): Add a var or function with undefined
symbol to the set of undefined vars or functions of the current
corpus.
* src/abg-fe-iface.cc
(fe_iface::add_fn_to_exported_or_undefined_decls): Renamed
fe_iface::maybe_add_fn_to_exported_decls into this. If the
function has an undefined symbol then add the function to the set
of undefined functions.
(fe_iface::add_var_to_exported_or_undefined_decls): Renamed
fe_iface::maybe_add_var_to_exported_decls into this. If the
variable has an undefined symbol then add the variable to the set
of undefined variables.
* src/abg-ir.cc (elf_symbol::is_variable): Undefined symbol with
type STT_NOTYPE are actually for undefined variables.
(maybe_adjust_canonical_type): It's here, after type
canonicalization that a member function is added to either the set
of defined & exported functions, or to the set of functions with
undefined symbols.
* src/abg-reader.cc (build_function_decl, build_class_decl)
(build_union_decl, handle_var_decl): Adjust.
* src/abg-symtab-reader.cc
(symtab::{lookup_undefined_function_symbol,
lookup_undefined_variable_symbol, function_symbol_is_undefined,
variable_symbol_is_undefined,
collect_undefined_fns_and_vars_linkage_names}): Define new member
functions.
(symtab::symtab): Initialize the new
cached_undefined_symbol_names_ data member.
* src/abg-symtab-reader.h
(symtab::{lookup_undefined_function_symbol,
lookup_undefined_variable_symbol, function_symbol_is_undefined,
variable_symbol_is_undefined,
collect_undefined_fns_and_vars_linkage_names}): Declare new member
functions.
(symtab::{undefined_variable_linkage_names_,
cached_undefined_symbol_names_}): Define new data members.
(symtab::load_): Consider undefined symbol of type STT_NOTYPE as
being undefined global variables. It's what I am seeing in ELF
binaries.
* src/abg-symtab-reader.h
(symtab::{lookup_undefined_function_symbol,
lookup_undefined_variable_symbol, function_symbol_is_undefined,
variable_symbol_is_undefined}): Declare new member functions.
(symtab::{undefined_function_linkage_names_,
undefined_variable_linkage_names_}): Define new member variables.
* src/abg-writer.cc (write_var_decl, write_function_decl): Emit a
reference to a symbol only when the symbol is defined.
* tools/abicompat.cc (report_function_changes)
(report_variable_changes)
(compare_expected_against_provided_functions)
(compare_expected_against_provided_variables): Define new static
functions.
(perform_compat_check_in_weak_mode): Use the new static functions
above. Compare interfaces expected by the application corpus
against interfaces provided by the library. Report the changes.
Do that in the reverse direction as well.
(read_corpus): Instruct the corpus reader to load the set of
undefined interfaces too.
* tests/data/test-abicompat/test6-var-changed-app: Remove file.
* tests/data/test-abicompat/test6-var-changed-app.cc: Likewise.
* tests/data/test-abicompat/libtest6-undefined-var.so: Add new
binary input file.
* tests/data/test-abicompat/test6-undefined-var.cc: Add sourcefile
for the binary input file above.
* tests/data/test-abicompat/test6-var-changed-report-2.txt: New
reference output file.
* tests/data/Makefile.am: Update the list of distributed files
accordingly.
* tests/data/test-abicompat/libtest5-fn-changed-libapp-v0.so:
Adjust.
* tests/data/test-abicompat/libtest5-fn-changed-libapp-v1.so:
Likewise.
* tests/data/test-abicompat/libtest6-var-changed-libapp-v0.so:
Likewise.
* tests/data/test-abicompat/libtest6-var-changed-libapp-v1.so:
Likewise.
* tests/data/test-abicompat/libtest7-fn-changed-libapp-v0.so:
Likewise.
* tests/data/test-abicompat/libtest7-fn-changed-libapp-v1.so:
Likewise.
* tests/data/test-abicompat/libtest8-fn-changed-libapp-v0.so:
Likewise.
* tests/data/test-abicompat/libtest8-fn-changed-libapp-v1.so:
Likewise.
* tests/data/test-abicompat/libtest9-fn-changed-v0.so: Likewise.
* tests/data/test-abicompat/libtest9-fn-changed-v1.so: Likewise.
* tests/data/test-abicompat/test5-fn-changed-app: Likewise.
* tests/data/test-abicompat/test6-var-changed-libapp-v0.cc:
Likewise.
* tests/data/test-abicompat/test6-var-changed-libapp-v1.cc:
Likewise.
* tests/data/test-abicompat/test6-var-changed-report-0.txt:
Likewise.
* tests/data/test-abicompat/test6-var-changed-report-1.txt:
Likewise.
* tests/data/test-abicompat/test7-fn-changed-app: Likewise.
* tests/data/test-abicompat/test7-fn-changed-report-1.txt:
Likewise.
* tests/data/test-abicompat/test7-fn-changed-report-2.txt:
Likewise.
* tests/data/test-abicompat/test8-fn-changed-app: Likewise.
* tests/data/test-abicompat/test8-fn-changed-libapp-v1.c:
Likewise.
* tests/data/test-abicompat/test9-fn-changed-app: Likewise.
* tests/data/test-abicompat/test9-fn-changed-app.cc: Likewise.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.ab: Likewise.i
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64--dbus-glib-0.104-3.fc23.armv7hl-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test0-from-fc20-to-fc23-dbus-glib-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test2-dbus-glib-0.100.2-2.fc20--dbus-glib-0.106-1.fc23-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test3-dbus-glib-0.100.2-2.fc20.i686--dbus-glib-0.106-1.fc23.i686-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/vte291-0.39.1-1.fc22.x86_64--vte291-0.39.90-1.fc22.x86_64-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/test-abicompat.cc (in_out_specs): Adjust.
* tests/test-read-ctf.cc (test_task_ctf::perform): Do not load
undefined interfaces, by default.
* tests/test-symtab.cc (Symtab::SimpleSymtabs)
(Symtab::SymtabWithWhitelist, Symtab::AliasedFunctionSymbols):
Adjust the expected undefined variable symbols counts.
2024-03-13 Dodji Seketeli <dodji@redhat.com>
tools-utils.cc: Fix potential crash when testing for CTF debug info
* src/abg-tools-utils.cc (file_has_ctf_debug_info): Do not crash
on empty debug info paths.
2024-03-08 Dodji Seketeli <dodji@redhat.com>
abidw: Add a -o short option for --out-file
* doc/manuals/abidw.rst: Document the -o option.
* tools/abidw.cc (display_usage): Update doc string for the
--out-file|-o option.
(parse_command): Support the -o short option.
2024-03-08 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support creating functions from DW_TAG_inlined_subroutine
* src/abg-dwarf-reader.cc (build_function_decl): Loosen the assert
to accept DW_TAG_inlined_subroutine DIEs.
2024-03-05 Dodji Seketeli <dodji@redhat.com>
ir,dwarf-reader: Peel const-qualifier from const this pointers
* include/abg-fwd.h (is_const_qualified_type)
(peel_const_qualified_type): Declare ...
* src/abg-ir.cc (is_const_qualified_type)
(peel_const_qualified_type): ... new functions.
* src/abg-dwarf-reader.cc (build_function_type): Trim the const
qualifier off of the this pointer representation if present.
* tests/data/test-annotate/test1.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test29-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Likewise.
* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-10.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-12.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-14.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-16.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test31-report-1.txt: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
2024-03-04 Dodji Seketeli <dodji@redhat.com>
comparison: Better sort function difference report
* src/abg-comparison-priv.h (is_less_than): Declare new helper
function.
(function_decl_diff_comp::operator(const function_decl_diff&,
const function_decl_diff&)):
Use it here.
(virtual_member_function_diff_comp::operator(const function_decl_diff&,
const function_decl_diff&)):
Likewise.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-diff-dwarf/test29-vtable-changes-report-0.txt:
Adjust.
* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt:
Adjust.
* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt:
Adjust.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt:
Adjust.
2024-03-04 Dodji Seketeli <dodji@redhat.com>
ir,dwarf-reader: Better handle inline-ness setting or detection
* include/abg-ir.h (function_decl::is_declared_inline): Add a
setter overload.
* src/abg-dwarf-reader.cc (die_is_declared_inline): Take into the
account values DW_INL_declared_inlined and
DW_INL_declared_not_inlined of DW_AT_inline attribute. Not just
DW_INL_declared_inlined.
(finish_member_function_reading): Set the inline-ness declaration
here.
(build_ir_node_from_die): Handle DW_TAG_inlined_subroutine just as
DW_TAG_subprogram.
* src/abg-ir.cc (function_decl::is_declared_inline): Add a setter
overload.
* tests/data/test-annotate/test1.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2024-03-02 Dodji Seketeli <dodji@redhat.com>
tests/data/test-diff-pkg: Update dpkg related reference output
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Adjust.
2024-02-28 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix DIE origin handling & scope getting
* src/abg-dwarf-reader.cc (die_origin_die): New static function.
(get_scope_die, get_scope_for_die): Use the new die_origin_die
above.
(build_ir_node_from_die): Don't handle DW_AT_abstract_origin and
DW_AT_specification here. In general, do not handle getting the
scope. Rather, just rely on get_scope_for_die.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test29-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Likewise.
* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-10.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-12.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-14.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-16.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test31-report-1.txt: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2024-02-27 Dodji Seketeli <dodji@redhat.com>
dwarf-reader, ir: Add member fns to exported corpus fns after c14n
* src/abg-dwarf-reader.cc
(reader::fixup_functions_with_no_symbols): Do not export the
virtual member function here.
(build_ir_node_from_die): For DW_TAG_subprogram DIEs, likewise.
* src/abg-ir.cc (maybe_adjust_canonical_type): Walk the member
functions of the canonical type and export them in the ABI corpus
if they have a defined and exported elf symbol.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2024-02-27 Dodji Seketeli <dodji@redhat.com>
ir: Use linkage name to sort virtual function members
* src/abg-ir.cc (virtual_member_function_less_than::operator()):
Take the linkage name into account during sorting before taking
into account the presence of elf symbols.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2024-02-21 Dodji Seketeli <dodji@redhat.com>
abicompat: Port this to the multi-front-end architecture
* tools/abicompat.cc (read_corpus): Use
abigail::tools_utils::create_best_elf_based_reader to create the
right reader depending on the debug information at hand.
2024-02-20 Dodji Seketeli <dodji@redhat.com>
ir,corpus,comparison: Const-iffy the access to corpus interfaces
* include/abg-comparison.h (typedef string_function_ptr_map): Make
this typedef use a const function_decl*, not just a
function_decl*.
(typedef string_var_ptr_map): Make this typedef use a const
var_decl*, not just a var_decl*.
* include/abg-corpus.h (typedef corpus::functions): Make this
typedef be a vector<const function_decl*>, not just a
vector<function_decl*>.
(corpus::exported_decls_builder::fn_id_maps_to_several_fns):
Adjust declaration to const function_decl*.
* include/abg-fwd.h (typedef istring_var_decl_ptr_map_type)
(typedef istring_function_decl_ptr_map_type): Move these typedefs to
abg-ir.h.
(get_function_id_or_pretty_representation): Use const function_decl*.
* include/abg-ir.h (typedef istring_var_decl_ptr_map_type)
(typedef istring_function_decl_ptr_map_type): Move these here from
abg-fwd.h. Also make these use const var_decl* and const.
function_decl.
* src/abg-comparison-priv.h (sort_string_function_ptr_map)
(sort_string_var_ptr_map): Use vector<const function_decl*> and
vector<const var_decl*> rather than their non-const variants.
* src/abg-comparison.cc (sort_string_function_ptr_map)
(sort_string_var_ptr_map): Likewise.
(corpus_diff::priv::{ensure_lookup_tables_populated,
apply_supprs_to_added_removed_fns_vars_unreachable_types}):
Adjust.
* src/abg-corpus-priv.h (corpus::priv::{fns,vars}): Make these
data members use vector<const function_decl*> and vector<const
var_decl*> types.
* src/abg-corpus.cc
(corpus::exported_decls_builder::fn_id_maps_to_several_fns)
(corpus::maybe_drop_some_exported_decls): Adjust.
(corpus_group::priv::{fns,vars}): Make these data members use
vector<const function_decl*> and vector<const var_decl*> types.
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for const corpus_diff&, adjust.
* src/abg-ir.cc (get_function_id_or_pretty_representation):
Adjust.
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
overload for const corpus_diff&, adjust.
* tools/abicompat.cc (perform_compat_check_in_normal_mode):
Adjust.
2024-02-28 Dodji Seketeli <dodji@redhat.com>
ir: Fix indentation
* src/abg-ir.cc (function_decl::clone): Fix indentation.
2024-02-28 Dodji Seketeli <dodji@redhat.com>
test-abicomat.cc: Don't show details about PASSing tests.
* tests/test-abicompat.cc (main): Don,'t emit details for PASSed
tests.
2024-02-28 Dodji Seketeli <dodji@redhat.com>
test-alt-dwarf-file.cc: Fix test result accounting
* tests/test-alt-dwarf-file.cc (main): Re-set the is_ok variable
to true in the loop.
2024-02-16 Dodji Seketeli <dodji@redhat.com>
ir,{btf,ctf,dwarf}-reader: Rename {subrange_type,array_type_def}::is_infinite.
* include/abg-ir.h
({array_type_def,subrange_type}::is_non_finite): Rename
{array_type_def,subrange_type}::is_infinite into this.
* src/abg-btf-reader.cc (reader::build_array_type): Add a missing
call to subrange_type::is_non_finite.
* src/abg-comp-filter.cc
(is_var_1_dim_unknown_size_array_change):Rename
subrange_type::is_infinite into subrange_type::is_non_finite.
* src/abg-ctf-reader.cc (build_array_ctf_range): Likewise.
* src/abg-dwarf-reader.cc (build_subrange_type): Likewise.
* src/abg-ir.cc (clone_array, has_flexible_array_data_member)
(array_type_def::subrange_type::as_string): Likewise.
({array_type_def,subrange_type}::is_non_finite): Rename
{array_type_def,subrange_type}::is_infinite into this.
* src/abg-reader.cc (build_subrange_type): Rename
subrange_type::is_infinite into subrange_type::is_non_finite.
* src/abg-reporter-priv.cc (report_size_and_alignment_changes):
Likewise.
* src/abg-writer.cc (write_array_size_and_alignment): Likewise.
2024-02-15 Dodji Seketeli <dodji@redhat.com>
btr-reader: Fix wording typo
* src/abg-btf-reader.cc (reader::build_array_type): It's
lower_bound, not lower_boud. Duh.
2024-02-15 Dodji Seketeli <dodji@redhat.com>
PR25409-librte_bus_dpaa.so.20.0.abi: Update to 2.3
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Bump ABIXML version to 2.3.
2024-02-15 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Bug 31377 - Fix the IR for zero length arrays
* src/abg-dwarf-reader.cc (build_subrange_type): In the absence of
DW_AT_upper_bound and DW_AT_lower_bound, make DW_AT_count being
zero the same as if no DW_AT_count is present.
* src/abg-reader.cc (build_subrange_type): Add a comment about how
things were in the past (before this patch) and document the fact
that we want to stay compatible with ABIXML from before this
patch.
* tests/data/test-abidiff-exit/PR31377/flex/include/rte_pipeline.h:
New header file input for this test.
* tests/data/test-abidiff-exit/PR31377/flex/lib64/librte_pipeline.so.24.1:
New binary input for this test.
* tests/data/test-abidiff-exit/PR31377/reference/include/rte_pipeline.h:
New header file input for this test.
* tests/data/test-abidiff-exit/PR31377/reference/lib64/librte_pipeline.so.24.0:
New binary input for this test.
* tests/data/test-abidiff-exit/PR31377/test-PR31377-report-1.txt:
New reference test output.
* tests/data/Makefile.am: Add the
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Adjust.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/test-abidiff-exit.cc
2024-01-12 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,corpus: Use interned string to lookup corpus interfaces by ID.
* include/abg-corpus.h (corpus::lookup_functions): Take an
interned_string instead of an std::string. Add an overload for
const char* string too, for debugging purposes.
* src/abg-corpus-priv.h (istr_fn_ptr_set_map_type)
(istr_var_ptr_map_type): Define new typedefs.
(corpus::exported_decls_builder::priv::{id_fns_map_,
id_var_map_}): Use the new istr_fn_ptr_set_map_type and
istr_var_ptr_map_type types for these data members.
(corpus::exported_decls_builder::priv::{id_fns_map, id_var_map,
add_fn_to_id_fns_map, var_id_is_in_id_var_map, add_var_to_map,
add_var_to_exported}): Adjust.
(corpus::priv::lookup_functions): Declare new member function.
* src/abg-corpus.cc
(corpus::exported_decls_builder::maybe_add_var_to_exported_vars): Adjust.
(corpus::priv::lookup_functions): Define new member function. The
code here comes from the code that was in
corpus::lookup_functions. This is a factorization of
corpus::lookup_functions.
(corpus::lookup_functions): Take an interned_string instead of the
previous. Factorize the code that was here into the new
corpus::priv::lookup_functions.
* src/abg-dwarf-reader.cc
(reader::symbol_already_belongs_to_a_function): Adjust the call to
corpus::lookup_functions to use an interned_string.
2024-02-01 Dodji Seketeli <dodji@redhat.com>
ir: Cache internal name for several types
* src/abg-ir.cc ({qualified_type_def, pointer_type_def,
reference_type_def}::get_qualified_name): Cache the internal
qualified type name for non-canonicalized types.
(function_type::get_cached_name): Cache the internal function type
name.
2024-02-08 Dodji Seketeli <dodji@redhat.com>
ir: Introduce a missing IR kind for subrange types
* include/abg-ir.h (type_or_decl_kind::SUBRANGE_TYPE): Add a new
enumerator to enum type_or_decl_kind::type_or_decl_kind.
* src/abg-ir.cc (array_type_def::subrange_type::subrange_type):
Use the new type_or_decl_kind::SUBRANGE_TYPE to flag the IR node
representing array_type_def::subrange_type.
2024-02-08 Dodji Seketeli <dodji@redhat.com>
writer: Don't forget data members when emitting referenced types
* src/abg-writer.cc (write_decl_in_scope): If the scope of the
decl to write is a type that was not yet emitted, then emit it in
full. Otherwise, just do things as we were doing previously.
2024-01-06 Dodji Seketeli <dodji@redhat.com>
writer: Avoid emitting a canonical type twice
* src/abg-writer.cc (write_canonical_types_of_scope): Don't emit a
canonical type if it's already been emitted.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2024-01-12 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix detection of C language DIEs
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Use
reader::die_is_in_c rather than looking at the language of the
current translation unit.
2024-01-12 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Avoid duplicating union members
* src/abg-dwarf-reader.cc (add_or_update_union_type): Do not add
an union member that already exists in the union.
2023-12-22 Dodji Seketeli <dodji@redhat.com>
ir: Avoid duplicates when reading member functions
* src/abg-ir.cc (fixup_virtual_member_function): Check if a
virtual member function with the same linkage name exists already
before adding it in.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2024-01-06 Dodji Seketeli <dodji@redhat.com>
ir: Fix wording of several comments
* src/abg-ir.cc: (get_decl_name_for_comparison)
(class_or_union::add_data_member) Fix comment wording.
2023-12-22 Dodji Seketeli <dodji@redhat.com>
abidw: Fix indentation
* tools/abidw.cc (load_corpus_and_write_abixml): Fix indentation.
2024-01-26 Dodji Seketeli <dodji@redhat.com>
Remove python3-mock dependency and use unittest.mock instead
* configure.ac: Do not require python-mock anymore.
* tests/mockfedabipkgdiff.in: Use unittest.mock, not mock from
python-mock.
2024-01-25 Dodji Seketeli <dodji@redhat.com>
Bug 31279 - Acknowledge that opaque types are always decl-only
* src/abg-dwarf-reader.cc
(reader::maybe_schedule_declaration_only_{class,enum}_for_resolution):
Do not schedule anonymous decl-only types for resolution to their
definition.
(build_typedef_type): When an anonymous decl-only type has just
been named by a typedef, schedule it for resolution to its
definition.
(add_or_update_class_type): Do not assert that /anonymous/
decl-only types are scheduled for resolution to their definition.
2024-01-15 Dodji Seketeli <dodji@redhat.com>
Bug 31236 - Fix removing a member declaration from its scope
* src/abg-ir.cc (scope_decl::remove_member_decl): Reset the
translation unit and the scope of the removed decl.
(remove_decl_from_scope): Do not reset the scope of the removed
decl here as it's now done above.
2023-12-29 Mark Wielaard <mark@klomp.org>
Recognize EM_RISCV in e_machine_to_string
* configure.ac: Defining HAVE_EM_RISCV_MACRO if EM_RISCV
is defined in elf.h.
* src/abg-dwarf-reader.cc (e_machine_to_string): Handle
EM_RISCV if HAVE_EM_RISCV_MACRO is defined.
2023-12-29 Mark Wielaard <mark@klomp.org>
Fix ABG_ASSERT in build_ir_node_from_die for DW_TAG_member
* src/abg-dwarf-reader.cc (build_ir_node_from_die): ABG_ASSERT
!rdr.die_is_in_c(), not rdr.cur_transl_unit().
2024-01-04 Giuliano Procida <gprocida@google.com>
website: doxygen: set PROJECT_NAME to libabigail
* doc/website/libabigail-website.doxy: Set PROJECT_NAME to
libabigail.
2023-11-29 Dodji Seketeli <dodji@redhat.com>
Bump LIBABIGAIL_SO_CURRENT version to 4
* configure.ac: Set LIBABIGAIL_SO_CURRENT to 4.
2023-12-01 Dodji Seketeli <dodji@redhat.com>
Bump abixml version to 2.3
* configure.ac: Bump ABIXML_VERSION_MINOR to 3.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise
* tests/data/test-annotate/test-pointer-to-member-1.o.annotated.abi:
Likewise
* tests/data/test-annotate/test0.abi: Likewise
* tests/data/test-annotate/test1.abi: Likewise
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise
* tests/data/test-annotate/test2.so.abi: Likewise
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise
* tests/data/test-annotate/test3.so.abi: Likewise
* tests/data/test-annotate/test4.so.abi: Likewise
* tests/data/test-annotate/test5.o.abi: Likewise
* tests/data/test-annotate/test6.so.abi: Likewise
* tests/data/test-annotate/test7.so.abi: Likewise
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise
* tests/data/test-read-btf/test0.o.abi: Likewise
* tests/data/test-read-btf/test1.o.abi: Likewise
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise
* tests/data/test-read-ctf/test-alias.o.abi: Likewise
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi:
Likewise
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise
* tests/data/test-read-ctf/test-array-mdimension.abi: Likewise
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise
* tests/data/test-read-ctf/test-array-size.abi: Likewise
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise
* tests/data/test-read-ctf/test-bitfield.abi: Likewise
* tests/data/test-read-ctf/test-callback.abi: Likewise
* tests/data/test-read-ctf/test-callback2.abi: Likewise
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise
* tests/data/test-read-ctf/test-const-array.abi: Likewise
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise
* tests/data/test-read-ctf/test-enum.o.abi: Likewise
* tests/data/test-read-ctf/test-fallback.abi: Likewise
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise
* tests/data/test-read-ctf/test-functions-declaration.abi:
Likewise
* tests/data/test-read-ctf/test-linux-module.abi: Likewise
* tests/data/test-read-ctf/test-list-struct.abi: Likewise
* tests/data/test-read-ctf/test0.abi: Likewise
* tests/data/test-read-ctf/test0.hash.abi: Likewise
* tests/data/test-read-ctf/test1.so.abi: Likewise
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise
* tests/data/test-read-ctf/test2.so.abi: Likewise
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise
* tests/data/test-read-ctf/test3.so.abi: Likewise
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise
* tests/data/test-read-ctf/test4.so.abi: Likewise
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise
* tests/data/test-read-ctf/test5.o.abi: Likewise
* tests/data/test-read-ctf/test7.o.abi: Likewise
* tests/data/test-read-ctf/test8.o.abi: Likewise
* tests/data/test-read-ctf/test9.o.abi: Likewise
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi: Likewise
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise
* tests/data/test-read-dwarf/PR28584/PR28584-smv.clang.o.abi:
Likewise
* tests/data/test-read-dwarf/PR29443-missing-xx.o.abi: Likewise
* tests/data/test-read-dwarf/PR29692-kdelibs3-libkjava.so.1.0.0.abi:
Likewise
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise
* tests/data/test-read-dwarf/test-fallback.abi: Likewise
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise
* tests/data/test-read-dwarf/test-pointer-to-member-1.o.abi:
Likewise
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi: Likewise
* tests/data/test-read-dwarf/test0.abi: Likewise
* tests/data/test-read-dwarf/test0.hash.abi: Likewise
* tests/data/test-read-dwarf/test1.abi: Likewise
* tests/data/test-read-dwarf/test1.hash.abi: Likewise
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise
* tests/data/test-read-dwarf/test2.so.abi: Likewise
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test3.so.abi: Likewise
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test4.so.abi: Likewise
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test5.o.abi: Likewise
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise
* tests/data/test-read-dwarf/test6.so.abi: Likewise
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test7.so.abi: Likewise
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise
* tests/data/test-read-write/test-crc.xml: Likewise
* tests/data/test-read-write/test26.xml: Likewise
* tests/data/test-read-write/test27.xml: Likewise
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise
2023-11-30 Dodji Seketeli <dodji@redhat.com>
Bug 30260 - Support pointer-to-member type
* include/abg-comparison.h (class ptr_to_mbr_diff): Declare new
class.
(ptr_to_mbr_diff_sptr): Declare new typedef.
(compute_diff): Declare new overload for ptr_to_mbr_diff.
(ptr_to_mbr_type_sptr): Declare new typedef.
* src/abg-comparison-priv.h (struct ptr_to_mbr_diff::priv): Define
* src/abg-comparison.cc (compute_diff_for_types): Support new
ptr_to_mbr_type type.
(ptr_to_mbr_diff::{ptr_to_mbr_diff, first_ptr_to_mbr_type,
second_ptr_to_mbr_type, member_type_diff, containing_type_diff,
has_changes, has_local_changes, get_pretty_representation, report,
chain_into_hierarchy, ~ptr_to_mbr_diff}): Define member functions
of class ptr_to_mbr_diff.
(compute_diff): Define overload for ptr_to_mbr_type_sptr.
* include/abg-fwd.h (ptr_to_mbr_type_sptr): Declare new typedef.
(is_ptr_to_mbr_type, is_pointer_to_ptr_to_mbr_type)
(is_typedef_of_maybe_qualified_class_or_union_type): Declare new
functions.
* include/abg-ir.h (type_maps::ptr_to_mbr_types): Declare new
accessor.
(POINTER_TO_MEMBER_TYPE): Add new enumerator to enum
type_or_decl_base::type_or_decl_kind.
(class ptr_to_mbr_type): Declare new class.
(equals): Declare new overload for ptr_to_mbr_type.
(ir_node_visitor::visit_{begin,end}): Declare new member
functions.
* src/abg-ir.cc (ptr_to_mbr_declaration_name)
(ptr_to_mbr_declaration_name, add_outer_ptr_to_mbr_type_expr)
(add_outer_pointer_to_ptr_to_mbr_type_expr): Define new static
functions.
(type_maps::priv::ptr_to_mbr_types_): Define new
data member.
(type_maps::ptr_to_mbr_types): Define new accessor.
(is_ptr_to_mbr_type, is_pointer_to_ptr_to_mbr_type)
(is_typedef_of_maybe_qualified_class_or_union_type): Define new
functions.
(maybe_update_types_lookup_map, equals): Define new overloads for
ptr_to_mbr_type_sptr.
(is_npaf_type): Use is_ptr_to_mbr_type.
(maybe_update_types_lookup_map): In the overload for
decl_base_sptr, call the new overload for ptr_to_mbr_type_sptr
above.
(struct ptr_to_mbr_type::priv): Define new struct.
(ptr_to_mbr_type::{ptr_to_mbr_type, get_member_type,
get_containing_type, operator==, get_qualified_name, traverse,
~ptr_to_mbr_type}): Define member functions of ptr_to_mbr_type.
(types_have_similar_structure): Support the new ptr_to_mbr_type
type.
(ir_node_visitor::visit_{begin,end}): Add new member functions.
(var_decl::get_pretty_representation): Support pretty-printing
pointer-to-member types.
(pointer_declaration_name, array_declaration_name): Likewise.
* include/abg-reporter.h ({reporter_base, default_reporter,
leaf_reporter}::report): Add an overload for ptr_to_mbr_diff.
(default_reporter::report_local_ptr_to_mbr_type_changes): Declare
a member function.
private data class of ptr_to_mbr_diff.
* src/abg-default-reporter.cc
(default_reporter::report_local_ptr_to_mbr_type_changes): Define
member functions.
(default_reporter::report): Define an overload for
ptr_to_mbr_diff.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Likewise.
* src/abg-dwarf-reader.cc (build_ptr_to_mbr_type): Define new
function.
(build_ir_node_from_die): Use the new build_ptr_to_mbr_type
function.
* src/abg-reader.cc (build_ptr_to_mbr_type): Define new function.
(build_type): Use the new build_ptr_to_mbr_type above.
* src/abg-writer.cc (write_ptr_to_mbr_type): Define new function.
(write_type, write_decl, write_member_type): Use the new
write_ptr_to_mbr_type above.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr1-output-1.txt:
Add new test material.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr1-v0.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr1-v0.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr1-v1.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr1-v1.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr2-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr2-v0.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr2-v0.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr2-v1.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr2-v1.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr3-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr3-v0.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr3-v0.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr3-v1.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr3-v1.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr4-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr4-v0.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr4-v0.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr4-v1.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr4-v1.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr5-output-1.txt:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr5-v0.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr5-v0.o:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr5-v1.cc:
Likewise.
* tests/data/test-abidiff-exit/pointer-to-member/test-ptr-to-mbr5-v1.o:
Likewise.
* tests/data/test-read-dwarf/test-pointer-to-member-1.cc:
Likewise.
* tests/data/test-read-dwarf/test-pointer-to-member-1.o: Likewise.
* tests/data/test-read-dwarf/test-pointer-to-member-1.o.abi:
Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the test material
above to this test harness.
* tests/test-annotate.cc (in_out_specs): Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
2023-11-30 Dodji Seketeli <dodji@redhat.com>
Improve type naming
* include/abg-fwd.h (is_npaf_type, is_pointer_to_function_type)
(is_pointer_to_array_type, is_pointer_to_npaf_type): Declare new
functions.
(is_pointer_type, is_reference_type, is_array_type): Take a
boolean parameter to look through qualifiers.
* include/abg-ir.h (is_pointer_type): Do not make this function a
friend of the type_or_decl_base class anymore.
* src/abg-ir.cc (pointer_declaration_name, array_declaration_name)
(stream_pretty_representation_of_fn_parms)
(add_outer_pointer_to_fn_type_expr)
(add_outer_pointer_to_array_type_expr): Define new static
functions.
(is_npaf_type, is_pointer_to_function_type)
(is_pointer_to_array_type, is_pointer_to_npaf_type): Define new
functions.
(get_type_representation): Remove the overload for array_type_def.
(get_function_type_name, get_method_type_name)
(function_decl::get_pretty_representation_of_declarator): Use the
new stream_pretty_representation_of_fn_parms. This actually
factorizes parameters pretty-printing by reusing
stream_pretty_representation_of_fn_parms.
(is_pointer_type, is_reference_type, is_array_type): Take a
boolean parameter to look through qualifiers.
(is_void_pointer_type): Use const where it's due.
(pointer_type_def::get_qualified_name): Use the new
pointer_declaration_name in lieu of the old and removed
get_name_of_pointer_to_type.
(array_type_def::{get_pretty_representation, get_qualified_name}):
Use the new array_declaration_name instead of the old and removed
get_type_representation.
(var_decl::get_pretty_representation): Use the new
array_declaration_name and pointer_declaration_name.
(function_decl::get_pretty_representation): Use the new
add_outer_pointer_to_array_type_expr, and
add_outer_pointer_to_array_type_expr function to support the
proper syntax for function returning pointers and arrays.
(function_decl::parameter::get_pretty_representation): Fix the
pretty-printing of each function parameter.
* tests/data/test-abicompat/test0-fn-changed-report-0.txt: Adjust.
* tests/data/test-abicompat/test0-fn-changed-report-2.txt:
Likewise.
* tests/data/test-abicompat/test1-fn-removed-report-0.txt:
Likewise.
* tests/data/test-abicompat/test3-fn-removed-report-0.txt:
Likewise.
* tests/data/test-abidiff-exit/PR30048-test-2-report-1.txt: Likewise.
* tests/data/test-abidiff-exit/PR30048-test-report-0.txt: Likewise.
* tests/data/test-abidiff-exit/PR30329/PR30329-report-1.txt: Likewise.
* tests/data/test-abidiff-exit/PR30503/libsdl/libsdl-1.2.60-1.2.64-report.txt: Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-1.txt: Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-2.txt: Likewise.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-fun-param-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-ld-2.28-210.so--ld-2.28-211.so.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-fun-type-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-more-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-leaf-stats-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-net-change-report0.txt:
Likewise.
* tests/data/test-abidiff-exit/test-net-change-report2.txt:
Likewise.
* tests/data/test-abidiff-exit/test2-filtered-removed-fns-report0.txt:
Likewise.
* tests/data/test-abidiff/test-PR18791-report0.txt: Likewise.
* tests/data/test-abidiff/test-crc-report-0-1.txt: Likewise.
* tests/data/test-abidiff/test-crc-report-1-0.txt: Likewise.
* tests/data/test-abidiff/test-crc-report-1-2.txt: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Likewise.
* tests/data/test-diff-dwarf/test-23-diff-arch-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test18-alias-sym-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test19-soname-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
* tests/data/test-diff-filter/test-PR26739-2-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test6-report.txt: Likewise.
* tests/data/test-diff-filter/test7-report.txt: Likewise.
* tests/data/test-diff-pkg/GtkAda-gl-2.24.2-29.fc29.x86_64--2.24.2-30.fc30.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/libxcrypt-4.1.1-6.el8.x86_64--libxcrypt-compat-4.4.18-3.el9.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/test-rpm-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-7.txt:
Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-4.txt:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-4.txt:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test30-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test32-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test32-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test44-suppr-sym-name-not-regexp-report-1.txt:
Likewise.
* tests/data/test-fedabipkgdiff/vte291-0.39.1-1.fc22.x86_64--vte291-0.39.90-1.fc22.x86_64-report-0.txt:
Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
2023-11-30 Dodji Seketeli <dodji@redhat.com>
abilint: Alphabetically sort programs options
* doc/manuals/abilint.rst: Alphabetically sort options in the
manual.
* tools/abilint.cc (display_usage): Likewise for the help strings.
2023-10-31 Dodji Seketeli <dodji@redhat.com>
abilint: Support --annotate
* tools/abilint.cc (options::annotate): Define new data member.
(options::options): Initialize.
(display_usage): Add help string.
(parse_command): Support the --annotate command options.
(main): Set the annotate option on the context.
2023-11-03 Dodji Seketeli <dodji@redhat.com>
suppression: Add "has_strict_flexible_array_data_member_conversion" property
* include/abg-comp-filter.h (has_strict_fam_conversion): Declare
new functions.
* include/abg-fwd.h
(ir::has_fake_flexible_array_data_member): Declare new accessor
functions.
* include/abg-suppression.h
(type_suppression::{,set_}has_strict_fam_conversion): Declare new
accessor functions.
* src/abg-comp-filter.cc (has_strict_fam_conversion): Define new
functions.
* src/abg-ir.cc
(ir::has_fake_flexible_array_data_member): Define new accessor
functions.
* src/abg-suppression-priv.h
(type_suppression::priv::has_strict_fam_conv_): Define new
data member.
* src/abg-suppression.cc
(type_suppression::{,set_}has_strict_fam_conversion): Define new
accessor functions.
(type_suppression::suppresses_diff): For a type suppression to
match a fake flex array conversion, either the size of the type
hasn't change or has_size_change must be true and then the type
must change from a fake flex array to a real flex array.
(read_type_suppression): Parse the new
'has_strict_flexible_array_data_member_conversion' property to
set the type_suppression::set_has_strict_fam_conversion property.
* doc/manuals/libabigail-concepts.rst: Add an entry for the new
'has_strict_flexible_array_data_member_conversion' property.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-{1,2}.suppr:
Add new test suppression files.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-report-{1,2}.txt:
Add new test reference output files.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-v{0,1}.c:
Add source code for new binary test input files.
* tests/data/test-diff-suppr/test-has-strict-flexible-array-data-member-conversion-v{0,1}.o:
Add new binary test input files.
* tests/data/Makefile.am: Add the new test files to the source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
files to this test harness.
2023-11-08 Dodji Seketeli <dodji@redhat.com>
Bug 31045 - Don't try setting translation unit for unique types
* src/abg-ir.cc (maybe_set_translation_unit): Define new static
function.
(scope_decl::{add,insert}_member_decl): Use it.
* tests/data/test-abidiff-exit/PR31045/zfs-abigail-2.4/libnvpair.{abi,so,suppr}:
New test input files.
* tests/data/test-abidiff-exit/PR31045/zfs-abigail-2.4/test-PR31045-report-1.txt:
New reference test output.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the input above
to this test harness.
Tested-by: Paolo Pisati <paolo.pisati@canonical.com>
2023-10-21 Dodji Seketeli <dodji@redhat.com>
configure: Bump development version to 2.5
* configure.ac: Bump version to 2.5
2023-10-20 Dodji Seketeli <dodji@redhat.com>
ChangeLog: Update for 2.4 release
* ChangeLog: Update automatically with make update-changelog.
2023-10-20 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 2.4 release
* NEWS: Update for 2.4 release.
2023-10-20 Dodji Seketeli <dodji@redhat.com>
doc/website/mainpage.txt: Update for 2.4 release
* doc/website/mainpage.txt: Update download link for 2.4 release.
Use the .xz tarball.
2023-10-20 Dodji Seketeli <dodji@redhat.com>
gen-changelog.py: Remove long standing debugging output
* gen-changelog.py (gen-changelog.py): Remove debugging output.
2023-10-20 Dodji Seketeli <dodji@redhat.com>
gen-changelog.py: Fix a long standing typo
* gen-changelog.py (get_rel_tags): It's libabigail, not GNET.
2023-10-20 Dodji Seketeli <dodji@redhat.com>
gen-changelog.py: Don't escaping '/' with '\' in regexp
* gen-changelog.py (get_rel_tags): Do not escape '/' with '\' in
regexp.
2023-10-20 Dodji Seketeli <dodji@redhat.com>
ir: Fix compilation error with GCC 4.8.5
* src/abg-ir.cc (enum_type_decl::get_sorted_enumerators): Add
const to parameters of the lambda function.
2023-10-18 Dodji Seketeli <dodji@redhat.com>
suppression: Make the "end" data member offset selector be named boundary
* src/abg-suppression.cc (END_STRING): Define new static string
constant accessor.
(type_suppression::insertion_range::eval_boundary): Eval the "end"
named boundary as having a numerical value of
std::numeric_limits<uint64_t>::max().
(read_type_suppression): Parse the "end" token as a named
boundary.
2023-10-05 Dodji Seketeli <dodji@redhat.com>
Support suppressing data member insertion before a flexible array member
* doc/manuals/libabigail-concepts.rst: Add documentation for the
new "offset_of_flexible_array_data_member" named boundary.
* include/abg-fwd.h (has_flexible_array_data_member): Declare new
function.
* src/abg-ir.cc (has_flexible_array_data_member): Define it.
* include/abg-suppression.h
(type_suppression::insertion_range::named_boundary_sptr): Define
new typedef.
(type_suppression::insertion_range::create_named_boundary): Declare
new static function member function.
(is_named_boundary): Declare new function.
(class type_suppression::insertion_range::named_boundary): Declare
new type.
* src/abg-suppression.cc
(struct type_suppression::insertion_range::named_boundary::priv):
Define new private type.
(OFFSET_OF_FLEXIBLE_ARRAY_DATA_MEMBER_STRING): Define new static
constant string getter function.
(type_suppression::insertion_range::create_named_boundary): Define
new static member function.
(is_named_boundary): Define new function.
(read_type_suppression): Parse the new
"offset_of_flexible_array_data_member" named boundary.
(type_suppression::insertion_range::eval_boundary): Evaluate the
new "offset_of_flexible_array_data_member" named boundary.
* tests/data/test-abidiff-exit/test-fam1-report-[1-5].txt: New
reference test output.
* tests/data/test-abidiff-exit/test-fam2-report-1.txt: Likewise.
* tests/data/test-abidiff-exit/test-fam1-suppr-[1-4].abignore: New test
suppression specification.
* tests/data/test-abidiff-exit/test-fam{1,2}-v{0,1}.o: New test input
binaries.
* tests/data/test-abidiff-exit/test-fam{1,2}-v{0,1}.c: Source code of
the test input binaries.
* tests/data/Makefile.am: Add the new test material to the source
distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new test
input to this harness.
2023-10-13 Dodji Seketeli <dodji@redhat.com>
comparison: Represent changed unreachable anonymous unions, structs & enums
* include/abg-fwd.h (class_or_union_types_of_same_kind)
(is_data_member_of_anonymous_class_or_union): Declare new
functions.
* include/abg-ir.h (lookup_data_member): Likewise, declare a new overload.
* src/abg-ir.cc (class_or_union_types_of_same_kind)
(lookup_data_member, is_data_member_of_anonymous_class_or_union):
Define news functions & overloads.
* src/abg-reporter-priv.cc (represent): When representing a change
in the name of a data member, if the context is an anonymous type,
use the non-qualified name of the data member, not its qualified
name.
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Handle
deleted/added anonymous enums, unions, classes and structs
similarly. That is, if an anonymous type was removed and another
one got added, if they both have data members (or enumerators) in
common, then we are probably looking at an anonymous type that was
changed. This is because these anonymous types are named using
their flat representation.
* tests/data/test-abidiff-exit/test-anon-types-report-1.txt: New
reference test comparison output.
* tests/data/test-abidiff-exit/test-anon-types-v{0,1}.o: New
binary tests input files.
* tests/data/test-abidiff-exit/test-anon-types-v{0,1}.c: Source
code of new binary test input.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the test inputs
above to this test harness.
2023-09-23 Dodji Seketeli <dodji@redhat.com>
ir,comparison: Represent changed anonymous enums
* include/abg-ir.h (is_enumerator_present_in_enum): Declare new
public function.
* src/abg-ir.cc (is_enumerator_present_in_enum): Turn this
static function into a public one.
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Detect that
an removed/added anonymous enum is actually a changed anonymous
enum and represent it as such.
* tests/data/test-abidiff-exit/test-anonymous-enums-change-report-v{0,1}.txt:
New reference test output files.
* tests/data/test-abidiff-exit/test-anonymous-enums-change-v{0,1}.c:
Source code for the some input test binary.
* tests/data/test-abidiff-exit/test-anonymous-enums-change-v{0,1}.o:
New test input binaries.
* tests/data/Makefile.am: Add the new test materials above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new test
input to the harness.
2023-09-22 Dodji Seketeli <dodji@redhat.com>
ir,comparison,corpus: Better support anonymous enums comparison
* include/abg-fwd.h (get_enum_flat_representation)
(get_class_or_enum_flat_representation): Declare new functions.
* include/abg-ir.h (enum_type_decl::get_sorted_enumerators):
Declare new member functions.
* src/abg-comparison.cc
(corpus_diff::priv::{ensure_lookup_tables_populated,
added_unreachable_type_is_suppressed,
deleted_unreachable_type_is_suppressed,
record_type_as_reachable_from_public_interfaces}): Use
non-internal pretty representation to designate ABI artifacts so
that anonymous enums get designated by their flat representation.
* src/abg-corpus.cc (corpus::type_is_reachable_from_public_interfaces):
Likewise.
* src/abg-ir.cc (get_type_name): The type name of an anonymous
enum or class should is now the flat representation if we are not
in the context of type canonicalization.
(enum_type_decl::get_pretty_representation): If we are not in the
context of type canonicalization, the pretty representation of an
enum is its flat representation.
(get_enum_flat_representation)
(get_class_or_enum_flat_representation): Define new functions.
(enum_type_decl::get_sorted_enumerators): Likewise.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf/test43-PR22913-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2023-09-26 Dodji Seketeli <dodji@redhat.com>
default-reporter,reporter-priv: Do not report names of anonymous enums
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for enum_diff, do not get the qualified name of anonymous
enums.
* src/abg-reporter-priv.cc
(report_name_size_and_alignment_changes): Do not report about name
changes for anonymous enums.
2023-09-28 John Moon <quic_johmoo@quicinc.com>
suppression: Add "changed_enumerators_regexp" property
* include/abg-suppression.h
(type_suppression::{g,s}et_changed_enumerators_regexp): Declare new
accessor functions.
* src/abg-suppression-priv.h
(type_suppression::priv::changed_enumerators_regexp_): Define new
data member.
* src/abg-suppression.cc
(type_suppression::{g,s}et_changed_enumerators_regexp): Define new
accessor function.
(type_suppression::suppresses_diff): For a type suppression to
match an enum_diff, the names of all changed enumerators must
match either the names returned by
type_suppression::get_changed_enumerator_names or one of the
regexps returned by the new member function
type_suppression::get_changed_enumerators_regexp.
(read_type_suppression): Parse the new
'changed_enumerators_regexp' property to set the
type_suppression::get_changed_enumerators_regexp property.
* doc/manuals/libabigail-concepts.rst: Add an entry for the new
'changed_enumerators_regexp' property.
* tests/data/test-diff-suppr/test40.1-enumerator-changes-enumerator-changes-[1-5].suppr:
Add new test suppression files.
* tests/data/test-diff-suppr/test40.1-enumerator-changes-enumerator-changes-report-[0-5].txt:
Add new test reference output files.
* tests/data/test-diff-suppr/test40.1-enumerator-changes-enumerator-changes-v{0,1}.c:
Add source code for new binary test input files.
* tests/data/test-diff-suppr/test40.1-enumerator-changes-enumerator-changes-v{0,1}.o:
Add new binary test input files.
* tests/data/Makefile.am: Add the new test files to the source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
files to this test harness.
2023-10-16 Dodji Seketeli <dodji@redhat.com>
Bug 30971 - Wrong interpretation of "has_data_member_inserted_at"
* include/abg-comparison.h
(class_or_union_diff::changed_data_members): Declare new accessor.
function.
* src/abg-comparison.cc
(class_or_union_diff::changed_data_members): Define new accessor.
function.
* src/abg-suppression.cc (type_suppression::suppresses_diff): If
the type suppression specification contains a
has_data_member_inserted_* property and yet the class contains no
data member inserted or replacing an existing one, then the type
suppression is falsified in the context of the current change.
Also, when a data member replaces an existing one, consider that
as an insertion for which the has_data_member_inserted_* predicate
should be evaluated. Stop considering deleted data members
because considering replaced data member is really what we meant.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-2-report.[1-3].txt:
New reference test output files.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-2-report.txt:
Likewise.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-{2,3}-v{0,1}.o:
New input test binaries.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-{2,3}-v{0,1}.c:
Source code of the new input test binaries.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-2.2.suppr:
New input test suppression specification.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-2.suppr: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the test input
above to this test harness.
Tested-by: John Moon <quic_johmoo@quicinc.com>
2023-10-12 Dodji Seketeli <dodji@seketeli.org>
ir: Remove redundant virtual member functions
* include/abg-ir.h
({qualified_type_def,pointer_type_def,class_or_union}::operator!=):
Remove these redundant virtual data members.
2023-10-11 Dodji Seketeli <dodji@redhat.com>
init: Fix thinko in apidoc
* src/abg-ini.cc (read_context::read_string): A string is a
contiguous vector of "property value" characters.
2023-10-11 Dodji Seketeli <dodji@redhat.com>
ini: Support '[' and ']' in arguments of function call expressions
* src/abg-ini.cc (char_is_function_name_char): The only delimiters
should be the '(' and ')' characters.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1-report-2.txt:
New reference test output.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1.2.suppr:
New suppression specification.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test
material above to this test harness.
2023-10-11 Dodji Seketeli <dodji@seketeli.org>
Bug 30959 - Crash on malformed fn call expression
* src/abg-suppression.cc
(type_suppression::insertion_range::eval_boundary): If the
function call expression is considered malformed, then do not
crash.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1-report-1.txt:
New reference test output.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1-v{0,1}.c:
Source code of the new input binaries.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1-v{0,1}.o:
New input binaries.
* tests/data/test-diff-suppr/test-has-data-member-inserted-at-1.1.suppr:
New test suppression specification.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new tests to
this harness.
2023-10-05 Dodji Seketeli <dodji@redhat.com>
suppression: Fix a typo in apidoc
* src/abg-suppression.cc (is_fn_call_expr_boundary): Fix a typo in
the apidoc.
2023-10-05 Dodji Seketeli <dodji@redhat.com>
suppression: Fix indentation
* include/abg-suppression.h: Fix indentation of the
type_suppression::insertion_range::end() accessor.
2023-10-05 Dodji Seketeli <dodji@redhat.com>
doc/manuals/libabigail-concepts.rst: Fix typo
* doc/manuals/libabigail-concepts.rst: Fix a typo in the doc for
the "end" named boundary.
2023-09-26 Dodji Seketeli <dodji@redhat.com>
abg-comparison[-priv]: Better detection of incompatible unreachable type changes
*
* Compile this with:
- * gcc -g -c -fno-eliminate-unused-debug-types test-enumerator-changes1-v0.c
+ * gcc -g -c -fno-eliminate-unused-debug-types test-enumerator-changes1-v1.c
*/
enum foo
{
E1_O,
- E1_1
+ E1_1,
+ E1_2
};
void
$
The enumerator E1_2 has been added to the 'foo' enum.
Now, let's see what abidiff prior to this patch would say about the
change between the two result binaries test-enumerator-changes1-v0.o
and test-enumerator-changes1-v1.o:
$ abidiff --non-reachable-types --harmless test-enumerator-changes1-v0.o test-enumerator-changes1-v1.o || echo "return value: $?"
Functions changes summary: 0 Removed, 0 Changed, 0 Added function
Variables changes summary: 0 Removed, 0 Changed, 0 Added variable
Unreachable types summary: 0 removed, 1 changed, 0 added type
1 changed type unreachable from any public interface:
[C] 'enum foo' changed:
type size hasn't changed
1 enumerator insertion:
'foo::E1_2' value '2'
return value: 12
$
See the return value of 12, that is actually the bits
abigail::tools_utils::ABIDIFF_ABI_CHANGE (of value 4) and
abigail::tools_utils::ABIDIFF_ABI_INCOMPATIBLE_CHANGE (of value 8) being set.
Normally, only the bit abigail::tools_utils::ABIDIFF_ABI_CHANGE (of
value 4) should be set.
Now, let's look at what abidiff says with this patch:
$ abidiff --non-reachable-types --harmless test-enumerator-changes1-v0.o test-enumerator-changes1-v1.o || echo "return value: $?"
Functions changes summary: 0 Removed, 0 Changed, 0 Added function
Variables changes summary: 0 Removed, 0 Changed, 0 Added variable
Unreachable types summary: 0 removed, 1 changed, 0 added type
1 changed type unreachable from any public interface:
[C] 'enum foo' changed:
type size hasn't changed
1 enumerator insertion:
'foo::E1_2' value '2'
return value: 4
$
Now the return value is 4, which is the bit
abigail::tools_utils::ABIDIFF_ABI_CHANGE being set, as we would expect
because that change is known to be not incompatible.
* Src/abg-comparison-priv.h
(corpus_diff::priv::changed_unreachable_types): Declare ...
* src/abg-comparison.cc
(corpus_diff::priv::changed_unreachable_types): ... new function.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Walk
the nodes returned by corpus_diff:priv::changed_unreachable_types
and apply the filters (including categorization filters) to them.
Also make the loop similarly applying filters to the nodes
returned by corpus_diff::priv::changed_unreachable_types_sorted be
a ranged-based one, for the sake of consistency.
(corpus_diff::has_incompatible_changes): Now that diff nodes
returned by corpus_diff::priv::changed_unreachable_types are
categorized, look at their change categories to see if they are
incompatible or not.
* tests/data/test-abidiff-exit/test-enumerator-changes1-report-1.txt:
New test output reference.
* tests/data/test-abidiff-exit/test-enumerator-changes1-v{0,1}.o:
New test input binaries.
* tests/data/test-abidiff-exit/test-enumerator-changes1-v{0,1}.c:
New source code for the new test input binaries.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new test
input binaries to the test harness.
2023-09-28 Dodji Seketeli <dodji@redhat.com>
comparison: Always apply filters on the diff graph
* src/abg-comparison.cc (diff_context::maybe_apply_filters): Do
not get out when all the categories of diff changes are allowed.
2023-09-22 Dodji Seketeli <dodji@redhat.com>
ir: Fix output of 'debug(enum-type)'
* src/abg-ir.cc (get_debug_representation): Don't say 'union' when
we are looking at an enum.
2023-09-26 Dodji Seketeli <dodji@redhat.com>
test-abidiff-exit: Do not use debuginfo dir when its empty
* tests/test-abidiff-exit.cc (main): If debug info dir is empty in
the input test specifier, do not try to use it in the abidiff
command.
2023-10-02 Dodji Seketeli <dodji@redhat.com>
libabigail-concepts.rst: Remove trailing white spaces
* doc/manuals/libabigail-concepts.rst: Remove trailing white
spaces.
2023-10-02 Dodji Seketeli <dodji@redhat.com>
libabigail-concepts.rst: Sort the properties of the directives
* doc/manuals/libabigail-concepts.rst: Sort the properties in the
lexicographic order.
2023-09-20 Dodji Seketeli <dodji@redhat.com>
configure,test-diff-pkg.cc: Handle symlinks presence in dist tarball
* configure.ac: Use "tar -cf" instead of "tar -chf" to construct
the tarball. Detect if the presence of the symlink in the
distribution and define the WITH_SYMLINKS_KEPT_IN_DIST
preprocessor macro accordingly.
* tests/test-diff-pkg.cc (in_out_specs): If symlinks are not
present in the tarball then the test that requires symlinks is
deactivated. Also, fix the
data/test-diff-pkg/symlink-dir-test1/dir1 test to make it point to
the target of the symlinks directly, to avoid considering a binary
twice, in cases where symlink targets are copied.
2023-09-20 Dodji Seketeli <dodji@redhat.com>
elf-reader, ir: Fix compilation on GCC 4.8.5
* src/abg-elf-reader.cc (reader::initialize): Use older-style
initialization to keep the old lady happy.
* src/abg-ir-priv.h (canonicalize_types): Avoid using type
deduction in this context to keep the old lady happy.
2023-08-15 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Do not re-use typedefs in a scope
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Do not re-use
a typedef from a given scope.
* src/abg-reader.cc (build_typedef_type): Do not re-use typedefs
with the same ID.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2023-08-15 Dodji Seketeli <dodji@redhat.com>
ir: Fix qualification as non-confirmed propagated canonical types
* src/abg-ir.cc (return_comparison_result): A type that doesn't
have propagated canonical type can't be considered having
"non-confirmed propagated canonical type".
2023-08-17 Dodji Seketeli <dodji@redhat.com>
ir: Use non qualified typedef name for type canonicalization
* include/abg-ir.h (reference_type_def::{pointed_to_type_,
is_lvalue_}): Remove these data members.
(reference_type_def::priv_): Add a unique data member.
(typedef_decl::get_qualified_name): Add new virtual member
functions.
* src/abg-ir.cc (get_decl_name_for_comparison): If the decl we are
comparing is a typedef, only consider its non-qualified name.
(get_type_name): For internal purposes, the type name of a typedef
is its non-qualified name.
(pointer_type_def::get_qualified_name): For internal purposes, if
the pointed-to name is a typedef, use the non-qualified name of
the typedef.
(reference_type_def::priv): Define new data type.
(reference_type_def::reference_type_def): Initialize the new
reference_type_def::priv_ data member and adjust to the move of
the reference_type_def::pointed_to_type_ data member to
reference_type_def::priv::pointed_to_type_.
(reference_type_def::{s,g}et_pointed_to_type): Adjust.
(reference_type_def::is_lvalue): Likewise.
(reference_type_def::get_qualified_name): Support caching
qualified names for internal and non-internal purposes.
(typedef_decl::get_pretty_representation): For internal purposes,
use non-qualified typedef name.
(typedef_decl::get_qualified_name): Define the two overloads for
this virtual member function.
(function_decl::get_pretty_representation): Use the
'qualified_name' parameter. Also, rather than systematically
using the qualified name of the return type, use get_type_name
instead that knows when to use qualified names and when not to.
(qualified_name_setter::do_update):
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2023-08-17 Dodji Seketeli <dodji@redhat.com>
ir: Really avoid canonicalizing decl-only classes
* include/abg-fwd.h (is_pointer_to_decl_only_class_or_union_type)
(is_reference_to_decl_only_class_or_union_type)
(is_typedef_to_decl_only_class_or_union_type): Remove declarations.
(is_typedef_ptr_or_ref_to_decl_only_class_or_union_type): Declare
new function.
* src/abg-ir.cc (is_pointer_to_decl_only_class_or_union_type)
(is_reference_to_decl_only_class_or_union_type)
(is_typedef_to_decl_only_class_or_union_type): Remove definitions.
(is_typedef_ptr_or_ref_to_decl_only_class_or_union_type): Define
new function.
(is_non_canonicalized_type): Change the invocation of
is_declaration_only_class_or_union_type to make it look through
decl-only types. Use
is_typedef_ptr_or_ref_to_decl_only_class_or_union_type in lieu of
is_{pointer,reference,typedef}_to_decl_only_class_or_union_type
that got removed.
(method_decl::set_linkage_name): Remove the mapping between the
method and the old linkage name, only if the old name is different
from the new name. Duh.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2023-08-15 Dodji Seketeli <dodji@redhat.com>
ir: Avoid forgetting potential seemingly duplicated member functions
* src/abg-ir.cc (is_declaration_only_class_or_union_type): Add an
overload for type_base_sptr.
(function_decl::get_id): Virtual member functions that are defined
on decl-only classes have a special ID to avoid confusing them
with their counterparts defined on defined classes.
* src/abg-reader.cc (build_function_decl)
(build_function_decl_if_not_suppressed): Add a new
add_to_exported_decls parameter to avoid adding the function to
the set of exported decls to early. For the function to be
properly added to the set of exported decls, all its attributes
must be set, including virtualness. In some case, those
attributes are not yet known by the end of the call to
build_function_decl. The caller must then set those properties
and then add the function to the set of exported decls.
(build_{class,union}_decl): Build the function first, then add its
missing properties and *then* add it to the set of exported decls.
(handle_function_decl): Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
2023-08-15 Dodji Seketeli <dodji@redhat.com>
ir: Fix forgetting canonicalizing some function types
* src/abg-ir.cc (maybe_adjust_canonical_type): Once a missing
member function has been copied from it's destination to the
freshly canonicalized type, make sure the type of the member
function is canonicalized as well.
(copy_member_function): Bind the lifetime of the new function type
to the lifetime of the current translation unit.
2023-07-24 Dodji Seketeli <dodji@redhat.com>
ir: Add fn types to type lookup maps
* src/abg-ir.cc (maybe_update_types_lookup_map): Handle function
types.
(translation_unit::bind_function_type_life_time): Update types
lookup map.
2023-08-15 Dodji Seketeli <dodji@redhat.com>
ir: Add missing ABG_RETURN in the comparison engine
* src/abg-ir.cc (equals): In the overload for function_type,
class_decl and union_decl, add a missing ABG_RETURN.
2023-09-05 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Avoid comparing binaries that are outside of the package
* src/abg-tools-utils.cc (maybe_get_symlink_target_file_path): Do
not require that the file path points to a symlink. A file path
can point to a file that is not a symlink and yet the whole path
can be in parent directory that is a symlink. In this case,
realpath will correctly resolve to the correct target file.
* tools/abipkgdiff.cc (maybe_update_package_content): A path to a
binary that is not inside the RPM (because a symlink resolved to a
file outside of the RPM) should not be added to the set of
binaries to be analyzed.
* tests/data/test-diff-pkg/symlink-dir-test1-report1.txt: Add new
test file.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1-report1.txt:
Likewise.
* tests/data/Makefile.am: Add new test file to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): for the
data/test-diff-pkg/symlink-dir-test1/dir{1,2}/symlinks test, the
root dir of the package is
data/test-diff-pkg/symlink-dir-test1/dir{1,2}. Use that to test
that the symlinks are properly handled. Also, use the
data/test-diff-pkg/symlink-dir-test1/dir{1,2}/symlinks as a root
of an alternative package for which the symlinks resolve outside
the package, under
data/test-diff-pkg/symlink-dir-test1/dir{1,2}/targets. In this
later case, the symlinked files should be ignored in the
comparison. Likewise for
data/test-diff-pkg-ctf/symlink-dir-test1/dir1/symlinks.
2023-09-04 Dodji Seketeli <dodji@redhat.com>
{dwarf,elf}reader: Don't consider no symbol table as an error
* src/abg-dwarf-reader.cc (reader::read_corpus): Return an empty
corpus if no symbol was found. Do not crash when no symbol table
is found.
* src/abg-elf-reader.cc (reader::read_corpus): Consider a corpus
with no symbol table as being OK.
* src/abg-reader.cc (build_elf_symbol_from_reference): Do not
crash when no symbol table is present.
2023-09-05 Dodji Seketeli <dodji@redhat.com>
tools-utils: Avoid endless loop
* src/abg-tools-utils.cc (is_dir): Avoid endless loop.
2023-08-30 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Initialize libxml2 to use it in a multi-thread context
* include/abg-tools-utils.h (initialize): Declare ...
* src/abg-tools-utils.cc (initialize): ... new function.
* tools/abipkgdiff.cc (main): Invoke the new
abigail::tools_utils::initialize() here.
2023-07-24 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix some logging
* src/abg-dwarf-reader.cc
(reader::{read_debug_info_into_corpus,
canonicalize_types_scheduled}): Add missing new lines and spaces.
2023-07-24 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir: Make logging a property of the middle end
* src/abg-dwarf-reader.cc (reader::read_debug_info_into_corpus):
Set the do_log property on the environment from the do_log
property of the reader.
* src/abg-ir-priv.h (environment::priv::do_log_): New data member.
(environment::priv::priv): Initialize it.
(environment::priv::do_log): Define new accessor method.
(canonicalize_types): Add logging.
* src/abg-ir.cc (canonicalize): Add logging to time the
canonicalization of each type.
2023-09-05 Dodji Seketeli <dodji@redhat.com>
tools-utils: Fix indentation
* src/abg-tools-utils.cc (string_suffix): Fix indentation.
2023-08-15 Dodji Seketeli <dodji@redhat.com>
reader: fix indentation
* src/abg-reader.cc (build_function_type): Fix indentation.
2023-08-31 Giuliano Procida <gprocida@google.com>
operator!= fixes for C++-20
* include/abg-ir.h
(qualified_typedef): Add definition of operator!=.
(pointer_type_def): Likewise.
(reference_type_def): Likewise.
(class_or_union): Likewise.
Reported-by: Ilya Biryukov <ibiryukov@google.com>
2023-07-10 Dodji Seketeli <dodji@redhat.com>
ir: Remove an unnecessary comparison
* src/abg-ir.cc (method_decl::set_linkage_name): Assert that the
'this' pointer always equals the pointer to any member function
decl looked up from the parent class.
2023-07-10 Dodji Seketeli <dodji@redhat.com>
reader: Fix a long standing Thinko
* src/abg-reader.cc (build_class_decl): Map the XML node for the
member function to the member function decl, not to the class
decl.
2023-07-07 Yaakov Selkowitz <yselkowi@redhat.com>
Fix fedabipkgdiff configure check for Python 3.12
* configure.ac (REQUIRED_PYTHON_MODULES_FOR_FEDABIPKGDIFF):
Test for importlib.machinery instead of imp with python3.
2023-06-24 Dodji Seketeli <dodji@redhat.com>
abidiff: Add --{follow,list}-dependencies & add-binaries{1,2} support
* tools/abidiff.cc (options::{follow_dependencies,
list_dependencies, added_bins_dirs1, added_bins_dirs2,
added_bins1, added_bins2}): Add new data members.
(options::options): Initialize the new follow_dependencies and
list_dependencies boolean data members.
(display_usage): Add usage strings for --added-binaries-dir{1,2},
--add-binaries{1,2}, --follow-dependencies, --list-dependencies.
(parse_command_line): Parse the options --follow-dependencies,
--list-dependencies, --added-binaries-dir{1,2},
--add-binaries{1,2}.
(display_dependencies): Add new static function.
(main): Support the new --add-binaries{1,2},
--follow-dependencies, --list-dependencies.
* doc/manuals/abidiff.rst: Document the new options above.
* tests/data/test-abidiff-exit/test-PR30034/libabigail.abignore: Add test input.
* tests/data/test-abidiff-exit/test-PR30034/reference/include/rte_log.h:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_eal.so:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_eal.so.23:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_eal.so.23.1:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_kvargs.so:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_kvargs.so.23:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_kvargs.so.23.1:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_telemetry.so:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_telemetry.so.23:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/reference/lib64/librte_telemetry.so.23.1:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/include/rte_log.h:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_eal.so:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_eal.so.23:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_eal.so.23.2:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_kvargs.so:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_kvargs.so.23:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_kvargs.so.23.2:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_log.so:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_log.so.23:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_log.so.23.2:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_telemetry.so:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_telemetry.so.23:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/split/lib64/librte_telemetry.so.23.2:
Likewise.
* tests/data/test-abidiff-exit/test-PR30034/test-PR30034-report-1.txt:
Likewise.
* tests/data/Makefile.am: Add the test inputs to source
distribution.
* tests/test-abidiff-exit.cc
(InOutSpec::in_elfv{0,1}_added_bins_dir): Add new data member.
(main): Add --added-binaries-dir{1,2} option to abidiff if the
InOutSpec::in_elfv{0,1}_added_bins_dir data members are non-empty.
(in_out_specs): Add test inputs to this test
harness.
2023-06-24 Dodji Seketeli <dodji@redhat.com>
abidw: Add --{follow,list}-dependencies & --add-binaries support
* tools/abidw.cc (options::{added_bins_dirs, added_bins,
follow_dependencies, list_dependencies}): Add new data members.
(options::options): Initialize follow_dependencies and
list_dependencies.
(display_usage): Add usage strings for --add-binaries,
--follow-dependencies, --list-dependencies, --added-binaries-dir.
(parse_command_line): Parse options --add-binaries,
--follow-dependencies, --list-dependencies, --added-binaries-dir.
(load_corpus_and_write_abixml): Implement the --list-dependencies,
--follow-dependencies and --add-binaries sub-commands.
* doc/manuals/abidw.rst: Document the --add-binaries,
--follow-dependencies, --list-dependencies, --added-binaries-dir
options.
2023-06-24 Dodji Seketeli <dodji@redhat.com>
corpus,tools-utils: Support loading a corpus, its deps & other binaries
* include/abg-corpus.h (corpus_group::has_corpus): Declare new
member function.
* include/abg-tools-utils.h (get_comma_separated_args_of_option)
(find_file_under_dirs, get_dependencies)
(add_binaries_into_corpus_group)
(add_dependencies_into_corpus_group)
(stick_corpus_and_binaries_into_corpus_group)
(stick_corpus_and_dependencies_into_corpus_group): Declare new
functions.
* src/abg-corpus.cc (corpus_group::priv::corpora_path): Add new
data member.
(corpus_group::add_corpus): Do not add a corpus that was already
added to the group. Update the set of paths of added corpora so
that we can detect if a corpus has already been added.
* src/abg-tools-utils.cc (find_file_under_dir): If the file found
is a symbolic link, return it. Otherwise if the symbolic link is
not the file we were looking for, then skip it, rather than
following it, in case it's a directory.
(get_comma_separated_args_of_option, find_file_under_dirs)
(get_dependencies, add_binaries_into_corpus_group)
(add_dependencies_into_corpus_group)
(stick_corpus_and_binaries_into_corpus_group)
(stick_corpus_and_dependencies_into_corpus_group): New functions.
2023-06-24 Dodji Seketeli <dodji@redhat.com>
Make fe_iface::initialize independent from the kind of interface
* include/abg-elf-based-reader.h (elf_based_reader::initialize):
Rename elf_based_reader::reset into this. Add a new virtual
overload that implements fe_iface::initialize.
* include/abg-elf-reader.h (reader::initialize): Rename
elf_reader::reset into this. Add a new virtual overload that
implements fe_iface::initialize.
* include/abg-fe-iface.h (fe_iface::initialize): Rename
fe_iface::reset into this and make it virtual.
* src/abg-btf-reader.cc (btf::reader::initialize): Adjust call to
elf_based_reader::reset to elf_based_reader::initialize.
* src/abg-ctf-reader.cc (ctf::reader::initialize): Likewise.
* src/abg-dwarf-reader.cc (dwarf::reader::initialize): Likewise.
* src/abg-elf-based-reader.cc (elf_based_reader::initialize):
Rename elf_based_reader::reset into this. Adjust call to
elf::reader::reset into elf::reader::initialize. Add a new
virtual overload that implements fe_iface::initialize.
* src/abg-elf-reader.cc (reader::initialize): Rename
elf::reader::reset into this. Adjust call to fe_iface::reset into
fe_iface::initialize. Add a new virtual overload that implements
fe_iface::initialize.
* src/abg-fe-iface.cc (fe_iface::priv::initialize): Reset the
corpus too.
(fe_iface::initialize): Rename fe_iface::reset into this. Invoke
priv::initialize and set the new corpus_path.
2023-07-06 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: Fix previous commit
* tools/fedabipkgdiff (Brew::__init__): Do not try to access the
'opts' attribute on sessions that don't have any.
2023-07-06 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: Don't choke Koji servers with self-signed SSL certs
* fedabipkgdiff (Brew::__init__): Se the "no_ssl_verify" option to
false by default.
2023-06-21 Dodji Seketeli <dodji@redhat.com>
Bug 30461 - insight fails self-compare
* src/abg-dwarf-reader.cc (build_ir_node_from_die): If we are
looking at a cloned function that's a member function to be added
to an existing class, make sure a member function with the same
linkage name doesn't already exist in the class before adding this
one. Otherwise, we'd be duplicating a member function inside the
class.
* src/abg-ir.cc (method_decl::set_linkage_name): When setting the
linkage name of a method to a new one, erase the old method that
had the old linkage name from the containing class.
(compare_canonical_type_against_candidate): Clear the comparison
type result cache after each type canonicalization to avoid
re-using cached result that should have been invalidated. This is
a work-around the more fundamental type canonicalization issue
outlined in the preamble of this commit log.
* src/abg-reader.cc (build_function_decl): Avoid loading
duplicated member functions. The key of the function being its
mangled name.
(build_class_decl): The XML node to map when looking a member
function is really the XML node for the member function.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2023-06-06 Matthias Maennich <maennich@google.com>
symtab reader: fix symtab iterator to support C++20
* abg-symtab-reader.h (symtab_iterator): Specify
iterator_concept as forward_iterator to support C++20 compilation.
2023-06-06 Matthias Maennich <maennich@google.com>
symtab reader: use C++11 `using` syntax instead of typedefs
* abg-symtab-reader.h: replace typedefs by corresponding using
declarations.
2023-06-07 Dodji Seketeli <dodji@redhat.com>
Bug 30503 - Fail to compare non-anonymous struct vs named struct data members
* src/abg-ir.cc (get_decl_name_for_comparison): Do not use
scope_anonymous_or_typedef_named. Rather, use
decl_base::get_has_anonymous_parent instead.
(scope_anonymous_or_typedef_named): Remove this as it's not used
anymore.
* include/abg-fwd.h (scope_anonymous_or_typedef_named): Remove
this declaration as the definition has been removed.
* tests/data/test-abidiff-exit/PR30503/libsdl/1.2.60/lib64/libSDL-1.2.so.1.2.60:
New test input file.
* tests/data/test-abidiff-exit/PR30503/libsdl/1.2.60/lib64/libSDL-1.2.so.1.2.60.debug:
Likewise.
* tests/data/test-abidiff-exit/PR30503/libsdl/1.2.64/lib64/libSDL-1.2.so.1.2.64:
Likewise.
* tests/data/test-abidiff-exit/PR30503/libsdl/1.2.64/lib64/libSDL-1.2.so.1.2.64.debug:
Likewise.
* tests/data/test-abidiff-exit/PR30503/libsdl/libsdl-1.2.60-1.2.64-report.txt:
Likewise.
* tests/data/Makefile.am: Add the new test inputs above to source
distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new test
inputs above to this test harness.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
2023-06-05 Dodji Seketeli <dodji@redhat.com>
configure.ac: Bump to 2.4 version
* configure.ac: Bump library version number to 2.4. Bump SONAME's
current number to 3.
2023-06-05 Dodji Seketeli <dodji@redhat.com>
Bug 30467 - enlightenment fails self check on f38
* src/abg-ir-priv.h (environment::priv::cancel_ct_propagation):
Clear the type comparison results cache.
2023-05-25 Dodji Seketeli <dodji@redhat.com>
Bug 30466 - harfbuzz fails self-check on f38
* include/abg-fwd.h (is_pointer_to_decl_only_class_or_union_type)
(is_reference_to_decl_only_class_or_union_type)
(is_typedef_to_decl_only_class_or_union_type)
(is_void_pointer_type_equivalent, is_unique_type): Declare new
functions.
(is_typedef, is_void_pointer_type): Declare new overloads.
(is_declaration_only_class_or_union_type): Add a new
look_through_decl_only flag as parameter.
* include/abg-ir.h (environment::{get_void_pointer_type,
is_void_pointer_type}): Define new member functions.
* src/abg-ir-priv.h (environment::priv::{void_pointer_type}): Add
new data member.
* src/abg-ir.cc (decl_topo_comp::operator()): For unique types,
use lexicographic sorting.
(environment::{get_void_pointer_type, is_void_pointer_type}):
Define new member function.
(is_typedef, is_pointer_to_decl_only_class_or_union_type)
(is_reference_to_decl_only_class_or_union_type)
(is_typedef_to_decl_only_class_or_union_type, is_unique_type):
Define new functions.
(is_declaration_only_class_or_union_type): Add a new
look_through_decl_only parameter. Some decl-only class or union
do have an associated definition; this function return false for
these types if look_through_decl_only is set to true.
(is_void_pointer_type_equivalent): Rename is_void_pointer_type
into this.
(is_void_pointer_type): Now that is_void_pointer_type equals is
old version of this is_void_poitner, make the new version test if
the type equals the unique void pointer type, or if it a pointer
to void type. It doesn't take typedefs into account, like what
is_void_pointer_type_equivalent does.
(equals): In the overload for pointer_type_def, use the new
is_void_pointer_type_equivalent instead of
is_void_pointer_type_equivalent.
(is_non_canonicalized_type): Re-organize this. Now, all unique
types are non-canonicalized. This was sort-of the case already
but was not clearly stated as such. The decl-only class-or-union
types were already non-canonicalized, but pointers and typedefs to
class-or-unions should also be non-canonicalized for the system to
work because a decl-only class-or-unions equals all defined types
in C++.
* src/abg-btf-reader.cc
(reader::build_ir_node_for_void_pointer_type): Define new member
function that return a unique type for void pointer types.
(reader::build_pointer_type): Use
build_ir_node_for_void_pointer_type to build void pointer types.
(reader::{build_ir_node_for_void_type,
build_ir_node_for_variadic_parameter_type}): Simplify.
* src/abg-ctf-reader.cc (build_ir_node_for_void_type)
(build_ir_node_for_void_pointer_type): Define new functions.
(process_ctf_function_type): Use build_ir_node_for_void_type for
void types.
(process_ctf_pointer_type): Use
build_ir_node_for_void_pointer_type for void pointer types.
* src/abg-dwarf-reader.cc (build_ir_node_for_void_pointer_type):
Define a new function that returns a unique type for void pointer
types.
(build_pointer_type_def): Use the new
build_ir_node_for_void_pointer_type to build void pointers.
(build_ir_node_for_variadic_parameter_type): Simplify.
* src/abg-reader.cc (read_type_id_string): Define this even
not debugging self-comparison.
(build_ir_node_for_void_type)
(build_ir_node_for_void_pointer_type): Define new functions.
(reader::{get_scope_for_node, get_scope_ptr_for_node}): New member
functions.
(reader::push_decl_to_current_scope): Remove this member function.
This was using the scope of the last IR node built as the current
scope. The problem is that the scope of a unique IR node is the
scope where it was used the first time; that has nothing to do
with the current scope. So this function is obsolete now that we
are using unique IR nodes for real.
(reader::push_decl_to_scope): New member function. This is the
one to use, now that push_decl_to_current_scope is no more.
(reader::push_and_key_type_decl): Pass the scope_decl to use.
Make this push the decl to the scope passed in parameter. Add an
overload that has the XML node to use to determine the scope to
push the decl to.
(reader::get_scope_for_node): Support template parameter type
composition nodes. Also, add an overload that takes just an XML
node.
(reader::get_scope_ptr_for_node): Define new member function.
(build_namespace_decl, build_function_decl, build_var_decl): Use
to reader::push_decl_to_scope, now that
reader::push_decl_to_current_scope is gone.
(build_type_decl): Use build_ir_node_for_void_type to build a void
type. Adjust the call to reader::push_and_key_type_decl.
(build_qualified_type_decl, build_reference_type_def)
(build_subrange_type, build_array_type_def, build_enum_type_decl)
(build_typedef_decl, build_class_decl, build_union_decl)
(build_function_tdecl, build_function_tdecl, build_class_tdecl)
(build_type_tparameter, build_type_composition)
(build_non_type_tparameter, build_template_tparameter): Adjust the
call to reader::push_and_key_type_decl.
(build_pointer_type_def): Likewise. Use
build_ir_node_for_void_pointer_type to build a void pointer IR
node. Also, build the pointed-to-type before the pointer type
itself; this is required to catch a void pointer type early and
use build_ir_node_for_void_pointer_type to build it.
* src/abg-comp-filter.cc (has_void_ptr_to_ptr_change): Use the new
is_void_pointer_type_equivalent in lieu of is_void_pointer_type.
This is because the former takes typedefs into account and so is
more accurate.
* src/abg-comparison.cc
(scope_diff::ensure_lookup_tables_populated): Do not consider
unique types when accounting for added/removed types.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-read-btf/test1.o.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test17.xml: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test19.xml: Likewise.
* tests/data/test-read-write/test20.xml: Likewise.
* tests/data/test-read-write/test21.xml: Likewise.
* tests/data/test-read-write/test22.xml: Likewise.
* tests/data/test-read-write/test23.xml: Likewise.
* tests/data/test-read-write/test26.xml: Likewise.
* tests/data/test-read-write/test27.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2023-05-17 Dodji Seketeli <dodji@redhat.com>
Bug 29693 - clang-libs from f37 fails self test
* src/abg-reader.cc (build_class_decl): Read member types even
when we are looking at a decl-only class.
2023-05-11 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Don't compute canonical type while propagating one
* src/abg-dwarf-reader.cc (propagate_canonical_type): If the
source (right-hand-side) type has no canonical type, do not
compute it and thus, do not try to propagate its canonical type to
the destination (left-hand-side) type.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
2023-05-01 Dmitry V. Levin <ldv@strace.io>
elf-helpers: make sure config.h is included first
* src/abg-elf-helpers.cc: Include "config.h" first.
Fixes: 7bd69830520f ("Make Front Ends first class citizens")
2023-05-10 Dodji Seketeli <dodji@redhat.com>
release-text-template.txt: Modernize a little bit.
* release-text-template.txt: Update this for the new xz tarball
format and add highlights.
2023-04-27 Dodji Seketeli <dodji@redhat.com>
Update website for the 2.3 release
* doc/website/mainpage.txt: Update for 2.3.
2023-04-27 Dodji Seketeli <dodji@redhat.com>
NEWS: Update for 2.3 release
* NEWS: Update using "git shortlog libabigail-2.2..HEAD".
2023-04-27 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 2.3 release
* ChangeLog: Update using the 'make update-changelog' command.
2023-04-27 Dodji Seketeli <dodji@redhat.com>
test-ini: Fix a typo
* tests/test-ini.cc (in_out_specs): Fix a typo near the last
record of the array.
2023-04-26 Dodji Seketeli <dodji@redhat.com>
ini: Do not crash on incorrect property value
* src/abg-ini.cc (read_context::read_property_value): Do not
dereference a null pointer to list property value.
* tests/data/test-ini/test02-buggy-property-value.abignore: New
test input.
* tests/data/test-ini/test02-buggy-property-value.abignore.expected:
Likewise.
* tests/data/Makefile.am: Add the two new test inputs to source
distribution.
* tests/test-ini.cc (in_out_spec): Add the new test input pair to
this test harness.
2023-04-26 Dodji Seketeli <dodji@redhat.com>
test-abidiff-exit: Fix the command line passed to abidiff
* tests/test-abidiff-exit.cc (main): Reset the headers directories
passed to abidiff at each iteration.
2023-04-26 Dodji Seketeli <dodji@redhat.com>
Fix the test of the patch for Bug 30309
* tests/data/Makefile.am: Add
test-abidiff-exit/PR30329/PR30329-report-1.txt to source
distribution.
2023-04-25 Dodji Seketeli <dodji@redhat.com>
Bug 30309 - Support absolute path to alt debug info file in DWARF
* src/abg-elf-reader.cc (find_alt_dwarf_debug_info_path): Trim the
"/usr/lib/debug" prefix from the alt dwarf file path, if it was
provided. The function is going to look for the alt dwarf file
under the debug info root file instead.
* src/abg-tools-utils.cc (entry_of_file_with_name): Add a
parameter for the path to the root directory under which the files
visit is taking place. Then, consider the file path being looked
for as being relative to the root directory under which the files
visit is taking place.
* tests/data/test-abidiff-exit/PR30329/new-image/usr/lib/debug/dwz/components/sqlite.bst/x86_64-unknown-linux-gnu:
New test input.
* tests/data/test-abidiff-exit/PR30329/new-image/usr/lib/debug/usr/lib/x86_64-linux-gnu/libsqlite3.so.0.8.6.debug:
Likewise.
* tests/data/test-abidiff-exit/PR30329/new-image/usr/lib/x86_64-linux-gnu/libsqlite3.so.0.8.6:
Likewise.
* tests/data/test-abidiff-exit/PR30329/old-image/usr/lib/debug/dwz/components/sqlite.bst/x86_64-unknown-linux-gnu:
Likewise.
* tests/data/test-abidiff-exit/PR30329/old-image/usr/lib/debug/usr/lib/x86_64-linux-gnu/libsqlite3.so.0.8.6.debug:
Likewise.
* tests/data/test-abidiff-exit/PR30329/old-image/usr/lib/x86_64-linux-gnu/libsqlite3.so.0.8.6:
Likewise.
* tests/data/test-abidiff-exit/PR30329/PR30329-report-1.txt:
Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (InOutSpec::in_elfv{0,1}_debug_dir):
New data members. Carry the debuginfo root dirs for the input
binaries.
(in_out_specs): Update the existing to adjust for the new
InOutSpec::in_elfv{0,1}_debug_dir data members. Also, add a new
entry for this new test case.
(main): Pass the root debug info dirs to abidiff.
2023-04-21 Dodji Seketeli <dodji@redhat.com>
reader: Recognize variadic parameter type from abixml
* include/abg-ir.h (environment::get_variadic_parameter_type_name)
Declare ...
* src/abg-ir.cc (environment::get_variadic_parameter_type_name):
... a new static member function.
(environment::get_variadic_parameter_type): Use
the new environment::get_variadic_parameter_type_name rather than
using an open coded constant here.
* src/abg-dwarf-reader.cc
(die_return_and_parm_names_from_fn_type_die): Likewise.
* src/abg-reader.cc (build_type_decl): For a variadic parameter
type, return
abigail::ir::environment::get_variadic_parameter_type() rather
than building a new type.
* tests/data/test-read-ctf/test2.so.abi: Adjust.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
2023-04-19 Dodji Seketeli <dodji@redhat.com>
ir: fix canonical type propagation canceling error
* src/abg-ir-priv.h
(environment::priv::{confirm_ct_propagation_for_types_dependant_on,
confirm_ct_propagation_for_types_dependant_on}): Asserting that
the type should be recursive is wrong because the recursive-ness
flag is set to false upon confirmation of the canonical type
propagation. So there can be some types that would make this
assertion fail before we reach the end of the set of types to
confirm the propagation for.
(environment::priv::cancel_ct_propagation): Cancel the canonical
type propagation for all types we are instructed to cancel, not
just for types that are recursive or depends on recursive types.
This is because the the recursive-ness flag is set to false upon
cancellation of the canonical type propagation. So there can be
some types that would make this condition fail before we reach the
end of the set of types to cancel the propagation for.
(environment::priv::cancel_all_non_confirmed_propagated_canonical_types):
Define new member function.
* src/abg-ir.cc (return_comparison_result): Confirm the
speculative canonical type propagation result when we are done
comparing the current type and the result of the comparison is
true. Let's not try to be smart here. Just be safe. This
optimization is fast enough as is. Otherwise, if the result of
the comparison is false, then all the speculatively propagated
canonical types of all the non-confirmed types should be canceled.
All of them. Again, let's not try to be smart. This is smart &
fast enough as is. And thing are going to be correct this way.
2023-04-19 Dodji Seketeli <dodji@redhat.com>
comparison: Fix index error when interpreting scope comparison
* src/abg-comparison.cc
(scope_diff::ensure_lookup_tables_populated): Use the proper index
to address the deleted decl. Also, use the range-based for syntax
in the enclosing for-loop for more clarity.
2023-04-19 Dodji Seketeli <dodji@redhat.com>
writer: Annotate pointer representation
* src/abg-writer.cc (write_pointer_type_def): Invoke annotate.
Add a temporary for the output of write_context::get_id_for_type.
It makes it easier to inspect in the debugger.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-annotate/test1.abi: Adjust.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-annotate/test5.o.abi: Adjust.
2023-04-19 Dodji Seketeli <dodji@redhat.com>
ir: Improve debugging type_base::get_canonical_type_for
* src/abg-ir.cc (compare_types_during_canonicalization): Adjust
this to make it take const type_base& rather than const
type_base_sptr.
(compare_canonical_type_against_candidate): Factorize this out of
...
(type_base::get_canonical_type_for): ... here.
2023-04-19 Dodji Seketeli <dodji@redhat.com>
Improve self-comparison debug mode
* include/abg-ir.h
(environment::{get_type_id_canonical_type_map}): Const-ify the
existing member function and add non-const overloads.
(environment::{get_type_id_from_pointer,
get_canonical_type_from_type_id}): Const-ify.
(environment::get_pointer_type_id_map): Add new member function.
* src/abg-ir-priv.h
(environment::priv::{confirm_ct_propagation_for_types_dependant_on,
confirm_ct_propagation}): Call
check_abixml_canonical_type_propagation_during_self_comp() here.
(environment::priv::{get_type_id_canonical_type_map,
get_pointer_type_id_map, get_type_id_from_pointer,
get_type_id_from_type, get_canonical_type_from_type_id,
check_abixml_canonical_type_propagation_during_self_comp}): Add
new member functions.
* src/abg-ir.cc (return_comparison_result): Call
check_abixml_canonical_type_propagation_during_self_comp on every
single type with non confirmed propagated canonical type.
(environment::{get_type_id_canonical_type_map,
get_pointer_type_id_map, get_type_id_from_pointer,
get_type_id_from_type, get_canonical_type_from_type_id}): Delegate
to the new implementations that are now member functions of
environment::priv.
(type_base::get_canonical_type_for): Fix typo in diagnostics when
debugging self-comparison. Add more context.
* src/abg-reader.cc
(abixml::reader::maybe_check_abixml_canonical_type_stability):
Likewise.
* src/abg-writer.cc (write_type_record): Do not try to get abixml
type-id for a type (originating from the DWARF) that has no
canonical type, otherwise, that /can/ introduce a gap in the
type-ids as those can turn out not being emitted in the abixml
after all.
2023-04-21 Dodji Seketeli <dodji@redhat.com>
tests/update-test-output.py: Adapt to some broken test output
* tests/update-test-output.py (process): Don't expect the start
pattern of the main diff hunk to begin at the end of a line
because that can be broken for runtestreaddwarf and co.
2023-04-14 Mark Wielaard <mark@klomp.org>
doc: Fix some typos and add some missing references
* doc/manuals/abidiff.rst: Add Linux Kernel reference.
* doc/manuals/abipkgdiff.rst: Likewise.
* doc/manuals/abidw.rst: Add space between `BTF`_ and formats.
Rename _abidiff_invocation_label to _abidw_invocation_label.
* doc/manuals/libabigail-concepts.rst: Add empty line between
_suppr_has_size_change_property_label and has_size_change.
* doc/manuals/libabigail-overview.rst: Extend title overlines.
2023-04-13 Dodji Seketeli <dodji@redhat.com>
ir: Recognize "void* as being equal to all other pointers in C
* include/abg-fwd.h (is_void_pointer_type): Declare new function.
* src/abg-ir.cc (is_void_pointer_type): Define new function.
(equals): In the overload for pointer_type_def, handle the special
case pointer to void, making it equal to all other pointer, for
the C language.
(is_non_canonicalized_type): pointer to void is no more
canonicalized as it can be equal to all other types.
* tests/data/test-annotate/libtest23.so.abi: Adjust
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test47-filter-void-ptr-change-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2023-04-13 Dodji Seketeli <dodji@redhat.com>
ir: Add new environment::get_type_id_from_type
* include/abg-ir.h (environment::get_pointer_type_id_map): Declare
...
* src/abg-ir.cc (environment::get_pointer_type_id_map): ... this
new member function.
2023-04-13 Dodji Seketeli <dodji@redhat.com>
abidiff,reader: Fix compilation with --debug-self-comparison
* src/abg-reader.cc
(reader::{maybe_check_abixml_canonical_type_stability, read_corpus}):
get_environment() doesn't returns a pointer anymore. So adapt the
code.
(maybe_map_type_with_type_id): Adjust because the environment is
const.
(load_canonical_type_ids): The xml_reader namespace doesn't exist
anymore. It's now abixml.
* tools/abidiff.cc (options::options): Initialize the
do_debug_self_comparison data member before the use_btf one, as it
should be.
2023-04-11 Dodji Seketeli <dodji@redhat.com>
abi{dw,diff}: Better error messages when alternate debuginfo not found
* tools/abidiff.cc (handle_error): Handle cases where the
fe_iface::STATUS[_ALT]_DEBUG_INFO_NOT_FOUND bits are set. Refer to
the alternate debug info file in the error message.
* tools/abidw.cc (load_corpus_and_write_abixml): Do not clear the
reader before emitting the error message, rather clear it after.
Also, refer to the alternate debug info file in the error message.
2023-04-07 Dodji Seketeli <dodji@redhat.com>
Bug 29339 - elf-helpers: Don't crash on unexpected ELF file
* src/abg-elf-helpers.cc (get_soname_of_elf_file): If the program
header we are looking at is not what we expect, just skip it; do
not abort.
2023-04-07 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: Remove busy loop when forking abipkgdiff
* tools/fedabipkgdiff (abipkgdiff): Remove the busy looping and
use subprocess.communicate() instead.
2023-04-07 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: Add timing data in debug logs
* tools/fedabipkgdiff (log_call): Log the time taken by the
decorated function.
2023-04-07 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support indirectly referenced subrange_type DIEs
* src/abg-dwarf-reader.cc (subrange_die_indirect_bound_value)
(subrange_die_indirectly_references_subrange_die): Define new
static function.
(build_subrange_type): If the value of DW_AT_upper_bound is not a
constant, try to consider it as an indirect reference to a
DW_TAG_subrange_type DIE, whose DW_AT_upper_bound might carry the
constant value that we are looking for.
2023-04-04 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix typo in comment
* src/abg-dwarf-reader.cc (reader::get_canonical_die): Fix typo in
comment.
2023-04-05 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support DW_OP_GNU_variable_value
* src/abg-dwarf-reader.cc (op_pushes_non_constant_value): Support
DW_OP_GNU_variable_value.
(op_is_arith_logic): Add a number of asserts and guards here.
2023-04-04 Dodji Seketeli <dodji@redhat.com>
reader: Make reader::get_scope_for_node handle subranges at array scope.
* src/abg-reader.cc (reader::get_scope_for_node): A subrange
at array scope is meant to be in the scope of the array.
2023-04-04 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Don't use user-specific filesystem info in error msg
* tools/abipkgdiff.cc (get_pretty_printed_list_of_packages): Emit
base names of packages, not the absolute filesystem path.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64-self-report-0.txt:
Adjust.
2023-04-04 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support Ada subranges having upper_bound < lower_bound
* src/abg-dwarf-reader.cc (build_subrange_type): Be aware that
the upper_bound can be lower than lower_bound.. This most
likely means the length of the subrange is zero.
* src/abg-ir.cc (array_type_def::subrange_type::get_length): If
lower_bound > upper_bound, then length is zero. This is Ada
lingo.
* src/abg-writer.cc (write_array_subrange_type): Always emit
lower_bound and upper_bound. Acknowledge that if lower_bound >
upper_bound, it means length is zero.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-read-btf/test0.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-array-mdimension.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-array-size.abi: Likewise.
* tests/data/test-read-ctf/test-const-array.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
2023-04-03 Dodji Seketeli <dodji@redhat.com>
Bug rhbz#2182807 -- abipkgdiff crashes on missing debuginfo package
* src/abg-fe-iface.cc (status_to_diagnostic_string): Remove the
newline from the end of the returned diagnostic string.
* tools/abipkgdiff.cc (get_pretty_printed_list_of_packages)
(emit_alt_debug_info_not_found_error): Define new static
functions.
(compare, compare_to_self): Add an ostream& parameter as a
destination of diagnostic messages. If the
abigail::fe_iface::STATUS_ALT_DEBUG_INFO_NOT_FOUND bit is set in
the status code, emit the explanatory message to output stream
associated to the current comparison task. Remove the previous
handling of this case.
(compare_task::maybe_emit_pretty_error_message_to_output): Define
new member function to get the output stream associated to the
current task massage it and stick to result into the pretty output
string to be emitted to the user in the end, namely the
compare_task::pretty_output string data member.
({compares, self_compare}_task::perform): Adjust this to call the
new maybe_emit_pretty_error_message_to_output in case of error.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64-self-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/test-dbus-glib-0.80-3.fc12.x86_64-report-0.txt:
Likewise.
2023-03-31 Dodji Seketeli <dodji@redhat.com>
Fix redundancy filtering of range types
* src/abg-comparison.cc (redundancy_marking_visitor::visit_end):
Propagate redundancy category to function parameter diff nodes if
they don't carry any local non-type change.
* src/abg-default-reporter.cc
(default_reporter::report_underlying_changes_of_qualified_type):
Define new member function.
(default_reporter::report): In the qualified_type_diff overload,
use the new report_underlying_changes_of_qualified_type above.
* src/abg-ir.cc (types_have_similar_structure): If two arrays are
accessed indirectly and if they have size and dimension changes,
then the two arrays are considered having a similar structure.
Otherwise, if they are accessed directly, having size or dimension
change make them considered as having non similar structure. This
has an impact on if a change between two array types is considered
local or not.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Local changes
to underlying types of a qualified type are considered local to
the qualified type. This change reflects that in the overload for
qualified type diff nodes. Otherwise, we won't report what would
otherwise be a leaf change to the a qualified type, just because
it's actually a leaf change to the underlying type of the
qualified type.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/test2-ada-subrange-redundant-report-{1,2}.txt:
New reference output files.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/v0/test.ad{b,s}:
Source code for the new binary input below.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/v0/test.o:
New binary input file.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/v1/test.ad{b,s}:
Source code for the new binary input below.
* tests/data/test-abidiff-exit/ada-subrange/test2-ada-subrange-redundant/v1/test.o:
New binary input file.
* tests/data/Makefile.am: Add the new test input files above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new input
tests above to this test harness.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-1.txt:
Adjust.
2023-03-30 Dodji Seketeli <dodji@redhat.com>
Bug 29340 - Add support for Ada range types
* configure.ac: Bump the abixml version to 2.2 from 2.1
* include/abg-comparison.h (diff_maps::get_subrange_diff_map):
Declare new member functions.
(class subrange_diff): Define new class.
(subrange_diff_sptr): Define new typedef.
(compute_diff): New overload for subrange_diff.
(is_subrange_diff): Declare new function.
* include/abg-ir.h (equals): Declare an overload for
subrange_type.
* include/abg-reporter.h (reporter_base::report): Declare an
overload for subrange_diff.
(default_reporter::report_underlying_changes_of_qualified_type):
Declare member function.
(leaf_reporter::report): Declare and overload for subrange_diff.
Declare new member function.
* include/abg-tools-utils.h
(get_anonymous_subrange_internal_name_prefix): Declare new function.
* src/abg-comparison-priv.h (struct subrange_diff::priv): Define
new type.
* src/abg-comparison.cc (diff_maps::priv::subrange_diff_map_):
Define data member.
(diff_maps::get_subrange_diff_map): Define member function.
(is_subrange_diff, compute_diff): Define new functions.
(compute_diff_for_types): Handle array_type::subrange_type types.
(subrange_diff::{subrange_diff, first_subrange, second_subrange,
get_pretty_representation, has_changes, has_local_changes, report,
chain_into_hierarchy}): Define member functions.
(diff_maps::insert_diff_node): Handle subrange diff nodes.
(corpus_diff::priv::count_leaf_type_changes): Count subranges diff
nodes.
* src/abg-default-reporter.cc (default_reporter::report): Define
an overload for subrange_diff.
* src/abg-ir.cc (has_generic_anonymous_internal_type_name):
Support subrange types.
* src/abg-leaf-reporter.cc (report_type_changes_from_diff_maps):
Report about subrange types.
(leaf_reporter::report): Define and overload for subrange_diff
nodes.
* src/abg-reader.cc (build_subrange_type): Add a boolean to add
the subrange type to the current scope.
(build_array_type_def): Adjust when calling build_subrange_type.
(build_type): Support building subrange types.
* src/abg-reporter-priv.cc (represent): Define a new overload for
the subrange_diff type.
* src/abg-reporter-priv.h (represent): Declare a new overload for
the subrange_diff type.
* src/abg-tools-utils.cc (ANONYMOUS_SUBRANGE_INTERNAL_NAME)
(ANONYMOUS_SUBRANGE_INTERNAL_NAME_LEN): Define new static const
variables.
(get_anonymous_subrange_internal_name_prefix): Define new
function.
* src/abg-writer.cc (write_array_subrange_type): Define new static
function.
(write_decl): Support emitting subrange_types.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-1.txt:
New reference output.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/test1-ada-subrange-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/v0/test1.ad{b,s}:
Source code of the input binary below.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/v0/test1.o:
New input test.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/v1/test1.ad{b,s}:
Source code of the input binary below.
* tests/data/test-abidiff-exit/ada-subrange/test1-ada-subrange/v1/test1.o:
New input test.
* tests/data/Makefile.am: Add the new test files to source
distributions.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new tests
input above to this test harness.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-btf/test0.o.abi: Likewise.
* tests/data/test-read-btf/test1.o.abi: Likewise.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-alias.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-array-mdimension.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-array-size.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield.abi: Likewise.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-const-array.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise.
* tests/data/test-read-ctf/test-fallback.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi:
Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/PR28584/PR28584-smv.clang.o.abi:
Likewise.
* tests/data/test-read-dwarf/PR29443-missing-xx.o.abi: Likewise.
* tests/data/test-read-dwarf/PR29692-kdelibs3-libkjava.so.1.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-fallback.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test-crc.xml: Likewise.
* tests/data/test-read-write/test26.xml: Likewise.
* tests/data/test-read-write/test27.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml: Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2023-03-28 Ben Woodard <woodard@redhat.com>
Have fedabipkgdiff sleep while waiting for abipkgdiff
* tools/fedabipkgdiff (abipkgdiff): add sleep while waiting for
subprocess completion. Also, update copyright year notice to 2023.
2023-03-27 Dodji Seketeli <dodji@redhat.com>
Bug 29345 - abipkgdiff is confused by symlinked binaries in RPMs
* tools/abipkgdiff.cc (create_maps_of_package_content): Resolve
symlinks when mapping binaries. Don't map a binary that has
already been seen.
2023-03-24 Dodji Seketeli <dodji@redhat.com>
Bug 29686 - Fix testing the presence of anonymous data member in a struct
* include/abg-fwd.h (anonymous_data_member_to_class_or_union): Add
a new overload.
(anonymous_data_member_exists_in_class): Declare new function.
* src/abg-dwarf-reader.cc (add_or_update_class_type): Use the new
anonymous_data_member_exists_in_class function.
* src/abg-ir.cc (anonymous_data_member_to_class_or_union): Define
new function.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
2023-03-24 Dodji Seketeli <dodji@redhat.com>
Bug 29690 - Out of range exception in add_or_update_class_type
* src/abg-dwarf-reader.cc (add_or_update_class_type): Make sure
the array is big enough.
2023-03-24 Dodji Seketeli <dodji@redhat.com>
test-symtab: Update after support for empty symtabs
* tests/test-symtab.cc (TEST_CASE("Symtab::Empty", "[symtab,
basic]")): Adjust.
(TEST_CASE("Symtab::NoDebugInfo", "[symtab, basic]")): Likewise.
2023-03-22 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Fix a typo
* tools/abipkgdiff.cc (compare_to_self): Fix a typo.
2023-03-22 Dodji Seketeli <dodji@redhat.com>
Bug 29692 - Support binaries with empty symbol table
* src/abg-dwarf-reader.cc (reader::read_debug_info_into_corpus):
Get out early also upon having an empty symbol table.
* src/abg-elf-reader.cc (reader::read_corpus): Error out only if
there is no symbol table for the binary. If an empty symbol table
is found however, that is not an error.
* tests/data/test-read-dwarf/PR29692-kdelibs3-libkjava.so.1.0.0:
New binary test input.
* tests/data/test-read-dwarf/PR29692-kdelibs3-libkjava.so.1.0.0.abi:
New expected abixml file.
* tests/data/Makefile.am: Add the new input test files to source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the new test inputs
above to this test harness.
2023-03-21 Dodji Seketeli <dodji@redhat.com>
Bug 29911 - fedabipkgdiff forgets to provide some debuginfo RPMs to abipkgdiff
* tools/abipkgdiff.cc (compare_to_self): Emit an error message
when in verbose mode, for cases where we fail to find the
alternate debug info.
* tools/fedabipkgdiff (generate_comparison_halves): Always provide
all associated debuginfo packages to abipkgdiff.
2023-03-17 Dodji Seketeli <dodji@redhat.com>
Bug 29912 - Better support an ELF symbol alias that designates several functions
* include/abg-corpus.h (corpus::lookup_functions): Return a set of
functions rather than a vector of functions where a function can
be present more than once. This allows to determine if a symbol
designates more than one function.
(corpus::exported_decls_builder::priv_): Make this public so that
some outside code can access it.
(corpus::exported_decls_builder::fn_id_maps_to_several_fns):
Declare new function.
(corpus::exported_decls_builder::maybe_add_fn_to_exported_fns):
Remove useless const here.
* include/abg-fwd.h (get_function_id_or_pretty_representation):
Declare new function.
* include/abg-ir.h
(elf_symbol::get_alias_with_default_symbol_version): Declare new
member function.
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Use the new
get_function_id_or_pretty_representation rather than
function_decl::get_id() to identify a function.
* src/abg-corpus-priv.h (str_fn_ptr_set_map_type): Define this new
typedef of unordered_map<string, std::unordered_set<function_decl*> >.
(corpus::exported_decls_builder::priv::id_fns_map_): Change the
type of this to the new str_fn_ptr_set_map_type.
(corpus::exported_decls_builder::priv::{id_fns_map, fn_id_is_in_id_fns_map,
fn_is_in_fns, fn_is_in_id_fns_map}): Adjust to using a set of
functions rather than a vector.
(corpus::exported_decls_builder::fn_is_in_fns_by_repr): Define new
static function.
(corpus::exported_decls_builder::add_fn_to_exported): Remove
useless const.
* src/abg-corpus.cc
(corpus::exported_decls_builder::fn_id_maps_to_several_fns):
Define new function.
(corpus::exported_decls_builder::maybe_add_fn_to_exported_fns):
Remove useless const.
(corpus::lookup_functions): Return a set of functions rather than
a vector of functions where a function can be present more than
once. This allows to determine if a symbol designates more than
one function.
* src/abg-dwarf-reader.cc
(reader::symbol_already_belongs_to_a_function): Adjust.
* src/abg-fe-iface.cc (fe_iface::maybe_add_fn_to_exported_decls):
Adjust.
* src/abg-ir.cc (get_function_id_or_pretty_representation): Define
new function.
2023-03-13 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,abidiff: Fix compilation with --enable-debug-type-canonicalization
* src/abg-dwarf-reader.cc (reader::initialize): Use env(). rather
than environment->.
* tools/abidiff.cc (options::options): Initialize
do_debug_type_canonicalization() before use_btf.
2023-03-13 Dodji Seketeli <dodji@redhat.com>
Bug 29977 - dwarf-reader: Fix canonical DIE propagation canceling
* src/abg-dwarf-reader.cc
(offset_pairs_stack_type::cancel_canonical_propagated_type): The
result of comparing the canonical-propagated types being canceled
is either COMPARISON_RESULT_UNKNOWN or
COMPARISON_RESULT_DIFFERENT. Also, do not forget to update the
cached value for the comparison of the depend types too.
2023-03-09 Dodji Seketeli <dodji@redhat.com>
ir: Fix cycle detection for union types
* src/abg-ir.cc (CACHE_COMPARISON_RESULT_AND_RETURN): Define new
macro.
(equals): In the overload for unions, detect cycles right
away. Also, do not use mark_types_as_being_compared and
return_comparison_result as that would indirectly call
environment::priv::unmark_as_being_compared one too many, thus
breaking the cycle detection machinery. Rather, just cache the
result of comparing the type as a class_or_union and return, using
CACHE_COMPARISON_RESULT_AND_RETURN.
2023-03-08 Dodji Seketeli <dodji@redhat.com>
tools-utils: Improve logging in build_corpus_group_from_kernel_dist_under
* src/abg-tools-utils.cc
(build_corpus_group_from_kernel_dist_under): Improve logging.
2023-03-06 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
tools-utils: Fix looking for vmlinux binary in debuginfo package
* src/abg-tools-utils.cc
(get_binary_paths_from_kernel_dist): Fix a thinko and really use
the kernel_modules_root variable. Look for modules under
kernel_modules_root and look for vmlinux (if necessary) under
debug_info_root. Add comments.
(compare_prepared_linux_kernel_packages): Fix another thinko. Now
we do have the path to vmlinux, from debuginfo packages before
getting into get_binary_paths_from_kernel_dist.
2023-02-16 Dodji Seketeli <dodji@redhat.com>
comp-filter: Speed up harmless/harmful categorization
* src/abg-comp-filter.cc
(class_diff_has_harmless_odr_violation_change)
(has_var_type_cv_qual_change): Avoid doing structural comparison
here.
2023-02-16 Dodji Seketeli <dodji@redhat.com>
comparison: When marking leaf nodes don't do unnecessary impact analysis
* src/abg-comparison.cc (corpus_diff::mark_leaf_diff_nodes): If
impact analysis is not required, visit each node just once.
2023-02-16 Dodji Seketeli <dodji@redhat.com>
comparison: Add a mode to not apply filters on interface sub-graphs
* doc/manuals/abidiff.rst: Document the new
--no-change-categorization option.
* doc/manuals/kmidiff.rst: Likewise.
* include/abg-comparison.h
(diff_context::perform_change_categorization): Declare new
accessor member functions.
* src/abg-comparison-priv.h
(diff_context::priv::perform_change_categorization_): Add new data
member.
(diff_context::priv::priv): Initialize the new data member.
* src/abg-comparison.cc
(diff_context::perform_change_categorization): Define new accessor
member functions.
(corpus_diff::priv::apply_filters_and_compute_diff_stats):
Don't apply filters on the diff node sub-graphs of interfaces when
the user requested "no change categorization".
* tools/abidiff.cc (options::perform_change_categorization): New
data member.
(options::options): Initialize the new data member.
(display_usage): Add a help string for the new
--no-change-categorization.
(parse_command_line): Parse the new --no-change-categorization
option.
(set_diff_context_from_opts): Set the option on the diff context
here.
* tools/kmidiff.cc(options::perform_change_categorization): New
data member.
(options::options): Initialize the new data member.
(display_usage): Add a help string for the new
--no-change-categorization.
(parse_command_line): Parse the new --no-change-categorization
option.
(set_diff_context_from_opts): Set the option on the diff context
here.
2023-02-15 Dodji Seketeli <dodji@redhat.com>
comp-filter: Don't re-visit node while applying filters to diff nodes
* src/abg-comp-filter.cc (apply_filter): In the overload for
corpus_diff, visit each diff node only once.
2023-02-15 Dodji Seketeli <dodji@redhat.com>
tools-utils: Support kernel stablelist
* src/abg-tools-utils.cc
(gen_suppr_spec_from_kernel_abi_whitelists): Support section name
that ends with the word 'stablelist'.
2023-02-15 Dodji Seketeli <dodji@seketeli.org>
abidiff: Add extensive logging
* include/abg-comparison.h ({diff, corpus_diff,
diff_context}::do_log): Declare member functions.
* include/abg-corpus.h (corpus::do_log): Likewise.
* src/abg-comparison-priv.h (diff_context::priv::do_log_): Add new
data member.
(diff_context::priv::priv): Initialize the new data member.
* src/abg-comparison.cc ({diff, corpus_diff,
diff_context}::do_log): Define member functions.
(diff_context::maybe_apply_filters): Add timing logs to applying
filters and propagating categories.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Add
timing logs to applying and propagating filters to changed
functions, variables, unreachable & leaf type changes,
suppressions application.
* src/abg-corpus-priv.h (corpus::priv::do_log): Add new data
member.
(corpus::priv::priv): Initialize it.
* src/abg-corpus.cc (corpus::do_log): Define member functions.
* src/abg-reader.cc (reader::do_log): Likewise.
(reader::read_corpus): Add timing log around the invocation of
perform_late_type_canonicalizing.
* tools/abidiff.cc (set_diff_context_from_opts): Set logging.
(main): Add timing logging for diff computing, changes analysis &
report generation.
2023-01-29 Dodji Seketeli <dodji@redhat.com>
Misc white space fixes
* include/abg-suppression.h (class
type_suppression::insertion_range::end): Fix indentation.
* src/abg-default-reporter.cc (default_reporter::report): Fix
indentation in the overload for corpus_diff.
* src/abg-suppression-priv.h
(type_suppression::priv::source_locations_to_keep_): Fix alignment.
* src/abg-suppression.cc (read_type_suppression): Fix alignment of
comment.
2023-01-29 Dodji Seketeli <dodji@redhat.com>
comparison, suppression: Support [allow_type] directive
* include/abg-comparison.h: Include abg-suppression.h
(diff, diff_context, diff_sptr, diff_context_sptr): Remove these
forward decls from here.
(enum diff_category::{HAS_ALLOWED_CHANGE_CATEGORY,
HAS_DESCENDANT_WITH_ALLOWED_CHANGE_CATEGORY,
HAS_PARENT_WITH_ALLOWED_CHANGE_CATEGORY}): Add new enumerators.
(enum diff_category::EVERYTHING_CATEGORY): Update enumerator.
(diff_context::{negated_suppressions, direct_suppressions}): Declare
new member functions.
(diff_context::suppressions): Add overload.
(diff::{is_filtered_out_without_looking_at_allowed_changes,
is_allowed_by_specific_negated_suppression,
has_descendant_allowed_by_specific_negated_suppression,
has_parent_allowed_by_specific_negated_suppression}): Declare new
member functions.
* include/abg-suppression.h (class negated_suppression_base, class
negated_type_suppression): Declare new classes.
(negated_suppression_sptr, negated_suppression_type): Define new
typedefs.
(is_negated_suppression): Declare new functions.
* src/abg-suppression.cc
(negated_suppression_base::{negated_suppression_base,
~negated_suppression_base}): Define member functions.
(negated_type_suppression::{negated_type_suppression,
suppresses_diff, ~negated_type_suppression}): Likewise.
(is_negated_suppression): Define functions.
(read_type_suppression): Allow parsing the "allow_type" directive
and instantiate a negated_type_suppression.
* src/abg-comparison-priv.h
(diff_context::priv::{negated_suppression_type_,
direct_suppressions}): Define new data members.
(diff::priv::is_filtered_out): A node categorized as
HAS_DESCENDANT_ALLOWED_BY_SPECIFIC_NEGATED_SUPPRESSION,
HAS_PARENT_ALLOWED_BY_SPECIFIC_NEGATED_SUPPRESSION and
HAS_ALLOWED_CHANGE_CATEGORY is not filtered out.
* src/abg-comparison.cc (diff_context::suppressions): Add a
non-const overload.
(diff_context::{negated,direct}_suppressions): Define new member
function.
(diff_context::add_suppression): Invalidate the cache data members
diff_context::priv::{negated,direct}_suppressions_.
(diff::is_filtered_out): A node categorized as
HAS_DESCENDANT_ALLOWED_BY_SPECIFIC_NEGATED_SUPPRESSION,
HAS_PARENT_ALLOWED_BY_SPECIFIC_NEGATED_SUPPRESSION and
HAS_ALLOWED_CHANGE_CATEGORY is not filtered out.
(diff::is_filtered_out_without_looking_at_allowed_changes): Define
new member function.
(diff::is_suppressed): If there is at least one negated
suppression that match the diff node, then it's not suppressed,
unless it's matched by a direct suppression.
(diff::{is_allowed_by_specific_negated_suppression,
has_descendant_allowed_by_specific_negated_suppression,
has_parent_allowed_by_specific_negated_suppression}): Define new
member functions.
(operator<<(ostream& o, diff_category c)): Serialize
HAS_{DESCENDANT_WITH,PARENT_WITH}_ALLOWED_CHANGE_CATEGORY
enumerators.
(category_propagation_visitor::visit_end): Do not propagate
HAS_ALLOWED_CHANGE_CATEGORY,
HAS_DESCENDANT_WITH_ALLOWED_CHANGE_CATEGORY and
HAS_PARENT_WITH_ALLOWED_CHANGE_CATEGORY categories.
(suppression_categorization_visitor::visit_begin): Categorize a
node that is not suppressed by a direct suppression and is
suppressed by a negated one as
HAS_ALLOWED_CHANGE_CATEGORY. Propagate it to descendant nodes as
HAS_PARENT_WITH_ALLOWED_CHANGE_CATEGORY ...
(suppression_categorization_visitor::visit_end): ... and to parent
node as HAS_DESCENDANT_WITH_ALLOWED_CHANGE_CATEGORY.
* src/abg-default-reporter.cc (default::reporter): In the overload
for typedef_diff, qualified_type_diff, reference_diff,
fn_parm_diff, function_type_diff, array_diff, base_diff,
function_decl_diff, report local changes only
on node that are not filtered out wrt allowed changed.
* tests/data/test-abidiff-exit/test-allow-type-array-suppr.txt:
New test input.
* tests/data/test-abidiff-exit/test-allow-type-array-v0--v1-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-array-v0--v2-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-array-v0--v3-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-array-v{0,1,2,3}.c:
Source code of new binary test inputs.
* tests/data/test-abidiff-exit/test-allow-type-array-v{0,1,2,3}.o:
New binary test inputs.
* tests/data/test-abidiff-exit/test-allow-type-region-suppr.txt:
New test input.
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v1-report-{1,2}.txt:
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v2-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v3-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v4-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-region-v0--v5-report-{1,2}.txt:
Likewise.
* tests/data/test-abidiff-exit/test-allow-type-region-v{0,1,2,3,4,5}.c:
Source code of new binary test input.
* tests/data/test-abidiff-exit/test-allow-type-region-v{0,1,2,3,4,5}.o:
New binary test inputs.
* tests/data/test-abidiff-exit/test-allow-type-suppr{1,2}.txt: New
test inputs.
* tests/data/Makefile.am: Add the new testing files above to
source distribution.
2023-01-27 Dodji Seketeli <dodji@redhat.com>
suppression: Support offset_of_{first,last}_data_member_regexp offset selectors
* doc/manuals/libabigail-concepts.rst: Document the new
properties.
* include/abg-fwd.h: Forward declare comparison::{diff_context,
diff_context_sptr, diff_context_wptr, diff, diff_wptr} and
regex::regex_t_sptr.
(find_first_data_member_matching_regexp)
(find_last_data_member_matching_regexp): Declare new functions.
* include/abg-suppression.h: Inject std::{string, shared_ptr,
vector} and comparison::{diff, diff_context_sptr} into the suppr
namespace. Remove the "abg-comparison.h" header.
* src/abg-elf-helpers.cc: Include sstream.
* src/abg-ir.cc (find_first_data_member_matching_regexp)
(find_last_data_member_matching_regexp): Define new functions.
* src/abg-suppression.cc
(type_suppression::insertion_range::eval_boundary): Support
evaluating "offset_of_first_data_member_regexp" and
"offset_of_first_data_member_regexp".
* src/abg-ctf-reader.cc: Include sstream.
* tests/data/test-diff-suppr/test-has-data-member-inserted-between-1-report-[1-4].txt:
New test reference outputs.
* tests/data/test-diff-suppr/test-has-data-member-inserted-between-1-v[0-4].c:
Source code of new test input.
* tests/data/test-diff-suppr/test-has-data-member-inserted-between-1-v[0-4].o:
New binary test input.
* tests/data/test-diff-suppr/test-has-data-member-inserted-between-1.suppr:
New suppression specification.
* tests/data/Makefile.am: Add the new test input files to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
to this test harness.
2023-01-27 Dodji Seketeli <dodji@redhat.com>
suppression: Support the has_size_change property for suppress_type
* doc/manuals/libabigail-concepts.rst: Document the new
has_size_change property.
* include/abg-suppression.h
(type_suppression::{g,s}et_has_size_change): Declare new accessors.
* src/abg-suppression-priv.h
(type_suppression::priv::has_size_change_): Define new data
member.
(type_suppression::priv::priv): Initialize the new data member.
* src/abg-suppression.cc
(type_suppression::{g,s}et_has_size_change): Define new accessors.
(type_suppression::suppresses_diff): Make the
has_data_member_inserted_* clauses have effect only if the class
size hasn't changed, unless the class has as the "has_size_change"
property. Also, allow members to be deleted in the right
insertion range if the resulting size stays the same or if the
has_size_change property is present. This allows some custom
behaviours where "padding" data members would be removed while
some new data members would be added, resulting in a type which
size would not change.
(read_type_suppression): Support parsing the "has_size_change"
property.
* tests/data/test-diff-suppr/test11-add-data-member-0.1.suppr: New
test suppression specification.
* tests/data/test-diff-suppr/test11-add-data-member-1.1.suppr:
Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-2.1.suppr:
Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-3.1.suppr:
Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-4.1.suppr:
Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-report-1.1.txt:
Likewise.
* tests/data/test-diff-suppr/test12-add-data-member-0.1.suppr:
Likewise.
* tests/data/test-diff-suppr/test12-add-data-member-report-1.1.txt:
New test reference output.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-0.1.suppr:
New test suppression specification.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-1.1.txt:
New test reference output.
* tests/data/test-diff-suppr/test35-leaf-report-0.1.txt: Likewise.
* tests/data/test-diff-suppr/test35-leaf.1.suppr: New test
suppression specification.
* tests/data/Makefile.am: Add the new testing material to source
distribution.
* tests/data/test-diff-suppr/test11-add-data-member-1.suppr: Add
the has_size_change property to explicitly allow suppressing type
changes involving data member insertion even when the type size
changes.
* tests/data/test-diff-suppr/test11-add-data-member-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-2.suppr:
Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-3.suppr:
Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test12-add-data-member-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test35-leaf.suppr: Likewise.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
to the test harness.
2023-01-27 Dodji Seketeli <dodji@redhat.com>
suppression: Factorize out is_data_member_offset_in_range
* include/abg-fwd.h (get_last_data_member)
(get_next_data_member_offset): Declare functions.
* src/abg-ir.cc (get_next_data_member): Add an overload for
class_or_union and write the overload for class_or_union_sptr in
term of the former.
(get_last_data_member): Add overloads form class_or_union& and
class_or_union*. Write the overload for class_or_union_sptr in
terms of the one for class_or_union*.
(get_next_data_member_offset): Add an overload for
class_or_union* and write the overload for class_or_union_sptr in
terms of the former.
* include/abg-suppression.h
(type_suppression::insertion_range::eval_boundary): Take a
class_or_union* for the context, as opposed to a class_decl_sptr.
This makes this static function work for unions as well.
(is_data_member_offset_in_range): Declare new function.
* src/abg-suppression.cc (type_suppression::suppression_diff):
Factorize ...
(is_data_member_offset_in_range): ... this function out.
(type_suppression::insertion_range::eval_boundary): Adjust this to
make it take a class_or_union* rather than a class_decl_sptr.
2023-01-26 Dodji Seketeli <dodji@redhat.com>
suppr: Support has_data_member and has_data_member_regexp properties
* has_data_data_member = {foo, bar, blah}
Suppresses change reports involving a type which has data members
with names specified by the value of this property.
* has_data_member_regexp = some-regexp
Suppresses change reports involving a type which has data members
with names specified by the regular expression given as a value of
this property.
* include/abg-fwd.h (string_set_type): Define new typedef.
* src/abg-suppression-priv.h
* include/abg-suppression.h
(type_suppression::{get,set}_potential_data_member_names[_regex_str]):
Declare new data member.
(type_suppression::priv::{potential_data_members_,
potential_data_members_regex_str_,
potential_data_members_regex_}): Define new data members.
(type_suppression::priv::{get,set}_potential_data_member_names_regex):
Define new member functions.
* src/abg-suppression.cc
(type_suppression::{get,set}_potential_data_member_names): Define new
member functions.
(type_suppression::{get,set}_potential_data_member_names_regex_str):
Likewise.
(type_suppression::suppresses_diff): Implement suppression using
the new "has_data_member" and "has_data_member_regexp" properties.
(read_type_suppression): Support parsing the new "has_data_member"
and "has_data_member_regexp" properties of the type suppression
directive.
* tests/data/test-diff-suppr/has-data-member-[1-7].suppr: New
suppression specifications for test purposes.
* tests/data/test-diff-suppr/test-has-data-member-output-{1,2}.txt:
New reference test outputs.
* tests/data/test-diff-suppr/test-has-data-member-v{0,1}.cc:
Source code of new input binary tests.
* tests/data/test-diff-suppr/test-has-data-member-v{0,1}.o: New
binary test inputs.
* tests/data/Makefile.am: Add the test inputs below to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test inputs
above to this test harness.
2023-01-26 Dodji Seketeli <dodji@redhat.com>
ini: Fix parsing list property values
* src/abg-ini.cc (read_context::read_list_property_value): Expect
white spaces after the comma.
2023-02-27 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
abipkgdiff: Fix kernel package detection when comparing kABIs
* include/abg-tools-utils.h (rpm_contains_file): Declare new
function.
* src/abg-ctf-reader.cc (ctf::reader::find_ctfa_file): Use
`find_file_under_dir' utility function to locate `vmlinux.ctfa'
file.
(ctf::reader::process_ctf_archive): Adjust dictionary name
according to module name, removing characters after dot.
* src/abg-tools-utils.cc (file_has_ctf_debug_info): Use
`find_file_under_dir' utility function to locate `vmlinux.ctfa'
file.
(rpm_contains_file): Define new function.
(file_is_kernel_package): Use the new `rpm_contains_file' to look
for the `vmlinuz' file inside the RPM package. For Debian
packages however, we don't keep looking at the naming pattern as
we don't yet have a deb_contains_file function. Also, this
function now takes the full path to the RPM.
(build_corpus_group_from_kernel_dist_under): for CTF, add the
`root' directory of the extracted package to the set of
directories under which we should look for debug info.
* tools/abipkgdiff.cc (maybe_handle_kabi_whitelist_pkg)
(create_maps_of_package_content, compare_prepared_package, main):
Adjust call to file_is_kernel_package as it now takes the full
path to the package.
2023-02-27 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Emit error when no vmlinux is found in debug package
* tools/abipkgdiff.cc (compare_prepared_linux_kernel_packages):
When no vmlinux binary is found in the debug info package, emit an
error message.
2023-02-27 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Emit better logs in verbose mode
* tools/abipkgdiff.cc (package::erase_extraction_directory): Say
explicitly what's DONE.
(extract_rpm): Add newline to log. Say explicitly what's DONE on
which package.
(extract_deb, extract_tar)
(erase_created_temporary_directories_parent, compare_to_self)
(create_maps_of_package_content): Say explicitly what's DONE on
which package.
2023-02-21 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Fix GCC 13 warnings
* src/abg-ctf-reader.cc (process_ctf_typedef)
(process_ctf_base_type, process_ctf_forward_type)
(process_ctf_struct_type, process_ctf_union_type)
(process_ctf_enum_type): Add missing parenthesis.
2023-02-21 Dodji Seketeli <dodji@redhat.com>
ir: Add missing virtual methods overloads
* include/abg-ir.h (type_decl::operator!=): Declare missing
virtual overloads.
(array_type_def::subrange_type::operator!=): Likewise.
(template_decl::operator==): Likewise.
(type_tparameter::operator==): Likewise.
(class_decl::operator==): Likewise.
(union_decl::operator==): Likewise.
(member_class_template::operator==): Likewise.
* src/abg-ir.cc (type_decl::operator!=)
(array_type_def::subrange_type::operator!=)
(class_decl::operator==, member_class_template::operator==)
(union_decl::operator==, template_decl::operator==)
(type_tparameter::operator==, type_tparameter::operator==)
(template_tparameter::operator==): Define new virtual overloads.
2023-02-10 Dodji Seketeli <dodji@redhat.com>
configure: Bump the CURRENT library number
* configure.ac: Bump LIBABIGAIL_SO_CURRENT to 2.
2023-02-03 Dodji Seketeli <dodji@redhat.com>
PR30048 - wrong pretty representation of qualified pointers
* src/abg-dwarf-reader.cc
(die_is_pointer_array_or_reference_type): Rename
die_is_pointer_or_reference_type into this. This new name
reflects more what the function does as it tests if a DIE is for
pointer, an array or a reference.
(pointer_or_qual_die_of_anonymous_class_type): Adjust to use the
newly (and better) named die_is_pointer_array_or_reference_type.
(die_is_pointer_or_reference_type): Make this really test if a DIE
is for a pointer or a reference. Now the name matches what the
function does.
(die_peel_qualified): Define new function.
(die_qualified_type_name): When a qualified name Q has another
qualified name as its underlying type, it's important to know if
the leaf type is a pointer type or not to know how to construct
the name of Q. This change now peels the potential qualifiers
from the underlying type of the qualified type to see if the leaf
type is a pointer or not.
* src/abg-ir.cc (get_name_of_qualified_type): Likewise. Also, the
name of array types doesn't follow the same rule as for pointers
and references.
* tests/data/test-abidiff-exit/PR30048-test-report-0.txt: Add new
reference test output.
* tests/data/test-abidiff-exit/PR30048-test-2-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/PR30048-test-v{0,1}.c: Add source
code of binary input data.
* tests/data/test-abidiff-exit/PR30048-test-2-v{0,1}.cc: Likewise.
* tests/data/test-abidiff-exit/PR30048-test-v{0,1}.o: Add binary
input data.
* tests/data/test-abidiff-exit/PR30048-test-2-v{0,1}.o: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the input
binaries to this test harness.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Adjust.
2023-02-10 Dodji Seketeli <dodji@redhat.com>
default-reporter: Fix source location in functions change report
* src/abg-default-reporter.cc (default_reporter::report): In the
overload of function_decl, use the source location of the old
function.
* tests/data/test-abicompat/test0-fn-changed-report-2.txt: Adjust.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Likewise.
* tests/data/test-abidiff-exit/test-PR28316-report.txt: Likewise.
* tests/data/test-abidiff-exit/test-decl-enum-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-decl-struct-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-fun-param-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-headers-dirs/test-headers-dir-report-2.txt:
Likewise.
* tests/data/test-abidiff-exit/test-loc-with-locs-report.txt:
Likewise.
* tests/data/test-abidiff-exit/test-member-size-report0.txt:
Likewise.
* tests/data/test-abidiff-exit/test-rhbz2114909-report-1.txt:
Likewise.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test-PR24731-report-1.txt: Likewise.
* tests/data/test-diff-filter/test-PR25661-1-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-2-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-3-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-4-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-5-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-6-report-3.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-7-report-3.txt:
Likewise.
* tests/data/test-diff-filter/test-PR26739-2-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test-PR29387-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test36-report-0.txt: Likewise.
* tests/data/test-diff-filter/test37-report-0.txt: Likewise.
* tests/data/test-diff-filter/test39/test39-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/dirpkg-3-report-2.txt: Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/symlink-dir-test1-report0.txt:
Likewise.
* tests/data/test-diff-pkg/tarpkg-1-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/PR28073/PR28073-output-2.txt:
Likewise.
* tests/data/test-diff-suppr/libtest48-soname-abixml-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test30-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test41-enumerator-changes-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0-1.txt:
Likewise.
2023-01-31 Dodji Seketeli <dodji@redhat.com>
{dwarf,elf_based}-reader,writer: Avoid duplicating corpora in corpus_group
* src/abg-dwarf-reader.cc (reader::read_debug_info_into_corpus):
Do not add the corpus to the group here ...
* src/abg-elf-based-reader.cc
(elf_based_reader::read_and_add_corpus_to_group): ... because it's
already added here. But then, let's add it here /before/ reading
type & symbols information into the corpus.
* src/abg-writer.cc (write_context::m_emitted_corpora_set): Add
new data member.
(write_context::{corpus_is_emitted, record_corpus_as_emitted}):
Define new member functions.
(write_corpus): Invoke the new
write_context::record_corpus_as_emitted here.
(write_corpus_group): Ensure that each corpus is emitted only
once.
2023-02-02 Dodji Seketeli <dodji@redhat.com>
corpus: Handle empty symbol table cases
* src/abg-corpus.cc (corpus::priv::{get_sorted_fun_symbols,
get_sorted_undefined_fun_symbols, get_sorted_var_symbols,
get_sorted_undefined_var_symbols}): If the symbol is null, then
return an empty vector of symbols.
2023-02-01 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Remove unused code
* src/abg-dwarf-reader.cc (reader::{find_symbol_table_section,
lookup_native_elf_symbol_from_index}): Remove these dead
functions.
2023-02-01 Dodji Seketeli <dodji@redhat.com>
fe-iface: Add missing virtual destructor
* include/abg-fe-iface.cc (fe_iface::~fe_iface): Make this
virtual.
2023-01-28 Aleksei Vetrov <vvvvvv@google.com>
symtab: fix getting CRC in relocatable modules
* src/abg-elf-helpers.cc (get_crc_for_symbol): Rename
crc_symbol_value to crc_symbol_address and adjust it for
relocatable ELF types.
2023-01-13 Dodji Seketeli <dodji@redhat.com>
Update CTF's ctf_dict_t detection
* configure.ac: Use AC_COMPILE_IFELSE to try and compile a code
snippet that doesn't need that ctf_dict_t be fully defined.
2023-01-09 Dodji Seketeli <dodji@redhat.com>
Better detect suitable libctf version
* configure.ac: If the "struct ctf_dict_t" type is not present in
the version of ctf-api.h that is present, then switch the support
of CTF off.
2023-01-09 Giuliano Procida <gprocida@google.com>
DWARF reader: avoid C++20 operator!= overload ambiguity
* (src/abg-dwarf-reader.cc) op_is_control_flow: In the
DW_OP_bra case, when testing the popped value, use the
expr_result's const_value explicitly.
2023-01-07 Dodji Seketeli <dodji@redhat.com>
btf-reader: Use abigail::ir::canonicalize_types to canonicalize types
* src/abg-btf-reader.cc (btf::reader::canonicalize_types): Use the
abigail::ir::canonicalize_types function from abg-ir-priv.h
file to canonicalize types.
2023-01-06 Dodji Seketeli <dodji@redhat.com>
Update the copyright notice for the BTF reader
* include/abg-btf-reader.h: Update the copyright notice for 2023.
* src/abg-btf-reader.cc: Likewise.
* tests/test-read-btf.cc: Likewise.
2022-10-31 Dodji Seketeli <dodji@redhat.com>
Add support for BTF
* configure.ac: If the header /usr/include/bpf/btf.h exists, then
define the WITH_BTF pre-processor macro, unless --disable-btf was
provided.
* doc/manuals/abidiff.rst: Document the new --btf option.
* doc/manuals/abidw.rst: Likewise.
* doc/manuals/kmidiff.rst: Likewise.
* doc/manuals/abipkgdiff.rst: Likewise.
* include/abg-btf-reader.h: New header file. Contains the
declaration of the new btf::reader class.
* src/abg-btf-reader.cc: New source file. Contains the
definitions of the new btf::reader class.
* include/Makefile.am: Add the new include/abg-btf-reader.h header
file to source distribution.
* include/abg-corpus.h (enum origin): Add a new BTF_ORIGIN
enumerator.
* include/abg-tools-utils.h (file_has_btf_debug_info): Declare new
function.
* src/abg-tools-utils.cc (file_has_btf_debug_info): Define new
function.
(create_best_elf_based_reader): Adapt to support BTF input. If
the user requested the BTF front-end, instantiate it. Otherwise,
if the input file has only BTF debug info, instantiate the BTF
front end.
* include/abg-elf-reader.h (elf::reader::find_btf_section):
Declare new member function.
(elf::reader::{function, variable}_symbol_is_exported): Add new
overloads.
* src/abg-elf-reader.cc (reader::priv::btf_section): New data
member.
(reader::find_btf_section): Define new member function.
* src/Makefile.am: Add the new abg-ctf-reader.cc file to source
distribution.
* tools/abidw.cc (options::use_btf): New data member.
(display_usage): Add a help string for the new --btf option.
(parse_command_line): Support the new --btf option.
(load_corpus_and_write_abixml): If the user asked to use the btf
front-end then use that one.
* tools/abidiff.cc (options::use_btf): New data member.
(options::options): Initialize it.
(display_usage):: Add a help string to the new --btf options.
(parse_command_line): Support the new --btf options.
(main): If the user asked to use the btf front-end, then use that
one.
* tools/abidw.cc (options::use_btf): New data member.
(options::options): Initialize it.
(parse_command_line): Add a help string to the new --btf options.
(load_corpus_and_write_abixml): If the user asked to use the btf
front-end, then use that one.
* tools/kmidiff.cc (options::use_btf): New data member.
(options::options): Initialize it.
(display_usage): Add a help string to the new --btf options.
(parse_command_line): Add a help string to the new --btf options.
(main): If the user asked to use the btf front-end, then use that
one.
* tools/abipkgdiff.cc (options::use_btf): New data member.
(options::options): Initialize it.
(display_usage): Add a help string to the new --btf options.
(parse_command_line): Add a help string to the new --btf options.
(compare, compare_to_self)
(compare_prepared_linux_kernel_packages): If the user asked to use
the btf front-end, then use that one.
* tests/data/test-read-btf/test{0,1}.o: New binary test input
file.
* tests/data/test-read-btf/test{0,1}.c: Source code of the binary
input file above.
* tests/data/test-read-btf/test{0,1}.o.abi: Reference ABIXML
output.
* tests/data/test-abidiff-exit/btf/test0-report-{1,2}.txt: New
test reference output.
* tests/data/test-abidiff-exit/btf/test0-v{0,1}.o: New binary test
input.
* tests/data/test-abidiff-exit/btf/test0-v{0,1}.c: The source
files of the binary inputs above.
* tests/test-read-btf.cc: New test file to run the btf/abixml
tests.
* tests/Makefile.am: Add the new test files to the source
distribution.
2023-01-05 Dodji Seketeli <dodji@redhat.com>
configure: Enable the CTF front-end by default
* configure.ac: If --disable-ctf hasn't been passed, test for the
presence of ctf.h and then for libctf.so. If both are found then
enable the CTF front end.
2023-01-03 Petr Pavlu <petr.pavlu@suse.com>
abidiff: Fix handling of linux-kernel-mode
* tools/abidiff.cc (parse_command_line): Recognize
--no-linux-kernel-mode.
(main): Pass opts.linux_kernel_mode down to the library.
2022-12-31 Dodji Seketeli <dodji@redhat.com>
fix comparing array subrange DIEs
* src/abg-dwarf-reader.cc (compare_dies): For DW_TAG_subprogram,
non-set DW_AT_{lower,upper}_bound is not the same as when they are
set to zero.
2022-12-31 Dodji Seketeli <dodji@redhat.com>
Bug 29811 - Better categorize harmless unknown array size changes
* include/abg-comp-filter.h
(is_var_1_dim_unknown_size_array_change): Declare new function.
* src/abg-comp-filter.cc (is_var_1_dim_unknown_size_array_change):
Define new function.
(has_benign_array_of_unknown_size_change): Rename
has_benign_infinite_array_change into this. Make this call the
new is_var_1_dim_unknown_size_array_change.
(categorize_harmless_diff_node): Adjust the call to
has_benign_infinite_array_change into the new
has_benign_array_of_unknown_size_change.
* include/abg-ir.h (var_equals_modulo_types): Declare new
function. Make it friend of class decl_base.
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for var_diff, call the new
maybe_report_diff_for_variable.
* src/abg-ir.cc (var_equals_modulo_types): Factorize this out of
the equals() function for var_decl.
(equals): In the overload for var_decl, call the new
var_equals_modulo_types.
* src/abg-reporter-priv.h (maybe_report_diff_for_variable):
Declare new function.
* src/abg-reporter-priv.cc (maybe_report_diff_for_variable):
Define new function.
* tests/data/test-diff-filter/test-PR29811-0-report-0.txt: Add
new reference test output.
* tests/data/test-diff-filter/test-PR29811-0-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test-PR29811-0-v{0,1}.o: Add new
binary test inputs.
* tests/data/test-diff-filter/test-PR29811-0-v{0,1}.c: Add source
code of the binary test inputs.
* tests/data/Makefile.am: Add new test input files above to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add new tests to
harness.
2022-12-30 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Bug 29811 - Support updating of variable type
* include/abg-ir.h (var_decl::set_type): Declare new member
function.
* src/abg-ir.cc (var_decl::priv::set_type): Define new member
function.
(var_decl::set_type): Likewise.
* src/abg-dwarf-reader.cc (build_var_decl): In "updating mode",
update the type of the variable as well.
* tests/data/test-diff-filter/test-PR29811-unknown-size-array-dwarf-ctf-CTF.o:
Add new test binary input.
* tests/data/test-diff-filter/test-PR29811-unknown-size-array-dwarf-ctf-DWARF.o:
Likewise.
* tests/data/test-diff-filter/test-PR29811-unknown-size-array-dwarf-ctf-report.txt:
Add test reference output.
* tests/data/test-diff-filter/test-PR29811-unknown-size-array-dwarf-ctf.c:
Add source code of the new test binary input.
* tests/data/Makefile.am: Add the new files above to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the input binaries
to the test harness.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
2022-12-30 Dodji Seketeli <dodji@redhat.com>
Don't use the "infinite" keyword for arrays of unknown size
* src/abg-reader.cc (build_subrange_type, build_array_type_def):
Support the "unknown" keyword, as well as the "infinite" keyword.
* src/abg-reporter-priv.cc (report_size_and_alignment_changes):
Emit the "unknown" keyword, not the "infinity" one.
* src/abg-writer.cc (write_array_size_and_alignment): Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-read-ctf/test-array-size.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
2023-01-01 Dodji Seketeli <dodji@redhat.com>
Update copyright year for 2023
* update-copyright.sh: Update the copyright years in this script.
* include/abg-comp-filter.h: Update copyright year for 2023.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-ctf-reader.h: Likewise.
* include/abg-cxx-compat.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-elf-based-reader.h: Likewise.
* include/abg-elf-reader.h: Likewise.
* include/abg-fe-iface.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-ctf-reader.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-elf-based-reader.cc: Likewise.
* src/abg-elf-helpers.cc: Likewise.
* src/abg-elf-helpers.h: Likewise.
* src/abg-elf-reader.cc: Likewise.
* src/abg-fe-iface.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-regex.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-symtab-reader.cc: Likewise.
* src/abg-symtab-reader.h: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-cxx-compat.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-dot.cc: Likewise.
* tests/test-elf-helpers.cc: Likewise.
* tests/test-ini.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-kmi-whitelist.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-ctf.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-svg.cc: Likewise.
* tests/test-symtab-reader.cc: Likewise.
* tests/test-symtab.cc: Likewise.
* tests/test-tools-utils.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/kmidiff.cc: Likewise.
2022-12-28 Dodji Seketeli <dodji@redhat.com>
ir: Add sanity checking to canonical type propagation confirmation
* configure.ac: Add a new --enable-debug-ct-propagation configure
flag that defines the WITH_DEBUG_CT_PROPAGATION preprocessor
macro.
* src/abg-ir-priv.h
(environment::priv::types_with_cleared_propagated_ct_): Define new
data member for tracking types with cleared propagated canonical
type.
(environment::priv::types_with_cleared_propagated_ct): Add getter
and setter for the new data member above.
(environment::priv::{record_type_with_cleared_propagated_canonical_type,
erase_type_with_cleared_propagated_canonical_type}): Add
book-keeping functions for the set of types with cleared
propagated canonical type.
(type_base::priv::clear_propagated_canonical_type): Make this
return true if the propagated canonical type is cleared.
(environment::priv::clear_propagated_canonical_type): Define a new
function that takes a type_base* and clears its propagated
canonical type. This also adds the type to the set of tracked
types returned by
environment::priv::types_with_cleared_propagated_ct().
(environment::priv::{cancel_ct_propagation_for_types_dependant_on,
cancel_ct_propagation}): Call the new
environment::priv::clear_propagated_canonical_type() rather than
calling the now low-level
type_base::priv::clear_propagated_canonical_type().
(environment::priv::propagate_ct): Remove the type which just
gained a propagated canonical type from the set of tracked types
returned by environment::priv::types_with_cleared_propagated_ct.
(canonicalize_types): Define new function that canonicalizes all
the types of the system (passed in parameter) and performs sanity
checking to make sure all types with cleared propagated canonical
types have been canonicalized.
* include/abg-ir.h (string_type_base_sptr_map_type): Define new
typedef for an unordered_map<string, type_base_sptr>.
* src/abg-ir.cc (canonicalize): Remove the type which has just
been canonicalized from the set of tracked types returned by
environment::priv::types_with_cleared_propagated_ct.
* src/abg-ctf-reader.cc (reader::types_map): Use the new
string_type_base_sptr_map_type typedef for the type of this map.
(reader::canonicalize_all_types): Use the new function
abigail::ir::canonicalize_types to canonicalize the types of the
system and perform necessary sanity checking.
* src/abg-dwarf-reader.cc (reader::canonicalize_types_scheduled):
Likewise.
2022-12-27 Dodji Seketeli <dodji@redhat.com>
ir: Bug 29934 - Fix propagated canonical type confirmation
* src/abg-ir.cc (return_comparison_result): A type whose canonical
type has been propagated must have its canonical type confirmed if
that type is not recursive and is not dependant on any recursive
type. In that case, the canonical type will never be cancelled.
2022-12-28 Dodji Seketeli <dodji@redhat.com>
ir: misc cleanups
* include/abg-ir.h (decl_base, scope_decl): Remove the declaration
of canonicalize() as friend to these classes.
2022-12-28 Dodji Seketeli <dodji@redhat.com>
elf-reader: Don't free CTF resources too early
* src/abg-elf-reader.cc (reader::priv::{alt_ctf_fd,
alt_ctf_handle}): Add new data members.
(reader::priv::clear_alt_ctf_debug_info_data): Define new member
function.
(reader::priv::~priv): Call the new
priv::clear_alt_ctf_debug_info_data
(reader::priv::initialize): Likewise. Initialize the new
alt_ctf_handle and alt_ctf_fd data members.
(reader::priv::locate_alt_ctf_debug_info): Do not free the fd and
ELF resources early here. Store them in the new
reader::priv::alt_ctf_{fd,handle} instead.
2022-12-24 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Bug 29932 - Handle function DIE as type as needed
* src/abg-dwarf-reader.cc
(reader::lookup_fn_type_from_die_repr_per_tu): Invoke
get_die_pretty_type_representation instead of
get_die_pretty_representation when looking at a function DIE
without a name.
2022-12-24 Dodji Seketeli <dodji@redhat.com>
Bug 29934 - Handle buggy data members with empty names
* src/abg-dwarf-reader.cc (die_is_anonymous_data_member): Define
new static function.
(die_member_offset): Move the declaration of this up so that it
can be used more generally.
(reader::build_name_for_buggy_anonymous_data_member): Define new
member function.
(add_or_update_class_type): Generate an artificial name for buggy
data members with empty names.
2022-12-22 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: Fix missing initializer for member in test suite
* tests/test-read-ctf.cc (in_out_specs): Add initializer for
`option' field in test entry.
* tests/data/test-read-ctf/test-alias.o.abi: Adjust.
2022-12-21 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-front-end: Add test for alias symbols
* tests/data/test-read-ctf/test-alias.o: New binary test input file.
* tests/data/test-read-ctf/test-alias.o.abi: New exported abixml file.
* tests/data/Makefile.am: Add the new test input above
* tests/test-read-ctf.cc: Add the new test input above to the test
harness.
2022-12-20 Xiaole He <hexiaole@kylinos.cn>
elf-reader: reclaim fd and mem before break
* src/abg-elf-reader.cc
(elf::reader::priv::locate_alt_ctf_debug_info): Reclaim fd and mem
before break. Also, do not try to locate the debug info it's
already been located.
2022-12-20 Dodji Seketeli <dodji@redhat.com>
Bug 29901 - abidiff hangs when comparing libgs.so.10 with itself
* src/abg-ir-priv.h (environment::priv::comparison_started): Look
for each operand of the comparison in both the right-hand and
left-hand operand stacks.
2022-12-05 Dodji Seketeli <dodji@redhat.com>
Update website documentation for 2.2
* mainpage.txt: Update for 2.2.
2022-12-02 Dodji Seketeli <dodji@redhat.com>
configure: Bump version number to 2.3
* configure.ac: Bump version number to 2.3
2022-12-02 Dodji Seketeli <dodji@redhat.com>
ChangeLog: Update for 2.2 release
* ChangeLog: Update by doing "make update-changelog".
2022-12-02 Dodji Seketeli <dodji@redhat.com>
NEWS: Update for 2.2 release
* NEWS: Update for 2.2 release, with the output of
`git shortlog libabigail-2.1..HEAD`
2022-12-18 Petr Pavlu <petr.pavlu@suse.com>
Fix de-initialization of elf::reader::priv
* src/abg-elf-reader.cc (priv::~priv): Release alt debug
information.
(priv::initialize): Reset all members.
(priv::clear_alt_dwarf_debug_info_data): New helper function.
2022-12-19 Dodji Seketeli <dodji@seketeli.org>
ir: Cache more aggregate type comparison results
* src/abg-ir.cc (CACHE_AND_RETURN_COMPARISON_RESULT): Define new
macro.
(equals): In the overloads for function_type, class_decl, and
union_decl use the new CACHE_AND_RETURN_COMPARISON_RESULT.
2022-12-19 Dodji Seketeli <dodji@seketeli.org>
Bug 29857 - Better detect comparison cycles in type graph
* src/abg-ir-priv.h (class_set_type, fn_set_type): Define new typedefs.
* src/abg-ir.cc (environment::priv::{left_classes_being_compared_,
right_classes_being_compared_, left_fn_types_being_compared_,
right_fn_types_being_compared_}): Define new data members.
(environment::priv::{classes_being_compared_,
fn_types_being_compared_}): Erase data members.
(environment::priv::{dump_classes_being_compared,
dump_fn_types_being_compared}): Erase member functions.
(environment::priv::{mark_as_being_compared,
unmark_as_being_compared, comparison_started}): Change this to use
the left-hand-side and right-hand-side comparison stack introduced
above.
(dump_classes_being_compared, dump_fn_types_being_compared):
Remove functions.
2022-12-16 Dodji Seketeli <dodji@seketeli.org>
Bug 29857 - dwarf-reader: Resolve decl-only unions
* include/abg-fwd.h (typedef classes_or_unions_type): Declare new
typedef.
(lookup_union_types): Declare new function.
* src/abg-dwarf-reader.cc (reader::decl_only_classes_map_): Change
the type of this from string_classes_map to
string_classes_or_unions_map.
(reader::declaration_only_classes): Return a
string_classes_or_unions_map, no more a string_classes_map.
(reader::{maybe_schedule_declaration_only_class_for_resolution,
is_decl_only_class_scheduled_for_resolution}): Handle
class_or_union, not just class_decl. This is a way to make this
handle unions as well as classes.
(get_opaque_version_of_type): Adjust.
* src/abg-ir.cc (lookup_union_types): Define new function.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
2022-12-19 Dodji Seketeli <dodji@seketeli.org>
Bug 29857 - Don't pop comparison operands that haven't been pushed
* src/abg-ir.cc (equals): In the overload for class_or_union,
don't try to pop, operands that haven't been pushed.
2022-12-16 Dodji Seketeli <dodji@seketeli.org>
ir: Add a debug_comp_stack debugging function
* include/abg-fwd.h (debug_comp_stack): Declare function.
* src/abg-ir.cc (debug_comp_vec, print_comp_stack): Define static
functions.
(debug_comp_stack): Define new function.
2022-12-16 Dodji Seketeli <dodji@seketeli.org>
ir: Improve get_debug_representation
* src/abg-ir.cc (get_debug_representation): Prefix
classes/structs/unions with the 'classes/struct/union' prefix.
2022-12-02 Dodji Seketeli <dodji@redhat.com>
Bug 29829 - dwarf-reader: Allow DIEs to be in a lexical block
* src/abg-dwarf-reader.cc (get_scope_for_die): Support
DW_TAG_lexical_block as DIE scope.
2022-12-02 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Make die_peel_{qual_ptr,typedef} always set peeled type
* src/abg-dwarf-reader.cc (die_peel_qual_ptr, die_peel_typedef):
If the function returned true, then set the peeled argument even
if the function hasn't peeled anything.
2022-11-24 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Avoid duplicating member functions
* src/abg-dwarf-reader.cc
(build_or_get_fn_decl_if_not_suppressed): Fix the code that is
supposed to avoid duplicating a member function.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2022-11-23 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Leverage ODR & DWZ
* doc/manuals/abidiff.rst: Add documentation for
--no-leverage-dwarf-factorization and
--no-assume-odr-for-cplusplus
* doc/manuals/abidw.rst: Likewise.
* doc/manuals/abipkgdiff.rst: Likewise.
* include/abg-fe-iface.h (options::{leverage_dwarf_factorization,
assume_odr_for_cplusplus}): New data members.
* src/abg-dwarf-reader.cc (reader::leverage_dwarf_factorization_):
New data member.
(reader::leverage_dwarf_factorization): New accessor.
(compare_dies): If we are allowed to leverage the DWARF
factorization and if two type DIEs coming from the
.gnu_debugaltlink DWARF section have different offset, then they
are different. Also, if we are allowed to assume ODR, use it to
speed up class/struct/unions comparisons.
* tools/abidiff.cc (options::{assume_odr_for_cplusplus,
leverage_dwarf_factorization}): Define new data members.
(options::options): Initialize them.
(display_usage): Add new help strings for
--no-leverage-dwarf-factorization and
--no-assume-odr-for-cplusplus.
(parse_command_line): Parse these new options.
(set_generic_options): New function.
(main): Use the new set_generic_options function.
* tools/abidw.cc (options::{assume_odr_for_cplusplus,
leverage_dwarf_factorization}): Define new data members.
(options::options): Initialize them.
(display_usage): Add new help strings for
--no-leverage-dwarf-factorization and
--no-assume-odr-for-cplusplus.
(parse_command_line): Parse these new options.
(set_generic_options): New function.
(load_corpus_and_write_abixml): Use the new set_generic_options
function.
* tools/abipkgdiff.cc (options::{assume_odr_for_cplusplus,
leverage_dwarf_factorization}): Define new data members.
(options::options): Initialize them.
(display_usage): Add new help strings for
--no-leverage-dwarf-factorization and
--no-assume-odr-for-cplusplus.
(parse_command_line): Parse these new options.
(set_generic_options): New function.
(compare): Use it.
2022-11-25 Dodji Seketeli <dodji@redhat.com>
Fix spurious deleted/added virtual destructor change report
* src/abg-comparison.cc (find_virtual_dtor_in_map): Define new
static function.
(class_diff::ensure_lookup_tables_populated): If a virtual
destructor is removed from the old binary version but is added to
the new one (but through a different name), let's assume the
virtual destructor is still there so there is no ABI issue
from that point of view.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Adjust.
2022-11-16 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Fix array size representation
* src/abg-ctf-reader.cc (build_array_ctf_range): Use
* tests/data/Makefile.am: Add new test.
`upper_bound' and number of elements to indicate infinite
array size.
* tests/data/test-read-ctf/test-array-size.abi: New test.
* tests/data/test-read-ctf/test-array-size.c: Likewise.
* tests/data/test-read-ctf/test-array-size.o: Likewise.
* tests/test-read-ctf.cc: Update testsuite.
2022-11-16 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: Fix representation of multidimensional arrays
* src/abg-ctf-reader.cc (+build_array_ctf_range): New definition.
* tests/data/Makefile.am: Add new testcase.
* tests/data/test-read-ctf/test-array-mdimension.abi: New testcase.
* tests/data/test-read-ctf/test-array-mdimension.c: Likewise.
* tests/data/test-read-ctf/test-array-mdimension.o: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Adjust.
* tests/test-read-ctf.cc: Update testsuite.
2022-11-16 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: Strip qualification from a qualified array type
* src/abg-ctf-reader.cc (maybe_strip_qualification): New
definition.
(process_ctf_qualified_type): Strip redundant qualifiers.
* tests/data/test-read-ctf/test-const-array.abi: New test.
* tests/data/test-read-ctf/test-const-array.c: Likewise.
* tests/data/test-read-ctf/test-const-array.o: Likewise.
* tests/Makefile.am: Add the new test material to source
distribution.
2022-11-29 Dodji Seketeli <dodji@redhat.com>
test-read-ctf: Update tests for fixing size and name for underlying types
* src/abg-ctf-reader.cc (process_ctf_{base_type,enum_type}):
Look at ctf refence type to build the underlying type if present.
* tests/data/Makefile.am: New test cases.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: New test input.
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.c: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.o: Likewise.
* tests/data/test-read-ctf/test-bitfield.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield.c: Likewise.
* tests/data/test-read-ctf/test-bitfield.o: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Adjust.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise:
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/test-read-ctf.cc: Update test suite.
2022-11-16 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: Fix size and name for underlying types
* src/abg-ctf-reader.cc (process_ctf_{base_type,enum_type}):
Look at ctf refence type to build the underlying type if present.
* tests/data/Makefile.am: New test cases.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: New test input.
* tests/data/test-read-ctf/test-bitfield-enum.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.c: Likewise.
* tests/data/test-read-ctf/test-bitfield-enum.o: Likewise.
* tests/data/test-read-ctf/test-bitfield.abi: Likewise.
* tests/data/test-read-ctf/test-bitfield.c: Likewise.
* tests/data/test-read-ctf/test-bitfield.o: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Adjust.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise:
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/test-read-ctf.cc: Update test suite.
2022-11-16 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: Set alignment-in-bits property to 0
* src/abg-ctf-reader.cc (process_ctf_base_type)
(process_ctf_function_type, process_ctf_struct_type): Adjust
`align_in_bits' argument to `0'.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-1.txt: Adjust test.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-2.txt: Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt: Likewise.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test-fallback.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi: Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
2022-11-22 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
Use the CTF reader by default when applicable
* doc/manuals/abidiff.rst: Adjust.
* doc/manuals/abidw.rst: Likewise.
* doc/manuals/abipkgdiff.rst: Likewise.
* doc/manuals/kmidiff.rst: Likewise.
* include/abg-elf-based-reader.h (initialize): Add member function.
* include/abg-elf-reader.h (has_{dwarf,ctf}_debug_info): Add predicate
functions.
* include/abg-tools-utils.h (create_best_elf_based_reader): Add arguments.
* src/abg-ctf-reader.cc (process_ctf_typedef, process_ctf_base_type)
(process_ctf_function_type, process_ctf_sou_members, process_ctf_forward_type)
(process_ctf_struct_type, process_ctf_union_type, process_ctf_array_type)
(process_ctf_qualified_type, process_ctf_pointer_type, process_ctf_enum_type):
Remove arguments. Using getters to access required information instead.
(reader::cur_tu_): Add data member.
(initialize): Add arguments.
(cur_transl_unit): Add {get,set)ter.
(slurp_elf_info): Clear `STATUS_DEBUG_INFO_NOT_FOUND' if corpus is
`LINUX_KERNEL_BINARY_ORIGIN'.
(reader::lookup_type): Remove.
(reader::build_type): New member function.
* src/abg-elf-reader.cc (reader::reader): Locate ctf debug info
from binary file.
(reader::reader): Reset base `fe_iface' constructor.
(reader::has_{dwarf,ctf}_debug_info): New definitions.
(reader::read_corpus): Set `STATUS_DEBUG_INFO_NOT_FOUND' according
to corpus::origin.
* src/abg-tools-utils.cc (dir_contains_ctf_archive): Define new member.
(file_has_ctf_debug_info): Looks for kernel ctf debug information archive.
(maybe_load_vmlinux_{dwarf,ctf}_corpus): Remove.
(load_vmlinux_corpus): Define function to load IR from kernel
regardless of the corpus::origin.
(build_corpus_group_from_kernel_dist_under): Use
create_best_elf_based_reader to select the front-end.
(create_best_elf_based_reader): Adjust to allow fallback behaviour
for different front-ends.
* tests/data/Makefile.am: Add tests.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-2.txt: Adjust.
* tests/data/test-read-ctf/test-fallback.abi: New test case.
* tests/data/test-read-ctf/test-fallback.c: Likewise.
* tests/data/test-read-ctf/test-fallback.o: Likewise.
* tests/data/test-read-dwarf/test-fallback.abi: Likewise.
* tests/data/test-read-dwarf/test-fallback.c: Likewise.
* tests/data/test-read-dwarf/test-fallback.o: Likewise.
* tests/test-diff-pkg.cc: Adjust.
* tests/test-read-common.cc (test_task::run_abidw): Use the
`options:option' field.
* tests/test-read-common.h (InOutSpec): Add new member.
* tests/test-read-ctf.cc (in_out_specs): Add option field to test
suite. Add new test case.
* tests/test-read-dwarf.cc: Likewise.
* tools/abidiff.cc (main): Use create_best_elf_based_reader.
* tools/abidw.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
2022-11-15 Dodji Seketeli <dodji@redhat.com>
Make Front Ends first class citizens
* include/abg-fwd.h (build_internal_underlying_enum_type_name):
Move this here from src/abg-dwarf-reader.cc.
* include/abg-elf-reader-common.h: Delete this file. Its content
is going to be put in the new include/abg-elf-reader.h.
* src/abg-elf-reader-common.cc: Likewise.
* include/abg-{elf-based-reader, elf-reader, fe-iface}.h: Add new
files.
* src/abg-fe-iface.cc: Likewise.
* include/Makefile.am: Add the new file abg-fe-iface.h,
abg-elf-based-reader.h and abg-elf-reader.h to source distribution
and remove include/abg-elf-reader-common.h from source
distribution.
* src/abg-ir.cc (build_internal_underlying_enum_type_name): Move
this here from abg-dwarf-reader.cc so that it can be used by other
readers.
* include/abg-reader.h (abigail::abixml::reader): Rename the
namespace abigail::xml_reader into this one.
(read_context, create_native_xml_read_context)
(read_context_get_path, read_corpus_from_native_xml)
(read_corpus_from_native_xml_file)
(read_corpus_group_from_native_xml)
(read_corpus_group_from_native_xml_file): Remove.
(read_translation_unit_from_file)
(read_translation_unit_from_buffer)
(read_translation_unit_from_istream)
(read_translation_unit)
(consider_types_not_reachable_from_public_interfaces)
(get_types_from_type_id, get_artifact_used_by_relation_map)
(load_canonical_type_ids): Take an fe_iface&, not a read_context.
(create_reader): Declare new function that returns a
fe_iface_sptr.
(read_corpus_from_abixml, read_corpus_from_abixml_file)
(read_corpus_group_from_abixml)
(read_corpus_group_from_abixml_file): Declare new functions.
* src/abg-reader.cc (namespace abixml): Rename the
xml_reader namespace into this.
(abixml::reader_sptr): New typedef.
(abixml::reader): Rename read_context into this. Make it
inherit the fe_iface interface.
(abixml::reader::{m_path, m_env, m_corpus, m_corpus_group,
m_exported_decls_builder, m_supprs}): Remove these data members
that are now part of the fe_iface parent type.
(abixml::reader::{set_environment, get_corpus, set_corpus,
set_corpus_group, maybe_add_fn_to_exported_decls,
maybe_add_var_to_exported_decls,
maybe_check_abixml_canonical_type_stability,
suppression_matches_function_sym_name,
suppression_matches_variable_name,
suppression_matches_variable_sym_name}): Remove.
(read_corpus_from_input): Remove. Actually the code of this went
into abixml::reader::read_context().
(abixml::reader::get_libxml_reader): Rename the get_reader
member function into this.
(abixml::add_reader_suppressions): Rename
add_read_context_suppressions into this.
(abixml::reader::read_corpus): Implement this virtual
member function if the fe_iface parent interface.
(maybe_set_naming_typedef, advance_cursor)
(handle_version_attribute, walk_xml_node_to_map_type_ids)
(read_elf_needed_from_input, read_symbol_db_from_input)
(get_or_read_and_add_translation_unit, build_needed)
(read_elf_needed_from_input, add_read_context_suppressions)
(maybe_set_artificial_location, maybe_set_naming_typedef)
(build_namespace_decl, build_elf_symbol)
(build_elf_symbol_from_reference, build_elf_symbol_db)
(build_function_parameter, build_function_decl)
(build_function_decl_if_not_suppressed, function_is_suppressed)
(type_is_suppressed, build_var_decl_if_not_suppressed)
(variable_is_suppressed, variable_is_suppressed, build_var_decl)
(build_type_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_function_type, build_subrange_type, build_array_type_def)
(build_enum_type_decl_if_not_suppressed, build_enum_type_decl)
(build_typedef_decl, build_class_decl_if_not_suppressed)
(build_union_decl_if_not_suppressed, build_class_decl)
(build_union_decl, build_function_tdecl, build_class_tdecl)
(build_type_tparameter, build_type_composition)
(build_non_type_tparameter, build_non_type_tparameter)
(build_template_tparameter, build_template_parameter, build_type)
(handle_type_decl, handle_namespace_decl)
(handle_qualified_type_decl, handle_pointer_type_def)
(handle_reference_type_def, handle_function_type)
(handle_array_type_def, handle_enum_type_decl)
(handle_typedef_decl, handle_var_decl, handle_function_decl)
(handle_class_decl, handle_union_decl, handle_function_tdecl)
(read_translation_unit_from_istream): Take or use an
abixml::reader rather than a read_context.
(read_translation_unit, read_translation_unit_from_input)
(consider_types_not_reachable_from_public_interfaces)
(get_types_from_type_id, get_artifact_used_by_relation_map)
(read_corpus_group_from_input, read_translation_unit)
(handle_element_node, read_location, read_artificial_location)
(load_canonical_type_ids) : Take an fe_iface&, not a read_context.
(create_abixml_reader): Rename create_native_xml_read_context
into this. Make it return a fe_iface_sptr.
(read_corpus_from_abixml): Rename read_corpus_from_abixml into
this.
(read_corpus_from_abixml_file): Rename
read_corpus_from_native_xml_file into this.
(read_context_get_path): Remove.
* include/abg-tools-utils.h
(abigail::tools_utils::{file_has_dwarf_debug_info,
file_has_ctf_debug_info}): Declare new functions.
(create_best_elf_based_reader): Declare new function.
* include/abg-corpus.h (corpus::add): Pass the translation unit by
reference.
(corpus::exported_decls_builder::maybe_add_{fn,var}_to_exported_fns):
Take a const parameter.
* src/abg-corpus-priv.h
(corpus::exported_decls_builder::priv::add_{fn,var}_to_exported):
Take a const parameter and adjust.
* src/abg-corpus.cc
(corpus::exported_decls_builder::maybe_add_{fn,var}_to_exported_fns):
Take a const parameter.
(corpus::add): Take a reference to translation_unit_sptr.
* include/abg-suppression.h (abigail::fe_iface): Forward-declare
this.
(abigail::{suppression_sptr, suppressions_type}): Declare these
types here.
(abigail::suppr::{suppression_can_match,
suppression_matches_function_name,
suppression_matches_function_sym_name,
suppression_matches_variable_name,
suppression_matches_variable_sym_name,
suppression_matches_type_name_or_location,
is_elf_symbol_suppressed, is_elf_symbol_suppressed,
is_function_suppressed, is_variable_suppressed,
is_type_suppressed}): Declare these functions here.
* src/abg-suppression-priv.h (function_is_suppressed)
(variable_is_suppressed, type_is_suppressed)
(is_elf_symbol_suppressed): Remove these template functions.
* src/abg-suppression.cc (suppression_matches_function_name)
(suppression_matches_function_sym_name): Remove.
(variable_is_suppressed, suppression_can_match)
(suppression_matches_function_name)
(suppression_matches_function_sym_name)
(suppression_matches_variable_name)
(suppression_matches_variable_sym_name)
(suppression_matches_type_name_or_location)
(is_elf_symbol_suppressed, is_elf_symbol_suppressed)
(is_function_suppressed, is_variable_suppressed)
(is_type_suppressed): New functions.
* include/abg-ctf-reader.h (abigail::ctf::{read_context,
create_read_context, read_corpus,
read_and_add_corpus_to_group_from_elf,
set_read_context_corpus_group, reset_read_context, dic_type_key}):
Remove.
(ctf::{create_reader, reset_reader}): Declare new
functions.
* src/abg-ctf-reader.cc (read_context): Remove.
(process_ctf_typedef, process_ctf_base_type)
(build_ir_node_for_variadic_parameter_type)
(process_ctf_function_type, process_ctf_sou_members)
(process_ctf_forward_type, process_ctf_struct_type)
(process_ctf_union_type, process_ctf_array_type)
(process_ctf_qualified_type, process_ctf_pointer_type)
(process_ctf_enum_type, fill_ctf_section)
(lookup_symbol_in_ctf_archive, dic_type_key): Forward-declare
these static functions.
(ctf::reader): New class that is the abstraction
of the CTF reader. It extends the abigail::elf_based_reader
class. This is a renaming of the
abigail::ctf::read_context class.
(ctf::reader::{elf_handler, elf_fd,
elf_handler_dbg, elf_fd_dbg, symtab, debug_info_root_paths_,
debug_info_root_paths_}): Remove these data members as they are
now properties of the abigail::elf_reader class, which is a parent
class of this abigail::ctf::reader class.
(ctf::reader::{exported_decls_builder,
maybe_add_fn_to_exported_decls, current_corpus_group,
has_corpus_group, main_corpus_from_current_group,
current_corpus_is_main_corpus_from_current_group,
should_reuse_type_from_corpus_group}): Remove these accessors
that can now be used from the parent classes abigail::{elf_reader,
elf_based_reader}.
(ctf::reader::reader): This now delegates to the constructor of
elf_based_reader. It doesn't pass any argument to initialize()
anymore.
(ctf::reader::initialize): Add an overload with no
parameter. In the other overload, do not take a pointer to an
environment as no new environment can be passed to the instance of
reader that is being reset. Adjust the code of the initializer to
reflect all the data members that got removed.
(ctf::{env, find_ctfa_file, slurp_elf_info,
process_ctf_archive, process_ctf_type, lookup_type, read_corpus,
~reader}): New member functions. Most of these were free-form
functions that took ctf::read_context as first parameter.
In read_corpus, do not set the corpus::LINUX_KERNEL_BINARY_ORIGIN
origin as that is now done by elf::reader when it reads the
binary.
(lookup_type): Remove. These are now member functions of the
ctf::reader class.
(process_ctf_typedef, process_ctf_base_type)
(build_ir_node_for_variadic_parameter_type)
(process_ctf_function_type, process_ctf_sou_members)
(process_ctf_forward_type, process_ctf_struct_type)
(process_ctf_union_type, process_ctf_array_type)
(process_ctf_qualified_type, process_ctf_pointer_type): Take a
ctf::reader rather an ctf::read_context. Adjust the
content of the functions.
(process_ctf_type, lookup_type, process_ctf_archive): Remove these
and turn them into member functions of ctf::reader.
(open_elf_handler, close_elf_handler, find_alt_debuginfo): Remove
these ELF handling functions as ELF handling is now done by the
elf_reader parent class.
(fill_ctf_section): Take a const pointer to Elf_Scn.
(slurp_elf_info, find_ctfa_file): Remove this and make it be a
member of ctf::reader. Also, make it handle only CTF
reader specific pieces. slurp_elf_info now delegates the reading
of generic ELF properties to elf::reader by calling
elf::reader::read_corpus().
(create_read_context, read_corpus, set_read_context_corpus_group)
(read_and_add_corpus_to_group_from_elf): Remove these functions.
(create_reader, reset_reader): Create new functions
(dic_type_key): Make this static.
* include/abg-dwarf-reader.h (abigail::dwarf::elf_type):
Move this enum into the namespace abigail::elf_reader in the file
include/abg-elf-reader.h.
(abigail::dwarf::{read_context, read_context_sptr,
create_read_context, read_context_get_path, reset_read_context,
add_read_context_suppressions, set_read_context_corpus_group,
read_corpus_from_elf, read_and_add_corpus_to_group_from_elf,
read_and_add_corpus_to_group_from_elf,
add_read_context_suppressions, refers_to_alt_debug_info,
has_alt_debug_info, get_soname_of_elf_file, get_type_of_elf_file,
set_debug_info_root_path, get_debug_info_root_path,
get_show_stats, set_show_stats, set_drop_undefined_syms,
set_do_log, set_environment, get_environment}): Remove.
* src/abg-dwarf-reader.cc (struct dwfl_deleter, dwfl_sptr)
(addr_elf_symbol_sptr_map_type, address_set_type)
(address_set_sptr): Delete these types.
(read_context::options_type): Remove. The data members of this
type got moved to struct fe_iface::options_type.
(find_alt_debug_info_link, find_alt_debug_info_path)
(find_alt_debug_info, lookup_data_tag_from_dynamic_segment)
(elf_file_type, refers_to_alt_debug_info, has_alt_debug_info)
(get_soname_of_elf_file, get_type_of_elf_file) : Remove these ELF
specific functions from here; move them to the elf_reader
namespace.
(dwarf::reader): Create new class that extends
elf_based_reader. dwarf::read_context is renamed into this
type, actually.
(dwarf::reader::die_source_dependant_container_set::get_container):
Adjust.
(dwarf::reader::{supprs_, dwarf_version_,
offline_callbacks_, debug_info_root_paths_, handle_, dwarf_,
alt_fd_, alt_dwarf_, alt_debug_info_path_, elf_module_,
elf_handle_, elf_path_, symtab_section_, cur_corpus_group_,
cur_corpus_, dt_needed_, dt_soname_, elf_architecture_,
exported_decls_builder_, options_, drop_undefined_syms_}): Remove
these ELF-related data members to move them into the elf_reader
namespace.
(maybe_propagate_canonical_type)
(build_translation_unit_and_add_to_ir, build_ir_node_from_die)
(add_or_update_class_type, add_or_update_union_type)
(build_ir_node_for_void_type)
(build_ir_node_for_variadic_parameter_type, build_function_decl)
(function_is_suppressed, build_or_get_fn_decl_if_not_suppressed)
(build_var_decl, build_or_get_var_decl_if_not_suppressed)
(variable_is_suppressed)
(propagate_canonical_type)
(get_parent_die, get_scope_die, die_is_at_class_scope)
(die_location, die_qualified_type_name, die_qualified_name)
(die_qualified_type_name_empty)
(die_return_and_parm_names_from_fn_type_die)
(die_function_signature, die_function_type_is_method_type)
(die_pretty_print_type, die_pretty_print_decl, die_pretty_print)
(maybe_canonicalize_type, build_subrange_type)
(build_subranges_from_array_type_die, compare_dies, die_location)
(die_loc_and_name, die_is_effectively_public_decl)
(maybe_cache_type_comparison_result)
(get_cached_type_comparison_result)
(maybe_get_cached_type_comparison_result, die_is_at_class_scope)
(die_function_type_is_method_type, die_member_offset)
(die_qualified_type_name, die_qualified_decl_name)
(die_qualified_name, die_qualified_type_name_empty)
(die_return_and_parm_names_from_fn_type_die)
(die_function_signature, die_pretty_print_type)
(die_pretty_print_decl, die_pretty_print)
(at_least_one_decl_only_among_odr_relevant_dies)
(compare_as_type_dies, compare_as_decl_and_type_dies)
(fn_die_equal_by_linkage_name, try_canonical_die_comparison)
(maybe_propagate_canonical_type, propagate_canonical_type)
(compare_dies, compare_dies_during_canonicalization)
(find_import_unit_point_between_dies, get_parent_die)
(get_scope_die, find_lower_bound_in_imported_unit_points)
(build_translation_unit_and_add_to_ir)
(build_namespace_decl_and_add_to_ir, build_type_decl)
(build_enum_underlying_type, build_enum_type)
(finish_member_function_reading)
(maybe_finish_function_decl_reading)
(lookup_class_or_typedef_from_corpus)
(is_function_for_die_a_member_of_class)
(add_or_update_member_function, add_or_update_class_type)
(add_or_update_union_type, build_qualified_type)
(schedule_array_tree_for_late_canonicalization)
(maybe_strip_qualification, build_pointer_type_def)
(build_reference_type, build_function_type, build_subrange_type)
(build_subranges_from_array_type_die, build_array_type)
(build_typedef_type, build_or_get_var_decl_if_not_suppressed)
(build_var_decl, function_is_suppressed)
(build_or_get_fn_decl_if_not_suppressed, variable_is_suppressed)
(type_is_suppressed, type_is_suppressed)
(get_opaque_version_of_type, create_default_fn_sym)
(build_function_decl, maybe_canonicalize_type)
(build_ir_node_from_die)
(build_ir_node_for_variadic_parameter_type): Take a reference to
the new dwarf::reader rather than to the previous
read_context. Adjust the function body.
(return_comparison_result): Adjust.
(dwarf::reader::reader): Adjust this from
read_context::read_context.
(dwarf::reader::initialize): Adjust from
dwarf::read_context::initialize.
(dwarf::reader::create): New factory static member
function.
(dwarf::reader::~reader): This doesn't have to clear
anything for now.
(dwarf::reader::read_corpus): New virtual member function
which implements the fe_iface::read_corpus pure virtual interface.
This now delegates the reading of the generic ELF properties to
elf::reader by calling elf::reader::read_corpus().
Newer front-ends will be able to do the same.
(dwarf::reader::reset_corpus): New member function.
(dwarf::reader::read_debug_info_into_corpus): Adjust. This
is now a member function. Also, do not set the
corpus::LINUX_KERNEL_BINARY_ORIGIN here as it's now set by the
elf::reader when it loads the binary.
(dwarf::reader::{env, drop_undefined_syms,
drop_undefined_syms, dwarf_elf_handle, dwarf_per_die_source,
elf_path, compute_canonical_die_offset, get_die_source,
get_die_from_offset, get_die_qualified_name,
get_die_pretty_type_representation, get_die_qualified_type_name,
get_die_pretty_representation, odr_is_relevant,
set_canonical_die_offset, get_canonical_die_offset,
erase_canonical_die_offset, die_wip_classes_map,
die_wip_function_types_map, compare_before_canonicalisation,
resolve_declaration_only_classes, resolve_declaration_only_enums,
symbol_already_belongs_to_a_function,
fixup_functions_with_no_symbols, canonicalize_types_scheduled,
tu_die_imported_unit_points_map, die_parent_map,
find_symbol_table_section, get_variable_address,
exported_decls_builder, load_all_types, load_in_linux_kernel_mode,
show_stats, do_log, build_die_parent_maps): Adjust.
(offset_pairs_stack_type::rdr_): Changed the ctxt_ into this.
(offset_pairs_stack_type::offset_pairs_stack_type): Adjust.
(offset_pairs_stack_type::{erase_redundant_type_pair_entry,
cancel_canonical_propagated_type}): Adjust.
(dwarf::reader::{get_suppressions, offline_callbacks,
create_default_dwfl, dwfl_handle, elf_module, elf_handle,
add_debug_info_root_paths, add_debug_info_root_path,
find_alt_debug_info, dwarf, alt_dwarf, alt_debug_info_path,
current_corpus, reset_current_corpus, current_corpus_group,
has_corpus_group, main_corpus_from_current_group,
current_corpus_is_main_corpus_from_current_group,
should_reuse_type_from_corpus_group, function_symbol_is_exported,
variable_symbol_is_exported, symtab, dt_needed, dt_soname,
elf_architecture, is_elf_symbol_suppressed,
load_dt_soname_and_needed, load_elf_architecture,
load_elf_properties, maybe_add_fn_to_exported_decls,
maybe_add_var_to_exported_decls}): Remove these member functions
as they got moved into the elf_reader namespace or into the
fe_iface class.
(dwarf::read_context::{suppression_can_match,
suppression_matches_function_sym_name,
suppression_matches_function_name,
suppression_matches_variable_name,
suppression_matches_variable_sym_name,
suppression_matches_type_name_or_location}): Move these into the
suppr namespace. Make it take an additional parameter that is
reference fe_iface.
(dwarf::reader::load_debug_info): Remove. This became
merged into dwarf::read_debug_info_into_corpus.
(dwarf::{set_debug_info_root_path,
get_debug_info_root_path, get_show_stats, set_drop_undefined_syms,
set_do_log}): Remove.
(add_read_context_suppressions)
(set_read_context_corpus_group, read_corpus_from_elf): Remove.
(read_debug_info_into_corpus): This became a member function of
dwarf::reader.
(create_reader): Renamed create_read_context into this.
Make it return an elf_based_reader_sptr, like the other front-end
factory functions. Adjust.
(reset_dwarf_reader): Renamed reset_read_context into this.
Adjust.
(read_corpus_from_elf): Adjust.
* src/abg-elf-based-reader.cc: New file.
* src/abg-elf-helpers.h (struct dwfl_deleter, dwfl_sptr)
(addr_elf_symbol_sptr_map_type, address_set_sptr): Move these
types here from abg-dwarf-reader.cc
(initialize_dwfl_callbacks, lookup_data_tag_from_dynamic_segment):
* src/abg-elf-helpers.cc (lookup_data_tag_from_dynamic_segment)
(lookup_data_tag_from_dynamic_segment, initialize_dwfl_callbacks)
(create_new_dwfl_handle, get_soname_of_elf_file): New functions
that got moved here from the factorizing of abg-dwarf-reader.cc
and abg-ctf-reader.cc.
* src/abg-tools-utils.cc (file_has_dwarf_debug_info)
(file_has_ctf_debug_info): New functions.
(load_generate_apply_suppressions): Take an elf_based_reader, not
a dwarf::read_context.
(maybe_load_vmlinux_dwarf_corpus): Adjust the body to use the new
front-end types.
* src/Makefile.am: Add the new files src/abg-{fe-iface,
elf-based-reader, elf-reader}.cc to source distribution. Remove
src/abg-elf-reader-common.cc.
* tools/Makefile.am: Factorize linking to libabigail.so by using
LDADD.
* tools/abicompat.cc (read_corpus, main): Adjust.
* tools/abidiff.cc (set_suppressions)
(set_native_xml_reader_options, handle_error, main): Adjust.
* tools/abidw.cc (set_suppressions, load_corpus_and_write_abixml)
(load_kernel_corpus_group_and_write_abixml): Adjust.
* tools/abilint.cc (build_type_use_tree, show_how_type_is_used)
(set_suppressions, main): Adjust.
* tools/abipkgdiff.cc (elf_file::type, compare, compare_to_self)
(create_maps_of_package_content)
(compare_prepared_userspace_packages)
(self_compare_prepared_userspace_package): Adjust.
* tools/abisym.cc: Adjust invocation to
abigail::dwarf::lookup_symbol_from_elf, from
abigail::dwarf_reader::lookup_symbol_from_elf.
* tools/kmidiff.cc (main): Adjust.
* tests/print-diff-tree.cc (main): Adjust.
* tests/test-abidiff.cc (main): Likewise.
* tests/test-diff-dwarf.cc (main): Likewise.
* tests/test-ir-walker.cc (main): Likewise.
* tests/test-read-ctf.cc (test_task_ctf::perform): Likewise.
* tests/test-read-dwarf.cc: Remove the useless "using" statements.
* tests/test-read-write.cc: Likewise.
* tests/test-symtab.cc (read_corpus, TEST_CASE)
(assert_symbol_count): Adjust.
* tests/data/test-read-ctf/test0.abi: Adjust.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
2022-11-10 Dodji Seketeli <dodji@redhat.com>
Use environment by reference.
* include/abg-corpus.h (corpus::corpus)
(corpus_group::corpus_group): Take environment&, not environment*
as parameter.
(corpus::{get_environment, set_environment}): Take or return
environment&, not environment*.
* src/abg-corpus.cc (corpus::corpus): Likewise.
(corpus::{get_environment, set_environment}): Likewise.
(corpus::add): Don't update the environment of the translation
unit.
(corpus::{record_type_as_reachable_from_public_interfaces,
type_is_reachable_from_public_interfaces, init_format_version,
add_corpus}): Adjust for accessing a reference to environment,
rather than a pointer.
* include/abg-ctf-reader.h (create_read_context): Take or return
environment&, not environment*.
* src/abg-ctf-reader.cc (read_context::ir_env): Make this a
reference to environment, not pointer anymore.
(read_context::read_context): Initialize the reference to
environment.
(read_context::initialize): Do not re-set the environment.
(process_ctf_base_type)
(build_ir_node_for_variadic_parameter_type)
(process_ctf_enum_type, read_corpus): Adjust for accessing a
reference to environment, rather than a pointer.
(create_read_context, reset_read_context): Take environment&, not
environment*.
* include/abg-dwarf-reader.h (create_read_context)
(reset_read_context, read_corpus_from_elf)
(lookup_symbol_from_elf, lookup_public_function_symbol_from_elf):
Likewise.
* src/abg-dwarf-reader.cc (lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab)
(lookup_symbol_from_elf_hash_tab, lookup_symbol_from_symtab)
(lookup_symbol_from_elf, lookup_public_function_symbol_from_elf):
Likewise.
(read_context::options_type::env): Make this be a reference to
environment, not a pointer.
(read_context::options::options): Remove the default constructor.
Add a new one to initialize the environment data member.
(read_context::read_context): Take environment&, not environment*.
Initialize the options_ data member.
(read_context::initialize): Do not take or initialize an
environment anymore.
(read_context::env): Return or take environment&, not
environment*.
(read_context::{get_die_qualified_name,
get_die_qualified_type_name, get_die_pretty_type_representation,
get_die_pretty_representation, compare_before_canonicalisation})
(build_translation_unit_and_add_to_ir, build_function_type)
(build_typedef_type, read_debug_info_into_corpus)
(read_debug_info_into_corpus, build_ir_node_from_die)
(build_ir_node_for_variadic_parameter_type, has_alt_debug_info):
Adjust to use an environment&, not a pointer.
(create_default_fn_sym, create_read_context)
(read_corpus_from_elf, lookup_symbol_from_elf)
(lookup_public_function_symbol_from_elf): Take environment&, not
environment*.
(reset_read_context): Do not take or reset environment* anymore.
* include/abg-fwd.h (type_or_void): Likewise.
* include/abg-ir.h (translation_unit::translation_unit): Likewise.
(translation_unit::{get_environment, set_environment}): Likewise.
(elf_symbol::elf_symbol): Likewise.
(elf_symbol::create): Remove the overload that takes no
parameter. Then for overload that take parameters then take
environment&, not environment*.
(elf_symbol::get_environment): Take environment&, not
environment*.
(type_or_decl_base::type_or_decl_base): Make the copy constructor
and assignment operator private.
(type_or_decl_base::{s,g}et_environment): Take or return
environment& not environment*.
(type_or_decl_base::set_environment_for_artifact): Erase these
methods.
(decl_base::decl_base): Make copy constructor private. Take or
return environment&, not environment* for the other constructors.
(scope_decl::scope_decl): Take or return environment&, not
environment*.
(type_base::type_base): Likewise.
(scope_type_decl::scope_type_decl): Likewise.
(namespace_decl::namespace_decl): Likewise.
(qualified_type_def::qualified_type_def): Likewise.
(pointer_type_def::pointer_type_def): Likewise.
(reference_type_def::reference_type_def): Likewise.
(array_type_def::subrange_type::subrange_type): Likewise.
(enum_type_def::enumerator::enumerator): Likewise.
(enum_type_def::enumerator::{get_name, get_qualified_name}):
Return a string&, no more interned_string&. As the enumerator
don't have an enumerator anymore, there is no way to intern the
string anymore. Hopefully this won't incur a performance loss.
(typedef_decl::typedef_decl, function_type::function_type)
(method_type::method_type, template_decl::template_decl)
(function_tdecl::function_tdecl, class_tdecl::class_tdecl)
(class_or_union::class_or_union, class_decl::class_decl)
(union_decl::union_decl): Take or return environment&, not
environment*.
* include/abg-reader.h (read_translation_unit_from_file)
(read_translation_unit_from_buffer)
(read_translation_unit_from_istream)
(create_native_xml_read_context, create_native_xml_read_context)
(read_corpus_from_native_xml, read_corpus_from_native_xml_file)
(read_corpus_group_from_native_xml)
(read_corpus_group_from_native_xml_file): Likewise.
* include/abg-tools-utils.h
(build_corpus_group_from_kernel_dist_under): Likewise.
* src/abg-tools-utils.cc (maybe_load_vmlinux_dwarf_corpus)
(maybe_load_vmlinux_ctf_corpus)
(build_corpus_group_from_kernel_dist_under): Likewise.
* include/abg-writer.h (create_write_context): Likewise.
* src/abg-writer.cc (id_manager::m_env, id_manager::id_manager)
(id_manager::get_environment, id_manager::get_id)
(id_manager::get_id_with_prefix): Adjust.
(write_context::m_env, write_context::write_context)
(write_context::get_environment, write_context::get_config)
(write_context::get_id_for_type, write_context::decl_is_emitted)
(write_context::record_decl_as_emitted, create_write_context)
(write_class_decl): Likewise.
* src/abg-comparison.cc (compute_diff): Stop ensuring that the two
artifacts being compare are in the same environment. Now that the
environment is passed by reference, the potential for
accendentally comparing artifacts coming from different
environments is very low, given how the API is used in practice.
This is in the overloads for decl_base_sptr, type_base_sptr,
var_decl_sptr, pointer_type_def_sptr, array_type_def_sptr,
reference_type_def_sptr, qualified_type_def_sptr,
enum_type_decl_sptr, class_decl_sptr, class_decl::base_spec_sptr,
union_decl_sptr, scope_decl_sptr, function_decl::parameter_sptr,
function_type_sptr, function_decl_sptr, type_decl_sptr,
typedef_decl_sptr, translation_unit_sptr, corpus_sptr.
* src/abg-corpus-priv.h (corpus::priv::env): Make this be a
reference to environments, not a pointer.
(corpus::priv::priv): Pass environment&, not environment*.
* src/abg-ir-priv.h (translation_unit::priv::env_): Make this an
environment&, not an environment* anymore.
(translation_unit::priv::priv): Take an environment&, not an
environment*.
(environment::priv::{confirm_ct_propagation_for_types_dependant_on,
confirm_ct_propagation,
cancel_ct_propagation_for_types_dependant_on,
mark_as_being_compared, unmark_as_being_compared,
comparison_started, mark_as_being_compared, comparison_started}):
Adjust to use an environment&, not a pointer.
* src/abg-ir.cc (class environment_setter): Remove this class.
(push_composite_type_comparison_operands)
(pop_composite_type_comparison_operands, try_canonical_compare)
(return_comparison_result, translation_unit::{get_global_scope,
bind_function_type_life_time}): Adjust.
(translation_unit::{translation_unit, get_environment}): Take or
get an environment&, not an environment*. Remove the getter that
returns an environment*.
(elf_symbol::priv::env_): Make this an environment&, not an
environment*.
(elf_symbol::priv::priv): Adjust.
(elf_symbol::elf_symbol): Remove the default constructor. Change
the one that takes an environment.
(elf_symbol::create): Remove the default one. Adjust the one that
takes an environment.
(elf_symbol::get_environment): Adjust.
(elf_symbol::set_environment_for_artifact): Remove.
(environment::{get_void_type, get_variadic_parameter_type}):
Adjust.
(type_or_decl_base::priv::env_): Make this be a const
environment&, not a const environment*.
(type_or_decl_base::priv::priv): Adjust.
(type_or_decl_base::type_or_decl_base): Remove the default and
copy constructor.
(type_or_decl_base::{set_environment, operator=})
(set_environment_for_artifact): Remove.
(type_or_decl_base::get_environment): Adjust.
(decl_base::{decl_base, set_name, set_naming_typedef,
set_linkage_name}): Adjust.
(get_decl_name_for_comparison, strip_typedef)
(strip_useless_const_qualification): Adjust.
(scope_decl::{scope_decl, add_member_decl, insert_member_decl}):
Adjust.
(get_generic_anonymous_internal_type_name, get_type_name)
(get_name_of_pointer_to_type, get_name_of_reference_to_type)
(get_name_of_qualified_type, get_function_type_name)
(get_method_type_name, is_void_pointer_type, lookup_basic_type)
(lookup_union_type, lookup_union_type_per_location)
(lookup_enum_type, lookup_typedef_type, lookup_pointer_type)
(lookup_type, lookup_basic_type_per_location)
(lookup_basic_type_per_location, lookup_basic_type)
(lookup_class_type, lookup_class_types)
(lookup_class_type_per_location, lookup_union_type)
(lookup_enum_type, lookup_enum_types)
(lookup_enum_type_per_location, lookup_typedef_type)
(lookup_typedef_type_per_location, maybe_update_types_lookup_map)
(maybe_update_types_lookup_map)
(synthesize_type_from_translation_unit)
(synthesize_function_type_from_translation_unit)
(demangle_cplus_mangled_name, type_or_void)
(types_defined_same_linux_kernel_corpus_public)
(compare_types_during_canonicalization)
(type_base::get_canonical_type_for, type_base::type_base)
(type_base::get_cached_pretty_representation)
(type_decl::type_decl, type_decl::get_qualified_name): Adjust.
(scope_type_decl::scope_type_decl)
(namespace_decl::namespace_decl, qualified_type_def::build_name)
(qualified_type_def::qualified_type_def)
(qualified_type_def::get_qualified_name)
(qualified_type_def::set_underlying_type)
(pointer_type_def::pointer_type_def)
(pointer_type_def::set_pointed_to_type)
(reference_type_def::reference_type_def)
(reference_type_def::set_pointed_to_type)
(array_type_def::subrange_type::subrange_type)
(array_type_def::array_type_def, array_type_def::update_size)
(array_type_def::set_element_type)
(array_type_def::append_subranges)
(array_type_def::get_qualified_name, enum_has_non_name_change):
Adjust.
(enum_type_decl::enumerator::priv::env_): Remove this pointer to
env. This is because the enumerator must be copy-able. As the
enumerator doesn't have an env anymore, it can't intern strings.
So the enumerator name and qualified name is not going to be
interned. If that incurs a performance hit, we'll reconsider this
decision. For now, it seems to work OK. As it simplifies things,
I am keeping this for now.
(enum_type_decl::enumerator::priv::{name, qualified_name}): Make
this be string, not interned_string.
(enum_type_decl::enumerator::get_environment): Remove.
(enum_type_decl::enumerator::priv::priv): Adjust.
(enum_type_decl::enumerator::enumerator)
(enum_type_decl::enumerator::operator=)
(enum_type_decl::enumerator::get_name)
(enum_type_decl::enumerator::get_qualified_name)
(enum_type_decl::enumerator::set_name): Likewise.
(typedef_decl::typedef_decl): Adjust.
(var_decl::get_id, var_decl::get_qualified_name): Adjust.
(function_type::function_type, method_type::method_type)
(function_decl::get_pretty_representation_of_declarator)
(function_decl::set_symbol): Likewise.
(function_decl::get_id, function_decl::parameter::get_type)
(function_decl::parameter::get_type_name)
(function_decl::parameter::get_type_pretty_representation)
(function_decl::parameter::get_name_id)
(class_or_union::class_or_union, class_decl::class_decl)
(class_decl::add_base_specifier, union_decl::union_decl)
(union_decl::union_decl, template_decl::template_decl)
(class_tdecl::class_tdecl)
(maybe_cancel_propagated_canonical_type)
(dump_classes_being_compared)
(dump_fn_types_being_compared, copy_member_function)
(maybe_propagate_canonical_type, keep_type_alive)
(is_non_canonicalized_type, qualified_name_setter::do_update):
Likewise.
(equals): Adjust the overloads for var_decl, function_type,
class_or_union, class_decl, union_decl.
* src/abg-reader.cc (read_context::m_env): Make this be an
environment&, not an environment*.
(read_context::read_context): Adjust
(read_context::set_environment): Remove.
(read_context::{get_environment,
maybe_check_abixml_canonical_type_stability}): Adjust.
(read_corpus_from_input, read_corpus_group_from_native_xml)
(read_corpus_group_from_native_xml_file)
(read_translation_unit_from_file)
(read_translation_unit_from_buffer, read_translation_unit)
(maybe_map_type_with_type_id, build_namespace_decl)
(build_elf_symbol, build_function_parameter, build_function_decl)
(build_function_type, build_enum_type_decl, build_class_decl)
(build_union_decl, build_function_tdecl, build_class_tdecl)
(build_type_tparameter, read_translation_unit_from_istream)
(create_native_xml_read_context, read_corpus_from_native_xml):
Likewise.
* src/abg-symtab-reader.h (symtab::load): Likewise.
* src/abg-symtab-reader.cc (symtab::load): Likewise.
* tests/print-diff-tree.cc (main): Likewise.
* tests/test-abidiff.cc (main): Likewise.
* tests/test-diff-dwarf.cc (main): Likewise.
* tests/test-ir-walker.cc (main): Likewise.
* tests/test-read-ctf.cc (test_task_ctf::perform): Likewise.
* tests/test-symtab.cc (read_corpus): Likewise.
* tools/abicompat.cc (read_corpus, main): Likewise.
* tools/abidiff.cc (main): Likewise.
* tools/abidw.cc (load_corpus_and_write_abixml)
(load_kernel_corpus_group_and_write_abixml, main): Likewise.
* tools/abilint.cc (main): Likewise.
* tools/abipkgdiff.cc (compare, compare_to_self)
(compare_prepared_linux_kernel_packages, compare_task::perform):
Likewise.
* tools/abisym.cc (main): Likewise.
* tools/kmidiff.cc (main): Likewise.
2022-11-18 Aleksei Vetrov <vvvvvv@google.com>
symtab: add support for CRC values from __kcrctab
* src/abg-elf-helpers.h (get_crc_for_symbol): Defined new
helper function to extract CRC from ELF symbol.
* src/abg-elf-helpers.cc (get_crc_for_symbol): Implemented this
function with support of old and new CRC values format.
* src/abg-symtab-reader.cc (symtab::load_): Used the new
function when building CRC values map.
Change-Id: I7de5c737d5caaef0c5b7b2ea0d448368889a16be
2022-11-08 Sam James <sam@gentoo.org>
Use xz as the default tarball compression format
* configure.ac: add dist-xz to AM_INIT_AUTOMAKE.
* Makefile.am: adjust $(TARBALL) to new extension.
* Makefile.am: pass XZ_OPT="-0" for distcheck-fast.
2022-11-11 Giuliano Procida <gprocida@google.com>
Narrow Linux symbol CRCs to 32 bits
* include/abg-ir.h (elf_symbol::elf_symbol): Change CRC type
from optional<uint64_t> to optional<uint32_t>.
(elf_symbol::create): Likewise.
(elf_symbol::get_crc): Likewise.
(elf_symbol::set_crc): Likewise.
* src/abg-ir.cc (elf_symbol::priv) Change CRC type from
optional<uint64_t> to optional<uint32_t>.
(elf_symbol::priv::priv): Likewise.
(elf_symbol::elf_symbol): Likewise.
(elf_symbol::create): Likewise.
(elf_symbol::get_crc): Likewise.
(elf_symbol::set_crc): Likewise.
* src/abg-reporter-priv.cc (maybe_report_diff_for_symbol):
Change CRC type from optional<uint64_t> to
optional<uint32_t>.
* src/abg-symtab-reader.cc (symtab::load_): Change crc_values
value type from uint64_t to uint32_t.
2022-11-08 Dodji Seketeli <dodji@redhat.com>
kmidiff: Fix spacing in the help string
* tools/kmidiff.cc (display_usage): Fix spacing.
2022-10-14 Dodji Seketeli <dodji@redhat.com>
ir: Don't crash when looking at corpus-less translation units
* src/abg-ir.cc ({decl,type}_topo_comp::operator()): Support types
that inherits from an empty corpus.
2022-10-20 Dodji Seketeli <dodji@redhat.com>
rhbz2114909 - Refer to changed base classes using their non-qualified names
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Refer to the added
or removed base class using its qualified name.
* src/abg-ir.cc (class_decl::base_spec::base_spec): Set the
qualified name of the base_spec.
* tests/data/test-abidiff-exit/test-rhbz2114909-report-1.txt: New
reference test output.
* tests/data/test-abidiff-exit/test-rhbz2114909-v{0,1}.o: New
input test binaries.
* tests/data/test-abidiff-exit/test-rhbz2114909-v{0,1}.cc: Source
code of the binaries, above.
* tests/data/Makefile.am: Add the new test materials above to
source distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new tests to
this harness.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt: Adjust.
2022-10-16 Xiaole He <hexiaole@kylinos.cn>
abg-diff-utils: fix typo in comments
* src/abg-diff-utils.h: fix typo in comments
2022-10-16 Xiaole He <hexiaole@kylinos.cn>
abg-reader: optimize if construction
* src/abg-reader.cc: optimize if construction
2022-10-16 Xiaole He <hexiaole@kylinos.cn>
abg-ir: add missing else
* src/abg-ir.cc (bind_function_type_life_time): add missing
else
Tested-by: Xiaole He <hexiaole@kylinos.cn>
2022-10-12 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix class size setting bug
* src/abg-dwarf-reader.cc (add_or_update_class_type): If we are
looking at a class DIE with children node, if it's advertized as
having non-zero size, then update the size.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
2022-10-10 Dodji Seketeli <dodji@redhat.com>
ir: Properly indent overload of equals() for class_decl
* src/abg-ir.cc (equals): Fix indentation.
2022-10-10 Dodji Seketeli <dodji@redhat.com>
ir: Fix a wrong comment in canonicalize()
* src/abg-ir.cc (canonicalize): Fix a comment.
2022-10-10 Dodji Seketeli <dodji@redhat.com>
ir: remove redundant cycle detection code in equals
* src/abg-ir.cc (equals): In the overload for class_or_union
remove redundant cycle detection code when comparison a decl-only
class to another class.
2022-10-07 Dodji Seketeli <dodji@redhat.com>
Bug 29650 - Caching class comparison result potentially too early
* src/abg-ir.cc (equal): In the overload of class_or_union do not
cache the result comparing just the data members sub-types of of
classes. In the overload for class_decl, put cycle detection
management code /after/ the call to equals for class_or_union,
because that called function does perform the cycle detection
management as well; otherwise, that introduces an unwarranted
redundancy. In the overload of equals for union_decl, cache the
result of the comparison.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
2022-10-07 Dodji Seketeli <dodji@redhat.com>
abidiff: add a --debug-tc option
* doc/manuals/abidiff.rst: Add documentation for the new
--debug-tc option. Fix the existing documentation for
--debug-self-comparison.
* tools/abidiff.cc (options::do_debug_self_comparison): Renamed
options::do_debug into this.
(options::do_debug_type_canonicalization): Add new data member.
(display_usage): Fix help string for the --debug option that is
now --debug-self-comparison. Also, add a help string for the new
option --debug-tc option.
(main): Adjust use options::do_debug into
options::do_debug_self_comparison. Call
environment::debug_type_canonicalization() if the user provided
the --debug-tc option.
2022-10-02 Dodji Seketeli <dodji@redhat.com>
ir: Fix documentation of canonical type propagation
* src/abg-ir.cc (on-the-fly-canonicalization): Enclose the comment
into <pre> html tag to make the ascii-art graph look good.
2022-10-02 Dodji Seketeli <dodji@redhat.com>
Update website for 2.1 release.
* doc/website/mainpage.txt: Update website for 2.1 release.
2022-09-26 Dodji Seketeli <dodji@redhat.com>
Bump version number to 2.2
* configure.ac: Bump version number to 2.2
2022-09-25 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 2.1
* NEWS: Update for 2.1.
2022-09-25 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 2.1 release.
* ChangeLog: Update by running "make update-changelog".
2022-09-24 Dodji Seketeli <dodji@redhat.com>
ir: Avoid cancelling a "confirmed" propagated canonical type
* src/abg-ir-priv.h
(type_base::priv::propagated_canonical_type_confirmed_): Define
new data member.
(type_base::priv::priv): Initialize it.
(type_base::priv::{propagated_canonical_type_confirmed,
set_propagated_canonical_type_confirmed}): Define new member
functions.
(type_base::priv::clear_propagated_canonical_type): Do not clear
the propagated canonical type if it has been confirmed already.
(type_base::priv::confirm_ct_propagation_for_types_dependant_on): Rename
type_base::confirm_ct into this. Mark the confirmed propagated
types as being confirmed.
(type_base::priv::confirm_ct_propagation): This is now a new member
function that calls
type_base::confirm_ct_propagation_for_types_dependant_on and that
does the book-keeping that was being done in
return_comparison_result.
(type_base::priv::cancel_ct_propagation_for_types_dependant_on):
Renamed type_base::priv::cancel_ct_propagation in this.
(type_base::priv::cancel_ct_propagation): In this new one, call
type_base::priv::cancel_ct_propagation_for_types_dependant_on. Perform here
the book-keeping that was being done in return_comparison_result.
Also, do not cancel a confirmed propagated canonical type.
(type_base::priv::add_to_types_with_non_confirmed_propagated_ct):
Define new member function.
* src/abg-ir.cc (return_comparison_result): Consider only types
with non-confirmed propagated canonical types for the
non-confirmed type queue. Also, only sub-types can be considered
non-confirmed. Split out some of the book-keeping into
type_base::priv::{confirm_ct_propagation, cancel_ct_propagation}
and call these instead. Confirm the propagated canonical types of
all types that remain after the comparison is fully done and is
successful.
(canonicalize): Assert the rule "The result of canonicalizing must
always been a confirmed canonical type".
2022-09-22 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Accept SHT_PROGBITS sections in .dynamic segment
* src/abg-dwarf-reader.cc (get_soname_of_elf_file): Accept
SHT_PROGBITS sections in the dynamic segment.
2022-09-22 Dodji Seketeli <dodji@redhat.com>
ir: Support cloning data members of unions
* src/abg-ir.cc (var_decl::clone): Support cloning data members
for unions.
2022-09-22 Dodji Seketeli <dodji@redhat.com>
Better support for golang programs
* src/abg-dwarf-reader.cc (die_qualified_type_name): Don't look at
the underlying type unnecessarily.
(build_function_type): Look for the WIP type first to avoid
infinite recursion.
* src/abg-ir.cc
(function_decl::get_pretty_representation_of_declarator): A
parameter can have a function type.
* src/abg-writer.cc (write_elf_symbol_reference)
(write_function_decl): Escape symbol names, function names and
symbol references.
2022-07-19 Dodji Seketeli <dodji@redhat.com>
comparison: Ensure that fn parms with basic types can't be redundant
* include/abg-comparison.h (peel_fn_parm_diff)
(peel_typedef_qualified_type_or_parameter_diff): Declare ...
* src/abg-comparison.cc (peel_fn_parm_diff)
(peel_typedef_qualified_type_or_parameter_diff): ... new
functions.
(has_basic_type_change_only): Look through function parameters,
typedefs and qualified types.
* src/abg-default-reporter.cc (default_reporter::report): Remove
the temporary removal of the redundant categorisation.
Redundant-ness should have been handled by the
redundancy_marking_visitor pass.
* tests/data/test-diff-filter/test-PR29387-report.txt: Reference
test output.
* tests/data/test-diff-filter/test-PR29387-v{0,1}.c: Source of the
input tests.
* tests/data/test-diff-filter/test-PR29387-v{0,1}.o: Input test
binaries.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the test binaries
above to the test harness.
2022-09-21 Dodji Seketeli <dodji@redhat.com>
test-read-ctf: Update test output files after typedef canonicalization
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Adjust.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-linux-module.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
2022-09-13 Dodji Seketeli <dodji@redhat.com>
ir, writer: Go back to canonicalizing typedefs in the IR
* include/abg-fwd.h (lookup_decl_only_class_types): Declare new
function.
* src/abg-ir-priv.h (class_or_union::priv::member_types_): Move
this data member into scope_decl::priv.
(class_or_union::priv::priv): Do not take member types.
* include/abg-ir.h (sort_type): Likewise.
(namespaces_type): Add new typedefs.
(scope_decl::insert_member_decl): Make this be non-virtual.
(scope_decl::{insert_member_type, add_member_type,
remove_member_type, get_member_types, get_sorted_member_types,
find_member_type}): Move these methods here from ...
(class_or_union::{insert_member_type, add_member_type,
remove_member_type, get_member_types, get_sorted_member_types,
find_member_type}): ... here.
(class_or_union::insert_member_decl): Make this be non-virtual.
(class_decl::insert_member_decl): Make this be non-virtual.
(class_or_union::get_sorted_member_types): Declare ...
* src/abg-dwarf-reader.cc (add_or_update_class_type): Do not add a
member type to the class type being built if it already exists
there.
(build_ir_node_from_die): If a scope (namespace, union or class)
already has a typedef, do not create a new one to add it there
again.
* src/abg-ir.cc (equals): In the overload for typedefs take into
account the name of typedefs again.
(lookup_decl_only_class_types): Define new function.
(compare_using_locations): Define new static function that has
been factorized out of ...
(decl_topo_comp::operator()): ... here. Also, two decls originate
from an abixml corpus, compare them only using their artificial
locations, meaning make them keep the same order as the order of
the original abixml file.
(type_top_comp::operator()): Likewise.
(sort_types): Define new function.
(scope_decl::priv::member_types_): Move this here from
class_or_union::priv.
(scope_decl::priv::sorted_member_types_): Define new data member.
(scope_decl::{get_member_types, find_member_type,
insert_member_type, add_member_type, remove_member_type}): Move
these methods here from class_or_union.
(scope_decl::get_sorted_member_types): Define new method.
(is_non_canonicalized_type): Canonicalize typedefs.
(lookup_type_in_map): Allow this to look through decl-only types
to get their definition. Otherwise, if only a decl-only was
found, return it.
(maybe_update_types_lookup_map<class_decl>): Allow adding
decl-only class types to the map of classes held per TU and per
corpus.
(class_or_union::{class_or_union, add_member_decl,
has_no_member}): Adjust.
(class_or_union::{insert_member_type, add_member_type,
add_member_type, remove_member_type, get_member_types,
get_sorted_member_types, find_member_type}): Move these methods to
scope_decl.
({class_decl, class_or_union}::insert_member_decl): Remove the
"before" parameter as it was not used anymore due to the re-use of
the scope_decl::add_member that handles member types.
* src/abg-reader.cc (read_corpus_group_from_input)
(create_native_xml_read_context): Set the corpus origin.
* src/abg-writer.cc (write_context::{m_nc_type_id_map,
m_emitted_non_canonicalized_type_set,
m_referenced_non_canonicalized_types_set}): Remove these maps that
hold stuff for non-canonicalized types.
(write_context::{type_has_existing_id, get_id_for_type,
clear_type_id_map, has_non_emitted_referenced_types,
record_type_as_referenced, type_is_referenced,
record_type_as_emitted, type_is_emitted, clear_referenced_types,
write_referenced_types, write_canonical_type_ids}): Adjust these
as the maps for non-canonicalized types are gone.
(write_context::{get_referenced_non_canonicalized_types,
get_emitted_non_canonicalized_type_set}): Remove these methods.
(write_decl_in_scope)
(write_class_decl_opening_tag, write_union_decl_opening_tag)
(write_union_decl): Adjust comments.
(write_class_decl): Sort member types. Also, When emitting a
decl-only class, get all of the decl-only classes of the same name
declared in several other TUs and emit all their member types into
this decl-only class just once. This reduces redundancies and
sorting instabilities because for libabigail, all decl-only
classes of a given name are equal, even if they have member types.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2022-09-08 Dodji Seketeli <dodji@redhat.com>
Fix IR comparison result caching and canonical type propagation tracking
* src/abg-ir-priv.h (environment::priv::recursive_types_): Define
new data member.
(environment::priv::cache_type_comparison_result): Cache results
only non-recursive and not dependant types, or when the result is
"false". In all these cases, the result, once cached, will not
change.
(environment::priv::mark_dependant_types_compared_until): Mark
types as recursive at the same time others are marked as
dependant.
(environment::priv::{is_recursive_type, set_is_not_recursive}):
Define new member functions.
(environment::priv::{confirm_ct_propagation,
cancel_ct_propagation}): Confirming canonical type propagation
should happen for recursive types as well as their dependant
types.
* src/abg-ir.cc (return_comparison_result): Keep up with the
book-keeping at all time when type canonicalization process is
on-going. Whenever we expect types that depends on recursive
types, expect recursive types too, obviously.
(type_base::get_canonical_type_for): Do not erase the comparison
result cache between the canonicalization of two different types.
(is_comparison_cycle_detected)
(mark_types_as_being_compared, unmark_types_as_being_compared):
Define new overloads for class_decl;
(equals): In the overloads for class_decl and union_decl, use
RETURN_COMPARISON_RESULT and mark_types_as_being_compared without
casting it to class_or_union.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Adjust.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
2022-09-02 Dodji Seketeli <dodji@redhat.com>
Allow restricting analyzed decls to exported symbols
* doc/manuals/tools-use-libabigail.txt: New doc text.
* doc/manuals/Makefile.am: Add the new tools-use-libabigail.rst
tool to the source distribution.
* doc/manuals/abidiff.rst: Include the new
tools-use-libabigail.rst. Document the --exported-interfaces-only
and --allow-non-exported-interfaces.
* doc/manuals/abidw.rst: Likewise.
* doc/manuals/abipkgdiff.rst: Likewise.
* doc/manuals/kmidiff.rst: Likewise.
* include/abg-ir.h
(environment::{user_set_analyze_exported_interfaces_only,
analyze_exported_interfaces_only}): Declare new accessors.
* src/abg-ir.cc
(environment::{user_set_analyze_exported_interfaces_only,
analyze_exported_interfaces_only}): Define new accessors.
* src/abg-dwarf-reader.cc (die_is_variable_decl)
(die_is_function_decl): Define new static functions.
(read_context::is_decl_die_with_exported_symbol): Define new
member function.
(read_context::get_{function,variable}_address): Const-ify the
Dwarf_Die* parameter.
(build_translation_unit_and_add_to_ir): If the user asks to
analyze exported interfaces only, the analyze only interfaces
that have exported ELF symbols.
(read_debug_info_into_corpus): If we are looking at the Linux
Kernel, then only analyze exported interfaces unless the user asks
otherwise.
* src/abg-ir-priv.h
(environment::priv::analyze_exported_interfaces_only_): Define new
data member.
* tools/abidiff.cc (options::exported_interfaces_only): Define new
data member.
(display_usage): Add new help strings for
--exported-interfaces-only and --allow-non-exported-interfaces.
(parse_command_line): Parse the new options
--exported-interfaces-only and --allow-non-exported-interfaces.
(main): Pass the value of opts.exported_interfaces_only to the
environment.
* tools/abidw.cc (options::exported_interfaces_only): Define new
data member.
(display_usage): Add new help strings for
--exported-interfaces-only and --allow-non-exported-interfaces.
(parse_command_line): Parse the new options
(load_corpus_and_write_abixml)
(load_kernel_corpus_group_and_write_abixml): Pass the value of
opts.exported_interfaces_only onto the environment.
* tools/abipkgdiff.cc (options::exported_interfaces_only): Define new
data member.
(display_usage): Add new help strings for
--exported-interfaces-only and --allow-non-exported-interfaces.
(parse_command_line): Parse the new options
(compare_task::perform, self_compare_task::perform): Pass the
value of opts.exported_interfaces_only onto the environment.
(compare_prepared_linux_kernel_packages): Likewise.
* tools/kmidiff.cc(options::exported_interfaces_only): Define new
data member.
(display_usage): Add new help strings for
--exported-interfaces-only and --allow-non-exported-interfaces.
(parse_command_line): Parse the new options
(main): Pass the value of opts.exported_interfaces_only onto the
environment.
2022-09-01 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Revamp the canonical type DIE propagation algorithm
* src/abg-ir-priv.h (enum comparison_result): Define new enum.
* src/abg-dwarf-reader.cc (type_comparison_result_to_be_cached)
(maybe_cache_type_comparison_result)
(get_cached_type_comparison_result)
(maybe_get_cached_type_comparison_result)
(maybe_propagate_canonical_type, propagate_canonical_type)
(return_comparison_result): Define new static functions.
(has_offset_pair, insert_offset_pair, erase_offset_pair)
(have_offset_pair_in_common): Remove static functions.
(read_context::die_comparison_visits_): Remove data member. The
concept supported by this data member is now replaced by caching
the results of comparing aggregate types, especially those that
are not yet canonicalized. This essentially prevents the same
aggregate type pair to be compared again and again.
(read_context::{die_comparison_results_, compare_count_,
canonical_propagated_count_, cancelled_propagation_count_}): New
data members.
(read_context::initialize): Initialize the new data members
compare_count_, canonical_propagated_count_,
cancelled_propagation_count_ of integral type.
(read_context::{erase_canonical_die_offset}): New member
functions.
(struct offset_pairs_stack_type): Define new type.
(die_offset): Remove.
(is_canon_type_to_be_propagated_tag): Add union types to the set
of types for which canonical type propagation might occur.
(is_type_die_to_be_canonicalized): Add function types and array
types to the types to be canonicalized.
(ABG_RETURN): Change this macro to consider
COMPARISON_RESULT_DIFFERENT rather than the "false" boolean.
Also, it uses the new return_comparison_result function.
(ABG_RETURN_FALSE): Likewise, use the new return_comparison_result
function.
(SET_RESULT_TO_FALSE): Make this return
COMPARISON_RESULT_DIFFERENT.
(SET_RESULT_TO, RETURN_IF_COMPARISON_CYCLE_DETECTED): Define new
macros.
(compare_dies): Make this return comparison_result rather than
just a bool. This is also the core of the overhaul of the
canonical DIE propagation algorithm. The algorithm is now similar
to the one implemented in the equals function for class_or_union
types in abg-ir.cc. It's described in the comment that starts
with '@defgroup OnTheFlyCanonicalization' in abg-ir.cc. The type
of the aggregates_being_compared parameter is now
offset_pairs_stack_type in parameter. No more need for the
redundant_aggregates_being_compared parameter. The new
offset_type that also encapsulates the source of the offset is now
used in lieu of the Dwarf_Off type. Results of comparing
aggregates being compared are now cached. When comparing
aggregates, use the RETURN_IF_COMPARISON_CYCLE_DETECTED to return
early if a cycle is detected. The invocation of the ABG_RETURN
macro (especially the call to return_comparison_result) is where
the book keeping for canonical types propagation takes place, so
remove the explicit code that was handling that from the end of
this function.
(read_debug_info_into_corpus): Print statistics about the number
of aggregates compared and canonical-type-propagated.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-pkg/GtkAda-gl-2.24.2-29.fc29.x86_64--2.24.2-30.fc30.x86_64-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2022-07-20 Mark Wielaard <mark@klomp.org>
Handle zero sh_entsize in get_soname_of_elf_file
* src/abg-dwarf-reader.cc (get_soname_of_elf_file):
Make sure entsize is non-zero before use.
https://sourceware.org/bugzilla/show_bug.cgi?id=29346
2022-09-19 Xiaole He via Libabigail <libabigail@sourceware.org>
abg-reader: fix comment of function
* src/abg-reader.cc (walk_xml_node_to_map_type_ids): fix comment
2022-09-20 Dodji Seketeli <dodji@redhat.com>
Fix butchered tests/data/Makefile.am
* tests/data/Makefile.am: Fix test file paths.
2022-09-19 Dodji Seketeli <dodji@redhat.com>
test-annotate: Don't emit architecture data
* tests/test-annotate.cc (main): Add the --no-architecture option
to abidw.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi:
Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
2022-09-19 Dodji Seketeli <dodji@redhat.com>
Bug PR29443 - Global variables not emitted to abixml in some cases
* src/abg-ir.cc (var_decl::get_pretty_representation): Always use
qualified name of vars in an anonymous scope for internal
purposes.
* tests/data/test-annotate/PR29443-missing-xx.o.annotated.abi: New
reference test output.
* tests/test-annotate.cc (in_out_specs): Add the above to the test
harness.
* tests/data/test-read-dwarf/PR29443-missing-xx.cc: New source
code for the test.
* tests/data/test-read-dwarf/PR29443-missing-xx.o: New test input
binary.
* tests/data/test-read-dwarf/PR29443-missing-xx.o.abi: New test
reference output.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the above to the
test harness.
2022-09-07 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Lookup debug info for symbols in a non default archive member
* src/abg-ctf-reader.cc (lookup_symbol_in_ctf_archive): New function.
(process_ctf_archive): Use `lookup_symbol_in_ctf_archive'.
2022-06-28 Ben Woodard via Libabigail <libabigail@sourceware.org>
Bug 28669 - Increment Library version
* configure.ac: Define the variables libabigail_so_{current,
revision, age}. These are to be adjusted after each releases
depending on how the compatibility status of the libabigail's
code.
* src/Makefile.am: Add -version-info
$(LIBABIGAIL_SO_CURRENT):$(LIBABIGAIL_SO_REVISION):$(LIBABIGAIL_SO_AGE)
to LDFLAGS.
2022-09-01 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Simplify the canonicalization decision of types added to IR
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Remove
the overload that takes a Dwarf_Die* parameter.
(operator++(die_source& source)): Likewise.
(read_context::{types_to_canonicalize_,
alt_types_to_canonicalize_,
type_unit_types_to_canonicalize_}): Remove these data members
of type vector<Dwarf_Off>. (read_context::initialize): Remove
invocations to alt_types_to_canonicalize_.clear(),
type_unit_types_to_canonicalize_.clear(), and
extra_types_to_canonicalize_.clear().
(read_context::extra_types_to_canonicalize_): Rename this into
read_context::types_to_canonicalize_, of type
vector<type_base_sptr>.
(read_context::types_to_canonicalize): Remove these member
functions that take a parameter of type die_source.
(read_context::extra_types_to_canonicalize): Rename this
function into types_to_canonicalize. It returns a type const
vector<type_base_sptr>&.
(read_context::schedule_type_for_late_canonicalization):
Remove this overload that takes a type const Dwarf_Die*. In
the overload that takes a parameter const type_base_sptr
however, rename the invocation to
extra_types_to_canonicalize_.push_back(t) into
types_to_canonicalize_.push_back(t).
(read_context::canonicalize_types_scheduled): This doesn't
take a die_source parameter anymore. It now only cycles
through the types retrieved by types_to_canonicalize() to
canonicalize them.
(read_context::add_late_canonicalized_types_stats): Remove the
die_source parameter. Use types_to_canonicalize().
(read_context::perform_late_type_canonicalizing): Just call
read_context::canonicalize_types_scheduled().
(build_ir_node_from_die): Adjust calls to maybe_canonicalize_type.
Also, really canonicalize the function type when a function decl is
constructed.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
2022-09-02 Dodji Seketeli <dodji@redhat.com>
ir: translation_unit::is_empty should work without environment.
* src/abg-ir.cc (translation_unit::is_empty): If there is no
global scope, then we know its empty. No need to create one.
2022-09-01 Dodji Seketeli <dodji@redhat.com>
ir: Don't overdo canonical type propagation control when comparing classes
* src/abg-ir.cc (equals): In the overload for const class_decl&,
do not cancel the propagated canonical type if the propagation is
not the result of invoking the equals overload for class_or_union.
2022-09-05 Dodji Seketeli <dodji@redhat.com>
Add test-abidiff-exit/ld-2.28-21{0,1}.so to source distribution
* tests/data/Makefile.am: Add the new files to source
distribution. Also, add the new
test-abidiff-exit/ld-2.28-21x.so.sources.txt.
* tests/data/test-abidiff-exit/ld-2.28-21x.so.sources.txt: New
file describing where the sources are.
2022-08-25 Giuliano Procida <gprocida@google.com>
abidw: resolve declaration-only enums the same as classes
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_enums): Use an ordered
map to ensure TUs are always considered in the same order and
so improve ABI XML stability. Given multiple possible
definitions for a enum declaration, check to see if they are
equal and resolve the declaration to the first definition if
so.
2022-08-25 Giuliano Procida <gprocida@google.com>
abidw: remove always true test in resolve_declaration_only_classes
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Remove
tautological conditional.
2022-08-25 Giuliano Procida <gprocida@google.com>
abidw: fix --stats output for resolved classes and enums
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Fix
conditional logic so that showing stats includes the first
unresolved type.
(read_context::resolve_declaration_only_enums): Likewise.
2022-08-15 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: looks for debug information in out-of-tree modules
* src/abg-ctf-reader.cc (process_ctf_archive, read_corpus
slurp_elf_info): Avoid looking for `vmlinux.ctfa' when we aren't
processing a `cur_corpus_group_'. So CTF info is embedded in the
`.ko' file.
* tests/data/Makefile.am: Add test inputs and expected files.
* tests/data/test-read-ctf/test-linux-module.{ko,c,abi}: Add new
test input and reference kABI.
* tests/test-read-ctf.cc: Add new testcase.
2022-08-26 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Better handle the absence of a die->parent map
* src/abg-dwarf-reader.cc (get_scope_for_die): Consider that in
the absence of the DIE->PARENT map, all decls are in the global.
namespace.
* tests/data/test-abidiff-exit/ld-2.28-210.so: New test.
* tests/data/test-abidiff-exit/ld-2.28-211.so: Likewise.
* tests/data/test-abidiff-exit/test-ld-2.28-210.so--ld-2.28-211.so.txt: New reference test output.
* tests/test-abidiff-exit.cc (in_out_specs): Add the test above to
the harness.
2022-08-29 Dodji Seketeli <dodji@redhat.com>
Update test-read-ctf reference output
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Adjust.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
2022-08-19 Dodji Seketeli <dodji@redhat.com>
ir: Don't consider different int types of same kind and size as equivalent
* src/abg-ir.cc (equals): In the overload for type_decl, do not
consider int types of the same type as being equivalent by
overlooking their long and short modifiers.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2022-07-24 Dodji Seketeli <dodji@redhat.com>
writer: Make sorting referenced typedefs types stable in abixml
* src/abg-writer.cc (read_context::type_ptr_cmp::operator()): In
the less-than operator the type pointer comparison functor, use
the non-internal pretty representation of types for sorting
purposes.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
2022-07-22 Dodji Seketeli <dodji@redhat.com>
ir: Consider integral types of same kind and size as equivalent
* include/abg-fwd.h (is_integral_type): Declare new function.
* include/abg-ir.h (type_decl::get_qualified_name): Add a
declaration of an implementation of the virtual interface
get_qualified_name.
* src/abg-ir-priv.h (integral_type::set_modifiers): Define a new
setter.
(integral_type::to_string): Add an "internal" flag.
* src/abg-ir.cc (operator~, operator&=): Declare
new operators.
(get_internal_integral_type_name): Define new static function.
(decl_base::priv::{temporary_internal_qualified_name_,
internal_qualified_name_}): Define two new data members.
(get_type_name): For internal name of integral types, use the new
get_internal_integral_type_name function.
(is_integral_type): Define new function.
(integral_type::set_modifiers): Define new member function.
(operator|, operator&): Fix some indentation.
(operator~, operator&=): Define new operators.
(parse_integral_type): Fix the logic of this function. Namely, it
wasn't handling parsing "long long" correctly.
(integral_type::to_string): Add an "internal" flag.
(equals): In the overload for type_decl, do not take the short,
long and long long into account when comparing integral types of
the same size.
(type_decl::get_qualified_name): Define new method.
(type_decl::get_pretty_representation): For internal name of
integral types, use the new get_internal_integral_type_name
function.
({decl,type}_topo_comp::operator()): Use the non-internal pretty
representation of decls/types for sorting purpose.
* src/abg-reader.cc (build_type_decl): We don't expect the
integral type name from abixml to the same as the name of the
parsed integral type, as the abixml file can be old and have an
old format.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-annotate/test0.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Adjust.
* tests/data/test-diff-filter/test41-report-0.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Adjust.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Adjust.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Adjust.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Adjust.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
* tests/data/test-read-dwarf/test0.abi: Adjust.
* tests/data/test-read-dwarf/test0.hash.abi: Adjust.
* tests/data/test-read-dwarf/test1.hash.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-write/test22.xml: Adjust.
* tests/data/test-read-write/test23.xml: Adjust.
* tests/data/test-read-write/test28-without-std-fns-ref.xml: Adjust.
* tests/data/test-read-write/test28-without-std-vars-ref.xml: Adjust.
2022-07-22 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Remove redundant qualifiers from qualified types
* include/abg-fwd.h (strip_redundant_quals_from_underyling_types):
Declare new function.
* include/abg-ir.h (operator&=): Declare new binary operator for
qualified_type_def::CV and ...
* src/abg-ir.cc (+operator&=): ... define it here.
(strip_redundant_quals_from_underyling_types): Define new function
and ...
* src/abg-dwarf-reader.cc (maybe_strip_qualification): ... Use it
here.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Adjust.
2022-07-22 Dodji Seketeli <dodji@redhat.com>
ir: Disambiguate sorting of array element types
* src/abg-ir.cc (get_type_representation): In the overload for
array_type_def, use qualified names for element types.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-diff-filter/test-PR26739-2-report-0.txt: Adjust.
2022-07-19 Dodji Seketeli <dodji@redhat.com>
ir: Make pointers name stable wrt decl-only-ness of pointed-to types
* src/abg-ir.cc (look_through_decl_only): New overload for
type_base.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
2022-07-18 Dodji Seketeli <dodji@redhat.com>
tests-diff-{filter,pkg,pkg-ctf}: Fix tests broken by the previous commit
* tests/data/test-diff-filter/test41-report-0.txt: Adjust.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
2022-07-18 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support DWARF incomplete class types
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Do not avoid
comparing ODR-relevant classes.
(add_or_update_class_type): Detect incomplete classes and treat
them as decl-only types. They'll be resolved to their proper
complete types later, by
read_context::resolve_declaration_only_classes.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2022-07-14 Dodji Seketeli <dodji@redhat.com>
Better Handle naming typedefs on anonymous enums
* src/abg-dwarf-reader.cc (build_typedef_type): Do not re-use
typedefs.
* src/abg-ir.cc (get_function_type_name, get_method_type_name)
(function_decl::get_pretty_representation_of_declarator): Strip
typedefs when the function name is computed for internal purposes.
(equals): In the overload for function_decl::parameter, strip
typedefs when comparing parameter types.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test3-report.txt: Likewise.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2022-07-14 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix a thinko when building vars
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Don't get out
early when building vars.
2022-07-11 Dodji Seketeli <dodji@redhat.com>
Bug 29302 - Don't edit fn linkage name when not appropriate
* src/abg-dwarf-reader.cc (build_function_decl): If the linkage
name is properly set in the DWARF, do not change it.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
2022-07-08 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: add support to looks for debug information to extract kABI
* src/abg-ctf-reader.cc (find_ctfa_file): Add new function
meant to locate the Linux Kernel debug information file
`vmlinux.ctfa'.
(ctf_reader::read_corpus): Use `find_ctfa_file' function.
2022-07-08 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
Add regression tests for abipkgdiff using ctf info
* doc/manuals/abipkgdiff.rst: Document the fact that abipkgdiff
now supports the CTF format.
* tests/data/test-diff-pkg-ctf/cracklib-2.9.6-15-ol8.x86_64-report-0.txt:
New test input.
* tests/data/test-diff-pkg-ctf/cracklib-2.9.6-15-ol8u0.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/cracklib-2.9.6-15-ol8u6.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-0-dir1/dir.abignore:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-0-dir1/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-0-dir1/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-0-dir2/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-0-dir2/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-0-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-dir1/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-dir1/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-dir2/dir.abignore:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-dir2/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-dir2/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-1-report-1.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-2-dir1/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-2-dir1/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-2-dir2/.abignore: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-2-dir2/dir.abignore:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-2-dir2/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-2-dir2/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-2-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-dir1/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-dir1/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-dir2/.abignore: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-dir2/libobj-v0.so:
Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-dir2/obj-v0.c: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-1.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3-report-2.txt: Likewise.
* tests/data/test-diff-pkg-ctf/dirpkg-3.suppr: Likewise.
* tests/data/test-diff-pkg-ctf/elfutils-libelf-0.186-1.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/elfutils-libelf-0.186-2.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/elfutils-libelf-0.186-report-0.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/elfutils-libelf-0.186-report-1.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.1.2-8-ol8u0.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.2.0-10-ol9u0.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/gmp-6.x.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/isl-0.16.1-6.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg-ctf/isl-0.16.1-7.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg-ctf/isl-0.16.1-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/isl-debuginfo-0.16.1-6.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/isl-debuginfo-0.16.1-7.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/libdwarf-20180129-4-no-ctf.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/libdwarf-20180129-4.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/libdwarf-20180129-5-no-ctf.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/libdwarf-20180129-5.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1-report0.txt:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir1/symlinks/foo.o:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir1/symlinks/libfoo.so:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir1/targets/foo.c:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir1/targets/foo.o:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir1/targets/libfoo.so:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir2/symlinks/foo.o:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir2/symlinks/libfoo.so:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir2/targets/foo.c:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir2/targets/foo.o:
Likewise.
* tests/data/test-diff-pkg-ctf/symlink-dir-test1/dir2/targets/libfoo.so:
Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir1.ta: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir1.tar: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir1.tar.bz2: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir1.tar.gz: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir2.ta: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir2.tar: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir2.tar.bz2: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-dir2.tar.gz: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-0-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-1-dir1.tar.gz: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-1-dir2.tar.gz: Likewise.
* tests/data/test-diff-pkg-ctf/tarpkg-1-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/test-rpm-report-0.txt: Likewise.
* tests/data/test-diff-pkg-ctf/test-rpm-report-1.txt: Likewise.
* tests/data/test-diff-pkg-ctf/test-rpm-report-2.txt: Likewise.
* tests/data/test-diff-pkg-ctf/test-rpm-report-3.txt: Likewise.
* tests/data/test-diff-pkg-ctf/test-rpm-report-4.txt: Likewise.
* tests/data/test-diff-pkg-ctf/test-rpm-report-5.txt: Likewise.
* tests/data/Makefile.am: Add the test material above to source
distribution.
* tests/test-diff-pkg.cc (in_out_spec): Add the test inputs above
to this harness.
2022-07-08 Matthias Maennich <maennich@google.com>
tests: Update Catch2 library to v2.13.9
* tests/lib/catch.hpp: Update to v2.13.9
2022-07-04 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
kmidiff: Add CTF support to comparing Kernel trees
* doc/manuals/kmidiff.rst: Add documentation for the new --ctf option.
* tools/kmidiff.cc (options::use_ctf): Define new data member.
(display_usage): Add a help string for the --ctf option.
(main): Adjust call to pass
build_corpus_group_from_kernel_dist_under with origin being
corpus::CTF_ORIGIN when the user provides the --ctf option.
2022-07-04 Dodji Seketeli <dodji@redhat.com>
dwarf-reader,ir: Don't canonicalize enums too early & too naively
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Delay enum
type canonicalization.
* src/abg-ir.cc (type_base::get_canonical_type_for): Look through
all decl-only types, not just decl-only classes.
(equals): In the overload for enums, look through decl-only
enums. Also, fix redundant enumerators detection to make it more
robust, otherwise, some regression tests break.
2022-06-13 Giuliano Procida <gprocida@google.com>
add Linux kernel symbol namespace support
* include/abg-ir.h (elf_symbol::elf_symbol): Add ns argument.
(elf_symbol::create): Add ns argument.
(elf_symbol::get_namespace): Declare new function.
(elf_symbol::set_namespace): Declare new function.
and set_namespace.
* src/abg-comp-filter.cc (namespace_changed): Define new
helper functions.
(categorize_harmful_diff_node): Also call namespace_changed().
* src/abg-ir.cc (elf_symbol::priv): Add namespace_ member.
(elf_symbol::priv::priv): Add namespace_ to initialisers.
(elf_symbol::elf_symbol): Take new ns argument and pass it to
priv constructor.
(elf_symbol::create): Take new ns argument and pass it to
elf_symbol constructor.
(elf_symbol::get_namespace): Define new function.
(elf_symbol::set_namespace): Define new function.
* src/abg-reader.cc (build_elf_symbol): If namespace
attribute is present, set symbol namespace.
* src/abg-reporter-priv.cc (maybe_report_diff_for_symbol): If
symbol namespaces differ, report this.
* src/abg-symtab-reader.cc (symtab::load): Get ELF header to
distinguish vmlinux from .ko. Try to get __ksymtab_strings
metadata and data. Use these to look up __kstrtabns_FOO
namespace entries. Set symbol namespace where found.
* src/abg-writer.cc (write_elf_symbol): Emit namespace
attribute, if symbol has a namespace.
* tests/data/Makefile.am: Add new test files.
* tests/data/test-abidiff/test-namespace-0.xml: New test file.
* tests/data/test-abidiff/test-namespace-1.xml: Likewise
* tests/data/test-abidiff/test-namespace-report.txt: Likewise.
* tests/test-abidiff.cc: Add new test case.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-06-13 Giuliano Procida <gprocida@google.com>
Linux symbol CRCs: support 0 and report presence changes
* include/abg-ir.h (elf_symbol::elf_symbol): Argument crc is
now an optional defaulted to absent.
(elf_symbol::create): Likewise.
(elf_symbol::get_crc): Now returns an optional uint64_t.
(elf_symbol::set_src): Now takes an optional uint64_t.
* src/abg-comp-filter.cc (crc_changed): Simplify comparison.
* src/abg-ir.cc (elf_symbol::priv): Member crc_ is now an
optional uint64_t.
(elf_symbol::priv::priv): Argument crc is now an optional
uint64_t.
(elf_symbol::elf_symbol): Likewise.
(elf_symbol::create): Argument crc is now an optional uint64_t
and defaults to absent.
(textually_equals): Simplify comparison.
(elf_symbol::get_crc): Now returns an optional uint64_t.
(elf_symbol::set_crc): Now takes an optional uint64_t.
* src/abg-reader.cc (build_elf_symbol): Treat CRC 0 the same
as other CRC values.
* src/abg-reporter-priv.cc (maybe_report_diff_for_symbol):
Treat CRC 0 the same as other CRC values and also report
changes to CRC presence.
* src/abg-writer.cc (write_elf_symbol): Treat CRC 0 the same
as other CRC values.
* tests/data/Makefile: Remove test-abidiff/test-crc-report.txt
and add test-abidiff/test-crc-report-{0-1,1-0,1-2}.txt.
* tests/data/test-abidiff/test-crc-report-0-1.txt: Report
showing additional of CRCs.
* tests/data/test-abidiff/test-crc-report-1-0.txt: Report
showing removal of CRCs.
* tests/data/test-abidiff/test-crc-report-1-2.txt: Renamed
from tests/data/test-abidiff/test-crc-report.txt.
* tests/test-abidiff.cc: Update test cases that no longer
generate empty reports.
* tests/test-symtab.cc: Update KernelSymtabsWithCRC test.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-06-13 Giuliano Procida <gprocida@google.com>
optional: minor improvements
* include/abg-cxx-compat.h (optional): Add operator== and
operator!=. Add noexcept decorations. Tweak operator bool.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-06-13 Giuliano Procida <gprocida@google.com>
crc_changed: eliminate copying of shared_ptr values
* src/abg-comp-filter.cc (crc_changed): Take references to
avoid std::shared_ptr copying. Split declarations into one per
line. Remove unnecessary return expression parentheses.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-06-30 Dodji Seketeli <dodji@redhat.com>
ir: Add some debugging facilities for the comparison machinery
* src/abg-ir-priv.h: Include iostream to access std::cerr.
(environment::priv::{dump_classes_being_compared,
dump_fn_types_being_compared}): Define new member functions.
* src/abg-ir.cc (dump_classes_being_compared)
(dump_fn_types_being_compared): Define new functions.
2022-06-30 Dodji Seketeli <dodji@redhat.com>
Bug 29303 - Cache the result of structural aggregate comparison
* src/abg-ir-priv.h (struct uint64_t_pair_hash): Define new type.
(uint64_t_pair_type, uint64_t_pairs_set_type)
(type_comparison_result_type): Define new typedefs.
(environment::priv::{classes_being_compared_,
fn_types_being_compared_}): Use the new uint64_t_pairs_set_type
type for these.
(environment::priv::{type_comparison_results_cache_,
allow_type_comparison_results_caching_}): Define new data members.
(environment::priv::priv): Initialize the new
allow_type_comparison_results_caching_ scalar data member.
(environment::priv::{allow_type_comparison_results_caching,
cache_type_comparison_result, is_type_comparison_cached,
clear_type_comparison_results_cache}): Define new member
functions.
(environment::priv::{mark_as_being_compared,
unmark_as_being_compared, comparison_started}): Take a pair of
types.
(struct function_type::priv): Move this here, from ...
* src/abg-ir.cc (struct function_type::priv): ... here.
(is_comparison_cycle_detected, mark_types_as_being_compared)
(unmark_types_as_being_compared): Adjust call to the new
environment::priv::{comparison_started, mark_as_being_compared,
unmark_as_being_compared}.
(type_base::get_canonical_type_for): Use aggregate types
comparison result caching when doing type comparison.
(equals): In the overload for function_type, class_or_union and
class_decl, cache the result of aggregate type comparison and
re-use that cached result when it's available.
* src/abg-dwarf-reader.cc
(read_context::compare_before_canonicalisation): Use aggregate
types comparison result caching when doing type comparison.
2022-06-28 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Don't consider top-level types as private
* src/abg-dwarf-reader.cc (die_is_public_decl): Only function and
variable decls having the DW_AT_external, as well as non-anonymous
namespaces are considered public decls. The rest is considered
private.
(build_namespace_decl_and_add_to_ir): If the current namespace is
private (anonymous), then its content is also private. Otherwise,
use die_is_public_decl to know if its content is public or not.
2022-06-24 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Avoid long comparisons when resolving C++ decl-only classes
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Don't compare
same-name-types of a binary if the ODR is relevant.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2022-06-23 Dodji Seketeli <dodji@redhat.com>
test-alt-dwarf: Add missing dwz alt-debug file
* tests/data/test-alt-dwarf-file/libstdc++/libstdc++-report-1.txt:
New reference test output.
* tests/data/test-alt-dwarf-file/libstdc++/usr/lib/debug/.dwz/gcc-12.1.1-1.fc37.x86_64:
New dwz alt-debug info file.
* tests/data/Makefile.am: Add the test material above to source
distribution.
2022-06-23 Dodji Seketeli <dodji@redhat.com>
ir: Make canonicalization stable wrt typedefs in fn return types
* src/abg-ir.cc (get_function_type_name, get_method_type_name):
When the function type name is for internal purposes, strip
potential typedefs off.
(equal): In the overload for function_type, strip potential
typedefs off of return types before comparing them.
(decl_base::set_naming_typedef): Properly adjust the qualified
name of the type to which a naming typedef is being set.
* tests/data/test-alt-dwarf-file/libstdc++/libstdc++-report.txt:
New reference test output.
* tests/data/test-alt-dwarf-file/libstdc++/usr/lib/debug/usr/lib64/libstdc++.so.6.0.30-12.1.1-1.fc37.x86_64.debug:
New binary test input.
* tests/data/test-alt-dwarf-file/libstdc++/usr/lib64/libstdc++.so.6.0.30:
New binary test input.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
2022-06-21 Dodji Seketeli <dodji@redhat.com>
Update year in copyright notice
* include/abg-comp-filter.h: Update year in copyright notice.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-ctf-reader.h: Likewise.
* include/abg-cxx-compat.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-elf-reader-common.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-ctf-reader.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-elf-helpers.cc: Likewise.
* src/abg-elf-helpers.h: Likewise.
* src/abg-elf-reader-common.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-regex.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-symtab-reader.cc: Likewise.
* src/abg-symtab-reader.h: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-cxx-compat.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-elf-helpers.cc: Likewise.
* tests/test-ini.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-kmi-whitelist.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-ctf.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-symtab-reader.cc: Likewise.
* tests/test-symtab.cc: Likewise.
* tests/test-tools-utils.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/kmidiff.cc: Likewise.
* update-copyright.sh: Likewise.
2022-06-21 Dodji Seketeli <dodji@redhat.com>
reporter-priv: Passing a string parm by reference
* src/abg-reporter-priv.h
(maybe_report_data_members_replaced_by_anon_dm): Pass the string parm by ...
* src/abg-reporter-priv.cc
(maybe_report_data_members_replaced_by_anon_dm): ... reference.
2022-04-11 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix DWARF string comparison optimization
* src/abg-dwarf-reader.cc (slowly_compare_strings)
(die_char_str_attribute): Define new static functions.
(compare_dies_string_attribute_value): Use the new
slowly_compare_strings here.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
2022-04-04 Dodji Seketeli <dodji@redhat.com>
Canonicalize DIEs w/o assuming ODR & handle typedefs transparently
* include/abg-fwd.h (peel_typedef_pointer_or_reference_type):
Declare new function.
* src/abg-dwarf-reader.cc (read_context::{compute_canonical_die,
get_canonical_die, get_or_compute_canonical_die}): Don't
special-case ODR-relevant cases.
(is_canon_type_to_be_propagated_tag): Rename
is_canonicalizeable_type_tag into this.
(erase_offset_pair): Make this return a bool, not void.
(have_offset_pair_in_common, try_canonical_die_comparison)
(notify_die_comparison_failed): Define new static functions.
(ABG_RETURN, ABG_RETURN_FALSE): Define new macros.
(compare_dies): Handle DW_TAG_{class,unspecified}_type DIES. Also
if a comparing a DIE kind is not supported, assume the comparison
yields "false" for the purpose of canonicalization. Add a new
parameter for redundant aggregates being compared. Use the
redundant aggregate set to detect if a redundant aggregate has
been detected and is still being "explored"; if that's the case,
then canonical DIE propagation is de-activated. This might incur
a performance hit. Use the new ABG_RETURN and ABG_RETURN_FALSE
macros. Use the new try_canonical_die_comparison to compare
canonical DIEs rather than doing it by hand.
(build_typedef_type): Don't try to rely on canonical typedefs
DIEs.
* src/abg-ir.cc
(type_topo_comp::has_artificial_or_natural_location): Define new
method.
(type_topo_comp::operator(const type_base*, const type_base*)): In
this topological comparison operator of types, when two types have
the same textual representation, if they don't have any location,
if they are pointer/reference/typedef types, use the textual
representation of their ultimate underlying type for sorting
order.
(peel_typedef_pointer_or_reference_type): Define new function.
(compare_types_during_canonicalization): Perform the structural
canonical comparison first.
(equals): In the overload for array_type_def::subrange_type&,
remove unused code. In the overload for typedef_decl& don't
compare typedef names. In the overload for class_or_union, make
the RETURN macro *NOT* propagate canonical type because this equal
function is used as a subroutine by overloads for class and union.
That means that the class_or_union equal function can return true,
and still, the caller (overload for class_decl or union_decl) can
later return false; in that case, we don't want canonical type to
be propagated. In the overload for class_decl::base_spec, use the
ABG_RETURN macro when returning comparing decl-bases. In the
overload for class_decl, use ABG_RETURN when returning the result
of comparing class_or_union artifacts.
(maybe_propagate_canonical_type): If we are using canonical type
comparison, then do not propagate the type, if
WITH_DEBUG_TYPE_CANONICALIZATION is defined.
(is_non_canonicalized_type): Add typedefs to the set of
non-canonicalized types.
* src/abg-writer.cc (struct non_canonicalized_type_hash, struct
non_canonicalized_type_equal): Define new functors.
(typedef nc_type_ptr_set_type): Define a new non-canonicalized set
type.
(typedef nc_type_ptr_istr_map_type): Define a new map of
non-canonicalized types/interned string map.
(write_context::{m_nc_type_id_map,
m_emitted_non_canonicalized_type_set,
m_referenced_non_canonicalized_types_set}): New data members.
(write_context::type_has_existing_id): Look for non-canonicalized
types in the m_nc_type_id_map map.
(write_context::get_id_for_type): Use m_nc_type_id_map for
non-canonicalized types.
(write_context::clear_type_id_map): Clear m_nc_type_id_map too.
(write_context::get_referenced_non_canonicalized_types): Renamed
write_context::get_referenced_non_canonical_types into this. Make
it return the new
write_context::m_referenced_non_canonicalized_types_set.
(write_context::has_non_emitted_referenced_types): Just use
write_context::type_is_emitted as it knows where to look up for
non-canonicalized types.
(write_context::record_type_as_referenced): Use
m_referenced_non_canonicalized_types_set to store referenced
non-canonicalized types. The other types are stored in
m_emitted_set as previously.
(write_context::type_is_emitted): Look into
m_emitted_non_canonicalized_type_set for non-canonicalized types.
Other types are still in m_emitted_type_set.
(write_context::{record_decl_only_type_as_emitted,
decl_only_type_is_emitted, get_emitted_decl_only_types_set}):
Remove methods.
(write_context::get_emitted_non_canonicalized_type_set): Define
new method.
(write_context::clear_referenced_types): Clear
m_referenced_non_canonicalized_types_set too, as
m_referenced_non_canonical_types_set is no more.
(write_context::referenced_type_should_be_emitted): Use only
write_context::type_is_emitted as it knows how to check it all
now.
(write_referenced_types): Use the more compact ranged-base for
loops.
(write_translation_unit): Write the non-canonicalized types that
are not yet emitted.
(write_class_decl, write_union_decl): Adjust recording type as
emitted.
(write_canonical_type_ids): Adjust.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt: Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64:
Likewise.
* tests/data/test-diff-pkg/nmap-7.70-5.el8_testjcc.x86_64-self-check-report-0.txt:
Likewise
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test39-opaque-type-report-0.txt:
Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi:
Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2022-04-14 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: compare_dies sometimes compares empty formal parms
* src/abg-dwarf-reader.cc (compare_dies): Don't try to compare
formal parameters if there is none.
2022-03-31 Dodji Seketeli <dodji@redhat.com>
abidw, dwarf-reader: Add an option to debug DIE canonicalization
* include/abg-ir.h
(environment::debug_die_canonicalization_is_on): Declare new methods.
* src/abg-ir.cc (environment::debug_die_canonicalization_is_on):
Define them.
* src/abg-dwarf-reader.cc
(compare_dies_during_canonicalization): Define new static
function.
(read_context::{debug_die_canonicalization_is_on_,
use_canonical_die_comparison_}): Declare these data members.
(read_context::read_context): Initialize them.
(read_context::get_canonical_die): When ODR is considered, if DIE
canonicalization debugging is on, use the new
compare_dies_during_canonicalization for the type comparison to be
done both structurally and canonically; both comparison should
yield the same result. Also, make this method function non-const.
* src/abg-ir-priv.h
(environment::priv::debug_die_canonicalization_): Define new data
member.
(environment::priv::priv): Initialize it.
* tools/abidw.cc (options::debug_die_canonicalization_): Define
new data member.
(options::options): Initialize it.
(display_usage): Add a description for the --debug-dc option.
(parse_command): Parse the new --debug-dc option.
(load_corpus_and_write_abixml): Use the new
environment::debug_die_canonicalization_is_on.
2022-03-31 Dodji Seketeli <dodji@redhat.com>
test-read-dwarf: Use abidw rather than using the library
* tests/test-read-dwarf.cc (set_suppressions)
(set_suppressions_from_headers): Remove these static functions.
(test_task_dwarf::perform): Use abidw rather than using the
library. Remove the path and architecture from the abixml files.
Also, when the test fails, display the actual command that failed.
2022-03-31 Dodji Seketeli <dodji@redhat.com>
Add better error messaging to several tests
* tests/test-diff-filter.cc (test_task::perform): Display the
failing command.
* tests/test-read-common.cc (test_task::run_abidw): Likewise.
* tests/test-read-common.h (test_task::run_diff): Likewise.
2022-06-13 Dodji Seketeli <dodji@redhat.com>
ir, test-read-ctf: Remove uncertainty in sorting anonymous types
* src/abg-ir.cc ({class_decl,
union_decl}::get_pretty_representation): If the anonymous class
has no internal name, use its flat representation as internal
representation.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
2022-06-09 Giuliano Procida <gprocida@google.com>
limit repeated DIE comparisons
* src/abg-dwarf-reader.cc (read_context): Add mutable
die_comparison_visits_ member.
(compare_dies): Return true if this is a self-comparison.
Return true if we have visited this comparison 10000 times.
2022-06-09 Dodji Seketeli <dodji@redhat.com>
abicompat: Properly guard inclusion of abg-ctf-reader.h
* tools/abicompat.cc: Guard inclusion of abg-ctf-reader.h with
#ifdef WITH_CTF.
2022-06-03 Dodji Seketeli <dodji@redhat.com>
Bug 29144 - abidiff doesn't report base class re-ordering
* include/abg-comparison.h (class_diff::moved_bases): Declare new
method.
* src/abg-comparison-priv.h (class_diff::priv::moved_bases_):
Define new data member.
* src/abg-reporter-priv.h (maybe_report_base_class_reordering):
Declare new function.
* src/abg-reporter-priv.cc (maybe_report_base_class_reordering):
Define new function.
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Detect that a base
class moved position and record it into
class_diff::priv::moved_bases_ data member.
* src/abg-default-reporter.cc (default_reporter::report): Use the
new maybe_report_base_class_reordering.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Likewise.
* tests/data/test-abidiff-exit/test-PR29144-report-2.txt: New
testing input file.
* tests/data/test-abidiff-exit/test-PR29144-report.txt: Likewise.
* tests/data/test-abidiff-exit/test-PR29144-v0.cc: Likewise.
* tests/data/test-abidiff-exit/test-PR29144-v0.o: Likewise.
* tests/data/test-abidiff-exit/test-PR29144-v1.cc: Likewise.
* tests/data/test-abidiff-exit/test-PR29144-v1.o: Likewise.
* tests/data/Makefile.am: Add the new files to source
distribution.
* tests/test-abidiff-exit.cc (in_out_specs): Add the new tests to
this harness.
2022-06-03 Ben Woodard via Libabigail <libabigail@sourceware.org>
abicompat: Support reading CTF and abixml
* tools/abicompat.cc (options::{fail_no_debug_info, use_ctf}): New
data members.
(options::options): Initialize them.
(display_usage): Add a help string for the new options
--fail-no-debug-info and --ctf.
(parse_command_line): Support parsing the new options
--fail-no-debug-info and --ctf.
(read_corpus): New static function.
(main): Use the new read_corpus in lieu of using
dwarf_reader::read_corpus_from_elf and/or ctf_reader::read_corpus
and/or xml::reader::read_corpus_from_input.
* doc/manuals/abicompat.rst: add documentation for new options.
2022-06-03 Ben Woodard <woodard@redhat.com>
abidiff: Remove redundant code
* tools/abidiff.cc (main): Remove redundant code.
2022-06-03 Giuliano Procida <gprocida@google.com>
XML writer: unify type emission tracking
* src/abg-writer.cc (write_context): Remove the
m_emitted_decl_only_set member.
(write_context::has_non_emitted_referenced_types): Remove the
calls to decl_only_type_is_emitted.
(write_context::record_decl_only_type_as_emitted): Removed.
(write_context::decl_only_type_is_emitted): Ditto.
(write_context::get_emitted_decl_only_types_set): Ditto.
(referenced_type_should_be_emitted): Remove the calls to
decl_only_type_is_emitted.
(write_class_decl): Just call record_type_as_emitted.
(write_union_decl): Ditto.
(write_enum_type_decl): Not changed, but now all 3 functions
have the same behaviour.
(write_canonical_type_ids): Remove the call to
get_emitted_decl_only_types_set.
2022-06-03 Ben Woodard <woodard@redhat.com>
abicompat: Add missing space
* tools/abicompat.cc (main): Add missing space in expression.
2022-06-01 Dodji Seketeli <dodji@redhat.com>
comparison: Fix leaf report summary
* src/abg-comparison.cc (corpus_diff::priv::emit_diff_stats): In
the "leaf change summary" section, add the number of removed/added
symbols not described by debug info.
2022-05-30 Giuliano Procida <gprocida@google.com>
test-annotate.cc: ignore whitespace during diff
* tests/test-annotate.cc (main): Pass diff -w option.
Suggested-by: Bogdan Graur <bgraur@google.com>
2022-05-16 Mark Wielaard <mark@klomp.org>
symtab-reader: Setup aliases before checking ppc64 opd function entries
* src/abg-elf-helpers.h (architecture_is_ppc32): Declare new
function.
* src/abg-elf-helpers.cc (architecture_is_ppc32): Define it.
* src/abg-symtab-reader.cc
(symtab::setup_symbol_lookup_tables): Rename
symtab::get_symbol_value into this. Setup symbol aliases before
setting up function entry address maps for ppc{32,64} ELFv1 and
after fixing up arm32/64 addresses.
(symtab::load_): Invoke the new setup_symbol_lookup_tables.
update_function_entry_address_symbol_map after setting up aliases.
No need to setup symbol aliases anymore.
(symtab::add_alternative_address_lookups): Invoke the new
setup_symbol_lookup_tables.
2022-05-16 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: add support to looking debug information in external path
* include/abg-ctf-reader.h (ctf_reader::create_read_context):
Add `debug_info_root_paths' argument.
(ctf_reader::reset_read_context): Likewise.
* src/abg-ctf-reader.cc: Add `read_context::elf_{handler,fd}_dbg',
data members.
(read_context::read_context): Add new `debug_info_root_paths'
argument.
(read_context::initialize): Likewise.
(ctf_reader::create_read_context): Likewise.
(ctf_reader::close_elf_handler): Release
`read_context::elf_{handler,fd}_dbg' members.
(ctf_reader::find_alt_debuginfo): Add new function.
(ctf_reader::slurp_elf_info): Add new argument `status'. Use
`find_alt_debuginfo' and `elf_helpers::find_section_by_name'
to read the symtab and ctf information from an external .debug
file, the `status' reference is updated.
(ctf_reader::read_corpus): Verify `status' after `slurp_elf_info'.
(ctf_reader::reset_read_context): Add new `debug_info_root_path'
argument.
* src/abg-elf-helpers.cc (elf_helpers::find_section_by_name): Update
comment.
* src/abg-tools-utils.cc (maybe_load_vmlinux_ctf_corpus):
Adjust `ctf_reader::{create,reset}_read_context'.
* tests/test-read-ctf.cc: Likewise.
* tools/abidiff.cc (display_usage): Add `--ctf' command line
option.
(main): Adjust `ctf_reader::create_read_context'.
Likewise.
* tools/abidw.cc (load_corpus_and_write_abixml): Adjust
`ctf_reader::create_read_context'.
* tools/abilint.cc (main): Likewise.
* tools/abipkgdiff.cc (compare, compare_to_self): Likewise.
2022-05-16 Vanessa Sochat <sochat1@llnl.gov>
Adding missing newline to build-container workflow
* .github/workflows/build-container.yaml: Add missing newline.
Reviewed-by: Ben Woodard <woodard@redhat.com>
2022-05-16 Ben Woodard <woodard@redhat.com>
Add github actions to support workflows
* .github/workflows/build-container.yaml: New file.
* .github/workflows/libabigail.yaml: Likewise.
* .github/workflows/test.yaml: Likewise.
* .github/workflows/test-fedora.yaml: Likewise.
* .github/README.md: Likewise.
* docker/Dockerfile.fedora: Likewise.
* docker/Dockerfile.ubuntu: Likewise.
* docker/Dockerfile.fedora-base: Likewise.
* docker/Dockerfile.test: Likewise.
* README-DOCKER.md: Likewise.
Reviewed-by: Ben Woodard <woodard@redhat.com>
2022-05-06 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
abipkgdiff: Add support to compare packages with CTF debug format
* tools/abipkgdiff.cc: Include `abg-ctf-reader.h'.
(options::use_ctf): Add new data member.
(display_usage): Add `--ctf' usage.
(compare): Add condition to use ctf-reader to extract
(parse_command_line): Set `options::use_ctf' when --ctf
option is provided.
and build CTF corpora when `options::use_ctf' is set.
(compare_to_self): Likewise.
2022-05-06 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: CTF debug info for some symbols is not found
* src/abg-ctf-reader.cc (read_context::is_elf_exec): Remove
data member.
(ctf_reader::process_ctf_qualified_type): Add condition to avoid
use qualifier in functions.
(ctf_reader::process_ctf_archive): Use `ctf_lookup_by_symbol_name'
to find debug information when `ctf_lookup_variable' was not
lucky iff `corpus::CTF_ORIGIN'.
(ctf_reader::slurp_elf_info): Use `elf_helpers::find_section_by_name'
to read .dynsym and .dynstr when {EXEC,DYN}.
* src/abg-elf-helpers.h (elf_helpers::find_section_by_name): Add new
declaration.
* src/abg-elf-helpers.cc (elf_helpers::find_section_by_name): Add new
definition.
2022-05-06 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: shows incomplete summary changes
* src/abg-ctf-reader.cc (read_context::exported_decls_builder_):
Add new data member.
(read_context::exported_decls_builder): Add new get/set member functions.
(read_context::maybe_add_{fn,var}_to_exported_decls): Likewise.
(read_context::initialize): Initialize exported_decls_builder_ member.
(read_context::build_ir_node_for_variadic_parameter_type): Add new function.
(read_context::process_ctf_function_type): Add additional code to handle
function's variadic parameter.
(read_context::process_ctf_archive): Rename variable for clarity
from `ctf_var_type' to `ctf_sym_type', using new member functions
`maybe_add_{fn,var}_to_exported_decls'.
(read_context::read_corpus): Set `exported_decls_builder'.
* tests/test-read-common.cc (test_task::run_abidw): Fix error message.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Adjust test case.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
2022-05-06 Frederic Cambus <fred@statdns.com>
Fix numbering error in the abidiff manual.
* doc/manuals/abidiff.rst: Fix numbering error for the
--headers-dir2 option.
2022-05-04 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: Add support to read CTF information from the Linux Kernel
* abg-elf-reader-common.h: Include ctf-api.h file.
(read_and_add_corpus_to_group_from_elf, set_read_context_corpus_group)
(reset_read_context, dic_type_key): Declare new member functions.
* include/abg-ir.cc (types_defined_same_linux_kernel_corpus_public): Use
bitwise to know the corpus `origin'.
* src/abg-ctf-reader.cc: Include map, algorithms header files.
(read_context::type_map): Change from unordered_map to std::map storing
ctf dictionary name as part of the key.
(read_context::is_elf_exec): Add new member variable.
(read_context::{cur_corpus_, cur_corpus_group_}): Likewise.
(read_context::unknown_types_set): Likewise.
(read_context::{current_corpus_group, main_corpus_from_current_group,
has_corpus_group, current_corpus_is_main_corpus_from_current_group,
should_reuse_type_from_corpus_group}): Add new member functions.
(read_context::{add_unknown_type, lookup_unknown_type, initialize}):
Likewise.
(read_context::{add_type, lookup_type}): Add new `ctf_dict_t' type
argument.
(ctf_reader::{process_ctf_typedef, process_ctf_base_type,
process_ctf_function_type, process_ctf_forward_type,
process_ctf_struct_type, process_ctf_union_type, process_ctf_array_type,
process_ctf_qualified_type, process_ctf_enum_type}): Add code to `reuse'
types already registered in main corpus `should_reuse_type_from_corpus_group'.
Use new `lookup_type' and `add_type' operations on `read_context::types_map'.
Replace function calls to the new ctf interface. Add verifier to not build
types duplicated by recursive calling chain.
(ctf_reader::process_ctf_type): Add code to return immediately if the
ctf type is unknown. Add unknown types to `unknown_types_set'.
(ctf_reader::process_ctf_archive): Change comment.
Add code to iterate over global symbols, searching by symbol name in the
ctf dictionary using `ctf_lookup_{variable,by_symbol_name}' depending of
the ELF file type and corpus type, creating a `{var,fuc}_decl' using the
return type of `ctf_type_kind'. Also close the ctf dict and call
`canonicalize_all_types'.
(slurp_elf_info): Set `is_elf_exec' depending of ELF type. Also return
success if corpus origin is Linux and symbol table was read.
(ctf_reader::read_corpus): Add current corpus. Set corpus origin to
`LINUX_KERNEL_BINARY_ORIGIN' if `is_linux_kernel' returns true. Verify
the ctf reader status, now the ctf archive is 'opened' using
`ctf_arc{open,bufopen}' depending if the corpus origin has
`corpus::LINUX_KERNEL_BINARY_ORIGIN' bit set. Use
`sort_{function,variables}' calls after extract ctf information.
`ctf_close' is called from `read_context' destructor.
(read:context::{set_read_context_corpus_group, reset_read_context,
read_and_add_corpus_to_group_from_elf, dic_type_key): Add new member
function implementation.
* include/abg-tools-utils.h (build_corpus_group_from_kernel_dist_under):
Add `origin' parameter with default `corpus::DWARF_ORIGIN'.
* src/abg-tools-utils.cc: Use `abg-ctf-reader.h' file.
(maybe_load_vmlinux_dwarf_corpus): Add new function.
(maybe_load_vmlinux_ctf_corpus): Likewise.
(build_corpus_group_from_kernel_dist_under): Update comments.
Add new `origin' argument. Use `maybe_load_vmlinux_dwarf_corpus'
or `maybe_load_vmlinux_ctf_corpus' according to `origin' value.
* src/abg-corpus.h (corpus::origin): Update `origin' type
values in enum.
* src/abg-corpus-priv.h (corpus::priv): Replace `origin' type
from `corpus::origin' to `uint32_t'.
* src/abg-corpus.cc (corpus::{get,set}_origin): Replace data
type from `corpus::origin' to `uint32_t'.
* tools/abidw.cc (main): Use of --ctf argument to set format debug.
* tests/test-read-ctf.cc: Add new tests to harness.
* tests/data/test-read-ctf/test-PR27700.abi: New test expected
result.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many-ctf.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol-ctf.o.hash.abi: Likewise.
* tests/data/test-read-common/test-PR26568-2.o: Adjust.
* tests/data/test-read-ctf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-ctf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.c: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi: Likewise.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi:
Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-ctf.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/data/test-read-ctf/test0: Likewise.
* tests/data/test-read-ctf/test0.abi: Likewise.
* tests/data/test-read-ctf/test0.c: Likewise.
* tests/data/test-read-ctf/test0.hash.abi: Likewise.
* tests/data/test-read-ctf/test1.so.abi: Likewise.
* tests/data/test-read-ctf/test1.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test2.so.abi: Likewise.
* tests/data/test-read-ctf/test2.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test3.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test4.so.abi: Likewise.
* tests/data/test-read-ctf/test4.so.hash.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
2022-05-04 vsoch <vsoch@users.noreply.github.com>
Add Logic to detect file type by extension
* tools/fedabipkgdiff - add logic to detect file type by extension
Reviewed-by: Ben Woodard <woodard@redhat.com>
2022-05-04 Ben Woodard <woodard@redhat.com>
Add an option ignore SONAME differences in libraries
* doc/manuals/abicompat.rst - added new option
* doc/manuals/abidiff.rst - added new option to manpage
* src/abg-comparison.cc (compute_diff): don't bother comparing the
sonames if you aren't going to print them.
* tools/abicompat.cc (options::ignore_soname): Add new data
member.
(parse_command_line): Support the new --ignore-soname command line
option.
(display_usage): Add a description string for the new
--ignore-soname command line option.
(create_diff_context): Set the diff_context::show_soname_change
from the new options::ignore_soname data member.
* tools/abidiff.cc (options::ignore_soname): Add new data member.
(display_usage): Add a description string for the new
--ignore-soname command line option.
(parse_command_line): Support the new --ignore-soname command line
option.
(set_diff_context_from_opts): Set the
diff_context::show_soname_change from the new
options::ignore_soname.
2022-04-07 Giuliano Procida <gprocida@google.com>
symtab: fix up 64-bit ARM address which may contain tags
* src/abg-elf-helpers.cc: (architecture_is_arm64): Add helper.
* src/abg-elf-helpers.h: Likewise.
* src/abg-symtab-reader.cc: (get_symbol_value): Adjust 64-bit
ARM symbol values by extending bit 55 into bits 56 to 63.
2022-04-07 Giuliano Procida <gprocida@google.com>
symtab: refactor ELF symbol value tweaks
* src/abg-symtab-reader.cc (symtab::load_): Replace address
tweaking logic with a call to get_symbol_value.
(symtab::add_alternative_address_lookups): Likewise.
(symtab::get_symbol_value): New function containing address
tweaking logic for PPC and ARM.
2022-04-29 Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
ctf-reader: Fix multiple var-decl in anonymous struct/uninons
* src/abg-ctf-reader.cc (process_ctf_sou_members): Remove
CTF_MN_RECURSE flag.
* tests/data/Makefile.am: Add new input test files.
* tests/data/test-read-ctf/test-anonymous-fields.c: New
test file.
* tests/data/test-read-ctf/test-anonymous-fields.o: New
expected test output.
* tests/data/test-read-ctf/test-anonymous-fields.o.abi:
Likewise.
* tests/test-read-ctf.cc: Add new test.
2022-04-25 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
tools-utils: `entry_of_file_with_name' returns incorrect result
* src/abg-tools-utils.cc (entry_of_file_with_name): Replace
call `string_ends_with' by `basename'.
2022-04-19 Ben Woodard <woodard@redhat.com>
Fix typo in abipkgdiff manpage
* doc/manuals/abipkgdiff.rst: add missing `--`
2022-03-17 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Add support to undefined forward declaration types
* src/abg-ctf-reader.cc (process_ctf_forward_type): New
function.
(process_ctf_type): New CTF_K_FORWARD case.
* tests/data/test-read-ctf/test-forward-undefine-type-decl.c:
New testcase.
* tests/data/test-read-ctf/test-forward-undefine-type-decl.abi:
New expected result.
* tests/data/test-read-ctf/test-forward-undefine-type-decl.o
New test input.
* tests/test-read-ctf.cc: Add new testcase to test harness.
* tests/data/Makefile.am: Add new test input files to test harness.
2022-03-07 Dodji Seketeli <dodji@redhat.com>
comparison: Avoid sorting diff nodes with wrong criteria
* src/abg-comparison.cc (diff::append_child_node): Do not sort
children nodes here because they must have been sorted already.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Likewise.
2022-03-07 Dodji Seketeli <dodji@redhat.com>
comparison: Factorize the code that inserts diff nodes to the graph
* include/abg-comparison.h ({distinct, var, pointer, reference,
array, qualified_type, enum, class_or_union, class, union, base,
scope, fn_parm, function_type, function_decl, type_decl,
typedef}_diff::finish_diff_type): Remove these declarations.
* src/abg-comparison.cc ({distinct, var, pointer, reference,
array, qualified_type, enum, class_or_union, class, union, base,
scope, fn_parm, function_type, function_decl, type_decl,
typedef}_diff::finish_diff_type): Remove these definitions.
(diff::finish_diff_type): Add the code to connect the children
nodes to the current node, making the generic view of the diff
node usable to walk the graph.
2022-03-07 Dodji Seketeli <dodji@redhat.com>
comparison: Describe the "generic view" of a diff node
* include/abg-comparison.h (class diff): Add comments to this class.
(diff::chain_into_hierarchy): Add comment to this method.
* src/abg-comparison-priv.h (diff::priv): Add comment to this class.
* src/abg-comparison.cc (diff::finish_diff_type): Add comment to
this method.
(diff::traverse): Add comment.
2022-03-03 Dodji Seketeli <dodji@redhat.com>
Bug 28013 - Acknowledge variadic parameter type is not canonicalized
* src/abg-ir.cc (is_non_canonicalized_type): Recognize variadic
parameter types.
* tests/data/test-diff-filter/test-PR28013-fn-variadic.c.{0,1}.abi: New test inputs.
* tests/data/test-diff-filter/test-PR28013-fn-variadic.c.report.txt: Likewise.
* tests/data/Makefile.am: Add the new test files to source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new tests to
this harness.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-filter/test-PR28013-fn-variadic.c.0.abi: Likewise.
* tests/data/test-diff-filter/test-PR28013-fn-variadic.c.1.abi: Likewise.
* tests/data/test-diff-filter/test-PR28013-fn-variadic.c.report.txt: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2022-02-24 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Don't propagate canonical type upon aggregate redundancy
* src/abg-dwarf-reader.cc (compare_dies): Do not propagate
canonical type when aggregate redundancy is detected.
2022-02-10 Dodji Seketeli <dodji@redhat.com>
Bug 26646 - unexpected declaration-only types (part 2)
* src/abg-dwarf-reader.cc (struct dwarf_offset_pair_hash)
(dwarf_offset_pair_set_type): Define new type.
(die_offset, has_offset_pair, insert_offset_pair)
(erase_offset_pair): Define new static helper functions.
(compare_dies): Use a set of DWARF offsets for the
'aggregates_being_compared' data structure, rather than a set of
string representation of the DIEs. Always look at the size of the
types being compared first so that we can get out quickly if they
differ. For DIEs of DW_TAG_{union,struct}_type kind, don't limit
the depth of the stack of DIEs being compared to 5; so we don't
consider two types as being equal just because the depth of the
stack being compared is 5 and the two types have the same size and
are equal. Hopefully things don't take too long.
2022-03-01 Dodji Seketeli <dodji@redhat.com>
ir: Remove obsolete comment from enumerator equal operator
* src/abg-ir.cc (enum_type_decl::enumerator::operator==): Remove
the obsolete parts from the comment.
2022-03-01 Dodji Seketeli <dodji@redhat.com>
reader: Fix a compilation warning
* src/abg-reader.cc (build_var_decl): Add braces to an 'if'
statement.
2022-02-28 Dodji Seketeli <dodji@redhat.com>
abilint --show-type-use: Show results for global decls that have no symbols
* include/abg-fwd.h (is_at_global_scope): Declare ...
* src/abg-ir.cc (is_at_global_scope): ... new overload.
* tools/abilint.cc (emit_artifact_use_trace): Emit the trace also
when the decl is at global scope or has a linkage name.
2022-02-17 Dodji Seketeli <dodji@redhat.com>
abilint: add the --show-type-use option
* configure.ac: Define the --enable-show-type-use-in-abilint
configure option. It defines the WITH_SHOW_TYPE_USE_IN_ABILINT
macro.
* include/abg-reader.h (read_translation_unit): Add an overload
that takes the read context.
(get_types_from_type_id, get_artifact_used_by_relation_map):
Declare new functions.
* src/abg-reader.cc (get_types_from_type_id)
(get_artifact_used_by_relation_map): Declare these functions as
friend of the read_context type.
(read_context::m_artifact_used_by_map):
(read_context::key_type_decl): Replace the shared_ptr<type_base>
type of the first parm by the equivalent type_base_sptr type.
(read_context::{record_artifact_as_used_by,
record_artifacts_as_used_in_fn_decl,
record_artifacts_as_used_in_fn_type}): Add new methods guarded by
the WITH_SHOW_TYPE_USE_IN_ABILINT macro.
(get_types_from_type_id, get_artifact_used_by_relation_map): Define
new functions guarded by the WITH_SHOW_TYPE_USE_IN_ABILINT macro.
(read_translation_unit): Define new overload.
(RECORD_ARTIFACT_AS_USED_BY, RECORD_ARTIFACTS_AS_USED_IN_FN_DECL)
(RECORD_ARTIFACTS_AS_USED_IN_FN_TYPE): Define new macros.
(build_function_decl, build_var_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_function_type, build_array_type_def, build_enum_type_decl)
(build_typedef_decl, build_class_decl, build_union_decl): Use the
macros above to mark the relevant sub-types as used by the
artifact being built.
* tools/abilint.cc (struct artifact_use_relation_tree): Define new
type, guarded by the WITH_SHOW_TYPE_USE_IN_ABILINT macro.
(fill_artifact_use_tree, build_type_use_tree, emit_trace)
(emit_artifact_use_trace, emit_artifact_use_trace)
(show_how_type_is_used): Define static functions guarded by the
WITH_SHOW_TYPE_USE_IN_ABILINT macro.
(display_usage): Add doc string for the --show-type-use option,
guarded by the WITH_SHOW_TYPE_USE_IN_ABILINT macro.
(parse_command_line): Parse the --show-type-use option, guarded by
the WITH_SHOW_TYPE_USE_IN_ABILINT macro.
(main): Slight re-organisation to make the abixml file reading use
a read_context. That read context is then used to analyze how a
given type is used whenever the --show-type-use option is used.
2022-02-17 Dodji Seketeli <dodji@redhat.com>
configure: Remove use of obsolete AC_CONFIG_HEADER
* configure.ac: Replace the use of the obsolete AC_CONFIG_HEADER
by AC_CONFIG_HEADERS.
2022-02-08 Randy MacLeod <Randy.MacLeod@windriver.com>
Improve some grammar
* COMPILING: Improve grammar
* CONTRIBUTING: Improve grammar
* README: Improve grammar
* VISIBILITY: Improve grammar
2022-01-21 Giuliano Procida <gprocida@google.com>
XML writer: do not create extra temporary referenced type shared_ptr
* src/abg-writer.cc (write_referenced_types): Create temporary
shared_ptr objects within each conditional branch instead of
outside the conditionals and within one of the branches.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-01-21 Giuliano Procida <gprocida@google.com>
XML writer: improve slightly emission of top-level declarations
* src/abg-writer.cc (decl_is_emitted): Make decl_base_sptr
argument a const reference.
(write_translation_unit): Eliminate a typedef and just use a
range-for loop without the extra dynamic cast for the non-type
case. Use else instead of continue to make it clear there are
only two possibilities.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-01-21 Giuliano Procida <gprocida@google.com>
XML writer: drop write_elf_symbols_table variable emitted_syms
* src/abg-writer.cc (write_elf_symbols_table): Drop unused
local variable emitted_syms.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-01-21 Giuliano Procida <gprocida@google.com>
XML writer: remove type_hasher and remaining comment
* src/abg-writer.cc (type_hasher): Remove this unused functor.
Remove a following comment referencing it.
Reviewed-by: Matthias Maennich <maennich@google.com>
2022-02-07 Dodji Seketeli <dodji@redhat.com>
Bug 26646 - unexpected declaration-only types
* src/abg-dwarf-reader.cc (add_or_update_class_type): Do not reuse
the IR for a DIE with the same textual representation as the one
we are seeing now.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
2022-02-07 Dodji Seketeli <dodji@redhat.com>
symtab-reader: Remove an over-agressive assertion
* src/abg-symtab-reader.cc
(symtab::add_alternative_address_lookups): Remove over-aggressive
assert.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2022-01-29 David Seifert <soap@gentoo.org>
Find fts-standalone on musl
* configure.ac: Invoke AC_CANONICAL_HOST to compute the host_cpu,
host_vendor, host_os parts of the 'host" variable. Then if the
host_os ends up with "musl" then, check for the fts-standalone
pkgconfig module and record the fts library into
FTS_{LIBS,CFLAGS}.
* src/Makefile.am: Link to $FTS_LIBS and use $FTS_CFLAGS for
compilation.
* tools/Makefile.am: Likewise.
* tools/abisym.cc: Include libgen.h
* tools/kmidiff.cc: Remove useless fts.h header file.
2022-02-07 Dodji Seketeli <dodji@redhat.com>
symtab-reader: Fix typo in comment
* src/abg-symtab-reader.cc
(symtab::update_function_entry_address_symbol_map): Fix typo in
comment.
2022-01-20 Dodji Seketeli <dodji@redhat.com>
writer: small compilation error fix
* abg-writer.cc (write_type_record): Fix const-ness in argument
passing.
2021-11-26 Matthias Maennich <maennich@google.com>
abidiff: improve whitespace generation in symbol diff report
* src/abg-reporter-priv.cc (maybe_report_diff_for_symbol):
Make return void. Simplify and fix new-line emission. Remove
comma emission. Tweak CRC wording.
* src/abg-reporter-priv.h (maybe_report_diff_for_symbol):
Return void.
* tests/data/test-abidiff-exit/test-crc-report.txt: Shorten CRC
wording.
* tests/data/test-abidiff/test-crc-report.txt: Likewise.
* tests/data/test-diff-filter/test-PR27569-report-0.txt:
Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2022-01-19 George Rawlinson <grawlinson@archlinux.org>
Bug 28663 - generate man page for kmidiff
* doc/manuals/conf.py: Update copyright year. Generate man page
for the kmidiff tool.
2021-12-03 Matthias Maennich <maennich@google.com>
XML writer: resolve declaration-only enum definitions
* src/abg-writer.cc (write_enum_type_decl): Look through
declaration-only types the same as for structs and unions.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-12-03 Matthias Maennich <maennich@google.com>
XML writer: map type ids by bare pointer
* src/abg-writer.cc (type_ptr_map): use default equality on
type_base pointer.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Refresh
test case, as described above.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-12-03 Matthias Maennich <maennich@google.com>
XML writer: track emitted types by bare pointer
* src/abg-writer.cc (type_ptr_set_type): Change typedef
container type to use default equality and hashing for pointer
keys.
(fn_type_ptr_set_type): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2022-01-18 Giuliano Procida <gprocida@google.com>
abidiff: include ABI XML versions when reporting a mismatch cont.
* tools/abidiff.cc
(emit_incompatible_format_version_error_message): Fix
parameter documentation.
Fixes: b251bc611eb6 ("abidiff: include ABI XML versions when reporting a mismatch")
2022-01-18 Giuliano Procida <gprocida@google.com>
abidiff: include ABI XML versions when reporting a mismatch
* tools/abidiff.cc
(emit_incompatible_format_version_error_message): Add version1
and version2 arguments. Add versions to error message.
(main): Pass emit_incompatible_format_version_error_message
mismatching versions.
2022-01-18 Mark Wielaard <mark@klomp.org>
DWARF reader: use size_t for DWARF expression length cont.
* src/abg-dwarf-reader.cc (eval_last_constant_dwarf_sub_expr):
Change expr_len argument type to size_t.
(op_pushes_constant_value): Update ops_len and index argument
types to size_t. Update next_index argument type to size_t&.
(op_pushes_non_constant_value): Likewise.
(op_is_arith_logic): Update expr_len and index argument types
to size_t. Update next_index argument type to size_t&.
(op_is_control_flow): Likewise.
Fixes: 16207c4af7bc ("Bug 28191 - Interpret DWARF 5 addrx locations")
2022-01-17 Giuliano Procida <gprocida@google.com>
DWARF reader: use size_t for DWARF expression length
* src/abg-dwarf-reader.cc (die_location_expr): Change expr_len
argument type to size_t*.
(op_manipulates_stack): Change expr_len and index argument
types to size_t; change next_index argument type to size_t&.
(eval_last_constant_dwarf_sub_expr): Change expr_len argument
and local variables index and next_index types to size_t.
(die_member_offset): Change local variable expr_len type to
size_t.
(die_location_address): Likewise.
(die_virtual_function_index): Likewise.
Fixes: 16207c4af7bc ("Bug 28191 - Interpret DWARF 5 addrx locations")
2022-01-11 Giuliano Procida <gprocida@google.com>
symtab reader: fix up alternative addresses
* src/abg-symtab-reader.cc
(symtab::add_alternative_address_lookups): Tweak function
addresses in the same manner as done in symtab::load_.
2022-01-14 David Cantrell <dcantrell@redhat.com>
Include <libgen.h> in tools/abisym.cc for basename(3)
* tools/abisym.cc: Include <libgen.h> in tools/abisym.cc for basename(3)
2022-01-13 Giuliano Procida <gprocida@google.com>
Bug 28191 - Interpret DWARF 5 addrx locations
* src/abg-dwarf-reader.cc (die_location_address): Use
dwarf_attr_integrate, dwarf_getlocation and
dwarf_getlocation_attr to decode addreses, instead of
die_location_expr and eval_last_constant_dwarf_sub_expr.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Refresh test reference output; two more symbols have types.
2022-01-14 Dodji Seketeli <dodji@redhat.com>
Bug 28319 - re-fix of rhbz1951526 - SELF CHECK FAILED for 'gimp-2.10'
* include/abg-ir.h (environment::use_enum_binary_only_equality):
Remove.
* src/abg-comparison.cc (compute_diff): In the overload for
enum_type_decl, stop using binary-only-equality for enums.
* src/abg-dwarf-reader.cc
(read_context::compare_before_canonicalisation): Likewise.
* src/abg-ir.cc (environment::use_enum_binary_only_equality):
Remove.
(enumerators_values_are_equal)
(is_enumerator_value_present_in_enum)
(is_enumerator_value_redundant): Define new static functions.
(equals): In the overload for enum_type_decl, use the new
is_enumerator_value_redundant to detect if two enums are equal
modulo a redundant enumerator value. In that case, consider they
are equal.
* tests/data/test-abidiff/test-enum0-report.txt: Adjust.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
2022-01-05 Thomas Schwinge <thomas@codesourcery.com>
Handle several variants of Python 'imp', 'importlib' modules
* tests/mockfedabipkgdiff.in: Handle several variants of Python
'imp', 'importlib' modules.
Tested-by: Mark Wielaard <mark@klomp.org> (CentOS 7)
2021-12-21 Dodji Seketeli <dodji@redhat.com>
suppression: Fix compilation warning on el7
* src/abg-suppression.cc (type_suppression::suppresses_diff):
Remove the unused variable second_type_decl.
2021-12-21 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Assert on ir::hash_as_canonical_type_or_constant
* src/abg-ctf-reader.cc (process_ctf_base_type): Add new
`translation_unit_sptr' parameter. Add condition to validate
success 'base_type' construction and register type object.
(process_ctf_typedef): Add `lookup_type' to get a `type_base'
object when this was previously created, if this is not the
case, register ctf type. Add condition to validate success
'base_type' construction and register type object.
(process_ctf_function_type): Likewise.
(process_ctf_array_type): Likewise.
(process_ctf_qualified_type): Likewise.
(process_ctf_pointer_type): Likewise.
(process_ctf_struct_type): Add `add_decl_to_scope'.
(process_ctf_union_type): Likewise.
(process_ctf_type): Add `lookup_type' to get a `type_base'
object when this was previously created. Delegate register
type object to `process_ctf_*'.
* tests/data/Makefile.am: Add tests I/O and expected files.
* tests/data/test-read-ctf/test-array-of-pointers.[co]: New
testcase.
* tests/data/test-read-ctf/test-list-struct.[co]: Likewise.
* tests/data/test-read-ctf/test-callback.[co]: Likewise.
* tests/data/test-read-ctf/test-callback2.[co]: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.[co]: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.[co]: Likewise.
* tests/data/test-read-ctf/test-array-of-pointers.abi:
Expected test output.
* tests/data/test-read-ctf/test-callback.abi: Likewise.
* tests/data/test-read-ctf/test-callback2.abi: Likewise.
* tests/data/test-read-ctf/test-forward-type-decl.abi: Likewise.
* tests/data/test-read-ctf/test-functions-declaration.abi: Likewise.
* tests/data/test-read-ctf/test-list-struct.abi: Likewise.
* tests/test-read-ctf.cc: Add testcases to CTF test harness.
2021-12-21 Thomas Schwinge <thomas@codesourcery.com>
Replace Python 'import importlib' with 'import importlib.machinery'
* tests/mockfedabipkgdiff.in: Replace Python 'import importlib'
with 'import importlib.machinery'.
2021-12-17 Thomas Schwinge <thomas@codesourcery.com>
fedabipkgdiff: Also accept MIME type 'application/x-redhat-package-manager' for RPM files
*** 4.0.0 900
900 http://ftp.de.debian.org/debian testing/main amd64 Packages
900 http://ftp.de.debian.org/debian testing/main i386 Packages
800 http://ftp.de.debian.org/debian unstable/main amd64 Packages
800 http://ftp.de.debian.org/debian unstable/main i386 Packages
100 /var/lib/dpkg/status
$ awk '$2 ~ /rpm/' < /etc/mime.types
application/x-redhat-package-manager rpm
$ dpkg -S /etc/mime.types
mime-support: /etc/mime.types
$ apt policy mime-support
mime-support:
Installed: 3.64ubuntu1
Candidate: 3.64ubuntu1
Version table:
*** 3.64ubuntu1 500
500 http://de.archive.ubuntu.com/ubuntu focal/main amd64 Packages
500 http://de.archive.ubuntu.com/ubuntu focal/main i386 Packages
100 /var/lib/dpkg/status
$ awk '$2 ~ /rpm/' < /etc/mime.types
application/x-redhat-package-manager rpm
$ dpkg -S /etc/mime.types
mime-support: /etc/mime.types
$ apt-cache policy mime-support
mime-support:
Installed: 3.54ubuntu1.1
Candidate: 3.54ubuntu1.1
Version table:
*** 3.54ubuntu1.1 0
500 http://us.archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages
500 http://us.archive.ubuntu.com/ubuntu/ trusty-security/main amd64 Packages
100 /var/lib/dpkg/status
3.54ubuntu1 0
500 http://us.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages
Otherwise, 'is_rpm_file' fails, resulting in a few test cases failing with an
unhelpful 'Unknown arguments. Please refer to --help.' message (similar to what
had been observed in PR22077 "runtestfedabipkgdiff.py fails on centos-x86_64").
* tools/fedabipkgdiff (is_rpm_file): Also accept MIME type
'application/x-redhat-package-manager' for RPM files.
CC: Chenxiong Qi <cqi@redhat.com>
2021-12-17 Thomas Schwinge <thomas@codesourcery.com>
Replace use of deprecated Python 'imp' module with 'importlib'
* tests/mockfedabipkgdiff.in: Replace use of deprecated Python
'imp' module with 'importlib'.
CC: Chenxiong Qi <cqi@redhat.com>
2021-12-17 Thomas Schwinge <thomas@codesourcery.com>
fedabipkgdiff: Enable testing without proper Koji installation
* tools/fedabipkgdiff: Handle 'koji.ConfigurationError'.
* configure.ac: Likewise.
* CONTRIBUTING: Document "fedabipkgdiff testing".
Documenting/providing a way to enable such testing, this commit can be
considered a sequel to commit 90d236a03343d75ea504d53c73270e50b9000e75
"Bug 22076 - Disable fedabipkgdiff for old koji clients", for Mark Wielaard's
PR22076 "runtestfedabipkgdiff.py fails on debian-amd64".
2021-12-10 Thomas Schwinge <thomas@codesourcery.com>
abipkgdiff: Use 'convert_path_to_relative' in 'create_abi_file_path'
* tools/abipkgdiff.cc (create_abi_file_path): Use
'convert_path_to_relative'.
2021-12-10 Thomas Schwinge <thomas@codesourcery.com>
abipkgdiff: Respect 'create_abi_file_path' interface
* tools/abipkgdiff.cc (compare_to_self): Respect
'create_abi_file_path' interface.
2021-12-10 Thomas Schwinge <thomas@codesourcery.com>
configure: Instead of for rpm 4.15+ version, test actual rpm/zstd support
* configure.ac: Instead of for rpm 4.15+ version, test actual
rpm/zstd support.
* tests/test-diff-pkg.cc: Adjust.
2021-12-14 Thomas Schwinge <thomas@codesourcery.com>
Further update 'make distcheck-fast'
* CONTRIBUTING: Further update 'make distcheck-fast'.
Suggested-by: Matthias Maennich <maennich@google.com>
2021-12-14 Thomas Schwinge <thomas@codesourcery.com>
Add '.mailmap'
* .mailmap: New.
CC: Ben Woodard <woodard@redhat.com>
CC: Guillermo E. Martinez <guillermo.e.martinez@oracle.com>
CC: Jose E. Marchesi <jose.marchesi@oracle.com>
CC: Matthias Maennich <maennich@google.com>
CC: Xiao Jia <xiaoj@google.com>
2021-12-11 Thomas Schwinge <thomas@codesourcery.com>
configure: Tune fedabipkgdiff dependencies detection
* configure.ac: Tune fedabipkgdiff dependencies detection.
2021-12-11 Thomas Schwinge <thomas@codesourcery.com>
CONTRIBUTING: Move "Coding language and style" section
* CONTRIBUTING: Move "Coding language and style" section.
2021-12-15 Mark Wielaard <mark@klomp.org>
dwarf-reader: Workaround libdw dwarf_location_expression bug
* src/abg-dwarf-reader.cc (die_constant_data_member_location):
New function.
(die_member_offset): Use die_constant_data_member_location
before calling die_location_expr and eval_quickly.
2021-12-14 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
Add regression tests for ctf reading
* tests/test-read-ctf.cc: New ctf reading regression test.
* tests/test-read-common.cc: New library to be used with
test-read-{ctf,dwarf}.cc.
* tests/test-read-common.h: Likewise.
* tests/test-annotate.cc (in_out_specs): Adjust path for input files.
* tests/Makefile.am: Build new tests/test-read-ctf.cc file.
* tests/data/Makefile.am: Add test inputs and expected files.
Add libtestreadcommon.a test library and use it for test-read-{ctf,dwarf}.
* tests/test-read-dwarf.cc: Adapt test to use libtestreadcommon.a in
test-read-common.{cc,h}.
* tests/data/test-annotate/test3.so.abi: Adjust ELF input path file
location to ./tests/data/test-read-common.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-read-common/PR26261: Move test harness to
test-read-common directory.
* tests/data/test-read-common/PR27700: Likewise.
* tests/data/test-read-common/test-PR26568-*: Likewise.
* tests/data/test-read-common/test3.{c,so}: Likewise.
* tests/data/test-read-common/test4.{c,so}: Likewise.
* tests/data/test-read-common/crti*: Helper object to export
_init and _fini sysmbols.
* tests/data/test-read-ctf/test-ambiguous-struct-A.c: New testcase.
* tests/data/test-read-ctf/test-ambiguous-struct-B.c: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.c: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.c: Likewise.
* tests/data/test-read-ctf/test-enum.c: Likewise.
* tests/data/test-read-ctf/test-enum-many.c: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.c: Likewise.
* tests/data/test-read-ctf/test-struct-iteration.c: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.c: Likewise.
* tests/data/test-read-ctf/test0.c: Likewise.
* tests/data/test-read-ctf/test1.c: Likewise.
* tests/data/test-read-ctf/test2.c: Likewise.
* tests/data/test-read-ctf/test5.c: Likewise.
* tests/data/test-read-ctf/test7.{c,h}: Likewise.
* tests/data/test-read-ctf/test8.c: Likewise.
* tests/data/test-read-ctf/test9.c: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi: Testcase
expected result.
* tests/data/test-read-ctf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-ctf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-A.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-ambiguous-struct-B.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-a.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-conflicting-type-syms-b.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum.o.abi: Likewise.
* tests/data/test-read-ctf/test-enum-many.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-enum-symbol.o.hash.abi: Likewise.
* tests/data/test-read-ctf/test-struct-iteration.o.abi: Likewise.
* tests/data/test-read-ctf/test-dynamic-array.o.abi: Likewise.
* tests/data/test-read-ctf/test0: Likewise.
* tests/data/test-read-ctf/test0*.abi: Likewise.
* tests/data/test-read-ctf/test1.so: Likewise.
* tests/data/test-read-ctf/test1*.abi: Likewise.
* tests/data/test-read-ctf/test2.so: Likewise.
* tests/data/test-read-ctf/test2*.abi: Likewise.
* tests/data/test-read-ctf/test3.so.abi: Likewise.
* tests/data/test-read-ctf/test4*.abi: Likewise.
* tests/data/test-read-ctf/test5.o.abi: Likewise.
* tests/data/test-read-ctf/test7.o.abi: Likewise.
* tests/data/test-read-ctf/test8.o.abi: Likewise.
* tests/data/test-read-ctf/test9.o.abi: Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Update
expected abixml file.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.*.abi: Likewise.
* tests/data/test-read-dwarf/test3*.abi: Likewise.
* tests/data/test-read-dwarf/test4*.abi: Likewise.
* doc/api/libabigail.doxy: Add tests/test-read-common.{cc,h} to
doxygen.
2021-11-27 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Fix length in dynamic array definition
* src/abg-ctf-reader.cc (process_ctf_array_type):
set subrange_type::is_infinite when `upper_bound' value
is equal to `0'.
2021-12-09 Thomas Schwinge <thomas@codesourcery.com>
Better highlight 'make distcheck-fast'
* CONTRIBUTING: Better highlight 'make distcheck-fast'.
2021-12-03 Matthias Maennich <maennich@google.com>
XML writer: use exemplar types for tracking referenced types
* src/abg-writer.cc (record_type_as_referenced): Use exemplar
type with referenced type sets.
(type_is_referenced): Likewise.
(tests/data/test-annotate/test14-pr18893.so.abi): Duplicate
type(s) removed, as described above.
(tests/data/test-read-dwarf/test14-pr18893.so.abi): Likewise.
(tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi):
Likewise.
(tests/data/test-read-dwarf/test16-pr18904.so.abi): Likewise.
(tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi):
Likewise.
(tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi):
Likewise.
(tests/data/test-read-dwarf/PR25007-sdhci.ko.abi): Some
function type(s) reordered, as described above.
(tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi):
Likewise.
(tests/data/test-annotate/test15-pr18892.so.abi):: Duplicate
type(s) removed and some function type(s) reordered, as
described above.
(tests/data/test-read-dwarf/test15-pr18892.so.abi): Likewise.
(tests/data/test-annotate/test21-pr19092.so.abi): Likewise.
(tests/data/test-read-dwarf/test21-pr19092.so.abi): Likewise
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-12-03 Matthias Maennich <maennich@google.com>
XML writer: use consistent type pointers for type ids and emission tracking
* include/abg-fwd.h (get_exemplar_type): Declare new function.
* src/abg-ir.cc (get_exemplar_type): Define new function.
* src/abg-writer.cc (type_has_existing_id): use get_exemplar_type
for resolution.
(get_id_for_type): Likewise.
(record_type_as_emitted): Likewise.
(type_is_emitted): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-12-06 Dodji Seketeli <dodji@redhat.com>
reader: Build array types with their element type "a priori"
* src/abg-ir.cc (var_decl::get_pretty_representation): Assert that
array element types are not empty.
* src/abg-reader.cc (build_array_type_def): Set array element
types a priori.
2021-12-02 Dodji Seketeli <dodji@redhat.com>
suppression: Fix has_data_member_inserted_between = {offset_of(), offset_of()}
* doc/manuals/libabigail-concepts.rst: Update the documentation to
reflect that has_data_member* properties will never suppress any
type change if the change carries a data member suppression or a
type size reduction.
* include/abg-fwd.h (get_last_data_member)
(get_next_data_member_offset): Declare new functions.
* include/abg-suppression.h
(insertion_range::boundary_value_is_end): Declare new static
member function.
(type_supression::insertion_range::eval_boundary): Make this
static function take an uint64_t rather than ssize_t.
(type_suppression::insertion_range::integer_boundary::{integer_boundary,
as_integer, operator int}): Make these member functions and
operator take or return uint64_t rather than int.
* src/abg-ir.cc (get_last_data_member)
(get_next_data_member_offset): Define new functions.
* src/abg-suppression.cc
(type_suppression::suppresses_diff): Rework logic to better handle
"has_data_member_inserted_*" properties in the context of class
diffs. If the diff object carries data member removal or size
reduction, the diff object is not suppressed by the current type
suppression. Also, the property "has_data_member_inserted_at =
end", is now represented by an insertion range where the beginning
and the end of the range are both the max possible value of
insertion range boundaries; the code is made to recognize that.
(type_suppression::insertion_range::eval_boundary): Make this
static function take an uint64_t rather than ssize_t. If the
boundary is expressed as a "offset_after" expression, make sure
the offset of the next data member is considered if it's present.
(type_suppression::insertion_range::integer_boundary::{integer_boundary,
as_integer, operator int}): Make these take or return uint64_t
rather than int.
(type_suppression::insertion_range::boundary_value_is_end): Define
new member function.
(type_suppression::insertion_range::integer_boundary::priv::value_):
Turn the type of this into uint64_t, from int.
(type_suppression::insertion_range::integer_boundary::priv::priv):
The parameter of this is now uint64_t, from int.
* tests/data/test-diff-suppr/PR28073/PR28073-bitfield-removed.c:
New test source code.
* tests/data/test-diff-suppr/PR28073/PR28073-bitfield-removed.o:
New test binary.
* tests/data/test-diff-suppr/PR28073/PR28073-bitfield-removed.o.abi:
New test input.
* tests/data/test-diff-suppr/PR28073/PR28073-output-{1,2}.txt: New
test reference output.
* tests/data/test-diff-suppr/PR28073/PR28073.after.o: New test
binary.
* tests/data/test-diff-suppr/PR28073/PR28073.after.o.abi: New test
input.
* tests/data/test-diff-suppr/PR28073/PR28073.before.o: New test
binary.
* tests/data/test-diff-suppr/PR28073/PR28073.before.o.abi: New
test input.
* tests/data/test-diff-suppr/PR28073/PR28073.c: New test source
code.
* tests/data/test-diff-suppr/PR28073/bitfield.suppr: New test
input.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-suppr.cc: Add the new test input to this test
harness.
2021-11-24 Matthias Maennich <maennich@google.com>
XML writer: adjust tracking of emitted declarations
* abg-writer.cc (write_context): Replace mutable
m_emitted_decls_map with plain m_emitted_decls_set.
(decl_name_is_emitted): Inlined into decl_is_emitted; dropped.
(decl_is_emitted): Turn the is_type check into an assert and
inline decl_name_is_emitted. Look up in set instead of map.
(record_decl_as_emitted): Make non-const. Insert into set
instead of map.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-11-22 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Fix memory leak reported by valgrind
* src/abg-ctf-reader.cc (process_ctf_archive): Add
ctf_dict_close
2021-11-18 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Use ABG_ASSERT instead of assert
* tools/abidiff.cc (main): Use ABG_ASSERT instead of assert.
* tools/abilint.cc: Likewise.
2021-11-18 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Make create_read_context return a smart pointer.
* include/abg-ctf-reader.h (read_context_sptr): New typedef.
(create_read_context): Use read_context_sptr as return value.
(read_corpus): New overload that takes a read_context_sptr.
* src/abg-ctf-reader.cc (create_read_context): Use
read_context_sptr as return value.
(read_corpus): New overload that takes a read_context_sptr.
* tools/abidiff.cc (main): Use read_context_sptr.
* tools/abidw.cc (load_corpus_and_write_abixml): Adjust call to
create_read_context.
* tools/abilint.cc: Likewise.
2021-11-22 Dodji Seketeli <dodji@redhat.com>
ctf-reader: Remove useless parameter from fill_ctf_section
* src/abg-ctf-reader.cc (fill_ctf_section): Remove the now useless
context parameter. Adjust the comment accordingly.
(slurp_elf_info): Adjust the invocation of fill_ctf_section.
2021-11-17 Guillermo E. Martinez via Libabigail <libabigail@sourceware.org>
ctf-reader: Use argument by reference reading the context
* include/abg-ctf-reader.h (create_read_context): Pass the string
by reference.
* src/abg-ctf-reader.cc (ctf_reader::read_context): Likewise.
(create_read_context): Likewise.
2021-11-17 Jose E. Marchesi via Libabigail <libabigail@sourceware.org>
abidw: add support for CTF
* tools/abidw.cc: Conditionally include abg-ctf-reader.h.
(load_corpus_and_write_abixml): Do not get a
dwarf_reader::read_context as an argument.
(main): Adjust call to load_corpus_and_write_abixml accordingly.
(struct options): New option use_ctf.
(options): ... and initialize it.
(display_usage): Document --ctf.
(parse_command_line): Handle --ctf.
* doc/manuals/abidw.rst: Document --ctf.
2021-11-16 Jose E. Marchesi via Libabigail <libabigail@sourceware.org>
ctf: ctf_reader::read_corpus now sets a status
* include/abg-ctf-reader.h: Include abg-elf-reader-common.h.
read_corpus now gets an extra argument `status'.
* src/abg-ctf-reader.cc (read_corpus): Likewise, and set `status'
accordingly when the debug info is not found.
* tools/abilint.cc (main): Pass a status argument to
ctf_reader::read_corpus.
* tools/abidiff.cc (main): Likewise.
2021-11-11 tangmeng <tangmeng@uniontech.com>
Standardize and improve the output of several tests
* tests/test-abidiff-exit.cc (main): Use
abigail::tests::emit_test_{summary, status_and_update_counters}
functions to ameliorate and standardize test output.
* tests/test-alt-dwarf-file.cc (main): Likewise.
* tests/test-annotate.cc (main): Likewise.
* tests/test-diff-dwarf-abixml.cc (main): Likewise.
* tests/test-ini.cc (main): Likewise.
* tests/test-lookup-syms.cc (main): Likewise.
2021-11-17 Dodji Seketeli <dodji@redhat.com>
test-utils: Define test status reporting functions
* tests/test-utils.h (emit_test_status_and_update_counters)
(emit_test_summary): Declare ...
* tests/test-utils.cc (emit_test_status_and_update_counters)
(emit_test_summary): ... new functions.
2021-11-17 Dodji Seketeli <dodji@redhat.com>
test-utils: Define colors for test status messages
* tests/test-utils.h (TEST_FAILURE_COLOR, TEST_SUCCESS_COLOR):
Define macros.
2021-11-15 Dodji Seketeli <dodji@redhat.com>
Bug 28584 - Don't drop global variables that lack DW_AT_external
* src/abg-dwarf-reader.cc (die_is_effectively_public_decl): Define
new static function.
(die_flag_attribute, die_is_public_decl): Adjust const-ness.
(build_ir_node_from_die): When building an IR for a variable,
consider the variable as being external if the variable is at
namespace scope, even if its DIE doesn't have the DW_AT_external
attribute.
* tests/data/test-read-dwarf/PR28584/PR28584-smv.cc: New source
code for a new clang-built binary.
* tests/data/test-read-dwarf/PR28584/PR28584-smv.clang.o: New
clang-built input binary for testing purposes.
* tests/data/test-read-dwarf/PR28584/PR28584-smv.clang.o.abi: The
reference output abixml.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the new test input
to this test harness.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
2021-11-12 Jose E. Marchesi via Libabigail <libabigail@sourceware.org>
Move dwarf_reader::status facilities to an abigail::elf_reader namespace
* include/abg-reader-common.h: New file.
* include/abg-dwarf-reader.h (enum status): Move to
abg-reader-status.h.
(status_to_diagnostic_string): Likewise.
(operator|): Likewise.
(operator&): Likewise.
(operator|=): Likewise.
(operator&=): Likewise.
Include abg-reader-common.h.
* include/Makefile.am (pkginclude_HEADERS): Add
abg-elf-reader-common.h.
* src/abg-elf-reader-status.cc: New file.
* src/abg-dwarf-reader.cc (operator|): Move to
abg-elf-reader-common.cc.
(operator&): Likewise.
(operator|): Likewise.
(operator|=): Likewise.
(operator&=): Likewise.
(status_to_diagnostic_string): Likewise.
* src/Makefile.am (libabigail_la_SOURCES): Add
elf-reader-common.cc.
* src/abg-tools-utils.cc: Use abigail::elf_reader instead of
abigail::dwarf_reader for the status definitions.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-symtab.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
2021-11-12 Dodji Seketeli <dodji@redhat.com>
abg-config.{cc,h}: Misc comment cleanups
* include/abg-config.h (abigail_get_library_version): Remove the
comment from the header file ...
* src/abg-config.cc (abigail_get_library_version): ... to put it
in the definition.
2021-11-12 Dodji Seketeli <dodji@redhat.com>
abidw: Add --abixml-version
* doc/manuals/abidw.rst: Document the --abixml-version command
line option.
* configure.ac (ABIXML_VERSION_MAJOR, ABIXML_VERSION_MINOR):
Define these two new autoconf variables.
* include/abg-config.h (abigail_get_abixml_version): Declare new
function.
* include/abg-tools-utils.h (get_abixml_version_string): Declare
new function.
* include/abg-version.h.in (ABIGAIL_ABIXML_VERSION_MAJOR)
(ABIGAIL_ABIXML_VERSION_MINOR): Define new preprocessor macros.
* src/abg-config.cc (config::config): Initialize
config::m_format_{minor,major} using the newly defined
preprocessor macros ABIGAIL_ABIXML_VERSION_M{IN,AJ}OR.
* src/abg-tools-utils.cc (get_abixml_version_string): Define new
function.
* tools/abidw.cc (options::display_abixml_version): Define new
data member.
(options::options): Initialize it.
(display_usage): Emit a help string for the new --abixml-version
option.
(parse_command_line): Parse the --abixml-version string.
(main): Emit the abixml version when asked.
2021-11-04 Dodji Seketeli <dodji@redhat.com>
Bug 28450 - Fix cloned member function handling in DWARF
* ABIXML-FORMAT-VERSIONS: New file that documents the version
changes of the ABIXML-FORMAT-VERSIONS.
* include/abg-fwd.h (look_through_no_op_qualified_type): Remove
this function declaration.
(strip_useless_const_qualification): Declare new function
declaration.
* src/abg-comparison.cc (compute_diff_for_types): Avoid stripping
off no-op-qualified types as these beasts don't exist anymore.
(redundancy_marking_visitor::visit_end): Allow a variable which
type has local changes to be considered redundant if its type is
itself redundant.
* src/abg-config.cc (config::config): Bump the abixml version from
2.0 to 2.1.
* src/abg-dwarf-reader.cc (maybe_strip_qualification): Factorize
out the new strip_useless_const_qualification function from here.
(build_or_get_fn_decl_if_not_suppressed): If the function is
created but doesn't have an ELF symbol associated to it, then
update it so that the ELF symbol can be associated. Otherwise,
potential_member_fn_should_be_dropped might later drop that
function on the floor because it doesn't have any ELF symbol
associated.
* src/abg-ir.cc (strip_useless_const_qualification): Define this,
which is has been factorized out of maybe_strip_qualification.
(look_through_no_op_qualified_type): Remove this definition.
(equals): In the overload for reference_type_def, do not peel
typedefs off from the reference before comparison. This is now
useless as the comparison infrastructure got a lot better. In the
overload for references, stop using
look_through_no_op_qualified_type as this function doesn't exist
anymore.
* src/abg-tools-utils.cc (abidiff_status_has_error): Detect when
there is a usage error as well.
* tests/data/test-types-stability/PR28450-libepetra.so.13.0: Add
new testing binary to the repository.
* tests/data/Makefile.am: Add the new testing binary above to
source distribution.
* tests/test-types-stability.cc (elf_paths): Add the new test to
this test harness.
* tests/test-diff-dwarf-abixml.cc (main): Add better error messages.
* tests/data/test-abidiff-exit/test-member-size-report0.txt: Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi: Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-10.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-12.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-14.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-16.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test31-report-1.txt: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test-crc.xml: Likewise.
* tests/data/test-read-write/test26.xml: Likewise.
* tests/data/test-read-write/test27.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml: Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml: Likewise.
2021-11-10 Jose E. Marchesi via Libabigail <libabigail@sourceware.org>
abg-ctf-reader: use the right string table for CTF data
* src/abg-ctf-reader.cc (slurp_elf_info): Use
find_strtab_for_symtab_section.
2021-11-10 Jose E. Marchesi via Libabigail <libabigail@sourceware.org>
elf_helpers: new utility function find_strtab_for_symtab_section
* src/abg-elf-helpers.h: Prototype for find_strtab_for_symtab_section.
* src/abg-elf-helpers.cc (find_strtab_for_symtab_section): New function.
2021-11-09 tangmeng <tangmeng@uniontech.com>
test-abicompat: Make the test output more pleasant
* test/test-abicompat.cc (main): make test output more pleasant.
2021-11-05 tangmeng <tangmeng@uniontech.com>
abicompat: Add prompt message for abnormal operation
* tools/abicompat.cc (parse_command_line): Notify the user
when --redundant and --no-redundant are used at the same time
2021-11-05 tangmeng <tangmeng@uniontech.com>
abilint: Add prompt message for abnormal operation
* tools/abilint.cc (parse_command_line): Notify the user when the
path to the file is ignored because the --stdin option was
provided.
2021-11-03 Jose E. Marchesi via Libabigail <libabigail@sourceware.org>
ctf: make libabigail::ctf_reader::read_corpus reentrant
* src/abg-ctf-reader.cc (class read_context): New attributes
elf_handler, elf_fd, ctf_sect, symtab_sec and strtab_sect.
(read_context): Do not read the CTF archive here.
(slurp_elf_info): Adjust to use attributes instead of locals, and
fetch the raw ELF section contents for libctf.
(close_elf_handler): New function.
(fill_ctf_section): Likewise.
(read_corpus): Call open_elf_handler, close_elf_handler and build
the CTF archive using ctf_arc_bufopen instead of ctf_open.
Signed-by: Jose E. Marchesi <jose.marchesi@oracle.com>
2021-11-03 tangmeng <tangmeng@uniontech.com>
Fix trivial typo when printing message
* tools/abilint.cc (main): End the 'FILE_TYPE_UNKNOWN' tips with a
newline.
* tools/abisym.cc (main): Add a newline after version string.
2021-10-29 Jose E. Marchesi via Libabigail <libabigail@sourceware.org>
Add support for the CTF debug format to libabigail.
* configure.ac: Check for libctf.
* src/abg-ctf-reader.cc: New file.
* include/abg-ctf-reader.h: Likewise.
* src/Makefile.am (libabigail_la_SOURCES): Add abg-ctf-reader.cc
conditionally.
* include/Makefile.am (pkginclude_HEADERS): Add abg-ctf-reader.h
conditionally.
* tools/abilint.cc (struct options): New option `use_ctf'.
(display_usage): Documentation for --ctf.
(parse_command_line): Handle --ctf.
(main): Honour --ctf.
* tools/abidiff.cc (struct options): New option `use_ctf'.
(display_usage): Documentation for --ctf.
(parse_command_line): Handle --ctf.
(main): Honour --ctf.
* doc/manuals/abidiff.rst: Document --ctf.
* doc/manuals/abilint.rst: Likewise.
2021-10-29 tangmeng <tangmeng@uniontech.com>
abicompat: Add prompt message for abnormal operation
* tools/abicompat.cc (main): Notify the user when the path to
the second library is ignored because the --weak-mode option
was provided. Also, fix comment.
2021-10-29 tangmeng <tangmeng@uniontech.com>
abilint: fix trivial typo when using abilint
* tools/abilint.cc (display_usage): Correct the errors and
redundant content in the help information.
(main): Add a newline after version string.
2021-10-27 tangmeng <tangmeng@uniontech.com>
Fix trivial typo when printing help information
* tools/abicompat.cc (display_usage): End the usage message with a
newline and properly indent it.
2021-10-20 Dodji Seketeli <dodji@redhat.com>
PR28365 - Assert on empty typedef on webkit2gtk3-jsc-2.32.3-1.fc34.x86_64
* src/abg-reader.cc (build_enum_type_decl): Set the naming typedef
only after the enum is created and keyed.
(build_typedef_decl): Build the underlying type of the typedef
first.
2021-10-11 Giuliano Procida <gprocida@google.com>
Tweak clang-format configuration
* .clang-format: Various tweaks to Clang format configuration.
2021-10-15 Vanessa Sochat <sochat1@llnl.gov>
Fixing incorrect symbol
* include/abg-ir.h (translation_unit::language<>LANG_PLI): Rename
LANG_PL1 into this.
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language): Rename
DW_LANG_PL1 into DW_LANG_PLI.
(get_default_array_lower_bound): Rename translation_unit::LANG_PL1
into translation_unit::LANG_PLI.
* src/abg-ir.cc (translation_unit_language_to_string): Rename
translation_unit::LANG_PL1 into case translation_unit::LANG_PLI.
(string_to_translation_unit_language): Rename
translation_unit::LANG_PL1 into translation_unit::LANG_PLI.
2021-10-18 Dodji Seketeli <dodji@redhat.com>
Update licensing information on the web page after 2.0
* doc/website/mainpage.txt: Libabigail is now Apache V2 + LLVM
exception.
2021-10-18 Dodji Seketeli <dodji@redhat.com>
Add debug info package for wireshark-cli-3.4.9-1.fc36.x86_64.rpm
* tests/data/test-diff-pkg/wireshark/wireshark-debuginfo-3.4.9-1.fc36.x86_64.rpm:
Add new debug info package.
* tests/data/Makefile.am: Add it to the source distribution.
* tests/test-diff-pkg.cc: Use the new debug info package in the
test harness.
2021-10-14 Dodji Seketeli <dodji@redhat.com>
Bug 28364 - libwiretap fails self comparison
* src/abg-dwarf-reader.cc (build_function_type): Associate the DIE
representation to the constructed type once it's fully built.
* src/abg-reader.cc (build_function_type): Support member function of unions.
* tests/data/Makefile.am: Add the new test input files to the
source distribution.
* tests/data/test-diff-pkg/wireshark/wireshark-cli-3.4.9-1.fc36.x86_64-self-check-report.txt:
Add new test input file.
* tests/data/test-diff-pkg/wireshark/wireshark-cli-3.4.9-1.fc36.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/wireshark/wireshark-cli-debuginfo-3.4.9-1.fc36.x86_64.rpm:
Likewise.
* tests/test-diff-pkg.cc (in_out_specs): Add these new test input
files to this test harness.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Adjust.
2021-10-14 Dodji Seketeli <dodji@redhat.com>
writer: Don't forget that a naming typedef is referenced
* src/abg-writer.cc (write_naming_typedef): Notice that the naming
typedef is referenced.
2021-10-14 Dodji Seketeli <dodji@redhat.com>
writer: Don't forget when emitting array subrange types
* src/abg-writer.cc (write_array_subrange_type): Record the type
as emitted.
2021-10-14 Dodji Seketeli <dodji@redhat.com>
writer: Don't forget to emit types referenced by function types
* src/abg-writer.cc (write_referenced_types): Factorize out of ...
(write_translation_unit): ... here. Also, use it to write the
types referenced by emitted function types.
2021-10-14 Dodji Seketeli <dodji@redhat.com>
ir: Avoid canonicalizing types that are not meant to
* src/abg-ir.cc (type_base::get_canonical_type_for): Do not
canonicalize types that are not meant to.
(maybe_adjust_canonical_type): Do not crash when dealing with a
nil canonical type.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi: Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2021-10-14 Dodji Seketeli <dodji@redhat.com>
tests/Makefile.am: Fix warning
* tests/Makefile.am: Stop referring to test-dot.cc which is no
more.
2021-10-14 Dodji Seketeli <dodji@redhat.com>
Add --enable-debug-type-canonicalization to configure
* configure.ac: Support the new
--enable-debug-type-canonicalization option. Define macro
WITH_DEBUG_TYPE_CANONICALIZATION accordingly.
* doc/manuals/abidw.rst: Update documentation.
* include/abg-ir.h
(environment::debug_type_canonicalization_is_on): Declare new
member function if WITH_DEBUG_TYPE_CANONICALIZATION is defined.
* src/abg-ir-priv.h
(environment::priv::{use_canonical_type_comparison_,
debug_type_canonicalization_}): Define new data members if
WITH_DEBUG_TYPE_CANONICALIZATION is defined.
(environment::priv::priv): Initialize them.
* src/abg-ir.cc (try_canonical_compare): When
WITH_DEBUG_TYPE_CANONICALIZATION is defined, perform comparison
using either structural or canonical equality depending on the
environment::priv::use_canonical_type_comparison_ flag.
(environment::debug_type_canonicalization_is_on): Define member
function when WITH_DEBUG_TYPE_CANONICALIZATION is defined.
(compare_types_during_canonicalization): Define new function.
(type_base::get_canonical_type_for): Use the new function
compare_types_during_canonicalization.
* tools/abidw.cc (options::debug_type_canonicalization): Define
new data member.
(option::option): Initialize it.
(display_usage): Add help string for --debug-tc.
(parse_command_line): Support new option --debug-tc or
--debug-type-canonicalization.
(load_corpus_and_write_abixml): Turn type canonicalization
debugging on if --enable-tc is provided.
2021-10-13 Dodji Seketeli <dodji@redhat.com>
Improve type (de)serialization instability debugging
* include/abg-fwd.h (is_non_canonicalized_type): Declare new
function.
* src/abg-ir-priv.h: Include abg-corpus.h
(environment::priv::pointer_type_id_map_): Fix comment.
(environment::priv::check_canonical_type_from_abixml_during_self_comp):
Define new member function.
* src/abg-ir.cc (unmark_types_as_being_compared): Factorize this
from ...
(return_comparison_result): ... here. Also, add a parameter to
control whether this function should perform the "canonical type
propagation optimization" or not. By default the optimization is
performed. This can be changed for debugging purposes later.
(type_base::get_canonical_type_for): Re-organise the self
comparison debugging process to invoke the new function
environment::priv::check_canonical_type_from_abixml_during_self_comp
each time a canonical type is computed, in addition to doing the
previous verification that was done when no canonical type was
found. Emit better error messages.
(is_non_canonicalized_type): Rename the static function
is_allowed_non_canonicalized_type into this and make it
non-static.
(hash_as_canonical_type_or_constant): Adjust.
* src/abg-reader.cc (maybe_map_type_with_type_id): Define new
static function.
(read_context::maybe_check_abixml_canonical_type_stability):
Ignore types that were not canonicalized.
(read_corpus_from_input): Set the origin of the corpus early
enough so that it's available to the canonicalizer even for types
being canonicalized early.
(MAYBE_MAP_TYPE_WITH_TYPE_ID): Factorize this macro out of ...
(build_type): ... this. That macro is defined only when debugging
self comparison.
(build_array_type_def): Map the read subrange type with its
type-id.
(handle_{type_decl, qualified_type, pointer_type_def,
reference_type_def, function_type, array_type_def,enum_type_decl,
typedef_decl, class_decl, union_decl}): Map the read type with its
type-id.
(load_canonical_type_ids): Ignore non-canonicalized types that
which ids were saved in the type-id file.
* src/abg-writer.cc (write_type_record): Factorize from ...
(write_canonical_type_ids): ... here. Don't forget to write the
type-ids of decl-only types. This can be useful for eye
inspection.
* tools/abidw.cc (load_corpus_and_write_abixml): Wait until the
end of the function before removing the type-id file. This can be
useful for eye inspection.
2021-10-05 Dodji Seketeli <dodji@redhat.com>
Bump to 2.1 version
* configure.ac: Bump to 2.1 version.
2021-10-04 Dodji Seketeli <dodji@redhat.com>
Update libabigail web page for 2.0 release
* doc/website/mainpage.txt: Update.
2021-10-04 Dodji Seketeli <dodji@redhat.com>
Fix tarball upload directory
* Makefile.am: The tarball upload director is really /var/ftp.
2021-10-04 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 2.0
* ChangeLog: Update automatically with make update-changelog.
2021-10-04 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 2.0
* NEWS: Update for 2.0
2021-09-23 Dodji Seketeli <dodji@redhat.com>
Bug 27086 - Consider all C++ virtual destructors when there are many
* src/abg-dwarf-reader.c (build_or_get_fn_decl_if_not_suppressed):
Do not try to re-use a virtual destructor of a class, based on its
signature. Several different of these can have the same
signature, inside a given class.
* tests/data/test-types-stability/PR27086-libstdc++.so.6.0.26:
Add new binary test input.
* tests/data/Makefile.am: Add the new test input to source
distribution.
* tests/test-types-stability.cc (elf_paths): Add the test input
above to this harness.
2021-09-23 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Indent
* src/abg-dwarf-reader.cc (finish_member_function_reading): Fix
indentation.
2021-09-22 Dodji Seketeli <dodji@redhat.com>
Bug 27970 - Duplicated member functions cause spurious self comparison changes
* src/abg-dwarf-reader.cc (fixup_functions_with_no_symbols): When
the function decl is finally associated to its (publicly defined)
ELF symbol, mark it as being exported.
(finish_member_function_reading): Don't risk marking a virtual
function as being non-virtual when updating its properties.
(build_or_get_fn_decl_if_not_suppressed): Update comment. If the
member function is already present in the class, do not create a
new one; rather, reuse the existing one. It's going to be later
updated by finish_member_function_reading.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
2021-09-21 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Do not erase working dirs before we are done using them
* tools/abipkgdiff.cc (compare_prepared_userspace_packages):
Removing working directories "early" prevents e.g,
dwarf_reader::get_soname_of_elf_file from accessing those files.
So do not remove them until the very end.
* tests/data/test-diff-pkg/libxcrypt-4.1.1-6.el8.x86_64--libxcrypt-4.1.1-6.el8.x86_64-output-1.txt:
Adjust.
2021-09-14 Dodji Seketeli <dodji@redhat.com>
Bug 28316 - Failure to represent typedef named anonymous enums
* include/abg-fwd.h (scope_anonymous_or_typedef_named)
(is_anonymous_or_typedef_named): Declare new functions.
* include/abg-ir.h (decl_base::set_has_anonymous_parent): Remove
declaration.
(decl_base::{get,set}_naming_typedef): Declare new member
functions.
* src/abg-ir.cc (update_qualified_name): Define static function.
(decl_base::priv::naming_typedef_): Define new data member.
(decl_base::priv::has_anonymous_parent_): Remove data member.
(decl_base::priv::priv): Adjust constructor.
(decl_base::get_has_anonymous_parent): Rather than storing a flag
for this, dynamically look at if the scope is anonymous.
(decl_base::set_has_anonymous_parent): Remove definition.
(decl_base::{get,set}_naming_typedef): Define new member
functions.
(scope_anonymous_or_typedef_named)
(is_anonymous_or_typedef_named): Define new functions.
(get_decl_name_for_comparison): Define new sub-routine for the
decl_base overload of equals.
(equals): In the overload for decl_base, use the new
get_decl_name_for_comparison. It helps to ensure that all
anonymous decls of the same kind have the same name for the
purpose of comparison. It also ensures that non anonymous decls
that are part of anonymous scopes should be compared only by
looking at their non-qualified names. In the overload for
class_or_union, adjust.
(scope_decl::add_member_decl): No more need to flag the fast that
the parent scope is anonymous here.
(get_debug_representation): Fix a thinko.
(class_or_union::get_naming_typedef): Remove member function as
it's now handled by decl_base::get_naming_typedef.
* src/abg-dwarf-reader.cc (build_typedef_type): When a typedef is
a naming typedef, then mark the named decl as being typedef-named.
(maybe_canonicalize_type): Delay canonicalization of anonymous
types because they can be typedef-named later.
* src/abg-reader.cc (read_naming_typedef_id_string)
(maybe_set_naming_typedef): Define new static function.
(build_class_decl): Use it here, rather than reading the
"naming-typedef-id" by hand.
(build_enum_type_decl, build_union_decl): Read the
"naming-typedef-id" property.
* src/abg-writer.cc (write_naming_typedef): Make this accept
decl_base_sptr, rather than just class_decl_sptr.
(write_enum_type_decl): Write the naming-typedef-id property if
needed.
* tests/data/test-abidiff-exit/test-PR28316-report.txt: New test
reference output.
* tests/data/test-abidiff-exit/test-PR28316-v{0,1}.cc: Source code
of new binary test input.
* tests/data/test-abidiff-exit/test-PR28316-v{0,1}.o: New binary
test input files.
* tests/data/Makefile.am: Add the new test files to the source
distribution.
* tests/test-abidiff-exit.cc: Add the new test files above to this
harness.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/test15-enum-report.txt: Likewise.
* tests/data/test-diff-filter/test19-enum-report-1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: Likewise.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2021-09-17 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Fix showing added/removed files
* tools/abipkgdiff.cc (compare_prepared_userspace_packages): Do
not return early if there are no binaries to compare. Also add
more verbose messages.
* tests/data/test-diff-pkg/libxcrypt-4.1.1-6.el8.x86_64--libxcrypt-4.1.1-6.el8.x86_64-output-1.txt:
New reference output file.
* tests/data/test-diff-pkg/libxcrypt-4.1.1-6.el8.x86_64--libxcrypt-compat-4.4.18-3.el9.x86_64-report-1.txt:
New reference output file.
* tests/data/test-diff-pkg/libxcrypt-4.1.1-6.el8.x86_64.rpm: New
binary input file.
* tests/data/test-diff-pkg/libxcrypt-4.4.18-3.el9.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/libxcrypt-compat-4.4.18-3.el9.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/libxcrypt-compat-debuginfo-4.4.18-3.el9.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/libxcrypt-debuginfo-4.1.1-6.el8.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/libxcrypt-debuginfo-4.4.18-3.el9.x86_64.rpm: Likewise.
* tests/data/Makefile.am: Add the new testing files to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add these binary packages
to this testing harness.
2021-09-09 Dodji Seketeli <dodji@redhat.com>
RHBZ1944102 - self comparing ABI of protobuf-3.14.0-2.el9 failed
* src/abg-reader.cc (read_size_and_alignment): Use atoll to read
long long values, not atoi.
2021-09-08 Dodji Seketeli <dodji@redhat.com>
RHBZ1951496 - ir: Acknowledge that "void type" is not canonicalized
* src/abg-ir.cc (is_allowed_non_canonicalized_type): Define new
static function.
(hash_as_canonical_type_or_constant): Use it.
2021-09-08 Dodji Seketeli <dodji@redhat.com>
writer: Avoid sigsev on types with no translation unit
* src/abg-writer.cc (referenced_type_should_be_emitted): Don't
crash on types with no associated translation unit.
2021-09-08 Dodji Seketeli <dodji@redhat.com>
xml-reader: Get back to original way of building qualified types
* src/abg-reader.cc (build_qualified_type_decl): Create the
underlying type first, then create the qualified type.
This helps fix bug
2021-09-08 Dodji Seketeli <dodji@redhat.com>
ir: Fix canonical type propagation cancelling
* src/abg-ir.cc (return_comparison_result): When the comparison of
the current type sub-object fails, clear the potentially
propagated canonical type and remove it from the set of types with
non confirmed propagated canonical types.
2021-09-08 Dodji Seketeli <dodji@redhat.com>
ir: Avoid infinite loop during type canonicalization
* src/abg-ir-priv.h
(environment::priv::collect_types_that_depends_on): Don't try to
collect a type that has already been collected.
2021-09-07 Dodji Seketeli <dodji@redhat.com>
writer: escape enum linkage name in abixml
* src/abg-writer.cc (write_enum_type_decl): Escape linkage name.
2021-09-07 Dodji Seketeli <dodji@redhat.com>
RHBZ-1944096 - assertion failure during self comparison of systemd
* src/abg-reader.cc (build_enum_type_decl): When strtoll detects
an underflow or overflo, it sets errno to ERANGE. So take that
into account.
2021-09-03 Dodji Seketeli <dodji@redhat.com>
Bug 27985 - abidiff: bad array types in report
* src/abg-ir.cc (array_type_def::get_qualified_name): Use the
cache for temporary qualified names when the type is not yet
canonicalized. That way, the cache for (non-temporary) qualified
names is used only for canonicalized types.
* tests/data/test-abidiff/test-PR27985-report.txt: Reference
output for the new test.
* tests/data/test-abidiff/test-PR27985-v{0,1}.c: Source code for
the new test binary inputs.
* tests/data/test-abidiff/test-PR27985-v{0,1}.o: New test binary inputs.
* tests/data/test-abidiff/test-PR27985-v{0,1}.o.abi: New test
abixml input.
* tests/data/Makefile.am: Add the new test materials above to
source distribution.
* tests/test-abidiff.cc (specs): Add the tests above to the harness.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Adjust.
2021-08-27 Giuliano Procida <gprocida@google.com>
abg-writer: faster referenced type emission tests
* src/abg-writer.cc (write_translation_unit): Reorder
referenced type emission tests for efficiency. Consolidate
related comments.
Reviewed-by: Matthias Maennich <maennich@google.com>
2021-08-10 Dodji Seketeli <dodji@redhat.com>
RHBZ 1925886 - Compare anonymous types without qualified names
* include/abg-fwd.h (is_anonymous_type): Constify this function.
* src/abg-ir.cc (equals): In the overload for decl_base, do not
take scope of anonymous types into account. In the overload for
array_type_def do not peel of typedefs. This is not directly
related to anonymous types, but it make comparison more robust
against naming typedefs used for anonymous types in array
elements.
(get_type_name): Do not take into account the scope of anonymous
types when building internal representation of types. Note that
the internal representation is what is used for canonicalization.
This means that all anonymous types are compared against each
others during type canonicalization.
* src/abg-reader.cc (build_class_decl): Do not try to re-use
anonymous types, just like we already do for DWARF.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2021-07-29 Dodji Seketeli <dodji@redhat.com>
Bug 27236 - Don't forget to emit some referenced types
* include/abg-writer.h (write_translation_unit): Add a new
parameter that says if we are emitting the last TU.
* src/abg-writer.cc (write_translation_unit::{type_is_emitted,
decl_only_type_is_emitted}): Constify these methods.
(write_context::has_non_emitted_referenced_types): Define new
member function using the const methods above.
(write_translation_unit): When emitting the last TU, emit all the
referenced types.
(write_corpus): Set signal when emitting the last translation
unit.
2021-07-29 Dodji Seketeli <dodji@redhat.com>
Bug 27236 - Allow updating classes from abixml
* src/abg-reader.cc (build_class_decl): Keep going when the class
has already been built. The rest of the code knows how to add new
stuff.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
2021-07-29 Dodji Seketeli <dodji@redhat.com>
Bug 27236 - Fix the canonical type propagation optimization
* include/abg-ir.h (pointer_set): This typedef is now for an
unordered_set<uintptr_t> rather than an unordered_set<size_t>.
(environment::priv_): Make this public so that code in free form
function from abg-ir.cc can access it.
* src/abg-ir-priv.h (struct type_base::priv): Move this private
structure here, from abg-ir.cc.
(type_base::priv::{depends_on_recursive_type_,
canonical_type_propagated_}): Added these two new data members.
(type_base::priv::priv): Initialize the two new data members.
(type_base::priv::{depends_on_recursive_type,
set_depends_on_recursive_type,
set_does_not_depend_on_recursive_type, canonical_type_propagated,
set_canonical_type_propagated, clear_propagated_canonical_type}):
Define new member functions.
(struct environment::priv): Move this struct here, from abg-ir.cc.
(environment::priv::{types_with_non_confirmed_propagated_ct_,
left_type_comp_operands_, right_type_comp_operands_}): New data
members.
(environment::priv::{mark_dependant_types,
mark_dependant_types_compared_until, confirm_ct_propagation,
collect_types_that_depends_on, cancel_ct_propagation,
remove_from_types_with_non_confirmed_propagated_ct}): New member
functions.
* src/abg-ir.cc (struct environment::priv, struct)
(type_base::priv, struct class_or_union::priv): Move these struct
to include/abg-ir-priv.h.
(push_composite_type_comparison_operands)
(pop_composite_type_comparison_operands)
(mark_dependant_types_compared_until)
(maybe_cancel_propagated_canonical_type): Define new functions.
(notify_equality_failed, mark_types_as_being_compared): Re-indent.
(is_comparison_cycle_detected, return_comparison_result): Define
new function templates.
(RETURN_TRUE_IF_COMPARISON_CYCLE_DETECTED): Define new macro.
(equals(const function_type& l, const function_type& r)): Redefine
the RETURN macro using the new return_comparison_result function
template. Use the new RETURN_TRUE_IF_COMPARISON_CYCLE_DETECTED
and mark_types_as_being_compared functions.
(equals(const class_or_union& l, const class_or_union&, change_kind*)):
Likewise.
(equals(const class_decl& l, const class_decl&, change_kind*)):
Likewise. Because this uses another equal() function to compare
the class_or_union part the type, ensure that no canonical type
propagation occurs at that point.
(types_are_being_compared): Remove as it's not used anymore.
(maybe_propagate_canonical_type): Use the new
environment::priv::propagate_ct() function here.
(method_matches_at_least_one_in_vector): Ensure the
right-hand-side operand of the equality stays on the right. This
is important because the equals() functions expect that.
* src/abg-reader.cc (build_type): Ensure all types are
canonicalized.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Adjust.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: Likewise.
2021-06-30 Dodji Seketeli <dodji@redhat.com>
Bug 27995 - Self comparison error from abixml file
* doc/manuals/abidiff.rst: Add documentation for the --debug
option.
* src/abg-ir.cc (equals): In the overload for decl_base consider
the internal version of qualified decl name. In the overload for
pointer_type_def do not peel typedefs off from the compared
pointed-to types. In the overload for typedef_decl compare the
typedef as a decl as well. In the overload for var_decl, compare
variables that have the same ELF symbols without taking into
account their qualified name, rather than their name. Stop
comparing data member without considering their names.
In the overload for class_or_union, when a decl-only class that is
ODR-relevant is compared against another type, assume that
equality if names are equal. This is useful in environments where
some TUs are ODR-relevant and others aren't.
(*::get_pretty_representation): Update doxygen comments.
(enum_type_decl::get_pretty_representation): Return an internal
pretty representation that is stable across all anonymous enums.
(var_decl::get_anon_dm_reliable_name): Use the non-internal pretty
representation for anonymous data members.
(function_type::priv::temp_internal_cached_name_): New data
member.
(function_type::get_cached_name): Cache the internal name after
the function type is canonicalized. Make sure internal name and
non-internal name are cached separately.
(class_or_union::find_anonymous_data_member): Look for the anonymous
data member by looking at its non-internal name.
({class, union}_decl::get_pretty_representation): Use something like "class
__anonymous_{union,struct}__" for all anonymous classes, so that they can
all be compared against each other during type canonicalization.
(type_has_sub_type_changes): Use non-internal pretty
representation.
(hash_type_or_decl, function_decl_is_less_than:): Use internal
pretty representation for comparison here.
* src/abg-reader.cc (read_context::maybe_canonicalize_type): Don't
early canonicalize array types.
* src/abg-writer.cc (annotate): Use non-internal pretty
representation.
* tests/data/test-diff-filter/test-PR27995-report-0.txt: New
reference report.
* tests/data/test-diff-filter/test-PR27995.abi: New test input
abixml file.
* tests/data/Makefile.am: Add test-PR27995.abi,
test-PR27995-report-0.txt to the source distribution.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-diff-dwarf/test6-report.txt: Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Adjust.
* tests/data/test-diff-filter/test41-report-0.txt: Adjust.
* tests/data/test-diff-filter/test43-decl-only-def-change-leaf-report-0.txt: Adjust.
* tests/data/test-diff-filter/test8-report.txt: Adjust.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
* tests/data/test-diff-suppr/test39-opaque-type-report-0.txt: Adjust.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/test-diff-filter.cc (in_out_specs): Add the
test-PR27995.abi to the test harness.
* tools/abidiff.cc (options::do_debug): New data member.
(options::options): Initialize it.
(parse_command_line): Parse --debug.
(main): Activate self comparison debug if the user provided
--debug.
2021-06-25 Dodji Seketeli <dodji@redhat.com>
ir: Tighten type comparison optimization for Linux kernel binaries
* src/abg-ir.cc (types_defined_same_linux_kernel_corpus_public):
Ensure that anonymous classes with naming typedefs have identical
typedef names.
2021-06-25 Dodji Seketeli <dodji@redhat.com>
ir: Tighten the test for anonymous data member
* src/abg-ir.cc: (is_anonymous_data_member): Consider
decl_base::get_is_anonymous as well.
2021-06-24 Dodji Seketeli <dodji@redhat.com>
ir: Improve the debugging facilities
* src/abg-ir.cc (maybe_compare_as_member_decls): Add a missing
ABG_RETURN
(get_debug_representation): Display the name of class and enums,
not their pretty representation.
2021-07-10 Giuliano Procida <gprocida@google.com>
PR28060 - Invalid offset for bitfields
* src/abg-dwarf-reader.cc (read_and_convert_DW_at_bit_offset):
Update documentation.
(die_member_offset): Treat DW_AT_bit_offset as an optional
adjustment to DW_AT_data_member_location.
* tests/data/test-annotate/test13-pr18894.so.abi: Update.
* tests/data/test-annotate/test15-pr18892.so.abi: Update.
* tests/data/test-annotate/test17-pr19027.so.abi: Update.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Update.
* tests/data/test-annotate/test21-pr19092.so.abi: Update.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Regenerate.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
Report now empty.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Update.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Update.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Update.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Update.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Update.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Update.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Update.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Update.
2021-07-07 Giuliano Procida <gprocida@google.com>
abg-ir.h: add declaration of operator<< for elf_symbol::visibility
* include/abg-ir.h (operator<<(elf_symbol::visibility): Add
declaration.
2021-07-06 Giuliano Procida <gprocida@google.com>
ir: remove "is Linux string constant" property from elf_symbol
* include/abg-ir.h (elf_symbol::elf_symbol): Drop
is_linux_string_cst argument.
(elf_symbol::create): Likewise.
(elf_symbol::get_is_linux_string_cst): Drop method.
* src/abg-dwarf-reader.cc (lookup_symbol_from_sysv_hash_tab):
Remove code that gets the index of the __ksymtab_strings
section. Drop corresponding elf_symbol::create argument.
(lookup_symbol_from_gnu_hash_tab): Likewise.
(lookup_symbol_from_symtab): Likewise.
(create_default_fn_sym): Drop false is_linux_string_cst
argument to elf_symbol::create.
* src/abg-ir.cc (elf_symbol::priv::is_linux_string_cst_): Drop
member variable.
(elf_symbol::priv default ctor): Drop initialisation of
is_linux_string_cst_.
(elf_symbol::priv normal ctor): Drop is_linux_string_cst
argument and corresponding is_linux_string_cst_
initialisation.
(elf_symbol::elf_symbol ctor): Drop is_linux_string_cst
argument and corresponding forwarding to priv ctor.
(elf_symbol::create): Drop is_linux_string_cst argument and
corresponding forwarding to ctor.
(elf_symbol::get_is_linux_string_cst): Drop method.
* src/abg-reader.cc (build_elf_symbol): Drop false
is_linux_string_cst argument to elf_symbol::create.
* src/abg-symtab-reader.cc (symtab::load): Likewise.
2021-07-05 Matthias Maennich <maennich@google.com>
Consistently use std::unique_ptr for private implementations (pimpl)
* include/abg-comparison.h (diff_maps): use unique_ptr for priv_
(diff_context): Likewise.
(diff_traversable_base): Likewise.
(type_diff_base): Likewise.
(decl_diff_base): Likewise.
(distinct_diff): Likewise.
(var_diff): Likewise.
(pointer_diff): Likewise.
(reference_diff): Likewise.
(array_diff): Likewise.
(qualified_type_diff): Likewise.
(enum_diff): Likewise.
(class_or_union_diff): Likewise.
(class_diff): Likewise.
(base_diff): Likewise.
(scope_diff): Likewise.
(fn_parm_diff): Likewise.
(function_type_diff): Likewise.
(function_decl_diff): Likewise.
(typedef_diff): Likewise.
(translation_unit_diff): Likewise.
(diff_stats): Likewise.
(diff_node_visitor): Likewise.
* include/abg-corpus.h (corpus): Likewise.
(exported_decls_builder): Likewise.
(corpus_group): Likewise.
* include/abg-ini.h (property): Likewise.
(property_value): Likewise.
(string_property_value): Likewise.
(list_property_value): Likewise.
(tuple_property_value): Likewise.
(simple_property): Likewise.
(list_property): Likewise.
(tuple_property): Likewise.
(config): Likewise.
(section): Likewise.
(function_call_expr): Likewise.
* include/abg-interned-str.h (interned_string_pool): Likewise.
* include/abg-ir.h (environment): Likewise.
(location_manager): Likewise.
(type_maps): Likewise.
(translation_unit): Likewise.
(elf_symbol::version): Likewise.
(type_or_decl_base): Likewise.
(scope_decl): Likewise.
(qualified_type_def): Likewise.
(pointer_type_def): Likewise.
(array_type_def): Likewise.
(subrange_type): Likewise.
(enum_type_decl): Likewise.
(enum_type_decl::enumerator): Likewise.
(typedef_decl): Likewise.
(dm_context_rel): Likewise.
(var_decl): Likewise.
(function_decl::parameter): Likewise.
(function_type): Likewise.
(method_type): Likewise.
(template_decl): Likewise.
(template_parameter): Likewise.
(type_tparameter): Likewise.
(non_type_tparameter): Likewise.
(template_tparameter): Likewise.
(type_composition): Likewise.
(function_tdecl): Likewise.
(class_tdecl): Likewise.
(class_decl::base_spec): Likewise.
(ir_node_visitor): Likewise.
* include/abg-suppression.h (suppression_base): Likewise.
(type_suppression::insertion_range): Likewise.
(type_suppression::insertion_range::boundary): Likewise.
(type_suppression::insertion_range::integer_boundary): Likewise.
(type_suppression::insertion_range::fn_call_expr_boundary): Likewise.
(function_suppression): Likewise.
(function_suppression::parameter_spec): Likewise.
(file_suppression): Likewise.
* include/abg-tools-utils.h (temp_file): Likewise.
(timer): Likewise.
* include/abg-traverse.h (traversable_base): Likewise.
* include/abg-workers.h (queue): Likewise.
* src/abg-comparison.cc (diff_context): add default destructor.
(diff_maps): Likewise.
(corpus_diff): Likewise.
(diff_node_visitor): Likewise.
(class_or_union_diff::get_priv): adjust return type.
(class_diff::get_priv): adjust return type.
* src/abg-corpus.cc (corpus): add default destructor.
* src/abg-ir.cc (location_manager): Likewise.
(type_maps): Likewise.
(elf_symbol::version): Likewise.
(array_type_def::subrange_type): Likewise.
(enum_type_decl::enumerator): Likewise.
(function_decl::parameter): Likewise.
(class_decl::base_spec): Likewise.
(ir_node_visitor): Likewise.
2021-06-14 Matthias Maennich <maennich@google.com>
symtab-reader: add support for binaries compiled with CFI
* src/abg-symtab-reader.cc (symtab::load_): use new
add_alternative_address_lookups method.
(add_alternative_address_lookups): New method.
* src/abg-symtab-reader.h (add_alternative_address_lookups): new
function declaration.
* tests/data/test-read-dwarf/test-libaaudio.so: New test data.
* tests/data/test-read-dwarf/test-libaaudio.so.abi: New test data.
* tests/data/Makefile.am: Add the two new tests input to source
distribution.
* tests/test-read-dwarf.cc: New test case.
Reported-by: Dan Albert <danalbert@google.com>
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-06-14 Matthias Maennich <maennich@google.com>
elf-helpers: refactor find_symbol_table_section
* src/abg-elf-helpers.cc(find_section): New overload.
(find_symtab_section): New function.
(find_dynsym_section): New function.
(find_symbol_table_section): Use new find_*_section functions.
* src/abg-elf-helpers.h(find_section): New overload declaration.
(find_symtab_section): New function declaration.
(find_dynsym_section): New function declaration.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-06-18 Dodji Seketeli <dodji@redhat.com>
Bug 27980 - Fix updating of type scope upon type canonicalization
* src/abg-ir.cc (canonicalize): Update the
scope_decl::get_canonical_types() of canonical type of the
containing type of the newly canonicalized type.
* src/abg-writer.cc (write_union_decl): Write the canonical types
contained in the current union scope, just like we do for classes.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-types-stability/pr27980-libc.so: New binary
input file.
* tests/data/Makefile.am: Add the test input file above to source
distribution.
* tests/test-types-stability.cc (elf_paths): Add the new test
input file to this test harness.
2021-05-27 Giuliano Procida <gprocida@google.com>
abg-reader: Create a fresh corpus object per corpus
* src/abg-reader.cc (read_corpus_from_input): Always create a
fresh corpus object for each abi-corpus XML element.
2021-05-27 Giuliano Procida <gprocida@google.com>
abg-reader: Ensure corpus always has a symtab reader
* src/abg-reader.cc (read_symbol_db_from_input): Fix
documentation for this function. Allow "successful parsing" to
include the case where no symbols were present in the input.
(read_corpus_from_input): Unconditionally set a symtab reader
on the corpus object. Unconditionally parse the abi-instr of a
corpus.
2021-05-27 Giuliano Procida <gprocida@google.com>
dwarf-reader: Create new corpus unconditionally
* src/abg-dwarf-reader.cc (read_debug_info_into_corpus):
Create new corpus object unconditionally.
2021-06-09 Ben Woodard via Libabigail <libabigail@sourceware.org>
Fix trivial typo when printing version string
* tools/abicompat.cc (main): Add a newline after version string.
2021-06-10 Dodji Seketeli <dodji@redhat.com>
Revert "Fix trivial typo when printing version string"
* tools/abicompat.cc: Revert "Fix trivial typo when printing version string"
2021-06-09 Ben Woodard via Libabigail <libabigail@sourceware.org>
Fix trivial typo when printing version string
* tools/abicompat.cc: Fix trivial typo when printing version string
2021-06-10 Dodji Seketeli <dodji@redhat.com>
doc: Fix typo
* doc/manuals/libabigail-concepts.rst: Fix typo.
2021-06-09 Dodji Seketeli <dodji@redhat.com>
abg-reader: Fix typo
* src/abg-reader.cc
(read_context::maybe_check_abixml_canonical_type_stability): Fix
typo.
2021-06-09 Dodji Seketeli <dodji@redhat.com>
abidw: Remove temporary .typeid files when using --debug-abidiff
* tools/abidw.cc (load_corpus_and_write_abixml): Remove temporary
typeid file after its use.
2021-06-08 Dodji Seketeli <dodji@redhat.com>
Fix recursive array type definition
* include/abg-ir.h (array_type_def::update_size): Declare new
private member function.
(array_type_def::array_type_def): Declare ...
* src/abg-ir.cc (array_type_def::array_type_def): ... a new
constructor that takes no element type.
(array_type_def::update_size): Define this helper private member
function.
(array_type_def::get_subrange_representation): Adjust for this to
work when there is no element type setup yet.
(array_type_def::{set_element_type, append_subranges}): Update the
size and name of the array.
* src/abg-reader.cc (build_array_type_def): Create the array type
before the element type so that the later can re-use the former.
2021-06-07 Dodji Seketeli <dodji@redhat.com>
rhbz1951526 - SELF CHECK FAILED for 'gimp-2.10'
* include/abg-ir.h
(environment::use_enum_binary_only_equality): Declare
accessors. (type_or_decl_base::{s,g}et_is_artificial):
Likewise. (decl_base::{s,g}et_is_artificial): Remove
accessors. * src/abg-ir.cc
(environment::priv::use_enum_binary_only_equality): Define new
data member.
(environment::priv::use_enum_binary_only_equality): Define
accessors. (type_or_decl_base::priv::is_artificial_): Define
new data member. It has actually moved here from
decl_base::priv::is_artificial_.
(type_or_decl_base::priv::priv): Initialize it.
(type_or_decl_base::{g,s}et_is_artificial): Define accessors.
(decl_base::is_artificial_): Move this to
type_or_decl_base::is_artificial_.
(maybe_adjust_canonical_type): In a given class of equivalence
of function types, if there is one non-artificial function
type, then the entire class of equivalence is considered
non-artificial; so flag the canonical function type as being
non-artificial. (is_enumerator_present_in_enum): Define new
static function. (equals): Re-arrange the overload for enums
so the order of the enumerators doesn't count in the
comparison. Also, two enums with different numbers of
enumerators can still be equal, with the right redundancy. In
the overload for var_decl, avoid taking into account the names
of data members in the comparison.
(enum_type_decl::enumerator::operator==): In the binary-level
comparison mode, only compare the value of enumerators, not
their name. * src/abg-comparison.cc (compute_diff): In the
overload for enum_type_decl, if the enums compare different
using binary-level comparison, then use source-level
comparison to build the diff-IR. * src/abg-dwarf-reader.cc
(read_context::compare_before_canonicalisation): Compare enums
using binary-level comparison. (add_or_update_class_type): If
we are looking at the definition of an existing declaration
that has been already defined then use the previous
definition, in case we are going to need to update the
definition. Also, update the size only if it's needed.
(build_function_type): By default, consider the newly built
function type as artificial. (build_ir_node_from_die): When
looking at a DW_TAG_subroutine_type DIE, consider the built
function type as non-artificial. * src/abg-reader.cc
(read_context::maybe_check_abixml_canonical_type_stability):
Don't consider declaration-only classes in an ODR context
because they don't have canonical types.
(build_function_decl): Flag the function type of the function
as artificial. (build_class_decl): Make sure to reuse class
types that were already created. * src/abg-writer.cc
(write_translation_unit): Allow emitting empty classes. Make
sure referenced types are emitting in the translation unit
where they belong. Avoid emitting artificial function types.
*
tests/data/test-alt-dwarf-file/rhbz1951526/rhbz1951526-report-0.txt:
New test reference output. *
tests/data/test-alt-dwarf-file/rhbz1951526/usr/bin/gimp-2.10:
New reference test binary input. *
tests/data/test-alt-dwarf-file/rhbz1951526/usr/lib/debug/.dwz/gimp-2.10.22-2.el9.1.aarch64:
Likewise. *
tests/data/test-alt-dwarf-file/rhbz1951526/usr/lib/debug/usr/bin/gimp-2.10-2.10.22-2.el9.1.aarch64.debug:
Likewise. * tests/data/Makefile.am: Add the new test files to
source directory. * tests/test-alt-dwarf-file.cc: Add the new
test inputs to this test harness. *
tests/data/test-abidiff/test-PR18791-report0.txt: Adjust. *
tests/data/test-abidiff/test-enum0-report.txt: Likewise. *
tests/data/test-annotate/libtest23.so.abi: Likewise. *
tests/data/test-annotate/libtest24-drop-fns-2.so.abi:
Likewise. *
tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise. * tests/data/test-annotate/test13-pr18894.so.abi:
Likewise. * tests/data/test-annotate/test14-pr18893.so.abi:
Likewise. * tests/data/test-annotate/test15-pr18892.so.abi:
Likewise. * tests/data/test-annotate/test17-pr19027.so.abi:
Likewise. *
tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise. *
tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise. *
tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise. * tests/data/test-annotate/test21-pr19092.so.abi:
Likewise. *
tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise. *
tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Likewise. * tests/data/test-diff-dwarf/test6-report.txt:
Likewise. *
tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise. *
tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise. * tests/data/test-diff-filter/test8-report.txt:
Likewise. *
tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise. *
tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Likewise. *
tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise. *
tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise. *
tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise. *
tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
*
tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise. *
tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise. *
tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise. *
tests/data/test-read-dwarf/libtest24-drop-fns.so.abi:
Likewise. *
tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi:
Likewise. * tests/data/test-read-dwarf/test12-pr18844.so.abi:
Likewise. * tests/data/test-read-dwarf/test13-pr18894.so.abi:
Likewise. * tests/data/test-read-dwarf/test14-pr18893.so.abi:
Likewise. * tests/data/test-read-dwarf/test15-pr18892.so.abi:
Likewise. * tests/data/test-read-dwarf/test16-pr18904.so.abi:
Likewise. * tests/data/test-read-dwarf/test17-pr19027.so.abi:
Likewise. *
tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise. *
tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise. *
tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise. * tests/data/test-read-dwarf/test21-pr19092.so.abi:
Likewise. *
tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise. *
tests/data/test-read-dwarf/test9-pr18818-clang.so.abi:
Likewise. *
tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise. *
tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2021-06-07 Dodji Seketeli <dodji@redhat.com>
reader: Canonicalizing a type once is enough
* src/abg-reader.cc (build_type): Don't try to canonicalize the
type here because all the sub-routines of this function (which
actually build the type) already try to canonicalize it.
2021-06-07 Dodji Seketeli <dodji@redhat.com>
ir: make 'debug(artefact)' support showing enums
* src/abg-ir.cc (get_debug_representation): Add support for
showing details for enums. Also show declaration-only-ness for
class or unions.
2021-06-07 Dodji Seketeli <dodji@redhat.com>
location:expand() shouldn't crash when no location manager available
* src/abg-ir.cc (location::expand): When no location manager is
present, just expand to an empty location.
2021-06-07 Dodji Seketeli <dodji@redhat.com>
Add environment::{get_type_id_from_pointer,get_canonical_type_from_type_id}
* include/abg-ir.h (environment::{get_pointer_type_id_map,
get_type_id_from_pointer, get_canonical_type_from_type_id}):
Declare new member functions.
* src/abg-ir.cc (environment::{get_pointer_type_id_map,
get_type_id_from_pointer, get_canonical_type_from_type_id}):
Define member functions.
(environment::priv::pointer_type_id_map_): Move
this data member here from ...
* src/abg-reader.cc (read_context::m_pointer_type_id_map):
... here.
(read_context::get_pointer_type_id_map): Remove this as it's now
defined in environment::get_pointer_type_id_map.
(read_context::maybe_check_abixml_canonical_type_stability):
Adjust.
(build_type): Likewise.
2021-06-07 Dodji Seketeli <dodji@redhat.com>
ir: Enable setting breakpoint on first type inequality
* src/abg-ir.cc (notify_equality_failed): Define new static
function if WITH_DEBUG_SELF_COMPARISON is defined.
(ABG_RETURN_EQUAL, ABG_RETURN_FALSE, ABG_RETURN): Define new macros.
(try_canonical_compare): Use ABG_RETURN_EQUAL rather than just
returning the result of a comparison.
(equals): In all the overloads, use the new ABG_RETURN* macros,
rather than just returning boolean values.
2021-05-22 Dodji Seketeli <dodji@redhat.com>
xml reader: Fix recursive qualified & reference type definition
* include/abg-ir.h (qualified_type_def::qualified_type_def):
Declare a constructor with no underlying type.
(reference_type_def::reference_type_def): Declare a constructor
with no pointed-to type.
(reference_type_def::set_pointed_to_type): Declare new method.
* src/abg-ir.cc (qualified_type_def::priv::priv): Define a
constructor that takes no underlying type.
(qualified_type_def::build_name): Make this work even on
incomplete types with no underlying type. In that case, this
behaves like if the underlying type is "void".
(qualified_type_def::qualified_type_def): Define a constructor
that takes no underlying type.
(qualified_type_def::get_size_in_bits): Make this work on
incomplete types with no underlying type.
(qualified_type_def::set_underlying_type): Adjust to properly
update this type when a new underlying type is set. Particularly,
its name and the lookup maps from the type scope.
(reference_type_def::reference_type_def): Define a constructor
that takes no pointed-to type.
(reference_type_def::set_pointed_to_type): Define new function.
* src/abg-reader.cc (build_qualified_type_decl): Construct the
qualified type early before we try to construct its underlying
type. Associate this incomplete type with the type-id. Then try
to construct the underlying type. During its construction, if
this incomplete qualified type is needed due to recursion then it
can be used, leading to just one qualified type being used as it
should be.
(build_reference_type_def): Likewise for building incomplete
reference type first before its pointed-to type.
2021-05-21 Dodji Seketeli <dodji@redhat.com>
abixml reader: Fix recursive type definition handling
* include/abg-ir.h (pointer_type_def::pointer_type_def): Declare a
constructor with no pointed-to type.
(pointer_type_def::set_pointed_to_type): Declare new method.
(typedef_decl::typedef_decl): Declare a constructor with no
underlying type.
* src/abg-ir.cc (pointer_type_def::pointer_type_def): Define a
constructor with no pointed-to type. The pointed-to type can thus
later be set when it becomes available.
(pointer_type_def::set_pointed_to_type): Define new method.
(pointer_type_def::get_qualified_name): Make this work on a
pointer type that (momentarily) has no pointed-to type.
(typedef_decl::typedef_decl): Define a constructor with no
underlying type.
(typedef_decl::get_size_in_bits): Make this work on a typedef that
has (momentarily) no underlying type.
(typedef_decl::set_underlying_type): Update the size and alignment
of the typedef from its new underlying type.
* src/abg-reader.cc (build_pointer_type_def): Construct the
pointer type early /BEFORE/ we even try to construct its
pointed-to type. Associate this incomplete type with the type-id.
Then try to construct the pointed-to type. During the
construction of the pointed-to type, if this pointer is needed
(due to recursion) then the incomplete pointer type can be used,
leading to just one pointer type used (recursively) as it should
be.
(build_typedef_decl): Likewise for building typedef type early
without its underlying type so that it can used by the underlying
type if needed.
* tests/data/test-diff-pkg/graphviz-2.44.0-18.el9.aarch64-self-check-report-0.txt:
New test reference output.
* tests/data/test-diff-pkg/graphviz-2.44.0-18.el9.aarch64.rpm: New
binary test input.
* tests/data/test-diff-pkg/graphviz-debuginfo-2.44.0-18.el9.aarch64.rpm: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the test inputs above
to this test harness.
2021-05-20 Dodji Seketeli <dodji@redhat.com>
Introduce artificial locations
* include/abg-fwd.h (get_artificial_or_natural_location): Declare
new function.
* include/abg-ir.h (location::location): Initialize & copy ...
(location::is_artificial_): ... a new data member.
(location::{g,s}et_is_artificial): New accessors.
(location::{operator=}): Adjust.
(type_or_decl_base::{set,get,has}_artificial_location): Declare
new member functions.
* src/abg-ir.cc (decl_topo_comp::operator()): In the overload for
decl_base*, use artificial location for topological sort in
priority. Otherwise, use natural location. Otherwise, sort
lexicographically.
(type_topo_comp::operator()): In the overload for type_base*, use
lexicographical sort only for types that don't have location at
all.
(type_or_decl_base::priv::artificial_location_): Define new data
member.
(type_or_decl_base::{set,get,has}_artificial_location): Define new
member functions.
(decl_base::priv): Allow a constructor without location. That one
sets no natural location to the artifact.
(decl_base::decl_base): Use decl_base::set_location in the
constructor now.
(decl_base::set_location): Adjust this to support setting a
natural or an artificial location.
(get_debug_representation): Emit debugging log showing the
location of an artifact, using its artificial location in
priority.
(get_natural_or_artificial_location): Define new function.
* src/abg-reader.cc (read_artificial_location)
(maybe_set_artificial_location): Define new static functions.
(read_location): Read artificial location when no natural location
was found.
(build_namespace_decl, build_function_decl, build_type_decl)
(build_qualified_type_decl, build_pointer_type_def)
(build_reference_type_def, build_subrange_type)
(build_array_type_def, build_enum_type_decl, build_typedef_decl)
(build_class_decl, build_union_decl, build_function_tdecl)
(build_class_tdecl, build_type_tparameter)
(build_non_type_tparameter, build_template_tparameter): Read and
set artificial location.
* src/abg-writer.cc (write_location): Don't serialize artificial
locations.
(write_namespace_decl): Topologically sort member declarations
before serializing them.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Adjust.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2021-05-19 Dodji Seketeli <dodji@redhat.com>
Detect abixml canonical type instability during abidw --debug-abidiff
* include/abg-ir.h (environment::get_type_id_canonical_type_map):
Declare new data member.
* src/abg-ir.cc (environment::priv::type_id_canonical_type_map_):
Define new data member.
(environment::get_type_id_canonical_type_map): Define new method.
* include/abg-reader.h (load_canonical_type_ids): Declare new
function.
* src/abg-reader.cc (read_context::m_pointer_type_id_map):
Define new data member.
(read_context::{get_pointer_type_id_map,
maybe_check_abixml_canonical_type_stability}): Define new methods.
(read_context::{maybe_canonicalize_type,
perform_late_type_canonicalizing}): Invoke
maybe_perform_self_comparison_canonical_type_check after
canonicalization to perform canonicalization type stability
checking.
(build_type): Associate the pointer value for the newly built type
with the type id string identifying it in the abixml. Once the
abixml representation is dropped from memory and we are about to
perform type canonicalization, we can still know what the type id
of a given type coming from abixml was; it's thus possible to
verify that the canonical type associated to that type id is the
same as the one stored in the typeid file.
(read_type_id_string): Define new static function.
(load_canonical_type_ids): Define new function.
* include/abg-writer.h (write_canonical_type_ids): Likewise.
* src/abg-writer.cc (write_canonical_type_ids): Define new
function overloads.
* tools/abidw.cc (options::type_id_file_path): New data member.
(load_corpus_and_write_abixml): Write and read back the typeid
file.
2021-05-18 Dodji Seketeli <dodji@redhat.com>
Detect failed self comparison in type canonicalization of abixml
* doc/manuals/abidw.rst: Add documentation for the --debug-abidiff
option.
* include/abg-ir.h (environment::{set_self_comparison_debug_input,
get_self_comparison_debug_inputs, self_comparison_debug_is_on}):
Declare new methods.
* configure.ac: Define a new --enable-debug-self-comparison option
that is disabled by default. That option defines a new
WITH_DEBUG_SELF_COMPARISON preprocessor macro.
* src/abg-ir.cc
(environment::priv::{first_self_comparison_corpus_,
second_self_comparison_corpus_, self_comparison_debug_on_}): New
data members. Also, re-indent the data members.
(environment::{set_self_comparison_debug_input,
get_self_comparison_debug_inputs, self_comparison_debug_is_on}):
Define new method.
(type_base::get_canonical_type_for): In the "debug self comparison
mode", if a type coming from the second corpus compares different
from its counterpart coming from the first corpus then log a debug
message.
* src/abg-dwarf-reader.cc (read_debug_info_into_corpus): When
loading the first corpus, if the debug self comparison mode is on,
then save that corpus on the side in the environment.
* src/abg-reader.cc (read_corpus_from_input): When loading the
second corpus, if the debug self comparison mode is on, then save
that corpus on the side in the environment.
* tools/abidw.cc: Include the config.h file for preprocessor
macros defined at configure
(options::debug_abidiff): New data member.
(parse_command_line): Parse the --debug-abidiff option.
(load_corpus_and_write_abixml): Switch the self debug mode on when
the --debug-abidiff option is provided. Use a read_context for
the abixml loading. That is going to be useful for subsequent
patches.
2021-05-17 Dodji Seketeli <dodji@redhat.com>
Add primitives callable from the command line of the debugger
* include/abg-fwd.h (get_debug_representation, get_data_member)
(debug, debug_equals): Declare new functions.
* include/abg-ir.h (environment{get_canonical_types,
get_canonical_type}): Declare new member functions.
* src/abg-ir.cc (environment::{get_canonical_types,
get_canonical_type}): Define new member functions.
(get_debug_representation, get_data_member)
(debug, debug_equals): Define new functions.
2021-05-24 Dodji Seketeli <dodji@redhat.com>
Peel array types when peeling pointers from a type
* src/abg-ir.cc (peel_typedef_pointer_or_reference_type): In the
overloads for type_base_sptr and type_base*, peel array type off
as well.
2021-05-24 Dodji Seketeli <dodji@redhat.com>
Fix DWARF type DIE canonicalization
* src/abg-dwarf-reader.cc (compare_dies): When comparing array
type DIEs, take into account the type of the elements of the
arrays.
2021-05-24 Dodji Seketeli <dodji@redhat.com>
Miscellaneous indentation and comments cleanups
* src/abg-ir.cc (environment::priv::{config_, canonical_types_,
sorted_canonical_types_, void_type_, variadic_marker_type_}):
Re-indent these data members.
(peel_typedef_pointer_or_reference_type): Fix comment.
(var_decl::var_decl): Likewise.
(function_decl::function_decl): Add a comment.
* src/abg-reader.cc (handle_reference_type_def): Fix indentation
of parameters.
2021-05-20 Dodji Seketeli <dodji@redhat.com>
Fix thinko in configure.ac
* configure.ac: Fix a thinko I spotted while looking at something
else.
2021-04-19 Dodji Seketeli <dodji@redhat.com>
reader: Use xmlFirstElementChild/xmlNextElementSibling to iterate over children elements
* src/abg-reader.cc (walk_xml_node_to_map_type_ids)
(read_translation_unit, read_translation_unit_from_input)
(read_symbol_db_from_input, build_needed)
(read_elf_needed_from_input, read_corpus_group_from_input)
(build_namespace_decl, build_elf_symbol_db, build_function_decl)
(build_function_type, build_array_type_def, build_enum_type_decl)
(build_class_decl, build_union_decl, build_function_tdecl)
(build_class_tdecl, build_type_composition)
(build_template_tparameter): Use
xmlFirstElementChild/xmlNextElementSibling rather than poking at
xmlNode::children and looping over xmlNode::next by hand.
2021-04-19 Dodji Seketeli <dodji@redhat.com>
reader: Use xmlFirstElementChild and xmlNextElementSibling rather than xml::advance_to_next_sibling_element
* include/abg-libxml-utils.h (advance_to_next_sibling_element):
Remove the declaration of this function.
* src/abg-libxml-utils.cc (go_to_next_sibling_element_or_stay)
(advance_to_next_sibling_element): Remove definitions of these functions.
* src/abg-reader.cc (read_translation_unit_from_input)
(read_elf_needed_from_input, read_corpus_group_from_input): Use xmlNextElementSibling instead
of xml::advance_to_next_sibling_element.
(read_corpus_from_input): Likewise. Also, use
xmlFirstElementChild instead of
xml::advance_to_next_sibling_element on the xmlNode::children data
member.
(read_corpus_group_from_input): use xmlFirstElementChild instead
of xml::advance_to_next_sibling_element on the xmlNode::children
data member.
2021-04-14 Dodji Seketeli <dodji@redhat.com>
reader: Handle 'abi-corpus' element being possibly empty
* src/abg-reader.cc (read_context::get_corpus_node): Add comment
to this member function.
(read_translation_unit_from_input, read_symbol_db_from_input)
(read_elf_needed_from_input): Start processing the current node of
the corpus that needs to be processed rather than its next
sibling. Once the processing is done, set the new "current node
of the corpus to be processed" properly by skipping to the next
element node to be processed.
(read_corpus_from_input): Don't get out early when the
'abi-corpus' element is empty. If, however, it has children node,
skip to the first child element and flag it -- using
read_context::set_corpus_node -- as being the element node to be
processed by the processing facilities of the reader. If we are
in a mode where we called xmlTextReaderExpand ourselves to get the
node to process, then it means we need to free that node
indirectly by calling xmlTextReaderNext. In that case, that node
should not be flagged by read_context::set_corpus_node. Add more
comments.
* src/abg-corpus.cc (corpus::is_empty): Do not crash when no
symtab is around.
* src/abg-libxml-utils.cc (go_to_next_sibling_element_or_stay):
Fix typo in comment.
(advance_to_next_sibling_element): Don't crash when given a nil
node.
* tests/data/test-abidiff/test-PR27616-squished-v0.abi: Add new
test input.
* tests/data/test-abidiff/test-PR27616-squished-v1.abi: Likewise.
* tests/data/test-abidiff/test-PR27616-v0.xml: Likewise.
* tests/data/test-abidiff/test-PR27616-v1.xml: Likewise.
* tests/data/Makefile.am: Add the new test inputs above to source
distribution.
* tests/test-abidiff.cc (specs): Add the new tests inputs above to
this harness.
* tools/abilint.cc (main): Support writing corpus groups.
2021-04-13 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: properly set artificial-ness in opaque types
* src/abg-dwarf-reader.cc (get_opaque_version_of_type): Propagate
the artificial-ness of the original type here.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Adjust.
2021-04-12 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Canonicalize opaque enums and classes
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Canonicalize
opaque enums and classes.
* tests/data/test-read-dwarf/PR27700/include-dir/priv.h: New test
header file.
* tests/data/test-read-dwarf/PR27700/include-dir/pub.h: Likewise
* tests/data/test-read-dwarf/PR27700/pub-incdir/inc.h: Likewise.
* tests/data/test-read-dwarf/PR27700/test-PR27700.o: New binary
input file.
* tests/data/test-read-dwarf/PR27700/test-PR27700.abi: Reference
abi file of the binary above.
* tests/data/test-read-dwarf/PR27700/test-PR27700.c: Source file
of the binary above.
* tests/data/Makefile.am: Add the test material above to source
distribution.
* tests/test-read-dwarf.cc (InOutSpec::in_public_headers_path):
Add new data member.
(in_out_specs): Adjust to reflect the new data member in the
InOutSpec type. Add a new test input.
(set_suppressions_from_headers): Define new static function.
(test_task::perform): Use the content of the new
InOutSpec::in_public_headers_path to construct and add
"--headers-dir <headers-dir> --drop-private-types" to the options
of the abidw program run.
2020-07-01 Matthias Maennich <maennich@google.com>
symtab: Add support for MODVERSIONS (CRC checksums)
* include/abg-ir.h (elf_symbol::elf_symbol): Add CRC parameter.
(elf_symbol::create): Likewise.
(elf_symbol::get_crc): New member method.
(elf_symbol::set_crc): New member method.
* src/abg-comp-filter.cc (crc_changed): New function.
(categorize_harmful_diff_node): Also test for CRC changes.
* src/abg-ir.cc (elf_symbol::priv::crc_): New data member.
* src/abg-ir.cc (elf_symbol::priv::priv): Add CRC parameter.
(elf_symbol::elf_symbol): Likewise.
(elf_symbol::create): Likewise.
(elf_symbol::textually_equals): Add CRC support.
(elf_symbol::get_crc): New member method.
(elf_symbol::set_crc): New member method.
* src/abg-reader.cc (build_elf_symbol): Add CRC support.
* src/abg-reporter-priv.cc (maybe_report_diff_for_symbol): Likewise.
* src/abg-symtab-reader.cc (symtab::load): Likewise.
* src/abg-writer.cc (write_elf_symbol): Likewise.
* tests/data/Makefile.am: Add new test data files.
* tests/data/test-abidiff-exit/test-crc-report.txt: New test file.
* tests/data/test-abidiff-exit/test-crc-v0.abi: Likewise.
* tests/data/test-abidiff-exit/test-crc-v1.abi: Likewise.
* tests/data/test-abidiff/empty-report.txt: New file.
* tests/data/test-abidiff/test-PR18166-libtirpc.so.report.txt: Deleted.
* tests/data/test-abidiff/test-PR24552-report0.txt: Deleted.
* tests/data/test-abidiff/test-crc-0.xml: New test file.
* tests/data/test-abidiff/test-crc-1.xml: Likewise.
* tests/data/test-abidiff/test-crc-2.xml: Likewise.
* tests/data/test-abidiff/test-crc-report.txt: Likewise.
* tests/data/test-abidiff/test-empty-corpus-report.txt: Deleted.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Add CRC values.
* tests/data/test-read-write/test-crc.xml: New test data file.
* tests/data/test-symtab/kernel-modversions/Makefile: New test source.
* tests/data/test-symtab/kernel-modversions/one_of_each.c: Likewise.
* tests/data/test-symtab/kernel-modversions/one_of_each.ko: Likewise.
* tests/test-abidiff-exit.cc: Add new test case.
* tests/test-abidiff.cc: Add new test case.
* tests/test-read-write.cc: Likewise.
* tests/test-symtab.cc (Symtab::KernelSymtabsWithCRC): New test case.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-10-15 Giuliano Procida <gprocida@google.com>
abg-writer.cc: fix write_elf_symbol_reference loop
* src/abg-writer.cc (write_elf_symbol_reference): Check main
symbol and aliases with more care.
Fixes: commmit ("dwarf-reader/writer: consider aliases when dealing with suppressions")
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-06-28 Matthias Maennich <maennich@google.com>
dwarf-reader/writer: consider aliases when dealing with suppressions
* src/abg-dwarf-reader.cc(function_is_suppressed): Do not suppress
a function for which there is an alias that is not suppressed.
(variable_is_suppressed): Likewise for variables.
* src/abg-reader.cc (build_elf_symbol): Improve handling of
suppressed aliased symbols when reading from XML.
* src/abg-symtab-reader.cc (load): Likewise.
* src/abg-writer.cc(write_elf_symbol_reference): Fall back to
any aliased symbol if the main symbol is suppressed.
* tests/data/Makefile.am: Add new test files.
* tests/data/test-abidiff-exit/test-missing-alias-report.txt: New test file.
* tests/data/test-abidiff-exit/test-missing-alias.abi: Likewise.
* tests/data/test-abidiff-exit/test-missing-alias.suppr: Likewise.
* tests/test-abidiff-exit.cc: Add support for whitelists and add
new testcase.
* tests/data/test-read-dwarf/test-suppressed-alias.c: New test file.
* tests/data/test-read-dwarf/test-suppressed-alias.o: Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.o.abi: Likewise.
* tests/data/test-read-dwarf/test-suppressed-alias.suppr: Likewise.
* tests/data/test-read-dwarf/test3-alias-1.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-1.suppr: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-2.suppr: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-3.suppr: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test3-alias-4.suppr: Likewise.
* tests/test-read-dwarf.cc: Add new test cases.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-06-30 Matthias Maennich <maennich@google.com>
symtab/dwarf-reader: allow hinting of main symbols for aliases
* include/abg-ir.h (elf_symbol::update_main_symbol): New method.
* include/abg-symtab-reader.h (symtab::update_main_symbol): New method.
* src/abg-dwarf-reader.cc
(build_var_decl): Hint symtab about main symbol discovered in DWARF.
(build_function_decl): Likewise.
* src/abg-ir.cc (elf_symbol::get_main_symbol): Lock the weak_ptr
on access in both overloads.
(update_main_symbol): New method to allow updating the main symbol.
* src/abg-symtab-reader.cc (symtab::update_main_symbol): New method.
* data/Makefile.am: Add new test data files.
* tests/data/test-annotate/test15-pr18892.so.abi: Updated test file.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-diff-dwarf/test12-report.txt: Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-4.suppr: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-2.txt: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-symtab/basic/aliases.c: New test source file.
* tests/data/test-symtab/basic/aliases.so: Likewise.
* tests/test-symtab.cc (Symtab::AliasedFunctionSymbols): New test case.
(Symtab::AliasedVariableSymbols): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-06-29 Matthias Maennich <maennich@google.com>
test-symtab: add tests for whitelisted functions
* tests/data/Makefile.am: add new test files
* tests/data/test-symtab/basic/one_function_one_variable_all.whitelist: New test file,
* tests/data/test-symtab/basic/one_function_one_variable_function.whitelist: Likewise.
* tests/data/test-symtab/basic/one_function_one_variable_irrelevant.whitelist: Likewise.
* tests/data/test-symtab/basic/one_function_one_variable_variable.whitelist: Likewise.
* tests/test-symtab.cc (read_corpus): Add support for whitelists.
(assert_symbol_count): Likewise.
(Symtab::SymtabWithWhitelist): New testcase.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-06-02 Matthias Maennich <maennich@google.com>
dwarf reader: drop (now) unused code related to symbol table reading
* include/abg-dwarf-reader.h (set_ignore_symbol_table): Remove.
(get_ignore_symbol_table): Likewise.
* src/abg-dwarf-reader.cc (add_symbol_to_map): Likewise.
(read_context::options_type::ignore_symbol_table): Likewise.
(read_context::options_type): Adjust.
(read_context::fun_addr_sym_map_): Remove.
(read_context::fun_entry_addr_sym_map_): Likewise.
(read_context::fun_syms_): Likewise.
(read_context::var_addr_sym_map_): Likewise.
(read_context::var_syms_): Likewise.
(read_context::undefined_fun_syms_): Likewise.
(read_context::undefined_var_syms_): Likewise.
(read_context::initialize): Adjust.
(read_context::lookup_elf_symbol_from_index): Remove.
(read_context::fun_entry_addr_sym_map_sptr): Likewise.
(read_context::fun_entry_addr_sym_map): Likewise.
(read_context::fun_syms_sptr): Likewise.
(read_context::fun_syms): Likewise.
(read_context::var_syms_sptr): Likewise.
(read_context::var_syms): Likewise.
(read_context::undefined_fun_syms_sptr): Likewise.
(read_context::undefined_var_syms_sptr): Likewise.
(read_context::load_symbol_maps_from_symtab_section): Likewise.
(read_context::load_symbol_maps): Likewise.
(read_context::maybe_load_symbol_maps): Likewise.
(set_ignore_symbol_table): Likewise.
(get_ignore_symbol_table): Likewise.
(create_default_var_sym): Likewise.
(build_var_decl): Adjust.
(function_is_suppressed): Likewise.
(variable_is_suppressed): Likewise.
(build_function_decl): Likewise.
(add_symbol_to_map): Remove.
(read_corpus_from_elf): Adjust.
(build_corpus_group_from_kernel_dist_under): Likewise.
* tools/abidw.cc (main): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-21 Matthias Maennich <maennich@google.com>
abg-corpus: remove symbol maps and their setters
* include/abg-corpus.h (corpus::set_fun_symbol_map): Remove
method declaration.
(corpus::set_undefined_fun_symbol_map): Likewise.
(corpus::set_var_symbol_map): Likewise.
(corpus::set_undefined_var_symbol_map): Likewise.
(corpus::get_fun_symbol_map_sptr): Likewise.
(corpus::get_undefined_fun_symbol_map_sptr): Likewise.
(corpus::get_var_symbol_map_sptr): Likewise.
(corpus::get_undefined_var_symbol_map_sptr): Likewise.
* src/abg-corpus-priv.h (corpus::priv::var_symbol_map): make
private and mutable
(corpus::priv::undefined_var_symbol_map): Likewise.
(corpus::priv::fun_symbol_map): Likewise.
(corpus::priv::undefined_fun_symbol_map): Likewise.
(corpus::priv::get_fun_symbol_map): New method declaration.
(corpus::priv::get_undefined_fun_symbol_map): Likewise.
(corpus::priv::get_var_symbol_map): Likewise.
(corpus::priv::get_undefined_var_symbol_map): Likewise.
* src/abg-corpus.cc (corpus::priv::get_fun_symbol_map): New
method implementation.
(corpus::priv::get_undefined_fun_symbol_map): Likewise.
(corpus::priv::get_var_symbol_map): Likewise.
(corpus::priv::get_undefined_var_symbol_map): Likewise.
(corpus::is_empty): depend on symtab only.
(corpus::set_fun_symbol_map): Remove method.
(corpus::set_undefined_fun_symbol_map): Likewise.
(corpus::set_var_symbol_map): Likewise.
(corpus::set_undefined_var_symbol_map): Likewise.
(corpus::get_fun_symbol_map_sptr): Likewise.
(corpus::get_undefined_fun_symbol_map_sptr): Likewise.
(corpus::get_var_symbol_map_sptr): Likewise.
(corpus::get_undefined_var_symbol_map_sptr): Likewise.
(corpus::get_fun_symbol_map): Use corpus::priv proxy method.
(corpus::get_undefined_fun_symbol_map): Likewise.
(corpus::get_var_symbol_map): Likewise.
(corpus::get_undefined_var_symbol_map): Likewise.
* src/abg-dwarf-reader.cc (read_debug_info_into_corpus): Do not
set corpus symbol maps anymore.
* src/abg-reader.cc (read_corpus_from_input): Likewise.
* tests/test-symtab.cc (assert_symbol_count): Do not access the
corpus symbol maps through sptr anymore.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Adjust
expected test output.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-14 Matthias Maennich <maennich@google.com>
symtab_reader: add support for ppc64 ELFv1 binaries
* src/abg-symtab-reader.cc (symtab::lookup_symbol): fall back to
lookup the address in entry_addr_symbol_map_.
(symtab::load): update the function entry address map for
ppc64 targets.
(symtab::update_function_entry_address_symbol_map): New
function implementation.
* src/abg-symtab-reader.h
(symtab::entry_addr_symbol_map_): New data member.
(symtab::update_function_entry_address_symbol_map): New
function declaration.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-12 Matthias Maennich <maennich@google.com>
abg-elf-helpers: migrate ppc64 specific helpers
* src/abg-dwarf-reader.cc (read_context::opd_section_): Delete.
(read_context::find_opd_section): Delete.
(read_context::read_uint64_from_array_of_bytes): Delete.
(read_context::read_int_from_array_of_bytes): Delete.
(read_context::lookup_ppc64_elf_fn_entry_point_address): Delete.
(read_context::address_is_in_opd_section): Delete.
(read_context::address_is_in_section): Delete.
(read_context::load_symbol_maps_from_symtab_section): Adjust.
* src/abg-elf-helpers.cc (read_int_from_array_of_bytes): New.
(read_uint64_from_array_of_bytes): New.
(lookup_ppc64_elf_fn_entry_point_address): New.
(address_is_in_section): New.
(address_is_in_opd_section): New.
* src/abg-elf-helpers.h
(lookup_ppc64_elf_fn_entry_point_address): New declaration.
(address_is_in_opd_section): New declaration.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-06 Matthias Maennich <maennich@google.com>
Switch kernel stuff over to new symtab and drop unused code
* src/abg-dwarf-reader.cc (read_context::ksymtab_format_): Delete.
(read_context::ksymtab_entry_size_): Likewise.
(read_context::nb_ksymtab_entries_): Likewise.
(read_context::nb_ksymtab_gpl_entries_): Likewise.
(read_context::ksymtab_section_): Likewise.
(read_context::ksymtab_reloc_section_): Likewise.
(read_context::ksymtab_gpl_section_): Likewise.
(read_context::ksymtab_gpl_reloc_section_): Likewise.
(read_context::ksymtab_strings_section_): Likewise.
(read_context::linux_exported_fn_syms): Likewise.
(read_context::linux_exported_var_syms): Likewise.
(read_context::linux_exported_gpl_fn_syms): Likewise.
(read_context::linux_exported_gpl_var_syms): Likewise.
(read_context::initialize): Remove initializations accordingly.
(read_context::find_ksymtab_section): Delete.
(read_context::find_ksymtab_gpl_section): Likewise.
(read_context::find_ksymtab_reloc_section): Likewise.
(read_context::find_ksymtab_gpl_reloc_section): Likewise.
(read_context::find_ksymtab_strings_section): Likewise.
(read_context::find_any_ksymtab_section): Likewise.
(read_context::find_any_ksymtab_reloc_section): Likewise.
(read_context::lookup_elf_symbol_from_index): Adjust.
(read_context::linux_exported_fn_syms): Delete.
(read_context::create_or_get_linux_exported_fn_syms): Likewise.
(read_context::linux_exported_var_syms): Likewise.
(read_context::create_or_get_linux_exported_var_syms): Likewise.
(read_context::linux_exported_gpl_fn_syms): Delete.
(read_context::create_or_get_linux_exported_gpl_fn_syms): Likewise.
(read_context::linux_exported_gpl_var_syms): Likewise.
(read_context::create_or_get_linux_exported_gpl_var_syms): Likewise.
(read_context::try_reading_first_ksymtab_entry): Likewise.
(read_context::try_reading_first_ksymtab_entry_using_pre_v4_19_format): Likewise.
(read_context::try_reading_first_ksymtab_entry_using_v4_19_format): Likewise.
(read_context::get_ksymtab_format_module): Likewise.
(read_context::get_ksymtab_format): Likewise.
(read_context::get_ksymtab_symbol_value_size): Likewise.
(read_context::get_ksymtab_entry_size): Likewise.
(read_context::get_nb_ksymtab_entries): Likewise.
(read_context::get_nb_ksymtab_gpl_entries): Likewise.
(read_context::populate_symbol_map_from_ksymtab): Likewise.
(read_context::populate_symbol_map_from_ksymtab_reloc): Likewise.
(read_context::load_kernel_symbol_table): Likewise.
(read_context::load_ksymtab_symbols): Likewise.
(read_context::load_ksymtab_gpl_symbols): Likewise.
(read_context::load_linux_specific_exported_symbol_maps): Likewise.
(read_context::load_symbol_maps): Do not load kernel symbol maps.
(read_context::maybe_adjust_sym_address_from_v4_19_ksymtab): Delete.
(read_context::add_fn_symbols_to_map): Likewise.
(read_context::add_var_symbols_to_map): Likewise.
(read_context::read_debug_info_into_corpus): Fill export maps
from new symtab.
(read_context::lookup_elf_fn_symbol_from_address): Delete.
(read_context::lookup_elf_var_symbol_from_address): Likewise.
(read_context::lookup_elf_symbol_from_address): Likewise.
(read_context::lookup_public_function_symbol_from_elf): Likewise.
(read_context::fun_entry_addr_sym_map_sptr): Likewise.
(read_context::fun_entry_addr_sym_map): Likewise.
(read_context::var_addr_sym_map): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-06 Matthias Maennich <maennich@google.com>
dwarf-reader: read_context: use new symtab in *_symbols_is_exported
* src/abg-dwarf-reader.cc (function_symbol_is_exported): Use new
symtab implementation.
(variable_symbol_is_exported): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-04 Matthias Maennich <maennich@google.com>
abg-reader: avoid using the (var|function)_symbol_map
* src/abg-reader.cc (build_elf_symbol_from_reference): drop
last parameter indicating the lookup type and use corpus
symtab for the lookup
(build_function_decl): Adjust accordingly.
(build_var_decl): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-04 Matthias Maennich <maennich@google.com>
corpus: make get_unreferenced_(function|variable)_symbols use the new symtab
* src/abg-corpus-priv.h (corpus::priv::unrefed_var_symbols): make
private, mutable and optional.
(corpus::unrefed_fun_symbols): Likewise.
(corpus::priv::get_unreferenced_function_symbols): New method declaration.
(corpus::priv::get_unreferenced_variable_symbols): Likewise.
* src/abg-corpus.cc
(corpus::priv::build_unreferenced_symbols_tables): Delete method.
(corpus::priv::get_unreferenced_function_symbols): New method implementation.
(corpus::priv::get_unreferenced_variable_symbols): Likewise.
(corpus::get_unreferenced_function_symbols): Proxy call to corpus::priv.
(corpus::get_unreferenced_variable_symbols): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-04-30 Matthias Maennich <maennich@google.com>
corpus: make get_(undefined_)?_(var|fun)_symbols use the new symtab
* src/abg-corpus-priv.h (corpus::priv::sorted_var_symbols): make
private, mutable and optional.
(corpus::sorted_undefined_var_symbols): Likewise.
(corpus::sorted_fun_symbols): Likewise.
(corpus::sorted_undefined_fun_symbols): Likewise.
(corpus::priv::get_sorted_fun_symbols): New method declaration.
(corpus::priv::get_sorted_undefined_fun_symbols): Likewise.
(corpus::priv::get_sorted_var_symbols): Likewise.
(corpus::priv::get_sorted_undefined_var_symbols): Likewise.
* src/abg-corpus.cc
(corpus::elf_symbol_comp_functor): Delete struct.
(corpus::priv::get_sorted_fun_symbols): New method implementation.
(corpus::priv::get_sorted_undefined_fun_symbols): Likewise.
(corpus::priv::get_sorted_var_symbols): Likewise.
(corpus::priv::get_sorted_undefined_var_symbols): Likewise.
(corpus::get_sorted_fun_symbols): Proxy call to corpus::priv.
(corpus::get_sorted_undefined_fun_symbols): Likewise.
(corpus::get_sorted_var_symbols): Likewise.
(corpus::get_sorted_undefined_var_symbols): Likewise.
* src/abg-writer.cc (write_elf_symbol_aliases): When emitting
aliases for a kernel symbol, ensure to only emit exported,
public aliases.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: update test
data.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-05-19 Matthias Maennich <maennich@google.com>
Integrate new symtab reader into corpus and read_context
* include/abg-corpus.h (corpus::set_symtab): New method declaration.
(corpus::get_symtab): New method declaration.
* include/abg-fwd.h (symtab_reader::symtab_sptr): New forward
declaration.
* src/abg-corpus-priv.h (corpus::priv::symtab_): New data member.
* src/abg-corpus.cc
(corpus::set_symtab): Likewise.
(corpus::get_symtab): Likewise.
* src/abg-dwarf-reader.cc (read_context::symtab_): New data member.
(read_context::initialize): reset symtab_ as well
(read_context::symtab): new method that loads a symtab on
first access and returns it.
(read_debug_info_into_corpus): also set the new symtab object
on the current corpus.
(read_corpus_from_elf): Also determine (i.e. load) the new
symtab object and contribute to the load status.
* src/abg-reader.cc (read_corpus_from_input): also set the new
type symtab when reading from xml.
* tests/test-symtab.cc: Add test assertions.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-04-29 Matthias Maennich <maennich@google.com>
Refactor ELF symbol table reading by adding a new symtab reader
* src/abg-symtab-reader.h (symtab_filter): New class.
(symtab_iterator): Likewise.
(symtab): Likewise.
(filtered_symtab): Likewise.
* src/abg-symtab-reader.cc (symtab_filter::matches): New.
(symtab::make_filter): Likewise.
(symtab::lookup_symbol): Likewise.
(symbol_sort): Likewise.
(symtab::load): Likewise.
(symtab::load_): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2021-03-29 Matthias Maennich <maennich@google.com>
clang-format: Minor correction to not break parameters on the first line
* .clang-format: correct function parameter break/indentation
2021-03-31 Dodji Seketeli <dodji@redhat.com>
Bug 27598 - abidiff mishandles union member functions
* src/abg-default-reporter.cc (default_reporter::report): Assume
the parent type of the method can be either a class or a union.
* tests/data/test-diff-filter/test-PR27598-report-0.txt: New
reference output for the test.
* tests/data/test-diff-filter/test-PR27598-v{0,1}.cc: New source
code for the input binaries below.
* tests/data/test-diff-filter/test-PR27598-v{0,1}.o: New input
test binaries.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the test inputs
above to this test harness.
2021-03-25 Dodji Seketeli <dodji@redhat.com>
Bug 27569 - abidiff misses a function parameter addition
* include/abg-comparison.h (enum diff_category): Add a new
FN_PARM_ADD_REMOVE_CHANGE_CATEGORY enumerator and adjust the
following enumerator values. Update the EVERYTHING_CATEGORY
accordingly.
(function_type_diff::{sorted_deleted_parms, sorted_added_parms}):
Add new member functions.
* src/abg-comparison.cc
(function_type_diff::{sorted_deleted_parms, sorted_added_parms}):
Define new accessors.
(get_default_harmful_categories_bitmap):
Consider changes of the category
FN_PARM_ADD_REMOVE_CHANGE_CATEGORY as harmful.
(operator<<(ostream& o, diff_category c)): Support the new
FN_PARM_ADD_REMOVE_CHANGE_CATEGORY while serializing a category
bitmap.
* src/abg-comp-filter.cc
(has_added_or_removed_function_parameters): Define new static
function.
(categorize_harmful_diff_node): Categorize diff nodes representing
function parameter addition or removal as
FN_PARM_ADD_REMOVE_CHANGE_CATEGORY.
* tests/data/test-diff-filter/test-PR27569-report-0.txt: New test
reference output.
* tests/data/test-diff-filter/test-PR27569-v{0,1}.abi: New test inputs.
* tests/data/Makefile.am: Add the new test inputs to the source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test
inputs to this test harness.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
2021-03-15 Giuliano Procida <gprocida@google.com>
dwarf-reader: Treat union members as public by default.
* src/abg-dwarf-reader.cc (add_or_update_union_type): Replace
"class" with "union" in comments; give union members public
access by default.
(finish_member_function_reading): Give union members public access
by default.
(maybe_set_member_type_access_specifier): Give union members
public access by default.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Refresh.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Refresh.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Refresh.
* tests/data/test-annotate/test13-pr18894.so.abi: Refresh.
* tests/data/test-annotate/test14-pr18893.so.abi: Refresh.
* tests/data/test-annotate/test15-pr18892.so.abi: Refresh.
* tests/data/test-annotate/test17-pr19027.so.abi: Refresh.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Refresh.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Refresh.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Refresh.
* tests/data/test-annotate/test21-pr19092.so.abi: Refresh.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Refresh.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Refresh.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Refresh.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Refresh.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Refresh.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi:
Refresh.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Refresh.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Refresh.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Refresh.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi:
Refresh.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Refresh.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Refresh.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Refresh.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Refresh.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Refresh.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Refresh.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Refresh.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Refresh.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Refresh.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Refresh.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Refresh.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Refresh.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi:
Refresh.
2021-03-12 Ben Woodard via Libabigail <libabigail@sourceware.org>
Bug 27512 - Remove broken zip-archive support
* configure.ac: remove --enable-zip-archive option and logic
associated with it.
* include/abg-libzip-utils.h: Remove.
* src/abg-libzip-utils.cc: Likewise.
* include/Makefile.am: remove reference to include/abg-libzip-utils.h
that no longer exists.
* src/Makefile.am: remove reference to src/abg-libzip-utils.cc that no
longer exists.
* relicensing-scripts/file-licenses.orig.txt: remove references to
files that no longer exist.
* relicensing-scripts/files-with-lgplv3.txt: remove references to
files that no longer exist.
* tests/test-write-read-archive.cc: Remove because it tests code
that no longer exists.
* tests/Makefile.am: remove reference to tests that no longer exist.
* include/abg-reader.h: remove conditionally compiled code for zip
archives.
* include/abg-tools-utils.h: remove conditionally compiled code for
zip archives.
* src/abg-corpus.cc: remove conditionally compiled code for zip
archives.
* src/abg-reader.cc: remove conditionally compiled code for zip
archives.
* src/abg-tools-utils.cc: remove conditionally compiled code for zip
archives.
* src/abg-writer.cc: remove conditionally compiled code for zip
archives.
* tools/abidiff.cc: remove conditionally compiled code for zip
archives.
* tools/abilint.cc: remove conditionally compiled code for zip
archives.
* tools/abiar.c: Remove.
* tools/Makefile.am: remove references to abiar a utility that no
longer has a reason for existing.
2021-03-18 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support more DWARF-5 type DIEs
* src/abg-dwarf-reader.cc (is_type_tag): Support
DW_TAG_coarray_type, DW_TAG_atomic_type and DW_TAG_immutable_type.
* tests/data/test-diff-pkg/elfutils-debuginfo-0.183-1.el9.x86_64.rpm:
Add new binary test input.
* tests/data/test-diff-pkg/elfutils-libs-debuginfo-0.183-1.el9.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/elfutils-libs-0.183-1.el9.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/elfutils-libs-debuginfo-0.183-1.el9.x86_64-self-check-report-0.txt:
Add new reference test output.
* tests/test-diff-pkg.cc (in_out_specs): Add the test inputs above
to the harness.
2021-03-10 Giuliano Procida <gprocida@google.com>
DWARF reader: Comment ARM32 ELF address interpretation
* src/abg-dwarf-reader.cc
(read_context::load_symbol_maps_from_symtab_section): Add
descriptive comment to ARM32 address handling; shorten
the assignment using &=.
2021-01-27 Matthias Maennich <maennich@google.com>
dwarf-reader split: create abg-symtab-reader.{h,cc} and test case
* src/abg-symtab-reader.h: New header file.
* src/abg-symtab-reader.cc: New source file.
* src/Makefile.am: Add new source files.
* tests/Makefile.am: Add new test case runtestsymtabreader.
* tests/test-symtab-reader.cc: New test source file.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-03-09 Giuliano Procida <gprocida@google.com>
DWARF reader: Interpret ARM32 ELF addresses correctly
* src/abg-dwarf-reader.cc
(read_context::load_symbol_maps_from_symtab_section): Clear
bit zero of ARM32 function addresses.
* src/abg-elf-helpers.cc (architecture_is_arm32): Add new
function.
* src/abg-elf-helpers.h (architecture_is_arm32): Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Update.
2021-01-27 Matthias Maennich <maennich@google.com>
abg-ir: elf_symbol: add is_suppressed field
* include/abg-ir.h (elf_symbol::elf_symbol): Add is_suppressed
parameter.
(elf_symbol::create): Likewise.
(elf_symbol::is_suppressed): New getter declaration.
(elf_symbol::set_is_suppressed): New setter declaration.
* src/abg-ir.cc (elf_symbol::priv::priv): Add is_suppressed
parameter.
(elf_symbol::priv::is_suppressed_): New field.
(elf_symbol::elf_symbol): Add is_suppressed parameter.
(elf_symbol::create): Likewise.
(elf_symbol::is_suppressed): New getter implementation.
(elf_symbol::set_is_suppressed): New setter implementation.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-01-27 Matthias Maennich <maennich@google.com>
abg-ir: elf_symbol: add is_in_ksymtab field
* include/abg-ir.h (elf_symbol::elf_symbol): Add is_in_ksymtab
parameter.
(elf_symbol::create): Likewise.
(elf_symbol::is_in_ksymtab): New getter declaration.
(elf_symbol::set_is_in_ksymtab): New setter declaration.
* src/abg-ir.cc (elf_symbol::priv::priv): Add is_in_ksymtab
parameter.
(elf_symbol::priv::is_in_ksymtab_): New field.
(elf_symbol::elf_symbol): Add is_in_ksymtab parameter.
(elf_symbol::create): Likewise.
(elf_symbol::is_in_ksymtab): New getter implementation.
(elf_symbol::set_is_in_ksymtab): New setter implementation.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-01-27 Matthias Maennich <maennich@google.com>
abg-cxx-compat: add simplified version of std::optional
* include/abg-cxx-compat.h (abg_compat::optional): Add new class.
* tests/tests-cxx-compat.cc: Add new test cases.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2021-03-02 Ben Woodard via Libabigail <libabigail@sourceware.org>
Fix declaratons of conditionally defined functions
* include/abg-reader.h (read_corpus_from_file): Guard the
declaration of these overloads with #ifdef WITH_ZIP_ARCHIVE.
* tools/abilint.cc: Guard the use of
abigail::xml_reader::read_corpus_from_file with #ifdef
WITH_ZIP_ARCHIVE.
2021-03-08 Dodji Seketeli <dodji@redhat.com>
Revert "Fix declaratons of conditionally defined functions"
* include/abg-reader.h: Revert "Fix declaratons of conditionally defined functions"
* tools/abilint.cc: Revert "Fix declaratons of conditionally defined functions"
2021-03-02 Ben Woodard via Libabigail <libabigail@sourceware.org>
Fix declaratons of conditionally defined functions
* include/abg-reader.h: Fix declaratons of conditionally defined functions
* tools/abilint.cc: Fix declaratons of conditionally defined functions
2021-03-08 Dodji Seketeli <dodji@redhat.com>
tests/catch.hpp: Add SPDX header back
* tests/lib/catch.hpp: Add SPDX header back.
2021-02-25 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Keep stable order when de-duplicating class definitions
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Compare the
classes that have the same name across several TU, always in the
same order.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
2021-02-24 Dodji Seketeli <dodji@redhat.com>
Better sorting of (anonymous) types in ABIXML files
* src/abg-writer.cc (type_ptr_cmp::operator()): Use the internal
pretty representation of types, for comparison.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
2021-02-23 Dodji Seketeli <dodji@redhat.com>
tests: Update to catch.hpp v2.13.4 and fix #2178
* tests/lib/catch.hpp: Update to v2.13.4 and initialize
sigStackSize to 32768 for now, as suggested by
https://github.com/catchorg/Catch2/issues/2178.
2021-02-11 Dodji Seketeli <dodji@redhat.com>
Don't consider type name when comparing typedefs
* include/abg-ir.h (maybe_compare_as_member_decls): Declare new
function. Make it a friend of class decl_base.
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Don't early
canonicalize typedefs because they can be "part" of a type that is
not yet completed, especially considering that class declaration
resolution is part of type building, stricto sensu.
* src/abg-ir.cc (maybe_compare_as_member_decls): Factorize this
out of ...
(equals): ... the overload for decl_base. Use it in the overload
for typedef_decl.
* tests/data/test-diff-pkg/nmap-7.70-5.el8_testjcc.x86_64-self-check-report-0.txt:
New test reference output.
* tests/data/test-diff-pkg/nmap-7.70-5.el8_testjcc.x86_64.rpm: New
binary input.
* tests/data/test-diff-pkg/nmap-debuginfo-7.70-5.el8_testjcc.x86_64.rpm: Likewise.
* tests/data/Makefile.am: Add these new testing material to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test input to
the harness.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
Adjust.
* tests/data/test-diff-suppr/test39-opaque-type-report-0.txt:
Adjust.
2021-02-10 Dodji Seketeli <dodji@redhat.com>
Use generic internal type name to canonicalize anonymous enums
* src/abg-ir.cc (has_generic_anonymous_internal_type_name) :
Define new static function.
(get_generic_anonymous_internal_type_name): Use it here.
(decl_base::get_pretty_representation): For internal purposes,
build an anonymous name that is stable.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: Adjust.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt: Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
2021-02-08 Giuliano Procida <gprocida@google.com>
abg-dwarf-reader: Fix typo in compare_dies_string_attribute_value
* src/abg-dwarf-reader.cc
(compare_dies_string_attribute_value): Typo fix.
2021-01-27 Giuliano Procida <gprocida@google.com>
abidiff: do not qualify member names in diff report
* src/abg-reporter-priv.cc (represent_data_member): Do not
qualify member names. (represent): Do not qualify member names.
* tests/data/test-abicompat/test0-fn-changed-report-0.txt: Refresh.
* tests/data/test-abicompat/test0-fn-changed-report-2.txt: Refresh.
* tests/data/test-abicompat/test5-fn-changed-report-0.txt: Refresh.
* tests/data/test-abicompat/test5-fn-changed-report-1.txt: Refresh.
* tests/data/test-abicompat/test6-var-changed-report-0.txt: Refresh.
* tests/data/test-abicompat/test6-var-changed-report-1.txt: Refresh.
* tests/data/test-abicompat/test7-fn-changed-report-0.txt: Refresh.
* tests/data/test-abicompat/test7-fn-changed-report-1.txt: Refresh.
* tests/data/test-abicompat/test7-fn-changed-report-2.txt: Refresh.
* tests/data/test-abicompat/test8-fn-changed-report-0.txt: Refresh.
* tests/data/test-abicompat/test9-fn-changed-report-0.txt: Refresh.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Refresh.
* tests/data/test-abidiff-exit/test-fun-param-report.txt: Refresh.
* tests/data/test-abidiff-exit/test-headers-dirs/test-headers-dir-report-2.txt:
Refresh.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-report.txt:
Refresh.
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt: Refresh.
* tests/data/test-abidiff-exit/test-leaf-redundant-report.txt: Refresh.
* tests/data/test-abidiff-exit/test-member-size-report0.txt: Refresh.
* tests/data/test-abidiff-exit/test-member-size-report1.txt: Refresh.
* tests/data/test-abidiff-exit/test-net-change-report0.txt: Refresh.
* tests/data/test-abidiff/test-PR18791-report0.txt: Refresh.
* tests/data/test-abidiff/test-qual-type0-report.txt: Refresh.
* tests/data/test-abidiff/test-struct0-report.txt: Refresh.
* tests/data/test-abidiff/test-struct1-report.txt: Refresh.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Refresh.
* tests/data/test-diff-dwarf/test0-report.txt: Refresh.
* tests/data/test-diff-dwarf/test1-report.txt: Refresh.
* tests/data/test-diff-dwarf/test10-report.txt: Refresh.
* tests/data/test-diff-dwarf/test11-report.txt: Refresh.
* tests/data/test-diff-dwarf/test13-report.txt: Refresh.
* tests/data/test-diff-dwarf/test21-redundant-fn-report-0.txt: Refresh.
* tests/data/test-diff-dwarf/test27-local-base-diff-report.txt:
Refresh.
* tests/data/test-diff-dwarf/test3-report.txt: Refresh.
* tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt:
Refresh.
* tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt:
Refresh.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-report-0.txt:
Refresh.
* tests/data/test-diff-dwarf/test37-union-report-0.txt: Refresh.
* tests/data/test-diff-dwarf/test38-union-report-0.txt: Refresh.
* tests/data/test-diff-dwarf/test39-union-report-0.txt: Refresh.
* tests/data/test-diff-dwarf/test4-report.txt: Refresh.
* tests/data/test-diff-dwarf/test40-report-0.txt: Refresh.
* tests/data/test-diff-dwarf/test44-anon-struct-union-report-0.txt:
Refresh.
* tests/data/test-diff-dwarf/test45-anon-dm-change-report-0.txt:
Refresh.
* tests/data/test-diff-dwarf/test46-rust-report-0.txt: Refresh.
* tests/data/test-diff-dwarf/test5-report.txt: Refresh.
* tests/data/test-diff-dwarf/test8-report.txt: Refresh.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test-PR26739-2-report-0.txt: Refresh.
* tests/data/test-diff-filter/test0-report.txt: Refresh.
* tests/data/test-diff-filter/test01-report.txt: Refresh.
* tests/data/test-diff-filter/test1-report.txt: Refresh.
* tests/data/test-diff-filter/test10-report.txt: Refresh.
* tests/data/test-diff-filter/test11-report.txt: Refresh.
* tests/data/test-diff-filter/test13-report.txt: Refresh.
* tests/data/test-diff-filter/test14-0-report.txt: Refresh.
* tests/data/test-diff-filter/test14-1-report.txt: Refresh.
* tests/data/test-diff-filter/test15-0-report.txt: Refresh.
* tests/data/test-diff-filter/test15-1-report.txt: Refresh.
* tests/data/test-diff-filter/test16-report-2.txt: Refresh.
* tests/data/test-diff-filter/test16-report.txt: Refresh.
* tests/data/test-diff-filter/test17-0-report.txt: Refresh.
* tests/data/test-diff-filter/test17-1-report.txt: Refresh.
* tests/data/test-diff-filter/test18-report.txt: Refresh.
* tests/data/test-diff-filter/test2-report.txt: Refresh.
* tests/data/test-diff-filter/test25-cyclic-type-report-0.txt: Refresh.
* tests/data/test-diff-filter/test25-cyclic-type-report-1.txt: Refresh.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-1.txt:
Refresh.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-1.txt:
Refresh.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-2.txt:
Refresh.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt:
Refresh.
* tests/data/test-diff-filter/test29-finer-redundancy-marking-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test3-report.txt: Refresh.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Refresh.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Refresh.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Refresh.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Refresh.
* tests/data/test-diff-filter/test32-ppc64le-struct-change-report0.txt:
Refresh.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test36-report-0.txt: Refresh.
* tests/data/test-diff-filter/test37-report-0.txt: Refresh.
* tests/data/test-diff-filter/test39/test39-report-0.txt: Refresh.
* tests/data/test-diff-filter/test42-leaf-report-output-0.txt: Refresh.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-0.txt:
Refresh.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-1.txt:
Refresh.
* tests/data/test-diff-filter/test9-report.txt: Refresh.
* tests/data/test-diff-pkg/GtkAda-gl-2.24.2-29.fc29.x86_64--2.24.2-30.fc30.x86_64-report-0.txt:
Refresh.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: Refresh.
* tests/data/test-diff-pkg/dirpkg-1-report-1.txt: Refresh.
* tests/data/test-diff-pkg/dirpkg-3-report-1.txt: Refresh.
* tests/data/test-diff-pkg/dirpkg-3-report-2.txt: Refresh.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Refresh.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
Refresh.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Refresh.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Refresh.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Refresh.
* tests/data/test-diff-pkg/symlink-dir-test1-report0.txt: Refresh.
* tests/data/test-diff-pkg/tarpkg-0-report-0.txt: Refresh.
* tests/data/test-diff-pkg/tarpkg-1-report-0.txt: Refresh.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Refresh.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Refresh.
* tests/data/test-diff-suppr/libtest48-soname-abixml-report-1.txt:
Refresh.
* tests/data/test-diff-suppr/test0-type-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test0-type-suppr-report-3.txt: Refresh.
* tests/data/test-diff-suppr/test0-type-suppr-report-5.txt: Refresh.
* tests/data/test-diff-suppr/test0-type-suppr-report-7.txt: Refresh.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-2.txt: Refresh.
* tests/data/test-diff-suppr/test11-add-data-member-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test12-add-data-member-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test12-add-data-member-report-2.txt:
Refresh.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-1.txt:
Refresh.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-report-1.txt:
Refresh.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-1.txt:
Refresh.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-5.txt:
Refresh.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-2.txt:
Refresh.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-5.txt:
Refresh.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-2.txt:
Refresh.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-5.txt:
Refresh.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-2.txt:
Refresh.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-5.txt:
Refresh.
* tests/data/test-diff-suppr/test2-struct-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test23-alias-filter-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test23-alias-filter-report-2.txt: Refresh.
* tests/data/test-diff-suppr/test24-soname-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test24-soname-report-10.txt: Refresh.
* tests/data/test-diff-suppr/test24-soname-report-12.txt: Refresh.
* tests/data/test-diff-suppr/test24-soname-report-14.txt: Refresh.
* tests/data/test-diff-suppr/test24-soname-report-16.txt: Refresh.
* tests/data/test-diff-suppr/test24-soname-report-4.txt: Refresh.
* tests/data/test-diff-suppr/test25-typedef-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test26-loc-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test26-loc-suppr-report-3.txt: Refresh.
* tests/data/test-diff-suppr/test29-soname-report-3.txt: Refresh.
* tests/data/test-diff-suppr/test29-soname-report-6.txt: Refresh.
* tests/data/test-diff-suppr/test29-soname-report-8.txt: Refresh.
* tests/data/test-diff-suppr/test3-struct-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test3-struct-suppr-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test3-struct-suppr-report-2.txt: Refresh.
* tests/data/test-diff-suppr/test30-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test31-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test33-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test35-leaf-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test4-local-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test4-local-suppr-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-0.txt:
Refresh.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-1.txt:
Refresh.
* tests/data/test-diff-suppr/test46-PR25128-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test46-PR25128-report-2.txt: Refresh.
* tests/data/test-diff-suppr/test47-non-reachable-types-report-1.txt:
Refresh.
* tests/data/test-diff-suppr/test47-non-reachable-types-report-2.txt:
Refresh.
* tests/data/test-diff-suppr/test47-non-reachable-types-report-4.txt:
Refresh.
* tests/data/test-diff-suppr/test47-non-reachable-types-report-7.txt:
Refresh.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt: Refresh.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt: Refresh.
* tests/data/test-diff-suppr/test5-fn-suppr-report-4.txt: Refresh.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt: Refresh.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0-1.txt: Refresh.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test6-fn-suppr-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test6-fn-suppr-report-2.txt: Refresh.
* tests/data/test-diff-suppr/test6-fn-suppr-report-3.txt: Refresh.
* tests/data/test-diff-suppr/test6-fn-suppr-report-4.txt: Refresh.
* tests/data/test-diff-suppr/test7-var-suppr-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test7-var-suppr-report-1.txt: Refresh.
* tests/data/test-diff-suppr/test7-var-suppr-report-2.txt: Refresh.
* tests/data/test-diff-suppr/test7-var-suppr-report-3.txt: Refresh.
* tests/data/test-diff-suppr/test7-var-suppr-report-4.txt: Refresh.
* tests/data/test-diff-suppr/test7-var-suppr-report-7.txt: Refresh.
* tests/data/test-diff-suppr/test7-var-suppr-report-8.txt: Refresh.
* tests/data/test-diff-suppr/test8-redundant-fn-report-0.txt: Refresh.
* tests/data/test-diff-suppr/test8-redundant-fn-report-1.txt: Refresh.
2021-02-08 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Use DW_FORM_line_strp only if it's present
* configure.ac: Define if HAS_DW_FORM_line_strp if the
DW_FORM_line_strp enumerator is present.
* src/abg-dwarf-reader.cc (form_is_DW_FORM_line_strp): Define new
static function.
(compare_dies_string_attribute_value): Use it.
2021-02-04 Dodji Seketeli <dodji@redhat.com>
Bug 27267 - Better support for opaque enum types
* src/abg-dwarf-reader.cc (get_opaque_version_of_type): Do not
quit early for enum types, because the code that comes a bit later
can handle enums. Add the newly built enum to its scope for
proper life cycle management.
* tests/data/test-diff-suppr/PR27267/include-dir-v{0,1}/include.h: New
include files for the input test library.
* tests/data/test-diff-suppr/PR27267/libtestpr27267-v{0,1}.so: New
input test library.
* tests/data/test-diff-suppr/PR27267/report-1.txt: New reference
output for the comparison.
* tests/data/test-diff-suppr/PR27267/v{0,1}.c: Source code for the
new input test library.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
above to the test harness.
2021-02-03 Dodji Seketeli <dodji@redhat.com>
Bug 27331 - Data member offset change not considered local
* src/abg-ir.cc (equals): In the overload of class_or_union, when
a data member changes without having its type change, then
consider the data change as being local.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Adjust.
* tests/data/test-diff-filter/test-PR27331-report-0.txt: New
reference output.
* tests/data/test-diff-filter/test-PR27331-v{0,1}.c: New test
source files.
* tests/data/test-diff-filter/test-PR27331-v{0,1}.o: New test
binary inputs.
* tests/data/Makefile.am: Add these new test material to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the tests above to
the harness.
2021-02-02 Dodji Seketeli <dodji@redhat.com>
Bug 27165 - Better support multi-language binaries
* src/abg-dwarf-reader.cc (get_scope_for_die): Get the language of
the DIE from the compilation unit of the DIE itself.
* tests/data/test-types-stability/PR27165-libzmq.so.5.2.3: New
test input.
* tests/data/test-types-stability/PR27165-libzmq.so.5.2.3.debug:
Debug information for the new test input.
* tests/data/Makefile.am: Add the test inputs above to the source
distribution.
* tests/test-types-stability.cc (elf_paths): Add the new test
inputs to this test harness.
2020-10-22 Dodji Seketeli <dodji@redhat.com>
Bump ABIXML format version to 2.0
* include/abg-corpus.h (corpus::init_format_version): Declare new
private method.
(corpus::set_environment): Make this non-const.
(corpus::{get,set}_format_{major,minor}_version_number): Declare
new accessors.
* src/abg-corpus.cc (corpus::init_format_version): Define new
method.
(corpus::set_environment): By default, initialize the format
version number of the corpus to the one supported by Libabigail.
(corpus::{get,set}_format_{major,minor}_version_number): Define
new accessors.
* include/abg-ir.h: Include abg-config.h to use the
abigail::config.
(environment::get_config): Declare new accessor.
* src/abg-ir.cc (environment::priv::config_): Add new data member.
(environment::get_config): Define new accessor.
* src/abg-config.cc (config::config): Bump the format
version number to "2.0".
* src/abg-corpus-priv.h
(corpus::priv::format_{major,minor}_version_number_): Add new data members.
* src/abg-reader.cc (handle_version_attribute): Define new static
function.
(read_corpus_from_input, read_corpus_group_from_input): Use it to
read the value of the "version" attribute and set the format
version number of the corpus and corpus group accordingly.
* src/abg-writer.cc (write_context::m_config): Remove the config
object because we can now get it from the environment.
(write_context::get_config): Get the config object from the
environment.
(write_translation_unit): Do not emit the version attribute on the
translation unit element anymore.
(write_version_info): Define static function.
(write_corpus, write_corpus_group): Use it to emit version
attribute on both the corpus and corpus group elements.
* tools/abidiff.cc
(emit_incomptatible_format_version_error_message): Define new
static function.
(main): Ensure that corpora and corpus groups being compared have
the same major version number.
* tests/update-test-output.py: Adjust syntax for python3.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-suppr/libtest48-soname-abixml-v0.so.abi:
Likewise.
* tests/data/test-diff-suppr/libtest48-soname-abixml-v1.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi:
Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-1.o.abi: Likewise.
* tests/data/test-read-dwarf/test-PR26568-2.o.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.hash.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test0.xml: Likewise.
* tests/data/test-read-write/test1.xml: Likewise.
* tests/data/test-read-write/test10.xml: Likewise.
* tests/data/test-read-write/test11.xml: Likewise.
* tests/data/test-read-write/test12.xml: Likewise.
* tests/data/test-read-write/test13.xml: Likewise.
* tests/data/test-read-write/test14.xml: Likewise.
* tests/data/test-read-write/test15.xml: Likewise.
* tests/data/test-read-write/test16.xml: Likewise.
* tests/data/test-read-write/test17.xml: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test19.xml: Likewise.
* tests/data/test-read-write/test2.xml: Likewise.
* tests/data/test-read-write/test20.xml: Likewise.
* tests/data/test-read-write/test21.xml: Likewise.
* tests/data/test-read-write/test22.xml: Likewise.
* tests/data/test-read-write/test23.xml: Likewise.
* tests/data/test-read-write/test24.xml: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
* tests/data/test-read-write/test26.xml: Likewise.
* tests/data/test-read-write/test27.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
* tests/data/test-read-write/test3.xml: Likewise.
* tests/data/test-read-write/test4.xml: Likewise.
* tests/data/test-read-write/test5.xml: Likewise.
* tests/data/test-read-write/test6.xml: Likewise.
* tests/data/test-read-write/test7.xml: Likewise.
* tests/data/test-read-write/test8.xml: Likewise.
* tests/data/test-read-write/test9.xml: Likewise.
2020-10-20 Dodji Seketeli <dodji@redhat.com>
Bug 26684 - Support DW_AT_data_bit_offset attribute
* src/abg-dwarf-reader.cc (read_and_convert_DW_at_bit_offset):
Define new static function.
(die_member_offset): Primarily use DW_AT_data_bit_offset if its
present. Otherwise, look for DW_AT_bit_offset. Use the new
read_and_convert_DW_at_bit_offset function to properly interpret
DW_AT_bit_offset if its present. Update comment.
* tests/data/test-diff-filter/test-PR26684-dwarf{4,5}.o: New
binary test inputs.
* tests/data/test-diff-filter/test-PR26684.c: Source code of the
new binary test inputs above.
* tests/data/test-diff-filter/test-PR26684-report-0.txt: New
reference test output.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the test inputs
above to this test harness.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Adjust.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
Adjust.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Adjust.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
2021-01-27 Dodji Seketeli <dodji@redhat.com>
Bug 27255 - fedabipkgdiff fails on nfs-utils on Fedora 33
* tools/fedabipkgdiff (RPMCollection::get_sibling_debuginfo):
Update comment.
(RPMCollection::get_matching_debuginfo): Define new function.
(generate_comparison_halves): Use
RPMCollection::get_matching_debuginfo instead of
RPMCollection::get_sibling_debuginfo.
2021-01-26 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Support fast DW_FORM_line_strp string comparison
* src/abg-dwarf-reader.cc (compare_dies_string_attribute_value):
Support DW_FORM_line_strp.
* tests/data/test-diff-pkg/sshpass-1.07-1.fc34.x86_64-self-check-report-0.txt:
New reference test output.
* tests/data/test-diff-pkg/sshpass-1.07-1.fc34.x86_64.rpm: New
test input.
* tests/data/test-diff-pkg/sshpass-debuginfo-1.07-1.fc34.x86_64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new testing material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the test input above
to this harness.
2021-01-26 Dodji Seketeli <dodji@redhat.com>
Bug 27232 - fedabipkgdiff fails on gawk from Fedora 33
* tools/abipkgdiff.cc (options::pkg{1,2}): Add new data members to
store the packages to compare and have them available for the
various functions that may need them down the road.
(package::create_abi_file_path): Add new function.
(compare_to_self): Use the new package::create_abi_file_path to
create the path to the ABI file in a directory not owned by the
package. That should increase our chances of having the rights to
write that one. Make sure to emit error message when the
comparison against self fails.
({compare_task, self_compare_task}::perform): During the process
of comparison if an internal error happens, report it. Cleanup
the existing reporting a little bit.
(pkg_extraction_task::perform): Fix comment.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64-self-report-0.txt:
Adjust.
2021-01-26 Matthias Maennich <maennich@google.com>
abipkgdiff: Address operator precedence warning
* tools/abipkgdiff.cc (compare_to_self): address clang warning.
2021-01-26 Dodji Seketeli <dodji@redhat.com>
Bug 27233 - fedabipkgdiff fails on package gnupg2 from Fedora 33
* src/abg-dwarf-reader.cc
(read_context::canonicalize_types_scheduled): Don't forget to
canonicalize types stored in extra_types_to_canonicalize_.
* src/abg-ir.cc (type_base::get_canonical_type_for): Add better
comment.
(hash_as_canonical_type_or_constant): Remove crutch that is
useless now that we canonicalize almost all types in the system.
2021-01-25 Dodji Seketeli <dodji@redhat.com>
Bug 27236 - Pointer comparison wrongly fails because of typedef change
* src/abg-ir.cc (equals): In the overloads for pointer_type_def,
reference_type_def and array_type_def, compare the pointed-to-type
modulo typedefs.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Adjust.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Adjust.
2021-01-22 Dodji Seketeli <dodji@redhat.com>
Ignore duplicated functions and those not associated with ELF symbols
* include/abg-ir.h (class_or_union::string_mem_fn_sptr_map_type):
Add a typedef for unordered_map<string, method_decl_sptr>.
(class_or_union::find_member_function_sptr): Declare new function.
* src/abg-ir.cc (class_or_union::priv::mem_fns_map_): Change the
type of this to string_mem_fn_sptr_map_type, so that shared
pointers to functions can be stored in the map, instead of bare
pointers to functions. This is useful to implement
class_or_union::find_member_function_sptr which returns a shared
pointer to function.
(class_or_union::find_member_function_sptr): Define new function.
(class_or_union::find_member_function): Adjust.
(method_decl::set_linkage_name): Use a non-deleting shared pointer
to store the current instance of member function into
class_or_union::priv::mem_fns_map_.
(hash_as_canonical_type_or_constant): As we are seeing more
function types, it appears that some function types are not
canonicalized. I am not sure why exactly, but let's loosen the
assert here for now, I'll chase the root of this later.
* src/abg-dwarf-reader.cc (finish_member_function_reading):
Improve detection of member function 'static-ness' by handling
cases where a this pointer can be const. Also support
DW_AT_object_pointer when it's present. This fixes the occurrence
of spurious change reports about loss of 'static-ness' of member
functions.
(potential_member_fn_should_be_dropped): Define new static
function and ...
(build_ir_node_from_die): ... use it here. When a function DIE
has the same linkage name as an existing function IR, do not
create a new IR for it. Rather, re-use the existing one to
complete it with the properties found on the function DIE. If a
new function doesn't seem to have an associated ELF symbol and is
not meant to be a virtual member function then drop its IR on the
floor as well.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi: Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi: Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-10.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-12.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-14.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-16.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test31-report-1.txt: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test1.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2021-01-20 Dodji Seketeli <dodji@redhat.com>
Bug 27204 - potential loss of some aliased ELF function symbols
* src/abg-ir.cc (function_decl::get_id): If the elf symbol has
aliases, make the function name be part of the ID so that this ID
differs from the one of the other functions that share a symbol
alias with this one.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-diff-pkg/glibc-2.32-3.fc33.aarch64-self-check-report-0.txt:
New test reference output.
* tests/data/test-diff-pkg/glibc-2.32-3.fc33.aarch64.rpm: New test
input RPM.
* tests/data/test-diff-pkg/glibc-debuginfo-2.32-3.fc33.aarch64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test input
RPMs to this test harness.
2020-12-15 Matthias Maennich <maennich@google.com>
abg-ir: Optimize calls to std::string::find() for a single char.
* src/abg-ir.cc (elf_symbol::get_name_and_version_from_id):
use character literal overload for single character string::find.
(parse_integral_type): Likewise.
Suggested-by: Chris Kennelly <ckennelly@google.com>
2021-01-15 Dodji Seketeli <dodji@redhat.com>
Bug 26992 - Try harder to resolve declaration-only classes
* src/abg-dwarf-reader.cc
(read_context::compare_before_canonicalisation): Define new member
function.
(read_context::resolve_declaration_only_classes): When there are
more than one definition that can resolve a given declaration, if
all those definitions are equal, then resolve the declaration to
those definitions.
(read_context::resolve_declaration_only_enums): Add a comment to
update similarly update this function (or do away with it
completely) later.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-diff-pkg/cogl-1.22.8-2.fc33.x86_64.rpm: Add new
test input.
* tests/data/test-diff-pkg/cogl-debuginfo-1.22.8-2.fc33.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/cogl-1.22.8-2.fc33.x86_64.self-check-report-0.txt:
Likewise.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test inputs
to the test harness.
* tests/data/Makefile.am: Add the new test input files to source
distribution.
2021-01-11 Dodji Seketeli <dodji@redhat.com>
mainpage: Update web page for 1.8 release
* doc/website/mainpage.txt: Update web page for 1.8 release
2020-12-14 Matthias Maennich <maennich@google.com>
Update catch2 testing framework: v1.12.2 -> v2.13.3
* tests/lib/catch.hpp: update to v2.13.3
* tests/test-symtab.cc (TEST_CASE("Symtab::SimpleSymtabs")): Use
the corpus variable to avoid unused variable warnings.
2020-12-14 Matthias Maennich <maennich@google.com>
clang-format: define C++ standard to improve formatting
* .clang-format: Set C++11 standard for formatting.
2020-12-11 Giuliano Procida <gprocida@google.com>
Refresh ABI cross check test files
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Refreshed ABI.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
File now empty.
2020-12-14 Matthias Maennich <maennich@google.com>
Drop unneccessary includes of abg-cxx-compat.h
* include/abg-comparison.h: Remove include of abg-cxx-compat.h.
* include/abg-diff-utils.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-libzip-utils.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-workers.h: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
2020-12-14 Matthias Maennich <maennich@google.com>
Remove <unordered_set> usages from abg_compat
* include/abg-cxx-compat.h: Drop compatibility for <unordered_set>.
* include/abg-comparison.h: migrate abg_compat use to std.
* include/abg-interned-str.h: Likewise.
* include/abg-suppression.h: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
2020-12-14 Matthias Maennich <maennich@google.com>
Remove <unordered_map> usages from abg_compat
* include/abg-cxx-compat.h: Drop compatibility layer for <unordered_map>.
* include/abg-comparison.h: migrate abg_compat use to std.
* include/abg-cxx-compat.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-ir.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-writer.cc: Likewise.
2020-12-14 Matthias Maennich <maennich@google.com>
Remove <memory> usages from abg_compat
* include/abg-cxx-compat.h: Drop compatibility layer for <memory>.
* include/abg-diff-utils.h: migrate abg_compat use to std.
* include/abg-fwd.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-libzip-utils.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-workers.h: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-write-read-archive.cc: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
2020-12-14 Matthias Maennich <maennich@google.com>
Remove <functional> usages from abg_compat
* include/abg-cxx-compat.h: Drop compatibility layer for <functional>.
* include/abg-interned-str.h: migrate abg_compat use to std.
* include/abg-ir.h: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ir.cc: Likewise.
2020-12-14 Matthias Maennich <maennich@google.com>
Drop C++03 compatibility layer
* include/abg-cxx-compat.h: remove compatibility with pre C++11.
* include/abg-ir.h: Remove mention of std::tr1 from comments.
* include/abg-sptr-utils.h: Likewise.
2020-12-04 Giuliano Procida <gprocida@google.com>
Add qualifier / typedef / array / pointer test
* tests/data/Makefile.am: Add new test files
* tests/data/test-abidiff-exit/qualifier-typedef-array-v0.c:
New test file.
* tests/data/test-abidiff-exit/qualifier-typedef-array-v0.o:
New test file.
* tests/data/test-abidiff-exit/qualifier-typedef-array-v1.c:
New test file.
* tests/data/test-abidiff-exit/qualifier-typedef-array-v1.o:
New test file.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-0.txt:
Plain diff report.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-1.txt:
Harmless diff report.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-2.txt:
Leaf changes report.
* tests/data/test-abidiff-exit/qualifier-typedef-array-report-3.txt:
Harmless leaf changes report.
* tests/test-abidiff-exit.cc: Run new test.
2020-12-03 Giuliano Procida <gprocida@google.com>
ir: Arrays are indirect types for type structure similarity purposes
* src/abg-ir.cc (types_have_similar_structure): When examining
array types, always treat element types as being underlying types
of an indirect type.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-non-leaf-array-report.txt:
New test case showing correct --leaf-changes-only reporting.
* tests/data/test-abidiff-exit/test-non-leaf-array-v0.c:
Likewise.
* tests/data/test-abidiff-exit/test-non-leaf-array-v0.o:
Likewise.
* tests/data/test-abidiff-exit/test-non-leaf-array-v1.c:
Likewise.
* tests/data/test-abidiff-exit/test-non-leaf-array-v1.o:
Likewise.
* tests/test-abidiff-exit.cc: Run new test case.
2020-12-04 Dodji Seketeli <dodji@redhat.com>
ir: Add better comments to types_have_similar_structure
* src/abg-ir.cc (types_have_similar_structure): Arrays are also
indirect types, just like pointers and references, for the purpose
of the concept of "type similarity". Add that to the introductory
comment of the function. Add some more misc comments throughout
the code base.
2020-12-03 Giuliano Procida <gprocida@google.com>
abidiff: support --dump-diff-tree with --leaf-changes-only
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
corpus_diff override, conclude by calling
maybe_dump_diff_tree.
2020-12-03 Dodji Seketeli <dodji@redhat.com>
Use C++11 for the code base
* CONTRIBUTING: Enact use of c++11. Also, we favor those who
read/debug/maintain the code as opposed to those who write it ;-)
* configure.ac: Switch to c++11 unconditionally.
* src/Makefile.am: Adjust.
* tests/Makefile.am: Adjust.
2020-12-03 Dodji Seketeli <dodji@redhat.com>
CONTRIBUTING: Update instructions about regression tests
* CONTRIBUTING: Update instructions about how to launch regression
tests.
2020-12-02 Dodji Seketeli <dodji@redhat.com>
Teach Automake that COPYING* files are gone from sources
* Makefile.am: Teach Automake that COPYING* files are gone and
that LICENSE.txt and license-change-2020.txt were added.
2020-06-09 Dodji Seketeli <dodji@redhat.com>
Add a license-change-2020.txt file
* license-change-2020.txt: New file.
2020-06-09 Dodji Seketeli <dodji@redhat.com>
Delete COPYING* files
* COPYING: Delete.
* COPYING-GPLV3: Likewise.
* COPYING-LGPLV2: Likewise.
* COPYING-LGPLV3: Likewise.
2020-06-09 Dodji Seketeli <dodji@redhat.com>
Add the LICENSE.txt file
* LICENSE.txt: New file coming from
http://llvm.org/foundation/relicensing/LICENSE.txt.
2020-05-29 Dodji Seketeli <dodji@redhat.com>
Re-license the project to Apache v2 With LLVM Exception
* abigail.m4: Change the SPDX identifier from "GPL-3.0-or-later
WITH GCC-exception-3.1" to "Apache-2.0 WITH LLVM-exception"
* include/abg-cxx-compat.h: Change the SPDX identifier from
"LGPL-2.0-or-later" to "Apache-2.0 WITH LLVM-exception".
* .clang-format: Change the SPDX identifier from
"LGPL-3.0-or-later" to "Apache-2.0 WITH LLVM-exception".
* Makefile.am: Likewise.
* bash-completion/Makefile.am: Likewise.
* bash-completion/abicompat: Likewise.
* bash-completion/abidiff: Likewise.
* bash-completion/abidw: Likewise.
* bash-completion/abilint: Likewise.
* bash-completion/abinilint: Likewise.
* bash-completion/abipkgdiff: Likewise.
* bash-completion/abisym: Likewise.
* bash-completion/fedabipkgdiff: Likewise.
* configure.ac: Likewise.
* default.abignore: Likewise.
* doc/Makefile.am: Likewise.
* doc/api/libabigail.doxy: Likewise.
* doc/manuals/Makefile.am: Likewise.
* doc/website/libabigail-website.doxy: Likewise.
* include/Makefile.am: Likewise.
* include/abg-comp-filter.h: Likewise.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-libzip-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-version.h.in: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* scripts/dot_to_png.sh: Likewise.
* scripts/dot_to_svg.sh: Likewise.
* scripts/make-verbose.sh: Likewise.
* scripts/svg_to_plain_svg.sh: Likewise.
* scripts/svg_to_png_and_pdf.sh: Likewise.
* src/Makefile.am: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-elf-helpers.cc: Likewise.
* src/abg-elf-helpers.h: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-libzip-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-regex.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/Makefile.am: Likewise.
* tests/data/Makefile.am: Likewise.
* tests/lib/catch.cc: Likewise.
* tests/mockfedabipkgdiff.in: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/runtestcanonicalizetypes.sh.in: Likewise.
* tests/runtestdefaultsupprs.py.in: Likewise.
* tests/runtestdefaultsupprspy3.sh.in: Likewise.
* tests/runtestfedabipkgdiff.py.in: Likewise.
* tests/runtestfedabipkgdiffpy3.sh.in: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-annotate.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-cxx-compat.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-dot.cc: Change the SPDX identifier from
"GPL-3.0-or-later WITH GCC-exception-3.1" to "Apache-2.0 WITH
LLVM-exception"
* tests/test-elf-helpers.cc: Change the SPDX identifier from
"LGPL-3.0-or-later" to "Apache-2.0 WITH LLVM-exception"
* tests/test-ini.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-kmi-whitelist.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-svg.cc: Change the SPDX identifier from
"GPL-3.0-or-later WITH GCC-exception-3.1" to "Apache-2.0 WITH
LLVM-exception".
* tests/test-symtab.cc: Change the SPDX identifier from
"LGPL-3.0-or-later" to "Apache-2.0 WITH LLVM-exception"
* tests/test-tools-utils.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tests/test-write-read-archive.cc: Likewise.
* tests/update-test-output.py: Likewise.
* tools/Makefile.am: Likewise.
* tools/abiar.cc: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/fedabipkgdiff: Likewise.
* tools/kmidiff.cc: Likewise.
* update-copyright.sh: Likewise.
2020-05-29 Dodji Seketeli <dodji@redhat.com>
Add helper files to perform the re-licensing
* relicensing-scripts/file-licenses.orig.txt: New file that
contains the raw set of files with SPDX identifiers denoting
LGPLv3+ files. It's the result of a simple command based on
"find" and "grep".
* relicensing-scripts/files-with-lgplv3.txt: New file
containing the same data as the file above, but massaged to be
easily useable by the script below.
* relicensing-scripts/do-relicensing.sh: This is a simple command
which performs the re-licensing on the files listed in the file
above.
2020-05-29 Dodji Seketeli <dodji@redhat.com>
Add replace-spdx-license.sh script
* relicensing-scripts/replace-spdx-license.sh: New script.
2020-05-27 Dodji Seketeli <dodji@redhat.com>
Add has-spdx-header.sh script
* relicensing-scripts/has-spdx-header.sh: New script.
2020-05-29 Dodji Seketeli <dodji@redhat.com>
Add missing SPDX headers to source files not specifying any license
* Makefile.am: Add a LGPL-3.0-or-later SPDX header prefixed
with '##' so that that the header doesn't get emitted in the
resulting Makefile.in file. Note that the license of Makefile.in
files is "FSF All Permissible License", which virtually compatible
with anything.
* bash-completion/Makefile.am: Likewise.
* doc/Makefile.am: Likewise
* doc/manuals/Makefile.am: Likewise
* include/Makefile.am: Likewise
* src/Makefile.am: Likewise
* tests/Makefile.am: Likewise
* tests/data/Makefile.am: Likewise
* tools/Makefile.am: Likewise
* .clang-format: Add a LGPL-3.0-or-later SPDX header.
* bash-completion/abicompat: Likewise.
* bash-completion/abidiff: Likewise.
* bash-completion/abidw: Likewise.
* bash-completion/abilint: Likewise.
* bash-completion/abinilint: Likewise.
* bash-completion/abipkgdiff: Likewise.
* bash-completion/abisym: Likewise.
* bash-completion/fedabipkgdiff: Likewise.
* configure.ac: Likewise.
* default.abignore: Likewise.
* doc/api/libabigail.doxy: Likewise.
* doc/website/libabigail-website.doxy: Likewise.
* include/abg-version.h.in: Likewise.
* scripts/dot_to_png.sh: Likewise.
* scripts/dot_to_svg.sh: Likewise.
* scripts/make-verbose.sh: Likewise.
* scripts/svg_to_plain_svg.sh: Likewise.
* scripts/svg_to_png_and_pdf.sh: Likewise.
* tests/runtestcanonicalizetypes.sh.in: Likewise.
* tests/runtestdefaultsupprs.py.in: Likewise.
* tests/runtestdefaultsupprspy3.sh.in: Likewise.
* tests/runtestfedabipkgdiffpy3.sh.in: Likewise.
* tests/update-test-output.py: Likewise.
* update-copyright.sh: Likewise.
2020-03-07 Matthias Maennich <maennich@google.com>
Replace individual license references with SPDX Identifiers
* abigail.m4: Replace the license header with the SPDX identifier
GPL-3.0-or-later WITH GCC-exception-3.1
* autoconf-archive/ax_check_python_modules.m4: Correctly set the
SPDX identifier to FSFAP.
* autoconf-archive/ax_compare_version.m4: Replace the license
header with the SPDX identifier FSFAP.
* autoconf-archive/ax_prog_python_version.m4: Likewise.
header with the SPDX identifier FSFAP.
* autoconf-archive/ax_valgrind_check.m4: Likewise.
* gen-changelog.py: Replace the license header with the SPDX
identifier LGPL-2.0-or-later.
* include/abg-comp-filter.h: Replace the license header with the
SPDX identifier LGPL-3.0-or-later.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-cxx-compat.h: Replace the license header with the
SPDX identifier LGPL-2.0-or-later.
* include/abg-diff-utils.h: Replace the license header with the
SPDX identifier LGPL-3.0-or-later
* include/abg-dwarf-reader.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-libzip-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-regex.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* install-sh: Replace the license header with the SPDX identifier MIT.
* ltmain.sh: Replace the license header with the SPDX identifier
GPL-2.0-or-later. Note that this file has the libtool special
exception which allows us to redistribute it under the general
license of the project.
* src/abg-comp-filter.cc: Replace the license header with the SPDX
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-elf-helpers.cc: Likewise.
* src/abg-elf-helpers.h: Likewise.
* src/abg-regex.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-libzip-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-sptr-utils.cc: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/lib/catch.cc: Likewise.
* tests/lib/catch.hpp: Add an SPDX identifier BSL-1.0.
* tests/mockfedabipkgdiff.in: Replace the license header with the
SPDX identifier GPL-3.0-or-later.
* tests/print-diff-tree.cc: Likewise.
* tests/runtestfedabipkgdiff.py.in: Replaace the license header
with the SPDW identifier GPL-3.0-or-later.
* tests/test-abicompat.cc: Replace the license header with the
SPDX identifier LGPL-3.0-or-later.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-annotate.cc: Likewise.
* tests/test-cxx-compat.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-dot.cc: Replace the license header with the
SPDX identifier GPL-3.0-with-GCC-exception.
* tests/test-elf-helpers.cc: Replace the license header with the
SPDX identifier LGPL-3.0-or-later.
* tests/test-ini.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-kmi-whitelist.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-svg.cc: Replace the license header with the SPDX
identifier GPL-3.0-with-GCC-exception.
* tests/test-symtab.cc: Replace the license header with the SPDX
identifier LGPL-3.0-or-later.
* tests/test-tools-utils.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tests/test-write-read-archive.cc: Likewise.
* tools/abiar.cc: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/fedabipkgdiff: Replace the license header with the
SPDX identifier GPL-3.0-or-later.
* tools/kmidiff.cc: Likewise.
2020-12-01 Dodji Seketeli <dodji@redhat.com>
Bump version number to 2.0
* configure.ac: Bump number version to 2.0
2020-12-01 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.8
* NEWS: Update for 1.8
2020-12-01 Dodji Seketeli <dodji@redhat.com>
Update the Changelog for 1.8
* Changelog: Update automatically with "make update-changelog'
2020-12-01 Dodji Seketeli <dodji@redhat.com>
Add check-self-compare to release regression testing
* Makefile.am: Make 'make tarball-and-all' run the
'check-self-compare' target as part of the release process.
2020-12-01 Dodji Seketeli <dodji@redhat.com>
configure: add --enable-rpm415 option
* configure: Introduce the --{en, dis}able-rpm415 option.
2020-11-30 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Bug 26908 - don't crash on empty DW_TAG_partial_unit
* src/abg-dwarf-reader.cc (die_has_children): Define new static
function.
(read_context::build_die_parent_relations_under): Do not try to
instantiate an imported_unit_point type for an imported unit with
no children node.
(imported_unit_point::imported_unit_point): Assert that the
imported die has a sub-tree.
(imported_unit_point::imported_unit_point): Remove useless spaces.
2020-11-27 Dodji Seketeli <dodji@redhat.com>
reader: Fix off-by-one error in assert
* src/abg-reader.cc (build_subrange_type): Fix off-by-one error.
2020-11-27 Dodji Seketeli <dodji@redhat.com>
writer: fix off-by-one error in assertion
* src/abg-writer.cc (write_array_subrange_type): Fix off-by-one
error in assertion.
* src/abg-dwarf-reader.cc (build_subrange_type): Assert the length
of the array complies with its bounds.
2020-11-27 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: make --self-check to fail on any change against own ABIXML
* tools/abipkgdiff.cc (compare_to_self): Report *any* ABI change.
Not just the "net" changes.
2020-11-26 Dodji Seketeli <dodji@redhat.com>
abidw: make --abidiff report any change against own ABIXML
* tools/abidw.cc (load_corpus_and_write_abixml): Emit an error
when comparing the binary to its ABIXML representation yields any
change.
2020-11-27 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Avoid having several functions with the same symbol
* src/abg-dwarf-reader.cc
(read_context::symbol_already_belongs_to_a_function): Define new
member function.
(read_context::fixup_functions_with_no_symbols): Use the new
symbol_already_belongs_to_a_function function to avoid setting a
symbol that already belongs to a function.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2020-11-27 Dodji Seketeli <dodji@redhat.com>
reader: Don't lose anonymous-ness of decl-only classes
* src/abg-reader.cc (build_class_decl): Set the is-anonymous flag
when reading a decl-only class.
2020-11-27 Dodji Seketeli <dodji@redhat.com>
ir: Introduce internal pretty representation for anonymous classes
* include/abg-fwd.h (get_class_or_union_flat_representation):
Introduce an "internal" parameter.
* src/abg-ir.cc (get_class_or_union_flat_representation):
Introduce an "internal" parameter. In the flat representation of
a class for internal purposes, always use the prefix "class" even
if this is a struct.
(get_type_name): To build an internal name for a
reference or pointer to an anonymous type, consider the namespace
name of said type.
(equals): In the overload for decl_base, take the namespace name
of anonymous decls into account when comparing them.
({var_decl, union_decl}::get_pretty_representation): Adjust calls
to get_class_or_union_flat_representation to pass a proper
"internal" argument.
* src/abg-default-reporter.cc (default_reporter::report): Adjust
the call to get_class_or_union_flat_representation to pass an
"internal" argument set to 'false'.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
2020-11-26 Dodji Seketeli <dodji@redhat.com>
writer: Emit definitions of declarations when they are present
* src/abg-writer.cc (write_class_decl, write_union_decl): Get the
definition of the declaration if it exists and emit that.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
2020-11-26 Dodji Seketeli <dodji@redhat.com>
Bug 26780 - Fix array subrange bounds (de)serialization
* src/abg-reader.cc (build_subrange_type): Read lower-bound
attribute if present. Then try to read upper-bound attribute as
well. If this is not an infinite subrange assert that the length
must be equal to the difference between the bounds.
* src/abg-writer.cc (write_array_subrange_type): Write the
lower-bound if it's present and not zero. In that case, write the
upper-bound as well.
* tests/data/test-diff-pkg/hdf5-1.10.6-2.fc33.x86_64.rpm: Add new
binary test input.
* tests/data/test-diff-pkg/hdf5-debuginfo-1.10.6-2.fc33.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/hdf5-1.10.6-2.fc33.x86_64.self-check-report-0.txt:
Add new reference output.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the binary test input
to the set of --self-check tests.
2020-11-26 Dodji Seketeli <dodji@redhat.com>
reader: Read array subrange length into an uint64_t
* src/abg-reader.cc (build_subrange_type): Change the type of
length to uint64_t and read it using strtoull.
2020-11-25 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Avoid uncertainty when sorting worker tasks
* elf_size_is_greater: Take the name of the binaries into account
when their size is equal. Also, assert that all comparison tasks
have compared binaries.
2020-11-25 Dodji Seketeli <dodji@redhat.com>
tests/data/test-fedabipkgdiff: Update reference output
* tests/data/test-fedabipkgdiff/test7-self-compare-from-fc23-dbus-glib-report-0.txt:
Adjust.
2020-11-24 Matthias Maennich <maennich@google.com>
abipkgdiff: minor cleanups
* tools/abipkgdiff.cc: remove unused using statements
(self_compare_task): remove shadowing members and delegate
construction to base class.
2020-11-23 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: support artificially generated translation units
* configure.ac: Detect if we are running on RPM >= 4.15. If yes,
then define the preprocessor macro RPM_4_15. If that macro is
defined then test-diff-pkg.cc can support RPMs from Fedora >= 31
as those are compressed with zstd. Earlier RPM versions don't
support that compression scheme.
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir):
Suffix the offset of the translation unit to its name when that
name is "<artificial>".
* tests/data/test-diff-pkg/mesa-libGLU-9.0.1-3.fc33.x86_64.rpm:
New binary test input.
* tests/data/test-diff-pkg/mesa-libGLU-debuginfo-9.0.1-3.fc33.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/mesa-libGLU-9.0.1-3.fc33.x86_64.self-check-report-0.txt:
New reference output for the binary test input above.
* tests/data/Makefile.am: Add the new test inputs above to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the binary test
inputs above to source distribution if we are running on an RPM
version >= 4.15.
2020-11-20 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff: make --self-compare use abipkgdiff --self-check
* tools/fedabipkgdiff (abipkgdiff): If the user provides the
--self-compare options, generate the abipkgdiff command by using
the --self-check option.
(run_abipkgdiff): Each return value of the abipkgidiff runs can be
negative because they are unsigned values in essence, but as
python doesn't seem to have a unsigned integer type. So we need
to consider the max of the absolute value of the return codes
here.
* tests/data/test-fedabipkgdiff/test7-self-compare-from-fc23-dbus-glib-report-0.txt:
Adjust.
2020-11-19 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Add a new --self-check option
* tools/abipkgdiff.cc (options::self_check): Define new data
member.
(options::options): Initialize it.
(display_usage): Add help string for the --self-check option.
(parse_command): Parse the new --self-check option.
(extract_deb): Add missing newline.
(compare): Remove useless white space.
(compare_to_self, self_compare_prepared_userspace_package)
(self_compare_prepared_package, compare_to_self): Add new static
functions.
(class self_compare_task): Add new class.
(prepare_package): Add a new overload that takes just one
parameter.
(elf_size_is_greater): Don't crash if the args are empty.
(main): If the --self-check option is given, make sure we have
just one package in argument. Use the new compare_to_self
function to handle the --self-check option.
* doc/manuals/abipkgdiff.rst: Add documentation for the new
--self-check option.
2020-11-16 Dodji Seketeli <dodji@redhat.com>
Bug 26769 - Fix missing types in abixml output
* include/abg-corpus.h (corpus::{record_canonical_type,
lookup_canonical_type}): Remove function declarations.
* src/abg-corpus-priv.h (corpus::priv::canonical_types_): Remove
data member.
* src/abg-corpus.cc (corpus::{record_canonical_type,
lookup_canonical_type}): Remove functions.
* src/abg-ir.cc (type_eligible_for_odr_based_comparison): Remove
static function.
(type_base::get_canonical_type_for): Don't perform the ODR-based
optimization for C++ anymore.
* src/abg-reader.cc
(read_context&::maybe_add_var_to_exported_decls): Don't add a
variable that hasn't been added to its scope. Otherwise, it means
we added a variable that wasn't yet properly constructed. Also
add a new overload for var_decl_sptr&.
(build_var_decl): Do not add the var to its the set of exported
declaration before we are sure it has been fully constructed and
added to the scope it belongs.
(build_class_decl): Only add *static* data members to the list of
exported declarations.
(handle_var_decl): A var decl seen here is a global variable
declaration. Add it to the list of exported declarations.
* src/abg-writer.cc (write_context::decl_only_type_is_emitted):
Constify parameter.
(write_translation_unit): Do not forget to emit referenced types
that were maybe not canonicalized. Also, avoid using noop_deleter
when it's not necessary.
(write_namespace_decl): Do not forget to emit canonicalized types
that are present in namespaces other than the global namespace.
* tests/runtestslowselfcompare.sh.in: New test that compares
libabigail.so against its own ABIXML representation.
* tests/Makefile.am: Add the new test runtestslowselfcompare.sh to
source distribution. This test is too slow to be run during the
course of 'make check'. It takes more than 5 minutes on my slow
box here. Rather, it can be run using 'make check-self-compare'.
I plan to run this before releases now.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
* tests/data/test-read-write/test6.xml: Likewise.
2020-11-13 Dodji Seketeli <dodji@redhat.com>
Make sure to canonicalize all types but decl-only classes
* include/abg-fwd.h (is_declaration_only_class_or_union_type):
Declare new ...
* src/abg-ir.cc (is_declaration_only_class_or_union_type):
... function.
(clone_array): Add the cloned array subrange to
its scope so that it can later be canonicalized.
(synthesize_type_from_translation_unit)
(synthesize_function_type_from_translation_unit): Canonicalize the
synthesized types.
(hash_as_canonical_type_or_constant): Ensure that all types are
canonicalized.
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Remove
useless overload.
(build_ir_node_for_variadic_parameter_type)
(schedule_array_tree_for_late_canonicalization): Define new static
functions.
(maybe_strip_qualification): Schedule type canonicalization for
types cloned prior to editing.
(build_function_type): Use the new
build_ir_node_for_variadic_parameter_type. It takes care of
canonicalizing variadic parameter types.
(build_function_decl): Canonicalize the function type that is
created here.
(build_ir_node_from_die): Use the overload of
maybe_canonicalize_type which canonicalizes class_or_union nodes
directly, rather than the one which handles DIE offsets. The
latter was used as an optimization to reduce the size of the array
of types scheduled for canonicalization, as DIE offsets take less
space than pointers to IR types. Now that we have DIE
de-duplication, my bet is that we can do away with the former.
And that also ensures that we miss no type for canonicalization
purposes.
* src/abg-reader.cc (build_array_type_def): Canonicalize the
subrange types of the array.
(build_type): Canonicalize all types.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2020-11-13 Dodji Seketeli <dodji@redhat.com>
ir: Add equality op to array_type_def::subrange_type::bound_value
* include/abg-ir.h
(array_type_def::subrange_type::bound_value::operator==): Declare
new ...
* src/abg-ir.cc
(array_type_def::subrange_type::bound_value::operator==):
... equality operator.
2020-11-12 Dodji Seketeli <dodji@redhat.com>
writer: Sort decls and fix topological sorting for types
* include/abg-ir.h (scope_decl::get_sorted_member_decls): Declare
new member function.
* src/abg-ir.cc (struct decl_topo_comp): New sorting functor.
(type_topo_comp::operator()): Re-use the decl_topo_comp to sort
type declarations.
(scope_decl::priv::sorted_members_): Add new data member.
(scope_decl::get_sorted_member_decls): Define new member function.
* src/abg-writer.cc (write_translation_unit): Use the new
scope_decl::get_sorted_member_decls.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-write/test2.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
2020-10-27 Dodji Seketeli <dodji@redhat.com>
Bug PR26739 - Handle qualified typedef array types
* include/abg-fwd.h (is_typedef_of_array, clone_array)
(clone_typedef, clone_qualified_type, clone_array_tree): Declare
new functions.
(peel_qualified_or_typedef_type): Declare new overload.
(is_array_of_qualified_element): Constify the parameter.
* include/abg-ir.h ({qualified_type,
typedef}_def::set_underlying_type): Add new member functions.
(array_type_def::subrange_type::subrange_type): Make constify the
reference to the underlying type parameter.
* src/abg-ir.cc (is_array_of_qualified_element): Constify the
parameter.
(peel_qualified_or_typedef_type): Define new
overload for type_base_sptr.
(clone_typedef_array_qualified_type): Define static function.
(clone_array clone_typedef, clone_qualified_type)
(clone_array_tree, is_typedef_of_array): Define new functions.
(qualified_type_def::get_underlying_type): Rename the return type
shared_ptr<type_base> into type_base_sptr.
({typedef, qualified_type}_def::set_underlying_type): Define new
member function.
(array_type_def::subrange_type::priv::priv): Initialize the
'infinite_' data member.
* src/abg-dwarf-reader.cc (maybe_strip_qualification): Handle
qualified typedef of arrays. Merge this with the handling of
qualified arrays. Note that before editing the elements of the
array to make the array (or typedef) qualifier apply to the
element the sub-tree is cloned to make its type nodes be
'un-shared'. This prevents us from editing type nodes that are
shared by other type expressions.
* tests/data/test-diff-filter/test-PR26739-report-0.txt: New
reference test output.
* tests/data/test-diff-filter/test-PR26739-2-report-0.txt: Likewise.
* tests/data/test-diff-filter/test-PR26739-v{0,1}.c: Source code
of new binary test input.
* tests/data/test-diff-filter/test-PR26739-2-v{0,1}.c: Likewise.
* tests/data/test-diff-filter/test-PR26739-v{0,1}.o: New binary
test inputs.
* tests/data/test-diff-filter/test-PR26739-2-v{0,1}.o: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the test inputs
above to this harness.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
2020-11-03 Dodji Seketeli <dodji@redhat.com>
Update test-libandroid.so.abi
* tests/data/test-read-dwarf/test-libandroid.so.abi: Update.
2020-10-29 Matthias Maennich <maennich@google.com>
dwarf-reader: Ignore zero length location expressions from DW_AT_location
* src/abg-dwarf-reader.cc (die_location_expr): Ignore zero
length location expressions.
* tests/data/Makefile.am: Add new test files.
* tests/data/test-read-dwarf/test-libandroid.so: New test file.
* tests/data/test-read-dwarf/test-libandroid.so.abi: Likewise.
* tests/test-read-dwarf.cc: Add new test case.
Reported-by: Dan Albert <danalbert@google.com>
Reviewed-by: Giuliano Procida <gprocida@google.com>
Cc: Mark Wielaard <mark@klomp.org>
2020-10-29 Giuliano Procida <gprocida@google.com>
Improve enum synthetic type names
* src/abg-dwarf-reader.cc
(build_internal_underlying_enum_type_name): Add a size
argument (and don't default is_anonymous argument). Append
size of type to synthetic type name.
(build_enum_underlying_type): Pass type size to
build_internal_underlying_enum_type_name.
* tests/data/test-abidiff-exit/test-decl-enum-report-3.txt:
Update. Note that there may be an issue with leaf-mode
reporting of pointer type changes.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Regenerate this (catching up with various abidw updates).
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Refresh with new type names.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test0.hash.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2020-10-29 Giuliano Procida <gprocida@google.com>
Improve and stabilise sort of member functions
* src/abg-ir.cc
(virtual_member_function_less_than::operator()): Name
temporaries like offsets and symbols to reduce repetition;
test each pair of elements (including symbol presence) and
return immediately if there's a difference; add a comparison
of linkage name just after comparing symbol names.
(sort_virtual_member_functions): Use stable_sort instead of
sort.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Update with new ordering of member functions.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2020-11-01 Dodji Seketeli <dodji@redhat.com>
update-test-output.py: Update syntax
* tests/update-test-output.py: Update syntax for python3.
2020-10-31 Dodji Seketeli <dodji@redhat.com>
Bug 26770 - Spurious declaration-only-ness induces spurious type changes
* src/abg-dwarf-reader.cc (add_or_update_class_type): When
creating a class, set declaration-only-ness unconditionally. When
updating the class however, only set the declaration-only-ness
when the current one is not consistent with the size of the class.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
2020-10-21 Matthias Maennich <maennich@google.com>
dwarf-reader: fix lookup for repeated translation unit paths
* src/abg-dwarf-reader.cc(build_translation_unit_and_add_to_ir):
Fix lookup for potentially already existing translation units.
Reported-by: Dan Albert <danalbert@google.com>
2020-10-21 Giuliano Procida <gprocida@google.com>
Stabilise sort of canonical types
* src/abg-ir.cc (scope_decl::get_sorted_canonical_types): Sort
canonical types with std::stable_sort(..., type_topo_comp()).
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-10-27 Mark Wielaard <mark@klomp.org>
Assume subrange bounds types are unsigned if no underlying type is given.
* src/abg-dwarf-reader.cc (build_subrange_type): Default
is_signed to false.
2020-10-23 Mark Wielaard <mark@klomp.org>
dwarf-reader: get subrange_type bounds signedness from underlying type
* src/abg-dwarf-reader.cc (die_attribute_has_form)
(die_attribute_is_signed, die_attribute_is_unsigned)
(die_attribute_has_no_signedness): Remove static functions.
(die_constant_attribute): Add the 'is_signed' parameter.
(die_address_attribute): Adjust comment.
(build_subrange_type): Determine signedness of the bounds by
looking at the DW_AT_encoding attribute of the underlying type.
2020-10-23 Dodji Seketeli <dodji@redhat.com>
abg-tools-utils: Fix comment
* include/abg-tools-utils.h (enum abidiff_status): Fix a comment.
2020-10-13 Dodji Seketeli <dodji@redhat.com>
configure: Support ABIGAIL_NO_OPTIMIZATION_DEBUG environment variable
* configure.ac: Set the CXXFLAGS and CFLAGS to "-g -O0 -Wall
-Wextra -Werror" if the ABIGAIL_NO_OPTIMIZATION_DEBUG is set.
2020-10-13 Dodji Seketeli <dodji@redhat.com>
Structurally compare the few non-canonicalized types in general
* include/abg-fwd.h (hash_as_canonical_type_or_constant): Remove
public declaration of this function.
* src/abg-hash.cc (type_base::dynamic_hash::operator()): Add a
comment.
* src/abg-ir.cc (hash_as_canonical_type_or_constant): Make this
function static now.
(hash_type_or_decl): Use hash_type for types.
* src/abg-writer.cc (type_hasher::operator()): Use hash_type.
2020-10-12 Dodji Seketeli <dodji@redhat.com>
Fix redundancy detection in the diff graph
* src/abg-comparison-priv.h
(diff_context::priv::last_visited_diff_node_): Remove unnecessary
data member.
(class_or_union_diff::priv::sorted_{deleted,inserted}_member_functions_):
Add new data members.
(sort_string_member_function_sptr_map): Declare new function.
* src/abg-comparison.cc (sort_string_member_function_sptr_map):
Define new function.
(redundancy_marking_visitor::visit_begin): If the current diff
node is equivalent to another one that has been already marked
redundant, then consider the current diff node as redundant as
well. Considering the fact an ancestor node has been filtered out
is now useless because if that's the case then the current
descendant node wouldn't even be walked at reporting time. So
remove the call to diff_has_ancestor_filtered_out.
(categorize_redundancy): Remove useless call here as well.
(diff_has_ancestor_filtered_out, diff_has_ancestor_filtered_out)
(diff_context::{mark_last_diff_visited_per_class_of_equivalence,
clear_last_diffs_visited_per_class_of_equivalence,
get_last_visited_diff_of_class_of_equivalence}): Remove
unnecessary functions.
(redundancy_marking_visitor::visit_end): Add comment.
(class_diff::ensure_lookup_tables_populated): Lexicographically
sort inserted/deleted member functions.
(class_or_union_diff::chain_into_hierarchy): Chain changed data
members diff nodes in a sorted manner.
* src/abg-default-reporter.cc (default_reporter::report): Report
deleted/inserted member functions in lexicographic order.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
2020-10-08 Dodji Seketeli <dodji@redhat.com>
Consider the implicit 'this' parameter when comparing methods
* include/abg-ir.h (function_type::get_first_parm): Declare new
accessor.
* src/abg-ir.cc (function_type::get_first_parm): Define new
accessor.
(equals): In the overload for function_type,
always take the implicit "this" parameter into account in
parameter comparisons.
(function_type::get_first_non_implicit_parm): Adjust comment.
* src/abg-comp-filter.cc (function_name_changed_but_not_symbol):
Avoid potential NULL pointer dereferencing.
* src/abg-comparison.cc
(function_type_diff::ensure_lookup_tables_populated): Always take
the changes to the implicit 'this' parameter into account in the
function type diff.
(compute_diff): In the overload for function_type, Always compare
the implicit 'this' parameter when comparing function parameters.
* src/abg-default-reporter.cc (default_reporter::report): Refer to
"implicit parameter" when reporting changes on parameters
artificially generated by the compiler.
* src/abg-suppression.cc (type_suppression::suppresses_diff): Make
the 'access_through' predicate work on a qualified version of type
'S', even if it was meant to work on type 'S'. This allows it to
work on 'const S', especially when S is accessed through 'pointer
to const S', which happens when we consider the implicit 'this'
parameter of a const member function.
* tests/data/test-abicompat/test5-fn-changed-report-0.txt: Adjust.
* tests/data/test-abicompat/test5-fn-changed-report-1.txt: Likewise.
* tests/data/test-abidiff-exit/test1-voffset-change-report0.txt:
Likewise.
* tests/data/test-abidiff/test-PR18791-report0.txt: Likewise.
* tests/data/test-abidiff/test-struct1-report.txt: Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test29-vtable-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt: Likewise.
* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test4-report.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-10.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-11.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-12.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-13.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-14.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-15.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-16.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-8.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-9.txt: Likewise.
* tests/data/test-diff-suppr/test31-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test33-report-0.txt: Likewise.
2020-08-17 Giuliano Procida <gprocida@google.com>
Fix two wrongs in test suppression regex
* tests/data/test-diff-suppr/test38-char-class-in-ini.abignore:
Don't anchor regex match to beginning of file name.
Change "filename_regexp" to "file_name_regexp".
2020-08-17 Giuliano Procida <gprocida@google.com>
Add missing newlines to end of test files.
* tests/data/test-diff-suppr/test0-type-suppr-2.suppr: Add
final new line.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-1.suppr:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-2.suppr:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-3.suppr:
Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test41-enumerator-changes-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-7.suppr:
Likewise.
* tests/data/test-ini/test01-equal-in-property-string.abignore:
Likewise.
2020-09-18 Giuliano Procida <gprocida@google.com>
abg-corpus.cc: report architecture discrepancies
* src/abg-corpus.cc (corpus_group::add_corpus): Report
architecture discrepancies.
2020-09-16 Dodji Seketeli <dodji@redhat.com>
Bug 26568 - Union should support more than one anonymous member
* src/abg-dwarf-reader.cc (add_or_update_union_type): Don't use
the empty name of anonymous members in the lookup to ensure that
all data members are unique. Rather, use the whole anonymous
member itself for the lookup, just like is done to handle
anonymous data member in classes/structs.
* src/abg-reader.cc (build_union_decl): Likewise.
* src/abg-ir.cc (get_generic_anonymous_internal_type_name): Define
new static function.
(get_type_name): For internal purposes, make the type name of all
anonymous types of a given kind to be the same. This allows the
internal representation of anonymous types which are based on type
names to all be the same, so that they can be compared among
themselves during type canonicalization.
* tests/data/test-read-dwarf/test-PR26568-{1,2}.c: Source code of
binary test input.
* tests/data/test-read-dwarf/test-PR26568-{1,2}.o: New binary test input.
* tests/data/test-read-dwarf/test-PR26568-{1,2}.o.abi: New
reference test ouput.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the new binary test
input above to this test harness.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi: Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
2020-09-02 Dodji Seketeli <dodji@redhat.com>
Make abidiff and abidw support several --headers-dir{1,2} options
* doc/manuals/abidiff.rst: Update documentation for the
--headers-dir{1,2} options.
* doc/manuals/abidw.rst: Likewise for the --header-dir option.
* include/abg-tools-utils.h (gen_suppr_spec_from_headers): Add new
overload that takes a vector of headers root dirs.
* src/abg-tools-utils.cc (gen_suppr_spec_from_headers_root_dir):
Define new function.
(gen_suppr_spec_from_headers): Define a new overload that takes a
vector of head_root_dir strings; it uses the new
gen_suppr_spec_from_headers function. Use the new overload in the
previous one that takes just one head_root_dir string.
* tools/abidiff.cc (options::headers_dirs{1,2}): Rename
option::headers_dir{1,2} into this one and make it be a vector of
strings rather than just a string.
(parse_command_line): Support several --headers-dir{1,2} on the
command line.
(set_diff_context_from_opts, set_suppressions): Adjust.
* tools/abidw.cc (options::headers_dirs): Renamed
options::headers_dir into this and make it be a vector of strings
rather than just a string.
(parse_command_line): Support several --headers-dir on the command
line.
(set_suppressions): Adjust.
* tests/data/test-abidiff-exit/test-headers-dirs/headers-a/header-a-v{0,1}.h:
Header files of new binary test input.
* tests/data/test-abidiff-exit/test-headers-dirs/headers-b/header-b-v{0,1}.h:
Likewise.
* tests/data/test-abidiff-exit/test-headers-dirs/test-headers-dir-v{0,1}.c:
Source code of new binary test input.
* tests/data/test-abidiff-exit/test-headers-dirs/test-headers-dir-report-{1,2}.txt:
Reference output of new binary test input.
* tests/data/test-abidiff-exit/test-headers-dirs/test-headers-dir-v{0,1}.o:
New binary test input.
* tests/data/Makefile.am: Add the new files above to source
distribution.
* tests/test-abidiff-exit.cc (InOutSpec::in_elfv{0,1}_path): Add
new data members.
(in_out_specs): Adjust the content of this array as its type
changed. Also, add two new entries to run the test over the new
binary test inputs above.
(do_prefix_strings): Define new static function.
(main): Use it the new do_prefix_strings here. Make abidiff
use the --header-dir{1,2} option whenever header directories are
specified in an entry of the in_out_specs array.
2020-09-14 Dodji Seketeli <dodji@redhat.com>
Bug 26309 - Wrong leaf reporting of changes to typedef underlying type
* src/abg-ir.cc (equals): In the overload for typedef_decls,
report changes to the underlying type as being local of kind
LOCAL_TYPE_CHANGE_KIND.
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Do not mark typedef
diff node as leaf node.
(suppression_categorization_visitor::visit_end): Propagate the
'suppressed' category of the underlying type to the parent typedef
unless the later has a local non-type change.
(redundancy_marking_visitor::visit_end): Likewise for the
'redundant' category.
* include/abg-reporter.h (report_non_type_typedef_changes): Rename ...
* src/abg-default-reporter.cc (report_non_type_typedef_changes):
... report_local_typedef_changes into this.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Make the leaf
reporter invoke the reporting method of the default reporter for
typedefs as all typedef changes are now local.
* tests/data/test-diff-filter/test-PR26309-report-0.txt: Add new
test reference output.
* tests/data/test-diff-filter/test-PR26309-v{0,1}.o: Add new test
binary input.
* tests/data/test-diff-filter/test-PR26309-v{0,1}.c: Add source
code for new test binary input.
* tests/data/Makefile.am: Add the new text material above to
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test input
above to this test harness.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt: Adjust.
2020-09-14 Dodji Seketeli <dodji@redhat.com>
Fix thinko in get_vmlinux_path_from_kernel_dist
* src/abg-tools-utils.cc (get_vmlinux_path_from_kernel_dist): Fix
thinko.
2020-09-08 Dodji Seketeli <dodji@redhat.com>
writer: Avoid using dynamic hashing in type maps
* include/abg-fwd.h (hash_as_canonical_type_or_constant): Declare ...
* src/abg-ir.cc (hash_as_canonical_type_or_constant): ... new
function.
* src/abg-writer.cc (type_hasher::operator()): Use the new
hash_as_canonical_type_or_constant.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
2020-09-08 Dodji Seketeli <dodji@redhat.com>
Use flat representation to canonicalize anonymous classes and unions
* src/abg-ir.cc ({class, union}_decl::get_pretty_representation):
Use the flat representation of the class or union even for
internal purposes.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
2020-07-24 Giuliano Procida <gprocida@google.com>
DWARF: track chained DIE declaration-only status
* src/abg-dwarf-reader.cc (add_or_update_class_type): Add an
is_declaration_only argument. Use this in favour of the
die_is_declaration_only helper function.
(add_or_update_union_type): Ditto.
(function_is_suppressed): Ditto.
(build_or_get_fn_decl_if_not_suppressed): Ditto.
(build_enum_type): Ditto.
(build_ir_node_from_die): To the main overload, add
is_declaration_only argument and default this to true.
Update this to false if the given DIE is not declaration
only and pass this on in recusrive calls and calls to
build_enum_type, add_or_update_union_type,
add_or_update_class_type and
build_or_get_fn_decl_if_not_suppressed.
* tests/data/test-annotate/test17-pr19027.so.abi: Update
test. This is mostly the removal of is-declaration-only
attributes, removal of unreachable parts of the type graph and
type id renumbering.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
2020-07-24 Giuliano Procida <gprocida@google.com>
DWARF: look up DW_AT_declaration non-recursively
* src/abg-dwarf-reader.cc (die_die_attribute): Rename
'look_thru_abstract_origin' argument to 'recursively' and
mention DW_AT_specification in its doc comment. Remove stale
comment for non-existent argument. Simplify code with the help
of the ternary operator. (die_flag_attribute): Add
recursively argument, defaulted to true. If this is false,
look for attribute using dwarf_attr rather than
dwarf_attr_integrate. (die_is_declaration_only): Call
die_flag_attribute specifying non-recursive attribute search.
* tests/data/test-annotate/test15-pr18892.so.abi: Update
tests. This is mostly the removal of unreachable parts of the type
graph and type id renumbering.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2020-07-24 Giuliano Procida <gprocida@google.com>
Improve documentation of abidiff --type-id-style
* tools/abidw.cc (display_usage): In documentation of
"--type-id-style" option, add a missing closing ')', spell
"type id" without a '-', split overly long string over two
lines, use "<...>" to indicate mandatory argument and improve
description of formats.
* doc/manuals/abidw.rst: In documentation of "--type-id-style"
option, use "<...>" to indicate mandatory argument.
2020-07-23 Giuliano Procida <gprocida@google.com>
Fix maybe_report_data_members_replaced_by_anon_dm
* src/abg-reporter-priv.cc
(maybe_report_data_members_replaced_by_anon_dm): Move
declarations of anonymous_data_member and
dms_replaced_by_same_anon_dm into inner loop. Use
anonymous_data_member for testing and reporting, allowing
iterators i and j to be replaced by just iterator i. Push
first decl onto dms_replaced_by_same_anon_dm unconditionally
and move control flow logic into loop condition.
* tests/data/Makefile.am: Add new test cases.
* tests/data/test-diff-filter/test-PR25661-7-report-1.txt: New
test case file.
* tests/data/test-diff-filter/test-PR25661-7-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-7-report-3.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-7-report-4.txt:
Likewise.
* tests/data/test-diff-filter/test-PR25661-7-v0.c: Likewise.
* tests/data/test-diff-filter/test-PR25661-7-v0.o: Likewise.
* tests/data/test-diff-filter/test-PR25661-7-v1.c: Likewise.
* tests/data/test-diff-filter/test-PR25661-7-v1.o: Likewise.
* tests/test-diff-filter.cc: Call new test cases.
2020-07-22 Giuliano Procida <gprocida@google.com>
Fix decl_base comparison function
* src/abg-ir.cc (equals): In the decl_base overload, note that
the value returned by decl_names_equal should be negated and
replace decls_are_different with decls_are_same, negating all
occurrences.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Update tests, removing some spurious anonymous union name change.
* tests/data/test-diff-filter/test33-report-0.txt: Diff now
completely empty.
* tests/data/test-diff-pkg/elfutils-libs-0.170-4.el7.x86_64-multiple-sym-vers-report-0.txt:
3 functions previously considered to have harmless changes are
now deemed to have no changes.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
1 struct RedStore data member previously considered to have
harmless changes is now deemed to have no changes.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi:
One instance of an anonymous struct removed and a typedef
repointed at another existing instance; many type ids
renumbered.
2020-07-22 Giuliano Procida <gprocida@google.com>
Make decl_names_equal more accurate
* src/abg-tools-utils.cc (decl_names_equal): Move {l,r}_pos2
declarations into the loop and make {l,r}_length const. Avoid
chance of arithmetic on string::npos values. Rework
logic so there is a single test for "names compare equal" and
a single test for different numbers of name components.
* tests/test-tools-utils.cc (main): Add nine more tests.
2020-07-30 Dodji Seketeli <dodji@redhat.com>
Bug 26261 - Fix logic for canonicalizing DW_TAG_subroutine_type DIEs
* src/abg-dwarf-reader.cc (compare_dies): Get out early if we are
are in the middle of a potential recursive comparison of function
types. Likewise if we detect that the two function types have
different textual representations, linkage names, or have a the
same textual representation, linkage names and are defined in the
same translation unit.
* tests/data/test-read-dwarf/PR26261/PR26261-exe: New test binary
input file.
* tests/data/test-read-dwarf/PR26261/PR26261-exe.abi: New
reference test output file.
* tests/data/test-read-dwarf/PR26261/PR26261-main.c: Source code
of the binary above.
* tests/data/test-read-dwarf/PR26261/PR26261-obj{a,b}.{c,h}:
Likewise.
* tests/data/test-read-dwarf/PR26261/Makefile: Makefile to
build the exe out of the source files.
* tests/data/Makefile.am: Add the new test input files to source
distribution.
* tests/test-read-dwarf.cc (in_out_spec): Add the binary test
input above to the test harness.
2020-07-29 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: re-indent a block of code
* src/abg-dwarf-reader.cc (compare_dies): Properly indent a
sub-block of the big switch case statement in there.
2020-07-17 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Remove duplicated line of code
* src/abg-ir.cc (decl_base::set_definition_of_declaration):
Remove duplicated assignment statement.
2020-07-16 Giuliano Procida <gprocida@google.com>
abg-writer.cc: Fix indentation of XML output
* src/abg-writer.cc (write_canonical_types_of_scope): Do not
add additional indentation. (write_translation_unit): Pass
additional indentation to write_canonical_types_of_scope.
(write_class_decl): Ensure optional annotations of base
classes have the same indentation as the base classes
themselves.
* tests/data/test-annotate/libtest23.so.abi: Fix indentation.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Ditto.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Ditto.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Ditto.
* tests/data/test-annotate/test1.abi: Ditto.
* tests/data/test-annotate/test14-pr18893.so.abi: Ditto.
* tests/data/test-annotate/test15-pr18892.so.abi: Ditto.
* tests/data/test-annotate/test17-pr19027.so.abi: Ditto.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Ditto.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Ditto.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Ditto.
* tests/data/test-annotate/test21-pr19092.so.abi: Ditto.
* tests/data/test-diff-suppr/test45-abi-wl.xml: Ditto.
* tests/data/test-diff-suppr/test45-abi.xml: Ditto.
* tests/data/test-diff-suppr/test46-PR25128-base.xml: Ditto.
* tests/data/test-diff-suppr/test46-PR25128-new.xml: Ditto.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Ditto.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Ditto.
* tests/data/test-read-dwarf/libtest23.so.abi: Ditto.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Ditto.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Ditto.
* tests/data/test-read-dwarf/test1.abi: Ditto.
* tests/data/test-read-dwarf/test1.hash.abi: Ditto.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Ditto.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Ditto.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Ditto.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Ditto.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Ditto.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Ditto.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Ditto.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Ditto.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Ditto.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Ditto.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Ditto.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Ditto.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Ditto.
* tests/data/test-read-write/test10.xml: Ditto.
* tests/data/test-read-write/test15.xml: Ditto.
* tests/data/test-read-write/test21.xml: Ditto.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Ditto.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Ditto.
2020-07-16 Giuliano Procida <gprocida@google.com>
Remove ABI XML test data file blank lines
* tests/data/test-abidiff/test-PR18166-libtirpc.so.abi: Remove
blank lines.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Ditto.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Ditto.
* tests/data/test-diff-suppr/test45-abi-wl.xml: Ditto.
* tests/data/test-diff-suppr/test45-abi.xml: Ditto.
* tests/data/test-diff-suppr/test46-PR25128-base.xml: Ditto.
* tests/data/test-diff-suppr/test46-PR25128-new.xml: Ditto.
2020-07-15 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Fix incorrect pop of compared types.
* src/abg-ir.cc (equals): In the class_or_union overload,
replace one instance of RETURN(false) with return false.
2020-07-09 Giuliano Procida <gprocida@google.com>
Enable Clang's -Werror-overloaded-virtual.
* configure.ac: Remove the special clause that disabled
-Werror-overloaded-virtual for Clang builds.
2020-07-09 Giuliano Procida <gprocida@google.com>
Fix inheritance of scope_decl::insert_member_decl
* include/abg-ir.h (scope_decl::insert_member_decl): Change
type of member argument from const decl_base_sptr& to plain
decl_base_sptr.
* src/abg-ir.cc (scope_decl::insert_member_decl): Likewise.
2020-07-27 Dodji Seketeli <dodji@redhat.com>
Pimpl-ify traversable_base and remove its unused traverse method
* include/abg-traverse.h (traversable_base::priv): Declare new type.
(traverse_base::priv_sptr): Add pointer to private data
member.
(traverse_base::visiting_): Move this data member definition into
traverse_base::priv.
(traverse_base::{visiting, traverse_base, ~traverse_base}): Move
definitions out-of-oline.
(traverse_base::traverse): Comment out.
* src/abg-traverse.cc (struct traversable_base::priv): Define new
type.
(traversable_base::{traversable_base, ~traversable_base, traverse,
visiting}): Move these previous inline definitions here.
2020-07-09 Giuliano Procida <gprocida@google.com>
Simplify peel_typedef_pointer_or_reference_type
* include/abg-fwd.h (peel_qualified_or_typedef_type): Remove
second argument in declarations of both overloads.
* src/abg-comp-filter.cc (is_mostly_distinct_diff): Remove
second argument to peel_qualified_or_typedef_type.
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Likewise.
* src/abg-ir.cc (peel_qualified_or_typedef_type): In both
overloads, remove second argument peel_qual_type, simplify
code with the assumption it was always false and remove
incomplete array type peeling logic. In type_base_sptr
overload, remove stray space.
2020-07-09 Giuliano Procida <gprocida@google.com>
Remove unused is_reference_or_pointer_diff.
* include/abg-comparison.h (is_reference_or_pointer_diff):
Drop function declaration.
* src/abg-comparison.cc (is_reference_or_pointer_diff): Drop
function definition.
2020-07-09 Giuliano Procida <gprocida@google.com>
abg-comparison.h: Remove stray declaration
* include/abg-comparison
(is_reference_or_pointer_diff_to_non_basic_distinct_types):
Remove stray declaration.
2020-07-08 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Refactor operator== methods with helper function
* src/abg-ir.cc (try_canonical_compare): New template function.
(type_decl::operator==): Use it here.
(scope_type_decl::operator==): Likewise.
(qualified_type_def::operator==): Likewise.
(pointer_type_def::operator==): Likewise.
(reference_type_def::operator==): Likewise.
(array_type_def::subrange_type::operator==): Likewise.
(array_type_def::operator==): Likewise.
(enum_type_decl::operator==): Likewise.
(typedef_decl::operator==): Likewise.
(function_type::operator==): Likewise.
(class_or_union::operator==): Likewise.
(class_decl::operator==): Likewise.
(union_decl::operator==): Likewise.
2020-07-01 Giuliano Procida <gprocida@google.com>
abg-comparison.cc: Tidy some corpus_diff code
* src/abg-comparison.cc (corpus_diff::priv::emit_diff_stats):
Adjust code whitespace; rename the second instance of
total_nb_variable_changes to
total_nb_unreachable_type_changes.
(corpus_diff::has_incompatible_changes): Fix comment typo.
2020-07-06 Giuliano Procida <gprocida@google.com>
Fix --type-id-style hash for empty internal names.
* src/abg-writer.cc (write_context::get_id_for_type): When
hashing internal type names, convert to std::string rather
than using the raw method directly as this will avoid a null
pointer dereference in the case of an empty string; tabify
code indentation.
2020-07-08 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Tidy some operator== definitions
* src/abg-irc.cc (scope_type_decl::operator==): Compare naked
canonical type pointers instead of the shared pointers.
(qualified_type_def::operator==): Remove excess blank line.
(function_type::operator==): Do dynamic_cast and check of
argument before comparing naked canonical type pointers.
(class_or_union::operator==): Eliminate temporary reference.
(class_decl::operator==): Likewise.
(union_decl::operator==): Likewise.
2020-07-17 Giuliano Procida <gprocida@google.com>
Fix corpus_diff::has_net_changes for --leaf-changes-only mode
* include/abg-reporter.h ({reporter_base, default_reporter,
leaf_reporter}::diff_has_net_changes): Add new virtual function.
This breaks binary compatibility but should conserve source
compatibility.
* src/abg-default-reporter.cc
(default_reporter::diff_has_net_changes): Define new member
function.
* src/abg-leaf-reporter.cc (leaf_reporter::diff_has_net_changes):
Likewise.
* src/abg-comparison.cc (corpus_diff::has_net_changes): Invoke
reporter_base::diff_has_net_changes on the current reporter,
rather than trying to handle all the different kinds of reporters
here.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Add a
TODO to possibly delegate the implementation of this function to
the reporters.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-net-change-report0.txt:
Normal mode, nothing suppressed.
* tests/data/test-abidiff-exit/test-net-change-report1.txt:
Normal mode, everything suppressed.
* tests/data/test-abidiff-exit/test-net-change-report2.txt:
Leaf mode, nothing suppressed.
* tests/data/test-abidiff-exit/test-net-change-report3.txt:
Leaf mode, everything suppressions.
* tests/data/test-abidiff-exit/test-net-change-v0.c: Test file
* tests/data/test-abidiff-exit/test-net-change-v0.o: Test file
* tests/data/test-abidiff-exit/test-net-change-v1.c: Test file
* tests/data/test-abidiff-exit/test-net-change-v1.o: Test file
* tests/data/test-abidiff-exit/test-net-change.abignore: This
suppresses changes for all variables, functions and types in
the test files, except for the 'victim' function.
* tests/test-abidiff-exit.cc: Run new test cases.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-07-01 Giuliano Procida <gprocida@google.com>
reporter: Fix report whitespace typos.
* src/abg-reporter-priv.cc (represent): Add missing space to
string split across two lines in certain anonymous data member
diffs.
* src/abg-default-reporter.cc (report): In the array_diff
overload, eliminate trailing space at end of line.
* tests/data/test-diff-dwarf/test10-report.txt: Delete
trailing whitespace.
* tests/data/test-diff-filter/test24-compatible-vars-report-1.txt:
Ditto.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Ditto.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
Ditto.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Ditto.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Ditto.
2020-07-09 Giuliano Procida <gprocida@google.com>
abg-writer.cc: Clean up new line emission.
* src/abg-writer.cc (annotate): In the
function_decl::parameter_sptr overload, fix code whitespace.
(write_decl_in_scope): Remove wrote_context state variable and
associated logic; emit new line unconditionally after end of
XML tags and nowhere else.
(write_canonical_types_of_scope): Emit new line after end of
XML comment and nowhere else.
(write_translation_unit): Emit new line after end of XML tags
and nowhere else.
(write_type_decl): Likewise.
(write_namespace_decl): Likewise.
(write_qualified_type_def): Emit new line after end of XML tag.
(write_pointer_type_def): Likewise.
(write_reference_type_def): Likewise.
(write_array_type_def): Emit new line after end of XML tags
and nowhere else.
(write_enum_type_decl): Emit new line after end of XML tag.
(write_elf_symbol): Likewise.
(write_elf_symbols_table): Emit no new lines.
(write_elf_needed): Emit new line unconditionally after end of
XML tags.
(write_typedef_decl): Emit new line after end of XML tag.
(write_var_decl): Emit new line after end of XML tag.
(write_function_decl): Likewise.
(write_function_type): Fold two output statements into
one; emit new line after end of XML tag.
(write_class_decl_opening_tag): Emit new line unconditionally
after end of XML tags and simplify empty element tag logic.
(write_union_decl_opening_tag): Likewise.
(write_class_decl): Emit new line after end of XML tag and
nowhere else.
(write_union_decl): Likewise.
(write_member_type_opening_tag): Emit new line after end of
XML tag.
(write_member_type): Emit new lines only after XML tags.
(write_type_tparameter): Emit new line after XML tag.
(write_non_type_tparameter): Likewise.
(write_template_tparameter): Emit new line after XML tag and
nowhere else.
(write_type_composition): Likewise.
(write_template_parameters): Emit no new lines.
(write_function_tdecl): Emit new line after XML tag and
nowhere else.
(write_class_tdecl): Likewise.
(write_corpus): Emit new lines only after XML tags.
(dump): In the decl_base_sptr overload, don't emit final new
line as this is now done by write_decl. In the var_decl_sptr
overload, don't emit final new line (mistakenly done to cerr
instead of o) as this is now done by write_var_decl. In the
translation_unit overload, don't emit final new line as this
doubles that emitted by write_translation_unit.
* tests/data/test-annotate/libtest23.so.abi: Delete all blank
lines.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Ditto.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Ditto.
* tests/data/test-annotate/test-anonymous-members-0.o.abi:
Ditto.
* tests/data/test-annotate/test1.abi: Ditto.
* tests/data/test-annotate/test13-pr18894.so.abi: Ditto.
* tests/data/test-annotate/test14-pr18893.so.abi: Ditto.
* tests/data/test-annotate/test15-pr18892.so.abi: Ditto.
* tests/data/test-annotate/test17-pr19027.so.abi: Ditto.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Ditto.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Ditto.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Ditto.
* tests/data/test-annotate/test21-pr19092.so.abi: Ditto.
* tests/data/test-annotate/test7.so.abi: Ditto.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Ditto.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Ditto.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Ditto.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Ditto.
* tests/data/test-read-dwarf/libtest23.so.abi: Ditto.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Ditto.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Ditto.
* tests/data/test-read-dwarf/test1.abi: Ditto.
* tests/data/test-read-dwarf/test1.hash.abi: Ditto.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Ditto.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Ditto.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Ditto.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Ditto.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Ditto.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Ditto.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Ditto.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Ditto.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Ditto.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Ditto.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Ditto.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Ditto.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Ditto.
* tests/data/test-read-dwarf/test7.so.abi: Ditto.
* tests/data/test-read-dwarf/test7.so.hash.abi: Ditto.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi:
Ditto.
* tests/data/test-read-write/test10.xml: Ditto.
* tests/data/test-read-write/test15.xml: Ditto.
* tests/data/test-read-write/test21.xml: Ditto.
* tests/data/test-read-write/test25.xml: Ditto.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Ditto.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Ditto.
2020-07-09 Dodji Seketeli <dodji@redhat.com>
reader: Remove useless support for WIP types
* src/abg-reader.cc (read_context::m_wip_types_map): Remove data
member.
(read_context::{clear_wip_classes_map, mark_type_as_wip,
unmark_type_as_wip, is_wip_type}): Remove member functions.
(read_context::maybe_canonicalize_type): Remove use of
is_wip_type.
2020-06-19 Giuliano Procida <gprocida@google.com>
Use pointers not strings in type graph comparison.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Update.
* tests/data/test-diff-pkg/elfutils-libs-0.170-4.el7.x86_64-multiple-sym-vers-report-0.txt:
Update.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Update.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Update.
2020-06-10 Giuliano Procida <gprocida@google.com>
Add tests for declaration-only enums.
* tests/data/test-abidiff-exit/test-decl-enum-report-2.txt: Add
new test reference output.
* tests/data/test-abidiff-exit/test-decl-enum-report-3.txt: Likewise.
* tests/data/test-abidiff-exit/test-decl-enum-report.txt: Likewise.
* tests/data/test-abidiff-exit/test-decl-enum-v{0,1}.c: Add source
code for the binaries below.
* tests/data/test-abidiff-exit/test-decl-enum-v{0,1}.o: Add new
binary test inputs.
* tests/data/Makefile.am: Add the new files above to source
distribution.
* tests/test-abidiff-exit.cc: Add the test inputs above to the
test harness.
2020-06-10 Giuliano Procida <gprocida@google.com>
Add declaration-only enums to XML reader/writer.
* src/abg-reader.cc (build_enum_type_decl): Detect a
declaration-only enum and flag it as such.
(build_type_decl): Support reading the "is-declaration" attribute.
(build_class_decl): Adjust.
* src/abg-writer.cc (write_is_declaration_only): Renamed
write_class_or_union_is_declaration_only into this.
(write_enum_is_declaration_only): Remove.
(write_type_decl, write_enum_type_decl)
(write_class_decl_opening_tag, write_union_decl_opening_tag): Use
write_is_declaration_only.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2020-06-10 Dodji Seketeli <dodji@redhat.com>
Support declaration-only enums in DWARF reader.
* src/abg-dwarf-reader.cc (string_enums_map): Define new
convenience typedef.
(read_context::decl_only_enums_map_): Define new data member.
(read_context::{declaration_only_enums,
is_decl_only_enum_scheduled_for_resolution,
resolve_declaration_only_enums}): Define new member functions.
(build_internal_underlying_enum_type_name)
(build_enum_underlying_type): Factorize these functions out of ...
(build_enum_type): ... here. Detect a decl-only enum and flag it
as such. If the enum type is decl-only, then set its underlying
type as decl-only as well.
(build_enum_underlying_type): Mark the underlying type as
artificial.
(get_opaque_version_of_type): Make this handle enums as well. So
make its return type be type_or_decl_base_sptr, rather than just
class_or_union_sptr as it used to be.
(read_debug_info_into_corpus): Add logging to trace decl-only
enums resolution.
(build_ir_node_from_die): Detect when a suppression specification
makes an enum opaque. In that case, get an opaque version of the
enum type by invoking get_opaque_version_of_type. Note that
get_opaque_version_of_type doesn't support returning opaque
-- i.e, decl-only enum types -- yet, but this is going to be
handled in a subsequent patch.
2020-06-10 Giuliano Procida <gprocida@google.com>
Support incomplete enums in core and diff code.
* include/abg-comp-filter.h (has_decl_only_def_change) : Declare
New function.
* src/abg-comp-filter.cc (there_is_a_decl_only_enum): Define new
static function and ...
(type_size_changed): ... use it here.
(has_decl_only_def_change): Define new function and ...
(categorize_harm{less, ful}_diff_node): ... use it here.
* include/abg-fwd.h (enums_type, decl_base_wptr): Declare new
typedefs.
(look_through_decl_only_class): Declare new overload for
class_or_union*.
(is_compatible_with_enum_type, is_compatible_with_enum_type)
(look_through_decl_only, lookup_enum_types, lookup_enum_types):
Declare new functions.
* include/abg-ir.h (decl_base::{get_is_declaration_only,
set_is_declaration_only, set_definition_of_declaration,
get_definition_of_declaration,
get_naked_definition_of_declaration}): Declare new member
functions. They were moved here from the class_or_union class.
(class_or_union::{get_earlier_declaration,
set_earlier_declaration, get_definition_of_declaration,
set_definition_of_declaration,
get_naked_definition_of_declaration, get_is_declaration_only,
set_is_declaration_only}): Remove these member functions.
* src/abg-ir.cc (decl_base::priv::{declaration_,
definition_of_declaration_, naked_definition_of_declaration_,
is_declaration_only_}): Define data members. Moved here from
class_or_union.
(decl_base::priv::priv): Adjust to initialize the new data
members.
(decl_base::{get_earlier_declaration, set_earlier_declaration,
get_definition_of_declaration,
get_naked_definition_of_declaration, get_is_declaration_only,
set_is_declaration_only, set_definition_of_declaration}): Define
member functions.
(operator|): In the overload for (change_kind, change_kind),
adjust the return type of the call to
decl_base::get_definition_of_declaration.
(look_through_decl_only): Define new function.
(look_through_decl_only_class): Adjust.
(look_through_decl_only_enum): Likewise.
(maybe_update_types_lookup_map<class_decl>): Adjust return type of
call to decl_base::get_definition_of_declaration.
(types_defined_same_linux_kernel_corpus_public): Use
look_through_decl_only_class rather than open coding it.
(class_or_union::priv::{declaration_, definition_of_declaration_,
naked_definition_of_declaration_, is_declaration_only_}): Remove
these data members. They are now carried by decl_base::priv.
(class_or_union::{g,s}et_alignment_in_bits): Adjust.
(class_or_union::{g,s}et_size_in_bits): Likewise.
(class_or_union::operator==): Likewise.
(equals): Adjust the overload for class_or_union.
(is_compatible_with_enum_type)
* src/abg-comparison.cc (try_to_diff<class_decl>): Adjust the
return type of decl_base::get_definition_of_declaration.
(leaf_diff_node_marker_visitor::visit_begin): Use
filtering::has_decl_only_def_change rather than
filtering::has_class_decl_only_def_change. Decl-only changes to
enums (or any other type really) will thus not be recorded as leaf
changes.
* src/abg-dwarf-reader.cc (get_scope_for_die): Adjust return type
of decl_base::get_definition_of_declaration.
* src/abg-default-reporter.cc (default_reporter::report): Report
enum decl-only <-> definition changes.
* src/abg-hash.cc (class_or_union::hash::operator()): In the
overload for class_or_union& adjust the return type for
decl_base::get_definition_of_declaration.
2020-06-19 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Remove unused re_canonicalize function.
* include/abg-fwd.h (re_canonicalize): Remove declaration of
obsolete function.
* include/abg-ir.h (class {decl_base, type_base}): Remove
re_canonicalize friend declarations from these classes.
* src/abg-ir.cc (re_canonicalize): Remove obsolete function.
2020-06-24 Dodji Seketeli <dodji@redhat.com>
Bug 26135 - Wrong linkage name causes anonymous classes miscomparison
* include/abg-ir.h (class_decl::class_decl): Add two overloads
that take the "is_anonymous" flag.
(union_decl::union_decl): Likewise.
* src/abg-ir.cc (class_decl::class_decl): Define two overloads
that take the "is_anonymous" flag and set the linkage name
accordingly.
(union_decl::union_decl): Likewise.
(type_base::get_canonical_type_for): Assert that an anonymous
class or union can't have a linkage name for now.
* src/abg-dwarf-reader.cc (add_or_update_class_type)
(add_or_update_union_type): Use a new overload for the constuctor
of {class, union}_decl and set the "is_anonymous" flag. Don't use
decl_base::set_is_anonymous anymore.
* src/abg-reader.cc (build_class_decl, build_union_decl):
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2020-06-29 Giuliano Procida <gprocida@google.com>
Rename declaration-definition change category.
* include/abg-comparison.h (TYPE_DECL_ONLY_DEF_CHANGE_CATEGORY):
Rename CLASS_DECL_ONLY_DEF_CHANGE_CATEGORY into this.
(EVERYTHING_CATEGORY): In the value of this enumerator, rename
CLASS_DECL_ONLY_DEF_CHANGE_CATEGORY into
TYPE_DECL_ONLY_DEF_CHANGE_CATEGORY.
* src/abg-comp-filter.cc (categorize_harmless_diff_node):
Likewise.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Likewise.
(operator<<(ostream& o, diff_category c)): Likewise.
* src/abg-default-reporter.cc (default_reporter::report): Likewise
in the overload for class_or_union_diff.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Likewise in
the overload for class_or_union_diff.
2020-06-10 Giuliano Procida <gprocida@google.com>
Tidy build_enum_type state variables.
* src/abg-dwarf-reader.cc (build_enum_type): Rename local
variable enum_is_anonymous to is_anonymous. Move initilisation
of local variable is_artificial to location corresponding to
that in add_or_update_class_type and add_or_update_union_type
functions.
2020-06-10 Giuliano Procida <gprocida@google.com>
Refactor d.context() as ctxt in report(enum_diff).
* src/abg-default-reporter.cc (report): In the enum_diff
overload, introduce the name ctxt to replace four occurrences
of d.context().
2020-06-10 Giuliano Procida <gprocida@google.com>
Improve code comments and whitespace.
* include/abg-fwd.h: Correct doc-comment reference to
enum_type_decl.
* src/abg-comp-filter.cc: Fix doc-comment syntax.
* src/abg-comparison.cc (operator<<): In the diff_category
overload, fix code indentation.
* src/abg-default-reporter.cc (report): In the
class_or_union_diff overload, adjust comment to reflect that
the code is reporting changes between declaration-only and
defined types, in either direction.
2020-06-17 Giuliano Procida <gprocida@google.com>
get_canonical_type_for: restore environment better
* src/abg-ir.cc (get_canonical_type_for): Ensure the
do_on_the_fly_canonicalization and
decl_only_class_equals_definition flags are restored
unconditionally.
2020-06-18 Dodji Seketeli <dodji@redhat.com>
Bug 26127 - abidw --annotate emits incomplete function types
* include/abg-ir.h (decl_base::clear_qualified_name): Declare new
protected member function.
({pointer_type_def, reference_type_def, qualified_type_def,
function_type}::on_canonical_type_set): Declare virtual member
functions.
* src/abg-ir.cc (decl_base::clear_qualified_name): Define new
protected member function.
({pointer_type_def, reference_type_def, qualified_type_def,
function_type}::on_canonical_type_set): Define virtual member
functions.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
2020-06-11 Giuliano Procida <gprocida@google.com>
Fix bug that suppressed DWARF read tests.
* tests/test-read-dwarf.cc (in_out_specs): Use NULL instead of
empty ABI paths for test25, test26 and test27. (perform):
Check members of spec, rather than locals with same name, when
deciding to terminate testing early; fix some code whitespace.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Update
multidimensional array sizes.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Ditto.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Ditto.
* tests/data/test-read-dwarf/test7.so.abi: Ditto.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Update following translation unit ordering change.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Ditto.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Ditto.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Ditto.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Ditto.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Ditto.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Ditto.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Ditto.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Ditto.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Ditto.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Ditto.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: Update
following code changes affecting ordering of some ABI
elements.
* tests/data/test-read-dwarf/test16-pr18904.so.abi
Reviewed-by: Matthias Maennich <maennich@google.com>
Tested-by: Matthias Maennich <maennich@google.com>
2020-06-16 Matthias Maennich <maennich@google.com>
cleanup: std::weak_ptr use: replace manual lock by std::weak_ptr::lock
* src/abg-comparison-priv.h (diff::priv::get_context): improve
weak_ptr usage.
(corpus_diff:diff_stats::priv::ctxt): Likewise.
* src/abg-comparison.cc (corpus_diff::priv::get_context): Likewise.
(var_diff::type_diff): Likewise.
* src/abg-ir.cc (elf_symbol::get_next_alias): Likewise.
(elf_symbol::get_next_common_instance): Likewise.
(type_base::get_canonical_type): Likewise.
(qualified_type_def::get_underlying_type): Likewise.
(pointer_type_def::get_pointed_to_type): Likewise.
(reference_type_def::get_pointed_to_type): Likewise.
(array_type_def::subrange_type::get_underlying_type): Likewise.
(array_type_def::get_element_type): Likewise.
(typedef_decl::get_underlying_type): Likewise.
(var_decl::get_type): Likewise.
(function_type::get_return_type): Likewise.
(function_decl::get_type): Likewise.
(function_decl::parameter::get_type): Likewise.
(class_or_union::get_naming_typedef): Likewise.
(class_or_union::get_definition_of_declaration): Likewise.
(class_decl::base_spec::get_base_class): Likewise.
(template_parameter::get_enclosing_template_decl): Likewise.
(non_type_tparameter::get_type): Likewise.
(type_composition::get_composed_type): Likewise.
2020-06-16 Giuliano Procida <gprocida@google.com>
Fix leaf-mode formatting of decl <-> defn diffs.
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
class_or_union_diff overload, add a terminating new line after
reporting a declaration-only <-> definition difference.
2020-06-15 Giuliano Procida <gprocida@google.com>
abg-writer: Add support for stable hash type ids.
* doc/manuals/abidw.rst: Replace stray documentation of
--named-type-ids with documention of new --type-id-style
option.
* include/abg-writer.h (type_id_style_kind): Add new enum.
(set_type_id_style): Add new write_context setter.
(set_common_options): Set type id style in write context.
* include/abg-hash.h (fnv_hash): Declare new 32-bit FNV-1a
hash function in abigail::hashing namespace.
* src/abg-hash.h (fnv_hash): Define new 32-bit FNV-1a hash
function in abigail::hashing namespace.
* src/abg-writer.cc (write_context): Add m_type_id_style
member to record type style to use, defaulting to
SEQUENCE_TYPE_ID_STYLE; add m_used_type_id_hashes to record
already-used hashes.
(write_context::get_type_id_style): Add new getter.
(write_context::set_type_id_style): Add new setter.
(get_id_for_type): Add support for HASH_TYPE_ID_STYLE style.
(set_type_id_style): Add new helper function.
* tools/abidw.cc (options): Add type_id_style member.
(display_usage): Add description of --type-id-style option.
(parse_command_line): Parse --type-id-style option.
* tests/data/Makefile.am: Add new hash type id ABI files.
* tests/test-read-dwarf.cc: (InOutSpec): Add type_id_style
member.
(in_out_specs): Set type_id_style to SEQUENCE_TYPE_ID_STYLE in
existing test specifications. Duplicate first 9 test cases
with type_id_style set to HASH_TYPE_ID_STYLE.
* tests/data/test-read-dwarf/test0.hash.abi: New ABI XML file
with hash type ids.
* tests/data/test-read-dwarf/test1.hash.abi: Ditto.
* tests/data/test-read-dwarf/test2.so.hash.abi: Ditto.
* tests/data/test-read-dwarf/test3.so.hash.abi: Ditto.
* tests/data/test-read-dwarf/test4.so.hash.abi: Ditto.
* tests/data/test-read-dwarf/test5.o.hash.abi: Ditto.
* tests/data/test-read-dwarf/test6.so.hash.abi: Ditto.
* tests/data/test-read-dwarf/test7.so.hash.abi: Ditto.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.hash.abi:
Ditto.
2020-06-12 Giuliano Procida <gprocida@google.com>
Eliminate non-ASCII characters.
* include/abg-diff-utils.h: Replace "’’" with "'".
* src/abg-elf-helpers.cc: Replace "â‹…" with ".".
* src/abg-ini.cc: Replace "@êef" with "@ref".
* src/abg-ir.cc: Ditto.
* src/abg-tools-utils.cc: Replace "–" with "-".
2020-06-11 Matthias Maennich <maennich@google.com>
dwarf-reader: get_die_source: always initialize return value
* src/abg-dwarf-reader.cc
(read_context::get_die_source): Always initialize die_source.
(read_context::ContainerType::get_container): Fix
initialization of die_source.
(read_context::compute_canonical_die): Likewise.
(read_context::get_canonical_die): Likewise.
(read_context::get_or_compute_canonical_die): Likewise.
(read_context::associate_die_to_decl): Likewise.
(read_context::set_canonical_die_offset): Likewise.
(read_context::schedule_type_for_late_canonicalization): Likewise.
(read_context::compare_dies): Likewise.
(read_context::get_parent_die): Likewise.
(read_context::get_scope_for_die): Likewise.
(read_context::add_or_update_union_type): Likewise.
(read_context::maybe_canonicalize_type): Likewise.
(read_context::build_ir_node_from_die): Likewise.
2020-06-09 Matthias Maennich <maennich@google.com>
abipkgdiff: remove unused includes of elfutils/libdw.h and elf.h
* tools/abipkgdiff.cc: Drop unused includes.
2020-05-29 Matthias Maennich <maennich@google.com>
abg-reporter: fully qualify std::string and std::ostream
* include/abg-reporter.h (reporter_base::report) fully qualify
std::string and std::ostream for all overloads.
(default_reporter::report_local_typedef_changes): Likewise.
(default_reporter::report_local_qualified_type_changes): Likewise.
(default_reporter::report_local_reference_type_changes): Likewise.
(default_reporter::report_local_function_type_changes): Likewise.
(default_reporter::report): Likewise.
(leaf_reporter::report_changes_from_diff_maps): Likewise.
(leaf_reporter::report): Likewise.
Suggested-by: Mark Barolak <mbar@google.com>
2020-06-05 Giuliano Procida <gprocida@google.com>
Fix HARMLESS_SYMBOL_ALIAS_CHANGE_CATEGORY spelling
* include/abg-comparison.h (enum diff_category): Rename
HARMLESS_SYMBOL_ALIAS_CHANGE_CATEORY enumerator to
HARMLESS_SYMBOL_ALIAS_CHANGE_CATEGORY.
* src/abg-comp-filter.cc (categorize_harmless_diff_node): Replace
use of HARMLESS_SYMBOL_ALIAS_CHANGE_CATEORY enumerator with
HARMLESS_SYMBOL_ALIAS_CHANGE_CATEGORY.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Replace use of HARMLESS_SYMBOL_ALIAS_CHANGE_CATEORY enumerator
with HARMLESS_SYMBOL_ALIAS_CHANGE_CATEGORY.
(operator<<): In the diff_category overload, replace use of
HARMLESS_SYMBOL_ALIAS_CHANGE_CATEORY enumerator with
HARMLESS_SYMBOL_ALIAS_CHANGE_CATEGORY and output correct
spelling for both this and HARMLESS_UNION_CHANGE_CATEGORY.
* tools/abicompat.cc (create_diff_context): Replace use of
HARMLESS_SYMBOL_ALIAS_CHANGE_CATEORY enumerator with
HARMLESS_SYMBOL_ALIAS_CHANGE_CATEGORY.
2020-05-18 Matthias Maennich <maennich@google.com>
dwarf-reader: read_context: drop unused symbol versioning code
* src/abg-dwarf-reader.cc
(read_context::versym_section_): Delete.
(read_context::verdef_section_): Delete.
(read_context::verneed_section_): Delete.
(read_context::symbol_versionning_sections_loaded_): Delete.
(read_context::symbol_versionning_sections_found_): Delete.
(read_context::initialize): Remove initializations of deleted members.
(read_context::get_symbol_versionning_sections): Delete.
(read_context::get_version_for_symbol): Delete.
(read_context::lookup_elf_symbol_from_index): Use
get_version_for_symbol provided by elf_helpers.
2020-05-18 Matthias Maennich <maennich@google.com>
dwarf-reader: Remove unused code
* src/abg-dwarf-reader.cc
(lookup_public_variable_symbol_from_elf): Delete.
(read_context::bss_section_): Delete.
(read_context::text_section_): Delete.
(read_context::rodata_section_): Delete.
(read_context::data_section_): Delete.
(read_context::data1_section_): Delete.
(read_context::initialize): Remove initializations of deleted members.
(read_context::options): Delete.
(read_context::bss_section): Delete.
(read_context::text_section): Delete.
(read_context::rodata_section): Delete.
(read_context::data_section): Delete.
(read_context::data1_section): Delete.
(read_context::get_elf_file_type): Delete.
(read_context::lookup_symbol_from_elf): Delete.
(read_context::lookup_public_variable_symbol_from_elf): Delete.
(read_context::fun_addr_sym_map_sptr): Delete.
(read_context::fun_addr_sym_map): Delete.
(read_context::get_data_section_for_variable_address): Delete.
(read_context::suppression_matches_function_sym_name): Delete.
(read_context::suppression_matches_function_name): Delete.
(read_context::suppression_matches_type_name): Delete.
2020-05-29 Dodji Seketeli <dodji@redhat.com>
abigail.m4: Fix copyright notice
* abigail.m4: Mention Red Hat in the copyright and myself as author.
2020-05-18 Matthias Maennich <maennich@google.com>
tests: Add kernel symtab test suite
* tests/data/Makefile.am: add new test data for runtestsymtab
* tests/data/test-symtab/kernel-4.14/Makefile: New test case makefile.
* tests/data/test-symtab/kernel-4.14/empty.c: Likewise.
* tests/data/test-symtab/kernel-4.14/one_of_each.c: Likewise.
* tests/data/test-symtab/kernel-4.14/single_function.c: Likewise.
* tests/data/test-symtab/kernel-4.14/single_function_gpl.c: Likewise.
* tests/data/test-symtab/kernel-4.14/single_variable.c: Likewise.
* tests/data/test-symtab/kernel-4.14/single_variable_gpl.c: Likewise.
* tests/data/test-symtab/kernel-4.14/empty.ko: New test data.
* tests/data/test-symtab/kernel-4.14/one_of_each.ko: Likewise.
* tests/data/test-symtab/kernel-4.14/single_function.ko: Likewise.
* tests/data/test-symtab/kernel-4.14/single_function_gpl.ko: Likewise.
* tests/data/test-symtab/kernel-4.14/single_variable.ko: Likewise.
* tests/data/test-symtab/kernel-4.14/single_variable_gpl.ko: Likewise.
* tests/data/test-symtab/kernel-4.19/Makefile: New test case makefile.
* tests/data/test-symtab/kernel-4.19/empty.c: Likewise.
* tests/data/test-symtab/kernel-4.19/one_of_each.c: Likewise.
* tests/data/test-symtab/kernel-4.19/single_function.c: Likewise.
* tests/data/test-symtab/kernel-4.19/single_function_gpl.c: Likewise.
* tests/data/test-symtab/kernel-4.19/single_variable.c: Likewise.
* tests/data/test-symtab/kernel-4.19/single_variable_gpl.c: Likewise.
* tests/data/test-symtab/kernel-4.19/empty.ko: New test data.
* tests/data/test-symtab/kernel-4.19/one_of_each.ko: Likewise.
* tests/data/test-symtab/kernel-4.19/single_function.ko: Likewise.
* tests/data/test-symtab/kernel-4.19/single_function_gpl.ko: Likewise.
* tests/data/test-symtab/kernel-4.19/single_variable.ko: Likewise.
* tests/data/test-symtab/kernel-4.19/single_variable_gpl.ko: Likewise.
* tests/data/test-symtab/kernel-5.4/Makefile: New test case makefile.
* tests/data/test-symtab/kernel-5.4/empty.c: Likewise.
* tests/data/test-symtab/kernel-5.4/one_of_each.c: Likewise.
* tests/data/test-symtab/kernel-5.4/single_function.c: Likewise.
* tests/data/test-symtab/kernel-5.4/single_function_gpl.c: Likewise.
* tests/data/test-symtab/kernel-5.4/single_variable.c: Likewise.
* tests/data/test-symtab/kernel-5.4/single_variable_gpl.c: Likewise.
* tests/data/test-symtab/kernel-5.4/empty.ko: New test data.
* tests/data/test-symtab/kernel-5.4/one_of_each.ko: Likewise.
* tests/data/test-symtab/kernel-5.4/single_function.ko: Likewise.
* tests/data/test-symtab/kernel-5.4/single_function_gpl.ko: Likewise.
* tests/data/test-symtab/kernel-5.4/single_variable.ko: Likewise.
* tests/data/test-symtab/kernel-5.4/single_variable_gpl.ko: Likewise.
* tests/data/test-symtab/kernel-5.6/Makefile: New test case makefile.
* tests/data/test-symtab/kernel-5.6/empty.c: Likewise.
* tests/data/test-symtab/kernel-5.6/one_of_each.c: Likewise.
* tests/data/test-symtab/kernel-5.6/single_function.c: Likewise.
* tests/data/test-symtab/kernel-5.6/single_function_gpl.c: Likewise.
* tests/data/test-symtab/kernel-5.6/single_variable.c: Likewise.
* tests/data/test-symtab/kernel-5.6/single_variable_gpl.c: Likewise.
* tests/data/test-symtab/kernel-5.6/empty.ko: New test data.
* tests/data/test-symtab/kernel-5.6/one_of_each.ko: Likewise.
* tests/data/test-symtab/kernel-5.6/single_function.ko: Likewise.
* tests/data/test-symtab/kernel-5.6/single_function_gpl.ko: Likewise.
* tests/data/test-symtab/kernel-5.6/single_variable.ko: Likewise.
* tests/data/test-symtab/kernel-5.6/single_variable_gpl.ko: Likewise.
* tests/data/test-symtab/kernel/Makefile: New test case source file.
* tests/data/test-symtab/kernel/empty.c: Likewise.
* tests/data/test-symtab/kernel/one_of_each.c: Likewise.
* tests/data/test-symtab/kernel/single_function.c: Likewise.
* tests/data/test-symtab/kernel/single_function_gpl.c: Likewise.
* tests/data/test-symtab/kernel/single_variable.c: Likewise.
* tests/data/test-symtab/kernel/single_variable_gpl.c: Likewise.
* tests/test-symtab.cc: New test case to test kernel symtabs.
2020-05-18 Matthias Maennich <maennich@google.com>
tests: Add symtab test suite
* tests/Makefile.am: add new test runtestsymtab
* tests/data/Makefile.am: add new test data for runtestsymtab
* tests/data/test-symtab/Makefile: Add this to build the binaries
below from their source code.
* tests/data/test-symtab/basic/empty.c: New test case source.
* tests/data/test-symtab/basic/link_against_me.c: Likewise.
* tests/data/test-symtab/basic/no_debug_info.c: Likewise.
* tests/data/test-symtab/basic/one_function_one_variable.c: Likewise.
* tests/data/test-symtab/basic/one_function_one_variable_undefined.c: Likewise.
* tests/data/test-symtab/basic/single_function.c: Likewise.
* tests/data/test-symtab/basic/single_undefined_function.c: Likewise.
* tests/data/test-symtab/basic/single_undefined_variable.c: Likewise.
* tests/data/test-symtab/basic/single_variable.c: Likewise.
* tests/data/test-symtab/basic/empty.so: New test data, built from
the Makefile above.
* tests/data/test-symtab/basic/link_against_me.so: Likewise.
* tests/data/test-symtab/basic/no_debug_info.so: Likewise.
* tests/data/test-symtab/basic/one_function_one_variable.so: Likewise.
* tests/data/test-symtab/basic/one_function_one_variable_undefined.so: Likewise.
* tests/data/test-symtab/basic/single_function.so: Likewise.
* tests/data/test-symtab/basic/single_undefined_function.so: Likewise.
* tests/data/test-symtab/basic/single_undefined_variable.so: Likewise.
* tests/data/test-symtab/basic/single_variable.so: Likewise.
* tests/test-symtab.cc: New test driver.
2020-05-19 Dodji Seketeli <dodji@redhat.com>
Bug 25989 - type_topo_comp doesn't meet irreflexive requirements
* src/abg-ir.cc (type_topo_comp::operator()): In the comparison
operator consider two equivalent empty-qualified types as being
topologically equivalent.
2020-05-07 Dodji Seketeli <dodji@redhat.com>
Bug 25661 - Support data member replacement by anonymous data member
* include/abg-comp-filter.h (has_data_member_replaced_by_anon_dm):
Declare new function.
* include/abg-comparison.h (changed_var_sptr)
(changed_var_sptrs_type): Declare new typedefs.
(HARMLESS_DATA_MEMBER_CHANGE_CATEGORY): Add a new enumerator to
the diff_category enum.
(EVERYTHING_CATEGORY): In the diff_category, adjust this
enumerator to OR the new HARMLESS_DATA_MEMBER_CHANGE_CATEGORY into
it.
(SUPPRESSED_CATEGORY, PRIVATE_TYPE_CATEGORY)
(SIZE_OR_OFFSET_CHANGE_CATEGORY, VIRTUAL_MEMBER_CHANGE_CATEGORY)
(CLASS_DECL_ONLY_DEF_CHANGE_CATEGORY)
(FN_PARM_TYPE_TOP_CV_CHANGE_CATEGORY)
(FN_RETURN_TYPE_CV_CHANGE_CATEGORY, VAR_TYPE_CV_CHANGE_CATEGORY)
(VOID_PTR_TO_PTR_CHANGE_CATEGORY)
(BENIGN_INFINITE_ARRAY_CHANGE_CATEGORY): Adjust the value of these
enumerators of the diff_category enum.
(class_or_union_diff::{data_members_replaced_by_adms,
ordered_data_members_replaced_by_adms}): Declare new member
functions.
* include/abg-fwd.h (var_decl_wptr): Declare new typedef.
(get_next_data_member, get_first_non_anonymous_data_member)
(find_data_member_from_anonymous_data_member)
(get_absolute_data_member_offset): Declare new functions.
* include/abg-ir.h (struct anonymous_dm_hash): Declare new type.
(anonymous_data_member_sptr_set_type): Declare new typedef.
(class decl_base): Befriend class class_or_union.
(class dm_context_rel): Pimpl-ify this class.
(dm_context_rel::{g,s}et_anonymous_data_member_types): Declare new
member functions.
(var_decl::get_anon_dm_reliable_name): Declare new member
function.
(class var_decl): Make get_absolute_data_member_offset,
get_absolute_data_member_offset be friends of this.
(class_or_union::maybe_fixup_members_of_anon_data_member): Declare
new protected member function.
* src/abg-comp-filter.cc (has_data_member_replaced_by_anon_dm):
Define new function.
(categorize_harmless_diff_node): Use the above.
* src/abg-comparison-priv.h
(class_or_union_diff::priv::{dms_replaced_by_adms_,
changed_var_sptrs_type dms_replaced_by_adms_ordered_}): Add new
data members.
(data_member_comp::compare_data_members): Factorize this out of ...
(data_member_comp::operator()(decl_base_sptr&, decl_base_sptr&)):
... this.
(data_member_comp::operator()(changed_var_sptr&,
changed_var_sptr&)): Add new member function.
(sort_changed_data_members): Declare ...
* src/abg-comparison.cc (sort_changed_data_members): ... new
function.
(get_default_harmless_categories_bitmap): Adjust to take the new
abigail::comparison::HARMLESS_DATA_MEMBER_CHANGE_CATEGORY into
account.
(operator<<(ostream& o, diff_category c)): Likewise.
(class_or_union_diff::ensure_lookup_tables_populated): Handle
Handle the insertion of anonymous data members to replace existing
data members.
(class_or_union_diff::{data_members_replaced_by_adms,
ordered_data_members_replaced_by_adms}): Define new accessors.
(suppression_categorization_visitor::visit_end): Propagate the
SUPPRESSION_CATEGORIZATION_VISITOR from changes to the type of the
data member if the data member doesn't have real local changes.
* src/abg-default-reporter.cc (default_reporter::report): Report
about anonymous data members that replace data members.
* src/abg-ir.cc (struct dm_context_rel::priv): Define new data
structure.
(dm_context_rel::{dm_context_rel, get_is_laid_out,
set_is_laid_out, get_offset_in_bits, set_offset_in_bits,
operator==, operator!=, get_anonymous_data_member,
set_anonymous_data_member}): Define the member functions here as
they are not inline anymore.
(class_or_union::maybe_fixup_members_of_anon_data_member): Define
new member function.
(class_or_union::add_data_member): Use it.
(get_first_non_anonymous_data_member, get_next_data_member)
(get_absolute_data_member_offset)
(find_data_member_from_anonymous_data_member): Define new
functions.
* src/abg-reporter-priv.h
(maybe_report_data_members_replaced_by_anon_dm): Declare ...
* src/abg-reporter-priv.cc
(maybe_report_data_members_replaced_by_anon_dm): ... new function.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Report data
members replaced by anonymous data members.
* tests/data/test-diff-filter/test-PR25661-[1-6]-report-[1-4].txt: New
test reference outputs.
* tests/data/test-diff-filter/test-PR25661-[1-6]-v{0,1}.c: Test
source code files.
* tests/data/test-diff-filter/test-PR25661-[1-6]-v{0,1}.o: Test
binary input files.
* tests/data/Makefile.am: Add the new test files above to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the binary test
inputs above to this test harness.
* tests/data/test-diff-dwarf/test45-anon-dm-change-report-0.txt:
Adjust.
2020-05-07 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: support several anonymous data members in a given class
* include/abg-ir.h (class_or_union::find_anonymous_data_member):
Declare a new member function.
(class_or_union::find_data_member): Declare a new overload.
(var_decl::get_anon_dm_reliable_name): Declare new member
function.
* src/abg-ir.cc (var_decl::get_pretty_representation): Make this
work on a var_decl is going to be used to represent an anonymous
data member even before the var_decl has been added to its finale
scope. This is useful to make class_or_union::find_data_member
work on a var_decl that is to be used as an anonymous data member.
(var_decl::get_anon_dm_reliable_name): Define new member function.
(class_or_union::find_data_member): In the existing overload that
takes a string, look for the named data member inside the
anonymous data members. Define a new overload that takes a
var_decl_sptr, to look for anonymous data members.
(class_or_union::find_anonymous_data_member): Define a new member
function.
(lookup_data_member): Use the existing
class_or_union::find_data_member.
* src/abg-reader.cc: (build_class_decl): Use the full anonymous
variable for lookup, rather than its name which is empty and will
thus give false positives.
* src/abg-dwarf-reader.cc (add_or_update_class_type): Likewise.
* src/abg-comparison.cc
(class_or_union_diff::ensure_lookup_tables_populated): Name
anonymous data members properly - as opposed to wrongly using
their empty name.
* src/abg-reporter-priv.cc (represent): In the overload for
var_diff_sptr, make sure that changes to the /type/ of a variable
declaration are always reported.
* tests/data/test-abidiff-exit/test-member-size-report0.txt:
Adjust as we now emit more detailed changes about anonymous data
members.
* tests/data/test-abidiff-exit/test-member-size-report1.txt:
Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Adjust
to reflect the fact that a class can now have several anonymous
data members.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
2020-05-07 Dodji Seketeli <dodji@redhat.com>
{default,leaf}-reporter: group data members changes reports together
* include/abg-comparison.h
(class_or_union_diff::{sorted_changed_data_members,
count_filtered_changed_data_members,
sorted_subtype_changed_data_members,
count_filtered_subtype_changed_data_members}): Declare ...
* src/abg-comparison.cc
(class_or_union_diff::{sorted_changed_data_members,
count_filtered_changed_data_members,
sorted_subtype_changed_data_members,
count_filtered_subtype_changed_data_members}): ... accessors for
existing private data members.
* src/abg-default-reporter.cc (default_reporter::report): In the
class_or_union_diff& overload, group the reporting of the changes
to data member sub-types with the replacement of data members.
These are just data member changes after all. Use the newly
declared accessors for better measure.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Likewise.
* tests/data/test-diff-dwarf/test45-anon-dm-change-report-0.txt: Adjust.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
2020-05-18 Dodji Seketeli <dodji@redhat.com>
Add -g back to ABIGAIL_DEVEL
* configure.ac: Don't forget to set -g when ABIGAIL_DEVEL is set.
2020-05-15 Giuliano Procida <gprocida@google.com>
clang-format: set continuation indentation to 2
* .clang-format: Set ContinuationIndentWidth to 2.
2020-05-15 Matthias Maennich <maennich@google.com>
configure: add more diagnostic options when ABIGAIL_DEVEL is set
* configure.ac: add -D_FORTIFY_SOURCE=2 and -D_GLIBCXX_DEBUG
compilation defines if ABIGAIL_DEVEL is set. Note that with GCC 4.8.5,
-D_FORTIFY_SOURCE=2 requires options to be set. So I am setting
the optimization level to -Og.
* src/abg-dwarf-reader.cc (read_context::{compute_canonical_die,
get_or_compute_canonical_die, associate_die_to_decl,
set_canonical_die_offset, schedule_type_for_late_canonicalization,
compare_dies}, get_scope_for_die, add_or_update_union_type)
(read_debug_info_into_corpus, build_ir_node_from_die): Initialize
the 'source' variable.
* tests/test-diff-filter.cc (main): Check the return value of the
system function.
* tests/test-diff-pkg.cc (main): Likewise.
* tests/test-read-write.cc (main): Likewise.
2020-05-15 Matthias Maennich <maennich@google.com>
configure: add ABIGAIL_DEBUG options
* configure.ac: add ABIGAIL_DEBUG environment variable for
improved debugging capabilities
2020-05-05 Giuliano Procida <gprocida@google.com>
Tidy get_pretty_representation qualified_name.
* include/abg-ir.h (type_decl::get_pretty_representation)
Change default for qualified_name parameter to true.
2020-05-13 Dodji Seketeli <dodji@redhat.com>
Bug 25986 - Wrong name of function type used in change report
* src/abg-ir.cc (function_type::get_cached_name): Don't cache
names for non-canonicalized types.
* tests/data/test-abidiff-exit/test-fun-param-report.txt: Add
reference output for new test.
* tests/data/test-abidiff-exit/test-fun-param-v{0,1}.abi: Add new test
input files.
* tests/data/test-abidiff-exit/test-fun-param-v{0,1}.c: Add source
files for the above.
* tests/data/test-abidiff-exit/test-fun-param-v{0,1}.o: Add
binaries for the above.
2020-05-11 Mark Wielaard <mark@klomp.org>
Don't iterate before the start of a RandomAccessOutputIterator.
* include/abg-diff-utils.h (compute_diff): Put brackets around
p[ux].[xy]() + 1 calculation.
2020-05-12 Giuliano Procida <gprocida@google.com>
doc: Fix sufficient suppression property lists.
* doc/manuals/libabigail-concepts.rst: Add missing
sufficient properties for suppress_file, suppress_function and
suppress_variable. Use consistent language about what will
happen when no property in the list in provided.
2020-05-11 Matthias Maennich <maennich@google.com>
cxx-compat: add test suite for cxx-compat
* tests/Makefile.am: Add new test case runtestcxxcompat.
* tests/test-cxx-compat.cc: New test source file.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-05-11 Matthias Maennich <maennich@google.com>
dwarf-reader: read_context: drop some unused accessor methods
* src/abg-dwarf-reader.cc (read_context::fun_syms_sptr): Delete method.
(read_context::fun_syms): Likewise.
(read_context::var_syms_sptr): Likewise.
(read_context::var_syms): Likewise.
(read_context::undefined_fun_syms_sptr): Likewise.
(read_context::undefined_fun_syms): Likewise. Both overloads.
(read_context::undefined_var_syms_sptr): Likewise.
(read_context::undefined_var_syms): Likewise. Both overloads.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-05-11 Matthias Maennich <maennich@google.com>
tests/.gitignore: ignore all files starting with runtest*
* tests/.gitignore: gitignore all files named runtest*
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-05-11 Matthias Maennich <maennich@google.com>
configure: set -Wno-error-overloaded-virtual for clang builds
* configure.ac: set -Wno-error-overloaded-virtual for clang++
2020-05-05 Giuliano Procida <gprocida@google.com>
Let std::unordered_map::operator[] insert keys.
* src/abg-reader.cc (read_context::key_type_decl): Rely on
std::unordered_map::operator[] to create map entries if they
are missing. (build_elf_symbol_db): Ditto.
2020-05-05 Giuliano Procida <gprocida@google.com>
abg-reader.cc: Remove key_replacement_type_map.
* src/abg-reader.cc (key_replacement_type_map): Drop unused
function.
2020-05-04 Giuliano Procida <gprocida@google.com>
Refactor read_parameter_spec_from_string logic.
* src/abg-suppression.cc (read_parameter_spec_from_string):
Use separate string and regex variables to simplify the
creation of returned parameter specification.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-04 Giuliano Procida <gprocida@google.com>
Use regex::match wrapper instead of regexec.
* src/abg-corpus-priv.h: Mechanically substitute use of
regexec with regex::match wrapper.
* src/abg-suppression-priv.h: Ditto.
* src/abg-suppression.cc: Ditto.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-12 Giuliano Procida <gprocida@google.com>
Tidy checks for sufficient suppression properties.
* src/abg-suppression.cc (check_sufficient_props): New helper
function to check for sufficient properties in a section.
(read_type_suppression): Replace conditional logic with call
to check_sufficient_props.
(read_function_suppression): Ditto.
(read_variable_suppression): Ditto.
(read_file_suppression): Ditto.
* tests/data/test-diff-suppr/test15-suppr-added-fn-4.suppr:
Explain why the suppression will be ignored.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-4.suppr:
Ditto.
* tests/data/test-diff-suppr/test17-suppr-added-var-4.suppr:
Ditto.
* tests/data/test-diff-suppr/test18-suppr-removed-var-4.suppr:
Ditto.
2020-05-12 Dodji Seketeli <dodji@redhat.com>
Bug 25977 - runtestabidiffexit regression on EL7
* abg-comparison.cc:
(suppression_categorization_visitor::visit_end): Don't suppress
the entire class of equivalence of a function diff node if that
function diff node itself was not suppressed.
2020-05-04 Giuliano Procida <gprocida@google.com>
Use regex::compile wrapper instead of regcomp.
* src/abg-corpus-priv.h: Mechanically substitute use of
regcomp with regex::compile wrapper.
* src/abg-suppression-priv.h: Ditto.
There are no behavioural changes.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-04 Giuliano Procida <gprocida@google.com>
Add POSIX regex wrapper functions.
* include/abg-regex.h (compile): Declare new function.
(match): Declare new function.
* src/abg-regex.cc (compile): Add new function wrapping
regcomp. (match): Add new function wrapping regexec.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-04 Giuliano Procida <gprocida@google.com>
abg-suppression.cc: More uniform variable naming.
* src/abg-suppression.cc (read_type_suppression): Rename "nil"
variable to "result" and reset it instead of introducing
"suppr" later on. (read_function_suppression): Rename "nil"
variable to "result" and reset it instead of introducing
"result" later on.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-04 Giuliano Procida <gprocida@google.com>
Escape names used in symbol whitelisting regex.
* include/regex.h (escape): New string reference holder
class. (operator<<): Declaration of std::ostream,
regex::escape overload.
* include/regex.cc (operator<<): New std::ostream,
regex::escape overload that outputs regex-escaped strings.
* src/abg-tools-utils.cc
(gen_suppr_spec_from_kernel_abi_whitelists): Make sure any
special regex characters in symbol names are escaped.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-04 Giuliano Procida <gprocida@google.com>
Document ^_^ regex in generate_from_strings.
* src/abg-regex.cc (generate_from_strings): Document ^_^
regex.
2020-05-04 Giuliano Procida <gprocida@google.com>
Tidy #includes in a few files.
* src/abg-corpus-priv.h: Separate and sort #include
directives.
* src/abg-corpus.cc: Ditto.
* src/abg-regex.cc: Ditto.
* src/abg-suppression-priv.h: Ditto.
* src/abg-suppression.cc: Ditto.
2020-05-01 Giuliano Procida <gprocida@google.com>
Hoist some common expressions evaluating offsets.
* src/abg-suppression.cc (type_suppression::suppresses_diff):
Hoist some constant expressions out of loops.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-01 Giuliano Procida <gprocida@google.com>
Make set_drops_artifact_from_ir non-const.
* include/abg-suppression.h
(suppression_base::set_drops_artifact_from_ir):
Drop const qualifier.
* src/abg-suppression.cc
(suppression_base::set_drops_artifact_from_ir):
Drop const qualifier.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-01 Giuliano Procida <gprocida@google.com>
Eliminate redundant conditional operators.
* src/abg-corpus.cc (corpus::priv::build_unreferenced_symbols_tables):
Eliminate redundant conditional operator.
* src/abg-dwarf-reader.cc (build_reference_type): Ditto.
* src/abg-reader.cc (read_static): Ditto.
(read_is_artificial): Ditto. (build_function_parameter):
Ditto. (build_function_decl): Ditto.
(build_qualified_type_decl): Ditto.
(build_reference_type_def): Ditto.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-01 Giuliano Procida <gprocida@google.com>
Remove stray semicolons.
* include/abg-diff-utils.h (display_edit_script): Remove
redundant semicolon.
* include/abg-fwd.h (lookup_basic_type): Ditto.
* src/abg-comparison.cc (mark_diff_as_visited):
Ditto. (array_diff::has_local_changes): Ditto.
(class_diff::ensure_lookup_tables_populated): Ditto.
* src/abg-corpus.cc
(corpus::priv::build_unreferenced_symbols_tables): Ditto.
* src/abg-default-reporter.cc (default_reporter::report):
Ditto.
* src/abg-dwarf-reader.cc (finish_member_function_reading):
Ditto.
* src/abg-ir.cc (is_compatible_with_class_type): Ditto.
(enum_type_decl::enumerator::set_name): Ditto.
* src/abg-reader.cc (read_corpus_from_input): Ditto.
(build_function_type): Ditto.
* src/abg-suppression.cc (type_suppression::suppresses_type):
Ditto.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-05-01 Giuliano Procida <gprocida@google.com>
Remove excess whitespace.
* src/abg-suppression.cc: Eliminate double blank lines.
(read_parameter_spec_from_string): Eliminate space between
++ operator and its operand.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-01-12 Matthias Maennich <maennich@google.com>
corpus/writer: sort emitted translation units by path name
* include/abg-fwd.h: remove translation_units fwd declaration.
* include/abg-ir.h (struct shared_translation_unit_comparator):
Define new class.
(translation_units): Define new typedef.
* src/abg-corpus.cc (corpus::add): do checked insert into the
translation_units set (rather than vector::push_back)
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust test data.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
2020-04-29 Matthias Maennich <maennich@google.com>
tests: reorder test execution to optimize 'make check' runtime
* tests/Makefile.am(TESTS): split up in expensive and non
expensive tests, sort the expensive ones by runime, the cheap
ones alphabetically
2020-04-29 Matthias Maennich <maennich@google.com>
test-types-stability: parallelize test case alternatives
* tests/test-types-stability.cc (test_task): add field no_default_sizes
(test_task::perform) Switch on the new flag to test a different
behaviour.
(main): Schedule an additional test case to test with the new flag.
Cc: Mark Wielaard <mark@klomp.org>
2020-05-04 Dodji Seketeli <dodji@redhat.com>
Fix compilation with g++ 4.8.5 on el7
* include/abg-libxml-utils.h (build_sptr<xmlTextReader>): Wrap
this specialization in the namespace sptr_utils and do away with
the sptr_utils qualifier.
* include/abg-regex.h (build_sptr<regex_t>): Likewise.
2020-04-24 Giuliano Procida <gprocida@google.com>
Simplify generation of symbol whitelist regex.
* include/abg-regex.h (generate_from_strings): Declare new
function to build a regex from some strings, representing a
membership test.
* src/abg-regex.cc (generate_from_strings): Implement new
function to build a regex from some strings, representing a
membership test, in a straightfoward fashion.
* src/abg-tools-utils.cc
(gen_suppr_spec_from_kernel_abi_whitelists): Replace
regex-building code with a call to generate_from_strings.
* tests/test-kmi-whitelist.cc: Update regexes in test.
2020-04-24 Giuliano Procida <gprocida@google.com>
Move libxml bits out of abg-sptr-utils.h.
* include/abg-sptr-utils.h: Remove reader_sptr and
xml_char_sptr typedefs, from namespace
sptr_utils. (build_sptr): Remove corresponding template
function specialisations for these types.
* include/abg-libxml-utils.h: Add reader_sptr and
xml_char_sptr typedefs, to namespace xml. (build_sptr): Add
corresponding template function specialisations for these
types.
2020-04-24 Giuliano Procida <gprocida@google.com>
Move regex definitions to own files.
* include/Makefile.am: Add abg-regex.h.
* src/Makefile.am: Remove abg-sptr-utils.h, add abg-regex.cc
* include/abg-sptr-utils.h (regex_t_sptr): Remove this
typedef, from namespace abigail::sptr_utils.
(regex_t_deleter): Remove this struct, from namespace
abigail::sptr_utils. (build_sptr): Remove these template
specialisations, in duplicate, for regex_t_sptr.
* include/abg-regex.h: New file, introduces namespace
abigail::regex. (regex_t_sptr): Add this typedef, to namespace
abigail::regex. (regex_t_deleter): Add this struct, to
namespace abigail::regex. (build_sptr): Add these template
specialisations for regex_t_sptr
* src/abg-sptr-utils.cc: Remove this file.
* src/abg-regex.cc: Add new file with contents effectively
the same as abg-sptr-utils.cc.
* src/abg-corpus-priv.h: Update regex_t_sptr namespace
qualification.
* src/abg-corpus.cc: Ditto.
* src/abg-suppression-priv.h: Ditto.
* src/abg-suppression.cc: Ditto.
2020-04-27 Mark Wielaard <mark@klomp.org>
Add --no-write-default-sizes option.
* doc/manuals/abidw.rst: Document --no-write-default-sizes.
* include/abg-writer.h (set_write_default_sizes): New function
declaration.
(set_common_options): Call set_write_default_sizes.
* src/abg-reader.cc (build_function_decl): Get default size.
(build_pointer_type_def): Likewise.
(build_reference_type_def): Likewise.
(build_function_type): Likewise.
* src/abg-writer.cc (write_context): Add m_write_default_sizes
bool.
(get_write_default_sizes): New method.
(set_write_default_sizes): Likewise.
(write_size_and_alignment): Add default size and alignment
parameters.
(set_write_default_sizes): New function.
(write_type_decl): Set default size and alignment.
(write_pointer_type_def): Likewise.
(write_reference_type_def): Likewise.
(write_function_decl): Likewise.
(write_function_type): Likewise.
(write_class_decl_opening_tag): Likewise.
(write_union_decl_opening_tag): Likewise.
* tests/test-types-stability.cc (perform): Also test --abidiff
with --no-write-default-sizes.
* tools/abidw.cc (option): Add default_sizes bool.
(parse_command_line): Parse --no-write-default-sizes.
(display_usage): Add doc string for --no-write-default-sizes.
2020-04-26 Mark Wielaard <mark@klomp.org>
Rename read_elf_symbol_binding to read_elf_symbol_visibility.
* src/abg-reader.cc (read_elf_symbol_binding): Renamed to...
(read_elf_symbol_visibility): ...this.
2020-04-22 Giuliano Procida <gprocida@google.com>
abidiff: Omit declaration-only type size 0 diffs.
* src/abg-reporter-priv.cc (report_size_and_alignment_changes):
Filter out declaration-only / defined type size changes
unconditionally.
* tests/data/test-abidiff-exit/test-decl-struct-report.txt:
Update test.
2020-04-22 Giuliano Procida <gprocida@google.com>
abidiff: Blank line after declaration-only diff.
* src/abg-default-reporter.cc (default_reporter::report): In
the class_or_union_diff overload, emit a new line at the end
of the declaration-only reporting path.
* tests/data/test-abidiff-exit/test-decl-struct-report.txt:
Add missing blank lines.
2020-04-22 Giuliano Procida <gprocida@google.com>
Add tests for declaration-only struct diffs.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-decl-struct-report.txt:
New test case generating "declaration-only" output.
* tests/data/test-abidiff-exit/test-decl-struct-v0.c: Ditto.
* tests/data/test-abidiff-exit/test-decl-struct-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-decl-struct-v1.c: Ditto.
* tests/data/test-abidiff-exit/test-decl-struct-v1.o: Ditto.
* tests/test-abidiff-exit.cc: Run new test case.
2020-04-24 Mark Wielaard <mark@klomp.org>
Add --no-elf-needed option to drop DT_NEEDED list from corpus.
* doc/manuals/abidw.rst: Document --no-elf-needed.
* include/abg-writer.h (set_write_elf_needed): New function.
(set_common_options): Call it.
* src/abg-writer.cc (write_context::m_write_elf_needed): New data
member.
(write_context::{g,s}et_write_elf_needed): Add new accessors.
(set_write_elf_needed): New function.
(write_context::write_corpus): Check write_elf_needed.
* tools/abidw.cc (options): Add write_elf_needed bool.
(display_usage): Describe --no-elf-needed.
(parse_command_line): Parse --no-elf-needed.
2020-04-21 Mark Wielaard <mark@klomp.org>
Add no-parameter-names to drop function parameter names.
* doc/manuals/abidw.rst: Add documentation for --no-parameter-names.
* include/abg-writer.h (set_write_parameter_names): New function.
(set_write_parameter_names): Call it.
* src/abg-writer.cc (write_context): Add m_write_parameter_names
bool, get_write_parameter_names and set_write_parameter_names
functions.
(write_context::write_function_decl): Check write_parameter_names.
* tools/abidw.cc (options): Add write_parameter_names.
(display_usage): Describe --no-parameter-names.
(parse_command_line): Parse --no-parameter-names.
2020-04-24 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: Fix race condition while using private types suppr specs
* tools/abipkgdiff.cc (compare_args::private_types_suppr{1,2}):
Make these data member *not* be a reference anymore.
(maybe_create_private_types_suppressions): Rename this into ...
(create_private_types_suppressions): ... this. Also, make this
function return a copy of the vector of suppression specifications
for private types created.
(compare_prepared_userspace_packages): Use the new
create_private_types_suppressions to create a copy of private
types suppression specifications, rather than sharing it from
package::private_types_suppressions_.
(extract_package_and_map_its_content): Adjust to avoid creating
the shared suppression specifications for private types.
(package::private_types_suppressions_): Remove this data member
that was holding the shared suppressions for private types.
(package::private_types_suppressions): Remove these accessors.
2020-04-22 Giuliano Procida <gprocida@google.com>
test24-soname-suppr*txt: Fix suppression syntax.
* tests/data/test-diff-suppr/test24-soname-suppr-0.txt: Fix
typo, change "reached_through" to "accessed_through".
* tests/data/test-diff-suppr/test24-soname-suppr-1.txt: Ditto.
* tests/data/test-diff-suppr/test24-soname-suppr-2.txt: Ditto.
* tests/data/test-diff-suppr/test24-soname-suppr-3.txt: Ditto.
* tests/data/test-diff-suppr/test24-soname-suppr-4.txt: Ditto.
2020-04-20 Giuliano Procida <gprocida@google.com>
test35-leaf.suppr: fix regex typo.
* tests/data/test-diff-suppr/test35-leaf.suppr: Fix typo in
regex, "*." -> ".*".
2020-04-21 Matthias Maennich <maennich@google.com>
abg-elf-helpers: migrate maybe_adjust_et_rel_sym_addr_to_abs_addr
* src/abg-dwarf-reader.cc
(maybe_adjust_et_rel_sym_addr_to_abs_addr)
(drop the wrapped overload completely): Move out functions.
* src/abg-elf-helpers.cc
(maybe_adjust_et_rel_sym_addr_to_abs_addr): New function.
* src/abg-elf-helpers.h
(maybe_adjust_et_rel_sym_addr_to_abs_addr): New function
declaration.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-04-21 Matthias Maennich <maennich@google.com>
abg-elf-helpers: migrate more elf helpers (architecture specific helpers)
* src/abg-dwarf-reader.cc (elf_architecture_is_ppc64): Move
function out and adjust callers to call the migrated
functions.
(elf_architecture_is_big_endian): Likewise.
(architecture_word_size): Likewise.
(current_elf_file_is_executable): Likewise.
(current_elf_file_is_dso): Likewise.
* src/abg-elf-helpers.cc (architecture_is_ppc64): Add new function.
(architecture_is_big_endian): Likewise.
(get_architecture_word_size): Likewise.
(is_executable): Likewise.
(is_dso): Likewise.
* src/abg-elf-helpers.h (architecture_is_ppc64): Add new declaration.
(architecture_is_big_endian): Likewise.
(get_architecture_word_size): Likewise.
(is_executable): Likewise.
(is_dso): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-04-21 Matthias Maennich <maennich@google.com>
abg-dwarf-reader: migrate more ELF helpers to elf-helpers
* src/abg-dwarf-reader.cc (read_context::{opd_section_,
ksymtab_section_, ksymtab_reloc_section_, ksymtab_gpl_section_,
ksymtab_gpl_reloc_section_, ksymtab_strings_section_}): Make these
data members mutable as they are set by their getter member
functions, as an implementation detail.
(read_context::find_symbol_table_section):
adjust to new interface of elf_helpers::find_symbol_table_section.
(find_opd_section): use elf_helpers::find_opd_section for lookup.
(find_ksymtab_section): use elf_helpers::find_ksymtab_section.
(find_ksymtab_gpl_section): use elf_helpers::find_ksymtab_gpl_section.
(find_relocation_section): Move out function.
(get_binary_load_address): Move out function.
(find_ksymtab_reloc_section): use elf_helpers::find_relocation_section
(find_ksymtab_gpl_reloc_section): use
elf_helpers::find_relocation_section
* src/elf-helpers.cc (find_symbol_table_section): change
interface to match other find_*_section functions.
(find_symbol_table_section_index): Adjust for the new interface of
find_symbol_table_section.
(find_opd_section): New function.
(find_ksymtab_section): New function.
(find_ksymtab_gpl_section): New function.
(find_relocation_section): New function.
(get_binary_load_address): New function.
* src/elf-helpers.h (find_symbol_table_section): Change declaration.
(find_opd_section): New function declaration.
(find_ksymtab_section): New function declaration.
(find_ksymtab_gpl_section): New function declaration.
(find_relocation_section): New function declaration.
(get_binary_load_address): New function declaration.
2020-04-21 Matthias Maennich <maennich@google.com>
abg-elf-helpers: consolidate the is_linux_kernel* helpers
* src/abg-dwarf-reader.cc
(read_context::function_symbol_is_exported): use is_linux_kernel
from elf_helpers.
(read_context::variable_is_exported): Likewise.
(read_context::get_symtab_format): Likewise.
(read_context::load_symbol_maps): Likewise.
(read_debug_info_into_corpus): Likewise.
(read_context::is_linux_kernel_binary): Drop function.
(read_context::is_linux_kernel_module): Drop function.
* src/abg-elf-helpers.cc (binary_is_linux_kernel): rename to
is_linux_kernel
(binary_is_linux_kernel_module): rename to is_linux_kernel_module
(find_ksymtab_strings_section): Adjust to function renames.
* src/abg-elf-helpers.h (binary_is_linux_kernel): rename to
is_linux_kernel
(binary_is_linux_kernel_module): rename to is_linux_kernel_module
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-04-21 Matthias Maennich <maennich@google.com>
abg-elf-helpers: move some kernel helpers from abg-dwarf-reader
* abg-dwarf-reader.cc (binary_is_linux_kernel): Move function out.
(binary_is_linux_kernel_module): Likewise.
(find_ksymtab_strings_section): Likewise.
* abg-elf-helpers.cc (binary_is_linux_kernel): Move function in.
(binary_is_linux_kernel_module): Likewise.
(find_ksymtab_strings_section): Likewise.
* abg-elf-helpers.h (binary_is_linux_kernel): Add declaration.
(binary_is_linux_kernel_module): Likewise.
(find_ksymtab_strings_section): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-04-21 Matthias Maennich <maennich@google.com>
abg-elf-helpers: move some versioning helpers from abg-dwarf-reader
* abg-dwarf-reader.cc (get_symbol_versionning_sections): Move function out.
(get_version_definition_for_versym): Likewise.
(get_version_needed_for_versym): Likewise.
(get_version_for_symbol): Likewise.
* abg-elf-helpers.cc (get_symbol_versionning_sections): Move function in.
(get_version_definition_for_versym): Likewise.
(get_version_needed_for_versym): Likewise.
(get_version_for_symbol): Likewise.
* abg-elf-helpers.h (get_symbol_versionning_sections): Add declaration.
(get_version_definition_for_versym): Likewise.
(get_version_needed_for_versym): Likewise.
(get_version_for_symbol): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-04-21 Matthias Maennich <maennich@google.com>
abg-elf-helpers: move some elf helpers from abg-dwarf-reader
* abg-dwarf-reader.cc (stt_to_elf_symbol_type): Move function out.
(stb_to_elf_symbol_binding): Likewise.
(stv_to_elf_symbol_visibility): Likewise.
(e_machine_to_string): Likewise.
(find_section): Likewise.
(find_symbol_table_section): Likewise.
(find_symbol_table_section_index): Likewise.
(enum hash_table_kind): Likewise.
(find_hash_table_section_index): Likewise.
(get_symbol_versionning_sections): Likewise.
(find_text_section): Likewise.
(find_bss_section): Likewise.
(find_rodata_section): Likewise.
(find_data_section): Likewise.
(find_data1_section): Likewise.
* abg-elf-helpers.cc (stt_to_elf_symbol_type): Move function in.
(stb_to_elf_symbol_binding): Likewise.
(stv_to_elf_symbol_visibility): Likewise.
(e_machine_to_string): Likewise.
(find_section): Likewise.
(find_symbol_table_section): Likewise.
(find_symbol_table_section_index): Likewise.
(enum hash_table_kind): Likewise.
(find_hash_table_section_index): Likewise.
(get_symbol_versionning_sections): Likewise.
(find_text_section): Likewise.
(find_bss_section): Likewise.
(find_rodata_section): Likewise.
(find_data_section): Likewise.
(find_data1_section): Likewise.
* abg-elf-helpers.h (stt_to_elf_symbol_type): Add declaration.
(stb_to_elf_symbol_binding): Likewise.
(stv_to_elf_symbol_visibility): Likewise.
(e_machine_to_string): Likewise.
(find_section): Likewise.
(find_symbol_table_section): Likewise.
(find_symbol_table_section_index): Likewise.
(enum hash_table_kind): Likewise.
(find_hash_table_section_index): Likewise.
(get_symbol_versionning_sections): Likewise.
(find_text_section): Likewise.
(find_bss_section): Likewise.
(find_rodata_section): Likewise.
(find_data_section): Likewise.
(find_data1_section): Likewise.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-04-21 Matthias Maennich <maennich@google.com>
abg-dwarf-reader split: create abg-elf-helpers.{h,cc} and test case
* src/Makefile.am: Add new source files abg-elf-helpers.{h,cc}.
* src/abg-elf-helpers.cc: New source file.
* src/abg-elf-helpers.h: New header file.
* tests/.gitignore: Exclude runtestelfhelpers from being committed.
* tests/Makefile.am: Add new test case runtestelfhelpers.
* tests/test-elf-helpers.cc: New test source file.
Reviewed-by: Giuliano Procida <gprocida@google.com>
2020-04-20 Matthias Maennich <maennich@google.com>
tests: parallelize diff-suppr test
* tests/test-diff-suppr.cc(main): parallelize test execution.
(test_task) new abigail::workers::task implementation to run
test cases in this test as separate worker tasks.
2020-04-20 Matthias Maennich <maennich@google.com>
abg-dwarf-reader: simplify symbol map update
* src/abg-dwarf-reader.cc
(read_context::load_symbol_maps_from_symtab_section): simplify
symbol map update for fun_syms_, undefined_fun_syms_, var_syms_,
undefined_var_syms_.
2020-04-20 Matthias Maennich <maennich@google.com>
make: add distcheck-fast target
* Makefile.am: add distcheck-fast make target
2020-04-14 Giuliano Procida <gprocida@google.com>
Fix variable suppression name_not_regex.
* src/abg-suppression-priv.h: In get_symbol_name_not_regex
method of variable_suppression::priv, fix typo causing
miscompilation of regex.
2020-04-13 Mark Wielaard <mark@klomp.org>
Add --drop-undefined-syms to abidw.
* include/abg-dwarf-reader.h (set_drop_undefined_syms):
New declaration.
* src/abg-dwarf-reader.cc (class read_context): Add private
bool drop_undefined_syms_.
(drop_undefined_syms): New getter and setter method.
(set_drop_undefined_syms): New function.
(function_is_suppressed): Check drop_undefined_syms on
read_context.
(variable_is_suppressed): Likewise.
* src/abg-reader.cc (read_context): Add private bool
m_drop_undefined_syms.
(drop_undefined_syms): New getter and setter method.
* tools/abidw.cc (struct options): Add drop_undefined_syms.
(display_usage): Print --drop-undefined-syms.
(parse_command_line): Parse --drop-undefined-syms.
(main): Call set_drop_undefined_syms.
2020-04-12 Mark Wielaard <mark@klomp.org>
Add --drop-private-types to abidw.
* tools/abidw.cc (options): Add drop_private_types bool.
(display_usage): Add --drop-private-types.
(parse_command_line): Parse --drop-private-types, set opts.
(set_suppressions): Call set_drops_artifact_from_ir when
drop_private_types set.
* doc/manuals/abidw.rst: Document --drop-private-types.
2020-04-12 Mark Wielaard <mark@klomp.org>
Add --header-file option to add individual public header files.
* include/abg-tools-utils.h (gen_suppr_spec_from_headers): Add
hdr_files string vector argument.
* src/abg-tools-utils.cc (handle_file_entry): New function that
adds one specific file to the type_suppression. Implementation
lifted from...
(handle_fts_entry): ...here. Call handle_file_entry for each file.
(gen_suppr_spec_from_headers): Also takes a header_files string
vector as argument. Call handle_file_entry for each file entry.
* tools/abidiff.cc (options): Add header_files1 and header_files2
string vectors.
(display_usage): Print --header-file1 and --header-file2 usage.
(parse_command_line): Handle --header-file1, --hf1 and
--header-file2, --hf2.
(set_diff_context_from_opts): Call gen_suppr_spec_from_headers
with header_files1 and header_files2.
(set_suppressions): Likewise.
* tools/abidw.cc (options): Add header_files string vector.
(display_usage): Print --header-file usage.
(parse_command_line): Handle --header-file1, --hf1.
(maybe_check_header_files): New function.
(set_suppressions): Call gen_suppr_spec_from_headers with
header_files.
(main): Call maybe_check_header_files.
* tools/abilint.cc (options): Add header_files string vector.
(display_usage): Print --header-file usage.
(parse_command_line): Handle --header-file1, --hf1.
(set_suppressions): Call gen_suppr_spec_from_headers with
header_files.
* doc/manuals/abidiff.rst: Document --header-file1, --hf1 and
--header-file2, --hf2. Add new options to documentation of
--drop-private-types.
* doc/manuals/abidw.rst: Document --header-file, --hf.
* doc/manuals/abilint.rst: Likewise.
2020-04-08 Giuliano Procida <gprocida@google.com>
abidiff: Document and refresh tests.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v1.cc:
Comment test. Reorder members of ops to get better coverage.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v1.cc:
Comment test.
* tests/data/test-abidiff-exit/test-leaf-more-v1.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf-peeling-v1.cc:
Comment test. Update comment on ops2.
* tests/data/test-abidiff-exit/test-leaf-redundant-v1.c:
Comment test.
* tests/data/test-abidiff-exit/test-leaf-stats-v1.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-report.txt:
Update locations. Update report to reflect deletion,
insertion and changed members (was previously changed only).:
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt:
Update locations.
* tests/data/test-abidiff-exit/test-leaf-redundant-report.txt:
Ditto.:
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v0.cc:
Added one line comment referring to -v1 source file.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v0.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf-more-v0.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf-peeling-v0.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf-redundant-v0.c: Ditto.
* tests/data/test-abidiff-exit/test-leaf-stats-v0.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v0.o: Recompiled.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v1.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v1.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-more-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-more-v1.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-peeling-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-peeling-v1.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-redundant-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-redundant-v1.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-stats-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf-stats-v1.o: Ditto.
2020-04-14 Giuliano Procida <gprocida@google.com>
abg-reporter-priv.cc: Improve readability of represent helper function.
* src/abg-reporter-priv.cc (represent): In the var_diff_sptr
overload, rename pretty_representation to o_pretty_representation,
introduce n_pretty_representation where needed and replace the
duplicate tr1 and tr2 with these; rename all other variables foo1
and foo2 to o_foo and n_foo respectively, using _type instead of
_t; introduce o_anon and n_anon and use them to make the local
variable is_strict_anonymous_data_member_change const, make
ABG_ASSERT in anonymous data member handling more obvious in the
case where anonymity has changed and allow simplification of
formatting in this case; move declarations of const local
variables above those of the non-const, state-tracking, variables.
2020-04-07 Giuliano Procida <gprocida@google.com>
abg-reporter-priv.cc: Fix anonymous member size change reports.
* src/abg-reporter-priv.cc (represent): In the var_diff_sptr
overload, factor out some expressions as local variables, rely
on diff_to_be_reported to decide whether to emit a change,
fold together local/non-local change reporting using
local_changes to preserve current name formatting differences,
keep track explicitly of whether size information has been
emitted and ensure it happens if needed, make offset and size
change reporting for anonymous data members more meaningful.
* tests/test-abidiff-exit.cc: Run new test cases.
* tests/data/Makefile.am: Add new test files.
* tests/data/test-abidiff-exit/test-member-size-v0.cc: New
test.
* tests/data/test-abidiff-exit/test-member-size-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-member-size-v1.cc: Ditto.
* tests/data/test-abidiff-exit/test-member-size-v1.o: Ditto.
* tests/data/test-abidiff-exit/test-member-size-report0.txt:
New test, default mode.
* tests/data/test-abidiff-exit/test-member-size-report1.txt:
New test, --leaf-changes-only mode.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-report.txt:
Eliminate duplicate reporting of member sizes.
* tests/data/test-abidiff-exit/test-leaf-more-report.txt: Ditto.
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt:
Ditto.
* tests/data/test-abidiff-exit/test-no-stray-comma-report.txt:
Ditto.
* tests/data/test-diff-dwarf/test45-anon-dm-change-report-0.txt:
Add size report for anonymous data member.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-0.txt:
Ditto.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Add missing size change report.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Remove
size change report for previously reported type.
* tests/data/test-diff-suppr/test46-PR25128-report-1.txt:
Eliminate duplicate reporting of member size change.
* tests/data/test-diff-suppr/test46-PR25128-report-2.txt:
Ditto.
2020-04-07 Giuliano Procida <gprocida@google.com>
abidiff: More compact references to prior diffs.
* src/abg-reporter-priv.cc (represent): In the var_diff_sptr
overload, use consistent punctuation and keep to a single line
of output when referring back to an existing type diff report.
Remove unnecessary braces around single line conditional
blocks.
* src/abg-reporter-priv.h: In the macro
RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER, use
consistent punctuation when referring back to an existing type
diff report.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust
formatting of back references to existing type diff reports.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
Ditto.
* tests/data/test-diff-filter/test16-report-2.txt: Ditto.
* tests/data/test-diff-filter/test17-1-report.txt: Ditto.
* tests/data/test-diff-filter/test25-cyclic-type-report-1.txt:
Ditto.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Ditto.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Ditto.
2020-04-06 Giuliano Procida <gprocida@google.com>
test-abidiff-exit.cc: Drop redundant --redundant.
* tests/test-abidiff-exit.cc: Drop obsolete --redundant flag
and comment as --redundant is now implied by
--leaf-changes-only.
2020-04-06 Giuliano Procida <gprocida@google.com>
Rename test-abidiff-exit/test-leaf[0-3] files.
* tests/data/Makefile.am: Rename test files.
* tests/test-abidiff-exit.cc: Rename test files.
* tests/data/test-abidiff-exit/test-leaf-fun-type-report.txt:
Renamed from test-leaf2-report.txt.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v0.cc:
Renamed from test-leaf2-v0.cc.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v0.o:
Renamed from test-leaf2-v0.o.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v1.cc:
Renamed from test-leaf2-v1.cc.
* tests/data/test-abidiff-exit/test-leaf-fun-type-v1.o:
Renamed from test-leaf2-v1.o.
* tests/data/test-abidiff-exit/test-leaf-more-report.txt:
Renamed from test-leaf1-report.txt.
* tests/data/test-abidiff-exit/test-leaf-more-v0.cc: Renamed
from test-leaf1-v0.cc.
* tests/data/test-abidiff-exit/test-leaf-more-v0.o: Renamed
from test-leaf1-v0.o.
* tests/data/test-abidiff-exit/test-leaf-more-v1.cc: Renamed
from test-leaf1-v1.cc.
* tests/data/test-abidiff-exit/test-leaf-more-v1.o: Renamed
from test-leaf1-v1.o.
* tests/data/test-abidiff-exit/test-leaf-redundant-report.txt:
Renamed from test-leaf3-report.txt.
* tests/data/test-abidiff-exit/test-leaf-redundant-v0.c:
Renamed from test-leaf3-v0.c.
* tests/data/test-abidiff-exit/test-leaf-redundant-v0.o:
Renamed from test-leaf3-v0.o.
* tests/data/test-abidiff-exit/test-leaf-redundant-v1.c:
Renamed from test-leaf3-v1.c.
* tests/data/test-abidiff-exit/test-leaf-redundant-v1.o:
Renamed from test-leaf3-v1.o.
* tests/data/test-abidiff-exit/test-leaf-stats-report.txt:
Renamed from test-leaf0-report.txt.
* tests/data/test-abidiff-exit/test-leaf-stats-v0.cc: Renamed
from test-leaf0-v0.cc.
* tests/data/test-abidiff-exit/test-leaf-stats-v0.o: Renamed
from test-leaf0-v0.o.
* tests/data/test-abidiff-exit/test-leaf-stats-v1.cc: Renamed
from test-leaf0-v1.cc.
* tests/data/test-abidiff-exit/test-leaf-stats-v1.o: Renamed
from test-leaf0-v1.o.
2020-04-07 Dodji Seketeli <dodji@redhat.com>
Update the mailing list registration form on the web page
* doc/website/mainpage.txt: Use the form at
https://sourceware.org/mailman/listinfo/libabigail to register to
the mailing list.
2020-03-30 Giuliano Procida <gprocida@google.com>
abg-dwarf-reader.cc: Avoid division by zero.
* src/abg-dwarf-reader.cc (perform_late_type_canonicalizing):
If total is zero, don't try to output percentages using it as
a divisor.
2020-03-29 Giuliano Procida <gprocida@google.com>
abidiffpkg: Remove stray test report file.
* tests/data/Makefile.am: Removed
tests/data/test-diff-pkg/dirpkg-2-report-1.txt.
* tests/data/test-diff-pkg/dirpkg-2-report-1.txt: Removed.
2020-03-29 Giuliano Procida <gprocida@google.com>
test-diff-suppr.cc: Add missing tests.
* tests/test-diff-suppr.cc: Add stanzas for
test6-fn-suppr-report-4, test16-suppr-removed-fn-report-5 and
test22-suppr-removed-var-sym-report-5 and
test23-alias-filter-report-4 tests.
* tests/data/test-diff-suppr/test6-fn-suppr-report-4.txt:
Number parameters from 1 and update expected output to current
formatting.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-5.txt:
Update expected output to current formatting.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-report-5.txt:
Update expected output to current formatting.
2020-03-29 Giuliano Procida <gprocida@google.com>
abidiff: Remove blank line after typedef changes.
* include/abg-reporter.h
(default_reporter::report_local_typedef_changes): Change
return type to void.
* src/abg-default-reporter.cc:
(default_reporter::report_local_typedef_changes): Change
return type to void, remove emit_nl state variable and logic.
* tests/data/test-abidiff/test-PR18791-report0.txt: Remove
blank lines.
* tests/data/test-diff-dwarf/test42-PR21296-clanggcc-report0.txt:
Ditto.
* tests/data/test-diff-suppr/test39-opaque-type-report-0.txt:
Ditto.
2020-03-26 Giuliano Procida <gprocida@google.com>
Fix size calculations for multidimensional arrays.
* include/abg-ir.h (array_type_def::append_subrange): Remove
this function.
* src/abg-ir.cc (array_type_def::set_element_type): Add a note
about safe usage.
(array_type_def::append_subrange): Inline this function into
its only caller append_subranges and remove it.
(array_type_def::append_subranges): Do correct multiplicative
calculation of multidimensional array sizes.
* src/abg-reader.cc (build_array_type_def): When checking
calculated against read array sizes, warn once if value
matches old behaviour rather than raising an assertion.
Otherwise, before raising an assertion, emit an informative
error message.
* tests/data/test-annotate/test14-pr18893.so.abi: Correct
array sizes.
* tests/data/test-annotate/test17-pr19027.so.abi: Ditto.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Ditto.
* tests/data/test-annotate/test7.so.abi: Ditto.
* tests/data/test-diff-dwarf/test10-report.txt: Ditto.
* tests/data/test-diff-dwarf/test11-report.txt: Ditto.
* tests/data/test-read-write/test25.xml: Ditto.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-27 Giuliano Procida <gprocida@google.com>
abidiff: Remove new lines after parameter diffs.
* src/abg-default-reporter.cc: (report_local_function_type_changes):
Remove unnecessary blank lines after lists of parameter changes.
* tests/data/test-*/test*report*.txt: Remove blank lines after
parameter change lists in 12 files.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-27 Giuliano Procida <gprocida@google.com>
abidiff: Eliminate leaf mode double blank lines.
* src/abg-leaf-reporter.cc: (report_diffs) Emit 1 instead of 2
new lines between sections.
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt:
Replace double blank lines with single ones.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-1.txt:
Ditto.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Ditto.
* tests/data/test-*/test*report*.txt:: Ditto.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-27 Giuliano Procida <gprocida@google.com>
abidiff: Fix variable declaration formatting.
* src/abg-reporter-priv.cc: (represent) In the var_diff_sptr
overload, make sure the state variables begin_with_and and
emitted are updated consistently; add a TODO for one case
which may result in the end of the function being reached
without having emitted a report; add missing new lines
following reporting of anonymous member changes; only emit a
final new line if begin_with_and hasn't tracked one already;
document state variables.
* tests/data/test-diff-dwarf/test45-anon-dm-change-report-0.txt:
Add missing blank line after anonymous member change text.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-1.txt:
Add missing "and " continuation.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-27 Giuliano Procida <gprocida@google.com>
abidiff: Remove member function diff blank lines.
* src/abg-default-reporter.cc (report): In the
class_or_union_diff overload, don't emit a new line after each
list of member function, member type, template member
function and template member class changes.
* src/abg-leaf-reporter.cc (report): : In the
class_or_union_diff overload, don't emit a new line after each
list of member function changes.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v0.cc:
New test case for --leaf-changes-only member function diffs.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v0.o:
Ditto.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v1.cc:
Ditto. Also add a TODO regarding a potentially bad diff.
* tests/data/test-abidiff-exit/test-leaf-cxx-members-v1.o:
Ditto.
* tests/data/test-abidiff/test-struct1-report.txt: Remove
blank lines after member function changes lists.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt:
Ditto.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Ditto.
* tests/test-abidiff-exit.cc: Add new test case.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-26 Giuliano Procida <gprocida@google.com>
abidiff: Fix enum impacted interfaces blank line.
* src/abg-default-reporter.cc (report): In the enum_diff
overload, don't emit a blank line before a possible "impacted
interfaces" stanza. In the class_or_union overload, change a
stray conditional to use the emitted state variable for
consistency.
* tests/data/test*report*.txt: Remove blank lines after enum
diffs in 17 files.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-26 Giuliano Procida <gprocida@google.com>
abidiff: Remove blank line after base class diffs.
* src/abg-default-reporter.cc (report): In the class_diff
overload, eliminate the extra blank line after base class
changes and remove unneeded new line logic.
* tests/data/test*report*.txt: Remove blank lines after base
class diffs in 9 files.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-26 Giuliano Procida <gprocida@google.com>
abidiff: Clean up new lines between sections.
* src/abg-default-reporter.cc (report): In the corpus_diff
override, add back the extra blank line per changed function
but remove the extra one after all changed changed functions
and variables; comment these.
* src/abg-leaf-reporter.cc (report): In the corpus_diff
override, add back the extra blank line per changed function
but remove the extra one after all changed changed functions
and variables; comment these.
* src/abg-reporter-priv.cc
(maybe_report_unreachable_type_changes): Remove extra blank
line emitted after all unreachable type changes; comment
this.
* tests/data/test*report*.txt: Remove/add blank lines.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-26 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Add types_have_similar_structure tests.
* src/abg-ir.cc (types_have_similar_structure): Update TODO
regarding structure of arrays - multidimensional arrays are
the issue.
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt:
Updated following changes.
* tests/data/test-abidiff-exit/test-leaf-peeling-v0.cc: Add
more cases (see below).
* tests/data/test-abidiff-exit/test-leaf-peeling-v0.o:
Updated.
* tests/data/test-abidiff-exit/test-leaf-peeling-v1.cc: Add
comment about a potential change to local-change semantics;
add test cases to demonstrate that * and & and * and *** are
structurally different; add a TODO regarding multidimensional
arrays where changes are sometimes missed in leaf mode.
* tests/data/test-abidiff-exit/test-leaf-peeling-v1.o
2020-03-28 Giuliano Procida <gprocida@google.com>
abg-reader.cc: Fix code indentation and tabify.
* src/abg-reader.cc (build_elf_symbol_db): Fix code
indentation.
(build_array_type_def): Tabify.
2020-03-26 Dodji Seketeli <dodji@redhat.com>
Update tests/data/test-abidiff-exit/test-leaf-peeling-report.txt
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt:
Update output.
2020-03-25 Giuliano Procida <gprocida@google.com>
abidiff: Remove some more unnecessary blank lines.
* src/abg-default-reporter.cc (report) In the
class_or_union_diff overload, don't emit a new line after
calls to represent. In the union_diff overload, emit a new
line after a from/to change; fix indentation. In the
corpus_diff overload, don't emit an extra new line after
reporting a diff.
* src/abg-leaf-reporter.cc (report_diffs) Don't emit a new
line after reporting a canonical diff. In the
class_or_union_diff overload, don't emit a new line after
calls to represent. In the corpus_diff overload, don't emit an
extra new line after reporting a diff.
* src/abg-reporter-priv.cc (represent): Emit a final new line,
but only if needed.
(maybe_report_interfaces_impacted_by_diff): Emit a new line
after the last impacted interface.
* tests/data/test-*/*report*.txt: Remove blank lines (and add
a missing one) to 77 test cases.
2020-03-25 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Improve types_have_similar_structure.
* include/abg-fwd.h (types_have_similar_structure): In both
overloads, add an indirect_type argument, defaulting to
false.
* src/abg-ir.cc (reference_type_def constructor): Tabify.
(types_have_similar_structure): In both overloads, add an
indirect_type argument and update documentation text. In the
type_base_sptr overload, pass indirect_type in the tail
call. In the type_base* overload, replace was_indirect_type
with indirect_type; peel CV qualifiers and typedefs without
testing as the peel function does this; replace the
indiscriminate peeling of qualifier/pointer/reference/array
type components with code that checks the same
pointer/reference/array type component is used on each side
and makes recursive calls with indirect_type set to true; pass
the indirect_type argument recursively when comparing other
subtypes; move the typeid check earlier, document its purpose
and remove unneccessary checks after later dynamic casts;
remove an always-true conditional; add a TODO for comparing
array types more accurately.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-leaf-peeling-v0.cc: New
test case.
* tests/data/test-abidiff-exit/test-leaf-peeling-v1.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf-peeling-report.txt:
Ditto.
* tests/test-abidiff-exit.cc: Run new test case.
2020-03-19 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Remove always-true check.
* src/abg-ir.cc (types_have_similar_structure): Remove
identical nested conditional.
(reference_type_def::reference_type_def): Tabify.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-19 Giuliano Procida <gprocida@google.com>
abg-ir.cc: Fix peel_typedef_type(const type_base*).
* src/abg-ir.cc (peel_typedef_type): In the const type_base*
overload, return the original argument rather than null if the
type isn't actually a typedef.
2020-03-18 Giuliano Procida <gprocida@google.com>
Eliminate redundancy in representation of local change kinds.
* include/abg-ir.h (change_kind): Remove redundant
LOCAL_CHANGE_KIND member, renumber members and update
comments.
* src/abg-comparison.cc (distinct_diff::has_local_changes):
Remove redundant LOCAL_CHANGE_KIND.
(var_diff::has_local_changes
* src/abg-ir.cc (equals): In the type_base,
qualified_type_def, pointer_type_def, reference_type_def,
array_type_def::subrange_type, array_type_def, enum_type_decl,
typedef_decl, var_decl, function_type, function_decl,
function_decl::parameter, class_or_union,
class_decl::base_spec, class_decl, decl_base and scope_decl
overloads, remove redundant LOCAL_CHANGE_KIND.
(enum_has_non_name_change): Remove redundant
LOCAL_CHANGE_KIND.
2020-03-20 Dodji Seketeli <dodji@redhat.com>
dwarf-reader: Fix bloom filter access in GNU_HASH section
* src/abg-dwarf-reader.cc (bloom_word_at): Properly read an
element from the bloom bitmasks array of 32-bits values as a
64-bits value in a portable way. Always return a 64 bits value.
(lookup_symbol_from_gnu_hash_tab): Use a 64-bits value to store
the bloom bitmask.
* tests/data/test-lookup-syms/test1-32bits.so: New test input,
compiled as a 32bits binary to test for ELFCLASS32 binaries.
* tests/data/test-lookup-syms/test1.c.compiling.txt: Documentation
about how to compile the test1[-21bits].so files.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-lookup-syms.cc (in_out_specs): Add the
test1-32bits.so test case to this test harness.
2020-03-18 Giuliano Procida <gprocida@google.com>
Ensure change_kind enum values are used consistently.
* src/abg-comparison.cc (distinct_diff::has_local_changes):
Remove unnecessary parentheses around return expression.
* src/abg-default-reporter.cc (report): In the reference_diff
overload, replace test against LOCAL_CHANGE_KIND with test
against ALL_LOCAL_CHANGES_MASK.
* src/abg-ir.cc (equals): In the array_type_def and class_decl
overloads, add missing LOCAL_TYPE_CHANGE_KIND. In the
class_decl overload, also add missing LOCAL_CHANGE_KIND. In
the enum_type_decl and function_decl::parameter overloads
clarify pairing of LOCAL*CHANGE_KIND bits.
(enum_has_non_name_change): Clarify pairing of
LOCAL*CHANGE_KIND bits.
2020-03-18 Giuliano Procida <gprocida@google.com>
dwarf-reader: Use all bits of Bloom filter words.
* src/abg-dwarf-reader.cc (lookup_symbol_from_gnu_hash_tab):
Don't narrow calculated Bloom word to 8 bits before using it
to mask the fetched Bloom word.
2020-03-15 Matthias Maennich <maennich@google.com>
dwarf-reader: remove superfluous ABG_ASSERT
* src/abg-dwarf-reader.cc
(maybe_adjust_et_rel_sym_addr_to_abs_addr): improve NULL check,
remove superfluous ABG_ASSERT
* tests/data/Makefile.am: Add new test case to the distribution.
* tests/test-read-dwarf.cc: Likewise.
* tests/data/test-read-dwarf/test27-bogus-binary.elf: New test case.
2020-03-15 Matthias Maennich <maennich@google.com>
test-read-dwarf: ensure in_elf_path exists and add missing test files
* tests/data/Makefile.am: add missing test case files
* tests/test-read-dwarf.cc (test_task::perform): assert the
input elf file exists.
2020-03-18 Matthias Maennich <maennich@google.com>
configure: add support for memory sanitizer (--enable-msan)
* configure.ac: Add configure options for -fsanitize=memory
2020-03-18 Dodji Seketeli <dodji@redhat.com>
abipkgdiff: fix documentation of --impacted-interface
* tools/abipkgdiff.cc (display_usage): Use the same help string
for the --impacted-interface option as abidiff does.
2020-03-15 Matthias Maennich <maennich@google.com>
abidiff: fix documentation of --impacted-interfaces
* tools/abidiff.cc(display_usage): Fix doc string for
--impacted-interfaces.
Reported-by: Saravana Kannan <saravanak@google.com>
2020-03-17 Giuliano Procida <gprocida@google.com>
Tag add/remove/change lines unconditionally with [A], [D], [C].
* src/abg-default-reporter.cc (report): In the corpus_diff
override, remove calculations of number of changes (total) and
comparisons against arbitrary threshold (large_num); emit [A],
[D], [C] tags unconditionally.
* src/abg-reporter-priv.cc
(maybe_report_unreachable_type_changes): Remove comparisons of
number of changes against arbitrary threshold (large_num);
emit [A], [D], [C] tags unconditionally; fix quoting of
deleted unreachable types; fix indentation of changed
unreachable types.
* tools/abipkgdiff.cc (compare_prepared_userspace_packages):
Emit [D] and [A] tags for removed and added binaries.
* tests/data/test-*/*report*.txt: In 109 report files, add
tags [A], [D], [C] tags and correct some indentation and
quoting.
2020-03-12 Matthias Maennich <maennich@google.com>
abg-workers: guard bring_workers_down to avoid dead lock
* src/abg-workers.cc(do_bring_workers_down): keep
task_todo_mutex locked while writing bring_workers_down,
(wait_to_execute_a_task): rewrite the loop condition to ensure
safe access to bring_workers_down.
2020-03-12 Matthias Maennich <maennich@google.com>
configure: add support for thread sanitizer (--enable-tsan)
* configure.ac: Add configure options for -fsanitize=thread
2020-03-13 Matthias Maennich <maennich@google.com>
dwarf-reader: gnu_hash_tab lookup: fix overflow in bloom hash calculation
* src/abg-dwarf-reader.cc(lookup_symbol_from_gnu_hash_tab): Fix
signed integer overflow.
2020-03-12 Giuliano Procida <gprocida@google.com>
Treat function type changes as local.
* src/abg-ir.cc (types_have_similar_structure): Always compare
function types (instead of just returning true) regardless of
whether they are components of pointer-to-function or
reference-to-function types.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-leaf2-report.txt: New test
case.
* tests/data/test-abidiff-exit/test-leaf2-v0.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf2-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf2-v1.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf2-v1.o: Ditto.
* tests/test-abidiff-exit.cc: Run new test case.
2020-03-13 Giuliano Procida <gprocida@google.com>
Output 2-space indentation consistently.
* src/abg-default-reporter.cc (report): In the
class_or_union_diff override, use 2-space indentation when
listing changed members. In the var_diff override, do the same
for variable type changes.
* src/abg-leaf-reporter.cc: Ditto.
* tests/data/test-*/*report*.txt: Update many test cases.
2020-03-16 Giuliano Procida <gprocida@google.com>
Eliminate some unnecessary blank lines in diff output.
* src/abg-default-reporter.cc (report): In the type_decl_diff,
enum_diff, array_diff, class_diff, union_diff and var_diff
overrides, simplify new line logic which no longer needs to be
threaded through report_name_size_and_alignment_changes. In
the distinct_diff override, simplify new line logic which no
longer needs to be threaded through
report_size_and_alignment_changes. In the enum_diff override,
emit just one blank line after each enum. In the array_diff
override, remove stray location reporting which doesn't appear
to ever trigger; fix new line logic. In the
class_or_union_diff override, simplify new line logic for
deleted members; pass indentation to represent_data_member.
* src/abg-leaf-reporter.cc (report): In the array_diff,
class_diff, union_diff and var_diff overrides, simplify new
line logic which no longer needs to be threaded through
report_name_size_and_alignment_changes. In the distinct_diff
override, simplify new line logic which no longer needs to be
threaded through report_size_and_alignment_changes. In the
array_diff override, remove stray location reporting which
doesn't appear to ever trigger; fix new line handling. In the
class_or_union_diff override, simplify new line logic for
deleted members; pass indentation to represent_data_member.
In the corpus_diff override, tabify source indentation.
* src/abg-reporter-priv.cc (represent_data_member): Handle
indentation; fix new line logic.
(report_size_and_alignment_changes): Fix new line logic
for "type size hasn't changed" message; simplify new line
logic and replace local bool n with argument bool nl for
clarity.
(report_size_and_alignment_changes): Remove bool nl argument
and associated code as it had become always false; take
responsibility for emitting terminating new lines and change
return type to void.
(report_name_size_and_alignment_changes): Fix new line logic;
remove bool nl argument and associated code as it had become
always false; take responsibility for emitting terminating new
lines and change return type to void.
(maybe_report_interfaces_impacted_by_diff) In both overrides,
remove new line prefix code and new_line_prefix argument.
* src/abg-reporter-priv.h (represent_data_member): Add indent
argument.
(report_size_and_alignment_changes) Remove bool nl argument;
change return type to void.
(report_name_size_and_alignment_changes) Remove bool nl
argument; change return type to void.
(maybe_report_interfaces_impacted_by_diff) In both overrides,
remove new_line_prefix argument.
* tests/data/test-*/*report*.txt: Remove some blank lines.
2020-03-12 Giuliano Procida <gprocida@google.com>
abg-leaf-reporter.cc: Fix indentation of function parameter diffs.
* src/abg-leaf-reporter.cc (report): In the fn_parm_diff
override, indent the lines of detail by 2 spaces.
* tests/data/test-abidiff-exit/test-leaf3-report.txt: Update
report with correct indentation.
2020-03-12 Giuliano Procida <gprocida@google.com>
Fix interaction of --redundant and --leaf-changes-only options.
* src/abg-comparison.cc (diff_context::show_leaf_changes_only):
Remove "--leaf-changes-only implies --redundant" logic.
* tools/abidiff.cc (display_usage): Mention that
--leaf-changes-only implies --redundant.
(set_diff_context_from_opts): Make --leaf-changes-only imply
--redundant; document this behaviour in a comment.
* tools/abipkgdiff.cc: Ditto.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-leaf3-report.txt: Add new
test case, to show --leaf-changes-only implies --redundant.
* tests/data/test-abidiff-exit/test-leaf3-v0.c: Ditto.
* tests/data/test-abidiff-exit/test-leaf3-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf3-v1.c: Ditto.
* tests/data/test-abidiff-exit/test-leaf3-v1.o: Ditto.
* tests/test-abidiff-exit.cc: Run new test case.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
Update abipkgdiff report with --redundant output.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt:
Ditto.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Ditto.
2020-03-13 Giuliano Procida <gprocida@google.com>
Add more leaf change reporting.
* doc/manuals/abidiff.rst: Update the documentation for
--leaf-changes-only.
* doc/manuals/abipkgdiff.rst: Likewise.
* src/abg-comparison.cc (emit_diff_stats): Exclude non-leaf
changes to variables from the reported total of leaf changes.
* src/abg-default-reporter.cc (report): In the corpus_diff
override, move some code and comments for clarity.
* src/abg-leaf-reporter.cc (report): In the corpus_diff
override, additionally report removed/added/changed variables
and removed/added symbols absent from debug info.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-leaf0-report.txt: Update
to include reporting of variable diff (change of type).
* tests/data/test-abidiff-exit/test-leaf1-report.txt: New test
case with added/removed variables/functions and changed
variables (both local and non-local type changes).
* tests/data/test-abidiff-exit/test-leaf1-v0.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf1-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf1-v1.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf1-v1.o: Ditto.
* tests/test-abidiff-exit.cc: Run new test case. Supply
--redundant otherwise the test isn't meaningful.
2020-03-12 Dodji Seketeli <dodji@redhat.com>
Update fedabipkgdiff tests according to commit b602f46c
* tests/data/test-fedabipkgdiff/test0-from-fc20-to-fc23-dbus-glib-report-0.txt:
Adjust for useless whitespace removal.
* tests/data/test-fedabipkgdiff/test1-from-fc20-to-dbus-glib-0.106-1.fc23.x86_64-report-0.txt: Likewise.
* tests/data/test-fedabipkgdiff/test2-dbus-glib-0.100.2-2.fc20--dbus-glib-0.106-1.fc23-report-0.txt: Likewise.
* tests/data/test-fedabipkgdiff/test3-dbus-glib-0.100.2-2.fc20.i686--dbus-glib-0.106-1.fc23.i686-report-0.txt: Likewise.
* tests/data/test-fedabipkgdiff/test4-glib-0.100.2-2.fc20.x86_64.rpm-glib-0.106-1.fc23.x86_64.rpm-report-0.txt: Likewise.
2020-03-11 Giuliano Procida <gprocida@google.com>
Fix spurious new lines after diff sections.
* src/abg-default-reporter.cc (report): In the corpus_diff
overload, just use a local boolean emitted state variable
within each section to determine whether or not to follow the
section with an extra new line.
* src/abg-leaf-reporter.cc: Ditto.
* tests/data/test-*/*report*.txt: Remove unwanted new lines
from 27 files.
2020-03-10 Giuliano Procida <gprocida@google.com>
abg-comparison.cc: Remove stray function declaration.
* src/abg-comparison.cc (show_relative_offset_changes): Remove
this stray function declaration.
2020-03-10 Giuliano Procida <gprocida@google.com>
abisym: Remove leading space in output.
* tools/abisym.cc (main): Remove leading space from output.
* tests/data/test-lookup-syms/test0-report.txt: Remove leading
space from expected output.
* tests/data/test-lookup-syms/test01-report.txt: Ditto.
* tests/data/test-lookup-syms/test02-report.txt: Ditto.
* tests/data/test-lookup-syms/test1-1-report.txt: Ditto.
2020-03-09 Giuliano Procida <gprocida@google.com>
Fix the reporting of leaf change statistics.
* src/abg-comparison.cc
(apply_filters_and_compute_diff_stats): Increment the correct
counter for leaf variable changes.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-leaf0-report.txt: New test
case.
* tests/data/test-abidiff-exit/test-leaf0-v0.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf0-v0.o: Ditto.
* tests/data/test-abidiff-exit/test-leaf0-v1.cc: Ditto.
* tests/data/test-abidiff-exit/test-leaf0-v1.o: Ditto.
* tests/test-abidiff-exit.cc: Run new test case.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-03-05 Giuliano Procida <gprocida@google.com>
Add space missing between "[C]" tag and description of changed item.
* src/abg-default-reporter.cc (report): In the overload for
corpus_diff, output space after "[C]".
* src/abg-leaf-reporter.cc (report): Likewise.
* tests/data/test-*/*report*.txt: Update all the test
reports.
2020-03-05 Giuliano Procida <gprocida@google.com>
Correct various inconsequential typos.
* src/abg-leaf-reporter.cc (report): In the class_or_union_diff
overoad, swap calls to report_mem_header to match the rest of the
code.
* src/abg-reporter-priv.cc (represent): In the var_diff_sptr
overload, add some missing whitespace; remember we've emitted the
pretty representation in 2 cases where this was omitted (though 1
of these is the last case where it makes no difference).
maybe_report_diff_for_symbol Add some missing whitespace; remember
we've reported a diff (and need a trailing newline) in 1 case
where this was omitted, also affecting the return value of the
function (but no caller cares).
2020-03-05 Giuliano Procida <gprocida@google.com>
Correct spelling of "alignment".
* src/abg-reporter-priv.cc: s/alignement/alignment/
* tests/data/test-abidiff/test-struct0-report.txt: Ditto..
* tests/data/test-abidiff/test-struct1-report.txt: Ditto.
* tests/data/test-abidiff/test-var0-report.txt: Ditto.
2020-02-27 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.8
* configure.ac: Update version number to 1.8
2020-02-26 Dodji Seketeli <dodji@redhat.com>
Update website for 1.7
* doc/website/mainpage.txt: Update for 1.7
2020-02-25 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog
* ChangeLog: Automatically update by running:
'make update-changelog'.
2020-02-25 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.7
* NEWS: update for 1.7
2020-02-25 Dodji Seketeli <dodji@redhat.com>
gen-changelog.py: Update the script for python3
* gen-changelog.py (process_commit): Use the functional notation
for the print function invocation required by python3.
(output_commits, get_rel_tags, ): Specify that the output stream
of the subprocess running the git command is in the text format.
2020-02-26 Dodji Seketeli <dodji@redhat.com>
tools-utils: Drop redefinition of fopen when BAD_FTS is defined
* src/abg-tools-utils.cc: Do not remap fopen to fopen64 as we
don't use fopen explicitly anymore.
2020-02-21 Dodji Seketeli <dodji@redhat.com>
Update copyright year to 2020
* include/abg-comp-filter.h: Update copyright year to 2020.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-cxx-compat.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-libzip-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-libzip-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-sptr-utils.cc: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-dot.cc: Likewise.
* tests/test-ini.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-svg.cc: Likewise.
* tests/test-tools-utils.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tests/test-write-read-archive.cc: Likewise.
* tools/abiar.cc: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/kmidiff.cc: Likewise.
* update-copyright.sh: Fix the updating script to handle not just
"Red Hat, Inc."
2020-02-21 Dodji Seketeli <dodji@redhat.com>
abixml-reader: Support SONAME related properties on file suppression
* doc/manuals/libabigail-concepts.rst: Update the documentation to
mention soname_regexp and soname_not_regexp is supported in the
[suppress_file] section.
* include/abg-suppression.h (suppression_matches_soname)
(suppression_matches_soname_or_filename): Declare new functions.
Make them be friends of class suppression_base.
* src/abg-reader.cc
(read_context::corpus_is_suppressed_by_soname_or_filename): Define
new member function.
(read_corpus_from_input): Apply file suppression.
* src/abg-suppression.cc (read_file_suppression): Support
"soname_regexp" and "soname_not_regexp" in the [suppress_file]
section.
(suppression_matches_soname)
(suppression_matches_soname_or_filename): Define new functions.
* tests/data/test-diff-suppr/libtest48-soname-abixml-report-{1,2}.txt:
New test reference output files.
Likewise.
* tests/data/test-diff-suppr/libtest48-soname-abixml-suppr.txt:
New test suppression file.
* tests/data/test-diff-suppr/libtest48-soname-abixml-suppr-{2,3,4}.txt::
Likewise.
* tests/data/test-diff-suppr/libtest48-soname-abixml-v{0,1}.so: New
test binary input files.
* tests/data/test-diff-suppr/libtest48-soname-abixml-v{0,1}.so.abi:
New abixml for the binary input files above.
* tests/data/test-diff-suppr/test48-soname-abixml-v{0,1}.c: Source
code of the binary input files above.
* tests/data/Makefile.am: Add the above test material to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the test input
above to this test harness.
2020-02-21 Dodji Seketeli <dodji@redhat.com>
suppression: Better handle soname/filename properties evaluation
* include/abg-suppression.h
(suppression_base::has_{soname,file_name}_related_property): Add
new member functions.
* src/abg-dwarf-reader.cc (read_context::suppression_can_match):
Fix the logic to make a difference between the case where the
suppression doesn't have any soname/filename property and the case
where the suppression does have a soname/filename property that
does not match the current binary.
* src/abg-reader.cc (read_context::suppression_can_match):
Likewise.
* src/abg-suppression-priv.h
(suppression_base::priv::matches_soname): If the suppression does
not have any soname related property then it doesn't match the
soname we are looking at.
(suppression_base::priv::matches_binary_name): If the suppression
does not have any filename related property then it doesn't match
the filename we are looking at.
* src/abg-suppression.cc
(suppression_base::has_{soname,file_name}_related_property):
Define new member functions.
(sonames_of_binaries_match): If the suppression does not have any
soname related property then it doesn't match the corpora of the
diff we are looking at.
(names_of_binaries_match): If the suppression does not have any
filename related property then it doesn't match the corpora of the
diff we are looking at.
(type_suppression::suppresses_type): Fix the logic to make a
difference between the case where the suppression doesn't have any
soname/filename property and the case where the suppression does
have a soname/filename property that does not match the current
binary.
(function_suppression::suppresses_{function, function_symbol}):
Likewise.
(variable_suppression::suppresses_{variable, variable_symbol}):
Likewise.
(file_suppression::suppresses_file): Likewise.
2020-02-05 Giuliano Procida <gprocida@google.com>
Fix stray comma in leaf-changes-only mode.
* src/abg-reporter-priv.cc (represent): Don't try to follow
output of indented pretty representation with a comma, just
emit "and" unconditionally; remove unnecessary intermediate
ostringstream.
* tests/data/Makefile.am: Add new test case files.
* tests/data/test-abidiff-exit/test-no-stray-comma-*: New test
cases.
* tests/data/test-diff-suppr/test46-PR25128-report-?.txt:
Replace unindented comma with indented "and".
* tests/test-abidiff-exit.cc: Add no-stray-comma test case.
Reviewed-by: Matthias Maennich <maennich@google.com>
2020-02-04 Giuliano Procida <gprocida@google.com>
Sort kernel module object files before processing them.
* src/abg-tools-utils.cc (get_binary_paths_from_kernel_dist):
Sort module_paths.
2020-02-04 Matthias Maennich <maennich@google.com>
abg-workers: Rework the worker queue to improve concurrent behaviour
* include/abg-workers.h (workers::task): move entire
implementation to header and drop superfluous forward declaration.
* src/abg-workers.cc (workers::task):: Likewise.
(workers::queue::priv): Drop queue_cond_mutex, rename queue_cond
to tasks_todo_cond, add task_done_cond, make default_notify
static.
(workers::queue::priv::priv): Add default arguments to fully
qualified constructor, drop the remaining ones.
(workers::queue:prive::more_tasks_to_execute): Drop method.
(workers::queue:prive::schedule_task): Do not synchronize access
to the queue condition variable, but only on the mutex.
(do_bring_workers_down): Likewise. Also await tasks_done to be
empty.
(workers::queue:prive::worker::wait_to_execute_a_task): Await
tasks on the tasks_todo with tasks_todo_(cond|mutex) and signal
task completion to tasks_done_cond.
2020-02-03 Matthias Maennich <maennich@google.com>
abg-dwarf-reader: zero initialize local Dwarf_Addr values
* src/abg-dwarf-reader.cc
(read_context::get_first_exported_fn_address_from_DW_AT_ranges):
initialize local Dwarf_Addr variables.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-29 Matthias Maennich <maennich@google.com>
abg-comparison: prefer .empty() over implicit bool conversion of .size()
* src/abg-comparison.cc (corpus_diff::has_changes): prefer
!container.empty() over bool(container.size())
[1] https://clang.llvm.org/extra/clang-tidy/checks/readability-container-size-empty.html
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-29 Matthias Maennich <maennich@google.com>
Fix some parameter name inconsistencies
* src/abg-comparison-priv.h
(corpus_diff::priv::count_unreachable_types): use consistent
parameter naming.
* tools/abidiff.cc(main): Likewise.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-02-03 Giuliano Procida <gprocida@google.com>
Don't ignore options when diffing translation units (.bi files).
* tests/data/Makefile.am: Add test case files.
* tests/data/test-abidiff-exit/test-loc-*: New test cases.
* tests/test-abidiff-exit.cc (in_out_specs): Add new test cases.
* tools/abidiff.cc (main): Use populated ctxt for translation unit
diff.
2020-01-29 Giuliano Procida <gprocida@google.com>
Fix typo in COMPILING.
* COMPILING: Fix typo in COMPILING.
2020-01-29 Giuliano Procida <gprocida@google.com>
Remove redundant mention of libtool in COMPILING documentation.
* COMPILING: Remove redundant mention of libtool.
2020-01-26 Matthias Maennich <maennich@google.com>
Testing: add Catch Unit test framework
* tests/.gitignore: Add entry for .dirstamp
* tests/Makefile.am: Add libcatch test library and use it for
runtestkmiwhitelist.
* tests/lib/catch.cc: New test driver implementation.
* tests/lib/catch.hpp: Add Catch v1.12.2 header only test library.
* tests/test-kmi-whitelist.cc: Migrate to use Catch test framework.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-25 Matthias Maennich <maennich@google.com>
abg-fwd: drop duplicate forward declaration for corpus_sptr
* include/abg-fwd.h: drop superfluous forward declaration.
2020-01-25 Matthias Maennich <maennich@google.com>
Fix / add include guards
* include/abg-dwarf-reader.h: Move include guard to the beginning.
* include/abg-reporter-priv.h: Likewise.
* include/abg-libxml-utils.h: Add include guard.
* include/abg-libzip-utils.h: Likewise.
2020-01-25 Matthias Maennich <maennich@google.com>
dwarf-reader: handle binaries with missing symtab
* src/abg-dwarf-reader.cc (load_symbol_maps_from_symtab_section):
Handle elf file with missing symtab.
* tests/test-read-dwarf.cc (InOutSpec): add test case.
* tests/data/test-read-dwarf/test26-bogus-binary.elf: new test data.
2020-01-24 Matthias Maennich <maennich@google.com>
dwarf-reader: handle symtab.section_header.sh_entsize == 0
* src/abg-dwarf-reader.cc (load_symbol_maps_from_symtab_section):
Handle elf file with invalid sh_entsize.
* tests/test-read-dwarf.cc (test_task::perform): handle empty
in_abi_path and out_abi_path as 'read only' test.
(InOutSpec): add test case.
* tests/data/test-read-dwarf/test25-bogus-binary.elf: new test data.
2020-01-21 Matthias Maennich <maennich@google.com>
clang-format: Better approximation for binary operators and assignments
* .clang-format: Add BreakBeforeBinaryOperators option.
2020-01-14 Matthias Maennich <maennich@google.com>
KMI Whitelists: Drop old whitelist extraction methods
* include/abg-tools-utils.h
(gen_suppr_spec_from_kernel_abi_whitelist): Delete declaration.
* src/abg-tools-utils.cc
(gen_suppr_spec_from_kernel_abi_whitelist): Delete definition
and migrate users to gen_suppr_spec_from_kernel_abi_whitelists.
* tools/abidiff.cc (set_suppressions): Migrate from using
gen_suppr_spec_from_kernel_abi_whitelist to
gen_suppr_spec_from_kernel_abi_whitelists.
* tools/abidw.cc (set_suppressions): Likewise.
* tools/abipkgdiff.cc: Drop unused using definition.
* tools/kmidiff.cc: Likewise.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-14 Matthias Maennich <maennich@google.com>
KMI Whitelists: Add functionality to make whitelists additive
* include/abg-tools-utils.h
(gen_suppr_spec_from_kernel_abi_whitelists): New function.
* src/abg-tools-utils.cc
(gen_suppr_spec_from_kernel_abi_whitelists): Likewise.
* tests/.gitignore: Ignore new test executable.
* tests/Makefile.am: Add new test executable.
* tests/data/test-kmi-whitelist/whitelist-with-another-single-entry:
New test input file.
* tests/data/test-kmi-whitelist/whitelist-with-duplicate-entry:
Likewise.
* tests/data/test-kmi-whitelist/whitelist-with-single-entry:
Likewise.
* tests/data/test-kmi-whitelist/whitelist-with-two-sections:
Likewise.
* tests/data/Makefile.am: Add above test material.
* tests/test-kmi-whitelist.cc: Add new test executable.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-13 Matthias Maennich <maennich@google.com>
writer: completely skip over empty corpora
* src/abg-writer.cc (write_corpus): completely skip empty
corpora rather than creating an empty entry for them.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-13 Matthias Maennich <maennich@google.com>
corpus: is_empty: consider actual translation unit contents
* src/abg-corpus.cc (corpus::is_empty): consider a list of
empty members to be empty.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-13 Matthias Maennich <maennich@google.com>
abg-reader: handle empty corpus nodes in xml representation
* src/abg-reader.cc (read_corpus_from_input): when assigning a
corpus node, assure the node actually has children.
* tests/test-abidiff.cc (main): Add test for variants of empty
xml nodes to the test harness.
* tests/data/test-abidiff/test-empty-corpus-0.xml: Test input
containing an empty xml node that closes immediately.
* tests/data/test-abidiff/test-empty-corpus-0.xml: Test input
containing an empty xml node that closes immediately with a tag.
* tests/data/test-abidiff/test-empty-corpus-0.xml: Test input
containing an empty xml node that closes with a tag on a new line.
* tests/data/test-abidiff/test-empty-corpus-report.txt:
Expected test output (empty abidiff) for diffing xml with itself.
* tests/data/Makefile.am: Add the new test input material above
to source distribution.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2020-01-17 Dodji Seketeli <dodji@redhat.com>
Bug 25409 - Fix reading layout-offset-in-bits attribute of data-member
* src/abg-reader.cc (read_offset_in_bits): Fix comment. Use
stroull rather than atoi.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0:
Add new binary test input.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0-report-0.txt:
Add new reference output.
* tests/data/test-diff-dwarf-abixml/PR25409-librte_bus_dpaa.so.20.0.abi:
Add new abixml representation for the binary test input above.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-dwarf-abixml.cc (in_out_specs): Add the test
input above to the test harness.
2020-01-13 Matthias Maennich <maennich@google.com>
abidiff/kmidiff: do not default-suppress added symbols
* tools/abidiff.cc (adjust_diff_context_for_kmidiff): Drop
default suppression of added symbols.
* tools/kmidiff.cc (set_diff_context): Likewise.
* tests/data/test-diff-suppr/test46-PR25128-report-1.txt: Adjust
test expectation.
* tests/data/test-diff-suppr/test46-PR25128-report-2.txt: Add
test case for abidiff with flag --no-added-syms.
* tests/data/Makefile.am: add new testcase.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2019-12-15 Matthias Maennich <maennich@google.com>
Add (undocumented) support for version suffixes
* configure.ac: add substitution for VERSION_SUFFIX
* include/abg-version.h.in: add define for ABIGAIL_VERSION_SUFFIX
* include/abg-config.h(abigail_get_library_version): add support
for a version suffix
* src/abg-config.cc(abigail_get_library_version): Likewise.
* src/abg-tools-utils.cc(get_library_version_string): Likewise.
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2019-11-13 Matthias Maennich <maennich@google.com>
dwarf-reader: relax restriction about relocation sections in try_reading_first_ksymtab_entry
* src/abg-dwarf-reader.cc (try_reading_first_ksymtab_entry):
remove assertion and update documentation
Fixes: 43679a610316 ("dwarf-reader: refactor try_reading_first_ksymtab_entry_using{pre,}_v4_19_format")
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2019-11-11 Matthias Maennich <maennich@google.com>
abg-dwarf-reader: resolve relocation sections by index
* src/abg-dwarf-reader.cc (find_relocation_section): New function.
(find_ksymtab_reloc_section): Use find_relocation_section to
resolve the ksymtab's relocation section.
(find_ksymtab_gpl_reloc_section): Likewise.
Fixes: e6870326e01a ("Support pre and post v4.19 ksymtabs for Linux kernel modules")
Cc: Jessica Yu <jeyu@kernel.org>
Cc: Android Kernel Team <kernel-team@android.com>
Reviewed-by: Dodji Seketeli <dodji@seketeli.org>
2019-12-03 Dodji Seketeli <dodji@redhat.com>
Misc typo fixes
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Fix typo in
comments.
* src/abg-corpus.cc
(corpus::get_types_not_reachable_from_public_interfaces):
Likewise.
* src/abg-ir.cc (decl_base::set_has_anonymous_parent): Likewise.
* src/abg-reader.cc (add_read_context_suppressions): Likewise.
2019-11-13 Dodji Seketeli <dodji@redhat.com>
Bug 24690 - Support comparing non-reachable types of a binary
* include/abg-comparison.h (string_type_base_sptr_map): Define new
typedef.
(diff_context::show_unreachable_types): Declare new member
functions.
(corpus_diff::{deleted_unreachable_types,
deleted_unreachable_types_sorted, added_unreachable_types,
added_unreachable_types_sorted, changed_unreachable_types,
changed_unreachable_types_sorted}): Likewise.
(maybe_report_unreachable_type_changes): Declare this function a
friend of class corpus_diff.
(corpus_diff::diff_stats::{num_added_unreachable_types,
num_added_unreachable_types_filtered_out,
net_num_added_unreachable_types, num_removed_unreachable_types,
num_removed_unreachable_types_filtered_out,
net_num_removed_unreachable_types, num_changed_unreachable_types,
num_changed_unreachable_types_filtered_out,
net_num_changed_unreachable_types}): Likewise.
* src/abg-comparison-priv.h
(diff_context::priv::show_unreachable_types_): Define new data
member.
(diff_context::priv::priv): Initialize the new data member.
(diff_comp::operator()): Use pretty representation of diff
subjects to sort them, rather than just their name. Also, add
comment to the other member functions of diff_comp.
(corpus_diff::{unreachable_types_edit_script_,
deleted_unreachable_types_, deleted_unreachable_types_sorted_,
suppressed_deleted_unreachable_types_, added_unreachable_types_,
added_unreachable_types_sorted_,
suppressed_added_unreachable_types_, changed_unreachable_types_,
changed_unreachable_types_sorted_}): Define new data members.
(corpus_diff::priv::apply_supprs_to_added_removed_fns_vars_unreachable_types):
Changed the name of
corpus_diff::priv::apply_suppressions_to_added_removed_fns_vars into
this.
(corpus_diff::priv::{added_unreachable_type_is_suppressed,
deleted_unreachable_type_is_suppressed,
changed_unreachable_types_sorted, count_unreachable_types}):
Declare new member functions.
(corpus_diff::diff_stats::priv::{num_added_unreachable_types,
num_added_unreachable_types_filtered_out,
num_removed_unreachable_types,
num_removed_unreachable_types_filtered_out,
num_changed_unreachable_types,
num_changed_unreachable_types_filtered_out}): Define new data
members.
(sort_string_type_base_sptr_map): Declare new function.
* src/abg-comparison.cc (sort_string_type_base_sptr_map)
(diff_context::show_unreachable_types): Define new functions.
(corpus_diff::diff_stats::{num_added_unreachable_types,
num_added_unreachable_types_filtered_out,
net_num_added_unreachable_types,
net_num_removed_unreachable_types,
num_removed_unreachable_types_filtered_out,
num_removed_unreachable_types}): Define new member functions.
(diff_maps::insert_diff_node): Do not update the map "diff ->
impacted interfaces" if the current impacted interface is nil.
This happens if we are looking at a diff node for a change on a
type that is not reachable from any interfaces.
(corpus_diff::priv::ensure_lookup_tables_populated): Handle the
edit script for unreachable types.
(corpus_diff::priv::apply_supprs_to_added_removed_fns_vars_unreachable_types):
Rename
corpus_diff::priv::apply_suppressions_to_added_removed_fns_vars
into this. Apply suppression specifications to added and removed
unreachable types as well.
(corpus_diff::priv::{added,deleted}_unreachable_type_is_suppressed):
Define new member functions.
(corpus_diff::priv::{count_unreachable_types,
changed_unreachable_types_sorted}): Likewise.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Update
statistics (including walking changed unreachable types to apply
categorization and redundancy filters to them) related to
unreachable types.
(corpus_diff::priv::emit_diff_stats): Emit diff stats related to
unreachable types.
(corpus_diff::priv::maybe_dump_diff_tree): Dump diff tree nodes
related to unreachable types.
(corpus_diff::{deleted_unreachable_types,
deleted_unreachable_types_sorted, added_unreachable_types,
added_unreachable_types_sorted, changed_unreachable_types,
changed_unreachable_types_sorted): Define new member functions.
(corpus_diff::has_changes): Take deleted/added/changed unreachable
types into account.
(corpus_diff::has_incompatible_changes): Take net removed/changed
unreachable types into account.
(corpus_diff::has_net_subtype_changes): Take net removed and
changed unreachable types into account.
(corpus_diff::has_net_changes): Take net removed/added/changed
unreachable types into account.
(corpus_diff::traverse): When traversing the components of a
corpus_diff node, make sure to traverse the changed unreachable
types of the corpus.
(leaf_diff_node_marker_visitor::visit_begin): Arrange for the fact
that the current topmost interface can be nil if we are looking at
types not reachable from global functions/variables. Also, make
sure that only leaf nodes that are reachable from a global
function/variable are recorded as leaf nodes.
(compute_diff): In the overload for corpus_sptr, compute the
changes between types not reachable from global functions and
variables, if the user wishes that we do so. Also, add more
comments.
(apply_suppressions): Update for the name change of the function
apply_suppressions_to_added_removed_fns_vars to
apply_supprs_to_added_removed_fns_vars_unreachable_types.
* include/abg-corpus.h
(corpus::{record_type_as_reachable_from_public_interfaces,
type_is_reachable_from_public_interfaces,
get_types_not_reachable_from_public_interfaces}): Declare new
member functions.
(corpus::recording_types_reachable_from_public_interface_supported):
Declare new virtual member function.
(corpus_group::get_public_types_pretty_representations): Declare
new member functons.
(corpus_group::recording_types_reachable_from_public_interface_supported):
Declare new virtual member function.
* src/abg-corpus-priv.h
(corpus::priv::{types_not_reachable_from_pub_ifaces_,
pub_type_pretty_reprs_}): Define new data members.
(corpus::priv::priv): Initialize the pub_type_pretty_reprs_ data
member because it's a pointer.
(corpus::priv::get_public_types_pretty_representations): Declare
new member function.
(corpus::priv::~priv): Declare a destructor.
* src/abg-corpus.cc
(corpus::priv::get_public_types_pretty_representations): Define
new member function.
(corpus::priv::~priv): Define new destructor to delete the new
pub_type_pretty_reprs_ member pointer.
(corpus::{record_type_as_reachable_from_public_interfaces,
type_is_reachable_from_public_interfaces,
get_types_not_reachable_from_public_interfaces,
recording_types_reachable_from_public_interface_supported}):
Define new member functions
(corpus_group::get_public_types_pretty_representations): Likewise.
* include/abg-diff-utils.h (struct deep_ptr_eq_functor): Document
the equality operator. Also, add an overload to the equality
operator, for weak_ptr<T>. The existing equality operator
overload was just for shared_ptr<T>.
* include/abg-fwd.h (is_user_defined_type): Declare function.
* include/abg-ir.h (operator!=(const decl_base_sptr&, const
decl_base_sptr&)): Declare new operator.
(type_maps::get_types_sorted_by_name): Declare
new member function.
(decl_base::{g,s}et_is_artificial): Declare new member function.
(function_decl::parameter::{g,s}et_artificial): Remove these
member functions.
* src/abg-ir.cc (operator!=(const decl_base_sptr&, const
decl_base_sptr&)): Define new operator.
(decl_base::priv::is_artificial_): Define new data
member.
(type_maps::priv::sorted_types_): Define new data member.
(struct type_name_comp): Define new comparison functor to sort
types based on their pretty representations.
(decl_base::priv::priv): Initialize it.
(decl_base::{g,s}et_is_artificial): Define new member functions.
(type_maps::get_types_sorted_by_name): Define new member function.
(is_user_defined_type): Define new function overloads.
(strip_typedef, function_type::{function_type, set_parameters}):
Adjust using decl_base::get_is_artificial rather than
function_decl::parameter::get_artificial.
(function_decl::parameter::priv::artificial_): Remove this data
member.
(function_decl::parameter::priv::priv): Adjust to the removal of
function_decl::parameter::priv::artificial_. This constructor
does not take an "is_artificial" flag anymore.
(function_decl::parameter::parameter): Adjust to the removal of
the is_artificial flag from the arguments of the constructor of
function_decl::parameter::parameter::priv.
(function_decl::parameter::get_artificial): Remove this member
function.
* src/abg-reporter-priv.h (maybe_report_unreachable_type_changes):
Declare new function.
* src/abg-reporter-priv.cc
(maybe_report_unreachable_type_changes): Define new function.
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for corpus_diff&, report added/removed/changed types that
are not reachable from global functions and variables using the
new function maybe_report_unreachable_type_changes.
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
overload for corpus_diff, report changes to types unreachable from
global functions or variables, using the new function
maybe_report_unreachable_type_changes.
* src/abg-dwarf-reader.cc (build_ir_node_from_die): When the user
requests that all types be loaded, record relevant types as
reachable from global functions and variables.
(build_enum_type, add_or_update_class_type)
(add_or_update_union_type): Read the 'is-artificial' DWARF
attribute and set the corresponding decl_base property
accordingly.
(finish_member_function_reading, strip_typedef)
(function_type::function_type): Adjust using
decl_base::get_is_artificial, rather than
function_decl::parameter::get_artificial.
* include/abg-reader.h
(consider_types_not_reachable_from_public_interfaces): Declare new
function.
* src/abg-reader.cc
(read_context::m_tracking_non_reachable_types): Add new data
member.
(read_context::read_context): Initialize it.
(read_context::tracking_non_reachable_types): Define accessors for
the new data member above.
(read_is_declaration_only): Re-indent.
(read_is_artificial): Define new helper function.
(build_function_parameter): Use the new read_is_artificial
function here, rather than open-coding it.
(build_enum_type_decl, build_class_decl, build_union_decl):
Support reading the 'is-artificial' property by using the new
read_is_artificial function.
(read_corpus_from_input): If the user wants us to take
non-reachable types into account, then make sure we do so.
(read_tracking_non_reachable_types, read_is_non_reachable_type):
Define new static functions.
(handle_element_node, build_type): Read the "is-non-reachable"
attribute on type element nodes if the user wants us to track
non-reachable types.
(consider_types_not_reachable_from_public_interfaces): Define new
function.
* src/abg-writer.cc (write_is_artificial): Define new static
helper function.
(annotate): Adjust using decl_base::get_is_artificial rather than
function_decl::parameter::get_artificial.
(write_enum_type_decl, write_class_decl_opening_tag)
(write_union_decl_opening_tag): Support writing the
"is-artificial" property, using the new write_is_artificial
function.
(write_function_type): Adjust this to use the new
write_is_artificial rather than open-coding writing the
'is-artificial' attribute.
(write_is_non_reachable)
(write_tracking_non_reachable_types): Define new static functions.
(write_enum_type_decl, write_class_decl_opening_tag)
(write_union_decl_opening_tag): Write the 'is-no-reachable'
attribute when applicable.
(write_corpus, write_corpus_group): Write the
'tracking-non-reachable-types' attribute when applicable.
* tools/abidiff.cc (options::options): Initialize ...
(options::show_all_types): ... new data member.
(display_usage): Add help string from the new
--non-reachable-types option.
(parse_command_line): Parse the new --non-reachable-types option.
(set_diff_context_from_opts): Set the
dwarf_reader::read_context::show_unreachable_types property.
(set_native_xml_reader_options): Define new
static function.
(main): Load all types when analyzing the DWARF or the ABIXML
files, if the user wants us to do so.
* tools/abipkgdiff.cc (options::show_all_types): Define new data
member.
(options::options): Initialize it.
(parse_command_line): Parse the --non-reachable-types option to
set the options::show_all_types data member.
(display_usage): Add a help string for the new
--non-reachable-types option.
(set_diff_context_from_opts): Set the
dwarf_reader::read_context::show_unreachable_types property based
on the options::show_all_type data member.
(compare): Configure the read context to load all types while
analyzing the DWARF info, depending on the options::show_all_type
data member.
* doc/manuals/abidiff.rst: Document the new --non-reachable-types
option added to abidiff above.
* doc/manuals/abipkgdiff.rst: Add documentation for the
--non-reachable-types option.
* tests/data/test-diff-suppr/test47-non-reachable-types-v{0,1}.c:
Source code files of test binary input.
* tests/data/test-diff-suppr/test47-non-reachable-types-suppr-{1,2,3,4,5}.txt:
New test input files.
* tests/data/test-diff-suppr/test47-non-reachable-types-report-{1,2,3,4,5,6,7,8,9,10}.txt:
New test reference output files.
* tests/data/test-diff-suppr/test47-non-reachable-types-v{0,1}.o.alltypes.abixml:
New test input abixml.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new tests above
to this test harness.
* tests/data/test-abidiff/test-struct1-report.txt: Adjust.
* tests/data/test-diff-pkg/PR24690/flatpak-debuginfo-1.2.4-3.fc30.x86_64.rpm:
New input binary RPM.
* tests/data/test-diff-pkg/PR24690/flatpak-debuginfo-1.4.0-1.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24690/flatpak-devel-1.2.4-3.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24690/flatpak-devel-1.4.0-1.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24690/flatpak-libs-1.2.4-3.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24690/flatpak-libs-1.4.0-1.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24690/flatpak-libs-debuginfo-1.2.4-3.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24690/flatpak-libs-debuginfo-1.4.0-1.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24690/PR24690-report-0.txt: New test
reference output.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test material
above to this test harness.
2019-11-26 Dodji Seketeli <dodji@redhat.com>
Small style fix in abg-default-reporter.cc
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for corpus_diff, break a line longer than 80 characters.
2019-10-21 Matthias Maennich <maennich@google.com>
dwarf-reader: add support for symbol namespaces in ksymtab entries
* src/abg-dwarf-reader.cc
(read_context::try_reading_first_ksymtab_entry): Add
symbol_offset parameter.
(read_context::get_ksymtab_entry_size): Add support for variable
size ksymtab entries due to symbol namespaces.
(load_kernel_symbol_table): only load nb_entries when needed
[1] https://lore.kernel.org/lkml/20190906103235.197072-1-maennich@google.com/
2019-10-21 Matthias Maennich <maennich@google.com>
dwarf-reader: refactor try_reading_first_ksymtab_entry_using{pre,}_v4_19_format
* src/abg-dwarf-reader.cc(try_reading_first_ksymtab_entry):
New function to consolidate functionality for
try_reading_first_ksymtab_entry_using_{pre,}v4_19_format functions.
(try_reading_first_ksymtab_entry_using_v4_19_format,
try_reading_first_ksymtab_entry_using_pre_v4_19_format):
refactor to use try_reading_first_ksymtab_entry
2019-10-28 Dodji Seketeli <dodji@redhat.com>
Bug 25128 - Handle decl-only classes that differ only in size
* include/abg-comp-filter.h (is_decl_only_class_with_size_change):
Declare an overload.
* include/abg-fwd.h (look_through_decl_only_class): Declare an
overload.
* src/abg-comp-filter.cc (is_decl_only_class_with_size_change):
Define an overload that takes class_or_union& type. Re-write the
previous overload in terms of this new one.
* src/abg-ir.cc (look_through_decl_only_class): Define a new
overload that takes a class_or_union&. Rewrite the previous
overload in terms of this one.
(equals): In the overload for class_or_union&, use
is_decl_only_class_with_size_change to detect cases of decl-only
classes that differ only by their size attribute and avoid
comparing them.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
2019-10-24 Dodji Seketeli <dodji@redhat.com>
Bug 25128 - Leaf diff reporter shouldn't compare decl-only classes
* include/abg-comp-filter.h (is_decl_only_class_with_size_change):
Declare new function.
* src/abg-comp-filter.cc (is_decl_only_class_with_size_change):
Define new function.
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Use the newly
defined is_decl_only_class_with_size_change above to ignore bogus
decl-only classes with a size change.
* tests/data/test-diff-suppr/test45-abi-report-1.txt: New test input.
* tests/data/test-diff-suppr/test45-abi-wl.xml: Likewise.
* tests/data/test-diff-suppr/test45-abi.xml: Likewise.
* tests/data/test-diff-suppr/test45-abi.suppr.txt: New reference
output for the test input above.
* tests/data/test-diff-suppr/test46-PR25128-base.xml: New test input.
* tests/data/test-diff-suppr/test46-PR25128-new.xml: Likewise.
* tests/data/test-diff-suppr/test46-PR25128-report-1.txt: New
reference input for the test input above.
* tests/data/Makefile.am: Add the new test material to source distribution.
* tests/test-diff-suppr.cc (in_out_spec): Add the new test input
above to this test harness.
2019-10-18 Dodji Seketeli <dodji@redhat.com>
Bug 25095 - Apply symbol white lists to ELF symbols
* src/abg-tools-utils.cc (gen_suppr_spec_from_kernel_abi_whitelist):
Generate a suppression specification which considers the name of
the symbol associated to a function/variable, rather than just the
name of said function/variable.
2019-10-18 Dodji Seketeli <dodji@redhat.com>
Support symbol_name_not_regexp in [suppress_{function, variable}]
* doc/manuals/libabigail-concepts.rst: Document the new
symbol_name_not_regexp properties for the
suppress_{function,variable} directives.
* include/abg-suppression.h
({function,variable}_suppression::{g,s}et_symbol_name_not_regex_str):
Declare new member functions.
* src/abg-dwarf-reader.cc
(read_context::is_elf_symbol_suppressed): Define new member functions.
(read_context::{load_symbol_maps_from_symtab_section,
populate_symbol_map_from_ksymtab,
populate_symbol_map_from_ksymtab_reloc}): Drop suppressed symbols
when reading symbol tables.
({function,variable}_is_suppressed): Consider that in C, the
linkage name is _by default_ the same as the function/variable
name. Remove local variable.
* include/abg-ir.h (elf_symbol_is_{function,variable}): Add ...
* src/abg-ir.cc (elf_symbol_is_{function,variable}): ... new
functions.
* src/abg-reader.cc (build_elf_symbol): Take an additional boolean
to detect and drop suppressed symbols.
(build_elf_symbol_db): Adjust the call to build_elf_symbol to make
it detect and drop suppressed symbols.
(read_corpus_from_input): Be mindful that the set of symbols for a
given corpus can be empty because of suppression specifications.
* src/abg-suppression-priv.h
({function,variable}_suppression::priv::symbol_name_not_regex[_str_]):
Add new data members.
(function,variable}_suppression::priv::get_symbol_name_not_regex):
Add new member functions.
({function,variable}_is_suppressed): Guard against empty name.
(is_elf_symbol_suppressed): Define new function template.
* src/abg-suppression.cc
({function,variable}_suppression::{g,s}et_symbol_name_not_regex_str):
Define new member functions.
({function,variable}_suppression::suppresses_function)
(suppression_matches_{function,variable}_sym_name)
(read_{function,variable}_suppression): Support the new
"symbol_name_not_regex" property.
* tests/data/test-diff-suppr/test44-suppr-sym-name-not-regexp-report-1.txt:
New test reference report.
* tests/data/test-diff-suppr/test44-suppr-sym-name-not-regexp-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test44-suppr-sym-name-not-regexp-v{0,1}.c:
Sources of the new test input.
* tests/data/test-diff-suppr/test44-suppr-sym-name-not-regexp-v{0,1}.o:
New test input binaries.
* tests/data/test-diff-suppr/test44-suppr-sym-name-not-regexp-v{0,1}.o.abi:
New test input abixml files.
* tests/data/test-diff-suppr/test44-suppr-sym-name-not-regexp.suppr.txt:
Next test suppression specification.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the input tests
above to the test harness.
2019-10-24 Dodji Seketeli <dodji@redhat.com>
[abg-comparison.cc] Fix comments typo
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Fix typo in comment.
2019-10-04 Matthias Maennich <maennich@google.com>
kmidiff: fix help message
* tools/kmidiff.c (display_usage): add missing line breaks to
help text
2019-10-04 Matthias Maennich <maennich@google.com>
dwarf-reader: read_corpus_from_elf: unconditionally load elf properties
* src/abg-dwarf-reader.cc (read_corpus_from_elf):
unconditionally load elf properties into context
2019-10-04 Dodji Seketeli <dodji@redhat.com>
PR25058 - Better support fn DIEs referring to symbols using DW_AT_ranges
* src/abg-dwarf-reader.cc
(read_context::get_first_exported_fn_address_from_DW_AT_ranges):
Rename read_context::get_first_address_from_DW_AT_ranges into
this. Walk through the addresses referred to by the DW_AT_ranges
attribute until we find one that is for an exported function
symbol, rather than just picking the first address of the set.
(read_context::get_function_address): Adjust.
2019-10-03 Dodji Seketeli <dodji@redhat.com>
PR25058 - Support decl DIEs referring to symbols using DW_AT_ranges
* src/abg-dwarf-reader.cc
(read_context::get_first_address_from_DW_AT_ranges): Define new
member function.
(read_context::get_function_address): Use the new
read_context::get_first_address_from_DW_AT_ranges here.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl-report-1.txt:
New reference test output.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl.so: New test
input binary.
* tests/data/test-diff-dwarf/PR25058-liblttng-ctl2.10.so: New test
input binary.
* tests/data/Makefile.am: Add the new test materials above to
source distribution.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new input test
input binary files to this test harness.
2019-10-01 Dodji Seketeli <dodji@redhat.com>
Fix thinkos in DW_FORM_strx detection in configure.ac
* configure.ac: Fix thinko when setting the HAVE_DW_FORM_strx
macro.
2019-10-01 Dodji Seketeli <dodji@redhat.com>
Fix a typo in a comment of abg-dwar-reader.cc
* src/abg-dwarf-reader.cc (compare_dies_string_attribute_value):
Fix a typo in the comment of this function.
2019-09-30 Dodji Seketeli <dodji@redhat.com>
PR25042 - Support string form DW_FORM_strx{1,4} from DWARF 5
* configure.ac: Detect the presence of the DW_FORM_strx{1,4}
enumerators.
* src/abg-dwarf-reader.cc (form_is_DW_FORM_strx): Define new
function.
(compare_dies_string_attribute_value): Use the new
form_is_DW_FORM_strx here.
* tests/data/Makefile.am: Add the new test input files below to
source distribution.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0:
New binary test input file.
* tests/data/test-read-dwarf/PR25042-libgdbm-clang-dwarf5.so.6.0.0.abi:
Reference output of the new binary test input file.
* tests/test-read-dwarf.cc (in_out_specs): Add the input test
files above to the test harness, for platforms that support the
DW_FORM_strx form.
2019-09-04 Dodji Seketeli <dodji@redhat.com>
Support the "name_not_regexp" property in the [suppress_type] section
* doc/manuals/libabigail-concepts.rst: Update this to document the
new name_not_regexp property of the suppress_type directive.
* include/abg-suppression.h
(type_suppression::{g,s}et_type_name_not_regex_str): Declare new accessors.
* src/abg-suppression-priv.h
(type_suppression::priv::{type_name_not_regex_str_,
type_name_not_regex_}): Define new data members.
(type_suppression::priv::{get_type_name_not_regex,
set_type_name_not_regex, get_type_name_not_regex_str,
set_type_name_not_regex_str}): Define new member functions.
* src/abg-suppression.cc
(type_suppression::get_type_name_regex_str): Fix comments.
(type_suppression::{set_type_name_not_regex_str,
get_type_name_not_regex_str}): Define new data members.
(suppression_matches_type_name): Adapt to support the new
type_name_not_regex property.
(read_type_suppression): Support parsing the type_name_not_regexp
property.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-0.txt:
New test reference output.
* tests/data/test-diff-suppr/test42-negative-suppr-type-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test42-negative-suppr-type-suppr-1.txt:
New test input.
* tests/data/test-diff-suppr/test42-negative-suppr-type-suppr-2.txt: Likewise.
* tests/data/test-diff-suppr/test42-negative-suppr-type-v0.{cc, o}: Likewise.
* tests/data/test-diff-suppr/test42-negative-suppr-type-v1.{cc,
o}: Likewise.
* tests/data/Makefile.am: Add the test files above to source
distribution.
* tests/test-diff-suppr.cc (int_out_specs): Add the new tests to
the harness.
2019-09-04 Dodji Seketeli <dodji@redhat.com>
Better propagation of suppressed-ness to function types
* src/abg-comparison.cc
(suppression_categorization_visitor::visit_end): Propagate
suppression-ness from suppressed function type diff node to its
parent function node if the latter doesn't have any local non-type
change.
* tests/data/test-diff-suppr/test43-suppr-direct-fn-subtype-report-1.txt:
New test reference output.
* tests/data/test-diff-suppr/test43-suppr-direct-fn-subtype-suppr-1.txt:
New test input suppression file.
* tests/data/test-diff-suppr/test43-suppr-direct-fn-subtype-v{0,1}.cc:
Source code of input binary file.
* tests/data/test-diff-suppr/test43-suppr-direct-fn-subtype-v{0,1}.o:
Input binary files.
* tests/data/Makefile.am: Add the new test input files above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the test input to
test harness.
2019-09-04 Dodji Seketeli <dodji@redhat.com>
[has_type_change] Better detect type size changes
* src/abg-comp-filter.cc (has_type_change): Support function
parameters.
2019-09-23 Dodji Seketeli <dodji@redhat.com>
Fix reading of relocation sections when endianness mismatches
* src/abg-dwarf-reader.cc
(read_context::{get_ksymtab_format_module,
populate_symbol_map_from_ksymtab_reloc}): Use elf_getdata rather
than elf_rawdata.
2019-09-20 Dodji Seketeli <dodji@redhat.com>
Guard testing v4.19+ AARCH64 kernel module loading for EL6 support
* tests/test-read-dwarf.cc: Do not run the test on
PR25007-sdhci.ko if the macros R_AARCH64_PREL32 and
R_AARCH64_ABS64 are not defined.
2019-09-19 Dodji Seketeli <dodji@redhat.com>
Remove the elf_symbol::get_value property
* include/abg-ir.h (elf_symbol::{elf_symbol, create}): Remove the
'val' parameter.
* src/abg-dwarf-reader.cc (elf_symbol::get_value): Remove this
member function declaration.
(lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab, lookup_symbol_from_symtab)
(create_default_var_sym, create_default_fn_sym)
(read_context::lookup_elf_symbol_from_index): Adjust calls to
creating elf_symbol instances.
* src/abg-ir.cc (elf_symbol::priv::value_): Remove this data
member.
(elf_symbol::{priv::priv, elf_symbol, create): Adjust.
* src/abg-reader.cc (build_elf_symbol): Likewise.
2019-09-19 Dodji Seketeli <dodji@redhat.com>
Bug 25007 - Don't use section-relative symbol values on ET_REL binaries
* src/abg-dwarf-reader.cc
(read_context::{lookup_native_elf_symbol_from_index,
maybe_adjust_et_rel_sym_addr_to_abs_addr}): Define new member
functions.
(read_context::lookup_elf_symbol_from_index): Add a new overload.
Write the old overloads in terms of the new one.
(read_context::{load_symbol_maps_from_symtab_section,
populate_symbol_map_from_ksymtab_reloc}): Use the new
maybe_adjust_et_rel_sym_addr_to_abs_addr function to translate the
symbol value/address into a binary-relative address before adding
it to the addr->sym maps.
(read_context::maybe_adjust_{fn, var}_sym_address): Do not adjust
DWARF-referred-to addresses of ET_REL symbols anymore.
* tests/data/test-read-dwarf/PR25007-sdhci.ko: New binary test input.
* tests/data/test-read-dwarf/PR25007-sdhci.ko.abi: ABI
representation of the above.
* tests/test-read-dwarf.cc: Add the new test input to the harness.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt: Adjust.
* tests/data/test-diff-filter/test20-inline-report-0.txt: Likewise.
* tests/data/test-diff-filter/test20-inline-report-1.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
2019-09-18 Dodji Seketeli <dodji@redhat.com>
Detect the presence of R_AARCH64_{ABS64, PREL32} macros
* configure.ac: Define macros HAVE_R_AARCH64_{ABS64, PREL32}_MACRO
if the macros R_AARCH64_{ABS64, PREL32} are present.
* src/abg-dwarf-reader.cc
(read_context::get_ksymtab_format_module): Conditionalize the use
of R_AARCH64_{ABS64, PREL32} using HAVE_R_AARCH64_{ABS64, PREL32}_MACRO.
2019-09-03 Jessica Yu <jeyu@kernel.org>
Support pre and post v4.19 ksymtabs for Linux kernel modules
* include/abg-ir.h (elf_symbol::{elf_symbol, create}): Take new
symbol value and shndx parameters.
(elf_symbol::{get_value, get_shndx}): Declare new accessors.
* src/abg-ir.cc (elf_symbol::priv::{value_, shndx_}): New data
members.
(elf_symbol::priv::priv): Adjust.
(elf_symbol::elf_symbol): Take new value and is_linux_string_cst
parameters.
(elf_symbol::create): Likewise.
(elf_symbol::{get_value, get_is_linux_string_cst}): Define new
accessors.
* src/abg-reader.cc (build_elf_symbol): Adjust.
* src/abg-dwarf-reader.cc (binary_is_linux_kernel)
(binary_is_linux_kernel): New static functions.
(lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab)
(lookup_symbol_from_symtab): Adjust.
(read_context::{ksymtab_reloc_section_,
ksymtab_gpl_reloc_section_, ksymtab_strings_section_}): New data
members.
(read_context::read_context): Initialize ksymtab_reloc_section_,
ksymtab_gpl_reloc_section_, ksymtab_strings_section_.
(read_context::{find_ksymtab_reloc_section,
find_ksymtab_gpl_reloc_section, find_ksymtab_strings_section,
find_any_ksymtab_reloc_section, get_ksymtab_format_module,
populate_symbol_map_from_ksymtab,
populate_symbol_map_from_ksymtab_reloc, is_linux_kernel_module}):
New member functions.
(read_context::load_kernel_symbol_table): Adjust to call either
populate_symbol_map_from_ksymtab{_reloc,} depending on ksymtab
format.
(read_context::get_ksymtab_format): Adjust to call
get_ksymtab_format_module for linux kernel modules.
(read_context::lookup_elf_symbol_from_index): Adjust.
(create_default_var_sym, create_default_fn_sym): Adjust.
2019-08-02 Dodji Seketeli <dodji@redhat.com>
Serialize canonical types to avoid testing if types have been emitted
* include/abg-fwd.h (is_decl_slow)
(peel_pointer_or_reference_type): Declare new functions.
* include/abg-ir.h (struct canonical_type_hash): Define new type.
(type_base_ptr_set_type, type_base_ptrs_type)
(type_base_sptrs_type, canonical_type_sptr_set_type): Define new
typedefs.
(environment::get_canonical_types_map): Declare new member
function.
(scope_decl::{get_canonical_types, get_sorted_canonical_types}):
Declare new member functions.
* src/abg-ir.cc (is_ptr_ref_or_qual_type)
(peel_pointer_or_reference_type, is_decl_slow): Define new
functions.
(environment::{get_canonical_types_map}): Define new member
functions.
(canonical_type_hash::operator()): Likewise.
(scope_decl::{get_canonical_types, get_sorted_canonical_types}):
Likewise.
(struct type_topo_comp): Define new comparison functor type.
(environment::{sorted_canonical_types_}): Define new data member.
(scope_decl::priv::{canonical_types_, sorted_canonical_types_}):
Likewise.
(scope_decl::is_empty): Take the presence of canonical types into
account when determining if a scope is empty or not.
(is_decl): Make this work for cases where the artifact at hand is
a type which has a declaration, as opposed to being a pure
declaration like a variable or a function.
(canonicalize): Add the canonical type the list of canonical types
of its scope.
* src/abg-dwarf-reader.cc (read_context::die_is_in_cplus_plus):
Define new member function.
* src/abg-writer.cc (write_type, write_canonical_types_of_scope):
Define new static functions.
(fn_type_ptr_set_type): Define new typedef.
(write_context::{m_referenced_fn_types_set,
m_referenced_non_canonical_types_set}): Add new data members.
(write_context::m_referenced_types_set): Renamed
m_referenced_types_map into this.
(write_context::get_referenced_types): Adjust.
(write_context::get_referenced_{function_types,
non_canonical_types}):
(write_context::record_type_as_referenced): Adjust to add the
referenced type in the proper set which would be one of the three
following: write_context::{get_referenced_types,
get_referenced_function_types,
get_referenced_non_canonical_types}.
(write_context::{type_is_referenced, clear_referenced}): Adjust.
(write_translation_unit): Use the new
write_canonical_types_of_scope. Also emit declaration-only
classes that have member types. Do not test if a given type of a
given scope has been emitted, in general, as this was super slow
given the number of types. Emit referenced function types (as
these don't belong to any scope). Rather than using the expensive
"is_function_type" on *all* the referenced types, just walk the
set write_context::get_referenced_function_types. Likewise,
rather than using type_base::get_naked_canonical_type on
*all* the referenced types, just walk the set
write_context::get_referenced_non_canonical_types
(write_class): Use write_canonical_types_of_scope here.
* tools/abilint.cc (main): Support linting corpus group abixml
files.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test10.xml: Likewise.
* tests/data/test-read-write/test14.xml: Likewise.
* tests/data/test-read-write/test15.xml: Likewise.
* tests/data/test-read-write/test17.xml: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test19.xml: Likewise.
* tests/data/test-read-write/test2.xml: Likewise.
* tests/data/test-read-write/test20.xml: Likewise.
* tests/data/test-read-write/test21.xml: Likewise.
* tests/data/test-read-write/test22.xml: Likewise.
* tests/data/test-read-write/test23.xml: Likewise.
* tests/data/test-read-write/test24.xml: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
* tests/data/test-read-write/test26.xml: Likewise.
* tests/data/test-read-write/test27.xml: Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml: Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml: Likewise.
* tests/data/test-read-write/test3.xml: Likewise.
* tests/data/test-read-write/test6.xml: Likewise.
2019-07-24 Matthias Maennich <maennich@google.com>
abg-dwarf-reader: detect kernel modules without exports as such
* src/abg-dwarf-reader.cc(is_linux_kernel_binary): consider
binaries only having a .modinfo section to be kernel binaries
Co-developed-by: Alessio Balsini <balsini@android.com>
2019-07-22 Matthias Maennich <maennich@google.com>
Ensure a consistent C++ standard use
* configure.ac: add -std=c++11 flag to CXXFLAGS when compiling
for C++11
* src/Makefile.am: drop now obsolete setting of the -std flag
* tests/Makefile.am: likewise
Reported-by: Chun-Hung Wu <Chun-hung.Wu@mediatek.com>
2019-07-19 Dodji Seketeli <dodji@redhat.com>
Bug 24787 - Filter out enum changes into compatible integer types
* include/abg-comparison.h (peel_typedef_or_qualified_type_diff):
Declare new function.
(peel_pointer_or_qualified_type_diff): Rename
peel_pointer_or_qualified_type into this.
* include/abg-fwd.h (is_enum_type): Declare a new overload for
type_or_decl_base*.
* src/abg-comp-filter.cc (has_harmless_enum_to_int_change): Define
new static function.
* src/abg-comparison.cc (categorize_harmless_diff_node): Use the
new has_harmless_enum_to_int_change here.
(peel_pointer_or_qualified_type_diff): Renamed
peel_pointer_or_qualified_type into this.
(is_diff_of_basic_type): Adjust.
(peel_typedef_or_qualified_type_diff): Define new function.
* test-diff-filter/PR24787-lib{one, two}.so: New test input
binaries.
* test-diff-filter/PR24787-{one, two}.c: Source files of the test
input binaries above.
* test-diff-filter/PR24787-report-0.txt: Test output reference.
* tests/data/Makefile.am: Add the new testing material to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test to
the test harness.
2019-07-19 Dodji Seketeli <dodji@redhat.com>
Add timing to the verbose logs of abidw
* include/abg-tools-utils.h (class timer): Declare new type.
(operator<<(ostream&, const timer&)): Declare new streaming
operator for the new timer type.
* src/abg-tools-utils.cc (struct timer::priv): Define new type.
(timer::{timer, start, stop, value_in_seconds, value,
value_as_string, ~timer}): Define member functions.
(operator<<(ostream& o, const timer& t)): Define streaming
operator.
(build_corpus_group_from_kernel_dist_under): Add timing logs to
the linux kernel reading process.
* src/abg-dwarf-reader.cc
(read_context::canonicalize_types_scheduled): Add timing logs to
type canonicalization.
(read_debug_info_into_corpus): Add timing logs for the whole debug
info loading and internal representation building process.
* tools/abidw.cc (load_corpus_and_write_abixml): Add timing logs
for the binary loading and serizalization process.
(load_kernel_corpus_group_and_write_abixml): Add timing logs the
Linux Kernel binary loading and writing process.
2019-07-18 Dodji Seketeli <dodji@redhat.com>
[ir] Fix indentation and add comments
* src/abg-ir.cc (types_defined_same_linux_kernel_corpus_public):
Fix indentation and add comments.
2019-07-15 Dodji Seketeli <dodji@redhat.com>
Implement fast comparison of Linux Kernel types when applicable
* include/abg-corpus.h (corpus::origin): Add a new
LINUX_KERNEL_BINARY_ORIGIN enumerator.
(corpus::{s,g}et_group): Declare new member
functions.
(class corpus): Make the corpus_group class friend of this one.
(corpus_group::get_main_corpus): Declare new member function.
* src/abg-corpus-priv.h (corpus::priv::group): Define new data
member.
(corpus::priv::priv): Initialize the new corpus::priv::group data
member.
* src/abg-corpus.cc (corpus::{g,s}et_group): Define new member
functions.
(corpus_group::get_main_corpus): Likewise.
(corpus_group::add_corpus): Use the new corpus::set_group() here
to to make the corpus be aware of the group it belongs to.
* src/abg-dwarf-reader.cc (read_debug_info_into_corpus): Set the
current corpus origin to the corpus::LINUX_KERNEL_BINARY_ORIGIN if
we are looking at a Linux Kernel binary.
(read_context::main_corpus_from_current_group): Use the
corpus_group::get_main_corpus method.
(should_reuse_type_from_corpus_group): Return the corpus group,
rather than the main corpus.
(read_debug_info_into_corpus): Add the current corpus to the
current corpus group before the debug info reading is done. That
way, the corpus group will be accessible from the current corpus
during the construction of the internal representation.
(read_and_add_corpus_to_group_from_elf): Add the corpus to the
group only if it wasn't added to it before.
* include/abg-ir.h (operator{==,!=}): Declare new deep equality
and inequality operators for class_or_union_sptr and
union_decl_sptr.
* src/abg-ir.cc (types_defined_same_linux_kernel_corpus_public):
Define a new static function.
(type_base::get_canonical_type_for): Use the new
types_defined_same_linux_kernel_corpus_public here to speed up
type comparison.
(equals): In the overload of class_or_union, use the new
types_defined_same_linux_kernel_corpus_public as well, to speed up
type comparison.
(operator{==,!=}): Define new deep equality and inequality
operators for class_or_union_sptr and union_decl_sptr.
(maybe_update_types_lookup_map): In the overload function for
type_decl_sptr, class_decl_sptr, union_decl_sptr,
enum_type_decl_sptr, typedef_decl_sptr, qualified_type_def_sptr,
reference_type_def_sptr, array_type_def_sptr,
array_type_def::subrange_sptr, and function_type_sptr, update the
type lookup maps of the containing corpus group as well, not just
the ones of the current corpus.
* src/abg-reader.cc (build_enum_type_decl): Forgot to set the
"is-anonymous" flag. Oops, fix this.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2019-07-09 Matthias Maennich <maennich@google.com>
abg-tools-utils: add missing header include guards
* include/abg-tools-utils.h: add header include guards
2019-07-05 Matthias Maennich <maennich@google.com>
Add compatibility layer for C++11 mode
* include/abg-cxx-compat.h: new file introducing the abg_compat
namespace to provide C++11 functionality from either std::tr1
or std::
* include/Makefile.am: Add the new abg-cxx-compat.h to source
distribution.
* include/abg-comparison.h: replace std::tr1 usage by abg_compat
and adjust includes accordingly: likewise
* include/abg-diff-utils.h: likewise
* include/abg-fwd.h: likewise
* include/abg-ini.h: likewise
* include/abg-interned-str.h: likewise
* include/abg-ir.h: likewise
* include/abg-libxml-utils.h: likewise
* include/abg-libzip-utils.h: likewise
* include/abg-reporter.h: likewise
* include/abg-sptr-utils.h: likewise
* include/abg-suppression.h: likewise
* include/abg-tools-utils.h: likewise
* include/abg-workers.h: likewise
* src/abg-comp-filter.cc: likewise
* src/abg-comparison-priv.h: likewise
* src/abg-corpus.cc: likewise
* src/abg-dwarf-reader.cc: likewise
* src/abg-hash.cc: likewise
* src/abg-ir.cc: likewise
* src/abg-reader.cc: likewise
* src/abg-suppression.cc: likewise
* src/abg-tools-utils.cc: likewise
* src/abg-writer.cc: likewise
* tests/test-diff-filter.cc: likewise
* tests/test-diff-pkg.cc: likewise
* tests/test-read-dwarf.cc: likewise
* tests/test-read-write.cc: likewise
* tests/test-types-stability.cc: likewise
* tests/test-write-read-archive.cc: likewise
* tools/abicompat.cc: likewise
* tools/abidiff.cc: likewise
* tools/abidw.cc: likewise
* tools/abilint.cc: likewise
* tools/abipkgdiff.cc: likewise
2019-07-05 Matthias Maennich <maennich@google.com>
Update tests/.gitignore to ignore runtesttoolsutils
* tests/.gitignore: ignore runtesttoolsutils
2019-07-05 Matthias Maennich <maennich@google.com>
Drop requirement to compile with GNU extensions
* include/abg-tools-utils.h (get_stream): Change return type to
std::fstream
* src/abg-corpus.cc: remove unused #include of ext/stdio_filebuf.h
* src/abg-tools-utils (temp_file::priv): remove filebuf_ member,
and replace iostream_ by fstream_ with changing the shared_ptr
type accordingly
(temp_file::priv::priv): initialize fstream_ based on
temporary file name
(temp_file::priv::~priv): adjust destruction accordingly
(temp_file::is_good): test the fstream rather than the fd
(temp_file::get_stream): adjust return type to std::fstream
and adjust implementation based on the changes in temp_file::priv
* src/Makefile.am: remove gnu extension from c++ standard flag
* tests/Makefile.am: likewise
2019-07-09 Dodji Seketeli <dodji@redhat.com>
Misc indent cleanup
* src/abg-dwarf-reader.cc (addr_elf_symbol_sptr_map_sptr): Fix a
typo in the comment of this typedef.
* src/abg-ir.cc (hash_type_or_decl): Fix typo in a comment.
* src/abg-writer.cc (write_translation_unit): Remove useless
vertical space.
2019-07-08 Dodji Seketeli <dodji@redhat.com>
[xml-writer] Remove a useless kludge
* src/abg-writer.cc (write_context::type_is_emitted): Remove
useless kludge from here.
2019-07-08 Dodji Seketeli <dodji@redhat.com>
[xml-writter] Speedup function_type::get_cached_name
* src/abg-ir.cc (function_type::get_cached_name): Really cache the
computed name of function_type instances.
2019-07-08 Dodji Seketeli <dodji@redhat.com>
[xml-writter] Avoid using RTTI when dynamically hashing types
* include/abg-fwd.h (hash_type): Declare new function.
* src/abg-ir.cc (hash_type): Define new function.
* src/abg-writer.cc (type_hasher::operator()): Use the new
hash_type rather than the old hash_type_or_decl.
2019-07-08 Dodji Seketeli <dodji@redhat.com>
Implement a poor-man's RTTI for performance
* include/abg-fwd.h (is_type_decl): Replace the overloads
that takes a type_base* and/or a decl_base* by one that takes a
type_or_decl_base*.
* include/abg-ir.h (type_or_decl_base::type_or_decl_kind): Define
new enum.
(type_or_decl_base::{kind, runtime_type_instance,
type_or_decl_base_pointer}): Declare new accessors.
(operator{|,|=,&,&=): Declare new operators for the new
type_or_decl_base::type_or_decl_kind enum.
(global_scope::global_scope): Move the definition of this
constructor to ...
* src/abg-ir.cc (global_scope::global_scope): ... here.
(type_or_decl_base::priv::{kind_, rtti_, type_or_decl_ptr_}):
Add new data members.
(type_or_decl_base::priv::priv): Take a
type_or_decl_base::type_or_decl_kind enum.
(type_or_decl_base::priv::kind): Define new accessors.
(operator{|,|=,&,&=): Define new operators for the new
type_or_decl_base::type_or_decl_kind enum.
(type_or_decl_base::type_or_decl_base): Take a
type_or_decl_base::type_or_decl_kind enum.
(type_or_decl_base::{kind, runtime_type_instance,
type_or_decl_base_pointer}): Define new accessors.
(decl_base::decl_base, scope_decl::scope_decl)
(type_base::type_base, scope_type_decl::scope_type_decl)
(class_or_union::class_or_union) : Adjust to set the runtime type
identifier of the instances of these types.
(global_scope::global_scope, type_decl::type_decl)
(qualified_type_def::qualified_type_def)
(pointer_type_def::pointer_type_def)
(reference_type_def::reference_type_def
array_type_def::subrange_type::subrange_type)
(array_type_def::array_type_def, enum_type_decl::enum_type_decl)
(typedef_decl::typedef_decl, var_decl::var_decl)
(function_type::function_type, method_type::method_type)
(function_decl::function_decl)
(function_decl::parameter::parameter, method_decl::method_decl)
(class_decl::class_decl, class_decl::base_spec::base_spec)
(union_decl::union_decl, template_decl::template_decl)
(type_tparameter::type_tparameter)
(non_type_tparameter::non_type_tparameter)
(template_tparameter::template_tparameter)
(type_composition::type_composition)
(function_tdecl::function_tdecl, function_tdecl::function_tdecl)
(class_tdecl::class_tdecl):
Likewise and call runtime_type_instance() here to set the runtime
type instance pointers of the current instance.
(is_decl, is_type, is_class_type, is_pointer_type): Adjust to use
the new poor-man's rtti machinery.
(is_type_decl): Replace the overloads that takes a type_base*
and/or a decl_base* by one that takes a type_or_decl_base*.
(pointer_type_def::operator==, class_decl::operator==): Use the
poor-man's rtti machinery to replace dynamic_cast.
hash_type_or_decl: Replace dynamic_cast<const type_base> by
is_type() and dynamic_cast<const decl_base*> by is_decl().
2019-07-05 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Make sure to canonicalize anonymous types
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Add two new
overloads. One that takes type_base_sptr, one that takes a
Dwarf_Die* and type_base_sptr. These force canonicalization for
anonymous types.
(build_function_type): Schedule function types for
canonicalization.
(build_ir_node_from_die): For struct/classes and unions, use the
new overload of maybe_canonicalize_type to schedule
canonicalization.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2019-07-04 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Constify the first parameter of maybe_canonicalize_type
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Make the
first parameter const.
(read_context::{get_canonical_die, lookup_artifact_from_die,
lookup_type_from_die, schedule_type_for_late_canonicalization}):
Adjust.
2019-06-26 Dodji Seketeli <dodji@redhat.com>
Make abidiff --harmless show harmless changes in unions
* include/abg-fwd.h (get_class_or_union_flat_representation): Add
a "qualified_name" boolean parameter.
* include/abg-ir.h ({type_or_decl_base, decl_base, type_decl,
namespace_decl, array_type_def::subrange_type, array_type_def,
enum_type_decl, typedef_decl, var_decl, function_decl,
function_decl::parameter, function_type, method_type, class_decl,
union_decl}::get_pretty_representation): Likewise.
* src/abg-ir.cc ({type_or_decl_base, decl_base, type_decl,
namespace_decl, array_type_def::subrange_type, array_type_def, enum_type_decl,
typedef_decl, var_decl, function_decl, function_decl::parameter,
function_type, method_type, class_decl, union_decl,
}::get_pretty_representation): Adjust the code to emit qualified
or non-qualified names depending on the new "qualified_name"
boolean parameter.
(get_class_or_union_flat_representation): Likewise.
* src/abg-default-reporter.cc (default_reporter::report): Use
get_class_or_union_flat_representation with the new
"qualified_name" boolean set to false.
* tests/data/test-diff-dwarf/test38-union-report-0.txt: Adjust.
* tests/test-diff-filter.cc (in_out_specs): Run the test harness
on test-PR24731-v{0,1}.o make abidiff use the --harmless option.
2019-06-26 Dodji Seketeli <dodji@redhat.com>
Bug 24731 - Wrongly reporting union members order change
* include/abg-comp-filter.h (union_diff_has_harmless_changes):
Declare new function and ...
* src/abg-comp-filter.cc (union_diff_has_harmless_changes):
... define it here.
(categorize_harmless_diff_node): Use the new
union_diff_has_harmless_changes here.
* include/abg-comparison.h (HARMLESS_UNION_CHANGE_CATEGORY): Add a
new enumerator to diff_category enum. Adjust the value of the
other enumerators.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Add the new HARMLESS_UNION_CHANGE_CATEGORY in here.
(operator<<(ostream& o, diff_category c)): Support the new
HARMLESS_UNION_CHANGE_CATEGORY.
* tests/data/test-diff-filter/test-PR24731-report-0.txt: Likewise.
* tests/data/test-diff-filter/test-PR24731-report-1.txt: Likewise.
* tests/data/test-diff-filter/test-PR24731-v0.c: Likewise.
* tests/data/test-diff-filter/test-PR24731-v0.o: Likewise.
* tests/data/test-diff-filter/test-PR24731-v1.c: Likewise.
* tests/data/test-diff-filter/test-PR24731-v1.o: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-filter.cc (in_out_spec): Add the new test input
to this test harness.
2019-06-20 Dodji Seketeli <dodji@redhat.com>
Fully account for anonymous-ness of scopes when comparing decl names
* include/abg-ir.h (decl_base::{get_has_anonymous_parent,
set_has_anonymous_parent,
get_is_anonymous_or_has_anonymous_parent}): Declare new member
functions.
* src/abg-ir.cc (decl_base::priv::has_anonymous_parent_): Define
new data member.
(decl_base::priv): Initialize the new data member.
(decl_base::{get_has_anonymous_parent, set_has_anonymous_parent,
get_is_anonymous_or_has_anonymous_parent}): Define new member
functions.
(equals): In the overload for decl_base, use the new
decl_names_equal for decls that have anonymous scopes.
(scope_decl::add_member_decl): Propagate the
decl_base::has_anonymous_parent_ property.
* include/abg-tools-utils.h
(get_anonymous_struct_internal_name_prefix)
(get_anonymous_union_internal_name_prefix)
(get_anonymous_enum_internal_name_prefix, decl_names_equal):
Declare new functions.
* src/abg-comp-filter.cc (has_harmless_name_change): Handle the
case where the name change is actually from an anonymous name to
another one, using the new decl_names_equal function.
* src/abg-dwarf-reader.cc
(get_internal_anonymous_die_prefix_name): Renamed
get_internal_anonynous_die_base_name into this. Use the new
get_anonymous_{struct, union, enum}_internal_name_prefix functions
here.
(get_internal_anonymous_die_name, die_qualified_type_name)
(build_enum_type, add_or_update_class_type)
(add_or_update_union_type): Adjust.
* src/abg-tools-utils.cc (get_anonymous_struct_internal_name_prefix)
(get_anonymous_union_internal_name_prefix)
(get_anonymous_enum_internal_name_prefix, decl_names_equal):
Define new functions.
* tests/test-tools-utils.cc: New test file.
* tests/Makefile.am: Add new runtesttoolsutils test, built from
test-tools-utils.cc.
* tests/data/test-diff-dwarf/test46-rust-report-0.txt: Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
2019-06-12 Matthias Maennich <maennich@google.com>
abg-reporter.h: add missing includes / using declarations
* include/abg-reporter.h: fix includes and using declarations
2019-06-17 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Fix indentation in compare_dies_string_attribute_value
* src/abg-dwarf-reader.cc (compare_dies_string_attribute_value):
Fix indentation.
2019-06-17 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Optimize speed of compare_as_decl_dies
* src/abg-dwarf-reader.cc (die_is_class_type): Take a const
pointer to Dwarf_Die.
(compare_as_decl_dies): For classes/structs, call
compare_dies_string_attribute_value just once to compare the
DW_AT_name attribute values.
2019-06-13 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Better use of linkage name for fn decl de-duplication
* src/abg-dwarf-reader.cc (read_context::{die_is_in_c,
die_is_in_c_or_cplusplus}): Define new member functions.
(fn_die_equal_by_linkage_name): Define new static function.
(compare_dies): In the case for for DW_TAG_subprogram, use the new
fn_die_equal_by_linkage_name.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
2019-06-13 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Re-use function types inside a given TU
* src/abg-dwarf-reader.cc (istring_fn_type_map_type): Declare new
typedef.
(die_is_function_type): Define new static function.
(read_context::per_tu_repr_to_fn_type_maps_): Define new data
member ...
(read_context::per_tu_repr_to_fn_type_maps): ... and its accessor.
(read_context::{associate_die_repr_to_fn_type_per_tu,
lookup_fn_type_from_die_repr_per_tu}): Define new member
functions.
(build_function_type): Use the new
read_context::lookup_fn_type_from_die_repr_per_tu and
read_context::associate_die_repr_to_fn_type_per_tu functions,
instead of read_context::lookup_type_from_die.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
2019-06-03 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] const-ify Dwarf_Die* use in many places
* src/abg-dwarf-reader.cc (get_parent_die, get_scope_die)
(die_is_anonymous, die_is_type, die_is_decl, die_is_namespace)
(die_is_pointer_type, pointer_or_qual_die_of_anonymous_class_type)
(die_is_reference_type, die_is_pointer_or_reference_type)
(die_is_qualified_type, die_has_object_pointer)
(die_is_at_class_scope, die_unsigned_constant_attribute)
(die_signed_constant_attribute, die_attribute_is_signed)
(die_attribute_is_unsigned, die_attribute_has_no_signedness)
(die_name, die_location, die_qualified_type_name)
(die_qualified_decl_name, die_qualified_name)
(die_qualified_type_name_empty)
(die_return_and_parm_names_from_fn_type_die)
(die_function_signature, die_function_type_is_method_type)
(die_pretty_print_type, die_pretty_print_decl, die_pretty_print)
(maybe_canonicalize_type, build_subrange_type)
(build_subranges_from_array_type_die, compare_dies)
(read_context::get_container)
(read_context::compute_canonical_die_offset)
(read_context::get_or_compute_canonical_die)
(read_context::get_die_source)
(read_context::get_die_qualified_type_name)
(read_context::get_die_pretty_representation)
(read_context::get_die_language, read_context::odr_is_relevant)
(read_context::set_canonical_die_offset)
(read_context::associate_die_to_type, die_is_anonymous)
(die_string_attribute, die_constant_attribute)
(die_attribute_has_form, die_linkage_name)
(die_decl_file_attribute, die_die_attribute, die_size_in_bits)
(die_is_decl, die_is_namespace)
(pointer_or_qual_die_of_anonymous_class_type, die_is_array_type)
(die_is_pointer_reference_or_typedef_type)
(die_peel_pointer_and_typedef, die_function_type_is_method_type)
(die_virtuality, die_is_virtual)
(compare_dies_string_attribute_value, compare_dies_cu_decl_file)
(die_location_expr, die_member_offset)
(get_internal_anonynous_die_base_name, compare_as_decl_dies)
(compare_as_type_dies): Const-ify the Dwarf_Die* parameter(s) of
these functions.
2019-06-05 Dodji Seketeli <dodji@redhat.com>
Take anonymous scopes into account when comparing decls
* include/abg-interned-str.h (interned_string::clear): Add new
member function.
* src/abg-ir.cc (equals): In the overload for decl_base, consider
the scope of the current (anonymous) decl. If that scope is
anonymous then take that into account as well.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Adjust.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
2019-05-21 Matthias Maennich <maennich@google.com>
.clang-format: Add more options for match existing coding style
* .clang-format: Add options for ConstructorInitializers
Set SortUsingDeclarations=false
Set AlignConsecutiveDeclarations=true
2019-05-21 Matthias Maennich <maennich@google.com>
.gitignore: Add libabigail-?.* *.orig files
* .gitignore: add entries for distribution artifacts
* .gitignore: add *.orig files
2019-05-21 Matthias Maennich <maennich@google.com>
abg-writer: drop deprecated API
* include/abg-fwd.h (ABG_DEPRECATED): Remove this macro.
* include/abg-writer.h (write_translation_unit, write_corpus)
(write_corpus_group): Drop the deprecated overloads of these
declarations.
* src/abg-writer.cc (write_translation_unit, write_corpus)
(write_corpus_group): Drop the deprecated overloads of these
definitions.
2019-05-21 Matthias Maennich <maennich@google.com>
abidw: add option to only emit file names (--short-locs)
* include/abg-writer.h (set_short_locs): Declare new function.
(set_common_options): Use it.
set_opts
* src/abg-writer.cc (write_context::m_short_locs): New data
member.
(write_context::write_context): Initialize it.
(write_context::{g,s}et_short_locs): Define new accessors.
(write_location, write_translation_unit, write_corpus): Honour the
new write_context::get_short_locs property.
(set_short_locs): Define new function.
* tools/abidw.cc (options::short_locs): New data member.
(display_usage): Help string for the new --no-show-locs option.
(parse_command_line): Parse the new --no-show-locs option.
2019-05-21 Matthias Maennich <maennich@google.com>
abidw: add option to omit the compilation directory
* include/abg-writer.h (set_write_comp_dir): Declare new function.
(set_common_options): Use it.
* src/abg-writer.cc (write_context::m_write_comp_dir): Define new
data member.
(write_context::write_context): Initialize it.
(write_context::{g,s}et_write_comp_dir): Define new member
accessors.
(set_write_comp_dir): Define new free-form getter.
(write_translation_unit): Teach to respect write_comp_dir flag of
write_context.
* tools/abidw.cc (options::write_corpus_path): Define new data
member.
(options::options): Initialize it.
(display_usage): Add doc string for a new command line option: --no-comp-dir-path.
(parse_command_line): Parse the new command line option --no-comp-dir-path.
2019-05-21 Matthias Maennich <maennich@google.com>
Make write_architecture and write_corpus_path flags in the write_context
* include/abg-writer.h (set_write_architecture)
(set_write_corpus_path): Declare new getter functions.
(write_corpus): Take a new "member_of_group" argument.
(set_common_options): Use set_write_{architecture, corpus_path}
here.
* src/abg-writer.cc (write_context::m_write_{architecture,
corpus_path}}): Add new data members.
(write_context::write_context): Initialize the new data members.
(write_context::{s,g}et_write_{architecture, corpus}): Define new
accessors.
(set_write_{architecture, corpus}): Define new free-form getter
functions.
(write_corpus): Add flag to make aware if written as part of a
group.
* tools/abidw.cc (load_corpus_and_write_abixml)
(load_kernel_corpus_group_and_write_abixml): Drop obsolete option
handling as xml_writer::set_common_options now takes care of it.
ldiff --git a/include/abg-writer.h b/include/abg-writer.h
index 200b5f7..729b455 100644
--- a/include/abg-writer.h
+++ b/include/abg-writer.h
@@ -53,6 +53,11 @@ set_show_locs(write_context& ctxt, bool flag);
void
set_annotate(write_context& ctxt, bool flag);
+void
+set_write_architecture(write_context& ctxt, bool flag);
+
+void
+set_write_corpus_path(write_context& ctxt, bool flag);
/// A convenience generic function to set common options (usually used
/// by Libabigail tools) from a generic options carrying-object, into
@@ -69,6 +74,8 @@ set_common_options(write_context& ctxt, const OPTS& opts)
{
set_annotate(ctxt, opts.annotate);
set_show_locs(ctxt, opts.show_locs);
+ set_write_architecture(ctxt, opts.write_architecture);
+ set_write_corpus_path(ctxt, opts.write_corpus_path);
}
void
@@ -105,7 +112,10 @@ write_corpus_to_archive(const corpus_sptr corp,
const bool annotate = false);
bool
-write_corpus(write_context& ctxt, const corpus_sptr& corpus, unsigned indent);
+write_corpus(write_context& ctxt,
+ const corpus_sptr& corpus,
+ unsigned indent,
+ bool member_of_group = false);
bool ABG_DEPRECATED
write_corpus(const corpus_sptr& corpus, unsigned indent, write_context& ctxt);
2019-05-21 Matthias Maennich <maennich@google.com>
abidw: Consolidate setting options
* include/abg-writer.h (set_common_option): Declare new function.
* tools/abidw.cc (load_corpus_and_write_abixml)
(load_kernel_corpus_group_and_write_abixml): Use the newly
introduced set_common_option.
2019-05-21 Matthias Maennich <maennich@google.com>
write_context: allow mutating the ostream used
* include/abg-writer.h (set_ostream): Declare new function.
* src/abg-writer.cc (write_context::m_ostream): Make this data
member be a pointer rather than a reference.
(write_context::{write_context, get_ostream): Adjust. member.
(write_context::set_ostream): Define new member function.
(set_ostream): Define new free-form function.
* tools/abidw.cc (load_corpus_and_write_abixml)
(load_kernel_corpus_group_and_write_abixml): Use the feature of
mutating the ostream and reuse the write_context in most cases.
2019-05-21 Matthias Maennich <maennich@google.com>
abg-writer: Refactor write_corpus_group API
* include/abg-writer.h (write_corpus_group): Introduce new
overload write_corpus_group(ctxt, corpus_group, indent) and
deprecate all others.
* src/abg-writer.cc (write_corpus_group): Likewise for the
definitions and adjust.
* tools/abidw.cc (load_kernel_corpus_group_and_write_abixml):
Migrate to new API of write_corpus_group()
2019-05-21 Matthias Maennich <maennich@google.com>
abg-writer: Refactor write_corpus API
* include/abg-writer.h (write_corpus): Introduce new overload
write_corpus(ctxt, corpus, indent) and deprecate all others.
* src/abg-writer.cc (write_corpus): Likewise for the definitions
and adjust.
* tests/test-read-dwarf.cc (test_task::perform): Use the new
write_corpus which requires a write_context.
* tools/abidw.cc (load_corpus_and_write_abixml, ): Likewise.
* tools/abilint.cc (main): Likewise. Also simplify logic around the
locations as they now can be expressed with less code.
2019-05-21 Matthias Maennich <maennich@google.com>
abg-writer: Refactor write_translation_unit API
* include/abg-writer.h (write_translation_unit): Declare a new
overload write_translation_unit(ctxt, tu, indent) and deprecate
all others.
* src/abg-writer.cc (write_translation_unit): Likewise in the
definitions.
(write_corpus, dump, write_translation_unit): Adjust.
* tools/abilint.cc (main): use new write_translation_unit() API
2019-05-21 Matthias Maennich <maennich@google.com>
Add deprecation facilities
* include/abg-fwd.h: Introduce deprecation macro ABG_DEPRECATED
2019-05-21 Matthias Maennich <maennich@google.com>
abg-writer: Simplify 'annotate' propagation
* src/abg-writer.cc (write_context::write_context): remove
'annotate' parameter.
(write_translation_unit, write_corpus, write_corpus_group, dump): Adjust.
2019-05-15 Matthias Maennich <maennich@google.com>
Add .clang-format approximation
* .clang-format: New File.
2019-05-16 Dodji Seketeli <dodji@redhat.com>
Bug 24552 - abidiff fails comparing a corpus against a corpus group
* include/abg-corpus.h (corpus{_group}::get_{fun,
var}_symbol_map): Make these member functions virtual.
* src/abg-corpus.cc (corpus::lookup_{function, variable}_symbol):
Use the virtual corpus::get_{fun, var}_symbol_map() member
function to get the symbols of the current corpus or corpus_group.
* tests/data/Makefile.am: Add the new test input material below to
source distribution.
* tests/data/test-abidiff/test-PR24552-report0.txt: New test input.
* tests/data/test-abidiff/test-PR24552-v0.abi: Likewise.
* tests/data/test-abidiff/test-PR24552-v1.abi: Likewise.
* tests/test-abidiff.cc (main): Support comparing corpus groups.
(specs): Add the new test inputs to the harness.
2019-05-15 Dodji Seketeli <dodji@redhat.com>
Bug 24560 - Assertion failure on an abixml with an anonymous type
* src/abg-reader.cc (read_context::maybe_canonicalize_type): Delay
canonicalization of union types too.
(build_class_decl, build_union_decl): Do not try to re-use
anonymous types.
2019-05-13 Dodji Seketeli <dodji@redhat.com>
Handle Linux kernel binaries with no __ksymtab section
* src/abg-dwarf-reader.cc (find_section): Use elf_getshdrstrndx
rather than poking at the elf header on our own.
(read_context::find_any_ksymtab_section): Define new member
function.
(read_context::{get_symtab_format,
try_reading_first_ksymtab_entry_using_pre_v4_19_format}): Use the
new find_any_ksymtab_section rather than find_ksymtab_section.
(read_context::get_nb_ksymtab_entries): Handle the absence of
__ksymtab.
(read_context::get_nb_ksymtab_gpl_entries): Handle the absence of
__ksymtab_gpl.
(read_context::load_kernel_symbol_table): Handle the case of zero
ksymtab entries.
(read_context::{maybe_adjust_address_for_exec_or_dyn,
maybe_adjust_fn_sym_address, load_kernel_symbol_table}): Handle an
address that is zero.
2019-05-10 Dodji Seketeli <dodji@redhat.com>
Fix logic of get_binary_load_address
* src/abg-dwarf-reader.cc (get_binary_load_address): Consider the
load address pointed to by the program header pointer returned by
gelf_getphdr rather than the program header itself.
2019-05-10 maennich@google.com <maennich@google.com>
Bug 24431 Treat __ksymtab as int32_t for v4.19+ kernels
* src/abg-dwarf-reader.cc (maybe_adjust_sym_address_from_v4_19_ksymtab):
treat passed addr as 32bit signed offset in case of v4.19+ __ksymtabs
2019-05-10 maennich@google.com <maennich@google.com>
Bug 24431 Read 32bit values when testing for the v4.19 symbol table format
* src/abg-dwarf-reader.cc
(try_reading_first_ksymtab_entry_using_v4_19_format): attempt to
read first __ksymtab entry into int32_t to preserve sign
2019-05-10 maennich@google.com <maennich@google.com>
dwarf-reader: templatize read_int_from_array_of_bytes
* src/abg-dwarf-reader.cc (read_int_from_array_of_bytes):
templatize return type to allow passing of signed integer references
2019-05-10 maennich@google.com <maennich@google.com>
dwarf-reader: Fix comments for try_reading_first_ksymtab_entry_using_{pre_,}v4_19_format
* src/abg-dwarf-reader.cc: swap the comments of
try_reading_first_ksymtab_entry_using_{pre_,}v4_19_format
2019-05-09 Dodji Seketeli <dodji@redhat.com>
Better handle several anonymous types of the same kind
*unqualified* name of its scope. Unlike for qualified names, the
scoped name won't have a "__anonymous_*__" string in its name if its
directly containing scope is not anonymous; a qualified name might
still have that string in its name because the decl has a parent scope
(not necessarily its directly containing scope though) that is
anonymous.
The patch goes on to update the logic for comparison of decls that are
anonymous. For a decl which direct scope is *NOT* anonymous, the
scoped name is what's used in the comparison. Otherwise, only the
name of the decl is used.
The patch also updates how we detect changes in data members and
member types, in the comparison engine. It now uses the names of the
data members, rather than their qualified name. This is in the scope
of the current class/union anyway. The improvement is that the fact
that the class/union itself is anonymous (even if its anonymous name
changes to another anonymous name) won't have any spurious impact on
the detection of name change of the members.
The patch considers the change of an anonymous decl name which
anonymous name changes to another anonymous name as being harmless.
The patch updates the logic of category propagation in the comparison
engine. Although a public typedef to private underlying type needs to
stay public and thus not propagate the PRIVATE_TYPE_CATEGORY from its
child diff node to himself, it still needs to suppress the changes to
the private underlying diff node that were suppressed (because of the
private-ness), unless that typedef has local changes.
* include/abg-ir.h (decl_base::get_scoped_name): Declare new
member function.
(scope_decl::get_num_anonymous_member_{classes, unions, enums}):
Declare new virtual member functions.
(class_decl::get_num_anonymous_member_{classes, unions, enums}):
Adjust to make these virtual. It's not necessary but I feel
redundancy is a kind of self-documentation here.
* src/abg-comp-filter.cc (has_harmless_name_change): Consider
anonymous name changes as harmless.
* src/abg-comparison.cc
(class_or_union_diff::ensure_lookup_tables_populated): Consider
the names of the members rather than their qualified names.
(suppression_categorization_visitor::visit_end): Suppress the
changes to the private underlying diff node that were suppressed
because of the private-ness, unless that typedef has local
changes.
* src/abg-dwarf-reader.cc (build_enum_type)
(add_or_update_class_type, add_or_update_union_type): Handle
anonymous types in namespaces as well, not just in class/unions.
* src/abg-ir.cc (decl_base::priv::scoped_name_): Define new data
member.
(decl_base::get_scoped_name): Define new member function.
(equals): For the decl_base overload, use scoped name in the
comparison, unless the decl belongs to an anonymous type. For the
class_or_union_diff, only consider scoped_name during comparison.
Avoid name comparison between anonymous types.
(scope_decl::get_num_anonymous_member_{classes, unions, enums}):
Define new member functions.
(types_have_similar_structure): Do not compare names between
anonymous types.
(qualified_name_setter::do_update): Update scoped names too.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/test43-PR22913-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test46-rust-report-0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test33-report-0.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2019-05-07 Dodji Seketeli <dodji@redhat.com>
Handle several member anonymous types of the same kind
* include/abg-ir.h
(class_or_union::get_num_anonymous_member_{classes, unions,
enums}): Declare new member functions.
* src/abg-dwarf-reader.cc (get_internal_anonynous_die_base_name)
(build_internal_anonymous_die_name)
(get_internal_anonymous_die_name, is_anonymous_type_die): Define
new static functions.
(die_qualified_type_name): Use the new
get_internal_anonymous_die_name.
(get_scope_for_die): Fix this to put anonymous types that were
wrongly emitted into the scope of DW_TAG_subroutine_type or
DW_TAG_array_type by buggy DWARF emitters into the enclosing
namespace, rather than into the enclosing class/union.
(build_enum_type): Take the scope of the enum to have a chance to
properly name potential anonymous enums.
(lookup_class_typedef_or_enum_type_from_corpus): Take an anonymous
member type index for when the DIE we are lookup up represents an
anonymous type. Support proper building of the internal anonymous
name of the anonymous type we are lookup up.
(add_or_update_class_type): Use the new
get_internal_anonynous_die_base_name and
build_internal_anonymous_die_name functions. Support making sure
that the anonymous member type we are adding to the class wasn't
already there, especially for cases where we are updating a class
type.
(add_or_update_union_type): Use the new
get_internal_anonynous_die_base_name and
build_internal_anonymous_die_name functions.
(build_ir_node_from_die): Adjust the use of build_enum_type to
pass it the scope of the enum type we are building.
* src/abg-ir.cc (lookup_union_type): Add a new overload.
(lookup_class_or_typedef_type): Use the new overload of
lookup_union_type above to support looking up union types too.
(class_or_union::get_num_anonymous_member_{classes, unions,
enums}): Define new member functions.
* src/abg-reporter-priv.cc (represent): Detect when anonymous
types of anonymous data members have their internal names change,
probably because anonymous member types were inserted in the scope.
* tests/data/Makefile.am: Add the new test-anonymous-members-0.*
test input files to the source distribution.
* tests/data/test-annotate/test-anonymous-members-0.cc: New test
input file.
* tests/data/test-annotate/test-anonymous-members-0.o: Likewise.
* tests/data/test-annotate/test-anonymous-members-0.o.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/test-annotate.cc (int_out_specs): Add the new test inputs
to this test harness.
2019-04-24 Dodji Seketeli <dodji@redhat.com>
Use canonical types hash maps for type IDs in abixml writer
* src/abg-writer.cc (write_context::{type_has_existing_id,
get_id_for_type}): Save the canonical type of the type in the map,
not the type itself.
(write_context::{type_is_emitted}): Use the canonical type rather
than the type itself.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2019-04-24 Dodji Seketeli <dodji@redhat.com>
Don't try to de-duplicate all anonymous struct DIEs
* include/abg-fwd.h (is_typedef): Remove the overloads for
type_base_sptr and decl_base_sptr. Replace those with an overload
for type_or_decl_base_sptr.
* src/abg-ir.cc (is_typedef): Do the same for the definitions.
* src/abg-dwarf-reader.cc (add_or_update_class_type)
(add_or_update_union_type): Do not de-duplicate anonymous
struct/union DIEs.
(build_typedef_type): Try to de-duplicate typedefs DIEs.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2019-04-24 Dodji Seketeli <dodji@redhat.com>
Canonicalize types non tied to any DWARF DIE
* src/abg-dwarf-reader.cc
(read_context::extra_types_to_canonicalize_): Add new data member.
(read_context::{initialize, clear_types_to_canonicalize}): Adjust.
(read_context::extra_types_to_canonicalize): Create new accessor.
(read_context::schedule_type_for_late_canonicalization): Add new
overload for type_base_sptr.
(read_context::perform_late_type_canonicalizing): Perform the
canonicalization of the types created by the DWARF analyzer, but
that are not tied to any DIE.
(maybe_strip_qualification): Take a read_context&. Schedule newly
created types (during type edition) for late canonicalization.
(build_ir_node_from_die): Adjust the call to
maybe_strip_qualification to pass a read_context.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2019-04-18 Mark Wielaard <mark@klomp.org>
Don't try to read a build_id as string in find_alt_debug_info_link.
* src/abg-dwarf-reader.cc (find_alt_debug_info_link): Remove
build_id argument. Don't try to read the buildid chars as a
string.
(find_alt_debug_info): Don't call find_alt_debug_info_link
with a build_id string argument.
2019-04-18 Mark Wielaard <mark@klomp.org>
Fix an undefined behaviour in has_var_type_cv_qual_change
* src/abg-comp-filter.cc: (has_var_type_cv_qual_change):
Initialize the ch_kind variable before using it.
2019-04-18 Dodji Seketeli <dodji@redhat.com>
Add --enable-{asan,ubsan} configure options
* configure.ac: Add configure options for -fsanitize=address and
-fsanitize=undefined.
2019-04-18 Dodji Seketeli <dodji@redhat.com>
abg-tools-utils.cc: Plug a leak in find_file_under_dir
* src/abg-tools-utils.cc (find_file_under_dir): Call fts_close
before return.
2019-04-18 Matthias Maennich <maennich@google.com>
dwarf-reader: fix undefined behaviour in get_binary_load_address
* src/abg-dwarf-reader.cc (get_binary_load_address): Move the
ph_mem and program_header variables out of the inner for-loop.
2019-04-18 Dodji Seketeli <dodji@redhat.com>
Delay canonicalization for array and qualified types
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Delay the
canonicalization of array and qualified types, just like what we
do for classes and function types already.
(maybe_strip_qualification): Do not
re-canonicalize array and qualified types here because it should
not be necessary anymore.
2019-04-18 Dodji Seketeli <dodji@redhat.com>
Fix a memory leak in real_path
* src/abg-tools-utils.cc (real_path): Fee the returned pointer of
realpath.
2019-04-18 Dodji Seketeli <dodji@redhat.com>
Enable building with AddressSanitizer activated
* configure.ac: If ABIGAIL_DEVEL_ASAN=on (in addition to
ABIGAIL_DEVEL=on), then turn on AddressSanitizer in the build.
2019-04-17 Dodji Seketeli <dodji@redhat.com>
Bug 24431 - ELF reader fails to determine __ksymtab format
* src/abg-dwarf-reader.cc
(read_context::{try_reading_first_ksymtab_entry_using_pre_v4_19_format,
try_reading_first_ksymtab_entry_using_v4_19_format}): Define new
member functions.
(read_context::maybe_adjust_sym_address_from_v4_19_ksymtab): Make
member function this const.
(read_context::get_ksymtab_format): Implement the new heuristic
here, using try_reading_first_ksymtab_entry_using_pre_v4_19_format
and try_reading_first_ksymtab_entry_using_v4_19_format, rather
than assuming that if we have no relocations, then we are in the
v4.19 format.
(maybe_adjust_sym_address_from_v4_19_ksymtab): When on a 64 bits
architecture, ensure the 32 bits address read from the v4.19
format __ksymtab section is converted into a 64 bits address.
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
Update .gitignore files to ignore typical dev side products
* tests/.gitignore: exclude tests binaries and test results
* tools/.gitignore: update to ignore produced binaries
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
dwarf-reader: fix recursion in expr_result::operator&
* src/abg-dwarf-reader.cc: fix expr_result::operator&
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
distinct_diff: avoid expression with side effects within typeid
* src/abg-comparison.cc: fix clang warning "potentially-evaluated-expression"
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
ir: drop unused data members from {environment,qualified_name}_setter
* src/abg-ir.cc: drop unused data members
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
suppressions: drop unused parameter from type_is_suppressed
* include/abg-suppression-priv.h: drop unused argument from type_is_suppressed
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
viz-dot: remove unused members from dot
* include/abg-viz-dot.h: remove unused data members from 'dot'
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
add missing virtual destructors
* include/abg-comparison.h: add virtual destructor for corpus_diff and diff_node_visitor
* include/abg-corpus.h: add virtual destructor for corpus
* include/abg-reporter.h: add virtual destructor for reporter_base
* include/abg-traverse.h: add virtual destructor for traversable_base
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
diff-utils: point: fix postfix decrement/increment operator
* include/abg-diff-utils.h: fix postfix dec/inc operator
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
abg-reader: clarify boolean use of assignment
* src/abg-reader.cc: clarify boolean use of assignment
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
abilint: fix return types bool -> int
* tools/abilint.cc: return int in main rather than bool.
* tests/print-diff-tree.cc: Likewise.
2019-04-15 Matthias Maennich via libabigail <libabigail@sourceware.org>
abg-fwd.h: fix mismatched tags for ir_node_visitor
* include/abg-fwd.h: forward-declare ir_node_visitor as class
2019-04-16 Dodji Seketeli <dodji@redhat.com>
Bug 24431 - ELF reader can't interpret ksymtab with Kernel 4.19+
* src/abg-dwarf-reader.cc (enum kernel_symbol_table_kind): Move this
enum at the top.
(enum ksymtab_format): Define new enum.
(read_context::{ksymtab_format_, ksymtab_entry_size_,
nb_ksymtab_entries_, nb_ksymtab_gpl_entries_}): Define new data
members.
(read_context::initiliaze): Initialize the new data members above.
(read_context::{get_ksymtab_format, get_ksymtab_symbol_value_size,
get_ksymtab_entry_size, get_nb_ksymtab_entries,
get_nb_ksymtab_gpl_entries,
maybe_adjust_sym_address_from_v4_19_ksymtab}): Define new member
functions.
(read_context::load_kernel_symbol_table): Support loading from
both pre and post v4.19 linux kernels with their different ksymtab
formats. Add more comments.
2019-04-10 Dodji Seketeli <dodji@redhat.com>
Bug 24430 - Fold away const for array types
* include/abg-fwd.h (is_array_of_qualified_element): Declare 2
overloads of this function.
(re_canonicalize): Declare a new function.
* include/abg-ir.h (class {decl_base, type_base}): Declare
re_canonicalize as a friend of these classes.
* src/abg-dwarf-reader.cc (maybe_strip_qualification): Detect
qualified array types and appropriately qualifies the array
element type, instead of qualifying the array type itself.
Re-canonicalize the resulting type if necessary.
* src/abg-ir.cc (is_array_of_qualified_element): Define 2
overloads of this function.
(re_canonicalize): Define new function.
* tests/data/Makefile.am: The two new test binary input files
PR24430-fold-qualified-array-clang and
PR24430-fold-qualified-array-gcc to source distribution, as well
as the expected reference output.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-filter/PR24430-fold-qualified-array-clang:
New binary test input coming from the bug report.
* tests/data/test-diff-filter/PR24430-fold-qualified-array-gcc:
Likewise.
* tests/data/test-diff-filter/PR24430-fold-qualified-array-report-0.txt:
Expected reference abi difference.
* tests/data/test-diff-filter/test33-report-0.txt: Adjust.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/test-diff-filter.cc: Add the new binary test input to this
test harness.
2019-04-09 Dodji Seketeli <dodji@redhat.com>
Fix "Add test for the fix for PR24410"
* tests/data/test-diff-pkg/PR24410-new/poppler-debuginfo-0.73.0-8.fc30.x86_64.rpm:
Really add this.
* tests/data/test-diff-pkg/PR24410-new/poppler-qt5-0.73.0-8.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24410-new/poppler-qt5-debuginfo-0.73.0-8.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24410-new/poppler-qt5-devel-0.73.0-8.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24410-old/poppler-debuginfo-0.73.0-4.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24410-old/poppler-qt5-0.73.0-4.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24410-old/poppler-qt5-debuginfo-0.73.0-4.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24410-old/poppler-qt5-devel-0.73.0-4.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/PR24410-report-0.txt: Likewise.
2019-04-09 Dodji Seketeli <dodji@redhat.com>
Add test for the fix for PR24410
* tests/data/test-diff-pkg/PR24410-new/poppler-debuginfo-0.73.0-8.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-new/poppler-qt5-0.73.0-8.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-new/poppler-qt5-debuginfo-0.73.0-8.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-new/poppler-qt5-devel-0.73.0-8.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-old/poppler-debuginfo-0.73.0-4.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-old/poppler-qt5-0.73.0-4.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-old/poppler-qt5-debuginfo-0.73.0-4.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-old/poppler-qt5-devel-0.73.0-4.fc30.x86_64.rpm:
Add new test input.
* tests/data/test-diff-pkg/PR24410-report-0.txt: Add new test
input.
* tests/data/Makefile.am: Add the test input above to source
distribution.
* tests/test-diff-pkg.cc: Make this test harness use the new input
rpms above.
2019-04-05 Dodji Seketeli <dodji@redhat.com>
Propagate private type diff category through refs/qualified type diffs
* src/abg-comparison.cc
(suppression_categorization_visitor::visit_end): Propagate
suppressed and private type diff categories for reference and
qualified types. For qualified types, make sure they don't have
local changes. Even when there are no local changes, do not
propagate private diff categories to typedefs.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2019-04-05 Dodji Seketeli <dodji@redhat.com>
Fix anonymous union constructed under the wrong context
* src/abg-dwarf-reader.cc (add_or_update_class_type)
(add_or_update_union_type): Only reuse anonymous class/union types
which have the same scope as the current one.
2019-04-08 Dodji Seketeli <dodji@redhat.com>
Internal pretty repr of union cannot be flat representation
* src/abg-ir.cc (union_decl::get_pretty_representation):
Anonymous internal pretty representation of unin is its fully
qualified name.
2019-04-08 Dodji Seketeli <dodji@redhat.com>
Misc comment fixes
* src/abg-comp-filter.cc (has_harmless_name_change): Fix comment.
* src/abg-ir.cc (var_decl::get_qualified_name): Likewise.
2019-03-29 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.7
* configure.ac: Bump version number to 1.7
2019-03-28 Dodji Seketeli <dodji@redhat.com>
Update website mainpage for 1.6 release
* doc/website/mainpage.txt: Update for 1.6 release.
2019-03-27 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog
* ChangeLog: Update automatically by using "make
update-changelog".
2019-03-27 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.6
* NEWS: Update for 1.6
2019-03-27 Dodji Seketeli <dodji@redhat.com>
Add missing assignment operators
* include/abg-interned-str.h (interned_string::operator=): Define
assignment operator.
* include/abg-ir.h
({location, enum_type_decl::enumerator}::operator=): Declare
assignment operator.
* src/abg-ir.cc (enum_type_decl::enumerator::operator=): Define
assignment operator.
2019-03-25 Dodji Seketeli <dodji@redhat.com>
Bug 24378 - DW_TAG_subroutine_type as a DIE scope causes infinite loop
* src/abg-dwarf-reader.cc (get_scope_die): Look through
DW_TAG_subroutine_type to get the scope of a given DIE.
* tests/data/Makefile.am: Add the two new files below to source
distribution.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.abi: New
reference test output.
* tests/data/test-read-dwarf/PR24378-fn-is-not-scope.o: New binary
test input.
* tests/test-read-dwarf.cc (in_out_specs): Add the new test input
to the test harness.
2019-03-22 Dodji Seketeli <dodji@redhat.com>
Misc cleanups
* src/abg-dwarf-reader.cc (build_function_type): Cleanup
indentation and comments.
2019-03-21 Dodji Seketeli <dodji@redhat.com>
Better pointer name equality optimization in DIE de-duplication code
* src/abg-dwarf-reader.cc
(die_is_pointer_reference_or_typedef_type)
(die_peel_pointer_and_typedef): Define new static functions.
(compare_dies_string_attribute_value): Turn this function into a
static one.
(compare_dies_cu_decl_file): Make this function compare the cu
decl file name of the leaf type of the pointer, not just the one
of the pointer itself.
(compare_as_decl_dies): Compare the DWARF tags too.
(compare_dies): Simplify logic.
2019-03-21 Dodji Seketeli <dodji@redhat.com>
Add ir::{lookup_data_member, get_function_parameter}
* include/abg-ir.h (lookup_data_member, get_function_parameter):
Declare new functions.
* src/abg-ir.cc (lookup_data_member, get_function_parameter):
Define them.
2019-03-21 Dodji Seketeli <dodji@redhat.com>
Better detection of void* to something* change
* include/abg-ir.h (is_void_type): Add a new overload that takes
type_base*.
* src/abg-ir.cc (is_void_type): Define the new overload that takes
type_base*.
(is_void_pointer_type): Look through typedefs in
the pointed-to type.
2019-03-21 Dodji Seketeli <dodji@redhat.com>
PR24257 - Handle DW_TAG_typedef with no underlying type
* src/abg-dwarf-reader.cc (build_typedef_type): DW_TAG_typedef
with no underlying type means typedef void foo.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2019-02-20 Dodji Seketeli <dodji@redhat.com>
Do not build DIE -> parent map just because we see an asm TU
* src/abg-dwarf-reader.cc: Do not build DIE -> parent map just because we see an asm TU
2019-02-19 Dodji Seketeli <dodji@redhat.com>
Avoid over-suppressing fns & vars when analysing the Kernel
* include/abg-dwarf-reader.h (get_ignore_symbol_table): Take a
const read_context&.
* src/abg-dwarf-reader.cc (get_ignore_symbol_table): Likewise.
(function_is_suppressed): When the symbol table optimization is in
flight -- that is, when no symbol table has been loaded -- do not
try to see if a given function symbol was exported at the ELF
level or not. Just look at if the function was suppressed or not.
(variable_is_suppressed): Likewise for variables.
2019-02-08 Dodji Seketeli <dodji@redhat.com>
Bug 24188 - Assertion failed while analysing a Fortran binary
* src/abg-dwarf-reader.cc (compare_as_type_dies): Handle
DW_TAG_string_type DIEs here.
(compare_dies): Handle DW_TAG_string_type DIEs by using
compare_as_type_dies.
* tests/data/test-diff-pkg/netcdf-fortran-debuginfo-4.4.4-10.fc29.x86_64.rpm:
New test RPM.
* tests/data/test-diff-pkg/netcdf-fortran-debuginfo-4.4.4-11.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/netcdf-fortran-mpich-4.4.4-10.fc29.x86_64-4.4.4-11.fc30.x86_64-report-0.txt:
New expected test reference output.
* tests/data/test-diff-pkg/netcdf-fortran-mpich-4.4.4-10.fc29.x86_64.rpm:
New test RPM.
* tests/data/test-diff-pkg/netcdf-fortran-mpich-4.4.4-11.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/netcdf-fortran-mpich-debuginfo-4.4.4-10.fc29.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/netcdf-fortran-mpich-debuginfo-4.4.4-11.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/netcdf-fortran-mpich-devel-4.4.4-10.fc29.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/netcdf-fortran-mpich-devel-4.4.4-11.fc30.x86_64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new test input material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_spec): Add the new test RPMs
above to the set of RPMs to use as test input.
2019-02-06 Dodji Seketeli <dodji@redhat.com>
Bug 24157 - Wrong support of Ada ranges
* include/abg-ir.h (array_type_def::subrange_type::bound_value):
Define new class.
(array_type_def::subrange_type::subrange_type): Adjust to use the
new bound_value type for bound values.
(array_type_def::subrange_type::{get_upper_bound, get_lower_bound,
set_upper_bound, set_lower_bound}): Return or take int64_t rather
than size_t.
(array_type_def::subrange_type::get_length): Return uint64_t
rather than size_t.
* src/abg-dwarf-reader.cc (die_signed_constant_attribute)
(die_constant_attribute, die_attribute_has_form)
(die_attribute_is_signed, die_attribute_is_unsigned)
(die_attribute_has_no_signedness): Define new static functions.
(get_default_array_lower_bound): Return uint64_t rather than int.
(build_subrange_type): Use the new
array_type_def::subrange_type::bound_value type for bound values.
Use the new die_constant_attribute function, rather than
die_unsigned_constant_attribute to fecth the bound values.
* src/abg-ir.cc
(array_type_def::subrange_type::bound_value::{bound_value,
get_signedness, set_signedness, get_signed_value,
get_unsigned_value, set_unsigned, set_signed}): Define new member
functions.
(array_type_def::subrange_type::priv::{lower_bound_,
upper_bound}): Use the new class bound_value.
(array_type_def::subrange_type::priv::priv): Adjust to use the new
bound_value class to hold bound values.
(array_type_def::subrange_type::subrange_type): Likewise.
(array_type_def::subrange_type::{get_upper_bound, get_lower_bound,
set_upper_bound, set_lower_bound}): Return or take int64_t rather
than size_t.
(array_type_def::subrange_type::get_length): Return uint64_t
rather than size_t.
(types_have_similar_structure): Handle array_type_def::subrange_type
* src/abg-reader.cc (build_subrange_type): Use the new
array_type_def::subrange_type::bound_value to hold bound values.
* tests/data/test-diff-pkg/GtkAda-debuginfo-2.24.2-29.fc29.x86_64.rpm:
New binary RPM as test input.
* tests/data/test-diff-pkg/GtkAda-debuginfo-2.24.2-30.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/GtkAda-devel-2.24.2-29.fc29.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/GtkAda-devel-2.24.2-30.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/GtkAda-gl-2.24.2-29.fc29.x86_64--2.24.2-30.fc30.x86_64-report-0.txt:
New expected test output.
* tests/data/test-diff-pkg/GtkAda-gl-2.24.2-29.fc29.x86_64.rpm:
New binary RPM as test input.
* tests/data/test-diff-pkg/GtkAda-gl-2.24.2-30.fc30.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/GtkAda-gl-debuginfo-2.24.2-29.fc29.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/GtkAda-gl-debuginfo-2.24.2-30.fc30.x86_64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new test material above to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new input testing
RPMs in here.
2019-01-30 Dodji Seketeli <dodji@redhat.com>
Small apidoc fix
* src/abg-comparison.cc (enum_diff::changed_enumerators): Fix apidoc.
2019-01-30 Dodji Seketeli <dodji@redhat.com>
Bug 24139 - Support suppressing some enumerator changes
* doc/manuals/libabigail-concepts.rst: Document the new
'changed_enumerators' property.
* include/abg-suppression.h
(type_suppression::{g, s}et_changed_enumerator_names): Declare two
new member functions.
* src/abg-suppression-priv.h
(type_suppression::priv::changed_enumerator_names_): Add a new
data member.
* src/abg-suppression.cc
(type_suppression::{g,s}et_changed_enumerator_names): Define two
new member functions.
(type_suppression::suppresses_diff): Support evaluating the new
'changed_enumerators = <vector of changed enumerators>'.
(read_type_suppression): Read the new list
property'changed_enumerators" and store it into the
type_suppression using the new
type_suppression::set_changed_enumerator_names ().
* tests/data/test-diff-suppr/libtest4{0,1}-enumerator-changes-v{0,1}.so:
Add new test inpujts.
* tests/data/test-diff-suppr/test4{0,1}-enumerator-changes-0.suppr:
Add a new suppr spec for this new test.
* tests/data/test-diff-suppr/test4{0,1}-enumerator-changes-report-0.txt:
The default report.
* tests/data/test-diff-suppr/test4{0,1}-enumerator-changes-v{0,1}.cc:
Add Source code of libtest4{0,1}-enumerator-changes-v{0,1}.so.
* tests/data/Makefile.am: Add the test files above to source
distribution.
* tests/test-diff-suppr.cc: Add the test input files above to the
harness.
2019-01-25 Dodji Seketeli <dodji@redhat.com>
Better comments in the comparison engine
* include/abg-comparison.h (enum diff_category): Add comments to
describe what to update when a new enumerator is added to this enum.
* src/abg-comp-filter.cc (has_fn_return_type_cv_qual_change): Fix
comment thinko here.
2019-01-25 Dodji Seketeli <dodji@redhat.com>
Bug 20175 - Classify CV qual changes in variable type as harmless
* include/abg-comparison.h (VAR_TYPE_CV_CHANGE_CATEGORY): Add new
enumerator to diff_category enum.
(EVERYTHING_CATEGORY): Update this enumerator.
* src/abg-comp-filter.cc (type_diff_has_cv_qual_change_only):
Support array diff nodes carrying a cv qual change on the element
type.
(has_var_type_cv_qual_change): Define new static function.
(categorize_harmless_diff_node): Use the new
has_var_type_cv_qual_change to categorize variable diff node with
cv qual change on its type as harmless.
* src/abg-comparison.cc
(get_default_harmless_categories_bitmap): Update this.
(operator<<(ostream& o, diff_category c)): Likewise.
* include/abg-ir.h (equals_modulo_cv_qualifier): Declare new ...
* src/abg-ir.cc (equals_modulo_cv_qualifier): ... function.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
Update expected test output.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise.
* tests/data/Makefile.am: Add the new test material below to
source distribution.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64-report-0.txt:
New expecte test output.
* tests/data/test-diff-pkg/nss-3.23.0-1.0.fc23.x86_64.rpm: New
test input.
* tests/data/test-diff-pkg/nss-3.24.0-1.0.fc23.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/nss-debuginfo-3.23.0-1.0.fc23.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/nss-debuginfo-3.24.0-1.0.fc23.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/nss-devel-3.23.0-1.0.fc23.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/nss-devel-3.24.0-1.0.fc23.x86_64.rpm: Likewise.
* tests/test-diff-pkg.cc (in_out_specs): Add the test input above
to the test harness.
2019-01-24 Dodji Seketeli <dodji@redhat.com>
Properly add the new rust tests to EXTRA_DIST
* tests/data/Makefile.am: Add the new rust tests to
EXTRA_DIST.
2019-01-24 Dodji Seketeli <dodji@redhat.com>
Conditionalize the Rust support regression test
* tests/test-diff-dwarf.cc: Run the rust support regression test
only if we support Rust on the platform.
* tests/test-utils.h: Include config.h.
2019-01-24 Dodji Seketeli <dodji@redhat.com>
Fix a typo in the recent Rust support and update regression tests
* configure.ac: Fix the typo HAS_LANG_Rust into HAS_DW_LANG_Rust.
* tests/data/test-diff-dwarf/test46-readme.txt: Add new file to
the test suite.
* tests/data/test-diff-dwarf/test46-rust-libone.so: Likewise.
* tests/data/test-diff-dwarf/test46-rust-libtwo.so: Likewise.
* tests/data/test-diff-dwarf/test46-rust-report-0.txt: Likewise.
* tests/test-diff-dwarf.cc (in_out_specs): Update the tests array
to compare the two new binaries included above.
2019-01-18 Dodji Seketeli <dodji@redhat.com>
Overhaul detection the DW_LANG_* enumerators from dwarf.h
* configure.ac: Detect the presence of DW_LANG_{UPC, D, Python,
Go, C11, C_plus_plus_03, C_plus_plus_11, C_plus_plus_14,
Mips_Assembler, Rust} and define the corresponding
HAVE_DW_LANG_*_enumerator macro accordingly.
* include/abg-ir.h (LANG_C_plus_plus_03): Define this new
enumerator in the translation_unit::language enum.
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language): Use the
new HAVE_DW_LANG_*_enumerator macros.
(get_default_array_lower_bound): Support the
translation_unit::LANG_C_plus_plus_03 enumerator.
* src/abg-ir.cc (is_cplus_plus_language): Support the
translation_unit::LANG_C_plus_plus_03 enumerator.
2019-01-18 Dodji Seketeli <dodji@redhat.com>
Fix a thinko
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language): Fix a
thinko in the detection of the support of the DW_LANG_Rust enumerator.
2019-01-17 Mark Wielaard <mark@klomp.org>
Conditionalize the use of DW_LANG_C_plus_plus_03 and DW_LANG_Rust
* include/abg-ir.h (LANG_C_plus_plus_03): Add this new language
enum to "enum translation_unit::language".
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language): Do not
use DW_LANG_Rust or DW_LANG_C_plus_plus_03 if these are not
defined.
(get_default_array_lower_bound): Handle the new
translation_unit::LANG_C_plus_plus_03 enumerator.
2019-01-17 Dodji Seketeli <dodji@redhat.com>
Support some new DWARF language encoding for C and C++
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language): Support
new DW_LANG_{C11, C_plus_plus_03, C_plus_plus_11, C_plus_plus_14}
enumerators.
2019-01-17 Dodji Seketeli <dodji@redhat.com>
Add (very) basic support for Rust
* include/abg-ir.h (LANG_Rust): Add this new enumerator to the
"enum language" enum.
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language): Handle
the Rust language.
(get_default_array_lower_bound): Likewise.
2019-01-15 Dodji Seketeli <dodji@redhat.com>
Separate public types of first binary from those of the second
* include/abg-dwarf-reader.h (read_context_get_path): Declare new
function.
* include/abg-reader.h (read_context_get_path): Likewise.
* src/abg-dwarf-reader.cc (read_context_get_path): Define new function.
* src/abg-reader.cc (read_context_get_path): Likewise.
* tools/abidiff.cc (set_suppressions): Set the suppression
specification derived from the --headers-dir1 option only for the first
binary, and similarly, from the --headers-dir2 option only for the
second binary.
2019-01-09 Dodji Seketeli <dodji@redhat.com>
Bug 23044 - Assertions with side effects
* configure.ac: Bug 23044 - Assertions with side effects
* include/abg-diff-utils.h: Bug 23044 - Assertions with side effects
* include/abg-fwd.h: Bug 23044 - Assertions with side effects
* src/abg-comp-filter.cc: Bug 23044 - Assertions with side effects
* src/abg-comparison-priv.h: Bug 23044 - Assertions with side effects
* src/abg-comparison.cc: Bug 23044 - Assertions with side effects
* src/abg-corpus-priv.h: Bug 23044 - Assertions with side effects
* src/abg-corpus.cc: Bug 23044 - Assertions with side effects
* src/abg-default-reporter.cc: Bug 23044 - Assertions with side effects
* src/abg-diff-utils.cc: Bug 23044 - Assertions with side effects
* src/abg-dwarf-reader.cc: Bug 23044 - Assertions with side effects
* src/abg-hash.cc: Bug 23044 - Assertions with side effects
* src/abg-ini.cc: Bug 23044 - Assertions with side effects
* src/abg-ir.cc: Bug 23044 - Assertions with side effects
* src/abg-leaf-reporter.cc: Bug 23044 - Assertions with side effects
* src/abg-reader.cc: Bug 23044 - Assertions with side effects
* src/abg-reporter-priv.cc: Bug 23044 - Assertions with side effects
* src/abg-suppression.cc: Bug 23044 - Assertions with side effects
* src/abg-tools-utils.cc: Bug 23044 - Assertions with side effects
* src/abg-workers.cc: Bug 23044 - Assertions with side effects
* src/abg-writer.cc: Bug 23044 - Assertions with side effects
* tests/test-diff-filter.cc: Bug 23044 - Assertions with side effects
* tests/test-diff-pkg.cc: Bug 23044 - Assertions with side effects
* tests/test-read-dwarf.cc: Bug 23044 - Assertions with side effects
* tests/test-read-write.cc: Bug 23044 - Assertions with side effects
* tests/test-types-stability.cc: Bug 23044 - Assertions with side effects
* tools/abicompat.cc: Bug 23044 - Assertions with side effects
* tools/abidw.cc: Bug 23044 - Assertions with side effects
* tools/abipkgdiff.cc: Bug 23044 - Assertions with side effects
2019-01-07 Dodji Seketeli <dodji@redhat.com>
Update copyright for 2019
* include/abg-comp-filter.h: Update copyright for 2019
* include/abg-comparison.h: Update copyright for 2019
* include/abg-config.h: Update copyright for 2019
* include/abg-corpus.h: Update copyright for 2019
* include/abg-diff-utils.h: Update copyright for 2019
* include/abg-dwarf-reader.h: Update copyright for 2019
* include/abg-fwd.h: Update copyright for 2019
* include/abg-hash.h: Update copyright for 2019
* include/abg-ini.h: Update copyright for 2019
* include/abg-interned-str.h: Update copyright for 2019
* include/abg-ir.h: Update copyright for 2019
* include/abg-libxml-utils.h: Update copyright for 2019
* include/abg-libzip-utils.h: Update copyright for 2019
* include/abg-reader.h: Update copyright for 2019
* include/abg-reporter.h: Update copyright for 2019
* include/abg-sptr-utils.h: Update copyright for 2019
* include/abg-suppression.h: Update copyright for 2019
* include/abg-tools-utils.h: Update copyright for 2019
* include/abg-traverse.h: Update copyright for 2019
* include/abg-viz-common.h: Update copyright for 2019
* include/abg-viz-dot.h: Update copyright for 2019
* include/abg-viz-svg.h: Update copyright for 2019
* include/abg-workers.h: Update copyright for 2019
* include/abg-writer.h: Update copyright for 2019
* src/abg-comp-filter.cc: Update copyright for 2019
* src/abg-comparison-priv.h: Update copyright for 2019
* src/abg-comparison.cc: Update copyright for 2019
* src/abg-config.cc: Update copyright for 2019
* src/abg-corpus-priv.h: Update copyright for 2019
* src/abg-corpus.cc: Update copyright for 2019
* src/abg-default-reporter.cc: Update copyright for 2019
* src/abg-diff-utils.cc: Update copyright for 2019
* src/abg-dwarf-reader.cc: Update copyright for 2019
* src/abg-hash.cc: Update copyright for 2019
* src/abg-ini.cc: Update copyright for 2019
* src/abg-internal.h: Update copyright for 2019
* src/abg-ir-priv.h: Update copyright for 2019
* src/abg-ir.cc: Update copyright for 2019
* src/abg-leaf-reporter.cc: Update copyright for 2019
* src/abg-libxml-utils.cc: Update copyright for 2019
* src/abg-libzip-utils.cc: Update copyright for 2019
* src/abg-reader.cc: Update copyright for 2019
* src/abg-reporter-priv.cc: Update copyright for 2019
* src/abg-reporter-priv.h: Update copyright for 2019
* src/abg-sptr-utils.cc: Update copyright for 2019
* src/abg-suppression-priv.h: Update copyright for 2019
* src/abg-suppression.cc: Update copyright for 2019
* src/abg-tools-utils.cc: Update copyright for 2019
* src/abg-traverse.cc: Update copyright for 2019
* src/abg-viz-common.cc: Update copyright for 2019
* src/abg-viz-dot.cc: Update copyright for 2019
* src/abg-viz-svg.cc: Update copyright for 2019
* src/abg-workers.cc: Update copyright for 2019
* src/abg-writer.cc: Update copyright for 2019
* tests/print-diff-tree.cc: Update copyright for 2019
* tests/test-abicompat.cc: Update copyright for 2019
* tests/test-abidiff-exit.cc: Update copyright for 2019
* tests/test-abidiff.cc: Update copyright for 2019
* tests/test-alt-dwarf-file.cc: Update copyright for 2019
* tests/test-core-diff.cc: Update copyright for 2019
* tests/test-diff-dwarf-abixml.cc: Update copyright for 2019
* tests/test-diff-dwarf.cc: Update copyright for 2019
* tests/test-diff-filter.cc: Update copyright for 2019
* tests/test-diff-pkg.cc: Update copyright for 2019
* tests/test-diff-suppr.cc: Update copyright for 2019
* tests/test-diff2.cc: Update copyright for 2019
* tests/test-ini.cc: Update copyright for 2019
* tests/test-ir-walker.cc: Update copyright for 2019
* tests/test-lookup-syms.cc: Update copyright for 2019
* tests/test-read-dwarf.cc: Update copyright for 2019
* tests/test-read-write.cc: Update copyright for 2019
* tests/test-types-stability.cc: Update copyright for 2019
* tests/test-utils.cc: Update copyright for 2019
* tests/test-utils.h: Update copyright for 2019
* tests/test-write-read-archive.cc: Update copyright for 2019
* tools/abiar.cc: Update copyright for 2019
* tools/abicompat.cc: Update copyright for 2019
* tools/abidiff.cc: Update copyright for 2019
* tools/abidw.cc: Update copyright for 2019
* tools/abilint.cc: Update copyright for 2019
* tools/abipkgdiff.cc: Update copyright for 2019
* tools/abisym.cc: Update copyright for 2019
* tools/binilint.cc: Update copyright for 2019
* tools/kmidiff.cc: Update copyright for 2019
* update-copyright.sh: Update new year to 2019
2018-12-06 Xiao Jia via libabigail <libabigail@sourceware.org>
Some documentation fixes
* COMPILING: Add the pkg-config dependency.
* doc/manuals/kmidiff.rst: Replace the redundant --full-impact
documentation with the proper --impacted-interfaces one.
2018-11-29 Dodji Seketeli <dodji@redhat.com>
Add basic support for Fortran binaries
* src/abg-dwarf-reader.cc (die_pretty_print_type): Support
DW_TAG_string_type DIEs. They all have the same representation
for now.
2018-11-08 Dodji Seketeli <dodji@redhat.com>
Some light style change in abidiff.cc
* tools/abidiff.cc (adjust_diff_context_for_kmidiff): Take a
reference to diff_context rather than a pointer.
(main): Adjust.
2018-11-08 Dodji Seketeli <dodji@redhat.com>
Add a --fail-no-debug-info to abidiff
* doc/manuals/abidiff.rst: Document the new --fail-no-debug-info
option.
* tools/abidiff.cc (options::fail_no_debug_info): Define new data
member.
(display_usage): Provide a help string for the new
--fail-no-debug-info option.
(parse_command_line): Parse the new option.
(main): If --fail-no-debug-info and no debug info was found, or
not alternate debuginfo file was found, bail out.
2018-11-08 Dodji Seketeli <dodji@redhat.com>
Support having several debuginfo search dirs for a binary
* doc/manuals/abidiff.rst: Adjust doc for the
--debug-info-dir{1,2} that can now be provided several times.
* include/abg-dwarf-reader.h ({create, reset}_read_context)
(read_corpus_from_elf): Take a vector of debug info root dirs.
* include/abg-tools-utils.h (trim_leading_string)
(find_file_under_dir, make_path_absolute_to_be_freed)
(convert_char_stars_to_char_star_stars): Declare new functions.
* src/abg-dwarf-reader.cc (find_alt_debug_info_link): Renamed
find_alt_debug_info_location into this.
(find_alt_debug_info_path): Define new static function.
(find_alt_debug_info): Take a vector of debug info root dirs. Use
the new find_alt_debug_info_path to look into the debug info root
dirs for the alt debug info.
(read_context::debug_info_root_paths_): Define new data member.
(read_context::read_context): Take a vector of debug info root
dirs and initialize the new read_context::debug_info_root_paths_.
(read_context::{initialize, create_default_dwfl}): Take a vector
of debug info root dirs and adjust.
(read_context::{add_debug_info_root_paths,
add_debug_info_root_path, find_alt_debug_info}): Define new member
functions.
(read_context::load_debug_info): Look into the debug info roots
for split debug info files.
(create_read_context, read_corpus_from_elf): Take a vector of
debug info root dirs and adjust.
(has_alt_debug_info): Adjust.
* src/abg-tools-utils.cc (trim_leading_string)
(make_path_absolute_to_be_freed, find_file_under_dir)
(convert_char_stars_to_char_star_stars): Define new functions.
(entry_of_file_with_name): Define new static function.
(build_corpus_group_from_kernel_dist_under): Adjust.
* tests/print-diff-tree.cc (main): Adjust.
* tests/test-diff-dwarf.cc (main): Adjust.
* tests/test-ir-walker.cc (main): Adjust.
* tests/test-read-dwarf.cc (main): Adjust.
* tools/abicompat.cc (main): Adjust.
* tools/abidiff.cc (options::di_root_paths{1,2}): Changed
di_root_path{1,2} into this, change their types into vectors of
allocated char*.
(options::prepared_di_root_paths{1,2}): Define new data members.
(options::~options): Define new destructor.
(parse_command_line): Adjust.
(prepare_di_root_paths): Define new static function.
(handle_error): Remove arguments input_file_name,
debug_info_dir{1,2}. Now just take an instance of options
instead. Adjust.
(main): Adjust.
* tools/abidw.cc (options::dir_root_paths): Renamed dir_root_path
into this and make it be a vector of allocated char*.
(options::prepared_di_root_paths): Define new data member.
(options::~options): Free the allocated char* in
options::dir_root_paths.
(parse_command_line): Support several --debug-info-dir.
(load_corpus_and_write_abixml): Adjust.
(prepare_di_root_paths): Define static function.
(main): Adjust.
* tools/abilint.cc (main): Adjust.
* tools/abipkgdiff.cc (compare): Adjust.
2018-10-26 Dodji Seketeli <dodji@redhat.com>
Update website for 1.5
* doc/website/mainpage.txt: Update website for 1.5
2018-10-26 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.6
* configure.ac: Bump version number to 1.6
2018-10-25 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 1.5
* ChangeLog: Update automatically by calling make
update-changelog.
2018-10-25 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.5
* NEWS: Update for 1.5
2018-10-18 Dodji Seketeli <dodji@redhat.com>
Bug rhbz1638554 - assertion failed in is_mostly_distinct_diff
* src/abg-comp-filter.cc (is_mostly_distinct_diff): Handle the
case of the type diff of the function parameter diff being a
distinct diff.
2018-10-17 Dodji Seketeli <dodji@redhat.com>
Define UINT64_MAX when it's not defined
* src/abg-dwarf-reader.cc: Define UINT64_MAX when it's not defined.
2018-10-16 Dodji Seketeli <dodji@redhat.com>
Better support array with unknown upper bound
* include/abg-comparison.h
(BENIGN_INFINITE_ARRAY_CHANGE_CATEGORY): A new enumerator in the
diff_category enum.
(EVERYTHING_CATEGORY): Adjust.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Adjust.
(operator<<(ostream& o, diff_category)): Likewise.
* include/abg-ir.h (array_type_def::subrange_type::is_infinite):
Declare new member function.
* src/abg-ir.cc (array_type_def::subrange_type::priv::infinite_):
New data member.
(array_type_def::subrange_type::priv::priv): Initialize it.
(array_type_def::subrange_type::get_length): Better support
unknown sized subrange.
(array_type_def::subrange_type::is_infinite): Define new member
function.
* src/abg-comp-filter.cc (has_benign_infinite_array_change):
Define new static function.
(categorize_harmless_diff_node): Use the new
has_benign_infinite_array_change above.
* src/abg-dwarf-reader.cc (build_subrange_type): Better recognize a
subrange type with unknown upper bound. Represent that with the
new array_type_def::subrange_type::is_infinite member property.
* src/abg-reader.cc (build_subrange_type): Likewise.
* tests/data/test-abidiff/test-PR18166-libtirpc.so.abi: Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2018-10-11 Dodji Seketeli <dodji@redhat.com>
Add default suppression specification for the libvirt project
* default.abignore: Suppress changes on functions with symbol
version LIBVIRT_PRIVATE in libvirt.so.* shared objects.
2018-10-11 Dodji Seketeli <dodji@redhat.com>
Add default suppression specification for the krb5 project
* default.abignore: Ignore changes about functions starting with
krb5int_.*.
2018-10-03 Dodji Seketeli <dodji@redhat.com>
Misc comment fix
* src/abg-suppression.cc (type_suppression::suppresses_diff): Fix
comment.
2018-10-03 Dodji Seketeli <dodji@redhat.com>
Bug 23708 - categorize void* to pointer change as harmless
* include/abg-comparison.h (VOID_PTR_TO_PTR_CHANGE_CATEGORY): New
enumerator in the diff_category enum. Also, adjust the
EVERYTHING_CATEGORY enumerator.
* include/abg-fwd.h (is_void_pointer_type): Declare new function.
* src/abg-comp-filter.cc (has_void_ptr_to_ptr_change): Define new
static function and ...
(categorize_harmless_diff_node): ... use it here.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Add the new abigail::comparison::VOID_PTR_TO_PTR_CHANGE_CATEGORY
category in here.
(operator<<(ostream& o, diff_category c)): Add support for the new
VOID_PTR_TO_PTR_CHANGE_CATEGORY.
* src/abg-ir.cc (is_void_pointer_type): Define new function.
* tests/data/Makefile.am: Add the new test material below to source distribution.
* tests/data/test-diff-filter/test47-filter-void-ptr-change-report-0.txt:
New test reference output.
* tests/data/test-diff-filter/test47-filter-void-ptr-change-v{0,1}.c:
Source code of the new binary test input below.
* tests/data/test-diff-filter/test47-filter-void-ptr-change-v{0,1}.o:
New binary test input.
* tests/test-diff-filter.cc: Add the test input/output above to
test harness.
2018-10-02 Dodji Seketeli <dodji@redhat.com>
Categorize CV qualifier changes on fn return types as harmless
* include/abg-comparison.h (FN_RETURN_TYPE_CV_CHANGE_CATEGORY):
New enumerator for diff_category.
(EVERYTHING_CATEGORY): Update.
* src/abg-comp-filter.cc (type_diff_has_cv_qual_change_only):
Factorize this function out of ...
(has_fn_parm_type_cv_qual_change): ... this one.
(has_fn_return_type_cv_qual_change): Define new static function.
(categorize_harmless_diff_node): Use the new
has_fn_return_type_cv_qual_change.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Adjust to add the new FN_RETURN_TYPE_CV_CHANGE_CATEGORY category.
(operator<<(ostream& o, diff_category c)): Support the new
FN_RETURN_TYPE_CV_CHANGE_CATEGORY.
* tests/data/Makefile.am: Add the new test material below to
source distribution.
* tests/data/test-diff-filter/test46-fn-return-qual-change-report-0.txt:
New reference output for the new input test.
* tests/data/test-diff-filter/test46-fn-return-qual-change-v{0,1}.c:
New source code for the new binary test input.
* tests/data/test-diff-filter/test46-fn-return-qual-change-v{0,1}.o:
New binary test input files.
* tests/test-diff-filter.cc: Add the new test input above to test
harness.
2018-10-01 Dodji Seketeli <dodji@redhat.com>
Fix propagation of private type suppression category
* include/abg-comp-filter.h (has_harmful_name_change): Declare new
function overloads.
* include/abg-comparison.h (PRIVATE_TYPE_CATEGORY): New enumerator
for diff_category;
(EVERYTHING_CATEGORY): Adjust this enumerator in diff_category;
(is_suppressed): Take an output parameter to say if the
suppression is a private type suppression.
* include/abg-suppression.h (is_private_type_suppr_spec): Take a
const reference parameter and add an overload for a shared
pointer.
* src/abg-comp-filter.cc (has_harmful_name_change): Define new
function.
* src/abg-comparison-priv.h (diff::priv::is_filtered_out): Diffs
of category PRIVATE_TYPE_CATEGORY are also considered filtered
out.
* src/abg-comparison.cc (diff::is_filtered_out): Adjust to account
for canonical diffs of category PRIVATE_TYPE_CATEGORY.
(diff::is_suppressed): Add an overload that takes a
is_private_type output parameter. Re-write the old overload in
terms of the new one.
(operator<<(ostream& o, diff_category c)): Handle
PRIVATE_TYPE_CATEGORY.
(category_propagation_visitor::visit_end): Do not propagate
PRIVATE_TYPE_CATEGORY here. Do not propagate
HARMLESS_DECL_NAME_CHANGE_CATEGORY either, when the class does
have a harmful decl name change.
(suppression_categorization_visitor::visit_begin): Set the new
PRIVATE_TYPE_CATEGORY category but do not propagate it.
(suppression_categorization_visitor::visit_end): Add some
comments.
* src/abg-default-reporter.cc (default_reporter::report): Avoid
reporting typedef underlying types that are in the
PRIVATE_TYPE_CATEGORY category.
* src/abg-suppression.cc (type_suppression::suppresses_diff): Do
not peel typedefs if we are a private type suppression.
(is_private_type_suppr_spec): Take a const reference.
* tests/data/Makefile.am: Add the new test material below to
source distribution.
* tests/test-diff-suppr.cc: Use new test binary input.
* tests/data/test-diff-filter/test7-report.txt: Adjust.
* tests/data/test-diff-suppr/test39-opaque-type-report-0.txt: New
test reference output.
* tests/data/test-diff-suppr/test39-opaque-type-v{0,1}.c: Source
code of new test binary input.
* tests/data/test-diff-suppr/test39-opaque-type-v{0,1}.o: New test
binary input.
* tests/data/test-diff-suppr/test39-public-headers-dir/test39-header-v{0,1}.h:
Source code of new test binary input.
2018-09-25 Dodji Seketeli <dodji@redhat.com>
PR23641 - confusion when a type definition DIE is matched by a supprspec and its decl DIEs aren't
* src/abg-dwarf-reader.cc (get_opaque_version_of_type): If no
pre-existing opaque version was found, a new one is created and
returned. Take a needed "where_offset" parameter.
(build_ir_node_from_die): Adjust the call to
get_opaque_version_of_type.
2018-09-21 Dodji Seketeli <dodji@redhat.com>
PR23641 - Type definition DIE matched by a supprspec but not its decl
*definition* of T, they will be dropped too.
We'll end up with those two libraries that are identical (modulo the
order in which libabigail sees type declarations and their
definitions) and are considered different when a suppression
specification makes us drop T: the second library appears to
libabigail as if T was removed from it.
This is the problem addressed by this patch.
When the definition of a type T is suppressed because it's considered
private then we look if there was a forward declaration for it
elsewhere, that is not matched by the private type suppression
specification. If we encountered such a type declaration then it
means that declaration is in effect an "opaque" version of T. So
rather than just dropping T altogether, we keep (and build an IR) for
its opaque version only. And we drop the definition of T.
This seems to fix the issue.
I can't seem to reproduce the slight re-ordering of DIEs descriptions that
uncover the issue so I'll rely on integration tests to catch future
regressions on this issue, rather than on unit tests. Sigh.
* include/abg-tools-utils.h (PRIVATE_TYPES_SUPPR_SPEC_NAME):
Remove this extern constant definition.
* src/abg-dwarf-reader.cc (type_is_suppressed): Add an overload
that takes an additional type_is_private output parameter.
(get_opaque_version_of_type): New static function.
(build_ir_node_from_die): For class types, get the opaque version
for suppressed private types rather than dropping them altogether.
* src/abg-reader.cc (type_is_suppressed): Adjust.
* src/abg-suppression-priv.h (type_is_suppressed): Add an overload
that takes a type_is_private output parameter.
* include/abg-suppression.h (get_private_types_suppr_spec_label)
(is_private_type_suppr_spec): Declare new functions.
* src/abg-suppression.cc
(get_private_types_suppr_spec_label, is_private_type_suppr_spec):
Define new functions.
(suppression_matches_type_name_or_location): Use the new
get_private_types_suppr_spec_label rather than a global extern
variable.
* src/abg-tools-utils.cc (handle_fts_entry): Adjust to use the new
get_private_types_suppr_spec_label.
(gen_suppr_spec_from_headers): Handle the case or an empty headers
root dir.
2018-09-03 Dodji Seketeli <dodji@redhat.com>
Add option to avoid walking abigail::ir nodes twice
* include/abg-ir.h (struct ir_node_visitor): Make this be a class.
Add a private data member to it, following the 'pimpl' idiom.
(ir_node_visitor::{allow_visiting_already_visited_type_node,
mark_type_node_as_visited, forget_visited_type_nodes,
type_node_has_been_visited}): Declare new member functions.
* src/abg-ir.cc ({type_base, type_decl, scope_type_decl,
qualified_type_decl, pointer_type_def, reference_type_def,
array_type_def, enum_type_decl, typedef_decl, class_or_union,
class_decl, union_decl}::traverse): Avoid re-visiting the type
node if the visitor was configured as such.
(struct ir_node_visitor::priv): Define new struct.
(ir_node_visitor::{allow_visiting_already_visited_type_node,
mark_type_node_as_visited, forget_visited_type_nodes,
type_node_has_been_visited}): Define new member functions.
* tests/test-ir-walker.cc
(name_printing_visitor::name_printing_visitor): Avoid visiting a
type node twice.
2018-08-31 Dodji Seketeli <dodji@redhat.com>
Fix apidoc of dwarf_reader::get_soname_of_elf_file
* src/abg-dwarf-reader.cc (get_soname_of_elf_file): Document the
first parameter. Remove bogus documentation of the previous 'elf'
parameter.
2018-08-30 Dodji Seketeli <dodji@redhat.com>
Bug 23533 - Accept '=' in ini property values
* src/abg-ini.cc (char_is_delimiter): Take a new include_equal
flag to control is the equal character should be considered as a
delimiter or not.
(char_is_property_value_char): Accept the equal character as a
valid property value character.
* tests/Makefile.am: Build a new runtestini test from the new
tests/test-ini.cc source file.
* tests/data/Makefile.am: Add the two new test inputs below to
source distribution.
* tests/data/test-ini/test01-equal-in-property-string.{abignore,
abignore.expected}: New test inputs.
* tests/test-ini.cc: New test harness.
2018-08-06 Dodji Seketeli <dodji@redhat.com>
Make test-ir-walker work on ELF binaries directly
* test-ir-walker.cc (main): Load an ABI corpus from an elf file
and walk its translation units.
2018-07-17 Dodji Seketeli <dodji@redhat.com>
Allow use of python even when fedabipkgdiff is disabled
* configure.ac: Detect the presence and version of python even
when fedabipkgdiff is disabled.
2018-07-16 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.5
* configure.ac: Bump version number to 1.5
2018-07-13 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 1.4 release
* ChangeLog: Update this using make update-changelog
2018-07-13 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.4 release
* NEWS: Added 1.4 entries
2018-07-13 Dodji Seketeli <dodji@redhat.com>
Properly add test materials for test-diff-suppr/test38-char-class-in-ini*
* tests/data/Makefile.am: Add proper path for
test-diff-suppr/test38-char-class-in-ini*.
2018-07-12 Dodji Seketeli <dodji@redhat.com>
Allow square brackets in ini property values
* src/abg-ini.cc (char_is_delimiter): Possibly disallow square
bracket characters into the set of delimiters.
* tests/data/test-diff-suppr/test38-char-class-in-ini-report-0.txt:
New reference output.
* tests/data/test-diff-suppr/test38-char-class-in-ini-v{0,1}.c:
Source code new test binaries.
* tests/data/test-diff-suppr/test38-char-class-in-ini-v{0,1}.o:
New test binaries.
* tests/data/test-diff-suppr/test38-char-class-in-ini.abignore:
New test abi suppression file.
* tests/data/Makefile.am: Add the new test materials above to
source distribution.
* tests/test-diff-suppr.cc: Add the test materials above to the
set of tests to run.
2018-07-10 Dodji Seketeli <dodji@redhat.com>
Fix race between runtestdefaultsupprs{py3.sh,.py}
* tests/Makefile.am: Run runtestdefaultsupprspy3.sh if we are in
python3 mode otherwise run runtestdefaultsupprs.py.
2018-06-29 Dodji Seketeli <dodji@redhat.com>
Ensure die_function_type_is_method_type returns a class type die
* src/abg-dwarf-reader.cc (die_peel_typedef): Define new static
function.
(die_function_type_is_method_type): Use the function above to peel
the class die from potential typedefs wrapping it.
2018-06-28 Dodji Seketeli <dodji@redhat.com>
Misc style adjustements
* include/abg-suppression.h
(function_suppression::ADDED_FUNCTION_CHANGE_KIND): Fix the
comment of this enumerator.
(suppresses_variable): Cleanup parameter name.
* src/abg-comparison.cc: Remove useless horizontal space.
* src/abg-suppression.cc
(variable_suppression::suppresses_variable): Fix typo.
2018-06-28 Dodji Seketeli <dodji@redhat.com>
Initial basic support of union type in suppression specifications
* src/abg-suppression.cc (suppression_matches_type_no_name):
Support union types.
2018-06-28 Dodji Seketeli <dodji@redhat.com>
Filter out changes like type to const type
* include/abg-comparison.h (FN_PARM_TYPE_CV_CHANGE_CATEGORY): Add
this new enumerator to the diff_category enum. Also, OR this to
the value of the EVERYTHING_CATEGORY enumerator.
* src/abg-comp-filter.cc (has_fn_parm_type_top_cv_qual_change):
Rename has_fn_parm_type_cv_qual_change into this.
(has_fn_parm_type_cv_qual_change): New function.
(categorize_harmless_diff_node): Categorize cv qual changes as
being of category FN_PARM_TYPE_CV_CHANGE_CATEGORY.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Add FN_PARM_TYPE_CV_CHANGE_CATEGORY to the default harmless
categories.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Adjust.
2018-06-28 Dodji Seketeli <dodji@redhat.com>
Fix redundancy detection through fn ptr and typedef paths
* include/abg-comparison.h
(is_function_type_diff_with_local_changes)
(is_reference_or_pointer_diff_to_non_basic_distinct_types)
(peel_typedef_diff): Declare new functions.
* src/abg-comparison.cc
(is_function_type_diff_with_local_changes)
(is_reference_or_ptr_diff_to_non_basic_nor_distinct_types)
(peel_typedef_diff): Define new functions.
(is_reference_or_pointer_diff): Peel typedefs before operating.
(redundancy_marking_visitor::visit_begin): Only sibbling parameter
diff node that carry basic type changes (or distinct type changes)
are *not* marked as redundant. All other kinds of sibbling
parameter diff nodes are markes redundant. Also, rather than
never marking function type diffs as redundant by fear of missing
local changes on these, just avoid marking function type diff
nodes with local changes. It's possible to be that precise now
that we can detect that a diff node carries local changes.
* tests/data/test-diff-suppr/test37-opaque-type-v{0,1}.o: New
binary tests input.
* tests/data/test-diff-suppr/test37-opaque-type-v{0,1}.c: Source
code of the binary tests input above.
* tests/data/test-diff-suppr/test37-opaque-type-header-dir/test37-opaque-type-header-v{0,1}.h:
Headers of the binary tests input above.
* tests/data/test-diff-suppr/test37-opaque-type-report-0.txt:
Reference output for this new test.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
above to the test harness.
2018-06-08 Dodji Seketeli <dodji@redhat.com>
Fix indentation of help string in abipkgdiff
* tools/abipkgdiff.cc (display_usage): Fix indentation of help
string.
2018-06-08 Dodji Seketeli <dodji@redhat.com>
Identify a function using its symbol name and version
* src/abg-default-reporter.cc (default_reporter::report): In C,
tell the user about the underlying function symbol name only if
said symbol name is different from the name of the function.
* src/abg-ir.cc (function_decl::get_id): If the function has an
underlying symbol, use the symbol name and version as the function
ID. But if the function symbol has an alias then use the linkage
name as the ID.
* tests/data/test-diff-pkg/elfutils-debuginfo-0.170-4.el7.x86_64.rpm:
New binary test input.
* tests/data/test-diff-pkg/elfutils-debuginfo-0.171-1.el7.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/elfutils-devel-0.170-4.el7.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/elfutils-devel-0.171-1.el7.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/elfutils-libs-0.170-4.el7.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/elfutils-libs-0.171-1.el7.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/elfutils-libs-0.170-4.el7.x86_64-multiple-sym-vers-report-0.txt:
New reference test output.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Integrate the new test
inputs above into the harness.
2018-06-06 Dodji Seketeli <dodji@redhat.com>
Bump version to 1.4
* configure.ac: Bump version to 1.4
2018-06-06 Dodji Seketeli <dodji@redhat.com>
Explicitely detect anonymous data member changes
* include/abg-comp-filter.h (has_anonymous_data_member_change):
Add new function declaration.
* include/abg-fwd.h (is_data_member, is_anonymous_data_member):
declare new overloads.
* src/abg-comp-filter.cc (has_anonymous_data_member_change):
Define new overloads.
* src/abg-ir.cc (is_data_member, is_anonymous_data_member): Define
new overloads.
* src/abg-reporter-priv.cc (represent): In the var_diff overload,
detect when we have anonymous data member changes and emit
explicit error messages then.
* tests/data/test-diff-dwarf/test45-anon-dm-change-report-0.txt:
New test material.
* tests/data/test-diff-dwarf/test45-anon-dm-change-v0.cc: Likewise.
* tests/data/test-diff-dwarf/test45-anon-dm-change-v0.o: Likewise.
* tests/data/test-diff-dwarf/test45-anon-dm-change-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test45-anon-dm-change-v1.o: Likewise.
* tests/data/Makefile.am: Add the new test material above to source
distribution.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test
material above to the test harness.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
2018-06-05 Dodji Seketeli <dodji@redhat.com>
Add test44-anon-struct-union-v{0,1}.o to source distribution
* tests/data/Makefile.am: Add
test-diff-dwarf/test44-anon-struct-union-v{0,1}.o files to source
distribution.
2018-06-04 Dodji Seketeli <dodji@redhat.com>
Use the flat representation for anonymous struct/unions
* src/abg-ir.cc (get_class_or_union_flat_representation): Take a
const class_or_union* (like what the declaration in the header
file says), rather than just a class_or_union*.
({class,union}_decl::get_pretty_representation): For anonymous
classes and unions, use the flat representation.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/test43-PR22913-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test44-anon-struct-union-report-0.txt:
New test reference output.
* tests/data/test-diff-dwarf/test44-anon-struct-union-v{0,1}.cc:
Source code of new test binary outputs.
* tests/data/test-diff-dwarf/test44-anon-struct-union-v{0,1}.o:
New test binary outputs.
* tests/data/Makefile.am: Add the new test materials above to
source districution.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test
material above to the test harness here.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
2018-06-01 Dodji Seketeli <dodji@redhat.com>
Better detect when pointer and qualified types carry local changes
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Do not mark
qualified types as leaf diff nodes.
(redundancy_marking_visitor::visit_end): Changes to qualified type
are never considered local. This is just as for pointer and
reference types.
* src/abg-default-reporter.cc
(default_reporter::report_local_reference_type_changes): Display
structural changes of the pointed-to type.
(default_reporter::report): In the overload for reference_diff,
better detect and handle when we have local changes, or not.
* src/abg-ir.cc (equals): In the overload for qualified_type_def
and reference_type_de, report local type changes of the underlying
type as local changes. Add comments in the overload for pointer
type, and make it look like the the overload for reference_type.
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
overload for pointer_diff, remove end of line.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-1.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
2018-05-23 Dodji Seketeli <dodji@redhat.com>
Better detect when diff nodes only carry local type changes
* include/abg-comparison.h ({diff, type_diff_base, decl_diff_base,
distinct_diff, var_diff, pointer_diff, reference_diff, array_diff,
qualified_type, enum_diff, class_or_union_diff, class_diff,
base_diff, scope_diff, fn_parm_diff, function_type_diff,
function_decl_diff, typedef_diff,
translation_unit_diff}::has_local_changes): Return an enum
change_kind, rather than just a bool.
(is_diff_of_basic_type): Declare an overload that takes a boolean
flag.
(is_qualified_type_diff, peel_pointer_diff, peel_reference_diff)
(peel_qualified_type, peel_pointer_or_qualified_type): Declare new
functions
* include/abg-fwd.h (peel_qualified_type):
* include/abg-ir.h (enum change_kind::{LOCAL_TYPE_CHANGE_KIND,
LOCAL_NON_TYPE_CHANGE_KIND, ALL_LOCAL_CHANGES_MASK}): Add these
three new enumerators.
* src/abg-comparison.cc ({distinct_diff, var_diff, pointer_diff,
array_diff, reference_diff, qualified_type_diff, enum_diff,
class_or_union_diff, class_diff, base_diff, scope_diff,
fn_parm_diff, function_type_diff, function_decl_diff,
type_decl_diff, typedef_diff,
translation_unit_diff}::has_local_changes): Adjust to return an
enum change_kind, rather than just a bool.
(has_local_type_change_only): Define new functions.
(has_basic_type_change_only): Use the new
has_local_type_change_only function and the new overload for
is_diff_of_basic_type.
(is_diff_of_basic_type): Define an overload that takes a boolean
flag.
(is_qualified_type_diff, peel_pointer_diff, peel_reference_diff)
(peel_qualified_type, peel_pointer_or_qualified_type): Define new
functions.
* src/abg-ir.cc (equals): In the overloads for decl_base,
scope_decl, type_base, qualified_type_diff, pointer_type_def,
reference_type_def, array_type_def, enum_type_decl, typedef_decl,
var_decl, function_type, function_decl, function_decl::parameter,
class_or_union, class_decl::base_spec and class_decl, properly set
the new abigail::ir::{LOCAL_CHANGE_KIND,
LOCAL_NON_TYPE_CHANGE_KIND, LOCAL_TYPE_CHANGE_KIND} bits.
(types_have_similar_structure): Peel qualified types and typedefs
off, first thing.
(peel_qualified_or_typedef_type): Define new function.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Adjust.
* tests/data/test-diff-filter/libtest45-basic-type-change-report-{0,1}.txt:
New reference test reports.
* tests/data/test-diff-filter/libtest45-basic-type-change-v{0,1}.so:
New input test binaries.
* tests/data/test-diff-filter/test45-basic-type-change-v{0,1}.cc:
Source code of the input test binaries above.
* tests/data/Makefile.am: Add the new test file above to source
distribution.
* tests/test-diff-filter.cc: Add the test input above to the test
harness.
2018-05-18 Dodji Seketeli <dodji@redhat.com>
Improve detection of local *type* changes
* include/abg-fwd.h (is_type_decl): Declare new overload for
type_base*.
(types_have_similar_structure): Declare new function.
* src/abg-comparison.cc
(class_or_union_diff::priv::count_filtered_changed_dm): Even when
looking at local changes only, do not forget to count nodes that
were filtered out.
* src/abg-ir.cc (types_have_similar_structure): Define new
function.
(is_type_decl): Define new overload for
type_base*.
(is_enum_type):
(equals): In the overload for var_decl, use the new
types_have_similar_structure function to detect local (type)
changes.
* src/abg-reporter-priv.cc (represent): In the overload for
var_decl, use the diff::has_local_changes function to detect local
changes, now that we can better detect local changes.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-1.txt:
Adjust.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Likewise.
2018-05-16 Dodji Seketeli <dodji@redhat.com>
Remove references, arrays and fn parms from leaf diff nodes
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Do not mark
references, array and fn parms diff nodes as leaf nodes.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Adjust.
2018-05-23 Dodji Seketeli <dodji@redhat.com>
Fix typo in tests/runtestdefaultsupprs.py
* tests/runtestdefaultsupprs.py.in: Fix typo.
2018-05-17 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog
* ChangeLog: Update this file automatically by running the "make
update-changelog" command.
2018-05-17 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.3 release
* NEWS: Update for 1.3.
2018-05-16 Dodji Seketeli <dodji@redhat.com>
Don't bail because "rpm" issued an error
* src/abg-tools-utils.cc (get_dsos_provided_by_rpm): Do not fail
when the rpm command issues an error. Rather rely on the presence
of a valid output or not. Also, make sure to filter out error
outputs so that they don't appear in the general output of tools
using this function.
2018-05-16 Dodji Seketeli <dodji@redhat.com>
Handle cases where no python2 interpreter is found
* configure.ac: When no python2 is found and only python3 is
found, then use python3.
2018-05-16 Dodji Seketeli <dodji@redhat.com>
Use the correct python interpreter in runtestdefaultsupprs.py
* configure.ac: Make the PYTHON environemnt variable usable in
auto-generated files.
* tests/runtestdefaultsupprs.py.in: Use the python interpreter
detected by configure.
2018-05-16 Dodji Seketeli <dodji@redhat.com>
Use the dynamically selected python for Koji configure tests
* configure.ac: Use the python interpreter that was selected by
the configure script for the Koji version test.
2018-05-14 Dodji Seketeli <dodji@redhat.com>
Sort the output of the leaf reporter
* include/abg-comparison.h (diff_ptrs_type): Define new typedef.
* src/abg-comparison-priv.h (sort_string_diff_ptr_map): Declare
new function.
* src/abg-comparison.cc (sort_string_diff_sptr_map): Update
comment.
(sort_string_diff_ptr_map): Define new function.
* src/abg-leaf-reporter.cc (report_diffs): Sort the diff nodes
before reporting about them.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Adjust.
2018-05-14 Dodji Seketeli <dodji@redhat.com>
Show data member offsets in bytes too
* src/abg-reporter-priv.cc (represent): In the overload for
var_diff_sptr, use the function show_offset_or_size, rather than
emit_num_value.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Adjust.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-0.txt: Adjust.
* tests/data/test-diff-filter/test44-anonymous-data-member-report-1.txt: Adjust.
2018-05-09 Dodji Seketeli <dodji@redhat.com>
Initial support of anonymous data members
* include/abg-comparison.h (is_class_or_union_diff)
(is_anonymous_class_or_union_diff): Declare new functions.
* include/abg-fwd.h (is_class_type): Declare new overload for
type_or_decl_base&.
(is_data_member): Declare new overload for decl_base*.
(is_anonymous_data_member)
(anonymous_data_member_to_class_or_union)
(get_class_or_union_flat_representation)
(data_member_has_anonymous_type): Declare new functions.
(is_at_class_scope): Return the class or union scope.
* include/abg-ir.h (var_decl::get_qualified_name): New virtual
data member which overloads decl_base::get_qualified_name.
* src/abg-comparison.cc (is_class_or_union_diff)
(is_anonymous_class_or_union_diff): Define new functions
(leaf_diff_node_marker_visitor::visit_begin): Don't mark anonymous
class or union diff nodes as diff nodes.
* src/abg-ir.cc (is_data_member): Define new overload for
decl_base*.
(is_class_type, is_union_type): Define new overload for type_or_decl_base&.
(is_anonymous_data_member)
(anonymous_data_member_to_class_or_union)
(get_class_or_union_flat_representation)
(data_member_has_anonymous_type): Define new function overloads.
(var_decl::get_qualified_name): Define new virtual member
function.
(is_at_class_scope): Return the class or union scope.
(var_decl::get_pretty_representation): Support anonymous data
members.
(equals): In the overload for class_or_union_diff, mark data
member textual representation changes as local changes.
* src/abg-reporter-priv.cc (represent): In the overload for
var_diff, support changes to anonymous data members.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Report sorted
-- by offset -- data member changes before the ones that are
sorted by other things.
* tests/data/test-diff-filter/libtest44-anonymous-data-member-v{0,1}.so:
New binary test input
* tests/data/test-diff-filter/test44-anonymous-data-member-report-{0,1}.txt:
New reference test outputs.
* tests/data/test-diff-filter/test44-anonymous-data-member-v{0,1}.c:
Source code of the new binary test output above.
* tests/data/Makefile.am: Add the new test files above to the
source distribution.
* tests/data/test-annotate/libtest23.so.abi: Adjust test reference
output.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf/test43-PR22913-report-0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise.
2018-04-20 Dodji Seketeli <dodji@redhat.com>
Represent sizes and offsets in bytes and hexadecimal values
* doc/manuals/abidiff.rst: Add documentation for the new
--show-bits, --show-bytes, --show-hex and --show-dec options.
* doc/manuals/abipkgdiff.rst: Likewise.
* doc/manuals/kmidiff.rst: Likewise.
* include/abg-comparison.h (diff_context::{show_hex_values,
show_offsets_sizes_in_bits}): Declare new member functions.
* src/abg-comparison-priv.h (diff_context::priv::{hex_values_,
show_offsets_sizes_in_bits_}): Declare new data members.
(diff_context::priv::priv): Initialize them.
* src/abg-comparison.cc (diff_context::{show_hex_values,
show_offsets_sizes_in_bits}): Define new member functions.
* src/abg-default-reporter.cc (default_reporter::report): Adjust
the call to maybe_report_diff_for_symbol.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Likewise.
* src/abg-reporter-priv.h (convert_bits_to_bytes)
(maybe_convert_bits_to_bytes, emit_num_value, show_offset_or_size)
(show_numerical_change): Declare new functions.
(maybe_report_diff_for_symbol): Take a diff_context in parameter.
* src/abg-reporter-priv.cc (convert_bits_to_bytes, emit_num_value)
(maybe_convert_bits_to_bytes, show_numerical_change)
(show_offset_or_size): Define new functions.
(represent): In the overload for method_decl, var_decl, use the
new emit_num_value function.
(represent_data_member): Use the new show_offset_or_size function.
(maybe_show_relative_offset_change): Use the new
convert_bits_to_bytes, diff_context::show_offsets_sizes_in_bits,
emit_num_value functions.
(maybe_show_relative_offset_change): Likewise.
(report_size_and_alignment_changes): Use the new emit_num_value
and show_numerical_change functions.
(maybe_report_diff_for_symbol): Tak a diff_context in argument.
Use the new show_numerical_change function.
* tests/test-diff-filter.cc (in_out_spec): Add a new entry to test
hexa and bytes output.
* tools/abidiff.cc (options::{show_hexadecimal_values,
show_offsets_sizes_in_bits}): New data members.
(options::options): Initialize them.
(display_usage): New help strings for the new
--show{bytes,bits,hex,dec} options.
(parse_command_line): Parse the new --show{bytes,bits,hex,dec} options.
(set_diff_context_from_opts) Set the diff context wrt hex and
bytes values.
* tools/abipkgdiff.cc (options::{show_hexadecimal_values,
show_offsets_sizes_in_bits}): New data members.
(options::options): Initialize them.
(display_usage): New help strings for the new
--show{bytes,bits,hex,dec} options.
(set_diff_context_from_opts): Set the diff context wrt hex and
bytes values.
(parse_command_line): Parse the new --show{bytes,bits,hex,dec}
options.
* tools/kmidiff.cc (options::{show_hexadecimal_values,
show_offsets_sizes_in_bits}): New data members.
(options::options): Initialize them.
(display_usage):New help strings for the new
--show{bytes,bits,hex,dec} options.
(parse_command_line): Parse the new --show{bytes,bits,hex,dec}
options.
(set_diff_context): Set the diff context wrt hex and bytes values.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report2.txt:
New reference test output.
* tests/data/Makefile.am: Add the new reference test output above
to source distribution.
* tests/data/test-abicompat/test0-fn-changed-report-0.txt: Adjust.
* tests/data/test-abicompat/test0-fn-changed-report-2.txt: Likewise.
* tests/data/test-abicompat/test5-fn-changed-report-0.txt: Likewise.
* tests/data/test-abicompat/test5-fn-changed-report-1.txt: Likewise.
* tests/data/test-abicompat/test6-var-changed-report-0.txt: Likewise.
* tests/data/test-abicompat/test6-var-changed-report-1.txt: Likewise.
* tests/data/test-abicompat/test7-fn-changed-report-0.txt: Likewise.
* tests/data/test-abicompat/test7-fn-changed-report-1.txt: Likewise.
* tests/data/test-abicompat/test7-fn-changed-report-2.txt: Likewise.
* tests/data/test-abicompat/test8-fn-changed-report-0.txt: Likewise.
* tests/data/test-abicompat/test9-fn-changed-report-0.txt: Likewise.
* tests/data/test-abidiff/test-PR18791-report0.txt: Likewise.
* tests/data/test-abidiff/test-qual-type0-report.txt: Likewise.
* tests/data/test-abidiff/test-struct0-report.txt: Likewise.
* tests/data/test-abidiff/test-struct1-report.txt: Likewise.
* tests/data/test-abidiff/test-var0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test1-report.txt: Likewise.
* tests/data/test-diff-dwarf/test10-report.txt: Likewise.
* tests/data/test-diff-dwarf/test11-report.txt: Likewise.
* tests/data/test-diff-dwarf/test13-report.txt: Likewise.
* tests/data/test-diff-dwarf/test21-redundant-fn-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test22-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt: Likewise.
* tests/data/test-diff-dwarf/test27-local-base-diff-report.txt: Likewise.
* tests/data/test-diff-dwarf/test3-report.txt: Likewise.
* tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test34-pr19173-libfoo-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test37-union-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test39-union-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test40-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test43-PR22913-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-dwarf/test9-report.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test1-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test11-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test14-0-report.txt: Likewise.
* tests/data/test-diff-filter/test14-1-report.txt: Likewise.
* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
* tests/data/test-diff-filter/test15-1-report.txt: Likewise.
* tests/data/test-diff-filter/test16-report-2.txt: Likewise.
* tests/data/test-diff-filter/test16-report.txt: Likewise.
* tests/data/test-diff-filter/test17-0-report.txt: Likewise.
* tests/data/test-diff-filter/test17-1-report.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-0.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-1.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-2.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-0.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt: Likewise.
* tests/data/test-diff-filter/test29-finer-redundancy-marking-report-0.txt: Likewise.
* tests/data/test-diff-filter/test3-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Likewise.
* tests/data/test-diff-filter/test32-ppc64le-struct-change-report0.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt: Likewise.
* tests/data/test-diff-filter/test37-report-0.txt: Likewise.
* tests/data/test-diff-filter/test39/test39-report-0.txt: Likewise.
* tests/data/test-diff-filter/test42-leaf-report-output-0.txt: Likewise.
* tests/data/test-diff-filter/test6-report.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-pkg/dirpkg-1-report-1.txt: Likewise.
* tests/data/test-diff-pkg/dirpkg-3-report-1.txt: Likewise.
* tests/data/test-diff-pkg/dirpkg-3-report-2.txt: Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise.
* tests/data/test-diff-pkg/symlink-dir-test1-report0.txt: Likewise.
* tests/data/test-diff-pkg/tarpkg-0-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tarpkg-1-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test11-add-data-member-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test12-add-data-member-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test12-add-data-member-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test2-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-10.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-12.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-14.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-16.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test25-typedef-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test26-loc-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test26-loc-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-8.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test30-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test31-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test32-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test32-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test33-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test35-leaf-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0-1.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-8.txt: Likewise.
* tests/data/test-diff-suppr/test8-redundant-fn-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test8-redundant-fn-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-1.txt: Likewise.
2018-04-18 Dodji Seketeli <dodji@redhat.com>
Use absolute builddir paths in automake test files
* tests/runtestdefaultsupprs.py.in: Use abs_top_builddir rather
than top_builddir.
2018-04-10 Jonathan Wakely <jwakely@redhat.com>
Use std::string::substr instead of appending single chars
* src/abg-ini.cc (trim_white_space): Use std::string::substr
instead of appending single chars.
2018-04-10 Jonathan Wakely <jwakely@redhat.com>
Rename misleading remove_trailing_white_spaces functions
* include/abg-tools-utils.h (trim_white_space): Renamed
remove_trailing_white_spaces into this.
* src/abg-ini.cc (trim_white_space): Likewise.
* src/abg-tools-utils.cc (get_dsos_provided_by_rpm): Adjust.
2018-04-10 Jonathan Wakely <jwakely@redhat.com>
Remove unused local set<string> variables
* src/abg-tools-utils.cc (get_dsos_provided_by_rpm): Remove unsed
set<string> variable.
* tools/abipkgdiff.cc (maybe_create_public_dso_sonames_set):
Likewise.
2018-04-10 Jonathan Wakely <jwakely@redhat.com>
Remove assertion with side-effects
* src/abg-tools-utils.cc (get_dsos_provided_by_rpm): Fix
std::string::sbustr and remove assert with side effect.
2018-04-13 Dodji Seketeli <dodji@redhat.com>
Misc style changes
* src/abg-comparison.cc (category_propagation_visitor): Adjust comment.
* src/abg-default-reporter.cc
(default_reporter::report_local_function_type_changes): Remove
useless new line.
2018-04-13 Dodji Seketeli <dodji@redhat.com>
Update tests for the "better leaf mode redundancy management" patchset
* tests/data/test-abidiff-exit/test1-voffset-change-report1.txt: Adjust.
* tests/data/test-abidiff/test-PR18791-report0.txt: Likewise.
* tests/data/test-abidiff/test-enum0-report.txt: Likewise.
* tests/data/test-abidiff/test-enum1-report.txt: Likewise.
* tests/data/test-diff-filter/test1-report.txt: Likewise.
* tests/data/test-diff-filter/test14-0-report.txt: Likewise.
* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
* tests/data/test-diff-filter/test17-0-report.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-0.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-0.txt: Likewise.
* tests/data/test-diff-filter/test3-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test32-ppc64le-struct-change-report0.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt: Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt: Likewise.
* tests/data/test-diff-filter/test4-report.txt: Likewise.
* tests/data/test-diff-filter/test41-report-0.txt: Likewise.
* tests/data/test-diff-filter/test42-leaf-report-output-0.txt: Likewise.
* tests/data/test-diff-pkg/dirpkg-3-report-1.txt: Likewise.
* tests/data/test-diff-pkg/dirpkg-3-report-2.txt: Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test15-suppr-added-fn-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test16-suppr-removed-fn-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test17-suppr-added-var-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test2-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test2-struct-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test25-typedef-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test30-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test34-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test35-leaf-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-9.txt: Likewise.
* tests/data/test-diff-suppr/test8-redundant-fn-report-0.txt: Likewise.
2018-04-13 Dodji Seketeli <dodji@redhat.com>
[abipkgdiff]: in leaf mode we always show redundant changes
* tools/abipkgdiff.cc (set_diff_context_from_opts):
diff_context::show_leaf_changes_only automatically makes us show
redundant changes. So do not try to show redundant changes in
that case.
2018-04-13 Dodji Seketeli <dodji@redhat.com>
When we say an a change was reported earlier give its source location
* src/abg-reporter-priv.h
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER2)
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER3): Report the
location of the artifact.
2018-04-13 Dodji Seketeli <dodji@redhat.com>
Avoid reporting an enum change if it has already been reported
* src/abg-default-reporter.cc (default_reporter::report): In the
enum_diff overload, do not report a node if it's always been
reported; rather, say that it has been reported earlier.
2018-04-13 Dodji Seketeli <dodji@redhat.com>
Always show redundant changes in leaf mode
* src/abg-comparison.cc (diff_context::show_leaf_changes_only):
Show redundant changes when in leaf mode.
2018-04-12 Dodji Seketeli <dodji@redhat.com>
Fix leaf report of class data member changes
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
class_or_uion_diff overload, do not emit the data member changes
header twice.
* src/abg-reporter-priv.cc (represent): In the var_diff_sptr
overload, show data member changes when its textual representation
changed.
2018-04-12 Dodji Seketeli <dodji@redhat.com>
Only show leaf type changes in the leaf type changes section
* src/abg-leaf-reporter.cc (report_type_changes_from_diff_maps):
Split this out from leaf_reporter::report_changes_from_diff_maps
and make it report only about leaf *type* changes.
(leaf_reporter::report_changes_from_diff_maps): Use the new
report_type_changes_from_diff_maps function.
(leaf_reporter::report): In the overload for corpus_diff, use the
new report_type_changes_from_diff_maps function, instead of the
report_changes_from_diff_maps function.
2018-04-12 Dodji Seketeli <dodji@redhat.com>
Don't filter out typedef changes with redundant underlying type changes
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for typedef, report underlying type changes een when they
are redundant, if the whole typedef change needs to be repoted.
2018-04-12 Dodji Seketeli <dodji@redhat.com>
Improve function changes reporting in leaf and default mode
* src/abg-default-reporter.cc (default_reporter::report): In the
overload for fn_parm_diff, consider that parameter type changes are
never redundant.
* src/abg-ir.cc (equals): In the overload for function_type,
consider that if the textual representation of the function return
type or a function parameter changed, then that's a local change
for the current instance of function_type. Likewise, in the
overload for function_decl, consider that a change in the textual
representation of the function_decl is a local change. Likewise,
in the overload of function_decl::parameter, consider that a
change in the textual representation of the parameter type is a
local change.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Report leaf
changes to functions.
2018-04-12 Dodji Seketeli <dodji@redhat.com>
Better handle category propagation of pointer changes
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Do not consider
local pointer changes as being leaf changes.
(suppression_categorization_visitor::visit_end):
Allow propagation of the SUPPRESSED_CATEGORY category to pointer
diff nodes.
(redundancy_marking_visitor::visit_end): Allow propagation of the
REDUNDANT_CATEGORY category to pointer diff nodes.
* src/abg-ir.cc (equals): In the pointer_type_def overload,
consider changes where the textual representation of the
pointed-to changed as being local to the pointer type.
* src/abg-leaf-reporter.cc (leaf_reporter::report): In the
pointer_diff overload, report the change in the textual
representation of the pointer.
2018-04-11 Dodji Seketeli <dodji@redhat.com>
Fix meaning of "harmless name change" to avoid overfiltering
* include/abg-ir.h (enum_has_non_name_change): Declare new
* function. Make it a friend of class enum_type_decl.
* src/abg-comp-filter.cc (has_harmless_name_change): A typedef
name change cannot be harmless if the textual representation of
the underlying type changes too. Also, use the new
enum_has_non_name_change to tighten the harmless name change
definition for an enum.
* src/abg-default-reporter.cc
(default_reporter::report_local_typedef_changes): If the name of
the typedef changed, report it no matter what.
* src/abg-ir.cc (enum_has_non_name_change): Define new function.
2018-04-11 Dodji Seketeli <dodji@redhat.com>
Do not mark "distinct" diff nodes as being redundant
* include/abg-comp-filter.h (is_mostly_distinct_diff): Declare new
function.
* include/abg-fwd.h (peel_typedef_pointer_or_reference_type): Take
a boolean to decide to peel qualified types or not.
* src/abg-comp-filter.cc (is_mostly_distinct_diff): Define this function.
* src/abg-comparison.cc (redundancy_marking_visitor::visit_begin):
Do not mark distinct_diff nodes as being redundant.
* src/abg-ir.cc (peel_typedef_pointer_or_reference_type):
Implement taking a boolean to decide to peel qualified types or
not.
2018-04-11 Dodji Seketeli <dodji@redhat.com>
Overhaul of the report diff stats summary
* include/abg-comparison.h
(corpus_diff::diff_stats::{num_leaf_type_changes,
num_leaf_type_changes_filtered_out, net_num_leaf_type_changes,
num_leaf_func_changes, num_leaf_func_changes_filtered_out,
net_num_leaf_func_changes, num_leaf_var_changes,
num_leaf_var_changes_filtered_out, net_num_leaf_var_changes}):
Declare new member functions.
* src/abg-comparison-priv.h
(corpus_diff::priv::count_leaf_type_changes): Declare new member
function.
* src/abg-comparison.cc
(corpus_diff::diff_stats::net_num_leaf_changes): Fix comment.
(corpus_diff::diff_stats::{num_leaf_type_changes,
num_leaf_type_changes_filtered_out, net_num_leaf_type_changes,
num_leaf_func_changes, num_leaf_func_changes_filtered_out,
net_num_leaf_func_changes, num_leaf_var_changes,
num_leaf_var_changes_filtered_out, net_num_leaf_var_changes}):
Define these member functions.
(do_count_diff_map_changes): Move this macro out of ...
(corpus_diff::priv::count_leaf_changes): ... this. Also, use
the new function corpus_diff::priv::count_leaf_type_changes.
(corpus_diff::priv::count_leaf_type_changes): Splitted this out of
the previous corpus_diff::priv::count_leaf_changes function.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Account
for (filtered) types, functions and variables, in a leaf change
manner.
(corpus_diff::priv::emit_diff_stats): Emit a better stat summary
that takes into account leaf-changed types, functions and
variables.
2018-04-10 Dodji Seketeli <dodji@redhat.com>
Do not show decl-only-to-def changes in the leaf reporter
* include/abg-comp-filter.h (has_class_decl_only_def_change):
Declare this function.
* src/abg-comp-filter.cc (has_class_decl_only_def_change): Make
this function be non-static.
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Use it to avoid
marking class-decl-only-def changes as being leaf changes.
* libtest43-decl-only-def-change-leaf-report-v0.so: New test input file.
* libtest43-decl-only-def-change-leaf-report-v1.so: Likewise.
* test43-decl-only-def-change-leaf-report-0.txt: Likewise.
* test43-decl-only-def-change-leaf-report-v0.cc: Likewise.
* test43-decl-only-def-change-leaf-report-v1.cc: Likewise.
* tests/test-diff-filter.cc (in_out_specs): Run the test over the
new test input.
* tests/data/Makefile.am: Add the new test materials to source
distribution.
2018-03-30 Dodji Seketeli <dodji@redhat.com>
Don't possibly forget type definition when reading a CorpusGroup
* src/abg-dwarf-reader.cc (add_or_update_class_type): Look for
declaration-only-ness to determine if we've already seen the same
type from the main corpus of the group.
2018-03-30 Dodji Seketeli <dodji@redhat.com>
Don't crash when invoking kmidiff with no debug info root dir
* tools/kmidiff.cc (main): Do not crash on empty debug info root
dir.
2018-03-30 Dodji Seketeli <dodji@redhat.com>
Do not enable fedabipkgdiff tests if fedabipkgdiff itself is disabled
* tests/Makefile.am: Run runtestfedabipkgdiff{py3?}.py only if
fedabipkgdiff itself is enabled.
2018-03-25 Chenxiong Qi <cqi@redhat.com>
Bug 22722 - Make fedabipkgdiff and its tests support both python 3 and 2
* configure.ac: Add new option --enable-python3. Add new
test runner file tests/runtestdefaultsupprs-py3 and
tests/runtestfedabipkgdiffpy3.sh. Add required six Python module.
* tests/Makefile.am: Add new test files
tests/runtestdefaultsupprspy3.sh and
tests/runtestfedabipkgdiffpy3.sh accordingly.
* tests/mockfedabipkgdiff.in: Convert print statement to
six.print_. Replace call to function filter with list
comprehension. Replace basestring with six.string_types.
* tests/runtestdefaultsupprspy3.sh.in: New shell script to run
test runtestdefaultsupprs with Python 3.
* tests/runtestdefaultsupprs.py.in: Repalce a few tabs with
proper number of spaces which is detected by Python 3
interpreter.
* tests/runtestfedabipkgdiffpy3.sh.in: New shell script to run
test runtestfedabipkgdiff with Python 3.
* tests/runtestfedabipkgdiff.py.in: Use python from env in
shebang instead of a fixed path to a Python interpreter.
* tools/fedabipkgdiff: Globally replace print statement with a
function call to print which is available by importing
print_function from __future__ module. Use six.print_ to output
string to stderr instead. Convert function call to map to
for-loop. (cmp_nvr): Change argument to handle a Koji build
mapping instead of only the nvr. (Brew.listBuilds): use the new
cmp_nvr to sort builds.
2018-03-29 Dodji Seketeli <dodji@redhat.com>
Detect the presence of 'rpm' as it's now needed by abipkgdiff
* configure.ac: Detect that the 'rpm' is present. Otherwise,
disable rpm support.
2018-03-28 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff avoid comparing private DSOs from RPMs
* doc/manuals/abipkgdiff.rst: Add documentation for the new
--private-dso option.
* include/abg-tools-utils.h (execute_command_and_get_output)
(execute_command_and_get_output, remove_trailing_white_spaces):
Declare new functions.
* src/abg-tools-utils.cc (execute_command_and_get_output)
(get_dsos_provided_by_rpm, remove_trailing_white_spaces): Define
new functions.
* tests/test-diff-pkg.cc (in_out_specs): Add the new --private-dso
option where it makes sense.
* tools/abipkgdiff.cc (options::compare_private_dsos): Add new
data member.
(options::options): Initialize it.
(package::public_dso_sonames_): Add new data member.
(package::public_dso_sonames): Add new accessors pair.
(display_usage): Add a help string for the new --private-dso
option.
(maybe_create_public_dso_sonames_set)
(must_compare_public_dso_only): Define new static functions.
(create_maps_of_package_content): Call the new
maybe_create_public_dso_sonames_set. Skip packages which SONAME
is not in the set of public SONAMES.
(parse_command_line): Parse the new --private-dso option.
2018-03-16 Dodji Seketeli <dodji@redhat.com>
Skip changes to function *types* in the leaf reporter
* src/abg-leaf-reporter.cc
(leaf_reporter::report_changes_from_diff_maps): Don't report
function type changes.
2018-03-16 Dodji Seketeli <dodji@redhat.com>
Report change locations in leaf reports
* src/abg-leaf-reporter.cc (report_diffs): Report the source
location of the diff.
* tests/data/test-diff-filter/test42-leaf-report-output-0.txt:
Update test reference output.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test35-leaf-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: Likewise.
2018-03-06 Dodji Seketeli <dodji@redhat.com>
Make the "upload-release" target be usable in parallel
* Makefile.am: Re-arrange the upload-release target to make it
usable with 'make upload-release -jN'.
2018-03-06 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.3
* configure.ac: Now that 1.2 is out of the door, bump version
number to 1.3
2018-03-06 Dodji Seketeli <dodji@redhat.com>
Update website for 1.2
* doc/website/mainpage.txt: Update link to download the tarball,
for 1.2.
2018-03-06 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 1.2
* ChangeLog: Updated automatically by running make update-changelog.
2018-03-06 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.2
* NEWS: Update for 1.2
2018-01-31 Dodji Seketeli <dodji@redhat.com>
Fix typo in abipkgdiff documenation
* doc/manuals/abipkgdiff.rst: Fix a typo
2018-01-31 Dodji Seketeli <dodji@redhat.com>
Update abipkgdiff documentation wrt suppression specifications
* doc/manuals/abipkgdiff.rst: Mention the .abignore file that is
read by the tool and considered as a suppression specification
file.
2018-03-06 Dodji Seketeli <dodji@redhat.com>
Fix indentation in the DWARF reader
* src/abg-dwarf-reader.cc (build_subrange_type): Fix indentation.
2018-03-02 Dodji Seketeli <dodji@redhat.com>
Fix the output indentation of abidiff --help
* tools/abidiff.cc (display_usage): Fix indentation of the help
string for the --drop-private-types option.
2018-03-02 Dodji Seketeli <dodji@redhat.com>
Bug 22913 - Correctly de-duplicate pointers to anonymous structs inside a given
* src/abg-dwarf-reader.cc
(pointer_or_qual_die_of_anonymous_class_type)
(die_is_qualified_type): Define new functions.
(compare_dies): If pointers, reference or qualified type have an
anonymous struct as their underlying type, then we need to
structurally compare the underlying anonymous struct.
* tests/data/test-diff-dwarf/libtest43-PR22913-v{0,1}.so: New
binary test input files.
* tests/data/test-diff-dwarf/test43-PR22913-report-0.txt: New
reference output of the comparison of the two binaries above.
* tests/data/test-diff-dwarf/test43-PR22913-v{0,1}.c: Source code
of the binaries above.
* tests/test-diff-dwarf.cc (in_out_specs): Make the test harness
compare the two binaries above.
* tests/data/Makefile.am: Add the new test files above to the
source distribution.
2018-02-27 Dodji Seketeli <dodji@redhat.com>
Initial support for Ada ranges
* include/abg-ir.h (type_maps::subrange_types): Declare new
accessors.
(is_ada_language, is_subrange_type): Declare new functions.
(class array_type_def::subrange_type): Make this extend type_base
and decl_base.
(array_type_def::subrange_type::{get_language, operator==,
get_pretty_representation, traverse}): Declare new member
functions.
(ir_node_visitor::visit_begin): Add new overloads for
array_type::def::subrange_type.
* src/abg-dwarf-reader.cc (build_subrange_type): Define new static
function.
(build_subranges_from_array_type_die): Cleanup the parameters of
this function.
(build_array_type): Adjust.
(build_ir_node_from_die): Support free-form DW_TAG_subrange_type.
(read_context::odr_is_relevant): Handle Ada.
(die_qualified_type_name): Support DW_TAG_subrange_type.
(die_pretty_print_type): Likewise. Make the handling of
DW_TAG_subrange_type use die_qualified_type_name. Adjust the use
of build_subranges_from_array_type_die.
(get_scope_die): a DW_TAG_array_type cannot be a scope. Rather,
it's its scope that can be a scope.
* src/abg-ir.cc (type_maps::priv::subrange_types_): New data
member.
(type_maps::empty): Adjust.
(type_maps::subrange_types): Define new accessors.
(is_ada_language, is_subrange_type): Define new functions.
(odr_is_relevant): Support Ada.
(maybe_update_types_lookup_map): Add an overload for
array_type_def::subrange_type. In the decl_base_sptr overload,
add support for the array_type_def::subrange_type type.
(struct array_type_def::subrange_type::priv::location_): Remove
this as it's now carried by the parent decl_base type.
(array_type_def::subrange_type::subrange_type): Adjust. Take an
environement pointer, a name, an underlying type and a language.
(array_type_def::subrange_type::{g,s}et_underlying_type): Define
new accessors.
(array_type_def::subrange_type::{get_language,
get_pretty_representation, traverse}): Define new member
functions.
(array_type_def::subrange_type::as_string): Add a representation
for Ada.
(equals): Define new overload for array_type_def::subrange_type.
(array_type_def::subrange_type::operator==): Define three new
overloads for decl_base, type_base and subrange_type.
(array_type_def::subrange_type::operator!=): Define new operator.
(get_type_representation): In the overload for array_type_def,
support Ada.
(array_type_def::get_language): Define new member function.
(ir_node_visitor::visit_{begin,end}): Define new overloads for
array_type_def::subrange_type.
* src/abg-reader.cc (build_subrange_type): Adjust documentation.
Support the new 'id', 'name', and 'type-id' properties.
* src/abg-writer.cc (write_array_subrange_type): Define new static
function.
(write_array_type_def): Use the new write_array_subrange_type
function.
* tests/data/test-abidiff/test-PR18166-libtirpc.so.abi: Adjust.
* tests/data/test-annotate/libtest23.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi: Likewise.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test25.xml: Likewise.
2018-02-06 Dodji Seketeli <dodji@redhat.com>
Add newline at end of version string display
* tools/abidiff.cc (main): Add a newline at the end of the version
string line.
* tools/abidw.cc (main): Likewise.
* tools/abipkgdiff.cc (main): Likewise.
* tools/kmidiff.cc (main): Likewise.
2018-01-31 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.2
* configure.ac: Bump version number to 1.2
2018-01-25 Dodji Seketeli <dodji@redhat.com>
Update website for 1.1
* doc/website/mainpage.txt: Update for 1.1.
2018-01-25 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 1.1
* ChangeLog: Automatically update using 'make update-changelog'.
2018-01-25 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.1
* NEWS: Update for 1.1
2018-01-29 Dodji Seketeli <dodji@redhat.com>
Correctly link with pthread
* src/Makefile.am: use -lpthread, not -pthread.
2018-01-18 Dodji Seketeli <dodji@redhat.com>
Skip class types with changed names in leaf reports
* include/abg-comp-filter.h (has_class_or_union_type_name_change)
(has_basic_or_class_type_name_change): Declare new functions.
* include/abg-comparison.h (is_diff_of_class_or_union_type):
Likewise.
* src/abg-comp-filter.cc (has_class_or_union_type_name_change)
(has_basic_or_class_type_name_change):
* src/abg-comparison.cc
(leaf_diff_node_marker_visitor::visit_begin): Use the new
filtering::has_basic_or_class_type_name_change to test if a basic
or class/union diff type carries a name change. Update comment.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
Adjust.
2018-01-16 Dodji Seketeli <dodji@redhat.com>
Only consider local changes when filtering subtype changes
* src/abg-comparison-priv.h
(class_or_union_diff::priv::{count_filtered_subtype_changed_dm,
count_filtered_changed_dm}): Take an additional flag.
* src/abg-comparison.cc
(class_or_union_diff::priv::{count_filtered_subtype_changed_dm,
count_filtered_changed_dm}): Likewise. When asked, only consider
local changes.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Consider
reporting only the *net local* data member changes.
2018-01-16 Dodji Seketeli <dodji@redhat.com>
Make kmidiff show the wrong option when it complains about it
* tools/kmidiff.cc (parse_command_line): Don't forget to record
the wrong option in options::wrong_option.
2018-01-12 Dodji Seketeli <dodji@redhat.com>
Fix typo in abipkgdiff.cc
* tools/abipkgdiff.cc (compare_task::perform): Fix a typo in a
comment.
2018-01-12 Dodji Seketeli <dodji@redhat.com>
Suppress duplicates when listing package content
* tools/abipkgdiff.cc (maybe_update_package_content): Rename
maybe_update_vector_of_package_content into this. Take a set of
strings, rather than a vector of strings.
(get_interesting_files_under_dir): Adjust.
2018-01-12 Dodji Seketeli <dodji@redhat.com>
Fix symlinks paths handling in abipkgdiff
* include/abg-tools-utils.h (real_path): Declare new function.
* src/abg-tools-utils.cc (real_path): Define it.
* tools/abipkgdiff.cc (package::convert_path_to_relative): Use the
new real_path function to consider real path (where symlinks are
resolved) of the extraction directory of the package.
(get_interesting_files_under_dir): Similarly, use the new
real_path function to consider the real path of the directory we
are exploring.
2018-01-12 Dodji Seketeli <dodji@redhat.com>
Fix logic in common_prefix
* src/abg-tools-utils.cc (common_prefix): Fix logic error.
2018-01-12 Dodji Seketeli <dodji@redhat.com>
abipkgdiff --verbose shouldn't trigger --fail-no-dbg
* tools/abipkgdiff.cc (compare): In the overload for elf_files,
separate the effect of --verbose from the one of --fail-no-dbg.
2018-01-10 Dodji Seketeli <dodji@redhat.com>
Bug 22692 - Consider Java as a language that supports the ODR
* include/abg-ir.h (is_java_language): Declare new function.
* src/abg-dwarf-reader.cc (odr_is_relevant): Adjust to consider
that Java also respects the ODR.
* src/abg-ir.cc (is_java_language): Define new function.
(odr_is_relevant): Adjust to consider that Java also respects the
ODR.
2018-01-09 Dodji Seketeli <dodji@redhat.com>
Fix version revision number printing in tools --help option
* configure.ac: Properly set the VERSION_REVISION macro.
* include/abg-tools-utils.h (get_library_version_string): Declare
new function.
* src/abg-tools-utils.cc (get_library_version_string): Define the
new function.
(gen_suppr_spec_from_kernel_abi_whitelist): Dis-ambiguate the use
of the 'config' type.
* tools/abicompat.cc (main): Use the new
abigail::tools_utils::get_library_version_string function.
* tools/abidiff.cc (main): Likewise.
* tools/abidw.cc (main): Likewise.
* tools/abilint.cc (main): Likewise.
* tools/abipkgdiff.cc (main): Likewise.
* tools/abisym.cc (main): Likewise.
* tools/kmidiff.cc (main): Likewise.
2018-01-09 Dodji Seketeli <dodji@redhat.com>
Bug 22684 - Add --d{1,2} options to kmidiff
* doc/manuals/kmidiff.rst: Add documentation for the new options.
* tools/kmidiff.cc (options::{di_root_path{1,2}): New data
members.
(display_usage): Add help strings for the new options.
(parse_command_line): Parse the new options.
(main): Pass the debug info root directory to
build_corpus_group_from_kernel_dist_under.
2018-01-08 Dodji Seketeli <dodji@redhat.com>
Update copyright notice for all source files
* update-copyright.sh: New sed-based script to update the year
in the copyright notice.
* include/abg-comp-filter.h: Updated the year in the copyright
notice.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-interned-str.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-libzip-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-reporter.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-suppression.h: Likewise.
* include/abg-tools-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-workers.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison-priv.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus-priv.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-default-reporter.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-internal.h: Likewise.
* src/abg-ir-priv.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-leaf-reporter.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-libzip-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-reporter-priv.cc: Likewise.
* src/abg-reporter-priv.h: Likewise.
* src/abg-sptr-utils.cc: Likewise.
* src/abg-suppression-priv.h: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-abicompat.cc: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-types-stability.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tests/test-write-read-archive.cc: Likewise.
* tools/abiar.cc: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
* tools/kmidiff.cc: Likewise.
2017-12-15 Dodji Seketeli <dodji@redhat.com>
Bug 22437 - Make fedabipkgdiff use all debug info RPMs of a sub-RPM
* tools/fedabipkgdiff (RPM::get_all_debuginfo_rpms): Define new
member function.
(RPM::generate_comparison_halves): The ancillary debuginfo RPM of
a given RPM now has a list type; there can be more than one
debuginfo RPM associated to a given RPM, especially if the RPM is
a devel one.
(format_debug_info_pkg_options): Define new function.
(abipkgdiff): Use the new function above.
2017-12-15 Dodji Seketeli <dodji@redhat.com>
Improve comments wording in fedabipkgdiff
* tools/fedabipkgdiff (class RPM): Fix wording.
(RPM::__init__): Likewise.
2017-12-11 Dodji Seketeli <dodji@redhat.com>
Update & cleanup the tools manuals summary
* doc/manuals/abidw.rst: Use the same header structure as or the
other tools manual.
* doc/manuals/kmidiff.rst: Likewise.
* doc/manuals/libabigail-tools.rst: Add the new kmidiff tool to
the summary.
2017-12-01 Dodji Seketeli <dodji@redhat.com>
Bug 22488 - Make abipkgdiff handle different binaries with same basename
* include/abg-tools-utils.h (string_suffix)
(sorted_strings_common_prefix): Declare new functions.
(dir_name): Take a new keep_separator_at_end parameter at the end.
* src/abg-tools-utils.cc (dir_name): Take a new
keep_separator_at_end parameter at the end. Add a comment for it
and update.
(string_suffix, sorted_strings_common_prefix): Define new
functions.
(common_prefix): Define new static function.
* tools/abipkgdiff.cc (get_interesting_files_under_dir): Forward
declare this pre-existing static function.
(package::{common_paths_prefix_, elf_file_paths_}): New data
members.
(package::{common_paths_prefix, elf_file_paths,
convert_path_to_relative, convert_path_to_unique_suffix,
load_elf_file_paths}): New member functions.
(create_maps_of_package_content): Use the new
package::{load_elf_file_paths, convert_path_to_unique_suffix}
functions.
(compare_prepared_userspace_packages): Show relative paths of
package elements in reported.
* tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64--dbus-glib-0.104-3.fc23.armv7hl-report-0.txt:
Update test ouptut.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64-self-report-0.txt:
Likewise.
2017-12-01 Dodji Seketeli <dodji@redhat.com>
Fully report diagnostic about alternate debug info file not found
* src/abg-dwarf-reader.cc (status_to_diagnostic_string): Report
textual diagnostic for the STATUS_ALT_DEBUG_INFO_NOT_FOUND case
too.
2017-11-27 Dodji Seketeli <dodji@redhat.com>
Bug 22436 - make abipkgdiff accept several debuginfo packages
* doc/manuals/abipkgdiff.rst: Document the fact that --d{1,2} can
be provided several times on the command line.
* tools/abipkgdiff.cc (options::debug_packages{1,2}): Rename the
debug_package{1,2} data members into this, and make them be vector
of strings, rather than just strings.
(package::debug_info_packages_): Renamed
package::debug_info_package_ into this and make it be a vector of
package_sptr, rather than just a package_sptr.
(package::debug_info_packages): Renamed the method
package::debug_info_package into this and -- for the getter
overload -- make it return a vector of package_sptr, rather than
just a package_sptr. Likewise for the setter overload. Add a
non-const getter overload.
(package::erase_extraction_directories)
(extract_package_and_map_its_content): Adjust.
(extract_rpm, extract_deb): Do not erase the content of the
extraction directory (if it was pre-existing) prior to extracting
the RPM/deb into it.
(pkg_extraction::pkgs): Renamed pkg_extraction::pkg into this and
make it be a vector of packages, rather than just a package.
(pkg_extraction::pkg_extraction): Adjust to take a package_sptr
rather than just a package. Add an overload to take a vector of
packages_sptr.
(pkg_extraction::perform): Extract the vector of package that the
task is not responsible for, not just one random package.
(extract_package_and_map_its_content): Adjust.
(prepare_packages): Take smart pointers to package rather than
just packages. Adjust accordingly.
(compare_prepared_package): Make the overload that takes two
packages to take two smart pointers of packages.
(compare): Make the overload that takes two package take two
package_sptr.
(parse_command_line): Parse having --d{1,2} several times for a
given input package.
(main): Take several debug info packages for one input file.
* include/abg-tools-utils.h (split_string): Declare ...
* src/abg-tools-utils.cc (split_string): ... new function.
* tests/data/test-diff-pkg/libxfce4ui-debuginfo-4.12.1-8.fc27.ppc64.rpm:
Add a new RPM test input file.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64-self-report-ok-0.txt:
new reference output file.
* tests/data/Makefile.am: Add the new test input files above to source
distribution.
* tests/test-diff-pkg.cc (in_out_spec): Add new test entry to
specify two debug info packages for one input package.
(test_task::perform): Support having several debug info package
paths in the IntOutSpec::{first,second}_in_debug_package_path data
member. The debug info packages paths are separated by either a
white space or commas.
2017-11-22 Dodji Seketeli <dodji@redhat.com>
Update version number to 1.1
* configure.ac: Update version number to 1.1
2017-11-22 Dodji Seketeli <dodji@redhat.com>
Bug 22076 - Disable fedabipkgdiff for old koji clients
* configure.ac: Try to invoke the koji.read_config method. If it
fails then disable the fedabipkgdiff feature.
2017-11-22 Dodji Seketeli <dodji@redhat.com>
Update the release text template after 1.0
* release-text-template.txt: Update some wording.
2017-11-22 Dodji Seketeli <dodji@redhat.com>
Update website for 1.0
* doc/website/mainpage.txt: Update after 1.0 release.
2017-11-21 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.0
* NEWS: Update for 1.0
2017-11-21 Dodji Seketeli <dodji@redhat.com>
Automatically Update ChangeLog for 1.0
* ChangeLog: Automatically update for 1.0
2017-11-21 Dodji Seketeli <dodji@redhat.com>
Bug 22438 - Emit a clear message when debug info is not found
* include/abg-dwarf-reader.h (enum abigail::dwarf_reader::status):
Add a new STATUS_ALT_DEBUG_INFO_NOT_FOUND enumerator there.
(refers_to_alt_debug_info): Declare new function.
* src/abg-dwarf-reader.cc (read_corpus_from_elf): Detect when the
referred-to alternate debug info file is not found and flip the
STATUS_ALT_DEBUG_INFO_NOT_FOUND bit of the status accordingly. If
the debug info was found but not the alternate debug info, then do
not try to read the debug info at all.
(refers_to_alt_debug_info): Define new function.
* tools/abidiff.cc (handle_error): Define new static function.
(main): Use it, rather than handling errors preventing libabigail
from reading the corpus on a case by case basis.
tools/abipkgdiff.cc (compare): Handle the case where no alternate
debug info was found.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64-self-report-0.txt:
New test output reference.
* tests/data/test-diff-pkg/libxfce4ui-devel-4.12.1-8.fc27.ppc64.rpm:
New test input RPM.
* tests/data/test-diff-pkg/libxfce4ui-devel-debuginfo-4.12.1-8.fc27.ppc64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new test files above to source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add a new test case from
the new input files above.
2017-11-13 Dodji Seketeli <dodji@redhat.com>
Support systems where fts.h can't be used with _FILE_OFFSET_BITS set
* configure.ac: Detect if we are on a system where fts.h cannot be
included with _FILE_OFFSET_BITS defined. If that is the case,
then define the BAD_FTS macro.
* src/abg-tools-utils.cc: If BAD_FTS is defined then include fts.h
with _FILE_OFFSET_BITS not defined (that is, before config.h) but
then make sure that open and fopen are 64 bits aware.
* tools/abipkgdiff.cc: Likewise.
2017-11-08 Dodji Seketeli <dodji@redhat.com>
Edit the NEWS file a tiny little bit for 1.0
* NEWS: Cleanup.
2017-11-06 Dodji Seketeli <dodji@redhat.com>
Automatically Update ChangeLog for 1.0
* ChangeLog: Update this file by running "make update-changelog".
2017-11-06 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.0 changes
* NEWS: Update for 1.0 changes
2017-11-06 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.0
* configure.ac: Bump version number to 1.0
2017-11-08 Dodji Seketeli <dodji@redhat.com>
Don't make system headers depend on config.h
* tools/abipkgdiff.cc: Include config.h after system headers and
before libabigail's headers.
2017-11-02 Dodji Seketeli <dodji@redhat.com>
Wire the --no-show-locs option to abidw
* doc/manuals/abidw.rst: Update the documentation.
* tests/test-annotate.cc: Now that --no-show-locs has an effect on
the ABIXML output, let's not use it here, because it changes the
output and we don't want that.
* tools/abidw.cc (display_usage): Fix a typo in the help string.
(load_corpus_and_write_abixml): Set the "show-locs" option to the
write_context object that we use.
2017-11-02 Dodji Seketeli <dodji@redhat.com>
Allow setting options to instances of xml_writer::write_context
* include/abg-writer.h (create_write_context, set_show_locs)
(set_annotate): Declare new functions.
(write_corpus, write_corpus_group): Remove the output stream and
the annotate parameters as these can be retrieved from the
context.
* src/abg-writer.cc (write_context::m_show_locs): New data member.
(write_context::write_context): Initialize it.
(write_context::{get_show_locs, set_show_locs}): Add new member
functions.
(write_location): Take a write_context, rather than an output
stream. From the context, we detect if the user did set the "show
loc" option and act accordingly. Write the second overload in
terms of the first one.
(create_write_context, set_show_locs, set_annotate): Define new
functions.
(write_type_decl, write_qualified_type_def)
(write_pointer_type_def, write_reference_type_def)
(write_array_type_def, write_enum_type_decl, write_typedef_decl)
(write_var_decl, write_function_decl)
(write_class_decl_opening_tag, write_union_decl_opening_tag)
(write_type_tparameter, write_non_type_tparameter)
(write_function_tdecl, write_class_tdecl): Adjust the invocation
of write_location.
(write_corpus, write_corpus_group): Remove the output stream and
the annotate parameters as these can be retrieved from the
context. Adjust.
* tools/abidw.c: (load_corpus_and_write_abixml): Create a
write_context object, set the 'annotate' option to it and use that
object to actually write out the corpus.
2017-11-02 Dodji Seketeli <dodji@redhat.com>
Remove useless vertical space from src/abg-writer.cc
* src/abg-writer.cc (class write_context): Remove useless vertical
space near the end of the class definition.
2017-10-16 Dodji Seketeli <dodji@redhat.com>
Add a --suppressions option to fedabipkgdiff
* tools/fedabipkgdiff (abipkgdiff): If a suppression file was
provided, pass it to the underlying abipkgdiff tool.
(build_commandline_args_parser): Parse the new --suppressions
option.
* docs/manuals/fedabipkgdiff.rst: Add documentation for the new
--suppressions option.
2017-10-16 Dodji Seketeli <dodji@redhat.com>
Handle exceptions when global_config is not yet set in fedabipkgdiff
* tools/fedabipkgdiff: When handling an exception, if the
global_config object is not yet set then just let the exception
through.
2017-10-11 Dodji Seketeli <dodji@redhat.com>
Fix a indentation warning from GCC 7.2.1
* tools/abipkgdiff.cc (compare): In the overload of elf_file, fix
a mis-indentation pointed out by a GCC 7.2.1 warning.
2017-10-11 Dodji Seketeli <dodji@redhat.com>
Cleanup a switch-case logic to avoid a GCC 7.2.1 warning
* src/abg-dwarf-reader.cc (die_qualified_type_name): Cleanup a
switch case to make the form support more what we meant, and shut
down a GCC 7.2.1 warning.
2017-10-09 Mark Wielaard <mark@klomp.org>
Fix -Wmisleading-indentation warning in abg-leaf-reporter.cc.
* src/abg-leaf-reporter.cc (leaf_reporter::report): Fix misleading
indentation.
2017-10-06 Dodji Seketeli <dodji@redhat.com>
Add --impacted-changes option to kmidiff
* doc/manuals/kmidiff.rst: Document the new --impacted-changes
option.
* tools/kmidif.cc (options::show_impacted_interfaces): Add new
data member.
(options::options): Initialize the new data member to false.
(display_usage): Add a description string for the new
--impacted-changes option.
(parse_command_line): Parse the new --impacted-changes option.
(set_diff_context): Update the 'show-impacted-interface' property
accordingly.
2017-10-04 Dodji Seketeli <dodji@redhat.com>
Add --full-impact option to kmidiff
* doc/manuals/kmidiff.rst: Add documentation for the new
--full-impact|-f option.
* tools/kmidiff.cc (options::leaf_changes_only): Add new data
member.
(option::option): Initialize the new data member.
(display_usage): Add a documentation string for the new
--full-impact|-f option.
(parse_command_line): Parse the new --full-impact|-f option.
(set_diff_context): Set the diff context appropriately.
2017-09-18 Dodji Seketeli <dodji@redhat.com>
Add a --leaf-changes-only option to abipkgdiff
* doc/manuals/abipkgdiff.rst: Add documentation for the new
--leaf-change-only, --impacted-interfaces and --full-impact
options.
* tools/abipkgdiff.cc (options::{leaf_changes_only,
show_impacted_interfaces, show_full_impact_report): Add new data
members.
(options::options): Initialize them.
(display_usage): Add help strings for the new --leaf-change-only,
--impacted-interfaces and --full-impact|-f options.
(set_diff_context_from_opts): Set the diff context for the
'leaf-changes-only' and 'show-impacted-interfaces' flags.
(parse_command_line): Parse the --leaf-change-only,
--impacted-interfaces and --full-impact options. Handle the case
where the --linux-kernel-abi-whitelist|-w option is given a
whitelist *package*.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-3.txt:
New test output reference.
* tests/test-diff-pkg.cc (in_out_spec): Compare
data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64.rpm and
data/test-diff-pkg/spice-server-0.12.8-1.el7.x86_64.rpm with the
new --leaf-changes-only and --impacted-interfaces options, using
the new output reference above.
* tests/data/Makefile.am: Add the new test material to source
distribution.
2017-08-02 Dodji Seketeli <dodji@redhat.com>
Initial implementation of a --leaf-changes-only option to abidiff
* doc/manuals/abidiff.rst: Add documentation the new
--leaf-changes-only and --impacted-interfaces options.
* src/abg-leaf-reporter.cc: New file.
* src/Makefile.am: Add the new src/abg-leaf-reporter.cc file to
source distribution.
* include/abg-fwd.h (get_var_size_in_bits)
(function_decl_is_less_than): Declare new functions.
(get_name): Add new overload for type_or_decl_base*.
* include/abg-ir.h (struct type_or_decl_hash, type_or_decl_equal)
(type_or_decl_base_comp): Define new types.
(artifact_sptr_set_type, artifact_ptr_set_type): Define new
typedefs.
* include/abg-comp-filter.h: Update copyright year.
(has_basic_type_name_change): Add new function declaration.
* src/abg-comp-filter.cc (decl_name_changed): Take a
type_or_decl_base rather than just a decl. Add an overload for
diff*.
(has_basic_type_name_change): Define new function.
* include/abg-comparison.h: Update copyright year.
(string_diff_ptr_map): Define this new typedef.
(class diff_maps): Define this new class.
(diff_context::{set_corpora}): Remove this member function.
(diff_context::{set_corpus_diff, get_corpus_diff,
show_leaf_changes_only, show_impacted_interfaces,
forbid_visiting_a_node_twice_per_interface}): Declare these new
member functions.
(diff_node_visitor::priv_): Add a new pimpl data member.
(diff_node_visitor::{diff_node_visitor, get_visiting_kind,
set_visiting_kind}): Turn these into out-of-line member functions.
(diff_node_visitor::{set,get}_current_topmost_iface_diff): Add new
member functions.
(class {scope_diff, function_type_diff, corpus_diff}): Add class
leaf_reporter as a friend.
(corpus_diff::mark_leaf_diff_nodes, get_leaf_diffs): Declare new
member functions.
(diff::{visiting_a_node_twice_is_forbidden_per_interface,
parent_interface_node}): Define new member functions.
(is_diff_of_basic_type): Return a type_decl_diff* rather than just
a bool.
(is_enum_diff, is_array_diff, is_function_type, is_typedef_diff)
(is_corpus_diff): Declare new functions.
(corpus_diff::diff_stats::{num_leaf_changes,
num_leaf_changes_filtered_out, net_num_leaf_changes}): Add new
member functions.
(is_distinct_diff): Declare new function.
* include/abg-reporter.h: Forward-declare "class diff_maps".
(reporter_base::diff_to_be_reported): Declare a new virtual member
function.
(reporter_base::{report_local_typedef_changes,
report_local_reference_type_changes,
report_local_function_type_changes}): Declare new member
functions.
(class leaf_reporter): Define new type.
* src/abg-comparison-priv.h (struct diff_hash, diff_equal): Define
new types.
(diff_artifact_set_map_type): Define new typedef.
(diff_context::priv::{first_corpus_, second_corpus_}): Remove
these data members.
(diff_context::priv::{corpus_diff_, leaf_changes_only_,
reset_visited_diffs_for_each_interface_,
show_impacted_interfaces_}): Add new data members.
(diff_context::priv::priv): Adjust.
(corpus_diff::priv::{leaf_diffs_, parent_interface_}): Add new
data member.
(corpus_diff::diff_stats::priv::{num_leaf_changes,
num_leaf_changes_filtered_out}): Add new data members.
(corpus_diff::priv::count_leaf_changes): Define new member
function.
(sort_artifacts_set, get_fn_decl_or_var_decl_diff_ancestor)
(is_diff_of_global_decls): Declare new functions.
(function_comp::operator()): Factorize this out into the new
function abigail::ir::function_decl_is_less_than.
* src/abg-ir.cc (get_var_size_in_bits)
(function_decl_is_less_than): Define new functions.
(get_name): Define new overload for type_or_decl_base*.
* src/abg-comparison.cc (is_enum_diff, is_typedef_diff)
(is_array_diff, is_function_type_diff, is_corpus_diff)
(is_distinct_diff, sort_artifacts_set, is_diff_of_global_decls):
Define new functions.
(is_union_diff): Fix comment.
(diff_context::forbid_visiting_a_node_twice_per_interface): Define
new member functions.
(diff_context::set_corpus_diff, get_corpus_diff)
(diff_context::show_leaf_changes_only)
(diff_context::visiting_a_node_twice_is_forbidden_per_interface)
(diff_context::show_impacted_interfaces): Define new member
functions.
(diff_context::get_reporter): Create the reporter that matches
what diff_context::show_leaf_changes_only says.
(diff_node_visitor::priv): Define a new type.
(diff_node_visitor::{diff_node_visitor, get_visiting_kind,
set_visiting_kind, or_visiting_kind,
set_current_topmost_iface_diff, get_current_topmost_iface_diff}):
Define new out-of-line member functions.
(struct diff_maps::priv): Define new type.
(diff_maps::{diff_maps, get_type_decl_diff_map,
get_type_decl_diff_map, get_enum_diff_map, get_class_diff_map,
get_union_diff_map, get_typedef_diff_map, get_array_diff_map,
get_function_type_diff_map, get_function_decl_diff_map,
get_var_decl_diff_map, get_reference_diff_map,
get_fn_parm_diff_map, get_distinct_diff_map, insert_diff_node,
lookup_impacted_interfaces}): Define member functions.
(corpus_diff::{mark_leaf_diff_nodes, get_leaf_diffs}): Define new
member functions.
(struct leaf_diff_node_marker_visitor): Define new type.
(corpus_diff::apply_filters_and_suppressions_before_reporting):
Mark diff nodes in here.
(corpus_diff::traverse): Appropriately set the current topmost
interface into the visitor before visiting a diff node.
(compute_diff): In the overload for corpus_sptr, adjust to reflect
that we are now storing the corpus_diff in the diff context.
(is_diff_of_basic_type): Return a type_decl_diff*, not just a
bool.
(corpus_diff::priv::count_leaf_changes): Define a new member
function.
(corpus_diff::diff_stats::{num_leaf_changes,
num_leaf_changes_filtered_out, net_num_leaf_changes}): Define new
member functions.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Use the
new corpus_diff::priv::count_leaf_changes to compute the number of
leaf changes.
(corpus_diff::priv::emit_diff_stats): Emit the report about leaf
type changes when necessary.
* src/abg-reporter-priv.h (report_mem_header): Declare new
overload.
(maybe_show_relative_offset_change,): Pass the var_diff_sptr
parameter by const reference.
(represent): Pass the var_diff_sptr parameter by const reference
and take a new "local-only" flag.
(maybe_show_relative_size_change)
(maybe_report_interfaces_impacted_by_diff): Declare new functions.
* src/abg-default-reporter.cc: Adjust copyright year.
(default_reporter::{report_local_typedef_changes,
report_local_qualified_type_changes,
report_local_reference_type_changes,
report_local_function_type_changes}): Define new member functions.
(default_reporter::report): Adjust. Add an overload for
function_type_diff&. In the overload for qualified_type_diff, if
the name of the underlying type changed, do not detail the changes
any further. In the overload for function_decl_diff, Adjust to
use the new diff_context::get_{first, second}_corpus member
function. In the overload for enum_diff, call the new
maybe_report_interfaces_impacted_by_diff that is advertised below.
* src/abg-reporter-priv.cc (represent): Adjust the overload for
var_diff_sptr.
(report_mem_header): Define new overload.
(maybe_show_relative_size_change)
(maybe_report_interfaces_impacted_by_diff): Define new functions.
(reporter_base::diff_to_be_reported): Define new member function.
(maybe_show_relative_offset_change): Pass the var_diff_sptr
parameter by const reference.
(represent): In the overload for var_diff_sptr, pass the
var_diff_sptr parameter by reference. Take a 'local_only' flag.
Iisplay type changes only if we are not displaying "local changes
only". Display size changes of data members too, when in
"local-only" mode.
* src/abg-suppression.cc (sonames_of_binaries_match)
(names_of_binaries_match): Adjust.
* tools/abidiff.cc (options::{leaf_changes_only,
show_impacted_interfaces}): Add new data members.
(display_usage): Emit usage string for the new --leaf-changes-only
and --impacted-interfaces options.
(parse_command_line): Parse the new --leaf-changes-only and the
--impacted-interfaces options.
(set_diff_context_from_opts): Set the 'show-leaf-changes' and the
'show-impacted-interfaces' flags.
* tests/data/test-diff-filter/libtest42-leaf-report-v{0,1}.so: New
test input.
* tests/data/test-diff-filter/test42-leaf-report-output-0.txt: New
test reference output.
* tests/data/test-diff-filter/test42-leaf-report-v{0,1}.cc: Source
code of the new test inputs.
* tests/test-diff-filter.cc (in_out_specs): Use the new test
inputs above in this harness.
* tests/data/test-diff-suppr/libtest35-leaf-v0.so: New test input.
* tests/data/test-diff-suppr/test35-leaf-report-0.txt: New test
reference output.
* tests/data/test-diff-suppr/test35-leaf-v{0,1}.cc: Source code of
the new test inputs.
* tests/data/test-diff-suppr/test35-leaf.suppr: Suppression
specification to use for the test35 test.
* tests/data/test-diff-suppr/libtest36-leaf-v0.so: New test input.
* tests/data/test-diff-suppr/libtest36-leaf-v1.so: Likewise.
* tests/data/test-diff-suppr/test36-leaf-report-0.txt: New
reference test output.
* tests/data/test-diff-suppr/test36-leaf-v0.cc: Source code of
test input above.
* tests/data/test-diff-suppr/test36-leaf-v1.cc: Likewise.
* tests/test-diff-suppr.cc (in_out_specs): Use the new test inputs
above in this harness.
* tests/data/Makefile.am: Add the new test inputs above to source
distribution.
2017-07-17 Dodji Seketeli <dodji@redhat.com>
Allow several kinds of reports to be emitted
* include/Makefile.am: Add the new abg-reporter.h header file to
source distribution.
* include/abg-comparison.h: Include the new abg-reporter.h header
file.
(diff_context::{g,s}et_reporter): Declare new accessors.
({type_diff_base, decl_diff_base, corpus_diff}::priv): Make this
be a struct rather than a class.
({decl_diff_base, class_diff, scope_diff, function_type_diff,
corpus_diff}): Declare default_reporter a friend class of these.
* include/abg-reporter.h: New file.
* src/Makefile.am: Add abg-comparison-priv.h,
abg-reporter-priv.{h,cc} and abg-default-reporter.cc files to
source distribution.
* src/abg-comparison-priv.h: New file.
* src/abg-comparison.cc (sort_enumerators)
(sort_changed_enumerators, sort_data_members)
(sort_string_function_ptr_map)
(sort_string_function_decl_diff_sptr_map)
(sort_string_var_diff_sptr_map, sort_string_elf_symbol_map)
(sort_string_var_ptr_map, sort_string_data_member_diff_sptr_map)
(sort_unsigned_data_member_diff_sptr_map)
(sort_string_diff_sptr_map, sort_string_base_diff_sptr_map)
(sort_string_base_sptr_map, sort_string_fn_parm_diff_sptr_map)
(sort_string_parm_map, get_leaf_type, sort_enumerators)
(sort_changed_enumerators): Make these functions non-static and
move them at the beginning of the file. These functions are now
declared in abg-compared-priv.h so they can be shared privately
with other files in src/.
(diff_context::{g,s}et_reporter): Define new accessors.
({diff_context, diff, type_diff_base, decl_diff_base,
distinct_diff, pointer_diff, array_diff, reference_diff,
qualified_type_diff, enum_diff, class_or_union_diff, class_diff,
base_diff, scope_diff, fn_parm_diff, function_type_diff,
function_decl_diff, type_decl_diff, typedef_diff,
translation_unit_diff, corpus_diff::diff_stats,
corpus_diff}::priv)
(diff_less_than_functor, enumerator_value_comp)
(changed_enumerator_comp, base_spec_comp, base_diff_comp)
(data_member_diff_comp, diff_comp, fn_parm_diff_comp, parm_comp)
(elf_symbol_comp, function_comp, function_decl_diff_comp)
(var_diff_sptr_comp): Move these type definitions to
abg-comparison-priv.h
(report_size_and_alignment_changes, report_loc_info)
(maybe_report_diff_for_member, maybe_report_diff_for_symbol)
(represent, represent_data_member)
(maybe_show_relative_offset_change, represent)
(report_size_and_alignment_changes, report_loc_info)
(report_name_size_and_alignment_changes, report_mem_header)
(maybe_report_diff_for_member, maybe_report_diff_for_symbol)
(show_linkage_name_and_aliases): Move these definitions to
abg-reporter-priv.cc.
({distinct_diff, var_diff, pointer_diff, array_diff,
reference_diff, qualified_type_diff, enum_diff,
class_or_union_diff, class_diff, base_diff, union_diff,
scope_diff, fn_parm_diff, function_type_diff, type_decl_diff,
typedef_diff, corpus_diff}::report): Use the reporter object to
report about the changes carried by the the current diff node.
* src/abg-default-reporter.cc: New file.
* src/abg-reporter-priv.h: Likewise.
2017-10-04 Dodji Seketeli <dodji@redhat.com>
Update copyright year to tools/abidiff.cc
* tools/abidiff.cc: Update copyright year.
2017-10-04 Dodji Seketeli <dodji@redhat.com>
Add missing comment to type declaration
* include/abg-comparison.h (struct diff_sptr_hasher): Add missing
comment.
2017-10-04 Dodji Seketeli <dodji@redhat.com>
Misc style fixes in abg-writer.cc
* src/abg-writer.cc (type_hasher): Add comment.
(write_context::record_decl_as_emitted): Remove useless newline.
2017-10-04 Dodji Seketeli <dodji@redhat.com>
Initialize naked canonical type
* src/abg-ir.cc (type_base::priv::priv): Initialize the naked
canonical type data member.
2017-10-04 Dodji Seketeli <dodji@redhat.com>
[abixml writer] Use an unordered set when appropriate
* src/abg-writer.cc (write_context::m_emitted_decl_only_set):
Renamed m_emitted_decl_only_map into this and make the type be a
set, rather than a map.
(write_context::{record_decl_only_type_as_emitted,
decl_only_type_is_emitted}): Adjust.
2017-09-29 Dodji Seketeli <dodji@redhat.com>
[abixml writer] Store pointers to emitted types rather than type-ids
* src/abg-writer.cc (type_ptr_set_type): Declare new typedef.
(writer_context::m_emitted_type_id_map): Remove this data member.
(writer_context::m_emitted_type_set): Add a new data member.
(writer_context::{record_type_id_as_emitted, type_id_is_emitted,
clear_emitted_types_map}): Remove these member functions.
(writer_context::{record_type_as_emitted, type_is_emitted}): Use
the new m_emitted_type_set data member above.
2017-09-27 Dodji Seketeli <dodji@redhat.com>
Use an unordered map for canonical DIE offsets
* src/abg-dwarf-reader.cc
(read_context::canonical_type_die_offsets_): Renamed the
canonical_type_die_vecs_ data member into this.
(read_context::canonical_decl_die_offsets_): Renamed the
canonical_decl_die_vecs_ data member into this.
(read_context::{initialize, compute_canonical_die_offset,
compute_canonical_die, get_canonical_die,
get_or_compute_canonical_die, set_canonical_die_offset,
get_canonical_die_offset}): Adjust.
2017-09-27 Dodji Seketeli <dodji@redhat.com>
Bug 22190 - crash in read_context::get_or_compute_canonical_die
* src/abg-dwarf-reader.cc: get_or_compute_canonical_die
2017-09-27 Dodji Seketeli <dodji@redhat.com>
Remove redundant (useless) typedef declaration
* src/abg-dwarf-reader.cc (dwarf_offsets_type): There are two
instances of this typedef declaration, remove one.
2017-09-27 Dodji Seketeli <dodji@redhat.com>
Renamed offset_offset_map type name into offset_offset_map_type
* src/abg-dwarf-reader.cc (offset_offset_map_type): Renamed
offset_offset_map into this.
(read_context::{primary_die_parent_map_,
alternate_die_parent_map_, type_section_die_parent_map_}): Adjust
the type of these data members.
(read_context::{die_parent_map, type_section_die_parent_map}):
Adjust the type of these member functions.
(read_context::{build_die_parent_relations_under,
get_parent_die}): Adjust for the type name in these functions.
2017-09-27 Dodji Seketeli <dodji@redhat.com>
Add missing newlines to kmidiff's usage strings
* tools/kmidiff.cc (display_usage): Add newlines after the lines
for --vmlinux1 and --vmlinux2.
2017-09-21 Dodji Seketeli <dodji@redhat.com>
22160 - Annotate state flag unitialized in abidw
* tools/abidw.cc (options::options): Initialize the annotate data
member.
2017-09-18 Dodji Seketeli <dodji@redhat.com>
Don't crash on classes that differ in their virtual member fn count
* src/abg-ir.cc (equals): In the overload for class_decl, when we
detect that the virtual member function counts are different, get
out, even when we are being asked about the kind of the change.
2017-09-18 Dodji Seketeli <dodji@redhat.com>
Avoid adding the same data member twice in the DWARF reader
* src/abg-dwarf-reader.cc (add_or_update_class_type): After a we
try to create a data member type, look *again* if the data member
wasn't added recursively by the creation of the data member type.
2017-09-11 Mark Wielaard <mark@klomp.org>
Bug 22075 - data_member_diff_comp forgets data members names
* src/abg-comparison.cc (data_member_diff_comp): Make the
comparison take the qualified name of the data member into
account. Also, if the initial offset and qualified names of the
data members of the diff nodes are equal, consider the offset and
qualified names of the new data members.
2017-09-11 Dodji Seketeli <dodji@redhat.com>
Bug 22122 - Fail to represent 'const array'
* src/abg-dwarf-reader.cc (die_is_array_type): Define new static
function.
(die_is_pointer_or_reference_type): Also test that the DIE can be
an array.
* tests/data/test-read-dwarf/PR22122-libftdc.so: New binary test input.
* tests/data/test-read-dwarf/PR22122-libftdc.so.abi: New reference output.
* tests/data/Makefile.am: Add the two new test files above to
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Run this test harness
over the new test input.
2017-09-08 Dodji Seketeli <dodji@redhat.com>
Finer detection of local changes of var_decl type
* src/abg-ir.cc (equals): In the var_decl overload detect size
changes of type as being a local change.
2017-09-08 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-fwd.h (get_pretty_representation): Add missing white
space.
* src/abg-ir.cc (get_name): Fix typo in comment.
2017-09-02 Mark Wielaard <mark@klomp.org>
readdir_r() is deprecated, use readdir().
* src/abg-tools-utils.cc (dir_is_empty): Use readdir() instead
of readdir_r().
2017-09-02 Mark Wielaard <mark@klomp.org>
Declare eval_last_constant_dwarf_sub_expr with [u]int64_t not [s]size_t.
* src/abg-dwarf-reader.cc (eval_last_constant_dwarf_sub_expr):
Declare expr_len as uint64_t and value as int64_t.
2017-08-28 Dodji Seketeli <dodji@redhat.com>
Bug 22015 - Failing to return global scope of a DIE in certain cases
* src/abg-dwarf-reader.cc (get_scope_for_die): If the translation
unit of the parent die hasn't yet been constructed, then return
the global scope of the current translation unit.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so: New
binary test input.
* tests/data/test-read-dwarf/PR22015-libboost_iostreams.so.abi:
New reference test output.
* tests/data/Makefile.am: Add the new test materials above to
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the new test input
to the test suite.
2017-07-17 Dodji Seketeli <dodji@redhat.com>
Fix some make distcheck failures
* tests/data/Makefile.am: Add
test-diff-dwarf/test42-PR21296-libgcc.so,
test-diff-dwarf/test42-PR21296-libclang.so,
test-diff-dwarf/test42-PR21296-clanggcc-report0.txt to the source
distribution. Also look for test-diff-filter/test39* tests inputs
in the test-diff-filter/test39/ directory.
2017-07-17 Dodji Seketeli <dodji@redhat.com>
Avoid crashing when the elf file could not be read
* src/abg-dwarf-reader.cc
(read_context::elf_architecture_is_ppc64): Do not crash if the elf
handle is nil.
2017-07-10 Dodji Seketeli <dodji@redhat.com>
Bug 21730 - Make abipkgdiff compare Linux Kernel packages as expected
* include/abg-tools-utils.h (get_vmlinux_path_from_kernel_dist):
Declare new function.
(get_binary_paths_from_kernel_dist): Re-organize order of
parameters.
(file_is_kernel_package, file_is_kernel_debuginfo_package): Make
the file_path parameter be const.
(build_corpus_group_from_kernel_dist_under): Take an additional
debug_info_root parameter.
* src/abg-tools-utils.cc (file_is_kernel_package)
(file_is_kernel_debuginfo_package): Const-ify the file_name
parameter.
(find_vmlinux_path): Define new static function.
(get_binary_paths_from_kernel_dist): Re-organize the order of
parameters. The debug_info_root_path parameter is now an input
parameter.
(get_vmlinux_path_from_kernel_dist): Define new function.
(get_binary_paths_from_kernel_dist): Adjust invocation of
get_binary_paths_from_kernel_dist.
(build_corpus_group_from_kernel_dist_under): Take an additional
debug_info_root parameter.
* tools/abidw.cc (load_kernel_corpus_group_and_write_abixml):
Adjust invocation to build_corpus_group_from_kernel_dist_under.
* tools/abipkgdiff.cc (create_maps_of_package_content): Don't map
the content of a Linux Kernel package.
(compare_prepared_userspace_packages)
(compare_prepared_linux_kernel_packages, compare_prepared): Define
new functions.
(compare): Use the new functions above here.
* tools/kmidiff.cc (print_kernel_dist_binary_paths_under): Adjust
the invocation of get_binary_paths_from_kernel_dist.
(main): Adjust the invocation of
build_corpus_group_from_kernel_dist_under. Make sure that a
kernel package is accompanied by a debug info package.
2017-07-11 Dodji Seketeli <dodji@redhat.com>
Support up to two --wp options for abipkgdiff
* doc/manuals/abipkgdiff.rst: Update the documentation to say that
--wp can be provided twice, but not more than that.
* tools/abipkgdiff.cc (options::kabi_whitelist_packages): Rename
kabi_whitelist_package to this, and make be of vector<string>
type.
(package::erase_extraction_directories): Erase the white list
package extracted data.
(maybe_handle_kabi_whitelist_pkg, parse_command_line): Adjust.
(main): Make sure there is no more than 2 --wp on the command
line. Associate a white list package to each kernel package on
the command line.
2017-07-11 Dodji Seketeli <dodji@redhat.com>
Fix support of the --wp option of abipkgdiff
* tools/abipkgdiff.cc (parse_command_line): Consider the absolute
path of the package given in argument to --wp.
2017-07-11 Dodji Seketeli <dodji@redhat.com>
Use shorter lines in abipkgdiff.cc
* tools/abipkgdiff.cc (parse_command_line): Use shorter lines
here.
2017-07-11 Dodji Seketeli <dodji@redhat.com>
Add missing space in abipkgdiff error message
* tools/abipkgdiff.cc (extract_package): Add missing space here.
2017-07-11 Dodji Seketeli <dodji@redhat.com>
Replace --lkaw with -w and --lkaw-pkg with --wp
* doc/manuals/abipkgdiff.rst: Adjust the documentation.
* tools/abipkgdiff.cc (display_usage): Adjust the usage string.
(parse_command_line): Parse -w instead of --lkaw and --wp
insteadof --lkaw-pkg.
2017-07-11 Dodji Seketeli <dodji@redhat.com>
speed up class type lookup in a corpus
* src/abg-ir.cc (lookup_class_type): In the overload that looks
for a class name denoted by an interned_string in the corpus, do
not look for the class in the translation units when the type
wasn't found in the type map of the corpus.
(maybe_update_types_lookup_map): Remove the
erase_if_exists_already parameter and the code that uses it.
(lookup_class_type_through_translation_units): Remove this
function that is now useless.
2017-07-06 Dodji Seketeli <dodji@redhat.com>
Bug 21644 - abipkgdiff does not emit diagnostics about comparison errors
* include/abg-dwarf-reader.h (status_to_diagnostic_string):
Declare new function.
* src/abg-dwarf-reader.cc (status_to_diagnostic_string): Define
new function.
* tools/abipkgdiff.cc (compare): Take a new detailed_error_status
parameter.
(compare_task::perform): Get the details of the error, in case the
status of the comparison is ABIDIFF_ERROR.
2017-07-05 Dodji Seketeli <dodji@redhat.com>
Bug 21153 - abipkgdiff reports undetermined interface subtype changes
* src/abg-ir.cc (get_name_of_qualified_type): A noop-qualified
type has an empty string as reprsentation for its qualifier.
* src/abg-dwarf-reader.cc (die_qualified_type_name): Adjust to
comply with what is done in get_name_of_qualified_type. Adjust
comment too.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64--libcdio-0.94-2.fc26.x86_64-report.1.txt:
New reference test output.
* tests/data/test-diff-pkg/libcdio-0.94-1.fc26.x86_64.rpm: New
test binary input.
* tests/data/test-diff-pkg/libcdio-0.94-2.fc26.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/libcdio-debuginfo-0.94-1.fc26.x86_64.rpm: Likewise.
* tests/data/test-diff-pkg/libcdio-debuginfo-0.94-2.fc26.x86_64.rpm Likewise.
* tests/data/Makefile.am: Add the new test inputs to source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Make this test harness run on
the new test inputs above.
2017-07-03 Dodji Seketeli <dodji@redhat.com>
Fix typo in comments
* src/abg-ir.cc (type_base::get_canonical_type_for): Fix a typo in
a command.
2017-07-03 Dodji Seketeli <dodji@redhat.com>
Fix a typo when reporting size change wrt a decl-only class
* src/abg-comparison.cc (report_size_and_alignment_changes): Fix
typo.
2017-07-03 Dodji Seketeli <dodji@redhat.com>
Better handle decl-only classes being different from their definition
* src/abg-comparison.cc (function_decl_diff::report): Don't report
possible vtable changes between a decl-only class and its
definition.
* src/abg-ir.cc (type_base::get_canonical_type_for): Consider that
a decl-only class is different from its definition when comparing
types for the purpose of type canonicalization.
(equals): In the class_or_union overload, only consider the global
decl_only_class_equals_definition() property to know when to
consider that a decl-only class is different from its definition
when comparing two classes.
* src/abg-reader.cc (build_class_decl): Read the size property of
a class, even if it's a decl-only class.
* src/abg-writer.cc (write_class_decl_opening_tag): Write size
property of types even if the types are decl-only classes.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2017-06-28 Dodji Seketeli <dodji@redhat.com>
Don't add empty translation unit to corpus
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir):
A translation unit DIE that has no child DIE shall not be added to
the current ABI corpus.
2017-06-27 Dodji Seketeli <dodji@redhat.com>
Bug 21631 - Forgot a "break" statement in stv_to_elf_symbol_visibility
* src/abg-dwarf-reader.cc (stv_to_elf_symbol_visibility): Add a
missing break statement.
2017-06-26 Dodji Seketeli <dodji@redhat.com>
Bug 21630 - A this pointer DIE can be const
* src/abg-dwarf-reader.cc (die_this_pointer_is_const): If the DIE
is not a DW_TAG_pointer_type then don't crash.
2017-06-23 Dodji Seketeli <dodji@redhat.com>
Bug 21629 - equivalent DIEs must be of the same DIE source
* src/abg-dwarf-reader.cc (compare_dies): Don't propagate
a canonical DIE to a DIE that comes from a different source.
2017-06-22 Dodji Seketeli <dodji@redhat.com>
Bug 21627 - Libabigail doesn't consider translation unit compile dir
*if* that translation unit has already been seen in the current
binary, instead of creating a new one altogether.
This patch doesn't carry a regression test as the problem was found
while running the
https://pagure.io/libabigail-selfcheck/blob/master/f/selfcheck.py
script over the Fedora 25 critpath packages.
The patch does however update existing reference outputs of existings
tests where appropriate.
* include/abg-ir.h (translation_unit::{get_compilation_dir_path,
set_compilation_dir_path, get_absolute_path}):
* src/abg-corpus.cc (corpus::add): Use the new
translation_unit::get_absolute_path() as the key for the tu path
-> tu map.
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Use the new
translation_unit::get_absolute_path().
(build_translation_unit_and_add_to_ir): Set the compilation
directory of the translation unit.
* src/abg-ir-priv.h (translation_unit::priv::{comp_dir_path_,
abs_path_}):
* src/abg-ir.cc (translation_unit::set_path): Update comment.
(translation_unit::{get_compilation_dir_path,
set_compilation_dir_path, get_absolute_path}): Define new member
functions.
* src/abg-reader.cc (read_translation_unit): Take the new
'comp-dir-path' attribute into account.
* src/abg-writer.cc (write_translation_unit): Emit the new
'comp-dir-path' attribute.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-annotate/test0.abi: Adjust.
* tests/data/test-annotate/test1.abi: Adjust.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-annotate/test2.so.abi: Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-annotate/test3.so.abi: Adjust.
* tests/data/test-annotate/test4.so.abi: Adjust.
* tests/data/test-annotate/test5.o.abi: Adjust.
* tests/data/test-annotate/test6.so.abi: Adjust.
* tests/data/test-annotate/test7.so.abi: Adjust.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-read-dwarf/test0.abi: Adjust.
* tests/data/test-read-dwarf/test1.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test2.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test3.so.abi: Adjust.
* tests/data/test-read-dwarf/test4.so.abi: Adjust.
* tests/data/test-read-dwarf/test5.o.abi: Adjust.
* tests/data/test-read-dwarf/test6.so.abi: Adjust.
* tests/data/test-read-dwarf/test7.so.abi: Adjust.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2017-05-04 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-dwarf-reader.cc (read_context::{die_wip_classes_map,
die_wip_function_types_map, types_to_canonicalize,
tu_die_imported_unit_points_map, die_parent_map,
load_kernel_symbol_table}): Add missing space to statement.
(get_parent_die): Likewise.
(build_enum_type): Fix typo in comment.
(e_machine_to_string, get_version_definition_for_versym)
(lookup_public_function_symbol_from_elf)
(lookup_public_variable_symbol_from_elf)
(lookup_data_tag_from_dynamic_segment, die_is_declaration_only)
(die_is_reference_type, die_function_type_is_method_type): Fix
indentation.
(read_context::{resolve_declaration_only_classes,
fixup_functions_with_no_symbols,
load_symbol_maps_from_symtab_section, load_dt_soname_and_needed,
load_elf_architecture, load_elf_properties,
maybe_adjust_address_for_exec_or_dyn, maybe_adjust_fn_sym_address,
address_is_in_opd_section, load_elf_architecture,
build_die_parent_maps}): Likewise.
(op_pushes_constant_value, op_manipulates_stack): Use the
dwarf_expr_eval_context::push method.
(op_is_control_flow, die_return_and_parm_names_from_fn_type_die)
(die_function_signature, die_pretty_print_type)
(get_default_array_lower_bound)
(build_translation_unit_and_add_to_ir, build_enum_type)
(add_or_update_class_type, build_function_type)
(build_function_decl, build_ir_node_from_die)
(lookup_public_function_symbol_from_elf): Fix indentation.
* src/abg-ir.cc (maybe_update_types_lookup_map): Remove useless space.
2017-05-31 Dodji Seketeli <dodji@redhat.com>
Fix doc glitch in abidiff.rst
* doc/manuals/abidiff.rst: Fix glitch.
2017-06-12 Dodji Seketeli <dodji@redhat.com>
Symbols with the same zero value are not aliases
* src/abg-dwarf-reader.cc (load_symbol_maps_from_symtab_section):
Do not consider symbols with zero value as being aliases.
* tests/data/test-diff-filter/test20-inline-report-0.txt: Adjust.
* tests/data/test-diff-filter/test20-inline-report-1.txt:
Likewise.
* test-diff-filter/test41-PR21486-abg-writer.gcc.o: New test
binary input.
* tests/data/test-diff-filter/test41-PR21486-abg-writer.llvm.o:
Likewise.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Run the test harness
on the new test input above.
* tests/data/test-diff-dwarf/test5-report.txt: Adjust.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
* tests/data/test-diff-filter/test20-inline-report-0.txt: Adjust.
* tests/data/test-diff-filter/test20-inline-report-1.txt: Adjust.
2017-06-12 Dodji Seketeli <dodji@redhat.com>
Support ELF symbol visibility property
* include/abg-ir.h (enum elf_symbol::visibility): Define new enum.
(elf_symbol::{elf_symbol, create}): Take a visibility parameter.
(elf_symbol::{set, get}_visibility): Declare new accessors.
(string_to_elf_symbol_binding): Declare new function.
* src/abg-ir.cc (elf_symbol::priv::visibility_): New data member.
(elf_symbol::priv::priv): Adjust.
(elf_symbol::elf_symbol): Take a visibility parameter.
(elf_symbol::create): Likewise
(elf_symbol::{s,g}et_visibility): Define new accessors.
(elf_symbol::is_public): Adjust.
(operator<<(std::ostream&, elf_symbol::visibility)): Define new
operator.
(string_to_elf_symbol_visibility): Define new function.
* src/abg-dwarf-reader.cc (stv_to_elf_symbol_visibility): Define
new static function.
(lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab, lookup_symbol_from_symtab)
(create_default_var_sym, create_default_fn_sym): Adjust.
* src/abg-reader.cc (read_elf_symbol_binding): Define new
function.
(build_elf_symbol): Adjust.
* src/abg-writer.cc (write_elf_symbol_visibility): Define new
function.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-annotate/test0.abi: Adjust.
* tests/data/test-annotate/test1.abi: Adjust.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test2.so.abi: Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-annotate/test3.so.abi: Adjust.
* tests/data/test-annotate/test4.so.abi: Adjust.
* tests/data/test-annotate/test5.o.abi: Adjust.
* tests/data/test-annotate/test6.so.abi: Adjust.
* tests/data/test-annotate/test7.so.abi: Adjust.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi:
Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-read-dwarf/test0.abi: Adjust.
* tests/data/test-read-dwarf/test1.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test2.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-read-dwarf/test3.so.abi: Adjust.
* tests/data/test-read-dwarf/test4.so.abi: Adjust.
* tests/data/test-read-dwarf/test5.o.abi: Adjust.
* tests/data/test-read-dwarf/test6.so.abi: Adjust.
* tests/data/test-read-dwarf/test7.so.abi: Adjust.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-write/test26.xml: Adjust.
* tests/data/test-read-write/test27.xml: Adjust.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Adjust.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Adjust.
2017-06-09 Dodji Seketeli <dodji@redhat.com>
Filter top cv qualifier changes on function parameter types
* include/abg-comparison.h (enum diff_category): Add a new
FN_PARM_TYPE_TOP_CV_CHANGE_CATEGORY enumerator. "Or" the
enumerator to the EVERYTHING_CATEGORY enumerator.
* src/abg-comp-filter.cc (has_fn_parm_type_cv_qual_change): Define
new static function.
(categorize_harmless_diff_node): Categorize changes to top cv
qualifiers on function parameter types into the new
FN_PARM_TYPE_TOP_CV_CHANGE_CATEGORY.
* src/abg-comparison.cc (get_default_harmless_categories_bitmap):
Add the new FN_PARM_TYPE_TOP_CV_CHANGE_CATEGORY category to the
set of harmless categories.
(operator<<(ostream&, diff_category)): Adjust to serialize
the new FN_PARM_TYPE_TOP_CV_CHANGE_CATEGORY.
* tests/data/test-diff-filter/libtest40-v0.so: New test input binary.
* tests/data/test-diff-filter/libtest40-v1.so: Likewise.
* tests/data/test-diff-filter/test40-report-0.txt: New test
reference output.
* tests/data/test-diff-filter/test40-v0.cc: Source code of the
test binary above.
* tests/data/test-diff-filter/test40-v1.cc: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add new binaries to
compare.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
2017-05-28 Dodji Seketeli <dodji@redhat.com>
Do not report about voffset when it's not set in debug info
* include/abg-ir.h (mem_fn_context_rel::mem_fn_context_rel):
Initialize the virtual offset to -1.
* src/abg-comparison.cc (represent): In the overload to represent
a method_decl, do not represent the vofffset if it's not set.
* src/abg-writer.cc (write_voffset): The virtual offset is signed
because if it's -1, it means no offset is set.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Adjust.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
2017-05-17 Dodji Seketeli <dodji@redhat.com>
Allow selective resolution of class declaration
* include/abg-fwd.h (type_base_wptrs_type)
(istring_type_base_wptrs_map_type): Define new typedefs.
(lookup_class_types): Declare new functions.
* include/abg-ir.h
(environment::decl_only_class_equals_definition): Declare new
accessor.
(type_maps::{*_types}): Make these accessors return
istring_type_base_wptrs_map_type& instead of
istring_type_base_wptr_map_type&.
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Implement the
new selective declaration resolution scheme.
* src/abg-ir.cc (type_maps::priv::{*_types_}): Change the type of
these data members from istring_type_base_wptr_map_type to
istring_type_base_wptrs_map_type.
(type_maps::{*_types}): Make these accessors definitions return
istring_type_base_wptrs_map_type& instead of
istring_type_base_wptr_map_type&.
(translation_unit::bind_function_type_life_time): Adjust.
(environment::priv::decl_only_class_equals_definition_): New data
member.
(environment::priv::priv): Initialize it. By default, a decl-only
class is now considered different from its definition.
(environment::decl_only_class_equals_definition): Define new
accessor.
(lookup_types_in_map, lookup_class_types): Define new functions.
(lookup_type_in_map, lookup_union_type_per_location)
(lookup_basic_type, lookup_basic_type_per_location)
(lookup_class_type, lookup_class_type_per_location)
(lookup_union_type, lookup_enum_type)
(lookup_enum_type_per_location, lookup_typedef_type)
(lookup_typedef_type_per_location, lookup_qualified_type)
(lookup_pointer_type, lookup_reference_type, lookup_array_type)
(lookup_function_type, maybe_update_types_lookup_map)
(maybe_update_types_lookup_map<class_decl>)
(maybe_update_types_lookup_map<function_type>): Adjust.
(type_base::get_canonical_type_for): When doing type comparison
here, we can now consider that an unresolved class declaration
compares different to an incompatible class definition of the same
name. So no need to look through decl-only classes in that case.
(equals): In the overload for class_or_union, if
environment::decl_only_class_equals_definition() is false, then an
unresolved class declaration of name "N" compares different to a
class definition named "N".
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Adjust.
* tests/data/test-diff-filter/test38/Makefile: New test material.
* tests/data/test-diff-filter/test38/test38-a.c: Likewise.
* tests/data/test-diff-filter/test38/test38-b.c: Likewise.
* tests/data/test-diff-filter/test38/test38-c.c: Likewise.
* tests/data/test-diff-filter/test38/test38-report-0.txt: Likewise.
* tests/data/test-diff-filter/test38/test38-v0: Likewise.
* tests/data/test-diff-filter/test38/test38-v1: Likewise.
* tests/data/test-diff-filter/test38/test38.h: Likewise.
* tests/data/test-diff-filter/test39/Makefile: Likewise.
* tests/data/test-diff-filter/test39/test39-a-v0.c: Likewise.
* tests/data/test-diff-filter/test39/test39-a-v1.c: Likewise.
* tests/data/test-diff-filter/test39/test39-b-v0.c: Likewise.
* tests/data/test-diff-filter/test39/test39-b-v1.c: Likewise.
* tests/data/test-diff-filter/test39/test39-c-v0.c: Likewise.
* tests/data/test-diff-filter/test39/test39-c-v1.c: Likewise.
* tests/data/test-diff-filter/test39/test39-main.c: Likewise.
* tests/data/test-diff-filter/test39/test39-report-0.txt: Likewise.
* tests/data/test-diff-filter/test39/test39-v0: Likewise.
* tests/data/test-diff-filter/test39/test39-v1: Likewise.
* tests/data/test-diff-filter/test39/test39.h: Likewise.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test
inputs above to the test harness.
2017-05-31 Dodji Seketeli <dodji@redhat.com>
Add documentation for the kmidiff tool
* doc/manuals/kmidiff.rst: New doc file.
* doc/manuals/Makefile.am: Add the above file to source
distribution.
2017-05-31 Dodji Seketeli <dodji@redhat.com>
Allow re-using the ELF/DWARF read_context when loading a corpus group
* include/abg-dwarf-reader.h (reset_read_context): Declare new
function.
* src/abg-dwarf-reader.cc (read_context::elf_paths_): Make this to
be non const.
(read_context::initialize): New function to initialize all data
members.
(read_context::read_context): Use the new read_context::initialize
function, rather than initializing data members 'inline' here.
(reset_read_context): Define a new function to reset a
read_context so that it can be re-used to load a new corpus.
2017-05-31 Dodji Seketeli <dodji@redhat.com>
Add --vmlinux{1,2} option to abidw and kmidiff
* include/abg-tools-utils.h
(build_corpus_group_from_kernel_dist_under): Add a new
vmlinux_path parameter.
* src/abg-tools-utils.cc (find_vmlinux_and_module_paths): Do not
try to find a vmlinux binary if we already have the path to one.
(build_corpus_group_from_kernel_dist_under): Add a new
vmlinux_path parameter.
* tools/abidw.cc (options::vmlinux): New data member.
(display_usage): Add a usage string for --vmlinux
(parse_command_line): Parse the new --vmlinux option.
(load_kernel_corpus_group_and_write_abixml): Fix some return code
when the function fails. Verify the presence of the vmlinux
binary that was given. Adjust.
* tools/kmidiff.cc (options::{vmlinux1, vmlinux2}): New data
members.
(display_usage): Add a usage string for --vmlinux1 and --vmlinux2.
(parse_command_line): Parse the --vmlinux1 and --vmlinux2
options.
(main): Adjust.
2017-05-18 Dodji Seketeli <dodji@redhat.com>
Cache function type name computation results
* src/abg-ir.cc (get_type_name): Cache function type names.
2017-05-29 Dodji Seketeli <dodji@redhat.com>
Fix innacurate test condition when reading an enum type from abixml
* src/abg-reader.cc (build_enum_type_decl): Do not check for
errno which might have been set earlier by something else.
Rather, check the returned value for overflow or underflow.
2017-05-28 Dodji Seketeli <dodji@redhat.com>
Do not report about voffset when it's not set in debug info
* include/abg-ir.h (mem_fn_context_rel::mem_fn_context_rel):
Initialize the virtual offset to -1.
* src/abg-comparison.cc (represent): In the overload to represent
a method_decl, do not represent the vofffset if it's not set.
* src/abg-writer.cc (write_voffset): The virtual offset is signed
because if it's -1, it means no offset is set.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Adjust.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
2017-05-18 Dodji Seketeli <dodji@redhat.com>
Speedup DIE representation computing esp function signature in C
* src/abg-dwarf-reader.cc (die_function_signature): For C DIEs,
just return the (linkage) name of the function.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
2017-05-17 Dodji Seketeli <dodji@redhat.com>
Allow selective resolution of class declaration
* include/abg-fwd.h (type_base_wptrs_type)
(istring_type_base_wptrs_map_type): Define new typedefs.
(lookup_class_types): Declare new functions.
* include/abg-ir.h
(environment::decl_only_class_equals_definition): Declare new
accessor.
(type_maps::{*_types}): Make these accessors return
istring_type_base_wptrs_map_type& instead of
istring_type_base_wptr_map_type&.
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Implement the
new selective declaration resolution scheme.
* src/abg-ir.cc (type_maps::priv::{*_types_}): Change the type of
these data members from istring_type_base_wptr_map_type to
istring_type_base_wptrs_map_type.
(type_maps::{*_types}): Make these accessors definitions return
istring_type_base_wptrs_map_type& instead of
istring_type_base_wptr_map_type&.
(translation_unit::bind_function_type_life_time): Adjust.
(environment::priv::decl_only_class_equals_definition_): New data
member.
(environment::priv::priv): Initialize it. By default, a decl-only
class is now considered different from its definition.
(environment::decl_only_class_equals_definition): Define new
accessor.
(lookup_types_in_map, lookup_class_types): Define new functions.
(lookup_type_in_map, lookup_union_type_per_location)
(lookup_basic_type, lookup_basic_type_per_location)
(lookup_class_type, lookup_class_type_per_location)
(lookup_union_type, lookup_enum_type)
(lookup_enum_type_per_location, lookup_typedef_type)
(lookup_typedef_type_per_location, lookup_qualified_type)
(lookup_pointer_type, lookup_reference_type, lookup_array_type)
(lookup_function_type, maybe_update_types_lookup_map)
(maybe_update_types_lookup_map<class_decl>)
(maybe_update_types_lookup_map<function_type>): Adjust.
(type_base::get_canonical_type_for): When doing type comparison
here, we can now consider that an unresolved class declaration
compares different to an incompatible class definition of the same
name. So no need to look through decl-only classes in that case.
(equals): In the overload for class_or_union, if
environment::decl_only_class_equals_definition() is false, then an
unresolved class declaration of name "N" compares different to a
class definition named "N".
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt:
Adjust.
* tests/data/test-diff-filter/test38/Makefile: New test material.
* tests/data/test-diff-filter/test38/test38-a.c: Likewise.
* tests/data/test-diff-filter/test38/test38-b.c: Likewise.
* tests/data/test-diff-filter/test38/test38-c.c: Likewise.
* tests/data/test-diff-filter/test38/test38-report-0.txt: Likewise.
* tests/data/test-diff-filter/test38/test38-v0: Likewise.
* tests/data/test-diff-filter/test38/test38-v1: Likewise.
* tests/data/test-diff-filter/test38/test38.h: Likewise.
* tests/data/test-diff-filter/test39/Makefile: Likewise.
* tests/data/test-diff-filter/test39/test39-a-v0.c: Likewise.
* tests/data/test-diff-filter/test39/test39-a-v1.c: Likewise.
* tests/data/test-diff-filter/test39/test39-b-v0.c: Likewise.
* tests/data/test-diff-filter/test39/test39-b-v1.c: Likewise.
* tests/data/test-diff-filter/test39/test39-c-v0.c: Likewise.
* tests/data/test-diff-filter/test39/test39-c-v1.c: Likewise.
* tests/data/test-diff-filter/test39/test39-main.c: Likewise.
* tests/data/test-diff-filter/test39/test39-report-0.txt: Likewise.
* tests/data/test-diff-filter/test39/test39-v0: Likewise.
* tests/data/test-diff-filter/test39/test39-v1: Likewise.
* tests/data/test-diff-filter/test39/test39.h: Likewise.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test
inputs above to the test harness.
2017-05-04 Dodji Seketeli <dodji@redhat.com>
Avoid de-duplicating different C types that have identical name
* src/abg-dwarf-reader.cc (die_decl_map_type, die_type_map_type):
Remove these typedefs.
(die_artefact_map_type, istring_dwarf_offsets_map_type): New
typedefs.
(die_is_at_class_scope, die_qualified_type_name)
(die_qualified_decl_name, die_qualified_type_name_empty)
(die_return_and_parm_names_from_fn_type_die)
(die_function_type_is_method_type):
Const-ify the read_context& parameter.
(read_context::die_source_dependant_container_set::get_container):
Likewise.
(read_context::{name_artefacts_map_, per_tu_name_artefacts_map_,
die_decl_map_, alternate_die_decl_map_, type_unit_die_decl_map_,
die_type_map_, alternate_die_type_map_, type_unit_die_type_map_}):
Remove data members.
(read_context::{die_decl_map, alternate_die_decl_map,
associate_die_to_decl_primary, associate_die_to_decl_alternate,
associate_die_to_decl_from_type_unit,
lookup_decl_from_die_offset_primary,
lookup_decl_from_die_offset_alternate,
lookup_decl_from_type_unit_die_offset,
lookup_type_artifact_from_die_per_tu,
lookup_artifact_from_per_tu_die_representation,
associate_die_to_artifact_by_repr,
associate_die_to_artifact_by_repr_internal, clear_die_type_maps}):
Remove member functions.
(read_context::{decl_die_repr_die_offsets_maps_,
type_die_repr_die_offsets_maps_, decl_die_artefact_maps_,
type_die_artefact_maps_, dwarf_expr_eval_context_}): Add new data
members.
(read_context::clear_per_translation_unit_data): Don't clear
read_context::per_tu_name_artefacts_map_ data member as it's
removed.
(read_context::clear_per_corpus_data): Don't clear
read_context::name_artefacts_map_ and all the other relevant data
members that got removed.
(read_context::{dwarf_per_die_source,
decl_die_repr_die_offsets_maps, type_die_repr_die_offsets_maps,
get_canonical_die, get_die_from_offset, decl_die_artefact_maps,
type_die_artefact_maps, dwarf_expr_eval_ctxt}): Add new member
functions.
(compare_dies, compare_as_decl_dies)
(compare_as_type_dies, maybe_finish_function_decl_reading)
(die_is_anonymous): Define new functions.
(read_context::associate_die_to_decl): Remove the
do_associate_by_repr_per_tu parameter. Use the new
read_context::{decl_die_artefact_maps_, get_canonical_die} member
functions.
(read_context::lookup_decl_from_die_offset): Use Dwarf_Off rather
than size_t for the type of the die_offset parameter. Use the
lookup_artifact_from_die_offset member function.
(read_context::lookup_type_artifact_from_die): Const-ify. In one
overload, take a new 'die_as_type' parameter. Use the new
get_canonical_die, type_die_artefact_maps and
decl_die_artefact_maps member functions. In the second overload,
use the first overload.
(read_context::odr_is_relevant): Add an overload that takes a DIE.
(read_context::associate_die_to_type): Remove the
do_associate_by_repr and do_associate_per_tu parameters. Use the
new get_canonical_die and type_die_artefact_maps member functions.
(read_context::lookup_type_from_die): Use the new
lookup_artifact_from_die member function.
(read_context::lookup_type_from_die_offset): Use the new
type_die_artefact_maps member function. When the found artifact
is a function_decl, return its type.
(read_context::schedule_type_for_late_canonicalization): Use the
new get_canonical_die and type_die_artefact_maps member functions.
(die_function_signature): Const-ify. Get the scope name right
even for scopes that are not types.
(die_member_offset): Make eval_last_constant_dwarf_sub_expr use
the new cached DWARF expression evalution context.
(get_parent_die): Support where_offset equals to zero. This means
we are looking at a C binary, basically.
(build_enum_type) : Use the new overload of
read_context::odr_is_relevant that takes a DIE. Adjust.
(add_or_update_union_type, add_or_update_class_type): Don't lookup
classes/unions per location anymore. Now that we can compare DIEs
in a fined grain manner, the approximation of the location is not
useful anymore.
(build_pointer_type)
(build_function_type): Associate DIE to type if we reuse an
existing type.
(build_or_get_fn_decl_if_not_suppressed): When re-using a
function decl internal representation from an equivalent DIE that
we've seen before, it can happen that we want to augment that
function decl internal representation with new properties coming
from the DIE we are currently looking at; do that here.
(is_function_for_die_a_member_of_class): Remove the "where_offset"
parameter.
(add_or_update_member_function): Adjust.
* tests/data/test-annotate/libtest23.so.abi: Adjust.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt: Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt: Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2017-04-14 Dodji Seketeli <dodji@redhat.com>
Speedup access to unreferenced symbols when loading corpus_group
* src/abg-corpus.cc (corpus_group::unrefed_{fun, var}_symbol_map):
New data members.
(corpus_group::priv::priv): Adjust.
(corpus_group::priv::add_unref_{fun,var}_symbols): Define new
member functions.
(corpus_group::add_corpus): Update the map of unreferenced
symbols.
(corpus_group::get_unreferenced_{function,variable}_symbols)
Adjust logic.
2017-04-07 Dodji Seketeli <dodji@redhat.com>
Initial support of de-serializing the KMI of a Linux Kernel Tree
* include/abg-libxml-utils.h (advance_to_next_sibling_element):
Declare new function.
* src/abg-libxml-utils.cc (go_to_next_sibling_element_or_stay)
(advance_to_next_sibling_element): Define new functions.
* include/abg-reader.h (read_corpus_group_from_input)
(read_corpus_group_from_native_xml)
(read_corpus_group_from_native_xml_file): Declare new functions.
* src/abg-reader.cc (read_context::m_corpus_group): New data
member.
(read_context::{get_corpus_group, set_corpus_group}): Define new
member functions.
(read_translation_unit_from_input): Cleanup logic.
(read_corpus_from_input): Don't assume that the document is
starting with an 'abi-corpus' element. Support the mode where a
caller called the xmlTextReaderExpand function (and so we are
given an expanded xmlNodePtr) and the mode where we need to use
the xmlTextReader API to walk through the 'abi-corpus' element.
Also, if we are building a corpus group, do not clear what used to
be 'per-corpus' data. That data must be shared by all the corpora
of a given abi-corpus-group.
(read_corpus_group_from_input, read_corpus_group_from_native_xml)
(read_corpus_group_from_native_xml_file): Define new functions.
* include/abg-tools-utils.h (FILE_TYPE_XML_CORPUS_GROUP): New
enumerator of the file_type enum.
* src/abg-tools-utils.cc (operator<<): In the overload for
file_type, add a case for the new FILE_TYPE_XML_CORPUS_GROUP.
(guess_file_type): Dectect abi-corpus-group xml element.
* tools/abidiff.cc (adjust_diff_context_for_kmidiff): Define new
static function.
(main): Adjust to handle the new FILE_TYPE_XML_CORPUS_GROUP. That
is, compare two FILE_TYPE_XML_CORPUS_GROUP if they are present.
* tools/abilint.cc (main): Likewise.
* tools/kmidiff.cc (main): Detect that one of two .kmi files are
passed. In that case, load the .kmi file(s), build a corpus_group
of it and use it in the comparison.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Initial support of the serialization of the KMI of a Linux Kernel Tree
* include/abg-tools-utils.h (check_dir)
(get_binary_paths_from_kernel_dist)
(build_corpus_group_from_kernel_dist_under): Declare new
functions. The last two functions are being moved from
tools/kmidiff.cc so that they can be re-used.
* include/abg-writer.h (write_corpus): Declare one overload that
takes a write_context parameter.
(write_corpus_group): Declare three overloads of this new function.
* src/abg-tools-utils.cc (check_dir): Define new function.
(load_generate_apply_suppressions, is_vmlinux, is_kernel_module)
(find_vmlinux_and_module_paths)
(get_binary_paths_from_kernel_dist)
(build_corpus_group_from_kernel_dist_under): Define new functions.
* src/abg-writer.cc (write_context::set_annotate): Define new
member function.
(write_corpus): Add an overload that takes a write_context. Adapt
the existing overload to make it use this new one.
(write_corpus_group): Define this new function and two additional
overloads for it.
* tools/kmidiff.cc (set_suppressions, is_vmlinux)
(is_kernel_module, find_vmlinux_and_module_paths)
(get_binary_paths_from_kernel_dist)
(build_corpus_group_from_kernel_dist_under): Remove.
(main): Adjust the call to
build_corpus_group_from_kernel_dist_under as its arguments are now
adapted since it's been factorized out into abg-tools-utils.h.
* tools/abidw.cc (options::corpus_group_for_linux): Define new
data member.
(options::options): Adjust.
(display_usage): Add help strings for the new --linux-tree option.
(load_corpus_and_write_abixml): Factorize this function out of the
main function.
(load_kernel_corpus_group_and_write_abixml): Define new function.
(main): Use the factorized load_corpus_and_write_abixml and the
new load_corpus_and_write_abixml functions.
* tests/test-read-write.cc: Adjust.
* doc/manuals/abidw.rst: Add documentation for the new
--linux-tree option.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Adjust test reference outputs after changes in abg-writer.cc
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Fix indentation glitch before the </abi-corpus> tag in abixml
* src/abg-writer.cc (write_corpus): Indent before emitting the
closing </abi-corpus> tag.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Avoid emitting some empty translation units to abixml
* src/abg-writer.cc (write_corpus): Do not emit a translation
unit that appears empty beforehand.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Avoid emitting duplicated decls in abixml
* src/abg-writer.cc (write_context::m_emitted_decls_map): New data
member.
(write_context::{decl_name_is_emitted, record_decl_as_emitted}):
Define new memeber functions.
(write_translation_unit): Do not emit a decl that has already been
emitted.
(write_var_decl, write_function): Record the decl as emitted.
2017-04-04 Dodji Seketeli <dodji@redhat.com>
Rename write_corpus_to_native_xml into write_corpus
* include/abg-writer.h (write_corpus): Rename
write_corpus_to_native_xml to this.
* src/abg-writer.cc (write_corpus): Rename
write_corpus_to_native_xml to this.
* tests/test-read-dwarf.cc (test_task::perform): Adjust.
* tests/test-read-write.cc: Remove a useless "using
abigail::xml_writer::write_corpus_to_native_xml".
* tools/abidw.cc (main): Adjust.
* tools/abilint.cc (main): Adjust.
2017-04-04 Dodji Seketeli <dodji@redhat.com>
Update the reference output of regression tests after kabidiff work
* tests/data/test-annotate/test0.abi: Adjust.
* tests/data/test-annotate/test13-pr18894.so.abi: Adjust.
* tests/data/test-annotate/test14-pr18893.so.abi: Adjust.
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust.
* tests/data/test-annotate/test17-pr19027.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-annotate/test21-pr19092.so.abi: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt: Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt: Adjust.
* tests/data/test-diff-pkg/spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt: Adjust.
* tests/data/test-read-dwarf/test0.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2017-06-12 Dodji Seketeli <dodji@redhat.com>
Introduce the --kmi-whitelist option to abidiff
* doc/manuals/abidiff.rst: Add documentation for the
--kmi-whitelist option.
* tools/abidiff.cc (display_usage): Emit help string for the
--kmi-whitelist option
(parse_command_line): Parse the new --kmi-whitelist option, of the
-w shortcut.
2017-04-04 Dodji Seketeli <dodji@redhat.com>
Make abidw support the --kmi-whitelist option
* tools/abidw.cc (options::{kabi_whitelist_paths,
kabi_whitelist_supprs}): New data members.
(display_usage): Add a help string for the new --kmi-whitelist
option.
(parse_command_line): Parse the new --kmi-whitelist option.
(maybe_check_suppression_files): Check the presence of the linux
kernel abi white list passed by the option --kmi-whitelist.
(main): Ignore loading the symbol table if the kernel abi white
list is provided.
* doc/manuals/abidw.rst: Add documentation for the new option.
2017-04-03 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff compare two kernel packages
* include/abg-suppression.h
(variable_suppression::variable_suppression): Add default arguments
to the parameters.
* include/abg-tools-utils.h (dir_exists, dir_is_empty)
(string_begins_with, get_rpm_name, get_rpm_arch, get_deb_name)
(file_is_kernel_package, file_is_kernel_debuginfo_package):
Declare new functions.
* src/abg-tools-utils.cc (dir_exists, dir_is_empty)
(string_begins_with, get_deb_name, get_rpm_name, get_rpm_arch)
(file_is_kernel_package, file_is_kernel_debuginfo_package): Define
new functions.
(gen_suppr_spec_from_kernel_abi_whitelist): The kernel ABI
whitelist is made of ELF symbols names that ought to match
functions *and* variables that have ELF symbols with those names.
So generate variable suppression specifications as well. Not just
function suppression specifications.
* tools/abipkgdiff.cc (options::{kabi_whitelist_package,
show_symbols_not_referenced_by_debug_info, kabi_whitelist_paths,
kabi_suppressions}): New data members.
(options::options): Adjust.
(package::KIND_KABI_WHITELISTS): New enumerator in the
package::kind enum.
(package::kabi_whitelist_package_): New data member.
(package::{base_name, kabi_whitelist_package, }): New member
functions.
(display_usage): Add a help string to the new
--linux-kernel-abi-whitelist and --no-unreferenced-symbols
options.
(parse_command_line): Parse the new --no-unreferenced-symbols,
--linux-kernel-abi-whitelist and --lkaw-pkg options.
(maybe_check_suppression_files): Check the presence of kabi
whitelist files.
(set_diff_context_from_opts): Consider (not) showing symbols not
referenced by debug info.
(compare): If we are looking at linux kernel packages, take the
kernel abi whitelist into account, apply the suppressions
resulting from the kabi whitelists to the ELF read context.
(maybe_collect_kabi_whitelists)
(get_kabi_whitelists_from_arch_under_dir)
(maybe_handle_kabi_whitelist_pkg, maybe_collect_kabi_whitelists)
(get_interesting_files_under_dir): Define new functions.
(maybe_update_vector_of_package_content): Take a new
file_name_to_look_for parameter.
(create_maps_of_package_content)
(extract_package_and_map_its_content): Consider the case of the
package being a linux kernel package.
(main): Take the potential --lkaw-pkg into account.
* doc/manuals/abipkgdiff.rst: Add documentation for options
--linux-kernel-abi-whitelist, --lkaw-pkg and
--no-unreferenced-symbols.
2017-04-03 Dodji Seketeli <dodji@redhat.com>
Avoid loading a translation unit twice from abixml
* src/abg-reader.cc (read_translation_unit): Take (in parameter) a
reference as the resulting translation unit.
(get_or_read_and_add_translation_unit): Define new static
function.
(read_context::get_scope_for_node)
(read_translation_unit_from_input): Use the new
get_or_read_and_add_translation_unit.
2017-04-03 Dodji Seketeli <dodji@redhat.com>
Support loading and comparing two kernel trees
* include/abg-dwarf-reader.h (set_read_context_corpus_group)
(read_and_add_corpus_to_group_from_elf, set_ignore_symbol_table)
(get_ignore_symbol_table): Declare new functions.
* abg-dwarf-reader.cc (read_context::options_type): Define new
type.
(die_dependant_container_set::clear): Define new member function.
(read_context::{bss, tesxt, rodata, data, data1}_section_): Add
new data members.
(read_context::{symbol_versionning_sections_loaded_,
symbol_versionning_sections_found_}): Likewise.
(read_context::corpus_group_): Likewise.
(read_context::{load_in_linux_kernel_mode, load_all_types,
show_stats, do_log_}): Replace these options by ..
(read_context::options_): ... this instance of the new
read_context:options_type.
(read_context::read_context): Adjust.
(read_context::{clear_alt_debug_info_data, clear_per_corpus_data,
env, get_data_section_for_variable_address, load_all_types,
load_in_linux_kernel_mode, show_stats, do_log}): Adjust.
(create_read_context): Adjust.
(read_context::~read_context): Define destructor.
(read_context::{options, bss_section, text_section,
rodata_section, data_section, data1_section, current_corpus_group,
has_corpus_group, main_corpus_from_current_group,
main_corpus_from_current_group,
current_corpus_is_main_corpus_from_current_group,
should_reuse_type_from_corpus_group}): Define new member
functions.
(read_context::get_die_qualified_type_name): Handle the name of
the current translation unit.
(read_context::load_symbol_maps): Really don't load (linux kernel
specific) symbol maps if we were told to ignore the ELF symbol
table.
(set_ignore_symbol_table, get_ignore_symbol_table)
(create_default_var_sym, create_default_fn_sym, add_symbol_to_map)
(set_read_context_corpus_group)
(read_and_add_corpus_to_group_from_elf): Define new functions.
(build_type_decl, build_typedef_type, build_enum_type)
(add_or_update_class_type)
(add_or_update_union_type): Reuse the type being built, from the
main corpus of the corpus group.
(build_qualified_type): Cleanup logic.
(build_var_decl, build_function_decl): Create a default symbol for
the variable or function if we are supposed to ignore the symbol
table of the current binary. Add that symbol to the symbol table
that is created in the read context.
(read_debug_info_into_corpus): Don't load the ELF symbol table
information if we are asked to ignore the symbol table. But set
the symbol table that we built artificially while loading
functions and variables, into the ABI corpus being built.
(read_context::maybe_adjust_var_sym_address): Adjust.
(build_ir_node_from_die): Add ir node to its logical scope. For
the C language, the scope of a type is the global scope.
(read_corpus_from_elf): Don't load ELF properties if we were asked
to avoid the ELF symbol table.
* include/abg-comparison.h (compute_diff): Declare ...
* src/abg-comparison.cc (compute_diff): ... an overload to compare
corpus_group.
* tools/kmidiff.cc: New tool.
2017-03-31 Dodji Seketeli <dodji@redhat.com>
Initial support to lookup types per location
* include/abg-fwd.h (get_name_of_qualified_type)
(get_name_of_reference_to_type, lookup_basic_type_per_location)
(lookup_class_type_per_location, lookup_union_type_per_location)
(lookup_enum_type_per_location, lookup_typedef_type)
(lookup_typedef_type_per_location, lookup_pointer_type)
(lookup_reference_type, lookup_type_per_location)
(lookup_type_through_translation_units)
(lookup_type_from_translation_unit, odr_is_relevant): Declare new
functions or new function overloads.
* include/abg-ir.h (location::expand): Declare new member
function.
(type_maps::empty): Likewise.
(operator|=): Declare an overload for qualified_type_def::CV.
(get_string_representation_of_cv_quals)
(get_name_of_qualified_type, lookup_qualified_type): Declare new functions.
* src/abg-ir.cc (location::expand): Define new member function.
(type_maps::empty): Likewise.
(odr_is_relevant): Likewise.
(get_string_representation_of_cv_quals)
(get_name_of_reference_to_type, get_name_of_qualified_type)
(lookup_union_type_per_location): Define new functions or overloads.
(lookup_basic_type, lookup_enum_type, lookup_typedef_type)
(lookup_qualified_type, lookup_pointer_type)
(lookup_reference_type, lookup_type_from_translation_unit)
(lookup_basic_type_per_location, lookup_basic_type_per_location)
(lookup_class_type_per_location, lookup_class_type_per_location)
(lookup_enum_type_per_location, lookup_enum_type_per_location)
(lookup_typedef_type_per_location)
(lookup_typedef_type_per_location, lookup_type_per_location):
Define new overloads.
(maybe_update_types_lookup_map)
(maybe_update_types_lookup_map<class_decl>)
(maybe_update_types_lookup_map<function_type>): Add a new
use_type_name_as_key parameter. If it's false, then associates
the type to its location rather than to its name.
(maybe_update_types_lookup_map): In the overloads for type_decl,
class_decl, union_decl, enum_type, typedef_decl, array_type_def,
record the type in the lookup map per location, in addition to the
per-name recording.
(qualified_type_def::build_name): Use the new
get_name_of_qualified_type.
(qualified_type_def::get_cv_quals_string_prefix): Use the new
get_string_representation_of_cv_quals.
(operator|=): Define a new overload for qualified_type_def::CV.
(pointer_type_def::get_qualified_name): Use the new
get_name_of_pointer_to_type.
(reference_type_def::get_qualified_name): Use the new
get_name_of_reference_to_type.
2017-03-30 Dodji Seketeli <dodji@redhat.com>
Create a Corpus Group API extension
* include/abg-corpus.h (corpus::{find_translation_unit,
get_type_per_loc_map}): Declare new member functions.
(corpus::{get_architecture_name, is_empty}): Make these member functions
const.
(corpus::{get_sorted_fun_symbols, get_functions, get_variables,
get_unreferenced_function_symbols,
get_unreferenced_variable_symbols}): Make these member functions
virtual.
(class corpus_group): Declare a new type.
* include/abg-fwd.h (corpus_sptr, corpus_group_sptr)
(string_tu_map_type, istring_var_decl_ptr_map_type)
(istring_function_decl_ptr_map_type): Define new typedefs.
* src/abg-corpus-priv.h (corpus_priv::{path_tu_map,
type_per_loc_map_}): Add new data members.
* src/abg-corpus.cc (corpus_add): Complete the function comment.
Assert that at most one translation unit of a given path can be
added to the corpus.
(corpus::{find_translation_unit, get_type_per_loc_map}): Define
new member functions.
(corpus::{get_architecture_name}): Make this member function
const.
(struct corpus_group::priv): Define new type.
(corpus_group::{corpus_group, ~corpus_group, add_corpus,
get_corpora, is_empty, get_functions, get_variables,
get_var_symbol_map, get_fun_symbol_map, get_sorted_fun_symbols,
get_sorted_var_symbols, get_unreferenced_function_symbols,
get_unreferenced_variable_symbols}): Define member functions of
the new corpus_group type.
2017-07-03 Dodji Seketeli <dodji@redhat.com>
Fix some typos in abidiff.cc
* tools/abidiff.cc (main): Fix typos.
2017-07-03 Dodji Seketeli <dodji@redhat.com>
Avoid comparing kernel.img file from the grub2 package
* default.abignore: Do not compare kernel.img files.
2017-06-14 Dodji Seketeli <dodji@redhat.com>
Bug 21567 - Fedabipkgdiff matches build distro names too tightly
* tools/fedabipkgdiff (get_distro_from_string): Define new function.
(Brew.get_package_latest_build): Also consider builds which distro
property is less than the expected distro string that we were
given.
2017-06-14 Sinny Kumari <sinny@redhat.com>
Check if return_codes list is empty in fedabipkgdiff
* tools/fedabipkgdiff (run_abipkgdiff()): Check if
return_codes list is empty
2017-06-13 Dodji Seketeli <dodji@redhat.com>
Do not forget to erase temporary directories in abipkgdiff
* tools/abipkgdiff.cc (maybe_erase_temp_dirs): Define new static
function.
(compare): Call the new maybe_erase_temp_dirs on all return
points.
2017-05-11 Ben Woodard <woodard@redhat.com>
Fix more clang build warnings
* include/abg-ini.h (config::section::priv): Make this be a class,
not a struct.
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir)
(build_ir_node_from_die): Add parenthesis around assignment
expressions inside conditional expression.
* src/abg-suppression.cc (read_function_suppression): Likewise.
2017-05-11 Ben Woodard <woodard@redhat.com>
Fix some clang compile problems
* include/abg-comp-filter.h (class filter_base): Declare this as a
struct.
* include/abg-comparison.h (class filtering::filter_base):
Likewise.
(struct diff_traversable_base): Declare this as a class.
* include/abg-ir.h (function_decl::parameter): Declare this before
using it.
* src/abg-corpus.cc
(corpus::priv::build_unreferenced_symbols_tables): Add missing
parenthesis around assignment expressions inside conditional
expressions.
2017-05-21 Sinny Kumari <sinny@redhat.com>
Add --self-compare option in fedabipkgdiff
* bash-completion/fedabipkgdiff: Add new option --self-compare
* tests/data/Makefile.am: Add new test file
* tests/data/test-fedabipkgdiff/test7-self-compare-from-fc23-dbus-glib-report-0.txt:
New reference output for testing ABI comparison on same package
* tests/runtestfedabipkgdiff.py.in (FEDABIPKGDIFF_TEST_SPECS):
Add test case for --self-compare
* tools/fedabipkgdiff (build_commandline_args_parser()): Add
new option --self-compare
(generate_comparison_halves()): Find second comparision half in same
package list while doing self-compare
(self_compare_rpms_from_distro()): New function to perform ABI
comparision on same pacakge
(main()): Add if condition when --self-compare option is enabled
2017-03-31 Dodji Seketeli <dodji@redhat.com>
Avoid building DIE -> parent DIE map when analyzing a C binary
* include/abg-ir.h (global_scope_sptr): Make this be a share_ptr
of scope_decl, not of global_scope.
(translation_unit::get_global_scope): Return a reference to
scope_decl_sptr.
* src/abg-ir.cc (translation_unit::get_global_scope): Return a
scope_decl not a global_scope.
* src/abg-dwarf-reader.cc (read_context::nil_scope_): Add new data
member.
(read_context::{global_scope, nil_scope}): Define new member functions.
(read_context::build_die_parent_maps): Do not build the map if we
are looking at a C (or asm) translation unit.
(get_scope_die, get_scope_for_die): If we are looking at a C
translation unit then do return the global scope.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Speed up access to the definition of a class declaration-only type
* include/abg-ir.h
(class_or_union::get_naked_definition_of_declaration): Declare a
new member function.
(class_decl::get_naked_definition_of_declaration): Likewise.
* src/abg-ir.cc ({type_decl, qualified_type_def,
array_type_def, enum_type_decl}::operator==): Use the
get_naked_canonical_type and get_naked.
(class_or_union::priv::naked_definition_of_declaration_): Define
new data member.
(class_or_union::priv::priv): Adjust to initialize the new data
member.
(class_or_union::get_naked_definition_of_declaration): Define new
member function.
({class_or_union, class_decl}::operator==): Use the new
get_naked_definition_of_declaration instead of
get_definition_of_declaration.
(equals): In the overload for class_or_union, do the same.
(class_decl::get_naked_definition_of_declaration): Define new
member function.
(hash_type_or_decl): Likewise.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Speedup comparison of decl-only classes
* src/abg-ir.cc (equals): In the overload for class_decl, if we
are looking at a decl-only class, then directly call the equals
function for class_or_union. That one knows how to perform the
comparison without calling the
class_or_union::priv_->comparison_started function, in that case.
2017-04-04 Dodji Seketeli <dodji@redhat.com>
Update the description of what abipkgdiff does
* tools/abipkgdiff.cc: Update the description of the sequence of
actions performed.
2017-04-06 Dodji Seketeli <dodji@redhat.com>
Misc cleanups in abg-writer.cc
* src/abg-writer.cc (class write_context): Fix indentation.
(write_location, write_visibility, write_binding)
(write_array_size_and_alignment, write_size_and_alignment): Fix
these declarations to use the *_sptr typedefs rather than the
explicit shared_ptr<*> types.
(write_translation_unit): Fix comment.
2017-05-10 Dodji Seketeli <dodji@redhat.com>
Don't consider changes to basic types as being redundant
* include/abg-comparison.h (is_diff_of_basic_type)
(has_basic_type_change_only): Declare these functions ...
* src/abg-comparison.cc (is_diff_of_basic_type)
(has_basic_type_change_only): ... and define them.
(redundancy_marking_visitor::visit_begin): Use the new
has_basic_type_change_only.
* tests/data/test-diff-filter/libtest37-v0.so: New binary test input.
* tests/data/test-diff-filter/libtest37-v1.so: Likewise.
* tests/data/test-diff-filter/test37-report-0.txt: New test
reference output.
* tests/data/test-diff-filter/test37-v0.cc: Source code of the new
binary test input.
* tests/data/test-diff-filter/test37-v1.cc: Likewise.
* tests/data/Makefile.am: Update to add the new test material to
the source distribution.
* tests/test-diff-filter.cc (in_out_spec): Add the new test input
to this test harness.
2017-05-10 Dodji Seketeli <dodji@redhat.com>
Rename fn_parm_diff::get_type_diff into fn_parm_diff::type_diff
* include/abg-comparison.h (fn_parm_diff::type_diff): Renamed
fn_parm_diff::get_type_diff intot his.
* src/abg-comparison.cc (fn_parm_diff::type_diff): Likewise.
(fn_parm_diff::report): Adjust.
(redundancy_marking_visitor::visit_begin): Likewise.
(is_diff_of_variadic_parameter): Likewise.
2017-05-03 Dodji Seketeli <dodji@redhat.com>
Invalidate function and variable ID cache when invoking ::set_symbol
* src/abg-ir.cc ({function, var}_decl::set_symbol): Invalidate the
ID cache.
2017-05-03 Dodji Seketeli <dodji@redhat.com>
Remove useless overloads of is_type
* include/abg-fwd.h (is_type): Remove the overloads that take
decl_base and type_base types.
* src/abg-ir.cc (is_type): Likewise.
2017-05-04 Dodji Seketeli <dodji@redhat.com>
Ensure build_qualified_type can return non-qualified types
* src/abg-dwarf-reader.cc (build_qualified_type): Return a
type_base_sptr.
(build_ir_node_from_die): Adjust the call to build_qualified_type.
2017-05-04 Dodji Seketeli <dodji@redhat.com>
Fix array subranges (wrongly) having the same lower bound
* src/abg-dwarf-reader.cc (build_subranges_from_array_type_die):
Consider the 'lower_bound' parameter as the default lower bound
for each sub-ranges.
2017-03-31 Dodji Seketeli <dodji@redhat.com>
Fix buffer overrun in 'equals' function for arrays
* src/abg-ir.cc (equals): In the overload for arrays, check for
the end of the subranges of the two arrays, not just for the first
one.
2017-04-18 Dodji Seketeli <dodji@redhat.com>
Fix a race condition in queue::priv::do_bring_workers_down
* src/abg-workers.cc (queue::priv::tasks_todo_mutex): Make this
data member mutable.
(more_tasks_to_execute):
(queue::priv::do_bring_workers_down): Update the
queue::priv::bring_workers_down only in the critical section
defined by queue::priv::queue_cond_mutex.
(worker::wait_to_execute_a_task): Testing for
queue::priv::bring_workers_down is done in the critical section
defined by queue::priv::queue_cond_mutex. The loop over waiting
ont the condition is also in the critical section, as it ought to
be.
* tests/test-read-write.cc (struct test_task): New type.
(main): Express in terms of the new test_task type.
2017-04-12 Ondrej Oprala <ondrej.oprala@gmail.com>
cppcheck: mitigate performance warnings
* include/abg-diff-utils.h (print_snake): pass argument of type
snake by const reference.
* include/abg-ir.h (location::operator{==,<}): Likewise.
* include/abg-viz-dot.h (node_base::{node_base,parent_node,child_node}):
Likewise.
* include/abg-viz-svg.h (svg::svg) Likewise.
* src/abg-config.cc (config::config): Member initialization in ctor body.
* src/abg-dwarf-reader.cc (class_decl_sptr::add_or_update_class_type):
Initial value never used.
* src/abg-ir.cc: (decl_base::priv::priv) Member initialization in ctor body,
pass argument of type location by const reference.
(equals): Variable initial value never used.
* src/abg-reader.cc (read_corpus_from_input): Initial variable
value never used.
(build_elf_symbol_db): Use pre-increment.
* src/abg-suppression-priv.h
(suppression_matches_type_location): Pass argument of type
location by const reference.
* src/abg-suppression.cc: Likewise.
2017-04-11 Ondrej Oprala <ondrej.oprala@gmail.com>
Fix cppcheck error: "Same iterator is used with different containers"
* src/abg-dwarf-reader.cc
(type_or_decl_base_sptr::lookup_artifact_from_per_tu_die_representation):
Fix an error found by cppcheck.
2017-04-11 Ondrej Oprala <ondrej.oprala@gmail.com>
Clean up scripts/*
* scripts/dot_to_png.sh: Clean up the script according to
shellcheck warnings and remarks.
* scripts/dot_to_svg.sh: Likewise.
* scripts/svg_to_plain_svg.sh: Likewise.
* scripts/svg_to_png_and_pdf.sh: Likewise.
2017-04-12 Ondrej Oprala <ondrej.oprala@gmail.com>
Fix comparison used instead of an assignment
* src/abg-ir.cc (parse_integral_type): An attempt at clang
compilation has discovered there to be a comparison with
unused result, that apparently should be an assignment.
2017-04-12 Dodji Seketeli <dodji@redhat.com>
Fix some random deadlock while running fedabipkgidiff in tests
* tools/fedabipkgdiff (abipkgidff): Do not use Popen.communicate()
as it might hang if the data is large. Rather, busy wait for the
abipkgdiff process to finish and then get its output.
2017-03-22 Slava Barinov <v.barinov@samsung.com>
Fix types in header to meet sources
* include/abg-fwd.h: Include stdint.h for uint64_t.
(ir::set_data_member_offset): Take uint64_t rather than size_t.
(ir::get_data_member_offset): Return uint64_t rather than size_t.
2017-03-24 Dodji Seketeli <dodji@redhat.com>
Launch fedabipkgdiff tests first
* tests/Makefile.am: Run the fedabipkgdiff test first.
2017-03-24 Dodji Seketeli <dodji@redhat.com>
Bug 21296 - Reporting diff of const ref against non-const ref aborts
* include/abg-fwd.h (look_through_no_op_qualified_type): Declare
new function.
* src/abg-ir.cc (look_through_no_op_qualified_type): Define it.
(compute_diff_for_types): Use the new
look_through_no_op_qualified_type here rather than open-coding it.
(equals): In the overload for function_decl::parameter, use the
new look_through_no_op_qualified_type function.
* tests/data/test-diff-dwarf/test40-PR21296-clanggcc.cc: Source
code of the new test inputs.
* tests/data/test-diff-dwarf/test40-PR21296-clanggcc-report0.txt:
New test input.
* tests/data/test-diff-dwarf/test40-PR21296-libgcc.so: New binary
test input.
* tests/data/test-diff-dwarf/test40-PR21296-libclang.so: Likewise.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test inputs to
the test harness.
2017-03-05 Chenxiong Qi <cqi@redhat.com>
Bug 20087 - Clean cache before or after ABI comparison
* configure.ac: Require shutil module.
* doc/manuals/fedabipkgdiff.rst: Add document for new option
clean-cache, clean-cache-before, and clean-cache-after.
* tools/fedabipkgdiff (build_commandline_args_parser): Add new
option --clean-cache, --clean-cache-before and
--clean-cache-after.
(diff_local_rpm_with_latest_rpm_from_koji): Delete download
cache directory before or after downloading RPMs.
(diff_latest_rpms_based_on_distros): Likewise.
(diff_two_nvras_from_koji): Likewise.
(diff_from_two_rpm_files): Likewise.
* bash-completion/fedabipkgdiff: Add new options.
* tests/mockfedabipkgdiff.in (get_download_dir): Rewrite to
behave just like the original get_download_dir.
(mock_get_download_dir): Removed.
(DOWNLOAD_CACHE_DIR): New global variable pointing directory
holding packages during tests.
(run_fedabipkgdiff): Mock original get_download_dir with the
rewrite get_download_dir.
* tests/runtestfedabipkgdiff.py.in (run_fedabipkgdiff_tests):
Add --clean-cache to run tests to ensure no regression.
2017-03-17 Dodji Seketeli <dodji@redhat.com>
Shut down a helgrind false positive in the "system" libc call
* tests/test-valgrind-suppressions.supp: Add a suppression that
occurs during an internal libc signal handling occasion.
2017-03-15 Dodji Seketeli <dodji@redhat.com>
Fix data race on worker::queue::priv::bring_workers_down
* src/abg-workers.cc (worker::wait_to_execute_a_task): Protect the
read of the queue::priv::bring_workers_down down variable with the
queue::priv::tasks_todo_mutex.
2017-03-07 Dodji Seketeli <dodji@redhat.com>
Bug 21228 - Handle cloning union member functions
* include/abg-ir.h (class_or_union::add_member_function): Move the
class_decl::add_member_function overload declaration into the
class class_or_union class.
(class class_decl): Make the class class_or_union be a friend of
class_decl.
* src/abg-ir.cc (class_decl::add_member_function): Transform the
definition of this overload into ...
(class_or_union::add_member_function): ... this one. Make sure
that when setting the virtual-ness attributes of the member
function, we are effectively looking at the a function that is a
member of a class.
(function_decl::clone): Do not assert that a member function is
necessarily a member of a class_decl. It can also a member of a
union_decl!. So, rather, assert that the scope of the member
function is of type class_or_union.
* tests/data/test-diff-pkg/tbb-2017-8.20161128.fc26.x86_64.rpm:
New test input RPM.
* tests/data/test-diff-pkg/tbb-2017-9.20170118.fc27.x86_64.rpm:
* tests/data/test-diff-pkg/tbb-debuginfo-2017-8.20161128.fc26.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/tbb-debuginfo-2017-9.20170118.fc27.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/tbb-2017-8.20161128.fc26.x86_64--tbb-2017-9.20170118.fc27.x86_64.txt:
New reference test output.
* tests/data/Makefile.am: Add the new test input RPMs to the
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Take the new input tests
above into account.
2017-03-03 Dodji Seketeli <dodji@redhat.com>
Consider file path when sorting virtual member functions
* src/abg-ir.cc (virtual_member_function_less_than::operator()):
Take the file path into account in the sorting.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
2017-03-03 Dodji Seketeli <dodji@redhat.com>
Fix virtual members sorting to unbreak the build on EL6
* src/abg-ir.cc (virtual_member_function_less_than::operator()):
Update comment. When two virtual functions have the same virtual
index and one of them has no ELF symbol, then that function is
less than the one with an ELF symbol.
* tests/data/Makefile.am: Remove
test-annotate/{test9-pr18818-clang.so.abi, test11-pr18828.so.abi,
test12-pr18844.so.abi, test16-pr18904.so.abi,
test22-pr19097-libstdc++.so.6.0.17.so.abi}.
* tests/data/test-annotate/test10-pr18818-gcc.so.abi: Remove.
* tests/data/test-annotate/test11-pr18828.so.abi: Likewise.
* tests/data/test-annotate/test12-pr18844.so.abi: Likewise.
* tests/data/test-annotate/test16-pr18904.so.abi: Likewise.
* tests/data/test-annotate/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/test-annotate.cc (in_out_specs): Remove those tests above
which input files have been removed.
2017-03-02 Dodji Seketeli <dodji@redhat.com>
Make Helgrind suppressions less specific to libgcc_s version
* tests/test-valgrind-suppressions.supp: Make Helgrind
suppressions less specific to libgcc_s version.
2017-03-02 Dodji Seketeli <dodji@redhat.com>
More Helgrind suppressions
* tests/test-valgrind-suppressions.supp: More specific suppressions.
2017-03-02 Dodji Seketeli <dodji@redhat.com>
Silence Helgrind reports about exception stack unwinding
* tests/test-valgrind-suppressions.supp: Silence Helgrind reports
about exception stack unwinding.
2017-03-01 Dodji Seketeli <dodji@redhat.com>
Make the helgrind suppressions less specific
* tests/test-valgrind-suppressions.supp: Make the ostream writting
suppressions be less specific so that they can apply to all the
related false positives.
2017-03-01 Dodji Seketeli <dodji@redhat.com>
Move test-read-dwarf.cc to abigail::workers
* tests/test-read-dwarf.cc (iospec, spec_lock, write_lock)
(out_abi_base, in_elf_base, in_abi_base): Remove these global
variables.
(handle_in_out_spec): Remove this.
(struct test_task): Write this task that does what
handle_in_out_spec was doing.
(test_task_sptr): Define new typedef.
(main): Remove the pthreads artifacts. Use the new test_task type
along with the abigail::workers interface.
* tests/test-valgrind-suppressions.supp: Add more helgrind
suppressions for ostream writting false positives.
2017-02-28 Dodji Seketeli <dodji@redhat.com>
Display the command that failed the runtestfedabipkgdiff.py test
* tests/runtestfedabipkgdiff.py.in (run_fedabipkgdiff_tests): When
A test fails, display the fedabipkgdiff command that triggered the failure.
2017-02-24 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff.cc use the abigail::workers interface
* tools/abipkgdiff.cc: Remove ftw.h, pthread.h, unistd.h, add
fts.h and abg-workers.h.
(verbose, elf_file_paths_tls_key, reports_map, env_map, map_lock)
(arg_lock, prog_options): Remove all these global variables.
(struct package_descriptor): Remove this type.
(pthread_routine_extract_package)
(first_package_tree_walker_callback_fn)
(second_package_tree_walker_callback_fn, pthread_routine_compare)
(pthread_join, pthread_routine_extract_pkg_and_map_its_content):
Remove these functions.
(options::{num_workers, verbose}): Define new data members.
(options::options): Initialize the new verbose and num_workers data members.
(package::erase_extraction_directory)
(erase_created_temporary_directories_parent): Take the program
options in parameter. Don't use the global verbose variable
anymore.
(package::erase_extraction_directories)
(erase_created_temporary_directories, extract_package): Take the
program options in parameter.
(extract_rpm, extract_deb, extract_tar): Likewise. And don't use
the global verbose variable anymore.
(compare): Don't use the global verbose variable anymore. Use the
new compare_task type along with the abigail::workers::queue type.
(pkg_extraction_task, pkg_prepare_task, compare_task)
(comparison_done_notify): Define new classes.
(maybe_update_vector_of_package_content): Define new static
function.
(create_maps_of_package_content): Don't take the ftw_cp_type
anymore. Don't use the global verbose variable anymore. Use the
fts_{open,read,close} functions, rather than the ftw one.
(extract_package_and_map_its_content): Don't use pthreads anymore.
Use the new pkg_extraction_task type created along with the
abigail::workers::queue type.
(prepare_packages): Don't use pthreads anymore. Use the new
pkg_prepare_task type along with the abigail::workers::queue type.
(elf_size_is_greater): Adjust to use
abigail::workers::queue::tasks, rather than the previous
compaer_args_sptr type.
(parse_command_line): Adjust to stop using the global verbose
variable.
(main): Remove use of global variables prog_options and also the
packages variable.
* tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64--dbus-glib-0.104-3.fc23.armv7hl-report-0.txt:
Adjust.
* tests/data/test-diff-pkg/dirpkg-0-report-0.txt: Likewise.
* tests/data/test-diff-pkg/test-dbus-glib-0.80-3.fc12.x86_64-report-0.txt:
Likewise.
* tests/data/test-diff-pkg/test-rpm-report-0.txt: Likewise.
* tests/data/test-diff-pkg/test-rpm-report-1.txt: Likewise.
* tests/data/test-diff-pkg/test-rpm-report-2.txt: Likewise.
* tests/data/test-diff-pkg/test-rpm-report-3.txt: Likewise.
* tests/data/test-fedabipkgdiff/test0-from-fc20-to-fc23-dbus-glib-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test1-from-fc20-to-dbus-glib-0.106-1.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test2-dbus-glib-0.100.2-2.fc20--dbus-glib-0.106-1.fc23-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test3-dbus-glib-0.100.2-2.fc20.i686--dbus-glib-0.106-1.fc23.i686-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test4-glib-0.100.2-2.fc20.x86_64.rpm-glib-0.106-1.fc23.x86_64.rpm-report-0.txt:
Likewise.
2017-02-24 Dodji Seketeli <dodji@redhat.com>
Do not ignore valgrind checks returning an error
* autoconf-archive/ax_valgrind_check.m4 (check-valgrind): Don't
ignore errors.
2017-02-24 Dodji Seketeli <dodji@redhat.com>
Add a "make check-valgrind-helgrind-recursive" target
* tests/Makefile.am (check-valgrind-helgrind-recursive): New
target to run the tests recursively under the control of
Valgrind's Helgrind tool.
* tests/test-valgrind-suppressions.supp: Update this suppression
file with suppressions for Helgrind.
2017-02-24 Dodji Seketeli <dodji@redhat.com>
Several fixes and enhancements to abigail::workers
* Don't try to schedule a task if the pointer to the task is nil
* Fix a data race when bringing workers (of a queue) down
* Always try to wake up all waiting threads when bringing down queue
workers.
* Fix a data race when accessing the queue condition variable
* Fix a data race when notifying listeners about the end of the job
performed by the task.
Enhancements
============
* Pass the "task done" notifier by reference, to the worker queue.
Without this, the worker queue needs to copy the "task done" notifier
by value. This implies that user code needs to provide task done
notifier instances that come with potentially complicated copy
constructors. By passing it by reference and by just re-using the
notifier from the user code, we do away with the need for copying
altogether. This also fixes some latent copying bugs.
* Add a workers::queue::schedule_tasks() method
This allows user code to schedule a vector of tasks at once.
* make workers::queue::get_completed_tasks() return a non-const vector
This enables user code to sort the completed tasks as they wish.
* include/abg-workers.h (queue::tasks_type): New typedef.
(queue::queue): Pass task_done_notify by reference.
(queue::schedule_tasks): Declare new member function.
(queue::get_completed_tasks): Return non-const vector.
* src/abg-workers.cc (queue::priv::default_notify): New data
member.
(queue::priv::notify): Make this data member be a reference.
(queue::priv::priv): Initialize the notify data member to either
the new default_notify (if no notifier is provided by the
constructor) or to the notifier provided by the constructor.
(queue::priv::schedule_task): Do not schedule a nil task. Update
comment.
(queue::priv::schedule_tasks): Add a new member function.
(queue::priv::do_bring_workers_down): Update comment. Protect
access to "bring_workers_down" with tasks_todo_mutex to prevent a
data race. Call pthread_cond_broadcast on the queue_cond
unconditionaly to prevent some worker threads to keep waiting for
ever. Also, protect the access to the queue_cond by the
queue_cond_mutex to precent a data race.
(queue::queue): Pass the notifier by reference. Update comment.
(queue::schedule_task): Update comment.
(queue::schedule_tasks): Define new member function.
(queue::wait_for_workers_to_complete): Update comment.
(queue::get_completed_tasks): Return a non-const vector. Update
comment.
(worker::wait_to_execute_a_task): Update several comments. Make
the execution of the notification code to be synchronized (on the
tasks_done_mutex).
2017-02-14 Dodji Seketeli <dodji@redhat.com>
Fix typo in help string of abipkgdiff
* tools/abipkgdiff.cc (display_usage): Remove erroneous end line.
2017-01-23 Dodji Seketeli <dodji@redhat.com>
fedabipkgdiff refuses to compare packages with the same release number
* tools/fedabipkgdiff (RPM.is_peer): Update comment. Fix logic.
* tests/data/test-fedabipkgdiff/packages/vte291/0.39.1/1.fc22/x86_64/vte291-0.39.1-1.fc22.x86_64.rpm:
New test input file.
* tests/data/test-fedabipkgdiff/packages/vte291/0.39.1/1.fc22/x86_64/vte291-debuginfo-0.39.1-1.fc22.x86_64.rpm: Likewise.
* tests/data/test-fedabipkgdiff/packages/vte291/0.39.1/1.fc22/x86_64/vte291-devel-0.39.1-1.fc22.x86_64.rpm: Likewise.
* tests/data/test-fedabipkgdiff/packages/vte291/0.39.90/1.fc22/x86_64/vte291-0.39.90-1.fc22.x86_64.rpm: Likewise.
* tests/data/test-fedabipkgdiff/packages/vte291/0.39.90/1.fc22/x86_64/vte291-debuginfo-0.39.90-1.fc22.x86_64.rpm: Likewise.
* tests/data/test-fedabipkgdiff/packages/vte291/0.39.90/1.fc22/x86_64/vte291-devel-0.39.90-1.fc22.x86_64.rpm:
Likewise.
* tests/data/test-fedabipkgdiff/vte291-0.39.1-1.fc22.x86_64--vte291-0.39.90-1.fc22.x86_64-report-0.txt: Likewise.
* tests/data/Makefile.am: Add the new test input data to source
distribution.
* tests/mockfedabipkgdiff.in: Update the package and build
information to add the new vte291-0.39.1-1.fc22.x86_64.rpm and
vte291-0.39.90-1.fc22.x86_64.rpm packages (as well as their devel
and debuginfo packages) into the "mock" Koji build database.
* tests/runtestfedabipkgdiff.py.in: Make this test harness run
over the two aforementioned packages.
2017-01-24 Dodji Seketeli <dodji@redhat.com>
Add missing tests input files to distribution files
* tests/data/Makefile.am: Add three missing test input files to
the source distribution tarball. Renamed
test-fedabipkgdiff/test6-missing-devel-debuginfo-nss-util-3.12.6-1.fc14.x86_64--nss-util-3.24.0-2.0.fc25.x86_64-report-0.txt
into
test-fedabipkgdiff/test6-nss-util-3.12.6-1.fc14.x86_64--nss-util-3.24.0-2.0.fc25.x86_64-report-0.txt.
* tests/runtestfedabipkgdiff.py.in (FEDABIPKGDIFF_TEST_SPECS):
Renamed
test6-missing-devel-debuginfo-nss-util-3.12.6-1.fc14.x86_64--nss-util-3.24.0-2.0.fc25.x86_64-report-0.txt
into
test6-nss-util-3.12.6-1.fc14.x86_64--nss-util-3.24.0-2.0.fc25.x86_64-report-0.txt.
2017-01-24 Dodji Seketeli <dodji@redhat.com>
Add missing new line to an error message of runtestfedabipkgdiff.py
* tests/runtestfedabipkgdiff.py.in (run_fedabipkgdiff_tests): Add
missing new line to an error message.
2017-01-24 Dodji Seketeli <dodji@redhat.com>
Fix silent failure of tests/runtestfedabipkgdiff.py
* tests/mockfedabipkgdiff.in (run_fedabipkgdiff): Patch
fedabipkgdiff.DEFAULT_KOJI_TOPURL instead of
fedabipkgdiff.DEFAULT_KOJI_TOPDIR.
* tests/runtestfedabipkgdiff.py.in (main): Properly return 0 upon
success, 1 otherwise.
2017-01-14 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-ir.h (class_or_union): Fix indentation.
* src/abg-dwarf-reader.cc (get_die_pretty_representation): Add new
line.
* src/abg-ir.cc (struct class_decl::priv): Fix indentation.
(virtual_member_function_less_than::operator()): Fix a typo in a
comment.
2017-01-13 Dodji Seketeli <dodji@redhat.com>
Bug 20476 - Compare virtual member functions when comparing classes
* include/abg-ir.h (class_decl::get_biggest_vtable_offset):
Declare new member function.
* src/abg-ir.cc (virtual_member_function_less_than::operator()):
Either compare the symbol id strings if the functions have
symbols or just compare their pretty representations.
(class_decl::get_biggest_vtable_offset): Define new member
function.
(methods_equal_modulo_elf_symbol)
(method_matches_at_least_one_in_vector): New static methods.
(equals): In the overload for classes, compare the virtual member
functions while comparing classes.
* src/abg-comparison.cc (represent): In the overload for
method_decl_sptr, fix the way we compute the highest vtable offset
number for a give class_decl.
(class_decl::ensure_lookup_tables_populated): Don't forget added
and removed virtual member functions in the report for changed
classes.
* tests/data/test-diff-dwarf/libtest41-PR20476-hidden-old.so: New
test binary input file.
* tests/data/test-diff-dwarf/libtest41-PR20476-hidden-new.so: Likewise.
* tests/data/test-diff-dwarf/test41-PR20476-hidden-report-0.txt:
New reference output.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-diff-dwarf.cc (in_out_spec): Add the new tests
here.
* tests/data/test-annotate/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-annotate/test11-pr18828.so.abi: Adjust.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-annotate/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
2017-02-14 Dodji Seketeli <dodji@redhat.com>
Fix indentation in src/abg-writer.cc
* src/abg-writer.cc (annotate): Fix indentation.
2017-02-13 Dodji Seketeli <dodji@redhat.com>
Adjust reference output of test-annotate
* tests/data/test-annotate/test15-pr18892.so.abi: Adjust this
reference output.
2017-02-13 Dodji Seketeli <dodji@redhat.com>
Fix help string for --header-dirs
* tools/abidw.cc (display_usage): Fix patch -> path typo.
2017-02-13 Dodji Seketeli <dodji@redhat.com>
Make abidw --headers-dir work with the --out-file option
* tools/abidw.cc (parse_command_line): Don't require an empty
output file when parsing the --headers-dir option. This was a
thinko.
2017-01-17 Ondrej Oprala <ondrej.oprala@gmail.com>
Bug 20970 - Add a --annotate option to abidw
* doc/manuals/abidiff.rst: Document the '--no-corpus-path'
option.
* doc/manuals/abidw.rst: Document the '--no-corpus-path'
and '--annotate' options.
* include/abg-libxml-utils.h ({un,}escape_xml_comment): Add
new function declarations.
* include/abg-writer.h: Add new annotate functions
(write_{translation_unit,corpus_to_{archive,native_xml_file}}):
Add an optional "annotate" parameter defaulting to "false".
* src/abg-libxml-utils.cc ({un,}escape_xml_comment): Add
new function definitions.
* src/abg-writer.cc (annotate): Define new templatized function
and specialize it for necessary cases.
* tests/Makefile.am: Add runtestannotate as a new test.
* tests/data/Makefile.am: Add paths to below reference test
outputs.
* tests/data/test-annotate/libtest23.so.abi: New reference test
output.
* tests/data/test-annotate/libtest24-drop-fns-2.so.abi: Likewise.
* tests/data/test-annotate/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-annotate/test0.abi: Likewise.
* tests/data/test-annotate/test1.abi: Likewise.
* tests/data/test-annotate/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-annotate/test11-pr18828.so.abi: Likewise.
* tests/data/test-annotate/test12-pr18844.so.abi: Likewise.
* tests/data/test-annotate/test13-pr18894.so.abi: Likewise.
* tests/data/test-annotate/test14-pr18893.so.abi: Likewise.
* tests/data/test-annotate/test15-pr18892.so.abi: Likewise.
* tests/data/test-annotate/test16-pr18904.so.abi: Likewise.
* tests/data/test-annotate/test17-pr19027.so.abi: Likewise.
* tests/data/test-annotate/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-annotate/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-annotate/test2.so.abi: Likewise.
* tests/data/test-annotate/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-annotate/test21-pr19092.so.abi: Likewise.
* tests/data/test-annotate/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-annotate/test3.so.abi: Likewise.
* tests/data/test-annotate/test4.so.abi: Likewise.
* tests/data/test-annotate/test5.o.abi: Likewise.
* tests/data/test-annotate/test6.so.abi: Likewise.
* tests/data/test-annotate/test7.so.abi: Likewise.
* tests/data/test-annotate/test8-qualified-this-pointer.so.abi: Likewise.
* tests/data/test-annotate/test9-pr18818-clang.so.abi: Likewise.
* tests/test-annotate.cc: New test for ABIXML annotations.
* tools/abidiff.cc: Add the new option '--no-corpus-path'.
* tools/abidw.cc: Likewise. Also add the '--annotate' option.
reviews round 1
2017-01-20 Dodji Seketeli <dodji@redhat.com>
Fix test-diff-pkg after commit 2dcc606
* tests/test-diff-pkg.cc (in_out_specs): Fix paths to spice-server
packages.
2017-01-20 Dodji Seketeli <dodji@redhat.com>
Add --harmless option to abipkgdiff
* doc/manuals/abidiff.rst: Fix a typo.
* doc/manuals/abipkgdiff.rst: Document the --harmless option.
* tools/abipkgdiff.cc: Update copyright year.
(options::show_harmless_changes): Add new data member.
(options::options): Initialize the new data member.
(display_usage): Add a help string for the new --harmless option.
(parse_command_line): Parse the new --harmless option.
(set_diff_context_from_opts): Configure the diff context
accordingly, if the user provided the --harmless option.
2017-01-20 Dodji Seketeli <dodji@redhat.com>
Fix suppression category propagation in diff node graph
* include/abg-comparison.h (diff::get_class_of_equiv_category):
Declare new member function.
* src/abg-comparison.cc: Update copyright year.
(diff::get_class_of_equiv_category): Define new member function.
(suppression_categorization_visitor::visit_end): When considering
children nodes category for propagation, consider the category of
the class of equivalence of children nodes.
* spice-debuginfo-0.12.4-19.el7.x86_64.rpm: New input test package.
* spice-debuginfo-0.12.8-1.el7.x86_64.rpm: Likewise.
* spice-server-0.12.4-19.el7.x86_64.rpm: Likewise.
* spice-server-0.12.8-1.el7.x86_64.rpm: Likewise.
* spice-server-devel-0.12.4-19.el7.x86_64.rpm: Likewise.
* spice-server-devel-0.12.8-1.el7.x86_64.rpm: Likewise.
* spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-0.txt:
New reference test output.
* spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-1.txt: Likewise.
* spice-server-0.12.4-19.el7.x86_64-0.12.8-1.el7.x86_64-report-2.txt: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test inputs
to the list of packages to test.
2017-01-18 Dodji Seketeli <dodji@redhat.com>
Bug 21058 - abipkgdiff wrongly drops non-public types
* doc/manuals/abidiff.rst (--dont-drop-private-types): Remove documentation.
(--drop-private-types): Document this new option.
* src/abg-tools-utils.cc: Update copyright notice
(handle_fts_entry): On the generated suppression specification, do
not set the flag to drop matched types. Also, don't match types
defined in files which patch start with "/usr/include/".
* tools/abidiff.cc (options::options): Initialize the
drop_private_types data member to false.
(display_usage): Remove usage string for
--dont-drop-private-types. Add a new one for
--drop-private-types.
(parse_command_line): Don't part --dont-drop-private-types,
rather, parse --drop-private-types.
(set_suppressions): When the suppression for private types is
generated, if --drop-private-types was provided, then instruct the
suppression to drop matched types.
* tools/abipkgdiff.cc (options::drop_private_types): New option.
(options::options): Initialize the new drop_private_types data
member to false.
(display_usage): Add a usage string for --drop-private-types.
(parse_command_line): Parse the new --drop-private-types option.
(maybe_create_private_types_suppressions): Don't take just a
package, but a package_descriptor because the latter carries the
options. So when the user used the --drop-private-types option,
make the generated private types suppression to drop matched
types.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
Adjust.
* tests/test-diff-suppr.cc (in_out_specs): Likewise.
2017-01-18 Dodji Seketeli <dodji@redhat.com>
Fix some include logic in abg-suppression.cc
* src/abg-suppression.cc: Update copyright notice. Fix include
files logic.
2017-01-16 Dodji Seketeli <dodji@redhat.com>
Support virtual member functions with vtable offset not yet set
* include/abg-fwd.h (member_function_has_vtable_offset): Declare
new function.
(get_member_function_vtable_offset): Return a ssize_t, not a
size_t.
(set_member_function_vtable_offset): Take a ssize_t, not a size_t.
* include/abg-ir.h (class_decl::virtual_mem_fn_map_type): Adjust
the map typedef to make it take ssize_t as the type of the key.
(mem_fn_context_rel::vtable_offset_in_bits_): Make this data
member be of ssize_t type, not size_t.
(mem_fn_context_rel::mem_fn_context_rel): Initialize the
vtable_offset_in_bits_ data member to -1.
* src/abg-ir.cc (member_function_has_vtable_offset): Define new
function.
(get_member_function_vtable_offset): Return a ssize_t, not a
size_t.
(set_member_function_vtable_offset): Take a ssize_t, not a size_t.
* src/abg-dwarf-reader.cc (die_virtual_function_index): Take an
int64_t& rather than a uint64_t&.
(finish_member_function_reading): Don't set the vtable offset if
it's -1.
* src/abg-reader.cc (build_class_decl): Likewise.
2017-01-14 Dodji Seketeli <dodji@redhat.com>
[comparison engine] Don't crash when the context is null
* src/abg-comparison.cc
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER): Guard against
null context.
(diff::is_filtered_out): Likewise.
2017-01-14 Dodji Seketeli <dodji@redhat.com>
[dwarf reader] Don't abort when trying to canonicalize a non-type
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Don't abort
when trying to canonicalize a decl.
2017-01-14 Dodji Seketeli <dodji@redhat.com>
[dwarf reader] properly separate function decls and types in lookup
* src/abg-dwarf-reader.cc
(read_context::associate_die_to_artifact_by_repr_internal):
Choose the right type of representation depending on if we are
associating a type or a decl.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2017-01-14 Dodji Seketeli <dodji@redhat.com>
[dwarf reader] Allow updating and de-duplicating member functions
* src/abg-dwarf-reader.cc (add_or_update_class_type): Register
member functions for lookup by member function DIE representation.
2017-01-14 Dodji Seketeli <dodji@redhat.com>
[dwarf reader] Do not over de-duplicate function *definitions*
* src/abg-dwarf-reader.cc
(build_or_get_fn_decl_if_not_suppressed): Do try to de-duplicate a
function if it's to be completed.
2017-01-13 Dodji Seketeli <dodji@redhat.com>
[dwarf reader] Fix pretty printing static methods from DWARF
* src/abg-dwarf-reader.cc
(die_return_and_parm_names_from_fn_type_die): Take a new
'is_static' parameter.
(die_qualified_type_name, die_pretty_print_type): Adjust calling
die_return_and_parm_names_from_fn_type_die.
(die_function_signature): Likewise. Also, do not forget to print
the first parameter for a static method.
2017-01-13 Dodji Seketeli <dodji@redhat.com>
Handle several virtual member functions having the same vtable offset
* include/abg-ir.h (class_or_union::virtual_mem_fn_map_type):
Define new typedef.
(class_decl::get_virtual_mem_fns_map): Declare new accessor.
* src/abg-ir.cc (class_decl::priv::virtual_mem_fns_map_): New data
member.
(class_decl::get_virtual_mem_fns_map): Define new accessor.
(fixup_virtual_member_function): Populate the new virtual member
functions map.
(class_decl::on_canonical_type_set): Sort the virtual member
function vectors stored in the new virtual member functions map.
(class_decl::add_member_function): Call
set_member_function_is_virtual *after* calling
set_member_function_vtable_offset because the former updates the
virtual function map, so it needs the vtable offset.
* src/abg-dwarf-reader.cc (finish_member_function_reading):
Likewise.
* src/abg-reader.cc (build_class_decl): Likewise.
2017-01-13 Dodji Seketeli <dodji@redhat.com>
Speed up pretty representing (function) types
* include/abg-ir.h (type_base::get_cached_pretty_representation):
Declare new function.
(function_type::get_cached_name): Likewise.
* src/abg-ir.cc (get_method_type_name): Use the new
type_base::get_cached_pretty_representation function.
(type_base::priv::{internal_cached_repr_, cached_repr_}): Add new
data members.
(function_type::priv::{internal_cached_name_, cached_name_}):
Likewise.
(type_base::get_cached_pretty_representation): Define new
function.
(function_type::get_cached_name): Likewise.
(type_base::get_canonical_type_for): Call
type_base::get_cached_pretty_representation here, so the internal
representation is cached right before canonicalization.
(function_type::{mark_as_being_compared, unmark_as_being_compared,
comparison_started}): Uset he new type_base::get_cached_name to
speed up function type name retrieval.
2017-01-13 Dodji Seketeli <dodji@redhat.com>
Add missing deep comparison operators for {function, method}_decl_sptr
* include/abg-ir.h (operator==): Declare two new overloads for
function_decl_sptr an method_decl_sptr.
* src/abg-ir.cc (operator==): Define two new overloads for
function_decl_sptr an method_decl_sptr.
2017-01-16 Dodji Seketeli <dodji@redhat.com>
Fix performance regression while analyzing libjvm.so
* include/abg-ir.h ({type_base,
class_decl}::on_canonical_type_set): Declare new virtual member
function.
* src/abg-ir.cc (type_base::on_canonical_type_set): Define new
virtual member function that does nothing.
(class_decl::on_canonical_type_set): Define new virtual member
function that sorts the virtual member functions of class_decl.
(canonicalize): Invoke type_base::on_canonical_type_set when the
canonical type is set.
(fixup_virtual_member_function): Don't sort virtual member
functions here.
* src/abg-dwarf-reader.cc (finish_member_function_reading): Do not
sort virtual member functions here.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
2017-01-14 Dodji Seketeli <dodji@redhat.com>
Update copyright notice for abg-fwd.h, abg-ir.h and test-abidiff.cc
* include/abg-fwd.h: Adjust copyright.
* include/abg-ir.h: Likewise.
* tests/test-abidiff.cc: Likewise.
2017-01-16 Dodji Seketeli <dodji@redhat.com>
Remove unused functions from abg-ir.cc
* src/abg-ir.cc (convert_node_to_decl): Remove specializations for
class_decl_sptr, type_base_sptr and var_decl_sptr.
2016-11-10 Dodji Seketeli <dodji@redhat.com>
Support Linux Kernel ABI whitelist files
* include/abg-suppression.h
(function_suppression::function_suppression): Make the declaration
of the default constructor public.
* src/abg-suppression-priv.h (function_suppression::priv::priv):
Declare a default constructor.
* src/abg-suppression.cc
(function_suppression::function_suppression): Define default
constructor.
* include/abg-tools-utils.h
(gen_suppr_spec_from_kernel_abi_whitelist): Declare new function.
* src/abg-tools-utils.cc
(gen_suppr_spec_from_kernel_abi_whitelist): Define new function.
* tools/abidiff.cc (options::kernel_abi_whitelist_paths):
(display_usage): Display a help string for the new
--linux-kernel-abi-whitelist option.
(parse_command_line): Parse the --linux-kernel-abi-whitelist from
the command line.
(maybe_check_suppression_files): Check the presence of the kernel
abi whitelist files.
(set_suppressions): Generate suppression specifications from the
whitelist files.
2016-10-10 Dodji Seketeli <dodji@redhat.com>
Support Linux Kernel binaries
* include/abg-dwarf-reader.h (create_read_context): Take a new
flag to say if the context is to read an ELF binary in linux
kernel mode.
* src/abg-dwarf-reader.cc (typedef address_set_type)
(address_set_sptr): New typedefs.
(get_binary_load_address): The load address of the binary is
the load address specified by the program header that is at the
smallest offset; not by the program header that is at offset zero.
(read_context::{ksymtab_section_, ksymtab_gpl_section_,
linux_exported_fn_syms_, linux_exported_var_syms_,
linux_exported_gpl_fn_syms_, linux_exported_gpl_var_syms_,
load_in_linux_kernel_mode_}): New data members.
(read_context::read_context): Initialize ksymtab_section_,
ksymtab_gpl_section_ and load_in_linux_kernel_mode_.
(read_context::{find_symbol_table_section, find_opd_section,
lookup_elf_fn_symbol_from_address,
lookup_elf_var_symbol_from_address, get_function_address,
get_variable_address}): Make these const.
(read_context::{find_ksymtab_section, find_ksymtab_gpl_section,
lookup_elf_symbol_from_address, function_symbol_is_exported,
variable_symbol_is_exported, linux_exported_fn_syms,
create_or_get_linux_exported_fn_syms, linux_exported_var_syms,
create_or_get_linux_exported_var_syms, linux_exported_gpl_fn_syms,
linux_exported_gpl_var_syms,
create_or_get_linux_exported_gpl_fn_syms,
linux_exported_gpl_var_syms,
create_or_get_linux_exported_gpl_var_syms, architecture_word_size,
load_kernel_symbol_table, load_ksymtab_symbols,
load_ksymtab_gpl_symbols,
load_linux_specific_exported_symbol_maps,
load_in_linux_kernel_mode}): New member functions.
(read_context::read_int_from_array_of_bytes): Factorize this
new member function out of ...
(read_context::{lookup_ppc64_elf_fn_entry_point_address}):
... this. Make this function const too.
(read_context::read_uint64_from_array_of_bytes): New function.
Uses read_int_from_array_of_bytes above.
(read_context::{fun_entry_addr_sym_map_sptr}): Try to load symbol
maps only when it's necessary.
(read_context::elf_architecture_is_big_endian): Fix logic.
(read_context::{var_addr_sym_map}): Express the const variant in
terms of the non-const one. In the non-const one, load the map
only when necessary.
(read_context::load_symbol_maps_from_symtab_section): Renamed
load_symbol_maps into this.
(read_context::is_linux_kernel_binary): Define new member
function.
(read_context::{function, variable}_symbol_is_exported): If we are
not prevented from considering loading in linux kernel mode, then
just looking at a linux kernel binary makes us consider the
special kernel sections.
(read_debug_info_into_corpus): Likewise.
(build_ir_node_from_die): Take a new flag that says if the ir node
is a declaration required by another concrete IR node.
(enum read_context::kernel_symbol_table_kind): New enum.
(read_context::load_symbol_maps): Support loading linux kernel
specific sections too.
(build_var_decl): Use the new
read_context::variable_symbol_is_exported.
(function_is_suppressed): Suppress non-member functions or
variables that are not declarations and that have no symbol.
(variable_is_suppressed, build_var_decl_if_not_suppressed): Take a
new flag that says if the variable is a declaration required by a
concrete variable. If non member variable that is a declaration
is not the specification of another concrete variable, then it's
suppressed.
(add_fn_symbols_to_map, add_var_symbols_to_map): New function
definitions.
(read_debug_info_into_corpus): If we are reading linux kernel or
linux kernel modules, only set explicitely exported symbols (in
the linux kernel binary sense) as exported function or variable
symbols.
(create_read_context): Take a new flag to say if the context is to
read an ELF binary in linux kernel mode.
* tools/abidiff.cc (options::options): Initialize
options::linux_kernel_mode to true.
(display_usage): Display usage of the --no-linux-kernel-mode option.
(parse_command_line): Parse the --no-linux-kernel-mode option.
* tools/abidw.cc (options::options): Initialize
options::linux_kernel_mode to true.
(display_usage): Display usage of --no-linux-kernel-mode option.
(parse_command_line): Parse the --no-linux-kernel-mode option.
* doc/manuals/abidiff.rst: Document the new --no-linux-kernel-mode
options.
* doc/manuals/abidw.rst: Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
2017-01-06 Dodji Seketeli <dodji@redhat.com>
Add debug routines to dump locations to a stream
* src/abg-writer.cc (dump_location): Define new function and one
overload.
(dump_decl_location): Re-write in terms of the new dump_location.
2017-01-06 Dodji Seketeli <dodji@redhat.com>
Better de-duplicate classes, unions, enums in non-odr contexts
* src/abg-dwarf-reader.cc (build_enum_type)
(add_or_update_class_type, add_or_update_union_type): When the ODR
is not relevant, use the location of the type to detect if two
enum, class or union types of the same name actually represent the
same type.
2017-01-06 Dodji Seketeli <dodji@redhat.com>
Adjust some reference outputs of the test-read-dwarf test harness
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2017-01-04 Ondrej Oprala <ondrej.oprala@gmail.com>
Bug 18754 - Add the "--no-added-syms" option to abidiff
* doc/manuals/abidiff.rst: Document the new --no-added-syms
option.
* tools/abidiff.cc (struct options): Add show_added_syms and
set it to true by default.
(display_usage): Document the new options --no-added-syms. If
this is the only suppression option specified, it is equivalent
to specifying --show_{changed,deleted}_{fns,vars} as arguments
to abidiff. If any of those options are specified before
--no-added-syms, then it has no effect.
(parse_command_line): Parse the new option and set
show_added_{fns,vars,syms} and show_all_{fns,vars} to false if
--no-added-syms is specified.
* tests/test-diff-filter.cc: Add a test for the new option.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-0.txt:
Reference results for the new test.
* tests/data/test-diff-filter/test35-pr18754-no-added-syms-report-1.txt:
Likewise.
* tests/data/Makefile.am: Add the above test files to the list of
test data.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Update copyright year on a bunch of files
* include/abg-corpus.h: Update copyright year to 2017.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tools/abicompat.cc: Likewise.
* tools/abidw.cc: Likewise.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
[apidoc] Allow brief description at the top of class description pages
* doc/api/libabigail.doxy: Don't disable "brief member desc".
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-corpus.h: Remove corpus_sptr typedef. It's in
abg-fwd.h now.
* src/abg-ir.cc: Remove some unnecessary vertical space.
* src/abg-reader.cc (build_function_decl): Cleanup some asserts.
* src/abg-writer.cc (write_function_type): Each the inspection of
the type id from within the debugger.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Misc comments and apidoc fixes
* src/abg-dwarf-reader.cc (lookup_symbol_from_gnu_hash_tab): Fix
typo in comment.
* tools/abicompat.cc (perform_compat_check_in_weak_mode): Better
comments.
* tools/abidw.cc (dislay_usage): Fix white spaces.
Conflicts:
tools/abidw.cc
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Speedup set_member_is_static
* src/abg-ir.cc (set_member_is_static): When comparing data
members, consider only their names.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Avoid unnecessary updates to type lookup maps
* src/abg-ir.cc (class_or_union::get_is_declaration_only): Try
to update the type maps only when a declaration-only class
type is now defined.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Update tests/data/test-read-dwarf/*.abi files
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Update tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Update.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
[abixml writer] Make sure all function types are emitted
* src/abg-writer.cc (write_translation_unit): Fix logic to avoid
forgetting referenced function types.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
[abixml writer] Fix comparison of pointer to types
* src/abg-writer.cc (type_ptr_comp::operator()): Do not add an
empty type id string to the type -> type id map when the entry for
a given type is empty.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Don't early canonicalize function types
* src/abg-dwarf-reader.cc (maybe_canonicalize_type):
Late-canonicalize function types.
signed-off-by: Dodji Seketeli <dodji@redhat.com>
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Fix qualified name caching for some types
* src/abg-ir.cc ({qualified, pointer,
array}_type_def::get_qualified_name): Don't cache internal and
non-internal qualified name when the type is not canonicalized.
2017-01-04 Dodji Seketeli <dodji@redhat.com>
Cleanup ODR-based type canonicalization optimization gating logic
* src/abg-ir.cc (type_base::get_canonical_type_for): Make it clear
that the ODR-based optimization is allowed only on C++ ABI
corpora.
2017-01-04 Dodji Seketeli <dodji@redhat.com>
Fix a typo in method name computation
* src/abg-ir.cc (get_method_type_name): Really return the method
name.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Update tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Adjust.
2017-01-05 Dodji Seketeli <dodji@redhat.com>
Update tests/data/test-read-write/test27.xml
* tests/data/test-read-write/test27.xml: Adjust.
2017-01-04 Dodji Seketeli <dodji@redhat.com>
[dwarf-reader] Handle per translation-unit type de-duplication
* src/abg-dwarf-reader.cc
(read_context::per_tu_name_artefacts_map_): New data member.
(read_context::clear_per_translation_unit_data): Clear the new
read_context::per_tu_name_artefacts_map_.
(read_context::associate_die_to_decl): Take a flag to say if we
should associate a DIE to its representation and another one to
say if the association should be done per-tu or per-corpus.
(read_context::lookup_{type_artifact, artifact}_from_die): Update
apidoc.
(read_context::lookup_artifact_from_die_representation): Likewise.
(read_context::{associate_die_to_artifact_by_repr,
associate_die_to_artifact_by_repr_internal,
associate_die_to_type}): Take a flag to say if the associating
should be done on a per-tu basis.
(read_context::lookup_{type_artifact, artifact}_from_die_per_tu):
New member functions.
(read_context::{lookup_artifact_from_per_tu_die_representation,
odr_is_relevant}): Likewise.
(build_enum_type, add_or_update_class_type)
(add_or_update_union_type): If ODR is not relevant, do not perform
per-corpus de-duplication.
(build_pointer_type_def, build_typedef_type): Do not associate the
type to its representation as these kinds of typs are not
de-duplicated.
(build_function_type): If ODR is not relevant, perform per-tu
de-duplication. When ODR is relevant, per-corpus de-duplication
is performed.
(build_or_get_fn_decl_if_not_suppressed): Function decls are
always de-duplicated per-corpus.
(build_ir_node_from_die): For data members, do not update the die
representation map as data members are not de-duplicated. Do not
do it for function decls either.
[1]: https://en.wikipedia.org/wiki/One_Definition_Rule
2017-01-02 Dodji Seketeli <dodji@redhat.com>
Handle per translation unit and per corpus types maps
* include/abg-fwd.h (lookup_type_in_corpus): Remove. This is to
be replaced by the new lookup_type below.
(lookup_{basic, class, union, enum, typedef, qualified, pointer,
reference, array, function, class_or_typedef,
class_typedef_or_enum}_type):
(lookup_class_type_through_scopes, lookup_type)
(lookup_type_through_scopes, lookup_or_synthesize_fn_type)
* src/abg-ir-priv.h (struct translation_unit::priv): Move this
private type here, from abg-ir.h.
(synthesize_type_from_translation_unit): Declare new functions.
* include/abg-ir.h (class type_maps): Define new type.
(translation_unit::get_function_types): Remove.
(translation_unit::get_types): Now return a type_maps.
(translation_unit::get_live_fn_types): Declare new type.
(class decl_base): Make canonicalize be a friend of this class.
* src/abg-ir.cc (struct translation_unit::priv): Move this to
abg-ir-priv.h
(struct type_maps::priv): Define new type.
(type_maps::{basic, class, union, enum, typedef, qualified,
pointer, reference, array, function}_types): Define new accessors.
(translation_unit::bind_function_type_life_time): Adjust.
(translation_unit::get_function_types): Remove accessor.
(translation_unit::get_types, get_live_fn_types): Define new
accessors.
(lookup_type_in_translation_unit)
(lookup_class_type_in_translation_unit)
(lookup_function_type_in_translation_unit)
(synthesize_type_from_translation_unit)
(synthesize_function_type_from_translation_unit)
(lookup_class_type_in_translation_unit) Remove function
definitions.
(lookup_type_in_map): Define function template.
(lookup_{basic, class, union, typedef, class_or_typedef,
class_typedef_or_enum, qualified, pointer, reference, array,
function}_type): Define functions.
(lookup_function_type, lookup_type_through_scopes)
(lookup_class_type_through_scopes)
(lookup_basic_type_through_translation_units)
(lookup_union_type_through_translation_units)
(lookup_enum_type_through_translation_units)
(lookup_class_type_through_translation_units)
(lookup_typedef_type_through_translation_units)
(lookup_qualified_type_through_translation_units)
(lookup_pointer_type_through_translation_units)
(lookup_reference_type_through_translation_units)
(lookup_array_type_through_translation_units)
(lookup_function_type_through_translation_units)
(lookup_type_through_translation_units)
(lookup_or_synthesize_fn_type, lookup_type): Likewise.
(maybe_update_types_lookup_map)
(maybe_update_types_lookup_map<class_decl>)
(maybe_update_types_lookup_map<function_type>): Define function
template, specilizations and functions.
(synthesize_type_from_translation_unit)
(synthesize_function_type_from_translation_unit): Define
functions.
* include/abg-corpus.h (corpus::get_types): Declare new accessor.
* src/abg-corpus.cc (corpus::priv::get_types): Define new
accessor.
(corpus::get_types): Likewise.
(lookup_type_in_corpus, lookup_class_type_in_corpus)
(lookup_type_in_corpus, lookup_function_type_in_corpus)
(maybe_update_types_lookup_map)
(maybe_update_types_lookup_map<class_decl>)
(maybe_update_types_lookup_map<function_type>): Remove.
(lookup_{basic, class, union, enum, typedef, qualified, pointer,
reference, array, function, class_or_typedef,
class_typedef_or_enum}_type): Likewise.
* src/abg-corpus-priv.h (corpus::priv::{basic, class, union,
typedef, qualified, pointer, reference, array, function}_types):
Remove these data members.
(corpus::priv::get_scopes): Remove member function.
(corpus::priv::get_{basic, class, union, enum, typedef, qualified,
pointer, reference, array, function}_types): Remove member
function declarations.
(corpus::priv::types_): New data member.
(corpus::priv::get_types): Declare new member function.
(lookup_{basic, class, enum, typedef, class_or_typedef, qualified,
pointer, reference, array, function}_type): Declare new functions.
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes)
(build_translation_unit_and_add_to_ir): Adjust use of
lookup_class_type.
* src/abg-reader.cc (read_context::type_is_from_translation_unit):
Adjust to the use of lookup_function_type_in_translation_unit that
got renamed into lookup_function_type.
* src/abg-writer.cc (type_ptr_cmp::operator()): New operator
implementation.
(read_context::sort_type): Add new overloads.
(write_translation_unit): Adjust to get the function types from
the new translation_unit::get_live_fn_types and sort them.
* tools/abicompat.cc (perform_compat_check_in_weak_mode): Adjust
to use the new lookup_or_synthesize_fn_type, in lieu of
lookup_function_type_in_corpus. Adjust to use lookup_type in lieu
of lookup_type_in_corpus.
2016-12-21 Dodji Seketeli <dodji@redhat.com>
Make abg-fwd.h use *_sptr typedefs
* include/abg-ir.h: Move convience typedef declarations and some
necessary forward declarations to ...
* include/abg-fwd.h: ... here.
(is_enum_type, is_var_decl): Take a pointer to type_or_decl_base.
(lookup_type_in_scope): Return a type_base_sptr.
(lookup_type_through_scopes): Introduce this to later replace the
overload of lookup_type_in_translation_unit that takes a list of
strings.
(lookup_type_in_scope): Return a type_base_sptr, not a
decl_base_sptr.
* src/abg-ir.cc (lookup_type_in_scope, lookup_node_in_scope)
(lookup_var_decl_in_scope): Adjust.
(is_enum_type, is_var_decl): Take a pointer to type_or_decl_base.
(lookup_node_in_scope): Return a type_or_decl_base_sptr.
(lookup_type_in_scope): Return a type_base_sptr.
(lookup_node_in_translation_unit): Return a
type_or_decl_base_sptr.
(lookup_type_through_scopes): Replace
lookup_type_in_translation_unit.
2016-12-18 Chenxiong Qi <cqi@redhat.com>
Fix wrong variable name
* tools/fedabipkgdiff: (diff_latest_rpms_based_on_distros): Fix
wrong variable name distro.
2016-12-18 Chenxiong Qi <cqi@redhat.com>
Warn properly when cannot find peer RPM
* tools/fedabipkgdiff: (RPMCollection.get_peer_rpm): Return None
when cannot find peer RPM due to nonexistent arch.
2016-12-19 Chenxiong Qi <cqi@redhat.com>
Read Koji config via Koji API
* tools/fedabipkgdiff: Read DEFAULT_KOJI_TOPURL and
DEFAULT_KOJI_SERVER from Koji config via Koji API read_config.
(build_commandline_args_parser): --topdir is renamed to
--topurl.
* doc/manuals/fedabipkgdiff.rst: Rename --topdir to --topurl.
2016-12-19 Chenxiong Qi <cqi@redhat.com>
Follow moved packages when download
* tools/fedabipkgdiff: (download_rpm) Add --location to curl
CLI.
2016-12-13 Chenxiong Qi <cqi@redhat.com>
More document for local RPMs comparison
* doc/manuals/fedabipkgdiff.rst: Add more document for local RPMs
comparison. Also fixed a typo.
2016-12-15 Ondrej Oprala <ondrej.oprala@gmail.com>
Properly report missing files for abipkgdiff
* tools/abipkgdiff.cc: (class options): Add the "nonexistent_file" flag
(parse_command_line): Check if the files given exist.
(main): Check the nonexistent_file flag. If any of the input
files don't exist, report it and exit. Also, for present and future test
uniformity, only show the base names of the packages when using their
names in error output.
* tests/test-diff-pkg.cc: Add a new regression test.
* tests/data/test-diff-pkg/test-nonexistent-report-0.txt: The
expected output of the above regression test.
* tests/data/Makefile.am: Add the above file to the list.
2016-12-15 Dodji Seketeli <dodji@redhat.com>
Misc style cleanup
* src/abg-dwarf-reader.cc (build_function_type): Remove
unnecessary new line.
2016-12-15 Dodji Seketeli <dodji@redhat.com>
make is_anonymous_type work for unions and classes
* src/abg-ir.cc (is_anonymous_type): Make this work for class or
union types, no only classes.
2016-12-15 Dodji Seketeli <dodji@redhat.com>
Naming typedefs of classes are not read properly from abixml
* src/abg-reader.cc (build_class_decl): Use
read_context::build_or_get_type_decl rather than
read_context::get_type_decl to build the naming typedef referred
to by the class being built. Move the handling of naming typedefs
after the class is marked as WIP and keyed.
2016-12-15 Dodji Seketeli <dodji@redhat.com>
Don't early-canonicalize function types when reading abixml
* src/abg-reader.cc (read_context::maybe_canonicalize_type):
late-canonicalize function types too.
2016-12-12 Ondrej Oprala <ondrej.oprala@gmail.com>
Check --enable-rpm dependencies more rigorously
* configure.ac: Check if both rpm2cpio and cpio
exist on the system. If not, disable the option and fail the
configuration if --enable-rpm was specified explicitly.
2016-12-12 Ondrej Oprala <ondrej.oprala@gmail.com>
abipkgdiff doesn't mention --no-default-suppression in help
* tools/abipkgdiff.cc (display_usage): Mention
--no-default-suppression as one of the options.
2016-12-12 Ondrej Oprala <ondrej.oprala@gmail.com>
Fix a few remarks made by cppcheck
* src/abg-comparison.cc (types_or_decls_equal::operator()): Pass
arguments by reference.
(class_diff::ensure_lookup_tables_populated): Expression
!A || (A && B) can be reduced to !A || B.
* src/abg-suppression.cc (suppression_matches_type_no_name):
Likewise.
2016-12-09 Ondrej Oprala <ondrej.oprala@gmail.com>
Bug 19272 - abipkgdiff doesn't report arch change
* src/abg-comparison.cc (corpus_diff::has_incompatible_changes):
The architecture change into account.
(corpus_diff::has_net_changes): Take architecture and soname
changes into account.
* tools/abicompat.cc (perform_compat_check_in_normal_mode): Use
corpus_diff::{has_net_changes, has_incompatible_changes}.
* tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.armv7hl.rpm: New
test input.
* tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64--dbus-glib-0.104-3.fc23.armv7hl-report-0.txt:
New test reference output.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-pkg.cc (in_out_spec): Compare the new package
above against an x86_64 one.
2016-08-11 Chenxiong Qi <cqi@redhat.com>
Bug 20380 - Compare two local RPMs
* configure.ac: add dependent mimetype module.
* doc/manuals/fedabipkgdiff.rst: Update to add document for the
new use case of comparing two local RPMs.
* tests/data/Makefile.am: Include new RPMs for tests.
* tests/data/test-fedabipkgdiff/dbus-glib/dbus-glib-0.100.2-2.fc20.x86_64.rpm:
New RPM for running test.
* tests/data/test-fedabipkgdiff/dbus-glib/dbus-glib-0.106-1.fc23.x86_64.rpm:
Likewise.
* tests/data/test-fedabipkgdiff/nss-util/nss-util-3.12.6-1.fc14.x86_64.rpm:
Likewise.
* tests/data/test-fedabipkgdiff/nss-util/nss-util-3.24.0-2.0.fc25.x86_64.rpm:
Likewise.
* tests/data/test-fedabipkgdiff/nss-util/nss-util-devel-3.24.0-2.0.fc25.x86_64.rpm:
Likewise.
* tests/data/test-fedabipkgdiff/test4-glib-0.100.2-2.fc20.x86_64.rpm-glib-0.106-1.fc23.x86_64.rpm-report-0.txt:
Rename filename by adding .rpm extension.
* tests/data/test-fedabipkgdiff/test5-same-dir-dbus-glib-0.100.2-2.fc20.x86_64--dbus-glib-0.106-1.fc23.x86_64-report-0.txt:
New reference output for testing comparing local RPMs.
* tests/data/test-fedabipkgdiff/test6-missing-devel-debuginfo-nss-util-3.12.6-1.fc14.x86_64--nss-util-3.24.0-2.0.fc25.x86_64-report-0.txt:
New reference output for testing comparison without non-existent
debuginfo or development package.
* tests/runtestfedabipkgdiff.py.in (FEDABIPKGDIFF_TEST_SPECS):
Rename filename for test4. Add two new test cases.
(run_fedabipkgdiff_tests): Remove semicolon and trailing
whitespaces.
(main): Likewise.
(ensure_output_dir_created): Likewise.
* tools/fedabipkgdiff: Require some new modules.
Fix of return code.
(PkgInfo): Renamed to ComparisonHalf.
(match_nvr): New method to determine if a string matches format
of N-V-R.
(match_nvra): New method to determine if a string matches format
of N-V-R.A.
(is_rpm_file): New method to guess if a file is a RPM file.
(RPM.is_peer): New method to determine if current RPM is a peer
of another.
(RPM.filename): Use Koji module API to construct the filename.
(RPM.nvra): Get nvra from filename instead of constructing
manually that is duplicated with Koji module API.
(RPMCollection): New class to represent a set of RPMs.
(generate_pkg_info_pair_for_abipkgdiff): New method working as a
generator to yeild comparison halves for running abipkgdiff.
(Brew.getRPM): Fix string format with incorrect argument.
(Brew.select_rpms_from_a_build): Return instance of
RPMCollection.
(abipkgdiff): If there is no debuginfo or development package,
just ignore it and leave a warning. If --error-on-warning is
specified, raise an exception instead. Arguments are modified
to represent the new name ComparisonHalf, and relative docstring
is also updated.
(magic_construct): Removed.
(run_abipkgdiff): Rewrite.
(make_rpms_usable_for_abipkgdiff): Removed.
(diff_local_rpm_with_latest_rpm_from_koji): Rewrite by using
RPMCollection.
(diff_latest_rpms_based_on_distros): Likewise.
(diff_two_nvras_from_koji): Likewise.
(diff_from_two_rpm_files): New method to compare two local RPMs.
(build_commandline_args_parser): Add new option
--error-on-warning.
(main): Add support to compare local RPMs.
2016-12-12 Dodji Seketeli <dodji@redhat.com>
Fix template_decl::hash::operator()
* src/abg-hash.cc (template_decl::hash::operator()): Combine the
contribution of the qualified name to the contribution of the type
name to the hash.
2016-12-09 Dodji Seketeli <dodji@redhat.com>
Fix aborting when reading .foo symbols from a ppc64 binary
* abg-dwarf-reader.cc (read_context::find_opd_section): Fix
comment.
(read_context::load_symbol_maps): If for a given function entry
point (that we got by looking at the ".opd" section for a given
function pointer value) we already had an entry in the
function_entry_address -> symbol, maybe it means that the previous
entry that we had was from an entry in the symbol table which
value was directly the entry point address of a function. In that
case, if the name of the symbol is "foo", the name of the symbol
which value is directly the entry point address is ".foo". What
we do in this case is that we just keep the reference to the "foo"
symbol in the function_entry_address -> symbol map.
(read_context::address_is_in_opd_section): Define new member
function.
* tests/data/test-diff-pkg/gmp-4.3.1-10.el6.ppc64.rpm: New test input.
* tests/data/test-diff-pkg/gmp-4.3.1-7.el6_2.2.ppc64.rpm: Likewise.
* tests/data/test-diff-pkg/gmp-debuginfo-4.3.1-10.el6.ppc64.rpm: Likewise.
* tests/data/test-diff-pkg/gmp-debuginfo-4.3.1-7.el6_2.2.ppc64.rpm: Likewise.
* tests/data/test-diff-pkg/gmp-4.3.1-7.el6_2.2.ppc64--gmp-4.3.1-10.el6.ppc64-report-0.txt:
New test reference output.
* tests/data/Makefile.am: Add the new test input and reference
output to source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test inputs
and reference output to the set of inputs that are compared.
2016-12-05 Dodji Seketeli <dodji@redhat.com>
Bug 20927 - Segfault when $HOME is not set
* src/abg-tools-utils.cc
(get_default_user_suppression_file_path): Handle the case where
the HOME environment variable is not set.
* tools/abipkgdiff.cc (package::extracted_packages_parent_dir):
Likewise. When $HOME is empty set then use $TMPDIR. If it's
empty too then use "/tmp".
2016-12-02 Dodji Seketeli <dodji@redhat.com>
Bug 20887 - Show relative change of offsets
* doc/manuals/abidiff.rst: Document the new
--no-show-relative-offset-changes.
* doc/manuals/abipkgdiff.rst: Likewise.
* include/abg-comparison.h
(diff_context::show_relative_offset_changes): New accessors.
* include/abg-ir.h ({set,get}_data_member_offset): Return uint64_t
instead of the less portable size_t.
* src/abg-comparison.cc
(diff_context::priv::show_relative_offset_changes_): New data
member.
(dif_context::show_relative_offset_changes): Define accessor.
(maybe_show_relative_offset_change): Define new function.
(represent): In the overload for var_diff, call the new
maybe_show_relative_offset_change.
(report_size_and_alignment_changes): If the size of the type
didn't change then say it now.
* src/abg-ir.cc (set_data_member_offset, get_data_member_offset):
Take or return a uint64_t instead of a size_t.
* tools/abidiff.cc (options::show_relative_offset_changes): New
data member.
(options::options): Initialize it.
(display_usage): Display help string for the new
--no-show-relative-offset-changes.
(parse_command_line): Parse the new
--no-show-relative-offset-changes options.
(set_diff_context_from_opts): Set the
"show-relative-offset-changes" flag according to the new option.n
* tools/abipkgdiff.cc (options::show_relative_offset_changes): New
data member.
(options::options): Initialize it.
(display_usage): Add help string for the new
--no-show-relative-offset-changes option.
(set_diff_context_from_opts): Set the
"show-relative-offset-changes" flag according to the new option.
(parse_command_line): Parse the new command line option.
* tests/data/test-diff-dwarf/test40-report-0.txt: Add new
reference output.
* tests/data/test-diff-dwarf/test40-v0.c: Source code of the first
test binary.
* tests/data/test-diff-dwarf/test40-v1.c: Source code of the
second test binay.
* tests/data/test-diff-dwarf/libtest40-v0.so: New first test binary.
* tests/data/test-diff-dwarf/libtest40-v1.so: New second test binary.
* tests/test-diff-dwarf.cc (in_out_spec): Add the new test
binaries above to the set of binaries that are compared.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/data/test-abicompat/test7-fn-changed-report-0.txt: Adjust.
* tests/data/test-abidiff/test-PR18791-report0.txt: Likewise.
* tests/data/test-abidiff/test-enum0-report.txt: Likewise.
* tests/data/test-abidiff/test-enum1-report.txt: Likewise.
* tests/data/test-abidiff/test-struct1-report.txt: Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test1-report.txt: Likewise.
* tests/data/test-diff-dwarf/test10-report.txt: Likewise.
* tests/data/test-diff-dwarf/test11-report.txt: Likewise.
* tests/data/test-diff-dwarf/test13-report.txt: Likewise.
* tests/data/test-diff-dwarf/test15-enum-report.txt: Likewise.
* tests/data/test-diff-dwarf/test27-local-base-diff-report.txt: Likewise.
* tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test38-union-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test4-report.txt: Likewise.
* tests/data/test-diff-dwarf/test5-report.txt: Likewise.
* tests/data/test-diff-dwarf/test6-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test1-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test16-report-2.txt: Likewise.
* tests/data/test-diff-filter/test16-report.txt: Likewise.
* tests/data/test-diff-filter/test17-0-report.txt: Likewise.
* tests/data/test-diff-filter/test17-1-report.txt: Likewise.
* tests/data/test-diff-filter/test18-report.txt: Likewise.
* tests/data/test-diff-filter/test19-enum-report-1.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test23-redundant-fn-parm-change-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test24-compatible-vars-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test25-cyclic-type-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test25-cyclic-type-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-0.t:
Likewise.xt
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-2.txt:
Likewise.
* tests/data/test-diff-filter/test29-finer-redundancy-marking-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test3-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Likewise.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test10-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test2-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test30-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0-1.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-8.txt: Likewise.
2016-12-02 Dodji Seketeli <dodji@redhat.com>
Rename tests/update-test-read-dwarf-output.py
* tests/update-test-output.py: renamed
tests/update-test-read-dwarf-output.py into this. Update its
comments. Make this script executable.
2016-11-30 Dodji Seketeli <dodji@redhat.com>
Add tests/data/test-diff-suppr/test33-report-0.txt to tarball
* tests/data/Makefile.am: Add test-diff-suppr/test33-report-0.txt.
2016-11-30 Dodji Seketeli <dodji@redhat.com>
Bug 20670 - abipkgdiff aborts if $XDG_CACHE_HOME does not exist
* tools/abipkgdiff.cc (package::extracted_packages_parent_dir):
Ensure that the cache directory is created, even when
XDG_CACHE_HOME is set. Also, remove the now useless "using
abigail::tools_utils::get_random_number_as_string" statement.
2016-11-09 Dodji Seketeli <dodji@redhat.com>
Very light speed improvements
* include/abg-comp-filter.h (has_harmless_name_change): Pass smart
pointers by reference.
* src/abg-comp-filter.cc (access_changed)
(function_name_changed_but_not_symbol)
(non_static_data_member_type_size_changed)
(static_data_member_type_size_changed, is_compatible_change)
(decl_name_changed, has_harmless_name_change): Pass smart
pointers by reference.
* include/abg-ir.h (decl_base::set_context_rel): Take a bare
pointer, not a smart pointer.
* src/abg-ir.cc (decl_base::priv::context_): Make this data member
be a naked pointer, not a smart pointer.
(decl_base::priv::priv): Initialize it.
(decl_base::priv::~priv): New constructor.
(decl_base::{get_context_rel, set_scope}): Adjust.
(class_decl::method_decl::{method_decl, set_scope}): Likewise.
(equals): In the overload for var_decl, compare the type of the
var first as that might be faster (to detect var_decls with
different types) in the general case where types are
canonicalized.
2016-11-08 Dodji Seketeli <dodji@redhat.com>
Introduce on-the-fly type canonicalization
* include/abg-ir.h (environment::do_on_the_fly_canonicalization):
Declare new member functions.
({type_base, function_type}::priv_): Make this public so that
static non-member functions defined in abg-ir.cc can access it.
* src/abg-ir.cc
(environment::priv::do_on_the_fly_canonicalization_): New data
member.
(environment::priv::priv): Initialize it.
(environment::do_on_the_fly_canonicalization): Define new member
functions.
(type_base::get_canonical_type_for): Trigger on-the-fly
canonicalization during comparison of the type being canonicalized
and an already canonicalized type.
(types_are_being_compared, maybe_propagate_canonical_type): Define
new static functions.
(equals): In overloads for class_decl and function_type, call
maybe_propagate_canonical_type when the two types compare equal.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2016-11-06 Dodji Seketeli <dodji@redhat.com>
Fix pretty representation of array types
* include/abg-ir.h (array_type_def::is_infinite): Fix indentation.
* src/abg-ir.cc (qualified_type_def::build_name): An empty set of
sub-ranges for a vector is represented by "[]".
(array_type_def::is_infinite): If a vector has no sub-range, that
means it has an infinite size. Adjust comment.
* tests/data/test-diff-filter/test33-report-0.txt: Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2016-10-11 Dodji Seketeli <dodji@redhat.com>
Support naming typedef and use them to speed up type canonicalization
* include/abg-ir.h (typedef_decl_wptr): New typedef.
(class_decl::{g,s}et_naming_typedef): Declare new member
functions.
* src/abg-dwarf-reader.cc (build_typedef_type): When the
underlying type of a typedef is an anonymous class, the class type
is said to have a naming typedef.
* src/abg-ir.cc (is_anonymous_type): An anonymous class that has
a naming typedef is said to not be anonymous anymore.
(class_decl::priv::naming_typedef): New data member.
(class_decl::{g,s}et_naming_typedef): Define new member functions.
(class_decl::get_pretty_representation): When called for internal
purposes (e.g, for type canonicalization) compute the pretty
representation of the class by using its typedef name, when class
is anonymous and has a naming typedef.
* src/abg-reader.cc (build_class_decl): Read the new
"naming-typedef-id" attribute.
* src/abg-writer.cc (write_naming_typedef): New function.
(write_class_decl_opening_tag): Use the new write_naming_typedef
function.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2016-11-02 Dodji Seketeli <dodji@redhat.com>
Implement de-duplication for types and decls at DWARF loading time
* include/abg-ir.h (method_type::priv_): Introduce new pimpl
pointer here.
(method_type::class_type_): Move this into the pimpl idiom.
(method_type::method_type): Take a new is_const flag.
(method_type::get_class_type): Make this method out-of-line.
(method_type::{s,g}et_is_const): Declare new member functions.
(get_method_type_name): Declare this function as a friend of
the method_type type.
* src/abg-dwarf-reader.cc: Include the new abg-ir-priv.h and
abg-corpus-priv.h.
(typedef die_tu_map_type): Fix comment.
(typedef die_istring_map_type): New typedef.
(class read_context::die_source_dependant_container_set): New
class template.
(read_context::{die_qualified_name_maps_, die_pretty_repr_maps_,
die_pretty_type_repr_maps_}): Define new data members.
(read_context::{get_die_qualified_name, get_die_qualified_name,
get_die_qualified_type_name, get_die_pretty_type_representation,
get_die_pretty_representation, lookup_type_artifact_from_die,
lookup_artifact_from_die, lookup_artifact_from_die_representation,
associate_die_to_artifact_by_repr,
associate_die_to_artifact_by_repr_internal,
lookup_type_from_die}): Define new member functions.
(read_context::lookup_type_from_die_offset): Fix comment.
(get_parent_die, get_scope_die, die_is_decl)
(die_is_namespace, die_is_unspecified, die_is_void_type)
(die_is_pointer_type, die_is_reference_type)
(die_is_pointer_or_reference_type, die_is_class_type)
(die_has_object_pointer, die_this_pointer_from_object_pointer)
(die_this_pointer_is_const, is_decl_tag)
(die_object_pointer_is_for_const_method, die_is_at_class_scope)
(die_name, die_qualified_type_name, die_qualified_decl_name)
(die_qualified_name, die_qualified_type_name_empty)
(die_return_and_parm_names_from_fn_type_die)
(die_function_signature, die_peel_qual_ptr)
(die_function_type_is_method_type, die_pretty_print_type)
(die_pretty_print_decl, die_pretty_print)
(build_subranges_from_array_type_die)
(build_or_get_fn_decl_if_not_suppressed)
(lookup_class_or_typedef_type)
(lookup_class_typedef_or_enum_type_from_corpus)
(is_function_for_die_a_member_of_class)
(add_or_update_member_function): Define new static functions.
(read_context::associate_die_to_decl): Call
associate_die_to_artifact_by_repr.
(read_context::{associate_die_to_type,
schedule_type_for_late_canonicalization}): Take just one "die"
parameter rather than taking a die offset and a die source; adjust
accordingly.
(maybe_canonicalize_type): Likewise.
(finish_member_function_reading): Take a const reference to
function_decl_sptr.
(die_loc_and_name): Use the new die_name function.
(die_is_type): Rename is_type_die into this.
(build_type_decl): Take a new "where_offset" parameter. Adjust.
If a type of the same name as the one for the current DIE is is
already present, do not create a new type; just return the
already-existing one.
(build_enum_type): Take a new "where_offset" parameter. Adjust.
(finish_member_function_reading): Pass two smart pointers by const
reference. Assert that the type of the member function is a
method_type. Some light cleanups.
(add_or_update_class_type): Rename build_class_type_and_add_to_ir.
If a DIE defining the same class has already been seen, then
return that class; don't construct any other internal
representation for the same class. Better handle the updating of
member data and functions. Do not duplicate member types.
(build_qualified_type, build_pointer_type_def)
(build_reference_type): Support de-duplication here.
(build_function_type): Likewise. Support detection and building
of method type. This also supports *const* method type building.
(build_array_type): Use the new
build_subranges_from_array_type_die.
(build_type_decl): Cleanup logic.
(build_or_get_var_decl_if_not_suppressed): Renamed
build_var_decl_if_not_suppressed into this. Perform
de-duplication for data members.
(build_function_decl): Don't set an empty source location. If the
function type cannot be constructed, do not construct the function
decl either. Adjust.
(build_ir_node_from_die): Adjust. When building a function for a
DW_TAG_subroutine_type DIE, use the new
build_or_get_fn_decl_if_not_suppressed.
* src/abg-ir.cc (translation_unit::bind_function_type_life_time):
Fix comment.
(strip_typedef): Adjust.
(qualified_type_def::build_name): Set the prefix name of a the
name of a noop qualifier to "noop-qual", just like what is done in
the new die_qualified_name function.
(struct method_type::priv): New priv type for the method_type
class.
(method_type::method_type): Take a new 'is_const' parameter.
Adjust as the method_type is now pimpl'ed.
(method_type::{get_class_type, set_is_const, get_is_const}):
Define new member functions.
(function_decl::get_pretty_representation_of_declarator): Better
detecter of const-ness.
(class_decl::insert_member_decl): Better setting of the
const-ness.
(class_decl::method_decl::method_decl): Adjust. Deduce the
const-ness of the method_decl from the const-ness of its
method_type.
(copy_member_function): Adjust.
(set_member_is_static): Do not assume a non-nil scope anymore
because member_decl can now be scope-less, at least for a little
while.
* src/abg-reader.cc (push_decl_to_current_scope): Adjust.
(build_function_decl): Style adjustment. Adjust for method_type
const-ness changes.
(build_function_type): Likewise. Also, support the new
"method-class-id" property that flags a function type as being a
method type.
* src/abg-writer.cc (write_function_decl): Style fixes.
(write_function_type): Likewise. Emit a new "method-class-id"
property for function type that is actually a method type. That
property's value is the id of the class of the method type.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi: Adjust.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test01-report.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt: Adjust.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Adjust.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt: Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2016-11-01 Dodji Seketeli <dodji@redhat.com>
Setup per-corpus type maps indexed by type names
* include/abg-corpus.h (corpus::priv_): Make this public so that
functions from outside of the class can access it. These
functions are meant to be used only by code that is *inside*
libabigail.so, though.
* src/abg-corpus-priv.h: New file.
* src/abg-corpus.cc: Include the new abg-corpus-priv.h file.
(struct regex_t_deleter): Move this to abg-sptr-utils.h.
(build_sptr<regex_t>): Move the declaration of this function
template specialization to abg-sptr-utils.h and its definition to
abg-sptr-utils.cc.
(typedef regex_t_sptrs_type, typedef str_var_ptr_map_type)
(struct corpus::exported_decls_builder::priv, struct
corpus::priv): Move these declarations to the new
abg-corpus-priv.h.
(maybe_update_types_lookup_map): Define overloads of this (one per
kind of type).
(lookup_{basic, class, enum, typedef, class_or_typedef,
class_typedef_or_enum, qualified, pointer, reference, array,
function}_type): Define new functions.
* include/abg-ir.h (typedef istring_type_base_wptr_map_type)
(typedef istring_type_or_decl_base_sptr_map_type): Declare new
typedefs.
(class_decl::find_member_function_from_signature): Declare new
member function.
* src/abg-ir.cc: Include the new abg-corpus-priv.h file.
(maybe_update_types_lookup_map): Remove this initial function.
There are now new overloads in abg-corpus.cc for it.
(scope_decl::{add_member_decl, insert_member_decl}): Adjust.
(class_decl::{set_is_declaration_only, find_member_function,
add_member_function}): Adjust.
(class_decl::find_member_function_from_signature): Define new
member function.
* include/abg-sptr-utils.h (struct regex_t_deleter): Declare new
type.
(build_sptr<regex_t>): New build function template
specializations.
* src/abg-sptr-utils.cc: New file.
* src/Makefile.am: Add src/abg-sptr-utils.cc and
src/abg-corpus-priv.h to the build system.
2016-11-01 Dodji Seketeli <dodji@redhat.com>
Allow pretty printing function decls for internal purposes
* include/abg-ir.h
(function_decl::get_pretty_representation_of_declarator): Take an
"internal" flag.
* src/abg-ir.cc
(function_decl::get_pretty_representation_of_declarator): Take an
"internal" flag.
(function_decl::get_pretty_representation): Pass the "internal"
flag to the function
function_decl::get_pretty_representation_of_declarator.
(function_decl::parameter::get_type_name): Better handle variadic
parameter type.
(function_decl::parameter::get_type_pretty_representation):
Likewise.
2016-11-26 Dodji Seketeli <dodji@redhat.com>
Make bash completion files non-executable
* bash-completion/abicompat: Make this be non-executable.
* bash-completion/abidiff: Likewise.
* bash-completion/abidw: Likewise.
* bash-completion/abilint: Likewise.
* bash-completion/abinilint: Likewise.
* bash-completion/abipkgdiff: Likewise.
* bash-completion/abisym: Likewise.
* bash-completion/fedabipkgdiff: Likewise.
2016-11-26 Dodji Seketeli <dodji@redhat.com>
A suppressed diff node implies suppressing all equivalent nodes too
*class of equivalence* is visited once. This is not only a way to
prevent infinite loops while visiting the graph, but also an
optimization as it avoids walking two equivalent diff nodes.
But then it can happen that we forget to categorize some diff nodes
inside a given class of equivalence, even though we categorized some
others.
This patch makes it so that when a diff node inside a class of
equivalence is categorized as SUPPRESSED, the canonical diff node of
that class of equivalence is categorized as SUPPRESSED too. That way,
to know if a diff node is suppressed, we just need to look at its
canonical diff node.
While doing this, I noticed that abidiff and abipkgdiff are not
dropping private types from libabigail's internal representation, even
though the Library now has that capability. The patch fixes that.
But then the patch adds a --dont-drop-private-types option to abidiff
to avoid dropping those private types from the IR, so that regression
tests can make sure that a suppressed diff node implies suppression
all equivalent nodes too.
* doc/manuals/abidiff.rst b/doc/manuals/abidiff.rst: Document the
new --dont-drop-private-types option.
* src/abg-comparison.cc (diff::is_filtered_out): If the canonical
type was suppressed then the current diff node is filtered out.
(suppression_categorization_visitor::visit_{begin,end}):
Categorized the canonical node as SUPPRESSED if the current node
is suppressed.
* tools/abidiff.cc (options::drop_private_types): New data member.
(options::options): Initialize it.
(display_usage): Add new help string for the new
--dont-drop-private-types option.
(parse_command_line): Parse the new --dont-drop-private-types
option.
(set_suppressions): Generate suppression specification from header
directories given in parameter and stick them to the read context.
* tools/abipkgdiff.cc (compare): Likewise.
* tests/data/test-diff-suppr/libtest34-v0.so: New test input.
* tests/data/test-diff-suppr/libtest34-v1.so: Likewise.
* tests/data/test-diff-suppr/test34-report-0.txt: New reference
report.
* tests/data/test-diff-suppr/test34-v0.c: Source code for the new
test input.
* tests/data/test-diff-suppr/test34-v1.c: Likewise.
* tests/data/test-diff-suppr/test34-priv-include-dir-v0/test34-priv-include-v0.h:
Likewise.
* tests/data/test-diff-suppr/test34-priv-include-dir-v1/test34-priv-include-v1.h:
Likewise.
* tests/data/test-diff-suppr/test34-pub-include-dir-v0/test34-pub-include-v0.h:
Likewise.
* tests/data/test-diff-suppr/test34-pub-include-dir-v1/test34-pub-include-v1.h:
Likewise.
* tests/data/Makefile.am: Add new test input material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_spec): Compare the two new test
library provided. Add --dont-drop-private-types to test30*.
signed-off-by: Dodji Seketeli <dodji@redhat.com>
2016-11-26 Dodji Seketeli <dodji@redhat.com>
Forgot to consider libtest33-v{0,1}.so in test-diff-suppr.cc
* tests/data/test-diff-suppr/test33-report-0.txt: New refernce report.
* tests/test-diff-suppr.cc (in_out_specs): Compare libtest33-v0.so
and libtest33-v1.so.
2016-11-24 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.0.rc7
* configure.ac: Bump version number to 1.0.rc7
2016-11-24 Dodji Seketeli <dodji@redhat.com>
Update website for 1.0.rc6
* doc/website/mainpage.txt: Update for 1.0.rc6 release
2016-11-23 Dodji Seketeli <dodji@redhat.com>
Update NEWS and ChangeLog for 1.0.rc6
* ChangeLog: Update this automatically using "make
update-changelog".
* NEWS: update this by editing the output of 'git shortlog
libabigail-1.0.rc5..HEAD'.
2016-11-24 Dodji Seketeli <dodji@redhat.com>
Avoid using size_t to get DWARF data
* src/abg-dwarf-reader.cc (die_size_in_bits, die_location_expr):
Take uint64_t rather than size_t and adjust.
(expr_result::const_value_): Make this be int64_t rather than
ssize_t.
(expr_result::expr_result): Take int64_t rather than ssize_t.
(expr_result::const_value): Return int64_t rather than ssize_t.
(expr_result::{operator(), operator=, operator+=}): Make these
operators return or take int64_t.
too.
(op_pushes_constant_value, op_manipulates_stack)
(op_is_arith_logic, op_is_control_flow)
(eval_last_constant_dwarf_sub_expr, die_member_offset)
(die_virtual_function_index): Take
uint64_t rather than size_t, or int64_t rather than ssize_t.
(finish_member_function_reading, build_class_type_and_add_to_ir)
(build_union_type_and_add_to_ir): Adjust.
2016-11-24 Dodji Seketeli <dodji@redhat.com>
Fix a compiler warning issued by GCC 6.2.1
* src/abg-dwarf-reader.cc (find_import_unit_point_between_dies):
Parameter 5 of find_import_unit_point_between_dies is not of type
Dwarf_Off.
2016-11-24 Dodji Seketeli <dodji@redhat.com>
Fix offset type mismatch
* src/abg-dwarf-reader.cc (die_member_offset): The last two
parameters of die_unsigned_constant_attribute must be of type
uint64_t.
2016-11-24 Dodji Seketeli <dodji@redhat.com>
Fix indentation in abg-writer.cc
* src/abg-writer.cc (write_union_decl_opening_tag): Fix
indentation.
2016-11-23 Dodji Seketeli <dodji@redhat.com>
Support reading data member offset from DW_AT_bit_offset
* src/abg-dwarf-reader.cc (die_member_offset): Better comments.
Support reading the bit offset also from the DW_AT_bit_offset
attribute when it's present. Make sure this always returns a
value in bits.
(build_class_type_and_add_to_ir): No need to multiply (by 8) the
value returned by die_member_offset anymore because it's now in
bits directly.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Adjust.
* tests/data/test-read-dwarf/test1.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Adjust.
2016-11-23 Dodji Seketeli <dodji@redhat.com>
Lexicographically sort union data members in change reports
* src/abg-comparison.cc (data_member_comp::operator()): Data
members with the same offset are sorted lexicographically, by
taking their name into account.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
2016-11-23 Dodji Seketeli <dodji@redhat.com>
Better diagnostics when wget is missing
* configure.ac: When wget is missing then make the disabling of
the building of the fedabipkgdiff tool show up in the
configuration summary and emit a notice.
2016-11-15 Dodji Seketeli <dodji@redhat.com>
Support union types
* include/abg-fwd.h (class_or_union, union_decl): Forward-declare
new types.
(is_class_or_union_type, is_union_type): Declare new functions.
* include/abg-ir.h (method_type::class_type_): Make this be of
class_or_union_wptr type.
(method_type::method_type): Make the class_type parameter be of
class_or_union_wptr type.
(method_type::{g,s}et_class_type): Take or return a
class_or_union_sptr.
(member_base, method_decl, member_function_template)
(member_class_template, member_base::hash)
(member_function_template::hash, member_class_template::hash):
Take these class types out of the class_decl scope.
(is_method_decl): Adjust.
(operator==, opertor!=): Adjust overloads for
member_function_template_sptr and member_class_template_sptr.
(class class_or_union): Declare new type.
(class class_decl): Make this class inherit class_or_union class.
(class_decl::{add_member_decl, insert_member_decl,
remove_member_decl, set_size_in_bits, get_size_in_bits,
get_alignment_in_bits, set_alignment_in_bits,
get_is_declaration_only, set_is_declaration_only,
set_definition_of_declaration, get_definition_of_declaration,
get_earlier_declaration, set_earlier_declaration,
insert_member_type, add_member_type, remove_member_type,
get_member_type, find_member_type, add_data_member,
get_data_members, find_data_member, get_non_static_data_members,
add_member_function, get_member_functions, find_member_function,
add_member_function_template, get_member_function_templates,
add_member_class_template, get_member_class_templates): Move these
to the parent class class_or_union.
(copy_member_function, equals): Add overloads for class_or_union.
(struct class_or_union::hash): Declare new type.
(class union_decl): Declare new type.
(equals, copy_member_function): New overloads for class union_decl
type.
(ir_node_visitor::visit): Add new overloads for union_decl* and
class_or_union*.
* src/abg-ir.cc (get_member_function_is_ctor)
(set_member_function_is_ctor, get_member_function_is_dtor)
(set_member_function_is_dtor, get_member_function_is_const)
(set_member_function_is_const, get_member_function_vtable_offset)
(set_member_function_vtable_offset)
(get_member_function_is_virtual, set_member_function_is_virtual)
(maybe_update_types_lookup_map, get_location)
(get_method_type_name, is_at_global_scope, is_at_class_scope):
Adjust.
(is_class_or_union_type, is_union_type): Define new functions.
(type_base::get_canonical_type_for, maybe_adjust_canonical_type)
(method_type::method_type, method_type::set_class_type)
(function_decl::get_pretty_representation)
(function_decl::get_first_non_implicit_parm)
(function_decl::clone): Adjust.
(equals): Adjust the overload for function_type.
(struct class_or_union::priv): Define new type.
(class::priv::{declaration_, definition_of_declaration_,
member_types_, data_members_, non_static_data_members_,
member_functions_, mem_fns_map_, member_function_templates_,
member_class_templates_, is_declaration_only_}): Move these data
member into class_or_union::priv.
(class_priv::{mark_as_being_compared, unmark_as_being_compared,
comparison_started}): Moved these member functions to
class_or_union::priv.
(class_or_union::{class_or_union, traverse, ~class_or_union,
add_member_decl, remove_member_decl, insert_member_type,
add_member_type, get_size_in_bits, remove_member_type,
get_alignment_in_bits, set_alignment_in_bits, set_size_in_bits,
get_is_declaration_only, set_is_declaration_only,
set_definition_of_declaration, get_definition_of_declaration,
get_earlier_declaration, set_earlier_declaration,
get_member_types, find_member_type, add_data_member,
get_data_member, find_data_member, add_member_function,
get_member_functions, find_member_function,
add_member_function_template, get_member_function_templates,
add_member_class_template, get_member_class_templates,
has_no_member, insert_member_decl, operator==}): Define new member
functions.
(class_decl::{add_member_decl, remove_member_decl,
insert_member_type, add_member_type, get_size_in_bits,
remove_member_type, get_alignment_in_bits, set_alignment_in_bits,
set_size_in_bits, get_is_declaration_only,
set_is_declaration_only, set_definition_of_declaration,
get_earlier_declaration, set_earlier_declaration,
get_member_types, find_member_type, add_data_member,
get_data_member, find_data_member, add_member_function,
get_member_functions, find_member_function,
add_member_function_template, get_member_function_templates,
add_member_class_template, get_member_class_templates): Move these
member functions into class_or_union.
(class_decl::{class_decl, get_definition_of_declaration,
insert_member_decl, add_member_function, has_no_base_nor_member}):
Adjust.
(equals, copy_member_function): Define new overloads for
class_or_union.
(equals): Adjust the overload for class_decl.
(method_decl::{method_decl, set_linkage_name, ~method_decl,
get_type, set_scope}): Remove from the class_decl scope.
(member_base::operator==, member_function_template::operator==):
Likewise.
(member_function_template::traverse)
(member_class_template::operator==)
(member_class_template::traverse): Likewise.
(operator==, operator!=): Adjust the overlod for
member_function_template_sptr.
(is_method_decl, fixup_virtual_member_function)
(set_member_is_static): Adjust.
(virtual_member_function_less_than::operator()): Likewise.
(union_decl::{union_decl, get_pretty_representation, operator==,
traverse}): Define new member functions.
(equals, copy_member_function): Define new overloads for
union_decl.
(hash_type_or_decl): Adjust.
(ir_node_visitor::visit_{begin, end}): Adjust. Add new overloads
for class_or_union* and union_decl*.
* include/abg-comparison.h (changed_member_function_sptr)
(string_member_function_sptr_map): Adjust these typedefs.
(class class_or_union_diff): Declare new type.
(class_diff): Adjust to make this inherit the new
class_or_union_diff type.
(class_diff::{get_priv, member_types_changes,
data_members_changes, inserted_data_members, deleted_data_members,
member_fn_tmpls_changes, member_fn_tmpls_changes,
member_class_tmpls_changes}): These member functions got moved
into -- and shared with -- class_or_union_diff class.
(class union_diff): Declare new type.
(typedef union_diff_sptr): New typedef.
(compute_diff): New overload for union_diff
(is_class_diff, is_union_diff): Declare new functions.
* src/abg-comparison.cc (is_class_diff, is_union_diff): Define new
functions.
(compute_diff_for_types): Support union_decl.
(represent): Adjust.
(represent_data_member): Do not show offset information for data
members of unions as all union data members are at offset 0.
(struct class_or_union_diff::priv): New type.
(class_or_union_diff::priv::{member_type_has_changed,
subtype_changed_dm, member_class_tmpl_has_changed,
get_deleted_non_static_data_members_number,
get_inserted_non_static_data_members_number,
count_filtered_subtype_changed_dm, count_filtered_changed_dm,
count_filtered_changed_mem_fns, count_filtered_inserted_mem_fns,
count_filtered_deleted_mem_fns}): Define new member functions.
(class_or_union_diff::{class_or_union_diff, finish_diff_type,
lookup_tables_empty, lookup_tables_empty,
ensure_lookup_tables_populated, allocate_priv_data, get_priv,
~class_or_union_diff, first_class_or_union, second_class_or_union,
member_types_changes, member_types_changes, data_members_changes,
inserted_data_members, deleted_data_members, member_fns_changes,
changed_member_fns, member_fns_changes, inserted_member_fns,
member_fn_tmpls_changes, member_fn_tmpls_changes,
member_class_tmpls_changes, member_class_tmpls_changes,
has_changes, has_local_changes, report, chain_into_hierarchy}):
Define new member functions.
(class_diff::priv::{member_types_changes_, data_members_changes,
member_fn_tmpls_changes_, member_class_tmpls_changes_,
deleted_member_types_, inserted_member_types_,
changed_member_types_, sorted_changed_member_types_,
deleted_data_members_, deleted_dm_by_offset_,
inserted_data_members_, inserted_dm_by_offset_,
subtype_changed_dm_, sorted_subtype_changed_dm_, changed_dm_,
sorted_changed_dm_, deleted_member_functions_,
inserted_member_functions_, changed_member_functions_,
sorted_changed_member_functions_, deleted_member_class_tmpls_,
inserted_member_class_tmpls_, changed_member_class_tmpls_,
sorted_changed_member_class_tmpls_}): Move these data members into
class_or_union_diff::priv.
(class_diff::{clear_lookup_tables, lookup_tables_empty,
ensure_lookup_tables_populate}): Adjust.
(class_diff::allocate_priv_data): Define new function.
(class_diff::priv::{count_filtered_changed_mem_fns,
count_filtered_inserted_mem_fns, count_filtered_deleted_mem_fns,
chain_into_hierarchy, class_diff}): Likewise.
(class_diff::{member_types_changes, data_members_changes,
inserted_data_members, deleted_data_members,
member_fn_tmpls_changes, member_fn_tmpls_changes,
member_class_tmpls_changes}): These are deleted as they got moved
to class_or_union_diff.
(class_diff::report): Adjust.
(union_diff::{clear_lookup_tables, lookup_tables_empty,
ensure_lookup_tables_populated, allocate_priv_data, union_diff,
finish_diff_type, first_union_decl, second_union_decl,
get_pretty_representation, report}): Define new functions.
(compute_diff): Define an overload for union_decl_sptr.
(function_decl_diff::report): Adjust.
(corpus_diff::priv::apply_suppressions_to_added_removed_fns_vars):
Adjust.
(corpus_diff::report): Adjust.
* src/abg-hash.cc (member_base::hash::operator)
(member_function_template::hash::operator)
(member_class_template::hash::operator): Move these out of the
class_decl scope.
(class_or_union::hash::operator): Define new member function.
(class_decl::hash::operator): Adjust.
(type_base::dynamic_hash::operator): Support hashing of
union_decl. Adjust.
* src/abg-suppression.cc (type_suppression::suppresses_diff):
Adjust.
* src/abg-dwarf-reader.cc (typedef die_class_or_union_map_type):
Define new typedef.
(read_context::{die_wip_classes_map_,
alternate_die_wip_classes_map_, type_unit_die_wip_classes_map_):
Make these data member have type die_class_or_union_map_type.
(read_context::{lookup_type_from_die_offset, die_wip_classes_map,
is_wip_class_die_offset, resolve_declaration_only_classes}):
Adjust.
(finish_member_function_reading, build_class_type_and_add_to_ir)
(build_function_type, build_function_decl, build_reference_type)
(type_is_suppressed, build_function_decl)
(maybe_canonicalize_type, maybe_set_member_type_access_specifier):
Adjust.
(build_union_type_and_add_to_ir): Define new static function.
(build_ir_node_from_die): Support DW_TAG_union_type DIE tag.
* src/abg-reader.cc (handle_element_node): Handle union_decl.
(build_function_decl, build_function_decl_if_not_suppressed):
Adjust.
(build_union_decl_if_not_suppressed, build_union_decl)
(handle_union_decl): Define new functions.
(build_class_decl): Adjust.
* src/abg-writer.cc (record_decl_only_type_as_emitted): Adjust.
(write_decl): Adjust. Support writting union_decl type.
p (write_class_decl_opening_tag, write_class_decl): Adjust. Call
the new write_class_or_union_is_declaration_only.
(write_union_decl_opening_tag, write_union_decl): Define new
static functions.
(write_member_tpe): Support writting union decl.
* tests/test-diff-dwarf.cc (in_out_specs): Add new tests for this
union type support.
* tests/data/test-diff-dwarf/libtest37-union-v0.so: New test input.
* tests/data/test-diff-dwarf/libtest37-union-v1.so: Likewise.
* tests/data/test-diff-dwarf/libtest38-union-v0.so: Likewise.
* tests/data/test-diff-dwarf/libtest38-union-v1.so: Likewise.
* tests/data/test-diff-dwarf/libtest39-union-v0.so: Likewise.
* tests/data/test-diff-dwarf/libtest39-union-v1.so: Likewise.
* tests/data/test-diff-dwarf/test37-union-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test38-union-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test39-union-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test37-union-v0.cc: Source code for
new test input.
* tests/data/test-diff-dwarf/test37-union-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test38-union-v0.cc: Likewise.
* tests/data/test-diff-dwarf/test38-union-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test39-union-v0.cc: Likewise.
* tests/data/test-diff-dwarf/test39-union-v1.cc: Likewise.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
Update test reference.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-read-dwarf/libtest23.so.abi: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi:
Likewise.
2016-11-10 Dodji Seketeli <dodji@redhat.com>
Support empty properties in INI files
* include/abg-ini.h (simple_property::simple_property): Add a new
constructor for empty values.
(simple_property::has_empty_value): Declare new member function.
* src/abg-ini.cc (simple_property::{simple_property,
has_empty_value}): Define new member functions.
(read_context::read_property): Support reading a property with no
value.
(write_property_value, write_property): Support writting a
property with empty value.
2016-11-10 Dodji Seketeli <dodji@redhat.com>
Rename config::property_vector into config::properties_type
* include/abg-ini.h (config::properties_type): Rename the typedef
config::property_vector into this.
(config::section::{section, get_properties, set_properties}):
Adjust.
* src/abg-ini.cc (config::section::priv::properties_): Adjust the
name of its type.
(config::section::{section, get_properties, set_properties,
find_property}): Adjust.
(write_section): Adjust.
* src/abg-suppression.cc (read_function_suppression): Adjust.
2016-11-09 Dodji Seketeli <dodji@redhat.com>
Apply harmless and harmful filters in one pass
* include/abg-comp-filter.h (class harmless_harmful_filter):
Decalre new class.
(typedef harmless_harmful_filter_sptr): Declare new typedef.
(class harmless_filter, class harmful_filter): Remove these class
declarations.
(typedef harmful_filter_sptr, harmless_filter_sptr): Remove these
typedefs.
* src/abg-comp-filter.cc (categorize_harmless_diff_node)
(categorize_harmful_diff_node): Define new static functions.
({harmless, harmful}_filter::{visit, visit_end}): Remove these
member functions.
(harmless_harmful_filter::{visit, visit_end}): Define new member
functions.
* src/abg-comparison.cc (diff_context::diff_context): Register the
new harmless_harmful_filter, and remove the premier
harmless_filter and harmful_filter.
# Please enter the commit message for your changes. Lines starting
# with '#' will be ignored, and an empty message aborts the
commit. # On branch kabidiff-dedup # Changes to be committed: #
(use "git reset HEAD <file>..." to unstage) # # modified:
include/abg-comp-filter.h # modified: src/abg-comp-filter.cc #
modified: src/abg-comparison.cc # # Untracked files: # (use "git
add <file>..." to include in what will be committed) # # diff.txt
# prtests/ # tests/data/test-read-dwarf/libtest23.so.abi.conflict
2016-11-08 Dodji Seketeli <dodji@redhat.com>
Avoid stripping typedefs too much
* src/abg-ir.cc (types_are_compatible)
(is_compatible_with_class_type): Do not strip typedefs. Just get
their leaf types.
2016-11-08 Dodji Seketeli <dodji@redhat.com>
Misc style cleanups in abg-ir.cc
* src/abg-ir.cc (equals): In overloads for function_type and
class_decl, avoid returning a constant when we can return a
variable like in the rest of the code.
2016-11-01 Dodji Seketeli <dodji@redhat.com>
Factorize out string representation of array_type_def::subrange_type
* src/abg-ir.cc (array_type_def::subrange_type::{as_string,
vector_as_string}): Define methods.
(array_type_def::get_subrange_representation): Use the new
vector_as_string method.
2016-11-01 Dodji Seketeli <dodji@redhat.com>
Factorize out parsing of integral types
* src/abg-ir-priv.h: New file.
* src/Makefile.am: Add abg-ir-priv.h to the build system.
* src/abg-ir.cc: Include the new abg-ir-priv.h header file.
(class_integral_type): Move this type
declaration to the new abg-ir-priv.h header.
(integral_type::modifiers_type): Make this non-static.
(parse_integral_type): This new overload is a factorized out of
...
(integral_type::integral_type): ... here.
2016-10-31 Dodji Seketeli <dodji@redhat.com>
Misc style fixes in abg-ir.cc
* src/abg-ir.cc (get_function_type_name,
get_pretty_representation): Misc style fixes.
2016-10-31 Dodji Seketeli <dodji@redhat.com>
Consider a method_decl as always being a member decl
* src/abg-ir.cc (is_member_decl): Consider a method decl as always
being a member decl.
(is_member_function): Use is_member_decl.
2016-10-31 Dodji Seketeli <dodji@redhat.com>
Cleanup void and variadic parameter type interfaces
* include/abg-ir.h (environment::{get_void_type,
get_variadic_parameter_type}): Renamed get_void_type_decl and
get_variadic_parameter_type_decl to these.
(environment::is_void_type): Remove the overload that takes a bare
pointer.
(environment::is_variadic_parameter_type): Declare new member
function.
* src/abg-ir.cc (environment::void_type_): Renamed the data member
void_type_decl_ into this.
(environment::variadic_marker_type_): Renamed the data member
variadic_marker_type_decl_ into this.
(environment::{get_void_type, get_variadic_parameter_type}):
Renamed get_void_type_decl and get_variadic_parameter_type_decl to
these.
(environment::is_void_type): Take a smart pointer now.
(environment::is_variadic_parameter_type): Define new member
function.
(synthesize_function_type_from_translation_unit): Adjust.
(function_decl::parameter::get_pretty_representation): Likewise.
* src/abg-comparison.cc (is_diff_of_variadic_parameter_type):
Adjust.
* src/abg-dwarf-reader.cc (build_function_type)
(build_ir_node_for_void_type): Likewise.
* src/abg-reader.cc (build_function_parameter)
(build_function_decl, build_function_type): Likewise.
2016-10-31 Dodji Seketeli <dodji@redhat.com>
Cleanup some entry points in abg-fwd.h
* include/abg-fwd.h (add_decl_to_scope): Pass the scope smart
pointer by reference.
(is_member_type): pass the type smart pointer by reference.
(is_function_decl, is_pointer_type, is_reference_type)
(is_qualified_type, is_function_type, is_method_type)
(is_array_type): Take a type_or_decl base pointer, rather than
either a decl_base or type_base pointer.
* include/abg-ir.h (translation_unit::set_corpus): Take a pointer
to non-const corpus.
(translation_unit::get_corpus): Add a non-const overload.
(type_or_decl_base::get_corpus): Likewise.
(type_or_decl_base::set_translation_unit): Take a pointer to
non-corpus translation_unit.
(type_or_decl_base::get_translation_unit): Add a non-const
overload.
(scope_decl::{add_member_decl, insert_member_decl}): Pass the
member smart pointer by reference.
(scope_decl::remove_member_decl): Take a non-const smart pointer.
(class_decl::add_member_decl): Pass the decl smart pointer by
reference.
(is_method_decl): Take pointer or reference to type_or_decl_base
rather than function_decl.
* src/abg-ir.cc (translation_unit::priv::corpus): Make this a
pointer to non-const corpus.
(translation_unit::set_corpus): Take a pointer to non-const
corpus.
(translation_unit::get_corpus): Add a non-const overload.
(translation_unit::get_global_scope): Adjust.
(translation_unit::bind_function_type_life_time): Adjust.
(type_or_decl_base::translation_unit): Make this a pointer to
non-const translation_unit.
(type_or_decl_base::get_corpus): Likewise.
(type_or_decl_base::set_translation_unit): Take a pointer to
non-corpus translation_unit.
(type_or_decl_base::get_translation_unit): Add a non-const
overload.
(is_member_type): pass the type smart pointer by reference.
(scope_decl::{add_member_decl, insert_member_decl}): Take a
reference to the member decl smart pointer. Adjust.
(class_decl::add_member_decl): Likewise.
(scope_decl::remove_member_decl): Take a non-const smart pointer.
(add_decl_to_scope): Pass the scope smart pointer by reference.
(is_decl, is_function_decl, is_pointer_type, is_reference_type)
(is_qualified_type, is_function_type, is_method_type)
(is_method_decl, is_array_type): Take a type_or_decl base pointer,
rather than either a decl_base or type_base pointer.
2016-10-31 Dodji Seketeli <dodji@redhat.com>
Fix abigail::ir::get_type_scope()
* src/abg-ir.cc (get_type_scope): Do not always return nil.
2016-10-27 Dodji Seketeli <dodji@redhat.com>
Bug 20740 Broken check for dwarf_getalt in configure.ac
* configure.ac: Add missing spaces around the "=" of a conditional
expression.
2016-10-11 Dodji Seketeli <dodji@redhat.com>
Canonicalize function types when reading from DWARF
* src/abg-dwarf-reader.cc (build_function_decl): Canonicalize
function types.
2016-10-11 Dodji Seketeli <dodji@redhat.com>
Misc cleanups here and there
* src/abg-dwarf-reader.cc (canonicalize_types_scheduled): Fix
identation.
* src/abg-reader.cc (build_class_decl): Use class_decl_sptr rather
than shared_ptr<class_decl>.
* src/abg-writer.cc (write_class_is_declaration_only)
(write_is_struct, write_decl, write_decl_in_scope)
(write_type_decl, write_qualified_type_def)
(write_pointer_type_def, write_reference_type_def)
(write_array_type_def, write_enum_type_decl, write_typedef_decl)
(write_elf_symbol, write_var_decl, write_function_decl)
(write_member_type_opening_tag, write_member_type)
(write_class_decl_opening_tag, write_class_decl): Cleanup
parameters to use the right typedef, rather than the long
shared_ptr<*> form. Pass the shared pointers by reference as
well.
2016-10-10 Dodji Seketeli <dodji@redhat.com>
Cleanup namespace importing in abg-interned-str.h
* include/abg-interned-str.h: Inject std::tr1::shared_ptr,
std::string and std::ostream inside the abigail namespace.
(interned_string::{interned_string, raw, operator==, operator!=,
operator<): Adjust.
(operator==, operator!=, operator<<, operator+): Adjust.
2016-10-07 Dodji Seketeli <dodji@redhat.com>
Cleanup functions to detect infinite comparison of class_decl
* src/abg-ir.cc (class_decl::priv::unmark_as_being_compared): In
the overload that takes a pointer to class_decl, re-use the
overload that takes a reference.
(class_decl::priv::comparison_started): Do not crash if the klass
pointer is nil.
(equals): In the overload for class_decl&, undef the RESULT macro
when it's not used anymore.
2016-10-07 Dodji Seketeli <dodji@redhat.com>
Cleanup class_decl inifite comparison detection
* src/abg-ir.cc (environment::priv::classes_being_compared_): Make
this use the new interned_string_set_type type.
(class_decl::priv::{mark_as_being_compared, comparison_started}):
Adjust.
2016-10-10 Dodji Seketeli <dodji@redhat.com>
Apply ODR-based type comparison optimization to function types
* src/abg-ir.cc (type_eligible_for_odr_based_comparison):
Factorize this out of type_base::get_canonical_type_for. Also,
add function types to the set of types to use the ODR-based
comparison optimization on.
(type_base::get_canonical_type_for): Use the new
type_eligible_for_odr_based_comparison function.
2016-10-07 Dodji Seketeli <dodji@redhat.com>
Prevent infinite loops while comparing two function_type
* include/abg-ir.h (class environment): Make class function_type
be a friend of this class.
(class function_type): Make the equality function for
function_types be a friend of this class.
* src/abg-ir.cc (environment::priv::fn_types_being_compared_): New
data member.
(function_type::priv::{mark_as_being_compared,
unmark_as_being_compared, comparison_started}): Define new member
functions.
(equals): In the overload for function_types, if any of the the
function_type being compared is already being compared, return
early saying that the two function_types are equal. This avoids
2016-10-06 Dodji Seketeli <dodji@redhat.com>
Define a new interned_string_set_type typedef
* include/abg-interned-str.h (interned_string_set_type): Define a new
typedef for unordered_set<interned_string>.
2016-09-23 Dodji Seketeli <dodji@redhat.com>
Update reference output of runtestreaddwarf
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2016-09-21 Matthias Klose <doko@debian.org>
Fix typo in abipkgdiff
* tools/abipkgdiff.cc (extract_deb): Fix typo.
2016-09-12 Dodji Seketeli <dodji@redhat.com>
Better handle fedabipkgdiff dependencies detection
* configure.ac: It's only when --enable-fedabipkgdiff is provided
that a missing dependency of the fedabipkgdiff program results in
a fatal error. Otherwise, building fedabipkgdiff is just
disabled.
2016-09-16 Dodji Seketeli <dodji@redhat.com>
Add default suppression specifications for C++ binaries
* default.abignore: Add suppressions for non-libstdc++ and
non-boost C++ libraries.
2016-09-20 Dodji Seketeli <dodji@redhat.com>
Add default suppression specification for webkitgtk
* default.abignore: New suppression specifications for webkitgtk.
2016-09-19 Dodji Seketeli <dodji@redhat.com>
Drop suppressed ABI artifacts from the IR
* doc/manuals/abidw.rst: Document the new --suppressions and
--headers-dir options off the abidw tool.
* doc/manuals/abilint.rst: Document the new --suppressions and
--headers-dir options on the abilint tool.
* doc/manuals/libabigail-concepts.rst: Document the new "drop" and
"name_not_regexp" properties on suppression directives.
* include/abg-corpus.h (corpus::corpus): Add a default argument to
the path parameter.
* src/abg-suppression-priv.h: New private header file.
* src/Makefile.am: Add the new abg-suppression-priv.h file to
source distribution.
* include/abg-suppression.h ({suppression_base, type_suppression,
function_suppression, variable_suppression}::priv): Make these
public.
(suppression_base::{g,s}et_drops_artifact_from_ir): Declare new
member functions.
(type_suppression::{suppressed_type}): Likewise.
(suppression_base::{names,sonames}_of_binaries_match): Remove
member functions.
(function_suppression::{get_name, set_name, get_name_regex_str,
set_name_regex_str}): Renamed get_function_name,
set_function_name, get_function_name_regex_str,
set_function_name_regex_str into these.
({variable,function}_suppression::{g,s}et_name_not_regex_str):
Declare new member functions.
* src/abg-suppression.cc: Include the new abg-suppression-priv.h
private header.
(class suppression_base::priv, class type_suppression::priv, class
function_suppression::parameter_spec::priv, class
function_suppression::priv, class variable_suppression::priv):
Move these types to that new private header.
(suppression_base::{g,s}et_drops_artifact_from_ir)
(function_suppression::{g,s}et_name_not_regex_str)
(variable_suppression::{g,s}et_name_not_regex_str): New member
functions.
(sonames_of_binaries_match): New static function, taken from
suppression_base::sonames_of_binaries_match.
(names_of_binaries_match): New static function, taken from
suppression_base::names_of_binaries_match.
(suppression_matches_type_no_name): New static function.
(type_suppression::suppresses_type): Adjust
(function_suppression::suppresses_function)
(variable_suppression::suppresses_variable): Adjust. Evaluate the
new "name_not_regexp" property.
(suppression_matches_type_name)
(suppression_matches_type_location)
(suppression_matches_type_name_or_location)
(suppression_matches_function_name)
(suppression_matches_function_sym_name)
(suppression_matches_variable_name)
(suppression_matches_variable_sym_name, suppression_matches_type):
New functions.
(read_type_suppression): Support the new "drop_artifacts" and
"drop" properties.
(read_function_suppression, read_variable_suppression): Support
the new "drop_artifacts", "drop", and "name_not_regexp"
properties.
(function_suppression::{g,s}et_name): Renamed
{g,s}et_function_name into these.
(function_suppression::set_name_not_regex_str): Renamed
{g,s}et_name_regex_str into this.
(function_suppression::suppresses_function_symbol): Adjust.
* include/abg-dwarf-reader.h (add_read_context_suppressions):
Declare new function.
* src/abg-dwarf-reader.cc: Use the new private
abg-suppression-priv.h header file.
(read_context::supprs_): New data member.
(read_context::get_suppressions): New member function.
(read_context::get_die_source): Make this const.
(read_context::tu_die_imported_unit_points_map): Add a const
overload.
(read_context::cur_transl_unit): Renamed current_translation_unit
unit into this;
(read_context::cur_tu): Remove or rename into cur_transl_unit.
(get_scope_for_die, build_translation_unit_and_add_to_ir)
(build_enum_type, build_pointer_type_def, build_reference_type)
(build_function_type, build_array_type, build_function_decl):
Adjust.
(read_context::{suppression_can_match,
suppression_matches_function_sym_name,
suppression_matches_function_name,
suppression_matches_variable_sym_name,
suppression_matches_variable_name,
suppression_matches_type_name_or_location,
suppression_matches_type_name}): Add member functions.
(die_signed_constant_attribute): Remove this as dead code.
(die_location, die_loc_and_name)
(find_import_unit_point_between_dies)
(find_import_unit_point_before_die, get_parent_die): Make the
read_context& parameter be const and adjust as required.
(build_var_decl_if_not_suppressed, function_is_suppressed)
(variable_is_suppressed, type_is_suppressed): Define new static
functions.
(add_read_context_suppressions): Define new function.
(build_class_type_and_add_to_ir): Do not add suppressed static
data members to the IR.
(build_ir_node_from_die): Do not add suppressed enum types, class
types, variables or functions to the IR. Adjust for the
read_context::cur_tu -> read_context::cur_transl_unit rename.
* include/abg-reader.h (read_context_sptr): Declare new type.
(create_native_xml_read_context, read_corpus_from_input)
(add_read_context_suppressions): Declare new functions.
* src/abg-reader.cc: Include the new private
abg-suppression-priv.h header file.
(read_context::m_exported_decls_builder): Renamed
m_exported_decls_builder_ into this.
(read_context::get_exported_decls_builder): Adjust.
(read_context::get_cur_scope): Make this const.
(read_location): Take a const read_context and adjust.
(read_corpus_from_input): Make this non-static.
(build_namespace_decl): Don't abort if trying to add an artifact
to the IR doesn't succeed. It might be suppressed now.
(read_context::{m_path, m_supprs}): New data members.
(read_context::{g,s}et_path): New member functions.
(read_context::{get_suppressions,
suppression_matches_function_name, suppression_can_match,
suppression_matches_function_name,
suppression_matches_function_sym_name,
suppression_matches_variable_name,
suppression_matches_variable_sym_name,
suppression_matches_type_name_or_location}): Likewise.
(add_read_context_suppressions, create_native_xml_read_context)
(read_corpus_from_native_xml): New functions.
(build_function_decl_if_not_suppressed, function_is_suppressed)
(type_is_suppressed, build_var_decl_if_not_suppressed)
(variable_is_suppressed, build_enum_type_decl_if_not_suppressed)
(build_class_decl_if_not_suppressed): New static functions.
(build_class_decl): Add member types that are being built early,
so that their sub-types can be evaluated for suppression. Do not
add suppressed static data members or suppressed member functions
to the IR.
(build_type): Do not add an enum type or a class type to the IR if
they are suppressed.
(handle_enum_type_decl): Do not add an enum type to the IR if its
suppressed.
(handle_var_decl): Likewise for a variable decl.
(handle_function_decl): Likewise for a function decl.
(handle_class_decl): Likewise for a class decl.
* src/abg-tools-utils.cc (handle_fts_entry): Drop suppressed ABI
from the IR.
* tools/abidiff.cc (display_usage): Fix help strings for
--headers-dirs{1,2}.
(set_suppressions): New static function.
(main): Adjust. Release the memory used by read_context early.
* tools/abidw.cc (options::{headers_dir, suppression_paths}):
(display_usage): New help strings for the new --header-dir and
--suppressions options.
(parse_command_line): Parse the new --header-dir and
--suppressions options.
(maybe_check_suppression_files, set_suppressions): New static
functions.
(main): Use the two new functions above. Free the memory used by
the read context before working with the corpus.
* tools/abilint.cc (options::suppression_paths):
(display_usage): New help strings for the new --header-dir and
--suppressions options.
(parse_command_line): Parse the new --header-dir and
--suppressions options.
(maybe_check_suppression_files, set_suppressions): New static
functions.
(main): Use the two new functions above. Free the memory used by
the read context before working with the corpus.
* tests/data/test-diff-suppr/test24-soname-suppr-{2,3].txt:
Adjust.
* tests/data/test-diff-suppr/test29-suppr-6.txt: Likewise.
* tests/data/test-diff-suppr/test29-suppr-8.txt: Likewise.
* tests/data/test-diff-suppr/libtest31-v{0,1}.so: New test input.
* tests/data/test-diff-suppr/libtest31.suppr: Likewise
* tests/data/test-diff-suppr/libtest32-v{0,1}.so: Likewise.
* tests/data/test-diff-suppr/libtest32-0.suppr: Likewise.
* tests/data/test-diff-suppr/libtest33-v{0,1}.so: Likewise.
* tests/data/test-diff-suppr/test31-report-{0,1}.txt: Likewise.
* tests/data/test-diff-suppr/test31-v{0,1}.cc: Likewise.
* tests/data/test-diff-suppr/test32-report-{0,1}.txt: Likewise.
* tests/data/test-diff-suppr/test32-v{0,1}.c: Likewise.
* tests/data/test-diff-suppr/test33-suppr-1.txt: Likewise.
* tests/data/test-diff-suppr/test33-v{0,1}.cc: Likewise.
* tests/data/test-diff-suppr/test33-v{0,1}.h: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns-2.so.abi:
Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so: Likewise.
* tests/data/test-read-dwarf/libtest24-drop-fns.so.abi: Likewise.
* tests/data/test-read-dwarf/test24-drop-fns-0.suppr: Likewise.
* tests/data/test-read-dwarf/test24-drop-fns.cc: Likewise.
* tests/data/test-read-write/test28-drop-std-fns.abignore:
Likewise.
* tests/data/test-read-write/test28-drop-std-vars.abignore:
Likewise.
* tests/data/test-read-write/test28-without-std-fns-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-fns.xml: Likewise.
* tests/data/test-read-write/test28-without-std-vars-ref.xml:
Likewise.
* tests/data/test-read-write/test28-without-std-vars.xml:
Likewise.
* tests/data/test-read-write/test28.xml: Likewise.
* tests/data/Makefile.am: Add the new test artifacts to source
distribution.
* tests/test-diff-suppr.cc (in_out_spec): Take the new test inputs
into account.
* tests/test-read-dwarf.cc (Inoutspec::in_suppr_spec_path): New
data member.
(in_out_spec): Adjust. The new test inputs into account.
(set_suppressions): New static function.
(handle_in_out_spec): Adjust.
* tests/test-read-write.cc (Inoutspec::{in_suppr_spec_path,
ref_out_path}): New data members.
(in_out_spec): Adjust. Take new test inputs into account.
(main): Adjust.
2016-09-19 Dodji Seketeli <dodji@redhat.com>
Pimplify the abigail::ir::scope_decl type
* include/abg-ir.h (scope_decl::{priv, priv_sptr}) Declare new types.
(scope_decl::priv_): New pimpl data member.
(scope_decl::{member_, member_scopes}): Move this as data member
of the new scope_decl::priv type in the abg-ir.cc file.
(scope_decl::{scope_decl, get_member_decls, get_member_scopes,
is_empty}): Make these inline member functions be out-of-line.
* src/abg-ir.cc (struct scope_decl::priv): Define new type.
(scope_decl::{scope_decl, get_member_decls, get_member_scopes,
is_empty}): Define these new member functions here. They were
inline in the include/abg-ir.h header files before.
(scope_decl::{add_member_decl, insert_member_decl,
remove_member_decl}): Adjust.
2016-09-19 Dodji Seketeli <dodji@redhat.com>
Add new helper functions
* include/abg-fwd.h (get_location, build_qualified_name): Declare
new functions.
* include/abg-ir.h (is_method_decl): Declare two new overloads of
this function.
* src/abg-ir.cc (get_location, build_qualified_name)
(is_method_decl): Define these functions declared above.
2016-09-19 Dodji Seketeli <dodji@redhat.com>
Do not emit empty namespaces in abixml
* include/abg-ir.h
(namespace_decl::is_empty_or_has_empty_sub_namespaces): Declare
new function ...
* src/abg-ir.cc
(namespace_decl::is_empty_or_has_empty_sub_namespaces): ... and
define it.
* src/abg-writer.cc (write_namespace_decl): Do not write empty
namespaces or namespaces containing empty namespaces.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/libtest23.so.abi: Adjust.
2016-09-21 Dodji Seketeli <dodji@redhat.com>
Fix misleading indentation issues
* tools/abipkgdiff.cc (compare): Likewise.
* tools/abisym.cc (main): Fix misleading indentation.
2016-08-30 Dodji Seketeli <dodji@redhat.com>
Bug 20534 - abipkgdiff wrongly displays the name of added binary files
* tools/abipkgdiff.cc (compare): Show the name of the added
binary, rather than its address.
2016-08-24 Dodji Seketeli <dodji@redhat.com>
Bug 20420 - Wrong ODR-based type comparison optimization on qualified type
* src/abg-ir.cc: Bug 20420 - Wrong ODR-based type comparison optimization on qualified type
2016-08-23 Dodji Seketeli <dodji@redhat.com>
Don't walk diff trees indefinitely when applying suppressions
* src/abg-comparison.cc: Don't walk diff trees indefinitely when applying suppressions
2016-07-27 Dodji Seketeli <dodji@redhat.com>
Control symbols exported from libabigail.so
* VISIBILITY: New documentation about this visiblity business.
* CONTRIBUTING: Update the "contributing guide" to refer to symbol
visibility issues.
* configure.ac: Define a variable VISIBILITY_FLAGS that is set to
the -fvisibility=hidden flag to pass to GCC, when its available.
* src/Makefile.am: Add VISIBILITY to source distribution. Also
add COMPILING and COMMIT-LOG-GUIDELINES that were missing.
* src/Makefile.am: Use the new $(VISIBILITY_FLAGS) when buiding
the library.
* tests/Makefile.am: Use the new $(VISIBILITY_FLAGS) when buiding
tests.
* tools/Makefile.am: Use the new $(VISIBILITY_FLAGS) when buiding
tools.
* src/abg-comp-filter.cc: Enclose inclusion of public headers in
ABG_BEGIN_EXPORT_DECLARATIONS and ABG_END_EXPORT_DECLARATIONS to
export the symbols of entities declared in there.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-libzip-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-suppression.cc: Likewise.
* src/abg-tools-utils.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-workers.cc: Likewise.
* src/abg-writer.cc: Likewise.
2016-07-26 Dodji Seketeli <dodji@redhat.com>
Support DW_TAG_type_unit
* src/abg-dwarf-reader.cc (TYPE_UNIT_DIE_SOURCE): New enumerator
in enum die_source.
(read_context::{type_unit_die_decl_map_, type_unit_die_type_map_,
type_unit_die_wip_classes_map_,
type_unit_die_wip_function_types_map_,
type_unit_types_to_canonicalize_,
type_units_tu_die_imported_unit_points_map_,
type_section_die_parent_map_}): New data members.
(read_context::{get_die_source, associate_die_to_decl,
lookup_decl_from_die_offset, die_type_map, clear_die_type_maps,
die_wip_classes_map, die_wip_function_types_map,
types_to_canonicalize, clear_types_to_canonicalize,
tu_die_imported_unit_points_map, die_parent_map}): Support
TYPE_UNIT_DIE_SOURCE.
(get_parent_die, get_scope_for_die): Likewise.
(read_context::{lookup_decl_from_type_unit_die_offset,
type_section_die_parent_map}): Define new member functions.
(read_context::build_die_parent_maps): Build a DIE -> parent map
for DIEs coming from the .debug_types section.
* tests/data/test-read-dwarf/libtest23.so: New test input.
* tests/data/test-read-dwarf/libtest23.so.abi: New reference output.
* tests/data/test-read-dwarf/test23-first-tu.cc: Source code of
the new binary above.
* tests/data/test-read-dwarf/test23-second-tu.cc: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Make this test harness
execute over the new test input and reference output.
2016-07-26 Dodji Seketeli <dodji@redhat.com>
Misc code cleanup
* src/abg-dwarf-reader.cc (build_function_decl): Use the more
readable is_class_type rather than a dynamic_cast.
2016-07-26 Dodji Seketeli <dodji@redhat.com>
Generalize DIE source concept in DWARF reader
* src/abg-dwarf-reader.cc (enum die_source): Define new enum.
(operator++): Define new prefix increment operator for the
die_source enum.
(imported_unit_point::imported_unit_from_alt_di): Remove this
data member.
(imported_unit_point::imported_unit_die_source):
New data member of type die_source.
(read_context::primary_die_parent_map_): Renamed
die_parent_map_ data member into this.
(read_context::clear_per_corpus_data): Use the new
clear_die_type_maps function, not die_type_map. Also use the
new clear_types_to_canonicalize overload that takes no
parameter.
(read_context::{get_die_source, clear_die_type_maps,
clear_types_to_canonicalize}): New member functions.
(build_ir_node_from_die, die_die_attribute, get_parent_die)
(get_scope_for_die, build_namespace_decl_and_add_to_ir)
(build_type_decl, build_enum_type)
(build_class_type_and_add_to_ir, build_qualified_type)
(build_pointer_type_def, build_reference_type)
(build_function_type, build_array_type, build_typedef_type)
(build_var_decl, build_function_decl): Remove the boolean
parameter that was designating the source of the DIE. If
necessary, get the source of the DIE from inside the function
using the new read_context::get_die_source.
(read_debug_info_into_corpus): Adjust.
(maybe_canonicalize_type, find_import_unit_point_between_dies)
(maybe_canonicalize_type, read_context::{associate_die_to_decl,
lookup_decl_from_die_offset, die_type_map, associate_die_to_type,
lookup_type_from_die_offset, die_wip_classes_map,
die_wip_function_types_map, is_wip_class_die_offset,
is_wip_function_type_die_offset, types_to_canonicalize,
schedule_type_for_late_canonicalization,
canonicalize_types_scheduled, add_late_canonicalized_types_stats,
perform_late_type_canonicalizing}): Take a die_source as the
source of the DIE, not a boolean. Adjust the code of the function
accordingly.
(read_context::{tu_die_imported_unit_points_map}): Modified
this to make it take a die_source and return the appropriate
map depending on the source.
(read_context::build_die_parent_relations_under): Turn the
non-member static function build_die_parent_relations_under
into a member function.
(read_context::build_die_parent_maps): Turn the non-member
static function build_die_parent_maps into a member function.
Make this function build a DIE -> parent map also for type
DIEs that are in the .type_units section.
2016-07-25 Dodji Seketeli <dodji@redhat.com>
Cleanup is_class and is_compatible_with_class_type
* include/abg-fwd.h (is_class): Remove the overloads that take a
decl_base or a type_base. Add one that takes a type_or_decl_base.
(is_compatible_with_class_type): Make this take a reference to
smart pointer, not just the smart pointer.
* src/abg-ir.cc (is_class): Do the same as in the header file.
(is_compatible_with_class_type): Likewise.
2016-07-22 Dodji Seketeli <dodji@redhat.com>
Add ABG_ASSERT_NOT_REACHED macro
* include/abg-tools-utils.h (ABG_ASSERT_NOT_REACHED): New macro.
* src/abg-dwarf-reader.cc (stt_to_elf_symbol_type)
(stb_to_elf_symbol_binding, get_elf_class_size_in_bytes)
(build_ir_node_from_die): Use the new ABG_ASSERT_NOT_REACHED macro
in lieu of just calling abort().
2016-07-22 Dodji Seketeli <dodji@redhat.com>
Prepare support for symbol visibility control
* configure.ac: Detect compiler support for
__attribute__((visibility("hidden")) and define the
HAS_GCC_VISIBILITY_ATTRIBUTE macro accordingly. Update the
configuration report.
* src/abg-internal.h: New internal header file that defines macros
to be used in the source code to control declaration visibility.
* src/Makefile.am: Add abg-internal.h to source distribution. Add
src/ to the include search path.
2016-07-06 Chenxiong Qi <cqi@redhat.com>
Make fedabipkgdiff consistent with Libabigail's other tests
* configure.ac: Do not require Python dependencies itertools,
unittest and StringIO anymore as they are not used anymore.
Require new module tempfile now. Generate new executable script
tests/mockfedabipkgdiff from tests/mockfedabipkgdiff.in.
* doc/manuals/abipkgdiff.rst: Add doc for new option
--show-identical-binaries to abipkgdiff
* doc/manuals/fedabipkgdiff.rst: Add doc for new options
--show-identical-binaries to fedabipkgdiff.
* tools/abipkgdiff.cc (options::show_identical_binaries): New data
member.
(options::options): Initialize new data member.
(display_usage): Add a new help string for the new
--show-identical-binaries option.
(parse_command_line): Parse the newq --show-identical-binaries
command line switch.
(pthread_routine_compare): When the comparison of two binaries is
empty, if --show-identical-binaries was provided, then emit some
output saying the comparison did yield the empty set.
* tools/fedabipkgdiff (DEFAULT_ABIPKGDIFF): Store the default path
to abipkgdiff in this new global variable. Naming this default
path is useful because it can then be cleanly overloaded when
using mock.patch.
(build_path_to_abipkgdiff): Return the new DEFAULT_ABIPKGDIFF
global variable.
(cmd): Parse the new --show-identical-binaries command line
switch.
* tests/data/test-diff-pkg/test-dbus-glib-0.80-3.fc12.x86_64-report-0.txt:
New reference output.
* tests/data/test-fedabipkgdiff/test0-from-fc20-to-fc23-dbus-glib-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test1-from-fc20-to-dbus-glib-0.106-1.fc23.x86_64-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test2-dbus-glib-0.100.2-2.fc20--dbus-glib-0.106-1.fc23-report-0.txt:
Likewise.
* tests/data/test-fedabipkgdiff/test3-dbus-glib-0.100.2-2.fc20.i686--dbus-glib-0.106-1.fc23.i686-report-0.txt:
Likewise.
* tests/mockfedabipkgdiff.in: New uninstalled script template.
* tests/runtestfedabipkgdiff.py.in (counter)
(temp_file_or_dir_prefix, UtilsTest, RPMTest, LocalRPMTest)
(RunAbipkgdiffTest, GetPackageLatestBuildTest, DownloadRPMTest)
(BrewListRPMsTest, AssertionHelper, MockGlobalConfig)
(BUILT_ABIPKGDIFF, CompareABIFromCommandLineTest): Remove these
classes, global variables and functions.
(FEDABIPKGDIFF, TEST_SRC_DIR, TEST_BUILD_DIR, INPUT_DIR)
(OUTPUT_DIR, FEDABIPKGDIFF_TEST_SPECS): New global variables.
(ensure_output_dir_created, run_fedabipkgdiff_tests, main): New
functions.
* tests/test-diff-pkg.cc (in_out_specs): Add
tests/data/test-diff-pkg/test-dbus-glib-0.80-3.fc12.x86_64-report-0.txt
to the set of reference outputs to consider.
* tests/Makefile.am: Add non-installed script mockfedabipkgdiff to
source distribution. Also added
tests/data/test-diff-pkg/test-dbus-glib-0.80-3.fc12.x86_64-report-0.txt,
tests/data/test-fedabipkgdiff/test0-from-fc20-to-fc23-dbus-glib-report-0.txt,
tests/data/test-fedabipkgdiff/test1-from-fc20-to-dbus-glib-0.106-1.fc23.x86_64-report-0.txt,
tests/data/test-fedabipkgdiff/test2-dbus-glib-0.100.2-2.fc20--dbus-glib-0.106-1.fc23-report-0.txt
and
tests/data/test-fedabipkgdiff/test3-dbus-glib-0.100.2-2.fc20.i686--dbus-glib-0.106-1.fc23.i686-report-0.txt
to source distribution.
2016-07-13 Dodji Seketeli <dodji@redhat.com>
Fix spurious type size change report for distinct_diff
* src/abg-comparison.cc (report_size_and_alignment_changes):
Report size change only when the sizes are different.
* tests/data/test-diff-filter/test33-report-0.txt: Adjust.
2016-07-13 Dodji Seketeli <dodji@redhat.com>
Bug 20199 - Consider integral type synonyms as being equal
* src/abg-ir.cc (class integral_type): New class declaration and
definition.
(operator|, operator&, operator&=): New non-member bitwise
operators for integral_type.
(parse_integral_type_modifier, parse_base_integral_type)
(parse_integral_type_modifier): New static function definitions.
(type_decl::type_decl): Use the parse_integral_type to parse an
integral type out of the current type_decl being built and
transform the current type name into a canonical form.
* tests/data/test-abidiff/test-PR18791-v0.so.abi: Adjust.
* tests/data/test-abidiff/test-PR18791-v1.so.abi: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Likewise.
* tests/data/test-diff-filter/test33-report-0.txt: Likewise.
* tests/data/test-diff-filter/test34-report-0.txt: Likewise.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2016-07-08 Dodji Seketeli <dodji@redhat.com>
Bug 20332 - too many ...'s counted as parameters
* src/abg-dwarf-reader.cc (build_function_type): Create a variadic
parameter just for the first DW_TAG_unspecified_parameters seen.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
2016-07-06 Dodji Seketeli <dodji@redhat.com>
Better recognize qualified void type
* include/abg-ir.h (environment::is_void_type): Declare new member
function.
* src/abg-ir.cc (environment::is_void_type): Define new member
function.
* src/abg-dwarf-reader.cc (maybe_strip_qualification): Strip const
qualifier from const void.
* tests/data/test-diff-filter/test34-libjemalloc.so.2-gcc-6.1.0:
New test input.
* tests/data/test-diff-filter/test34-libjemalloc.so.2-intel-16.0.3: Likewise.
* tests/data/test-diff-filter/test34-report-0.txt: New reference output.
* tests/data/Makefile.am: Add the new files above to the source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Compare the two new
binaries above.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Adjust.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt: Adjust.
* tests/data/test-read-dwarf/test1.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2016-07-05 Dodji Seketeli <dodji@redhat.com>
Bug 20194 - Fail to recognize void type represented by DW_TAG_base_type
* src/abg-dwarf-reader.cc (build_type_decl): Recognize a
DW_TAG_base_type of size zero and of name "void" as a void
type.
* tests/data/test-diff-filter/test33-libelf.so.0.8.13-gcc: New
binary test input.
* tests/data/test-diff-filter/test33-libelf.so.0.8.13-intel16.0.3: Likewise.
* tests/data/test-diff-filter/test33-report-0.txt: New reference output.
* tests/data/Makefile.am: Add the new files above to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Make this test harness
run over the new test inputs above.
2016-07-04 Dodji Seketeli <dodji@redhat.com>
Add a new overload for is_type_decl
* include/abg-fwd.h (is_type_decl): Declare a new overload
* src/abg-ir.cc (is_type_decl): Define a new overload.
(function_decl::parameter::get_pretty_representation): Adjust.
2016-06-29 Chenxiong Qi <cqi@redhat.com>
Add --abipkgdiff option in manual and bash completion
* doc/manuals/fedabipkgdiff.rst: Add description of --abipkgdiff
option. Reformat paragraph.
* bash-completion/fedabipkgdiff: Add --abipkgdiff
2016-06-29 Chenxiong Qi <cqi@redhat.com>
Add fedabipkgdiff bash completion to dist
* bash-completion/Makefile.am: Add fedabipkgdiff
* bash-completion/fedabipkgdiff: Change mode to 775
2016-06-29 Chenxiong Qi <cqi@redhat.com>
Update bash completion for fedabipkgdiff
* bash-completion/fedabipkgdiff: New bash completion file.
2016-06-29 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.0.rc6
* configure.ac: Bump version number to 1.0.rc6
2016-06-29 Dodji Seketeli <dodji@redhat.com>
Update web page for 1.0.rc5
* doc/website/mainpage.txt: Update web page.
2016-06-27 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 1.0.rc5
* ChangeLog: Update by doing "make update-changelog" in the build
directory.
2016-06-27 Dodji Seketeli <dodji@redhat.com>
Update NEWS file in preparation for 1.0.rc5
* NEWS: update with the edited content of the command:
git shortlog libabigail-1.0.rc4..HEAD
2016-06-27 Dodji Seketeli <dodji@redhat.com>
Fix python interpreter path for el6
* tests/runtestdefaultsupprs.py.in: Use the python interpreter at
/usr/bin/python, not the one at /bin/python.
2016-06-24 Dodji Seketeli <dodji@redhat.com>
Misc cleanup in abg-reader.cc
* src/abg-reader.cc (read_context::push_decl_to_current_scope):
Pass the decl smart pointer by value.
2016-06-22 Dodji Seketeli <dodji@redhat.com>
Use ODR-based optimization on C/C++ translation unit only
* src/abg-ir.cc (strip_typedef): Set the translation unit of the
new ABI artifact.
(type_base::get_canonical_type_for): Perform the ODR-based
optimization only for ABI artifact in C and C++ language
translation units.
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Assert that
the new ABI artifact has its translation unit set.
* src/abg-reader.cc (read_context::{push_decl_to_current_scope,
push_and_key_type_decl}): Set the translation unit of the current
decl, irrespective of if it was added to the current scope or not.
Assert that the decl that was newly pushed to the current scope is
added to the current translation unit.
2016-06-10 Dodji Seketeli <dodji@redhat.com>
Misc white space and comment cleanups
* include/abg-ir.h (typedef type_or_decl_base): Cleanup comment.
* src/abg-ir.cc (struct type_or_decl_base::priv): Fix comment.
2016-06-10 Dodji Seketeli <dodji@redhat.com>
Cleanup function_decl::parameter::get_pretty_representation
* src/abg-ir.cc
(function_decl::parameter::get_pretty_representation): Assert that
the environment is always non-nil. Then no needs to check for it
being non-nil anymore. Use is_type_decl instead of
dynamic_pointer_cast.
2016-06-07 Chenxiong Qi <cqi@redhat.com>
Fix package NVR comparison in fedabipkgdiff
* configure.ac: Add new dependency.
* tests/runtestfedabipkgdiff.py.in (builds): Add new builds for
running tests to test selecting latest build from a package.
(packages): Add new package gnutls.
(GetPackageLatestBuildTest.{test_get_latest_one,
test_cannot_find_a_latest_build_with_invalid_distro}): Use new
builds of package gnutls to run tests.
* tools/fedabipkgdiff (cmp_nvr): New function used to compare nvrs
by Python built-in function sorted.
(Brew.listBuilds): Use the new cmp_nvr function.
2016-06-06 Chenxiong Qi <cqi@redhat.com>
Bug 20135 - Make fedabipkgdiff compare ABIs using devel packages
* doc/manuals/fedabipkgdiff.rst: Add documentation for the new
--no-devel-pkg command line option, as well as for the new default
behaviour of taking devel packages into account during ABI
comparison.
* tools/fedabipkgdiff (PkgInfo): Add new attribute
devel_package.
(RPM.is_devel): New property to determine if rpm is a
development package.
(LocalRPM._find_rpm): New method to find a specific rpm.
(LocalRPM.find_debuginfo): Use new method _find_rpm to find
debuginfo package.
(LocalRPM.find_devel): New method to find an associated
development package.
(Brew.select_rpms_from_a_build): RPMs selector method is
changed to select development package also.
(abipkgdiff): Construct and run abipkgdiff with and without
--devel-pkg[12] options.
(magic_construct): Construct PkgInfo with development package.
(run_abipkgdiff): Run abipkgdiff against rpms with development
packages.
(diff_local_rpm_with_latest_rpm_from_koji): Find development
package, and call method abipkgdiff with development package.
(build_commandline_args_parser): add new option --no-devel-pkg.
* tests/runtestfedabipkgdiff.py.in (packages): Add new package
nss-util.
(builds): Add new builds of nss-utils, nss-util-3.12.6-1.fc14
and nss-util-3.24.0-2.0.fc25.
(rpms): Add new associated rpms of the two new builds.
(AssertionHelper.assert_functions_changes_summary): New method
to match and assert functions changes summary.
(AssertionHelper.assert_abi_comparison_result): Changed to
support to help assert functions changes summary.
(MockGlobalConfig.{no_devel_pkg, check_all_subpackages}): New
fake options with default value for running tests.
(RPMTest.setUp): add new development package for running test
case.
(RPMTest.test_is_devel): New test to test is_devel property.
(RunAbipkgdiffTest.setUp): Add new development packages for
running test case.
(RunAbipkgdiffTest.{test_all_success, test_all_failure,
test_partial_failure}): Mock global config.
(RunAbipkgdiffWithDSOOnlyOptionTest): Removed.
(CompareABIFromCommandLineTest.test_compare_with_no_devel_pkg):
New test to test fedabipkgdiff with or without --no-devel-pkg
option.
* tests/data/Makefile.am: Add new rpms.
* tests/data/test-fedabipkgdiff/packages/nss-util/3.12.6/1.fc14/
x86_64/nss-util-3.12.6-1.fc14.x86_64.rpm: New rpm for running
tests.
* tests/data/test-fedabipkgdiff/packages/nss-util/3.12.6/1.fc14/
x86_64/nss-util-debuginfo-3.12.6-1.fc14.x86_64.rpm: New rpm for
running tests.
* tests/data/test-fedabipkgdiff/packages/nss-util/3.12.6/1.fc14/
x86_64/nss-util-devel-3.12.6-1.fc14.x86_64.rpm: New rpm for
running tests.
* tests/data/test-fedabipkgdiff/packages/nss-util/3.24.0/2.0.fc25/
x86_64/nss-util-3.24.0-2.0.fc25.x86_64.rpm: New rpm for running
tests.
* tests/data/test-fedabipkgdiff/packages/nss-util/3.24.0/2.0.fc25/
x86_64/nss-util-debuginfo-3.24.0-2.0.fc25.x86_64.rpm: New rpm
for running tests.
* tests/data/test-fedabipkgdiff/packages/nss-util/3.24.0/2.0.fc25/
x86_64/nss-util-devel-3.24.0-2.0.fc25.x86_64.rpm: New rpm for
running tests.
2016-06-03 Dodji Seketeli <dodji@redhat.com>
Improve python modules detection
* configure.ac: Include
autoconf-archive/ax_check_python_modules.m4 rather than
autoconf-archive/ax_python_module.m4. Use AX_CHECK_PYTHON_MODULES
rather than AX_PYTHON_MODULE.
* Makefile.am: Add the new file
autoconf-archive/ax_check_python_modules.m4 to source distribution
and remove the older autoconf-archive/ax_python_module.m4 one.
* autoconf-archive/ax_check_python_modules.m4: New file.
* autoconf-archive/ax_python_module.m4: Remove.
2016-05-30 Chenxiong Qi <cqi@redhat.com>
Add integration tests for fedabipkgdiff
* configure.ac: do not detect shutil module.
* tests/runtestfedabipkgdiff.py.in: do not import shutil
anymore.
(BUILT_ABIPKGDIFF): new global variable to reference the
abipkgdiff built from source code, as the new test case' tests
require this command directly rather than mocking the
global_config.
(test_data_dir): convert variable name to uppercase,
reference to the test data directory by absolute path instead of
relative path.
(TEST_TOPDIR): new global variable to use data directory as the
topdir passed to fedabpkgdiff to download rpms.
(TEST_DOWNLOAD_CACHE_DIR): new global variable referencing a
fake download cache directory for tests only.
(packages, builds, rpms): new global variables as a fake
storage holding packages, builds and rpms.
(AssertionHelper): new class helping to assert abipkgdiff
result easily.
(MockClientSession): new class to mock koji.ClientSession.
(MockGlobalConfig.abipkgdiff): set this option to global
variable BUILT_ABIPKGDIFF.
(MockKojiClientSessin): removed.
(mock_get_session): removed.
(GetPackageLatestBuildTest.{test_get_latest_one,
test_cannot_find_a_latest_build_with_invalid_distro,
test_cannot_find_a_latest_build_with_invalid_distro}): mock
koji.ClientSession with new class MockClientSession. Remove
invalid documentation from docstring. Use new package rather
than httpd.
(DownloadRPMTest.setUp): remove self.download_dir and use global
TEST_DOWNLOAD_CACHE_DIR.
(DownloadRPMTest.tearDown): do not remove download cache
directory.
(DownloadRPMTest.make_remote_file_url): do not omit positional
argument specifiers in string format.
(DownloadRPMTest.{test_succeed_to_download_a_rpm,
test_failed_to_download_a_rpm}): set fake download cache
directory to mocked get_download_dir in mock.patch decorator.
(BrewListRPMsTest.test_select_specific_rpms): use new
MockClientSession to mock koji.ClientSession. Rewrite test by
using the new package listed in global variable packages.
(RunAbipkgdiffWithDSOOnlyOptionTest.{test_abipkgdiff_with_dso_only,
test_abipkgdiff_without_dso_only}): set fake download cache
directory to mocked get_download_dir in mock.patch decorator.
(CompareABIFromCommandLineTest): new integration test case.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.100.2/2.fc20/
i686/dbus-glib-0.100.2-2.fc20.i686.rpm: new rpm for running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.100.2/2.fc20/
i686/dbus-glib-debuginfo-0.100.2-2.fc20.i686.rpm: new rpm for
running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.100.2/2.fc20/
i686/dbus-glib-devel-0.100.2-2.fc20.i686.rpm: new rpm for
running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.100.2/2.fc20/
x86_64/dbus-glib-0.100.2-2.fc20.x86_64.rpm: new rpm for running
tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.100.2/2.fc20/
x86_64/dbus-glib-debuginfo-0.100.2-2.fc20.x86_64.rpm: new rpm
for running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.100.2/2.fc20/
x86_64/dbus-glib-devel-0.100.2-2.fc20.x86_64.rpm: new rpm for
running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.106/1.fc23/
i686/dbus-glib-0.106-1.fc23.i686.rpm: new rpm for running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.106/1.fc23/
i686/dbus-glib-debuginfo-0.106-1.fc23.i686.rpm: new rpm for
running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.106/1.fc23/
i686/dbus-glib-devel-0.106-1.fc23.i686.rpm: new rpm for running
tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.106/1.fc23/
x86_64/dbus-glib-0.106-1.fc23.x86_64.rpm: new rpm for running
tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.106/1.fc23/
x86_64/dbus-glib-debuginfo-0.106-1.fc23.x86_64.rpm: new rpm for
running tests.
* tests/data/test-fedabipkgdiff/packages/dbus-glib/0.106/1.fc23/
x86_64/dbus-glib-devel-0.106-1.fc23.x86_64.rpm: new rpm for
running tests.
* tests/data/Makefile.am: add new rpms.
2016-05-31 Dodji Seketeli <dodji@redhat.com>
Bug 19967 - System-level suppressions for glibc
* default.abignore: Add initial suppression specifications for
glibc.
2016-05-31 Dodji Seketeli <dodji@redhat.com>
Escape all characters when reading a string in ini files
* src/abg-ini.cc (read_context::peek): Take an output parameter to
tell the caller when this function escaped the returned
character. Added an overload without this new parameter.
(read_context::read_string): Accept all characters as part of the
string.
* tests/data/test-diff-suppr/test7-var-suppr-9.suppr: New test
input.
* tests/data/test-diff-suppr/test7-var-suppr-report-9.txt: New
test reference output.
* tests/data/Makefile.am: Add the files above to source
distribution.
* tests/test-diff-suppr.cc (in_out_spec): Run a new comparison of
libtest7-var-suppr-v{0,1}.so this time using the new
test7-var-suppr-9.suppr specification that exercices a string with
the escaped characters that we were having difficulty with.
2016-05-31 Dodji Seketeli <dodji@redhat.com>
Don't require all version symbol sections to present
* src/abg-dwarf-reader.cc (get_symbol_versionning_sections): Allow
returning just some of the three version-related section, not
necessarily all of them. Adjust comment.
(get_version_for_symbol): Be ready to not necessarily having the
three version-related sections available.
2016-05-30 Dodji Seketeli <dodji@redhat.com>
Bug 20180 - Support system-wide suppression specifications
* doc/manuals/abidiff.rst: Document the default suppression
scheme, its interaction with the --supprs option and the new
--no-default option.
* doc/manuals/abipkgdiff.rst: Likewise.
* doc/manuals/fedabipkgdiff.rst: Likewise.
* configure.ac: Generate the tests/runtestdefaultsupprs.py file
from the new tests/runtestdefaultsupprs.py.in template.
* default.abignore: New file.
* Makefile.am: Add it to source distribution.
* src/Makefile.am: Define the ABIGAIL_ROOT_SYSTEM_LIBDIR
preprocessor macro that is set the value of the $libdir autotools
macro.
* include/abg-tools-utils.h: Update copyright years.
(get_system_libdir, get_default_system_suppression_file_path)
(get_default_user_suppression_file_path)
(load_default_system_suppressions)
(load_default_user_suppressions): Declare new functions
* src/abg-tools-utils.cc (get_system_libdir)
(get_default_system_suppression_file_path)
(get_default_user_suppression_file_path)
(load_default_system_suppressions)
(load_default_user_suppressions): Define new functions.
(is_regular_file): Amend this so that it return true for symlinks
to regular files too.
(is_dir): Amend this so that it returns true for symlinks to
directories too.
* tools/abidiff.cc (options::no_default_supprs): New data member.
(options::options): Initialize the new data member.
(display_usage): Display a new help string for the new
--no-default-suppression command line option.
(parse_command_line): Parse this new command line option.
(set_diff_context_from_opts): Load the default suppression
specifications, unless --no-default-suppression or --supprs was
provided.
* tools/abipkgdiff.cc (options::no_default_supprs): New data
member.
(options::options): Initialize the new data member.
(parse_command_line): Parse the new --no-default-suppression
command line option.
(main): Load the default suppression specifications, unless
--no-default-suppression or --supprs was provided.
* tools/fedabipkgdiff (abipkgdiff): Add --no-default-suppression
to the invocation of abipkgdiff if it was provided on the command
line.
(build_commandline_args_parser): Parse the new
--no-default-suppression command line option.
* tests/runtestdefaultsupprs.py.in: New test harness template.
* tests/Makefile.am: Add the new runtestdefaultsupprs.py to the
set of tests.
* tests/data/test-default-supprs/test0-type-suppr-0.suppr: New
test input.
* tests/data/test-default-supprs/test0-type-suppr-report-0.txt: Likewise.
* tests/data/test-default-supprs/test0-type-suppr-v0.o: Likewise.
* tests/data/test-default-supprs/test0-type-suppr-v1.o: Likewise.
* tests/data/test-default-supprs/dirpkg-1-dir-report-0.txt:
Likewise.
* tests/data/test-default-supprs/dirpkg-1-dir1: Likewise.
* tests/data/test-default-supprs/dirpkg-1-dir2: Likewise.
* tests/data/Makefile.am: Add new the new tests input above to
Makefile.am.
* tests/runtestcanonicalizetypes.sh.in: Pass
--no-default-suppression to abidiff invocations.
* tests/runtestdefaultsupprs.py.in: Likewise.
* tests/test-abidiff-exit.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tools/abidiff.cc: Likewise.
2016-05-30 Dodji Seketeli <dodji@redhat.com>
Add --abipkgdiff option to fedabipkgdiff
* tools/fedabipkgdiff (build_path_to_abipkgdiff): Define new
function.
(abipkgdiff): Invoke the new build_path_to_abipkgdiff() here.
(build_commandline_args_parser): Parse the new --abipkgdiff
option.
2016-05-28 Dodji Seketeli <dodji@redhat.com>
Better diagnostics when abipkgdiff has an extra argument
* tools/abipkgdiff.cc (options::wrong_arg): New data member.
(parse_command_line): Set options::wrong_arg
to the wrong argument passed.
(main): Tell wrong argument case apart, and report it.
2016-05-26 Dodji Seketeli <dodji@redhat.com>
Fix suppr spec wording in abipkgdiff manual
* doc/manuals/abipkgdiff.rst: Fix the wording for the --suppr
option.
2016-05-26 Dodji Seketeli <dodji@redhat.com>
Update reference to tools in libabigail-concepts manual
* doc/manuals/libabigail-concepts.rst: Do not refer just to
abidiff when talking about suppression specification. Also
refer to abipkgdiff and other tools.
2016-05-30 Dodji Seketeli <dodji@redhat.com>
Fix some wording in the Libabigail overview manual page
* doc/manuals/libabigail-overview.rst: Cleanup some confusion
about Abigail-the-framework and libabigail-the-library.
2016-05-25 Dodji Seketeli <dodji@redhat.com>
Add test data for tests/runtestfedabipkgdiff.py
* tests/data/test-fedabipkgdiff/dbus-glib-0.104-3.fc23.x86_64.rpm:
New file.
* tests/data/test-fedabipkgdiff/dbus-glib-0.80-3.fc12.x86_64.rpm: Likewise.
* tests/data/test-fedabipkgdiff/dbus-glib-debuginfo-0.104-3.fc23.x86_64.rpm:
Likewise.
* tests/data/test-fedabipkgdiff/dbus-glib-debuginfo-0.80-3.fc12.x86_64.rpm:
Likewise.
2016-05-25 Dodji Seketeli <dodji@redhat.com>
Add a 'check-valgrind' target to the top-most Makefile.am
* Makefile.am (check-valgrind): Add this new target here.
2016-05-21 Chenxiong Qi <cqi@redhat.com>
Bug 20085 - Add --dso-only option to fedabipkgdiff
* tools/fedabipkgdiff: Do not import shlex anymore.
(ABIDIFF_OK, ABIDIFF_ERROR, ABIDIFF_USAGE_ERROR)
(ABIDIFF_ABI_CHANGE): New global constant variables.
(abipkgdiff): Pass the --dso-only option to the abipkgdiff command
line tool, if that option was passed to fedabipkgdiff. Build this
abipkgdiff command invocation from an array of strings, rather
than from formatting a string. This makes us get rid of the shlex
module. Fix typo in dry-run logged string. If there was an
internal error reported by abipkgdiff, report it to stderr.
(build_commandline_args_parser): Parse the --dso-only command line
option.
* tests/runtestfedabipkgdiff.py.in (fedabipkgdiff_mod): Fix a typo
in initializing this global variable.
(test_data_dir): New global variable, that is used to reference
tests/data/test-fedabipkgdiff/.
(RunAbipkgdiffTest.{test_all_success, test_partial_failure}): Fix
typo.
(Mockglobalconfig.{koji_topdir, dso_only}): New data members.
(GetPackageLatestBuildTest.{test_get_latest_one,
test_cannot_find_a_latest_build_with_invalid_distro,
test_succeed_to_download_a_rpm, test_failed_to_download_a_rpm}):
Fix typo.
(BrewListRPMsTest.test_select_specific_rpms): Fix typo.
(RunAbipkgdiffWithDSOOnlyOptionTest): New test case class.
* doc/manuals/fedabipkgdiff.rst: update document for this new
--dso-only option.
* tests/data/test-fedabipkgdiff/dbus-glib-0.104-3.fc23.x86_64.rpm:
New symbolic link to
test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64.rpm.
* tests/data/test-fedabipkgdiff/dbus-glib-0.80-3.fc12.x86_64.rpm:
New symbolic link to
test-diff-pkg/dbus-glib-0.80-3.fc12.x86_64.rpm.
* tests/data/test-fedabipkgdiff/dbus-glib-debuginfo-0.104-3.fc23.x86_64.rpm:
New symbolic link to
test-diff-pkg/dbus-glib-debuginfo-0.104-3.fc23.x86_64.rpm.
* tests/data/test-fedabipkgdiff/dbus-glib-debuginfo-0.80-3.fc12.x86_64.rpm:
New symbolic link to
test-diff-pkg/dbus-glib-debuginfo-0.80-3.fc12.x86_64.rpm.
* tests/data/Makefile.am: add tests/data/test-fedabipkgdiff so
that this data directory and all things within it can be included
in tarball.
2016-05-24 Sinny Kumari <sinny@redhat.com>
Change parent directory for keeping extracted packages in abipkgdiff
* tools/abipkgdiff.cc (extracted_packages_parent_dir): Change
TMPDIR environment variable to XDG_CACHE_HOME and default
temporary parent directory to $HOME/.cache/libabigail/
2016-05-20 Dodji Seketeli <dodji@redhat.com>
Make abi{pkg}diff filter out changes about private types
* include/abg-comp-filter.h: Update copyright year.
* src/abg-comp-filter.cc (has_virtual_mem_fn_change): Make this
static function become exported.
(has_virtual_mem_fn_change): Declare new function.
* include/abg-suppression.h
(suppression_base::{get,set}_is_artificial): Declare new
accessors.
(type_suppression::get_source_locations_to_keep): Return an
unordered set of strings, not a vector. Add a non-const overload.
(type_suppression::set_source_locations_to_keep): Set an unordered
set of strings, not a vector.
* src/abg-suppression.cc (suppression_base::priv::is_artificial_):
New data member.
(suppression_base::priv::priv): Initialize the new data member.
(suppression_base::{get,set}_is_artificial): Define new accessors.
(type_suppression::priv::source_locations_to_keep_): Change the
vector of strings representing source file names into unordered
set of string.
(type_suppression::get_source_locations_to_keep): Return an
unordered set of strings, not a vector. Define a non-const
overload.
(type_suppression::set_source_locations_to_keep): Set an unordered
set of strings, not a vector.
(type_suppression::suppresses_diff): Make this suppress virtual
member function diffs if the enclosing type of the changed virtual
member is suppressed by the current type_suppression.
(read_type_suppression): Adjust to use the fact that the source
locations are not stored in an unordered set, not in a vector
anymore. Otherwise, using a vector here make things too slow.
(type_suppression::suppresses_type): Likewise. Also, If the type
we are looking at has no location because it's a true opaque type
and if the current suppression is an artificial suppression that
is meant to suppress change reports about non-public types, then
suppress the type.
* include/abg-tools-utils.h (gen_suppr_spec_from_headers): Declare
new public function.
* src/abg-tools-utils.cc (PRIVATE_TYPES_SUPPR_SPEC_NAME): Define a
new constant variable.
(handle_fts_entry): Define new static function.
(gen_suppr_spec_from_headers): Define new public function.
* src/abg-comparison.cc
(corpus_diff::priv::apply_suppressions_to_added_removed_fns_vars):
If a type suppression suppresses a given class C, make it change
added/removed virtual functions whose enclosing type is C.
* tools/abidiff.cc (options::{headers_dir1, headers_dir2}): New
data members.
(display_usage): Add help strings for --headers-dir1 and
--headers-dir2.
(parse_command_line): Parse the new --headers-dir1 and
--headers-dir2 options.
(set_diff_context_from_opts): Generate suppression specifications
to filter out changes on private types, if --headers-dir1 or
--headers-dir2 is given.
* tools/abipkgdiff.cc (options::{devel_package1, devel_package2}):
New data members.
(typedef package_sptr): New typedef.
(enum package::kind): New enum.
(package::kind_): New data member. This replaces ...
(package::is_debug_info_): ... this data member.
(package::{devel_package_, private_types_suppressions_}): New data
members.
(package::package): Adjust.
(package::get_kind): Define new member function. This replaces
...
(package::is_debug_info): ... this member function overload.
(package::set_kind): Define new member functin. It replaces ...
(package::is_debug_info): ... this member function overload.
(package::{devel_package, private_types_suppressions}): Define new
accessors.
(package::erase_extraction_directies): Erase the sub-directory
where development packages are extracted to.
(compare_args::private_types_suppr{1,2}): New data members.
(compare_args::compare_args): Adjust.
(display_usage): Add help strings for --devel-pkg1/--devel-pkg2.
(compare): Make the overload that compares elf files take private
types suppressions. Add the private types suppressions to the
diff context.
(pthread_routine_compare): Adjust the call to compare.
(maybe_create_private_types_suppressions): Define new static
function.
(pthread_routine_extract_pkg_and_map_its_content): If a devel
package was specified for the main package then extract it in
parallel with the other package extraction. When the extraction
is done, create private types suppressions by visiting the
directories that contain the header files.
(compare): In the overload that compares packages by scheduling
comparison of individual elf files that are in the packages, pass
in the private type suppressions too.
(parse_command_line): Parse the new --devel-pkg{1,2} command line
options.
(main): Associate the devel package to the main package, if the
--devel-pkg{1,2}.
* doc/manuals/abidiff.rst: Add documentation about the new
--headers-dir1 and --headers-dir2 options.
* doc/manuals/abipkgdiff.rst: Likewise, add documentation about
the new --devel-pkg1 and --devel-pkg2 libraries.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-1.txt:
New test reference output.
* tests/data/test-diff-pkg/tbb-devel-4.1-9.20130314.fc22.x86_64.rpm:
New test input package.
* tests/data/test-diff-pkg/tbb-devel-4.3-3.20141204.fc23.x86_64.rpm: Likewise.
* tests/test-diff-pkg.cc b/tests/test-diff-pkg.cc
(InOutSpec::{first,second}_in_devel_package_path): New data
members.
(in_out_specs): Adjust. Also, add a new entry describing the new
test inputs above.
(test_task::perform): When the new test entry contains devel
packages, pass them to abipkgdiff using the --devel1 and --devel2
options.
* tests/data/test-diff-suppr/test30-include-dir-v0/test30-pub-lib-v0.h:
A new test input source code.
* tests/data/test-diff-suppr/test30-include-dir-v1/test30-pub-lib-v1.h: Likewise.
* tests/data/test-diff-suppr/test30-priv-lib-v0.cc: Likewise.
* tests/data/test-diff-suppr/test30-priv-lib-v0.h: Likewise.
* tests/data/test-diff-suppr/test30-priv-lib-v1.cc: Likewise.
* tests/data/test-diff-suppr/test30-priv-lib-v1.h: Likewise.
* tests/data/test-diff-suppr/test30-pub-lib-v0.cc: Likewise.
* tests/data/test-diff-suppr/test30-pub-lib-v0.so: Add new test
binary input.
* tests/data/test-diff-suppr/test30-pub-lib-v1.cc: Add new test
input source code.
* tests/data/test-diff-suppr/test30-pub-lib-v1.so: Add new test
binary input.
* tests/data/test-diff-suppr/test30-report-0.txt: Add new test
reference output.
* tests/data/test-diff-suppr/test30-report-1.txt: Add new test
reference output.
* tests/test-diff-suppr.cc (InOutSpec::headers_dir{1,2}): New data
members.
(InOutSpec::abidiff_options): Renamed the bidiff_options data
member into this.
(in_out_specs): Adjust. Also, added the new test input above to
this.
(main): Adjust to invoke abidiff with the new --hd1 and --hd2
options if the input specs for the tests has the new
InOutSpec::headers_dir{1,2} data member set. Renamed bidiff into
abidiff.
* tests/data/Makefile.am: Add the new test inputs to the source
distribution.
2016-05-24 Dodji Seketeli <dodji@redhat.com>
Fix the number of removed functions in change report
* src/abg-suppression.cc (corpus_diff::report): Show the net
number of removed functions, not the total number of the removed
functions.
2016-05-23 Dodji Seketeli <dodji@redhat.com>
Document how to handle regression tests in CONTRIBUTING
* CONTRIBUTING: Add a section about regression tests.
* Makefile.am: Add a check-valgrind-recursive target.
2016-05-21 Dodji Seketeli <dodji@redhat.com>
Fix whitespaces in autotools files
* configure.ac: Fix some white spaces.
* tests/Makefile.am: Likewise.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Fix white space in abg-comparison.cc
* src/abg-comparison.cc (struct diff_context::priv): Fix indentation.
2016-05-21 Dodji Seketeli <dodji@redhat.com>
Fix bash completion configure status
* configure.ac: If bash completion is disabled, say so.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Enhance API doc for diff_context::add_diff
* src/abg-comparison.cc (diff_context::add_diff): Enhance the API
doc string.
2016-05-20 Dodji Seketeli <dodji@redhat.com>
Add missing API doc strings
* src/abg-comparison.cc (diff::diff)
(decl_diff_base::decl_diff_base, distinct_diff::distinct_diff)
(base_diff::base_diff, scope_diff::scope_diff)
(fn_parm_diff::fn_parm_diff)
(function_type_diff::function_type_diff)
(type_decl_diff::type_decl_diff, typedef_diff::typedef_diff)
(translation_unit_diff::translation_unit_diff)
(corpus_diff::corpus_diff): Add missing API doc strings.
2016-05-20 Dodji Seketeli <dodji@redhat.com>
Optimize out some shared_ptr use
* include/abg-ir.h (pointer_type_def::get_naked_pointed_to_type):
Declare new member function.
* src/abg-ir.cc (pointer_type_def::priv::naked_pointed_to_type_):
New data member.
(pointer_type_def::priv::priv): Adjust to initialize the new data
member.
(pointer_type_def::pointer_type_def): Adjust to use the
constructor pointer_type_def::priv::priv to initialize the
pointed-to type (including its new naked pointer variant). So we
do not have to initialize the priv_->pointed_to_type_ explicitely
in the constructor anymore.
(pointer_type_def::get_naked_pointed_to_type): Define new data
member.
(pointer_type_def::get_qualified_name): Use a naked pointer to the
pointed-to type, rather than a smart pointer.
2016-05-20 Dodji Seketeli <dodji@redhat.com>
Light optimizations by passing reference to smart pointers around
* include/abg-fwd.h (get_type_name): Take a reference to type_sptr.
* src/abg-ir.cc (get_type_name): Take a reference to type_sptr.
(suppression_base::priv::{get_file_name_regex,
get_file_name_not_regex, get_soname_regex, get_soname_not_regex}):
Return a reference to regex_t_sptr.
2016-05-20 Dodji Seketeli <dodji@redhat.com>
Minimize number of string::length calculation
* src/abg-tools-utils.cc (string_ends_with): Call string::length
just once on each instance of string that matters.
2016-05-20 Dodji Seketeli <dodji@redhat.com>
Avoid unnecessary computation of type name in suppression evaluation
* src/abg-suppression.cc (type_suppression::suppresses_type): If
neither the type suppression "name" or "name_regex" properties
where provided in the suppression specification, then do not try
to look at the type name.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Plug leak of diffs of member variables of class type
* include/abg-comparison.h (diff_wptr, unordered_diff_sptr_set): New typedefs.
(struct diff_sptr_hasher): Define new type.
(diff_context::keep_diff_alive): Declare new member function.
(diff::children_nodes): Return a vector of diff*, rather than a
vector of diff_sptr.
* src/abg-comparison.cc (diff_context::priv::live_diffs_): New
data member.
(diff_context::keep_diff_alive): Define new data member.
(diff::priv::children_): Make this be a vector of diff*, rather
than a vector of diff_sptr.
(diff_less_than_functor::operator()): Add a new overload for
diff*. Make the existing overload of diff_sptr use the new one.
(diff::children_nodes): Adjust;
(diff::append_child_node): Make sure the child node is kept
alive. Only add the naked pointer to the child node to the vector
of children.
(diff::traverse): Adjust.
(var_diff::priv::type_diff_): Make this be a weak pointer, rather
than a shared pointer.
(var_diff::type_diff): The var_diff::priv::type_diff_ data member
is now a weak pointer, so make this accessor convert it to a
shared pointer.
(corpus_diff::priv::children_): Turn this into a vector of diff*,
rather than a vector of diff_sptr.
(corpus_diff::children_nodes): Adjust.
(corpus_diff::append_child_node): Make sure the child node is kept
alive. Only add the naked pointer to the child node to the vector
of children.
(category_propagation_visitor::visit_end): Adjust.
(suppression_categorization_visitor::visit_end): Adjust.
(redundancy_marking_visitor::{visit_begin, visit_end}): Adjust.
2016-05-20 Dodji Seketeli <dodji@redhat.com>
Speedup diff node child insertion
* src/abg-comparison.cc (corpus_diff::append_child_node): Insert
the new child at the right point in the vector of children, so
that it remains sorted.
2016-05-21 Dodji Seketeli <dodji@redhat.com>
Fix invocation of delete operator in test-read-dwarf.cc
* tests/test-read-dwarf.cc (main): Call delete[], not delete.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Plug leak of debug info handles
* configure.ac: Check the presence of dwarf_getalt in libdw. If
it's present, define the preprocessor macro
LIBDW_HAS_DWARF_GETALT. Update the autoconf configuration
summary.
* src/abg-dwarf-reader.cc: Add config.h.
(find_alt_debug_info_location): Factorize this out of ...
(find_alt_debug_info): ... this function. Use dwarf_getalt if
present, otherwise, keep using dwfl_standard_find_debuginfo. In
the later case, return the file descriptor opened to access the
alternate debug info, by parameter, so that the caller can fclose
it.
(read_context::alt_fd_): New data member.
(read_context::read_context): Initialize the new alt_fd_ data
member.
(read_context::load_debug_info): Store the file descriptor used to
access the alternate debug info into the new alt_fd_ data member.
(read_context::~read_context): New desctructor.
(get_soname_of_elf_file, get_type_of_elf_file): Free the elf
handle.
(read_context::load_debug_info): Be paranoid in making sure we
never override alt_dwarf_.
* tests/data/test-alt-dwarf-file/test0-report.txt: Adjust.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Plug leak of shared private data of class_diff type
* include/abg-comparison.h (class_diff::get_priv): Declare new
member function.
(class_diff::get_priv): Define new member function.
(class_diff::{chain_into_hierarchy, base_changes, deleted_bases,
inserted_bases, changed_bases, base_changes, member_types_changes,
member_types_changes, data_members_changes, inserted_data_members,
deleted_data_members, member_fns_changes, changed_member_fns,
member_fns_changes, deleted_member_fns, inserted_member_fns,
member_fn_tmpls_changes, member_class_tmpls_changes,
member_class_tmpls_changes, report}): Rather than accessing
class_diff::priv directly, use the new class_diff::get_priv.
2016-05-21 Dodji Seketeli <dodji@redhat.com>
Remove circular ref from class_decl::priv::definition_of_declaration
* include/abg-ir.cc (class_decl::get_definition_of_declaration):
Return a shared pointer, rather than a reference to a shared pointer.
* src/abg-ir.cc (class_decl::priv::definition_of_declaration_):
Make this be a weak pointer.
(class_decl::get_definition_of_declaration):
Likewise. And return the shared pointer built out of the weak
pointer we have in there now.
2016-05-21 Dodji Seketeli <dodji@redhat.com>
Plug leak of regex_t in suppression engine
* include/abg-sptr-utils.h (build_sptr<T>): Declare an overload that
allocates a T* and wraps it into a shared_ptr<T>.
(build_sptr<regex_t>): Declare a specialization for regex_t.
* src/abg-corpus.cc (build_sptr<regex_t>()): Define the
specialization here.
* src/abg-suppression.ccp
(suppression_base::priv::{get_file_[not]_name_regex,
get_soname_[not]_regex}): Use the new build_sptr<regex_t>().
(type_suppression::priv::{get_type_name_regex,
get_source_location_to_keep_regex}): Likewise.
(function_suppression::parameter_spec::priv::get_type_name_regex):
Likewise.
(function_suppression::priv::{get_name_regex,
get_return_type_regex, get_symbol_name_regex,
get_symbol_version_regex}): Likewise.
(variable_suppression::priv::{get_name_regex,
get_symbol_name_regex, get_symbol_version_regex,
get_type_name_regex}): Likewise.
2016-05-18 Dodji Seketeli <dodji@redhat.com>
Plug leak of diff_context_sptr after calling compute_diff
* src/abg-comparison.cc (diff::priv::ctxt_): Make this a weak_ptr.
(diff::priv::get_context): Convert the weak pointer to the context
into a shared_ptr and return it.
(diff::priv::is_filtered_out): Adjust to use
diff::priv::get_context() to access the context.
(diff::context): Likewise.
(corpus_diff::priv::ctxt_): Make this a weak_ptr.
(corpus_diff::priv::priv): Add a new overload that takes two
corpora and a diff context.
(corpus_diff::priv::get_context): Convert the weak pointer to the
context into a shared_ptr and return it.
(corpus_diff::priv::ensure_lookup_tables_populated): Adjust to use
the new corpus_diff::priv::get_context to get the context.
(variable_is_suppressed): Likewise.
(corpus_diff::priv::{apply_suppressions_to_added_removed_fns_vars,
apply_filters_and_compute_diff_stats, emit_diff_stats,
categorize_redundant_changed_sub_nodes,
clear_redundancy_categorization}): Likewise.
(corpus_diff::{corpus_diff, context,
apply_filters_and_suppressions_before_reporting}): Adjust.
* tools/abipkgdiff.cc (compare): Make the overload that compares
elf binaries take a diff context output parameter. After the
context is created by this function, it's return to the caller, so
that it's life time is bound to the scope this function was
called from.
(pthread_routine_compare): Create a shared pointer to hold a
reference on a diff context. Pass that shared pointer by
reference to the compare function that compares elf binaries.
Rather than storing corpora in the reports_map, (as those corpora
would then out-live the diff context and thus create memory
corruption issues), emit the report directly into an ostringstream
and store that stream in reports_map.
(compare): In the overoad that compares packages, rather than
trying to get corpora from the report_map, just emit the content
of the ostringstream that is now there.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Fix a read passed-the-end in abg-dwarf-reader.cc
* src/abg-dwarf-reader.cc (lookup_symbol_from_gnu_hash_tab): Do
not read passed the end of the array.
2016-05-21 Dodji Seketeli <dodji@redhat.com>
Support running "make check-valgrind"
* autoconf-archive/ax_valgrind_check.m4: Add new file. Copied it
from http://www.gnu.org/software/autoconf-archive/ax_valgrind_check.html.
* configure.ac: Include the new ax_valgrind_check.m4 file.
Initialize the valgrind checking on tests. Update the configure
status.
* tests/test-valgrind-suppressions.supp: New valgrind suppression
file to silence memcheck leak errors from python.
* tests/Makefile.am: Add test-valgrind-suppressions.supp to source
distribution. Add check-valgrind-memcheck-recursive target.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Update the CONTRIBUTING file
* CONTRIBUTING: Cleanup.
2016-05-22 Dodji Seketeli <dodji@redhat.com>
Update the COMMIT-LOG-GUIDELINES file
* COMMIT-LOG-GUIDELINES: Various enhancements.
2016-05-16 Dodji Seketeli <dodji@redhat.com>
Do not run fedabipkgdiff tests if --enable-fedabipkgdiff is turned off
* tests/Makefile.am: Make running runtestfedabipkgdiff be
dependent on ENABLE_FEDABIPKGDIFF.
2016-05-13 Chenxiong Qi <cqi@redhat.com>
Fix pep8 error
* tools/fedabipkgdiff (build_commandline_args_parser): Fix
PEP8 error, line is too long.
2016-05-13 Chenxiong Qi <cqi@redhat.com>
Use consistent string format
* tools/fedabipkgdiff (download_rpm): do not omit positional
argument specifiers in string format.
2016-05-16 Dodji Seketeli <dodji@redhat.com>
Remove config.h.in from the repository
* config.h.in: Remove from repository.
2016-02-09 Chenxiong Qi <cqi@redhat.com>
Bug 19428 - New fedabipkgdiff utility
* autoconf-archive/ax_compare_version.m4: New file copied from the
autoconf-archive project.
* autoconf-archive/ax_prog_python_version.m4: Likewise.
* autoconf-archive/ax_python_module.m4: Likewise.
* Makefile.am: Add the new files above to the source distribution.
* configure.ac: Include the new m4 macros from the autoconf
archive. Add a new --enable-fedabipkgdiff option. Update the
report at the end of the configure process to show the status of
the fedabipkgdiff feature. Add check for prerequisite python
modules argparse, glob, logging, os, re, shlex, subprocess, sys,
itertools, urlparse, itertools, shutil, unittest, xdg, koji and
mock. These are necessary for the unit test of
fedabipkgdiff. Generate tests/runtestfedabipkgdiff.py into the
build directory, from the tests/runtestfedabipkgdiff.py.in input
file.
* tools/Makefile.am: Include the fedabipkgdiff to the source
distribution and install it if the "fedabipkgdiff" feature is
enabled.
* tests/Makefile.am: Rename runtestfedabipkgdiff.sh into
runtestfedabipkgdiff.py. Add the new runtestfedabipkgdiff.py.in
autoconf template file in here.
* tests/runtestfedabipkgdiff.py.in: New unit test file.
* tools/fedabipkgdiff: New fedabipkgdiff tool.
* doc/manuals/fedabipkgdiff.rst: New manual.
2016-05-07 Dodji Seketeli <dodji@redhat.com>
Implement a [suppress_file] suppression directive
* doc/manuals/libabigail-concepts.rst: Document the new
'suppress_file' directive.
* include/abg-suppression.h (file_suppression): Define new class.
(file_suppression_sptr): Define new typedef.
(is_file_suppression, file_is_suppressed): Declare new functions.
* src/abg-suppression.cc ():
(read_file_suppression, is_file_suppression, file_is_suppressed):
Define new functions.
(file_suppression::{file_suppression, suppresses_file,
~file_suppression}): Define new member functions.
* tools/abidiff.cc (main): If a suppression specification
suppresses one of the input files, then do not perform the
comparison.
* tools/abipkgdiff.cc (compare): If a suppression specification
suppresses a file that is to be compared, then do not perform the
comparison.
* tools/abicompat.cc (create_diff_context): New static function.
(perform_compat_check_in_normal_mode)
(perform_compat_check_in_weak_mode): Adjust to take a context in
parameter. Do not create a diff context here anymore, do not load
suppression files here either.
(main): Use the new create_diff_context to create a diff context
and initialize it, including loading suppression specifications.
If any suppression specification suppresses a file to load, then
do not load perform any compatibility checking. Adjust
invocations of perform_compat_check_in_weak_mode and
perform_compat_check_in_normal_mode to pass the diff context.
* tests/data/test-diff-suppr/test0-type-suppr-3.suppr: New test
input.
* tests/data/test-diff-suppr/test0-type-suppr-4.suppr: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-5.suppr: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-6.suppr: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-6.txt:
Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-7.txt:
Likewise.
* tests/test-diff-suppr.cc (in_out_specs): Use the new test
inputs.
* tests/data/test-abicompat/test0-fn-changed-1.suppr: New test
input.
* tests/data/test-abicompat/test0-fn-changed-report-3.txt:
Likewise.
* tests/test-abicompat.cc (in_out_specs):: Use the new test
inputs.
* tests/data/Makefile.am: Add the new test material to source
distribution.
2016-05-07 Dodji Seketeli <dodji@redhat.com>
Split suppression engine off of abg-comparison.{cc,h}
* include/Makefile.am: Add abg-suppression.h to source
distribution.
* include/abg-comparison.h: Remove abg-ini.h include directive.
(suppression_sptr, suppressions_type): Move these typedefs to
abg-fwd.h.
(class suppression_base, type_suppression)
(type_suppression::insertion_range)
(type_suppression::insertion_range::boundary)
(type_suppression::insertion_range::integer_boundary)
(type_suppression::insertion_range::fn_call_expr_boundary)
(function_suppression, function_suppression::parameter_spec)
(variable_suppression): Move these type definitions to the new
abg-suppression.h.
(read_suppressions, is_type_suppression, is_integer_boundary)
(is_fn_call_expr_boundary, is_function_suppression)
(is_variable_suppression, operator&)
(operator|): Move these function declarations to the new
abg-suppression.h.
(type_suppression, type_suppression_sptr, type_suppression_type)
(function_suppression, function_suppression_sptr)
(function_suppressions_type, variable_suppression)
(variable_suppression_sptr, variable_suppressions_type): Move
these forward declaration and typedefs to the new
abg-suppression.h.
(diff_context::suppressions): Adjust return type to
suppr::suppressions_type&.
(diff_context::add_suppression): Adjust parameter type to
suppr::suppressions_sptr.
(diff_context::add_suppressions): Adjust parameter type
suppr::suppressions_type&.
(is_type_diff, is_decl_diff, is_var_diff, is_function_decl_diff)
(is_pointer_diff, is_reference_diff, is_fn_parm_diff)
(is_base_diff, is_child_node_of_function_parm_diff)
(is_child_node_of_base_diff): Declare these new functions. They
were previously static, local to abg-comparison.cc only. Now they
need to be exported because they are used by the suppression
engine's code that now lives in its one files.
* include/abg-fwd.h (suppr::{suppression_base, suppression_sptr,
suppressions_type}): Forward declare these here.
* include/abg-suppression.h (class suppression_base)
(type_suppression, type_suppression::insertion_range)
(type_suppression::insertion_range::boundary)
(type_suppression::insertion_range::integer_boundary)
(type_suppression::insertion_range::fn_call_expr_boundary)
(function_suppression, function_suppression::parameter_spec)
(variable_suppression): Move these type definitions here, in the
namespace suppr.
(read_suppressions, is_type_suppression, is_integer_boundary)
(is_fn_call_expr_boundary, is_function_suppression)
(is_variable_suppression, operator&)
(operator|): Move these function decalration here, in the
namespace suppr.
(type_suppression_sptr, type_suppressions_type)
(function_suppression_sptr, function_suppressions_type)
(variable_suppression_sptr, variable_suppressions_type): Move
these typedefs here, in the namespace suppr.
* src/Makefile.am: add src/abg-suppression.cc to source
distribution.
* src/abg-comparison.cc (is_type_diff, is_decl_diff, is_var_diff)
(is_function_decl_diff, is_pointer_diff, is_reference_diff)
(is_reference_or_pointer_diff, is_fn_parm_diff, is_base_diff)
(is_child_node_of_function_parm_diff, is_child_node_of_base_diff):
Export these functions.
(*suppression*): Move all the suppression-related definitions to
the new abg-suppression.cc.
* src/abg-suppression.cc: New file. Contains all the *suppression*
definitions from src/abg-comparison.cc, that are put in the suppr
namespace.
* tools/abicompat.cc: Adjust.
* tools/abidiff.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
2016-05-08 Dodji Seketeli <dodji@redhat.com>
Fix indentation for abidiff manual
* doc/manuals/abidiff.rst: Fix indentation for the --suppression
paragraph.
2016-05-08 Dodji Seketeli <dodji@redhat.com>
Add several shortcuts to options for abicompat
* doc/manuals/abicompat.rst: Update documentation.
* tools/abicompat.cc (display_usage): Update help strings.
(parse_command_line): Add shortcuts --suppr, --appd, --libd1 and
--libd2.
2016-05-08 Dodji Seketeli <dodji@redhat.com>
Update copyright year in tools/abicompat.cc
* tools/abicompat.cc: Update copyright years to 2016.
2016-05-07 Dodji Seketeli <dodji@redhat.com>
Fix mention of tool's name in abidiff error message
* src/abg-tools-utils.cc (emit_prefix): Try to emit the prefix
only if the program name was provided.
* abidiff.cc (maybe_check_suppression_files): Pass the name of the
tool to the check_file function.
2016-05-07 Dodji Seketeli <dodji@redhat.com>
Update copyright year on abg-comparison.h
* include/abg-comparison.h: Update copyright year.
2016-05-08 Dodji Seketeli <dodji@redhat.com>
Doc not show classes' inherited members in apidoc
* doc/api/libabigail.doxy: Don't show inherited member functions
or variables of a given class.
2016-05-08 Dodji Seketeli <dodji@redhat.com>
Fix typo in concept manual
* doc/manuals/libabigail-concepts.rst: Do not refer to abidiff
specifically for suppressions because several tools use
suppressions.
2016-05-08 Dodji Seketeli <dodji@redhat.com>
Fix indentation in concepts manual
* doc/manuals/libabigail-concepts.rst: Fix indentation.
2016-05-06 Dodji Seketeli <dodji@redhat.com>
Add some apidoc to dwarf_reader
* include/abg-dwarf-reader.h (namespace dwarf_reader): Add apidoc.
(enum elf_type): Add an apidoc for each enumerator.
* src/abg-dwarf-reader.cc (get_type_of_elf_file): Add an apidoc
for the 'type' parameter.
2016-04-28 Dodji Seketeli <dodji@redhat.com>
[abipkgdiff] Show SONAME of removed/added libraries
* tools/abipkgdiff.cc (abi_diff::{added,removed}_binaries): Change
the type of these data member from vector<string> to
vector<elf_file_sptr>.
(compare): Adjust. Show the soname of added/removed binaries.
2016-04-27 Dodji Seketeli <dodji@redhat.com>
Bug 20015 - support file_name_not_regexp and soname_not_regexp in suppr specs
* include/abg-comparison.h
(suppression_base::{get,set}_file_name_not_regex_str): Declare new
member functions.
(suppression_base::{get,set}_soname_not_regex_str): Likewise.
(suppression_base::{names,sonames}_of_binaries_match): Likewise.
* src/abg-comparison.cc
(suppression_base::priv::get_file_name_regex): Fix comment.
(suppression_base::priv::get_file_name_not_regex): New member
function.
(suppression_base::priv::get_soname_regex): Fix comment.
(suppression_base::priv::get_soname_not_regex): New member
function.
(suppression_base::{get,set}_file_name_not_regex_str): Define new
member functions.
(suppression_base::{get,set}_soname_not_regex_str): Likewise.
(suppression_base::{names,sonames}_of_binaries_match): Likewise.
These got factorized out of type_suppression::suppresses_type,
function_suppression::suppresses_function,
function_suppression::suppresses_function_symbol,
variable_suppression::suppresses_variable,
variable_suppression::suppresses_variable_symbol.
(type_suppression::suppresses_type): Use the new
suppression_base::{names,sonames}_of_binaries_match.
(read_type_suppression): Read the new file_name_not_regexp and
soname_not_regexp properties.
(function_suppression::{suppresses_function,
suppresses_function_symbol}): Use the new
suppression_base::{names,sonames}_of_binaries_match.
(read_function_suppression): Read the new file_name_not_regexp and
soname_not_regexp properties.
(variable_suppression::{suppresses_variable,
variable_suppression::suppresses_variable_symbol}): Use the new
suppression_base::{names,sonames}_of_binaries_match.
(read_variable_suppression): Use the new
suppression_base::{names,sonames}_of_binaries_match.
* doc/manuals/libabigail-concepts.rst: Document the new
file_name_not_regexp and soname_not_regexp suppression properties.
* tests/data/test-diff-suppr/test24-soname-report-10.txt: New test
reference output.
* tests/data/test-diff-suppr/test24-soname-report-11.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-12.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-13.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-14.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-15.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-16.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-9.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-10.txt: New test input.
* tests/data/test-diff-suppr/test24-soname-suppr-11.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-12.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-13.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-14.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-15.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-16.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-9.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-2.txt: New test
reference output.
* tests/data/test-diff-suppr/test29-soname-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-8.txt: Likewise.
* tests/data/test-diff-suppr/test29-suppr-2.txt: New test input.
* tests/data/test-diff-suppr/test29-suppr-3.txt: Likewise.
* tests/data/test-diff-suppr/test29-suppr-4.txt: Likewise.
* tests/data/test-diff-suppr/test29-suppr-5.txt: Likewise.
* tests/data/test-diff-suppr/test29-suppr-6.txt: Likewise.
* tests/data/test-diff-suppr/test29-suppr-7.txt: Likewise.
* tests/data/test-diff-suppr/test29-suppr-8.txt: Likewise.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Make this test harness
run over the new test inputs.
2016-04-27 Dodji Seketeli <dodji@redhat.com>
Make API documentation of thread pools visible
* include/abg-workers.h: Document the workers namespace, the task,
queue and queue::task_done_notify types.
* src/abg-workers.cc: Move the documentation of the thread_pool
module inside the abigail::worker namespace, so that references to
task and queue types (which are also in the abigail::worker
namespace) can be resolved in the apidoc.
2016-04-27 Dodji Seketeli <dodji@redhat.com>
Update documentation to require doxygen and python-sphinx for building
* COMPILING: Add python-sphinx to the set of required packages to
build the documentation.
* doc/website/mainpage.txt: Update the website to mention doxygen
and python-sphinx for documentation.
2016-04-27 Dodji Seketeli <dodji@redhat.com>
Add doc, info, man and html-doc targets to generate documentation
* Makefile.am: Add info, man and html-doc targets to generate
documentation in info, man and html formats. If you want to
generate them all, then the doc target is the one to be used.
* COMPILING: Add documentation for the above.
2016-04-25 Dodji Seketeli <dodji@redhat.com>
Bug 19964 - Cannot load function aliases on ppc64
* src/abg-dwarf-reader.cc (read_context::load_symbol_maps): While
filling the ppc64-specific "function-entry-address => symbol" map,
if we stumble accross a function-entry-address that belongs to an
alias of 'symbol', then assume the alias must have been registered
as an alias already, by the platform-agnostic code. Do not try to
register the alias again.
* tests/data/Makefile.am: Add the new test input binaries to the
source distribution.
* tests/data/test-diff-dwarf/libtest36-ppc64-aliases-v0.so: New
binary test input.
* tests/data/test-diff-dwarf/libtest36-ppc64-aliases-v1.so: Likewise.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-report-0.txt:
New test reference output.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-v0.cc: Source
code for the new binary test input above.
* tests/data/test-diff-dwarf/test36-ppc64-aliases-v1.cc: Likewise.
* tests/test-diff-dwarf.cc: Add the new test input to the list of
test inputs considered by this test harness.
2016-04-20 Sinny Kumari <sinny@redhat.com>
Bug 19961 - Distinguish between PI executable and shared library
* include/abg-dwarf-reader.h (elf_type): Add new enumerator
ELF_TYPE_PI_EXEC.
* src/abg-dwarf-reader.cc
(lookup_data_tag_from_dynamic_segment): New function for
data tag lookup in dynamic segment of an elf
(elf_file_type): Return ELF_TYPE_PI_EXEC file type for
a PI executable.
(get_elf_file_type): Change this to take an elf handle.
(get_type_of_elf_file): New function that got factorized out of ...
(load_dt_soname_and_needed): ... this one.
* tools/abipkgdiff.cc (create_maps_of_package_content): Also
consider ELF_TYPE_PI_EXEC file type.
(compare): Likewise.
* tests/test-diff-pkg.cc (in_out_specs): Test case additions
* tests/data/Makefile.am: Include test files
* tests/data/test-diff-pkg/tarpkg-1-dir1.tar.gz: New test data
* tests/data/test-diff-pkg/tarpkg-1-dir2.tar.gz: New test data
* tests/data/test-diff-pkg/tarpkg-1-report-0.txt: New test result
2016-04-17 Dodji Seketeli <dodji@redhat.com>
Update website to 1.0.rc4
* doc/website/mainpage.txt: Update tarball reference to 1.0.rc4
2016-04-17 Dodji Seketeli <dodji@redhat.com>
Bump current version number to 1.0.rc5
* configure.ac: Bump current version number to 1.0.rc5
2016-04-17 Dodji Seketeli <dodji@redhat.com>
Add a 'release' target to main Makefile
* Makefile.am: Add tarball, upload-release-only, upload-release
and release targets.
2016-04-11 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 1.0.rc4
* ChangeLog: Update automatically by running "make
update-changelog"
2016-04-11 Dodji Seketeli <dodji@redhat.com>
Update NEWS for 1.0.rc4
* NEWS: Update for 1.0.rc4
2016-04-16 Dodji Seketeli <dodji@redhat.com>
Fix typos in the suppression specifications manual
* doc/manuals/libabigail-concepts.rst: Fix typos.
2016-04-16 Dodji Seketeli <dodji@redhat.com>
Ease use of soname_regexp/file_name_regexp in suppr specs
* doc/manuals/libabigail-concepts.rst: Update the manual to
reflect the changes in the suppression_type, suppress_function and
suppress_variable directives.
* src/abg-comparison.cc (read_type_suppression): Accept that
the suppress_type directive contains only file_name_regexp
or the soname_regexp property.
(read_function_suppression): Likewise for the suppress_function
directive.
(read_variable_suppression): Likewise for the suppress_variable
directive.
* tests/data/test-diff-suppr/libtest29-soname-v0.so: New binary
test input.
* tests/data/test-diff-suppr/libtest29-soname-v1.so: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-5.txt: New
reference test output.
* tests/data/test-diff-suppr/test24-soname-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-report-8.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-5.txt: New test
suppression file.
* tests/data/test-diff-suppr/test24-soname-suppr-6.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-7.txt: Likewise.
* tests/data/test-diff-suppr/test24-soname-suppr-8.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-report-0.txt: New
reference test output.
* tests/data/test-diff-suppr/test29-soname-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test29-soname-v0.cc: Source code for
the new binary output above.
* tests/data/test-diff-suppr/test29-soname-v1.cc: Likewise.
* tests/data/test-diff-suppr/test29-suppr-0.txt: New test
suppression file.
* tests/data/test-diff-suppr/test29-suppr-1.txt: Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_specs): Make this test harness
run over the new test input above.
2016-03-31 Dodji Seketeli <dodji@redhat.com>
Fix comments in tests/test-diff-pkg.cc
* tests/test-diff-pkg.cc: Fix the wording of the introductory
comments.
2016-03-30 Dodji Seketeli <dodji@redhat.com>
Bug 19885 - Cannot associates a function DIE to a symbol on powerpc64
*from* the address of its entry point.
More precisely, on ppc64, the address of a function is the address of
a function descriptor. The function descriptor is a set of three 64
bits addresses. The first element of the triplet is the function
entry pointer address. So to get the symbol a given function entry
point address belongs to, one must get to the function descriptor
which contains said function entry point address. And function
descriptors are in the ".opd" special section.
Unfortunately, Libabigail's ELF/DWARF reader has no knowledge of all
this. So it cannot get the symbol of a given function DWARF
description. So it considers all functions as having no ELF symbols.
So it shows no ABI change pertaining to function sub-types on ppc64.
This patch makes Libabigail support function descriptors on ppc64 so
it can detect changes on function sub-types there.
* src/abg-dwarf-reader.cc (read_context::{opd_section_,
fun_entry_addr_sym_map_}): New data members.
(read_context::read_context): Initialize the new opd_section_ data
member.
(read_context::{find_opd_section,
lookup_ppc64_elf_fn_entry_pointer_address,
fun_entry_addr_sym_map_sptr, fun_entry_addr_sym_map,
elf_architecture_is_ppc64, elf_architecture_is_big_endian}): New
member functions.
(read_context::lookup_elf_fn_symbol_from_address): Adjust to use
the new read_context::fun_entry_addr_sym_map() function.
(read_context::load_symbol_maps): Populate the function entry
addresses -> symbol map, for ppc64 ELFv1.
(read_context::load_elf_properties): Renamed
read_context::load_remaining_elf_data into this.
(read_corpus_from_elf): Load elf properties before trying to load
elf symbols information.
* tests/data/test-diff-filter/libtest32-struct-change-v0.so: New
binary test input, compiled for ppc64le.
* tests/data/test-diff-filter/libtest32-struct-change-v1.so: Likewise.
* tests/data/test-diff-filter/test32-ppc64le-struct-change-report0.txt:
New test reference output.
* tests/data/test-diff-filter/test32-ppc64le-struct-change-v0.c:
Source code of the new binary test input above.
* tests/data/test-diff-filter/test32-ppc64le-struct-change-v1.c:
Likewise.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-filter.cc (in_out_spec): Make this test harness
run over the new test input binaries above.
2016-03-25 Dodji Seketeli <dodji@redhat.com>
Fix logs in abipkgdiff and add some more
* tools/abipkgdiff.cc (compare): Fix logs to make them more
readable in a multithreaded context.
(create_maps_of_package_content): Likewise. Add logs about the
number of elf files found in a given directory. Add logs about
skipping files.
2016-03-25 Dodji Seketeli <dodji@redhat.com>
Bug 19867 - abipkgdiff skips symbolic links
* include/abg-tools-utils.h (maybe_get_symlink_target_file_path):
Declare new function.
* src/abg-tools-utils.cc (get_stat): Use lstat here, not stat.
Update comment.
* tools/abipkgdiff.cc (first_package_tree_walker_callback_fn)
(second_package_tree_walker_callback_fn): Follow symbolic links to
elf files to get their target paths, and only work with that
target path.
(maybe_get_symlink_target_file_path): Define new function.
* test-diff-pkg/symlink-dir-test1-report0.txt New test material.
* test-diff-pkg/symlink-dir-test1/dir1/symlinks/foo.o: Likewise.
* test-diff-pkg/symlink-dir-test1/dir1/symlinks/libfoo.so: Likewise.
* test-diff-pkg/symlink-dir-test1/dir1/targets/foo.c: Likewise.
* test-diff-pkg/symlink-dir-test1/dir1/targets/foo.o: Likewise.
* test-diff-pkg/symlink-dir-test1/dir1/targets/libfoo.so: Likewise.
* test-diff-pkg/symlink-dir-test1/dir2/symlinks/foo.o: Likewise.
* test-diff-pkg/symlink-dir-test1/dir2/symlinks/libfoo.so: Likewise.
* test-diff-pkg/symlink-dir-test1/dir2/targets/foo.c: Likewise.
* test-diff-pkg/symlink-dir-test1/dir2/targets/foo.o: Likewise.
* test-diff-pkg/symlink-dir-test1/dir2/targets/libfoo.so: Likewise.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-pkg.cc (in_out_spec): Run this test harness
over the new test material above.
2016-03-21 Dodji Seketeli <dodji@redhat.com>
Fix typo on the web page
* doc/website/mainpage.txt: Fix typo.
2016-03-18 Roland McGrath <roland@hack.frob.com>
Fix typo in configure --enable-deb help text
* configure.ac: Fix typo in --enable-deb usage text.
2016-03-18 Dodji Seketeli <dodji@redhat.com>
Bug 19846 - variable decl associated with the wrong debug info section
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Associate the
decl of the variable to the same debug info file (alternate or
not) as the DIE, not as its specification DIE.
2016-03-18 Dodji Seketeli <dodji@redhat.com>
Fix typo in the manual of abidiff
* doc/manuals/abidiff.rst: Fix typo.
2016-03-18 Dodji Seketeli <dodji@redhat.com>
Fix typos in comments in src/abg-dwarf-reader.cc
* src/abg-dwarf-reader.cc (read_context::{die_type_map,
is_wip_class_die_offset, is_wip_function_type_die_offset}): Fix
typo in comments.
2016-03-18 Dodji Seketeli <dodji@redhat.com>
Bug 19844 - Cannot try to canonicalize a type that is being constructed
* src/abg-dwarf-reader.cc
(read_context::{alternate_die_wip_classes_map_,
alternate_die_wip_function_types_map_}): New data members.
(read_context::lookup_type_from_die_offset): Lookup WIP class and
function types too.
(read_context::{die_wip_classes_map, die_wip_function_types_map}):
Take a flag saying if we should get the map for the alternate
debug info section or not.
(read_context::{is_wip_class_die_offset,
is_wip_function_type_die_offset}): Take a flagy saying if the DIE
is in the alternate debug info section or not.
(build_class_type_and_add_to_ir, build_function_type)
(maybe_canonicalize_type): Adjust.
(build_ir_node_from_die): Do not call maybe_canonicalize_type on
type DIEs which no type has been constructed for.
* tests/data/test-diff-pkg/gtk2-debuginfo-2.24.22-5.el7.i686.rpm:
New test input.
* tests/data/test-diff-pkg/gtk2-debuginfo-2.24.28-8.el7.i686.rpm:
Likewise.
* tests/data/test-diff-pkg/gtk2-immodule-xim-2.24.22-5.el7.i686.rpm:
Likewise.
* tests/data/test-diff-pkg/gtk2-immodule-xim-2.24.28-8.el7.i686.rpm:
Likewise.
* tests/data/test-diff-pkg/gtk2-immodule-xim-2.24.22-5.el7.i686--gtk2-immodule-xim-2.24.28-8.el7.i686-report-0.txt:
New test reference output.
* tests/data/Makefile.am: Add the new test material to the source
distribution.
* tests/test-diff-pkg.cc (in_out_spec): Make this test harness run
on the new test input above.
2016-03-16 Dodji Seketeli <dodji@redhat.com>
Fix a typo in include/abg-tools-utils.h
* include/abg-tools-utils.h (enum abidiff_status): Fix typo in
comment.
2016-03-16 Dodji Seketeli <dodji@redhat.com>
Update copyright dates for the manuals
* doc/manuals/conf.py: Update copyright years.
2016-03-16 Dodji Seketeli <dodji@redhat.com>
More docs about ABIDIFF_ABI_INCOMPATIBLE_CHANGE
* doc/manuals/abidiff.rst: Explain the kind of changes that flip
the ABIDIFF_ABI_INCOMPATIBLE_CHANGE flag.
2016-03-09 Dodji Seketeli <dodji@redhat.com>
Fix typos on the web page
* doc/website/mainpage.txt: Fix typos.
2016-03-08 Dodji Seketeli <dodji@redhat.com>
Bump version number to 1.0.rc4
* configure.ac: Bump version number to 1.0.rc4
2016-03-08 Dodji Seketeli <dodji@redhat.com>
Fix potential race condition in test-diff-pkg.cc
* tests/test-diff-pkg.cc (in_out_spec): Make the tar format tests
output have different names.
2016-03-08 Dodji Seketeli <dodji@redhat.com>
Updated website to point to 1.0.rc3 tarball
* doc/website/mainpage.txt: Updated website to point to 1.0.rc3
tarball.
2016-03-08 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog before 1.0.rc3
* ChangeLog: Update for 1.0.rc3
2016-03-08 Dodji Seketeli <dodji@redhat.com>
Update NEWS file for 1.0.rc3
* NEWS: update for 1.0.rc3
2016-03-07 Dodji Seketeli <dodji@redhat.com>
Walk function_type_diff tree in a deterministic way
* src/abg-comparison.cc
(function_type_diff::priv::{sorted_subtype_changed_parms_,
sorted_changed_parms_by_id_}): Add two data members.
(function_type_diff::ensure_lookup_tables_populated): Sort the
changed parameters here ...
(function_type_diff::report): ... not here.
(function_type_diff::chain_into_hierarchy): Chain the *sorted*
changed parameters.
2016-03-07 Dodji Seketeli <dodji@redhat.com>
Fix reference to test file in Makefile.am
* tests/data/Makefile.am: Fix bogus reference to
libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt.
2016-03-07 Dodji Seketeli <dodji@redhat.com>
Bug 19780 - abipkgdiff doesn't support parallel execution
* tools/abipkgdiff.cc: Update copyright notice.
(package::extracted_packages_parent_dir): Use mkdtemp to generate
the unique root directory under which packages are extracted.
* tests/test-diff-pkg.cc (struct test_task): New type.
(main): Use worker threads to run abipkgdiff in parallel,
depending on the number of CPUs advertised by the underlying
machine.
2016-03-07 Dodji Seketeli <dodji@redhat.com>
Bug 19778 - diff_has_ancestor_filtered_out() loops forever
* src/abg-comparison.cc (diff_has_ancestor_filtered_out): Add an
overload that takes an additional map of pointer values. Make the
older overload call the new one.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm: New test material.
* tests/data/test-diff-pkg/libICE-1.0.6-1.el6.x86_64.rpm--libICE-1.0.9-2.el7.x86_64.rpm-report-0.txt:
New reference output.
* tests/data/test-diff-pkg/libICE-1.0.9-2.el7.x86_64.rpm: New test material.
* tests/data/test-diff-pkg/libICE-debuginfo-1.0.6-1.el6.x86_64.rpm: New test material.
* tests/data/test-diff-pkg/libICE-debuginfo-1.0.9-2.el7.x86_64.rpm:
New test material.
* tests/data/Makefile.am: Add the new test material to source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Run this test harness
over the new tests material above.
2016-03-07 Dodji Seketeli <dodji@redhat.com>
Forgot to add test2-filtered-removed-fns-v{0,1}.o
* test2-filtered-removed-fns-v{0,1}.o: Add these test input files.
2016-03-03 Dodji Seketeli <dodji@redhat.com>
Bug 19596 - Suppressed removed symbol changes still considered incompatible
* src/abg-comparison.cc (corpus_diff::has_incompatible_changes):
Consider the *net* number of removed function and variable
symbols. Also, if all function sub-type changes have been
suppressed, then no virtual offset change should be considered
incompatible.
* tests/data/test-abidiff-exit/test1-voffset-change-report1.txt
* tests/data/test-abidiff-exit/test1-voffset-change.abignore
* tests/data/test-abidiff-exit/test2-filtered-removed-fns-report0.txt
* tests/data/test-abidiff-exit/test2-filtered-removed-fns-report1.txt
* tests/data/test-abidiff-exit/test2-filtered-removed-fns-v0.c
* tests/data/test-abidiff-exit/test2-filtered-removed-fns-v1.c
* tests/data/test-abidiff-exit/test2-filtered-removed-fns.abignore
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abidiff-exit.cc (InOutSpec::in_suppr_path): New data
member.
(in_out_specs): Adjust. Add new test inputs.
(main): Adjust.
2016-02-25 Dodji Seketeli <dodji@redhat.com>
Fixup virtual member functions with linkage and no underlying symbol
* src/abg-dwarf-reader.cc (die_function_decl_map_type): New
typedef.
(read_context::die_function_with_no_symbol_map_): New data member.
(read_context::die_function_decl_with_no_symbol_map): New
accessor.
(read_context::fixup_functions_with_no_symbols): New member
function.
(finish_member_function_reading): Take a read_context. Schedule
virtual member functions with linkage and no underlying symbol to
be fixed up after all the debug info is read.
(build_function_decl): After a virtual member function_decl has
been updated, if it has its underlying symbol and was scheduled
for fixup, then de-schedule it.
(build_class_type_and_add_to_ir, build_ir_node_from_die): Adjust
call to finish_member_function_reading.
(read_corpus_from_elf): Move the pure ELF (symbol and other mundane
information) information reading ...
(read_debug_info_into_corpus): ... here. Make it happen *before*
actual reading of DWARF information. We need symbol information
to be present and fully set before we start reading debug info.
This is so that we can know when a virtual member function doesn't
need to be fixed up. Also, perform the fixup after the debug
information was read.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
2016-02-25 Dodji Seketeli <dodji@redhat.com>
Add --verbose to abidw
* doc/manuals/abidw.rst: Update the manual for the new --verbose
option.
* tools/abidw.cc (options::do_log): New data member.
(options::options): Initialize it.
(display_usage): New string for --verbose.
(parse_command_line): Parse the --verbose option.
(main): Set the the logging option.
2016-02-25 Dodji Seketeli <dodji@redhat.com>
Update copyright information
* tools/abidiff.cc: Update copyright info for 2016.
* tools/abidw.cc: Likewise.
2016-02-24 Dodji Seketeli <dodji@redhat.com>
Make libabigail link with pthread
* src/Makefile.am: Add -pthread to libabigail_la_LDFLAGS.
* tools/Makefile.am: Do not use abinilint_LDFLAGS when it should
be abinilint_LDADD. This one was fixed by Michi Henning.
2016-02-24 Dodji Seketeli <dodji@redhat.com>
Update mentions to the build dependencies in the doc
* COMPILING: Mention elfutils, libtool, autoconf, automake and
libtool.
* doc/website/mainpage.txt: Mention automake and libtool. Fix a typo.
2016-02-24 Dodji Seketeli <dodji@redhat.com>
Bug 19706 - Core dump from abidiff with suppression
* src/abg-comparison.cc
(function_suppression::suppresses_function): Make sure a function
has a symbol before (de)referencing it.
2016-02-24 Dodji Seketeli <dodji@redhat.com>
Some small speed optimizations
* include/abg-ir.h (var_decl::get_naked_type): Declare new member function.
* src/abg-ir.cc (var_decl::get_naked_type): Define it.
(equals): For the var_decl overload, avoid copying symbol
smart pointers. Likewise for variable type smart pointers.
(hash_type_or_decl): Avoid accessing canonical type smart pointer.
2016-02-24 Dodji Seketeli <dodji@redhat.com>
Mist style cleanups
* include/abg-ir.h: Add missing comments. Space cleanups. Use
shorter typedefs rather than long template instantiation names.
Use string rather than the longer std::string.
* src/abg-ir.cc: Space cleanups. Add missing comments. User
shorter typedefs.
* src/abg-reader.cc: Likewise.
* src/abg-writer.cc: Likewise.
2016-02-24 Dodji Seketeli <dodji@redhat.com>
Implement string interning for Libabigail
* include/Makefile.am: Add the new abg-interned-str.h file to
source distribution.
* include/abg-corpus.h (corpus::corpus): Re-arrange the order of
* src/abg-corpus.cc
(corpus::exported_decls_builder::priv::get_id): Return
interned_string rather than std::string.
(corpus::corpus): Re-arrange the order of parameters: take an
environment as first parameter. parameters: take an environment
as first parameter.
* include/abg-dwarf-reader.h (lookup_symbol_from_elf)
(lookup_public_function_symbol_from_elf): Likewise.
* src/abg-dwarf-reader.cc (lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab)
(lookup_symbol_from_elf_hash_tab, lookup_symbol_from_symtab)
(lookup_symbol_from_elf, lookup_public_function_symbol_from_elf)
(lookup_public_variable_symbol_from_elf, lookup_symbol_from_elf)
(lookup_public_function_symbol_from_elf): Take an environment as
first parameter and adjust.
(build_translation_unit_and_add_to_ir)
(build_namespace_decl_and_add_to_ir, build_type_decl)
(build_enum_type, finish_member_function_reading)
(build_class_type_and_add_to_ir, build_function_type)
(read_debug_info_into_corpus, read_corpus_from_elf): Adjust.
* include/abg-fwd.h: Include abg-interned-str.h
(get_type_name, get_function_type_name, get_method_type_name):
Return a interned_string, rather than a std::string.
* include/abg-interned-str.h: New declarations for interned strings
and their pool.
* include/abg-ir.h (environment::intern): Declare new method.
(elf_symbol::{g,s}et_environment): Likewise.
(type_or_decl_base::type_or_decl_base): Make the default
constructor private.
({translation, type_or_decl_base}::set_environment)
(set_environment_for_artifact): Take a const environment*.
(elf_symbol::elf_symbol)
(elf_symbol::create)
(type_or_decl_base::type_or_decl_base)
(translation::translation, decl_base::decl_base)
(scope_decl::scope_decl, type_base::type_base)
(type_decl::type_decl, scope_type_decl::scope_type_decl)
(namespace_decl::namespace_decl)
(enum_type_decl::enumerator::enumerator)
(function_type::function_type, method_type::method_type)
(template_decl::template_decl, function_tdecl::function_tdecl)
(class_tdecl::class_tdecl, class_decl::class_decl): Take an
environment.
(type_or_decl_base::operator=)
(enum_type_decl::enumerator::get_environment): Declare new method.
(decl_base::{peek_qualified_name, peek_temporary_qualified_name,
get_qualified_name, get_name, get_qualified_parent_name,
get_linkage_name}, qualified_type_def::get_qualified_name)
(reference_type_def::get_qualified_name)
(array_type_def::get_qualified_name)
(enum_type_decl::enumerator::{get_name, get_qualified_name})
({var,function}_decl::get_id)
(function_decl::parameter::{get_type_name, get_name_id}): Return
an interned_string, rather than a std::string.
(decl_base::{set_qualified_name, set_temporary_qualified_name,
get_qualified_name, set_linkage_name})
(qualified_type_def::get_qualified_name)
(reference_type_def::get_qualified_name)
(array_type_def::get_qualified_name)
(function_decl::parameter::get_qualified_name): Take an
interned_string, rather than a std::string.
(class_decl::member_{class,function}_template::member_{class,function}_template):
Adjust.
* src/abg-ir.cc (environment_setter::env_): Make this be a pointer
to const environment.
(environment_setter::visit_begin): Adjust.
(interned_string_pool::priv): Define new type.
(interned_string_pool::*): Define the method declared in
abg-interned-str. h.
(operator==, operator!=, operator+): Define operator for interned_string and
std::string
(operator<<): Define for interned_string.
(translation_unit::priv::env_): Make this be a pointer to const
environment.
(translation_unit::priv::priv): Take a pointer to const
environment.
(elf_symbol::priv::env_): New data member.
(elf_symbol::priv::priv): Adjust. Make an overoad take an
environment.
(translation_unit::{g,s}et_environment): Adjust.
(interned_string_bool_map_type): New typedef.
(environment::priv::classes_being_compared_): Make this hastable
of string be a hashtable of interned_string.
(environment::priv::string_pool_): New data member.
(environment::{get_void_type_decl,
get_variadic_parameter_type_decl}): Adjust.
(type_or_decl_base::priv::env_): Make this be a pointer to const
environment.
(type_or_decl::base::priv::priv): Adjust.
(type_or_decl_base::set_environment)
(set_environment_for_artifact): Take a pointer to const
environment.
(elf_symbol::{g,s}et_environment, environment::intern)
(type_or_decl_base::operator=): Define new methods.
(decl_base::priv::{name_, qualified_parent_name_,
temporary_qualified_name_, qualified_name_, linkage_name_}): Make
these data member be of tpe interned_string.
(decl_base::priv::priv): Make this take an environment. Adjust.
(decl_base::{peek_qualified_name, peek_temporary_qualified_name,
get_linkage_name, get_qualified_parent_name, get_name,
get_qualified_name}, get_type_name, get_function_type_name)
(get_method_type_name, get_node_name)
(qualified_type_def::get_qualified_name)
(pointer_type_def::get_qualified_name)
(array_type_def::get_qualified_name)
(enum_type_decl::enumerator::get_qualified_name)
(var_decl::get_id, function_decl::get_id)
(function_decl::parameter::get_{name_id, type_name}): Return an
interned_string.
(decl_base::{set_qualified_name, set_temporary_qualified_name})
(qualified_type_def::get_qualified_name)
(pointer_type_def::get_qualified_name)
(reference_type_def::get_qualified_name)
(array_type_def::get_qualified_name)
(function_decl::parameter::get_qualified_name): Take an
interned_string.
(decl_base::{set_name, set_linkage_name}): Intern the std::string
passed in parameter.
(equals): In the overload for decl_base, adjust for a little speed
optimization that is justified by profiling.
(pointer_type_def::priv::{internal_qualified_name_,
temp_internal_qualified_name_}): Make these data member be
interned_string.
(enum_type_decl::enumerator::priv::env_): New data member.
(enum_type_decl::enumerator::priv::{name_, qualified_name}): Make
these data member be of type interned_string.
(enum_type_decl::enumerator::get_environment): New method.
(enum_type_decl::enumerator::priv::priv) Adjust.
(typedef_decl::operator==): Implement a little speed optimization.
(var_decl::priv::nake_type_): New data member.
(var_decl::priv::id_): Make this data member be of type
interned_string.
(equals): In the overload for var_decl, function_type,
function_decl, adjust for the use of interned_string.
(function_decl::priv::id_): Make this be of type interned_string.
(scope_decl::{add_member_decl, insert_member_decl})
(lookup_function_type_in_translation_unit)
(synthesize_type_from_translation_unit, lookup_node_in_scope)
(lookup_type_in_scope, scope_decl::scope_decl)
(qualified_type_def::qualified_type_def)
(qualified_type_def::get_qualified_name)
(pointer_type_def::pointer_type_def)
(reference_type_def::reference_type_def)
(array_type_def::array_type_def, array_type_def::append_subrange)
(array_type_def::get_qualified_name)
(enum_type_decl::enum_type_decl)
(enum_type_decl::enumerator::get_qualified_name)
(enum_type_decl::enumerator::set_name)
(typedef_decl::typedef_decl, var_decl::var_decl)
(function_type::function_type, method_type::method_type)
(function_decl::function_decl)
(function_decl::parameter::parameter)
(class_decl::priv::comparison_started)
(class_decl::add_base_specifier)
(class_decl::base_spec::base_spec)
(class_decl::method_decl::method_decl)
(type_tparameter::type_tparameter)
(non_type_tparameter::non_type_tparameter)
(template_tparameter::template_tparameter)
(type_composition::type_composition)
(function_tdecl::function_tdecl, class_tdecl::class_tdecl)
(qualified_name_setter::do_update): Adjust.
(translation_unit::translation_unit, elf_symbol::elf_symbol)
(elf_symbol::create, type_or_decl_base::type_or_decl_base)
(decl_base::decl_base, type_base::type_base)
(type_decl::type_decl, scope_type_decl::scope_type_decl)
(namespace_decl::namespace_decl)
(enum_type_decl::enumerator::enumerator, class_decl::class_decl)
(template_decl::template_decl, function_tdecl::function_tdecl)
(class_tdecl::class_tdecl): Take an environment.
* src/abg-comparison.cc
(function_suppression::suppresses_function): Adjust.
* src/abg-reader.cc (read_translation_unit)
(read_corpus_from_input, build_namespace_decl, build_elf_symbol)
(build_function_parameter, build_function_decl, build_type_decl)
(build_function_type, build_enum_type_decl, build_enum_type_decl)
(build_class_decl, build_function_tdecl, build_class_tdecl)
(read_corpus_from_native_xml): Likewise.
* src/abg-writer.cc (id_manager::m_cur_id): Make this mutable.
(id_manager::m_env): New data member.
(id_manager::id_manager): Adjust.
(id_manager::get_environment): New method.
(id_manager::{get_id, get_id_with_prefix}): Return an
interned_string.
(type_ptr_map): Make this be a hash map of type_base* ->
interned_string, rather a type_base* -> string.
(write_context::m_env): New data member.
(write_context::m_type_id_map): Make this data member be mutable.
(write_context::m_emitted_type_id_map): Make this be a hash map of
interned_string -> bool, rather than string -> bool.
(write_context::write_context): Take an environment and adjust.
(write_context::get_environment): New method.
(write_context::get_id_manager): New const overload.
(write_context::get_id_for_type): Return an interned_string; adjust.
(write_context::{record_type_id_as_emitted,
record_type_as_referenced}): Adjust.
(write_context::type_id_is_emitted): Take an interned_string.
(write_context::{type_is_emitted,
record_decl_only_type_as_emitted}): Adjust.
(write_translation_unit, write_corpus_to_native_xml, dump):
Adjust.
* tools/abisym.cc (main): Adjust.
* tests/data/test-read-write/test22.xml: Adjust.
* tests/data/test-read-write/test23.xml: Adjust.
* tests/data/test-read-write/test26.xml: Adjust.
2016-02-24 Dodji Seketeli <dodji@redhat.com>
Update copyright notice
* include/abg-corpus.h: Update copyright notice.
* include/abg-dwarf-reader.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-ir.cc: Likewise.
2016-02-23 Dodji Seketeli <dodji@redhat.com>
Fix crash when handling templates with empty patterns
* src/abg-ir.cc (function_tdecl::traverse): Do not crash when
traversing a template with empty pattern.
(class_tdecl::operator==): Do not crash when comparing templates
with empty patterns.
2016-02-23 Dodji Seketeli <dodji@redhat.com>
Add missing inequality operators for ABI artifacts
* include/abg-ir.h ({translation_unit, elf_symbol::version,
context_rel, decl_base, type_base, type_decl,
array_type_def::subrange_type, enum_type_def::enumerator,
dm_context_rel, template_parameter}::operator!=): Declare.
(operator==): Make the overload form translation_unit_sptr,
scope_decl_sptr, class_decl::base_spec_sptr,
class_decl::member_function_template_sptr,
class_decl::member_class_template_sptr take const references.
(operator!=): Declare an an overload for the non-member operator
!= of translation_unit_sptr, elf_symbol_sptr,
type_or_decl_base_sptr, type_base_sptr, scope_decl_sptr,
type_decl, qualified_type_def_sptr, pointer_type_def_sptr,
reference_type_def_sptr, enum_type_decl_sptr, class_decl_sptr,
class_decl::base_spec_sptr,
class_decl::member_function_template_sptr,
class_decl::member_class_template_sptr.
* src/abg-ir.cc ({translation_unit, elf_symbol::version,
context_rel, decl_base, type_base, type_decl,
array_type_def::subrange_type, enum_type_def::enumerator,
dm_context_rel, template_parameter}::operator!=): Define.
(operator==): Make the overload for translation_unit_sptr,
scope_decl_sptr, class_decl::base_spec_sptr,
class_decl::member_function_template_sptr,
class_decl::member_class_template_sptr take const references.
(operator!=): Define an an overload for the non-member operator !=
of translation_unit_sptr, elf_symbol_sptr, type_or_decl_base_sptr,
type_base_sptr, scope_decl_sptr, type_decl,
qualified_type_def_sptr, pointer_type_def_sptr,
reference_type_def_sptr, enum_type_decl_sptr, class_decl_sptr,
class_decl::base_spec_sptr,
class_decl::member_function_template_sptr,
class_decl::member_class_template_sptr.
2016-02-20 Dodji Seketeli <dodji@redhat.com>
Make the tree pass distcheck again.
* tests/data/Makefile.am: Add file
test-diff-suppr/test28-add-aliased-function-report-0.txt to source
distribution.
2016-02-18 Dodji Seketeli <dodji@redhat.com>
Bug 19658 - Type canonicalization slow for the 2nd binary loaded
* include/abg-corpus.h (corpus::{record_canonical_type,
lookup_canonical_type}): Declare new member functions.
* src/abg-corpus.cc (corpus::priv::canonical_types_): New data
member.
(corpus::{record_canonical_type, lookup_canonical_type}): Define
new member functions.
* src/abg-ir.cc (type_base::get_canonical_type_for): Cache the
canonical type inside the corpus of the type being canonicalized.
Then later when canonicalizing another type, lookup in the cache
inside its corpus to see if there is a type with the same name.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Adjust.
2016-02-18 Dodji Seketeli <dodji@redhat.com>
Add --verbose option to abidiff
* doc/manuals/abidiff.rst: Add documentation for new --verbose
option.
* include/abg-dwarf-reader.h (set_do_log): Declare new function.
* src/abg-dwarf-reader.cc (read_context::do_log_): New data
member.
(read_context::read_context): Initialize the new data member.
(read_context::do_log): Define accessors.
(set_do_log): Define new function;
(read_context::canonicalize_types_scheduled)
(read_debug_info_into_corpus): Add logs.
* tools/abidiff.cc (options::do_log): New data member.
(options::options): Initialize it.
(display_usage): Add an usage string for --verbose.
(parse_command_line): Parse the new --verbose option.
(main): Set the dwarf reader's context wrt presence of the
--verbose option.
2016-02-18 Dodji Seketeli <dodji@redhat.com>
Fix indentation
* tools/abipkgdiff.cc (parse_command_line): Fix a wrong indentation.
2016-02-17 Dodji Seketeli <dodji@redhat.com>
Bug 19638 - DWARF reader fails to link clone function to its declaration
* include/abg-ir.h (decl_base::set_linkage_name): Make this member
function virtual.
(class_decl::string_mem_fn_ptr_map_type): Define new member type.
(class_decl::find_member_function): Declare new member function.
(copy_member_function): Declare new function. Declare it as
friend of class_decl.
(method_decl::set_linkage_name): Declare an overload for this
virtual function.
* src/abg-dwarf-reader.cc (build_function_decl): Allow updating of
linkage_name even if the linkage_name was already defined.
(build_ir_node_from_die): In the case DW_TAG_subprogram, make the
lookup of scope of the DIE work even if it has both an abstract
origin and a specification (DW_AT_abstract_origin and
DW_AT_specification).
* src/abg-ir.cc (maybe_adjust_canonical_type): Define new
function.
(canonicalize): Use it.
(function_decl::get_id): Return the linkage name first, if it
exist.
(class_decl::priv::mem_fns_map_): New data member.
(class_decl::find_member_function): Define new member function.
(class_decl::method_decl::set_linkage_name): Likewise.
(class_decl::add_member_function): Update the new data member
class_decl::priv::mem_fns_map_.
(copy_member_function): Define new static function.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2016-02-17 Dodji Seketeli <dodji@redhat.com>
Add function lookup by linkage name to libabigail::corpus
* include/abg-corpus.h (corpus::lookup_functions): Declare new
member function.
* src/abg-corpus.cc (class corpus::exported_decls_builder::priv):
Make class corpus be a friend of this type.
(corpus::exported_decls_builder::priv::add_fn_to_id_fns_map): Fix
a thinko that was preventing the fn_id -> functions map from ever
being filled. Fix this function to make it associate each aliases
of a given function to the function, in the hash table.
(corpus::lookup_functions): Define new member function.
2016-02-17 Dodji Seketeli <dodji@redhat.com>
Fix style cleanups
* include/abg-ir.h (method_type::{method_type, set_class_type,
get_type, set_type}): Use type_base_sptr and class_decl_sptr
instead of the full non-typedefed name.
(method_type):Do some cleanups in the definition of the
convenience typedefs.
* src/abg-ir.cc (method_type::{method_type, set_class_type,
get_type, set_type}): Use type_base_sptr and class_decl_sptr
instead of the full non-typedefed name.
* src/abg-writer.cc (write_class_decl): Add a comment.
2016-02-13 Dodji Seketeli <dodji@redhat.com>
Bug 19619 - failing to suppress added aliased function reports for C++
* src/abg-comparison.cc
(function_suppression::suppresses_function): Make the evaluation
of the "name" and "name_regexp" consider the cases of languages in
which the function name is the same as the symbol name and the
case of languages in which it is not. In the former case, all
symbol alias names must be matched. In the latter case, if "name"
and "name_regexp" match the function name, the suppression
specification is considered to match the report about the function
change. Also, use the elf_symbol::is_main_symbol() predicate to
test for the symbol being a main symbol, rather than using
error-prone pointer equality.
* tests/data/test-diff-suppr/test27-add-aliased-function-0.suppr:
New test input.
* tests/data/test-diff-suppr/test27-add-aliased-function-1.suppr: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-2.suppr: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-3.suppr: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-4.suppr: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-v0.cc: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-v0.o: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-v1.cc: Likewise.
* tests/data/test-diff-suppr/test27-add-aliased-function-v1.o: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-0.suppr: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-1.suppr: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-2.suppr: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-3.suppr: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-4.suppr: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-5.suppr: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-v0.c: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-v0.o: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-v1.c: Likewise.
* tests/data/test-diff-suppr/test28-add-aliased-function-v1.o: Likewise.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-diff-suppr.cc: Add the new test inputs above to this
test harness.
2016-02-12 Dodji Seketeli <dodji@redhat.com>
Emit more informational messages on unrecognized options
* tools/abicompat.cc (options::prog_name): New data member.
(display_help, perform_compat_check_in_normal_mode)
(perform_compat_check_in_weak_mode, main): Prefix error messages
with the name of the program.
* tools/abidw.cc (options::wrong_option): New data member.
(display_help): Prefix error messages with the name of the
program.n
(parse_command_line): Record the name of the unrecognized option.
(main): Tell the name of the unrecognized option. Prefix error
messages with the name of the program.
* tools/abilint.cc (optionqs::wrong_option): New data member
(display_usage): Prefix error messages with the name of the
program.
(parse_command_line): Record the name of the unrecognized option.
(main): Tell the name of the unrecognized option. Prefix error
messages with the name of the program.
* tools/abipkgdiff.cc (options::{wrong_option, prog_name}): New
data members.
(package::erase_extraction_directory, display_usage, extract_rpm)
(extract_deb, extract_tar)
(erase_created_temporary_directories_parent, extract_package)
(compare, create_maps_of_package_content): Prefix error messages
with the name of the program.
(maybe_check_suppression_files): Adjust.
(parse_command_line): Record the name of the unrecognized option,
and the name of option which lacks an operand.
(main): Give the name of the unrecognized option. Prefix error
messages with the name of the program.
2016-02-12 Dodji Seketeli <dodji@redhat.com>
Prefix abidiff error message with the 'abidiff' program name
* include/abg-tools-utils.h (emit_prefix): Declare new function.
(check_file): Add a new parameter with a default value, so that
existing code keeps compiling.
* src/abg-tools-utils.cc (emit_prefix): Define new function.
(check_file): Use the emit_prefix function and give it the program
name passed as a new parameter.
* tools/abidiff.cc (display_usage, main): Use the new emit_prefix
to prefix error messages.
2016-02-11 Dodji Seketeli <dodji@redhat.com>
Bug 19606 - Need better error message for invalid options
* tools/abidiff.cc (options::wrong_option): New data member.
(parse_command_line): Record the name of the unknown option and of
the option which value is missing.
2016-02-11 Dodji Seketeli <dodji@redhat.com>
Add a comment about libabigail needing elfutils 0.159 at least.
* configure.ac: Add a comment saying that we require at least
elfutils 0.159.
2016-02-11 Dodji Seketeli <dodji@redhat.com>
Talk about mandatory properties in suppress_* directives
* doc/manuals/libabigail-concepts.rst: Talk about the mandatory
properties for suppress_type, suppress_function and
suppress_variable directives.
2016-02-11 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff check for the presence of suppression spec files
* tools/abipkgdiff.cc (maybe_check_suppression_files): Define new
static function.
(main): Use it.
2016-02-11 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff return correct exit code on usage error
* tools/abipkgdiff.cc (main): Return the correct error code on
usage error.
2016-02-11 Dodji Seketeli <dodji@redhat.com>
Bug 19604 - abidiff --suppressions doesn't complain about invalid file name
* tools/abidiff.cc (maybe_check_suppression_files): Define new
static function.
(main): Use it.
2016-02-10 Dodji Seketeli <dodji@redhat.com>
Use proper WIFEXITED and WEXITSTATUS macros to get exit code
* tests/test-diff-dwarf-abixml.cc (main): Use WIFEXITED and
WEXITSTATUS macros to get the return code of the abidiff program.
* tests/test-diff-filter.cc (test_task::perform): Likewise.
* tests/test-diff-pkg.cc (main): Likewise.
* tests/test-diff-suppr.cc (main): Likewise.
2016-02-10 Dodji Seketeli <dodji@redhat.com>
Bug 19596 - Incorrect exit status for incompatible ABI change
* include/abg-comparison.h (enum diff_category): Adjust the
comment for enumerator VIRTUAL_MEMBER_CHANGE_CATEGORY; changes of
this category are incompatible ABI changes.
(corpus_diff::diff_stats::num_func_with_virtual_offset_changes):
Declare new accessors.
* src/abg-comparison.cc
(corpus_diff::diff_stats::priv::num_func_with_virt_offset_changes):
New data member.
(corpus_diff::diff_stats::priv::priv): Initialize the new data
member.
(corpus_diff::diff_stats::num_func_with_virtual_offset_changes):
Define new accessors.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Use the
new accessor to set the number of functions with virtual offset
changes onto the stats data structure.
(corpus_diff::has_incompatible_changes): Take functions with
virtual offset changes into account.
* tests/test-abidiff-exit.cc: New test harness to test for exit
codes of abidiff.
* tests/Makefile.am: Build the new test harness runtestabidiff
from the test-abidiff-exit.cc source file.
* tests/data/test-abidiff-exit/test1-voffset-change-report0.txt:
New reference test output.
* tests/data/test-abidiff-exit/test1-voffset-change-v0.cc: New
test input source code.
* tests/data/test-abidiff-exit/test1-voffset-change-v0.o: New test input.
* tests/data/test-abidiff-exit/test1-voffset-change-v1.cc: New
test input source code.
* tests/data/test-abidiff-exit/test1-voffset-change-v1.o: New test input.
* tests/data/Makefile.am: tests/data/Makefile.am: Add the new test
inputs above to the source distribution.
2016-02-04 Dodji Seketeli <dodji@redhat.com>
Fix synthesizing of reference type
* src/abg-ir.cc (synthesize_type_from_translation_unit): Support
synthesizing reference types.
* tests/data/test-abicompat/libtest9-fn-changed-v0.so: Add new
test input.
* tests/data/test-abicompat/libtest9-fn-changed-v1.so: Likewise.
* tests/data/test-abicompat/test9-fn-changed-app: Likewise.
* tests/data/test-abicompat/test9-fn-changed-app.cc: : Likewise.
* tests/data/test-abicompat/test9-fn-changed-report-0.txt: Likewise.
* tests/data/test-abicompat/test9-fn-changed-v0.cc: Likewise.
* tests/data/test-abicompat/test9-fn-changed-v0.h: Likewise.
* tests/data/test-abicompat/test9-fn-changed-v1.cc: Likewise.
* tests/data/test-abicompat/test9-fn-changed-v1.h: Likewise.
* tests/data/Makefile.am: Add the new material to source
distribution.
* tests/test-abicompat.cc (in_out_specs): Add the new test inputs
to the test harness.
2016-02-03 Dodji Seketeli <dodji@redhat.com>
Fix synthesizing of pointer type
* include/abg-ir.h: Update copyright.
* src/abg-ir.cc (synthesize_type_from_translation_unit): Support
synthesizing pointer types.
* tests/data/test-abicompat/libtest8-fn-changed-libapp-v0.so: New
test input.
* tests/data/test-abicompat/libtest8-fn-changed-libapp-v1.so: Likewise.
* tests/data/test-abicompat/test8-fn-changed-app: Likewise.
* tests/data/test-abicompat/test8-fn-changed-app.c: Likewise.
* tests/data/test-abicompat/test8-fn-changed-libapp-v0.c: Likewise.
* tests/data/test-abicompat/test8-fn-changed-libapp-v0.h: Likewise.
* tests/data/test-abicompat/test8-fn-changed-libapp-v1.c: Likewise.
* tests/data/test-abicompat/test8-fn-changed-libapp-v1.h: Likewise.
* tests/data/test-abicompat/test8-fn-changed-report-0.txt: Likewise.
* tests/data/Makefile.am: Add the new test input files to source
distribution.
* tests/test-abicompat.cc (in_out_specs): Add the new test inputs
above to the test harness.
2016-01-26 Mark Wielaard <mjw@redhat.com>
Remove defined but not used functions pointed out by GCC6.
* src/abg-ir.cc (convert_node_to_decl(decl_base_sptr)): Remove
definition.
(get_node_name(decl_base_sptr)): Likewise.
2016-01-26 Mark Wielaard <mjw@redhat.com>
Make make more silent.
* Makefile.am (AM_MAKEFLAGS): Set --no-print-directory.
2016-01-26 Mark Wielaard <mjw@redhat.com>
Fix GCC6 -Wmisleading-indentation warnings.
* src/abg-dwarf-reader.cc (find_import_unit_point_before_die):
Properly indent code after if clause.
* src/abg-ini.cc (write_property_value): Properly indent return
statement after else clause.
2016-01-27 Dodji Seketeli <dodji@redhat.com>
Fix abicompat's handling of library types not used by the application
* tools/abicompat.cc (perform_compat_check_in_weak_mode): If the
application doesn't use a given type defined and exported by the
library, then skip it.
2016-01-27 Dodji Seketeli <dodji@redhat.com>
Do not crash when looking up a type from global scope
* src/abg-ir.cc (lookup_type_in_scope): Gently Handle empty access
path.
2016-01-25 Dodji Seketeli <dodji@redhat.com>
Comparing aliases of the same symbol must be done by pointer
* src/abg-ir.cc (elf_symbol::operator==): Fix thinko and
indentation. What was I thinking ...
(elf_symbol::add_alias)
(compute_aliases_for_elf_symbol): Do not compare aliases using the
equality operator, because it considers all aliases of a given
symbol as equal. Rather, use elf_symbol::is_main_symbol() to test
if an alias is the main symbol alias.
* src/abg-comp-filter.cc (function_name_changed_but_not_symbol):
Likewise.
* src/abg-corpus.cc
(corpus::priv::build_unreferenced_symbols_tables): Likewise.
* src/abg-writer.cc (write_elf_symbol_aliases): Likewise.
2016-01-21 Dodji Seketeli <dodji@redhat.com>
Bug 19204 - libabigail aborts on DWARF referencing non-existing DIE
* src/abg-dwarf-reader.cc (get_parent_die): If we couldn't find
the parent of a given DIE, return false, do not abort. Also,
assert that if we don't find the parent of a DIE in the main debug
info, we don't find it in the alternate debug info either (and
vice versa). This is because I'd like to abort on cases where we
look for a DIE in the wrong debug info; those cases are likely to
be hint that the DWARF reader is doing something wrong which ought
to be investigated and fixed.
(get_scope_for_die): If we couldn't get the parent of the DIE,
then return a nil scope.
* tests/data/test-types-stability/pr19204-libtcmalloc.so.4.2.6-xlc:
New test binary input.
* tests/data/Makefile.am: Add the new binary test input to the
source distribution.
* tests/test-types-stability.cc (elf_paths): Account for the new
binary input.
2016-01-20 Dodji Seketeli <dodji@redhat.com>
Pass parm of elf_symbol::add_alias by reference
* include/abg-ir.h (elf_symbol::add_alias): Pass parameter by
reference.
* src/abg-ir.cc (elf_symbol::add_alias): Likewise.
2016-01-20 Dodji Seketeli <dodji@redhat.com>
Bug 19141 - Libabigail doesn't support common ELF symbols
* include/abg-ir.h (elf_symbol::elf_symbol): Take a new flag to
say if the symbol is common.
(elf_symbol::{is_common_symbol, has_other_common_instances,
get_next_common_instance, add_common_instance}): New member functions.
* src/abg-ir.cc (elf_symbol::priv::{is_common_,
next_common_instance_): New data members.
(elf_symbol::priv::priv): Adjust.
(elf_symbol::{elf_symbol, create}): Take a new flag to say if the
symbol is common.
(textually_equals): Adjust to account for symbol common-ness.
(elf_symbol::{is_common_symbol, has_other_common_instances,
get_next_common_instance, add_common_instance}): Define new member
functions.
(elf_symbol::add_alias): Drive-by fix; compare symbols using
pointer value. Value comparison is not necessary.
* src/abg-dwarf-reader.cc (lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab, lookup_symbol_from_symtab)
(read_context::lookup_elf_symbol_from_index): Adjust the creation
of the symbol to account for common-ness.
(read_context::load_symbol_maps): Recognize instances of a given
common symbol and represent them as such. Do not mistake this
with symbol aliases.
* src/abg-reader.cc (build_elf_symbol): Adjust the creation of the
symbol to account for common-ness.
* src/abg-writer.cc (write_elf_symbol): Adjust symbol
serialization to account common-ness.
* tests/data/test-types-stability/pr19141-get5d.o: Add new test
binary input.
* tests/data/test-types-stability/pr19142-topo.o: Likewise.
* tests/data/Makefile.am: Add the new test inputs to source distribution.
* tests/test-types-stability.cc (elf_paths): The the new test
inputs into account.
2016-01-13 Dodji Seketeli <dodji@redhat.com>
Bug 19434 - invalid character in attribute value
* include/abg-tools-utils.h (string_is_ascii_identifier): Declare
new function.
* src/abg-tools-utils.cc (string_is_ascii_identifier): Define new function.
* src/abg-dwarf-reader.cc (build_function_type): Discard parameter
name if it's made of non-identifier ascii characters.
* tests/data/test-types-stability/pr19434-elf0: New test binary input file.
* tests/data/Makefile.am: Add the new test input to source distribution.
* tests/test-types-stability.cc: Test the new test input into account.
2016-01-18 Dodji Seketeli <dodji@redhat.com>
Sort the tests run in tests/ by running the slowest ones first
* tests/Makefile.am: Sort the tests by running the slowest ones
first.
2016-01-15 Dodji Seketeli <dodji@redhat.com>
Use worker threads pattern to speed up some tests
* include/Makefile.am: Add the new abg-workers.h to source
distribution.
* include/abg-workers.h: New file.
* src/Makefile.am: Add the new abg-worker.cc to source
distribution.
* src/abg-workers.cc: New file.
* tests/test-utils.cc: Update copyright. Make get_src_dir() and
get_build_dir() return a const char*, as opposed to returning a
string. Make that const char reside in thread local storage, so
that two concurrent threads can safely call these functions in
parallel, without any race.
* tests/test-utils.h: Make get_src_dir() and get_build_dir()
return a const char*, as opposed to returning a string.
* tests/test-abicompat.cc: Update copyright. Adjust for
get_src_dir() and get_build_dir() change.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-diff-dwarf-abixml.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-types-stability.cc: Likewise. Use the new task queue
type to run these tests in parallel.
* tests/test-diff-filter.cc: Likewise.
2016-01-18 Ondrej Oprala <ooprala@redhat.com>
Escape the value of the filepath attribute.
* src/abg-writer.cc (write_location): Sanitize the filepath with
xml::escape_xml_string().
(write_translation_unit): Likewise.
(write_corpus_to_native_xml): Likewise.
* tests/data/test-types-stability/pr19433-custom0: Add a new test file.
* tests/test-types-stability.cc: Add the test file to the test harness.
* tests/data/Makefile.am: Add the new test file to the list.
2016-01-09 Dodji Seketeli <dodji@redhat.com>
Make enum values take 64 bits on all platforms
* include/abg-ir.h: Include stdint.h for int64_t.
(enumerator::enumerator): Take an int64_t value for the value of
the enumerator.
(enumerator::{s,g}et_value): Take/return an int64_t value.
* src/abg-ir.cc (enum_type_decl::enumerator::priv): Store the
value in an int64_t.
(enumerator::priv::priv): Take a int64_t for the value.
(enum_type_decl::enumerator::enumerator): Likewise.
(enum_type_decl::enumerator::{s,g}et_value): Take/returnan int64_t
value.
* src/abg-dwarf-reader.cc (die_unsigned_constant_attribute): Take
an uint64_t value.
(die_signed_constant_attribute): Take an int64_t value.
(die_location, die_size_in_bits, die_access_specifier)
(die_virtuality, die_is_virtual, die_is_declared_inline)
(build_translation_unit_and_add_to_ir, build_type_decl)
(build_enum_type, build_pointer_type_def, build_array_type):
Adjust.
* src/abg-reader.cc (build_enum_type_decl): Adjust.
* src/abg-writer.cc (write_enum_type_decl): Do not cast the result
of enumerator::get_value() anymore, it's value is now a int64_t.
2016-01-08 Dodji Seketeli <dodji@redhat.com>
Include missing <algorithm> to abg-dwarf-reader.cc
* src/abg-dwarf-reader.cc: Add missing <algorithm> include file.
2016-01-08 Dodji Seketeli <dodji@redhat.com>
Bug 19138 - Failure to relate variables address from DWARF and ELF
* include/abg-dwarf-reader.h (elf_type::ELF_TYPE_RELOCATABLE): New
enumerator.
* src/abg-dwarf-reader.cc (find_section): Factorize this from ...
(find_text_section, find_bss_section): ... these.
(find_rodata_section, find_data_section, find_data1_section):
Define new static functions.
(elf_file_type): Move this static function definition up.
(read_context::{get_elf_file_type, address_is_in_section,
get_data_section_for_variable_address}): New member functions.
(read_context::maybe_adjust_fn_sym_address): Adjust comment.
Adjust to use the new
read_context::get_data_section_for_variable_address().
* tests/data/test-types-stability/pr19138-elf0: New test input
binary.
* tests/data/Makefile.am: Add the new test input binary to the
test suite.
* tests/test-types-stability.cc (elf_paths): Take it into account.
2016-01-08 Dodji Seketeli <dodji@redhat.com>
Bump version revision to 1.0.rc3
* configure.ac: Change version_revision to rc3
2016-01-08 Dodji Seketeli <dodji@redhat.com>
Add a release announcement text pattern
* release-text-template.txt: New file.
2016-01-08 Dodji Seketeli <dodji@redhat.com>
Upate build instructions on the website
* doc/website/mainpage.txt: Add instruction about how to build
tarballs.
2016-01-07 Dodji Seketeli <dodji@redhat.com>
Update website link for 1.0.rc2
* doc/website/mainpage.txt: Update tarball link for 1.0.rc2
2016-01-07 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog before 1.0.rc2
* ChangeLog: Update with make update-changelog
2016-01-07 Dodji Seketeli <dodji@redhat.com>
Update NEWS for 1.0.rc2
* NEWS: Update.
2016-01-07 Dodji Seketeli <dodji@redhat.com>
Fix tests/data/Makefile.am glitch
* tests/data/Makefile.am: Fix a faulty file path.
2016-01-07 Dodji Seketeli <dodji@redhat.com>
Lexicographically sort added/removed base classes in change report
* src/abg-comparison.cc (sort_string_base_diff_sptr_map): Define
new static function.
(struct base_spec_comp): Define new type.
(class_diff::priv::sorted_{deleted,inserted}_bases_): New data
members.
(class_diff::ensure_lookup_tables_populated): Sort the deleted and
inserted base classes.
(class_diff::report): Use the sorted set of deleted/inserted base
classes in the report.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt: Adjust.
2016-01-06 Dodji Seketeli <dodji@redhat.com>
Fix regression on the support for alternate debug info files
* src/abg-dwarf-reader.cc
(imported_unit_point::imported_unit_from_alt_di): New data member.
(imported_unit_point::imported_unit_point): Adjust.
(read_context::alt_tu_die_imported_unit_points_map_): New data
member.
(read_context::alt_tu_die_imported_unit_points_map): New accessor.
(die_die_attribute): Remove the overload which doesn't say if the
resulting DIE comes from alternate debug info.
(build_die_parent_relations_under): Take a new flag which says if
we are building the relations about DIEs in the alternate debug
info section or not. Use that flag to know if the imported unit
trace we are building is for an alternate debug info file or not.
(build_die_parent_maps): Build two different imported unit point
trace vectors: one for the main debug info file, and another one
for the alternate debug info file.
(find_import_unit_point_between_dies): Take a flag that says if
the beginning of the search is a DIE in the alternate debug info
file or not. Use it to know if we should use the import point
trace vectors from alternate debug info or from the main debug
info file. When the import point trace vector is empty, return
immediatly.
(get_parent_die): If the parent DIE is a DW_TAG_partial_unit which
hasn't been imported into this TU, then assume the logical parent
is the DIE for the current translation unit.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64--tbb-4.3-3.20141204.fc23.x86_64-report-0.txt:
Reference test output.
* tests/data/test-diff-pkg/tbb-4.1-9.20130314.fc22.x86_64.rpm: New
input test rpm.
* tests/data/test-diff-pkg/tbb-4.3-3.20141204.fc23.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/tbb-debuginfo-4.1-9.20130314.fc22.x86_64.rpm:
Likewise.
* tests/data/test-diff-pkg/tbb-debuginfo-4.3-3.20141204.fc23.x86_64.rpm:
Likewise.
* tests/data/Makefile.am: Add the new test materials to the source
distribution.
* tests/test-diff-pkg.cc (int_out_specs): Add the new rpms to the
list of rpms to test against.
2016-01-06 Dodji Seketeli <dodji@redhat.com>
Bump revision number to 1.0.rc2
* configure.ac: Bump revision number to 1.0.rc2
2016-01-05 Dodji Seketeli <dodji@redhat.com>
Update link to the 1.0.rc1 tarball
* doc/website/mainpage.txt: Update the "Getting source code"
section.
2016-01-05 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog before 1.0.rc1
* ChangeLog: Update automatically with make update-changelog
2016-01-05 Dodji Seketeli <dodji@redhat.com>
Fix abidw -v
* tools/abidw.cc (parse_command_line): Simplify logic.
(main): Fix logic.
2016-01-05 Dodji Seketeli <dodji@redhat.com>
Add a NEWS file
* NEWS: New file.
* Makefile.am: Add NEWS file to source distribution.
2016-01-04 Dodji Seketeli <dodji@redhat.com>
Bug 19355 - Libabigail slow on r300_dri.so
* src/abg-dwarf-reader.cc (struct imported_unit_point): Define new
type.
(operator<(const imported_unit_point&, const
imported_unit_point&)): Define less-than operator for new
imported_unit_point& type.
(imported_unit_points_type, tu_die_imported_unit_points_map_type):
New typedefs.
(find_lower_bound_in_imported_unit_points): Define new static function.
(read_context::tu_die_imported_unit_points_map_): New data member.
(read_context::tu_die_imported_unit_points_map): New getter.
(die_die_attribute): Define new overload.
(build_die_parent_relations_under): Take imported_unit_points_type
output parameter and populate it along the way. Remove the
overload that takes a read_context as a parameter.
(build_primary_die_parent_relations_under)
(build_alternate_die_parent_relations_under): Remove.
(build_die_parent_maps): Pass an instance of
imported_unit_points_type to build_die_parent_relations_under.
(find_import_unit_point_between_dies): Rename one overload of
find_last_import_unit_point_before_die into this. Adjust to make
it find the import point between two offsets.
(find_import_unit_point_before_die): Rename the other overload of
find_last_import_unit_point_before_die into this. Adjust to use
find_import_unit_point_between_dies.
(get_parent_die): Adjust to use find_import_unit_point_before_die.
2016-01-04 Dodji Seketeli <dodji@redhat.com>
Support two different variables having the same underlying symbol
* src/abg-ir.cc (var_decl::get_id()): Include the name of the
variable in the ID.
2016-01-04 Dodji Seketeli <dodji@redhat.com>
Avoid adding the same base class twice
* src/abg-dwarf-reader.cc: Avoid adding the same base class twice
* src/abg-reader.cc: Avoid adding the same base class twice
2016-01-04 Dodji Seketeli <dodji@redhat.com>
Speed up class_decl::find_base_class
* src/abg-ir.cc (class_decl::priv::bases_map_): New data member.
(class_decl::add_base_specifier): Add the new base specifier to
the new class_decl::priv::bases_map_ data member.
(class_decl::find_base_class): Use the new
class_decl::priv::bases_map_ data member to speed up finding the
base class.
2016-01-04 Dodji Seketeli <dodji@redhat.com>
Make class_decl::base_spec class follow the pimpl pattern
* include/abg-ir.h (class_decl::base_spec::priv): Declare new
private data type.
(class_decl::base_spec::priv_): Declare new pimpl data member.
(class_decl::base_spec::{base_class_, offset_in_bits_,
is_virtual_}): Remove.
(class_decl::base_spec::{get_base_class, get_is_virtual,
get_offset_in_bits}): Make these member functions out of line.
* src/abg-ir.cc (struct class_decl::base_spec::priv): New type.
(class_decl::base_spec::{get_base_class, get_is_virtual,
get_offset_in_bits}): Define these functions here.
(class_decl::base_spec::base_spec): Adjust because now there is
only one pimpl data member to initialize.
2015-11-16 Ondrej Oprala <ooprala@redhat.com>
Add the option of printing the file, line and column information about a type being reported.
* bash-completion/abicompat: Complete the new "--no-show-locs" option.
* bash-completion/abidiff: Likewise.
* bash-completion/abidw: Likewise.
* bash-completion/abipkgdiff: Likewise.
* doc/manuals/abicompat.rst: Mention the new "--no-show-locs" option.
* doc/manuals/abidiff.rst: Likewise.
* doc/manuals/abidw.rst: Likewise.
* doc/manuals/abipkgdiff.rst: Likewise.
* include/abg-comparison.h (show_locs): Add declarations.
* src/abg-comparison.cc: (diff_context::priv): Add a new switch
called "show_locs_" and set its default value to false.
(report_loc_info): New function. Outputting the extra information
is conditionalized based on the associated diff contexts settings.
(show_locs): define a getter/setter for
diff_context::priv::show_locs_.
({distinct,pointer,reference,qualified_type,enum,class,scope,fn_parm,
typedef,corpus}_diff::report): Call report_loc_info when
appropriate.
(maybe_report_diff_for_member): Likewise.
(represent): Accept a const reference to a diff_context_sptr as a first
argument and call report_loc_info on its second argument.
* src/abg-dwarf-reader.cc:
* tests/data/Makefile.am: Add the new test reference files.
* tests/data/test-abicompat/test0-fn-changed-report-2.txt: New test
reference output.
* tests/data/test-abicompat/test5-fn-changed-report-1.txt: Likewise.
* tests/data/test-abicompat/test6-var-changed-report-1.txt: Likewise.
* tests/data/test-abicompat/test7-fn-changed-report-2.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report1.txt:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-1.txt:
Likewise.
* tests/data/test-diff-pkg/dirpkg-3-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0-1.txt: Likewise.
* tests/test-abidiff.cc: Explicitly create a diff context and turn off
location emitting.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-abicompat.cc: Add --no-show-locs to all existing test
arguments. Run a few of the existing tests again, but without this
option.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-pkg.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tools/abicompat.cc: Handle the new "--no-show-locs" option.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abipkgdiff.cc: Likewise.
2015-11-16 Ondrej Oprala <ooprala@redhat.com>
Fix a function doc
* src/abg-ir.cc: (location_manager::expand_location): Fix a factual
error in the function documentation.
2015-12-11 Dodji Seketeli <dodji@redhat.com>
[PERF] Speedup comparing declaration-only class_decls
* src/abg-ir.cc (equals): In the overload for class_decl, avoid
calling class_decl::get_is_declaration_only() several times.
Avoid copying the qualified name of the class_decl. Also, use the
== operator to compare strings, rather than the != one.
2015-12-11 Dodji Seketeli <dodji@redhat.com>
[PERF] Access naked pointers for canonical types and function types
* include/abg-ir.h (type_base::get_naked_canonical_type): Declare
new accessor.
(function_decl::get_naked_canonical_type): Likewise.
(function_decl::set_type): Pass a reference to the shared_ptr.
* src/abg-ir.cc (type_base::priv::naked_canonical_type): New data
member.
(type_base::priv::priv): Initialize it.
(canonicalize): Set the naked canonicalize type when we set its
shared pointer.
(type_base::get_naked_canonical_type): Define new accessor.
({pointer_type_def,reference_type_def,function_type,class_decl}::operator==):
Use naked canonical pointers rather than the slower shared_ptr to
canonical pointers.
(function_decl::priv::naked_type_): New data member.
(function_decl::priv::priv): Initialize it.
(function_decl::get_naked_type): Define new accessor.
(function_decl::set_type): Pass a reference to the shared_ptr .
(equals): In the overload for function_decl, use the faster naked
pointers to the type of the function.
2015-12-11 Dodji Seketeli <dodji@redhat.com>
[PERF] Turn some pimpl pointers into naked pointers
* include/abg-ir.h ({decl_base, type_base, function_decl}::priv_)
Make this a naked pointer to priv, rather than a shared_ptr<priv>.
* src/abg-ir.cc (decl_base::~decl_base): Destroy the private data
pointer, aka pimpl pointer.
(type_base::~type_base): Likewise.
(function_decl::~function_decl): Likewise.
(class_decl::~class_decl): Likewise.
2015-12-11 Dodji Seketeli <dodji@redhat.com>
[PERF] Pass a bunch of perf-sensitive smart pointers by reference
* include/abg-fwd.h (lookup_type_in_corpus, lookup_type_in_scope)
(lookup_var_decl_in_scope): Pass the decls smart pointers by
reference.
* src/abg-ir.cc (lookup_type_in_corpus, lookup_type_in_scope)
(lookup_var_decl_in_scope): Pass the decls smart pointers by
reference, for performance reasons.
2015-12-10 Dodji Seketeli <dodji@redhat.com>
Bug 19126 - abidw segv on a dwz compressed version of r300_dri.so
* include/abg-ir.h (class location_manager): Forward declare it
before class location.
(location::loc_manager_): New data member.
(location::location): Take the location manager in one overload
and initialize the new loc_managers_ in all the overloads.
(location::get_location_manager): New getter.
(location::expand): New member function.
(location::*): Add API doc to all entry points.
(location_manager::expand_location): Take a const location.
(type_or_decl_base::set_corpus): Remove.
(type_or_decl_base::{get,set}_translation): New accessors.
(decl_base::{decl_base,get_location}): Take or return a reference
on location.
(scope_decl::scope_decl): Likewise.
(type_decl::type_decl): Likewise.
(namespace_decl::namespace_decl): Likewise.
(qualified_type_def::qualified_type_def): Likewise.
(pointer_type_def::pointer_type_def): Likewise.
(reference_type_def::reference_type_def): Likewise.
(array_type_def::subrange_type::{subrange_type,
get_location}): Likewise.
(enum_type_decl::enum_type_decl): Likewise.
(typedef_decl::typedef_decl): Likewise.
(var_decl::var_decl): Likewise.
(function_decl::function_decl): Likewise.
(function_decl::parameter::parameter): Likewise.
(template_decl::template_decl): Likewise.
(type_tparameter::type_tparameter): Likewise.
(non_type_tparameter::non_type_tparameter): Likewise.
(function_tdecl::function_tdecl): Likewise.
(class_tdecl::class_tdecl): Likewise.
(class_decl::class_decl): Likewise.
(class_decl::method_decl::method_decl): Likewise.
* src/abg-ir.cc (location::expand_location): Define new member
function.
(type_or_decl_base::priv::corpus_): Remove.
(type_or_decl_base::priv::translation_unit_): New data member.
(type_or_decl_base::priv::priv): Adjust.
(type_or_decl_base::set_corpus): Remove.
(type_or_decl_base::get_corpus): Adjust.
(type_or_decl_base::{get,set}_translation_unit): New member
functions.
(decl_base::priv::priv): Take a reference to location.
(decl_base::decl_base): Likewise.
(decl_base::get_location): Return a reference to location.
(location_manager::create_new_location): Adjust.
(location_manager::expand_location): Take a reference to location.
(translation_unit::get_global_scope()): Adjust.
(translation_unit::bind_function_type_life_time): Likewise.
(scope_decl::{add,insert}_member_decl): Adjust.
(get_translation_unit): Likewise.
(type_decl::type_decl): Take a reference to location.
(namespace_decl::namespace_decl): Likewise.
(qualified_type_def::qualified_type_def): Likewise.
(pointer_type_def::pointer_type_def): Likewise.
(reference_type_def::reference_type_def): Likewise.
(array_type_def::subrange_type::priv::priv): Likewise.
(array_type_def::subrange_type::{subrange_type,
get_location}): Likewise.
(enum_type_decl::enum_type_decl): Likewise.
(typedef_decl::typedef_decl): Likewise.
(var_decl::var_decl): Likewise.
(function_decl::function_decl): Likewise.
(function_decl::parameter::parameter): Likewise.
(template_decl::template_decl): Likewise.
(type_tparameter::type_tparameter): Likewise.
(non_type_tparameter::non_type_tparameter): Likewise.
(function_tdecl::function_tdecl): Likewise.
(class_tdecl::class_tdecl): Likewise.
(class_decl::class_decl): Likewise.
(class_decl::method_decl::method_decl): Likewise.
* src/abg-writer.cc (write_location): Take a reference to
location and adjust.
(write_array_type_def, write_function_decl, dump_decl_location):
Adjust.
2015-12-08 Dodji Seketeli <dodji@redhat.com>
Fix some white space nits
* src/abg-comparison.cc (class_diff::report): Remove a useless
horizontal white space.
* src/abg-ir.cc (operator==): Add a vertical space.
2015-12-08 Dodji Seketeli <dodji@redhat.com>
Filter out harmless diagnostics glitches due to some ODR violation
* src/abg-comp-filter.cc
(class_diff_has_harmless_odr_violation_change): New static
function.
(harmless_filter::visit): Call it.
2015-12-08 Dodji Seketeli <dodji@redhat.com>
Fix internal name for pointers, typedefs and arrays
* include/abg-ir.h (pointer_type_def::priv_): New data structure.
The type is now pimpled.
(typedef_decl::priv_): Likewise.
* src/abg-ir.cc (struct pointer_type_def::priv): New struct.
(pointer_type_def::pointer_type_def): Adjust.
(pointer_type_def::get_pointed_to_type): Likewise.
(pointer_type_def::get_qualified_name): Store temporary/internal
names into different caches.
(array_type_def::priv::{temp_internal_qualified_name_,
internal_qualified_name_}): New data members.
(get_type_representation): In the overload for array_type_def,
take requests for internal names into account.
(array_type_def::get_qualified_name): Take requests for internal
names into account. Store temporary/internal names into different
caches.
(typedef_decl::priv): New struct.
(typedef_decl::typedef_decl): Adjust.
(typedef_decl::get_underlying_type): Likewise.
2015-12-08 Dodji Seketeli <dodji@redhat.com>
Avoid try/catch code paths when that is possible
* src/abg-ir.cc (is_type, equals): Do not use try/catch based
dynamic_cast.
2015-12-08 Dodji Seketeli <dodji@redhat.com>
Fix comparison in qualified_type_diff::has_changes
* src/abg-comparison.cc (qualified_type_diff::has_changes): Make
this stupid and simple, now that we have (fast) canonical type
based comparison.
* include/abg-ir.h (qualified_type_diff::operator==): Add an
overload for qualified_type_diff here.
(operator==): Likewise.
* src/abg-ir.cc (qualified_type_diff::operator==): Define it.
(operator==): Likewise.
2015-12-06 Dodji Seketeli <dodji@redhat.com>
Bug 19336 - Better handle redundantly qualified reference types
* src/abg-dwarf-reader.cc (maybe_strip_qualification): Do not nuke
the qualified type. Rather, just turn the redundant const
qualifier into a no-op one.
* src/abg-comparison.cc (compute_diff_for_types): Look through
no-op qualified types.
* include/abg-ir.h
(decl_base::{peek,set}_temporary_qualified_name): Declare new
accessors.
* src/abg-ir.cc (decl_base::priv::temporary_qualified_name_): New
data member.
(decl_base::{peek,set}_temporary_qualified_name): Define new
accessors.
(qualified_type_def::priv::{temporary_internal_name_,
internal_name}): New data members.
(qualified_type_def::build_name): For a no-op qualified type, the
internal name (which contains the 'none' qualifier) is different
from the non-internal name.
(qualified_type_def::get_qualified_name): Handle temporary names
and non-temporary names in two different caches. Also handle
internal and non-internal names in two different caches. This
makes four different caches.
(qualified_name_setter::do_update): Do not touch the non-internal,
non-temporary qualified name cache if the qualified parent name is
empty.
* tools/abidw.cc (main): change --check-alternate-debug-info to
make it *not* display the name/path to the alternate debug info,
when it's found. Rather, only
--check-alternate-debug-info-base-name keeps displaying the base
name of the alternate debug info.
* tests/data/test-alt-dwarf-file/test1-libgromacs-debug-dir/*: New
test material.
* tests/data/Makefile.am: Add the new test material to the build
system.
* tests/test-alt-dwarf-file.cc (in_out_specs): Take the new test
input into account.
* tests/data/test-read-dwarf/test1.abi: Adjust.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
2015-12-06 Dodji Seketeli <dodji@redhat.com>
Do not forget to peel qualified type off when peeling types
* include/abg-fwd.h (peel_qualified_type): Declare new function
...
* src/abg-ir.cc (peel_qualified_type): ... and define it.
(peel_typedef_pointer_or_reference_type): Peel qualified types
here too.
2015-12-06 Dodji Seketeli <dodji@redhat.com>
Find more spots where to discriminate internal and non-internal names
* src/abg-ir.cc (get_type_name, get_method_type_name)
({typedef_decl,var_decl,function_decl,class_decl}::get_pretty_representation):
Propagate the internal-ness to the call to get_qualified_name().
2015-12-06 Dodji Seketeli <dodji@redhat.com>
Constify is_qualified_type()
* include/abg-fwd.h (is_qualified_type): Make this take a const
parameter.
* src/abg-ir.cc (is_qualified_type): Likewise.
2015-11-28 Dodji Seketeli <dodji@redhat.com>
Add missing new line to abidiff help message
* tools/abidiff.cc (display_usage): Add missing new line.
2015-11-26 Dodji Seketeli <dodji@seketeli.org>
Do not abort when there is no binary to compare in a package
* tests/data/test-diff-pkg/empty-pkg-libvirt-0.9.11.3-1.el7.ppc64.rpm:
New input test package.
* tests/data/test-diff-pkg/empty-pkg-libvirt-1.2.17-13.el7_2.2.ppc64.rpm:
Likewise.
* tests/data/test-diff-pkg/empty-pkg-report-0.txt: New test
reference output.
* data/Makefile.am: Add the new test material above to the build system.
* tests/test-diff-pkg.cc (int_out_specs): Add the new test inputs
to the set of tests.
* tools/abipkgdiff.cc (compare): Do not abort if there is no
binary to compare.
2015-11-14 Ondrej Oprala <ooprala@redhat.com>
Abidiff: Remove doubled line in help.
* tools/abidiff.cc (display_usage): Remove a doubled help message.
2015-11-14 Ondrej Oprala <ooprala@redhat.com>
Add bash-completion scripts for the libabigail tools
* Makefile.am: include bash-completion/Makefile.am
* bash-completion/Makefile.am: New makefile for the bash-completion
directory.
* bash-completion/abicompat: New completion script.
* bash-completion/abidiff: Likewise.
* bash-completion/abidw: Likewise.
* bash-completion/abilint: Likewise.
* bash-completion/abinilint: Likewise.
* bash-completion/abipkgdiff: Likewise.
* bash-completion/abisym: Likewise.
* configure.ac: Check for the bash-completion package. Handle
the new --enable-bash-completion[=WHEN] configure option.
* manuals/libabigail-tools.rst: Mention the scripts.
2015-11-17 Dodji Seketeli <dodji@redhat.com>
Read enum values in the size_t and write them in ssize_t
* include/abg-ir.h (enum_type_def::enumerator::get_value): Return
a size_t.
* src/abg-ir.cc (enum_type_decl::enumerator::get_value): Likewise.
* src/abg-dwarf-reader.cc (die_signed_constant_attribute): #if-out
this static function that is not used anymore.
(build_enum_type): Read the value of the enumerator using a size_t
value.
* src/abg-reader.cc (build_enum_type_decl): Read the enum value
using a long long int.
* src/abg-writer.cc (write_enum_type_decl): Write using a ssize_t.
2015-11-17 Dodji Seketeli <dodji@redhat.com>
Bump version to release candidate 1.0.rc1
* configure.ac: Bump version to release candidate 1.0.rc1
2015-11-17 Dodji Seketeli <dodji@redhat.com>
Do not use designated initializers in abipkgdiff.cc
* tools/abipkgdiff.cc (prepare_packages): Do not use designated
initializers syntax.
2015-11-16 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog for 1.0.rc0
* ChangeLog: Udpate using make update-changelog
2015-11-16 Dodji Seketeli <dodji@redhat.com>
Fix doxygen configuration file paths in doc/Makefile.am
* doc/Makefile.am: There was an extra "/doc" in the path.
2015-11-16 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog file in preparation of 1.0.rc0 release
* ChangeLog: Update using make update-changelog.
2015-11-16 Dodji Seketeli <dodji@redhat.com>
Add --version option to several libabigail tools
* configure.ac: Set the version revision to "rc0".
* doc/manuals/abicompat.rst: Adjust manual for new --version
option.
* doc/manuals/abidiff.rst: Likewise.
* doc/manuals/abidw.rst: Likewise.
* doc/manuals/abilint.rst: Likewise.
* doc/manuals/abipkgdiff.rst: Likewise.
* include/abg-config.h (config::{m_format_minor, m_format_major}):
Make these be strings.
(config::{get,set}_format_minor_version_number): Make these return
strings.
(config::{get,set}_format_major_version_number): Make these return
or take strings.
(abigail_get_library_version): Make this take strings.
* src/abg-config.cc (config::config): Adjust.
(config::{get,set}_format_major_version_number): Make these return
or take strings.
(config::{get,set}_format_minor_version_number): Make these return
strings.
(abigail_get_library_version): Make this take strings.
* include/abg-version.h.in: Make the version variables be strings.
* src/abg-writer.cc (write_translation_unit): The version numbers
are now strings so adjust.
* tools/{abicompat,abidiff,abidw,abilint,abipkgdiff,abisym}.cc
(options::display_version): New data member.
(options::options): Initialize it.
(display_usage): Add documentation for new --version option.
(parse_command_line): Parse new --version option.
(main): Support --version.
2015-11-12 Dodji Seketeli <dodji@redhat.com>
Correctly handle fn DIE with abstract_origin in alt debug info
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Consider that
the function decl is for a DIE in the alternate debug info file only if
the DIE itself comes from the alternate debug info file, not if
the specification or the origin of the function comes from the
alternate debug info file.
* tests/data/test-diff-pkg/qemu-img-rhev-2.3.0-20.el7.ppc64.rpm:
New test input rpm.
* tests/data/test-diff-pkg/qemu-img-rhev-2.3.0-7.el7.ppc64.rpm: Likewise.
* tests/data/test-diff-pkg/qemu-kvm-rhev-debuginfo-2.3.0-20.el7.ppc64.rpm: Likewise.
* tests/data/test-diff-pkg/qemu-kvm-rhev-debuginfo-2.3.0-7.el7.ppc64.rpm: Likewise.
* tests/data/test-diff-pkg/qemu-img-rhev-2.3.0-7.el7.ppc64--qemu-img-rhev-2.3.0-20.el7.ppc64-report-0.txt:
New test reference output.
* tests/data/Makefile.am: Add the new test material to the source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Use the new test rpm
inputs.
2015-11-09 Ondrej Oprala <ooprala@redhat.com>
Bug 19081 - abipkgdiff parallelization
* doc/manuals/abipkgdiff.rst: Mention the new --no-parallel option.
* tools/Makefile.am: Add -pthread to abipkgdiffs link options.
* tools/abipkgdiff.cc (elf_file_paths_tls_key): New key for the
thread-local vector of ELF filepaths.
(reports_map): A map of the path of the first ELF of a compared pair
and a corpus representing the difference.
(env_map): A map of the corpus difference and a corresponding
environment needed to be kept alive until the diff is reported.
({arg,map}_lock): mutexes to control access to the comparison argument
list and the {reports,env}_map respectively.
(options): Add a new member "parallel" and set it to true in the ctor.
(elf_file): Add a new "size" member and set it in the ctor.
(package descriptor): Arguments passed to extract_package_set.
(compare_args): Arguments passed to the ELF comparison function.
(display_usage): Mention the new "--no-parallel" option.
(pthread_routine_extract_package): A wrapper function around
extract_package to be used in a multi-threaded environment.
({first_second}_package_tree_walker_callback_fn): Add the new ELF file
paths to a thread-specific vector.
(compare): In an overload of compare, verbose output is updated to
always mention the ELF files being compared for each reported stage.
Reporting is no longer done in this function, the resulting difference
is instead passed back to the calling function for reporting in the
main thread, along with a corresponding environment.
(pthread_routine_compare): Accept a pointer to a vector of comparison
arguments. This function is to be called NTHREAD times and share the
vector passed to it with its other invocations. Create the environment
for compare() and store its output in a map if there is a difference.
(create_maps_of_package_content): Allocate memory for a thread local
vector of ELF paths and dispose of it before returning.
(pthread_routine_extract_pkg_and_map_its_content): Renamed from
extract_package_and_map_its_content. Extract the debuginfo as well as
the regular package in this function. Spawn a separate thread for the
extraction of the debug package.
(pthread_join): A function handling thread joining throughout package
extractions.
(prepare_packages): Spawn a thread to extract each set of packages.
(elf_size_is_greater): New comparison function used to order ELF pairs
by size.
(compare): In the overload of compare, pass through the ELF path
vectors and identify pairs to be diffed. Put them in a vector and sort
it by the summed ELF pair size. Spawn comparison threads and safely
check for results in the proper order of the ELF pairs. Report any
differences ASAP and collect the threads after all the reporting is
done, checking their return status.
(parse_command_line): Check for the "--no-parallel" option.
2015-11-10 Dodji Seketeli <dodji@redhat.com>
Fix typo in test-diff-dwarf-abixml.cc
* tests/test-diff-dwarf-abixml.cc (main): Fix typo.
2015-10-14 Ondrej Oprala <ooprala@redhat.com>
Document abipkgdiff's option --no-abignore
* doc/manuals/abipkgdiff.rst: Mention the new option.
* tools/abipkgdiff.cc: Likewise.
2015-11-09 Dodji Seketeli <dodji@redhat.com>
Avoid canonicalizing function types too early
* src/abg-dwarf-reader.cc (die_function_type_map_type): New
typedef.
* ():
(read_context::die_wip_function_types_map_): New data member.
(read_context::{die_wip_function_types_map,
is_wip_function_type_die_offset}): New methods.
(build_function_type): Mark the function being built as "work in
progress".
(maybe_canonicalize_type): Do not early-canonicalize WIP function
types.
* src/abg-reader.cc (build_function_type): Mark the function being
built as "work in progress".
* tests/test-diff-dwarf-abixml.cc: New test harness.
* tests/Makefile.am: Add new test harness runtestdiffdwarfabixml
to the build system.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1:
New test binary input.
* tests/data/test-diff-dwarf-abixml/test0-pr19026-libvtkIOSQL-6.1.so.1.abi:
New test input.
* tests/data/Makefile.am: Add new test inputs to source
distribution.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
2015-11-09 Dodji Seketeli <dodji@redhat.com>
Propagate environment property to base specifiers
* src/abg-comparison.cc (compute_diff): In the overload for
class_decl::base_spec_sptr, assert that the environment of the
base classes are equal and that the environment the base class is
the same as the environment of the base specifier.
* src/abg-ir.cc (add_base_specifier): Propagate the environment of
the class to its base specifiers.
* tests/data/test-types-stability/pr19026-libvtkIOSQL-6.1.so.1:
New test binary input.
* tests/data/Makefile.am: Add the new test input to the build
system.
* tests/test-types-stability.cc (elf_paths): Add new binary to the
test harness.
2015-11-09 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-comparison.cc (diff_context::mark_diff_as_visited): Add
missing space.
(corpus_diff::priv::ensure_lookup_tables_populated): Likewise.
* src/abg-dwarf-reader.cc (lookup_symbol_from_elf): Likewise.
(get_soname_of_elf_file, get_type_of_elf_file): Likewise.
* src/abg-ir.cc (var_decl::get_pretty_representation): Likewise.
2015-11-07 Dodji Seketeli <dodji@redhat.com>
Support DW_AT_count DWARF attribute
* src/abg-dwarf-reader.cc (get_default_array_lower_bound): Define
new static function.
(build_array_type): Support the DW_AT_count attribute.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang.so:
New test binary input.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang2.so: Likewise.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-clang-report-0.txt:
New test reference output.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc.so:
New test binary input.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc2.so:
New test binary input.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long-gcc-report-0.txt:
New test reference output.
* tests/data/test-diff-dwarf/test35-pr19173-libfoo-long.c: Source
code for the binaries above.
* tests/data/Makefile.am: Add the new test material to the build
system.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test inputs
to the harness.
2015-11-07 Dodji Seketeli <dodji@redhat.com>
Bug 19173 - Abidiff doesn't detect symbol size change in library
* include/abg-ir.h (elf_symbol::{elf_symbol, create}): Take a size
parameter.
(elf_symbol::{get,set}_size): New accessors.
* src/abg-ir.cc (elf_symbol::priv::size_): New data member.
(elf_symbol::priv::priv): Initialize it.
(elf_symbol::{elf_symbol, create}) Take a size parameter.
(textually_equals): Compare the size of variable symbols.
(elf_symbol::{get, set}_size): New accessors.
* src/abg-comparison.cc (maybe_report_diff_for_symbol): New static
function.
({function_decl_diff,var_diff}::report): Use it.
* src/abg-dwarf-reader.cc (lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab, lookup_symbol_from_symtab)
(read_context::lookup_elf_symbol_from_index): Set the size of the
elf symbols' internal representation.
* src/abg-reader.cc (build_elf_symbol): Read the size attribute if
present.
* src/abg-writer.cc (write_elf_symbol): Write the size attribute
for variable symbols, if it's not zero.
* tests/data/test-diff-dwarf/test34-pr19173-libfoo.so: New test
input binary.
* tests/data/test-diff-dwarf/test34-pr19173-libfoo2.so: Likewise.
* tests/data/test-diff-dwarf/test34-pr19173-libfoo-report-0.txt:
New reference test output.
* tests/data/Makefile.am: Add the new test input binaries to the
build system.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test input
above to the test harness.
* tests/data/test-diff-dwarf/test9-report.txt: Adjust.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Likewise.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2015-11-07 Dodji Seketeli <dodji@redhat.com>
Add some needed vertical space
* src/abg-dwarf-reader.cc (build_array_type): Add a new line after
this function.
2015-11-07 Dodji Seketeli <dodji@redhat.com>
Pass a bunch of parameters by reference as they ought to be
* include/abg-ir.h (operator==): In the overload for
elf_symbol_sptr, pass the parameters by reference.
* src/abg-ir.cc (operator==): Do the same at definition site.
* src/abg-comparison.cc (maybe_report_diff_for_member): Pass
parameters by reference.
2015-11-05 Dodji Seketeli <dodji@redhat.com>
Bug 19139 - DWARF reader doesn't handle garbage in function names
* include/abg-tools-utils.h (string_is_ascii): Declare new
function ...
* src/abg-tools-utils.cc (string_is_ascii): ... and define it.
* src/abg-writer.cc (write_function_type): Escape forbidden XML
characters in function type names.
* src/abg-dwarf-reader.cc (build_function_type): If a parameter
name is not ascii, drop it on the floor.
* tests/data/test-types-stability/pr19139-DomainNeighborMapInst.o:
New test input binary.
* tests/data/test-types-stability/pr19202-libmpi_gpfs.so.5.0:
Likewise.
* tests/data/Makefile.am: Add the new binaries above to the build
system.
* tests/test-types-stability.cc: New test harness.
* tests/Makefile.am: Add the new test harness to the build system.
2015-11-05 Dodji Seketeli <dodji@redhat.com>
Introduce the name abixml in some comments
* src/abg-reader.cc: Mention abixml in the comment at the top of
the file.
* src/abg-writer.cc: Likewise.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Bug 19026 - Types with same name and different size considered equivalent
* src/abg-ir.cc (type_base::get_canonical_type_for): Really
compare the size of the type to be canonicalized against the size
of the *current* potential canonical type of the same name.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Add a script to update the reference output of runtestreaddwarf
* tests/update-test-read-dwarf-output.py: New helper python program.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Style fixes in the abixml writer.
* src/abg-writer.cc (write_var_decl): Use the var_decl_sptr
typedef.
(write_class_decl): Indent.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Fix typo in test-read-dwarf.cc
* tests/test-read-dwarf.cc (for test test21-pr19092.so.abi): Fix
typo in the output path of that test.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Adjust regression tests reference output for the current patch set
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so:
New test input binary.
* tests/data/test-read-dwarf/test22-pr19097-libstdc++.so.6.0.17.so.abi:
New test reference output.
* tests/data/Makefile.am: Add the new test files above to the
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the two new test
files above to the set of test input files.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Adjust.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Adjust.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Adjust.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Adjust.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Adjust.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Use abidw --abidiff in test-read-dwarf.cc
* tests/test-read-dwarf.cc (handle_in_out_spec): Rather than
calling abilint on the abixml and abidiff-ing the .so file against
its .so.abi, call abidw --abidiff on the .so file and voila. Ok,
it does one extra save of abixml, but then that won't hurt. And
things are faster now than what they were anyway :-)
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Fix emitting of referenced type in abixml writer
* Use of canonical pointers in the hash map of referenced types
The abixml writer was using canonical types pointer values to hash
referenced types in a map. It was doing so "by hand"; and it was thus
messing things up for types without canonical types (like some class
declarations) etc.
This patch changes that by using the generic solution of
abigail::ir::hash_type_or_decl(), which also uses the same canonical
pointer type values. For types with no canonical types, that
functions knows has to gracefully fallback. At worst, it will just
make things slower, not wrong.
* Sorting of referenced types
The patch also changes the sorting function used for the hash map of
referenced types. The previous solution was sorting the pretty
representation of types; but then when two types have the same pretty
representation (think, typedefs, for instance) then their relative
position in the sorted result was random. This causes some stability
issues, in that emitting the abixml for the same binary several times
can lead to the some types being sorted differently -- they have the
same name, but not necessarily the same type *IDs*, as they are
different types.
The new sorting code handles this better; it also uses the pretty
representations of types, when they are equal, it uses the type IDs to
tell the types apart. At least this brings stability in the abixml
output, for a given binary.
* Avoiding duplicating declaration-only types when emitting the
context of referenced member types.
We don't keep track of declaration-only classes that are emitted.
This is because we allow a given class declaration (that carries no
definition) to appear several times in a given ABI corpus. So when a
referenced type is a class declaration, it always appears as if that
referenced type has not been emitted. So when we specifically emit
the not-emitted referenced types, it can happen that declaration-only
classes can appear a lot of times. This is unnecessary duplication,
aka bloat.
This patch thus introduces a new hash map that tracks emitted
declaration-only classes, so that we can allow duplication of class
declarations when they follow what's done in the IR read from DWARF,
and disallow that duplication when it's totally artificial and
useless.
* Better tracking of referenced types
We were blatantly forgetting to mark some referenced types as such.
So those were missing in some abixml output.
This patch fixes the spots where we were forgetting that important
information.
* Better representation of the scopes of the referenced types that
were specifically emitted.
The previous code was failing at properly representing the class scope
of some referenced types that were specifically emitted, or sometimes,
for member types, representing the scope would be so screwed that the
(referenced) member type itself wouldn't be emitted at all.
This is because I thought that to emit a given member type, just
emitting its parent scope would be enough. I thought that would
automatically trigger emitting the member type itself. First, that
would emit too much information at times; the other members of the
scope are not necessarily needed. And second the "duplication
detection code" would sometime refuse to emit the scope class, because
it has already been emitted earlier! But the incarnation that got
emitted didn't have this member type as member, then. Yes, in DWARF,
the same class A can be declared several times with different member
types in it. The complete representation of A would be a union of all
those declarations of A that are seen.
This patch addresses this issue by carefully emitting just the
information that is needed from the scope of the referenced type.
Basically the scope is declared just to declare/define the type we are
interested in; period. The abixml reader is now properly geared to
re-construct the scope by merging its different parts that are now
scattered around, in the ABI corpus. That support is part of this
patch set.
instance, a member typedef would be emitted with the information of
its parent class badly formatted.
* src/abg-writer.cc (struct type_ptr_comp_functor): Remove this.
(sort_type_ptr_map): Likewise.
(write_context::record_type_as_referenced): Do not add the
canonical type of the type to record as referenced directly.
(write_context::type_is_referenced): Adjust accordingly.
(struct write_context::type_ptr_cmp): New comparison functor.
(write_context::sort_types): New sorting function.
(write_context::{record_decl_only_type_as_emitted,
decl_only_type_is_emitted}): New member functions.
(write_member_type_opening_tag): Factorize out of ...
(write_member_type): ... here.
(write_class_decl_opening_tag): Factorize out of ...
(write_class_decl): ... here. Now, keep track also of
declaration-only classes that are emitted.
(write_decl_in_scope): Use the new write_member_type_opening_tag
and write_class_decl_opening_tag. Now write class scopes
ourselves; they only contain the type declarations that we are
emitting.
(write_translation_unit): Use the new sorting code to sort the
referenced types to emit. Do not emit referenced types that are
declaration-only classes that have already been emitted. Handle
the fact that emitting the referenced types might make those
emitted type *reference* other types too! So handle those new
referenced types as such, and emit them too.
(write_qualified_type_def, write_typedef_decl, write_var_decl): Do
not forget to mark referenced types as such.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Support updating a class in the abixml reader
* include/abg-ir.h (class_decl::{find_base_class,
find_member_type, find_data_member}): Declare new member functions ..
* src/abg-ir.cc (class_decl::{find_base_class,
find_member_type, find_data_member}): ... and define them.
* src/abg-reader.cc (build_class_decl): Add the ability to update
a class to add new data members, member types and base classes to
it, if necessary.
2015-10-17 Dodji Seketeli <dodji@redhat.com>
Don't canonicalize types not added to their context in abixml reader
* src/abg-reader.cc (read_context::maybe_canonicalize_type):
Assert that a class type that is scheduled for canonicalization
must be in a scope. We do this only for classes, for now. The
assert here helped to spot (and fix) a lot of places where we
were canonicalizing types without scope.
(read_context::build_or_get_type_decl): Canonicalize types here,
when they are built and (hopefully) added to their scope. There
might be cases here where we try to canonicalize types that are
not added to their scope. That should bomb in the assert above,
at least for class types, for now. We'll then fix the places where
the types are created, to make them properly scoped.
(build_type_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_array_type_def, build_enum_type_decl, build_typedef_decl):
Do not try to canonicalize the types early, right when they are
created. Canonicalization should happen at the point where (or
after) they are added to their scope.
(build_class_decl): Likewise. Also, schedule member types for
canonicalization once they've been added to their scope.
(build_class_tdecl): Schedule the pattern of the class template
for canonicalization once it has been added to its scope. I am
not sure I should do this, as the pattern is not yet a real type,
but I am taking my bet.
(build_type_composition): Schedule the composed type for
canonicalization once it's been added to its scope.
(handle_type_decl, handle_qualified_type_decl)
(handle_pointer_type_def, handle_reference_type_def)
(handle_function_type, handle_array_type_def)
(handle_enum_type_decl, handle_typedef_decl, handle_class_decl):
At this point, we should know if the type is to be added to a
scope or not. If it's in a scope, then schedule for
canonicalization.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Bug 19092 - abidw aborts on types that violate the ODR
* src/abg-ir.cc (type_base::get_canonical_type_for): Look at the
size of types with the same name which could be considered
ODR-equal, to spot possible violations that would induce a type
canonicalization error.
* tests/data/test-read-dwarf/test21-pr19092.so: New test input
binary.
* tests/data/test-read-dwarf/test21-pr19092.so.abi: New reference
abixml for the binary above.
* tests/data/Makefile.am: Add the new test input above to source
distribution.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
Likewise.
* tests/test-read-dwarf.cc (int_out_specs): Add the two test input
above.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Fix activation of Debian package support
* configure.ac: If we cannot activate Debian package support, then
report it clearly.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Misc style cleanup
* include/abg-fwd.h: Remove unnecessary declaration of class
parameter.
* src/abg-ir.cc: Remove trailing space in a comment.
* src/abg-reader.cc: Fix a comment.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Emit statistics about resolved class declarations
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Emit statistics
about resolved classes and the missed ones.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Add a missing xml text reader call
* src/abg-reader.cc (read_corpus_from_input): Add the necessary
call to xmlTextReaderNext call after the xmlTextReaderExpand call.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Pass some more parameters in reference
* include/abg-ir.h (operator==): For the type_base_sptr and
decl_base_sptr overloads, pass the parameters by reference.
({var,function}_decl::{set,get}_symbol): Pass the elf_symbol_ptr
by reference.
* src/abg-ir.cc (operator==): For the type_base_sptr and
decl_base_sptr overloads, pass the parameters by reference, now in
the definition.
({var,function}_decl::{set,get}_symbol): Pass the elf_symbol_ptr
by reference, now in the definition.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Adjust tests for the patchset
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Make abidw --abidiff not show definitely harmless changes
* tools/abidw.cc (set_diff_context): New function.
(main): Use that new function. Do not show any output for
--abidiff if only compatible changes were detected. Also, do not
abort if no input binary was giving.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Allow only one definition of a given type per corpus in abixml
* src/abg-writer.cc (write_translation_unit): Do not clear some
important per-translation unit maps here. There are needed to
keep track of the emitted and referenced types through the entire
corpus. Avoid (wrongly) recording function types twice.
(write_array_type_def, write_function_decl, write_function_type):
Record referenced types.
(write_class_decl): Record referenced types, and, allow only
declarations to be duplicated in a corpus.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
A series of small speed optimizations here and there
* src/abg-comparison.cc (var_diff::has_changes): Just compare the
two var_decl. It's (way) faster now than using recursive hashing
for that.
* src/abg-ir.cc (elf_symbol::does_alias): Get out early if the two
main symbols are equal.
(equals): In the overload for function_decl, start by comparing
types. This can be very fast for functions with different types,
as it amounts to a pointer comparison. In the overload for
class_decl, avoid a map lookup when it's not necessary.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Accelerate a slow path in hash_type_or_decl()
* include/abg-ir.h (is_function_parameter, is_class_base_spec):
Declare new functions.
* src/abg-ir.cc (is_function_parameter, is_class_base_spec):
Define them.
(hash_type_or_decl): Handle hashing of function parameters are
class base specifications with the fast path of type hashing.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Implement fast type lookup in a corpus
* include/abg-fwd.h (components_to_type_name): Declare new
function.
* include/abg-ir.h (string_type_base_wptr_map_type): New typedef.
(translation_unit::{get,set}_types): Declare new member functions.
* src/abg-ir.cc (translation_unit::priv::types_): New data member.
(translation_unit::{get,set}_types): Define these member
functions.
(maybe_update_types_lookup_map): Define new static function.
(components_to_type_name): Define new function.
(scope_decl::{add_member_decl, insert_member_decl}): Call the new
maybe_update_types_lookup_map.
(scope_decl::find_iterator_for_member): Fix logic.
(class_decl::set_is_declaration_only): When a class declaration
becomes a definition, update the name -> type map maintained in
the scope of the class.
(lookup_type_in_translation_unit): Use the hash map of qualified
name -> types that is now maintained in the translation unit.
This is way faster than the previous walking algorithm.
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir):
When fixing up global variable declarations that need to be
re-added to the translation unit, use the new fast type lookup
function.
2015-10-15 Dodji Seketeli <dodji@redhat.com>
Set the corpus of all ABI artifact reads from abixml
* src/abg-reader.cc (read_translation_unit): Set the current
corpus to the current translation unit being built.
2015-10-14 Dodji Seketeli <dodji@redhat.com>
Make canonicalization non sensitive to struct-ness of subtypes
* include/abg-fwd.h (get_type_name, get_function_type_name)
(get_method_type_name, get_pretty_representation): Add an
"internal" flag to all overoads.
* include/abg-ir.h
({type_or_decl_base, decl_base, type_decl, scope_type_decl,
qualified_type_def, array_type_def, enum_type_decl, typedef_decl,
var_decl, function_decl, function_decl::parameter, function_type,
method_type, class_decl}::get_pretty_representation): Add an
'internal' flag.
({decl_base, qualified_type_def, pointer_type_def,
reference_type_def, array_type_def, enum_type_decl::enumerator,
function_decl::parameter}::get_qualified_name): Likewise.
(qualified_type_def::build_name): Likewise.
* src/abg-ir.cc ({decl_base, qualified_type_def, pointer_type_def,
reference_type_def, array_type_def, enum_type_decl,
enum_type_decl::enumerator,
function_decl::parameter}::get_qualified_name): Take an "internal"
flag.
(qualified_type_def::build_name): Likewise.
({decl_base, type_decl, namespace_decl, array_type_def,
enum_type_decl, typedef_decl, var_decl, function_type,
method_type, function_decl,
class_decl}::get_pretty_representation): Likewise.
(get_type_name, get_function_type_name, get_method_type_name)
(get_pretty_representation): Likewise.
(type_base::get_canonical_type_for): Call
get_pretty_representation() with the "internal" flag set to
"true", to get a pretty representation that is independant from
the struct-ness of the subtypes of the type being canonicalized.
2015-10-14 Dodji Seketeli <dodji@redhat.com>
Handle aliased function decls when comparing decls in general
* include/abg-ir.h (is_function_decl): Add a const to the
reference parameter, making it comply with the definition.
* src/abg-ir.cc (equals): In the overload for decl_base, when the
two linkage names are different, consider the case of the decls
being aliased functions.
2015-10-14 Dodji Seketeli <dodji@redhat.com>
Fix const-ness of a function parameter
* include/abg-fwd.h (is_function_decl): Add a const to the
parameter to make it comply with the definition in abg-ir.cc.
Woops.
2015-10-14 Dodji Seketeli <dodji@redhat.com>
Fix "is-anonymous" abixml property impact on some tests
* tests/data/test-abidiff/test-PR18166-libtirpc.so: New file.
* tests/data/test-abidiff/test-PR18166-libtirpc.so.abi: Likewise.
* tests/data/test-abidiff/test-corpus0-report0.txt: Renamed into
tests/data/test-abidiff/test-PR18166-libtirpc.so.report.txt.
* tests/data/test-abidiff/test-corpus0-v{0,1}.so.abi: Removed.
* tests/data/Makefile.am: Renamed test-corpus0-* files into
test-PR18166-libtirpc.so-* files.
* tests/test-abidiff.cc (specs): Adjust.
2015-10-14 Dodji Seketeli <dodji@redhat.com>
Do not compare access specs for member types & functions
* include/abg-fwd.h (is_function_decl): Declare a new overload.
* src/abg-ir.cc (is_function_decl): Define a new overload.
(equals): In the overload for decl_base, do not compare access
specifiers when comparing member functions and types.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt: Likewise.
* tests/data/test-diff-filter/test4-report.txt: Likewise.
2015-10-14 Dodji Seketeli <dodji@redhat.com>
Fix strip_typedef issues
* src/abg-ir.cc (strip_typedef): Do not canonicalize
the return type of the method type to typedef-strip.
Acknowledge that the return type can be nil.
2015-10-14 Dodji Seketeli <dodji@redhat.com>
Force late canonicalizing of function types read from abixml
* src/abg-reader.cc (build_function_type): Late-canonicalize
function types.
2015-10-13 Ondrej Oprala <ooprala@redhat.com>
Bug 19082 - Recognize suppression spec files
* tests/data/Makefile.am: Add new test material to the build system.
* tests/data/test-diff-pkg/dirpkg-{0-dir1,{1,2}-dir2}/dir.abignore:
A test suppression specification.
* tests/data/test-diff-pkg/dirpkg-{2,3}-dir2/.abignore: Likewise.
* tests/data/test-diff-pkg/dirpkg-3.suppr: Likewise.
* tests/data/test-diff-pkg/dirpkg-{1,2,3}-dir{1,2}/libobj-v0.so: New
binary test inputs.
* tests/data/test-diff-pkg/dirpkg-{1,2,3}-dir{1,2}/obj-v0.cc: New test
source files
* tests/data/test-diff-pkg/dirpkg-{1,2,3}-report-{0,1}.txt: New
reference outputs
* tests/test-diff-pkg.cc: Adjust to run the new tests.
* tools/abipkgdiff.cc (prog_options): New static pointer to struct
opts.
(file_tree_walker_callback_fn): Rename to
first_package_tree_walker_callback_fn.
(second_package_tree_walker_callback_fn): Check for ELF files just
like the previous function but additionally check for files
ending with ".abignore", unless disabled from the command line.
({create_maps_of_package,extract_package_and_map_its}_content):
Add a callback as a new argument.
(main) handle the new "--no-abignore" option, which turns off
the search for suppression files within the new package.
2015-10-08 Dodji Seketeli <dodji@redhat.com>
Bug 19024 - Failing to flag underlying type of enums as anonymous
* src/abg-dwarf-raeder.cc (build_enum_type): Set the is-anonymous
flag on the underlying type of the enum.
* tests/data/test-read-dwarf/test0.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi: Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi: Likewise.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi: Likewise.
2015-10-08 Dodji Seketeli <dodji@redhat.com>
Bug 19025 - abixml writer forgets to emit some member types
* include/abg-fwd.h (is_namespace): Fix prototype.
* src/abg-writer.cc (struct type_ptr_comp_functor): New internal
type.
(sort_type_ptr_map): New static function.
(write_context::m_referenced_types_map): Renamed
m_referenced_fntypes_map data member into this.
(write_context::get_referenced_types): New member function.
(write_context::record_type_as_referenced): Renamed
record_fntype_as_referenced member function into this. Adjust.
(write_context::type_is_referenced): Renamed fntype_is_referenced
into this.
(write_context::clear_referenced_types_map): Renamed
clear_referenced_fntypes_map member function into this. Adjust.
(write_decl_in_scope): New static function.
(write_translation_unit): Use it here to emit types that are
referenced by other types in the TU, but that are not emitted.
Adjust.
(write_pointer_type_def, write_reference_type_def)
(write_typedef_decl): Record the underlying types referenced by
the emitted types as being, well, referenced.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so:
New test binary input.
* tests/data/test-read-dwarf/test20-pr19025-libvtkParallelCore-6.1.so.abi:
New reference output of the binary input above.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-read-dwarf.cc (in_out_spec): Add the new test inputs.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
Likewise.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
Likewise.
2015-10-06 Ondrej Oprala <ooprala@redhat.com>
Parallelize test read-dwarf.
* tests/Makefile.am: Link runtestreaddwarf with libpthread.
* tests/test-read-dwarf.cc (main) Create worker threads corresponding
to the number of CPUs online, add a "--no-parallel" option and move
the main loop...
(handleInOutSpec) ...here.
2015-10-07 Dodji Seketeli <dodji@redhat.com>
Bug 19023 - Type canonicalization is sensitive to struct-ness
* include/abg-ir.h (class_decl::is_struct): Declare a setter for the
"is-struct" property.
* src/abg-ir.cc (class_decl::is_struct): And define that setter
here.
(type_base::get_canonical_type_for): Temporarily set the
'is-struct' flag of the class type to 'false' before building its
pretty representation.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so:
New test input binary.
* tests/data/test-read-dwarf/test19-pr19023-libtcmalloc_and_profiler.so.abi:
New test reference output.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the two new test
inputs to the list of test inputs to consider.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Adjust.
2015-10-06 Dodji Seketeli <dodji@redhat.com>
Style adjustment in abg-corpus.cc
* src/abg-corpus.cc (corpus::exported_decls_builder::id_var_map_):
Renamed data member vars_map_ into this.
(corpus::exported_decls_builder::id_var_map): Renamed vars_map
into this.
(corpus::exported_decls_builder::var_id_is_in_id_var_map): Renamed
var_is_in_map into this.
(corpus::exported_decls_builder::{add_var_to_map,
add_var_to_exported, maybe_add_var_to_exported_vars}): Adjust.
2015-10-06 Dodji Seketeli <dodji@redhat.com>
Bug 19037 - Make ABI corpus support several functions with same symbol
* include/abg-corpus.h
(corpus::exported_decls_builder::str_{fn,var}_ptr_map_type):
Remove these typedefs from here as they only used internally in
abg-corpus.cc. So we move them there instead.
* src/abg-corpus.cc (str_fn_ptrs_map_type): New typedef.
(str_var_ptr_map_type): Moved the typedef that was in
corpus::exported_decls_builder here.
(corpus::exported_decls_builder::id_fns_map_): Rename the fns_
data member into this. Make it have a str_fn_ptrs_map_type as a
type.
(corpus::exported_decls_builder::id_fns_map): Renamed the
fns_map() accessor into this one.
(corpus::exported_decls_builder::{fn_id_is_in_id_fns_map,
fn_is_in_fns}): New member functions.
(corpus::exported_decls_builder::fn_is_in_id_fns_map): Rename
fn_is_in_map into this.
(corpus::exported_decls_builder::add_fn_to_id_fns_map): Rename
add_fn_to_map into this.
(corpus::exported_decls_builder::add_fn_to_exported): Adjust.
(corpus::exported_decls_builder::maybe_add_fn_to_exported_fns):
Adjust.
* src/abg-comparison.cc (function_decl_diff::report): Emit reports
about function name changes (for a given function ID) only if
there are sub-type changes to be reported for the function. In
that case, do not forget to emit the sub-type changes after the
name changes have been reported.
(corpus_diff::priv::ensure_lookup_tables_populated): Several
functions of the same ID can be removed or added from/to the
corpus.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so:
New test input binary.
* tests/data/test-read-dwarf/test18-pr19037-libvtkRenderingLIC-6.1.so.abi:
New test output reference.
* tests/data/Makefile.am: Add the new test materials to the source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Adjust to add the new
test inputs above.
2015-10-05 Ondrej Oprala <ooprala@redhat.com>
Do not imply private access when building a struct from ABIXML.
* src/abg-reader.cc (read_context): Abort if we run into an
unsupported access specifier.
(build_class_decl) Default to public access for the children
of a struct.
2015-10-05 Ondrej Oprala <ooprala@redhat.com>
Fix minor warnings when building documentation.
* manuals/abilint.rst: Fix the "Literal block expected" warning.
* manuals/abipkgdiff.rst: Fix the "Title underline too short" warning.
2015-10-05 Ondrej Oprala <ooprala@redhat.com>
Fix an "Unknown target name" error during make info.
* doc/manuals/libabigail-overview.rst: Fix the reference to
"ELF symbols".
2015-10-05 Ondrej Oprala <ooprala@redhat.com>
Fix a path in doc/Makefile.am
* doc/Makefile.am: Prefix the path for DOXY_WEBSITE_SRC_CFG and
DOXY_WEBSITE_BLD_{CFG,DIR} with "/doc" to protect it against make
clean.
2015-10-04 Dodji Seketeli <dodji@redhat.com>
Misc style cleanups
* src/abg-reader.cc (read_is_struct): Fix comment.
(build_type_decl): Use type_decl_sptr rather than
shared_ptr<type_decl>.
(build_type_decl): Use typedef_decl_sptr rather than
shared_ptr<typedef_decl>.
2015-10-04 Dodji Seketeli <dodji@redhat.com>
Use the ODR to speed up type canonicalization
* include/abg-fwd.h (class corpus): Forward-declare this.
(is_anonymous_type): Declare this new function.
* include/abg-ir.h (corpus_sptr, corpus_wptr): Declare these
typedefs here too.
(translation_unit::{g,s}et_corpus): Declare new member functions.
(type_or_decl_base::{g,s}et_corpus): Likewise.
* src/abg-ir.cc (translation_unit::priv::corpus): New data member.
(translation_unit::priv::priv): Initialize it.
(translation_unit::{g,s}et_corpus): Define new accessors.
(translation_unit::get_global_scope): Propagate the corpus of the
translation unit to its newly created global scope.
(translation_unit::bind_function_type_life_time): Propagate the
corpus of the translation_unit to the added function type.
(type_or_decl_base::priv::corpus_): Add new data member.
(type_or_decl_base::priv::priv): Initialize it.
(type_or_decl_base::{g,s}et_corpus): Define new accessors.
(scope_decl::{add,insert}_member_decl): Propagate the context's
corpus to the member added to the context.
(decl_base::priv::is_anonymous_): Add new data member.
(decl_base::priv::priv): Initialize it.
(decl_base::{s,g}et_is_anonymous): Define accessors.
(is_anonymous_type): Define a new test function.
(decl_base::set_name): Update the "is_anonymous" property.
(type_base::get_canonical_type_for): Implement the ODR-based
optimization to type canonicalization.
* src/abg-corpus.cc (corpus::add): When a translation unit is
added to a corpus, set the corpus of the translation unit.
* src/abg-dwarf-reader.cc (build_enum_type)
(build_class_type_and_add_to_ir): Set the "is_anonymous" flag on
anonymous enums and classes.
* src/abg-reader.cc (read_is_anonymous): Define new static
function.
(build_type_decl, build_enum_type, build_class_decl): Call the new
read_is_anonymous function and set the "is_anonymous" property on
the built type declaration.
* src/abg-writer.cc (write_is_anonymous): Define new static
function.
(write_type_decl, write_enum_type_decl, write_class_decl): Write
the "is_anonymous" property.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
2015-10-04 Dodji Seketeli <dodji@redhat.com>
Late canonicalize all types that reference classes when reading DWARF
* include/abg-fwd.h (peel_array_type): Declare new function.
* src/abg-ir.cc (peel_array_type): Define it.
(peel_typedef_pointer_or_reference_type): Peel arrays too, to get
the type of its element.
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): If a pointer,
reference, array or typedef references a class, then do
late-canonicalize this type.
2015-10-04 Dodji Seketeli <dodji@redhat.com>
Fix infinite loop in peel_typedef_pointer_or_reference_type
* src/abg-ir.cc (peel_typedef_pointer_or_reference_type): Make
sure the variable tested in the condition is the one updated by
the loop.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
Try harder to hash_type_or_decl avoid the slow path
* src/abg-ir.cc (hash_type_or_decl): When a declaration-only
class has a definition, then use the canonical type of that
definition as a hash value. If the class no definition, only
then, use the slow patfh of computing the recursive progressive
hash value of the type.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
Do not use recursive type hashing when writing out function types
* src/abg-writer.cc (typedef fn_shared_ptr_map): Remove.
(write_context::m_referenced_fntypes_map): Change the type of this
into type_ptr_map.
(write_context::{record_fntype_as_referenced,
fntype_is_referenced}): Use the pointer value of the canonical
type of the referenced type as key for the map.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
Prevent build_function_type from not canonicalizing certain types
* src/abg-dwarf-reader.cc (build_function_type): Associate the
type being built with its DIE, before starting to build the
sub-types. The current type is then amended with the sub-types
that are built later.
(build_ir_node_from_die): In the case for DW_TAG_subroutine_type,
do not associate the type to the DIE here, as it's been done in
build_function_type.
* src/abg-ir.cc (function_type::set_parameters): Adjust the index
of the parameters being set to the function: they start at 1,
unless the first parameter is artificial, in which case its index
starts at zero. This is just like what is done when the function
type is constructed directly with the parameters passed as an
argument to the constructor.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
Fix detection of changes in pointer diff in the comparison engine
* src/abg-comparison.cc (pointer_diff::has_changes): Just
comparing the underlying type might not be enough. Let's just
compare the pointer itself. Now that we have canonical types,
comparing the pointer itself is not slower.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
Do not overly canonicalize types during typedef stripping
* src/abg-ir.cc (strip_typedef): Do not canonicalize the stripped
type if the input one is not canonicalized.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
Cleanup some IR type comparison operators
* include/abg-ir.h (operator==): In the overloads for type_decl,
enum and class_decl, turn the shared_ptr parameter into a const
reference to the shared_ptr.
* src/abg-ir.cc (operator==): Do the same in the definitions.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
Add missing deep equality operator for pointer and reference types
* include/abg-ir.h (pointer_type_def::operator==): Add an overload
for pointer_type_def.
(reference_type_def::operator==) Add an overload for
reference_type_def.
(operator==): Add an overload for pointer_type_def_sptr and
reference_type_def_sptr.
* src/abg-ir.cc (pointer_type_def::operator==): Make the overload
for type_base& use the overload for decl_base&. Add a new
overload for pointer_type_def& and make is use the overload for
decl_base& too.
(operator==): Add free form overloads for pointer_type_def& and
reference_type_def&.
(reference_type_def::operator==): Add comments. Add an overload
for reference_type_def&.
2015-10-02 Dodji Seketeli <dodji@redhat.com>
constify is_class_type()
* include/abg-fwd.h (is_class_type): Take a pointer to const.
* src/abg-ir.cc (is_class_type): Adjust.
2015-10-01 Ondrej Oprala <ooprala@redhat.com>
Bug 19027 - ABI asymmetry with enums over INT_MAX
* src/abg-reader.cc (build_enum_type_decl): Use strtol
instead of atoi to parse the values and check for overflow.
* tests/data/Makefile.am: Add the new test material to the build
system.
* tests/data/test-read-dwarf/test17-pr19027.so: New test file.
* tests/data/test-read-dwarf/test17-pr19027.so.abi: Likewise.
* tests/test-read-dwarf.cc: Adjust to launch the new test.
2015-10-01 Dodji Seketeli <dodji@redhat.com>
Encourage people to use autoreconf -i
* COMPILING: Mention autoreconf -i, rather than just autoreconf.
2015-09-23 Ondrej Oprala <ooprala@redhat.com>
Bug 17340 - Support pointers and references to functions
* include/abg-comparison.h (compute_diff_for_distinct_kinds): Take the
first two arguments of type const type_or_decl_base_sptr instead.
* include/abg-ir.h (translation_unit::get_function_types): Declare new
method.
(function_types): Declare new typedef.
* src/abg-comparison.cc (compute_diff_for_types): Take the first two
arguments of type const type_or_decl_base_sptr instead of a const
decl_base_sptr.
(try_to_diff): Likewise.
(try_to_diff<class_decl>): Likewise.
(try_to_diff_distinct_kinds): Likewise.
(compute_diff_for_distinct_kinds): Likewise. Also remove a variant
accepting arguments of type const type_base_sptr.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Skip
building a pointer if it points to the beginning of a vptr.
(build_pointer_type_def): Declare utype_decl of type
type_or_decl_base_sptr and adjust assignments to it accordingly.
(build_function_type): New function definition.
(build_function_decl): Call build_function_type instead of building
an ftype manually.
(build_ir_node_from_die): Amend case DW_TAG_subroutine_type with
appropriate calls to build a function type.
* src/abg-ir.cc (translation_unit::get_function_types): New method
definition.
({pointer,reference}_type_def::pointer_type_def): Expect that
pointed_to might not have an accompanying declaration and set a type's
name in this case as well.
({pointer,reference}_type_def::get_qualified_name): Generate a
qualified name even if the pointed-to type has no declaration.
* src/abg-reader.cc (build_function_type): New function definition.
(handle_element_node): Return a type_or_decl_base_sptr instead and
try calling handle_function_type in addition to others.
(handle_function_type): New function definition that calls
build_function_type.
(build_type): Try calling build_function_type as well.
* src/abg-writer.cc (fn_shared_ptr_map): Declare new typedef.
(write_context::{clear_referenced_fntypes_map,fntype_is_referenced,
record_fntype_as_referenced}): New member functions.
(write_translation_unit): Call the new clear_referenced_fntypes_map.
* tests/data/Makefile.am: Add the new test material to the build
system.
(write_translation_unit): Separately write function types that have
been recorded to emit by write_{pointer,reference}_type_def.
(write_{pointer,reference}_type_def): Record the type pointed to as
a type to be emitted if type == function type.
(write_function_type): Write the details of a function type in the
abixml format and unmark the type.
* tests/data/test-diff-dwarf/test32-fnptr-changes-report-0.txt: New
test reference report.
* tests/data/test-diff-dwarf/test32-fnptr-changes-v{0,1}.cc: New test
source files.
* tests/data/test-diff-dwarf/test32-fnptr-changes-v{0,1}.o: New binary
test inputs.
* tests/data/test-diff-dwarf/test33-fnref-changes-report-0.txt: New
test reference report.
* tests/data/test-diff-dwarf/test33-fnref-changes-v{0,1}.cc: New test
source files.
* tests/data/test-diff-dwarf/test33-fnref-changes-v{0,1}.o: New binary
test inputs.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
Adjust.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test27.xml: New test source file.
* tests/test-diff-dwarf.cc: Adjust to launch the new tests.
* tests/test-read-write.cc: Likewise.
2015-09-09 Ondrej Oprala <ooprala@redhat.com>
Generalize some dwarf-reader functions to generate and return instances of type_or_decl_base_stpr to be able to propagate types occurring without an accompanying declaration.
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Return
a type_or_decl_base_sptr instead.
(get_scope_for_die): Likewise.
(build_class_type_and_add_to_ir): Typecast the assignment from
build_ir_node_from_die properly.
(build_{qualified,reference,array,typedef}_type): Likewise.
(build_pointer_type_def): Likewise.
(build_{var,function}_decl): Likewise.
2015-09-29 Ondrej Oprala <ooprala@redhat.com>
Move a constructor declaration
* include/abg-ir.h (decl_base): Change the decl_base() declaration's
visibility to private.
2015-09-24 Dodji Seketeli <dodji@redhat.com>
Bug 18535 - abidiff reports false positive ABI difference for libstdc++
*non-static* data member; a static data member only is not enough to
make the class declaration become a definition.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): The
presence of a data member shouldn't make a declaration-only class
loose its declaration-only-ness; the presence of a enon-static*
data member should.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Adjust.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-4.8.3.so:
New binary test input.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-4.9.2.so:
Likewise.
* tests/data/test-diff-filter/test31-pr18535-libstdc++-report-0.txt:
New test reference output.
* tests/data/Makefile.am: Add the new test material to the build
system.
* tests/test-diff-filter.cc (in_out_specs): Add the new test
inputs to the set of inputs to consider.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Remove duplicated runtestreaddwarf test
* tests/Makefile.am: Remove one copy of the runtestreaddwarf test
that is present twice.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Add a missing function declaration
* include/abg-tools-utils.h (dir_name): Add missing function
declaration.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Remove some dead code in abilint
* tools/abilint.cc (options::bidiff): Remove.
(options::options): Adjust.
(display_usage): Remove usage string for --bidiff
(parse_command_line): Remove parsing of un-implemented option
--bidiff.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Add a new --abidiff option to abidw
* tools/abidw.cc (options::abidiff): New data member.
(options::options): Initialize it.
(display_usage): Add a usage string for the new --abidiff option.
(parse_command): Parse the new --abidiff options.
(main): Save the abi of the input elf in a temporary abixml file;
read it back and compare both.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-hash.cc (class_decl::hash::operator()): Use a temporary
variable to ease debugging.
* src/abg-reader.cc (read_context::is_wip_type): Make this
function const.
* src/abg-writer.cc (write_context): Move data members at the top.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Speed up type canonicalization by avoiding recursive hashing
* include/abg-ir.h (canonical_types_map_type): Adjust this typedef
to make it point to an unordered_map which the key is now a string
and the value is a vector of types.
(type_or_decl_base::{get_cached_hash_value, set_cached_hash_value,
cached_hash}): Remove these member functions and type.
(struct type_base::cached_hash): Remove.
* src/abg-ir.cc (struct type_or_decl_base::priv::hash_): Remove.
(type_or_decl_base::priv::priv): Adjust.
(type_or_decl_base::{g,s}et_cached_hash_value): Remove.
(type_base::get_canonical_type_for): For declaration-only classes,
look at their definition for the canonical_type. Do not use
recursive type hashing anymore. Rather, use the pretty
representation string, and hash that.
(class_decl::base_spec::get_hash): Do away with hash value caching
here.
(class_decl::operator==): For decl-only classes, look at their
definitions for canonical types.
(hash_type_or_decl): Adjust comment. Use the canonical type
pointer value for type hash. That's the fast path. Otherwise, if
not available, fall back to a slow path which is the recursive
type hash we were using before.
* src/abg-dwarf-reader.cc (maybe_canonicalize_type): Schedule all
classes and typedef to classes for late canonicalization.
* src/abg-hash.cc (type_base::dynamic_hash::operator()): There is
no hash value cashing anymore.
(type_base::cached_hash::operator()): Remove.
* src/abg-reader.cc (read_context::get_type): Slight style
adjustment.
(read_translation_unit_from_file)
(read_translation_unit_from_buffer): Do not forget to canonicalize
types when reading just one translation unit.
(build_type_tparameter, build_template_tparameter): Canonicalize
the type.
* src/abg-writer.cc (struct type_hasher): New hasher type.
(type_ptr_map): Use a deep pointer comparison equal operator
functor, and canonical types as type hash values.
(write_class_decl): Do not write size and alignment on decl-only
classes. Do not record decl-only classes as being emitted. Their
definition must be emitted before.
* tests/test-read-write.cc (main): Do not do abi testing on
translation units (as opposed to doing it on abi corpora) as that
code is not wet yet. We need to know how to diff namespaces.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Update qualified name of a decl when it's added to its context
* include/abg-ir.h (decl_base::priv_): Make this be public, so
that the qualified name updater function can access it.
(class class_decl): Make set_member_is_static() a friend function.
* src/abg-ir.cc (class ::qualified_name_setter): New tree walking
type.
(decl_base::get_qualified_parent_name): Do not do any computation
here. Just return the pre-computed qualified parent name string.
(decl_base::get_qualified_name): Likewise, for qualified name.
(scope_decl::{add,insert}_member_decl): Update the qualified name of the
newly added member. Set the scope of the member here. It's not
going to be set elsewhere, from now on.
(add_decl_to_scope): Do not set the scope here anymore. Just call
scope_decl::add_member_decl and let it do the work.
(insert_decl_into_scope): Likewise, just call
scope_decl::insert_member_decl and let it do the work.
(class_decl::{add_data_member, add_member_function}): Do not
handle details of context setting at this point. Let
scope_decl::add_member_decl do it. Adjust the properties of the
context relation afterwards. In add_data_member, when a data
member changes its static-ness, move the data member into the
class_decl::priv::non_static_data_members_ or out of it, as
necessary.
(class_decl::insert_member_decl): By default, a data member is
considered static.
(set_member_is_static): Move this definition after the definitions
of class_decl, so that this function can see those. Also, when a
data member changes its static-ness, move the data member into the
class_decl::priv::non_static_data_members_ or out of it, as
necessary.
(class_decl::add_member_function_template): As we the
underlying function template decl to the context, do not do any
scope adding for it here.
(::qualified_name_setter::{do_update, visit_begin}): Define new
member functions.
(update_qualified_name): Define new static function.
* src/abg-reader.cc (build_class_decl): Make build_function_decl,
build_var_decl, build_function_tdecl and build_class_tdecl
automatically add the created decl to their context, and then
update the properties of the resulting member decl later, just
like what we do in the DWARF reader.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Add new test functions
* include/abg-fwd.h (is_function_decl, is_decl, is_namespace)
(is_scope_decl): Declare new function overloads.
* src/abg-ir.cc (is_function_decl, is_decl, is_namespace)
(is_scope_decl): Define them.
2015-09-21 Dodji Seketeli <dodji@redhat.com>
Constify some diff-utils functor operators
* include/abg-diff-utils.h (deep_ptr_eq_functor::operator()): Make
the overloads be const.
2015-09-16 Dodji Seketeli <dodji@redhat.com>
Support source_location_not_in and source_location_not_regexp suppressions
* include/abg-ini.h (enum property_value::value_kind): Add a
LIST_PROPERTY_VALUE kind.
(class {list_property_value, list_property}): Declare new types.
(is_list_property, is_list_property_value): Declare new functions.
* src/abg-ini.cc (struct list_property_value::priv): Define new
type.
(list_property_value::{list_property_value, get_content,
set_content, as_string}): Define new member functions.
(is_list_property_value): Define new function.
(struct list_property::priv): Define new type.
(list_property::{list_property, get_value, set_value,
handle_escape}): Define new member functions.
(is_list_property): Define new function.
(read_context::buf_): New data member.
(read_context::{peek, get, put_back, good, eof, read_string,
read_list_property_value}): New member functions.
(read_context::read_next_char): Use the new read_context::{get,
good, eof} member function, rather than using the input stream
directly.
(read_context::{skip_white_spaces, skip_comments,
skip_white_spaces_or_comments, read_property_name,
read_function_name, read_function_argument,
read_function_call_expr, read_property_value,
read_tuple_property_value, read_section_name, read_section}):
Adjust to use the new member functions of read_context rather than
using the input stream directly.
(read_context::read_string_property_value): Likewise. Use the new
read_context::read_string() method.
(read_context::{read, write}_property): Support reading list_property.
* include/abg-comparison.h
(type_suppression::{get_source_locations_to_keep,
set_source_locations_to_keep,
set_source_location_to_keep_regex_str,
get_source_location_to_keep_regex_str}): Add new member functions.
* src/abg-comparison.cc
(type_suppression::priv::{source_location_to_keep_,
source_location_to_keep_regex_str_,
source_location_to_keep_regex_}): Add new data members.
(type_suppression::priv::{g,s}et_source_location_to_keep_regex):
Define new member functions.
(type_suppression::{g,s}et_source_locations_to_keep): Define new
member functions.
(type_suppression::{g,s}et_source_location_to_keep_regex_str):
Likewise.
(type_suppression::suppresses_type): Support
"source_location_not_regexp" and "source_location_not_in"
properties of suppression specifications.
(read_type_suppression): Likewise. Also adjust to the fact that
ta tuple property value that is a list of strings is not a list
property value.
* doc/manuals/libabigail-concepts.rst: Add documentation for
source_location_not_in and source_location_not_regexp.
* tests/data/test-diff-suppr/libtest26-loc-suppr-v{0,1}.so: New
binary test inputs.
* tests/data/test-diff-suppr/test26-loc-suppr-{0,1,2}.suppr: New
suppression specification test inputs.
* tests/data/test-diff-suppr/test26-loc-suppr-report-{0,1,2,3}.txt:
New test reference reports.
* tests/data/test-diff-suppr/test26-loc-suppr-v{0,1}.cc: Source
code of the test binary input above.
* tests/data/test-diff-suppr/test26-loc-suppr.h: Likewise.
* tests/data/Makefile.am: Add the new test material to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test inputs above.
2015-09-16 Dodji Seketeli <dodji@redhat.com>
Pass simple property data by reference
* include/abg-ini.h (simple_property::{simple_property,
set_value}): Pass the value shared pointer by reference.
* src/abg-ini.cc (simple_property::{simple_property, set_value):
Pass the value shared pointer by reference.
2015-09-15 Dodji Seketeli <dodji@redhat.com>
Make string_ends_with() allow long suffixes
* src/abg-tools-utils.cc (string_ends_with): Allow suffixes of the
same size as the input string.
2015-09-13 Dodji Seketeli <dodji@redhat.com>
Add missing 'break' keyword in e_machine_to_string()
* src/abg-dwarf-reader.cc (e_machine_to_string): Add missing
'break' keywords in switch/case statement.
2015-09-09 Dodji Seketeli <dodji@redhat.com>
Fix compilation warnings in abipkgdiff.cc
* tools/abipkgdiff.cc (package::erase_extraction_directory)
(extract_rpm, extract_deb, extract_tar)
(erase_created_temporary_directories_parent): Check the return
value of the system() function.
(extract_package): Add necessary white space.
2015-09-09 Dodji Seketeli <dodji@redhat.com>
Fix spurious errors in the install-man-and-info-doc target
* doc/manuals/Makefile.am (install-man-and-info-doc): Don't check
for abidiff.info, that thing doesn't exist. Rather, check for
abigail.info. Use gzip -f in case the zipped file exists already.
2015-09-09 Dodji Seketeli <dodji@redhat.com>
Compare qualified name in decl_base comparison operator
* src/abg-ir.cc (equals): In the overload for decl_base, compare
qualified names, not just names.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
2015-09-08 Dodji Seketeli <dodji@redhat.com>
Fix a stupid typo in function sorting code
* src/abg-comparison.cc (function_comp::operator()): Fix a typo
preventing the proper sorting of function name when their
declarator names are equal. Oops.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt: Adjust.
2015-09-08 Dodji Seketeli <dodji@redhat.com>
Update manual for abipkgdiff
* doc/manuals/abipkgdiff.rst: Say we support tarballs and plain
directories.
2015-09-07 Dodji Seketeli <dodji@redhat.com>
Adjust {s,g}et_show_stats() to use a reference
* include/abg-dwarf-reader.h ({s,g}et_show_stats): Use a reference
to the reader.
* tools/abidiff.cc (main): Adjust.
* tools/abidw.cc (main): Likewise.
2015-09-07 Dodji Seketeli <dodji@redhat.com>
Use cache type hash values only after type canonicalization is done
*when* we request that hash value. If we are computing the hash value
of struct list itself, then the temporary value of "struct list" is
zero. But then once we are done computing the hash value of "struct
list", that value becomes non-zero.
Hence, the hash value of a type depends on when that value is
computed.
But then if we want to cache that hash value and re-use it later,
which value should we cache? Definitely not the zero value!
So in other words, we can use (and thus cache) the hash value of a
given type T only after the hash values of all types which use T have
been computed.
To satisfy that condition, we decide to use the (cached) hash value of
each type only after we've computed all the hash values of all types
of the system.
So, during type canonicalization, when a type T is canonicalized, this
patch stores the hash value of T. But then it's only when all types
are canonicalized that the hashing code is allowed to re-use the
cached value of types.
This fixes the issues of spurious type differences introduced when the
same type was read either from DWARF or from abixml. Those
differences where introduced by differences in the order of hashing
types which sub-types refer to themselves. The patch also updates
regression tests accordingly.
* src/abg-dwarf-reader.cc (read_debug_info_into_corpus): Before we
read debug info and build the IR, set a flag in the environment
saying that type canonicalization isn't finished yet. But then,
after type canonicalization is done, flip that flag to say that
type canonicalization is done.
* src/abg-reader.cc (read_corpus_from_input): Likewise.
* src/abg-ir.cc (type_base::get_canonical_type_for): Once a type
has been canonicalized, cache its hash value.
* src/abg-hash.cc (type_base::dynamic_hash::operator()): If type
canonicalization has been done and if the type has a cached value,
use that one.
* tests/data/test-read-dwarf/test2.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: Likewise.
2015-09-07 Dodji Seketeli <dodji@redhat.com>
Introduce the concept of environment
* include/abg-ir.h: Adjust note about memory management.
(class environment): Declare new class.
(translation_unit::translation_unit): Take an environment in
parameter.
(translation_unit::{g,s}et_environment): Declare new member
functions.
(type_or_decl_base::{g,s}et_environment): Likewise.
(type_or_decl_base::{get_cached_hash_value,
set_cached_hash_value}): Change the name of
decl_base::peek_hash_value() and decl_base::set_hash() here into
these and move them here.
(type_or_decl_base::hashing_started): Move
decl_base::hashing_started() here.
({g,s}et_environment_for_artifact): Declare new functions.
(class decl_base): Move member functions hashing_started(),
peek_hash_value() and set_hash() on to the type_or_decl_base base
class.
(scope_decl::scope_decl): Initialize the virtual member
type_or_decl_base().
(type_decl::{get_void_type_decl,
get_variadic_parameter_type_decl}): Remove these static member
functions. They are now non-static member functions of the new
environment type.
* src/abg-ir.cc (class environment_setter): New internal class.
(get_canonical_types_map): Remove. This now becomes a member
function of the environment type.
(class usage_watchdog): Remove.
(usage_watchdog_{s,w}ptr): Remove these typedefs.
(get_usage_watchdog_wptr, ref_usage_watchdog)
(maybe_cleanup_type_system_data): Remove these functions.
(translation_unit::priv::usage_watchdog_): Remove data member.
(translation_unit::priv::env_): New data member.
(translation_unit::priv::priv): Take an environment and initialize
the new env_ data member. Do not initialize the removed
usage_watchdog_.
(translation_unit::translation_unit): Take an environment
parameter.
(translation_unit::get_global_scope): Set the environment of a new
global scope.
(translation_unit::{g,s}et_environment): New accessors.
(translation_unit::bind_function_type_life_time): Set the
environment of the function type.
(struct environment::priv): New class.
(environment::{environment, ~environment, get_canonical_types_map,
get_variadic_parameter_type_decl, canonicalization_is_done}): New
member functions.
(struct type_or_decl_base::priv): New class.
(type_or_decl_base::{type_or_decl_base, hashing_started,
get_cached_hash_value, set_cached_hash_value, set_environment,
get_environment, traverse}): New member functions.
({s,g}get_environment_for_artifact): New functions.
(decl_base::priv::{hash_, hashing_started}): Remove.
(decl_base::priv::priv): Adjust.
(decl_base::decl_base): In the copy constructor, initialize the
virtual base type_or_decl_base. Do not initialize hash_ and
hashing_started data member that got removed.
(decl_base::{hashing_started, peek_hash_value, set_hash}): Remove
member functions.
(strip_typedef): Set the environment of the new type which has its
typedefs stripped off. Adjust the call to type_or_void().
(scope_decl::{add, insert}_member_decl): Set the environment of
the new member decl to the environment of its scope.
(synthesize_type_from_translation_unit)
(synthesize_function_type_from_translation_unit): Set the
environment for the newly synthesized type. Adjust calls to
type_or_void().
(type_or_void): Take an environment in parameter. Get the void
type from the environment.
(get_canonical_types_map): Remove.
(type_base::get_canonical_type_for): Get the canonical types map
from the environment, not from a global variable.
(type_decl::{get_void_type_decl,
get_variadic_parameter_type_decl}): Remove.
(pointer_type_def::pointer_type_def): Adjust call to type_or_void.
(reference_type_def::reference_type_def): Likewise.
(function_decl::parameter::get_pretty_representation): Get the
variadic parameter type decl from the environment.
(class_decl::priv::classes_being_compared_): Remove static data
member.
(class_decl::priv::{mark_as_being_compared,
unmark_as_being_compared, comparison_started): Use the "classes
being compared" map from the environment.
(class_decl::base_spec::get_hash): Adjust.
(keep_type_alive): Get the alive types array from the environment)
not from a global variable anymore.
(get_next_string): Put the counter in thread-local storage.
* src/abg-hash.cc (scope_decl::hash::operator())
(function_decl::hash::operator()): Do not handle caching (here).
* include/abg-corpus.h (corpus::{g,s}et_environment): Declare new
accessors.
* src/abg-corpus.cc (corpus::priv::env): New data member.
(corpus::priv::priv): Initialize it.
(corpus::corpus): Take an environment in parameter.
(corpus::{g,s}et_environment): Define new member functions
(corpus::add): Set the environment of the newly added translation
unit, if it's not set already set. In any case, assert that the
translation unit must use the same environment as the corpus.
* include/abg-dwarf-reader.h (create_read_context)
(read_corpus_from_elf): Take an environment parameter.
({s,g}et_debug_info_root_path, {s,g}et_environment): Declare new
functions.
* src/abg-dwarf-reader.cc (read_context::{env_,
offline_callbacks_}): New data members.
(read_context::read_context): Initialize them.
(read_context::clear_per_translation_unit_data): Do not touch the
void type declaration, it doesn't belong to the translation unit.
(read_context::{env, offline_callbacks}): New accessors.
(read_context::{create_default_dwfl}): New member function.
(read_context::dwfl_handle): Add a setter overload.
({s,g}et_debug_info_root_path): Define new accessors.
(create_default_dwfl, create_dwfl_sptr, create_default_dwfl_sptr):
Remove these.
(build_translation_unit_and_add_to_ir): Adjust to pass the
environment to the newly created translation unit.
(build_function_decl): Adjust to pass the environment to the
created function and parameter types. Get variadic parameter type
node from the current environment, not from a global variable.
And do not try to canonicalize function types here.
(read_debug_info_into_corpus): Set the environment of the newly
created corpus.
(build_ir_node_for_void_type): Get the void type node from the
current environment, rather than from a global variable.
(create_read_context): Take the environment in parameter.
Create the default dwarf front end library handle using the new
member function of the read context. Set the current environment
used by the reader.
(read_corpus_from_elf): Take an environment in
parameter. Overhaul. This is now simpler.
(has_alt_debug_info): Adjust the call to create_read_context() to
make it pass an empty environment.
* include/abg-fwd.h (class environment): Forward declare.
* include/abg-reader.h (read_translation_unit_from_file)
(read_translation_unit_from_buffer)
(read_translation_unit_from_istream)
(read_corpus_from_native_xml): Take an environment in parameter.
* src/abg-reader.cc (read_context::m_env): New data member.
(read_context::read_context): Initialize it.
(read_context::{get_environment, set_environment}): New data
member.
(read_translation_unit): Set environment of the new translation
unit.
(read_corpus_from_input): Set the environment of the new corpus.
(read_translation_unit_from_file)
(read_translation_unit_from_buffer)
(read_translation_unit_from_istream, read_corpus_from_native_xml):
Take an environment in parameter.
(build_function_parameter): Get variadic parameter type from the environment.
* src/abg-comparison.cc (compute_diff): Add asserts in all the
overloads to ensure that the artifact being compared come from the
same environment.
* tests/print-diff-tree.cc (main): Create an env for the ABI
artifacts to use.
* tests/test-abidiff.cc (main): Likewise.
* tests/test-diff-dwarf.cc (main): Likewise.
* tests/test-ir-walker.cc (main): Likewise.
* tests/test-read-dwarf.cc (main): Likewise.
* tests/test-read-write.cc (main): Likewise.
* tools/abicompat.cc (main): Likewise.
* tools/abidiff.cc (main): Likewise.
* tools/abidw.cc (main): Likewise.
* tools/abilint.cc (main): Likewise.
* tools/abipkgdiff.cc (main): Likewise.
2015-09-07 Dodji Seketeli <dodji@redhat.com>
Fix redundant const qualifier stripping
* include/abg-ir.h (operator&, operator~): Add overloaded bitwise
operators for qualified_type_def::CV.
* src/abg-ir.cc (operator&, operator~): Define them.
* src/abg-dwarf-reader.cc (maybe_strip_qualification): Fix
comment. If there are multiple qualifiers, only strip the const
one.
(build_ir_node_from_die): Once we've built a qualified type, if
the 'const' qualifier is stripped, then add the new (stripped)
type to the set of new types.
2015-09-05 Dodji Seketeli <dodji@redhat.com>
Fix wording in README
* README: Fix wording.
2015-09-02 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-hash.cc (class_decl::hash::operator()): Remove some dead
code.
* src/abg-ir.cc (equals): In the overload for class_decl,
re-indent.
2015-09-02 Dodji Seketeli <dodji@redhat.com>
Re-arrange some regression tests order
* tests/Makefile.am: Run runtestreaddwarf and
runtestcanonicalizetypes at the beginning.
2015-09-02 Dodji Seketeli <dodji@redhat.com>
Bug 18904 - Fix support for C++ rvalue references
* src/abg-comparison.cc (reference_diff::has_changes): Just
compare the references, rather than assuming that the change can
only be on underlying types.
(reference_diff::report): Describe lvalue/rvalue changes for
references.
* src/abg-ir.cc (reference_type_def::reference_type_def): Properly
set the name for an rvalue reference.
(equals): For references, compare lvalue-ness too.
(reference_type_def::get_qualified_name): Properly set rvalue
reference names.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-liba.so:
New test input.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-libb.so:
New test input.
* tests/data/test-diff-filter/test30-pr18904-rvalueref-report0.txt:
New test reference output.
* tests/data/Makefile.am: Add the new files to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Run the new tests.
2015-09-02 Dodji Seketeli <dodji@redhat.com>
More type degradation fixes (from DWARF to abixml)
* include/abg-fwd.h (get_type_scope): Declare new function.
* src/abg-hash.cc (var_decl::hash::operator()): Do not cache the
hash because that can alter the hash computing of a larger type
which embeds a var decl as a member declaration. This is
especially true if the var decl indirectly references the larger
type. The only way to cache the value of a var decl would be to
wait after all canonical types have been computed. We'd then seal
all types. After that sealing happens, we can cache var decls
starting from the top-level ones.
(function_decl::hash::operator()): Likewise.
* src/abg-ir.cc (get_type_scope): Define new functions.
* src/abg-reader.cc (read_is_declaration_only): Declare this
function earlier.
(typedef const_types_map_it): Adjust this to make it point to a
map of string and vector of types, as opposed to a map to string
and type as it was before.
(typedef types_map_it): New typedef.
(read_context::map_id_and_node): Map a type id to the last
xmlNodePtr that represent a *declaration*. That gives more leeway
to the declaration resolution code to choose the right definition
later. Otherwise, there are cases where the wrong definition. By
wrong definition, I mean a definition that is different from the
one chosen by the DWARF reading code, for a given declaration.
Basically for a given ABI corpus, a type declaration resolve to
the first definition seen in the corpus.
(read_context::get_all_type_decls): Define new member function.
(read_context::types_equal): Use qualified names only if both
types have a scope.
(read_context::key_type_decl): Now a given ID is associated to
*all* the declarations and definition that have that ID.
(read_translation_unit_from_input): Make sure the current corpus
node points to the right node.
(build_class_decl): Resolve class declarations to the first
definition seen in the corpus. Key a type decl before reading its
members as a reading a member can request the current decl. No
need to try and canonicalize a member type, as build_class_decl()
does that already.
* tests/data/test-read-dwarf/test16-pr18904.so: New test binary
input.
* tests/data/test-read-dwarf/test16-pr18904.so.abi: New test
output reference.
* tests/test-read-dwarf.cc: Run the test above.
* tests/data/Makefile.am: Add the new test input to source
distribution.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: Likewise.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: Likewise.
2015-08-30 Dodji Seketeli <dodji@redhat.com>
Bug 18892 - type degradation from DWARF to abixml on libtsan.so
* src/abg-reader.cc (read_context::maybe_canonicalize_type): Late
canonicalize enum types.
(build_enum_type_decl): Read the linkage name of the enum type.
* src/abg-writer.cc (write_enum_type_decl): Emit the linkage name
of the enum type.
* tests/data/test-read-dwarf/test15-pr18892.so: New binary test
input.
* tests/data/test-read-dwarf/test15-pr18892.so.abi: New test
output reference.
* tests/data/Makefile.am: Add the new test inputs above to source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Run the two tests above.
2015-08-30 Dodji Seketeli <dodji@redhat.com>
Bug 18893 - type degradation from dwarf to abixml on libGLU.so
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Do not
consider that virtual member functions disqualify a class from
being declaration-only.
* src/abg-hash.cc (var_decl::hash::operator()): Do not cache the
result of hashing before we are done building the type of the
var_decl.
(function_decl::hash::operator()): Likewise, do not cache the
result of hashing before we are done building the type of the
function_decl.
* src/abg-reader.cc (build_class_decl): Build the link between a
class declaration and its definition. If there are several
definitions of a class in the corpus, keep just one.
* src/abg-writer.cc (write_class_is_declaration_only): Emit the
link between a class declaration and its definition.
(write_class_decl): Emit a class declaration even if it has a
definition. The definition is going to be emitted
separately.
* tests/data/test-read-dwarf/test14-pr18893.so: New binary test
input.
* tests/data/test-read-dwarf/test14-pr18893.so.abi: New test
reference output.
* tests/data/Makefile.am: Add the new test input files to source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Run the new tests.
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: Likewise.
2015-08-30 Dodji Seketeli <dodji@redhat.com>
Use common canonicalization oracle when reading class type from dwarf
* src/abg-dwarf-reader.cc (build_ir_node_from_die):
(maybe_canonicalize_type): Move the specific logic that was in
build_ir_node_from_die (for class types) here.
2015-08-30 Dodji Seketeli <dodji@redhat.com>
Fix crash in file type guessing
* src/abg-tools-utils.cc (string_ends_with): Handle the case where
the string suffix is longer than the string itself.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Bug 18894 - Fix representation of enumerators in abixml format
* include/abg-ir.h (enum_type_decl::enumerator::get_value()):
Change the type of this from size_t to ssize_t.
* src/abg-ir.cc (enum_type_decl::enumerator::get_value): Do the
same on the definition side.
(non_canonicalized_subtype_detector::visit_begin): If a type
refers to itself, late canonicalize it to have a similar hashing
result as what the abixml reader does.
* src/abg-reader.cc (build_enum_type_decl): Use ssize_t to read
the value of enumerators.
* tests/data/test-read-dwarf/test13-pr18894.so.abi: New test input.
* tests/data/Makefile.am: Add the new test inputs above to source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add new test inputs.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Likewise.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Likewise.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Detect vtable changes from member function changes
* include/abg-ir.h (class_decl::{has_virtual_base, has_vtable}):
Declare new member functions.
* src/abg-comp-filter.cc (has_virtual_mem_fn_change): New overload
for function_decl_diff.
(has_virtual_mem_fn_change): In the overload for diff*, support
virtual member function changes detection for function_decl_diff*.
* src/abg-comparison.cc (function_decl_diff::report): Detect and
report changes to a vtable by looking a changes that can happen to
a given member function.
(corpus_diff::report): Detect and report changes to vtables by
looking at changes change to member functions.
* tests/data/test-diff-dwarf/test29-vtable-changes-report-0.txt:
New text input.
* tests/data/test-diff-dwarf/test29-vtable-changes-v{0,1}.cc: Source
code of new test input binaries.
* tests/data/test-diff-dwarf/test29-vtable-changes-v{0,1}.o: New
test input binaries.
* tests/data/test-diff-dwarf/test30-vtable-changes-report-0.txt:
New text input.
* tests/data/test-diff-dwarf/test30-vtable-changes-v{0,1}.cc: New
test input.
* tests/data/test-diff-dwarf/test30-vtable-changes-v{0,1}.o: New
test input binaries.
* tests/data/test-diff-dwarf/test31-vtable-changes-report-0.txt:
New test input.
* tests/data/test-diff-dwarf/test31-vtable-changes-v{0,1}.cc:
Source code of new test input binary.
* tests/data/test-diff-dwarf/test31-vtable-changes-v{0,1}.o: New
test input binary.
* tests/data/Makefile.am: Add the new test input files above to
source distribution.
* tests/test-diff-dwarf.cc (in_out_specs): Consume the new test
inputs above.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Do not hash or compare virtual member functions as par of classes
* src/abg-ir.cc (equals): When comparing two classes, do not
compare their virtual member functions.
* src/abg-hash.cc (class_decl::hash::operator()): Do not hash
virtual member functions when hashing a class.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-ir.cc (qualified_type_def::get_qualified_name): Fix
typos in comments.
(class_decl::member_class_template::operator==): Add comments.
(operator==): Add comment for the overload of
class_decl::member_class_template_sptr.
(function_tdecl::operator==): Add comments.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Adjust many reference output for the non-regression test suite
* tests/data/test-abidiff/test-enum0-report.txt: Adjust.
* tests/data/test-abidiff/test-enum1-report.txt: Adjust.
* tests/data/test-abidiff/test-qual-type0-report.txt: Adjust.
* tests/data/test-abidiff/test-struct0-report.txt: Adjust.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-write/test17.xml: Adjust.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Make test-read-dwarf.cc and test-read-write.cc abidiff the ABIs
* tests/test-read-dwarf.cc (main): Use abidiff to compare the
input elf file with the XML emitted. That should yield the empty
set.
* tests/test-read-write.cc (main): Likewise, use abidiff to
compare the input abixml file with the one that is emitted.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Add a new --noout option to abidw
* tools/abidw.cc (options::noout): New data member.
(options::options): Initialize it.
(display_usage): Add a usage string for the new option.
(parse_command_line): Parse the new option.
(main): If --noout is provided, do not emit the XML form.
* doc/manuals/abidw.rst: Document the new option.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Add a --no-architecture option to abidiff
* tools/abidiff.cc (options::no_arch): New data member.
(options::options): Initialize it.
(display_usage): Display a help string for the new options.
(parse_command_line): Parse the new options.
(main): If --no-architecture is provided, set the corpus
architecture to "".
* doc/manuals/abidiff.rst: Document the new options.
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Read abixml as a whole file and fix lots discrepancies with dwarf
* src/abg-reader.cc (class read_context): Move data member at
the top of the class like what is done elsewhere in the code
base.
(read_context::m_corp_node): New data member.
(read_context::read_context): Initialize it.
(read_context::{get,set}_corpus_node): New accessors.
(read_context::map_id_and_node): Accept that a node id previously
defined is defined again. In that case we just remember the first
mapping id -> xml-node. That seems to work for now.
(read_context::get_translation_unit): Fix the logic.
(read_context::m_wip_types_map): Rename
read_context::m_wip_classes_map into this.
(read_context::clear_wip_types_map): Rename
read_context::clear_wip_classes into this.
(read_context::mark_type_as_wip): Rename
read_context::mark_class_as_wip into this.
(read_context::unmark_type_as_wip): Rename
read_context::unmark_type_as_wip into this.
(read_context::is_wip_type): Rename read_context::is_wip_class
into this.
(read_context::types_equal): New member function.
(read_context::clear_per_translation_unit_data): Do not clear
anything anymore as the previous data that were per-tu are now
per-corpus.
(read_context::clear_per_corpus_data): Clear here the previous
data that were per-tu.
(read_context::maybe_canonicalize_type): Add a new force_delay
flag that forces the type to be late-canonicalized. Also force
late-canonicalize references, pointers, qualified-type and typedef
because they must be canonicalized once they've been added to
their context; but then this function might be called too early,
before they are added to their context.
(read_context::type_id_new_in_translation_unit): Remove this
member function.
(read_translation_unit_from_input): Be able to either use the
xmlTextReader interface, or get the current 'abi-instr' xml
element node. If using the xmlTextReader interface, use it to
move to the 'abi-instr' node, expand it and then use that. In
either case, call read_translation_unit() with the 'abi-instr' xml
element node.
(read_translation_unit): Take an 'abi-instr' XML element in
argument now, use that to read the translation unit, as opposed to
using the xmlTextReader interface we where using before to walk
the sub-tree of the abi-instr xml node.
(read_context::get_scope_for_node): If the scope is a new
translation unit, then build the new translation unit.
(read_symbol_db_from_input): Take the function and variable symbol
data bases, and read the current xml element node (do not use the
xmlTextReader interface anymore) to populate the function and
variable symbols.
(read_elf_needed_from_input): Do not use the xmlTextReader
interface anymore. Rather, use the current xml element node, look
for the 'elf-needed' xml element node and use it to populate the
set of elf dependencies.
(read_corpus_from_input): Rework to expand the contents of the
corpus node and use the result, rather than just exclusively
relying on the xmlTextReader interface.
(build_function_parameter): Build a proper IR node for variadic
parameters. Build function type node *after* having built all the
parameters IR, so that parameter indexing is the same as what is
done in the DWARF reader. Also, if the function is not being
added to its context yet, then delay the canonicalizing of its
type, just like what is done by the DWARF reader.
(build_qualified_type_decl, build_pointer_type_def)
(build_reference_type_def, build_enum_type_decl, build_type_decl):
Adjust. Do not enforce anymore that the ID of this type be new in
the current TU. Delay canonicalizing if the type is not being
added to its context. For typedefs, use an adapted way of
checking the consistency of the underlying type.
(build_array_type_def): Do not enforce anymore that the ID of this
type be new in the current TU. Support the fact that the array
might not have any DW_AT_byte_size attribute. Force late
canonicalizing if the array is not being added to its context.
(build_class_decl): Adjust. Reuse the
read_context::maybe_canonicalize_type() function rather than
trying to determine locally when to canonicalize.
(build_template_tparameter): Adjust
2015-08-29 Dodji Seketeli <dodji@redhat.com>
Fix handling of class declaration during DWARF reading
*virtual* member functions, data members, base classes or a
DW_AT_byte_size as being conditions for being defined.
* src/abg-dwarf-reader.cc (read_context::decl_only_classes_map_):
Remove this data member.
(read_context::{declaration_only_classes_to_force_defined,
schedule_declaration_only_class_for_forced_resolution}): Remove
these member functions.
(read_context::resolve_declaration_only_classes): Do not force
resolution of class declaration.
(build_class_type_and_add_to_ir): Do not schedule classes for
forced-resolution when they are used as base classes. The
presence of a member function is not enough to make the class be
defined. It needs to be a virtual member function.
2015-08-28 Dodji Seketeli <dodji@redhat.com>
Fix important hashing issues
* src/abg-hash.cc (class_decl::hash::operator()): Do not force
base classes to have definitions anymore. GCC and Clang (at
least) some time emits debug info in which the definition of some
base classes are missing, especially when those base classes have
vtables. In that case, the definition of the class might it's in
the binary where the vtable is emitted, which might not be the
binary we are looking at. So let's relax the assertion we had
here for base classes. For hashing virtual member functions,
directly walk the virtual member functions by looking at
class_decl::get_virtual_mem_fns() rather than walking all
member functions and looking for the virtual ones. This is a
speed optimization but it also helps during debugging.
2015-08-28 Dodji Seketeli <dodji@redhat.com>
Fix template comparison operators
* include/abg-ir.h (function_tdecl::operator==): Introduce a new
virtual member operator that takes a function_tdecl&.
* src/abg-ir.cc
(class_decl::member_function_template::operator==): Avoid the
static cast in the overload for member_base. In the overload for
member_class_template, avoid infinite recursion.
(function_tdecl::operator==): In the overload for decl_base, do
not do the real work here in the overload for decl_base Rather,
the real work is done in the new overload for function_tdecl, and
all other overloads call that one.
2015-08-28 Dodji Seketeli <dodji@redhat.com>
Use size/alignment of class definition when requested on declaration
* include/abg-ir.h (type_base::{set_size_in_bits,
set_alignment_in_bits}): Make these member functions virtual.
(class_decl::{set_size_in_bits, get_size_in_bits,
get_alignment_in_bits, set_alignment_in_bits}): Declare these
virtual member functions.
* src/abg-ir.cc (class_decl::{set_size_in_bits, get_size_in_bits,
get_alignment_in_bits, set_alignment_in_bits}): Define these
virtual functions.
2015-08-28 Dodji Seketeli <dodji@redhat.com>
Fix type lookup algorithm
* src/abg-ir.cc (find_next_delim_in_cplus_type): Define new static
function.
(fqn_to_components): Use the new function above to break up a
fully qualified name into components, rather than the too simple
string::find_first_of() we were using previously.
(lookup_node_in_scope): If the found type (class) is a
declaration-only and if it has a definition, then return it.
2015-08-26 Dodji Seketeli <dodji@redhat.com>
Make decl hashing always take qualified name into account
* src/abg-hash.cc (decl_base::hash::operator()(const decl_base&)):
Always hash the qualified name of the decl.
2015-08-26 Dodji Seketeli <dodji@redhat.com>
Accept base classes which types are compatible with class type
* include/abg-fwd.h (is_compatible_with_class_type): Declare a new
overload.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Rather
than requiring that base classes be of class type, just require
that they be compatible with class types.
* src/abg-ir.cc (is_compatible_with_class_type): Define a new
overload.
2015-08-26 Dodji Seketeli <dodji@redhat.com>
Harden function_decl::get_pretty_representation()
* src/abg-ir.cc (function_decl::get_pretty_representation): Make
sure the function type is a member function before calling
get_member_function_is_{virtual,ctor,dtor,const}.
2015-08-25 Dodji Seketeli <dodji@redhat.com>
Don't cache type qualified name before canonicalization
* src/abg-ir.cc (decl_base::{get_qualified_parent_name,
get_qualified_name}): Use the qualified name cache only if the
type is fully built, i.e, when its canonical type is present.
(qualified_type_def::get_qualified_name): Likewise.
(pointer_type_def::get_qualified_name): Likewise.
(reference_type_def::get_qualified_name): Likewise.
(array_type_def::get_qualified_name): Likewise.
2015-08-22 Dodji Seketeli <dodji@redhat.com>
Misc style cleanups
* configure.ac: Fix some spelling typos.
* src/abg-tools-utils.cc (guess_file_type): Fix indentation.
* tests/test-diff-pkg.cc (int_out_specs): Add some vertical spaces
for better legibility.
* tools/abidiff.cc (main): Add a missing space.
* tools/abipkgdiff.cc (extract_deb): Fix a typo in the comment.
2015-08-22 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff compare tar archives containing binaries
* config.h.in (WITH_TAR): New configuration preprocessor macro.
* configure.ac: Add a new --enable-tar option. It's turned on
automatically if the tar program is found in the PATH. Adjust the
build configuration report to add the tar archive support.
* include/abg-tools-utils.h (string_ends_with): Declare new
function.
(enum file_type): Add a new FILE_TYPE_TAR enumerator.
* src/abg-tools-utils.cc (string_ends_with): Define new function.
(operator<<(ostream&, file_type)): Serialize the new FILE_TYPE_TAR
enumerator.
(guess_file_type): Detect UStar format file by reading its magic
number. Detect compressed tar files based on the file path
extension.
* tools/abipkgdiff.cc (extract_tar): Define new function.
(extract_package): Handle tar packages.
(main): Handle tar archives.
* tools/abidiff.cc (main): Handle the new FILE_TYPE_TAR
enumerator.
* tools/abilint.cc (main): Likewise.
* tests/data/test-diff-pkg/tarpkg-0-dir{1,2}.ta{,r,.bz2, gz}: New
test input tarballs.
* tests/data/test-diff-pkg/tarpkg-0-report-0.txt: New test output
reference.
* tests/data/Makefile.am: Add the new test data file above to
source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add new tests cases.
2015-08-22 Dodji Seketeli <dodji@redhat.com>
Misc style fixes in abipkgdiff
* include/abg-tools-utils.h (enum file_type): Fix the comment for
for the FILE_TYPE_DEB enumerator.
* tools/abipkgdiff.cc (main): Fix the style of the conditions.
Also, fix the text emitted.
2015-08-22 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff compare directories containing binaries
* include/abg-tools-utils.h (enum file_type): Add a new
FILE_TYPE_DIR enumerator.
* src/abg-tools-utils.cc (operator<<(ostream&, file_type)):
Support serialization of the new FILE_TYPE_DIR enumerator.
(guess_file_type): Detect that the path given is a directory.
* tools/abipkgdiff.cc (package::package): If the package is a
directory, then set its extracted directory path to the path of
the directory.
(package::erase_extraction_directory): Do not erase the extraction
directory if the package is a directory provided by the user.
(extract_package): If the package is a directory provided by the
user, then there is nothing to extract.
(main): If the first package is a directory, then the second one
should be a directory as well.
* tools/abidiff.cc (main): Support directories as input.
* tools/abilint.cc (main): Likewise.
* tests/data/test-diff-pkg/dirpkg-0-dir{1,2}/libobj-v0.so: New
binary test inputs.
* test/data/test-diff-pkg/dirpkg-0-report-0.txt: New input test
file.
* tests/data/test-diff-pkg/dirpkg-1-dir{1,2}/obj-v0.cc: Source
code of the binary test inputs above.
* tests/data/Makefile.am: Add the new files above to the source
distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the new test input
files above to the set of tests this harness has to run over.
2015-08-22 Dodji Seketeli <dodji@redhat.com>
[dwarf reader] Support reference types without explicit DW_AT_byte_size
* src/abg-dwarf-reader.cc (build_reference_type): If the type DIE
has no DW_AT_byte_size, assume the type size is the translation
unit's address size.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
2015-08-21 Dodji Seketeli <dodji@redhat.com>
[dwarf reader] Support pointer types without explicit DW_AT_byte_size
* abg-dwarf-reader.cc (build_pointer_type_def): If the type DIE
has no DW_AT_byte_size, assume the type size is the translation
unit's address size.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Adjust.
2015-08-21 Dodji Seketeli <dodji@redhat.com>
make abipkgdiff compile with GCC 4.4.7
* tools/abipkgdiff.cc (package::extracted_packages_parent_dir):
The string holding the dir name is no more __thread, as this won't
compile with GCC 4.4.7
2015-08-21 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-dwarf-reader.cc (read_context::die_type_map): Fix typo
in the comment.
* src/abg-ir.cc (peel_typedef_type): Fix typo in the comment.
* src/abg-reader.cc
(read_context::perform_late_type_canonicalizing): Fix a type in
the comment.
2015-08-21 Dodji Seketeli <dodji@redhat.com>
Make get_pretty_representation work on method types
* include/abg-fwd.h (is_method_type): Declare new overloads for
naked pointers.
(get_method_type_name): Declare new functions.
(get_pretty_representation): Declare new overloads for
method_type.
* src/abg-ir.cc (get_function_type_name): If the function type is
a method type, handle it as such.
(get_method_type_name): Define new functions.
(get_pretty_representation): If the function type is a method
type, handle it as such.
(get_pretty_representation): Define new overloads for method_type
and pointer/reference to method_type.
(is_method_type): Add overloads for naked pointers.
2015-08-21 Dodji Seketeli <dodji@redhat.com>
Hash a class declaration the same as its definition
* src/abg-hash.cc (class_decl::hash::operator()(const class_decl&)):
If the class declaration has a definition, hash its definition
instead. Otherwise, if the class declaration has no definition,
just return a zero hash, like what we were doing before.
* src/abg-reader.cc (read_context::maybe_canonicalize_type): Do
not early canonicalize method types because most of the time, when
this function is called, the method hasn't been added to its
parent class yet. So wait until late before canonicalizing.
* src/abg-writer.cc (write_class_is_declaration_only): Do not emit
the "is-declaration-only" property if the declaration has a
definition.
(write_class_decl): If the class declaration has a definition,
emit the definition instead.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: Adjust.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: Likewise.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/test-read-write/test18.xml: Likewise.
* tests/data/test-read-write/test20.xml: Likewise.
* tests/data/test-read-write/test21.xml: Likewise.
2015-08-20 Dodji Seketeli <dodji@redhat.com>
Add a --stats to abidiff and abidw
* include/abg-dwarf-reader.h (get_show_stats)
(set_show_stats): New accessors for a new "show_stats" property of
the dwarf reader context.
* src/abg-dwarf-reader.cc: Include iostream to use std::cerr.
(dwarf_reader::show_stats_): New data member.
(dwarf_reader::dwarf_reader): Initialize it.
(dwarf_reader::show_stats)
(get_show_stats)
(set_show_stats): Define new accessors.
(dwarf_reader::die_type_map): Add const overload to this accessor.
(dwarf_reader::lookup_type_from_die_offset): Make this accessor
const.
(dwarf_reader::add_late_canonicalized_types_stats): New member
function.
(dwarf_reader::perform_late_type_canonicalizing): Emit the
statistics about late-canonicalized types if the user asked for
it.
* tools/abidiff.cc (options::show_stats): New data member.
(options::options): Initialize it.
(display_usage): Document it.
(parse_command_line): Parse the new --stats option.
(main): Create a dwarf reader context, set the show_stats to it
and then use that context to read the corpora before diffing them.
* tools/abidw.cc (options::show_stats): New data member.
(options::options): Initialize it.
(display_usage): Document it.
(parse_command_line): Parse the new --stats option.
(main): Set the show_stats to the dwarf reader context before
using it.
* doc/manuals/abidiff.rst: Update the manual.
* doc/manuals/abidw.rst: Update the manual.
2015-08-19 Dodji Seketeli <dodji@redhat.com>
Canonicalize all types that got scheduled for late canonicalization
* src/abg-dwarf-reader.cc
(read_context::canonicalize_types_scheduled): Canonicalize all
types scheduled for late canonicalization.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust.
2015-08-19 Dodji Seketeli <dodji@redhat.com>
Propagate canonical type of a class definition to its declaration
* src/abg-ir.cc: (canonicalize): Propagate the canonical type of
the type definition to its declaration.
(class_decl::set_definition_of_declaration): Likewise.
2015-08-19 Dodji Seketeli <dodji@redhat.com>
Make type_has_non_canonicalized_subtype() tighter
* include/abg-fwd.h (is_typedef, is_pointer_type)
(is_reference_type): Declare new overloads.
(peel_typedef_type): Renamed get_typedef_underlying_type into
this.
(peel_pointer_type, peel_reference_type)
(peel_typedef_pointer_or_reference_type): Declare new functions.
* src/abg-ir.cc (peel_typedef_type): Renamed
get_typedef_underlying_type into this.
(is_typedef, is_pointer_type, is_reference_type): Define new
overloads.
(peel_pointer_type, peel_reference_type)
(peel_typedef_pointer_or_reference_type): Define new functions.
(non_canonicalized_subtype_detector::has_non_canonical_type_):
Make the type of this data member be a type_base*, not a bool.
This is so that we can return the first non-canonicalized subtype
of the type we are looking at.
(non_canonicalized_subtype_detector::non_canonicalized_subtype_detector):
Adjust the data member initialization.
(non_canonicalized_subtype_detector::visit_begin): Add an overload
for function_decl*, to avoid looking into non-virtual member
functions.
In the overload for type_base*, peel typedefs, pointers and
reference of each sub-type that has no canonical type, to see if
refers to the type we are actually walking. If yes, then keep
going.
(type_has_non_canonicalized_subtype): Return the non-canonicalized
sub-type found.
* src/abg-comparison.cc (type_suppression::suppresses_diff):
Adjust for the get_typedef_underlying_type -> peel_typedef_type
renaming.
2015-08-19 Dodji Seketeli <dodji@redhat.com>
Make decl_base::get_qualified_name() work when decl context changes
* include/abg-ir.h (class decl_base): Make class scope_decl a
friend of decl_base.
(type_base::priv_): Make this protected, rather than private.
* src/abg-ir.cc (scope_decl::add_member_decl)
(scope_decl::insert_member_decl): Reset the cache of the result of
decl_base::get_qualified_name().
* tests/data/test-abidiff/test-PR18791-report0.txt: Adjust.
2015-08-18 Dodji Seketeli <dodji@redhat.com>
Bug 18844 - assert failure in abidw at abg-dwarf-reader.cc:6537
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir):
Schedule declaration-only class resolution before the class
appears as usable as to other types being built.
* tests/data/test-read-dwarf/test12-pr18844.so: Add a new binary
test input.
* tests/data/test-read-dwarf/test12-pr18844.so.abi: The reference
ABI XML output for the binary above.
* tests/data/Makefile.am: Add the new test inputs above to the
source distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the new test inputs
above to the set of input this test harness has to run over.
2015-08-18 Dodji Seketeli <dodji@redhat.com>
Fix a little glitch in the test suite
* test-read-dwarf.cc (in_out_specs): Emit the output of the test11
to output/test-read-dwarf/test11-pr18828.so.abi, not
output/test-read-dwarf/test10-pr18828.so.abi.
2015-08-18 Dodji Seketeli <dodji@redhat.com>
Escape XML property names that were not escaped before
* src/abg-writer.cc (write_namespace_decl, write_typedef_decl)
(write_var_decl): Escape the XML characters that are forbidden in
XML properties, and that are emitted as value of the 'name'
property.
2015-08-15 Dodji Seketeli <dodji@redhat.com>
Bug 18828 - Handle force-resolving of multiple declarations-only of the same type
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Accept that a
class that needs to be force-resolved might have been declared
several times. In that case, some instances of that
declaration-only class might have already been resolved (or
completed).
* tests/data/test-read-dwarf/test11-pr18828.so: New binary input.
It comes from bug https://sourceware.org/bugzilla/show_bug.cgi?id=18828.
* tests/data/test-read-dwarf/test11-pr18828.so.abi: The reference
output for the binary above.
* tests/data/Makefile.am: Add the test input files above to source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the test inputs
above to the set of input this test harness has to run over.
2015-08-15 Dodji Seketeli <dodji@redhat.com>
Avoid declaring a type several times in the same TU in the XML format
* src/abg-writer.cc (write_context::{record_type_id_as_emitted,
record_type_as_emitted, type_id_is_emitted, type_is_emitted,
clear_emitted_types_map}): New member functions.
(write_context::m_emitted_type_id_map): New data member.
(write_translation_unit): Clear the per-translation unit map of
emitted types. Do not emit a type that has already been emitted
in this translation unit.
(write_namespace_decl): Do not emit a type that has already been
emitted in this translation unit.
(write_type_decl, write_qualified_type_def)
(write_pointer_type_def, write_reference_type_def)
(write_array_type_def, write_typedef_decl, write_class_decl)
(write_type_tparameter, write_template_tparameter): Record the
type we've just written as having been written out.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Adjust as
duplicated declarations got removed.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Misc style fixes in the XMLABI writer
* src/abg-writer.cc (write_context): Align data members.
(write_translation_unit): Remove useless horizontal white spaces.
(write_decl, write_qualified_type_def, write_pointer_type_def)
(write_reference_type_def, write_array_type_def)
(write_enum_type_decl, write_typedef_decl, write_class_decl)
(write_type_tparameter): Use the *_sptr typedefs rather than the
longer form of shared_ptr<sometype> in function signatures.
(write_enum_type_decl): In this function in particular, indent a
line properly.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Fix typos in abipkgdiff
* tools/abipkgdiff.cc (display_usage): s/pompare/compare. Give a
better help message for --help.
(extract_rpm): Insert a space after the path of the package being
extracted, when emitting a verbose message.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Install the manpage for abipkgdiff
* doc/manuals/Makefile.am (section1_manpages): Add abipkgdiff.1 to
the set of manpages to be install into section 1.
2015-08-12 Dodji Seketeli <dodji@redhat.com>
Bug 18818 - abidw aborts on a class with a non-complete base class
* src/abg-dwarf-reader.cc
(read_context::decl_only_classes_to_force_defined_map_): New data
member.
(read_context::declaration_only_classes_to_force_defined): New
accessors.
(read_context::schedule_declaration_only_class_for_forced_resolution):
New member function.
(build_class_type_and_add_to_ir): If a base class is a
declaration-only class then mark it as needing to be force-defined
*if* it's still not defined at the end of the abi corpus loading.
(read_context::resolve_declaration_only_classes): If
declaration-only classes that need to force-defined are present
and not defined (when we reach the end of the ABI corpus) then
force-define them as empty classes.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so: New test
binary input file. This comes from a user binary submitted to bug
https://sourceware.org/bugzilla/show_bug.cgi?id=18818. The
original URL to the binary is
https://sourceware.org/bugzilla/attachment.cgi?id=8518.
* tests/data/test-read-dwarf/test9-pr18818-clang.so: New binary
input file. This comes from the same bug report as above. The
original URL to the binary is
https://sourceware.org/bugzilla/attachment.cgi?id=8511.
* tests/data/test-read-dwarf/test10-pr18818-gcc.so.abi: New
reference output file.
* tests/data/test-read-dwarf/test9-pr18818-clang.so.abi: Likewise.
* tests/data/Makefile.am: Add the new files above to the source
distribution.
* tests/test-read-dwarf.cc (in_out_specs): Add the test inputs
above the set of tests input this harness has to run over.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Update the abipkgdiff manual to say that .deb files are now supported
* doc/manuals/abipkgdiff.rst: Say that .deb fiel are now supported
by abipkgdiff.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Update comment about the supported formats in abipkgdiff
* tools/abipkgdiff.cc: Now that .deb packages are supported, say
it.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Make the support of RPM and DEB package formats conditional
* config.h.in: Define WITH_DEB and WITH_RPM pre-processor macros.
* configure.ac: Add --enable-{rpm,deb} switches. Check for
rpm2cpio and cpio programs, unless --disable-rpm was provided. If
they are found and if --enable-rpm=auto was provided, then
consider that --enable-rpm=yes was provided. In that case, set
the WITH_RPM macro to 1. Otherwise, undefine that macro.
Similarly, check for dpkg unless --disable-deb was provided. If
it's found and if --enable-deb=auto was provided, consider that
--enable-deb=yes was provided. In that case, set the WITH_DEB
macro to 1. Otherwise, undefine that macro. Define the
ENABLE_RPM and ENABLE_DEB conditional automake variables, if the
rpm resp. deb support is enabled. Emit a notice about the rpm and
deb features being enabled or not, at the end of the configure
process.
* tests/test-diff-pkg.cc: Include the config.h header.
(in_out_spec): Guard rpm tests by the WITH_RPM macro. Similarly,
guard deb tests by the WITH_DEB macro.
* tools/abipkgdiff.cc: Include the config.h header.
(extract_rpm): Guard this function definition with the WITH_RPM
macro.
(extract_deb): Guard this function definition with the WITH_DEB
macro.
(extract_package): Guard the handling of rpm packages with the
WITH_RPM macro and the handling of deb package with the WITH_DEB
macro. If a package not-support package format is encountered,
emit an appropriate error message and error out.
2015-08-07 Matthias Klose <doko@debian.org>
Add support for .deb files to abipkgdiff
* include/abg-tools-utils.h (file_type): Add FILE_TYPE_DEB.
* tools/abipkgdiff.cc (extract_deb): New.
(extract_package, main): Handle FILE_TYPE_DEB.
* src/abg-tools-utils.cc (operator<<): Handle FILE_TYPE_DEB.
(guess_file_type): Detect FILE_TYPE_DEB.
* tools/abidiff.cc (main): Handle FILE_TYPE_DEB.
* tools/abilint.cc (main): Handle FILE_TYPE_DEB.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a-dbgsym_2.4.0-1_amd64.ddeb:
Input debian debug info package; to be compared by the test
harness runtestdiffpkg.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64.deb:
Input debian package; to be compared by the test harness
runtestdiffpkg.
* tests/data/test-diff-pkg/libsigc++-2.0-0v5-dbgsym_2.4.1-1ubuntu2_amd64.ddeb:
Input debug info package
* tests/data/test-diff-pkg/libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64.deb:
Input debian package; to be compared by the test harness
runtestdiffpkg.
* tests/data/test-diff-pkg/libsigc++-2.0-0c2a_2.4.0-1_amd64--libsigc++-2.0-0v5_2.4.1-1ubuntu2_amd64-report-0.txt:
Reference output for the comparison of the packages above.
* tests/data/Makefile.am: Add the new files above to the source distribution.
* tests/test-diff-pkg.cc (in_out_specs): Add the input packages
above to the set of files to be compared by this test harness.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Add configure check for rm and mkdir used by abipkgdiff
* configure.ac: Add configure checks for rm and mkdir used by
abipkgdiff.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Fix a comment in configure.ac
* configure.ac: Fix a comment.
2015-08-14 Dodji Seketeli <dodji@redhat.com>
Do not remove api and website source files by accident
* doc/Makefile.am: Do not remove the entirety of the build dir of
doxygen for the apidoc and the website as these can be also the
source dirs. Rather, remove that is under the html/ sub-directory
of the build dir, as this is always generated by doxygen.
2015-08-13 Dodji Seketeli <dodji@redhat.com>
Add an abipkgdiff --fail-no-dbg command line option
* tools/abipkgdiff.cc (options::fail_if_no_debug_info): New data
member.
(options::options): Initialize it.
(display_usage): Document it.
(compare): If the user asked for it, fail if the we couldn't file
the debug info for the corpus files being compared.
2015-08-13 Dodji Seketeli <dodji@redhat.com>
Add -h and -d option shortcuts to abidw
* tools/abidw.cc (display_usage): Added a documentation string.
(parse_command_line): Parse the new -h and -d shortcuts.
* doc/manuals/abidw.rst: Update the manual.
2015-08-13 Dodji Seketeli <dodji@redhat.com>
Add a -h option shortcut to abidiff
* tools/abidiff.cc (display_usage): Add documentation for the new
switch.
(parse_command_line): Parse the -h option.
* doc/manuals/abidiff.rst: Update the manual.
2015-08-13 Dodji Seketeli <dodji@redhat.com>
Add a -h shortcup to abipkgdiff --help
* tools/abipkgdiff.cc (display_usage): Document the -h shortcut.
(parse_command_line): Parse the -h shortcut to --help.
2015-08-09 Dodji Seketeli <dodji@redhat.com>
Bug 18791 - libabigail fails to read the output of abidw
* src/abg-reader.cc (read_context::get_scope_for_node): Take an
access_specifier output parameter to set the access specifier of
the current node in its scope. Update the function to set the
access_specifier.
(read_context::build_or_get_type_decl): Adjust to set the access
specifier of the type we are building, in case it's a member type.
* tests/data/test-abidiff/test-PR18791-v{0,1}.so.abi: New test input files.
* tests/data/test-abidiff/test-PR18791-report0.txt: New test
output reference.
* tests/data/Makefile.am: Add the new test material to the source
distribution.
* tests/test-abidiff.cc (specs): Add the new test inputs to the set of
input files this test harness has to run over.
2015-08-09 Dodji Seketeli <dodji@redhat.com>
Fix a thinko in language support de-serialization
* src/abg-ir.cc (string_to_translation_unit_language): Fix
thinko. What was I thinking ...
2015-08-06 Dodji Seketeli <dodji@redhat.com>
Add --no-added-syms to abipkgdiff
* tools/abipkgdiff.cc (options::show_added_syms): New data member.
(options::options): Initialize it.
(parse_command_line): Parse the new --no-added-syms option and set
the options::show_added_syms flag accordingly.
(display_usage): Add a help string for the new option.
(set_diff_context_from_opts): Set the diff context according to
the state of the new options::show_added_syms flag.
* doc/manuals/abipkgdiff.rst: Add manual entry for the new
--no-added-syms options.
* tests/data/test-diff-pkg/test-rpm-report-5.txt: New test
reference input file.
* tests/data/Makefile.am: Add the new file above to source
distribution.
* tests/test-diff-pkg.cc (InOutSpec::prog_options): New data
member.
(in_out_specs): Adjust. Add a new input to run the test again
with --no-added-syms.
(main): Adjust to pass the program options contained in
InOutSpec::prog_options to abipkgdiff.
fixup! Add --no-added-syms to abipkgdiff
2015-08-06 Dodji Seketeli <dodji@redhat.com>
Update diff stats when added symbols are removed from change report
* include/abg-comparison.h (diff_context_wptr)
(corpus_diff::diff_stats_sptr): New typedefs.
(corpus_diff::diff_stats::diff_stats): Make this constructor take
a diff_context_sptr. Make the default constructor private.
* src/abg-comparison.cc (corpus_diff::diff_stats::priv::ctxt_):
New data member. This is a weak pointer to a diff_context.
(corpus_diff::diff_stats::priv::priv): Take a diff_context_sptr
and initialize the weak pointer ctxt_ to it.
(corpus_diff::diff_stats::priv::ctxt): New accessor to the
diff_context hold by the diff_stats.
(corpus_diff::diff_stats::{num_removed_func_filtered_out,
num_added_func_filtered_out, num_removed_vars_filtered_out,
num_added_vars_filtered_out, num_removed_func_syms_filtered_out,
num_added_func_syms_filtered_out,
num_removed_var_syms_filtered_out,
num_added_var_syms_filtered_out}): If the user asked for the added
[or removed] variables/functions/symbols to be ignored, the
accessors for the number of filtered added/removed variables/functions/symbols
return the total number of added/removed
variables/functions/symbols; that is, say that *all* added/removed
variables/functions/symbols got filtered out.
(corpus_diff::priv::diff_stats_): Turn this data member into a
[shared] pointer to diff_stats.
(corpus_diff::priv::filters_and_suppr_applied_): Remove this data
member. Now that diff_stats_ is a pointer, we don't need this
boolean anymore.
(corpus_diff::apply_filters_and_suppressions_before_reporting):
Adjust to the fact that filters_and_suppr_applied_ is gone, and
that diff_stats_ is now a pointer.
(corpus_diff::report): Control un-referenced added symbols
reporting with
diff_context::show_added_symbols_unreferenced_by_debug_info()
2015-07-31 Dodji Seketeli <dodji@redhat.com>
Make applying supp specs through pointer access look through typedefs
* include/abg-comparison.h (type_suppression::suppresses_type):
Declare new member function.
(get_typedef_diff_underlying_type_diff): Declare new function.
* include/abg-fwd.h (get_typedef_underlying_type): Likewise.
* src/abg-comparison.cc (type_suppression::suppresses_type):
Define new member function.
(get_typedef_diff_underlying_type_diff): Define new function.
(type_suppression::suppresses_diff): After looking through the
different kind of access methods, use the new
type_suppression::suppresses_type(), rather than doing lots of
stuff ourselves here. But then, if the suppression doesn't apply
to the subjects of the diff, look through typedefs and try to
apply the suppression again.
* src/abg-ir.cc (get_typedef_underlying_type): Define new
function.
* tests/data/test-diff-suppr/libtest25-typedef-v{0,1}.so: New
binary test input files.
* tests/data/test-diff-suppr/test25-typedef-v{0,1}.c: Source code
for the binary test input files above.
* tests/data/test-diff-suppr/test25-typedef-report-{0, 1}.txt: New test
input files.
* tests/data/test-diff-suppr/test25-typedef-suppr-0.txt: New test
input file.
* tests/data/Makefile.am: Add the new test material to the source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the test inputs
above to the set of test inputs this harness has to run over.
2015-07-24 Dodji Seketeli <dodji@redhat.com>
Make abipkgdiff erase the *parent* directory of temporary files
* tools/abipkgdiff.cc
(erase_created_temporary_directories_parent): New static function.
(compare): After comparison, erase the temporary parent directory
as well.
2015-07-24 Dodji Seketeli <dodji@redhat.com>
Make the name of the removed variable section be consistent
* src/abg-comparison.cc (corpus_diff::report): Introduce the
section of removed variables with the string "Removed variable",
rather than with the string "Deleted variable".
* tests/data/test-abicompat/test2-var-removed-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test18-suppr-removed-var-report-5.txt: Likewise.
2015-07-24 Dodji Seketeli <dodji@redhat.com>
Consider default symbol versions when computing added/removed fns/vars
* include/abg-corpus.h (corpus::{lookup_function_symbol,
lookup_variable_symbol}): Take a elf_symbol::version object,
rather than a string representing the version. Add an overload
that takes an elf_symbol.
* src/abg-corpus.cc (find_symbol_by_version): New static function.
(corpus::{lookup_function_symbol, lookup_variable_symbol}): Take a
elf_symbol::version object, rather than a string representing the
version. Add an overload that takes an elf_symbol. If the looked
up symbol has no version and if the corpus contains a symbol with
the same name and with a default version, then return that latter
symbol if the corpus doesn't contain a symbol with the same name
and empty version.
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Adjust.
(corpus_diff::priv::ensure_lookup_tables_populated): Before
deciding that a symbol has been added, if the symbol has a default
version, make sure no symbol with the same name and without
version was present in the former corpus. Similarly, before
deciding that a symbol has been removed, if the symbol has no
version, make sure the latter corpus has no symbol with the same
name and with a default version.
* tests/data/test-diff-dwarf/test12-report.txt: Adjust. The
function should not be considered as added, because its symbol
(and version) was already present in the former DSO.
2015-07-24 Dodji Seketeli <dodji@redhat.com>
Fix a thinko in removed variables detection
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Once we have
computed a set of potentially deleted variables that turned out to
contain variables that were actually *NOT* deleted, really take
these into account by removing these false positives from the set
of deleted *variables*. We were trying to delete these from the
set deleted *functions*; woops, I guess this was a copy & paste
error.
2015-07-24 Dodji Seketeli <dodji@redhat.com>
Fix logic of type_has_non_canonicalized_subtype()
* src/abg-ir.cc (type_has_non_canonicalized_subtype): Once the
type has been traversed, just test if the visitor has accumulated
the 'has_non_canonical_type' property.
2015-07-24 Dodji Seketeli <dodji@redhat.com>
Fix style issues
* include/abg-ir.h (struct ir_node_visitor): Fix the wording of
the comment of this type.
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Fix the
filling of the text of the comment of the code that chooses to
perform early canonicalizing.
2015-07-24 Dodji Seketeli <dodji@redhat.com>
Adding member type doesn't reset declaration-only-ness of a class
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir):
Adding a new member type shouldn't remove the
declaration-only-ness of the class.
2015-07-22 Dodji Seketeli <dodji@redhat.com>
Extract all packages for a given run of abipkgdiff under the same temp dir
* tools/abipkgdiff.cc (package::{<all data members>}): Make the
data members be private. Make their names end with an underscore.
(package::extracted_package_parent_dir_path): Remove.
(package::extracted_package_dir_path): Rename into
package::extracted_dir_path_.
(package::extracted_packages_parent_dir): New static member
function, accessor.
(package::package): Adjust to the new names of the data members.
Call the new package::extracted_package_parent_dir() static member
function to initial the package::extracted_dir_path_ data member.
(package::{path, extracted_dir_path, type, is_debug,
path_elf_file_sptr_map, debug_info_package}): New accessors for
the data members.
(package::{erase_extraction_directory,
erase_extraction_directories}): Adjust.
(erase_created_temporary_directories)
(create_maps_of_package_content)
(extract_package_and_map_its_content, prepare_packages, compare)
(main): Adjust.
2015-07-22 Dodji Seketeli <dodji@redhat.com>
Add a --keep-tmp-files option to abipkgidff
* tools/abipkgdiff.cc (options::keep_tmp_files): New data member.
(options::options): Initialize it.
(display_usage): Display a usage string for the new
--keep-tmp-files option.
(parse_command_line): Parse the new --keep-tmp-files option.
(compare): Do not erase temporary directories if the users asked so.
* doc/manuals/abipkgdiff.rst: Document the new --keep-tmp-files
options.
2015-07-21 Dodji Seketeli <dodji@redhat.com>
Show linkage names in abipkgdiff output
* doc/manuals/abipkgdiff.rst: Document the new --no-linkage-name
options.
* tools/abipkgdiff.cc (options::show_linkage_names): New data
member.
(options::options): Initialize it.
(display_usage): Display a usage string for --no-linkage-name.
(parse_command_line): Parse the --no-linkage-name option.
(set_diff_context_from_opts): Set the diff context accordingly.
* tests/data/test-diff-pkg/test-rpm-report-0.txt: Adjust.
2015-07-21 Dodji Seketeli <dodji@redhat.com>
Add --no-added-binaries to abipkgdiff
* tools/abipkgdiff.cc (options::show_added_binaries): New data
member.
(options::options): Initialize it.
(display_usage): Add a help string for --no-added-binaries.
(parse_command_line): Parse the new --no-added-binaries option.
(compare): Do not show added binaries if the user doesn't want to.
* doc/manuals/abipkgdiff.rst: Document the new --no-added-binaries
option.
2015-07-21 Dodji Seketeli <dodji@redhat.com>
make abipkgdiff return a proper exit code
* tools/abipkgdiff.cc (compare): Return an instance
abigail::tools_utils::abidiff_status, just like what we do in
abidiff.
* doc/manuals/abipkgdiff.rst: Document the new exit code.
2015-07-21 Dodji Seketeli <dodji@redhat.com>
Fix logic of determining if changes happened in abidiff
* tools/abidiff.cc (main): Simplify the logic when determining if
the comparison between two corpora yields worthwhile changes.
2015-07-21 Dodji Seketeli <dodji@redhat.com>
Add a new corpus_diff::has_net_changes() entry point
* include/abg-comparison.h (corpus_diff::has_net_changes): Declare
new member function.
* src/abg-comparison.cc (corpus_diff::has_net_changes): Define it.
2015-07-20 Dodji Seketeli <dodji@redhat.com>
Fix type synthesis to fix abicompat weak mode
* include/abg-fwd.h
(synthesize_type_from_translation_unit): Declare new function.
(synthesize_function_type_from_translation_unit): Make the
translation_unit parameter non-const because the function needs to
bind the life time of the synthesized function to the life time of
the translation unit. Make this function be a friend of
abigail::ir::translation_unit.
(synthesize_function_type_from_translation_unit):
* src/abg-ir.cc (translation_unit::priv::synthesized_types_): New
data member.
(synthesize_type_from_translation_unit): Define new function.
(synthesize_function_type_from_translation_unit): Make the
translation_unit parameter non-const. If the return is void, then
take that in account carefuly. Rather than just looking up the
type of parameters and return value, synthesize them too,
especially when they are qualified types. Bind the life time of
the synthesized function type to the lifetime of the translation
unit.
* tests/data/test-abicompat/test7-fn-changed-report-1.txt: New
test reference output.
* tests/test-abicompat.cc (in_out_spec): Run the harness on the
exisiting test7-fn-changed-app and libtest7-fn-changed-libapp-v1
but in weak mode this time.
2015-07-20 Dodji Seketeli <dodji@redhat.com>
Clean up the output of abicompat weak mode
* tools/abicompat.cc (perform_compat_check_in_weak_mode): Remove
disgracious vertical spaces in the wording.
* tests/data/test-abicompat/test5-fn-changed-report-0.txt: Adjust.
* tests/data/test-abicompat/test6-var-changed-report-0.txt: Adjust.
2015-07-20 Sinny Kumari <sinny@redhat.com>
Display --suppressions|--suppr option in help usage
* tools/abipkgdiff.cc (display_usage): Print
--suppressions|--suppr <path> option in help usage
2015-07-20 Dodji Seketeli <dodji@redhat.com>
Fix computing the set of exported functions and varible symbols
* src/abg-ir.cc (elf_symbol::get_name_and_version_from_id): Always
set the version and name of the symbol.
* src/abg-corpus.cc
(corpus::exported_decls_builder::{keep_wrt_id_of_fns_to_keep,
keep_wrt_id_of_vars_to_keep}): Reset the symbol name *and* version
before passing it. This is redundant with the fix in
elf_symbol::get_name_and_version_from_id() that always set the
symbol name and version now, but I felt it makes it easier to
understand the fix overall.
* tests/data/test-abicompat/libtest7-fn-changed-libapp-v{0,1}.so:
New test input binaries.
* tests/data/test-abicompat/test7-fn-changed-app: Likewise.
* tests/data/test-abicompat/test7-fn-changed-{app, libapp-v0,
libapp-v1}.c: Source code of the binary test inputs above.
* * tests/data/test-abicompat/test7-fn-changed-{libapp-v0,
libapp-v1}.h: Likewise.
* tests/data/test-abicompat/test7-fn-changed-report-0.txt: Test
input.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-abicompat.cc (int_out_specs): Add the test inputs
above to the set of inputs this test harness has to run over.
2015-07-20 Dodji Seketeli <dodji@redhat.com>
Fix the wording of description of abipkgdiff.cc again
* tools/abipkgdiff.cc: Fix the wording again.
2015-07-20 Dodji Seketeli <dodji@redhat.com>
Remove use of tmpnam from abilint
* include/abg-tools-utils.h (abigail::tools_utils::temp_file):
Declare new type.
(abigail::tools_utils::temp_file_sptr): New typedef.
* src/abg-tools-utils.cc (temp_file::priv): Define new type.
(temp_file::{temp_file, is_good, get_path, get_stream, create}):
Define new member functions.
* tools/abilint.cc (main): Do not use tmpnam anymore. Use the new
abigail::tools_utils::temp_file type instead.
2015-07-20 Dodji Seketeli <dodji@redhat.com>
Try to avoid a race condition when abipkgdiff extracts packages.
* include/abg-tools-utils.h (get_random_number)
(get_random_number_as_string): Declare new functions.
* src/abg-tools-utils.cc (get_random_number)
(get_random_number_as_string): Define them.
* tools/abipkgdiff.cc
(package::extracted_package_parent_dir_path): New data member.
(package::package): Initialize
package::extracted_package_parent_dir_path to
<tmpdir>/<randomname>, with randomname being a random number
represented as a string.
(extract_rpm): Make sure to create a hierarchy of directories, not
just a directory.
2015-07-19 Dodji Seketeli <dodji@redhat.com>
Fix the wording of the description of the abipkgdiff.cc file
* tools/abipkgdiff.cc: Fix the wording of the description.
2015-07-19 Dodji Seketeli <dodji@redhat.com>
Fix the --suppressions manual doc for abidiff
* doc/manuals/abidiff.rst: Talk about the --suppr shortcut of the
--suppressions option.
2015-07-19 Dodji Seketeli <dodji@redhat.com>
On changed fn, show symbol info when name is different from linkage name in C
* include/abg-ir.h (translation_unit::language): New enum type.
(translation_unit::{get_language, set_language}): Declare new
accessors.
(translation_unit_language_to_string)
(string_to_translation_unit_language, is_c_language)
(is_cplus_plus_language): Declare new functions.
* src/abg-ir.cc (translation_unit::priv::language_): New data
member.
(translation_unit::priv::language_): Initialize it.
(translation_unit::{set_language, get_language}): Define new
member functions.
(translation_unit_language_to_string)
(string_to_translation_unit_language, is_c_language)
(is_cplus_plus_language): Define new functions.
* src/abg-dwarf-reader.cc (dwarf_language_to_tu_language): New
static function.
(build_translation_unit_and_add_to_ir): Read the language of the
translation unit.
* src/abg-comparison.cc (corpus_diff::report): When reporting a
change in a function sub-type, if we are in C language translation
unit, if the function name is different from its linkage name,
even if the symbol doesn't have any alias, show symbol
information.
* src/abg-reader.cc (read_translation_unit_from_input): Read the
'language' property of the translation unit, if present.
* src/abg-writer.cc (write_translation_unit): Write the 'language'
property to the translation unit, if present.
* tests/data/test-read-dwarf/test0.abi: Adjust for the new
'language' property of the 'abi-instr' element.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
Likewise.
2015-07-19 Dodji Seketeli <dodji@redhat.com>
Add --suppressions to abipkgdiff
* tools/abipkgdiff.cc (options::suppressions): New data member.
(set_diff_context_from_opts): Set the suppression specifications
provided by the user to the diff context.
(parse_command_line): Parse the --suppressions and --suppr command
line options.
* doc/manuals/abipkgdiff.rst: Document the --suppressions and
--suppr options.
2015-07-18 Dodji Seketeli <dodji@redhat.com>
Support file_name_regexp and soname_regexp in supp-specs
* include/abg-comparison.h (suppression_base::priv_): Make this
pimpl member protected.
(suppression_base::set_file_name_regex_str)
(get_file_name_regex_str, get_soname_regex_str)
(set_soname_regex_str): Declare new accessors.
(function_suppression::{suppresses_function,
suppresses_function_symbol}): Take a diff_context_sptr.
(variable_suppression::{suppresses_variable,
suppresses_variable_symbol}): Take a diff_context_sptr.
* src/abg-comparison.cc
(suppression_base::priv::{file_name_regex_str_, file_name_regex_,
soname_regex_str_, soname_regex_}): Define new data members.
(suppression_base::priv::get_file_name_regex_str)
(get_soname_regex_str): Define new member functions.
(suppression_base::set_file_name_regex_str)
(get_file_name_regex_str, get_soname_regex_str)
(set_soname_regex_str): Define new accessors.
(type_suppression::suppresses_diff): Evaluate file_name_regexp and
soname_regexp.
(read_type_suppression): Fix the reading of the "label" property.
Read the file_name_regexp and soname_regexp properties.
(function_suppression::{suppresses_function,
suppresses_function_symbol): Take a diff_context_sptr parameter.
Evaluate file_name_regexp and soname_regexp properties.
(function_suppression::suppresses_diff): Adjust for the api change
of function_suppression::suppresses_function().
(read_function_suppression): Read the file_name_regexp and
soname_regexp properties.
(variable_suppression::suppresses_variable): Take a
diff_context_sptr parameter and evaluate file_name_regexp and
soname_regexp properties.
(variable_suppression::suppresses_variable_symbol): Likewise.
(variable_suppression::suppresses_diff): Adjust for the api change
of variable_suppression::suppresses_variable().
(read_variable_suppression): Read the file_name_regexp and
soname_regexp properties.
(function_is_suppressed, variable_is_suppressed): Take a
diff_context_sptr parameter.
(corpus_diff::priv::apply_suppressions_to_added_removed_fns_vars):
Adjust.
* doc/manuals/libabigail-concepts.rst: Document file_name_regexp
and soname_regexp in the manual.
* tests/data/test-diff-suppr/libtest24-soname-v{0,1}.so: New test
binary input files.
* tests/data/test-diff-suppr/test24-soname-report-{0,4}.txt: New
test input files.
* tests/data/test-diff-suppr/test24-soname-suppr-{0,4}.txt:
Likewise.
* tests/data/test-diff-suppr/test24-soname-v{0,1}.cc: Source code
of the binary test input files above.
* tests/data/Makefile.am: Add the new test material above to
source distribution.
* tests/test-diff-suppr.cc (in_out_spec): Add the new test inputs
to the set of tests this harness has to run over.
2015-07-18 Dodji Seketeli <dodji@redhat.com>
Fix possible crash in suppression evaluation
* src/abg-comparison.cc (type_suppression::suppresses_diff): When
evaluating the reach_kind property, do not crash on diff nodes
that are pointer_diff or reference_diff to something else but a
type diff.
2015-07-17 Dodji Seketeli <dodji@redhat.com>
Fix '--' being rendered as '-' in html manuals
* doc/manuals/abicompat.rst: Quote options as verbatim.
* doc/manuals/abidiff.rst: Likewise.
* doc/manuals/abidw.rst: Likewise.
* doc/manuals/abilint.rst: Likewise.
* doc/manuals/abipkgdiff.rst: Likewise.
2015-07-17 Dodji Seketeli <dodji@redhat.com>
Fix the --verbose option
* tools/abipkgdiff.cc (compare): In the elf_file overload, do not
emit an error message when a binary could not be analyzed unless
--verbose was provided.
2015-07-16 Dodji Seketeli <dodji@redhat.com>
Cleanup the output for added/removed binaries
* tools/abipkgdiff.cc (compare): In the overload for packages,
indent the content of the "Removed binaries" and "Added binaries"
paragraphs.
2015-07-16 Dodji Seketeli <dodji@redhat.com>
Avoid redundant diff report messages by default.
* tools/abipkgdiff.cc (options::show_redundant_changes): New data
member.
(options::options): Initialize it.
(display_usage): Add a help string for the --redundant command
Line option.
(set_diff_context_from_opts): New static function.
(compare): Take the options variable. Set the diff context from
the options, especially if we should show redundant changes or
not. Use that diff context when comparing ABIs.
(parse_command_line): Parse the new --redundant command line
switch.
* doc/manuals/abipkgdiff.rst: Document the new --redundant option.
2015-07-16 Dodji Seketeli <dodji@redhat.com>
Support comparing only shared libraries
* tools/abipkgdiff.cc (options::compare_dso_only): New data
member.
(options::options): Initialize it.
(display_usage): Display a little help string for it.
(create_maps_of_package_content): Take the option variable. Do
not compare non-dso files if the --dso-only option was provided.
(extract_package_and_map_its_content, prepare_packages, compare):
Take the option variable.
(parse_command_line): Parse the new --dso-only option.
* doc/manuals/abipkgdiff.rst: Add documentation for the new
--dso-only option.
2015-07-15 Dodji Seketeli <dodji@redhat.com>
Comment functions and types of abipkgdiff
* src/abg-dwarf-reader.cc (get_soname_of_elf_file): Better wording
of the apidoc of this function.
* tools/abipkgdiff.cc (verbose, elf_file_paths): Add apidoc for
these global variables.
(struct options, ): Add apidoc for these types.
(options::{erase_extraction_directory,
erase_extraction_directories}, display_usage, extract_rpm)
(erase_created_temporary_directories, extract_package)
(file_tree_walker_callback_fn, compare)
(create_maps_of_package_content)
(extract_package_and_map_its_content, prepare_packages, compare)
(parse_command_line): Add apidoc for these functions.
2015-07-16 Sinny Kumari <sinny@redhat.com>
Add regression tests for abipkgdiff tool
* tests/Makefile.am: Build new runtestdiffpkg regression test
* tests/data/Makefile.am: Add new test files to source
* tests/data/test-diff-pkg/dbus-glib-0.104-3.fc23.x86_64.rpm:
Test data for abipkgdiff tool
* tests/data/test-diff-pkg/dbus-glib-0.80-3.fc12.x86_64.rpm: Likewise
* tests/data/test-diff-pkg/dbus-glib-debuginfo-0.104-3.fc23.x86_64.rpm:
Likewise
* tests/data/test-diff-pkg/dbus-glib-debuginfo-0.80-3.fc12.x86_64.rpm:
Likewise
* tests/data/test-diff-pkg/test-rpm-report-0.txt: Expected test output
* tests/data/test-diff-pkg/test-rpm-report-1.txt: Likewise
* tests/data/test-diff-pkg/test-rpm-report-2.txt: Likewise
* tests/data/test-diff-pkg/test-rpm-report-3.txt: Likewise
* tests/data/test-diff-pkg/test-rpm-report-4.txt: Likewise
* tests/test-diff-pkg.cc: New file
2015-07-15 Dodji Seketeli <dodji@redhat.com>
Add a manual for abipkgidiff
* doc/manuals/abipkgdiff.rst: New manual file.
* doc/manuals/libabigail-tools.rst: Refer to the manual for
abipkgdiff.
* doc/manuals/Makefile.am: Add the new manual file to source
distribution.
* doc/manuals/conf.py: Add the manual for abipkgdiff to section 1.
2015-07-15 Dodji Seketeli <dodji@redhat.com>
Comment functions and types of abipkgdiff
* src/abg-dwarf-reader.cc (get_soname_of_elf_file): Better wording
of the apidoc of this function.
* tools/abipkgdiff.cc (verbose, elf_file_paths): Add apidoc for
these global variables.
(struct options, ): Add apidoc for these types.
(options::{erase_extraction_directory,
erase_extraction_directories}, display_usage, extract_rpm)
(erase_created_temporary_directories, extract_package)
(file_tree_walker_callback_fn, compare)
(create_maps_of_package_content)
(extract_package_and_map_its_content, prepare_packages, compare)
(parse_command_line): Add apidoc for these functions.
2015-07-15 Dodji Seketeli <dodji@redhat.com>
Various style fixes
* abipkgdiff.cc (get_soname_of_elf_file): Fix spacing.
* tools/abipkgdiff.cc (elf_file_paths): Make this global variable
static.
(extract_rpm): Rename parameter pkg_path name into package_path.
2015-07-15 Dodji Seketeli <dodji@redhat.com>
Remove the last direct fiddling with ELF from abipkgdiff.cc
* abg-dwarf-reader.h (enum elf_type): Move this declaration here
from abipkgdiff.cc to here.
(get_type_of_elf_file): Declare this new function.
(get_soname_from_elf): Change this to take a path to the elf file
rather than a Elf* handler. So now to use this, the user doesn't
have to get her hand dirty with elfutils.
* src/abg-dwarf-reader.cc (get_soname_from_elf): Change this to
take a path to the elf file rather than a Elf* handler.
(elf_file_type): Move this static function here, from
abipkgdiff.cc.
(get_type_of_elf_file): New function. This has been factorized
out of create_maps_of_package_content() in abipkgdiff.cc.
* tools/abipkgdiff.cc (class elf_file): Changed struct elf_file
into this. Make the default constructor private.
(elf_file::elf_file): Change the constructor to just take the path
to the elf_file. The base name, soname and elf file type are now
computed from the path file, in the constructor. This makes
instantiation much much easier from the point of view of the user
of the type.
(struct abi_diff): Renamed struct abi_changes into this.
(abi_diff::has_changes): Define new member function.
(abi_diffs): Remove this global variable.
(package::package): Remove the elf file type from the set of
parameters of this constructor. Rather, compute that elf file
type from the path to the elf file, in the constructor. Again,
this eases the use of the type.
(elf_file_type): Remove this from here, as it got moved to
abg-dwarf-reader.cc.
(compare): In the elf_file overload, return true if the comparison
yields ABI changes.
(create_maps_of_package_content): Do not fiddle with elfutils
stuff here. Rather, just instantiate elf_file and the analyzing
of the file magically happens.
(compare): Make the package overload take an abi_diff as output
parameter, rather than populating a global variable in return.
(compare): Add an other overload for package that doesn't take the
abi_diff as output parameter and write it in terms of the previous
one.
(main): Adjust as the instantiation of package is now simpler.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Add a --verbose option to abipkgdiff
* tools/abipkgdiff.cc (verbose): Add a new global variable.
(package::erase_extraction_directory, extract_rpm, compare)
(create_maps_of_package_content): Emit verbose information.
(parse_command_line): Parse the --verbose option.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Use the library to implement ABI comparison in abipkgdiff
* tools/abipkgdiff.cc (compare): In the overload for elf_file, use
abigail::comparison::compute_diff() to compare the ABI of two
corpora. The corpora themselves is read using
abigail::dwarf_reader::read_corpus_from_elf(). This cleans up the
output of the tool because nothing is emitted to standard output
if the two ABI corpora compares equal.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Fix several string passing issues in abipkgdiff.cc
* tools/abipkgdiff.cc (elf_file::elf_file): Pass the strings by
reference. Also, change the order of the parameters; all the
strings are passed first, then the elf_type is passed last.
(package::package): Likewise, pass the strings by reference, not
by value.
(create_maps_of_package_content): Adjust for the change in
parameters order of elf_file::elf_file.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Only try to compare DSOs or executable binaries in abipkgdiff
* tools/abipkgdiff.cc (compare): In the overload for packages,
only compare binaries that are DSO or executable.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Avoid flushing the output stream in abipkgdiff.cc
* tools/abipkgdiff.cc (extract_package)
(create_maps_of_package_content, compare, main): Avoid flushing
the output stream arbitrarily.
2015-07-08 Sinny Kumari <sinny@redhat.com>
Move get_soname() function to abg-dwarf-reader.h/cc
* include/abg-dwarf-reader.h (get_soname_from_elf): Declare
new function
* src/abg-dwarf-reader.cc (get_soname_from_elf): Define new
function
* tools/abipkgdiff.cc (get_soname): Remove function
(pkg_diff): Call get_soname_from_elf() instead of get_soname()
2015-07-07 Dodji Seketeli <dodji@redhat.com>
Important organizational changes in abipkgdiff.cc
* Avoid using shortened names when the line is not too long.
* Use shared_ptr when possible.
* When a function parameter is not meant to be nil, do not pass it
as a pointer; rather, pass it as a reference.
* Avoid doing things that can "fail" in a destructor; e.g, spawning
a process. Also, it's not common practise to cleanup a resource in a
type destructor, when that resource has not been created in one of the
member functions of the type. It eases maintenance when resource
creation and cleanup is performed at the same logical level.
* tools/abipkgdiff.cc (option::package{1,2}): Rename
option::pkg{1,2} into this, to increase legibility.
(option::debug_package{1,2}): Likewise, rename
option::debug_pkg{1,2} into this.
(elf_file::~elf_file): Do not "delete this" in a destructor. This
leads to double free. It's when someone invokes the "delete"
operator on a pointer to the object that the destructor of the
object is executed automatically; so if in the destructor the
delete operator is called again, bad things are going to happen.
As the destructor is now empty, remove it altogether.
(elf_file_sptr): New typedef for shared_ptr<elf_file>.
(package::path): Rename package::pkg_path into this, for better
legibility.
(package::extracted_package_dir_path): Rename
package::extracted_pkg_dir_path into this.
(package::type): Rename package::pkg_type into this.
(package::is_debug_info): Rename package::is_debuginfo_pkg into
this.
(package::path_elf_file_sptr_map): Rename
package::dir_elf_files_map into this because this is a map of
path -> elf_file_sptr. Also, now the value of the map element is
a elf_file_sptr, no more an elf_file*.
(package::debug_info_package): Rename package::debuginfo_pkg into
this.
(package::package): Adjust for the changes above.
(package::{erase_extraction_directory,
erase_extraction_directories}): New member functions.
(elf_file_paths): Renamed dir_elf_files_path into this.
(erase_created_temporary_directories)
(create_maps_of_package_content)
(extract_package_and_map_its_content, prepare_packages): New
static functions.
(get_soname, elf_file_type, extract_rpm): Make this static.
(extract_package): Take a const package& rather than a
package_sptr to express that the function really expects a non-nil
object by reference (not by copy) and that the object won't be
modified. Using a reference removes the possibility that the
pointer could be nil, causing crashes in the code where
parameter->something was used. Now only parameter.something can
be used, so no crash possible there. This is more solid code.
(file_tree_walker_callback_fn): Rename callback() into this. It
makes the code more legible and kind of 'self-documented'. At
least you get the hint that this is a callback function for some
file tree walking (ftw) function. Adjust for the relevant names
renaming above.
(compare): Rename compute_abidiff into this; again, this increases
legibility; at least at the point of use of this function. Rename
compare_package() into a an overload of compare() as well.
compare_package() used to take a vector of packages. It was hard
to guess by reading the signature of the function, which element
of the vector is expected to be the first vector of the
comparison, which one is to be the second, etc. Now, this
function takes two packages, named first_package and
second_package. That is more "typed"; that is, the signature is
more meaningful. Greater legibility, hopefully. And in the body
of the function, the debug information packages are now accessed
using the package::debug_info_package data member. Again, this is
less surprising, I believe. Also, explicitly erase the temporary
files that were created during this comparison. All this
simplifies the logic of this function, hopefully.
(parse_command_line): Make this static. Add new --d1 and --d2
command line switches that are shortcuts of --debug-info-pkg1 and
--debug-info-pkg2. Adjust this function for the relevant name
changes above. Make lines be shorter than 80 characters.
(main): Do not create any vector of parameters anymore as the
compare_packages() function don't take any vector of parameter
anymore. Just instantiate first_package and second_package now.
Adjust for the relevant name changes above. This hopefully
simplifies the logic of this function.
2015-07-06 Dodji Seketeli <dodji@redhat.com>
Wording fixes in abipkgdiff.cc
* tools/abipkgdiff.cc (extract_package): Renamed extract_pkg into
this because shortening 'package' into 'pkg' provides no
legibility improvement.
(compare_packages): Renamed pkg_diff() into this, so that the name
of the function starts with a verb, and the shortened 'pkg' word
is renamed back to the 'package' word. This way, the code almost
reads like normal English sentences with verbs and complement,
thus enhancing legibility and easing latter maintenance.
(main): Adjust for the changes above.
2015-07-06 Dodji Seketeli <dodji@redhat.com>
Re-indent tools/abipkgdiff.cc
* tools/abipkgdiff.cc: Re-indent the file properly and fix some
white spacing here and there.
2015-07-06 Dodji Seketeli <dodji@redhat.com>
Some slight typo and wording fixes in abipkgdiff
* tools/abipkgdiff.cc (display_usage): Fixed the typo in
'bi-pacakge.' Also, refer to 'package', not to 'bi-package' that
is surprising to the user at first.
(compute_abidiff): Shorten the size of the introductory line.
2015-07-03 Dodji Seketeli <dodji@redhat.com>
Remove names of unused variables in callback()
* tools/abipkgdiff.cc (callback): Remove the name of parameters st
and flag.
2015-07-03 Dodji Seketeli <dodji@redhat.com>
Remove useless const from the declaration of extract_rpm()
* tools/abipkgdiff.cc (extract_rpm): Remove useless const qualifier.
2015-07-03 Dodji Seketeli <dodji@redhat.com>
End all branches of get_soname() finish with a return statement
* tools/abipkgdiff.cc (get_soname): Have just one return statement
at the end of this function.
2015-07-03 Dodji Seketeli <dodji@redhat.com>
Fix abipkgdiff compilation issues
* tools/abipkgdiff.cc (elf_file::elf_file): Initialize data member
in the same order as they were declared.
(package::package): Likewise.
2015-06-19 Sinny Kumari <sinny@redhat.com>
Exclude processing symlink, display removed/added binaries between two packages
* tools/abipkgdiff.cc (abi_changes): Declare new struct
(callback): Exclude symbloic link file for durther processing
(compute_abidiff): Consider SONAME if exists as key in map instead
of binary name, else binary as key. Also, print if removed/added
binaries exist between packages
2015-06-09 Sinny Kumari <sinny@redhat.com>
Stdout ABI changes if same binary found in both package
* tools/abipkgdiff.cc (compute_abidiff): New function
tools/abipkgdiff.cc (pkg_diff): Iterate through list of binaries
in both package directory and call compute_diff function if
same binary found in both file.
tools/abipkgdiff.cc (main): Also consider debug-info directories
avilable in debu-info packages.
2015-06-02 Sinny Kumari <sinny@redhat.com>
Save ELF files, their type and SONAME if exist for extracted packages
* tools/abipkgdiff.cc (elf_type): Declare new enum
(elf_file): Declare new struct
(package): Add member variable dir_elf_files_map
(get_soname): Define new function
(elf_file_type): Define new function
(extract_rpm): Iterate over extracted directory files
and filter ELF binary files along with their information
like name, soname, elf_type and save in dir_elf_files_map
2015-05-26 Sinny Kumari <sinny@redhat.com>
Extract packages(RPMs) into temporary directories for further processing
* tools/abipkgdiff.cc (struct package): Declare new struct
(package_sptr): Declare shared_ptr for struct package
(extract_rpm): Define new fuction to extract rpm package
(extract_pkg): Define new function to extract pacakge
(pkg_diff): Define new function to get ABI diff between
two packages
(main): Create new object of type pacakge for each binary
and debuginfo pacakge passed in commandline options
2015-05-21 Sinny Kumari <sinny@redhat.com>
Guess RPM file type
* include/abg-tools-utils.h (file_type): Added member
FILE_TYPE_RPM and FILE_TYPE_SRPM
(operator<<): New function declaration.
* src/abg-tools-utils.cc (file_type): Detect RPM and
SRPM file type
(operator<<): New function definition
* tools/abidiff.cc (main): Check for RPM and SRPM
file type as well.
* tools/abilint.cci (main): Check for RPM and SRPM file
type as well.
* tools/abipkgdiff.cc (main): Check whether input files
to abipkgdiff are valid RPM files or not.
2015-05-19 Sinny Kumari <sinny@redhat.com>
Initial skeleton of abipkgdiff tool
* tools/Makefile.am: Include abipkgdiff.cc in compilation and
generate abipkgdiff binary.
* tools/abipkgdiff.cc: New file
2015-07-16 Dodji Seketeli <dodji@redhat.com>
Support reading binaries that do not have a symbol table
* src/abg-dwarf-reader.cc
(read_context::find_symbol_table_section): Allow returning a nil
pointer to symbol table.
(read_context::lookup_elf_symbol_from_index): Return an empty elf
symbol if we got a nil pointer to symbol table.
(read_context::load_symbol_maps): If no symbol table is found then
consider that the symbol maps loading failed.
2015-07-16 Dodji Seketeli <dodji@redhat.com>
Remove extra vertical spaces from diff report
* src/abg-comparison.cc (class_diff::report): Do not emit new line
unless the diff is to be reported.
* tests/data/test-diff-filter/test25-cyclic-type-report-0.txt: Adjust.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-0.txt: Adjust.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-1.txt:
: Adjust.
2015-07-09 Dodji Seketeli <dodji@redhat.com>
Allow null types in type comparison again
* src/abg-comparison.cc (compute_diff): In the overload of
type_base_sptr accept nil types.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Handle the life time of the map of canonical types
* include/abg-ir.h (type_base::canonical_types_map_type): Move
this typedef into abg-ir.cc and out of the type_base namespace.
(type_base::get_canonical_types_map): Likewise.
* src/abg-ir.cc (canonical_types_map_type): New typedef that got
moved here from type_base::canonical_types_map_type.
(get_canonical_types_map): Likewise got moved here from
type_base::get_canonical_types_map. Made static in the process.
(class usage_watchdog): New type.
(usage_watchdog_sptr, usage_watchdog_wptr): New typedefs.
(get_usage_watchdog, get_usage_watchdog_wptr, ref_usage_watchdog)
(maybe_cleanup_type_system_data): New static functions.
(translation_unit::priv::usage_watchdog_): Add new data member.
(translation_unit::priv::priv): Get a reference on the usage
watchdog.
(translation_unit::priv::~priv): If the usage watchdog says that
the type system is not used, then cleanup the global data
logically owned by the type system.
* include/abg-dwarf-reader.h (read_corpus_from_elf): Make this
return a corpus and set the status by reference using a parameter.
* src/abg-dwarf-reader.cc (read_corpus_from_elf): Implement the
above.
* include/abg-reader.h (read_translation_unit_from_file)
(read_translation_unit_from_buffer)
(read_translation_unit_from_istream): Remove the overloads that do
not return a translation_unit_sptr and that pass it as a
parameter. Only keep the overloads that return a
translation_unit_sptr, forcing users of the API to own a proper
reference on the resulting translation_unit pointer. That is
important to handle the life time of the global data of the type
system that need to be cleared when the last translation unit is
de-allocated.
* src/abg-reader.cc (read_translation_unit_from_input): Make this
return a translation_unit_sptr.
(read_translation_unit_from_file)
(read_translation_unit_from_buffer)
(read_translation_unit_from_istream): Remove the overloads that do
not return a translation_unit_sptr and that pass it as a
parameter. Only keep the overloads that return a
translation_unit_sptr.
(read_to_translation_unit): Make this return a
translation_unit_sptr.
* tests/print-diff-tree.cc (main): Adjust.
* tests/test-diff-dwarf.cc (main): Likewise.
* tests/test-ir-walker.cc (main): Likewise.
* tests/test-read-dwarf.cc (main): Likewise.
* tests/test-read-write.cc (main): Likewise.
* tools/abicompat.cc (main): Likewise.
* tools/abidiff.cc (main): Likewise.
* tools/abidw.cc (main): Likewise.
* tools/abilint.cc (main): Likewise.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Add --d{1,2} shortcut options for --debug-info-dir{1,2} in abidiff
* tools/abidiff.cc (display_usage): Add the --d{1,2} to the help
strings.
(parse_command_line): Parse the new --d1 and --d2 options.
2015-07-08 Dodji Seketeli <dodji@redhat.com>
Factorize incompatible and subtype changes detection
* include/abg-comparison.h (corpus_diff::{has_incompatible_changes,
has_net_subtype_changes}): Declare new member functions.
* src/abg-comparison.cc (corpus_diff::{has_incompatible_changes,
has_net_subtype_changes}): Define them.
* abidiff.cc (main): Use the new member functions above.
2015-07-09 Dodji Seketeli <dodji@redhat.com>
Adjust some tests for output changes
* tests/data/test-abidiff/test-struct1-report.txt: Adjust.
* tests/data/test-diff-dwarf/test10-report.txt: Likewise.
* tests/data/test-diff-dwarf/test11-report.txt: Likewise.
* tests/data/test-diff-dwarf/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-0.txt: Likewise.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-1.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-1.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-2.txt: Likewise.
2015-07-06 Dodji Seketeli <dodji@redhat.com>
Fix missing newlines in diff report
* src/abg-comparison.cc (class_diff::report): The overload of
represent() for instances of var_decl does not emit new lines. So
the caller must ensure a new line is emitted.
2015-07-02 Dodji Seketeli <dodji@redhat.com>
Support filtering out just one alias of a function
* include/abg-comparison.h (function_suppression::{get,
set}_allow_other_aliases): Declare new member functions.
* src/abg-comparison.cc
(function_suppression::priv::allow_other_aliases_): New data
member.
(function_suppression::priv::priv): Initialize it to 'true'.
(function_suppression::{get, set}_allow_other_aliases): Define new
member functions.
(read_function_suppression): Parse the new "allow_other_aliases"
property.
(function_suppression::suppresses_function): Update to evaluate
the new 'allow_other_aliases' property when there is a property to
match against some a symbol name of the function.
(corpus_diff::report): Fix the printing of function aliases when
printing sub-type changes to properly emit the plural of the word
'symbol' when the function has several aliases.
* include/abg-ir.h (elf_symbol::get_number_of_aliases): Declare
new member function.
* src/abg-ir.cc (elf_symbol::get_number_of_aliases): Define new
member function.
* doc/manuals/libabigail-concepts.rst: Update manual.
* tests/data/test-diff-dwarf/test5-report.txt: Adjust.
* tests/data/test-diff-suppr/libtest23-alias-filter-v0.so: New
test input.
* tests/data/test-diff-suppr/libtest23-alias-filter-v1.so: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-0.suppr: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-1.suppr: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-2.suppr: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-3.suppr: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-4.suppr: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-v0.c: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-v1.c: Likewise.
* tests/data/test-diff-suppr/test23-alias-filter-version-script: Likewise.
* tests/data/Makefile.am: Add the new test stuff to source
distribution.
* tests/test-diff-suppr.cc (in_out_spec): Add the tests inputs
above to the list of input to run over.
2015-07-01 Dodji Seketeli <dodji@redhat.com>
Complete apidoc
* src/abg-ir.cc (elf_symbol::get_aliases_id_string): Finish the
incomplete apidoc for this member function.
2015-07-01 Dodji Seketeli <dodji@redhat.com>
Show aliases of functions with changed sub-types
* include/abg-ir.h (elf_symbol::get_aliases_id_string): Declare
new overload.
* src/abg-ir.cc (elf_symbol::get_aliases_id_string): Define new
overload.
* src/abg-comparison.cc (corpus_diff::report): For functions with
sub-type changes report their aliases. Do not do this if the
function is a constructor or destructor because these almost
always have aliases, at least with GCC and the developer most
certainly has not done anything special for that; she would thus
be uselessly surprised by that remote implementation detail.
* tests/data/test-diff-dwarf/test5-report.txt: Adjust test.
2015-06-25 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog file
* ChangeLog: Update automatically using 'make update-changelog'.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Misc typo fixes
* src/abg-comparison.cc
(corpus_diff::priv::{deleted, added}n_variable_is_suppressed): Fix
a typo.
* tests/data/test-diff-dwarf/test16-syms-only-v0.cc: Fix a typo in
the comments.
* tests/data/test-diff-dwarf/test16-syms-only-v1.cc: Likewise.
2015-06-22 Dodji Seketeli <dodji@redhat.com>
Apply suppression specifications to added and removed functions and variables
* include/abg-comparison.h (is_type_suppression)
(is_function_suppression): Declare new functions.
({function, variable}_suppression::change_kind): Declare new enum.
(function_suppression::{parse_change_kind, get_change_kind,
set_change_kind, suppresses_function,
suppresses_function_symbol}): Declare new member functions.
(variable_suppression::{parse_change_kind, get_change_kind,
set_change_kind, suppresses_variable, suppresses_variable,
suppresses_variable_symbol}): Declare new member functions.
(operator{&,|}): Declare new operators for
function_suppression::change_kind and
variable_suppression::change_kind enums.
(corpus_diff::diff_stats::{num_removed_func_filtered_out,
net_num_func_removed, num_added_func_filtered_out,
net_num_func_added, num_removed_vars_filtered_out,
net_num_vars_removed, num_added_vars_filtered_out,
net_num_vars_added, num_removed_func_syms_filtered_out,
num_added_func_syms_filtered_out, net_num_removed_func_syms,
net_num_added_func_syms, num_added_var_syms_filtered_out,
num_removed_vars_filtered_out, net_num_removed_var_syms,
net_num_added_var_syms}): Declare new member functions.
(corpus_diff::diff_stats::num_changed_vars_filtered_out): Renamed
corpus_diff::diff_stats::num_vars_filtered_out into this.
(corpus_diff::diff_stats::num_changed_func_filtered_out): Renamed
corpus_diff::diff_stats::num_func_filtered_out into this.
* src/abg-comparison.cc (is_type_suppression)
(is_function_suppression): Define new
function.
(function_suppression::priv::change_kind): New data member.
(function_suppression::priv): Initialize it.
(function_suppression::{parse_change_kind, get_change_kind,
set_change_kind, suppresses_function,
suppresses_function_symbol}): Define new member functions.
(operator{&,|}): Define new operators for the new
function_suppression::change_kind enum.
(function_suppression::suppresses_diff): Re-write this in terms of
the new function_suppression::suppresses_function() function.
(read_function_suppression): Support reading the new "change_kind"
property.
(variable_suppression::priv::change_kind_): New data member.
(variable_suppression::priv::priv): Initialize it.
(variable_suppression::{parse_change_kind, get_change_kind,
set_change_kind, suppresses_variable,
suppresses_variable_symbol}): Define new member functions.
(is_variable_suppression): Define new function.
(operator{&,|}): Define new operators for
variable_suppression::change_kind enum.
(variable_suppression::suppresses_diff): Re-write in terms of the
new variable_suppression::suppresses_variable function.
(read_variable_suppression): Support reading the new "change_kind"
property.
(corpus_diff::diff_stats::priv::{num_removed_func_filtered_out,
num_added_func_filtered_out, num_removed_vars_filtered_out,
num_added_vars_filtered_out, num_removed_func_syms_filtered_out,
num_added_func_syms_filtered_out,
num_removed_var_syms_filtered_out,
num_added_var_syms_filtered_out}): New data members.
(corpus_diff::diff_stats::priv::num_changed_func_filtered_out):
Renamed the data member num_func_filtered_out into this.
(corpus_diff::diff_stats::priv::num_changed_vars_filtered_out):
Renamed data member num_vars_filtered_out into this.
(corpus_diff::diff_stats::priv::priv): Initialize the new data
members.
(corpus_diff::diff_stats::{num_removed_func_filtered_out,
num_removed_func_filtered_out, net_num_func_removed,
net_num_func_added, num_added_func_filtered_out,
net_num_func_added, num_removed_vars_filtered_out,
num_removed_vars_filtered_out, net_num_vars_removed,
num_added_vars_filtered_out, net_num_vars_added,
num_removed_func_syms_filtered_out,
num_added_func_syms_filtered_out, net_num_removed_func_syms,
net_num_added_func_syms, num_added_var_syms_filtered_out,
num_removed_vars_filtered_out, net_num_removed_var_syms,
net_num_added_var_syms}): Define new member functions.
(corpus_diff::diff_stats::num_changed_func_filtered_out): Renamed
corpus_diff::diff_stats::num_func_filtered_out into this.
(corpus_diff::diff_stats::num_changed_vars_filtered_out): Renamed
corpus_diff::diff_stats::num_vars_filtered_out into this.
(corpus_diff::diff_stats::{net_num_func_changed,
net_num_vars_changed}): Adjust.
(corpus_diff::priv::{suppressed_deleted_fns_,
suppressed_added_fns_, suppressed_deleted_vars_,
suppressed_added_vars_, suppressed_added_unrefed_fn_syms_,
suppressed_deleted_unrefed_fn_syms_,
suppressed_added_unrefed_var_syms_,
suppressed_deleted_unrefed_fn_syms_}): New data members.
(corpus_diff::priv::{apply_suppressions_to_added_removed_fns_vars,
deleted_function_is_suppressed, added_function_is_suppressed,
deleted_variable_is_suppressed, added_variable_is_suppressed,
added_unrefed_fn_sym_is_suppressed,
deleted_unrefed_fn_sym_is_suppressed,
added_unrefed_var_sym_is_suppressed,
deleted_unrefed_var_sym_is_suppressed}): Define member functions.
(function_is_suppressed, variable_is_suppressed): Define new
functions.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Compute
stats for filtered added or removed functions, variables and their
symbols.
(corpus_diff::priv::emit_diff_stats): Emit diff stats for filtered
added or removed functions, variables and symbols.
(corpus_diff::report): Support suppressed reports about added or
removed functions, variables and symbols. Fixed a typo that was
in there for a while. Note that that fix requires updating some
regression tests, and the part of this patch that touches
regression tests does that.
(apply_suppressions): In the overload for corpus_diff, apply the
suppression to added or removed functions and variables.
* doc/manuals/libabigail-concepts.rst: Update this manual to
reflect the changes above. Also, perform an extensive cleanup of
the manual to introduce more section titles to make it easier to
navigate the document using the table of content.
* tests/data/test-abicompat/test2-var-removed-report-0.txt:
Adjust.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test12-report.txt: Likewise.
* tests/data/test-diff-dwarf/test18-alias-sym-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test19-soname-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test7-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-dwarf/test9-report.txt: Likewise.
* tests/data/test-diff-dwarf/test16-syms-only-report.txt: Likewise.
* tests/data/test-diff-dwarf/test17-non-refed-syms-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* test-diff-suppr/test15-suppr-added-fn-v0.o: Add new test
material.
* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test21-compatible-vars-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test24-compatible-vars-report-1.txt:
Likewise.
* test-diff-suppr/test15-suppr-added-fn-v1.o: Likewise.
* test-diff-suppr/test15-suppr-added-fn-0.suppr: Likewise.
* test-diff-suppr/test15-suppr-added-fn-1.suppr: Likewise.
* test-diff-suppr/test15-suppr-added-fn-2.suppr: Likewise.
* test-diff-suppr/test15-suppr-added-fn-3.suppr: Likewise.
* test-diff-suppr/test15-suppr-added-fn-4.suppr: Likewise.
* test-diff-suppr/test15-suppr-added-fn-report-0.txt: Likewise.
* test-diff-suppr/test15-suppr-added-fn-report-1.txt: Likewise.
* test-diff-suppr/test15-suppr-added-fn-report-2.txt: Likewise.
* test-diff-suppr/test15-suppr-added-fn-report-3.txt: Likewise.
* test-diff-suppr/test15-suppr-added-fn-report-4.txt: Likewise.
* test-diff-suppr/test15-suppr-added-fn-report-5.txt: Likewise.
* test-diff-suppr/test15-suppr-added-fn-v0.cc: Likewise.
* test-diff-suppr/test15-suppr-added-fn-v1.cc: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-v0.o: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-v1.o: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-0.suppr: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-1.suppr: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-2.suppr: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-3.suppr: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-4.suppr: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-report-0.txt: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-report-1.txt: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-report-2.txt: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-report-3.txt: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-report-4.txt: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-report-5.txt: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-v0.cc: Likewise.
* test-diff-suppr/test16-suppr-removed-fn-v1.cc: Likewise.
* test-diff-suppr/test17-suppr-added-var-v0.o: Likewise.
* test-diff-suppr/test17-suppr-added-var-v1.o: Likewise.
* test-diff-suppr/test17-suppr-added-var-0.suppr: Likewise.
* test-diff-suppr/test17-suppr-added-var-1.suppr: Likewise.
* test-diff-suppr/test17-suppr-added-var-2.suppr: Likewise.
* test-diff-suppr/test17-suppr-added-var-3.suppr: Likewise.
* test-diff-suppr/test17-suppr-added-var-4.suppr: Likewise.
* test-diff-suppr/test17-suppr-added-var-report-0.txt: Likewise.
* test-diff-suppr/test17-suppr-added-var-report-1.txt: Likewise.
* test-diff-suppr/test17-suppr-added-var-report-2.txt: Likewise.
* test-diff-suppr/test17-suppr-added-var-report-3.txt: Likewise.
* test-diff-suppr/test17-suppr-added-var-report-4.txt: Likewise.
* test-diff-suppr/test17-suppr-added-var-report-5.txt: Likewise.
* test-diff-suppr/test17-suppr-added-var-v0.cc: Likewise.
* test-diff-suppr/test17-suppr-added-var-v1.cc: Likewise.
* test-diff-suppr/test18-suppr-removed-var-v0.o: Likewise.
* test-diff-suppr/test18-suppr-removed-var-v1.o: Likewise.
* test-diff-suppr/test18-suppr-removed-var-0.suppr: Likewise.
* test-diff-suppr/test18-suppr-removed-var-1.suppr: Likewise.
* test-diff-suppr/test18-suppr-removed-var-2.suppr: Likewise.
* test-diff-suppr/test18-suppr-removed-var-3.suppr: Likewise.
* test-diff-suppr/test18-suppr-removed-var-4.suppr: Likewise.
* test-diff-suppr/test18-suppr-removed-var-report-0.txt: Likewise.
* test-diff-suppr/test18-suppr-removed-var-report-1.txt: Likewise.
* test-diff-suppr/test18-suppr-removed-var-report-2.txt: Likewise.
* test-diff-suppr/test18-suppr-removed-var-report-3.txt: Likewise.
* test-diff-suppr/test18-suppr-removed-var-report-4.txt: Likewise.
* test-diff-suppr/test18-suppr-removed-var-report-5.txt: Likewise.
* test-diff-suppr/test18-suppr-removed-var-v0.cc: Likewise.
* test-diff-suppr/test18-suppr-removed-var-v1.cc: Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-v0.o: New
test input.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-v1.o:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-1.suppr:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-2.suppr:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-3.suppr:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-report-4.txt:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-v0.cc:
Likewise.
* tests/data/test-diff-suppr/test19-suppr-added-fn-sym-v1.cc:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-v0.o:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-v1.o:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-1.suppr:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-2.suppr:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-3.suppr:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-report-4.txt:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-v0.cc:
Likewise.
* tests/data/test-diff-suppr/test20-suppr-removed-fn-sym-v1.cc:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-v0.o:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-v1.o:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-1.suppr:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-2.suppr:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-3.suppr:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-report-4.txt:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-v0.cc:
Likewise.
* tests/data/test-diff-suppr/test21-suppr-added-var-sym-v1.cc:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-v0.o:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-v1.o:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-0.suppr:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-1.suppr:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-2.suppr:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-3.suppr:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-4.suppr:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-report-3.txt:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-report-4.txt:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-report-5.txt:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-v0.cc:
Likewise.
* tests/data/test-diff-suppr/test22-suppr-removed-var-sym-v1.cc:
Likewise.
* tests/data/Makefile.am: Add the new test materials above to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new tests
material above to the list of test inputs this harness has to run
over.
2015-06-22 Dodji Seketeli <dodji@redhat.com>
Do not compare static data members when comparing types
* include/abg-ir.h (class_decl::get_non_static_data_members):
Declare new data members.
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Only look at
non-static data members.
(compute_diff): In the overload for class_decl, only compare
non-static data members.
* src/abg-hash.cc (class_decl::hash::operator()): Do not hash
static data members members hashing a class_decl.
* src/abg-ir.cc (class_decl::priv::data_members_): New data
member.
(class_decl::priv::priv): When initializing data members, store
the non-static data members on the side, in the new
class_decl::priv::non_static_data_members_ data member.
(class_decl::get_non_static_data_members): Define member function.
(class_decl::add_data_member): Store the non-static data members
on the side in class_decl::priv::non_static_data_members_.
(equals): In the overload for class_decl, do not take in account
static data members when running the comparison.
* tests/data/test-diff-dwarf/test7-report.txt: Adjust.
* tests/data/test-diff-filter/test12-report.txt: Adjust.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Add a --suppr short alias to the --suppressions option of abidiff
* tools/abidiff.cc (display_usage): Add a help string for the new
--suppr option.
(parse_command_line): Support the --suppr option which is an alias
for --suppressions.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Enable large file support
* configure.ac: Call the AC_SYS_LARGEFILE autoconf macro.
* config.h.in: Update.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Do not build zip archive support by default
* configure.ac: By default, unconditionally disable the
zip-archive support.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Put the man pages of the binaries in section 1
* doc/manuals/Makefile.am(section1_manpages, section7_manpages):
Two new variables to contain the man page names per section.
(manpages): Set this variable to $section1_manpages and $section7_manpages.
(install-man-and-info-doc): In this rule, create the destination
directories for section 1 and 7 and copy the right man pages in
their right directory.
* doc/manuals/conf.py (man_pages): Generate the binary man pages
into section 1 and the libabigail man page into section 7.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Sort deleted/added variables and symbols before emitting report
* src/abg-comparison.cc (sort_string_var_ptr_map)
(sort_string_elf_symbol_map): Define new static functions.
(var_comp, elf_symbol_comp): Define new comparison functors.
(corpus_diff::report): Sort the deleted variables, added
variables, deleted function symbols, added function symbols,
deleted variable symbols, and added variable symbols before
walking them to emit reports.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Remove useless white space
* src/abg-comparison.cc (sort_string_parm_map): Remove trailing
white space from comment.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Bug 18580 - abidw ignores --out-file
* tools/abidw.cc (main): Take the argument of --out-file into
account when emitting the serialized form of the ABI.
2015-06-23 Dodji Seketeli <dodji@redhat.com>
Fix a thinko in the comparison code
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Ensure that when a
member function is wrongly considered as being added, then either
the new member function doesn't have a symbol name (linkage name)
or it has one, and it was already present in the first version of
the binary.
# Veuillez saisir le message de validation pour vos
modifications. Les lignes # commençant par '#' seront ignorées, et
un message vide abandonne la validation. # Sur la branche
fix-master # Votre branche est à jour avec 'origin/master'. # #
Modifications qui seront validées : # modified:
src/abg-comparison.cc # # Modifications qui ne seront pas validées
: # modified: tools/abidw.cc # # Fichiers non suivis: # abidw.abi
# build/ # depcomp # missing # patch-edited.txt # patch.txt #
prtests/ # test-driver # # ------------------------ >8
------------------------ # Ne touchez pas à la ligne ci-dessus #
Tout se qui suit sera éliminé.
diff --git a/src/abg-comparison.cc b/src/abg-comparison.cc
index 14208f5..ef7c6c9 100644
--- a/src/abg-comparison.cc
+++ b/src/abg-comparison.cc
@@ -7419,8 +7419,8 @@ class_diff::ensure_lookup_tables_populated(void) const
inserted_member_fns().begin();
i != inserted_member_fns().end();
++i)
- if (i->second->get_symbol()
- && f->lookup_function_symbol(i->second->get_symbol()->get_name(),
+ if (!i->second->get_symbol()
+ || f->lookup_function_symbol(i->second->get_symbol()->get_name(),
i->second->get_symbol()->get_version().str()))
to_delete.push_back(i->first);
2015-06-07 Dodji Seketeli <dodji@redhat.com>
Build libabigail tests with position-independent code
* tests/Makefile.am: Add -fPIC to the compile flags.
2015-06-07 Dodji Seketeli <dodji@redhat.com>
Build libabigail tools as position-independent code
* tools/Makefile.am: Compile the binaries here with -fPIC. Note
that the library libabigail.la is built with libtool which already
takes care of this, so no need to worry about this for
libabigail.la.
2015-06-07 Dodji Seketeli <dodji@redhat.com>
Update ChangeLog file
* ChangeLog: Update this automatically by typing make
update-changelog.
2015-06-07 Dodji Seketeli <dodji@redhat.com>
Avoid infinite loop in elf_symbol::get_alias_from_name()
* src/abg-ir.cc (elf_symbol::get_alias_from_name)
(elf_symbol::get_alias_which_equals): Test for the next alias
pointing to the main symbol, in the loop exit condition.
2015-06-04 Dodji Seketeli <dodji@redhat.com>
Change the linkage name only when necessary
* include/abg-ir.h (elf_symbol::get_alias_from_name): Declare new
member function.
* src/abg-ir.cc (elf_symbol::get_alias_from_name): Define it.
* src/abg-dwarf-reader.cc (build_var_decl, build_function_decl):
Once the linkage name is supposed to contain the value of the
DW_AT_linkage_name attribute, set it the name of the underlying
symbol only if value of DW_At_linkage_name is missing or different
from the names of all the aliases of the underlying symbol.
* tests/data/test-read-dwarf/test2.so.abi: Adjust.
2015-06-04 Dodji Seketeli <dodji@redhat.com>
Various white space cleanups
* include/abg-comparison.h: Remove various useless vertical white
spaces.
* tests/test-diff-dwarf.cc (in_out_spec): Fix indentation of some
entries.
2015-06-04 Dodji Seketeli <dodji@redhat.com>
Fix various comments here and there
* src/abg-comparison.cc
(diff_context::set_or_get_canonical_diff_for, compute_diff)
(redundancy_marking_visitor::visit_begin): Fix comment in these
functions.
* src/abg-ir.cc (elf_symbol::is_variable): Likewise.
2015-06-04 Dodji Seketeli <dodji@redhat.com>
Add missing apidoc to elf_symbol type
* src/abg-ir.cc (elf_symbol::{elf_symbol, get_name, set_name,
get_type, set_type, get_binding, set_binding, get_version,
is_defined, is_public, is_function, is_variable}): Add missing
apidoc to these member functions.
2015-06-04 Dodji Seketeli <dodji@redhat.com>
Cleanup logic in class_diff::ensure_lookup_tables_populated()
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Remove the code that
tries to lookup allegedly added functions from the set of deleted
ones, by using the pretty printed name of the function. Handling
the case of a function decl not correctly tied to it symbol is
handled my generically a bit later in this function.
2015-06-04 Dodji Seketeli <dodji@redhat.com>
Report possible changes in the set of aliases of a symbol.
* src/abg-comparison.cc (function_decl_diff::report): Report
a change in the aliases of the symbols of a function; note that
everything else but have stayed equal in the function.
2015-06-04 Dodji Seketeli <dodji@redhat.com>
Report vtable changes in top-level function change reports
* src/abg-comparison.cc (function_decl_diff::report): Report about
virtual-ness and vtable offset changes.
* tests/data/test-diff-dwarf/test28-vtable-changes-report-0.txt:
New test input file.
* tests/data/test-diff-dwarf/test28-vtable-changes-v{0,1}.o: New
test input binaries.
* tests/data/test-diff-dwarf/test28-vtable-changes-v{0,1}.cc:
Source code of the input binaries above.
* tests/data/Makefile.am: Add the new test input above to source
distribution.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test input
above to the list of input this test harness has to run over.
2015-06-03 Dodji Seketeli <dodji@redhat.com>
Support new 'accessed_through' suppression property
* include/abg-comparison.h (enum type_suppression::reach_kind):
Define new enum.
(type_suppression::{get_consider_reach_kind,
set_consider_reach_kind, get_reach_kind,
mark_last_diff_visited_per_class_of_equivalence,
clear_last_diffs_visited_per_class_of_equivalence,
get_last_visited_diff_of_class_of_equivalence}): Declare new
member functions.
* src/abg-comparison.cc (diff_has_ancestor_filtered_out)
(read_suppression_reach_kind): Define static function.
(type_suppression::priv::{consider_reach_kind_, reach_kind_}):
Define new data members.
(type_suppression::priv::priv): Take a new reach_kind parameter.
(type_suppression::type_suppression): Adjust to new prototype of
priv constructor.
(type_suppression::{get_consider_reach_kind,
set_consider_reach_kind, get_reach_kind, set_reach_kind}): Define
new member functions.
(type_suppression::suppresses_diff): Interpret the result of
type_suppression::get_reach_kind() to determine if the suppression
specification suppresses a given diff node.
(read_type_suppression): Support reading the content of the
"accessed_through" property.
(diff_context::priv::last_visited_diff_node_): New data member.
(diff_context::{mark_last_diff_visited_per_class_of_equivalence,
clear_last_diffs_visited_per_class_of_equivalence,
get_last_visited_diff_of_class_of_equivalence}): Define new data
members.
(redundancy_marking_visitor::visit_begin): So if the current diff
node has already been visited, but if the previously visited node
has been filtered out, then do not mark this node as being
redundant. And mark the current diff node as being the last
visited one in its class of equivalence.
(categorize_redundancy): Clear the map of diff nodes visited per
class of equivalence.
* doc/manuals/libabigail-concepts.rst: Document the new
'accessed_through' property.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-0.suppr:
New test input data.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-report-{0,1}.txt:
Likewise.
* tests/data/test-diff-suppr/libtest13-suppr-through-pointer-v{0,1}.so:
New test input binaries.
* tests/data/test-diff-suppr/test13-suppr-through-pointer-v{0,1}.cc:
Source code of the test input binaries above.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-0.suppr:
New test input data.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-v{0,1}.o:
New test input binaries.
* tests/data/test-diff-suppr/test14-suppr-non-redundant-v{0,1}.cc:
Source code of the binaries above.
2015-06-03 Dodji Seketeli <dodji@redhat.com>
Fix redundancy marking for change of types used directly
* include/abg-comparison.h (pointer_map): Make this be a map of
{size_t, size_t} pairs, rather than {size_t, bool}, so that each
pointer in the map can be associated to another one.
(diff_context::diff_has_been_visited): Return the pointer to the
first diff node of the equivalence class that has been visited.
* src/abg-comparison.cc (is_pointer_diff, is_reference_diff)
(is_reference_or_pointer_diff, is_fn_parm_diff, is_base_diff)
(is_child_node_of_function_parm_diff, is_child_node_of_base_diff):
Define new static functions.
(diff_context::diff_has_been_visited): Return the pointer to the
first diff node of the equivalence class that has been visited.
(diff_context::mark_diff_as_visited): Save the pointer to the
first diff node of a given class of equivalence that has been
visited.
(redundancy_marking_visitor::visit_begin): If a diff node is a
child node of a function parameter diff or base diff node and if
it's not a pointer or reference diff node, then do not mark it as
redundant. Also, make sure to not mark the first diff node of a
given class of equivalence that has been visited, as redundant;
only the other subsequent nodes should be marked redundant; we
were hitting this case because of an optimization that makes
equivalent class diff nodes to share their private (pimpl) data.
* tests/data/test-diff-filter/test29-finer-redundancy-marking-v{0,1}.o:
New test input binaries.
* tests/data/test-diff-filter/test29-finer-redundancy-marking-v{0,1}.cc:
Source code of the new test input binaries above.
* tests/data/test-diff-filter/test29-finer-redundancy-marking-report-0.txt:
New test input.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
* tests/test-diff-filter.cc (in_out_specs): Make this test harness
run over the additional test input above.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Adjust.
2015-06-02 Dodji Seketeli <dodji@redhat.com>
Fix detection of local changes in base classes
* abg-ir.cc (equals): In the overload of class_decl::base_spec, if
the underlying class carries changes, then do not flag these
changes as local for the class_decl::base_spec.
* tests/data/test-diff-dwarf/test27-local-base-diff-v{0,1}.o: New
test input binaries.
* tests/data/test-diff-dwarf/test27-local-base-diff-v{0,1}.cc: Source
code for the test input binaries above.
* tests/data/test-diff-dwarf/test27-local-base-diff-report.txt:
New test input.
* tests/data/Makefile.am: Add the test inputs above to source
distribution.
2015-06-02 Dodji Seketeli <dodji@redhat.com>
Fix symbols comparison
* include/abg-ir.h (elf_symbol_wptr): New typedef.
(elf_symbol): Make the constructors and assignment operator
private. The type can neither be copied nor created with the new
operator.
(elf_symbol::create): New static member function.
(elf_symbol::{get_main_symbol, get_next_alias, add_alias}):
Adjust.
( compute_aliases_for_elf_symbol): Likewise.
(elf_symbol::operator=): Make this private.
(elf_symbol::get_alias_which_equals): Declare new member function.
* src/abg-comp-filter.cc (function_name_changed_but_not_symbol):
Adjust.
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Adjust.
* src/abg-corpus.cc
(corpus::priv::build_unreferenced_symbols_tables): Likewise.
* include/abg-dwarf-reader.h (lookup_symbol_from_elf)
(lookup_public_function_symbol_from_elf): Adjust.
* src/abg-dwarf-reader.cc (lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab, lookup_symbol_from_elf_hash_tab)
(lookup_symbol_from_symtab, lookup_symbol_from_elf)
(lookup_public_function_symbol_from_elf)
(lookup_public_variable_symbol_from_elf): Adjust.
(read_context::lookup_elf_symbol_from_index): Likewise.
(read_context::lookup_elf_fn_symbol_from_address): Likewise.
(read_context::lookup_elf_var_symbol_from_address): Likewise.
(read_context::lookup_public_function_symbol_from_elf): Likewise.
(read_context::lookup_public_variable_symbol_from_elf): Likewise.
(read_context::load_symbol_maps): Likewise.
(build_var_decl, build_function_decl): Likewise.
* src/abg-ir.cc (elf_symbol::priv::{main_symbol_, next_alias_}):
Change the type of these from elf_symbol* to elf_symbol_wptr.
(elf_symbol::priv::priv): Adjust.
(elf_symbol::{create, get_alias_which_equals}): Define new functions.
(textually_equals): Likewise.
(elf_symbol::{get_main_symbol, is_main_symbol, get_next_alias,
add_alias}): Adjust to return or take elf_symbol_sptr type, rather
than a elf_symbol* one.
(elf_symbol::{get_aliases_id_string, does_alias}): Adjust.
(compute_alias_for_elf_symbol): Likewise.
(elf_symbol::operator==): Two symbols A and B are now equal if A
has at least one alias that is textually equal to B.
(equals): In the overload for function_decls, in the part where we
compare the decl_base part of the functions without considering
their decl names, we now also omit considering their linkage
names, because we compared they symbols before.
* tools/abisym.cc (main): Adjust.
* tests/data/test-diff-dwarf/test12-report.txt: Adjust.
* tests/data/test-diff-dwarf/test12-report.txt: Adjust.
* tests/data/test-diff-dwarf/test18-alias-sym-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/test8-report.txt: Adjust.
* tests/data/test-diff-filter/test10-report.txt: Adjust.
* tests/data/test-diff-filter/test13-report.txt: Adjust.
* tests/data/test-diff-filter/test2-report.txt: Adjust.
* tests/data/test-diff-filter/test20-inline-report-0.txt: Adjust.
* tests/data/test-diff-filter/test20-inline-report-1.txt: Adjust.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
2015-04-22 Dodji Seketeli <dodji@redhat.com>
Support specifying data member insertion in suppressions
* include/abg-comparison.h (type_suppression::insertion_range):
Declare new type.
(type_suppression::insertion_ranges): Declare new typedef.
(type_suppression::{s,g}et_data_member_insertion_ranges): Declare
new member functions.
(is_integer_boundary, is_fn_call_expr_boundary): Declare new
functions.
(type_suppression::insertion_range::{boundary, integer_boundary,
fn_call_expr_boundary}): Define new types.
* src/abg-comparison.cc:
(struct type_suppression::insertion_range::priv): New type.
(type_suppression::insertion_range::{insertion_range, begin,
end}): Define new member functions.
(type_suppression::priv::insertion_ranges_): Add data member.
(type_suppression::{s,g}et_data_member_insertion_ranges): Define
new member functions.
(type_suppression::insertion_range::boundary::priv): Define new
type.
(type_suppression::insertion_range::boundary::{boundary,
~boundary}): Define new member functions.
(type_suppression::insertion_range::integer_boundary::priv):
Define new type.
(type_suppression::insertion_range::integer_boundary::{integer_boundary,
as_integer, operator int, ~integer_boundary}): Define member
functions.
(type_suppression::insertion_range::fn_call_expr_boundary::priv):
Define new type.
(type_suppression::insertion_range::fn_call_expr_boundary::{fn_call_expr_boundary,
as_function_call_expr, operator ini::function_call_expr_sptr}):
Define new member functions.
(type_suppression::insertion_range::{create_integer_boundary,
type_suppression::insertion_range::create_fn_call_expr_boundary,
type_suppression::insertion_range::eval_boundary}): Define new
member functions.
(is_integer_boundary, is_fn_call_expr_boundary): Define new
functions.
(read_type_suppression, read_function_suppression)
(read_variable_suppression): Support the new kinds of
property-related types. Aslo, in read_type_suppression, support
the new properties has_data_member_inserted_at,
has_data_member_inserted_between and
has_data_members_inserted_between.
(type_suppression::suppresses_diff): If we are looking at a type
diff node that has inserted data members, evaluate the insertion
ranges of the current type_suppression and see if they match the
inserted data members.
* include/abg-ini.h (property, simple_property, property_value)
(string_property_value, tuple_property_value, function_call_expr):
Declare new types.
(property_sptr, property_value_sptr, string_property_value_sptr)
(tuple_property_value_sptr): Declare new typedefs.
(is_string_property_value, is_tuple_property_value)
(is_simple_property, is_tuple_property, read_function_call_expr):
Declare new functions.
* src/abg-ini.cc (char_is_white_space, char_is_comment_start)
(char_is_delimiter, char_is_property_value_char)
(char_is_section_name_char, char_is_property_name_char)
(char_is_comment_start, char_is_white_space)
(remove_trailing_white_spaces, is_string_property_value)
(is_tuple_property_value, is_simple_property, is_tuple_property)
(write_property_value, char_is_function_name_char)
(char_is_function_argument_char): Define new functions.
(property::priv, tuple_property_value::priv)
(simple_property::priv, tuple_property::priv): Define new types.
(property::{property, get_name, set_name, ~property}): Define new
member functions.
(struct property_value::priv): Define new type.
(property_value::{property_value, get_kind, operator const
string&(), ~property_value}): Define new member functions.
(struct string_property_value::priv): Define new type.
(string_property_value::{string_property_value, set_content,
as_string, operator string()}, ~string_property_value): Define new
member functions.
(tuple_property_value::{tuple_property_value, get_value_items,
~tuple_property_value, as_string}): Likewise.
(simple_property::{simple_property, get_value, set_value,
~simple_property}): Likewise.
(tuple_property::{tuple_property, set_value, get_value}):
Likewise.
(config::section::find_property): Adjust return type.
(read_context::{char_is_delimiter, char_is_property_value_char,
char_is_section_name_char, char_is_property_name_char,
char_is_comment_start, char_is_white_space}): Remove these from
here as they got moved them to be non-member functions above.
(read_context::read_property_value): Return a property_value_sptr
and do not take any parameter anymore.
(read_context::{read_string_property_value,
read_tuple_property_value, read_function_name,
read_function_argument, read_function_call_expr}): Define new
member functions.
(read_context::read_property): Adjust return type. Also, change to read
the different new kinds of properties values.
(function_call_expr::priv): Define new type.
(function_call_expr::{function_call_expr, get_name,
get_arguments}): New member functions.
(read_context::read_section): Adjust.
(write_property, write_section): Adjust.
* tests/data/test-diff-suppr/libtest{11,12}-add-data-member-v{0,1}.so:
New test input binaries.
* tests/data/test-diff-suppr/test{11,12}-add-data-member-{0,1}.suppr:
New input suppression files.
* tests/data/test-diff-suppr/test11-add-data-member-{2,3,4}.suppr:
Add new test input files.
* tests/data/test-diff-suppr/test{11,12}-add-data-member-report-{0,1}.txt:
New reference output files.
* tests/data/test-diff-suppr/test12-add-data-member-report-2.txt:
Likewise.
* tests/data/test-diff-suppr/test{11,12}-add-data-member-v{0,1}.cc:
Source code for the new binaries above.
* tests/test-diff-suppr.cc (in_out_specs): Add new test inputs.
* tests/data/Makefile.am: Add the new test related files above to
source distribution.
* doc/manuals/libabigail-concepts.rst: Document the new properties
has_data_member_inserted_at, has_data_member_inserted_between and
has_data_members_inserted_between.
2015-05-24 Dodji Seketeli <dodji@redhat.com>
Make indexes of function parameters start at 1
* src/abg-ir.cc (function_type::function_type): Starts the index
of the parameters at 1, unless the firs parameter is an artificial
one, in which case it starts at 0.
* tests/data/test-abicompat/test5-fn-changed-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-dwarf/test1-report.txt: Adjust.
* tests/data/test-diff-dwarf/test10-report.txt: Adjust.
* tests/data/test-diff-dwarf/test11-report.txt: Adjust.
* tests/data/test-diff-dwarf/test13-report.txt: Adjust.
* tests/data/test-diff-dwarf/test15-enum-report.txt: Adjust.
* tests/data/test-diff-dwarf/test2-report.txt: Adjust.
* tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/test21-redundant-fn-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/test22-changed-parm-c-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/test25-removed-fn-parms-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt: Adjust.
* tests/data/test-diff-dwarf/test4-report.txt: Adjust.
* tests/data/test-diff-dwarf/test6-report.txt: Adjust.
* tests/data/test-diff-dwarf/test7-report.txt: Adjust.
* tests/data/test-diff-dwarf/test8-report.txt: Adjust.
* tests/data/test-diff-filter/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test01-report.txt: Adjust.
* tests/data/test-diff-filter/test1-report.txt: Adjust.
* tests/data/test-diff-filter/test10-report.txt: Adjust.
* tests/data/test-diff-filter/test13-report.txt: Adjust.
* tests/data/test-diff-filter/test14-0-report.txt: Adjust.
* tests/data/test-diff-filter/test14-1-report.txt: Adjust.
* tests/data/test-diff-filter/test16-report-2.txt: Adjust.
* tests/data/test-diff-filter/test16-report.txt: Adjust.
* tests/data/test-diff-filter/test17-0-report.txt: Adjust.
* tests/data/test-diff-filter/test17-1-report.txt: Adjust.
* tests/data/test-diff-filter/test18-report.txt: Adjust.
* tests/data/test-diff-filter/test19-enum-report-1.txt: Adjust.
* tests/data/test-diff-filter/test2-report.txt: Adjust.
* tests/data/test-diff-filter/test22-compatible-fns-report-0.txt: Adjust.
* tests/data/test-diff-filter/test23-redundant-fn-parm-change-report-0.txt: Adjust.
* tests/data/test-diff-filter/test25-cyclic-type-report-0.txt: Adjust.
* tests/data/test-diff-filter/test25-cyclic-type-report-1.txt: Adjust.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-0.txt: Adjust.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-1.txt: Adjust.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-1.txt: Adjust.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-2.txt: Adjust.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-0.txt: Adjust.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt: Adjust.
* tests/data/test-diff-filter/test3-report.txt: Adjust.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
* tests/data/test-diff-suppr/test0-type-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test0-type-suppr-report-3.txt: Adjust.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-2.txt: Adjust.
* tests/data/test-diff-suppr/test10-changed-parm-c-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test2-struct-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test3-struct-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test3-struct-suppr-report-1.txt: Adjust.
* tests/data/test-diff-suppr/test3-struct-suppr-report-2.txt: Adjust.
* tests/data/test-diff-suppr/test4-local-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test4-local-suppr-report-1.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-4.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt: Adjust.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test6-fn-suppr-report-1.txt: Adjust.
* tests/data/test-diff-suppr/test6-fn-suppr-report-2.txt: Adjust.
* tests/data/test-diff-suppr/test6-fn-suppr-report-3.txt: Adjust.
* tests/data/test-diff-suppr/test8-redundant-fn-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test8-redundant-fn-report-1.txt: Adjust.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-1.txt: Adjust.
2015-05-22 Dodji Seketeli <dodji@redhat.com>
Some wording fixes to doc/manuals/libabigail-concepts.rst
* doc/manuals/libabigail-concepts.rst: Some light wording fixes.
2015-05-24 Dodji Seketeli <dodji@redhat.com>
Type read from DWARF don't have alignment information
* src/abg-dwarf-reader.cc (build_type_decl)
(build_class_type_and_add_to_ir, build_pointer_type_def)
(build_reference_type, build_function_decl): Set the alignment for
native types, class, reference and function type to zero,
effectively meaning that they don't have alignment information.
* src/abg-hash.cc (var_decl::hash::operator): Take the hash value
of the data member context in account when computing the hash
value of a given data member.
* tests/data/test-diff-dwarf/test-23-diff-arch-report-0.txt:
Adjust.
* tests/data/test-diff-dwarf/test10-report.txt: Likewise.
* tests/data/test-diff-dwarf/test13-report.txt: Likewise.
* tests/data/test-diff-dwarf/test22-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-dwarf/test9-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test6-report.txt: Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
* tests/data/test-read-dwarf/test7.so.abi: Likewise.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi: Likewise.
2015-05-06 Dodji Seketeli <dodji@redhat.com>
Better name ID function parameters
* src/abg-ir.cc (function_decl::parameter::get_name_id): Make this
be "parameter-<index>".
2015-05-06 Dodji Seketeli <dodji@redhat.com>
Better detection of parameter sub-type changes
* include/abg-fwd.h (type_has_sub_type_changes): Declare new
function.
* src/abg-ir.cc (type_has_sub_type_changes): Define it.
* src/abg-comparison.cc (fn_parm_diff::report): Use the new
function type_has_sub_type_changes() instead of just looking at
name changes.
* tests/data/test-diff-dwarf/test4-report.txt: Adjust this
reference test output.
2015-05-06 Dodji Seketeli <dodji@redhat.com>
Fix a potential crash when comparing variadic parameters again
* src/abg-comparison.cc (redundancy_marking_visitor::visit_begin):
Avoid flagging diffs of variadic parameter *types* as redundant as
well.
2015-05-06 Dodji Seketeli <dodji@redhat.com>
Add debugging function for function parameters
* include/abg-ir.h
(function_decl::parameter::get_pretty_representation): Declare new
virtual member function.
* src/abg-ir.cc
(function_decl::parameter::get_pretty_representation): Define it.
2015-05-06 Dodji Seketeli <dodji@redhat.com>
Add comments
* src/abg-dwarf-reader.cc (build_function_decl): Add comments when
building the function parameters.
2015-05-06 Dodji Seketeli <dodji@redhat.com>
Add a debugging function for type_or_decl_base*
* include/abg-fwd.h (get_pretty_representation): Declare new
overload for type_or_decl_base*.
* src/abg-ir.cc (get_pretty_representation): Define it and express
the previous overload for type_or_decl_base_sptr in terms of this
new one.
2015-05-05 Dodji Seketeli <dodji@redhat.com>
Return a reference to smart pointer for the void type node
* src/abg-ir.h (type_decl::get_void_type_decl): Return a reference
to the smart pointer initially returned.
* src/abg-ir.cc (type_decl::get_void_type_decl): Likewise.
2015-05-05 Dodji Seketeli <dodji@redhat.com>
Bug 18342 - Segmentation fault while comparing functions with variadic parameters
* include/abg-fwd.h (is_array_type): New overload for a naked
pointer.
* include/abg-ir.h (type_decl::get_variadic_parameter_type_decl): Declare new
static function.
* src/abg-ir.cc (is_array_type): Define new function overload for
naked pointers
(type_decl::get_variadic_parameter_type_decl): Define new static
function.
* src/abg-dwarf-reader.cc (build_function_decl): The type of
variadic parameter is now a special type_decl.
* include/abg-comparison.h (is_diff_of_variadic_parameter_type)
(is_diff_of_variadic_parameter): New function declarations.
* src/abg-comparison.cc (is_diff_of_variadic_parameter_type)
(is_diff_of_variadic_parameter): Define new functions.
(compute_diff): Refuse to return a NULL
diff for types. Assert that the parameters are non-NULL.
(report_size_and_alignment_changes): We are comparing arrays only
if the two parameters are arrays.
(fn_parm_diff::fn_parm_diff): Refuse that type diff for this diff
node is non empty.
(fn_parm_diff::report): Strengthen an assert. Cleanup a comment.
(redundancy_marking_visitor::visit_begin): Do not mark function
type and variadic parms diff nodes as redundant for local changes.
* tests/data/test-diff-dwarf/libtest26-added-parms-before-variadic-v{0,1}.so:
New test input binaries.
* tests/data/test-diff-dwarf/test26-added-parms-before-variadic-report.txt:
New test output reference.
* tests/data/test-diff-dwarf/test26-added-parms-before-variadic-v{0,1}.c:
Source code of the new test input binaries above.
* tests/data/Makefile.am: Add the new test stuff to source
distribution.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test inputs
above to the set of input to run this test harness over.
2015-04-24 Dodji Seketeli <dodji@redhat.com>
Fix archive writing support
* configure.ac: Require libzip 0.10.1 at least.
* src/abg-writer.cc (archive_write_ctxt::serialized_tus): Make
this be a list<string>, rather than a vector<string>.
(create_archive_write_context): Truncate the archive if it exists
already.
(write_translation_unit_to_archive): Do not use the deprecated
zip_add() function anymore. Rather, use zip_file_add().
* tests/test-write-read-archive.cc (main): Double check if the
translation unit we read is empty or not.
2015-04-22 Dodji Seketeli <dodji@redhat.com>
Use a better wording for the COPYING file
* COPYING: Update to a more complete description.
2015-04-20 Dodji Seketeli <dodji@redhat.com>
Update licence texts
* COPYING: Of course we know the licence we want to use now :-)
* COPYING-GPLV3: Add the text of GPLv3.
* Makefile.am: Add the file COPYING-GPLV3 above to source
distribution.
2015-04-15 Dodji Seketeli <dodji@redhat.com>
18252 - Added parameters are not properly sorted
* src/abg-comparison.cc (sort_string_parm_map): Define new static
function.
(struct parm_comp): Define new type.
(function_type_diff::priv::{sorted_deleted_parms_,
sorted_added_parms_}): New data members that hold sorted
deleted/added parameters.
(function_type_diff::ensure_lookup_tables_populated): Initialize
the two new data members above.
(function_type_diff::report): For the report of parameters that
got added/removed, use the sorted set of added/removed parameters
above.
* tests/data/test-diff-dwarf/test24-added-fn-parms-report-0.txt:
New test input.
* tests/data/test-diff-dwarf/libtest24-added-fn-parms-v{0,1}.so:
Likewise.
* tests/data/test-diff-dwarf/test25-removed-fn-parms-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/libtest25-removed-fn-parms-v{0,1}.so:
Likewise.
* tests/data/test-diff-dwarf/test24-added-fn-parms-v{0,1}.c:
Likewise.
* tests/data/test-diff-dwarf/test25-removed-fn-parms-v{0,1}.c:
Likewise.
* tests/data/Makefile.am: Add the new test material above to the
source distribution.
2015-04-14 Dodji Seketeli <dodji@redhat.com>
Misc reporting fixes/improvements
* src/abg-comparison.cc (distinct_diff::report): Remove spurious
vertical space before reporting size and alignment changes here.
(represent): In the variables/data member overload, report type
changes first. Then the other changes.
(report_size_and_alignment_changes): Make this report array size
changes too. Also, make some small adjustments about how type
size/alignment changes are introduced.
(array_diff::report): Now that report_size_and_alignment_changes()
supports size change reporting, just use that function rather than
doing it here.
(corpus_diff::report): Consistently add a space between each
changed function report. Prefix changed variables with a [C],
just like for functions.
* tests/data/test-abicompat/test0-fn-changed-report-0.txt: Adjust.
* tests/data/test-abicompat/test5-fn-changed-report-0.txt: Likewise.
* tests/data/test-abicompat/test6-var-changed-report-0.txt: Likewise.
* tests/data/test-abidiff/test-qual-type0-report.txt: Likewise.
* tests/data/test-abidiff/test-struct0-report.txt: Likewise.
* tests/data/test-abidiff/test-struct1-report.txt: Likewise.
* tests/data/test-abidiff/test-var0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test-23-diff-arch-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test1-report.txt: Likewise.
* tests/data/test-diff-dwarf/test10-report.txt: Likewise.
* tests/data/test-diff-dwarf/test11-report.txt: Likewise.
* tests/data/test-diff-dwarf/test13-report.txt: Likewise.
* tests/data/test-diff-dwarf/test15-enum-report.txt: Likewise.
* tests/data/test-diff-dwarf/test2-report.txt: Likewise.
* tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test21-redundant-fn-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test22-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test3-report.txt: Likewise.
* tests/data/test-diff-dwarf/test6-report.txt: Likewise.
* tests/data/test-diff-dwarf/test7-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-dwarf/test9-report.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test1-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test11-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test14-0-report.txt: Likewise.
* tests/data/test-diff-filter/test14-1-report.txt: Likewise.
* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
* tests/data/test-diff-filter/test15-1-report.txt: Likewise.
* tests/data/test-diff-filter/test16-report-2.txt: Likewise.
* tests/data/test-diff-filter/test16-report.txt: Likewise.
* tests/data/test-diff-filter/test17-0-report.txt: Likewise.
* tests/data/test-diff-filter/test17-1-report.txt: Likewise.
* tests/data/test-diff-filter/test18-report.txt: Likewise.
* tests/data/test-diff-filter/test19-enum-report-1.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test20-inline-report-1.txt: Likewise.
* tests/data/test-diff-filter/test21-compatible-vars-report-0.txt: Likewise.
* tests/data/test-diff-filter/test22-compatible-fns-report-0.txt: Likewise.
* tests/data/test-diff-filter/test23-redundant-fn-parm-change-report-0.txt: Likewise.
* tests/data/test-diff-filter/test24-compatible-vars-report-1.txt: Likewise.
* tests/data/test-diff-filter/test25-cyclic-type-report-0.txt: Likewise.
* tests/data/test-diff-filter/test25-cyclic-type-report-1.txt: Likewise.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-0.txt: Likewise.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-1.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-0.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-1.txt: Likewise.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-2.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-0.txt: Likewise.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-1.txt: Likewise.
* tests/data/test-diff-filter/test3-report.txt: Likewise.
* tests/data/test-diff-filter/test6-report.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test10-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test2-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test6-fn-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-8.txt: Likewise.
* tests/data/test-diff-suppr/test8-redundant-fn-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test8-redundant-fn-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-1.txt: Likewise.
2015-04-10 Dodji Seketeli <dodji@redhat.com>
Make abidiff and abicompat return meaningful exit codes
* doc/manuals/abicompat.rst: Update documentation for abicompat
exit codes.
* doc/manuals/abidiff.rst: Likewise for abidiff exit codes.
* include/abg-tools-utils.h (enum abidiff_status): Declare new
enum.
(operator{|,&,|=}): Declare new operators for the new enum
abidiff_status.
(abidiff_status_has_error, abidiff_status_has_abi_change)
(abidiff_status_has_incompatible_abi_change): Declare new
functions.
* src/abg-tools-utils.cc (operator{|,&,|=}): Define these new
operators.
(abidiff_status_has_error, abidiff_status_has_abi_change)
(abidiff_status_has_incompatible_abi_change): Define new
functions.
* tests/test-diff-filter.cc (main): Adjust for the new exit code
of abidiff.
* tests/test-diff-suppr.cc (main): Likewise.
* tests/test-abicompat.cc (main): Likewise.
* tools/abicompat.cc (enum abicompat_status): Remove.
(operator{|,&,|=}): Remove these operators for enum
abicompat_status.
(perform_compat_check_in_normal_mode)
(perform_compat_check_in_weak_mode): Return abidiff_status instead
of abicompat_status. Adjust therefore.
(main): Adjust to return abidiff_status now, instead of a just
zero for all non-error cases.
* tools/abidiff.cc (main): Likewise.
2015-04-01 Dodji Seketeli <dodji@redhat.com>
Add support for abicompat weak mode
* include/abg-fwd.h (class type_or_decl_base): Forward declare
this.
(is_decl, is_type, is_function_type, get_name, get_type_name)
(get_function_type_name, get_pretty_representation)
(lookup_function_type_in_corpus, lookup_type_in_translation_unit)
(lookup_function_type_in_translation_unit)
(synthesize_function_type_from_translation_unit)
(hash_type_or_decl): New function declarations.
* src/abg-corpus.cc (lookup_type_in_corpus)
(lookup_function_type_in_corpus): Define new functions.
* include/abg-ir.h
(translation_unit::lookup_function_type_in_translation_unit):
Declare new friend function.
(class type_or_decl_base): Declare this.
(operator==(const type_or_decl_base&, const type_or_decl_base&)):
Declare new operator.
(operator==(const type_or_decl_base_sptr&, const
type_or_decl_base_sptr&)): Likewise.
(class {decl_base, type_base}): Make these class inherit
type_or_decl_base.
(decl_base::get_member_scopes): New const overload.
(bool operator==(const function_decl::parameter_sptr&,
const function_decl::parameter_sptr&)): New operator.
(function_type::get_parameters): Remove the non-const overload.
(function_type::get_pretty_representation): Declare new member
function.
(method_type::get_pretty_representation): Likewise.
* src/abg-ir.cc (bool operator==(const type_or_decl_base&, const
type_or_decl_base&)): Define new equality operator.
(bool operator==(const type_or_decl_base_sptr&, const
type_or_decl_base_sptr&)): Likewise.
(strip_typedef): Do not expect canonicalized types anymore. Now
the system accepts (and expects) canonicalized types in certain
cases. For instance, non-complete types and aggregated types that
contain non-complete sub-types.
(get_name, get_function_type_name, get_type_name)
(get_pretty_representation, is_decl, is_type, is_function_type)
(lookup_function_type_in_translation_unit)
(synthesize_function_type_from_translation_unit)
(lookup_type_in_scope, lookup_type_in_translation_unit): Define
new functions or new overloads.
(bool operator==(const function_decl::parameter_sptr&,
const function_decl::parameter_sptr& r)): Define
new operator.
(function_type::get_parameters): Remove non-const overload.
(function_type::get_pretty_representation): Define new function.
(function_type::traverse): Adjust.
(method_type::get_pretty_representation): Likewise.
(function_decl::get_pretty_representation): Avoid emitting the
type of cdtors.
(hash_type_or_decl): Define new function.
* include/abg-dwarf-reader.h (create_read_context)
(read_corpus_from_elf): Take a new 'read_all_types' flag.
* src/abg-dwarf-reader.cc (read_context::load_all_types_): New
flag.
(read_context::read_context): Initialize it.
(read_context::canonical_types_scheduled): If some types still
have non-canonicalized sub-types, then do not canonicalize them.
(read_context::load_all_types): New member functions.
(build_function_decl): Do not represent void return type like
empty type anymore, rather, represent it like a void type node.
(build_ir_node_from_die): When asked, load all types
including those that are not reachable from an exported
declaration.
(create_read_context, read_corpus_from_elf): Take a new
'load_all_types' flag and honour it.
* src/abg-reader.cc (read_context::type_is_from_translation_unit):
Support looking up function types in the current translation unit,
now that we now how to lookup function types.
* include/abg-comparison.h (diff_context::{has_diff_for, add_diff,
set_canonical_diff_for, set_or_get_canonical_diff_for,
get_canonical_diff_for}): Make these take instances of
type_or_decl_base_sptr, instead of decl_base_sptr.
(diff::diff): Likewise.
(diff::{first_subject, second_subject}): Make these return
type_or_decl_base_sptr instead of decl_base_sptr.
(type_diff_base::type_diff_base): Make these take instances of
type_or_decl_base_sptr instead of decl_base_sptr.
(distinct_diff::distinct_diff): Likewise.
(distinct_diff::{first, second}): Make these return
type_or_decl_base_sptr instead of decl_base_sptr.
(distinct_diff::entities_are_of_distinct_kinds): Make these take
instances of type_or_decl_base_sptr instead of decl_base_sptr.
(class function_type_diff): Create this new type. It's a
factorization of the function_decl_diff type.
* src/abg-comparison.cc ():
* src/abg-comp-filter.cc ({harmless, harmful}_filter::visit):
Adjust as diff::{first,second}_subject() now returns a
type_or_decl_base_sptr, no more a decl_base_sptr.
(decls_type, decls_diff_map_type): Remove these typedefs and replace it with ...
(types_or_decls_type, types_or_decls_diff_map_type): ... these.
(struct {decls_hash, decls_equals): Remove these type sand replace them with ...
(struct {types_or_decls_hash, types_or_decls_equals}): ... these.
({type_suppression, variable_suppression}::suppresses_diff):
Adjust.
(diff_context::priv::decls_diff_map): Replace this with ...
(diff_context::priv::types_or_decls_diff_map): ... this.
(diff_context::{has_diff_for, add_diff, get_canonical_diff_for,
set_canonical_diff_for, set_or_get_canonical_diff_for}): Take
type_or_decl_base_sptr instead of decl_base_sptr.
(diff::priv::{first, second}_subject): Make the type of these be
type_or_decl_base_sptr, no more decl_base_sptr.
(diff::priv::priv): Adjust for the subjects of the diff being of
type type_or_decl_sptr now, no more decl_base_sptr.
(diff_less_than_functor::operator()(const diff_sptr, const
diff_sptr) const): Adjust.
(diff::diff): djust for the subjects of the diff being of type
type_or_decl_sptr now, no more decl_base_sptr.
(diff::{first,second}_subject): Make the type of these be
type_or_decl_base_sptr, no more decl_base_sptr.
(report_size_and_alignment_changes): Likewise.
(type_diff_base::type_diff_base): Make the type of this be
type_or_decl_base_sptr instead of type_base_sptr.
(distinct_diff::distinct_diff): Make this take instances of
type_or_decl_base_sptr instead of decl_base_sptr.
(distinct_diff::{first, second, entities_are_of_distinct_kinds}):
Likewise.
(distinct_diff::has_changes): Simplify logic.
(distinct_diff::report): Adjust.
(compute_diff_for_types): Add an additional case to support the
new function_type.
(report_size_and_alignment_changes): Make this take instances of
type_or_decl_base_sptr instead of decl_base_sptr.
(class_diff::priv::member_type_has_changed): Return an instance of
type_or_decl_base_sptr rather than a decl_base_sptr.
(class_diff::report): Adjust.
(diff_comp::operator()(const diff&, diff&) const): Adjust.
(enum function_decl_diff::priv::Flags): Remove.
(function_decl_diff::priv::{first_fn_flags_, second_fn_flags_,
fn_flags_changes_}): Remove.
(function_decl_diff::priv::{fn_is_declared_inline_to_flag,
fn_binding_to_flag}): Remove.
(function_decl_diff::{deleted_parameter_at,
inserted_parameter_at}): Remove.
(function_decl_diff::ensure_lookup_tables_populated): Empty this.
(function_decl_diff::chain_into_hierarchy): Adjust.
(function_decl_diff::function_decl_diff): This now only takes the
subjects. It's body is now empty.
(function_decl_diff::{return_type_diff, subtype_changed_parms,
removed_parms, added_parms, type_diff}): Remove these member
functions.
(function_decl_diff::type_diff): Define new member function.
(function_decl_diff::report): Simplify logic by using the
reporting of the child type diff node.
(compute_diff): Likewise, in the overload for function_decl_sptr
simplify logic by using the child type diff object.
(function_type_diff::priv): Define new type.
(function_type_diff::{function_type_diff,
ensure_lookup_tables_populated, deleted_parameter_at,
inserted_parameter_at, finish_diff_type, first_function_type,
second_function_type, return_type_diff, subtype_changed_parms,
removed_parms, added_parms, get_pretty_representation,
has_changes, has_local_changes, report, chain_into_hierarchy}):
Define new functions.
(compute_diff): Define new overload for function_type_sptr.
* tools/abicompat.cc (options::weak_mode): New data member.
(options::options): Initialize it.
(enum abicompat_status): New enum
(abicompat_status operator|(abicompat_status, abicompat_status))
(abicompat_status& operator|=(abicompat_status &, abicompat_status))
(abicompat_status operator&(abicompat_status, abicompat_status)):
New operators to manipulate the abicompat_status enum.
(display_usage): Add help string for the new --weak-mode option.
(parse_command_line): Add the new --weak-mode command line
argument. If the tool is called with just the application and one
library then assume that we are in the weak mode.
(perform_compat_check_in_normal_mode): Define new function, factorized
from what was in the main function.
(perform_compat_check_in_weak_mode): Define new function.
(struct {fn,var}_change): Define new types.
(main): Use perform_compat_check_in_weak_mode() and
perform_compat_check_in_normal_mode().
* tools/abidiff.cc (main): Adjust.
* tools/abidw.cc: (options::load_all_types): Add new data member.
(options::options): Initialize it.
(display_usage): New help string for --load-all-types.
(parse_command_line): Support the new --load-all-types option.
(main): Adjust and honour the --load-all-types option.
* tools/abilint.cc (main): Adjust.
* doc/manuals/abicompat.rst: Update documentation for the new weak
mode. Also provide stuff that was missing from the examples
provided.
* doc/manuals/abidw.rst: Update documentation for the new
--load-all-types option.
* tests/print-diff-tree.cc (main): Adjust.
* tests/test-diff-dwarf.cc (main): Likewise.
* tests/test-read-dwarf.cc (main): Likewise.
* tests/data/test-abicompat/test0-fn-changed-app: Recompile this.
* tests/data/test-abicompat/libtest5-fn-changed-libapp-v{0,1}.so:
New new test input binaries
* tests/data/test-abicompat/test5-fn-changed-app: Likewise.
* tests/data/test-abicompat/test6-var-changed-app: Likewise.
* tests/data/test-abicompat/libtest6-var-changed-libapp-v{0,1}.so:
Likewise.
* tests/data/test-abicompat/test5-fn-changed-report-0.txt:
Reference output for one test above.
* tests/data/test-abicompat/test6-var-changed-report-0.txt:
Likewise.
* tests/data/test-abicompat/test5-fn-changed-app.cc: Source file
for a binary above.
* tests/data/test-abicompat/test5-fn-changed-libapp-v{0,1}.{h,cc}:
Likewise.
* tests/data/test-abicompat/test6-var-changed-libapp-v{0,1}.{cc,h}:
Likewise.
* tests/data/test-abicompat/test6-var-changed-app.cc: Likewise.
* tests/data/Makefile.am: Add the test related files above to the
source distribution.
* tests/test-abicompat.cc (in_out_spec): Add the new test input
above to the list of inputs to feed to this test harness.
(main): Support taking just the app and one library.
* tests/data/test-read-dwarf/test{0, 1, 2.so, 3.so, 5.o,
8-qualified-this-pointer.so,}.abi: Adjust for void type being
really emitted now, as opposed to just being an empty type.
2015-04-01 Dodji Seketeli <dodji@redhat.com>
18186 - Assertion in abigail::ir::class_decl::hash::operator()
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): When
the size of the class is provided then the class is complete, no
matter if this function called to update the class or to build it
for the first time.
2015-03-31 Sinny Kumari <sinny@redhat.com>
Check if EM_AARCH64, EM_TILEPRO and EM_TILEGX macros are defined in elf.h
* config.h.in: Generated autoheader by configure.ac
for added macros
* configure.ac: Defining HAVE_EM_AARCH64_MACRO,
HAVE_EM_TILEPRO_MACRO and HAVE_EM_TILEGX_MACRO to check
whether EM_AARCH64, EM_TILEPRO and EM_TILEGX macros are defined
in elf.h or not
* src/abg-dwarf-reader.cc (e_machine_to_string): Look for
EM_AARCH64, EM_TILEPRO and EM_TILEGX macros only
if they are defined in elf.h
2015-03-30 Dodji <dodji@ks305400.kimsufi.com>
PR libabigail/18180
* src/abg-hash.cc (class_decl::hash::operator()(const class_decl&)
const): Return zero only for class declarations that are not
resolved.
* tests/data/test-read-write/test20.xml: Fix the output to make a
class definition to reference its declaration, when there was a
forward declaration for it.
2015-03-30 Dodji Seketeli <dodji@redhat.com>
18179 - abidiff crashes on libcangjie
* include/abg-fwd.h (lookup_class_type_in_corpus)
(lookup_class_type_in_translation_unit): Declare new functions.
* src/abg-ir.cc (lookup_class_type_in_translation_unit): Define
new function.
(get_node, convert_node_to_decl): Define new specializations for
the class_decl type.
* src/abg-corpus.cc (lookup_class_type_in_corpus): Define new
function.
* src/abg-dwarf-reader.cc
(read_context::resolve_declaration_only_classes): Lookup class
types specifically.
2015-03-30 Dodji Seketeli <dodji@redhat.com>
Forgot to initialize a data member
* src/abg-reader.cc (read_context::read_context): Initialize the
new m_exported_decls_builder_ data member.
2015-03-30 Dodji Seketeli <dodji@redhat.com>
18166 - Abidiff fails with internal on Libtirpc ABI in XML format
* src/abg-reader.cc (read_context::m_exported_decls_builder_): New
data member.
(read_context::read_context): Initialize it.
(read_context::{type_is_from_translation_unit,
get_exported_decls_builder, set_exported_decls_builder,
maybe_add_fn_to_exported_decls, maybe_add_fn_to_exported_decls,
type_id_new_in_translation_unit}): New member functions.
(read_context::clear_per_translation_unit_data): Clear id->xml
node map here ...
(read_context::clear_per_corpus_data): ... not here.
(read_context::walk_xml_node_to_map_type_ids): Only walk the
sub-tree we are asked to walk.
(read_translation_unit_from_input): Cleanup.
(read_corpus_from_input): Wire populating of exported declarations
of the current corpus.
(build_function_decl, build_var_decl): Populate exported
declarations of the current corpus here.
(build_type_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_array_type_def, build_enum_type_decl, build_type_decl)
(build_template_tparameter): Adjust assert on ID to make sure
it's the first type it's being defined in the current translation
unit.
* tests/data/test-abidiff/test-corpus0-report0.txt: New test
reference output.
* tests/data/test-abidiff/test-corpus0-v{0,1}.so.abi: New test
input.
* tests/test-abidiff.cc (specs): Add the test inputs above to the
list of inputs over which to run the test harness.
(main): Support reading corpora too, as this test harness was
reading just translation units before.
(tests/data/Makefile.am): Add test material above to source
distribution.
2015-03-19 Dodji Seketeli <dodji@redhat.com>
Update the CONTRIBUTING file
* CONTRIBUTING: How to check out the web pages.
2015-03-19 Dodji Seketeli <dodji@redhat.com>
Update website documentation
* doc/website/mainpage.txt: Update the web page.
2015-03-18 Dodji Seketeli <dodji@redhat.com>
Cleanup type canonicalizing logic
* src/abg-ir.cc (type_base::get_canonical_type_for): Cleanup the
logic here. Basically since we are not trying to cache the result
of type hashing anymore, this can be simpler.
2015-03-18 Dodji Seketeli <dodji@redhat.com>
Fix redundancy propagation on node with filtered local changes
*NOT* take in account the categories inherited from its children
nodes. That way, it's possible to know if the *local changes* of a
given node have been filtered out.
* include/abg-comparison.h (diff::{get_local_category,
add_to_local_category, add_to_local_and_inherited_categories,
remove_from_local_category, set_local_category,
is_filtered_out_wrt_non_inherited_categories,
has_local_changes_to_be_reported}): Declare new member functions.
* src/abg-comp-filter.cc ({harmless, harmful}_filter::{visit,
visit_end}): Update local category too.
* src/abg-comparison.cc (diff::priv::local_category_): Add new
data member.
(diff::priv::priv): Initialize it.
(diff::priv::is_filtered_out): Add new member function. This is
factorized out of diff::is_filtered_out().
(diff::is_filtered_out): Re-write in terms of
diff::priv::is_filtered_out().
(diff::{get_local_category, add_to_local_category,
add_to_local_and_inherited_categories, remove_from_local_category,
set_local_category, is_filtered_out_wrt_non_inherited_categories,
has_local_changes_to_be_reported}): Define new member functions.
(suppression_categorization_visitor::visit_begin): Update local
categories too.
(redundancy_marking_visitor::visit_end): If all of the children
nodes of the a diff node N are redundant and if N has filtered-out
local changes, then N is redundant too.
* tests/data/test-diff-filter/libtest28-redundant-and-filtered-children-nodes-v{1,2}.so:
New binary test inputs.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-v{0,1}.cc:
Source code for the binary test inputs above.
* tests/data/test-diff-filter/test28-redundant-and-filtered-children-nodes-report-{0,1}.txt:
New test output references.
* tests/test-diff-filter.cc (in_out_specs): Add the test inputs
above to the set of inputs this test harness has to run over.
* tests/data/Makefile.am: Add the test materials above to the
source distribution.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Various style cleanups
* src/abg-hash.cc (class_decl::hash::operator()(const class_decl&
t) const): Fix comment.
* src/abg-ir.cc (lookup_node_in_scope): Likewise.
(class_decl::add_base_specifier): Use base_spec_sptr rather than
shared_ptr<base_spec>.
(class non_canonicalized_subtype_detector): Fix comment.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Make is_global_scope() return a pointer to the global scope
* include/abg-fwd.h (is_global_scope): Return a global_scope*.
* src/abg-ir.cc (is_global_scope): Likewise.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Add a useful assert in the comparison engine
* src/abg-comparison.cc (qualified_type_diff::report): Assert that
if the qualified type diff node has changes to be reported and no
local change, then its child node must have changes to be
reported.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Fix diff report about non-static data members.
* src/abg-comparison.cc
(class_diff::priv::{get_deleted_non_static_data_members_number,
get_inserted_non_static_data_members_number}): Define new member
functions.
(class_diff::reports): Use the new functions above. Also, add
forgotten new lines where they belong.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Do not cache hash values in decl_base::get_hash
* src/abg-ir.cc (decl_base::get_hash): Do not cache the hash
value.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Do not miss early non-complete type resolution when it's possible
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): A type
that has its size defined is not non-complete. Same if it has a
method or a member type.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Delay non-complete class type resolution up to end of corpus reading
* include/abg-fwd.h (lookup_type_in_corpus): Declare new function.
* src/abg-corpus.cc (lookup_type_in_corpus): Define new function
here.
* include/abg-ir.h (function_types_type): Declare new typedef.
(translation_unit::get_canonical_function_type): Remove member function.
(translation_unit::bind_function_type_life_time): Declare new
member function.
(classes_type): New typedef.
* src/abg-ir.cc
(translation_unit::priv::canonical_function_types_): Remove data
member.
(translation_unit::priv::function_types): New data member.
(translation_unit::get_canonical_function_type): Remove this
function definition.
(translation_unit::bind_function_type_life_time): New function
definition.
(lookup_node_in_scope): Ensure that the type returned is
complete.
* src/abg-dwarf-reader.cc (string_classes_map): New typedef.
(read_context::decl_only_classes_map_): New data member.
(read_context::declaration_only_classes): New accessor.
(read_context::{maybe_schedule_declaration_only_class_for_resolution,
is_decl_only_class_scheduled_for_resolution,
resolve_declaration_only_classes, current_elf_file_is_executable,
current_elf_file_is_dso}): Define new member functions.
(read_context::clear_per_translation_unit_data): Do not clear the
data structures that associate DIEs to decls/types or that contain
the types to canonicalize here. Rather, clear them ...
(read_context::clear_per_corpus_data): ... here instead.
(read_context::build_translation_unit_and_add_to_ir): Do not
perform late type canonicalizing here. Rather, do it ...
(read_debug_info_into_corpus): ... here instead. And before that,
call read_context::clear_per_corpus_data() and the new
read_context::resolve_declaration_only_classes() here.
(build_class_type_and_add_to_ir): Schedule the non-complete types
for resolution to complete types. Assert that base classes that
are non-complete are scheduled to be completed.
(build_function_decl): Do not try to canonicalize function types
this early, systematically. Now, all the non-complete types needs
to be completed before starting canonicalizing. So let function
types go through the normal processes of deciding when to
canonicalize them. But then, bind the life time of the function
type to the life time of the current translation unit.
(maybe_canonicalize_type): If a class type is non-complete,
schedule it for late canonicalizing.
* src/abg-hash.cc (class_decl::hash::operator()(const class_decl&)
const): During hashing, a base class should be complete.
* src/abg-reader.cc
(read_context::clear_per_translation_unit_data): Do not clear
id/xml node, and type maps here. Rather, clear it ...
(read_context::clear_per_corpus_data): ... here instead.
(read_translation_unit_from_input): Do not perform late
canonicalizing here. Rather, do it ...
(read_corpus_from_input): ... here. Also, call the new
read_context::clear_per_corpus_data() here.
(build_function_decl): Do not canonicalize function types here so
early. Rather, bind the life time of the function type to the
life time of the translation unit.
* src/abg-writer.cc (write_translation_unit): Do not clear the
type/ID map here.
* tests/data/test-read-dwarf/test2.so.abi: Adjust test input.
2015-03-17 Dodji Seketeli <dodji@redhat.com>
Add --no-architecture option to abidw
* tools/abidw.cc (options::write_architecture): New flag.
(options::options): Initialize it.
(display_usage): Add usage string for the new --no-architecture
option.
(parse_command): Parse the new --no-architecture command line
option.
(main): Ignore the architecture name if required by the user.
2015-03-13 Dodji Seketeli <dodji@redhat.com>
We shouldn't build qualified types with empty underlying type
* src/abg-ir.cc (qualified_type_def::qualified_type_def): Assert
that we shouldn't build qualified types with empty underlying
type.
2015-03-13 Dodji Seketeli <dodji@redhat.com>
Add an overload for is_type() that takes naked pointers
* include/abg-fwd.h (is_type): Declare new overload that takes a
naked pointer.
* src/abg-ir.cc (is_type): Define new overload that takes a naked
pointer.
2015-03-13 Dodji Seketeli <dodji@redhat.com>
Declaration-only classes shouldn't have canonical types
* include/abg-fwd.h (keep_type_alive): Declare new function.
* src/abg-ir.cc (strip_typedef): Simplify logic. Support types
that are not canonicalized.
(type_base::get_canonical_type_for): For declaration-only classes,
return an empty canonical class, forcing the class to be compared
structurally.
(keep_type_alive): Define new function.
* src/abg-hash.cc ({decl_base, type_decl, scope_type_decl,
qualified_type_def, pointer_type_def, reference_type_def,
array_type_def, enum_type_decl, typedef_decl,
class_decl::member_class_template, class_decl, type_tparameter,
template_tparameter, }::hash::operator()): Do not cache the
computed hash.
2015-03-13 Dodji Seketeli <dodji@redhat.com>
Fix redundancy categorization propagation
* src/abg-comparison.cc (redundancy_marking_visitor::visit_end):
Consider the cases of changes that are a filtered out.
* tests/data/test-diff-filter/libtest27-redundant-and-filtered-children-nodes-v{0,1}.so:
New test binaries to use as test input.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-report-{0,1,2}.txt:
New test result baselines.
* tests/data/test-diff-filter/test27-redundant-and-filtered-children-nodes-v{0,1}.cc:
Source code for the test input binaries above.
* tests/test-diff-filter.cc (in_out_spec): Add the binaries to the
test inputs used for this test harness.
* tests/data/Makefile.am: Add the new test material above to the
distribution.
2015-03-13 Dodji Seketeli <dodji@redhat.com>
Fix thinko in has_virtual_mem_fn_change().
* src/abg-comp-filter.cc (has_virtual_mem_fn_change): Fix thinko.
2015-03-13 Dodji Seketeli <dodji@redhat.com>
From inside the comparison engine re-use IR's equality operators
* include/abg-ir.h (operator==(scope_decl_sptr, scope_decl_sptr)):
Declare.
(operator==(type_decl_sptr, type_decl_sptr)): Likewise.
(operator==(enum_type_decl_sptr, enum_type_decl_sptr)): Likewise.
* src/abg-comparison.cc (diff_length_of_decl_bases)
(diff_length_of_type_bases): Remove these static functions.
(class_diff::has_changes): Re-use the comparison operator for
class_decl_sptr.
(type_decl_diff::has_changes): Re-use the comparison operator for
type_decl_sptr.
* src/abg-ir.cc (operator==(scope_decl_sptr, scope_decl_sptr)):
Define.
(operator==(type_decl_sptr, type_decl_sptr)): Likewise.
(operator==(enum_type_decl_sptr, enum_type_decl_sptr)): Likewise.
2015-03-11 Dodji Seketeli <dodji@redhat.com>
Remove unnecessary vertical white space from diff report
* src/abg-comparison.cc (class_diff::report): When reporting
virtual member functions make sure to emit the newline only if one
report for member function has already been emitted.
2015-03-10 Dodji Seketeli <dodji@redhat.com>
Cleanup array_type_def::is_infinite
* src/abg-ir.cc (array_type_def::is_infinite): Style cleanup.
2015-03-10 Dodji Seketeli <dodji@redhat.com>
Make a function static as it oughts to be
* src/abg-ir.cc (get_type_representation): Make this static.
2015-03-10 Dodji Seketeli <dodji@redhat.com>
Canonicalize function types
* src/abg-dwarf-reader.cc (build_function_decl): Call
maybe_canonicalize_type to canonicalize the function type.
2015-03-10 Dodji Seketeli <dodji@redhat.com>
Use more naked pointers when comparing function types
* src/abg-ir.cc (equals): In the overload for function types, use
more naked pointers, less smart pointers.
2015-03-10 Dodji Seketeli <dodji@redhat.com>
Pass a bunch of smart pointers by reference
* include/abg-fwd.h (get_member_is_static, is_member_function)
(get_member_function_is_ctor, set_member_function_is_ctor)
(get_member_function_is_dtor, set_member_function_is_dtor)
(get_member_function_is_const, set_member_function_is_const)
(get_member_function_vtable_offset)
(set_member_function_vtable_offset)
(get_member_function_is_virtual): Declare the smart pointer
parameter of these as being passed by reference.
* include/abg-ir.h (get_member_access_specifier)
(get_member_is_static, get_member_access_specifier)
(set_member_function_is_ctor, set_member_function_is_const)
(set_member_function_vtable_offset): Likewise, for these friend
declarations to the decl_base type.
* src/abg-ir.cc (get_member_access_specifier)
(get_member_is_static, is_member_function)
(get_member_function_is_ctor, set_member_function_is_ctor)
(get_member_function_is_dtor, set_member_function_is_dtor)
(get_member_function_is_const, set_member_function_is_const)
(get_member_function_vtable_offset)
(set_member_function_vtable_offset)
(get_member_function_is_virtual): In these definitions, the smart
pointer parameter is passed by reference.
2015-03-10 Dodji Seketeli <dodji@redhat.com>
Make decl_base::get_context_rel() return a naked pointer
* include/abg-fwd.h (set_member_is_static): Add an overload that
takes the member as a reference to a smart pointer.
(set_member_function_{is_dtor, is_ctor, is_const, vtable_offset,
is_virtual}): Pass the member function as a reference.
(set_member_function_is_const, set_member_function_is_virtual):
Pass the member function as a non-const reference.
* include/abg-ir.h (decl_base::get_context_rel): Return a naked
pointer.
(set_member_is_static, set_member_function_is_virtual): Adjust
this friend declaration.
(set_member_access_specifier): Add an overload that takes a
reference to the member. Pass a reference to smart pointer to the
other overload.
(set_member_function_is_{is_ctor,is_dtor,is_const,is_virtual,vtable_offset}):
Take a non-const reference to function_decl.
* src/abg-ir.cc (decl_base::get_context_rel): Likewise.
(equals(const decl_base&, const decl_base&, change_kind*)):
Adjust.
(equals(const var_decl&, const var_decl&, change_kind*)):
Likewise.
(get_member_access_specifier, get_member_is_static)
(set_data_member_offset, get_data_member_offset)
(set_data_member_is_laid_out, get_data_member_is_laid_out)
(get_member_function_is_ctor, set_member_function_is_ctor)
(get_member_function_is_dtor, set_member_function_is_dtor)
(get_member_function_is_const, set_member_function_is_const)
(get_member_function_vtable_offset)
(set_member_function_vtable_offset)
(get_member_function_is_virtual, set_member_function_is_virtual):
Likewise.
(set_member_access_specifier): Add an overload that takes a
reference to decl_base.
(set_member_is_static, set_member_function_{is_dtor, is_ctor,
is_const, vtable_offset, is_virtual}): Pass the member function as
a reference.): Add an overload that takes the member as a
reference, and write the older overload in terms of the new one.
2015-03-09 Dodji Seketeli <dodji@redhat.com>
Make overloads of decl_base::get_qualified_name() return a reference
* incude/abg-ir.h (decl::get_{qualified_name,
qualified_parent_name}): Return a reference to a string rather
than a copy of a string.
(qualified_type_def::get_qualified_name): Likewise.
(reference_type_def::get_qualified_name): Likewise.
(array_type_def::get_qualified_name): Likewise.
(class enum_type_decl::enumerator): Make this is an out-of-line
pimpled class implementation.
(enum_type_decl::enumerator::{get, set}_enum_type): Declare new
method.
(enum_type_decl::enumerator::get_qualified_name): Change this so
that it doesn't take the name of the enum type anymore.
* src/abg-comparison.cc (enum_diff::report): Adjust for
enum_type_decl::enumerator::get_qualified_name() not taking the
name of the enum type anymore.
* src/abg-ir.cc (decl_base::get_qualified_parent_name): Return a
reference to string.
(decl_base::get_qualified_name): Likewise.
(decl_base::get_qualified_name(string&)): Use the new verson of
decl_base::get_qualified_name() that returns a reference.
({qualified_type_def, pointer_type_def, reference_type_def,
array_type_def}::get_qualified_name()): Return a string reference.
({qualified_type_def, pointer_type_def, reference_type_def,
array_type_def}::get_qualified_name(string& qualified_name)
const): Use the new qualified_type_def::get_qualified_name() that
returns a string reference.
(class enum_type_decl::priv): New type.
(enum_type_decl::{get_underlying_type, get_enumerators}): Adjust.
(enum_type_decl::{enumerator::enumerator, enumerator::operator==,
enumerator::get_name, enumerator::get_qualified_name,
enumerator::set_name, enumerator::get_value,
enumerator::set_value, enumerator::get_enum_type,
enumerator::set_enum_type}): Define methodes out-of-line here.
2015-02-24 Dodji Seketeli <dodji@redhat.com>
Harden strip_typedef
* src/abg-ir.cc (strip_typedef): Consider that the underlying type
can be void.
2015-02-24 Dodji Seketeli <dodji@redhat.com>
When reading DWARF set member type access where the type is built
* include/abg-fwd.h (is_class(decl_base*)): Return a class_decl*
rather than just a bool.
* abg-ir.cc (is_class(decl_base*)): Return a class_decl* rather
than just a bool. Simplify the implementation.
* src/abg-dwarf-reader.cc
(maybe_set_member_type_access_specifier): Define new static
function.
(build_ir_node_from_die): Remove the is_member_type flag. When
building member types set their access specifier. Simplify the
logic of detecting that a type is a member type; basically
delegate taht to the new maybe_set_member_type_access_specifier().
(build_class_type_and_add_to_ir): Do not try to set the member
type access specifiers anymore.
(build_qualified_type, build_pointer_type, build_reference_type)
(build_typedef_type, build_var_decl, build_function_decl): Adjust.
2015-02-24 Dodji Seketeli <dodji@redhat.com>
Fix enum_diff::has_changes()
* src/abg-comparison.cc (enum_diff::has_changes): Just use the
normal comparison operator to compare the two enums here. It's
fast now.
2015-02-23 Dodji Seketeli <dodji@redhat.com>
Build the set of exported decls directly during DWARF loading
* include/abg-ir.h ({var,function}_decl::get_id): Return a
reference.
* src/abg-ir.cc ({var,function}_decl::get_id): Return a reference
to the string rather than copying it over.
* include/abg-corpus.h (class corpus::exported_decls_builder):
Declare new type.
(corpus::{sort_functions, sort_variables,
maybe_drop_some_exported_decls, get_exported_decls_builder}):
Declare new methods.
* src/abg-corpus.h (corpus::exported_decls_builder::priv): Define
new type.
(class symtab_build_visitor_type): Remove this type that is
useless now.
(corpus::exported_decls_builder::{exported_decls_builder,
exported_functions, exported_variables,
maybe_add_fn_to_exported_fns, maybe_add_var_to_exported_vars}):
Define new functions.
(corpus::priv::is_public_decl_table_built): Remove this data
member. It's now useless.
(corpus::priv::priv): Adjust.
(corpus::priv::build_public_decl_table): Remove this member
function. It's now useless.
(corpus::{priv::build_unreferenced_symbols_tables, get_functions,
get_variables}): No need to build the public decls table here.
It's already built by the time the corpus is read from DWARF now.
(corpus::{sort_functions, sort_variables,
maybe_drop_some_exported_decls, get_exported_decls_builder}):
Define new member functions.
* src/abg-dwarf-reader.cc (read_context::exported_decls_builder):
New data member.
(read_context::read_context): Initialize it.
(read_context::{exported_decls_builder,
maybe_add_fn_to_exported_fns, maybe_add_var_to_exported_vars}):
Define new member functions.
(read_debug_info_into_corpus): Get the the new
'exported_decls_builder' object from the corpus and stick it into
the read context so the DWARF reading code can use it to build the
exported decls set. When the DWARF reading is done, sort the set
of exported functions and variables that was built.
(build_ir_node_from_die): When a function or variable is built,
consider putting it into the set of exported decls.
* tools/abicompat.cc (main): Now that the exported decls is built
*before* we had a chance to stick the list of symbol IDs to keep,
call corpus::maybe_drop_some_exported_decls() to update the set of
exported decls we should consider for the corpus.
was applied to that list and the final
2015-02-22 Dodji Seketeli <dodji@redhat.com>
Fix canonicalizing of member types ... *AGAIN*
* src/abg-dwarf-reader.cc (build_ir_node_from_die): For typedefs,
we don't need to test that the current scope is a class to know
that we are looking at a member type. Just looking at the
is_member flag is enough.
So the issue arises when for instance, we are reading a class that
defines a member typedef (or enum) and uses that enum as the type of a
data member. When reading that data member (before reading the
definition of the typedef), we read the type of the data member; so we
hit the typedef. But build_ir_node_from_die() cannot fully construct
the scope of the typedef before handing off the typedef because we are
currently building it! So it hands out a non-complete version of the
class that is being built; 'is_member' is not set to 'true' because
we are getting the type of the data member; it's not *necessarily* a
member type. So we need to check !is_class_type(scope) to know if we
are given a member type. I am now thinking that the "is_member" flag
is actually useless. I think I'll remove it in a later patch.
Anyway, this fixes 'abidiff libabigail.so libabigail.so' again. I
have some stashed patches that brings it's time down to ~ 45 seconds.
So we are getting close to being able to include that *ultimate* test in
regression test suite. Oh well.
* src/abg-dwarf-reader.cc (build_ir_node_from_die): When building
typedefs, enum and memeber classes, check that the scope is a
member class to detect if we are building a member type. In which
case the caller is going to handle the canonicalizing of the
member type *after* it's access specification has been adjusted.
Otherwise, that adjustments happens after the type has been
canonicalized and bad things happen at comparison type.
2015-02-21 Dodji Seketeli <dodji@redhat.com>
Bug 17649 Avoid endless looping on diff graph with cycles
* include/abg-comp-filter.h (harm{less,ful}_filter::visit_end):
Declare new methods.
* include/abg-comparison.h (diff_context::maybe_apply_filters):
Remove the traverse_nodes_once flag.
* src/abg-comp-filter.cc (apply_filter): Force the traversing to
operate in cycle avoidance mode.
(harm{less,ful}_filter::visit): Update the category of the
canonical node too.
(harm{less,ful}_filter::visit_end): Define new method.
* src/abg-comparison.cc (diff_context::maybe_apply_filters):
Remove the traverse_nodes_once flag. Adjust. Simplify logic.
(diff::traverse): Always call diff_node_visitor::{begin,end}. If
the node has already been visited previously then do not call
diff_node_visitor::visit() and do not visit the children nodes.
(category_propagation_visitor::visit_end): If the node has
already been visited, then propagate the category from the
canonical nodes of the children nodes.
(propagate_categories): Force the traversing to operate in cycle
avoidance mode.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Add missing new line after reporting alignment changes
* src/abg-comparison.cc (distinct_diff::report): After calling
report_size_and_alignment_changes, one needs to add a new line if
some stuff got emitted out the output stream.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Add type checking overloads that ease their calling from GDB
* include/abg-fwd.h (is_class_type, is_pointer, is_reference_type)
(is_qualified_type): Declare overloads that take naked (non-smart)
pointers.
* src/abg-ir.cc (is_class_type, is_pointer, is_reference_type)
(is_qualified_type): Define overloads that take naked (non-smart)
pointers.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Remove overly eager assert in distinct_diff::report
* src/abg-comparison.cc (distinct_diff::report): Remove over-eager
assert.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Factorize late canonicalizing code in the dwarf reader
* src/abg-dwarf-reader.cc
(read_context::{canonicalize_types_scheduled,
perform_late_type_canonicalizing}): Factorize these from ...
(build_translation_unit_and_add_to_ir): ... here.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Rename schedule_type_for_canonicalization -> schedule_type_for_late_canonicalization
* src/abg-dwarf-reader.cc
(read_context::schedule_type_for_late_canonicalization): Renamed
read_context::schedule_type_for_canonicalization into this. Also,
add some sanity checking code in there.
(build_class_type_and_add_to_ir, maybe_canonicalize_type): Adjust.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Adjust semantics of the 'is_member' flag of build_ir_node_from_die()
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Rename
is_member into is_member_type. Adjust.
(get_scope_for_die, build_translation_unit_and_add_to_ir)
(build_namespace_decl_and_add_to_ir): Adjust.
(build_class_type_and_add_to_ir): Adjust. Adjust set to false
when calling build_ir_node_from_die() to build a function_decl.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Simplify canonicalizing handling for typedefs
* src/abg-dwarf-reader.cc (build_ir_node_from_die): For typedefs,
we don't need to test that the current scope is a class to know
that we are looking at a member type. Just looking at the
is_member flag is enough.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Do not miss canonicalizing opportunities on non-member class types
* src/abg-dwarf-reader.cc (build_ir_node_from_die): When a class
is not a member type, then it at least ought to be scheduled for
late canonicalizing.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Fix handling of canonicalizing of member enum types
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Once we've
built the enum type by calling build_enum_type(), do not try to
canonicalize it here if it's a member type. The calling
build_class_type_and_add_to_ir() must deal with it already.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Stick qualified, pointer, reference and array types into the global scope
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Do not
consider qualified, pointer, reference and array types as member
types. Only typedef, class and enum types are.
(build_ir_node_from_die): Stick base, pointer, reference,
qualified and array types into the global scope.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Avoid creating multiple versions of certain composite types
* src/abg-dwarf-reader.cc (build_qualified_type)
(build_pointer_type_def, build_reference_type, build_array_type)
(build_typedef_type): If the composite type we are about to create
was already created, just return the one that exists already.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Do not forget to canonicalize enum underlying type and void type
* src/abg-dwarf-reader.cc (build_enum_type): Canoncialize the
underlying type of the enum type.
(build_ir_node_for_void_type): Canonicalize the void type.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Do not forget to associate DIE to the types they represent
* src/abg-dwarf-reader.cc (build_type_decl, build_enum_type)
(build_qualified_type, build_pointer_type_def)
(build_reference_type, build_typedef_type)
(build_class_type_and_add_to_ir): Take a new flag that says if the
DIE is from the alternate debug info section or not. Perform the
DIE->type association in these functions. Note that in
build_class_type_and_add_to_ir we are now doing the DIE->type
association even for declaration-only classes. And for member
types, do not bother doing the association because it's already
been done by build_ir_node_from_die().
(build_ir_node_from_die): Do not do the DIE->type association here
anymore. Adjust to the new signature of the build_* functions
above that actually build the types.
2015-02-20 Dodji Seketeli <dodji@redhat.com>
Clear per-TU data before reading debub info for a TU
* src/abg-dwarf-reader.cc
(read_context::die_type_map): New accessor for the two DIE->Type
maps we have; the one of the main debug info section and the one
of the alternate debug info section.
(read_context::{associate_die_to_type,
lookup_type_from_die_offset}): use the new die_type_map()
accessor.
(read_context::clear_per_translation_unit_data): Factorize this
from build_translation_unit_and_add_to_ir(). Also, add code to
clear the DIE->type map as well as the vectors of offsets of the
types of the DIEs to canonicalize after the translation unit has
been read.
2015-02-19 Dodji Seketeli <dodji@redhat.com>
Fix the new regression test for type canonicalizing
* tests/runtestcanonicalizetypes.sh.in (binaries): Refer to
abg-tools-utils, not abg-tools-utils.o; the extension is computed
automatically, depending on the underlying platform.
2015-02-19 Dodji Seketeli <dodji@redhat.com>
Make strip_typedef() act on canonical types only
* include/abg-fwd.h (is_compatible_with_class_type): Declare new
function.
(canonicalize): Move the declaration here, from ...
* include/abg-ir.h (canonicalize): ... here.
* src/abg-ir.cc (strip_typedef): Assert that the input type is
canonicalized. Make sure that weak references are on
canonicalized types. Make sure that the returned type is a
canonical one.
(canonicalize): Make this return the canonical type that it has
computed.
* src/abg-comp-filter.cc (type_size_changed): Use the new
is_compatible_with_class_type() function, instead of
is_class_type().
2015-02-18 Dodji Seketeli <dodji@redhat.com>
Speed up function_decl::get_id() and var_decl::get_id()
* src/abg-ir.cc (var_decl::priv::id_): New data member.
(var_decl::get_id): Cache the result on the first invocation and
and returns it on subsequent invocations.
(function_dec::priv::id_): New data member.
(function_decl::get_id): Cache the result on the first invocation
and and returns it on subsequent invocations.
2015-02-18 Dodji Seketeli <dodji@redhat.com>
Speed up symbol version reading
* src/abg-dwarf-reader.cc (find_symbol_table_section)
(get_symbol_versionning_sections): Forward declare these existing
static functions.
(read_context::{symtab_section_,
symbol_versionning_sections_loaded_,
symbol_versionning_sections_found_, versym_section_
verdef_section, verneed_section}): New data members.
(read_context::read_context): Initialize them.
(read_context::{find_symbol_table_section,
get_symbol_versionning_sections, get_version_for_symbol}):
Implement a caching version of their exisiting non-caching
counterpart.
(read_context::lookup_elf_symbol_from_index): Use the new caching
functions read_context::find_symbol_table_section and
read_context::get_version_for_symbol.
(read_context::load_symbol_maps): Likewise, use the new caching
function read_context::find_symbol_table_section.
2015-02-17 Dodji Seketeli <dodji@redhat.com>
Stop traversing function/variable node when added to symbol table
* src/abg-corpus.cc (symtab_build_visitor_type::visit_begin):
Replace symtab_build_visitor_type::visit_end with this and return
false.
2015-02-13 Dodji Seketeli <dodji@redhat.com>
Do not apply diff filters sub-tree not carrying changes
* src/abg-comp-filter.cc ({harmless, harmful}_filter::visit): Do
not try to do the categorizing on a diff sub-tree that does
not carry any change.
* src/abg-comparison.cc (diff_context::maybe_apply_filters): Do
not bother trying to apply the filters on a diff sub-tree that
does not carry any change.
2015-02-13 Dodji Seketeli <dodji@redhat.com>
Canonicalize types either early or late after TU reading
* include/abg-fwd.h (is_class_type)
(type_has_non_canonicalized_subtype): Declare new functions.
(is_member_type): Remove the overload that takes a decl_base_sptr.
It's superfluous. We just need the one that takes a
type_base_sptr.
* include/abg-ir.h (translation_unit::{is_constructed,
set_is_constructed}): Add new methods.
(class_decl::has_virtual_member_functions): Likewise.
(class decl_base): Makes it virtually inherit ir_traversable_base.
(class type_base): Make this virtually inherit traversable_base
too.
(type_base::canonicalize): Renamed enable_canonical_equality
into this.
(type_base::traverse): Declare new virtual method.
(canonicalize): Renamed enable_canonical_equality into this.
(scope_type_decl::traverse): Declare new virtual method.
(namespace_decl::get_pretty_representation): Declare new virtual
method.
(function_type::traverse): Likewise.
(class_decl::base_spec::traverse): Likewise.
(ir_node_visitor::visit): Remove the overloads and replace each of
them with a pair of ...
(ir_node_visitor::{visit_begin, visit_end}): ... of these.
* include/abg-traverse.h (traversable_base::visiting): New
method.
(traversable_base::visiting_): New data member.
(traversable_base::traversable_base): New constructor.
* src/abg-ir.cc ({scope_decl, type_decl, namespace_decl,
qualified_type_def, pointer_type_def, reference_type_def,
array_type_def, enum_type_decl, typedef_decl, var_decl,
function_decl, function_decl::parameter, class_decl,
class_decl::member_function_template,
class_decl::member_class_template, function_tdecl,
class_tdecl}::traverse): Fix this to properly set the
traversable_base::visiting_ flag and to reflect the new signatures
of the ir_node_visitor methods.
({type_base, scope_type_decl, function_type,
class_decl::base_spec}::traverse): New method.
(type_base::get_canonical_type_for): Handle the case of the type
already having a canonical type. Properly hash the type using the
dynamic type hasher. Look through declaration-only classes to
consider the definition of the class instead. Fix logic to have a
single pointer of return, to ease debugging.
(canonicalize): Renamed enable_canonical_equality into this.
(namespace_decl::get_pretty_representation): Define new method.
(ir_node_visitor::visit): Replace each of these overloads with a
pair of visit_begin/visit_end ones.
(translation_unit::priv::is_constructed_): New data member.
(translation_unit::priv::priv): Initialize it.
(translation_unit::{is_constructed, set_is_constructed}): Define
new methods.
(is_member_type(const decl_base_sptr)): Remove.
(is_class_type(decl_base *d)): Define new function.
(class_decl::has_virtual_member_functions): Define new method.
(equals(const class_decl&, const class_decl&, change_kind*)): If
the containing translation unit is not constructed yet, do not
take virtual member functions in account when comparing the
classes. This is because when reading from DWARF, there can be
DIEs that change the number of virtual member functions after the
DIE of the class. So one needs to start taking virtual members
into account only after the translation unit has been constructed.
(class non_canonicalized_subtype_detector): Define new type.
(type_has_non_canonicalized_subtype): Define new function.
* src/abg-corpus.cc (symtab_build_visitor_type::visit): Renamed
this into symtab_build_visitor_type::visit_end.
* src/abg-dwarf-reader.cc (die_type_map_type): New typedef.
(die_class_map_type): This is now a typedef on a map of
Dwarf_Off/class_decl_sptr.
(read_context::{die_type_map_, alternate_die_type_map_,
types_to_canonicalize_, alt_types_to_canonicalize_}): New data
members.
(read_context::{associate_die_to_decl,
associate_die_to_decl_primary}): Make these methods public.
(read_context::{associate_die_to_type,
lookup_type_from_die_offset, is_wip_class_die_offset,
types_to_canonicalize, schedule_type_for_canonicalization}):
Define new methods.
(build_type_decl, build_enum_type)
(build_class_type_and_add_to_ir, build_qualified_type)
(build_pointer_type_def, build_reference_type, build_array_type)
(build_typedef_type, build_function_decl): Do not canonicalize
types here.
(maybe_canonicalize_type): Define new function.
(build_ir_node_from_die): Take a new flag that says if the ir node
is a member type/function or not. Early-canonicalize base types.
Canonicalize composite types that have only canonicalized
sub-types. Schedule the other types for late canonicalizing. For
class types, early canonicalize those that are non-member types,
that are fully constructed and that have only canonicalized
sub-types. Adjust to the new signature of build_ir_node_from_die.
(get_scope_for_die, build_namespace_decl_and_add_to_ir)
(build_qualified_type, build_pointer_type_def)
(build_reference_type, build_array_type, build_typedef_type)
(build_var_decl, build_function_decl): Adjust for the new
signature of build_ir_node_from_die.
(build_translation_unit_and_add_to_ir): Likewise. Perform the
late canonicalizing of the types that have been scheduled for
that.
(build_class_type_and_add_to_ir): Return a class_decl_sptr, not a
decl_base_sptr. Adjust for the new signature of
build_ir_node_from_die. Early canonicalize member types that are
created and added to a given class, or schedule them for late
canonicalizing.
* src/abg-reader.cc (class read_context::{m_wip_classes_map,
m_types_to_canonicalize}): New data members.
(read_context::{clear_types_to_canonicalize,
clear_wip_classes_map, mark_class_as_wip, unmark_class_as_wip,
is_wip_class, maybe_canonicalize_type,
schedule_type_for_late_canonicalizing,
perform_late_type_canonicalizing}): Add new method definitions.
(read_context::clear_per_translation_unit_data): Call
read_context::clear_types_to_canonicalize().
(read_translation_unit_from_input): Call
read_context::perform_late_type_canonicalizing() at the end of the
function.
(build_function_decl): Fix the function type canonicalizing (per
translation) that was already in place. Do the canonicalizing of
these only when the type is fully built. Oops. This was really
brokend. Also, when the function type is constructed, consider it
for type canonicalizing.
(build_type_decl): Early canonicalize basic types.
(build_qualified_type_decl, build_pointer_type_def)
(build_pointer_type_def, build_reference_type_def)
(build_array_type_def, build_enum_type_decl, build_typedef_decl):
Handle the canonicalizing for these composite types: either early
or late.
(build_class_decl): Likewise. Also, mark this class a 'being
built' until it's fully built. This helps the canonicalizing code
to know that it should leave a class alone until it's fully built.
* tests/test-ir-walker.cc (struct name_printing_visitor): Adjust
to the visitor methods naming change.
* configure.ac: Generate the tests/runtestcanonicalizetypes.sh
testing script from tests/runtestcanonicalizetypes.sh.in.
* tests/runtestcanonicalizetypes.sh.in: Add the template for the
new runtestcanonicalizetypes.sh script that test for type
canonicalizing.
* tests/Makefile.am: Add the new runtestcanonicalizetypes.sh
regression testing script to the build system.
2015-02-18 Dodji Seketeli <dodji@redhat.com>
Factorize per TU data clearing in the xml-abi reader
* src/abg-reader.cc
(read_context::clear_per_translation_unit_data): Factorize this
function out of ...
(read_context::read_translation_unit_from_input): ... this one.
2015-02-13 Dodji Seketeli <dodji@redhat.com>
Use the deep type sptr equality operator when possible
* src/abg-ir.cc (equals): On function_decl overload, use the deep
sptr type equality operator when comparing types.
(non_type_tparameter::operator==): Likewise.
2015-02-18 Dodji Seketeli <dodji@redhat.com>
Properly compare virtualness of member functions
* src/abg-ir.cc (equals(const function_decl&, const
function_decl&, change_kind*)): Compare virtualness of member
function before comparing their vtable offsets.
2015-02-13 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-ir.h (reference_type_def::get_pointed_to_type): use
type_base_sptr, rather than shared_ptr<type_base>
(typdef_decl::get_underlying_type): Likewise.
(function_decl::get_return_type): Likewise.
(function_decl::set_type): Likewise.
(class_decl::member_class_template::as_class_tdecl): Likewise.
* src/abg-comparison.cc (compute_diff): Remove useless vertical
space.
(corpus_diff::traverse): Add a vertical space after this.
* src/abg-dwarf-reader.cc (type_ptr_map): Remove this unused
typedef.
(get_version_for_symbol)
(finish_member_function_reading): Fix the comments of these
functions.
* src/abg-reader.cc (build_function_decl): Return a
function_decl_sptr rather than a shared_ptr<function_decl>.
(build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_array_type_def, build_typedef_decl, build_class_decl): Use
the is_<someking_of_type> functions here, rather than using the
dynamic cast. This increases maintainability.
2015-02-11 Dodji Seketeli <dodji@redhat.com>
Optimize compressed debug info reading for speed
* src/abg-dwarf-reader.cc
(find_last_import_unit_point_before_die): Look for the inclusion
point of the partial unit in reverse topological order.
2015-02-10 Dodji Seketeli <dodji@redhat.com>
Share private data of class_diff nodes
* src/abg-comparison.cc (class_diff::class_diff): Do not
initialize the private data of class_diff here.
(compute_diff): In the overload for class_diff, initialize the
private data of the new instance of class_diff to the private data
of its canonical instance.
(redundancy_marking_visitor::visit_begin): If a node is marked
redundant, do not dare visit its children. In cases of classes
that have members that reference themselves, this prevents us from
wrongly marking some of the data member changes as being
redundant.
2015-02-10 Dodji Seketeli <dodji@redhat.com>
Do not crash when applying filters to a NULL diff
* src/abg-comparison.cc (diff_context::maybe_apply_filters): Do
not crash when called with a NULL diff.
2015-02-09 Dodji Seketeli <dodji@redhat.com>
Initial implementation of canonical type comparison in the IR
* include/abg-ir.h (class type_base): Pimplify this class.
(type_base::canonical_types_map_type): New typedef.
(type_base::{get_canonical_types_map, get_canonical_type_for,
get_canonical_type}): Declare new member functions.
(enable_canonical_equality): Declare new function.
(struct type_base::hash): Declare this functor here.
* src/abg-ir.cc ():
* src/abg-dwarf-reader.cc (build_type_decl, build_enum_type)
(build_class_type_and_add_to_ir, build_qualified_type)
(build_pointer_type_def, build_reference_type, build_array_type)
(build_typedef_type, build_function_decl): Enable canonical
equality for the resulting type returned by these functions.
* src/abg-hash.cc (type_base::hash::operator()(const type_base&)):
Adjust as this is now out-of-line. Also, add two overloads for
type_base* and type_base_sptr.
(struct type_base::priv): Define new type for private data of
type_base.
(type_base::{get_canonical_types_map, get_canonical_type_for,
get_canonical_type}): Define new member functions.
(enable_canonical_equality): Define new function
(type_base::{type_base, set_size_in_bits, get_size_in_bits,
set_alignment_in_bits, get_alignment_in_bits}): Adjust.
({type_decl, scope_type_decl, qualified_type_def,
pointer_type_def, reference_type_def, array_type_def,
enum_type_decl, typedef_decl, function_type,
class_decl}::operator==): If the types being compared have
canonical type then use them for comparison.
2015-02-07 Dodji Seketeli <dodji@redhat.com>
Don't walk the diff tree when there are no suppressions
* src/abg-comparison.cc (apply_suppressions): Do not walk the diff
tree to apply suppressions when there are no suppressions to
apply.
2015-02-07 Dodji Seketeli <dodji@redhat.com>
Speedup some diff::has_changes() implementations
* src/abg-comparison.cc ({distinct_diff, var_diff,
class_diff}::has_changes): Use the hash value of the diff subjects
to detect quickly if they differ. If they don't, then go the slow
path of comparing the types.
2015-02-05 Dodji Seketeli <dodji@redhat.com>
Get out as early as possible when comparing different ABI artefacts
* include/abg-ir.h (equal): Turn the last parameter of type
change_kind& into a change_kind*. Do this on all the overloads'
declarations.
* src/abg-ir.cc (equal): Do the same for the definitions of the
overloads and adapt them to report about the kind of changes makes
the two ABI artifact different -- only if the change_kind pointer
is non-null. That way, callers have a way to choose if they want
to go the expensive route of knowing what kind of changes there
are.
({decl_base, scope_decl, type_base, scope_type_decl,
qualified_type_def, pointer_type_def, pointer_type_def,
reference_type_def, array_type_def, enum_type_decl, typedef_decl,
var_decl, function_type, function_decl, function_decl::parameter,
class_decl::base_spec, class_decl}::operator==): Adjust to the new
signature of equals; call it with the change_kind* parameter set
to NULL.
* src/abg-comparison.cc ({var_diff, pointer_diff, array_diff,
reference_diff, qualified_type_diff, enum_diff, class_diff,
base_diff, scope_diff, fn_parm_diff, function_decl_diff,
type_decl_diff, typedef_diff}::has_local_changes): Adjust.
2015-02-05 Dodji Seketeli <dodji@redhat.com>
Rename diff::length() into diff::has_changes()
* include/abg-comparison.h (*::has_changes): Rename the ::length()
method of all the diff types that inherit the diff class into
this, in the class declarations.
* src/abg-comparison.cc (*::has_changes): Do the same as in the
declarations, in the definitions.
(diff::to_be_reported, distinct_diff::has_local_changes)
(distinct_diff::report, distinct_diff::, array_diff::has_changes)
(reference_diff::has_changes, qualified_type_diff::has_changes)
(enum_diff::has_changes, translation_unit_diff::has_changes)
(suppression_categorization_visitor::visit_end)
(redundancy_marking_visitor::visit_begin): Adjust.
* tests/test-diff-dwarf.cc (main): Adjust.
* tools/abidiff.cc (main): Likewise.
2015-01-27 Dodji Seketeli <dodji@redhat.com>
Add a method to diff_context to dump a diff tree to error output
* include/abg-comparison.h (diff_context::error_output_stream):
Make this function const.
(diff_context::{do_dump_diff_tree}): Declare new methods.
* src/abg-comparison.cc (diff_context::error_output_stream): Make
this function const.
(diff_context::do_dump_diff_tree): Define new methods.
2015-01-27 Dodji Seketeli <dodji@redhat.com>
Keep children nodes of class_diff and scope_diff sorted
* include/abg-comparison.h (decl_diff_base, type_diff_base):
Forward declare these types.
(diff_sptrs_type, decl_diff_base_sptr, decl_diff_base_sptrs_type)
(type_diff_base_sptr, type_diff_base_sptrs_type)
(base_diff_sptrs_type, string_type_diff_base_sptr_map)
(string_decl_diff_base_sptr_map, string_diff_sptr_map): New
typedefs.
(changed_type_or_decl, changed_parm, changed_parms_type)
(string_changed_type_or_decl_map)
(unsigned_changed_type_or_decl_map, changed_type_or_decl_vector):
Remove typedefs.
(class_diff::changed_base): Make this return a
base_diff_sptrs_type now. No more a string_base_diff_sptr_map.
(class_diff::changed_member_fns): Make this return a
function_decl_diff_sptrs_type, no more a
string_changed_member_function_sptr_map.
(class_diff::changed_types): Make this return a diff_sptrs_type,
not a string_changed_type_or_decl_map anymore.
(class_diff::changed_decls): Make this return a diff_sptrs_type,
not a string_changed_type_or_decl_map anymore.
* src/abg-comp-filter.cc (has_virtual_mem_fn_change)
(has_non_virtual_mem_fn_change): Adjust.
* src/abg-comparison.cc (compute_diff): For the decl_base_sptr and
type_base_sptr overloads, assert that the resulting diff is
non-null.
(class_diff::priv::{sorted_changed_base_,
sorted_changed_member_types_, sorted_subtype_changed_dm_,
sorted_changed_dm_, sorted_changed_member_functions_,
sorted_changed_member_class_tmpls_}): New data members.
(class_diff::priv::changed_member_types_): Changed the type of
this from string_changed_type_or_decl_map to string_diff_sptr_map.
(class_diff::priv::changed_member_functions_): Changed the type of
this from string_changed_member_function_sptr_map to
string_function_decl_diff_sptr_map.
(class_diff::priv::changed_member_class_tmpls_): Changed the type
of this from string_changed_type_or_decl_map to
string_diff_sptr_map.
(class_diff::ensure_lookup_tables_populated): Adjust. Initialize
the new sorted members class_diff::priv::{sorted_changed_bases_,
sorted_subtype_changed_dm_, sorted_changed_dm_,
sorted_changed_member_functions_, sorted_changed_member_types_}.
(class_diff::priv::{member_type_has_changed,
member_class_tmpl_has_changed, count_filtered_bases,
count_filtered_subtype_changed_dm, count_filtered_changed_mem_fns,
}): Adjust.
(class_diff::chain_into_hierarchy): Adjust: The children nodes of
class_diff are now laid out in a sorted way.
(class_diff::{changed_bases, changed_member_fns}): Adjust.
(base_diff_comp, virtual_member_function_diff_comp): New types.
(sort_string_base_diff_sptr_map)
(sort_string_virtual_member_function_diff_sptr_map): New static
functions.
(data_member_diff_comp): Renamed var_diff_comp into this.
(sort_unsigned_data_member_diff_sptr_map): Renamed sort_var_diffs
into this and adjust.
(class_diff::report): Do not sort the nodes we are about to emit
here. Just use the natural order of the nodes in their parent
tree as they should now be sorted.
(scope_diff::priv::{changed_types_, changed_decls_}): Change the
type of these from string_changed_type_or_decl_map to
string_diff_sptr_map.
(scope_diff::priv::{sorted_changed_types_,
sorted_changed_decls_}): New data members.
(scope_diff::ensure_lookup_tables_populated): Adjust. Initialize
the new scope_diff::priv::sorted_changed_{types_, decls_}.
(scope_diff::chain_into_hierarchy): Adjust. The children of
scope_diff are now sorted.
(scope_diff::changed_{types, decls}): Return the sorted vectors of
children nodes.
(struct changed_type_or_decl_comp): Remove.
(struct diff_comp): New type.
(sort_changed_type_or_decl): Remove.
(sort_string_diff_sptr_map): New static function.
(scope_diff::report): Adjust. Do not sort children nodes here
ourselves before reporting about them. Rather, use the natural
topological order of the children as they are now sorted.
(corpus_diff::priv::sorted_changed_vars_): Renamed
corpus_diff::priv::changed_vars_ into this to make it more
explicit that the things it holds are sorted.
(corpus_diff::changed_variables_sorted): Adjust.
(corpus_diff::priv::ensure_lookup_tables_populated): Likewise.
(corpus_diff::priv::apply_filters_and_compute_diff_stats):
Likewise.
(corpus_diff::priv::categorize_redundant_changed_sub_nodes):
Likewise.
(corpus_diff::priv::clear_redundancy_categorization): Likewise.
(corpus_diff::priv::maybe_dump_diff_tree): Likewise.
(corpus_diff::report): Likewise.
2015-01-26 Dodji Seketeli <dodji@redhat.com>
Hand-code the string representation of GElf_Ehdr::e_machine
* configure.ac: Do not check for elfutils/libebl.h and libebl.a
anymore.
* src/abg-dwarf-reader.cc: Do not include elfutils/libebl.h
anymore.
(e_machine_to_string): Define new static
function.
(read_context::::load_elf_architecture): Use the new
e_machine_to_string() function rather than ebl_backend_name() and
ebl_openbackend().
* tests/data/test-diff-dwarf/test-23-diff-arch-report-0.txt: Adjust.
2015-01-26 Dodji Seketeli <dodji@redhat.com>
Fix chaining of descendant node of qualified type diff node
* include/abg-comparison.h
(qualified_type_diff::leaf_underlying_type_diff): Declare new
accessor.
* src/abg-comparison.cc (get_leaf_type): Forward declare this
static function.
(qualified_type_diff::priv::leaf_underlying_type_diff): Define new
data member.
(qualified_type_diff::leaf_underlying_type_diff): Define this new
accessor.
(qualified_type_diff::chain_into_hierarchy): Call
leaf_underlying_type_diff() here rather than
underlying_type_diff().
(qualified_type_diff::report): Use leaf_underlying_type_diff()
rather than re-computing the diff between the two leaf underlying
type diff nodes.
* libtest26-qualified-redundant-node-v{0,1}.so: New binary test
input files.
* tests/data/test-diff-filter/test26-qualified-redundant-node-v{0,1}.cc:
Source code for the binary test inputs above.
* tests/test-diff-filter.cc (int_out_spec): Add the new test input
to the vector of test input data over which to run this test
harness.
* tests/data/test-diff-filter/test26-qualified-redundant-node-report-{0,1.txt:
New test input file.
* tests/data/Makefile.am: Add the new test input data to the
source distribution.
2015-01-24 Dodji Seketeli <dodji@redhat.com>
Recognize cyclic diff tree nodes as being redundant
* include/abg-comparison.h (enum visiting_kind): Rename
enumerator DO_NOT_MARK_VISITED_NODES_AS_TRAVERSED into
DO_NOT_MARK_VISITED_NODES_AS_VISITED.
(diff_context::diff_has_been_visited): Rename
diff_context::diff_has_been_traversed into this.
(diff_context::mark_diff_as_visited): Rename
diff_context::mark_diff_as_traversed into this.
(diff_context::forget_visited_diffs): Rename
diff_context::forget_traversed_diffs into this.
(diff_context::forbid_visiting_a_node_twice): Rename
diff_context::forbid_traversing_a_node_twice into this.
(diff_context::visiting_a_node_twice_is_forbidden): Rename
diff_context::traversing_a_node_twice_is_forbidden into this.
(diff::is_traversing): Move this from protected to public.
* src/abg-comparison.cc (diff_context::priv::visited_diff_nodes_):
Rename diff_context::priv::traversed_diff_nodes_ into this.
(diff_context::priv::forbid_visiting_a_node_twice_): Rename
diff_context::priv::forbid_traversing_a_node_twice_ into this.
(diff_context::priv::priv): Adjust.
(diff_context::diff_has_been_visited): Rename
diff_context::diff_has_been_traversed into this. Adjust.
(diff_context::mark_diff_as_visited): Rename
diff_context::mark_diff_as_traversed into this. Adjust.
(diff_context::forget_visited_diffs): Rename
diff_context::forget_traversed_diffs into this. Adjust.
(diff_context::forbid_visiting_a_node_twice): Rename
diff_context::forbid_traversing_a_node_twice into this.
(diff_context::visiting_a_node_twice_is_forbidden): Rename
diff_context::traversing_a_node_twice_is_forbidden into this.
(diff_context::maybe_apply_filters): Adjust.
(diff::end_traversing): Remove the 'mark_as_traversed' parameter
of this. Remove the visited-marking code.
(diff::traverse): This is the crux of the changes of this patch.
Avoid traversing a node that is being traversed, but one can visit
a node being visited. Also, traversing a node means visiting it
and visiting its children nodes.
(diff::is_filtered_out): Simplify logic for filtering redundant
code. Basically all nodes that are redundant are filtered. All
the complicated logic that was due when diff nodes were shared is
not relevant anymore.
(corpus_diff::priv::categorize_redundant_changed_sub_nodes)
(propagate_categories, apply_suppressions)
(diff_node_printer::diff_node_printer, print_diff_tree)
(categorize_redundant_changed_sub_nodes)
(clear_redundancy_categorization)
(clear_redundancy_categorization): Adjust.
(redundancy_marking_visitor::visit_begin): Adjust. Also, if the
current diff node is already being traversed (that's a clyclic
node) then mark it as redundant.
* src/abg-comp-filter.cc (apply_filter): Adjust.
* tests/data/test-diff-filter/test16-report-2.txt: New test input data.
* tests/data/test-diff-filter/libtest25-cyclic-type-v{0,1}.so: New
test input binaries.
* tests/data/test-diff-filter/test25-cyclic-type-v{0,1}.cc: Source
code for the test input binaries.
* tests/data/test-diff-filter/test25-cyclic-type-report-0.txt: New
test input data.
* tests/data/test-diff-filter/test25-cyclic-type-report-1.txt:
Likewise.
* tests/test-diff-filter.cc (in_out_specs): Add the new test
inputs above to the list of test input data over which to run this
test harness.
* tests/data/Makefile.am: Add the new test files above to source
distribution.
* tests/data/test-diff-filter/test16-report.txt: Adjust.
* tests/data/test-diff-filter/test17-0-report.txt: Likewise.
2015-01-20 Dodji Seketeli <dodji@redhat.com>
Tighten the condition for creating a cloned function from DWARF
* src/abg-dwarf-reader.cc (build_ir_node): Re-indent. Also,
consider that when a DIE C refers to a DIE A via the
DW_abstract_origin attribute, C represents a clone of A, only if C
and A have *different* linkage names.
2015-01-19 Dodji Seketeli <dodji@redhat.com>
Fix the output of the array diff report
* src/abg-comparison.cc (array_diff::report): Refer to the pretty
representation of the array when talking about changes of the
array element type.
* src/abg-ir.cc (equals): In the overload for array_type, use the
equality operator that knows how to handle null pointers to
element type. This avoids crashes when the pointer to element
type is null.
* tests/data/test-diff-dwarf/test10-report.txt: Adjust.
* tests/data/test-diff-filter/test24-compatible-vars-report-1.txt:
Likewise.
2015-01-14 Dodji Seketeli <dodji@redhat.com>
Do not install the generated documentation by default
* doc/manuals/Makefile.am: Do not install the generated
documentation by default
2015-01-14 Dodji Seketeli <dodji@redhat.com>
Make sure to install html docs & gziped info on make install
* doc/manuals/Makefile.am: Make sure Make sure to install html
docs & gziped info on make install
2015-01-14 Dodji Seketeli <dodji@redhat.com>
Do not install the abinilint program
* tools/Makefile.am: Add abinilint to the noinst_PROGRAMS primary.
2015-01-13 Dodji Seketeli <dodji@redhat.com>
Small grammar fix in a manpage title
* doc/manuals/conf.py: Fix the grammar of the title of the abidiff
man page.
2015-01-13 Dodji Seketeli <dodji@redhat.com>
Generate texinfo documentation properly
* doc/manuals/Makefile.am: Generate texinfo doc, install it and
uninstall it.
* doc/manuals/libabigail-tools.rst: Do not use the :doc: syntax to
refer to documents because it doesn't seem to work with sphinx
right now. Rather, use a table of content.
2015-01-13 Dodji Seketeli <dodji@redhat.com>
Fix man pages installation
* doc/manuals/Makefile.am: Install the man pages only if they are
generated.
2015-01-13 Dodji Seketeli <dodji@redhat.com>
Bump the candidate version of the library to 1.0
* configure.ac: Bump version to 1.0.0
2015-01-13 Dodji Seketeli <dodji@redhat.com>
Do not forget to install the Manpages
* doc/manuals/Makefile.am: Add the man pages to the man7_MANS
automake primary.
2015-01-13 Dodji Seketeli <dodji@redhat.com>
Adjust archive-related code for the recent addition of tools_utils::*
* tests/Makefile.am: tools/libtoolsutils.la is no more.
* tests/test-write-read-archive.cc (main): Adjust.
* tools/abiar.cc (extract_tus_from_archive): Likewise.
2015-01-13 Dodji Seketeli <dodji@redhat.com>
Generate Manpages for abidiff, abidw, abilint
* doc/manuals/conf.py: Define man pages for abidiff, abidw,
abilint and an introductory one for libabigail.
2015-01-09 Dodji Seketeli <dodji@redhat.com>
Sort functions & variables diff nodes in the diff tree
* include/abg-comparison.h (function_decl_diff_sptrs_type)
(var_diff_sptrs_type): New typedefs.
(corpus_diff::{changed_functions, changed_variables}): Declare new
methods.
* src/abg-comparison.cc (sort_string_function_decl_diff_sptr_map)
(sort_string_var_diff_sptr_map): Forward declare these static
functions there were already defined later.
(struct diff_less_than_functor): Define new comparison functor.
(diff::append_child_node): Sort the children diff nodes of a given
diff node.
(corpus_diff::priv::changed_fns_map_): Renamed the data member
corpus_diff::priv::changed_fns_ into this.
(corpus_diff::priv::changed_fns_): New data member that is a
sorted vector of changed functions.
(corpus_diff::priv::{lookup_tables_empty, clear_lookup_tables}):
Adjust changed_fns_ -> changed_fns_map_ and changed_vars_ ->
changed_vars_map_.
(corpus_diff::priv::ensure_lookup_tables_populated): Likewise.
Sort the changed functions and changed variables.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Adjust
changed_fns_ -> changed_fns_map_ and changed_vars_ ->
changed_vars_map_. Also, walk the changed functions and variables
diff nodes in their sorted order.
(corpus_diff::priv::{categorize_redundant_changed_sub_nodes,
clear_redundancy_categorization, maybe_dump_diff_tree}): Walk the
changed functions and variables diff nodes in their sorted order.
* include/abg-ir.h
(function_decl::get_pretty_representation_of_declarator):
Declarenew method.
* src/abg-ir.cc
(function_decl::get_pretty_representation_of_declarator): Define
new function. Its content got split out of ...
(function_decl::get_pretty_representation): ... this one.
* src/abg-comparison.cc (corpus_diff::chain_into_hierarchy):
Consider the sorted the children nodes of a diff tree node.
(corpus_diff::append_child_node): Keep the children nodes of a
diff tree node sorted.
(corpus_diff::{changed_functions, changed_variables, length,
report}): Adjust.
(corpus_diff::{changed_functions_sorted,
changed_variables_sorted}): Define new functions.
(function_comp::operator()): First compare the qualified function
names along with the parameter declarations, then the rest.
(sort_string_function_decl_diff_sptr_map)
(sort_string_var_diff_sptr_map): Adjust.
* tests/data/test-abicompat/test0-fn-changed-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test8-redundant-fn-report-0.txt:
Adjust.
2015-01-09 Dodji Seketeli <dodji@redhat.com>
Fix logic of function parmeters diff redundancy detection
* src/abg-comparison.cc (redundancy_marking_visitor::visit_begin):
For a given function parameter diff node N, we were comparing it
against the other parmeter diff nodes of the function. This
change ensures that we do not compare N against itself.
2015-01-09 Dodji Seketeli <dodji@redhat.com>
Update copyright year for tests/test-abicompat.cc
* tests/test-abicompat.cc: Update copyright year.
2015-01-09 Dodji Seketeli <dodji@redhat.com>
Enhance the format of the diff tree dumping report
* src/abg-comparison.cc (diff_node_printer::do_indent): New
method.
(diff_node_printer::visit): Use diff_node_printer::do_indent().
Print the addresses of the diff tree node and its canonical node.
Add some vertical spaces and some indenting to make the report
more readable.
2015-01-08 Dodji Seketeli <dodji@redhat.com>
Expose a new libabigail::tools_utils namespace
* include/abg-tools-utils.h: Moved tools/abg-tools-utils.h in
here. Renamed the namespace tools into tools_utils. Inject
std::ostream, std::istream, std::ifstream, and std::string types
into the tools_utils namespace. Adjust the function declarations
accordingly. Remove the useless dirname() function declaration.
* include/Makefile.am: Add abg-tools-utils.h to the list of
exported headers.
* src/abg-tools-utils.cc: Moved tools/abg-tools-utils.cc in here.
Renamed the namespace tools into tools_utils.
(get_stat): Add apidoc.
(is_dir): Cleanup apidoc.
(dir_name); Cleanup parameter name.
(guess_file_type): Cleanup parameter type.
* src/Makefile.am: Add abg-tools-utils.cc to the list of exported
headers.
* tools/Makefile.am: Do not build the temporary library
libtoolsutils.la anymore as abg-tools-utils.{h,cc} have moved out
of this directory.
* tools/abicompat.cc (parse_command_line, main): Adjust for tools
-> tools_utils namespace change.
* tools/abidiff.cc (parse_command_line, main): Likewise.
* tools/abidw.cc (parse_command_line, main): Likewise.
* tools/abilint.cc (parse_command_line, main): Likewise.
* tests/test-abicompat.cc (main): Adjust for tools -> tools_utils
namespace change.
* tests/test-abidiff.cc (main): Likewise.
* tests/test-alt-dwarf-file.cc (main): Likewise.
* tests/test-core-diff.cc (main): Likewise.
* tests/test-diff-dwarf.cc (main): Likewise.
* tests/test-diff-filter.cc (main): Likewise.
* tests/test-diff-suppr.cc (main): Likewise.
* tests/test-lookup-syms.cc (main): Likewise.
* tests/test-read-dwarf.cc (main): Likewise.
* tests/test-read-write.cc (main): Likewise.
* tests/Makefile.am: Do not reference the libtoolsutils.la private
library anymore.
2015-01-07 Dodji Seketeli <dodji@redhat.com>
Update copyright years
* include/abg-comp-filter.h: Update copyright years.
* include/abg-comparison.h: Likewise.
* include/abg-config.h: Likewise.
* include/abg-corpus.h: Likewise.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-fwd.h: Likewise.
* include/abg-hash.h: Likewise.
* include/abg-ini.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* include/abg-libzip-utils.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-sptr-utils.h: Likewise.
* include/abg-traverse.h: Likewise.
* include/abg-viz-common.h: Likewise.
* include/abg-viz-dot.h: Likewise.
* include/abg-viz-svg.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-comp-filter.cc: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-diff-utils.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-hash.cc: Likewise.
* src/abg-ini.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-libzip-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-traverse.cc: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-writer.cc: Likewise.
* tests/print-diff-tree.cc: Likewise.
* tests/test-abidiff.cc: Likewise.
* tests/test-alt-dwarf-file.cc: Likewise.
* tests/test-core-diff.cc: Likewise.
* tests/test-diff-dwarf.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
* tests/test-diff-suppr.cc: Likewise.
* tests/test-diff2.cc: Likewise.
* tests/test-ir-walker.cc: Likewise.
* tests/test-lookup-syms.cc: Likewise.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
* tests/test-write-read-archive.cc: Likewise.
* tools/abg-tools-utils.cc: Likewise.
* tools/abg-tools-utils.h: Likewise.
* tools/abiar.cc: Likewise.
* tools/abidiff.cc: Likewise.
* tools/abidw.cc: Likewise.
* tools/abilint.cc: Likewise.
* tools/abisym.cc: Likewise.
* tools/binilint.cc: Likewise.
2015-01-07 Dodji Seketeli <dodji@redhat.com>
Detect and report changes in ELF architecture
* configure.ac: Detect the presence of libebl.a and add it to the
list of library we depend on to build libabigail. Report when
libelf.so is not found.
* include/abg-comparison.h:
(diff_context::show_architecture_change): Declare new accessors.
(corpus_diff::architecture_changed): Declare new method.
* include/abg-corpus.h (corpus::{get,set}_architecture_name):
Declare new accessors.
* src/abg-comparison.cc
(diff_context::priv::show_architecture_change_): New data member.
(diff_context::priv::priv): Initialize it.
(diff_context::show_architecture_change): Define new accessors.
(function_decl_diff::report): Report when the size/alignment of
the function address changes.
(corpus_diff::priv::architectures_equal_): New data member.
(corpus_diff::priv::priv): Initialize it.
(corpus_diff::priv::emit_diff_stats): Take in account changes of
architecture.
(corpus_diff::architecture_changed): Define new method.
(corpus_diff::length): Take in account changes of architecture.
(corpus_diff::report): Report about changes of architecture.
(compute_diff): In the overload for corpus_diff_sptr, detect
changes fo architecture.
* src/abg-corpus.cc (corpus_priv::architecture_name): Define new
data member.
(corpus::{get,set}_architecture_name): Define new method.
* src/abg-dwarf-reader.cc: Include elfutils/libebl.h to use
ebl_openbackend() and ebl_backend_name()
(read_context::elf_architecture_): Define new data member.
(read_context::elf_architecture): Define new accessor.
(read_context::{load_elf_architecture, load_remaining_elf_data}):
Define new methods.
(read_corpus_from_elf): Use ctxt.load_remaining_elf_data() in lieu
of ctxt.load_dt_soname_and_needed. Stick the architecture into
the corpus.
* src/abg-reader.cc (read_corpus_from_input): Read the
'architecture' XML property.
* src/abg-writer.cc (write_corpus_to_native_xml): Write the
'architecture' XML property.
* tests/data/test-diff-dwarf/libtest-23-diff-arch-v0-32.so: New
test input file.
* tests/data/test-diff-dwarf/libtest-23-diff-arch-v0-64.so:
Likewise.
* tests/data/test-diff-dwarf/test-23-diff-arch-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test-23-diff-arch-v0.cc: Source code
for the binary test input files above.
* tests/data/Makefile.am: Add the new test input files to the
source distribution.
* tests/test-diff-dwarf.cc (in_out_specs): Add the new test input
data to the set of input data to run this test harness over.
* tests/test-read-dwarf.cc (main): Do not take the architecture in
account during comparisons.
2015-01-05 Sinny Kumari <skumari@redhat.com>
Include libabigail-website.doxy file in EXTRA_DIST
* doc/Makefile.am: Include website/libabigail-website.doxy
file in EXTRA_DIST
2015-01-06 Dodji Seketeli <dodji@redhat.com>
Delete ltsugar.m4 and pkg.m4 files from m4/
* m4/ltsugar.m4: Removed.
* m4/pkg.m4: Likewise.
2014-12-27 Dodji Seketeli <dodji@redhat.com>
Enable parallel tests
* configure.ac (AM_INIT_AUTOMAKE): Enable parallel tests by
switching on the parallel-tests option.
2014-12-27 Dodji Seketeli <dodji@redhat.com>
Add a --dump-diff-tree to abidiff for debugging purposes
* include/abg-comparison.h (enum visiting_kind): Add new
DO_NOT_MARK_VISITED_NODES_AS_TRAVERSED enumerator.
(diff_context::{default_output_stream, error_output_stream,
dump_diff_tree}): Declare new accessors.
(diff::end_traversing): Take a new boolean flag.
(print_diff_tree): Add new overload for diff_sptr.
* src/abg-comparison.cc
(diff_context::priv::{default_output_stream_,
error_output_stream_, dump_diff_tree_}): New data members.
(priv::priv): Initialize them.
(diff_context::{default_output_stream_, error_output_stream_,
dump_diff_tree, dump_diff_tree}): Define new accessors.
(diff::end_traversing): Take a new flag that control whether or
not to mark the current diff node as having been traversed.
(diff::traverse): Take in account the visiting kind carried by the
visitor to determine if the visited node should be marked as being
traversed.
(corpus_diff::priv::maybe_dump_diff_tree): Define new member
function.
(corpus_diff::report): Call it.
(diff_node_printer::visit): Pretty print the diff node just once.
(print_diff_tree): Define a new overload for diff_sptr.
* tools/abidiff.cc (options::dump_diff_tree): New data member.
(options::options): Initialize it.
(display_usage): Add a help string for the new --dump-diff-tree
command line switch.
(parse_command_line): Parse the new --dump-diff-tree command line
switch.
(set_diff_context_from_opts): Set the diff context according to
the --dump-diff-tree presence.
* doc/manuals/abidiff.rst: Add a bullet point for the new
--dump-diff-tree command line switch.
2014-12-27 Dodji Seketeli <dodji@redhat.com>
Fix typos in the abicompat manual
* doc/manuals/abicompat.rst: Fix typos.
2014-12-27 Dodji Seketeli <dodji@redhat.com>
Fix a typo in the abidiff manual
* doc/manuals/abidiff.rst: Fix a typo.
2014-12-27 Dodji Seketeli <dodji@redhat.com>
Fix redundancy in abidiff manual
* doc/manuals/abidiff.rst: Remove the redundant bullet point about
the --drop-fn command line switch.
2014-12-26 Dodji Seketeli <dodji@redhat.com>
Fix the doc string of the CanonicalDiff section of the apidoc
* src/abg-comparison.cc: The summary of the CanonicalDiff should
not be a @par directive, otherwise it won't show up in the summary
field on the html-genereated page.
2014-12-26 Dodji Seketeli <dodji@redhat.com>
Update doc string for new --no-redundant option of abidiff
* doc/manuals/abidiff.rst: Update the documentation string for the
--no-redundant option of abidiff.
2014-12-26 Dodji Seketeli <dodji@redhat.com>
Make abidiff *NOT* show redundant changes by default
* tools/abidiff.cc (options::options): Initialize
options::show_redundant_changes to false.
2014-12-26 Dodji Seketeli <dodji@redhat.com>
Try harder to handle pointer/reference to void
* include/abg-fwd.h (type_or_void): Declare new function.
* src/abg-ir.cc (type_or_void): Define it.
(pointer_type_def::pointer_type_def)
(reference_type_def::reference_type_def)
(reference_type_def::get_qualified_name, strip_typedef): Use it to
ensure that empty pointed-to-type is considered as a void type.
2014-12-26 Dodji Seketeli <dodji@redhat.com>
Do not mark sibling structurally identical nodes as redundant
* include/abg-comparison.h (diff::parent_node): Declare new
accessor.
* src/abg-comparison.cc (diff::priv::parent_): New data member.
(diff::priv::priv): Initialize it.
(diff::parent_node): Define new accessor.
(diff::append_child_node): Set the diff::priv::parent_ data member
of the added child node.
(redundancy_marking_visitor::visit_begin): If two (logical)
sibbling nodes are structurally equivalent, do not mark them as
being redundant.
* tests/data/test-diff-suppr/libtest10-changed-parm-c-v0.so: New
test input binary.
* tests/data/test-diff-suppr/libtest10-changed-parm-c-v1.so:
Likewise.
* tests/data/test-diff-suppr/test10-changed-parm-c-report-0.txt:
New test input data.
* tests/data/test-diff-suppr/test10-changed-parm-c-v0.c: Source
code for the binary input above.
* tests/data/test-diff-suppr/test10-changed-parm-c-v1.c: Likewise.
* tests/data/Makefile.am: Add the new test files to source
distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
to the vector of test inputs to run this harness over.
2014-12-26 Dodji Seketeli <dodji@redhat.com>
Un-share diff nodes in the comparison IR
* include/abg-ir.h: Prefix the doc string with "///", rather than
writing it inside a /**/ comment.
* include/abg-comparison.h (function_decl_diff)
(function_decl_diff_sptr, fn_parm_diff, fn_parm_diff_sptr)
(var_diff_sptr, base_diff, class_diff, class_diff_sptr): Move
these class & typedef decls to the top of the file.
(string_changed_base_map, string_changed_parm_map)
(unsigned_changed_parm_map, changed_function_ptr)
(string_changed_function_ptr_map): Remove these typedefs.
(string_base_diff_sptr_map, string_fn_parm_diff_sptr_map)
(unsigned_fn_parm_diff_sptr_map, string_var_diff_sptr_map)
(unsigned_var_diff_sptr_map, string_function_decl_diff_sptr_map)
(string_var_diff_ptr_map): New typedefs.
(diff_context::{has_diff_for,add_diff}): Make these member
functions private.
(diff_context::{set_canonical_diff_for,
set_or_get_canonical_diff_for}): Declare new private member
functions.
(diff_context::{get_canonical_diff_for,
initialize_canonical_diff}): New public member functions.
(diff_context::maybe_apply_filters): Set the default value of the
'traverse_nodes_once' parameter to false.
(compute_diff): Make the overload for class_decl_sptr friend of
the diff_context class.
(class diff): Make the diff_context class a friend of this one.
(diff::set_canonical_diff): Declare new private member function.
(diff::get_canonical_diff): Declare new public member function.
(diff::children_nodes): Make this return a vector<diff_sptr>, rather
than a vector<diff*>.
(diff::append_child_node): Make this take a diff_sptr rather than
a diff*.
(class fn_parm_diff): Declare new type.
(compute_diff): Declare new overload for the new
function_decl::parameter_sptr.
(function_decl_diff::subtype_changed_parms): Return a
string_fn_parm_diff_sptr_map rather than a string_changed_parm.
(function_decl_diff::children_nodes): Return a vector<diff_sptr>.
(function_decl_diff::append_child_node): Take a diff_sptr.
(function_decl_diff::changed_functions): Return a
string_function_decl_diff_sptr_map.
(function_decl_diff::changed_variables): Return a
string_var_diff_sptr.
(class function_decl::parameter): Make this a pimpled class.
Also, make it inherit decl_base.
(equals): New overload for function_decl::parameter.
(struct function_decl::parameter::hash): Declare this.
(ir_node_visitor::visit): Declare new overload for
function_decl::parameter.
* src/abg-comparison.cc: Add doc-string about the internal
representation of the comparison engine and also about the concept
of canonical diff of the comparison engine.
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER)
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER2)
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER3): Consider the
canonical diff when trying to know if the current node was
reported earlier.
(diff_context::priv::canonical_diffs): New data member.
(diff_context::{get_canonical_diff_for, set_canonical_diff_for,
set_or_get_canonical_diff_for, initialize_canonical_diff}): Define
new member functions.
(diff_context::{diff_has_been_traversed, mark_diff_as_traversed):
Consider canonical diff for these tests and actions.
(diff::priv::children_): Change the type of this to
vector<diff_sptr>.
(diff::canonical_diff_): New data member.
(diff::diff): Initialize the diff::canonical_diff_ data member.
(diff::begin_traversing): Mark the canonical diff node too.
(diff::is_traversing): Consider the canonical diff node in this
test.
(diff::end_traversing): Make the canonical diff node too. Also
mark the current node as having been traversed.
(diff::children_nodes): Return a vector<diff_sptr> type.
(diff::{get_canonical_diff, set_canonical_diff}): Define new
member functions.
(diff::append_child_node): Take a diff_sptr type parameter.
(diff::{reported_once, currently_reporting}): Flag the canonical
diff node too. And consider the canonical diff node when checking
the flag.
(diff::traverse): No need to mark the node as being traversed
because the diff::end_traversing() function does it now. Adjust
the code because diff::children_nodes() now returns
vector<diff_sptr>.
({distinct_diff, var_diff, pointer_diff, array_diff,
reference_diff, qualified_type_diff, enum_diff, class_diff,
base_diff, scope_diff, function_decl_diff, typedef_diff,
corpus_diff}::chain_into_hierarchy): Adjust to the new type that
diff::append_child_node() takes. Also, take into account that the
diff nodes are now un-shared.
(compute_diff_for_distinct_kinds, compute_diff_for_types)
(compute_diff): Do not share diff nodes anymore. Initialize the
canonical diff node for the new created node.
(represent): Take a var_diff_sptr rather than two var_decl_sptr.
Adjust. Also take in account the fact that diff nodes are not
shared anymore, and that they do have canonical diffs.
(var_diff::type_diff): Make the computation of the type_diff of
the var_diff be lazy. This avoids infinite (recursive) creation
of diff nodes when a class diff node has a sub-type of data member
that is a class diff node too.
(var_diff::report): Detect redundant reporting of this kind of
diff node.
(class_diff::priv::changed_bases_): Change the type of this to
string_base_diff_sptr_map.
(class_diff::priv::subtype_changed_dm_): Change the type of this
to string_var_diff_sptr_map.
(class_diff::priv::changed_dm_): Change the type of this to
unsigned_var_diff_sptr_map.
(class_diff::priv::{count_filtered_subtype_changed_dm,
count_filtered_bases}): Do not take a diff_context_sptr anymore.
(class_diff::ensure_lookup_tables_populated): changed_bases_
subtype_changed_dm_ and changed_dm_ are now *NOT* shared diff
nodes anymore.
(class_diff::priv::base_has_changed): Adjust.
(class_diff::priv::subtype_changed_dm): Adjust.
(class_diff::priv::count_filtered_bases): Adjust as changed_bases_
is now a map of un-shared diff nodes.
(class_diff::priv::count_filtered_subtype_changed_dm): Adjust as
subtype_changed_dm_ is now a map of un-shared diff nodes.
(class_diff::priv::{count_filtered_changed_mem_fns,
count_filtered_inserted_mem_fns, count_filtered_deleted_mem_fns,
}): Adjust for change of the default parameter value of
diff_context::maybe_apply_filters().
(class_diff::~class_diff): New destructor.
(class_diff::changed_bases): Return a string_base_diff_sptr_map&
type.
(class_diff::{inserted_data_members, deleted_data_members,
changed_member_fns}): Add doc strings.
(struct changed_data_member_comp): Remove.
(struct var_diff_comp): New comparison functor.
(sort_changed_data_members): Remove.
(sort_var_diffs): Define new sorting function.
(class_diff::report): Adjust.
(fn_parm_diff::*): Define member types and functions of the new
fn_parm_diff type.
(function_decl_diff::priv::{subtype_changed_parms_,
changed_parms_by_id_}): Make these take a map of fn_parm_diff_sptr
nodes.
(function_decl_diff::ensure_lookup_tables_populated): Adjust to
the fact that priv_->subtype_changed_parms_ and
priv_->priv_->changed_parms_by_id_ now are maps of un-shared
fn_parm_diff_sptr nodes.
(function_decl_diff::subtype_changed_parms): Adjust.
(struct changed_parm_comp): Remove.
(struct fn_parm_diff_comp): New comparison functor.
(sort_changed_parm_map): Remove.
(sort_string_fn_parm_diff_sptr_map): New sorting function.
(function_decl_diff::report): Adjust.
(corpus_diff::priv::children_): Change the type of this to
vector<diff_sptr>.
(corpus_diff::priv::changed_fns_): Changed the type of this to
string_function_decl_diff_sptr_map.
(corpus_diff::priv::changed_vars_): Changed the type of this to
string_var_diff_sptr_map.
(corpus_diff::priv::ensure_lookup_tables_populated): Adjust.
(corpus_diff::priv::apply_filters_and_compute_diff_stats}):
Adjust. Do not need to clear redundancy categorization anymore
because the diff nodes are not shared anymore.
(corpus_diff::priv::categorize_redundant_changed_sub_nodes):
Adjust.
(corpus_diff::priv::clear_redundancy_categorization): Adjust.
(corpus_diff::changed_variables): Adjust.
(struct changed_function_ptr_comp): Remove.
(struct function_decl_diff_comp): New comparison functor.
(sort_string_changed_function_ptr_map): Remove.
(sort_string_function_decl_diff_sptr_map): Define new sorting
function.
(struct changed_vars_comp): Remove.
(struct var_diff_sptr_comp): New comparison functor.
(sort_changed_vars): Remove.
(sort_string_var_diff_sptr_map): Define new sorting function.
(corpus_diff::report): Adjust.
(corpus_diff::traverse): Adjust.
({category_propagation_visitor,
suppression_categorization_visitor}::visit_end): Adjust.
(clear_redundancy_categorization): Adjust.
* src/abg-hash.cc (function_decl::parameter::hash::operator):
Adjust.
* src/abg-ir.cc (struct function_decl::parameter::priv): Define
here as part of pimpl-ifying the function_decl::parameter type.
(function_decl::parameter::*): Define here the member functions as
part of pimpl-ifying the function_decl::parameter type.
(equals): Define the overload for function_decl::parameter here
too.
(ir_node_visitor::visit(function_decl::parameter*)): Define this.
* tests/data/test-abicompat/test0-fn-changed-report-0.txt: Adjust.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: Adjust.
* tests/data/test-diff-dwarf/libtest21-redundant-fn-v0.so: New
test input data.
* tests/data/test-diff-dwarf/libtest21-redundant-fn-v1.so:
Likewise.
* tests/data/test-diff-dwarf/test21-redundant-fn-v0.cc: Source
code for test input binary above.
* tests/data/test-diff-dwarf/test21-redundant-fn-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test21-redundant-fn-report-0.txt: New
test input data.
* tests/data/test-diff-dwarf/libtest22-changed-parm-c-v0.so: New
test input data.
* tests/data/test-diff-dwarf/libtest22-changed-parm-c-v1.so:
Likewise.
* tests/data/test-diff-dwarf/test22-changed-parm-c-v0.c: Source
code for test input binary above.
* tests/data/test-diff-dwarf/test22-changed-parm-c-v1.c: Likewise.
* tests/test-diff-dwarf.cc (in_out_spec): Add the new test input
data to the vector the test inputs to run this harness over.
* tests/data/test-diff-suppr/test8-redundant-fn-report-0.txt: New
test input data.
* tests/data/test-diff-suppr/test8-redundant-fn-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/libtest8-redundant-fn-v0.so: New test
input binary.
* tests/data/test-diff-suppr/libtest8-redundant-fn-v1.so: Likewise.
* tests/data/test-diff-suppr/test8-redundant-fn-v0.cc: Source code
code for binary test input above.
* tests/data/test-diff-suppr/test8-redundant-fn-v1.cc: Likewise.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-0.txt:
New test input data.
* tests/data/test-diff-suppr/test9-changed-parm-c-report-1.txt:
Likewise.
* tests/data/test-diff-suppr/libtest9-changed-parm-c-v0.so: New
test input binary.
* tests/data/test-diff-suppr/libtest9-changed-parm-c-v1.so: New
test input binary.
* tests/data/test-diff-suppr/test9-changed-parm-c-v0.c: Source
code for binary test input above.
* tests/data/test-diff-suppr/test9-changed-parm-c-v1.c: Likewise.
* tests/test-diff-suppr.cc (in_out_specs): Add the new test input
data to the vector the test inputs to run this harness over.
* tests/data/Makefile.am: Add the new files to the source
distribution.
2014-12-26 Dodji Seketeli <dodji@redhat.com>
Style fix
* src/abg-ir.cc (reference_type_def::get_pointed_to_type): Return
a type_base_sptr.
* src/abg-comparison.cc (diff::is_filtered_out): Fix a comment.
2014-12-25 Dodji Seketeli <dodji@redhat.com>
Fix pretty printing of pointer_diff node
* src/abg-comparison.cc (pointer_diff::get_pretty_representation):
Add the missing opening square bracket.
2014-12-17 Sinny Kumari <skumari@redhat.com>
Add new methods in corpus_diff class
* include/abg-comparison.h
(corpus_diff::added_unrefed_function_symbols):
Declare new member function
(corpus_diff::added_unrefed_variable_symbols):
Declare new member function
* src/abg-comparison.cc
(corpus_diff::added_unrefed_function_symbols):
Define new member function
(corpus_diff::added_unrefed_variable_symbols):
Define new member function
2014-12-15 Sinny Kumari <sinny@redhat.com>
Add new corpus_diff::added_variables() method
* include/abg-comparison.h (corpus_diff::added_variables):
Declare new member function
* src/abg-comparison.cc (corpus_diff::added_variables):
Define new member function
2014-12-12 Dodji Seketeli <dodji@redhat.com>
Extend detection of compatible types to arrays
* include/abg-fwd.h (is_array_type): Renamed is_array_type_def()
into this for consistency.
* src/abg-comparison.cc (type_suppression::suppresses_diff):
Adjust.
* src/abg-dwarf-reader.cc (build_array_type): Remove useless code
that was trying to read a DW_AT_byte_size attribute from the DIE
of the array, but then wasn't doing anything with the value. But
then if the attribute was not present, the array type wouldn't be
built.
* src/abg-ir.cc (strip_typedef): Strip typedefs from sub-types of
array types too.
(is_array_type): Rename is_array_def() to this, for consistency.
(var_decl::get_pretty_representation): Adjust.
* tests/data/test-diff-filter/libtest24-compatible-vars-v0.so: New
test input data.
* tests/data/test-diff-filter/libtest24-compatible-vars-v1.so: Likewise.
* tests/data/test-diff-filter/test24-compatible-vars-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test24-compatible-vars-v0.c: Source
code for the first binary above.
* tests/data/test-diff-filter/test24-compatible-vars-v1.c: Source
code for the second binary above.
* tests/data/Makefile.am: Add the new test input data to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test input
data to the list of input to run this test harness over.
2014-12-12 Dodji Seketeli <dodji@redhat.com>
Improve the doc string for the elf_symbol::get_id_string() method
* src/abg-ir.cc (elf_symbol::get_id_string): Improve doc string.
Talk about the content of the id string of an elf symbol.
2014-12-11 Dodji Seketeli <dodji@redhat.com>
Better handle pointer-to-void in various places of the pipeline
* src/abg-comparison.cc (pointer_diff::report): Handle the case of
pointer to void.
* src/abg-dwarf-reader.cc (build_pointer_type_def): Assert that
the underlying pointer is non-null.
* src/abg-ir.cc (pointer_type_def::pointer_type_def): Handle the
case of pointer to void.
(equals): Likewise in the overload for const pointer_type_def.
(pointer_type_def::get_qualified_name): Likewise.
2014-12-11 Dodji Seketeli <dodji@redhat.com>
Try harder to detect a DWARF attribute pointing into alternate DWARF section
* src/abg-dwarf-reader.cc
(is_die_attribute_resolved_through_gnu_ref_alt): Support the case
of the origin function itself having a specification function
link.
2014-12-11 Dodji Seketeli <dodji@redhat.com>
Fix accidentally removing the scope of variables when fixing them up
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir):
During var decl fixup, remove the scope of a variable only when we
are sure that we want to re-scope it.
2014-12-11 Dodji Seketeli <dodji@redhat.com>
Fix several aborts while diffing libdw.so
* src/abg-corpus.cc
(corpus::priv::build_unreferenced_symbols_tables): Fix wrong
guestimation of the size of the map of unreferenced symbol table.
* src/abg-dwarf-reader.cc (get_version_needed_for_versym): Honour
the conditions of breaking out from walking the verneed table.
2014-12-10 Dodji Seketeli <dodji@redhat.com>
Temporarily disable redundant diff report elimination
* src/abg-comparison.cc
(diff_context::priv::priv): Show redundant changes by default.
(categorize_redundancy): Do not categorize redundancy if the
diff_context says that we shouldn't.
* tools/abicompat.cc (options::show_redundant): New data member.
(options::options): Initialize to true.
(display_usage): Add new help string for new --no-redundant and
--redundant options.
(parse_command_line): Parse new --no-redundant and --redundant
command line options.
(main): Initialize the diff context with respect to the
options::show_redundant property.
* tools/abidiff.cc (options::options): Initialize the
show_redundant_changes data member to true.
(display_usage): Show new help string for the new --no-redundant
command line option.
(parse_command_line): Parse the new --no-redundant command line
option.
* tests/data/test-diff-filter/libtest23-redundant-fn-parm-change-v0.so:
New test data input.
* tests/data/test-diff-filter/libtest23-redundant-fn-parm-change-v1.so:
Likewise.
* tests/data/test-diff-filter/test23-redundant-fn-parm-change-report-0.txt:
Likewise.
* tests/data/test-diff-filter/test23-redundant-fn-parm-change-v0.c:
Source code for the first binary above.
* tests/data/test-diff-filter/test23-redundant-fn-parm-change-v1.c:
Source code for the second binary above.
* tests/data/Makefile.am: Add the new test data input to source
distribution.
* tests/test-abicompat.cc (in_out_specs): Add --no-redundant to
abicompat when we don't want it to show redundant diff reports.
* test-diff-filter.cc (in_out_specs): Likewise for abidiff.
* test-diff-suppr.cc (in_out_specs): Likewise.
2014-12-10 Jan Engelhardt <jengelh@inai.de>
Fix conditional build wrt zip archives and cx11
* configure.ac: remove (broken) assignment to the
ENABLE_ZIP_ARCHIVE_AND_CXX11 variable
* Makefile.am: replace variable assignments to
ZIP_ARCHIVE_TESTS_FIRST_PART, ZIP_ARCHIVE_TESTS_SECOND_PART
by ZIP_ARCHIVE_TESTS using the "+=" automake operator.
Likewise for CXX11_TESTS.
2014-12-10 Dodji Seketeli <dodji@redhat.com>
Make determining of compatible types complete
* include/abg-fwd.h (is_reference_type, is_function_type)
(is_method_type): Declare new predicates.
* include/abg-ir.h (class qualified_type_def): Pimpl this class.
(qualified_type_def::qualified_type_def): Use the convenience
type_base_sptr typedef.
(qualified_type_def::{get_cv_quals, set_cv_quals}): Use the
qualified_type_def::CV type rather than char.
(qualified_type_def::get_underlying_type): Use the convenience
type_base_sptr typedef.
(pointer_type_def::pointer_type_def): Likewise.
(function_decl::parameter::parameter): Add a new constructor.
* src/abg-ir.cc (is_reference_type, is_function_type)
(is_method_type): Define new predicates.
(class qualified_type_def::priv): Define this new private type,
for the purpose of Pimpl-ifying the qualified_type_def class.
(qualified_type_def::{qualified_type_def, build_name,
get_cv_quals_string_prefix, get_underlying_type}): Adjust for the
purpose of Pimpl-ifying the qualified_type_def class.
(equals): In the qualified_type_def, reference_type_def overloads,
trust the fact that we have operator== overload for the
type_base_sptr. This avoids crashes for when the (possible)
underlying type is null.
(pointer_type_def::operator==): Likewise.
(strip_typedef): Make this recursively strip
typedefs from sub-types.
(types_are_compatible): Handle null types.
(qualified_type_def::{get_cv_quals, set_cv_quals}): Handle
qualified_type_def::CV rather than char.
(pointer_type_def::pointer_type_def): Use the convenience
type_base_sptr typedef.
* include/abg-comparison.h (distinct_diff::compatible_child_diff):
Declare new member function.
* src/abg-comparison.cc (distinct_diff::compatible_child_diff):
Define new member function.
(distinct_diff::chain_into_hierarchy):
Chain the compatible child diff node that might be present.
(distinct_diff::report): Now when a distinct diff carries a
compatible change, mention it in the report.
* src/abg-comp-filter.cc (is_compatible_change): A compatible
change can now involve types that are not typedefs. Only their
sub-types need to be involved with typedef-ness.
* tests/data/test-diff-dwarf/test{2,4,5}-report.txt: Adjust.
* tests/data/test-diff-filter/libtest21-compatible-vars-v0.so: New
test data input.
* tests/data/test-diff-filter/libtest21-compatible-vars-v1.so: Likewise.
* tests/data/test-diff-filter/test21-compatible-vars-report-0.txt Likewise.
* tests/data/test-diff-filter/test21-compatible-vars-report-1.txt Likewise.
* tests/data/test-diff-filter/test21-compatible-vars-v0.cc: Source
code for the first data input binary above.
* tests/data/test-diff-filter/test21-compatible-vars-v1.cc: Source
code for the second data input binary above.
* tests/data/test-diff-filter/libtest22-compatible-fns-v0.so: New
test data input.
* tests/data/test-diff-filter/libtest22-compatible-fns-v1.so Likewise.
* tests/data/test-diff-filter/test22-compatible-fns-report-0.txt:
New test data input.
* tests/data/test-diff-filter/test22-compatible-fns-report-1.txt: Likewise.
* tests/data/test-diff-filter/test22-compatible-fns-v0.c: Source
code for the first test data input binary above.
* tests/data/test-diff-filter/test22-compatible-fns-v1.c: Source
code for the second test data input binary above.
* tests/data/Makefile.am: Add the new test input data to source
distribution.
* tests/test-diff-filter.cc (in_out_specs): Add the new test data
input above to the list of test data this harness has to be run
over.
2014-12-09 Dodji Seketeli <dodji@redhat.com>
Fix classification of parameter addition in C
* src/abg-comp-filter.cc (function_name_changed_but_not_symbol):
Compare the fully qualified name of the functions; not their
pretty representation.
* tests/data/test-diff-dwarf/libtest20-add-fn-parm-v0.so: New test
data intput.
* tests/data/test-diff-dwarf/libtest20-add-fn-parm-v1.so:
Likewise.
* tests/data/test-diff-dwarf/test20-add-fn-parm-report-0.txt:
Likewise.
* tests/data/test-diff-dwarf/test20-add-fn-parm-v0.c: Source code
for the first shared library above.
* tests/data/test-diff-dwarf/test20-add-fn-parm-v1.c: Source code
for the second shared library above.
* tests/test-diff-dwarf.cc (in_out_specs): Add the test input data
above to the list of test input the harness must run over.
* Makefile.am: Add the new files above to source distribution.
2014-12-08 Dodji Seketeli <dodji@redhat.com>
Wire the soname check into abicompat
* include/abg-comparison.h (corpus_diff::soname_changed): Declare
new member function.
* src/abg-comparison.cc (corpus_diff::soname_changed): Define new
member function.
(corpus_diff::length): Use the new corpus_diff::soname_changed()
method.
* tests/data/test-abicompat/libtest4-soname-changed-v0.so: New
test input data.
* tests/data/test-abicompat/libtest4-soname-changed-v1.so:
Likewise.
* tests/data/test-abicompat/test4-soname-changed-app: Likewise.
* tests/data/test-abicompat/test4-soname-changed-report-0.txt:
Likewise.
* tests/data/test-abicompat/test4-soname-changed-app.cc: Source
code for one of the binaries above.
* tests/data/test-abicompat/test4-soname-changed-v0.cc: Likewise.
* tests/data/test-abicompat/test4-soname-changed-v1.cc: Likewise.
* tests/test-abicompat.cc (in_out_specs): Add the new test input
data to the list of input data to run this harness over.
(main): Take the soname change in account to determine if the
change is ABI incompatible.
* tests/data/Makefile.am: Add the new test input data above to source
distribution.
2014-12-07 Dodji Seketeli <dodji@redhat.com>
Fixup messed up old runtestdiffdwarf input tests
* tests/data/test-diff-dwarf/test17-non-refed-syms-report-0.txt:
Add this missing reference test output.
* tests/data/Makefile.am: Add the new reference test output to
source distribution.
* tests/data/test-diff-dwarf/test18-alias-sym-report-0.txt: Fix
this output to avoid emitting symbol alias information in it.
* tests/test-diff-dwarf.cc (in_out_specs): Add two missing test
input data to the list of input data this harness is supposed to
run over.
2014-12-07 Dodji Seketeli <dodji@redhat.com>
Support reading and comparing soname from ELF files
* include/abg-corpus.h (corpus::{get_needed, set_needed,
get_soname, set_soname}): Declare new accessors.
* src/abg-corpus.cc (corpus::priv::{needed, soname}): New data
members.
(corpus::{get_needed, set_needed, get_soname, set_soname}): Define
new accessors.
(corpus::is_empty): Take dt_needed and dt_soname in account in
computing empty-ness.
* src/abg-dwarf-reader.cc (read_context::{dt_needed_,
dt_soname_}): New data members.
(read_context::{dt_needed, dt_soname}): New accessors.
(read_context::load_dt_soname_and_needed): New member function.
(read_corpus_from_elf): Call the new
read_context::load_dt_soname_and_needed() to read the dt_soname
and dt_needed tags. Set them to the corpus.
* include/abg-comparison.h (diff_context::show_soname_change):
Declare new accessors.
* src/abg-comparison.cc (diff_context::priv::show_soname_change_):
New data member.
(diff_context::priv::priv): Initialize the new data member
diff_context::priv::show_soname_change_.
(diff_context::show_soname_change): Define new accessors.
(corpus_diff::priv::sonames_equal_): New data member.
(corpus_diff::priv::priv): Initialize the new data member
corpus_diff::priv::sonames_equal_.
(corpus_diff::length): Take the new priv_->sonames_equals_ data
member in account.
(corpus_diff::{report, priv::emit_diff_stats}): If the sonames
changed and we are allowed to report it, then report it.
(compute_diff): In the variant for corpus_diff, do not forget to
compare the sonames.
* src/abg-reader.cc (build_needed, read_elf_needed_from_input):
Define new static functions.
(read_corpus_from_input): Read the 'soname' attribute from the
'abi-corpus' xml element node.
* src/abg-writer.cc (write_elf_needed): Define new static
function.
(write_corpus_to_native_xml): Write a new 'elf-needed' xml element
node that contains one xml 'dependency' element node per
dependency to emit. This uses the new write_elf_needed() function
above.
* tests/data/test-diff-dwarf/libtest19-soname-v0.so: New test
input data.
* tests/data/test-diff-dwarf/libtest19-soname-v1.so: Likewise.
* tests/data/test-diff-dwarf/test19-soname-report-0.txt: Likewise.
* tests/data/test-diff-dwarf/test19-soname-v0.c: Source code of
the first binary above.
* tests/data/test-diff-dwarf/test19-soname-v1.c: Source code of
the second binary above.
* tests/test-diff-dwarf.cc (in_out_specs): Add the test input
above to the list of test input to run this harness on.
* tests/data/Makefile.am: Add the new test input data above.
* tests/data/test-read-dwarf/test{0,1}.abi: Adjust.
* tests/data/test-read-dwarf/test{2,3,4,6,}.so.abi: Adjust.
2014-12-07 Dodji Seketeli <dodji@redhat.com>
Fix some style nits in the native reader and writer
* src/abg-reader.cc (read_symbol_db_from_input): Align parameter
names. Fix indentation of the first line of the function.
* src/abg-writer.cc (write_elf_symbols_table): Align parameter names.
2014-12-07 Dodji Seketeli <dodji@redhat.com>
Fix a crash while writing symbol information
* src/abg-corpus.cc (corpus::{get_fun_symbol_map_sptr,
get_var_symbol_map_sptr}): Make sure the symbol map is always
constructed, even if it's empty.
* tests/data/test-read-write/test26.xml: New test input data.
* tests/test-read-write.cc (in_out_spec): Add this new test input
data to the list of input data to run the harness on.
(main): Support reading and writing corpus files alongside
translation unit files that we were handling already.
* tests/data/Makefile.am: Add the new test input data to source
distribution.
2014-12-05 Dodji Seketeli <dodji@redhat.com>
Avoid showing ugly version info in the libabigail online manual
* doc/manuals/conf.py: Update copyright mention. Do not show ugly
version information.
2014-11-30 Dodji Seketeli <dodji@redhat.com>
Initial implementation of the abicompat tool
* include/abg-comparison.h
(diff_context::show_added_symbols_unreferenced_by_debug_info):
Declare new accessors.
(corpus_diff::{deleted_variables,
deleted_unrefed_function_symbols,
deleted_unrefed_variable_symbols,
apply_filters_and_suppressions_before_reporting}): Declare new
methods.
(corpus_diff::diff_stats): Declare this new type. Actually this
was previously corpus_diff::priv::diff_stats, which was a hidden
internal type.. We are moving it here, in the external API so
that client code can have more information about changes
statistics. Change all the previously publicly accessible data
members into accessor functions.
* src/abg-comparison.cc (class corpus_diff::diff_stats::priv): New
type.
(diff_context::priv::show_added_syms_unreferenced_by_di_): New
data member.
(diff_context::priv::priv): Adjust.
(diff_context::show_added_symbols_unreferenced_by_debug_info):
Define this new method.
(corpus_diff::priv::emit_diff_stats): Do not show the diff stat
if the only changes is added function or variables symbols and if
we were instructed to not show added symbols.
(corpus_diff::priv::{diff_stats_, filters_and_suppr_applied_}):
New data members.
(corpus_diff::priv::priv): Initialize the
filters_and_suppr_applied_ data member.
(corpus_diff::priv::diff_stats): Move this type to
corpus_diff::diff_stats.
(corpus_diff::priv::{apply_filters_and_compute_diff_stats,
emit_diff_stats}): Adjust.
(corpus_diff::apply_filters_and_suppressions_before_reporting):
Define new member function.
(corpus_diff::report): Use the new
apply_filters_and_suppressions_before_reporting() function, rather
than applying the filters and suppressions by ourselves. Also
adjust to the use the accessors of the new corpus_diff::diff_stats
type.
(corpus_diff::{deleted_variables,
deleted_unrefed_function_symbols,
deleted_unrefed_variable_symbols}): Define new accessors.
(corpus_diff::diff_stats::{diff_stats, num_func_removed,
num_func_added, num_func_changed, num_func_filtered_out,
net_num_func_changed, num_vars_removed, num_vars_added,
num_vars_changed, num_vars_filtered_out, net_num_vars_changed,
num_func_sym_removed, num_func_syms_added, num_var_syms_removed,
num_var_syms_added}): Define new member functions.
* include/abg-corpus.h (corpus::{get_sym_ids_of_fns_to_keep,
get_sym_ids_of_vars_to_keep}): Declare new methods.
* src/abg-corpus.cc (corpus::priv::{sym_id_fns_to_keep,
sym_id_vars_to_keep}): Added data members.
(symtab_build_visitor_type::{unrefed_fun_symbols,
unrefed_var_symbols, sym_id_fns_to_keep, sym_id_vars_to_keep}):
Added new data members.
(symtab_build_visitor_type::symtab_build_visitor_type): Take two
additional parameters for the function and variable symbol ids to
keep.
(symtab_build_visitor_type::add_fn_to_wip_fns): Take the function
symbols to keep in account when building the exported symbol
table.
(symtab_build_visitor_type::add_var_to_wip_vars): Likewise, take
the variable symbols to keep in account when building the exported
symbol table.
(corpus::priv::build_public_decl_table): Adjust the initialization
of the visitor that walks the ABI artifacts to build the exported
symbol table to know take a list of function/variable symbols to
keep.
(corpus::priv::build_unreferenced_symbols_tables): Ensure that the
public table of functions/variables is built before doing the work
of this function. Also, if a list of variable/function symbols to
keep is given, drop all symbols that are not in that list on the
floor.
(corpus::{get_sym_ids_of_fns_to_keep,
get_sym_ids_of_vars_to_keep}): Define new accessors.
* tools/abicompat.cc: New abicompat tool.
* doc/manuals/abicompat.rst: New documentation source for
abicompat.
* doc/manuals/libabigail-tools.rst: Add an entry for the abicompat
doc.
* tests/test-abicompat.cc: New test harness for the 'abicompat'
tool.
* tests/Makefile.am: Build the runtestabicompat test harness and
add it to the list of tests harnesses that are run by make check.
* tests/data/test-abicompat/libtest0-fn-changed-libapp-v0.so: New
test input.
* tests/data/test-abicompat/libtest0-fn-changed-libapp-v1.so: Likewise.
* tests/data/test-abicompat/test0-fn-changed-app: Likewise.
* tests/data/test-abicompat/test0-fn-changed-0.suppr: Likewise
* tests/data/test-abicompat/test0-fn-changed-report-0.txt: Likewise.
* tests/data/test-abicompat/test0-fn-changed-report-1.txt: Likewise.
* tests/data/test-abicompat/test0-fn-changed-app.cc: Likewise.
* tests/data/test-abicompat/test0-fn-changed-libapp.h: Likewise.
* tests/data/test-abicompat/test0-fn-changed-libapp-v0.cc: Likewise.
* tests/data/test-abicompat/test0-fn-changed-libapp-v1.cc: Likewise.
* tests/data/test-abicompat/libtest1-fn-removed-v0.so: Likewise.
* tests/data/test-abicompat/libtest1-fn-removed-v1.so: Likewise.
* tests/data/test-abicompat/test1-fn-removed-app: Likewise.
* tests/data/test-abicompat/test1-fn-removed-app.cc: Likewise.
* tests/data/test-abicompat/test1-fn-removed-report-0.txt: Likewise.
* tests/data/test-abicompat/test1-fn-removed-v0.cc: Likewise.
* tests/data/test-abicompat/test1-fn-removed-v1.cc: Likewise.
* tests/data/test-abicompat/libtest2-var-removed-v0.so: Likewise.
* tests/data/test-abicompat/libtest2-var-removed-v1.so: Likewise.
* tests/data/test-abicompat/test2-var-removed-app: Likewise.
* tests/data/test-abicompat/test2-var-removed-app.cc: Likewise.
* tests/data/test-abicompat/test2-var-removed-report-0.txt: Likewise.
* tests/data/test-abicompat/test2-var-removed-v0.cc: Likewise.
* tests/data/test-abicompat/test2-var-removed-v1.cc: Likewise.
* tests/data/test-abicompat/libtest3-fn-removed-v0.so: Likewise.
* tests/data/test-abicompat/libtest3-fn-removed-v1.so: Likewise.
* tests/data/test-abicompat/test3-fn-removed-app: Likewise.
* tests/data/test-abicompat/test3-fn-removed-app.cc: Likewise.
* tests/data/test-abicompat/test3-fn-removed-report-0.txt: Likewise.
* tests/data/test-abicompat/test3-fn-removed-v0.cc: Likewise.
* tests/data/test-abicompat/test3-fn-removed-v1.cc: Likewise.
* tests/data/test-abicompat/test3-fn-removed-version-script-0 Likewise.:
* tests/data/test-abicompat/test3-fn-removed-version-script-1: Likewise.
* tests/data/Makefile.am: Add the new test inputs above to the
source distribution.
2014-11-30 Dodji Seketeli <dodji@redhat.com>
Support reading undefined symbols from an ELF file
* include/abg-corpus.h (corpus::{set_undefined_fun_symbol_map,
set_undefined_var_symbol_map, get_undefined_fun_symbol_map_sptr,
get_undefined_fun_symbol_map, get_sorted_undefined_fun_symbols,
get_undefined_var_symbol_map_sptr, get_undefined_var_symbol_map,
get_sorted_undefined_var_symbols}): Declare new methods ...
* src/abg-corpus.cc (corpus::{set_undefined_fun_symbol_map,
set_undefined_var_symbol_map, get_undefined_fun_symbol_map_sptr,
get_undefined_fun_symbol_map, get_sorted_undefined_fun_symbols,
get_undefined_var_symbol_map_sptr, get_undefined_var_symbol_map,
get_sorted_undefined_var_symbols}): ... and define them.
(struct corpus::priv::{undefined_var_symbol_map,
sorted_undefined_var_symbols, undefined_fun_symbol_map,
sorted_undefined_fun_symbols}): New data members.
* src/abg-dwarf-reader.cc (get_symbol_versionning_sections): Also
return the SHT_GNU_verneed section.
(get_version_needed_for_versym): New static function.
(get_version_definition_for_versym): Factorize this function out
of ..
(get_version_for_symbol): ... this one. Take a flag that says if
we want the definition version or the needed version of a symbol.
Extend the implementation using the two new function
get_version_needed_for_versym() and
get_version_definition_for_versym() above. This function now
returns the version either for a defined & exported symbol, or for
an undefined symbol.
(lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab, lookup_symbol_from_symtab):
Adjust for the change of signature of get_version_for_symbol().
(read_context::{undefined_fun_syms_, undefined_var_syms_}): New
data members.
(read_context::lookup_elf_symbol_from_index): Adjust for
invocation of the new signature of get_version_for_symbol().
(read_context::{undefined_fun_syms_sptr, undefined_fun_syms,
undefined_var_syms_sptr, undefined_var_syms}): Define new methods.
(read_context::load_symbol_maps): Add support for loading
undefined symbols and their versions.
(read_context::maybe_load_symbol_maps): Take in account the need
to load undefined symbols as well.
(read_corpus_from_elf): Once the undefined symbols have been read
from the ELF file, stuff them into the resulting ABI corpus that
has been built.
2014-11-30 Dodji Seketeli <dodji@redhat.com>
Show the pretty representation of deleted variables in the diff output
* src/abg-comparison.cc (corpus_diff::report): Show the pretty
representation of deleted variables in all cases.
2014-11-30 Dodji Seketeli <dodji@redhat.com>
Fix status checking in abidw
* tools/abidw.cc (main): Fix successful status checking.
2014-11-30 Dodji Seketeli <dodji@redhat.com>
Rename elf_symbol::get_is_defined() to elf_symbol::is_defined()
* include/abg-ir.h (elf_symbol::get_is_defined): Rename into
elf_symbol::is_defined.
(elf_symbol::set_is_defined): Rename into elf_symbol::is_defined.
* src/abg-ir.cc (elf_symbol::get_is_defined): Likewise, rename
this into elf_symbol::is_defined.
(elf_symbol::set_is_defined): Likewise, rename this into
elf_symbol::is_defined.
(elf_symbol::{elf_symbol, is_public}): Adjust.
* src/abg-writer.cc (write_elf_symbol): Adjust.
2014-11-30 Dodji Seketeli <dodji@redhat.com>
Update the copyright years of include/abg-corpus.h
* include/abg-corpus.h: Update the copyright years of this file.
2014-11-20 Dodji Seketeli <dodji@redhat.com>
Make tests/data directory have its own Makefile
* configure.ac(AC_CONFIG_FILE): Generate a new tests/data/Makefile
file.
* tests/Makefile.am: Link the data/ sub-directory from here. Move
the EXTRA_DIST definition to ...
* tests/data/Makefile.am: ... this new file here.
2014-11-20 Dodji Seketeli <dodji@redhat.com>
Hmh, finally EXTRA_DIST was just fine
* tests/Makefile.am: Put EXTRA_DIST back.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Make sure we don't try to build test data
* tests/Makefile.am: Replace EXTRA_DIST with noinst_DATA.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Fix manual documentation generation
* doc/manuals/Makefile.am: Trigger the manual generation from the
html-doc target. Add the source files to the distribution. Fix
the clean target.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Fix apidoc building
* doc/Makefile.am: Trigger the building frm the html-doc target.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Cleanup of configure.ac
* configure.ac: Remove useless variables and fix a typo.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Add loads of forgotten test data files to source distribution
* tests/Makefile.am: Add lots of test data file that were
forgotten and then revealed by running make distcheck. Also fix
some wrong paths to test data files.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Use DESTDIR in doc/manuals/Makefile.am when creating the manuals
* doc/manuals/Makefile.am: Use the DESTDIR variable when
addressing the destination directory of the created manuals.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Fix a thinko in doc/Makefile.am
* apidoc-install-html-doxygen: Make sure that the directory
$(DESTDIR)$(docdir) does not exist, before trying to create it.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Add doc/api/libabigail.doxy to source distribution
* doc/Makefile.am: Add the file api/libabigail.doxy to source
distribution.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Make the install-html target of apidoc/manual be conditional
* configure.ac: add --enable-apidoc and --enable-manual. Add the
two ENABLE_APIDOC and ENABLE_MANUAL automake conditional
variables. Add the activation of the apidoc and manual into the
final package configuration report.
* doc/Makefile.am: Make the install-html, install-data-local and
uninstall-local targets conditional on the ENABLE_APIDOC
conditional variable.
* doc/manuals/Makefile.am: Likewise, make the install-html,
install-data-local and uninstall-data-local conditional on the
ENABLE_MANUAL conditional variable.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Make the alt dwarf debug file *not* be a symlink
* tests/data/test-alt-dwarf-file/test0-debug-dir/.build-id/16/7088580c513b439c9ed95fe6a8b29496495f26.debug:
Make this be a real file, no more a symlink to
../../../test0-common-dwz.debug.
* tests/data/test-alt-dwarf-file/test0-report.txt: Now that the
file above is no more a symlink the message emitted by the test
changes. It now says that the file found is the base name of the
real file. So change the reference report accordingly.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Use the POSIX 1003.1-1988 tar format for dist tar
* configure.ac: For the tar invocation made by make dist, make
sure to use the POSIX 1003.1-1988 tar format that can support file
names of more than 99 characters. This is useful for the
test-alt-dwarf-file test that has data made of a file which patch
has more than 99 characters.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
Nested automake conditionals don't work
* configure.ac (ENABLE_ZIP_ARCHIVE_AND_CXX11): Define this
automake condition variable that is true if both the zip archive
and c++11 features are enabled. This is important to know if the
test runtestdot is going to be compiled. That test needs both
c++11 and the zip archive features.
* tests/Makefile.am: Do not nest automake conditional statements.
It does not work. Rather, use the new
ENABLE_ZIP_ARCHIVE_AND_CXX11 condition variable.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
INSTALL file is not yet in the distribution
* Makefile.am: Do not say that INSTALL file is in the distribution
while it is not.
2014-11-19 Dodji Seketeli <dodji@redhat.com>
If c++11 is disable do not execute the runtestdot test
* tests/Makefile.am: runtestdot should not be executed if c++11 is
disabled.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
make html now generates the apidoc, manual and web site
* doc/Makefile.am (html-local): Make the html file generation be
triggered by the html-local target, not the html target. The html
target is a recursive target that calls the the html-local targets
under each directory.
(apidoc-html-doxygen): Rename the doc-html-doxygen target into
(apidoc-install-html-doxygen): Rename doc-install-html-doxygen
into this. this.
(DO_HTML, DO_INSTALL_HTML): Adjust.
(install-data-local): New target.
* doc/manuals/Makefile.am (install-html, install-data-local): New
targets.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Generate the manual html documentation in the proper build directory
* doc/manuals/Makefile.am: Renamed doc/manuals/Makefile into this.
(BUILDDIR): Make this variable point to $(builddir)/_build as
opposed to just _build previously.
(SOURCEDIR): New variable that points to the source dir as known
by the autotools magic.
(ALLSPHINXOPTS): Make the source dir refer to the new
$(SOURCEDIR), rather than just '.' as previously.
* configure.ac (doc/manuals/Makefile): Generate this now.
* doc/Makefile.am: Link the sub-directory doc/manuals.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Update Makefile.am after the additions related to gen-changelog.py
* Makefile.am: Add ChangeLog and COPYING-LGPLV2 to the source
distribution.
(update-changelog, tag-release-only tag-release): New Makefile
targets.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Added a ChangeLog that is auto-generated by gen-changelog.py
* ChangeLog: Add this auto-generated file.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
[gen-changelog] Make subject line always come first
* gen-changelog.py (process_commit): In changelog entries with an
empty body, make sure the subject line comes first.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Try harder to remove timezone info from the date
* gen-changelog.py (process_commit): The timezone shit can start
either with a '+' or a '-'.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Not all ChangeLog file lines end up with a ':'
* gen-changelog.py (process_commit): When trying to recognize the
beginning of a ChangeLog entry body, do not expect a line that
starts with a '*' to end with a ':' because there can be long file
names that end on the next line.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Allow introductory text in commit log and ignore it when generating ChangeLog
* gen-changelog.py (process_commit): Everything that comes between
the subject line of the commit and the first \t* sequence is
considered to be introductory text. Ignore it when generating the
ChangeLog entry.
* COMMIT-LOG-GUIDELINES: Update the commit log guidelines to
reflect the fact that we can now have introductory text in the
commit log.
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Initial import of gen-changelog.py
* gen-changelog.py: Copy from
https://github.com/GNOME/gnet/blob/master/gen-changelog.py.
License it under LGPLV v2+ after asking Edward Hervey's kind
permission. Ain't Free Software really great?
2014-11-18 Dodji Seketeli <dodji@redhat.com>
Fix the reference to the IRC channel on the web page
* doc/website/mainpage.txt: The IRC server address is
irc.oftc.net, not just oftc.net.
* include/abg-fwd.h: Likewise.
2014-11-10 Dodji Seketeli <dodji@redhat.com>
Consider enclosing template when comparing template parameters
* src/abg-ir.cc (template_parameter::priv::comparison_started_):
New data member.
(template_parameter::priv::priv): Initialize it.
(template_parameter::operator==): Compare the enclosing template
too. And avoid infinite recursion.
2014-11-10 Dodji Seketeli <dodji@redhat.com>
Remove mention of libzip from the web page
* doc/website/mainpage.txt: Remove mention of libzip from the list
of dependencies.
2014-11-10 Dodji Seketeli <dodji@redhat.com>
Cleanup of the web page
* doc/website/libabigail-website.doxy: Remove the redundant
information that was appearing on the web page.
* doc/website/mainpage.txt: Clean-up the text of the web page, add
information for the new IRC channel #libabigail on oftc.net,
re-organize the content by putting sections where we had
paragraphs. Add a table of content. Also add a web form to
subscribe/unsubscribe to the mailing list.
2014-11-08 Dodji Seketeli <dodji@redhat.com>
Sort functions by the their qualified name
* src/abg-comparison.cc (function_comp::operator()): Sort the
functions by only looking at their qualified name, as opposed to
their return type name.
2014-11-08 Dodji Seketeli <dodji@redhat.com>
Remove too tight assert from de-mangling code
* src/abg-ir.cc (demangle_cplus_mangled_name): The return length
can be zero. That means, no de-mangling was done.
2014-11-08 Dodji Seketeli <dodji@redhat.com>
Sort reported changed declarations & types in a given scope
* src/abg-comparison.cc (struct changed_type_or_decl_comp, struct
changed_vars_comp): New comparison functors.
(sort_changed_type_or_decl, sort_changed_vars): New static
functions.
(scope_diff::report): Use the above to sort changed declarations,
and types in a given scope.
(corpus_diff::report): Likewise for the changed variables.
* tests/data/test-abidiff/test-struct1-report.txt: Adjust.
* tests/data/test-diff-suppr/test7-var-suppr-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-8.txt:
Likewise.
2014-11-08 Dodji Seketeli <dodji@redhat.com>
Sort elf symbols before serializing them
* include/abg-corpus.h (corpus::{get_sorted_fun_symbols,
get_sorted_var_symbols}): Declare new member functions.
* src/abg-corpus.cc (corpus_priv::{sorted_var_symbols,
sorted_fun_symbols}): New data members.
(struct elf_symbol_comp_functor): Define new comparison functor.
(corpus::{get_sorted_fun_symbols, get_sorted_var_symbols}): Define
new member functions.
* src/abg-writer.cc (write_elf_symbols_table): Take a sorted
vector of symbols in parameters, rather than an unsorted map.
(write_corpus_to_native_xml): Write a sorted vector of symbols,
rather than an unsorted map of symbols.
* tests/data/test-read-dwarf/test0.abi: Adjust.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
* tests/data/test-read-dwarf/test3.so.abi: Likewise.
* tests/data/test-read-dwarf/test6.so.abi: Likewise.
2014-11-07 Dodji Seketeli <dodji@redhat.com>
Fix template parameter hashing: make it know about enclosing template
* include/abg-ir.h (template_parameter_sptr, template_decl_sptr)
(template_decl_wptr): Declare new typedefs.
(class template_decl): Make this virtually inherit decl_base and
pimpl-ify it.
(class template_parameter): Pimpl-ify this. Make the constructor
take the enclosing template parameter.
(struct template_decl::hash): Declare this here, rather than in
src/abg-hash.cc
(class type_tparameter, non_type_tparameter, template_tparameter)
(class type_composition, function_tdecl, class_tdecl): Pimpl-ify
this.
* src/abg-hash.cc (template_parameter::hash::operator()): Hash the
enclosing template parameter. Avoid infinite recursion due to the
loop hash parameter -> hash template -> hash parameter.
(template_decl::hash::operator()) Define this here, now that it's
declared in abg-ir.h. Also, avoid infinite recursion here; this
is complementary to what is done in the hashing for
template_parameter.
({type_tparameter, template_tparameter, }::hash::operator()):
Cache the calculated hash just as what is done for other types
hashed.
(template_decl::priv): Define this new type.
(template_decl::{add_template_parameter, get_template_parameters,
~template_decl}): Define these here to pimpl-ify template_decl.
(template_parameter::priv): Define this new type.
(template_parameter::template_parameter): Define this here to
pimpl-ify template_parameter. Note also that this now takes the
enclosing template decl.
(template_parameter::{get_index, get_enclosing_template_decl,
get_hashing_has_started, set_hashing_has_started, operator::==}):
Define these here to pimpl-ify template_parameter.
(type_tparameter::priv): Define this new type.
(type_tparameter::type_tparameter): Define this here to pimpl-ify
type_tparameter. Also, not that this constructor now takes the
enclosing template decl.
(class non_type_tparameter::priv): Define new type.
(non_type_tparameter::{non_type_tparameter, get_type}): Define
these here to pimpl-ify non_type_tparameter. The constructor now
takes the enclosing template.
(template_tparameter::priv): Define new type.
(template_tparameter::template_tparameter): Define this here to
pimpl-ify template_tparameter. This constructor now takes the
enclosing template.
(class type_composition::priv): New type.
(type_composition::{type_composition, get_composed_type,
set_composed_type}): Define these here to pimpl-ify
type_composition. The constructor now takes the enclosing
template decl.
(class function_tdecl::priv): Define new type.
(function_tdecl::{function_tdecl, set_pattern, get_pattern,
get_binding}): Define this here to pimpl-ify function_tdecl.
(class class_tdecl::priv): Define this new type.
(class_tdecl::class_tdecl): Define this here to pimpl-ify
class_tdecl.
(class_tdecl::set_pattern): Adjust to pimpl-ify.
(class_tdecl::get_pattern): Define new pimpl-ified getter.
* src/abg-reader.cc (build_function_tdecl, build_class_tdecl):
Cleanup. Pass the enclosing template to the template parameters
that are built.
(build_type_tparameter, build_type_composition)
(build_non_type_tparameter, build_template_tparameter)
(build_template_parameter): Take the enclosing template
declaration and pass it to the template parameter being created.
* tests/data/test-read-write/test12.xml: Fix and Adjust.
* tests/data/test-read-write/test13.xml: Likewise.
2014-11-06 Dodji Seketeli <dodji@redhat.com>
Style fix
* include/abg-ir.h (class location): Remove useless white space.
* src/abg-writer.cc (type_has_existing_id): Use type_base_sptr
rather than shared_ptr<type_base>.
(write_template_tparameter): Use template_tparameter_sptr rather
than shared_ptr<template_tparameter>.
2014-11-05 Dodji Seketeli <dodji@redhat.com>
Pass -std=gnu++11 to the compiler when --enable-cxx11 for tests
* tests/Makefile.am: Pass -std=gnu++11 to the compiler when
--enable-cxx11 has been used.
2014-11-05 Dodji Seketeli <dodji@redhat.com>
Make the use of a C++-11 compiler optional
* configure.ac: Define a new --enable-cxx11 switch to control the
use of the C++-11 compiler. Define a WITH_CXX11 C macro and an
automake ENABLE_CXX11 variable.
* config.h.in: Initialize the new WITH_CXX11 C macro.
* src/Makefile.am: Include the files coded in C++-11 only if the
ENABLE_CXX11 automake variable is defined.
* tests/Makefile.am: Likewise, build the runtestsvg test program
only if C++-11 usage is enabled.
* include/abg-diff-utils.h (class d_path_vec): Remove useless
usage of the 'typename' keyword.
* include/abg-fwd.h (is_enum_type): Renamed is_enum into this,
because of a name clash with a tr1 function when not using C++-11.
(is_pointer_type): Likewise, renamed is_pointer into this because
of a name clash with a tr1 function when not using C++-11.
* src/abg-comp-filter.cc (has_harmless_name_change): Adjust for
the is_enum -> is_enum_type change.
* src/abg-comparison.cc (type_suppression::suppresses_diff):
Likewise.
(class function_suppression::priv): Add a missing "class" keyword
in friend declaration.
(diff_context::diff_has_been_traversed)
(diff_context::mark_diff_as_traversed): Do not use the C++-11
specific type uintptr_t.
* src/abg-dwarf-reader.cc (create_default_dwfl): Do not use
designated initializers. Sigh. This is handy though.
(expr_result::abs): Cast the argument of std::abs to avoid
ambiguous call.
(finish_member_function_reading): Adjust for the is_pointer ->
is_pointer_type renaming.
* src/abg-hash.cc (scope_decl::hash::operator)
(class_decl::base_spec::hash::operator)
(type_composition::hash::operator): Use std::tr1::hash string,
rather than the C++-11 specific std::hash function.
* src/abg-ini.cc (read_sections, write_sections): Make
std::ifstream constructor take a const char* rather than a string.
* src/abg-ir.cc (is_enum_type, is_pointer_type): Renamed is_enum
into is_enum_type and is_pointer into is_pointer_type.
* src/abg-writer.cc (write_translation_unit): Remove useless
typename keyword. Make ofstream take a const char* rather than a
string.
(write_namespace_decl): Remove useless typename keyword.
(write_corpus_to_native_xml_file): Make ofstream take a const
char* rather than a string.
* tests/test-abidiff.cc (main): Make ofstream take a const char*
rather than a string.
* tests/test-diff-dwarf.cc (main): Likewise.
2014-11-05 Dodji Seketeli <dodji@seketeli.org>
Remove some m4 auto-generated files from version control
* m4/ltoptions.m4: Remove from version control.
* m4/ltversion.m4: Remove from version control.
* m4/lt~obsolete.m4: Remove from version control.
2014-11-03 Dodji Seketeli <dodji@redhat.com>
Add usage examples to the abidiff manual
* doc/manuals/abidiff.rst: Add a usage example section along with
some small and clean examples.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Fix the API doc string of the abigail::xml_writer namespace
* src/abg-writer.cc: Fix the API doc of the xml_writer namespace.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Fix an apidoc typo
* include/abg-comparison.h (class variable_suppression): Fix a
typo in the doc string.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Update the manual for variable suppression concepts
* doc/manuals/libabigail-concepts.rst: Add a section for variable
suppression specification in the concepts part of the manual.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Fix some restructured text doc glitches in the fn suppression manual
* doc/manuals/libabigail-concepts.rst: Fix quoting of the syntax
of parameter specification string, for the function suppression
concepts.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Cleanup the mainpage of the API doc
* include/abg-fwd.h: Cleanup text of the API doc mainpage.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Make get_binary_load_address static
* src/abg-dwarf-reader.cc (get_binary_load_address): Make this
function static.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Initial support for variable suppressions
* include/abg-comparison.h (variable_suppression_sptr)
(variable_suppressions_type): New convenience typedefs.
(class variable_suppression): Declare new type.
* src/abg-comparison.cc (is_var_diff): New predicate.
(read_variable_suppression): Define new static function.
(class variable_suppression::priv): Define type for the private
data of the variable_suppression type.
(variable_suppression::{variable_suppression,
~variable_suppression, get_name, set_name, get_name_regex_str,
set_name_regex_str, get_symbol_name, set_symbol_name,
get_symbol_name_regex_str, set_symbol_name_regex_str,
get_symbol_version, set_symbol_version,
get_symbol_version_regex_str, set_symbol_version_regex_str,
get_type_name, set_type_name, get_type_name_regex_str,
set_type_name_regex_str, suppresses_diff}): Define new member
functions for the variable_suppression type.
* tests/data/test-diff-suppr/libtest7-var-suppr-v0.so: Add new
test input.
* tests/data/test-diff-suppr/libtest7-var-suppr-v1.so: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-1.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-2.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-3.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-4.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-5.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-6.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-7.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-8.suppr: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-3.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-4.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-5.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-6.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-7.txt: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-report-8.txt:
Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-version-script: Likewise.
* tests/data/test-diff-suppr/test7-var-suppr-v0.cc: Source code
for the librairie above.
* tests/data/test-diff-suppr/test7-var-suppr-v1.cc: Source code
for the librairie above.
* tests/Makefile.am: Add the new test input data to the source
distribution.
* tests/test-diff-suppr.cc: Update to make this harness to run
over the new test input above.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Update the suppr-doc.txt file for variable suppressions
* doc/suppr-doc.txt: Add the suppress_variable section example.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Make var_diff and function_decl_diff extend decl_diff_base
* include/abg-comparison.h (class var_diff, class
function_decl_diff): Make these types inherit the decl_diff_base
class. This is like the fact that all kinds of diff inherit the
type_diff_base class.
* src/abg-comparison.cc (var_diff::var_diff)
(function_decl_diff::function_decl_diff): Adjust to initialize the
sub-object of decl_diff_base;
(is_decl_diff): New predicate to know if a diff is about decls.
(is_function_decl): New predicate to know if a diff is about
function decls.
(function_suppression::suppresses_diff): Adjust to use the new
is_function_decl.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Fix logic of type suppression evaluation
* include/abg-comparison.cc (type_suppression::suppresses_diff):
Try to evaluate the "type_name_regexp" property only if the
"type_name" is empty.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Remove useless functions from the comparison engine
* include/abg-comparison.h (read_type_suppression): Remove this
function declaration.
* src/abg-comparison.cc (read_type_suppressions): Remove this
static function definition.
(read_function_suppressions): Remove this static function
declaration.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Spit and polish variables presentation in diff report
* src/abg-comparison.cc (corpus_diff::report): Show the full
representation of the variable, rather than just its name. Also,
show the new representation of the variable only if it has
changed.
* tests/data/test-diff-dwarf/test9-report.txt: Adjust test.
* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
* tests/data/test-diff-filter/test15-1-report.txt: Likewise.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Fix various apidoc typos
* include/abg-comparison.h (class function_suppression): Fix typo
in the doc string.
* src/abg-comparison.cc (is_type_diff, read_suppressions)
(diff::reported_once, typedef_diff::report): Fix the doc string.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Fix regexp escaping section of manual
* doc/manuals/libabigail-concepts.rst: Re-indent and fix some
typos in the regexp escaping section of the manual.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Doxygen shouldn't extract doc for static functions or private types
* doc/api/libabigail.doxy: Do not extract doc for static
functions, local classes.
2014-11-01 Dodji Seketeli <dodji@redhat.com>
Update .gitignore
* .gitignore: Ignore *~ emacs files.
2014-10-29 Dodji Seketeli <dodji@redhat.com>
Separate alias targets with a comma
* src/abg-ir.cc (elf_symbol::get_aliases_id_string): Separate
alias targets by a comma.
* tests/data/test-diff-dwarf/test18-alias-sym-v1.cc: Update test
to add more than one alias to a given symbol.
2014-10-28 Dodji Seketeli <dodji@redhat.com>
Fix a typo in the manual about function suppressions
* doc/manuals/libabigail-concepts.rst: Fix a typo.
2014-10-28 Dodji Seketeli <dodji@redhat.com>
Initial support for function suppressions
* include/abg-comparison.h (enum visiting_kind): Change the
meaning of this. It was to determine if traversal was to be done
in a pre or post manner. But with the recent addition of
diff_node_visitor::visit_{begin,end}() notifiers, the pre/post
handling is taken care of in a different way. So now the meaning
of this enum is changed to handle whether diff node children
should be visited or not. So the enumerators are now
DEFAULT_VISITING_KIND, and SKIP_CHILDREN_VISITING_KIND. And it's
a bit-field.
(operator{&,~}): Declare more bit manipulation operators for the
enum visiting_kind.
(function_suppression_sptr, function_suppressions_type): New
typedefs.
(function_suppression, function_suppression::parameter_spec):
Declare new types.
(read_function_suppressions): Declare new function.
(diff_node_visitor::diff_node_visitor): Adjust for the enum
visiting_kind change. Value-initialize the visiting_kind_ data
member.
* src/abg-comparison.cc (operator{&,~}): Define these operators
for enum visiting_kind.
(read_type_suppressions): Forward declare this static function.
(read_function_suppression, read_parameter_spec_from_string):
Define new static functions.
(read_suppressions): Update to read function suppressions too,
using the new read_function_suppression function above.
(class function_suppression::parameter_spec::priv): Define new
type.
(function_suppression::parameter_spec::*): Define the member
functions of the new function_suppression::parameter_spec type.
(class function_suppression::priv): Define new type.
(function_suppression::*): Define the member functions of the new
function_suppression type.
(diff::traverse): There is no more {PRE,POST}_VISITING_KIND
enumerator. So nuke the code that was dealing with it.
(redundancy_marking_visitor::skip_children_nodes_): New data
member flag.
(redundancy_marking_visitor::visit_begin): If the current diff
node is not be reported (is filtered out), do not bother visit its
children nodes for the purpose of marking redundant nodes. So use
the new skip_children_nodes_ flag above to know we are in that case.
(redundancy_marking_visitor::visit_end): Unset the new
skip_children_nodes_ flag above when appropriate.
* include/abg-fwd.h (is_function_decl): Declare new function.
* include/abg-ir.h
(function_type::get_parm_at_index_from_first_non_implicit_parm):
Declare new member function.
* src/abg-ir.cc (is_function_decl): Define new function.
(function_type::get_parm_at_index_from_first_non_implicit_parm):
Define new member function.
* src/abg-comp-filter.cc (apply_filter): Adjust for the enum
visiting_kind change. No need to set it for filters anymore
* doc/suppr-doc.txt: Update examples of function suppression.
* doc/manuals/libabigail-concepts.rst: Update the manual for the
function suppression addition.
* tests/data/test-diff-suppr/libtest5-fn-suppr-v0.so: New test input.
* tests/data/test-diff-suppr/libtest5-fn-suppr-v1.so: New test input.
* tests/data/test-diff-suppr/libtest6-fn-suppr-v0.so: New test input.
* tests/data/test-diff-suppr/libtest6-fn-suppr-v1.so: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-0.suppr: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-1.suppr: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-2.suppr: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-3.suppr: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-4.suppr: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-report-0.txt: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-report-1.txt: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-report-2.txt: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-report-3.txt: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-report-4.txt: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-report-5.txt: New test input.
* tests/data/test-diff-suppr/test5-fn-suppr-v0.cc: Source code for
new test input.
* tests/data/test-diff-suppr/test5-fn-suppr-v1.cc: Source code for
new test input.
* tests/data/test-diff-suppr/test6-fn-suppr-0.suppr: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-1.suppr: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-2.suppr: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-3.suppr: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-report-0.txt: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-report-1.txt: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-report-2.txt: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-report-3.txt: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-report-4.txt: New test input.
* tests/data/test-diff-suppr/test6-fn-suppr-v0.cc: Source code for
new test input.
* tests/data/test-diff-suppr/test6-fn-suppr-v1.cc: Source code for
new test input.
* tests/data/test-diff-suppr/test6-fn-suppr-version-script: New
test input.
* tests/Makefile.am: Add the new files above to source
the distribution.
* tests/test-diff-suppr.cc (in_out_specs): Add the test inputs
above to the list of tests to be run by this harness.
2014-10-28 Dodji Seketeli <dodji@redhat.com>
Add missing virtual destructor in comparison engine code
* include/abg-comparison.h (type_suppression::~type_suppression):
Declare missing virtual destructor.
* src/abg-comparison.cc (type_suppression::~type_suppression):
Define missing virtual destructor.
2014-10-27 Dodji Seketeli <dodji@redhat.com>
Pimplify abigail::ir::function_type
* include/abg-ir.h (function_type::priv_): Declare new data
member.
(function_type::<all the methods>): Move the inline methods out of
line in src/abg-ir.cc.
(function_type::{return_type_, parms_}): Move these ...
* src/abg-ir.cc (function_type::priv::{return_type_, parms_}):
... Here.
(struct function_type::priv): New type for the private data of
function_type.
(function_type::<all the methods>): Move the previously inline
methods of function_type here. Adjust them to tap into priv_->*
to get the private data members.
2014-10-27 Dodji Seketeli <dodji@redhat.com>
Light style fix
* include/abg-ir.h (function_decl::get_type): Change the return
type from shared_ptr<function_type> to function_type_sptr.
2014-10-27 Dodji Seketeli <dodji@redhat.com>
Allow white spaces in ini file property values
* src/abg-ini.cc (read_context::char_is_property_value_char): New
member function.
(read_context::read_next_char): Fix typos. Allow escaping of '['
and ']'.
(read_context::read_property_value): Use the new
read_context::char_is_property_value_char above.
2014-10-27 Dodji Seketeli <dodji@redhat.com>
Fix typo in suppression specification manual
* doc/manuals/libabigail-concepts.rst: Fix name -> name_regexp.
2014-10-22 Dodji Seketeli <dodji@redhat.com>
Support comparing symbols not referenced by debug info
* doc/manuals/abidiff.rst: Adjust intro to mention that w/o debug
info, abidiff now works but just report about added/removed
symbols. Add documentation about the new
--no-unreferenced-symbols option.
* include/abg-comparison.h (string_elf_symbol_map): New typedef.
(diff_context::show_symbols_unreferenced_by_debug_info): Declare
new accessors.
* src/abg-comparison.cc
(diff_context::priv::show_syms_unreferenced_by_di_): New data
member.
(diff_context::priv::priv): Adjust.
(diff_context::show_symbols_unreferenced_by_debug_info): Implement
these accessors.
(corpus_diff::priv::{unrefed_fn_syms_edit_script_,
unrefed_var_syms_edit_script_, added_unrefed_fn_syms_,
deleted_unrefed_fn_syms_, added_unrefed_var_syms_,
deleted_unrefed_var_syms_}): New data members.
(corpus_diff::priv::diff_stats::{num_func_syms_removed,
num_func_syms_added, num_var_syms_removed, num_var_syms_added}):
New data members.
(corpus_diff::priv::diff_stats::diff_stats): Adjust.
(corpus_diff::ensure_lookup_tables_populated): Populate lookup
tables for added/removed symbols that are not referenced by any
debug info.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Compute
stats for the added/removed symbols not referenced by any debug
info.
(corpus_diff::priv::emit_diff_stats): Emit stats about
added/removed symbols that are not referenced by any debug info.
(corpus_diff::length): Adjust to take in account added/removed
symbols not referenced by any debug info.
(show_linkage_name_and_aliases): New static function.
(corpus_diff::report): When emitting a symbol name, emit its
version too, and tell if it aliases other symbols. Avoid emitted
extra new lines. Report added/removed symbols not referenced by
any debug info.
(compute_diff): In the overload for corpus_sptr, compute the diffs
for symbols not referenced by debug info.
* include/abg-corpus.h
(corpus::get_unreferenced_{function,variable}_symbols): Declare
new member functions.
* src/abg-corpus.cc (corpus_priv::{unrefed_fun_symbols,
unrefed_var_symbols}): New data members.
(corpus_priv::build_unreferenced_symbols_tables): Define new
member function.
(struct comp_elf_symbols_functor): New functor.
(corpus::is_empty): Adjust to take in account added/removed
symbols not referenced by debug info.
(corpus::{get_unreferenced_function_symbols,
corpus::get_unreferenced_variable_symbols}): Define these
accessors.
* include/abg-dwarf-reader.h (enum status): Transform this into
bitfields. Add a STATUS_UNKNOWN value that has the value 0.
(operator|(status, status), operator&(status, status))
(operator|=(status&, status), operator&=(status, status)): New
bit-wise operators to manipulate instances of the status bit-field.
* src/abg-dwarf-reader.cc (get_version_for_symbol): Fix this to
avoid returning garbage version sometimes.
(read_debug_info_into_corpus): Fix this to return a non-null but
empty corpus_sptr when there is no debug info available.
(operator|(status, status), operator&(status, status))
(operator|=(status&, status), operator&=(status, status)): Define
these new bitwise operators to manipulate instances of the status
bit-field.
(read_corpus_from_elf): Now that the abigail::dwarf_reader::status
is a bit-field, set it to reflect if debug info and/or symbol
tables have been found. Do not bail out if debug info hasn't been
found. Rather, keep going, and go look for symbols-only; this is
a kind of operating in degraded mode.
* include/abg-ir.h (elf_symbol::get_aliases_id_string): Add a flag
that says if the current instance of elf_symbol should be included
in the list of aliases or not.
* src/abg-ir.cc (elf_symbol::get_aliases_id_string): Define it.
* tests/data/test-diff-dwarf/test16-syms-only-v{0,1}.o: New test
input.
* tools/abidiff.cc
(options::show_symbols_not_referenced_by_debug_info): New data
member.
(options:options): Adjust.
(display_usage): Add an info string for the new
--no-unreferenced-symbols command line option.
(parse_command_line): Parse the new --no-unreferenced-symbols
command line.
(set_diff_context_from_opts): Set the diff_context according to
the presence of --no-unreferenced-symbols.
(main): Adjust for the fact that abigail::dwarf_reader::status is
now a bit-field.
* tools/abilint.cc (main): Adjust for the fact that
abigail::dwarf_reader::status is now a bit-field..
():
* tests/data/test-diff-dwarf/test16-syms-only-report.txt: New test
reference output.
* tests/data/test-diff-dwarf/test16-syms-only-v{0,1}.cc: Source code
for new test input.
* tests/data/test-diff-dwarf/test17-non-refed-syms-v{0,1}.o: New
test input.
* tests/data/test-diff-dwarf/test17-non-refed-syms-v{0,1}.cc: New
source code for test input.
* tests/data/test-diff-dwarf/libtest18-alias-sym-v{0,1}.so: New
test input.
* tests/data/test-diff-dwarf/test18-alias-sym-report-0.txt:
Reference output for new test input.
* tests/data/test-diff-dwarf/test18-alias-sym-v{0,1}.cc: Source
code for new test input.
* tests/data/test-diff-dwarf/test18-alias-sym-version-script:
Source code for new test input.
* tests/Makefile.am: Add the new test materials to the source
distribution.
* tests/test-diff-dwarf.cc(in_out_specs): Add the new input tests
above to the array of tests to run by this harness.
(main): Emit empty reports for empty resulting diffs.
* tests/data/test-diff-dwarf/test{0,8,9,12,14-inline-report,}-report.txt:
Adjust.
* tests/data/test-diff-filter/test{0,01,2,4,5,7,8,9,10,12,13,15-0,15-1}-report.txt:
Likewise.
* tests/data/test-diff-filter/test{19-enum,20-inline,}-report-0.txt:
Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-report-{1,2}.txt:
Likewise.
* tests/data/test-diff-suppr/test{1,2}-typedef-suppr-report-1.txt:
Likewise.
2014-10-22 Dodji Seketeli <dodji@redhat.com>
Allow comparison of shared_ptr of things
* include/abg-diff-utils.h: Adjust copyright years.
(deep_ptr_eq_functor::operator()(const shared_ptr<T>, const
shared_ptr<T>)): New comparison operator.
2014-10-17 Dodji Seketeli <dodji@redhat.com>
Use the "standard" equality operator when comparing variables
* src/abg-comparison.cc (compute_diff): In the overload for
corpus_sptr, use the diff_utils::deep_ptr_eq_functor that is used
to compare functions too, rather than the ad-hoc early struct
var_eq_type we were using until now.
2014-10-16 Dodji Seketeli <dodji@redhat.com>
Yet another fix to the DWARF method "static-ness" detection heuristic
* include/abg-fwd.h (is_pointer, is_qualified_type): Declare new
functions.
* src/abg-ir.cc (is_pointer, is_qualified_type): Implement these
new functions.
* src/abg-dwarf-reader.cc (finish_member_function_reading):
Sometimes, the this pointer of a non-static method can point to a
*qualified* version of its containing type. I am seeing that when
comparing libstdc++.so from RHEL 6.5 and RHEL 7. Take that in
account when trying to detect that the first parameter of a member
function is the this pointer, and thus detect that the function is
a non static member function.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so.abi:
New test input.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.so: New
test input.
* tests/data/test-read-dwarf/test8-qualified-this-pointer.cc:
Source code of new test input.
* tests/test-read-dwarf.cc: Update copyright year.
(in_out_spec): Add the new test inputs to this array, so that this
test harness runs on them.
* tests/Makefile.am: Add the new test inputs to the source
distribution.
2014-10-16 Dodji Seketeli <dodji@redhat.com>
Avoid infinite loops in the comparison code for classes
* src/abg-ir.cc (equals): In the overload for classes, make sure
to store the name of the lhs of the class and the rhs into the
lhs. Also, when we bail out because we detect that there is a
comparison underway, do *not* unmark the current class as not being
involved in the comparison. Also, break at the first lhs virtual
member function that is different from the rhs counter part.
2014-10-15 Dodji Seketeli <dodji@redhat.com>
Update the manual for the suppression specification initial work
* doc/manuals/abidiff.rst: Add documentation for the new
--suppressions command line switch.
(--harmless, --harmful): Refer to the new "concepts" section
below, where harmful/harmless concepts are now explained.
(Notes): Move the content of the notes section where
harmful/harmless concepts were explained, to the newly created
'Concepts' section.
* doc/manuals/index.rst: Limit the depth of the table of content
to 2. Add the new libabigail-concepts.rst stuff in here. Adjust
for the renaming of tools.rst to libabigail-tools.rst.
* doc/manuals/libabigail-concepts.rst: New file.
2014-10-13 Dodji Seketeli <dodji@redhat.com>
Properly propagate {REDUNDANT, SUPPRESSED}_CATEGORY wrt local changes
* src/abg-comparison.cc
(suppression_categorization_visitor::visit_end): If a diff node
carries local changes, then, even if all of its children node have
been suppressed, this diff node shall not be categorized as
suppressed by way of propagation.
(redundancy_marking_visitor::visit_end): If a diff node carries
local changes, then, even if all of its children nodes are
redundant, this diff node shall not be categorized as being
redundant by way of propagation.
* tests/data/test-diff-suppr/libtest4-local-suppr-v{0,1}.so: New test
inputs.
* tests/data/test-diff-suppr/test4-local-suppr-0.suppr: Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-report-{0,1}.txt:
Likewise.
* tests/data/test-diff-suppr/test4-local-suppr-v{0,1}.{c,h}:
Source code of the new tests inputs.
* tests/Makefile.am: Add the new test material to the source
distribution.
* tests/test-diff-suppr.cc (in_out_spec): Run this test harness
over the new test input above.
2014-10-13 Dodji Seketeli <dodji@redhat.com>
Gain ability know if a diff node has local changes
* include/abg-comparison.h (diff::has_local_changes): Add new pure
interface.
({decl_diff_base, type_diff_base, distinct_type_diff, var_diff,
pointer_diff, reference_diff, array_diff, qualified_type_diff,
enum_diff, class_diff, base_diff, scope_diff, function_decl_diff,
type_decl_diff, typedef_diff,
translation_unit_diff}::has_local_changes): Declare the
implementation of the pure interface above.
* src/abg-comparison.cc ({decl_diff_base, type_diff_base,
distinct_type_diff, var_diff, pointer_diff, reference_diff,
array_diff, qualified_type_diff, enum_diff, class_diff, base_diff,
scope_diff, function_decl_diff, type_decl_diff, typedef_diff,
translation_unit_diff}::has_local_changes): Define the
implementation of the pure interface above.
2014-10-13 Dodji Seketeli <dodji@redhat.com>
Write comparison functions that hint at the kind of changes they see
* include/abg-ir.h (enum change_kind): Declare new enum.
(operator|(change_kind, change_kind), operator&(change_kind,
change_kind), operator|=(change_kind&, change_kind)): Declare new bit-wise
operators for the new enum change_kind.
(equals): Declare this new comparison function for decl_base,
scope_decl, type_base, type_decl, scope_type_decl,
qualified_type_def, pointer_type_def, reference_type_def,
array_type_def, enum_type_decl, typedef_decl, var_decl,
function_decl, function_type, class_decl, and
class_decl::base_spec.
(class_decl::base_spec::operator(const decl_base&)): Declare new
equality operator.
* src/abg-ir.cc (operator|(change_kind l, change_kind r))
(operator&(change_kind l, change_kind r), operator|=(change_kind&
l, change_kind r), operator&=(change_kind& l, change_kind r)):
Define these new operators.
(equals): Define this new comparison function for decl_base,
scope_decl, type_base, type_decl, scope_type_decl,
qualified_type_def, pointer_type_def, reference_type_def,
array_type_def, enum_type_decl, typedef_decl, var_decl,
function_decl, function_type, class_decl, and
class_decl::base_spec.
({decl_base, scope_decl, type_base, type_decl, scope_type_decl,
qualified_type_def, pointer_type_def, reference_type_def,
array_type_def, enum_type_decl, typedef_decl, var_decl,
function_decl, function_type, class_decl,
class_decl::base_spec}::operator==): Re-write these comparison
operators in terms of their relevant equal() functions.
2014-09-22 Dodji Seketeli <dodji@redhat.com>
Fix struct type kind suppression support
* src/abg-comparison.cc (type_suppression::suppresses_diff): Do
not crash on diff nodes that are not about struct/classes, when
"type_kind = struct" has been specified.
* tests/data/test-diff-suppr/test2-struct-suppr-{0,1}.suppr: New test input.
* tests/data/test-diff-suppr/test2-struct-suppr-report-{0,1}.txt:
Likewise.
* tests/data/test-diff-suppr/test2-struct-suppr-v{0,1}.o: Likewise
* tests/data/test-diff-suppr/test2-struct-suppr-v{1,0}.cc: Source code
for binary test input.
* tests/test-diff-suppr.cc (in_out_spec): Run this harness on the
new test input above.
* tests/Makefile.am: Add the new test input files to source
distribution.
2014-09-22 Dodji Seketeli <dodji@redhat.com>
Replace is_typedef by type_kind property in type suppressions
* doc/suppr-doc.txt: Add type_kind property "documentation" in the
type suppression.
* include/abg-comparison.h (type_suppression::type_kind): New
enum.
(type_suppression::{get_consider_typedefness,
set_consider_typedefness, get_is_typedef, set_is_typedef}):
Remove.
(type_suppression::{get_consider_type_kind,
set_consider_type_kind, get_type_kind, set_type_kind}): Declare
new methods.
* Include/abg-fwd.h (is_type_decl): Declare new function.
(is_enum): Declare new overload that takes a type_base_sptr.
* src/abg-comparison.cc
(type_suppression::priv::{consider_typedefness_, is_typedef_}):
Remove these data members.
(type_suppression::priv::{consider_type_kind_, type_kind_}): New
data members.
(type_suppression::priv::priv): Adjust.
(type_suppression::{get_consider_typedefness,
set_consider_typedefness, get_is_typedef, set_is_typedef}): Remove
these member functions.
(type_suppression::{get_consider_type_kind,
set_consider_type_kind, get_type_kind, set_type_kind}): Define
these new member functions.
(type_suppression::suppresses_diff): Adjust to consider the kind
of types more generally than just considering typedef-ness.
(read_type_kind_string): New static function.
(read_type_suppression): Use the above to parse the value of the
new type_kind property. Adjust the creation of the resulting
type_suppression object.
* src/abg-ir.cc (is_type_decl): Define new function.
* tests/data/test-diff-suppr/test1-typedef-suppr-0.suppr: Adjust.
* tests/data/test-diff-suppr/test1-typedef-suppr-1.suppr: Adjust.
2014-09-19 Dodji Seketeli <dodji@redhat.com>
Initial support for type suppressions
* include/abg-comparison.h (diff_category::SUPPRESSED_CATEGORY):
New enumerator.
(diff_category::{SIZE_OR_OFFSET_CHANGE_CATEGORY,
VIRTUAL_MEMBER_CHANGE_CATEGORY): Update the enumerator values for
these.
(diff::EVERYTHING_CATEGORY): Adjust.
(suppression_base, type_suppression): Declare new types.
(suppression_ptr, suppressions_type, type_suppression_sptr)
(type_suppressions_type): New typedefs.
(read_type_suppressions, read_suppressions): Declare new
functions.
(diff_context::{suppressions, add_suppression, add_suppressions}):
Declare new methods.
(diff::is_suppressed): Declare new member function.
(apply_suppressions): Declare new function & overloads.
* src/abg-comparison.cc (is_type_diff): Define new static
function.
({suppression_base, type_suppression}::priv): Define new types.
({suppression_base, type_suppression}::*): Define the methods of the new
suppression_base, type_suppressions types.
(read_type_suppression, read_type_suppressions, read_suppressions)
(read_type_suppressions): Define new static functions.
(diff_context::priv::supprssions_): New data member.
(diff_context::{suppressions, add_suppression, add_suppressions}):
New methods.
(diff::is_filtered_out): Consider that a diff node that is in the
SUPPRESSED_CATEGORY is filtered out.
(diff::is_suppressed): Define new member function.
(operator<<(ostream& o, diff_category c)): Support the
SUPPRESSED_CATEGORY category.
(corpus_diff::report): Apply suppressions before reporting
anything.
(category_propagation_visitor::visit_end): Do not propagate
SUPPRESSED_CATEGORY. This is just like what we do for
REDUNDANT_CATEGORY.
(struct suppression_categorization_visitor): New visitor.
(apply_suppressions): Define function & overloads.
* include/abg-ini.h (config::section::find_property): New method.
(config::section): Fix end of class comment.
* src/abg-ini.cc (config::section::find_property): Define new
method.
* tests/data/test-diff-suppr/test0-type-suppr-{0,1,2}.suppr: New
test input files.
* tests/data/test-diff-suppr/test0-type-suppr-report-{0,1,2,3}.txt:
Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-v{0,1}.o: Likewise.
* tests/data/test-diff-suppr/test0-type-suppr-v{0,1}.cc: Source code
for new test input.
* tests/data/test-diff-suppr/test1-typedef-suppr-v{0,1}.o: New test
input files.
* tests/data/test-diff-suppr/test1-typedef-suppr.h: Source code
for new test input files.
* tests/data/test-diff-suppr/test1-typedef-suppr-v{0,1}.c: Likewise
* tests/data/test-diff-suppr/test1-typedef-suppr-{0,1}.suppr: New
test input files.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test1-typedef-suppr-report-2.txt: Likewise.
* tests/test-diff-suppr.cc: New test harness to run type suppression tests
using the input files above.
* tests/data/test-diff-suppr/test3-struct-suppr-0.suppr: New test input.
* tests/data/test-diff-suppr/test3-struct-suppr-1.suppr: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-0.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-1.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-report-2.txt: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-v0.cc: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-v0.o: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-v1.cc: Likewise.
* tests/data/test-diff-suppr/test3-struct-suppr-v1.o: Likewise.
* tests/Makefile.am: Build the new runtestdiffsuppr test harness
from the test-diff-filter.cc file. Add the new test files to the
build system and source distribution.
* tools/bidiff.cc (options::suppressions): New data member.
(display_usage): Add a help string for the new
--suppressions command line switch.
(parse_command_line): Parse the --suppressions command line
switch.
(set_diff_context_from_opts): Read the suppressions provided by
the --suppression command line switch and stuff them into the diff
context.
2014-09-19 Dodji Seketeli <dodji@redhat.com>
Make all type diff types extend new type_diff_base type
* include/abg-comparison.h (type_diff_base, decl_diff_base): New
types.
(type_diff_base_sptr): New typedef.
(pointer_diff, reference_diff, array_diff, qualified_type_diff)
(enum_diff, class_diff, type_decl_diff, typedef_diff): Make this
extend the new type_diff_base.
* src/abg-comparison.cc (type_diff_base::priv, type_diff_base):
Define these new types and their methods.
(pointer_diff::pointer_diff, array_diff::array_diff)
(reference_diff::reference_diff)
(qualified_type_diff::qualified_type_diff, enum_diff::enum_diff)
(class_diff::class_diff, type_decl_diff::type_decl_diff)
(typedef_diff::typedef_diff): Adjust.
2014-09-18 Dodji Seketeli <dodji@redhat.com>
Rename abigail::ini::config::section_vector to sections_type
* include/abg-ini.h (abigail::ini::config::sections_type): Renamed
section_vector into this.
(config::{get_sections, set_sections, read_sections,
write_sections}): Adjust.
* src/abg-ini.cc (config::priv::sections_): Adjust.
(config::priv::priv): Likewise.
(config::{config, get_sections}): Likewise.
(read_sections, read_config, write_sections): Likewise.
2014-09-08 Dodji Seketeli <dodji@redhat.com>
Implement the abigail::ini::config abstraction
* include/abg-ini.h (config::config): Add an overload that take a
path and sections.
(config::{get,set}_sections): New accessors.
(read_sections): Rename the previous read_config() functions into
these.
(read_config): Add these function declarations to really act on
instances of abigail::ini::config.
(write_section): Rename the previous write_config functions into
these.
(write_config): Add these function declarations to really act on
instances of abigail::ini::config.
* src/abg-ini.cc (class config::priv): Implement this.
(config::{config, ~config, get_path, set_path, get_sections,
set_sections}): Define these new methods.
(read_sections): Rename the former read_config into this.
(read_config): Add this function definitions to really act on
instances of abigail::ini::config.
(write_sections): Rename the former write_config into this.
(write_config):: Add this function definitions to really act on
instances of abigail::ini::config.
* tools/binilint.cc (main): Adjust.
2014-09-05 Dodji Seketeli <dodji@redhat.com>
Initial support of ini-style file parsing
* include/abg-ini.h: New file.
* include/Makefile.am: Add include/abg-ini.h to the source
distribution.
* src/abg-ini.cc: New file.
* src/Makefile.am: Add src/abg-ini.cc to the source distribution.
* tools/binilint.cc: New testing tool.
* tools/Makefile.am: Add tools/binilint.cc to the source distribution.
2014-09-03 Dodji Seketeli <dodji@redhat.com>
Initial examples of suppression list specifications
* doc/suppr-doc.txt: New file.
2014-10-11 Dodji Seketeli <dodji@redhat.com>
Put IR artifacts in the abigail::ir namespace
* include/abg-fwd.h: Wrap IR artifacts into abigail::ir namespace.
Inject that new abigail::ir namespace into the abigail namespace.
* include/abg-ir.h: Wrap IR artifacts into abigail::ir namespace.
(function_decl::parameter::get_type_name): Adjust the call to
abigail::get_type_name. It's now a call to
abigail::ir::get_type_name.
* src/abg-ir.cc: Wrap IR artifacts into abigail::ir namespace.
* include/abg-traverse.h: Wrap the ir traversing artifact into the
abigail::ir namespace too.
* src/abg-traverse.cc: Adjust.
* include/abg-corpus.h: Wrap corpus type stuff into abigail::ir.
* include/abg-dwarf-reader.h: Inject namespace abigail::ir stuff
into the abigail::dwarf_reader namespace.
* include/abg-reader.h: Inject namespace abigail::ir stuff into
the abigail::xml_reader namespace.
* src/abg-reader.cc: Adjust.
* include/abg-writer.h: Inject namespace abigail::ir stuff into
the abigail::xml_writer namespace.
* src/abg-writer.cc: Inject namespace abigail::ir stuff into
abigail namespace here too.
* src/abg-hash.cc: Inject the abigail::ir namespace into the
abigail namespace.
* tools/abg-tools-utils.cc: Adjust for the injection of
abigail::function_decl. It's now abigail::ir::function_decl.
2014-10-13 Dodji Seketeli <dodji@redhat.com>
Misc style cleanups
* src/abg-comparison.cc: ({pointer_diff, reference_diff}::length):
Add some vertical spaces here.
2014-10-13 Dodji Seketeli <dodji@redhat.com>
constify dm_context_rel::operator==
* include/abg-ir.h (dm_context_rel::operator==): Make this const.
2014-10-13 Dodji Seketeli <dodji@redhat.com>
A distinct_diff node has no children node
* src/abg-comparison.cc (distinct_diff::chain_into_hierarchy): Do
not append any children node here.
2014-10-13 Dodji Seketeli <dodji@redhat.com>
Remove useless redundant_filter
* include/abg-comp-filter.h (class redundant_filter): Remove this
now useless type declaration
* src/abg-comparison.cc (filtering::redundant_filter::visit):
Remove this useless member function definition.
2014-10-10 Dodji Seketeli <dodji@redhat.com>
Sort diff reports about function parameters by their indexes
* include/abg-comparison.h (changed_parms_type): New convenience
typedef.
* src/abg-comparison.cc (struct changed_parm_comp): New comparison
functor.
(sort_changed_parm_map): New sorting function.
(function_decl_diff::report): Use the new sort_changed_parm_map to
sort the diffs for function parameters by their indexes.
2014-10-10 Dodji Seketeli <dodji@redhat.com>
Don't be too eager to use distinct_diff
* src/abg-comparison.cc (try_to_diff): For this to actually
select a diff kind, the two diff subject must be of type
'DiffType'.
(compute_diff_for_types, compute_diff_for_decls): Use
distinct_diff in last resort.
2014-10-10 Dodji Seketeli <dodji@redhat.com>
Implement generic diff tree walking and port categorization over it
* include/abg-comp-filter.h (apply_filter): Declare new overload
that takes a corpus_diff_sptr ...
* src/abg-comp-filter.cc (apply_filter): ... and define it. On
the existing overload for diff_sptr, make sure to traverse all
diff nodes, even those that have already been traversed.
* include/abg-comparison.h (enum diff_category): Remove
NOT_REDUNDANT_CATEGORY, add REDUNDANT_CATEGORY.
(operator&=, +operator<<): Declare new operators for enum diff_category.
(diff_context::{forbid_traversing_a_node_twice,
traversing_a_node_twice_is_forbidden):
(diff_context::categorizing_redundancy): Remove this declaration.
(diff_context::maybe_apply_filters): Declare a new overload that
takes a corpus_diff_sptr. And a take a new flag that says if it
should visit all nodes including those that have already been
visited.
(diff::priv_): Make this data member protected.
(diff::{begin_traversing, is_traversing, end_traversing,
finish_diff_type, children_nodes, append_child_node,
get_pretty_representation, chain_into_hierarchy, traverse}):
Declare new member functions.
(distinct_diff::{finish_diff_type, get_pretty_representation,
chain_into_hierarchy}): Likewise.
(distinct_diff::traverse): Remove.
(pointer_diff::pointer_diff): Take the underlying type diff in
parameter.
(pointer_diff::{finish_diff_type, get_pretty_representation,
chain_into_hierarchy}): Declare new member functions.
(pointer_diff::traverse): Remove.
(reference_type_def::reference_type_def): Take the underlying type
diff in parameter.
({array_type_def, reference_type_def}::{finish_diff_type,
get_pretty_representation, chain_into_hierarchy}): Declare new
member functions.
({array_type_diff, reference_type_def}::traverse): Remove.
(qualified_type_diff::qualified_type_diff): Take the underlying
type diff in parameter.
({enum_diff, qualified_type_diff, class_diff}::{finish_diff_type,
get_pretty_representation, chain_into_hierarchy}): Declare new
member functions.
({enum_diff, qualified_type_diff, class_diff}::traverse): Remove.
(is_class_diff): Declare new function.
(base_diff::base_diff): Take the underlying type diff in
parameter.
({scope_diff, base_diff}::{finish_diff_type, get_pretty_representation,
chain_into_hierarchy}): Declare new member functions.
({scope_diff, base_diff}::traverse): Remove.
(function_decl_diff::function_decl_diff): Take the return type
diff as parameter.
({function_decl_diff, type_decl_diff}::{finish_diff_type,
get_pretty_representation, chain_into_hierarchy}): Declare new
member functions.
({function_decl_diff, type_decl_diff}::traverse): Remove.
(typedef_diff::typedef_diff): Take the underlying type diff as
parameter.
(typedef::{finish_diff_type, get_pretty_representation,
chain_into_hierarchy}): Declare new member functions.
({typedef, translation_unit_diff}::traverse): Remove member
function.
(corpus_diff::{finish_diff_type, children_nodes,
append_child_node, changed_variables, get_pretty_representation,
chain_into_hierarchy}): Declare new member functions.
(class diff_node_visitor::{visit_begin, visit_end}): Declare new
member functions.
(propagate_categories, print_diff_tree, categorizing_redundancy)
(clear_redundancy_categorization, apply_filters): New functions
and function overloads.
* src/abg-comparison.cc (TRY_PRE_VISIT, TRY_PRE_VISIT_CLASS_DIFF)
(TRY_POST_VISIT, TRY_POST_VISIT_CLASS_DIFF)
(CATEGORIZE_REDUNDANCY_FROM_CHILD_NODE)
(UPDATE_REDUNDANCY_CATEGORIZATION_FROM_NODE_SUBTREE)
(TRAVERSE_DIFF_NODE_AND_PROPAGATE_CATEGORY)
(TRAVERSE_MEM_DIFF_NODE_AND_PROPAGATE_CATEGORY)
(TRAVERSE_MEM_FN_DIFF_NODE_AND_PROPAGATE_CATEGORY)
(ENSURE_DIFF_NODE_TRAVERSED_ONCE)
(ENSURE_MEM_DIFF_NODE_TRAVERSED_ONCE): Remove these macros.
Hurrah.
(diff_context::priv::categorizing_redundancy_): Remove.
(diff_context::priv::forbid_traversing_a_node_twice_): Add new
data member.
(diff_context::priv::priv): Adjust.
(diff_context::{forbid_traversing_a_node_twice,
traversing_a_node_twice_is_forbidden}): Define new member
functions.
(diff_context::maybe_apply_filters): Once filters are applied (and
categories are set to the relevant diff tree nodes, run a pass
over the diff tree to propagate the categories to the relevant
diff tree parent nodes. Add an overload for corpus_diff_sptr.
(diff_context::categorizing_redundancy): Remove member function.
(diff_context::maybe_apply_filters): Define a new overload for
corpus_diff_sptr
(struct diff::priv::{finished_, traversing_, children_,
pretty_representation_}): New data members.
(diff::priv::priv): Adjust.
(diff::{begin_traversing, is_traversing, end_traversing,
finish_diff_type, children_nodes, append_child_node, traverse,
set_category, get_pretty_representation, chain_into_hierarchy}):
Define new member functions.
(diff::is_filtered_out): Do not refer to NOT_REDUNDANT_CATEGORY
anymore. Rather, use the new REDUNDANT_CATEGORY.
({distinct_diff, var_diff, pointer_diff, array_diff,
reference_diff, qualified_type_diff, enum_diff, class_diff,
base_diff, scope_diff, function_decl_diff, type_decl_diff,
typedef_diff}::{get_pretty_representation, chain_into_hierarchy,
finish_diff_type}): Define new member functions.
({distinct_diff, var_diff, pointer_diff, array_diff,
reference_diff, qualified_type_diff, enum_diff, class_diff,
base_diff, scope_diff, function_decl_diff, type_decl_diff,
typedef_diff, translation_unit_diff}::traverse): Remove member
functions.
(operator&=, operator<<): Define new operators for diff_category.
({function_decl_diff, typedef_diff}::priv::priv): Add a new
constructor.
(pointer_diff::{priv::priv, pointer_diff})
(reference_diff::{priv::priv, reference_diff})
(qualified_type_diff::{priv::priv, qualified_type_diff})
(enum_diff::{priv::priv, enum_diff}, base_diff::{priv::priv,
base_diff}, function_decl_diff::function_decl_diff): Take the
underlying type diff in parameter.
(compute_diff): Adjust the pointer_diff, reference_diff,
qualified_type_diff, base_diff, function_decl_diff overloads.
(class_diff::priv::{count_filtered_bases,
count_filtered_subtype_changed_dm, count_filtered_changed_dm,
count_filtered_changed_mem_fns, count_filtered_inserted_mem_fns,
count_filtered_deleted_mem_fns}): Adjust for the call to
diff_context::maybe_apply_filters.
(corpus_diff::priv::{finished_, pretty_representation_}): New data
member.
(corpus_diff::priv::priv): New constructor.
(corpus_diff::priv::clear_redundancy_categorization): Define new
member function.
(corpus_diff::priv::apply_filters_and_compute_diff_stats):
Adjust for call to diff_context::maybe_apply_filters. Also, call
clear_redundancy_categorization at the end.
(corpus_diff::priv::categorize_redundant_changed_sub_nodes):
Revisit logic.
(corpus_diff::{chain_into_hierarchy, finish_diff_type,
children_nodes, append_child_node, changed_variables,
get_pretty_representation}): Define new member functions.
(corpus_diff::report): Categorize redundancy for every top level
function/variable diff.
(corpus_diff::traverse): Adjust to the new traversing interface.
(diff_node_visitor::{visit_begin, visit_end}): Define new member
functions.
(struct category_propagation_visitor, struct diff_node_printer)
(struct redundancy_marking_visitor, struct
redundancy_clearing_visitor): New diff tree node visitors.
(propagate_categories, print_diff_tree, categorize_redundancy)
(clear_redundancy_categorization, apply_filters): Define new
functions.
* tests/Makefile.am: Add the new tests/print-diff-tree.cc to the
source distribution. Build it into a tests/printdifftree binary.
* tools/abidiff.cc (print_diff_tree): Add debugging functions to
call from within the debugger. By default, this function and its
overloads are not compiled.
2014-10-10 Dodji Seketeli <dodji@redhat.com>
Update copyright notice for tests/test-diff2.cc
* tests/test-diff2.cc: Update copyright year.
2014-10-09 Dodji Seketeli <dodji@redhat.com>
Do not crash on function_decl_diff for fns that have no symbol
* src/abg-comparison.cc (function_decl_diff::report): If a
function decl has no associated elf symbol, do not crash while
trying to report about its elf symbol aliases.
2014-10-09 Dodji Seketeli <dodji@redhat.com>
Avoid broken output for virtual member fns w/o symbols
* src/abg-comparison.cc (represent): When a virtual member
function has no associated elf symbol, do not emit garbage in lieu
of the linkage name. Just emit no linkage name;
* tests/data/test-abidiff/test-struct1-report.txt: Adjust.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Sort added/removed/changed functions reported by the comparison engine
* src/abg-comparison.cc (struct function_comp, struct
changed_function_ptr_comp): New comparison functors.
(sort_string_function_ptr_map)
(sort_string_changed_function_ptr_map): Define new static
functions.
(corpus_diff::report): Sort the added/removed/changed functions
that are reported.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test01-report.txt: Adjust.
* tests/data/test-diff-filter/test2-report.txt: Adjust.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Mention virtual-ness of member function in their pretty representation
* include/abg-fwd.h (get_member_function_is_virtual): Declare new
overload for pointers.
* src/abg-ir.cc (get_member_function_is_virtual): Define it.
(function_decl::get_pretty_representation): Print virtual-ness of
the function_decl being pretty printed.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Do not crash when reporting diffs about virtual member fns that have no symbol
* src/abg-comparison.cc (represent): If a virtual member function
has no symbol do not crash.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Fixup member functions which virtual-ness has just been set
* include/abg-ir.h (fixup_virtual_member_function): Declare new
function.
(class_decl): Declare fixup_virtual_member_function() as a member.
* src/abg-ir.cc (set_member_function_is_virtual): Ensure that the
member function that has seen its virtualness set is also put
correctly put in the vector of virtual member functions of its
class.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Assert that only decls with elf symbols are part of comparison
* src/abg-corpus.cc (corpus::priv::build_public_decl_table): Assert
that when read from DWARF, only decls with elf symbols are part of
the public decls table.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Emit all virtual member functions in group
* src/abg-writer.cc (write_class_decl): Emit virtual member
functions contiguously.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Always emit vtable offset for virtual member function
* src/abg-writer.cc (write_voffset): Emit the vtable offset of
virtual function even when the offset is zero.
2014-10-02 Dodji Seketeli <dodji@redhat.com>
Do not forget priv_->in_pub_sym_tab_ when copying decl_base
* src/abg-ir.cc (decl_base::decl_base(const decl_base& d)): Do
not forget to copy priv_->in_pub_sym_tab_.
2014-10-01 Dodji Seketeli <dodji@redhat.com>
Fix reading several clones of the same member function from DWARF
* include/abg-fwd.h (set_member_function_is_ctor)
(set_member_function_is_dtor, set_member_function_is_const)
(set_member_function_vtable_offset): Declare new functions.
* include/abg-ir.h (class_decl::sort_virtual_mem_fns): Declare new
member function.
(mem_fn_context_rel::{vtable_offset, is_constructor is_destructor,
is_const}): Add these setters.
(set_member_function_is_ctor, set_member_function_is_dtor)
(set_member_function_is_static, set_member_function_is_const)
(set_member_function_vtable_offset)
(set_member_function_is_virtual): Declare these new friend
function to class class_decl::method_decl.
* src/abg-dwarf-reader.cc (finish_member_function_reading): Split
this out from build_class_type_and_add_to_ir. Use the new setters
for member functions properties introduced above.
(build_class_type_and_add_to_ir): Factorize the creation of member
function by using build_ir_node_from_die. Once that function has
created the member function in a rather generic way, use the new
finish_member_function_reading to set the remaining specific
properties for member functions.
(build_function_decl): When called to read additional properties
of a function_decl, allow this to read and update the elf symbol
properties too. This is useful for building a clone of a function
that already has an elf symbol.
(build_ir_node_from_die): When building a function decl, consider
the case of a DIE that has both DW_AT_specification and
DW_AT_abstract_origin set. That is, DW_AT_abstract_origin is set,
and the origin has DW_AT_specification set. This is basically a
clone of a function that implements an interface (this happens for
destructors, for instance). In this case, really do the cloning
of the interface implementation. If the cloned function happens
to be member function, use finish_member_function_reading to read
the properties relevant to its method-ness.
* src/abg-ir.cc (set_member_function_is_ctor)
(set_member_function_is_dtor, set_member_function_is_const)
(set_member_function_vtable_offset)
(class_decl::sort_virtual_mem_fns): Define new functions.
(sort_virtual_member_functions): Define new static function.
(struct virtual_member_function_less_than): New functor.
(class_decl::add_member_function): Keep virtual member functions
vector sorted.
* data/test-read-dwarf/test1.abi: Adjust. Now, both the
cdtor specification and all the clones that implements the
different are emitted.
* data/test-read-dwarf/test2.so.abi: Likewise.
2014-10-01 Dodji Seketeli <dodji@redhat.com>
Do not crash when comparing functions that have no symbol
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Just skip functions
that have no ELF symbol.
2014-09-30 Dodji Seketeli <dodji@redhat.com>
Rename member_function_is_virtual to get_member_function_is_virtual
* include/abg-fwd.h (get_member_function_is_virtual): Renamed the
declaration of member_function_is_virtual into this.
* src/abg-ir.cc (get_member_function_is_virtual): Likewise for its
definition.
* include/abg-ir.h (class decl_base): Adjust the friend function
member_function_is_virtual references.
* src/abg-comp-filter.cc (has_virtual_mem_fn_change)
(has_non_virtual_mem_fn_change): Adjust.
* src/abg-comparison.cc (represent)
(SKIP_MEM_FN_IF_VIRTUALITY_DISALLOWED, class_diff::report):
Likewise.
* src/abg-hash.cc (class_decl::hash::operator()): Likewise.
(function_decl::clone, class_decl::add_member_function): Adjust.
2014-09-30 Dodji Seketeli <dodji@redhat.com>
Factorize a no-op deleter for shared pointer
* include/abg-sptr-utils.h (struct noop_deleter): Move this here
from ...
* src/abg-comparison.cc (struct noop_deleter): ... here.
2014-09-30 Dodji Seketeli <dodji@redhat.com>
Link manuals from the main web page
* doc/website/mainpage.txt: Add a link to the manuals.
2014-09-26 Dodji Seketeli <dodji@redhat.com>
Initial documentation for libabigail
* doc/manuals/Makefile: New file, generated by sphinx-quickstart.
* doc/manuals/abidiff.rst: New manual for abidiff.
* doc/manuals/abidw.rst: New manual for abidw.
* doc/manuals/abilint.rst: New manual for abilint.
* doc/manuals/conf.py: New configuration file generated by sphinx-quickstart.
* doc/manuals/index.rst: The root of the this documentation.
* doc/manuals/libabigail-overview.rst: The overview of libabigail.
* doc/manuals/tools.rst: The root of the tools manuals.
2014-09-26 Dodji Seketeli <dodji@redhat.com>
Do not install the abisym program
* tools/Makefile.am: Do not install abisym. It's really there
just for testing purposes and is of almost no use for generic
users.
2014-09-26 Dodji Seketeli <dodji@redhat.com>
Rename bi* tools to abi* tools
* tests/data/test-bidiff: Rename this directory to
tests/data/test-abidiff.
* tests/test-bidiff.cc: Renamed this to tests/test-abidiff.cc.
* tools/biar.cc: Renamed to tools/abiar.cc
* tools/bidiff.cc: Renamed to tools/abidiff.cc
* tools/bidw.cc: Renamed to tools/abidw.cc
* tools/bilint.cc: Renamed to tools/abilint.cc
* tools/bisym.cc: Renamed to tools/abisym.cc
* tests/test-alt-dwarf-file.cc: Renamed references to bidw* to abidw*.
* tests/test-diff-filter.cc: Renamed references to bidiff to abidiff.
* tests/test-lookup-syms.cc: Renamed references to bisym to abisym.
* tools/Makefile.am: Adjust.
* tests/Makefile.am: Likewise.
2014-09-19 Dodji Seketeli <dodji@redhat.com>
Light cleanup in abg-corpus.cc
* src/abg-corpus.cc
(symtab_build_visitor_type::regex_fns_suppress): use
sptr_utils::build_sptr, rather than building the shared_ptr of
regex_t by hand.
2014-09-18 Dodji Seketeli <dodji@redhat.com>
Pimplify abigail::comparison::diff type
* include/abg-comparison.h (diff::{priv, sptr}): New types.
(diff::priv_): New member.
(diff::*): Remove all the other previous data members and
transform the inline member function definition into declarations
only.
* src/abg-comparison.cc (class diff::priv): New private data type.
(diff::*): Define the previous inline member functions as
out-of-line here.
2014-09-18 Dodji Seketeli <dodji@redhat.com>
Rename shared_ptr<regex_t> into regex_t_sptr
* include/abg-sptr-utils.h (build_sptr()): Rename the return type
from shared_ptr<regex_t> to regex_t_sptr.
2014-09-19 Dodji Seketeli <dodji@redhat.com>
Fix a comment in abg-comparison.h
* include/abg-comparison.h (class base_diff): Fix comment.
2014-09-05 Dodji Seketeli <dodji@redhat.com>
Light style cleanup in tools/bidiff.cc
* tools/bidiff.cc (display_usage): Remove useless space before '&'.
2014-09-05 Dodji Seketeli <dodji@redhat.com>
src/Makefile.am cleanup
* src/Makefile.am: Remove the unused 'headers' variable.
2014-09-16 Dodji Seketeli <dodji@redhat.com>
Emit reports about not-yet categorized diff nodes
* include/abg-comparison.h (NO_CHANGE_CATEGORY): Better comment
this enumerator.
* src/abg-comparison.cc (diff::is_filtered_out): Not-yet
categorized changes are not filtered out anymore.
(distinct_diff::report): Avoid extraneous new line here.
2014-09-16 Dodji Seketeli <dodji@redhat.com>
Better support for inline related diffs
* include/abg-comparison.h
(diff_category::HARMLESS_SYMBOL_ALIAS_CHANGE_CATEORY): New
enumerator.
(diff_category::EVERYTHING_CATEGORY): Adjust.
* include/abg-ir.h (elf_symbol::get_aliases_id_string)
(elf_symbol::does_alias, elf_symbols_alias)
(compute_aliases_for_elf_symbol): Declare new functions ...
* src/abg-ir.cc (elf_symbol::get_aliases_id_string)
(elf_symbol::does_alias, elf_symbols_alias)
(compute_aliases_for_elf_symbol): ... and define them.
(function_decl::operator==): Take in account elf symbol aliases.
* src/abg-comp-filter.cc (function_name_changed_but_not_symbol):
Define new static functions.
(harmless_filter::visit): Categorize function name changes that
n doesn't impact underlying elf symbols (or the fact that two
symbols were aliases and are not anymore) as harmless.
* src/abg-comparison.cc (function_decl_diff::report): Properly
report function name changes, or symbol aliases changes for that
matter. Also report inline-ness declaration changes.
* src/abg-dwarf-reader.cc (die_is_declared_inline): New static
function.
(build_function_decl): Use the above.
* tools/bidiff.cc (set_diff_context_from_opts): Add
abigail::comparison::HARMLESS_SYMBOL_ALIAS_CHANGE_CATEORY into the
harmless change camp.
* tests/data/test-diff-dwarf/test14-inline-report.txt: New test
input.
* tests/data/test-diff-dwarf/test14-inline-v0.o: Likewise.
* tests/data/test-diff-dwarf/test14-inline-v1.o: Likewise.
* tests/data/test-diff-dwarf/test14-inline-v0.cc: Source code for
test input.
* tests/data/test-diff-dwarf/test14-inline-v1.cc: Source code for
test input.
* tests/test-diff-dwarf.cc: Run this test harness over the new
input above.
* tests/data/test-diff-filter/test20-inline-report-0.txt: Likewise.
* tests/data/test-diff-filter/test20-inline-report-1.txt:
Likewise.
* tests/data/test-diff-filter/test20-inline-v0.o: New test input.
* tests/data/test-diff-filter/test20-inline-v1.o: New test input.
* tests/data/test-diff-filter/test20-inline-v0.cc: Source code for
test input.
* tests/data/test-diff-filter/test20-inline-v1.cc: Likewise.
* tests/test-diff-filter.cc: Run this test harness over the new
input above.
2014-09-16 Dodji Seketeli <dodji@redhat.com>
Better support for enum diffs
* include/abg-comparison.h (changed_enumerator_type): New typedef.
(diff_category::{HARMLESS_ENUM_CHANGE_CATEGORY}): New enumerator.
* src/abg-comp-filter.cc (has_type_size_change)
(has_enumerator_insertion, has_enumerator_removal_or_change)
(has_harmful_enum_change): New functions.
(harmless_filter::visit): Categorize enumerator insertions that
don't change the size of the type into HARMLESS_ENUM_CHANGE_CATEGORY.
(harmful_filter::visit): Categorize enumerator removal or any enum
change that changes the size of the type into
SIZE_OR_OFFSET_CHANGE_CATEGORY.
* src/abg-comparison.cc (enumerator_value_comp)
(changed_enumerator_comp): New types.
(sort_enumerators, sort_changed_enumerators): New static
functions.
(enum_diff::report): Sort enum related reports by the value of the
enumerators.
* src/abg-dwarf-reader.cc (build_enum_type): Name anonymous enums
as __anonymous_enum__.
* tools/bidiff.cc (set_diff_context_from_opts): Add
abigail::comparison::HARMLESS_ENUM_CHANGE_CATEGORY into the harmless
stuff camp.
* tests/data/test-diff-dwarf/test15-enum-report.txt: New test
input.
* tests/data/test-diff-dwarf/test15-enum-v1.o: Likewise.
* tests/data/test-diff-dwarf/test15-enum-v0.o: Likewise.
* tests/data/test-diff-dwarf/test15-enum-v0.cc: Source code for
test input.
* tests/data/test-diff-dwarf/test15-enum-v1.cc: Likewise.
* tests/data/test-diff-filter/test19-enum-report-0.txt: New test input.
* tests/data/test-diff-filter/test19-enum-report-1.txt: Likewise.
* tests/data/test-diff-filter/test19-enum-v0.o: Likewise.
* tests/data/test-diff-filter/test19-enum-v1.o: Likewise.
* tests/data/test-diff-filter/test19-enum-v0.cc: Source code for
test input.
* tests/data/test-diff-filter/test19-enum-v1.cc: Likewise.
* tests/test-diff-dwarf.cc: Run this test harness on the new test
inputs above.
* tests/test-diff-filter.cc: Likewise.
* tests/Makefile.am: Add the new files above to the source distribution.
2014-09-16 Dodji Seketeli <dodji@redhat.com>
Add constness to elf_symbol::operator==
* include/abg-ir.h (elf_symbol::operator==): Add a const to the
declaration ...
* src/abg-ir.cc (elf_symbol::operator==): ... and to the definition.
2014-09-15 Dodji Seketeli <dodji@redhat.com>
Misc style cleanups
* src/abg-comparison.cc (ChangedDataMemberComp): Rename this to
changed_data_member_comp
(sort_changed_data_members): Adjust.
(DataMemberComp): Rename this to data_member_comp.
(sort_data_members): Adjust.
2014-09-15 Dodji Seketeli <dodji@redhat.com>
Constify some function parameters in abg-comp-filter.cc
* src/abg-comp-filter.cc (type_size_changed): Now take const
parameters.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Add .gitignore files.
* .gitignore: Add new file.
* m4/.gitignore: Likewise.
* tools/.gitignore: Likewise.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Place -L/-l flags into *_LIBADD/*_LDADD
* src/Makefile.am: -L and -l ought to be in LIBADD/LDADD because
that is the only place guaranteed to be in the right spot. So add
Them to libabigail_la_LIBADD.
* tools/Makefile.am: Likewise.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Add libelf to libabigail.la's linker line
* configure.ac: Check for the existence of libelf at configure
time by looking at the presence of the elf_end symbol. Add the
libelf to the link command line.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Drop hardcoded substitutions
* doc/Makefile.am: Do not use @docdir@. It's indeed replaced at
configure time. But there is no need for this limitation with
automake, as $(docdir) is available and replaceable anytime.
* src/Makefile.am: Likewise for @DEPS_LIBS@ and @DEPS_CFLAGS@.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Replace indirect variable assignments
* configure.ac(DEVEL_CFLAGS, DEVEL_CXXFLAGS): Remove these
useless variables.
(CFLAGS, CXXFLAGS): Set these variables directly.
* include/Makefile.am (pkginclude_HEADERS): Use this predefined
variable.
(publicheaders_DATA, publicheadersdir): Remove these.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Remove empty and autogenerated files from git repository
* ChangeLog: Remove this empty file for now. It'll be added back
right before the first release by automatic generation from the
commit logs.
* INSTALL: Remove this empty file for now.
* NEWS: Remove this empty file for now. It'll be added back right
before the first release.
* configure.ac (AM_INIT_AUTOMAKE): As the mandatory but empty
files above are being removed for now, let's put in the 'foreign'
mode of automake for the moment. We'll likely remove it at
release time.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Set automake options globally
* configure.ac(AM_INIT_AUTOMAKE): Set the subdir-object option
here ..
* src/Makefile.am: ... not here.
* tests/Makefile.am: Likewise.
* tools/Makefile.am: Likewise.
2014-09-09 Jan Engelhardt <jengelh@inai.de>
Stash some autogenerated tools in build-aux/
* configure.ac: Reduce the pollution in the top-level directory a
bit.
2014-09-10 Dodji Seketeli <dodji@redhat.com>
Fix memory leaks due to cycles in types ownership
* include/abg-fwd.h (std::tr1::weak_ptr): Inject this type in the
abigail namespace.
* include/abg-ir.h: Write a memory management guideline for the IR
artifacts.
(Type_base_wptr, function_type_wptr)
(class_decl_wptr): New typedefs.
(translation_unit::get_canonical_function_type): Declare new
member function.
(qualified_type_def::underlying_type_)
(reference_type_def::pointed_to_type_)
(typedef_decl::underlying_type_, function_decl::parameter::type_)
(function_type::return_type_, method_type::class_type_)
(non_type_tparameter::type_, type_composition::type_): Make this a
weak pointer.
(qualified_type_def::get_pointed_to_type)
(reference_type_def::get_pointed_to_type)
(array_type::get_element_type, typedef_decl::get_underlying_type)
(var_decl::get_type, function_decl::parameter::get_type)
(function_type::get_return_type, method_type::get_class_type)
(non_type_tparameter::get_type)
(type_composition::get_composed_type): Adjust to make this return
a shared pointer initialized with the content of the weak pointer.
(function_decl::function_decl, method_decl::method_decl): Remove
the overload that doesn't take a type. This is because now,
function types need to be registered to their containing
translation unit.
(struct function_type::hash): Declare here.
* src/abg-hash.cc (struct function_type::hash): Declare this in
abg-ir.h and just define the methods here.
* src/abg-ir.cc (fn_type_ptr_map): New typedef.
(translation_unit::priv::canonical_types_): Remove this unused
member.
(translation_unit::priv::canonical_function_types_): New member.
(translation_unit::get_canonical_function_type): Define this
function.
(array_type_def::priv::element_type_, var_decl::priv::type_)
(function_decl::priv::type_): Make this a weak pointer.
(qualified_type_def::get_underlying_type)
(pointer_type_def::get_pointed_to_type)
(reference_type_def::get_pointed_to_type)
(array_type_def::get_element_type)
(typedef_decl::get_underlying_type, var_decl::get_type)
(function_decl::get_type): Adjust to make this return a shared
pointer initialized with the content of the weak pointer.
(qualified_type_def::build_name)
(pointer_type_def::get_qualified_name)
(reference_type_def::get_qualified_name): Adjust.
(method_type::set_class_type): Cleanup the logic.
(function_decl::priv::priv): Remove the overload that takes a bare
pointer to a type. This should not be used now that we need the
function type to registered with the translation unit.
(function_decl::function_decl): Remove the overload that doesn't
take a type. This is because now, function types need to be
registered to their containing translation unit.
* src/abg-dwarf-reader.cc (build_function_decl): Register the
function type within its translation type and use its canonical
version. This complies with the new memory management rules.
* src/abg-reader.cc (build_function_decl): Likewise.
2014-09-10 Dodji Seketeli <dodji@redhat.com>
Compare class names when comparing methods
* src/abg-ir.cc: Compare class names when comparing methods
2014-09-10 Dodji Seketeli <dodji@redhat.com>
Slight white space fix
* src/abg-hash.cc (method_type::hash::operator()(const
method_type&)): White space fix.
2014-09-10 Dodji Seketeli <dodji@redhat.com>
Update copyright notice
* include/abg-ir.h: Update year of copyright notice.
2014-07-05 Ondrej Oprala <ooprala@redhat.com>
Unite help output for tools
* tools/biar.cc (std::ostream): Add a using directive.
(display_usage): Make it take a string reference and an ostream
as parameters. Use the ostream argument as an output stream
instead of a hard-coded cout.
Prettify output.
(main): Call display_usage with new parameters.
* tools/bidiff.cc (display_usage): Declare it static.
Prettify output.
* tools/bidw.cc (display_usage): Prettify output.
* tools/bilint.cc (display_usage): Declare it static.
Prettify output.
* tools/bisym.cc (std::cerr): Add a using directive.
(prog_name): Rename progname into this.
(display_usage): Rename show_help into this.
Add an ostream as a parameter. Use the ostream argument
as output stream insted of a hard-coded cout.
2014-09-03 Dodji Seketeli <dodji@redhat.com>
Adjust copyright year
* tests/test-diff-dwarf.cc: Adjust year in copyright notice.
2014-09-03 Dodji Seketeli <dodji@redhat.com>
Sort reported changed data members by increasing offset
* include/abg-comparison.h (changed_type_or_decl_vector): New
typedef.
* include/abg-fwd.h (is_data_member): Change the overload that
takes a decl_base_sptr to make it return the real var_decl_sptr
rather than just a bool.
* src/abg-comparison.cc (ChangedDataMemberComp, DataMemberComp):
New comparison functors.
(sort_changed_data_members, sort_data_members): Sorting functions
for changed data members and data members.
(class_diff::report): Sort reports for deleted, inserted and
change data members by the increasing value of the offsets of said
data members.
* src/abg-ir.cc (is_data_member): Change the overload that takes a
decl_base_sptr to make it return the real var_decl_sptr rather
than just a bool.
* tests/data/test-bidiff/test-struct1-report.txt: Adjust.
* tests/data/test-diff-dwarf/test13-report.txt: New test input.
* tests/data/test-diff-dwarf/test13-v0.cc: Source code for new
test input.
* tests/data/test-diff-dwarf/test13-v0.o: New test input.
* tests/data/test-diff-dwarf/test13-v1.cc: Source code for new
test input.
* tests/data/test-diff-dwarf/test13-v1.o: New test input.
* tests/Makefile.am: Add the new test inputs above to the source
distribution.
* tests/test-diff-dwarf.cc: Run this test harness on the new test
input.
2014-09-03 Dodji Seketeli <dodji@redhat.com>
Do not filter out diff nodes that are only in NOT_REDUNDANT_CATEGORY
* src/abg-comparison.cc (diff::is_filtered_out): If a diff not is
only in the NOT_REDUNDANT_CATEGORY category consider it as not
being filtered.
* tests/data/test-diff-filter/test18-report.txt: New test input.
* tests/data/test-diff-filter/test18-v0.cc: Source code for new
test input.
* tests/data/test-diff-filter/test18-v0.o: New test input.
* tests/data/test-diff-filter/test18-v1.cc: Source code for new
test input.
* tests/data/test-diff-filter/test18-v1.o: New test input.
* tests/Makefile.am: Add the new test inputs to the source distribution.
* tests/test-diff-filter.cc: Run this test harness on the new test
input above.
2014-09-03 Dodji Seketeli <dodji@redhat.com>
White space cleanup
* src/abg-ir.cc (get_data_member_offset): Remove useless
horizontal white space.
2014-09-03 Dodji Seketeli <dodji@redhat.com>
Add some comments in the comparison engine
* src/abg-comparison.cc: Add a comment for the file.
(struct class_diff::priv::{subtype_changed_dm_,changed_dm_}): Add
comment for these data members.
2014-09-02 Dodji Seketeli <dodji@redhat.com>
Remove useless new line from comparison engine's report
* src/abg-comparison.cc (class_diff::report): Do not emit new
lines after reporting about inserted data members.
* tests/data/test-bidiff/test-qual-type0-report.txt: Adjust.
* tests/data/test-bidiff/test-struct0-report.txt: Adjust.
* tests/data/test-bidiff/test-struct1-report.txt: Adjust.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-dwarf/test1-report.txt: Adjust.
* tests/data/test-diff-dwarf/test3-report.txt: Adjust.
* tests/data/test-diff-dwarf/test7-report.txt: Adjust.
* tests/data/test-diff-filter/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test01-report.txt: Adjust.
* tests/data/test-diff-filter/test1-report.txt: Adjust.
* tests/data/test-diff-filter/test11-report.txt: Adjust.
* tests/data/test-diff-filter/test14-0-report.txt: Adjust.
* tests/data/test-diff-filter/test14-1-report.txt: Adjust.
* tests/data/test-diff-filter/test15-0-report.txt: Adjust.
* tests/data/test-diff-filter/test15-1-report.txt: Adjust.
* tests/data/test-diff-filter/test16-report.txt: Adjust.
* tests/data/test-diff-filter/test17-0-report.txt: Adjust.
* tests/data/test-diff-filter/test17-1-report.txt: Adjust.
* tests/data/test-diff-filter/test2-report.txt: Adjust.
* tests/data/test-diff-filter/test3-report.txt: Adjust.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
2014-09-01 Dodji Seketeli <dodji@redhat.com>
Adjust copyright years
* src/abg-corpus.cc: Adjust copyright years.
* src/abg-libzip-utils.cc: Likewise.
* src/abg-writer.cc: Likewise.
2014-09-01 Dodji Seketeli <dodji@redhat.com>
Factorize basic redundancy detection in diff report
* src/abg-comparison.cc
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER)
(RETURN_IF_BEING_REPORTED_OR_WAS_REPORTED_EARLIER{2,3}): New
macros.
({pointer_diff, array_diff, reference_diff, qualified_type_diff,
class_diff, typedef_diff}::report): Use the new macros above.
* tests/data/test-bidiff/test-qual-type0-report.txt: Adjust
because type pretty representation are now always quoted.
* tests/data/test-bidiff/test-struct1-report.txt: Adjust likewise.
2014-08-31 Dodji Seketeli <dodji@redhat.com>
Display package configuration at the end of configure
* configure.ac: Display the configure of the package at the end of
the configure script.
2014-08-31 Dodji Seketeli <dodji@redhat.com>
Make zip archive support optional
* configure.ac: Support a new --enable-zip-archive option. By
default its value is set to the 'auto', meaning that if libzip is
installed, that turns the option on -- just like if
--enable-zip-archive was called with the value 'yes'; if libzip is
not installed, that turns the option off -- just like if
--enable-zip-archive was called with the value 'no'. If libzip is
detected, the pre-processor macro HAVE_LIBZIP is set to 1. If
--enable-zip-archive is turned on, the pre-processor macro
WITH_ZIP_ARCHIVE is set to 1.
* config.h.in (HAVE_LIBZIP, WITH_ZIP): New define.
* src/abg-corpus.cc: Include config.h. Guard the inclusion of
abg-libzip-utils.h with the WITH_ZIP_ARCHIVE macro. Likewise for
the use of declarations coming from abg-libzip-utils.h.
* src/abg-libzip-utils.cc: Include config.h. Guard the file's
content with the WITH_ZIP_ARCHIVE macro.
* src/abg-reader.cc: Include config.h. Guard the inclusion of
abg-libzip-utils.h with the WITH_ZIP_ARCHIVE. Likewise for the
use of declarations coming from abg-libzip-utils.h.
* src/abg-writer.cc: Likewise.
* tests/Makefile.am: Build runtestwritereadarchive and runtestdot
only if zip archives are supported.
* tools/Makefile.am: The biar program is built only if
zip archives are supported.
* tools/bidiff.cc: Handle zip archives only if the
WITH_ZIP_ARCHIVE macros is defined.
* tools/bilint.cc: Likewise.
2014-08-28 Dodji Seketeli <dodji@redhat.com>
Tell bidiff --help, wrong options and missing argument apart
* tools/bidiff.cc (options::{display_usage,missing_operand}): New
data members.
(options::options): Initialize them.
(parse_command_line): Flag missing operands. Return false only
when an option could not be parsed. Flag when the user wants us
to display help.
(main): Tell --help, wrong options and missing argument apart and
give an appropriate message on stderr. The help string goes to
stdout though. Just like what GNU diff does.
2014-08-28 Dodji Seketeli <dodji@redhat.com>
In bidiff, don't emit a report when the binaries have the same ABI
* tools/bidiff.cc (main): For differences of zero length, do not
emit any report.
2014-08-29 Dodji Seketeli <dodji@redhat.com>
Take variables in account in corpus changes detection
* src/abg-comparison.cc (corpus_diff::length): Take changes about
variables into account.
2014-08-28 Dodji Seketeli <dodji@redhat.com>
During redundancy marking start with the current node as non redundant
* src/abg-comparison.cc (ENSURE_DIFF_NODE_TRAVERSED_ONCE): If the
diff node is being traversed for the first time, mark it as being
in the NOT_REDUNDANT_CATEGORY. I don't know why I was doing this
only for classes and basic types. Update comments.
* tests/data/test-diff-filter/test16-report.txt: New test input.
* tests/data/test-diff-filter/test16-v0.cc: Source code of new
test input.
* tests/data/test-diff-filter/test16-v0.o: New test input.
* tests/data/test-diff-filter/test16-v1.cc: Source code of new
test input.
* tests/data/test-diff-filter/test16-v1.o: New test input.
* tests/data/test-diff-filter/test17-0-report.txt: Likewise.
* tests/data/test-diff-filter/test17-1-report.txt: Likewise.
* tests/data/test-diff-filter/test17-v0.cc: Source code of new
test input.
* tests/data/test-diff-filter/test17-v0.o: Likewise.
* tests/data/test-diff-filter/test17-v1.cc: Source code of new
test input.
* tests/data/test-diff-filter/test17-v1.o: Likewise.
* tests/Makefile.am: Add the new files to the source distribution.
* tests/test-diff-filter.cc (in_out_spec): Run this test harness
over the new test inputs.
2014-08-28 Dodji Seketeli <dodji@redhat.com>
Give anonymous struct the name "__anonymous_struct__"
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Set
the name of anonymous structs to '__anonymous_struct_'.
2014-08-28 Dodji Seketeli <dodji@redhat.com>
Style fix in the comparison engine
* src/abg-comparison.cc (represent): Remove useless white space.
2014-08-27 Dodji Seketeli <dodji@redhat.com>
In bidiff, change --no-linkage-names to --no-linkage-name
* tools/bidiff.cc (display_usage): Change--no-linkage-names -o
--no-linkage-name in the help string.
(parse_command_line): Adjust the command line parsing accordingly.
* tests/test-diff-filter.cc (in_out_specs): Adjust.
2014-08-27 Dodji Seketeli <dodji@redhat.com>
In diff reports, show symbol version info in linkage names
* src/abg-comparison.cc (represent, corpus_diff::report): show
symbol version info in linkage name info.
2014-08-27 Dodji Seketeli <dodji@redhat.com>
In diff reports, fns & members add/remove at the top, changes later.
* src/abg-comparison.cc (class_diff::report): Put virtual member
function adding/removal/change first, then data members
add/removal, then the rest (including data members changes).
(corpus_diff::report): Put function adding/removal first, then
function changes. Likewise for variables.
* tests/data/test-bidiff/test-struct0-report.txt: Adjust.
* tests/data/test-bidiff/test-struct1-report.txt: Adjust.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-dwarf/test1-report.txt: Adjust.
* tests/data/test-diff-dwarf/test12-report.txt: Adjust.
* tests/data/test-diff-dwarf/test8-report.txt: Adjust.
* tests/data/test-diff-dwarf/test9-report.txt: Adjust.
* tests/data/test-diff-filter/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test01-report.txt: Adjust.
* tests/data/test-diff-filter/test1-report.txt: Adjust.
* tests/data/test-diff-filter/test13-report.txt: Adjust.
* tests/data/test-diff-filter/test2-report.txt: Adjust.
* tests/data/test-diff-filter/test3-report.txt: Adjust.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
2014-08-27 Dodji Seketeli <dodji@redhat.com>
Consider symbol versions' public-ness during comparison
* src/abg-ir.cc (elf_symbol::operator==): Rather than comparing
bindings, compare public-ness here. That is, if two symbol
versions' differ because one is GLOBAL and the other one is WEAK,
they should still be considered equal, from an ABI standpoint.
2014-08-27 Dodji Seketeli <dodji@redhat.com>
Lookup proper names of symbol during determination of deleted/added decls
* src/abg-comparison.cc
({class,corpus}_diff::ensure_lookup_tables_populated): Now that in the
intermediate maps we store symbol *ids* rather than symbol names,
make sure to really refer to symbol names for symbol lookups,
rather than (wrongly) referring to symbol ids.
2014-08-26 Dodji Seketeli <dodji@redhat.com>
Cleanup bidiff help string some more
* tools/bidiff.cc (display_usage): Add help strings for --harmless
and --no-harmful.
(main): Emit the help string to stdout, not stderr.
2014-08-26 Dodji Seketeli <dodji@redhat.com>
bidiff --no-harmless is no more
* tools/bidiff.cc (display_usage): Remove the help string for the
--no-harmless option that doesn't exist anymore, as it's on by
default.
2014-08-26 Dodji Seketeli <dodji@redhat.com>
During comparison use symbol name + version as decl ID
* include/abg-ir.h ({var,function}_decl::get_id): New member
function declarations.
* src/abg-ir.cc ({var,function}_decl::get_id): New member function
definitions.
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Use the
::get_id() function to get an identifier for the function or
variable.
* src/abg-corpus.cc (symtab_build_visitor_type::build_id): Use the
get_id of the function/variable.
2014-08-26 Dodji Seketeli <dodji@redhat.com>
Fix access to alternate die -> decl map
* src/abg-dwarf-reader.cc (read_context::alternate_die_decl_map):
Return the real alternate die decl map, rather than what we was
doing previously b/c of a stupid copy/paste. Oh well.
2014-08-25 Dodji Seketeli <dodji@redhat.com>
Take symbol versions in account when computing added/removed decls
* include/abg-corpus.h
(corpus::lookup_{function,variable}_symbol): Add an overload
declaration that takes the version of the symbol to lookup.
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): So when looking
up the corpora for symbols, take their versions in account.
* src/abg-corpus.cc (corpus::lookup_{function,variable}_symbol):
Add an overload definition that takes the version of the symbol to
lookup.
(symtab_build_visitor_type::build_id): New
member functions.
(corpus::priv::build_public_decl_table): Use the new member
functions above.
* src/abg-ir.cc (elf_symbol::version::operator==): Do not take the
is_default flag in account when comparing two symbol versions.
* libtest12-v{0,1}.so: New test input files.
* libtest12-v{0,1}.c: Source code for the test input files.
* test12-version-script: Version script to build the files above.
* test12-report.txt: Test input file.
* tests/Makefile.am: Add the new test input files above to the
source distribution.
* tests/test-diff-dwarf.cc (in_out_specs[]): Add an entry to this
table for the new test input files.
2014-08-25 Dodji Seketeli <dodji@redhat.com>
Misc style cleanups
* include/abg-corpus.h (corpus::lookup_function_symbol)
(corpus::lookup_variable_symbol): Add the name of the function
parameter in the declaration.
* include/abg-ir.h (elf_symbol::version::version): Properly indent
this constructor declaration.
* src/abg-corpus.cc
(symtab_build_visitor_type::symtab_build_visitor_type): Properly
indent constructor parameters.
* src/abg-ir.cc (function_decl::operator==): Fix typo in
comments.
2014-08-25 Dodji Seketeli <dodji@redhat.com>
bidiff --harmful is not supported anymore
* tools/bidiff.cc (display_usage): remove the '--harmful' line
from the help string as this option is now activated by default.
It's --harmless that exists now.
2014-08-22 Dodji Seketeli <dodji@redhat.com>
A builtin type name change is not harmless - fix that
* include/abg-comp-filter.h (has_harmless_name_change): New
function declaration.
* include/abg-comparison.h
(diff_category::DECL_NAME_CHANGE_CATEGORY): Renamed this into
HARMLESS_DECL_NAME_CHANGE_CATEGORY.
(diff_category::EVERYTHING_CATEGORY): Update.
* include/abg-fwd.h (is_enum): New function declaration.
(is_var_decl): Return the shared_ptr<var_decl> rather than a bool.
(is_data_member): New overload that takes a shared_ptr<decl_base>.
* src/abg-comp-filter.cc (decl_name_changed): Consider the
qualified name here.
(has_harmless_name_change): Define new function declaration.
(harmless_filter::visit): Use the new has_harmless_name_change
function.
* src/abg-comparison.cc (represent)
(report_name_size_and_alignment_changes, enum_diff::report)
(typedef_diff::report, is_data_member): Use the new
filtering::has_harmless_name_change function to simplify logic of
emitting the name change related diff
* tools/bidiff.cc (set_diff_context_from_opts): Adjust
DECL_NAME_CHANGE_CATEGORY -> HARMLESS_DECL_NAME_CHANGE_CATEGORY.
* src/abg-ir.cc (is_data_member, is_enum): New function definitions.
(is_var_decl): Return the var_decl_sptr rather than just a bool.
* tests/data/test-diff-filter/test13-report.txt: Adjust.
* tests/data/test-diff-filter/test6-report.txt: Adjust.
2014-08-18 Ondrej Oprala <ooprala@redhat.com>
Support C and C++ array type.
* include/abg-comparison.h (array_diff): Declare new class.
(array_diff_sptr): Shared pointer to type array_diff.
(compute_diff): Overload the function to take type
array_diff_sptr as the first two arguments.
* include/abg-fwd.h (array_type_def): Declare new class.
(subrange_type): Likewise.
(is_array_def): Declare new function.
* include/abg-ir.h (array_type_def_sptr): Shared pointer
to type array_type_def.
(array_type_def): Declare new class.
(ir_node_visitor::visit): Declare a new virtual function
taking a pointer to type array_type_def as an argument.
* src/abg-comparison.cc (compute_diff_for_types): Add
try_to_diff for two instances of type array_type_def.
(array_diff::priv): declare struct for holding private members
of type array_diff.
(array_diff::array_diff): Define constructor.
(array_diff::{first,second}_array):Define new
member functions.
(array_diff::element_type_diff): Likewise.
(array_diff::{length,report,traverse}): Likewise.
(compute_diff): Define function overloaded in
include/abg-comparison.h.
* src/abg-dwarf-reader.cc (build_array_type): Define new
function. Handle DW_TAG_array_type and DW_TAG_subrange type.
(build_ir_node_from_die): Amend case DW_TAG_array_type with
a call to build_array_type.
* src/abg-hash.cc (array_type_def::hash): Declare new struct.
(type_base::dynamic_hash::operator()): Attempt to dynamic_cast
the argument to type array_type_def as well.
(array_type_def::hash): Declare new struct.
* src/abg-ir.cc (array_type_def::array_type_def): Define
constructors.
(array_type_def::priv): declare struct for holding private members
of type array_type_def.
(array_type_def::operator==(const decl_base&):
Define new operator.
(array_type_def::operator==(const type_base&):
Likewise.
(array_type_def::append_subrange{,s}): Define
new functions.
(array_type_def::{set,get}_size_in_bits): Likewise.
(array_type_def::get_dimension_count): Likewise.
(array_type_def::get_qualified_name): Likewise.
(array_type_def::get_pretty_representation): Likewise.
(array_type_def::get_subrange_representation): Likewise.
(array_type_def::traverse): Likewise.
(array_type_def::get_{element_type,location,subranges}): Likewise.
(array_type_def::is_infinite): Likewise.
(array_type_def::~array_type_def): Define destructor.
(ir_node_visitor::visit): Define function, taking
pointer to array_type_def as an argument.
* src/abg-reader.cc (map_id_and_node): Check if node
is an array.
(is_array_def): Check if object is an array.
(handle_element_node): Handle array_type_def as well.
(build_subrange_type): Define new function.
(build_array_type_def): Likewise.
(build_type): Build type array_type_def as well.
(build_type_composition): Likewise.
(handle_array_type_def): Define new function.
* src/abg-writer.cc: (write_decl): Output arrays
as well.
(write_member_type): Likewise.
(write_type_composition): Likewise.
(write_array_type_def): Define new function.
* tests/data/test-diff-dwarf/test{10,11}-v{0,1}.{cc,o}: New test source
files
* tests/data/test-diff-dwarf/test{10,11}-report.txt: Likewise.
* tests/data/test-diff-dwarf/test10-report.txt: New test input.
* tests/data/test-read-dwarf/test7.cc: New test source
file.
* tests/data/test-read-dwarf/test7.so: New input binary
to read.
* tests/data/test-read-dwarf/test7.so.abi: New reference
test to compare against.
* tests/data/test-read-write/test25.xml: New test source
file.
* tests/test-diff-dwarf.cc: Adjust to launch the new test.
* tests/test-read-dwarf.cc: Likewise.
* tests/test-read-write.cc: Likewise.
* test/Makefile.am: Add the new test inputs to the source
distribution.
2014-08-19 Dodji Seketeli <dodji@redhat.com>
Ignore variables which type couldn't be read from DWARF
* src/abg-dwarf-reader.cc (build_var_decl): Drop the var on the
floor if its type couldn't be built.
2014-08-19 Dodji Seketeli <dodji@redhat.com>
Support TLS variables
* src/abg-ir.cc (elf_symbol::is_variable): Accept TLS objects as
variables too.
* src/abg-dwarf-reader.cc (eval_last_constant_dwarf_sub_expr)
(die_location_address): Add an output parameter to say if the
resulting constant value is a tls address or not.
(lookup_public_variable_symbol_from_elf): Use the proper
elf_symbol::is_variable() method, rather than trying to figure out
the low levels of what a variable is here. Also, cleanup the
condition.
(read_context::load_symbol_maps): Consider symbols of type
STT_TLS, when loading symbols for variables. Also, to avoir
symbols that are for versions, filter out symbols of type
STT_OBJECT and with a SHN_ABS section index.
(read_context::get_variable_address): If the address is for a tls
variable, do no try to adjust the address to arrange for things
like prelink. As that doesn't seem to affect TLS variables.
(dwarf_expr_eval_context::set_tls_addr): New data member.
(dwarf_expr_eval_context::dwarf_expr_eval_context): Initialize it.
(dwarf_expr_eval_context::set_tls_address): New accessors.
(dwarf_expr_eval_context::op_manipulates_stack): Handle
DW_OP_GNU_push_tls_address, a bit like DW_OP_form_tls_address, but
then, its result is a constant. Set the
dwarf_expr_eval_context::set_tls_addr flag when these two OPs are
run.
(die_member_offset): Adjust to the new signature of
eval_last_constant_dwarf_sub_expr.
* tests/data/test-diff-dwarf/libtest9-v0.so: New test input.
* tests/data/test-diff-dwarf/libtest9-v1.so: Likewise.
* tests/data/test-diff-dwarf/test9-report.txt: Likewise
* tests/data/test-diff-dwarf/test9-v0.cc: Source code for the
first input.
* tests/data/test-diff-dwarf/test9-v1.cc: Source code for the
second input.
* tests/test-diff-dwarf.cc: Run this harness on the two new inputs
above.
* tests/Makefile.am: Add the new inputs to the source distribution.
2014-08-18 Dodji Seketeli <dodji@redhat.com>
Update copyright for abg-dwarf-reader.cc
* src/abg-dwarf-reader.cc: Update copyright year.
2014-08-18 Dodji Seketeli <dodji@redhat.com>
Make the link to the alt debug info file relative
* tests/data/test-alt-dwarf-file/test0-debug-dir/.build-id/16/7088580c513b439c9ed95fe6a8b29496495f26.debug:
Make this link be relative.
2014-08-15 Dodji Seketeli <dodji@redhat.com>
White space fix
* tests/test-lookup-syms.cc: Remove useless white space.
2014-08-15 Dodji Seketeli <dodji@redhat.com>
Update copyright notice
* tests/test-lookup-syms.cc: Update year in copyright notice.
* tools/bidw.cc: Likewise.
2014-08-15 Dodji Seketeli <dodji@redhat.com>
Support alternate debug info sections
* include/abg-dwarf-reader.h (class read_context)
(typedef read_context_sptr, create_read_context)
(has_alt_debug_info): Declare these.
(read_corpus_from_elf): Declare new overload.
* src/abg-dwarf-reader.cc (find_alt_debug_info)
(is_die_attribute_resolved_through_gnu_ref_alt)
(build_primary_die_parent_relations_under)
(build_alternate_die_parent_relations_under):
Define new static functions.
(read_context::{alt_dwarf_,
alt_debug_info_path_, alternate_die_decl_map_,
alternate_die_parent_map_}): New data members.
(read_context::{alt_dwarf, alt_debug_info_path,
alternate_die_decl_map, associate_die_to_decl_primary,
associate_die_to_decl_alternate, associate_die_to_decl,
lookup_decl_from_die_offset_primary,
lookup_decl_from_die_offset_alternate,
lookup_decl_from_die_offset, alternate_die_parent_map}): New
member functions.
(read_context::load_debug_info): Painfully Get a handle on the
alternate debug info section too. We shouldn't have to do all
this work; we could use the new dwarf_getalt() function from
libdw, but we cannot as we want to support supports that predate
that api. When a version of elfutils gets released with that api
though, we should conditionally use that instead.
(build_ir_node_from_die, get_parent_die, get_scope_for_die)
(build_namespace_decl_and_add_to_ir)
(build_class_type_and_add_to_ir, build_qualified_type)
(build_pointer_type_def, build_reference_type, build_typedef_type)
(build_var_decl, build_function_decl): Take a new parameter that
tells if the input DIE is from alternate debug info. Adjust their
code accordingly.
(die_die_attribute): Take a new output parameter that tells if the
resolved DIE is from alternate debug info. Also take a new
parameter that tells if the input DIE is from alternate debug info
sections.
(build_die_parent_relations_under): Take the DIE -> parent map to
act upon. Also, add a new overload that takes a flag saying if
the DIE is from alternate debug info or not, and act upon that.
(build_die_parent_maps): Renamed build_die_parent_map into this
and make it build DIE -> parent DIE relationship for the alternate
debug info file as well.
(find_last_import_unit_point_before_die, ): Adjust to use the
information about if the relevant DIEs are in alternate debug info
or not.
(build_translation_unit_and_add_to_ir): Clear the alternate DIE ->
decl map, that is per TU just as the primary DIE -> decl map.
Adjust to use the information about if the relevant DIEs are in
alternate debug info or not.
(read_debug_info_into_corpus): Build the two DIE -> DIE parent
maps (one for the primary debug info and one for the alternate
debug info).
(create_read_context, has_alt_debug_info): Define new public entry
points.
(read_corpus_from_elf): New entry point overload that takes a
read_context.
* tools/bidw.cc (options::{check_alt_debug_info_path,
show_base_name_alt_debug_info_path}): New data members.
(display_usage): Update for the two new options
--check-alternate-debug-info and
check-alternate-debug-info-base-name.
(parse_command_line): Parse the two options above.
(main) Handle the two new options above.
* tests/Makefile.am: Build the new runtestaltdwarf test. Add the
new data/test-alt-dwarf-file/* files to the build system.
* tests/test-alt-dwarf-file.cc: New test driver.
* tests/data/test-alt-dwarf-file/test0-common.cc: New test input
files.
* tests/data/test-alt-dwarf-file/libtest0-common.so: Likewise.
* tests/data/test-alt-dwarf-file/test0.cc: Likewise.
* tests/data/test-alt-dwarf-file/libtest0.so: Likewise.
* tests/data/test-alt-dwarf-file/test0.h: Likewise.
* tests/data/test-alt-dwarf-file/test0-common-dwz.debug: Likewise.
* tests/data/test-alt-dwarf-file/test0-debug-dir/.build-id/16/7088580c513b439c9ed95fe6a8b29496495f26.debug:
Likewise.
* tests/data/test-alt-dwarf-file/test0-debug-dir/test0-common-dwz.debug:
Likewise.
* tests/data/test-read-dwarf/test1.abi: Adjust. bidw doesn't emit
an abstract constructor/destructor anymore. It emits just the
functions matching the cdtor symbols found in the binary.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
2014-07-26 Dodji Seketeli <dodji@redhat.com>
Better handle corner cases of void* DWARF parsing
* src/abg-dwarf-reader.cc (build_pointer_type_def): Better
support cases where the underlying type of the pointer is not
know. In that case, the pointer should not be created.
2014-07-20 Dodji Seketeli <dodji@redhat.com>
Support finding symbols with bias wrt DWARF references
* src/abg-dwarf-reader.cc (get_binary_load_address): New function
definition.
(read_context::elf_handle): Add comment.
(read_context::{dwarf_elf_handle, dwarf_is_splitted,
maybe_adjust_address_for_exec_or_dyn}): New method definitions.
(maybe_adjust_fn_sym_address)
(maybe_adjust_var_sym_address): Move these so they become members
of read_context. Also, For shared libraries and executable (that
could have been e.g prelinked), consider their loading address
when trying to find which symbol resides at a given place in
memory.
(read_context::{get_function_address, get_variable_address):
Adjust.
(build_translation_unit_and_add_to_ir): Fix comment.
2014-07-20 Dodji Seketeli <dodji@redhat.com>
Reset the scope of void_type_decl for each new translation unit
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir):
Clear the void_type_decl on new translation units.
2014-07-18 Dodji Seketeli <dodji@redhat.com>
Update INSTALL file
* INSTALL: Adjust the copyright year information because autotools
2.69 did.
2014-07-18 Dodji Seketeli <dodji@redhat.com>
Correctly write the name of a const reference type
* src/abg-dwarf-reader.cc (maybe_strip_qualification): Define new
function.
(build_ir_node_from_die): Use the maybe_strip_qualification when
building a qualified type.
* src/abg-ir.cc (qualified_type_def::build_name): Fix the
representation of the name of a reference that is const.
* tests/data/test-read-dwarf/test1.abi: Adjust.
* tests/data/test-diff-dwarf/test0-report.txt: Likewise.
* tests/data/test-diff-dwarf/test1-report.txt: Likewise.
* tests/data/test-diff-dwarf/test6-report.txt: Likewise.
* tests/data/test-diff-dwarf/test7-report.txt: Likewise.
* tests/data/test-diff-dwarf/test8-report.txt: Likewise.
* tests/data/test-diff-filter/test0-report.txt: Likewise.
* tests/data/test-diff-filter/test01-report.txt: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test3-report.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test13-report.txt: Likewise.
* tests/data/test-diff-filter/test14-0-report.txt: Likewise.
* tests/data/test-diff-filter/test14-1-report.txt: Likewise.
2014-07-01 Sinny Kumari <skumari@redhat.com>
Consider symbols with STB_GNU_UNIQUE binding as public
* src/abg-ir.cc (is_public): Change in function to consider
symbols with STB_GNU_UNIQUE binding as public
* tests/data/test-read-dwarf/test6.cc: Test file to generate
STB_GNU_UNIQUE binding symbols
* tests/data/test-read-dwarf/test6.so: Test shared library having
STB_GNU_UNIQUE binding symbols
* tests/data/test-read-dwarf/test6.so.abi: XML file containing
dwarf information from test6.so
* tests/test-read-dwarf.cc (in_out_specs): Add the new test above
* tests/Makefile.am: Add tests/data/test-read-dwarf/test6.cc,
tests/data/test-read-dwarf/test6.so and
tests/data/test-read-dwarf/test6.so.abi to the distribution
2014-07-01 Dodji Seketeli <dodji@redhat.com>
Add comment to test-read-write.cc
* tests/test-read-write.cc: Update copyright notice and add a
meaningful comment for the file.
2014-06-23 Dodji Seketeli <dodji@redhat.com>
Support reading void* type from DWARF
* include/abg-ir.h (type_decl::get_void_type_decl): Declare new
static method.
* src/abg-ir.cc (type_decl::get_void_type_decl): Define it.
* src/abg-dwarf-reader.cc (build_ir_node_for_void_type): Define
new static function.
(build_pointer_type_def): Support void* type nodes here.
* tests/data/test-read-dwarf/test5.cc: Source code for new test
input.
* tests/data/test-read-dwarf/test5.o: New test input.
* tests/data/test-read-dwarf/test5.o.abi: Likewise.
* tests/Makefile.am: Add the above to the source distribution.
2014-06-23 Dodji Seketeli <dodji@redhat.com>
Update a comment in abg-dwarf-reader.cc
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Update a
comment here.
2014-06-23 Mark Wielaard <mjw@redhat.com>
Handle C99 restrict qualifier and DWARFv3 DW_TAG_restrict_type.
* src/abg-dwarf-reader.cc (build_qualified_type): Handle
DW_TAG_restrict_type by adding CV_RESTRICT.
(build_ir_node_from_die): Call build_qualified_type for
DW_TAG_restrict_type.
* src/abg-reader.cc (build_qualified_type_decl): Handle
"restrict" attribute by adding CV_RESTRICT.
* src/abg-writer.cc (write_qualified_type_def): Output
"restrict" attribute for CV_RESTRICT.
* tests/data/test-read-dwarf/test4.c: New test file.
* tests/data/test-read-dwarf/test4.so: Likewise.
* tests/data/test-read-dwarf/test4.so.abi: Likewise.
* tests/data/test-read-write/test24.xml: Likewise.
* tests/test-read-dwarf.cc (in_out_specs): Add test4.
* tests/test-read-write.cc (in_out_specs): Add test24.xml.
2014-06-23 Dodji Seketeli <dodji@seketeli.org>
Add subdir-objects automake option where it is needed
* src/Makefile.am: Add the subdir-object automake option here.
Do not specify absolute paths for the input files as Automake now
takes care of that just fine.
* tests/Makefile.am: Likewise.
* tools/Makefile.am: Likewise.
2014-06-23 Dodji Seketeli <dodji@seketeli.org>
Remove autotools artifacts from the repository
* config.guess: Remove from revision control system.
* config.sub: Likewise.
* depcomp: Likewise.
* m4/libtool.m4: Likewise.
* missing: Likewise.
2014-06-23 Dodji Seketeli <dodji@redhat.com>
Avoid reporting diff nodes that have already been reported
* include/abg-comp-filter.h (class harmful_filter): Update
comment.
(class redundant_filter): Declare new filter.
* include/abg-comparison.h (enum
diff_category::NOT_REDUNDANT_CATEGORY): New category. Update the
values of the other enumerators.
(diff_context::{add_diff, diff_has_been_traversed}): New overloads.
(diff_context::{categorizing_redundancy, show_redundant_changes}):
Declare new methods.
(diff_context::remove_from_category): Define new inline method.
* src/abg-comparison.cc (noop_deleter::operator()): Constify the
parameter.
(CATEGORIZE_REDUNDANCY_FROM_CHILD_NODE)
(UPDATE_REDUNDANCY_CATEGORIZATION_FROM_NODE_SUBTREE): New macros.
(TRAVERSE_DIFF_NODE_AND_PROPAGATE_CATEGORY)
(TRAVERSE_MEM_DIFF_NODE_AND_PROPAGATE_CATEGORY)
(TRAVERSE_MEM_FN_DIFF_NODE_AND_PROPAGATE_CATEGORY): Use the new
CATEGORIZE_REDUNDANCY_FROM_CHILD_NODE and
UPDATE_REDUNDANCY_CATEGORIZATION_FROM_NODE_SUBTREE macros above.
(ENSURE_DIFF_NODE_TRAVERSED_ONCE)
(ENSURE_MEM_DIFF_NODE_TRAVERSED_ONCE): If the (type_decl or class)
node hasn't been yet traversed, mark it as non-redundant.
(diff_context::priv::categorizing_redundancy): New member.
(diff_context::priv::priv): Initialize it.
(diff_context::{add_diff, diff_has_been_traversed): Define new
overloads.
(diff_context::mark_diff_as_traversed): Intern a diff node that is
marked as being traversed.
(diff_context::{categorizing_redundancy, show_redundant_changes}):
Define new methods.
(diff::is_filtered_out): A redundant function or top-level
variable is considered filtered-out. Otherwise, the new
NOT_REDUNDANT_CATEGORY doesn't play any role when comparing
allowed categories with the set of categories a diff node belongs
to.
(corpus::priv::categorize_redundant_changed_sub_nodes): Define
new member function.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): Change
this to first walk the changed functions and variables to apply
filters, then categorize redundant changed functions, and then
walk the changed functions and variables again to count
filtered-out diff nodes.
(filtering::redundant_filter::visit): Define new member function.
* tools/bidiff.cc (options::show_redundant_changes): New data
member.
(options::options): Initialize it.
(display_usage): Add help string for the --redundant command line
option.
(parse_command_line): Add support for the --redundant command line
option.
(set_diff_context_from_opts): Take the --redundant command line
option in account.
* tests/test-diff-filter.cc: Update this to add new test inputs.
* tests/data/test-diff-filter/test14-0-report.txt: New test input.
* tests/data/test-diff-filter/test14-1-report.txt: Likewise.
* tests/data/test-diff-filter/test14-v0.cc: Likewise.
* tests/data/test-diff-filter/test14-v0.o: Likewise.
* tests/data/test-diff-filter/test14-v1.cc: Likewise.
* tests/data/test-diff-filter/test14-v1.o: Likewise.
* tests/data/test-diff-filter/test15-0-report.txt: Likewise.
* tests/data/test-diff-filter/test15-1-report.txt: Likewise.
* tests/data/test-diff-filter/test15-v0.cc: Likewise.
* tests/data/test-diff-filter/test15-v0.o: Likewise.
* tests/data/test-diff-filter/test15-v1.cc: Likewise.
* tests/data/test-diff-filter/test15-v1.o: Likewise.
* tests/Makefile.am: Add the above to the build system.
2014-06-23 Dodji Seketeli <dodji@redhat.com>
A name that couldn't be demangled remains the same
* src/abg-ir.cc (demangle_cplus_mangled_name): When the demangler
fails to demangle a name, just return the input name as-is.
2014-06-23 Dodji Seketeli <dodji@redhat.com>
Update copyright notice for a bunch of files
* include/abg-comp-filter.h: Update copyright notice.
* include/abg-comparison.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-ir.cc: Likewise.
* tools/bidiff.cc: Likewise.
* tests/test-diff-filter.cc: Likewise.
2014-06-19 Sinny Kumari <skumari@redhat.com>
Keep symbol's multiple aliases within single attribute separated by comma
* src/abg-writer.cc (write_elf_symbol_aliases): Changing function
to keep multiple symbol aliases within one alias attribute
* src/abg-reader.cc (build_elf_symbol_db): Changing function to read
symbol's alias attribute and split if multiple alias exist with comma(,)
asi a delimiter and add all aliases to main symbol
* tests/data/test-read-dwarf/test3.c: Test file to generate multiple aliases
* tests/data/test-read-dwarf/test3.so: Test shared library having multiple
aliases of a symbol
* tests/data/test-read-dwarf/test3.so.abi: XML file containing dwarf
information from test3.so
* tests/test-read-dwarf.cc (in_out_specs): Add the new test above
* tests/Makefile.am: Add tests/data/test-read-dwarf/test3.c,
tests/data/test-read-dwarf/test3.so and tests/data/test-read-dwarf/test3.so.abi
to the distribution
2014-06-18 Mark Wielaard <mjw@redhat.com>
DW_TAG_mutable_type doesn't exist.
* src/abg-dwarf-reader.cc (is_type_tag): Remove DW_TAG_mutable_type.
(build_ir_node_from_die): Likewise.
2014-06-05 Dodji Seketeli <dodji@redhat.com>
Look at first parm type and artificial-ness to detect static-ness
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): To
tell if a member function is static, look if the first parm is a
pointer to the type of the enclosing class, and if it's
artificial. Don't bother trying to be smart by looking at the
non-presence of DW_AT_object_pointer b/c that attribute wasn't
emitted by GCC 4_4.
2014-06-04 Dodji Seketeli <dodji@redhat.com>
Harden debug info path management & better error reporting
* include/abg-dwarf-reader.h (enum status): New enum.
(read_corpus_from_elf): Return an instance of status above, and
return the corpus by parameter.
* src/abg-dwarf-reader.cc (create_default_dwfl): Add a comment
about elfutils wanting the Dwfl_Callbacks::debuginfo_path to be an
absolute path.
(read_corpus_from_elf): Return an instance of status above, and
return the corpus by parameter.
* tools/abg-tools-utils.h (make_path_absolute): Declare new function.
* tools/abg-tools-utils.cc (make_path_absolute): New
implementation.
* tools/bidiff.cc (options::di_root_path[12]): Make these be
shared pointers.
(parse_command_line): ensure the debug info root paths are
absolute.
(main): Adjust. Give meaningful errors when the debug info or
symbol files couldn't be read.
* tools/bidw.cc (options::di_root_path): Make this be a shared
pointer.
(parse_command_line): Ensure the debug info root path is absolute.
(main): Adjust. Give meaningful errors when the debug info or
symbol files couldn't be read.
* tools/bilint.cc (options::di_root_path): Make this be a shared
pointer.
(parse_command_line): Ensure the debug info root path is absolute.
(main): Adjust. Give meaningful errors when the debug info or
symbol file couldn't be read.
* tests/test-diff-dwarf.cc (main): Adjust.
* tests/test-read-dwarf.cc (main): Likewise.
2014-06-02 Dodji Seketeli <dodji@redhat.com>
Do not choke on AR archives
* tools/abg-tools-utils.h (file_type::FILE_TYPE_AR): New enumerator.
* tools/abg-tools-utils.cc (guess_file_type): Recognize AR archive
files.
* tools/bidiff.cc (main): Support AR archives.
* tools/bidw.cc (main): Likewise.
* tools/bilint.cc (main): Likewise.
2014-05-30 Dodji Seketeli <dodji@redhat.com>
Honor linkage name showing when displaying added/removed member functions
* src/abg-comparison.cc (represent): Take a diff_context. If
instructed to show linkage names, show the linkage name of the
member function.
(class_diff::report): Adjust for the new signature of represent().
2014-05-30 Dodji Seketeli <dodji@redhat.com>
Make bidiff filter output and display symbol names by default
* tools/bidiff.cc (options::options): Initialize
options::show_linkage_names to true and
options::show_harmful_changes to false.
(parse_command_line): Change --linkage-names into
--no-linkage-names as the linkage names are now displayed by
default. Change --no-harmless into --harmless as harmless changes
are now filtered by default.
(display_usage): Update help string for the --linkage-names ->
--no-linkage-names and --no-harmful -> --harmful change.
* tests/test-diff-filter.cc: Adjust.
2014-05-29 Dodji Seketeli <dodji@redhat.com>
Ensure added/removed member functions have their symbols added/removed
* include/abg-comparison.h (diff_context::{set_corpora,
get_first_corpus, get_second_corpus}): Declare new member
functions.
* src/abg-comparison.cc (diff_context::{set_corpora,
get_first_corpus, get_second_corpus}): Define them.
(compute_diff): In the overload for corpus_sptr stick the corpora
being compared, into the diff context.
(class_diff::ensure_lookup_tables_populated): If a member function
is allegedly removed, check that its underlying symbol is removed
from the corpus as well. Otherwise, consider that the member
function hasn't been removed. Likewise, if a member function is
allegedly added, check that its underlying symbol has been added
to the corpus as well. Otherwise, consider that the member
function hasn't been added. The symbols can now be accessed
through the two corpora that are now present in the diff context.
2014-05-29 Dodji Seketeli <dodji@redhat.com>
Fix scope for DIEs with specification or abstract_origin attributes
* src/abg-dwarf-reader.cc (get_scope_for_die): If the DIE has a
DW_AT_specification or DW_AT_abstract_origin attribute, get the
scope of the referred-to DIE.
(build_ir_node_from_die): For a variable DIE that has a
DW_AT_{specification,abstract_origin} attribute, do not add the
built variable IR node to its scope because it is already in a
scope. It's in a scope because that built variable is for the DIE
that is referred-to by the DW_AT_{specification,abstract_origin}
attribute. Likewise for member functions. Also, now,
get_scope_for_die can return a class for a function DIE because
get_scope_for_die now returns the *logical* scope of the DIE; that
is, it follows DW_AT_{specification,abstract_origin} attributes.
* tests/data/test-read-dwarf/test1.abi: Adjust.
2014-05-28 Dodji Seketeli <dodji@redhat.com>
Add a symbol database to the ABI Corpus & support symbol aliases
* include/abg-corpus.h (corpus::{g,s}et_{fun,var}_symbol_map{_sptr}):
Declare new accessors.
(corpus::lookup_{variable,function}_symbol): Declare new member
functions.
* src/abg-corpus.cc (corpus::{g,s}et_{fun,var}_symbol_map{_sptr}):
Define new accessors.
(corpus::lookup_{variable,function}_symbol): Define new member
functions.
* include/abg-ir.h (string_elf_symbol_sptr_map_type)
(string_elf_symbol_sptr_map_sptr, elf_symbols)
(string_elf_symbols_map_type, string_elf_symbols_map_sptr): New
convenience typedefs.
(elf_symbol::{get_main_symbol, is_main_symbol, get_next_alias,
has_aliases, add_alias, get_id_string,
get_name_and_version_from_id, operator=}): Declare new member
functions.
* src/abg-ir.cc (elf_symbol::{get_main_symbol, is_main_symbol,
get_next_alias, has_aliases, add_alias, get_id_string,
get_name_and_version_from_id, operator=}): Define new member
functions.
* include/abg-reader.h (read_corpus_from_file): Take a shared
pointer to corpus.
* src/abg-reader.cc (read_context::{g,s}et_corpus): Define these.
(build_elf_symbol_db, build_elf_symbol_from_reference)
(read_symbol_db_from_input): Define new functions.
(read_corpus_from_input): Adjust. Make it read symbol databases.
(build_elf_symbol): Harden this.
(build_{var,function}_decl): Read the symbol reference. Do not
read the local symbol serialization anymore.
(read_corpus_from_archive): Adjust.
(read_corpus_from_file): Take a reference to a shared pointer to
corpus, rather than a reference to the corpus.
(read_corpus_from_native_xml): Only keep the overload that returns
a corpus. Set the current context with the corpus.
* src/abg-dwarf-reader.cc (addr_elf_symbol_sptr_map_type)
(addr_elf_symbol_sptr_map_sptr): New convenience typedefs.
(read_context::{fun_sym_addr_sym_index_map_,
var_sym_addr_sym_index_map_): Remove.
(read_context::{fun,var}_addr_sym_map_): New. Replace the above
that got removed.
(read_context::{var,fun}_syms_): New.
(read_context::lookup_elf_{fn,var}_symbol_from_address): Adjust.
(read_context::{fun,var}_addr_sym_map{_sptr}): New.
(read_context::{fun,var}_syms{_sptr}): New.
(read_context::load_symbol_maps): Replace
read_context::load_symbol_addr_to_index_maps. Adjust to load all
the new maps.
(read_context::maybe_load_symbol_maps): New.
(read_debug_info_into_corpus): Renamed build_corpus into this.
Update to load symbol maps and set it to the corpus.
* src/abg-writer.cc (write_context::get_fun_symbol_map): New
accessor.
(write_elf_symbol_aliases, write_elf_symbol_reference)
(write_elf_symbols_table): Define new static functions.
(write_var_decl): Write the reference to the underlying symbol of
the variable. Do not write the full symbol here anymore.
(write_function_decl): Likewise, write the reference to the
underlying symbol of the function. Do not write the full symbol
here anymore.
(write_corpus_to_native_xml): Write the symbol databases at the
beginning of the corpus document.
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Now that the
corpus has symbols, check if a the symbol of an allegedly deleted
function (resp. variable) is deleted; if not, then do not report
the function (resp. variable) as deleted. Similarly, check if the
symbol of an allegedly added function (resp. variable) is added.
if not, the do not report the function (resp. variable) as added.
* tests/test-write-read-archive.cc (main): Adjust.
* tools/biar.cc (extract_tus_from_archive): Likewise.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
* tests/data/test-read-dwarf/test0.abi: Likewise.
* tests/data/test-read-dwarf/test1.abi: Likewise.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
2014-05-21 Dodji Seketeli <dodji@redhat.com>
Rename 'symbol' in fn names to 'public decl' in abg-corpus.{cc,h}
* src/abg-corpus.cc (lots of places): Rename references to
'symbol' in function & variable names to 'public_decl'.
2014-05-22 Dodji Seketeli <dodji@redhat.com>
Support debug info files being outside the expected system directories
* include/abg-dwarf-reader.h (read_corpus_from_elf): Take a
debug_info_root_path parameter.
src/abg-dwarf-reader.cc (create_default_dwfl): Take a
debug_info_root_path. Use that to initialize the Dwfl_Callbacks
structure used by dwfl_begin.
(create_default_dwfl_sptr, read_corpus_from_elf): Likewise, Take a
debug_info_root_path parameter.
* tests/test-diff-dwarf.cc (main): Adjust.
* tests/test-read-dwarf.cc (main): Likewise.
* tools/bidiff.cc (options::dir_root_path[12]): New member.
(options::options): Initialize it.
(display_usage): Add help string for the --debug-info-dir[12]
options.
(parse_command_line): Handle the new --debug-info-dir[12] options.
(main): Pass the debug info directories to read_corpus_from_elf.
* bidw.cc (options::::di_root_path): New member.
(options::options): Initialize it.
(display_usage): Add help string for the new --debug-info-dir
option.
(parse_command_line): Handle the new --debug-info-dir.
(main): Pass the debug info root path to read_corpus_from_elf.
* tools/bilint.cc (options::di_root_path): New member.
(options::options): Initialize it.
(display_usage): Add help string for the new --debug-info-dir.
(parse_command_line): Handle --debug-info-dir command line option.
(main): Pass the debug info root path to read_corpus_from_elf.
2014-05-21 Dodji Seketeli <dodji@redhat.com>
Fix detection of destructors
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Simply
detect that the destructor starts with a '~'.
2014-05-21 Dodji Seketeli <dodji@redhat.com>
Add clone in the scope of the cloned decl they logically belong to
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Do not try to
add the cloned function/variable to the current scope because
cloning should have added the decl into the scope of the cloned
target.
* src/abg-ir.cc ({var,function}_decl::clone): Insert the clone
decl into the scope of the cloned decl. My understanding is that
it's where they belong.
* tests/data/test-read-dwarf/test1.abi: Update this to incorporate
all the abstract constructors/destructors *and* their clones into
the classes where they belong.
* tests/data/test-read-dwarf/test1.abi: Adjust for the abstract
cdtor being added to the class, as well as their cloned concrete
instances.
* tests/data/test-read-dwarf/test2.so.abi: Likewise.
2014-05-20 Dodji Seketeli <dodji@redhat.com>
Support decl cloning when seeing DW_AT_abstract_origin
* include/abg-ir.h ({var,function}_decl::clone): New method.
* src/abg-dwarf-reader.cc (die_die_attribute): Add a flag to avoid
looking through DW_AT_abstract_origin attribute here.
(build_function_decl): Set the linkage name from
DW_AT_linkage_name if it's not set yet.
(build_ir_node_from_die): For DW_TAG_{variable,subprogram}, when
we see DW_AT_abstract_origin, clone the decl they refer to.
Also, avoid dropping the DIE on the floor just because it doesn't
have die_is_artificial here.
* src/abg-ir.cc ({var,function}_decl::clone): Implement this.
2014-05-19 Dodji Seketeli <dodji@redhat.com>
Don't share types across TUs when DW_TAG_partial_unit are involved
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir):
Clear the part of the context that needs to be per TU.
(build_ir_node_from_die): Assert that this should not be called
for partial and imported unit because for now our practical
assumption is that DIEs under partial unit are lazily read only
when referenced by DIEs that are under DW_TAG_compile_unit.
* tests/Makefile.am: Add the new test files to the build system.
* tests/data/test-read-dwarf/test2.so.abi: Fix the reference
output here to avoid sharing types across TUs, making the output
valid for bilint.
2014-05-19 Dodji Seketeli <dodji@redhat.com>
Initial support for DW_TAG_partial_unit
* src/abg-dwarf-reader.cc (read_context::cur_tu_die_): New member.
(read_context::read_context): Initialize the new member.
(read_context::cur_tu_die): New accessors.
(find_last_import_unit_point_before_die): New static function.
(get_parent_die): Take a logical current die offset parameter. If
the die we want the parent for is a partial unit, then find the
last DW_TAG_imported_unit that imports that partial unit before
the logical current die and return the parent of that
DW_TAG_imported_unit die.
(get_scope_for_die): Take a logical current die offset parameter.
Adjust.
(build_translation_unit_and_add_to_ir): Set/unset the current
translation unit DIE in the context. Adjust.
(build_namespace_decl_and_add_to_ir)
(build_class_type_and_add_to_ir, build_qualified_type)
(build_pointer_type_def, build_reference_type, build_typedef_type)
(build_var_decl, build_function_decl, build_ir_node_from_die):
Take a logical current die offset parameter. Adjust.
(build_corpus): Accept that we can have DIE that are not
DW_TAG_compile_unit at the top level, because, well, we can now
have DW_TAG_partial_unit too.
* tests/data/test-read-dwarf/test2-{0,1}.cc: New test source
files.
* tests/data/test-read-dwarf/test2.h: Likewise.
* tests/data/test-read-dwarf/test2.so: New input binary to read.
* tests/data/test-read-dwarf/test2.so.abi: New reference test to
compare against.
* tests/test-read-dwarf.cc: Adjust to launch the new test.
2014-05-14 Dodji Seketeli <dodji@redhat.com>
Re-build a test input file with debug info
* tests/data/test-lookup-syms/test1.so: Rebuild this with debug
info.
2014-05-14 Dodji Seketeli <dodji@redhat.com>
Serialize and de-serialize elf symbols for var & function decls
* abg-ir.h (string_to_elf_symbol_type, string_to_elf_symbol_binding):
Declare new entry points.
* src/abg-ir.cc (string_to_elf_symbol_type)
(string_to_elf_symbol_binding): Define new entry points.
* include/abg-libxml-utils.h (xml_char_sptr_to_string): Declare
new entry points.
* src/abg-libxml-utils.cc (xml_char_sptr_to_string): Define new
entry points.
* src/abg-reader.cc (read_elf_symbol_type)
(read_elf_symbol_binding, build_elf_symbol): Define new static
functions.
(build_function_decl, build_var_decl): Use the new
build_elf_symbol and set the symbol to the function. Flag the
function as having a public symbol in the symbol table if the
symbol is public.
* src/abg-writer.cc (write_elf_symbol_type)
(write_elf_symbol_binding, write_elf_symbol): Define new static
functions.
(write_var_decl, write_function_decl): Use the new
write_elf_symbol to serialize the symbol for the decl.
* tests/data/test-read-dwarf/test[01].abi: Adjust.
2014-05-14 Dodji Seketeli <dodji@redhat.com>
Don't crash when de-serializing an empty function parm xml node
* src/abg-reader.cc (build_function_parameter): Do not crash if
the xml node is NULL.
2014-05-14 Dodji Seketeli <dodji@redhat.com>
Fix a typo in serializing a decl_base::binding
* src/abg-ir.cc (operator<<(std::ostream&, decl_base::binding)):
Fix a typo here.
2014-05-14 Dodji Seketeli <dodji@redhat.com>
Add a help string for the --no-absolute-path option of bisym
* tools/bisym.cc (show_help): Add a missing help string.
2014-05-13 Dodji Seketeli <dodji@redhat.com>
Do not try to use ELF hash tables in demangling lookup mode
* src/abg-dwarf-reader.cc (lookup_symbol_from_elf): If in
demangling mode, do not use ELF hash tables.
2014-05-13 Dodji Seketeli <dodji@redhat.com>
Use the proper symbol table for and set linkage_name to symbol name
* src/abg-dwarf-reader.cc (find_symbol_table_section): Return the
.symtab if we are looking at an executable or relocatable file and
.dynsym if we are looking at a DSO.
(find_symbol_table_section_index): Likewise. Implement this in
terms of find_symbol_table_section.
(build_{function,var}_decl): Set the linkage_name to the symbol
name, if the symbol name is not empty.
* tests/data/test-diff-filter/test9-report.txt: Adjust.
2014-05-13 Dodji Seketeli <dodji@redhat.com>
Remove redundant "'" around linkage names in diff reports
* src/abg-comparison.cc (corpus_diff::report): Remove the
redundant "'" from the linkage names in the diff.
2014-05-08 Dodji Seketeli <dodji@redhat.com>
Initial support for elf symbol (versionning) during decl comparison
* include/abg-fwd.h (get_linkage_name): Remove.
* include/abg-dwarf-reader.h (enum symbol_type)
(enum symbol_binding): Move these into abg-ir.h.
(lookup_symbol_from_elf, lookup_public_function_symbol_from_elf):
Adjust.
* src/abg-dwarf-reader.cc (eval_last_constant_dwarf_sub_expr):
Declare this before using it.
(die_address_attribute, die_location_address)
(stt_to_elf_symbol_type, stb_to_elf_symbol_binding)
(find_hash_table_section_index, find_symbol_table_section)
(find_symbol_table_section_index, find_text_section)
(find_bss_section, compare_symbol_name)
(get_symbol_versionning_sections get_version_for_symbol)
(lookup_symbol_from_sysv_hash_tab)
(lookup_symbol_from_gnu_hash_tab, get_elf_class_size_in_bytes)
(bloom_word_at, setup_gnu_ht, lookup_symbol_from_elf_hash_tab)
(lookup_symbol_from_symtab, maybe_adjust_fn_sym_address)
(maybe_adjust_var_sym_address): New static functions.
(enum hash_table_kind): New enum.
(struct gnu_ht): New struct.
(read_context::var_decls_to_add_): Renamed var_decls_to_add into
this.
(read_context::{fun, var}_sym_addr_sym_index_map_): New member.
(read_context::{lookup_symbol_from_elf,
lookup_elf_symbol_from_index, lookup_elf_fn_symbol_from_address,
lookup_elf_var_symbol_from_address, fun_sym_addr_sym_index_map,
var_sym_addr_sym_index_map, load_symbol_addr_to_index_maps,
get_function_address, get_variable_address}): New member
functions.
(read_context::lookup_public_{variable,
function}_symbol_from_elf): Adjust.
(op_pushes_constant_value): Fix a bug here.
(lookup_symbol_from_elf): Adjust. Support cases where there is no
elf hash table, e.g, for relocatable files.
(lookup_public_function_symbol_from_elf)
(lookup_public_variable_symbol_from_elf): Adjust.
(build_var_decl): Allow updating the var_decl to associate it with
its underlying symbol. In that case, if the linkage name is not
set, set it to the symbol name.
(build_function_decl): Likewise for function_decl.
(operator<<(std::ostream&, symbol_type)):
(operator<<(std::ostream&, symbol_binding)): Move these do
abg-ir.cc.
* include/abg-ir.h (class elf_symbol): Declare new class. Move
enum symbol_binding and enum symbol_type (from abg-dwarf-reader.h) to
elf_symbol::binding and elf_symbol::type here.
(operator<<(std::ostream&, elf_symbol::type))
(operator<<(std::ostream&, elf_symbol::binding))
(operator==(const elf_symbol_sptr, const elf_symbol_sptr)): New
operators.
(class elf_symbol::version): Declare new class.
(class var_decl): Make this pimpl, and add ...
(var_decl::{g,s}et_symbol): ... new member functions.
(class function_decl): Likewise, make this pimpl and add ...
(function_decl::{g,s}et_symbol): ... new member functions.
* src/abg-ir.cc (struct elf_symbol, elf_symbol::priv): New
types.
(elf_symbol::*): Lots of new members and member functions.
(operator==(const elf_symbol_sptr, const elf_symbol_sptr)): New.
(operator<<(std::ostream&, elf_symbol::type)): New.
(operator<<(std::ostream&, elf_symbol::binding)): New.
(elf_symbol::version::priv): New type.
(elf_symbol::version::*): Lots of member functions.
(get_linkage_name): Removed.
(var_decl::priv): New type. Pimplify the thing.
(var_decl::{s,g}et_symbol): New.
(var_decl::operator==): Take symbols in account in the comparison.
(function_decl::priv): New type.
(function_decl::*): Pimplify.
(function_decl::{s,g}et_symbol): New.
(function_decl::operator==): Take symbols in account in the
comparison.
* include/abg-comparison.h (diff_context::show_linkage_name): New
member function.
* src/abg-comparison.cc (diff_context::priv::show_linkage_name_):
New member.
(diff_context::priv::priv): Initialize it.
(diff_context::show_linkage_names): New member function.
(corpus_diff::report): If the user used --show-linkage-names,
display the linkage name after the name of the functions. Add
missing "'" in the some spots.
* tools/bidiff.cc (options.show_linkage_names): New member.
(display_usage, parse_command_line): Support --linkage-names.
* tools/bisym.cc (show_help): Add '\n' at the end of help string
for --demangle. Add --no-absolute-path option.
(parse_command_line): Support --no-absolute-path.
(main): Adjust for symbol (versionning) support. Consider that
the program successfully completed even when the symbol wasn't
found. Support --no-absolute-path.
* tests/data/test-lookup-syms/test0-report.txt: New.
* tests/data/test-lookup-syms/test01-report.txt: New.
* tests/data/test-lookup-syms/test02-report.txt: New.
* tests/data/test-read-dwarf/test0.abi: Adjust.
* tests/data/test-read-dwarf/test1.abi: Adjust.
* tests/data/test-diff-dwarf/test7-report.txt: Adjust.
* tests/data/test-diff-filter/test10-report.txt: Adjust.
* tests/data/test-diff-filter/test12-report.txt: Adjust.
* tests/data/test-lookup-syms/test1-[123]-report.txt: New.
* tests/data/test-lookup-syms/test1.c: New.
* tests/data/test-lookup-syms/test1.version-script: New.
* tests/test-lookup-syms.cc: Adjust for new tests.
* test/Makefile.am: Adjust makefile.
2014-05-07 Dodji Seketeli <dodji@redhat.com>
Rename decl_base::get_mangled_name into decl_base::get_linkage_name
* include/abg-ir.h (decl_base::get_linkage_name): Renamed
decl_base::get_mangled_name into this.
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated)
(function_decl_diff::report, type_decl_diff::report)
(corpus_diff::priv::ensure_lookup_tables_populated)
(corpus_diff::report, compute_diff): Adjust.
* src/abg-corpus.cc ({var_comp, func_comp}::operator()): Likewise.
(corpus::priv::build_symbol_table): Likewise.
* src/abg-dwarf-reader.cc (die_linkage_name): Renamed
die_mangled_name into this.
(die_loc_and_name, build_translation_unit_and_add_to_ir)
(build_namespace_decl_and_add_to_ir, build_type_decl)
(build_enum_type, build_class_type_and_add_to_ir)
(build_typedef_type, build_var_decl, build_function_decl, ): Adjust.
* src/abg-hash.cc (decl_base::hash::operator()): Likewise.
* src/abg-ir.cc (decl_base::priv::linkage_name_): Renamed
decl_base::priv::mangled_name_ into this.
(decl_base::priv::priv, decl_base::{decl_base, operator==})
(get_linkage_name, typedef_decl::typedef_decl, var_decl::var_decl)
(function_decl::function_decl, class_decl::base_spec::base_spec)
(class_decl::method_decl::method_decl): Adjust.
(decl_base::{g,s}et_linkage_name): Renamed
decl_base::{g,s}et_mangled_name into this.
* src/abg-writer.cc (write_decl, write_typedef_decl)
(write_var_decl, write_function_decl, dump): Adjust.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Drop symbols not global in a symtab from corpus symtab
* src/abg-corpus.cc (corpus_priv::build_symbol_table): If a
function or variable symbol is not public (global or weak) and
present in an elf symbol table, drop it from the corpus symbol
table. As a result functions are variables (not present in the
elf symbol tables) that we were previously taking in account are
not dropped on the floor, leading to much less noise.
* tests/data/test-diff-dwarf/test0-v0.cc: Update to avoid
generating inline functions.
* tests/data/test-diff-dwarf/test0-v0.o: Likewise.
* tests/data/test-diff-dwarf/test0-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test0-v1.o: Likewise.
* tests/data/test-diff-dwarf/test7-v0.o: Likewise.
* tests/data/test-diff-dwarf/test7-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test7-v1.o: Likewise.
* tests/data/test-diff-dwarf/test8-v0.cc: Likewise.
* tests/data/test-diff-dwarf/test8-v0.o: Likewise.
* tests/data/test-diff-dwarf/test8-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test8-v1.o: Likewise.
* tests/data/test-diff-filter/test0-v0.cc: Likewise.
* tests/data/test-diff-filter/test0-v0.o: Likewise.
* tests/data/test-diff-filter/test0-v1.cc: Likewise.
* tests/data/test-diff-filter/test0-v1.o: Likewise.
* tests/data/test-diff-filter/test10-v0.cc: Likewise.
* tests/data/test-diff-filter/test10-v0.o: Likewise.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test10-v1.o: Likewise.
* tests/data/test-diff-filter/test13-v0.cc: Likewise.
* tests/data/test-diff-filter/test13-v0.o: Likewise.
* tests/data/test-diff-filter/test13-v1.cc: Likewise.
* tests/data/test-diff-filter/test13-v1.o: Likewise.
* tests/data/test-diff-filter/test2-v0.cc: Likewise.
* tests/data/test-diff-filter/test2-v0.o: Likewise.
* tests/data/test-diff-filter/test2-v1.cc: Likewise.
* tests/data/test-diff-filter/test2-v1.o: Likewise.
* tests/data/test-diff-filter/test4-v0.cc: Likewise.
* tests/data/test-diff-filter/test4-v0.o: Likewise.
* tests/data/test-diff-filter/test4-v1.cc: Likewise.
* tests/data/test-diff-filter/test4-v1.o: Likewise.
* tests/data/test-diff-filter/test9-v0.o: Likewise.
* tests/data/test-diff-filter/test9-v1.cc: Likewise.
* tests/data/test-diff-filter/test9-v1.o: Likewise.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Fix mangled name setting for static data members from DWARF
* src/abg-dwarf-reader.cc (build_var_decl): Support adding
properties to an existing var_decl. For now just add mangled
name.
(build_ir_node_from_die): Accept DW_TAG_member too. This helps
for when this function is used to add additional properties to an
existing DW_TAG_member representing a static data member. Then,
use build_var_decl to really add the value of the additional
mangled name property.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Always show pretty representation of variables in report
* src/abg-comparison.cc (corpus_diff::report): Display the pretty
representation of the variable, no matter what.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Set "is_in_public_symbol_table" property for vars & fns
* src/abg-dwarf-reader.cc (build_var_decl, build_function_decl):
Set the "is_in_public_symbol_table" property for the variable or
function decl.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Support symbol lookups from ELF
* include/abg-dwarf-reader.h (symbol_type, symbol_binding): New
enums.
(operator<<): Declare new overloads for the new enums above.
(lookup_symbol_from_elf, lookup_public_function_symbol_from_elf):
Declare new entry points.
* src/abg-dwarf-reader.cc (lookup_symbol_from_elf)
(lookup_public_function_symbol_from_elf)
(lookup_public_variable_symbol_from_elf): Define new static
functions.
(read_context::elf_{module_, handle}_): New data members.
(read_context::{elf_module, elf_handle}): New accessors.
(read_context::load_debug_info): Store the elf module into
read_context::_elf_module_. Adjust.
(read_context::{lookup_symbol_from_elf,
lookup_public_function_symbol_from_elf,
lookup_public_variable_symbol_from_elf}): New member functions.
(lookup_symbol_from_elf, lookup_public_function_symbol_from_elf)
(operator<<): Define public entry points.
* tools/bisym.cc: New tool to lookup a symbol in an elf file.
* tools/Makefile.am: Add the bisym.cc source file to the
distribution and arrange to compile it into a 'bisym' executable.
* tests/test-lookup-syms.cc: New test harness.
* tests/data/test-lookup-syms/test0-report.txt: New test input
for the harness above.
* tests/data/test-lookup-syms/test0.cc: Likewise.
* tests/data/test-lookup-syms/test0.o: Likewise
* tests/data/test-lookup-syms/test01-report.txt: Likewise.
* tests/data/test-lookup-syms/test02-report.txt: Likewise.
* tests/Makefile.am: Build the new runtestlookupsyms test and add
the new files to the distribution.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Add corpus::{s,g}et_origin accessors
* include/abg-corpus.h (enum corpus::origin): New enum.
(corpus::{g,s}et_origin): New accessors.
* src/abg-corpus.cc (corpus::priv::origin): New data member.
(corpus::priv::is_symbol_table_built): Move this up.
(corpus::priv::priv): Adjust.
(corpus::{g,s}et_origin): Define accessors.
* src/abg-dwarf-reader.cc (read_corpus_from_elf): Set the corpus
origin. Also set the path. Oops.
* src/abg-reader.cc (read_corpus_from_input)
(read_corpus_from_archive): Set the corpus origin.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Add a get_linkage_name function.
* include/abg-fwd.h (is_at_global_scope): Declare a new overload.
(get_linkage_name): Declare ...
* src/abg-ir.cc (get_linkage_name): ... these new entry points.
(is_at_global_scope): Define these new overloads useful for the
new get_linkage_name.
2014-04-21 Dodji Seketeli <dodji@redhat.com>
Pimplify decl_base and add decl_base::{s,g}et_is_in_public_symbol_table
* include/abg-ir.h (struct decl_base::priv): New pimpl type.
(decl_base::priv_): New pimpl.
(decl_base::{hashing_started, peek_hash_value,
peek_qualified_name, set_qualified_name}): Declare new protected
methods.
(decl_base::{get_context_rel, set_qualified_name, get_location,
set_location, set_name, set_mangled_name, get_visibility,
set_visibility}): Move these out-of-line.
(decl_base::{g,s}et_is_public_symbol_table):
(class_decl::hashing_started): Remove this as we now have
decl_base::hashing_started.
(decl_base::{hash_, hashing_started, location_, context_, name_,
qualified_parent_name_, qualified_name_, mangled_name_,
visibility_}): Move all these members into the new ...
* src/abg-ir.cc (struct decl_base::priv): ... pimpl type.
(decl_base::decl_base): Move these out-of-line here. Adjust the
other overloads.
(decl_base::{hashing_started, peek_hash_value,
peek_qualified_name, set_qualified_name}): Define these new
protected methods.
(decl_base::{get_context_rel, set_context_rel, get_location,
set_location, set_name, get_mangled_name, set_mangled_name,
get_visibility, set_visibility}): Define these out-of-line here.
(decl_base::{get_hash, set_hash, get_scope,
get_qualified_parent_name, get_qualified_name, operator==,
set_scope}): Adjust.
(qualified_type_def::get_qualified_name): Likewise.
(pointer_type_def::get_qualified_name): Likewise.
(reference_type_def::get_qualified_name): Likewise.
(var_decl::set_scope): Likewise.
(class_decl::base_spec): Likewise.
(class_decl::method_decl::set_scope): Likewise.
(decl_base::{g,s}et_is_in_public_symbol_table): Define new accessors.
* src/abg-hash.cc ({decl_base, type_decl, scope_decl,
scope_type_decl, qualified_type_def, pointer_type_def,
reference_type_def, enum_type_decl, typedef_decl, var_decl,
class_decl}::hash::operator): Adjust.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Categorize base class changes as SIZE_OR_OFFSET_CHANGE_CATEGORY
* include/abg-comparison.h (class_diff::{deleted, inserted,
changed}_bases): Declare new member functions ...
* src/abg-comparison.cc ((class_diff::{deleted, inserted,
changed}_bases)): ... and define them.
* src/abg-comp-filter.cc (base_classes_added_or_removed): Define
new static functions.
(harmless_filter): Categorize base classes added or removed.
* tests/data/test-diff-dwarf/test8-report.txt: New test input.
* tests/data/test-diff-dwarf/test8-v0.cc: Likewise.
* tests/data/test-diff-dwarf/test8-v0.o: Likewise.
* tests/data/test-diff-dwarf/test8-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test8-v1.o: Likewise.
* tests/data/test-diff-filter/test13-report.txt: New test input.
* tests/data/test-diff-filter/test13-v0.cc: Likewise.
* tests/data/test-diff-filter/test13-v0.o: Likewise.
* tests/data/test-diff-filter/test13-v1.cc: Likewise.
* tests/data/test-diff-filter/test13-v1.o: Likewise.
* tests/Makefile.am: Add the new files above to the source distribution.
* tests/test-diff-dwarf.cc: Use the new relevant input above to
run more tests.
* tests/test-diff-filter.cc: Likewise.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Fix class diff reporting issues for base classes
* src/abg-comparison.cc (class_diff::report): For base classes,
report their pretty representation. Do not try to report a the
diff of a changed base class that got filtered out. Avoid
emitting too many vertical white spaces.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Simplify SIZE_OR_OFFSET_CHANGE_CATEGORY categorizing
* src/abg-comp-filter.cc (harmful_filter::visit): Now that
type_size_changed is correctly geared to not be fulled by
decl-only classes, there is no need for its caller to handle that
case. And data_member_offset_changed ain't affected by decl-only
classes anyway. So the code is now much simpler.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Fix API doc for static_data_member_type_size_changed
* src/abg-comp-filter.cc (static_data_member_type_size_changed):
Fix API doc comment.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Don't blindly drop DIEs defined in the scope of a function
* src/abg-dwarf-reader.cc (get_scope_for_die): Do not drop a DIE
on the floor just because it is in the scope of a function. We
were dropping a function parameter because its type is a typedef
defined right before the parameter, in the scope of the function.
Urgh. So with this change, that function parameter is not dropped
anymore. I have seen that happening in a DWARF generated by GCC
4.7.1 on libstdc++.so. Hard to come up with a regression test
case for this one.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Useless code killing
* src/abg-comparison.cc (decls_equal::operator()(const decls_type,
const decls_type)): Kill dead code. Note that there is a proper
equality operator for decl_base_sptr already.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
File static data member changes in STATIC_DATA_MEMBER_CHANGE_CATEGORY
* include/abg-comparison.h
(diff_category::STATIC_DATA_MEMBER_CHANGE_CATEGORY): New category.
(diff_category::EVERYTHING_CATEGORY): Update
* src/abg-comp-filter.cc (static_data_member_type_size_changed)
(static_data_member_added_or_removed): Define new static
functions.
(harmless_filter::visit): Categorize changes to static data
members as STATIC_DATA_MEMBER_CHANGE_CATEGORY.
* tools/bidiff.cc (set_diff_context_from_opts):
STATIC_DATA_MEMBER_CHANGE_CATEGORY is falls into the harmless
group.
* tests/data/test-diff-filter/test12-report.txt: New test input.
* tests/data/test-diff-filter/test12-v0.cc: Likewise.
* tests/data/test-diff-filter/test12-v0.o: Likewise.
* tests/data/test-diff-filter/test12-v1.cc: Likewise.
* tests/data/test-diff-filter/test12-v1.o: Likewise.
* tools/bidiff.cc: Run this test with the additional input data
above.
* tests/Makefile.am: Adjust.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Fix typo in comments
* include/abg-comparison.h
(diff_category::NON_VIRT_MEM_FUN_CHANGE_CATEGORY): Fix typo in
comments.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Only non-static data member changes are SIZE_OR_OFFSET_CHANGE_CATEGORY
* src/abg-comp-filter.cc
(non_static_data_member_type_size_changed): Renamed
data_member_offset_changed into this. Make sure the test detects
changes on *non-static* data members only.
(non_static_data_member_added_or_removed): Likewise for
data_member_offset_changed that got renamed into this.
(harmful_filter::visit): Adjust.
2014-04-17 Dodji Seketeli <dodji@redhat.com>
Fix comments in categorization code
* src/abg-comp-filter.cc (data_member_added_or_removed): Fix
comments.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Really detect static-ness of data members. Oops.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Let's
consider that a data member being not laid out (i.e, not having a
data_member_location) is is a static data member. Otherwise, we
were not detecting static data members at all. Well we were only
inferring their presence from seeing the static variable
definition later on. That means we were missing most of the
static variables. Woops.
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Now that we
are really seeing static data members, let's be prepare to the
fact that we can the same static data member being declared
several times in a corpus.
* tests/data/test-diff-dwarf/test7-report.txt: New test input file.
* tests/data/test-diff-dwarf/test7-v0.cc: Likewise.
* tests/data/test-diff-dwarf/test7-v0.o: Likewise.
* tests/data/test-diff-dwarf/test7-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test7-v1.o: Likewise.
* tests/test-diff-dwarf.cc: Update this to consume the new test
input files.
* tests/Makefile.am: Update this to add the missing test files to
the source distribution.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Add dumping routines for declaration location
* include/abg-fwd.h (get_global_scope()): New overload for const
decl_base&. Move the other overloads up in the file.
(get_translation_unit): Add an overload for decl_base&. Constify
the others.
(dump_decl_location): Declare new functions.
* src/abg-ir.cc (get_global_scope): Define the overload for const
decl_base&. Write the other overloads in terms of this one.
(get_translation_unit): Likewise, define the overload for const
decl_base&. Write the other overloads in terms of this one.
(dump_decl_location): Define these new overloads.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Fix dumping function to make them use generic ostream
* src/abg-writer.cc (dump(const decl_base_sptr, std::ostream&)):
Do not dump the content to cerr here. Rather dump to the output
stream given in parameter. Oops.
(dump(const translation_unit&, std::ostream&)): Likewise.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-ir.cc (get_translation_unit): Remove useless vertical
white space.
(is_global_scope): Add missing API doc.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
A virt mem fn deleted and added to the same offset is not harmful
* src/abg-comp-filter.cc (has_virtual_mem_fn_change): A virtual
member that gets deleted and added back again to the same vtable
offset is not considered as being a virtual member function change
suitable for VIRTUAL_MEMBER_CHANGE_CATEGORY. Likewise for a
function sub-type change not involving a change in the vtable
offset.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Do not categorize size/offset changes when a decl-only class is involved
* src/abg-comp-filter.cc (there_is_a_decl_only_class)
(diff_involves_decl_only_class): New static functions.
(type_size_changed, data_member_added_or_removed)
(has_virtual_mem_fn_change, has_non_virtual_mem_fn_change): Bail
out if one of the types involved is a decl-only class.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Work around "mangled name vanishing from one version of mem fn decl" bug
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): If the first version
of the member function decl doesn't have a mangled name while the
second has it, try the lookups using the pretty representation of
the function.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Do not try to represent the offset for a static data member
* src/abg-comparison.cc (represent_data_member(var_decl_sptr,
ostream&)): If the data member is static, do not try to represent
its offset.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
A static data member shouldn't be checked for having been laid out
* src/abg-comparison.cc (represent_data_member(var_decl_sptr,
ostream&)): If the data member is static do not check for it
having been laid out.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Prefix pretty representation of static data members with 'static'
* src/abg-ir.cc (var_decl::get_pretty_representation): Prefix
pretty representation of static data members with 'static'.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Provide a robust way of getting the size of a qualified type
* include/abg-ir.h (qualified_type_def::get_size_in_bits): Declare
new member function ...
* src/abg-ir.cc (qualified_type_def::get_size_in_bits): ... and
define it. Keep in mind that some times the size of the
underlying type can change between the moment the qualified type
is created and the end of its life time. That is because a
subsequent DIE (from DWARF) can alter the size of the underlying
type. This overload allows the user to always query the size of
the underlying type and keep the size of the qualified type in
sync with it.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Add an assert to the pointer diff reporting code
* src/abg-comparison.cc (pointer_diff::report): If the pointer
diff node is deemed to be reported then the underlying diff node
should be reported as well.
2014-04-16 Dodji Seketeli <dodji@redhat.com>
Little style adjustment in diff node categorization code
* src/abg-comp-filter.cc (harmful_filter::visit): Factorize the
categorization into SIZE_OR_OFFSET_CHANGE_CATEGORY for data member
adding or removal and for data member type size change.
2014-04-15 Dodji Seketeli <dodji@redhat.com>
If a diff node is in NO_CHANGE_CATEGORY do not report it anymore
* src/abg-comparison.cc (diff::is_filtered_out): Now that we seem
to be flagging every changes to a class into a category, we do not
need to dive into reporting a diff not that is categorized as
NO_CHANGE_CATEGORY anymore. So let's have the implementation that
one would expect for this function.
2014-04-15 Dodji Seketeli <dodji@redhat.com>
Categorize changes to virt mem fncts as VIRTUAL_MEMBER_CHANGE_CATEGORY
* src/abg-comp-filter.cc (has_virtual_mem_fn_change): New static
function.
(harmful_filter): Categorize changes to virtual member functions
into VIRTUAL_MEMBER_CHANGE_CATEGORY.
* src/abg-comparison.cc
(class_diff::priv::count_filtered_changed_dm): Move this up, right
after class_diff::priv::count_filtered_subtype_changed_dm.
(SKIP_MEM_FN_IF_VIRTUALITY_DISALLOWED): New macro.
(class_diff::priv::count_filtered_{changed, inserted,
deleted}_mem_fns): Modify these to properly take member function
virtual-ness in account.
2014-04-15 Dodji Seketeli <dodji@redhat.com>
Do not hash non-virtual member functions when hashing a class
* src/abg-hash.cc (class_decl::hash::operator): Do not hash
non-virtual member functions.
2014-04-15 Dodji Seketeli <dodji@redhat.com>
Fix a missing new line in the reports
* src/abg-comparison.cc (represent(class_decl::method_decl_sptr,
ostream&)): Add a missing new line.
* tests/data/test-bidiff/test-struct1-report.txt: Adjust.
2014-04-14 Dodji Seketeli <dodji@redhat.com>
Add more pretty printing facilities
* include/abg-comparison.h (get_pretty_representation(diff*)):
Declare new function.
* include/abg-fwd.h (get_pretty_representation): Declare functions
for decl_base*, type_base*, decl_base_sptr and type_base_sptr.
* src/abg-comparison.cc (get_pretty_representation): Implement
this for diff*.
* src/abg-ir.cc (get_pretty_representation): Define
implementations for decl_base*, type_base*, decl_base_sptr and
type_base_sptr.
2014-04-14 Dodji Seketeli <dodji@redhat.com>
Don't compare non-virtual member functions in class comparison
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Use the virtual
member functions here, not the member functions in general.
(compute_diff): Consider virtual member functions only, not
non-virtual ones.
* src/abg-ir.cc (class_decl::operator==): Do not compare
non-virtual member functions. Only compare virtual member
functions.
* tests/data/test-bidiff/test-struct1-report.txt: New test input.
* tests/data/test-diff-dwarf/test0-report.txt: New test input.
* tests/data/test-diff-filter/test0-report.txt: New test input.
* tests/data/test-diff-filter/test01-report.txt: New test input.
* tests/data/test-diff-filter/test10-report.txt: New test input.
* tests/data/test-diff-filter/test11-report.txt: New test input.
* tests/data/test-diff-filter/test2-report.txt: New test input.
* tests/data/test-diff-filter/test9-report.txt: New test input.
2014-04-14 Dodji Seketeli <dodji@redhat.com>
Recognize virtual member functions better and store them appart
* include/abg-fwd.h (set_member_function_is_virtual): Declare new
function.
* include/abg-ir.h (class class_decl): Declare
set_member_function_is_virtual and member_function_is_virtual as
friends of class_decl.
(class_decl::add_member_function): Take an is_virtual flag.
(class_decl::get_num_virtual_functions): Remove.
(class_decl::get_virtual_mem_fns): New member function.
(mem_fn_context_rel::is_virtual_): New member.
(mem_fn_context_rel::mem_fn_context_rel): Adjust to initialize the
new is_virtual_ member.
(mem_fn_context_rel::is_virtual): New member functions.
* src/abg-comparison.cc (represent): Adjust.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Adjust.
* src/abg-ir.cc (member_function_is_virtual): Change this to use
mem_fn_context_rel::is_virtual.
(set_member_function_is_virtual): Define this new function.
(class_decl::priv::virtual_mem_fns_): New member to hold virtual
member functions.
(class_decl::get_virtual_mem_fns): Implement this member function.
(class_decl::get_num_virtual_functions): Remove.
(class_decl::add_member_function): Take a new is_virtual flag.
Add virtual member functions to
class_decl::priv::virtual_mem_fns_.
* src/abg-reader.cc (build_class_decl): Adjust.
2014-04-13 Dodji Seketeli <dodji@redhat.com>
Filter non-virtual member fns insertions/deletions from class changes
* include/abg-fwd.h (member_function_is_virtual): Declare new
function.
* include/abg-comparison.h
(diff_category::{NON_VIRT_MEM_FUN_CHANGE_CATEGORY,
VIRTUAL_MEMBER_CHANGE_CATEGORY}): New enumerators.
(diff_category::EVERYTHING_CATEGORY): Adjust.
(class_diff::{changed, deleted, inserted}_member_fns): Declare new
member functions.
* src/abg-comp-filter.cc (data_member_added_or_removed): Add
missing comments.
(has_non_virtual_mem_fn_change): New static predicate function.
(harmless_filter::visit): Categorize non-virtual member function
changes in a diff into NON_VIRT_MEM_FUN_CHANGE_CATEGORY.
* src/abg-comparison.cc
(TRAVERSE_MEM_FN_DIFF_NODE_AND_PROPAGATE_CATEGORY): New macro.
(report_mem_header): Count filtered functions for added/deleted
functions as well.
(class_diff::priv::count_filtered_changed_mem_fns): Renamed
priv::count_filtered_member_functions into this. Filter out
changes to non-virtual member functions here.
(class_diff::priv::count_filtered_{inserted, deleted}_mem_fns):
New member functions.
(class_diff::{deleted, inserted, changed}_member_fns): Define new
member functions.
(class_diff::report): Adjust count for filtered inserted/deleted
member functions. Do not report NON_VIRT_MEM_FUN_CHANGE_CATEGORY
if it's disallowed.
(class_diff::traverse): Propagate only
VIRTUAL_MEMBER_CHANGE_CATEGORY from member functions to their
enclosing class.
* src/abg-ir.cc (member_function_is_virtual): Define new
functions.
* tools/bidiff.cc (set_diff_context_from_opts): Adjust to add
NON_VIRT_MEM_FUN_CHANGE_CATEGORY into the harmless group and
VIRTUAL_MEMBER_CHANGE_CATEGORY into the harmful one.
* tests/data/test-diff-filter/test0-report.txt: New test input.
* tests/data/test-diff-filter/test10-report.txt: Likewise.
* tests/data/test-diff-filter/test10-v0.cc: Likewise.
* tests/data/test-diff-filter/test10-v0.o: Likewise.
* tests/data/test-diff-filter/test10-v1.cc: Likewise.
* tests/data/test-diff-filter/test10-v1.o: Likewise.
* tests/data/test-diff-filter/test11-report.txt: Likewise.
* tests/data/test-diff-filter/test11-v0.cc: Likewise.
* tests/data/test-diff-filter/test11-v0.o: Likewise.
* tests/data/test-diff-filter/test11-v1.cc: Likewise.
* tests/data/test-diff-filter/test11-v1.o: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Likewise.
* tests/data/test-diff-filter/test9-report.txt: Likewise.
* tests/data/test-diff-filter/test9-v0.cc: Likewise.
* tests/data/test-diff-filter/test9-v0.o: Likewise.
* tests/data/test-diff-filter/test9-v1.cc: Likewise.
* tests/data/test-diff-filter/test9-v1.o: Likewise.
* tests/test-diff-filter.cc: Consume the test input above to run
more tests.
2014-04-13 Dodji Seketeli <dodji@redhat.com>
Make class_decl pimpl and harden comparison infloop prevention
* include/abg-ir.h (class_decl::{priv}): New private data member.
(class_decl::{get_is_declaration_only, set_is_declaration_only,
is_struct, get_definition_of_declaration, get_earlier_declaration,
add_base_specifier, get_base_specifiers, get_member_types,
get_data_members, get_member_functions,
get_member_function_templates, get_member_class_templates}): Move
these methods out-of-line.
(class_decl::{comparison_started_,
declaration_,is_declaration_only_, definition_of_declaration,
is_struct_, bases_, member_types_, data_members_,
member_functions_, member_function_template,
member_class_templates_}): Move these data members into the pimpl
in ...
* src/abg-ir.cc
(class_decl::priv::{declaration_,is_declaration_only_,
definition_of_declaration, is_struct_, bases_, member_types_,
data_members_, member_functions_, member_function_template,
member_class_templates_}): ... here.
(class_decl::priv::classes_being_compared_): New data member.
(class_decl::priv::priv): Initialize the data members.
(class_decl::priv::{mark_as_being_compared,
unmark_as_being_compared, comparison_started): New methods.
(class_decl::{get_is_declaration_only, set_is_declaration_only,
is_struct, get_definition_of_declaration, add_base_specifier,
get_base_specifiers, get_member_types, get_data_members,
get_member_functions, get_member_function_templates,
get_member_class_templates}): Move these out-of-line in here.
(class_decl::{class_decl, set_definition_of_declaration,
set_earlier_declaration, insert_member_type, add_member_type,
add_data_member, add_member_function,
add_member_function_template, add_member_class_template,
has_no_base_nor_member}): Adjust.
(class_decl::operator==): Harden inf-loop prevention during class
comparison using the new priv::mark/unmark_as_being_compared()
functions. Now comparison of a class really compares member
functions again. And it is *slooow*. I should probably change
this to compare only virtual member functions. But at least this
should be correct and robust for now.
* tests/data/test-diff-filter/test0-report.txt: Adjust.
* test01-report.txt: Adjust.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Remove the parent member of the diff node
* include/abg-comparison.h (diff::parent_): Remove.
(diff::diff): Adjust.
(diff::{get, set}_parent): Remove.
* src/abg-comp-filter.cc (harmless_filter::visit): Remove category
propagation to the parent.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Update the decl_base copy constructor for forgotten members
* src/abg-ir.cc (decl_base::decl_base): Copy forgotten decl_base
members hashing_started_, qualified_parent_name_, qualified_name_.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Comment fix in filtering code
* src/abg-comp-filter.cc (harmful_filter::visit): Fix comment
typos.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Put data member type size changes in SIZE_OR_OFFSET_CHANGE_CATEGORY
* src/abg-comp-filter.cc (type_size_changed): New overload for
type_base_sptr.
(data_member_type_size_changed): New predicate.
(harmful_filter::visit): Use the new predicate to categorize data
member type size changes into the SIZE_OR_OFFSET_CHANGE_CATEGORY.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Represent a removed+added data member at a given offset as changed
* include/abg-fwd.h (get_data_member_offset): Declare new overload for
decl_base_sptr.
* include/abg-comparison.h (unsigned_decl_base_sptr_map)
(unsigned_changed_type_or_decl_map): New typedefs.
* src/abg-ir.cc (get_data_member_offset): Define new overload for decl_base_sptr.
* src/abg-comparison.cc (diff_kind::subtype_change_kind): New
enumerator for a change about a type or sub-type of a member of a
structure/enum.
(report_mem_header): Handle the new enumerator above.
(class_diff::priv::{deleted_dm_by_offset_, inserted_dm_by_offset_,
changed_dm_}): New data members.
(class_diff::priv::subtype_changed_dm_): Renamed
class_diff::priv::changed_data_members_ into this.
(class_diff::priv::subtype_changed_dm): Renamed
class_diff::priv::data_member_has_changed into this. Adjust.
(class_diff::count_filtered_subtype_changed_dm): Renamed
count_filtered_data_members into this. Adjust.
(class_diff::priv::count_filtered_changed_dm): New member
function.
(class_diff::lookup_tables_empty): Adjust.
(class_diff::ensure_lookup_tables_populated): Adjust. Detect when
a data member is deleted and added back to offset N, and be
prepared to present that as a change of data member at offset N.
(class_diff::report): Adjust. Report data members of a given
offset that have changed.
* tests/data/test-diff-dwarf/test6-report.txt: New reference
report for new test input.
* tests/data/test-diff-dwarf/test6-v0.cc: Source code for new test
input binary.
* tests/data/test-diff-dwarf/test6-v0.o: New test input binary.
* tests/data/test-diff-dwarf/test6-v1.cc: Source code for new test
input binary.
* tests/data/test-diff-dwarf/test6-v1.o: New test input binary.
* tests/test-diff-dwarf.cc: Adjust to include the new test inputs above.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Unmark class_diff node as being traversed once traversal is finished
* src/abg-comparison.cc (class_diff:traverse): Unmark class_diff
node as being traversed once traversal is finished
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Do not use the parent diff node link for category propagation
* src/abg-comparison.cc (class_diff::traverse): Use the new
TRAVERSE_MEM_DIFF_NODE_AND_PROPAGATE_CATEGORY macro to propagate
categorization from the children diff nodes to the current one for
bases, data members and member functions.
(scope_diff::traverse): Likewise, use the
TRAVERSE_DIFF_NODE_AND_PROPAGATE_CATEGORY to propagate
categorization from the children diff nodes to the current one.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Ensure that each diff node is traversed just once
* include/abg-comparison.cc (pointer_map): New typedef.
(diff_context::{has_diff_for}): New overload for diff*.
(diff_context::{diff_has_been_traversed, mark_diff_as_traversed,
forget_traversed_diffs}): Declare new methods.
* src/abg-comparison.cc (ENSURE_DIFF_NODE_TRAVERSED_ONCE)
(ENSURE_MEM_DIFF_NODE_TRAVERSED_ONCE): Define new macros.
(diff_context::priv::traversed_diff_nodes_): New data member.
(diff_context::has_diff_for): New overload for diff*
(diff_context::{diff_has_been_traversed, mark_diff_as_traversed,
forget_traversed_diffs}): Define new member functions.
(diff_context::maybe_apply_filters): Forget the traversed diffs
before applying a filter.
({distinct_diff, var_diff, pointer_diff, reference_diff,
qualified_type_diff, enum_diff, class_diff, base_diff, scope_diff,
function_decl_diff, type_decl_diff, typedef_diff,
translation_unit_diff}::traverse): Ensure that the diff node is
traversed only once.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Factorize diff sub-tree traversal and category propagation code
* src/abg-comparison.cc
(TRAVERSE_DIFF_NODE_AND_PROPAGATE_CATEGORY)
(TRAVERSE_MEM_DIFF_NODE_AND_PROPAGATE_CATEGORY): New macros.
({distinct_diff, pointer_diff, reference_diff,
qualified_type_diff, enum_diff, base_diff, function_decl_diff,
typedef_diff}::traverse): Use the new macro above in lieu of the
duplicated sub-tree traversal code in there.
2014-04-11 Dodji Seketeli <dodji@redhat.com>
Style fixes in the diff nodes traversing code
* src/abg-comparison.cc (TRY_{PRE, PRO}_VISIT, TRY_{PRE,
PRO}_VISIT_CLASS_DIFF, ): Add a white space.
2014-04-10 Dodji Seketeli <dodji@redhat.com>
Supporting reporting data member name change
* src/abg-comparison.cc (represent): Support reporting data member
name change.
2014-04-10 Dodji Seketeli <dodji@redhat.com>
Consider added/removed data members as changing size or offset
* src/abg-comp-filter.cc (data_member_added_or_removed): New
static function.
(harmless_filter::visit): Re-organize logic. Categorize data
member addition/removal into SIZE_OR_OFFSET_CHANGE_CATEGORY.
2014-04-10 Dodji Seketeli <dodji@redhat.com>
Add missing comment
* src/abg-ir.cc (non_type_tparameter::get_hash): Add missing api doc.
2014-04-09 Dodji Seketeli <dodji@redhat.com>
Fix and add missing hashing through the virtual decl_base::get_hash
* include/abg-ir.h (struct {scope_decl, non_type_tparameter,
type_composition, class_decl}::hash): Declare hashers.
({scope_decl, var_decl, non_type_tparameter, type_composition,
class_decl}::get_hash): Provide new overloads of the get_hash.
* src/abg-hash.cc ({type_decl, scope_type_decl,
qualified_type_def, pointer_type_def, reference_type_def,
enum_type_decl, typedef_decl, var_decl,
function_decl}::hash::operator()): If the hash is being
calculated, do not use the not-yet fully calculated hash value.
Rather, calculate the hash, cache it and return the value.
({class_decl, non_type_tparameter}::hash::operator()): Moved the
{class_decl, non_type_tparameter}::hash declaration out of here
and stick it in include/abg-ir.h. Keep the definition of the
hashing operators here though.
(type_composition::hash::operator()): New operator definition.
* src/abg-ir.cc ({scope_decl, var_decl, class_decl,
non_type_tparameter, type_composition}::get_hash): Define new
virtual overload.
2014-04-08 Dodji Seketeli <dodji@redhat.com>
Fix mis-hashing of base specifiers and function_decl during comparison
* include/abg-ir.h (function_decl::get_hash): Declare new virtual
overload.
* src/abg-hash.cc (class_decl::base_spec::hash::operator()):
Properly hash the base specifier so that it doesn't collide with
hashing a class.
* src/abg-ir.cc (decl_base::get_hash): Abort if we detect a
missing overload for this;
(function_decl::get_hash() const): Implement this missing
overload, allowing using the virtual decl_base::get_hash for
function_decl.
2014-04-08 Dodji Seketeli <dodji@redhat.com>
Properly place opening quote and add missing closing quote in report
* src/abg-comparison.cc (corpus_diff::report): Move the [{A,D}]
marker before the opening quote. And add a closing quote.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test01-report.txt: Adjust.
* tests/data/test-diff-filter/test2-report.txt: Adjust.
2014-04-08 Dodji Seketeli <dodji@redhat.com>
Drive-by indentation fix
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Fix
indentation.
2014-04-08 Dodji Seketeli <dodji@redhat.com>
Drop ABI artifacts that are local to a function
* src/abg-dwarf-reader.cc (get_scope_for_die): If the parent die
is DW_TAG_subprogram then just drop the whole thing on the floor.
(build_ir_node_from_die): When the scope is NULL, just drop the
whole thing on the floor.
2014-04-08 Dodji Seketeli <dodji@redhat.com>
Fix the static data member recognition hack
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir):
When trying to recognize the global var_decl as being definition
variables for static data members, lookup the declaration for the
data member in the relevant class. If found, then just flag the
var_decl for the data member as being static; no need to add a
var_decl as data member in that case, that would duplicate the
data member.
2014-04-08 Dodji Seketeli <dodji@redhat.com>
Fix looking up a node inside a class
* src/abg-ir.cc (lookup_node_in_scope): Do not forget to actually
look at the class members. Sigh.
2014-04-07 Dodji Seketeli <dodji@redhat.com>
Work around old dwarf producers forgetting mangled names for functions
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): If lookup
using mangled name for a deleted function yields nada, try the
lookup with the pretty representation for the function.
2014-04-07 Dodji Seketeli <dodji@redhat.com>
Make type_base::get_{size,alignment}_in_bits virtual
* include/abg-ir.h (type_base::get_{size,alignment}_in_bits): Make
this virtual.
(typedef_decl::get_{size,alignment}_in_bits): Add new member
functions. Get the size,alignment from the underlying type and
update the current size/alignment if they differ. Keep in mind
that the size of an underlying class_decl can change over its
lifetime, given how the dwarf reader reads the type information,
i.e, there can be a DIE for a class type with no size information
that will lead to the creation of a class_decl with size zero.
Later during the DWARF reading process, another DIE will
supplement the type information, adding size information to that
class_decl. In between, a typedef_decl might have been created
with the first version of the class_decl that has a zero size. I
guess this should be extended to the other type constructs that
have an underlying type (qualified types, references and pointers).
2014-04-07 Dodji Seketeli <dodji@redhat.com>
Look through typedefs when setting SIZE_OR_OFFSET_CHANGE_CATEGORY
* include/abg-fwd.h (is_class_type): Declare new functions.
* src/abg-comp-filter.cc (harmful_filter::visit): Use the above to
convert a type into a class.
* src/abg-ir.cc (is_class_type): Define the new function.
2014-04-06 Dodji Seketeli <dodji@redhat.com>
Add a new DECL_NAME_CHANGE_CATEGORY change category
* include/abg-comparison.h (enum
diff_category::DECL_NAME_CHANGE_CATEGORY): New enumerator.
* src/abg-comparison.cc (report_name_size_and_alignment_changes)
({enum, typedef}_diff::report): Adjust to avoid emitting name
change report if the DECL_NAME_CHANGE_CATEGORY category of change
is currently disallowed.
* abg-comp-filter.cc (decl_name_changed): New static function.
(harmless_filter::visit): Detect that the decl name changed and
put the current diff node (and its parents) into the
DECL_NAME_CHANGE_CATEGORY category.
* tools/bidiff.cc (set_diff_context_from_opts): Set the new
DECL_NAME_CHANGE_CATEGORY category into the harmless_changes group
of categories.
* tests/data/test-diff-filter/test6-report.txt: New test input file.
* tests/data/test-diff-filter/test6-v0.cc: Likewise.
* tests/data/test-diff-filter/test6-v0.o: Likewise.
* tests/data/test-diff-filter/test6-v1.cc: Likewise.
* tests/data/test-diff-filter/test6-v1.o: Likewise.
* tests/data/test-diff-filter/test7-report.txt: Likewise.
* tests/data/test-diff-filter/test7-v0.cc: Likewise.
* tests/data/test-diff-filter/test7-v0.o: Likewise.
* tests/data/test-diff-filter/test7-v1.cc: Likewise.
* tests/data/test-diff-filter/test7-v1.o: Likewise.
* tests/test-diff-filter.cc: Take the new inputs above to run new tests.
* tests/Makefile.am: Add the new files above to the distribution.
2014-04-05 Dodji Seketeli <dodji@redhat.com>
Emit qualified name for typedefs
* src/abg-comparison.cc (typedef_diff::report): Emit qualified
names for typedefs in diff reports about typedef name changes.
2014-04-05 Dodji Seketeli <dodji@redhat.com>
Fix indentation in distinct type diff report
* src/abg-comparison.cc (distinct_diff::report): Do not forget to
change line.
2014-04-05 Dodji Seketeli <dodji@redhat.com>
Really compare return types for function types
* src/abg-ir.cc (compare_function_types): Compare return types,
unless this is a method and the return type is the same type as
the containing class type.
* tests/data/test-diff-dwarf/test5-report.txt: Reference report
for the comparison of the two input binaries below.
* tests/data/test-diff-dwarf/test5-v0.cc: Source code for the
input binary below.
* tests/data/test-diff-dwarf/test5-v0.o: Test input binary.
* tests/data/test-diff-dwarf/test5-v1.cc: Source code for the
input binary below.
* tests/data/test-diff-dwarf/test5-v1.o: Test input binary.
2014-04-05 Dodji Seketeli <dodji@redhat.com>
Add missing tests for previous commits
* tests/data/test-diff-dwarf/test4-report.txt: Adjust.
* tests/test-diff-dwarf.cc: Run tests for
data/test-diff-dwarf/test3-report.txt" and
data/test-diff-dwarf/test4-report.txt.
2014-04-05 Dodji Seketeli <dodji@redhat.com>
Categorize through compatible distinct type diffs
* src/abg-comparison.cc (report_size_and_alignment_changes): Split
this static function out of ...
(report_name_size_and_alignment_changes): ... this one.
(distinct_diff::report): If the typedef-stripped variants of the
diff subjects are of the same kind, display their diff.
Otherwise, tell explicitly is the distinct type diff involves a
type size change.
(distinct_diff::traverse): If the typedef-stripped variants of the
diff subjects are of the same kind, traverse that underlying diff
sub-tree and propagate the categorizing possibly resulting from
that traversal.
* tests/data/test-diff-dwarf/test4-v0.o: New test input binary.
* tests/data/test-diff-dwarf/test4-v0.cc: Source code for the
input binary above.
* tests/data/test-diff-dwarf/test4-v1.o: New test input binary.
* tests/data/test-diff-dwarf/test4-v1.cc: Source code for the
input binary above.
* tests/data/test-diff-dwarf/test4-report.txt: Reference report
for the difference between the two binaries above.
* tests/data/test-diff-filter/test5-v0.o: New test input binary.
* tests/data/test-diff-filter/test5-v0.cc: Source code for the
input binary above.
* tests/data/test-diff-filter/test5-v1.o: New test input binary.
* tests/data/test-diff-filter/test5-v1.cc: Source code for the
input binary above.
* tests/data/test-diff-filter/test5-report.txt: Reference report
for the difference between the two binaries above.
* tests/test-diff-filter.cc: Adjust to produce a filtered diff for
the two input binaries above.
* tests/Makefile.am: Adjust to add missing test files to the
distribution.
2014-04-04 Dodji Seketeli <dodji@redhat.com>
Slight run-by fixes
* src/abg-comparison.cc
(corpus_diff::priv::apply_filters_and_compute_diff_stats)
(corpus_diff::report): Use compute_diff for types which it has an
overload rather than going through the compute_diff_for_decls that
would use dynamic casting.
2014-04-04 Dodji Seketeli <dodji@redhat.com>
Do not hook type diff nodes to a parent
* abg/comparison.cc (var_diff::var_diff): Do not set parent node
for the type diff of the var_diff.
(var_diff::traverse): Handle category propagation from the
type diff node to the var_diff node.
(pointer_diff::underlying_type_diff)
(reference_diff::underlying_type_diff)
(qualified_type_diff::underlying_type_diff, enum_diff::enum_diff)
(base_diff::get_underlying_class_diff)
(typedef_diff::underlying_type_diff): Do not set the parent node
here.
({pointer_diff, reference_diff, qualified_type, enum_diff,
class_diff, base_diff, function_decl_diff,
typedef_diff}::traverse): Handle category propagation here.
* tests/data/test-diff-filter/test4-v0.o: New input binary.
* tests/data/test-diff-filter/test4-v0.cc: Source code for the
input binary above.
* tests/data/test-diff-filter/test4-v1.o: New input binary.
* tests/data/test-diff-filter/test4-v1.cc: Source code for the
input binary above.
* tests/data/test-diff-filter/test4-report.txt: Reference diff
report for the input binaries above.
* tests/test-diff-filter.cc:: Run bidiff --no-harmless on the
binaries above.
2014-04-04 Dodji Seketeli <dodji@redhat.com>
Fix off-by one comparison bug in comparing function parameters
* src/abg-comparison.cc
(function_decl_diff::ensure_lookup_tables_populated): Function
parameters that are diff'ed start at the first non-implicit
parameter, not at the first parameter. Oops.
* tests/data/test-diff-dwarf/test3-v0.o: New test input binary.
* tests/data/test-diff-dwarf/test3-v0.cc: Source code for the
binary above.
* tests/data/test-diff-dwarf/test3-v1.o: New test input binary.
* tests/data/test-diff-dwarf/test3-v1.cc: Source code for the
binary above.
* tests/data/test-diff-dwarf/test3-report.txt: Reference report
for the diff of the new test inputs.
* tests/test-diff-dwarf.cc: Use the test inputs above to run new
tests.
2014-04-03 Dodji Seketeli <dodji@redhat.com>
Do not forget parm sub-type changes as opposed to parm changes
* src/abg-comparison.cc
(function_decl_diff::ensure_lookup_tables_populated): A parm
change is valid only when the added parm has a different name from
the removed parm. Both have the same index, of course. In that
case, do not try to remove the corresponding parm sub-type change.
* tests/data/test-bidiff/test-enum0-report.txt: Adjust.
* tests/data/test-bidiff/test-enum1-report.txt: Adjust.
* tests/data/test-bidiff/test-qual-type0-report.txt: Adjust.
* tests/data/test-bidiff/test-struct0-report.txt: Adjust.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
* tests/data/test-diff-dwarf/test1-report.txt: Adjust.
* tests/data/test-diff-filter/test0-report.txt: Adjust.
* tests/data/test-diff-filter/test01-report.txt: Adjust.
* tests/data/test-diff-filter/test1-report.txt: Adjust.
* tests/data/test-diff-filter/test2-report.txt: Adjust.
* tests/data/test-diff-filter/test3-report.txt: Adjust.
2014-04-03 Dodji Seketeli <dodji@redhat.com>
Remove useless white space
* src/abg-ir.cc (look_through_decl_only_class): Remove useless
white space.
2014-04-02 Dodji Seketeli <dodji@redhat.com>
Use mangled name for decl comparison when it's present
* src/abg-ir.cc (decl_base::operator==(const decl_base& other)
const): Use the mangled name of the decl in priority.
* src/abg-hash.cc (struct decl_base::hash::operator()): Likewise.
* src/abg-comparison.cc (function_decl_diff::report): Do not
report a function name change if it doesn't involve a mangled name
change. This might change when we start dealing with templates.
2014-04-02 Dodji Seketeli <dodji@redhat.com>
A change involving a decl-only class is not SIZE_OR_OFFSET_CHANGE_CATEGORY
* src/abg-comp-filter.cc (harmful_filter::visit): If a size change
involves a decl-only class, it certainly shouldn't trigger putting
the sub-tree into the SIZE_OR_OFFSET_CHANGE_CATEGORY category.
2014-04-02 Dodji Seketeli <dodji@redhat.com>
Fix heuristics to detect function static-ness for DWARF < 3
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Make
the heuristics work for functions with no parameters.
2014-04-02 Dodji Seketeli <dodji@redhat.com>
Avoid emitting local filtered-out changes in more spots
* src/abg-comparison.cc (maybe_report_diff_for_member): Take the
diff_context in parameter. Use that to check if local changes of
category ACCESS_CHANGE_CATEGORY are filtered-out and do not report
the change in that case.
({var_diff, enum_diff, class_diff, base_diff,
function_decl_diff}::report): Adjust.
2014-04-02 Dodji Seketeli <dodji@redhat.com>
Add a COMPATIBLE_TYPE_CHANGE_CATEGORY to bidiff --no-harmless
* include/abg-comparison.h
(diff_category::COMPATIBLE_TYPE_CHANGE_CATEGORY): New enumerator.
(operator|=(diff_category&, diff_category)): New declaration.
* include/abg-fwd.h (is_typedef, strip_typedef)
(types_are_compatible): New declarations.
* include/abg-ir.h (operator==(const decl_base_sptr, const
decl_base_sptr)): Added the consts here.
(operator==(const type_base_sptr, const type_base_sptr)): New
declaration.
* src/abg-comp-filter.cc (is_compatible_change): New static
function.
(harmless_filter::visit): Detect compatible changes and add the
sub-tree into the new COMPATIBLE_TYPE_CHANGE_CATEGORY if
applicable. Cleanup the logic.
* src/abg-comparison.cc (operator|=(diff_category&,
diff_category)): Define new function.
(operator==(const decl_base_sptr l, const decl_base_sptr r)): Add
consts.
(operator==(const type_base_sptr l, const type_base_sptr r)):
Define new operator.
(is_typedef, strip_typedef, types_are_compatible): New function
definitions.
* tests/data/test-diff-filter/test3-report.txt: New test report
reference.
* tests/data/test-diff-filter/test3-v0.cc: Source code for new
test input.
* tests/data/test-diff-filter/test3-v0.o: New test input.
* tests/data/test-diff-filter/test3-v1.cc: Source code for new
test input.
* tests/data/test-diff-filter/test3-v1.o: New test input.
* tests/test-diff-filter.cc: Adjust to consume the new tests
inputs above.
* tools/bidiff.cc: Add the new COMPATIBLE_TYPE_CHANGE_CATEGORY
into the --harmless group.
2014-04-01 Dodji Seketeli <dodji@redhat.com>
Don't emit local filtered-out changes
* src/abg-comparison.cc (represent): For var_decl, do not emit
filtered-out local size/offset/access changes.
(report_name_size_and_alignment_changes): Take the diff context.
Do not report filtered-out local size/offset changes.
({var_diff, enum_diff, class_diff, type_decl_diff}::report):
Adjust.
* test0-report.txt: Adjust.
* test01-report.txt: New reference report for the same inputs
test0-v{1,0}.o, but called without the --no-harmless command line.
* tests/data/test-diff-filter/test2-v0.cc: Source code for new test input.
* tests/data/test-diff-filter/test2-v1.cc: Likewise.
* tests/data/test-diff-filter/test2-v0.o: New test input.
* tests/data/test-diff-filter/test2-v1.o: Likewise.
* tests/data/test-diff-filter/test2-report.txt: Reference report
for new test input.
* tests/test-diff-filter.cc: Consume the test inputs above.
* tests/Makefile.am: Add the new test inputs above to the
distribution.
2014-04-01 Dodji Seketeli <dodji@redhat.com>
Compact & intuitive reporting for changed function parameters
* include/abg-comparison.h (unsigned_changed_parm_map)
(unsigned_parm_map): New typedefs.
* src/abg-comparison.cc
(function_decl_diff::subtype_changed_parms): Renamed this from
changed_parms.
(function_decl_diff::priv::subtype_changed_parms_}): Renamed this
from changed_parms_;
(function_decl_diff::priv::{deleted_parms_by_id_,
added_parms_by_id_, changed_parms_by_id_}): New members.
(function_decl_diff::ensure_lookup_tables_populated): Update the
new priv::changed_parms_by_id_ member to contain the parameters
that got changed, as opposed to the subtype_changed_parms_ member
that contain parameters that got a sub-type change. The other
priv::*_by_id_ members are helpers for this. Update them too.
(function_decl_diff::subtype_changed_parms): Renamed this from
::changed_parms.
(function_decl_diff::report): Report separately about parameters
having a sub-type change, and parameters that got changed. Note
that in both cases, the change is necessarily to a compatible
type.
* data/test-diff-dwarf/test2-v0.cc: New test file.
* data/test-diff-dwarf/test2-v0.o: Likewise.
* data/test-diff-dwarf/test2-v1.cc: Likewise.
* data/test-diff-dwarf/test2-v1.o: Likewise.
* data/test-diff-dwarf/test2-report.txt: Likewise.
* tests/Makefile.am: Add the new test files above to the
distribution.
* tests/test-diff-dwarf.cc: Consume the input files above to
actually perform a regression test.
2014-03-31 Dodji Seketeli <dodji@redhat.com>
Fix thinko class_diff traversing.
* src/abg-comparison.cc (class_diff::traverse): Fix thinking in
introduced by commit "6709478 Fix infinite loop when traversing
classes and their members"
* tests/data/test-diff-filter/test1-v{0,1}.o: New test binary input files.
* tests/data/test-diff-filter/test1-v{0,1}.cc: Source code for the
above.
* tests/data/test-diff-filter/test1-report.txt: Reference report
for the diffing of the two binary input files above.
* tests/test-diff-filter.cc: Make the test run on the new input above.
* tests/Makefile.am: Add the new material to the distribution.
2014-03-31 Dodji Seketeli <dodji@redhat.com>
Add forgotten test output adjustment
* tests/data/test-diff-filter/test0-report.txt: Adjust for the
commit "a8d5284 Fix diff report indentation issue"
* tests/data/test-diff-dwarf/test{0,1}-report.txt: Likewise.
2014-03-31 Dodji Seketeli <dodji@redhat.com>
Add forgotten source file for binary test input
* tests/data/test-diff-dwarf/test1-v0.cc: New file.
* tests/data/test-diff-dwarf/test1-v1.cc: Likewise.
2014-03-31 Dodji Seketeli <dodji@redhat.com>
Fix diff report indentation issue
* abg-comparison.cc (corpus_diff::report): Indent the details of
function changes.
2014-03-31 Dodji Seketeli <dodji@redhat.com>
Fix infinite loop when traversing classes and their members
* src/abg-comparison.cc (TRY_{PRE,POST}_VISIT_CLASS_DIFF): New
macros.
(class_diff::priv::traversing_): New flag.
(class_diff::priv::priv): New constructor to initialize the new
flag above.
(class_diff::traversing): Do not traverse the diff again if it's
being traversed already.
2014-03-31 Dodji Seketeli <dodji@redhat.com>
Fix access_changed and data_member_offset_changed predicates
* src/abg-comp-filter.cc (access_changed)
(data_member_offset_changed): Fix detection of membership.
2014-03-29 Dodji Seketeli <dodji@redhat.com>
Take filtering in account in diff stats & better categorizing
* include/abg-comparison.h
(diff_category::ACCESS_CHANGE_CATEGORY): Renamed
ACCESS_CHANGED_CATEGORY into this.
(diff_category::SIZE_OR_OFFSET_CHANGE_CATEGORY): Renamed
SIZE_CHANGED_CATEGORY into this. Changed its semantics to
incorporate offset changes as well.
* src/abg-comparison.cc (struct noop_deleter): Move this up.
(represent): Do not report filtered out data members.
(report_mem_header): Add a new num_filtered parameter to take
filtered-out members in account in members report headers.
Adjust.
(class_diff::priv::{count_filtered_bases,
count_filtered_data_members, count_filtered_member_functions}):
New member functions. When a member is filtered, do not report
it all.
({enum_diff, class_diff}::report): Adjust. Take filtered members
into account in headers.
(corpus_diff::priv::apply_filters_and_compute_diff_stats): New
member function.
(corpus_diff::priv::emit_diff_stats): Renamed
emit_corpus_diff_stats into this. Change it to take the stats in
parameter.
(corpus_diff::report): Adjust to re-use the above. Filter
varibles as well. Take the filtered functions & variables in
account in the stats. Do not report filtered-out functions &
variables at all.
* src/abg-comp-filter.cc (type_size_changed, access_changed)
(data_member_offset_changed): New predicates.
({harmless, harmful}_filter::visit): Adjust to use the new
predicates above. Update the harmful variant for the new
SIZE_OR_OFFSET_CHANGE_CATEGORY category.
* tools/bidiff.cc (set_diff_context_from_opts): Adjust for the
categories name changes.
* tests/data/test-diff-filter/test0-report.txt: New test input.
* tests/data/test-diff-filter/test0-v0.cc: Likewise.
* tests/data/test-diff-filter/test0-v0.o: Likewise.
* tests/data/test-diff-filter/test0-v1.cc: Likewise.
* tests/data/test-diff-filter/test0-v1.o: Likewise.
* tests/test-diff-filter.cc: New test harness.
* tests/Makefile.am: Add the new test files above to the
distribution.
2014-03-29 Dodji Seketeli <dodji@redhat.com>
Fix var_diff length determination
* src/abg-comparison.cc (var_diff::length): Just compare the two
diff subjects.
2014-03-29 Dodji Seketeli <dodji@redhat.com>
Fix typos in the test-diff-dwarf.cc source code
* tests/test-diff-dwarf.cc: Fix various typos.
2014-03-27 Dodji Seketeli <dodji@redhat.com>
Initial implementation of diff tree node filtering
* include/abg-comp-filter.h: New file.
* include/Makefile.am: Add the new include/abg-comp-filter.h to
the source distribution.
* include/abg-comparison.h (enum visiting_kind, diff_category): New enums.
(operator|): Declare new operator declaration for the new
visiting_kind enum.
(operator{|,^,&,~}): Declare new operator decl for the new
diff_category enum.
(diff_context::{get_allowed_category, set_allowed_category,
switch_categories_on, switch_categories_off, diff_filters,
add_diff_filter, maybe_apply_filters}): Declare new member functions.
(diff::{parent_, category_}): New members.
(diff::diff): Adjust.
(diff::{get_parent, set_parent, get_category, add_to_category,
is_filtered_out, to_be_reported}): New members.
(diff_node_visitor::{get_visiting_kind, set_visiting_kind}): New
members.
(diff_node_visitor::visit): Add a new flag to saying if the
visitor is being called in post or pre children traversing mode.
* src/abg-comparison.cc (operator|): Declare new operator
declaration for the new visiting_kind enum.
(operator{|,^,&,~}): Declare new operator decl for the new
diff_category enum.
(diff_context::priv::{allowed_category_, filters_}): New members.
(diff_context::diff_context): Add all known filters.
(diff_context::{get_allowed_category, set_allowed_category,
switch_categories_on, switch_categories_off, diff_filters,
add_diff_filter, maybe_apply_filters}): Define new member
functions.
(diff::{is_filtered_out, to_be_reported}): Define new members.
(*::report): Use the new diff::to_be_reported function.
(*::traverse): Adjust for pre/post visiting.
(var_diff::var_diff): Chain the type diff node to its parent.
({pointer_diff, reference_diff, qualified_type_diff,
typedef_diff}::underlying_type_diff): Chain the underlying type
diff node to its parent.
(enum_diff::enum_diff): Likewise.
(base_diff::underlying_class_diff): Likewise.
({class_diff, corpus_diff}::report): Do not report changed
(member) functions that have been filtered out. Rather report
that they have been filtered out.
({function_decl_diff, class_diff}::traverse): Chain underlying
type diff nodes to their parent.
(diff_node_visitor::visit): Add a new flag to saying if the
visitor is being called in post or pre children traversing mode.
Make sure to call the default diff::visit overload.
* src/abg-comp-filter.cc: New file.
* src/Makefile.am: Add the new abg-comp-filter.cc to the source
distribution.
* tools/bidiff.cc (options::show_harm{ful,less}_changes): New
members.
(display_usage): Add usage strings for --no-harmless and
--no-harmful options.
(parse_command_line): Parse --no-harmless and --no-harmful command
line options.
(set_diff_context_from_opts): Populate the diff context
accordingly.
2014-03-26 Dodji Seketeli <dodji@redhat.com>
Add missing headers double inclusion guards
* include/abg-comparison.h: Add a missing double inclusion guard.
* include/abg-diff-utils.h: Likewise.
2014-03-26 Dodji Seketeli <dodji@redhat.com>
Add a missing apostrophe to access reporting
* src/abg-comparison.cc (represent): For member var_decls, add a
missing apostrophe after the access.
* tests/data/test-diff-dwarf/test0-report.txt: Update test report.
2014-03-21 Dodji Seketeli <dodji@redhat.com>
Fix diff emptiness detection for function_decl_diff nodes
* src/abg-comparison.cc (function_decl_diff::length): Just compare
the two functions here, damit.
* tests/data/test-diff-dwarf/test0-report.txt: Adjust.
2014-03-21 Dodji Seketeli <dodji@redhat.com>
Fixlets in the bidiff regression testing harness
* tests/test-bidiff.cc (main): Fix a typo. Fix the path to the
output path.
2014-03-21 Dodji Seketeli <dodji@redhat.com>
Initial regression test for dwarf diffing
* tests/test-diff-dwarf.cc: New dwarf diffing regression test
harness.
* tests/data/test-diff-dwarf/test0-report.txt: New test input.
* tests/data/test-diff-dwarf/test0-v0.cc: Likewise.
* tests/data/test-diff-dwarf/test0-v0.o: Likewise.
* tests/data/test-diff-dwarf/test0-v1.cc: Likewise.
* tests/data/test-diff-dwarf/test0-v1.o: Likewise.
* tests/Makefile.am: Add the new test inputs from
tests/test-diff-dwarf.cc and tests/data/test-diff-dwarf/* to
the build system.
2014-03-21 Dodji Seketeli <dodji@redhat.com>
Rename test-walker.cc into test-ir-walker.cc
* tests/test-ir-walker.cc: Renamed test-walker.cc into this.
* tests/Makefile.am: Adjust. The generated binary is now testirwalker.
2014-03-21 Dodji Seketeli <dodji@redhat.com>
Initial diff tree traversal infrastructure
* include/abg-comparison.h (struct diff_traversable_base, struct
diff_node_visitor): New type.
(class diff): Extends the new diff_traversable_base.
({diff, distinct_diff, var_diff, pointer_diff, reference_diff,
qualified_type_diff, enum_diff, class_diff, base_diff, scope_diff,
function_decl_diff, type_decl_diff, typedef_diff,
translation_unit_diff, corpus_diff}::traverse): New methods.
(function_decl_diff::return_type_diff): New accessor. Renamed
return_diff into this.
(translation_unit_diff::{first, second}_translation_unit): New
accessors.
(corpus_diff::{deleted, added, changed}_functions): New accessors.
* src/abg-comparison.cc ({distinct_diff, var_diff,
pointer_diff, reference_diff, qualified_type_diff, enum_diff,
class_diff, base_diff, scope_diff, function_decl_diff,
type_decl_diff, typedef_diff, translation_unit_diff,
corpus_diff}::traverse): New function implementations.
(maybe_report_diff_for_member): Renamed
maybe_report_diff_for_class_members into this.
(var_diff::report): Adjust.
(struct translation_unit_diff::priv): New private type.
(translation_unit_diff::translation_unit_diff): Instantiate the
new priv_ member.
(translation_unit_diff::{first,second}_translation_unit): New
accessors.
(corpus_diff::{deleted, added, changed}_functions): New function
implementations.
(diff_node_visitor::visit): New function implementations.
2014-03-19 Dodji Seketeli <dodji@redhat.com>
Make tree walking preemptive
* include/abg-traverse.h (traversable_base::traversable): Change
the signature of this to return a boolean.
* include/abg-ir.h (ir_traversable_base::traverse): Change the
signature of this to return a boolean.
(*::traverse): Adjust.
(ir_node_visitor::visit): Change the signature of this to return a
boolean.
* src/abg-corpus.cc (symtab_build_visitor_type::visit): Adjust.
* src/abg-ir.cc (::traverse): Adjust.
* tests/test-walker.cc (name_printing_visitor::visit): Adjust.
2014-03-26 Jonathan Wakely <jwakely@redhat.com>
Fix comment typos
* include/abg-diff-utils.h (compute_diff): Fix typo in apidoc
comment.
2014-03-24 Dodji Seketeli <dodji@redhat.com>
Follow DW_AT_abstract_origin and add missing mangled name
* src/abg-dwarf-reader.cc (build_function_decl): Change signature
to take function_decl to which one shall add properties that got
added by subsequent DIEs later.
(build_class_type_and_add_to_ir): Adjust.
(build_function_decl): Allow adding new properties to an existing
function_decl. Add the mangled name in particular.
* tests/data/test-read-dwarf/test1.abi: Update test.
2014-03-20 Dodji Seketeli <dodji@redhat.com>
Fix destructor naming.
* src/abg-ir.cc (function_decl::get_pretty_representation): In
DWARF at least, the destructor function name already contains the
'~'. No need to add it.
2014-03-20 Dodji Seketeli <dodji@redhat.com>
Better static function determination heuristic
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Better
heuristic.
2014-03-20 Dodji Seketeli <dodji@redhat.com>
Dynamically wire class_decl::base_spec hashing
* include/abg-ir.h (decl_base::get_hash): Make this virtual.
(class_decl::base_spec::get_hash): Declare a new virtual overload.
* src/abg-ir.cc (class_decl::base_spec::get_hash): Define.
2014-03-20 Dodji Seketeli <dodji@redhat.com>
Slight indentation fix in the diff report
* src/abg-comparison.cc (class_diff::report): Indentation fix for
member function changes report.
2014-03-20 Dodji Seketeli <dodji@redhat.com>
Get rid of class_decl::member_function
* include/abg-fwd.h (is_member_function)
(get_member_function_is_{ctor,dtor,const})
(get_member_function_vtable_offset): New function declarations.
* include/abg-ir.h (class_decl::member_function): Remove.
(class_decl::member_functions): Adjust. This is now just a vector
of method_decl_sptr.
(class_decl::add_member_function): Remove the overload taking
class_decl::member_function. Adjust the other overload to take a
method_decl_sptr.
(class mem_fn_context_rel): New class.
(class_decl::method_decl::set_scope): New virtual overload.
(class_decl::member_function): Remove.
(operator==): Remove the overload taking a
class_decl::member_function.
(class_decl::member_function::hash): Remove.
(ir_node_visitor::visit): Remove the overload taking a
class_decl::member_function.
* include/abg-comparison.h (changed_member_function_sptr)
(string_member_function_sptr_map): Adjust.
* src/abg-comparison.cc (represent): Adjust the overload taking a
class_decl::member_function to take a class_decl::method_decl.
(class_diff::{report, ensure_lookup_tables_populated}): Adjust.
* src/abg-corpus.cc (symtab_build_visitor_type::visit): Remove the
overload taking a class_decl::member_function.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir):
Adjust.
* src/abg-hash.cc (decl_base::hash::operator()): Use the fully
qualified name of the decl in the hash, to increase the likelihood
of avoiding hash collisions.
(method_type::hash::operator()): Likewise.
(function_decl::hash::operator()): Take member functions in
account.
(class_decl::member_function::hash::operator()): Remove.
(class_decl::hash::operator()): Adjust.
(type_base::dynamic_hash::operator()): Adjust.
* src/abg-ir.cc (is_member_function)
(get_member_function_is_{ctor,dtor,const})
(get_member_function_vtable_offset): New function definitions.
(function_decl::get_pretty_representation): Adjust.
(function_decl::operator): Take member functions in account here.
(class_decl::insert_member_decl): Adjust.
(mem_fn_context_rel::~mem_fn_context_rel): New definition.
(class_decl::member_function::*): Remove.
(class_decl::method_decl::set_scope): New definition.
(class_decl::get_num_virtual_functions): Adjust.
(class_decl::add_member_function): Remove overload taking a
class_decl::member_function. Define a new overload taking a
class_decl::method_decl.
(ir_node_visitor::visit): Remove the overload taking a
class_decl::member_function.
* src/abg-reader.cc (build_class_decl): Adjust.
* src/abg-writer.cc (write_voffset, write_class_decl): Adjust.
2014-03-19 Dodji Seketeli <dodji@redhat.com>
Get rid of class_decl::data_member
* include/abg-fwd.h (has_scope): Delete the overloads for
type_base.
(get_member_is_static): Add an overload for decl_base*.
({is,get,set}_data_member,{get_,set}_data_member_is_laid_out)
({get,set}_data_member_offset): New access declarations.
* include/abg-ir.h (class context_rel): Move up.
(decl_base::set_context_rel): New definition.
(class dm_context_rel): New type.
(decl_base::hash_as_member): Remove.
(var_decl::set_scope): Declare new virtual member.
(class_decl::data_member): Remove.
(ir_node_visitor::visit): Remove the overload for
class_decl::data_member.
(represent_data_member): Remove the represent overload for
class_decl::data_member into this. Make it take a var_decl.
(represent): Change the overload that takes two
class_decl::data_member take two var_decl. And adjust it.
(class_diff::report): Adjust.
* src/abg-corpus.cc (symtab_build_visitor_type::visit): Remove the
overload that takes a class_decl::data_member*. Adjust the
overload that takes a var_decl to recognize (static) data members.
* src/abg-dwarf-reader.cc (build_translation_unit_and_add_to_ir)
(build_class_type_and_add_to_ir, build_ir_node_from_die):
Adjust.
* src/abg-hash.cc (var_decl::hash::operator()): Adjust.
(class_decl::data_member::hash::operator()): Remove.
(decl_base::hash::operator()): Take the context relationship in
account here.
(decl_base::hash_as_member::operator()): Remove.
({enum_type_decl,typedef_decl}::hash::operator()): Adjust.
(class_decl::member_function::hash::operator()): Adjust.
(type_base::dynamic_hash::operator()): Adjust.
* src/abg-ir.cc (dm_context_rel::~dm_context_rel): New definition.
(has_scope): Remove overload for type_base.
(get_member_is_static): New overload for decl_base*.
(is_data_member): New function definition.
({get,set}_data_member_{offset,is_laid_out}): Define new
accessors.
(var_decl::set_scope): Define new member function. Make this set
a dm_context_rel as the context relationship.
(var_decl::operator==): Adjust to take in account the new data
member relationship.
(class_decl::class_decl): Adjust.
(class_decl::insert_member_decl): Adjust.
(class_decl::add_data_member): Remove the overload for
class_decl::data_member.
(class_decl::add_data_member): Adjust the overload for var_decl.
(operator==): Remove overload for class_decl::data_member*.
(class_decl::data_member::operator==): Likewise.
(ir_node_visitor::visit): Remove overload for
class_decl::data_member.
* src/abg-writer.cc (write_layout_offset, write_class_decl):
Adjust.
* tests/data/test-read-write/test20.xml: Adjust.
2014-03-18 Dodji Seketeli <dodji@redhat.com>
Better base class diff reporting
* include/abg-comparison.h (class base_diff): New.
* include/abg-ir.h (function_decl::get_first_non_implicit_parm):
New member function.
(function_type::get_first_non_implicit_parm): Likewise.
* src/abg-comparison.cc (base_has_changed): Change parm to take
class_decl::base_spec_sptr.
(class_diff::ensure_lookup_tables_populated): Compare the base
specs not just the base classes.
(class_diff::report): Adjust. Report sub-type changes in the
member functions.
(base_diff::*): Define member functions.
(compute_diff): Define an overload for base_diff_sptr.
* src/abg-hash.cc ({function_type,
method_type}::hash::operator()): Do not hash the implicit parm of
member functions.
(class_decl::hash::operator()): Do not hash member types.
* src/abg-ir.cc (decl_base::decl_base): Initialize the
hashing_started_ member that got moved here from class_decl.
(decl_base::get_hash): Do not set the hash if it's being set b/c
we are in a class_decl.
(decl_base::operator==) Do not compare hashes for now. Two decls
can have different hashes and compare equal; think about an
incomplete type foo, that compares equal with a complete foo.
Their hashes will be different though. So for now, just avoid
comparing these.
(compare_function_types): Avoid comparing the implicit parameter
for member functions.
({function, method}_type::get_first_non_implicit_parm): New
definition.
* tests/data/test-read-write/test20.xml: Update.
2014-03-13 Dodji Seketeli <dodji@redhat.com>
Do not report change in typedef underlying type is there is none
* src/abg-comparison.cc (typedef_diff::report): Do not forget to
check the length of the diff of the underlying type before sending
its diff report down the wire.
2014-03-13 Dodji Seketeli <dodji@redhat.com>
Avoid hashing a access & static-ness of member types twice
* src/abg-hash.cc (class_decl::hash::operator()): Do hash the
'member' part of the member types here, it has been hashed
already.
2014-03-13 Dodji Seketeli <dodji@redhat.com>
Set class {size,loc} when adding members to a decl-only class
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Do not
forget to set class size and location when adding members to a
declaration-only class, turning it into a definition class.
2014-03-13 Dodji Seketeli <dodji@redhat.com>
Use the same representation for member and non-member types
* include/abg-fwd.h (is_at_class_scope): Add new oveloads.
(as_non_member_type, as_non_member_class_decl): Remove.
(has_scope, is_member_decl, is_member_type): New function
declarations. (get_member_is_static, set_member_is_static):
Likewise. * include/abg-ir.h (enum access_specifier): Move to
the abigail:: namespace, from ...
(class_decl::access_specifier): ... here. (class
context_rel): New type. (decl_base::hash_as_member): New
hasher. (decl_base::context_): Change the type of this to
context_rel_sptr. (decl_base::get_context_rel): New protected
getter. (decl_base::get_scope): Move this out-of-line.
(class_decl::member_type): Remove.
(class_decl::member_types): Adjust this typedef.
(class_decl::{insert,add}_member_type): Make these take a
type_base_sptr now. (class_decl::add_member_type): Change the
overload that returned a member_type to return a
type_base_sptr. (get_member_access_specifier,
set_member_access_specifier): New function declarations. *
include/abg-comparison.h (class member_type_diff): Remove.
(compute_diff): Remove the overload for member_type_diff. *
src/abg-comparison.cc (compute_diff_for_types): Adjust for the
removal of class_decl::member_type.
(maybe_report_diff_for_class_members): New static function.
(report_name_size_and_alignment_changes): Do not report a name
change just because of a struct -> class change. ({var_diff,
enum_diff, function_decl_diff}::report): Use the new
maybe_report_diff_for_class_members. (class_diff::report):
Adjust for the removal of class_decl::member_type. Use the
new maybe_report_diff_for_class_members. (class member_diff):
Remove. * src/abg-dwarf-reader.cc (die_access_specifier)
(get_scope_for_die, build_translation_unit_and_add_to_ir)
(build_class_type_and_add_to_ir, build_function_decl)
(build_ir_node_from_die): Adjust. * abg-hash.cc (struct
decl_base::hash_as_member): Define. ({scope_type_decl,
enum_type_decl, typedef_decl}::hash::operator()): Use the
decl_base::hash_as_member.
* src/abg-ir.cc (decl_base::decl_base): Adjust.
(decl_base::get_scope): New out-of-line getter.
(decl_base::{operator==, set_scope): Adjust.
(has_scope, is_member_decl, is_member_type)
(get_member_access_specifier, set_member_access_specifier)
(get_member_is_static, set_member_is_static, is_at_class_scope):
New function definitions.
(as_non_member_type, as_non_member_class_decl): Remove.
(get_node_name): Adjust.
(class_decl::{class_decl, set_earlier_declaration,
insert_member_decl, insert_member_type, add_member_type):
Likewise.
(class_decl::member_type::*) Remove.
* src/abg-reader.cc (read_access, build_qualified_type_decl)
(build_reference_type_def, build_typedef_decl)
(build_class_decl): Adjust.
* src/abg-writer.cc (write_access, write_member_type)
(write_class_decl): Likewise.
2014-03-12 Dodji Seketeli <dodji@redhat.com>
Avoid more static_casts in the (comparison) code
* src/abg-ir.cc (class_decl::insert_member_type, operator==):
Remove static_casts.
(class_decl::member_type::operator==): Likewise.
(class_decl::member_class_template::operator==): Likewise.
2014-03-12 Dodji Seketeli <dodji@redhat.com>
Allow adding members to decl-only classes making them defined classes
* include/abg-fwd.h (lookup_type_in_scope)
(lookup_var_decl_in_scope): New declarations.
* include/abg-ir.h (class_decl::get_is_declaration_only): Rename
is_declaration_only on this.
(class_decl::set_is_declaration_only):
* src/abg-comparison.cc (try_to_diff<class_decl>)
(class_diff::ensure_lookup_tables_populated)
(scope_diff::ensure_lookup_tables_populated): Update for the
get_is_declaration_only renaming.
* src/abg-dwarf-reader.cc (get_scope_for_die): Likewize.
(build_class_type_and_add_to_ir): Make sure that a member type or
data member is not already present in the class before adding it.
Also, if a decl-only class gets a data member, it's not a
decl-only class anymore.
* src/abg-hash.cc (class_decl::hash::operator()): Update for the
get_is_declaration_only renaming.
* src/abg-ir.cc (scope_decl::find_iterator_for_member)
(look_through_decl_only_class): Likewise.
(lookup_type_in_scope, lookup_var_decl_in_scope, get_node_name)
(convert_node_to_decl, lookup_node_in_scope)
(lookup_type_in_scope): New definitions.
(class_decl::{set_definition_of_declaration,
set_earlier_declaration, operator==}): Update for the
get_is_declaration_only renaming.
* src/abg-reader.cc (build_class_decl): Likewise.
* src/abg-writer.cc (write_class_is_declaration_only): Likewise.
2014-03-12 Jonathan Wakely <jwakely@redhat.com>
Fixed typos in abg-diff-utils.h
* include/abg-diff-utils.h (compute_diff): Fix typos in the API
doc.
2014-03-11 Dodji Seketeli <dodji@redhat.com>
Initialize a variable
* tools/bilint.cc (main): Initialize the 'r' variable.
2014-03-11 Dodji Seketeli <dodji@redhat.com>
Do not declare classes before defining them anymore
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Do not
declare classes before defining them because both the declaration
and the definition now compare equal.
* tests/data/test-read-dwarf/test1.abi: Update test.
* tests/data/test-read-write/test20.xml: Likewise.
2014-03-11 Dodji Seketeli <dodji@redhat.com>
Little style fix
* src/abg-comparison.cc (class_diff::report): Slight style fix.
2014-03-10 Dodji Seketeli <dodji@redhat.com>
Better support for decl-only classes in diffing and comparison
* include/abg-fwd.h (look_through_decl_only_class): New function
declaration.
* src/abg-comparison.cc (class_diff::length): Just compare the two
classes.
(compute_diff): Look through the two classes if they are
decl-only, and use their declaration for the diffing.
* src/abg-ir.cc (look_through_decl_only_class): Define this new
entry point.
(class_decl::set_definition_of_declaration): Allow setting a
definition that is itself a declaration-only.
* src/abg-writer.cc (write_class_decl): Declaration-only can now
have members, namely member types.
2014-03-10 Dodji Seketeli <dodji@redhat.com>
Fix comparison wrt hash number
* src/abg-ir.cc (decl_base::operator==): Do not consider empty
hashes.
(class_decl::operator==): Better support for comparing decl-only
classes against non-decl-only classes.
2014-03-10 Dodji Seketeli <dodji@redhat.com>
Better support of class DIEs with DW_AT_specification
* src/abg-dwarf-reader.cc (get_scope_for_die): The definition of a
declaration-only class can be NULL. Do not look through in that
case.
(build_class_type_and_add_to_ir): Support adding class members to
an existing class.
(build_ir_node_from_die): If a class DIE has a DW_AT_specification,
get the specification DIE, get its matching IR node and add the
current members of the current DIE to that IR node.
2014-03-10 Dodji Seketeli <dodji@redhat.com>
Tell struct and class apart
* include/abg-ir.h (class_decl::is_struct_): New member.
(class_decl::class_decl): Take an additional is_struct member.
(class_decl::is_struct): New getter.
* src/abg-ir.cc (class_decl::class_decl): Initialize the new
is_struct_ data member.
(class_decl::get_pretty_representation): Tell struct and class
apart.
* abg-reader.cc (read_is_struct): New static function.
(build_class_decl): Capture the struct-ness of the class.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir):
Likewise.
* src/abg-writer.cc (write_is_struct): New static function.
(write_class_decl): Write the struct-ness of the class.
* tests/data/test-read-dwarf/test1.abi: Update test.
2014-03-06 Dodji Seketeli <dodji@redhat.com>
Fix typedef_diff emptyness detection
* src/abg-comparison.cc (typedef_diff::length): Do not mask away the
dynamic type of the typedef_decl before the comparison.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Add --drop/--keep options to bidiff
* include/abg-sptr-utils.h: New file.
* include/Makefile.am: Add abg-sptr-utils. to the build system.
* include/abg-libxml-utils.h (reader_sptr, xml_char_sptr): Remove
these typedefs as there are now in abg-sptr-utils.
(build_sptr): Likewise for this template and its specializations
declarations.
* src/abg-libxml-utils.cc (sptr_utils::build_sptr): Mode the
definition of the specializations for xmlTextReader and xmlChar
into the sptr_utils namespace.
* include/abg-corpus.h
(corpus::{get_regex_patterns_of_fns_to_suppress,
get_regex_patterns_of_vars_to_suppress,
get_regex_patterns_of_fns_to_keep,
get_regex_patterns_of_vars_to_keep}): Declare new member
functions.
* src/abg-comparison.cc (sptr_utils::regex_t_deleter): Define new
functor.
(build_sptr) Define new specialization for regex_t.
(struct array_deleter): Remove unused functor.
(corpus::priv::regex_patterns_{fns,vars}_to_{suppress,keep}): New data
members.
(symtab_build_visitor_type::regex_patterns_{fns,vars}_to_{suppress,keep}):
Likewise.
(symtab_build_visitor_type::r_{fns,vars}_{suppress,keep})):
Likewise.
(symtab_build_visitor_type::symtab_build_visitor_type): Update the
signature of this constructor to take regex patterns for functions
and variables to suppress and to keep. Also, initialize the data
members from these new parameters.
(symtab_build_visitor_type::regex_{fns,vars}_{suppress,keep}): New
member functions.
(symtab_build_visitor_type::{add_fn_to_wip_fns,
add_var_to_wip_vars}): Likewise.
(symtab_build_visitor_type::visit) Use either add_fn_to_wip_fns or
add_var_to_wip_vars depending on the overload of the visit()
member.
(corpus::priv::build_symbol_table): Update for the change of the
symtab_build_visitor_type constructor signature.
(corpus::get_regex_patterns_of_{fns,vars}_to_{suppress,keep}):
Define new member functions.
* tools/bidiff.cc (options::{drop,keep}_{fn,var}_regex_patterns}):
New data member.
(display_usage): Add help strings for --drop, --drop-fn,
--drop-var, --keep, --keep-fn, --keep-var
(parse_command_line): Parse the command lines above.
(set_corpus_keep_drop_regex_patterns): Define new static function.
(main): Use the new set_corpus_keep_drop_regex_patterns.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Style fix in the dwarf reader
* src/abg-dwarf-reader.cc (die_is_public_decl): Rename
is_public_decl into this.
(die_is_declaration_only): Rename is_declaration_only into this.
(build_class_type_and_add_to_ir, build_var_decl)
(build_function_decl): Adjust for the renames above.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Skip artificial (member) functions from DWARF
* src/abg-dwarf-reader.cc (die_is_artificial): New static
function.
(build_class_type_and_add_to_ir, build_ir_node_from_die): Use the
die_is_artificial function to test if the function DIE is
artificial and then skip it.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Fix function parameter addition/deletion/change detection
* include/abg-ir.h (function_decl::parameter::get_name_id):
Declare new entry point.
* src/abg-comparison.cc
(function_decl_diff::ensure_lookup_tables_populated): Use the new
function_decl::parameter::get_name_id() for the unique name of the
parameter. Also, fix a little logic error: if a parm is deleted
and inserted, in all cases, consider it as not deleted.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Add a --stat option to bidiff
* include/abg-comparison.h (diff_context::show_stats_only):
Declare new accessors.
* src/abg-comparison.cc
(diff_context::priv::show_stats_only_): New member.
(diff_context::show_stats_only): Define new accessors.
(corpus_diff::report): If showing stats only, quit right after
showing the summary.
* tools/bidiff.cc (options::show_stats_only): New data member.
(options::options): Initialize the new data member.
(display_usage): Add help string for --stat.
(parse_command_line): Parse the --stat option.
(set_diff_context_from_opts): Update to set the show_stats_only
onto the context. Cleanup the logic to make it more compact.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Report about functions of different names
* src/abg-comparison.cc (function_decl_diff::report): Consider the
case of functions with different names. This doesn't happen in
the current pipeline b/c they just show up as deleted/added
functions so the function reporter doesn't see them as they have
been already reported by now.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Fix length calculation for type diffs.
* src/abg-comparison.cc (diff_length_of_type_bases): Fix stupid
harmful thinko here.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Fix calculation of the length of distinct_diff
* src/abg-comparison.cc (distinct_diff::length): Also perform a
deep comparison here.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Fix diff length calculation for typedef diffs
* src/abg-comparison.cc (typedef_diff::length): Just use
comparison for this.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Fix layout of diff summary
* src/abg-comparison.cc
(corpus_diff::priv::emit_corpus_diff_stats): Remove useless
vertical and horizontal white spaces.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Fix indentation of pieces of class diff report
* src/abg-comparison.cc (represent, class_diff::report): Fix
indentation.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Fix detection of entities of different kinds for diff purposes
* src/abg-comparison.cc
(distinct_diff::entities_are_of_distinct_kinds): Consider two NULL
decls are distinct types for the purpose of diffing. This is just
a shortcut to avoid creating a null_diff type for now. But then,
stop considering same pointers as different. This was a bug.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Constify function_decl::parameter::get_type_pretty_representation()
* include/abg-ir.h
(function_decl::parameter::get_type_pretty_representation): This
is now const.
2014-02-28 Dodji Seketeli <dodji@redhat.com>
Improve API doc for the location machinery
* include/abg-ir.h (class location): Improve doc.
(decl_base::{get,set}_location): Likewise.
2014-02-26 Dodji Seketeli <dodji@redhat.com>
Remove useless dynamic cast
* src/abg-ir.cc (class_decl::insert_member_decl): Remove useless
dynamic cast from here.
2014-02-26 Dodji Seketeli <dodji@redhat.com>
Insert reference, pointers and qual types at their declaration point
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Insert
reference, pointers and qualified types at the point where we see
them, in their scope, rather than under the scope of their
underlying type. This is because their might be first declared as
member types and we don't want to loose that information.
2014-02-24 Dodji Seketeli <dodji@redhat.com>
Fix documentation for the diff_utils namespace
* include/abg-diff-utils.h (namespace diff_utils): Add comment.
(compute_diff): Update comments for some overloads where they were
missing.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): use
as_non_member_class_decl rather that complicated casting.
src/abg-ir.cc (var_decl::get_pretty_representation): Use
get_type_declaration rather than casting.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Fix a glitch in member data diff reporting
* src/abg-comparison.cc (represent): Do not forget the "'" around
the access specifier.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Proper support for diffing member types
* include/abg-comparison.h (class member_type_diff): New class.
(member_type_diff_sptr): New convenience typedef.
(compute_diff): New overload for member_type_diff.
* src/abg-comparison.cc (struct member_type_diff::priv): New
definition.
(member_type_diff::{first_member_type, second_member_type,
underlying_type_diff, length}): New member function definitions.
(compute_diff): New definition for member type diffs.
(compute_diff_for_types): Support diffing
member types.
(class_diff::report): Do not use strip member types now that we
can properly diff them.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Fix the support for printing cv-qualified names
* include/abg-ir.h (decl_base::{location_, name_,
qualified_parent_name_, qualified_name_}): Make these data members
protected rather than private.
(decl_base::get_qualified_parent_name): Declare new member
functions.
(decl_base::get_qualified_name): Make the core overload virtual.
Simplify the other overload that calls the core one.
(qualified_type_def::build_name): Declare new protected helper
function.
(qualified_type_def::{get_cv_quals_string_prefix,
get_qualified_name}): Declare new functions.
(pointer_type_def::{get_qualified_name}}): Likewise.
(class_decl::member_type::get_qualified_name): Likewise.
* src/abg-ir.cc (decl_base::get_qualified_parent_name): New
definition.
(decl_base::get_name): Make this out-of-line.
(decl_base::get_qualified_name): The signature of this got
simplified. Make it use the new get_qualified_parent_name.
(qualified_type_def::{build_name, get_qualified_name,
get_cv_quals_string_prefix}): New definitions.
(qualified_type_def::qualified_type_def): Update the constructor
to use the new build_name function above.
(pointer_type_def::get_qualified_name): New definitions.
(reference_type_def::get_qualified_name): Likewise.
(class_decl::member_type::get_qualified_name): Likewise.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Misc style fix
* src/abg-comparison.cc (represent): Remove useless curly braces
and vertical spaces.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Support DW_AT_specification on class/struct DIEs
* src/abg-dwarf-reader.cc (build_ir_node_from_die): Support
DW_AT_specification on DW_TAG_{class,structure}type.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Avoid comparing member types and class templates
* src/abg-comparison.h (compute_diff): For class_decl_sptr, do not
compare member types and member class templates. This adds a lots
of noise that is not necessarily useful for now.
* tests/data/test-bidiff/test-qual-type0-report.txt: Update tests.
* tests/data/test-bidiff/test-struct0-report.txt: Likewise.
* tests/data/test-bidiff/test-struct1-report.txt: Likewise.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Fix the report of added/removed function parameters
* src/abg-comparison.cc
(function_decl_diff::priv::{inserted_parms_, removed_parms_}):
Remove these.
(function_decl_diff::ensure_lookup_tables_populated): Fix thinko.
Avoid using the members removed above. Use one less loop to
update the changed params.
(function_decl_diff::report): Avoid using the removed_parms_
data member that was removed above.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Put the setter of access specifiers in class_decl::member_base
* include/abg-ir.h
(class_decl::member_base::set_access_specifier): Put the setter
for access specifier here, where it belongs ...
(class_decl::member_type::set_access_specifier): ... not here.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
First approach to avoid duplication of IR nodes for forward-declared classes
* src/abg-dwarf-reader.cc (is_declaration_only): Put this back (I
removed it earlier).
(build_class_type_and_add_to_ir): If the class is a
declaration-only (a forward declaration), do not add a new
declaration only IR node.
2014-02-21 Dodji Seketeli <dodji@redhat.com>
Do not forget to set the indexes of fn parms
* include/abg-ir.h (function_type::function_type): In the
constructor that takes a vector of parms, walk the vector and set
the indexes of the parms.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Misc diff reporting output cleanup
* src/abg-comparison.cc (function_decl_diff::report): Do not talk
about changed function anymore. Rather, say that some indirect
sub-types changed in the function.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Do not forget some member types/functions we built IR nodes for
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir):
Associate the member type IR node to the offset of the die of the
member type.
(build_ir_node_from_die): For a DW_TAG_subprogram DIE that has a
DW_AT_specification pointing to another subprogram DIE, associate
the offset of this DIE to the IR node of that other DIE.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Better support of static member variables
* include/abg-fwd.h (fqn_to_components)
(lookup_type_in_translation_unit, demangle_cplus_mangled_name):
Declare new public entry points
* src/abg-comparison.cc (corpus_diff::report): Report stuff about
global variables using their mangled name, and demangle them. If
there is no mangled name for the variable, then use its pretty
representation.
(compute_diff): For the corpus overload, compare global variables
using their mangled name, if its available; otherwise, fall back
to using their pretty representation.
* src/abg-corpus.cc (var_comp::operator()(const var_decl*,
const_var_decl*)): Compare variables using their mangled name in
priority. If it's not available then use their pretty
representation.
* src/abg-dwarf-reader.cc
(read_context::var_decls_to_re_add_to_tree): New accessor.
(build_translation_unit_and_add_to_ir): If there is what appears
to be a definition of a static member variable variable -- this is
in case this definition lacks the DW_AT_specification attribute
that links it to the DW_TAG_member or DW_TAG_variable DIE that is
a child of the right class/structure DIE -- that is not at the
right place in the DIE tree, remove it from the its current place
in the tree and try to hang it off of the right DIE. To do this,
de-mangle its mangled name, look at what is supposed to be the
parent class name, look it up in the translation unit IR, and if
found, stick the variable IR node in there, as a static member
variable. If not found, then bad luck.
(build_class_type_and_add_to_ir): Do not try to see if a member
variable is static here as the way I was doing it was unreliable.
Build the data member node directly w/o going through building a
variable node first. Register the data member in the die offset
-> IR node map.
(build_ir_node_from_die): When seeing DW_TAG_variable, look for a
DW_AT_specification attribute. If there is one, then it points to
a the DIE of a data member and means that data member is static.
Flag the IR node of that data member as static thus. Update the
die offset -> IR node map. If there is no DW_AT_specification
attribute or if it doesn't point to a data member DIE, schedule
this variable tag for a stage when after the whole IR is built for
the translation unit, the variable's mangled named is inspected,
its hypothetical parent struct/class is looked up and the variable
IR node is put into the node of the right struct/class IR node.
* src/abg-ir.cc (enum lookup_entity_kind): New.
(fqn_to_components, iterator, lookup_type_in_translation_unit)
(lookup_node_in_translation_unit, lookup_type_in_translation_unit)
(demangle_cplus_mangled_name): New function definitions.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Shorten an accessor name in the DWARF reader
* src/abg-dwarf-reader.cc (read_context::cur_tu): Rename
read_context::current_translation_unit into this.
(read_context::current_scope, die_location)
(build_translation_unit_and_add_to_ir, build_enum_type)
(build_function_decl): Adjust wrt the change above.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Unset decl scope when removing the decl from its scope
* src/abg-ir.cc (remove_decl_from_scope): Unset the scope of the
decl.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Support adding data member from var_decl
* src/abg-ir.cc (class_decl::insert_member_decl): Support taking
a var_decl.
(class_decl::add_data_member): Do not insert a data member twice.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Fix qualified type pretty printing
* src/abg-ir.cc (qualified_type_def::qualified_type_def): Remove
useless white space.
2014-02-19 Dodji Seketeli <dodji@redhat.com>
Add class_decl::member_base::set_is_static() accessor
* include/abg-ir.h (class_decl::member_base::get_is_static):
Rename is_static into get_is_static.
(class_decl::member_base::set_is_static): New accessor.
* src/abg-comparison.cc (represent): Adjust for
class_decl::member_base::is_static -> get_is_static.
* src/abg-corpus.cc (symtab_build_visitor_type::visit): Likewise.
src/abg-hash.cc (class_decl::member_function::hash::operator()):
Likewise.
* src/abg-ir.cc (class_decl::member_base::operator==): Likewise.
* src/abg-writer.cc (write_class_decl): Likewise.
2014-02-13 Dodji Seketeli <dodji@redhat.com>
Fixes needed to diff libstdc++ v4_4 against master
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Support several
instances of the same member function being deleted. That can
happen when the same member function was present in the initial
class several times. Yeah, I've seen that in dwarf.
* src/abg-corpus.cc (corpus::priv::build_symbol_table): Do not add
the same variable (identified by its mangled name) twice in the
variable symbol table.
2014-02-13 Dodji Seketeli <dodji@redhat.com>
Fix wrong deleted functions count when diffing corpora
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): If a function
has changed, deleted it from the list the removed functions.
2014-02-13 Dodji Seketeli <dodji@redhat.com>
Several fixes needed to read libstdc++.so
* src/abg-reader.cc (read_context::map_id_and_node): Allow
duplicated class and basic type declarations.
(build_type_decl): Allow duplicated type decls.
(build_qualified_type_decl, build_pointer_type_def)
(build_reference_type_def): As there can be several distinct
duplicated types, compare them by value.
(build_class_decl): There can be duplicated class decls.
* src/abg-writer.cc (write_enum_type_decl): The name of the enum
needs to be xml-escaped.
2014-02-12 Dodji Seketeli <dodji@redhat.com>
qualified, pointer and reference types can be member types
* src/abg-reader.cc (build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def): Consider that
these types can be member types.
2014-02-12 Dodji Seketeli <dodji@redhat.com>
Consider two typedefs with different names to be different
* src/abg-ir.cc (typedef_decl::operator==): Consider two typedefs
with different names to be different.
2014-02-12 Dodji Seketeli <dodji@redhat.com>
Really Avoid trying to build IR nodes for non-public functions
* src/abg-dwarf-reader.cc (build_ir_node_from_die): For the
DW_TAG_subprogram case, bail out early if the current function is
non-public.
2014-02-12 Dodji Seketeli <dodji@redhat.com>
Add --{changed,deleted,added}-{fns,vars} options to bidiff
* include/abg-comparison.h
(diff_context::{show_{deleted,changed_added}_{fns,vars}}): Declare
new accessors.
(corpus_diff::context): Declare new getter.
* src/abg-comparison.cc
(diff_context::{show_{deleted,changed_added}_{fns,vars}}): Define
these new accessors.
(corpus_diff::priv::emit_corpus_diff_stats): Define new function.
(corpus_diff::context()): Define new getter.
(corpus_diff::report): Use the new
corpus_diff::priv::emit_corpus_diff_stats to emit diff stats at
the beginning of the report. Conditionalise emitting the
different parts of the reports (changed,deleted,added stuff) on
the values of the new properties that were just added.
* tools/bidiff.cc
(options::{show_{deleted,changed,added}_{fns,vars}): New
properties.
(display_usage, parse_command_line): Update for the newly added
--{changed,deleted,added}-{fns,vars} command line options.
(set_diff_context_from_opts): Define new static function.
(main): Create a diff context, initialize it from the options
(using set_diff_context_from_opts) and pass it to compute_diff.
2014-02-11 Dodji Seketeli <dodji@redhat.com>
Add --show-symtabs to bidiff
* tools/bidiff.cc (display_usage): Update usage string.
(parse_command_line): Recognize the --show-symtab cmdline option.
(display_symtabs): New static function.
(main): Call the new display_symtabs.
2014-02-11 Dodji Seketeli <dodji@redhat.com>
Harden class_decl node traversal code
* src/abg-ir.cc (class_decl::traverse): Add a few asserts here and there.
2014-02-11 Dodji Seketeli <dodji@redhat.com>
Fix the pretty representation for member functions
* src/abg-ir.cc (function_decl::get_pretty_representation): Fix
this to properly display the representation of member functions.
* tests/data/test-bidiff/test-enum0-report.txt: Update this.
* tests/data/test-bidiff/test-enum1-report.txt: Likewise.
* tests/data/test-bidiff/test-qual-type0-report.txt: Likewise.
* tests/data/test-bidiff/test-struct0-report.txt: Likewise.
* tests/data/test-bidiff/test-struct1-report.txt: Likewise.
2014-02-11 Dodji Seketeli <dodji@redhat.com>
Do not forget to traverse member types
* include/abg-ir.h (class_decl::member_type::traverse): Declare new virtual
function.
(ir_node_visitor::visit): Declare new virtual function
* src/abg-ir.cc (class_decl::member_type::traverse): Implement the
traversal of a member type.
(ir_node_visitor::visit): Provide a default implementation for the
visitor of member type.
2014-02-11 Dodji Seketeli <dodji@redhat.com>
From DWARD, avoid adding IR nodes for member functions twice
* include/abg-fwd.h (as_non_member_class_decl): Declare new overload.
* src/abg-ir.cc (as_non_member_class_decl): Define new overload.
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir): Add
member functions to the DIE -> IR Node map.
(build_ir_node_from_die): Assert that DW_TAG_subprogram cannot be
for a member function here because getting the scope of the member
function would have constructed the entire class that contains it,
including the member function. Then, calling
build_ir_node_from_die for the DIE of the member function would
find the already IR Node in the DIE -> IR Node map.
2014-02-11 Dodji Seketeli <dodji@redhat.com>
Fix access specifiers value
* include/abg-ir.h (class_decl::enum access_specifier): Give the enumerators
the same values as what the DWARF spec says.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Misc diff report cleanups
* include/abg-ir.h (function_decl::parameter::get_type_name): Add
comment.
(function_decl::parameter::get_type_pretty_representation): New
member fn.
* src/abg-comparison.cc (represent): When representing changed
members, use their pretty representation.
(function_decl_diff::{ensure_lookup_tables_populated, report}): Use the
pretty representation of parameters type.
(typedef_diff::report): Enclose the underlying type in "'".
(corpus_diff::report): Add proper spacing.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Re-organize the output of diffing two corpora
* src/abg-comparison.cc (corpus_diff::report): Emit
information about the number of added/removed/changed
functions. If the report is big, prefix any added
function with '[A]' deleted function with '[B]'. Also,
fix indentation.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Support diffing entities of different kinds.
* include/abg-comparison.h (class distinct_diff): Declare new
type.
(compute_diff_for_distinct_kinds): Declare new function.
* src/abg-comparison.cc (distinct_diff::{distinct_diff, first,
second, entities_are_of_distinct_kinds, length, report}): Define
new member functions.
(compute_diff_for_distinct_kinds, try_to_diff_distinct_kinds):
Define new function.
(compute_diff_for_types, compute_diff_for_decls): Support diffing
entities of different kinds.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Avoid recursive comparison on class_decl & perform some optimizations
* src/abg-ir.cc (class_decl::operator==(const decl_base& other)
const): Bail out early in case of recursive comparison, or if type
hashes are different. Do not try to compute qualified name unless
it's really necessary. The optimizations part of this change were
hinted by profiling.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Handle the DIE for a fn that has a 'specification' attribute
* src/abg-dwarf-reader.cc (build_ir_node_from_die): For the
DW_TAG_subprogram case, if the function has a DW_AT_specification
attribute, build the IR node for the specification DIE instead.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Add an assert in the dwarf reader
* src/abg-dwarf-reader.cc (build_class_type_and_add_to_ir):
Assert that the result of build_function_decl on a member function
is a method_decl.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Do not forget that build_ir_node_from_die can return member types
* src/abg-dwarf-reader.cc (get_scope_for_die): Handle member class
types.
(build_function_decl): Likewise.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
A member function can have an empty mangled name
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): If a member function
has an empty mangling name, use its pretty representation.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Remove too eager asserts
* src/abg-comparison.cc
(class_diff::ensure_lookup_tables_populated): Do not assert that
the same member type cannot be deleted/inserted twice. It
actually can for, pointers, references, typedefs, etc.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Fix some new line handling in diff reports
* src/abg-comparison.cc (represent): Remove extra new line after
reporting virtual function number.
(class_diff::report): Do not forget to emit a new line between two
inserted functions.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Perform the diff of changed functions and variables in the right order
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): In a changed
function or variable, do not mix up the new and old value.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Fix typo in report
* src/abg-comparison.cc (reference_diff::report): Fix typo
refereneced -> referenced.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Fix various crashes
* src/abg-comparison.cc (decls_equal::operator()(const decls_type,
const decls_type) const): Do not crash when of the decl_types is
NULL.
({pointer_diff, reference_diff, enum_diff}::length): Avoid
crashing if the underlying type is NULL.
* abg-ir.cc (function_decl::get_pretty_representation): Avoid
crashing on member functions with empty parameter set.
signed-off-by: Dodji Seketeli <dodji@redhat.com>
2014-02-10 Dodji Seketeli <dodji@redhat.com>
More optimizations hinted by profiling
* include/abg-ir.h (decl_base::qualified_name_): New member.
(decl_base::get_qualified_name): Cache the qualified name.
(decl_base::get_type): Return a reference on the shared pointer.
(method_type::get_class_type): Likewise.
(class_decl::get_definition_of_declaration): Likewise.
(class_decl::member_type::get_underlying_type): Likewise.
(class_decl::base_spec::get_base_class): Likewise.
* src/abg-ir.cc (decl_base::get_qualified_name): Implement the
caching.
(class_decl::member_type::get_qualified_name): Return a reference
on the shared pointer.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Avoid crashing when getting function parm type name
* include/abg-ir.h (function_decl::parameter::get_type_name): New
member function.
* src/abg-comparison.cc
(function_decl_diff::ensure_lookup_tables_populated): Use the new
member function above.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Small optimization hinted by profiling
* include/abg-diff-utils.h (d_path_vec::max_d): Avoid using member
functions. This is relevant only when compiling w/o optimization.
2014-02-10 Dodji Seketeli <dodji@redhat.com>
Fix allocation of diff_utils::d_path_vec
* include/abg-diff-utils.h (d_path_vec::d_path_vec): Do not
forget to allocate enough data for reverse vectors as well. The
comment of the constructor is accurate.
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-hash.h (combine_hashes): Remove trailing white
spaces.
* include/abg-ir.h (class function_decl): Add end-of-class
comment.
(struct type_base::cached_hash): Fix comment.
* src/abg-comparison.cc: Remove useless new line.
* src/abg-corpus.cc: Likewise.
* src/abg-writer.cc: Likewise.
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Support looking through decl-only classes and update diff reports accordingly
* include/abg-comparison.h (class diff_context): New class.
(class diff::{ctxt_, reported_once_, currently_reporting_}): New
data members.
(diff::diff): Initialize the new data members above.
(diff::{context, currently_reporting, reported_once}): New
accessors.
(compute_diff, var_diff::var_diff, pointer_diff::pointer_diff)
(reference_diff::reference_diff, qualified_type_diff)
(enum_diff:enum_diff, class_diff::class_diff)
(scope_diff::scope_diff, function_decl_diff::function_decl_diff)
(type_decl_diff::type_decl_diff, typedef_diff::typedef_diff)
(translation_unit_diff::translation_unit_diff, corpus_diff::corpus_diff):
Take an additional pointer to diff_context.
* abg-comparison.cc (diff_context::{has_diff_for,
has_diff_for_types, add_diff}): New methods.
(try_to_diff, compute_diff_for_types, compute_diff_for_decls)
(represent): Take an additional pointer to
diff_context in argument. In the later function, do not re-report
a diff if it has already been reported, or if it's being reported
already.
(var_diff::var_diff, pointer_diff::pointer_diff)
(reference_diff::reference_diff)
(qualified_type_diff::qualified_type_diff, enum_diff::enum_diff)
(class_diff::class_diff, scope_diff::scope_diff)
(function_decl_diff::function_decl_diff, type_decl::type_decl)
(typedef_diff::typedef_diff)
(translation_unit_diff::translation_unit_diff)
(corpus_diff::corpus_diff): Take an additional pointer to
diff_context in argument.
({pointer_diff, qualified_type_diff,
reference_type_diff}::report): do not re-report a diff about the
underlying type if it has already been reported, or if it's being
reported already.
(enum_diff::report): Fix this to properly use the populated lookup
tables.
(compute_diff): take an additional pointer to diff_context in
argument. For the var_decl, pointer_diff reference_type_diff,
qualified_type_diff enum_diff, scope_diff, function_decl_diff,
type_decl_diff and typedef_diff overloads, do not re-build a diff
object, if one exits already. Otherwise, record the new diff
object created so that it can be re-used later.
(enum_diff::ensure_lookup_tables_populated): Fix logic to avoid
one loop.
(class_decl::priv::{deleted_member_functions_,
inserted_member_functions_, changed_member_function_}): New
members to support reporting about member functions changes.
(class_decl::{lookup_tables_empty, clear_lookup_tables, length):
Update for the new additions above.
(class_decl::ensure_lookup_tables_populated): Likewise. Fix to
properly use the lookup tables and also avoid a going through
several loops to compute the changed members.
(class_decl::report): Flip a switch to make the beginning and end
of the reporting, in the context. Also, do not try to report
again, if we were already reporting this diff. Fix quite some
spots to properly use the lookup tables.
(scope_diff::ensure_lookup_tables_populated): Skip decl-only
classes during comparison. Fix some thinkos. Fix logic to avoid a
loop.
(scope_diff::report): Adjust to pass a context to
compute_diff_for_types.
(function_decl_diff::ensure_lookup_tables_populated): Fix logic to
avoid a loop.
(function_decl_diff::report): Adjust call to
compute_diff_for_types to pass the context.
(typedef::report): Avoid re-reporting the diff of the underlying
types, if we are already reporting it.
(corpus_diff::priv::ensure_lookup_tables_populated): Use the
pretty representation of the function rather than its name to key
the maps of deleted and added functions. Fix logic to avoid going
through an additional loop for the changed functions.
(corpus_diff::report): Add a title for removed/added/changed
functions. Fix indentation for added/removed/changed functions.
* include/abg-ir.h (class_decl::comparison_started_): New member
* src/abg-dwarf-reader.cc (is_public_decl): Style fix.
(is_declaration_only_): New static function.
(build_class_type_and_add_to_ir): Create decl-only classes (IR) for
classes flagged as declaration-only in the DWARF.
* src/abg-hash.cc (class_decl::hash::operator()): Do not forget to
include the "is_declaration_only" flag into the hashing.
* src/abg-ir.cc (class_decl::operator==): Look through decl-only
classes to get their definitions and compare the definitions
instead. Avoid comparing member types and fns if the comparison
of this type has already started.
* src/abg-reader.cc (build_class_decl): Set the definition of a
declaration, when we see it.
* tests/data/test-bidiff/test-qual-type0-report.txt: Update.
* tests/data/test-bidiff/test-struct0-report.txt: Likewise.
* tests/data/test-bidiff/test-struct1-report.txt: Likewise.
signed-off-by: Dodji Seketeli <dodji@redhat.com>
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Support reading *.bi input with duplicated qualified type ids.
* src/abg-reader.cc (read_context::map_id_and_node): Support
qualified types with duplicated ids.
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Fix comparison of member types
* src/abg-ir.cc (class_decl::member_type::operator==): Compare the
underlying type of the member type.
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Avoid duplicated entries in the symbol tables of the corpus
* include/abg-ir.h ({var_decl, function_decl}::ptr_equal): New
equality functor for pointers to var_decl and function_decl.
({function_decl, var_decl}::hash): Make these hashing functors
public.
* include/abg-hash.cc (struct var_decl::hash, struct
function_decl::hash): Remove these from here. There are now in
the public abg-ir.h.
({var_decl, function_decl}::hash::operator()): Define these here.
* src/abg-corpus.cc (symtab_build_visitor_type::{fns_map,
fn_is_in_map, add_fn_to_map, vars_map, var_is_in_map,
add_var_to_map}): New accessors.
(corpus::priv::build_symbol_table): Avoid duplicated entries in
variables and functions symbols tables.
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Ease debugging of abigail::diff_utils::compute_diff
* include/abg-diff-utils.h (compute_diff): Add asserts on for the
length of the shortest edit script during the divide and conquer
part of the diff algorithm.
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Fix further reaching reverse path calculation in core diff algo
* include/abg-diff-utils.h (end_of_frr_d_path_in_k_plus_delta):
Favour moving left when the two abscissas at the previous steps
are equal.
(compute_diff): Update the length of the shortest edit script when
the size of one of the inputs is zero.
* tests/test-core-diff.cc (in_out_spec): Add a new input to diff
two sequences for regression testing.
* tests/data/test-core-diff/report13.txt: New reference for
the comparison of the new regression test above.
2014-02-07 Dodji Seketeli <dodji@redhat.com>
Add debugging facilities for core diffing issues
* include/abg-ir.h (fns_to_str): Declare new fn.
* src/abg-ir.cc (get_next_string, fn_to_str, fns_to_str): New
static functions.
(fns_to_str): Define new fn.
* tools/abg-tools-utils.cc (dump_functions_as_string)
(dump_function_names, compare_functions): New functions.
2014-01-20 Dodji Seketeli <dodji@redhat.com>
Fix apidoc comment
* src/abg-ir.cc (decl_base::operator==): Fix comment.
2014-01-20 Dodji Seketeli <dodji@redhat.com>
Fix bilint outputting for translation units & corpus
* tools/bilint.cc (main): Fix logic.
2014-01-20 Dodji Seketeli <dodji@redhat.com>
Remove debugging assertion when diffing
* include/abg-diff-utils.h (d_path_vec::at): Do not check for
bounds.
2014-01-20 Dodji Seketeli <dodji@redhat.com>
Do not use exceptions in dynamic_cast
* src/abg-ir.cc (class_decl::member_function::operator==)
(class_decl::member_function::operator==): Do not use the
exception path for dynamic casting. This was near the top of many
profiles.
2014-01-20 Dodji Seketeli <dodji@redhat.com>
Just add decls sequentially when reading from DWARF
* src/abg-dwarf-reader.cc (insert_decl_into_ir_under_scope)
(build_namespace_decl_and_add_to_ir, build_enum_type)
(build_class_type_and_add_to_ir, build_ir_node_from_die)
(build_ir_node_from_die): Remove.
* tests/data/test-read-dwarf/test0.abi: Update because now type
IDs can be used before they are defined.
* tests/data/test-read-dwarf/test1.abi: Likewise.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Misc Doxygen API doc fixes
* include/abg-comparison.h: Various doxygen api doc string fixes.
* include/abg-diff-utils.h: Likewise.
* include/abg-dwarf-reader.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-reader.h: Likewise.
* include/abg-writer.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-dwarf-reader.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-libxml-utils.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-writer.cc: Likewise.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Fix bilint --noout, add --diff option
* tools/bilint.cc (options::options): Initialize ...
(options::{diff, bidiff}): ... new members.
(display_usage): Update the display usage string for --diff &
--bidiff options.
(parse_command_line): Support the --diff and --bidiff options.
(main): Require the --diff option to actually diff the emitted
output with input. Make --noout really work for when reading
from dwarf.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Read .abi files with types used before being defined & lots of fixes
* src/abg-reader.cc (read_context::m_decls_stack): Make this is a
std::deque, rather than a std::stack.
(read_context::{get_id_xml_node_map,
clear_id_xml_node_map, get_xml_node_decl_map,
map_xml_node_to_decl, get_decl_for_xml_node,
clear_xml_node_decl_map, map_id_and_node, get_xml_node_from_id,
get_scope_for_node, build_or_get_type_decl}): New member
functions.
(read_context::{get_cur_decl, push_decl, pop_decl}): Update this
now that the decl stack uses a std::deque.
(read_context::clear_decls_stack): New.
(read_context::get_translation_unit): Use the first decl of the
decl stack, that is most certainly the global scope of the current
translation unit, to get the translation unit.
(read_context::key_type_decl): Take a new flag to force the
re-keying; that is set an id to a new type, even if the id was
already set to a type.
(read_context::push_and_key_type_decl): Assert that a type must
have a declaration.
(handle_*): Make these return the decl_base_sptr resulting from
the parsing of the xml node, rather than just a bool.
(walk_xml_node_to_map_type_ids): New static function.
(read_translation_unit_from_input): Read the abi-instr xml
sub-tree once, just to build an id->xml node map. That way, when a
declaration needs a type what is not yet defined, it can just get
its XML node, build the type from it and use it. Do not forget to
advance the xml reader cursor when the reading of the 'abi-instr'
sub-tree is read. Clear all the new maps we have used for the
current translation unit.
(handle_element_node): Cleanup logic.
(build_namespace_decl): Update the new xml node -> decl map, and
use it to avoid building the same namespace twice.
(build_function_parameter): Do not even try to get the type of a
variadic parameter.
(build_function_decl, build_var_decl): Support types that are defined later.
(build_type_decl): Do not build the same type twice. But there
can be several 'unnamed-enum-underlying-type' node. In that case
just return the previous one.
(build_qualified_type_decl, build_pointer_type_def)
(build_reference_type_def, build_enum_type_decl)
(build_typedef_decl): Support underlying type defined later.
(build_class_decl): Support declaration-only related cases where
we can have several xml nodes with the same id. Update the new
xml node -> IR node maps. Fix member type adding.
(build_type_tparameter, build_non_type_tparameter)
(build_template_tparameter): Support used types defined later.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Fix member class template creation
* src/abg-ir.cc (class_decl::add_member_class_template): Do not
forget the scope of the member class template itself.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Avoid endless loop in unescape_xml_string
* src/abg-libxml-utils.cc (unescape_xml_string): Avoid and endless
loop for strings containing an '&' but that are not pre-defined
entities.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Fix a potential crash
* src/abg-ir.cc (decl_base::get_qualified_name): Do not crash if
the scope is empty.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Do not loose the member type information when reading them from DWARF
* include/abg-ir.h (class_decl::declaration_): Make this be a
decl_base_sptr so that it can actually be a
class_decl::member_type which underlying type is a class decl.
(class_decl::{set, get}_earlier_declaration): Take or return a
decl_base_sptr rather than a class_decl_sptr.
* src/abg-ir.cc (class_decl::set_earlier_declaration): Take a
decl_base_sptr rather than a class_decl_sptr.
* src/abg-dwarf-reader.cc (die_class_map_type): Make this map take
decl_base_sptr rather than a class_decl_sptr.
(build_class_type_and_add_to_ir): If the class being currently
built is a member class, do not loose that information after it
has been added to its scope. Also, base types and types of member
variables can be member types and should retain that information.
(build_qualified_type): Likewise, the underlying type of a
qualified type shouldn't loose the information about its
potentially being a member type.
(build_pointer_type_def, build_reference_type, build_typedef_type)
(build_var_decl, build_function_decl): Likewise.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Fix hashing of member types
* include/abg-ir.h (class_decl::{member_function_template,
member_class_template}): Make these inherit from decl_base, to
comply with class_decl::member_type.
(class_decl_base_spec::{base_spec, member_type, member_function,
member_function_template, member_class_template}::hash): Declare
these hashing functors in the header here.
(class_decl::{member_base, member_type, data_member,
member_function, member_function_template,
member_class_template}::hash::operator()): define these out of
line here.
(type_base::dynamic_hash::operator()): Update this to hash member
things.
* src/abg-writer.cc (write_qualified_type_def)
(write_pointer_type_def, write_class_decl)
(write_reference_type_def, write_enum_type_decl): Add an overload
that takes the type ID to use in the serialization.
(write_member_type): New implementation.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
A Member class can also be a scope for other decls in DWARF
* include/abg-fwd.h (as_non_member_class_decl): Declare ...
* src/abg-ir.cc (as_non_member_class_decl): ... this new function.
* include/abg-ir.h (class class_decl::member_type): Add more
comments about member types.
* src/abg-dwarf-reader.cc (get_scope_for_die): Use the new
as_non_member_class_decl here.
2014-01-17 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-ir.h (location_manager::_Impl): Rename this type
into priv.
* src/abg-ir.cc b/src/abg-ir.cc (location_manager::_Impl):
Likewise.
(location_manager::location_manager): Update for the renaming
above.
* src/abg-reader.cc (build_type_decl): Remove useless white space.
(build_enum_type_decl, build_class_decl): Use the _sptr typedef in
the return type.
2014-01-14 Dodji Seketeli <dodji@redhat.com>
Update namespace comments
* src/abg-dwarf-reader.cc (namespace dwarf_reader): Add apidoc comment.
* src/abg-reader.cc (namespace xml_reader): Update apidoc comment.
2014-01-14 Dodji Seketeli <dodji@redhat.com>
Expand 'abi-instr' XML element nodes during de-serialization
* src/abg-reader.cc (update_read_context)
(update_depth_info_of_read_context): Remove.
(read_context::{pop_scope, pop_scope_or_abort): New.
(read_context::{push_decl_to_current_scope,
push_and_key_type_decl}): Remove the overloads that take the
'update_depth_info' boolean.
(build_namespace_decl): New static function.
(build_function_decl, build_var_decl, build_type_decl)
(build_qualified_type_decl, build_pointer_type_def)
(build_reference_type_def, build_enum_type_decl, build_type_decl)
(build_class_decl, build_function_tdecl, build_class_tdecl)
(build_type_tparameter, build_type_composition)
(build_non_type_tparameter, build_template_tparameter)
(build_template_parameter, build_type): Remove the
'update_depth_info' boolean from parameters.
(handle_element_node): Renamed handle_element into this. Take an
xml node and a boolean to add the resulting IR node to the IR.
(handle_type_decl, handle_namespace_decl)
(handle_qualified_type_decl, handle_pointer_type_def)
(handle_reference_type_def, handle_enum_type_decl)
(handle_typedef_decl, handle_var_decl, handle_function_decl)
(handle_class_decl, handle_function_tdecl, handle_class_tdecl):
Take an xml node and a boolean to add the resulting IR node to the
IR.
(advance_cursor): No more need to call update_read_context.
(read_translation_unit_from_input): Expand the 'abi-instr' node
into memory so that we walk its XML nodes and build the IR nodes
from them.
(read_location): Remove the overload that was using the xml reader.
():
2014-01-14 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-reader.cc (read_context::{get_cur_decl, pop_decl}): Return
decl_base_sptr rather than shared_ptr<decl_base>.
(read_context::push_decl): Take a decl_base_sptr rather than
shared_ptr<decl_base>.
2014-01-14 Dodji Seketeli <dodji@redhat.com>
Fix apidoc markup
* include/abg-comparison.h (class var_diff): @ref var_decls ->
@ref var_decl.
* src/abg-comparison.cc (function_decl_diff::first_function_decl):
@Return -> @return.
2014-01-14 Jonathan Wakely <jwakely@redhat.com>
Fix checkout & build instructions
* CONTRIBUTING: Fix Git repository url.
* doc/website/mainpage.txt: Add elfutils into the dependencies
list and fix the repository directory name. Also use autoreconf
-i.
* include/abg-fwd.h: Fix Git repository URL.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Tweak dwarf reading test to detect more namespace linking-fu
* tests/data/test-read-dwarf/test0.cc: Define a member function
out-of-line, outside of its namespace.
* tests/data/test-read-dwarf/test0.abi: Update the .abi file.
* tests/data/test-read-dwarf/test0: Update the resulting binary.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Add asserts to detect type id mis-management in native format
* read_translation_unit_from_input
(read_translation_unit_from_input): Abort when an element could
not be handled.
(build_function_parameter, build_type_decl, qualified_type_def)
(build_pointer_type_def, build_reference_type_def)
(build_enum_type_decl, build_typedef_decl, build_class_decl)
(build_type_tparameter, build_template_tparameter)
(handle_qualified_type_decl, handle_pointer_type_def)
(handle_reference_type_def, handle_typedef_decl):
Abort when a referred-to type is not found or if a type is defined twice.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-hash.cc
(class_decl::member_function_template::hash::operator()): Remove
useless vertical space.
* src/abg-ir.cc (class_decl::class_decl): Properly indent.
* src/abg-writer.cc (fn_tmpl_shared_ptr_map)
(class_tmpl_shared_ptr_map): Properly indent these typedefs.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Optimize comparison & underlying type accessing
* include/abg-ir.h (qualified_type::get_underlying_type)
(pointer_type_def::get_pointed_to_type)
(reference_type_def::get_pointed_to_type)
(typedef_decl::get_underlying_type): Avoid triggering refcount
counter increasing/decreasing here, by returning a reference to
the underlying type. This showed up high on a profile.
({scope_decl, type_decl, scope_type_decl, namespace_decl,
qualified_type_def, pointer_type_def, reference_type_def,
enum_type_decl, typedef_decl, var_decl, class_decl}::operator==):
Avoid taking the exception-using path of dynamic_cast. This
showed up very high on a profile.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Fix reading/writing native xml corpus files
* src/abg-reader.cc (read_context::clear_type_map): New member
function.
(read_translation_unit_from_input): Read up to the next element
node if we are not on an element node already. Clear the type
map. Realize that we might be on the next 'abi-instr' node upon
completion.
(read_corpus_from_input): Read up to the next element node if we
are not on an element node already. It must be an "abi-corpus"
node. THen Advance to the next 'abi-instr' element node before
handing it to read_translation_unit_from_input.
* src/abg-writer.cc (write_context::clear_type_id_map): New member
function.
(write_translation_unit): Call it.
* tools/abg-tools-utils.cc (guess_file_type): Read enough bytes to
detect abi-corpus files magic bytes.
* tools/bilint.cc (main): Do not write the corpus file to the
output stream if --noout has been provided.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Escape xml pre-defined entities in native (de-)serialization.
* include/abg-libxml-utils.h (escape_xml_string)
(unescape_xml_string): Declare new functions.
* src/abg-libxml-utils.cc (escape_xml_string)
(unescape_xml_string): Define them.
* src/abg-reader.cc (build_function_decl, build_var_decl)
(build_type_decl, build_enum_type_decl, build_class_decl)
(build_type_tparameter, build_non_type_tparameter)
(build_template_tparameter, handle_namespace_decl)
(handle_typedef_decl): Use unescape_xml_string.
* src/abg-writer.cc (write_type_decl, write_function_decl)
(write_class_decl, write_type_tparameter)
(write_non_type_tparameter, write_template_tparameter): Use
escape_xml_string.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Implement hash caching
* include/abg-ir.h (decl_base::hash_): New member.
(decl_base::{g,s}et_hash): New accessors.
(type_base_::cached_hash): Forward-declare new hasher.
(struct type_ptr_equal): New equality predicate.
(type_shared_ptr_equal::operator()): Do not forget to test pointer
equality.
(type_base::cached_hash): Declare new hasher.
* src/abg-hash.cc ({decl_base, type_decl, scope_type_decl,
qualified_type_def, pointer_type_def, reference_type_def,
enum_type_decl, typedef_decl, var_decl, function_decl,
function_decl::parameter, class_decl::data_member,
class_decl::member_function, class_decl, }::hash::operator()):
Implement caching.
(type_base::cached_hash::operator()(const type_base*)): Define.
(type_base::cached_hash::operator() (const type_base_sptr):
Define.
* src/abg-ir.cc (type_ptr_map): Make this map use
type_base::cached_hash instead of type_base::ptr_hash now.
(decl_base::decl_base): Initialize the new
decl_base::hash_. member.
(decl_base::{s,g}et_hash): Define.
(decl_base::operator==(const decl_base& other)): Take the hash in
account to speed up inequality detection.
* src/abg-writer.cc (type_ptr_map): Renamed type_shared_ptr_map
into this. Make it use type_base::cached_hash and type_ptr_equal
instead of type_base::shared_ptr_hash and type_shared_ptr_equal.
(get_id_for_type): Add overload for type_base*. Re-write the
previous overload in terms of this one.
(write_context::m_type_id_map): Use type_ptr_map as the type for
this.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Do not canonicalize types anymore; it's slow and luckily not needed
* src/abg-ir.h (translation_unit::canonicalize_type): Remove.
* src/abg-dwarf-reader.cc (canonicalize_and_add_type_to_ir)
(canonicalize_and_insert_type_into_ir)
(canonicalize_and_insert_type_into_ir_under_scope): Remove.
(build_enum_type, build_class_type, build_ir_node_from_die):
Update for removal of type canonicalization.
* src/abg-ir.cc (translation_unit::canonicalize_type): Remove.
2014-01-13 Dodji Seketeli <dodji@redhat.com>
Fix class scope setting & member type de-serializing from dwarf
* include/abg-fwd.h (add_decl_to_scope, insert_decl_into_scope):
return the decl added to the scope.
(as_non_member_type, get_type_declaration): Declare new entry
points.
* include/abg-ir.h (class decl_base::insert_decl_into_scope):
Update this friend declaration.
(class scope_decl, class_decl): Update the friend add_decl_to_scope
declaration.
(scope_decl::add_member_decl): Return the added decl.
(class_decl_sptr): Move this typedef befoer the class_decl class
declaration.
(class_decl::definition_of_declaration_): New member.
(class_decl::{set_definition_of_declaration,
get_definition_of_declaration}): New accessors.
(class_decl::add_member_decl): Return the added member.
(class_decl::insert_member_type): New member.
(class_decl::member_base::access_specifier): Make this protected.
(class_decl::member_type): Make this inherit from type_vase.
(class_decl::member_type::type_): Remove this member.
(class_decl::member_type::as_type): Remove this accessor.
(class_decl::member_type::operator==(const type_base&)): New.
(class_decl::member_type::operator shared_ptr<type_base>() const):
Remove.
(class_decl::member_type::get_underlying_type): New.
(class_decl::member_type::operator==(const member_type&) const):
New.
* src/abg-comparison.cc
(class_diff::{ensure_lookup_tables_populated, report}): Adjust for
the removal of class_decl::member_type::as_type.
* src/abg-dwarf-reader.cc (scope_stack_type): Change this as a
typedef to stack<scope_decl*>.
(current_scope): Change return type from scope_decl_sptr to
scope_decl*.
(insert_decl_into_scope): New.
(build_namespace_decl_and_add_to_ir): Use insert_decl_into_scope
in lieu of add_decl_to_scope.
(build_class_type_and_add_to_ir): likewise. Link a class
definition to its declaration. Push the current scope on the
scope stack. Use as_non_member_type. Fix setting member types.
(get_scope_for_die): Look through declaration-only classe to get
its definition.
(build_qualified_type, build_pointer_type_def)
(build_reference_type, build_typedef_type, build_var_decl)
(build_function_decl): Use as_non_member_type.
(build_ir_node_from_die): Fix member variable & function adding.
* src/abg-ir.cc (scope_decl::{add_member_decl,
insert_member_decl}): Return the added member.
(add_decl_to_scope): Likewise.
(insert_decl_into_scope): Likewise.
(get_top_most_scope_under): Fix logic.
(get_type_declaration): New overload that return a decl_base*.
(as_non_member_type): New definition.
(class_decl::{get_definition_of_declaration,
set_definition_of_declaration, insert_member_decl}): Likewise.
(class_decl::add_member_decl): Re-write in terms of
class::insert_member_decl.
(class_decl::insert_member_type): New definition.
(class_decl::add_member_type): Re-write in terms of
class_decl::insert_member_type.
(class_decl::remove_member_type): Update for the
class_decl::member_type::as_type removal.
(class_decl::{add_data_member, add_member_function,
add_member_function_template, add_member_class_template}): Call
scope_decl::add_member_decl.
(class_decl::member_type::member_type): Update as the type now
virtually inherits from type_base.
(class_decl::member_type::{set,get}_access_specifier): New
definitions.
(class_decl::member_type::get_underlying_type): Likewise.
(class_decl::member_type::set_scope): Update wrt
class_decl::member_type::as_type -> get_underlying_type rename.
(class_decl::member_type::operator==(const decl_base& other)):
There is no more class_decl::member_type::as_type.
(class_decl::member_type::operator==(const type_base& other)):
New.
(class_decl::member_type::get_pretty_representation): Update wrt
class_decl::member_type::as_type -> get_underlying_type rename.
* src/abg-reader.cc (build_class_decl): New that add
add_member_decl adds even member types, no need to add it
explicitly anymore.
2014-01-07 Dodji Seketeli <dodji@redhat.com>
Add regression tests for dwarf reading
* tests/test-read-dwarf.cc: New dwarf reading regression test.
* tests/data/test-read-dwarf/test0: New test input.
* data/test-read-dwarf/test0: Likewise.
* data/test-read-dwarf/test0.abi: Likewise.
* data/test-read-dwarf/test0.cc: Likewise.
* data/test-read-dwarf/test1: Likewise.
* data/test-read-dwarf/test1.abi: Likewise.
* data/test-read-dwarf/test1.cc: Likewise.
* tests/Makefile.am: Build the new tests/test-read-dwarf.cc file.
2014-01-07 Dodji Seketeli <dodji@redhat.com>
Remove useless dependencies in tests/Makefile.am
* tests/Makefile.am: Remove useless *_DEPENDENCIES variables.
2014-01-07 Dodji Seketeli <dodji@redhat.com>
Support new 'abi-corpus' native XML format (.abi)
* include/abg-reader.h (read_corpus_from_native_xml)
(read_corpus_from_native_xml_file): Declare new entry points.
* include/abg-writer.h (write_corpus_to_native_xml)
(write_corpus_to_native_xml_file): Likewise.
* src/abg-reader.cc (read_translation_unit_from_input): Renamed
read_input into this. Support new 'path' attribute for
'abi-instr' XML element.
(read_corpus_from_input): New static function.
(read_translation_unit_from_file)
(read_translation_unit_from_buffer)
(read_translation_unit_from_istream): Update wrt read_input ->
read_translation_unit_from_input.
(read_corpus_from_native_xml, read_corpus_from_native_xml)
(read_corpus_from_native_xml_file): Define new entry points.
* src/abg-writer.cc (write_translation_unit): Write 'path'
attribute into the 'abi-instr' xml element.
(write_corpus_to_native_xml, write_corpus_to_native_xml_file):
Define new entry points.
* tools/abg-tools-utils.h (file_type::{FILE_TYPE_XML_CORPUS,
FILE_TYPE_ZIP_CORPUS}): New enumerators.
* tools/abg-tools-utils.cc (guess_file_type): Support detection of
the new xml file format containing a document root 'abi-corpus'
root element.
* tools/bidiff.cc (main): Support diffing xml corpus-es and zip
corpus-es.
* tools/bidw.cc (main): Recognize elf files before reading them.
* tools/bilint.cc (main): Support reading xml/zip corpus-es too.
* tests/data/test-read-write/test[0-23].xml: Update 'path'
attribute.
2014-01-07 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-writer.h (write_translation_unit): Re-indent parms.
* src/abg-writer.cc (write_translation_unit): Likewise.
* test/test-read-write.cc (main): Fix white space.
2014-01-06 Dodji Seketeli <dodji@redhat.com>
Fix global variables diff reporting in corpus-es
* src/abg-comparison.cc
(corpus_diff::priv::ensure_lookup_tables_populated): Fix a wrong
assert, resulting from a copy paste typo.
2014-01-06 Dodji Seketeli <dodji@redhat.com>
Add support for global variables in corpus diffing
* include/abg-comparison.h (string_var_ptr_map, changed_var_ptr)
(string_changed_var_ptr_map): New convenience typedefs.
* src/abg-comparison.cc
(corpus_diff::priv::{deleted_vars_,added_vars_,changed_vars_}):
New members.
(corpus_diff::priv::{lookup_tables_empty, clear_lookup_tables}):
Update wrt the new variables related lookup tables.
(corpus_diff::ensure_lookup_tables_populated): Update to populate
variables related lookup tables.
(corpus_diff::report): Update to display added/removed/changed
variables.
2014-01-06 Dodji Seketeli <dodji@redhat.com>
Misc style fixlets
* include/abg-comparison.h (changed_function_ptr): Fix comment.
* src/abg-comparison.cc (corpus_diff::report): Likewise.
* src/abg-corpus.cc (corpus::is_empty): Likewise.
2013-12-23 Dodji Seketeli <dodji@redhat.com>
Initial support for diffing ABI corpus files
* include/abg-comparison.h (string_function_ptr_map)
(changed_function_ptr, string_changed_function_ptr_map)
(corpus_diff_sptr): New convenience typedefs.
(translation_unit_diff): Add comments.
(class corpus_diff): New type.
(compute_diff): New overload for corpus_diff.
* include/abg-corpus.h (corpus::{functions, variables}): New
typedefs.
(corpus::{operator==, get_functions, get_variables}): New members.
* include/abg-diff-utils.h (struct deep_ptr_eq_functor): New
functor.
* include/abg-ir.h (translation_unit::operator==): New member
equality operator.
* src/abg-comparison.cc (struct corpus_diff::priv): New private
struct holding the private members of corpus_diff.
(corpus_diff::priv::{lookup_tables_empty, clear_lookup_tables,
ensure_lookup_tables_populated}): Define new private member functions.
(corpus_diff::{corpus_diff, first_corpus, second_corpus,
function_changes, variable_changes, length, report}): New public members.
(struct noop_deleter): New struct.
(compute_diff): New implementation for corpus_diff.
* src/abg-corpus.cc (struct corpus::priv): Renamed corpus::impl
into this. Add new fns, vars and is_symbol_table_built data
members.
(corpus::priv::build_symbol_table): New member function.
(class symtab_build_visitor_type): New visitor type to build the
symbol table.
(struct func_comp, struct var_comp): New comparison functors.
(corpus::priv::build_symbol_table): Define new member function.
(corpus::{corpus, add, get_translation_units, operator==,
get_functions, get_variables}): Define new members.
* src/abg-ir.cc (translation_unit::operator==): Define new member
equality operator.
(operator==(translation_unit_sptr l, translation_unit_sptr r)):
Define new equality operator.
* tools/abg-tools-utils.h (enum file_type): New enum.
(guess_file_type): Declare new function.
* tools/abg-tools-utils.cc (guess_file_type): define new function.
* tools/bidiff.cc (main): Guess the type of the files given in
input and support elf files reading and diffing.
2013-12-23 Dodji Seketeli <dodji@redhat.com>
Generalize use of equality operator in core diff algorithms
* include/abg-diff-utils.h (struct default_eq_functor): New
equality functor.
(end_of_fr_d_path_in_k, end_of_frr_d_path_in_k_plus_delta): Add a
new equality functor template parameter and document it. Use it
to compare the elements of the sequences given in argument.
(compute_middle_snake, ses_len, compute_diff): Add a new equality
functor template parameter and document it. Adjust call to
end_of_frr_d_path_in_k_plus_delta, end_of_fr_d_path_in_k and
compute_middle_snake.
(ses_len, compute_diff): Add a new overload that uses a
default_eq_functor as comparison functor, to avoid breaking
existing client code.
* src/abg-diff-utils.cc (compute_middle_snake): Adjust the call to
the compute_middle_snake.
2013-12-23 Dodji Seketeli <dodji@redhat.com>
Change ir node visitor interface work on pointer to nodes
* include/abg-ir.h (ir_traversable_base): New type to be the base
of IR nodes that are to be traversed. Extends traversable_base.
Its ir_traversable_base::traversable() method takes an
ir_node_visitor&.
(ir_node_visitor::visit): Change these virtual overloads to take
pointers to IR nodes, rather than references. This will be useful
to e.g, store these IR nodes in containers on the side for some
algorithms to work. That is going to be useful later to,
e.g. build symbol tables on the side, using the visitor interface.
(class decl_base): Make this inherit ir_traversable_base.
* src/abg-ir.cc (*::traverse): Adjust comments and the call the
ir_node_visitor::visit call. Use the ir_traversable_base type
rather than traversable_base.
(ir_traversable_base::traverse): Define.
(ir_node_visitor::visit): Change these overloads to take pointers
rather than reference to ir nodes.
* tests/test-walker.cc (name_printing_visitor::visit): Adjust to
take pointers rather than references.
2013-12-23 Dodji Seketeli <dodji@redhat.com>
Do not forget to read function parms
* src/abg-dwarf-reader.cc (build_function_decl): Do not forget the
the function parameters. Oops.
2013-12-20 Dodji Seketeli <dodji@redhat.com>
Support reading member functions and member types from DWARF
* include/abg-ir.h (method_type_sptr): New convenience typedef.
* src/abg-dwarf-reader.cc (read_context::{dwarf_version,
die_wip_classes_map}): New accessors.
(die_is_virtual): Rename is_virtual into this.
(is_type_tag, is_type_die, die_virtual_function_index): Define new
static functions.
(die_member_offset): Fix comment.
(get_scope_for_die): Take the read context as argument.
(canonicalize_and_add_type_to_ir): Likewise. On NULL scope, get
the current translation unit from the read context.
(canonicalize_and_insert_type_into_ir_under_scope): Handle NULL
context.
(build_function_decl): Support creating method_decls from here
when necessary.
(build_class_type_and_add_to_ir): Rename build_class_type into
this. Handle adding the class to the IR and to the relevant maps.
During the creation of the class, arrange for
build_ir_node_from_die on the current DIE to return a
declaration-only class, representing the declaration for the class
that is being constructed. This breaks circular dependencies
induced by decls/types that refer to the class being built, before
the class is fully built and has a (logical) type ID. Once the
class is created, make it refer to the class declaration that was
previously handed for the requests to the class DIE. Now requests
to the class DIE will just yield the newly built class. Add
support for member functions and member types.
(build_corpus): Support reading the dwarf version and stick it
into the context.
(build_ir_node_from_die): Adjust for change in
canonicalize_and_add_type_to_ir and build_class_type signature
change.
* src/abg-ir.cc (class_decl::method_decl::get_type): Support
returning NULL type.
2013-12-20 Dodji Seketeli <dodji@redhat.com>
Don't crash in get_global_scope on empty decls
* src/abg-ir.cc (get_global_scope): Don't crash when given a NULL
decl.
2013-12-20 Dodji Seketeli <dodji@redhat.com>
Make decl_base::set_scope virtual, to work on class_decl::member_type
* include/abg-ir.h (decl_base::set_scope): Make this virtual.
(class_decl::member_type::set_scope): Declare an overload here.
* src/abg-ir.cc (class_decl::member_type::set_scope): Define new
overload. Make this set the scope of the underlying type of the
member type as well.
2013-12-20 Dodji Seketeli <dodji@redhat.com>
Support artificial parameters
* include/abg-ir.h (function_decl::parameter::{get,
set}_artificial): Add new accessors for an "artificial" flag.
* src/abg-reader.cc (build_function_parameter): Support reading
the artificial parameter flag.
* src/abg-writer.cc (write_function_decl): Support writing the
artificial parameter flag.
2013-12-19 Dodji Seketeli <dodji@redhat.com>
Initial support for reading struct/class
* src/abg-dwarf-reader.cc (enum virtuality): New enum.
(class expr_result, struct dwarf_expr_eval_context): New types.
(die_size_in_bits)
(die_access_specifier, die_virtuality, is_virtual)
(die_location_expr, op_pushes_constant_value)
(op_pushes_non_constant_value, op_manipulates_stack)
(op_is_arith_logic, op_is_control_flow)
(eval_last_constant_dwarf_sub_expr, die_member_offset)
(build_class_type): New static functions.
(build_ir_node_from_die<DW_TAG_{class, structure}_type>): Support
creating IR node for class and struct by calling the new
build_class_type.
2013-12-19 Dodji Seketeli <dodji@redhat.com>
Slight style fix
* src/abg-dwarf-reader.cc (build_qualified_type): Fix indentation.
2013-12-19 Dodji Seketeli <dodji@redhat.com>
Be more forgiving when parsing xml from stdin
* src/abg-libxml-utils.cc (xml_istream_input_read): Return the
byte read count even when the stream seems to be borked. In that
case it should be zero.
2013-12-19 Dodji Seketeli <dodji@redhat.com>
Don't crash if building pointer/reference yields NULL
* src/abg-dwarf-reader.cc
(build_ir_node_from_die<DW_TAG_pointer_type)
(DW_TAG_rvalue{0,1}_reference_type>): Do not crash if building the
IR node for the underlying type yields NULL.
2013-12-19 Dodji Seketeli <dodji@redhat.com>
Use dwarf_attr_integrate() rather than dwarf_attr()
* src/abg-dwarf-reader.cc (die_string_attribute)
(die_unsigned_constant_attribute, die_signed_constant_attribute)
(die_flag_attribute, die_die_attribute): Use dwarf_attr_integrate
rather than dwarf_attr to look through DW_AT_abstract_origin.
2013-12-14 Dodji Seketeli <dodji@redhat.com>
Support enums
* src/abg-dwarf-reader.cc (build_enum_type): New function.
(build_ir_node_from_die): Call the new build_enum_type here to
Handle DW_TAG_enumeration_type DIEs.
2013-12-14 Dodji Seketeli <dodji@redhat.com>
Build & use a DIE -> parent map to avoid emitting useless types
* include/abg-ir.h (translation_unit::{mark_type_as_used,
prune_unused_types}): Remove these declarations.
* src/abg-ir.cc (translation_unit::priv::used_types_): Remove.
(class subtype_marking_visitor): Likewise.
(translation_unit::{mark_type_as_used, prune_unused_types):
Likewise.
(get_top_most_scope_under): Fix logic and add comment.
* src/abg-dwarf-reader.cc (die_tu_map_type, offset_offset_map):
New convenience typedefs.
(read_context::{die_tu_map_, die_parent_map_}): New context
members.
(read_context::{die_tu_map, die_parent_map}): New accessors.
(build_ir_node_from_die): New overload that takes the scope of the
ir node in parameter.
(die_signed_constant_attribute): Un-comment this.
(build_die_parent_relations_under, build_die_parent_map)
(get_parent_die, get_scope_for_die): New static functions.
(build_translation_unit_and_add_to_ir): Renamed
build_translation_unit into this. Populate the new
read_context::die_tu_map() here.
(canonicalize_and_add_type_to_ir)
(canonicalize_and_insert_type_into_ir)
(canonicalize_and_insert_type_into_ir_under_scope): Move these
overloads over the top of the file.
(build_namespace_decl_and_add_to_ir): Fix this by adding the
namespace to the IR scope of the DIE (using the new
get_scope_for_die()). Update the read_context::die_decl_map()
map.
(build_function_decl): Support functions that return void. Also,
skip parameters that don't have type set.
(build_corpus): Walk all the DIEs to build a DIE -> parent map.
Adjust for the rename to build_translation_unit_and_add_to_ir.
(build_ir_node_from_die): Add a scope parm. Adjust back to
building IR nodes only for public decls, unless the
'called_from_public_decl' flag is set. Adjust to stick the resulting
IR node into the scope given in parameter.
2013-12-14 Dodji Seketeli <dodji@redhat.com>
Mark sub-types as part of general type marking
* src/abg-ir.cc (subtype_marking_visitor): New visitor.
(translation_unit::mark_type_as_used): When marking a composite
type as used, mark its sub-types as well.
2013-12-14 Dodji Seketeli <dodji@redhat.com>
Add missing virtual keywords for traverse() method
* include/abg-ir.h ({translation_unit, decl_base, scope_decl,
type_decl, namespace_decl, qualified_type_decl, pointer_type_def,
reference_type_def, enum_type_decl, typedef_decl, var_decl,
function_tdecl, class_decl, class_decl::data_member,
class_decl::member_function, class_decl::member_function_template,
class_decl::member_class_template}::traverse): Add a virtual
keyword at least to "document" that this method is virtual -- and
thus remind the user that it overrides the
traversable_base::traverse().
2013-12-14 Dodji Seketeli <dodji@redhat.com>
Add a is_type overload
* include/abg-fwd.h (is_type): Declare new overload that takes a
type reference.
* src/abg-ir.cc (is_type): Define.
2013-12-13 Dodji Seketeli <dodji@redhat.com>
Prune types that are not ref'ed by public decls
* include/abg-fwd.h (remove_decl_from_scope): Declare new
function.
* include/abg-ir.h (type_base_sptr, decl_base_sptr): Move these
convenience typedef before the translation_unit declaration.
(translation_unit::{mark_type_as_used, prune_unused_types}):
Declare new methods.
(decl_base::remove_member_decl): Likewise.
(class_decl::{remove_member_decl, remove_member_type): Likewise.
* src/abg-dwarf-reader.cc (die_decl_map_type): Change this map
type so that the value is now a DIE offset, rather than a DIE.
This is because many times the lifetime of DIEs is shorter than
the one of the reader_context. Also, the die offset uniquely
designates a physical DIE even if several different instances of
logical DIE might point to it.
(struct die_hash): Remove this as it's useless now that we store
DIE offsets in the map.
(build_translation_unit): Call build_ir_node_from_die w/o setting
the called_from_public_decl flag. Prune the types that are not
used by any public decls.
(build_namespace_decl_and_add_to_ir): all build_ir_node_from_die
w/o setting the called_from_public_decl flag.
(build_ir_node_from_die): Change the only_public_decl flag into a
called_from_public_decl flag. Mark types used by public decls as
such. Adjust for the parm changes of build_qualified_type
build_pointer_type_def, build_reference_type, and
build_typedef_type.
(build_qualified_type, build_pointer_type_def)
(build_reference_type, build_typedef_type): Take a new
called_from_public_decl. Pass it to build_ir_node_from_die.
(build_var_decl): Call build_ir_node_from_die with the
called_from_public_decl flag set to true to flag the types
referenced by this variable as being used.
(build_function_decl): Take a called_from_public_decl flag as
well, as this function can now call build_function_decl itself to
build a function decl out of the value of the DW_AT_specification
attribute, for DIEs representing function definitions. Also, flag
the types referenced by public functions are being used.
* src/abg-ir.cc (translation_unit::priv::used_types_): New map for
the used types.
(translation_unit::{mark_type_as_used, prune_unused_types}):
Define new methods.
(scope_decl::remove_member_decl): Likewise.
(remove_decl_from_scope): Define new function.
(class_decl::{remove_member_decl, remove_member_type}): Define new
methods.
2013-12-12 Dodji Seketeli <dodji@redhat.com>
Support reading namespaces
* include/abg-fwd.h (get_global_scope): Return a const
global_scope. Add a new overload that takes a naked pointer as
parm.
(insert_decl_into_scope, get_top_most_scope_under): Declare new
entry points.
* include/abg-ir.h (class decl_base, class scope_decl): Add
insert_decl_into_scope as a friend of these classes.
(scope_decl::{insert_decl_into_scope, find_iterator_for_member}):
Declare new member.
(scope_decl::get_member_decls): New non-const overload.
* src/abg-dwarf-reader.cc (build_translation_unit): Remove the
"recurse" parameter. Adjust the call to build_ir_node_from_die to
read just public decls that are at namespace scope. Anything else
should be dropped unless it's needed to emitting the public
namespace-level decls.
(build_namespace_decl_and_add_to_ir)
(canonicalize_and_insert_type_into_ir): Define new static
functions.
(build_corpus): Adjust ad build_translation_unit doesn't have the
"recurse" parameter anymore.
(canonicalize_and_add_type_to_ir): Make this static. Fix
comments.
(build_ir_node_from_die): Take a new "only_public_decl"
parameter. For DW_TAG_base_type case, use the new
canonicalize_and_insert_type_into_ir to insert the type at the
right place in the global scope making sure it is seen before the
current scope. For pointer, references and qualified types, use
canonicalize_and_insert_type_into_ir to add the type at the same
scope as its underlying type. Handle DW_TAG_{namespace,module}
using the new build_namespace_decl_and_add_to_ir function. Add
some vertical spaces and some assertions.
* src/abg-ir.cc (scope_decl::add_member_decl): Use scope_decl_sptr
typedef.
(scope_decl::{insert_member_decl,find_iterator_for_member}):
Define new methods.
(insert_decl_into_scope, get_top_most_scope_under): Define new
functions.
(get_global_scope): Constify the return type.
(get_translation_unit): Adjust as get_global_scope now returns a
const.
* src/abg-reader.cc (get_translation_unit): Likewise.
2013-12-12 Dodji Seketeli <dodji@redhat.com>
Fix function_decl::parameter::operator==
* include/abg-ir.h (function_decl::parameter::operator==): Support
empty type, e.g, in presence of a variadic parameter.
2013-12-12 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* include/abg-ir.h (decl_base::set_visibility): Remove useless
white space.
(class scope_decl): Remove useless white space.
(scope_decl::add_member_decl): Use decl_base_sptr convenience
typedef.
(global_scope_sptr, namespace_decl_sptr): New convenience typedef.
(class global_scope): Remove useless white space.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-dwarf-reader.cc (die_string_attribute, is_public_decl)
(build_translation_unit, build_ir_node_from_die): Fix comments.
(die_unsigned_constant_attribute, die_signed_constant_attribute)
(die_loc_and_name): Align parms.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Support typedef types
* src/abg-dwarf-reader.cc (build_typedef_type): Define new static
function.
(canonicalize_and_add_type_to_ir): Do not crash on NULL input
type. Also, add a new overload for smart pointer on scope.
(build_ir_node_from_die): For DW_TAG_base_type case, adjust as
canonicalize_and_add_type_to_ir now takes smart pointers on
scopes. Support the DW_TAG_typedef case by calling the new
build_typedef_type.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Support reference types
* src/abg-dwarf-reader.cc (build_pointer_type_def): Do not forget
to get the proper size of the pointer type.
(build_reference_type): Define new static function.
(build_ir_node_from_die): Call build_reference_type for the
DW_TAG_reference_type and DW_TAG_rvalue_reference_type cases.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Support pointer types
* include/abg-fwd.h (get_translation_unit, get_global_scope):
Declare new overloads that act on a naked pointer to decl_base.
* src/abg-dwarf-reader.cc (build_pointer_type_def): Define new
static function.
(canonicalize_and_add_type_to_ir): Take a naked pointer to
scope_decl rather than a smart pointer.
(build_ir_node_from_die): For DW_TAG_base_type, adjust. Support
DW_TAG_pointer_type case. For DW_TAG_{const,volatile}_type case,
make sure the qualified type is in the same scope as its
underlying type.
* src/abg-ir.cc (get_global_scope, get_translation_unit): Define
new overloads that acts on a naked decl_base.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Support qualified types
* src/abg-dwarf-reader.cc (build_qualified_type)
(canonicalize_and_add_type_to_ir): Define new static functions.
(build_ir_node_from_die): In the DW_TAG_base_type case, use the
new canonicalize_and_add_type_to_ir which is a factorization of
this code. In the DW_TAG_{const,volatile}_type, use the new
build_qualified_type and canonicalize_and_add_type_to_ir
functions.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Support reading public functions from DWARF
* src/abg-dwarf-reader.cc (read_context::dwarf_): New member.
(read_context::load_debug_info): Move the content of
load_debug_info_from_elf here.
(read_context::dwarf): New accessor for the dwarf_ member above.
(die_flag_attribute, die_loc_and_name, is_public_decl)
(build_function_decl): New static functions.
(die_location): Do not try to create a location object when the
location has empty file or empty line number.
(build_translation_unit): Take a new address_size parameter.
(build_type_decl): Really take a context parameter. Use the new
die_loc_and_name() here.
(build_var_decl): Skip non-public vars.
(build_corpus): Use dwarf_nextcu instead of dwfl_nextcu, so that
we can get the address_size used in the current CU. Note that for
this we are getting the Dwarf* pointer from the context thanks to
the new read_context::dwarf() getter. Adjust the call to
build_translation_unit to pass it the new address_size.
(build_ir_node_from_die): Shorten lines a little bit. Call the
new build_function_decl to support reading DW_TAG_subprogram DIEs.
(read_corpus_from_elf): Adjust to create the read context earlier
and use its read_context::load_debug_info method to load the debug
info.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Make bilint read input from stdin
* include/abg-libxml-utils.h (new_reader_from_istream): Declare
new public entry point.
* src/abg-libxml-utils.cc (xml_istream_input_read)
(xml_istream_input_close): New static functions.
(new_reader_from_istream): Define new public input function.
* include/abg-reader.h (read_translation_unit_from_istream):
Declare new entry points.
* src/abg-reader.cc (read_translation_unit_from_istream): Define
new entry points.
* tools/bilint.cc (options::{read_from_stdin, noout}): New
members.
(display_usage): Document --stdin and --noout.
(parse_command_line): Adjust to consider that no option on the
command line means reading from stdin, just like --stdin. Support
the --noout option as well.
(main): Support Read the abi instr from stdin; in that case, what
was read is just serialized back to stdout, unless --noout was
supplied.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Support the "address-size" attribute for <abi-instr> elements
* include/abg-ir.h (translation_unit::translation_unit): Take an
address_size parameter.
(translation_unit::{get_address_size, set_address_size}): New
accessors.
* src/abg-ir.cc (translation_unit::priv::address_size_): New
private member.
(translation_unit::translation_unit): Take an address_size
parameter.
(translation_unit::{get_address_size, set_address_size}): Define
these new methods.
* src/abg-reader.cc (read_input): Read the "address-size"
attribute from the abi-instr element.
* src/abg-writer.cc (write_translation_unit): Write the
"address-size" attribute.
* tests/data/test-read-write/test23.xml: New test input.
* tests/test-read-write.cc (in_out_specs): Add the new test above
to the list of files to read and write back.
2013-12-11 Dodji Seketeli <dodji@redhat.com>
Support variadic arguments in function decls
* src/abg-reader.cc (build_function_parameter): Support reading
the "is-variadic" attribute.
* src/abg-writer.cc (write_function_decl): Support writing the
"is-variadic" attribute.
* tests/data/test-read-write/test22.xml: New test input.
* tests/test-read-write.cc (in_out_specs): Add the new test to the
list of files to read and write back.
2013-12-07 Dodji Seketeli <dodji@redhat.com>
Initial support of reading an ABI Corpus from DWARF
* configure.ac: Check the presence of libdw.so and
elfutils/libdwfl.h headers from elfutils and define the necessary
linking flags.
* include/abg-dwarf-reader.h: New header file
* include/Makefile.am: Add the new header file to the source
distribution.
* src/abg-dwarf-reader.cc:: New file.
* src/Makefile.am: Add the new file to the source distribution.
* include/abg-fwd.h (dump): Add declarations for several overloads
to allow dumping to a given output stream.
* include/abg-ir.h (class translation_unit): Use a pimpl idiom for
this now.
(translation_unit::canonicalize_type): Declare new method.
* src/abg-ir.cc (struct translation_unit::priv): New private type
for the pimpl idiom for translation_unit.
(translation_unit::{translation_unit, get_global_scope, get_path,
set_path, get_loc_mgr}): Adjust for pimpl idiom.
(translation_unit::canonicalize_type): Define this new method and
one overload.
* src/abg-writer.cc (dump): Define several overloads to dump IR
nodes to given output streams.
* tools/bidw.cc: New file for the new bidw tool.
* tools/Makefile.am: Define rules to build the new bidw tools.
2013-12-07 Dodji Seketeli <dodji@redhat.com>
Pass a string by reference rather than by value
* tools/bilint.cc (display_usage): Pass program name by reference.
2013-12-07 Dodji Seketeli <dodji@redhat.com>
Misc style fixes
* src/abg-ir.cc (location_manager::location_manager)
(translation_unit::{is_empty, traverse, ~translation_unit): Remove
useless vertical white spaces.
* tools/bilint.cc (parse_command_line): Fix indentation.
2013-12-04 Dodji Seketeli <dodji@redhat.com>
Prepare serialization API for multiple backends
* include/abg-reader.h: New file with abigail::xml_reader APIs.
* include/abg-writer.h: New file with abigail::xml_writer APIs.
* include/Makefile.am: Add the new files above to the source
distribution.
* src/abg-reader.cc: Update top-file comments.
(namespace xml_reader): Rename namespace
reader into this.
(read_to_translation_unit, read_corpus_from_archive): New static
functions.
(read_translation_unit_from_file)
(read_translation_unit_from_file, read_corpus_from_file): New
entry points.
(struct array_deleter): New functor.
(translation_unit::read): Remove this.
* src/abg-writer.cc: Update top file comments.
(namespace xml_writer): Rename namespace
writer into this.
(struct archive_write_ctxt): New internal type.
(create_archive_write_context, write_translation_unit_to_archive)
(write_translation_unit, write_corpus_to_archive): New low level
static functions overloads.
(write_corpus_to_archive, write_translation_unit): Public higher
level overloads.
(translation_unit::write): Remove.
(dump): Update for new xml_writer namespace.
* include/abg-ir.h (translation_unit::{read, write}): Remove these
serialization methods.
* include/abg-corpus.h (corpus_sptr): New convenience typedef.
(corpus::{read, write}): Remove these methods.
* src/abg-corpus.cc (corpus::{read, write})
(corpus::impl::{serialized_tus, archive}): Remove these members.
(corpus::impl::{get_archive, close_archive, write_tu_to_archive,
read_to_translation_unit}): Remove these methods.
* tests/test-bidiff.cc (main): Update for usage of the new
xml_reader API.
* tests/test-read-write.cc (main): Likewise. Update for the usage
of the new xml_writer API, too.
* tests/test-walker.cc (main): Update for the usage of the new
xml_reader API.
* tests/test-write-read-archive.cc (main): Likewise. And for the
xml_writer API, too.
* tools/biar.cc (add_tus_to_archive, extract_tus_from_archive): Likewise.
* tools/bidiff.cc (main): Likewise, for xml_reader APIs.
* tools/bilint.cc (main): Likewise, for xml_writer APIs, too.
2013-11-29 Dodji Seketeli <dodji@redhat.com>
Add support for bidiff regression testing
* tests/data/test-bidiff/test-enum0-v0.cc.bi: New input file.
* tests/data/test-bidiff/test-enum0-v1.cc.bi: Likewise.
* tests/data/test-bidiff/test-enum0-report.diff: Likewise.
* tests/data/test-bidiff/test-enum1-v0.cc.bi: Likewise.
* tests/data/test-bidiff/test-enum1-v1.cc.bi: Likewise.
* tests/data/test-bidiff/test-enum1-report.txt: Likewise.
* tests/data/test-bidiff/test-qual-type0-v0.cc.bi: Likewise.
* tests/data/test-bidiff/test-qual-type0-v1.cc.bi: Likewise.
* tests/data/test-bidiff/test-qual-type0-report.txt: Likewise.
* tests/data/test-bidiff/test-struct0-v0.cc.bi: Likewise.
* tests/data/test-bidiff/test-struct0-v1.cc.bi: Likewise.
* tests/data/test-bidiff/test-struct0-report.txt: Likewise.
* tests/data/test-bidiff/test-struct1-v0.cc.bi: Likewise.
* tests/data/test-bidiff/test-struct1-v1.cc.bi: Likewise.
* tests/data/test-bidiff/test-struct1-report.txt: Likewise.
* tests/data/test-bidiff/test-var0-v0.cc.bi: Likewise.
* tests/data/test-bidiff/test-var0-v1.cc.bi: Likewise.
* tests/data/test-bidiff/test-var0-report.txt: Likewise.
* tests/test-bidiff.cc: New file.
* tests/Makefile.am: Build the new runtestbidiff regression test
and add the above to the source distribution.
2013-11-29 Dodji Seketeli <dodji@redhat.com>
Add missing test inputs to source distribution
* tests/Makefile.am (data/test-read-write/test{17, 18, 19, 20,
21}.xml): Add these test input files to the source distribution.
2013-11-28 Dodji Seketeli <dodji@redhat.com>
Add diff support for var_decl
* include/abg-comparison.h (class var_diff): New declaration.
(var_diff_sptr): New convenience typedef.
(compute_diff): New overloads for var_diff, decl_base and
type_base.
* src/abg-comparison.cc (try_to_diff): Renamed try_to_diff_types
into this.
(compute_diff_for_types): Adjust for the try_to_diff_types
renaming. Fix comments.
(compute_diff_for_decls): Re-use try_to_diff. Update for
var_decl.
(compute_diff): Define overloads for decl_base, type_base and
var_decl.
(diff_length_of_decl_bases, diff_length_of_type_bases): New static
help functions.
(report_name_size_and_alignment_changes): Renamed
report_size_and_alignment_changes into this. Make it report name
changes as well.
(var_diff::priv): New struct.
(var_diff::{var_diff, first_var, second_var, type_diff, length,
report}): Define methods.
({qualified_type_diff, enum_diff, class_diff, scope_diff,
function_decl_diff}::report): Do not report
anything if the diff is empty.
(type_decl_diff::length): Fix this.
(type_decl_diff::report): Adjust for renaming to
report_name_size_and_alignment_changes.
2013-11-28 Dodji Seketeli <dodji@redhat.com>
Add enum_type_decl::get_pretty_representation()
* include/abg-ir.h (enum_type_decl::get_pretty_representation):
Declare new virtual method override.
* src/abg-ir.cc (enum_type_decl::get_pretty_representation):
Define it.
2013-11-28 Dodji Seketeli <dodji@redhat.com>
Change return type of abigail::is_type()
* include/abg-fwd.h (is_type): Change the return type from bool to
type_base_sptr.
2013-11-27 Dodji Seketeli <dodji@redhat.com>
Support diff for enum_type_decl
* include/abg-ir.h (enum_type_decl_sptr): New typedef.
(enum_type_decl::enumerator::enumerator): Make default constructor
public so that enumerators can be stored in vectors. Maybe I
should have made stored pointers to enumerators instead ...
(enum_type_decl::enumerator::get_qualified_name): Define new
method.
* include/abg-comparison.h (string_enumerator_map)
(changed_enumerator, string_changed_enumerator_map)
(enum_diff_sptr): New convenience typedefs.
(class enum_diff): Declare new class.
(compute_diff): New overload for enum_type_decl.
* src/abg-comparison.cc (enum diff_kind, report_mem_header): Move
these at the beginning of the file.
(struct enum_diff::priv): Define this.
(enum_diff::{clear_lookup_tables, lookup_tables_empty,
ensure_lookup_tables_populated, enum_diff, first_enum,
second_enum, underlying_type_diff, deleted_enumerators,
inserted_enumerators, changed_enumerators, length, report}):
Define these new methods.
(compute_diff): New overload for enum_diff.
(compute_diff_for_types): Add support enum_type_decl here.
2013-11-27 Dodji Seketeli <dodji@redhat.com>
Fix equality operator for enum_type_decl
* src/abg-ir.cc (enum_type_decl::operator==(const type_base& o)):
This was comparing just the decl_base and type_base part of the
enum. Now re-use the enum_type_decl::operator==(const decl_base)
that compares the entirety of the types.
2013-11-27 Dodji Seketeli <dodji@redhat.com>
Fix indentation and wording of some existing diff reports
* src/abg-comparison.cc (class_diff::report): Fix report wording.
Change indentation space from 4 white spaces to two.
(scope_diff::report): Fix logic indentation generation.
2013-11-26 Dodji Seketeli <dodji@redhat.com>
Change enum_type_decl::enumerators from a list to a vector
* include/abg-ir.h (enum_type_decl::enumerators): Change this from
a list to a vector.
* src/abg-hash.cc (enum_type_decl::hash::operator()): Use the
typedef enum_type_decl::enumerators rather than std::list<blah>.
* src/abg-ir.cc (enum_type_decl::get_enumerators): Use
the enum_type_decl::enumerators typedef.
(enum_type_decl::operator==): Likewise.
* src/abg-reader.cc (build_enum_type_decl): Likewise.
* src/abg-writer.cc (write_enum_type_decl): Likewise.
2013-11-25 Dodji Seketeli <dodji@redhat.com>
Fix thinko in qualified_type_diff::length
* src/abg-comparison.cc (qualified_type_diff::length): Fix thinko.
2013-11-25 Dodji Seketeli <dodji@redhat.com>
Support diff between qualified types
* include/abg-ir.h (qualified_type_def_sptr): Declare new typedef.
(class qualified_type_def): Add comment at the end.
(operator<<(std::ostream&, qualified_type_def::CV)): Declare new
streaming operator.
* src/abg-ir.cc (operator<<(std::ostream&,
qualified_type_def::CV)): Define this new streaming operator.
* include/abg-comparison.h (class qualified_type): Declare new
class.
(compute_diff): Declare new overload for qualified_type_def_sptr.
* src/abg-comparison.cc (struct qualified_type_diff::priv): Define
new type.
(qualified_type_diff::{qualified_type_diff, first_qualified_type,
second_qualified_type, underlying_type_diff, length}):
Define new methods.
(get_leaf_type): Define new static function.
(compute_diff): Define overload for qualified_type_def_sptr.
(compute_diff_for_types): Add support for
diffing qualified_type_def here.
2013-11-25 Dodji Seketeli <dodji@redhat.com>
Cleanup header of changes of underlying types of pointers/references
* src/abg-comparison.cc ({pointer_diff, reference_diff}::report):
Unify header of changes in the referenced type.
* src/abg-ir.cc (decl_base::get_pretty_representation): By
default, do not prefix types with "type ", for consistency sake.
2013-11-25 Dodji Seketeli <dodji@redhat.com>
Ensure diff types can only be created by compute_diff
* include/abg-comparison.h (diff::diff): Make constructor
protected.
(pointer_diff::pointer_diff): Likewise.
(pointer_diff::{first_pointer, second_pointer}): Constify the
return type.
(compute_diff): Make this a friend of class pointer_diff.
(reference_diff::reference_diff): Make this constructor protected.
(compute_diff): Make this a friend of class reference_diff.
(class_diff::class_diff): Make this constructor protected.
(compute_diff): Make this a friend of class class_diff.
(scope_diff::scope_diff): Make this constructor protected.
(compute_diff): Make this a friend of class scope_diff.
(function_decl_diff::function_decl_diff): Make this constructor
protected.
(type_decl_diff::type_decl_diff): Likewise.
(typedef_diff::typedef_diff): Likewise.
(translation_unit_diff::translation_unit_diff): Likewise.
(compute_diff): Make this a friend of class translation_unit_diff.
* src/abg-comparison.cc (pointer_diff::{first_pointer,
second_pointer}): Constify return type.
2013-11-21 Dodji Seketeli <dodji@redhat.com>
Add size/alignment info to class diff report
* src/abg-comparison.cc (represent): Move these static overloads
to the beginning of the file.
(report_size_and_alignment_changes): New function. It has been
factorized out of ...
(type_decl_diff::report): ... this.
(class_diff::report): Use the new
report_size_and_alignment_changes to report size/alignment info
for classes.
2013-11-21 Dodji Seketeli <dodji@redhat.com>
Style fix
* src/abg-comparison.cc (class_diff::report): Rename first_class
into first and second_class into second.
2013-11-21 Dodji Seketeli <dodji@redhat.com>
Misc diff reporting nits
* include/abg-ir.h (type_decl::get_pretty_representation): New
overload.
* abg-ir.cc (type_decl::get_pretty_representation): Implement it.
* src/abg-comparison.cc (represent, class_diff::report): Quote the
pretty representation of abi artifacts in the report.
(type_decl_diff::report): Better wording to express type_decl
change.
2013-11-20 Dodji Seketeli <dodji@redhat.com>
Support reporting changed data member in class
* include/abg-ir.h (operator<<(std::ostream&, decl_base::binding))
(operator<<(std::ostream&, class_decl::access_specifier)): Declare
new streaming operators.
(class_decl::member_type::get_pretty_representation): New virtual
overload.
* src/abg-ir.cc (operator<<(std::ostream&, decl_base::binding)):
(operator<<(std::ostream&, class_decl::access_specifier)): Define
new streaming operators.
(class_decl::member_type::get_pretty_representation): Define new method.
* src/abg-comparison.cc (represent): Make the existing overloads
end by a newline. Add a new overload that represents the changes
that happened a given data member.
(enum diff_kind): New.
(report_mem_header): Renamed report_num_dels_or_ins into this.
Make it support introducing changed members as well as
deletions/insertions.
(class_diff::report): Adjust for the report_num_dels_or_ins ->
report_mem_header change. Use the new represent() overload to
report about changed data members. Adjust logic now that
represent() emits a newline at its end. Also adjust logic as far
as representing base classes and member types changes is
concerned.
(type_decl_diff::report): Remove useless white space.
2013-11-20 Dodji Seketeli <dodji@redhat.com>
Ensure that *::report adds just one empty line to its content
* include/abg-comparison.h (diff::report): Add a comment saying
that each the diff::report interface must leave one empty line at
the end of the report.
* src/abg-comparison.cc ({pointer_diff, reference_diff,
class_diff, scope_diff, function_decl_diff, type_decl_diff,
typedef_diff}::report): Leave just one
empty line after content.
2013-11-20 Dodji Seketeli <dodji@redhat.com>
Various doxygen doc additions and fixes
* include/abg-comparison.h: Lots of doc string additions & fixes,
especially for typedefs.
* include/abg-ir.h: Likewise.
* src/abg-comparison.cc: Likewise.
* src/abg-ir.cc: Likewise.
2013-11-20 Dodji Seketeli <dodji@redhat.com>
Better support changed base classes and member types
* include/abg-comparison.h (class_diff::{clear_lookup_tables,
lookup_tables_empty, ensure_lookup_tables_populated}): Declare new
methods.
(compute_diff): Make this a friend of class_diff.
* src/abg-comparison.cc (class_diff::priv::{deleted_bases_,
inserted_bases_, changed_bases_, deleted_member_types_,
inserted_member_types_, changed_member_types_,
deleted_data_members_, inserted_data_members_,
changed_data_members_, deleted_member_class_tmpls_,
inserted_member_class_tmpls_, changed_member_class_tmpls_}):
Define new members.
(class_diff::priv::{base_has_changed, member_type_has_changed,
data_member_has_changed}): Declare and define new methods.
(class_diff::{clear_lookup_tables, lookup_tables_empty,
ensure_lookup_tables_populated}): Define new methods.
(class_diff::report): Detect and report when a base class or a
member type has changed, as opposed to just saying that it has
been removed and inserted. Fix the rest of the function to avoid
emitting useless vertical space and avoid saying that the class
has "zero" insertion/deletion of a given kind of member.
(scope_diff::report): avoid saying that the scope has "zero"
insertion/deletion of a given kind of member. Avoid useless
vertical spaces.
(type_decl_diff::report): Avoid useless vertical spaces.
2013-11-19 Dodji Seketeli <dodji@redhat.com>
Add bilint tool to validate bi files somewhat.
* tools/bilint.cc: New file.
* tools/Makefile.am: Build and install the new file above.
2013-11-19 Dodji Seketeli <dodji@redhat.com>
Add diff support for typedef_decl and type_decl
* include/abg-ir.h (operator<<(std::ostream&,
decl_base::visibility)): Declare new streaming operator.
* src/abg-ir.cc (operator<<(std::ostream&,
decl_base::visibility)): Define it.
(type_decl::{operator==, get_pretty_representation}): Likewise,
define these new overloads.
(decl_base::{operator==, get_pretty_representation}): New overloads.
* include/abg-comparison.h (type_decl_diff type_decl_diff_sptr,
typedef_diff, typedef_diff_sptr): Declare new classes and
typedefs.
* src/abg-comparison.cc (type_decl_diff::{type_decl_diff,
first_type_decl, second_type_decl, length, report}): New methods
definitions.
(compute_diff): New function definition that takes pointers of
type_decl.
(typedef_diff::{typedef_diff, first_typedef_decl,
second_typedef_decl, underlying_type_diff, length, report}): New
methods.
(compute_diff): New function definition that takes pointers of
typedef_decl.
(try_to_diff_types): New template function, factorized out of ...
(compute_diff_for_types): ... this. Add support diffing type_decl
and typedef_decl.
(pointer_diff::report): Fix indentation of emitted report.
* tools/bidiff.cc (parse_command_line): Fix style.
2013-11-19 Dodji Seketeli <dodji@redhat.com>
Avoid missing member types while reading bi files
* include/abg-fwd.h (get_type_declaration): Declare function.
* include/abg-ir.h (class decl_base): Add class_decl as a friend.
This to be able to call decl_base::set_scope from class_decl.
(scope_decl::add_member_decl): Make this virtual protected, so
that it can be called (virtually) from e.g, class_decl.
(type_decl_sptr, typedef_decl_sptr): New convenience typedefs.
(class_decl::add_member_decl): New virtual overload for
scope_decl::add_member_decl.
(class_decl::{add_member_type, add_data_member,
add_member_function}): New overloads.
* src/abg-ir.cc (add_decl_to_scope): Benign style cleanup.
(get_type_declaration): Define new function.
(class_decl::add_member_decl): New method.
(class_decl::add_member_type): Avoid silently added a new member
type when that member type has already been (perhaps
inadvertently) added to a scope already. Rather, put a strict
assert in place there. Also add a new overload that constructs
the member type out of a classic type and adds it to the class.
(class_decl::{add_data_member, add_member_function}): Likewise.
(class_decl::{add_member_function_template,
add_member_class_template}): Avoid silently added a new member
template when that template has already been (perhaps
inadvertently) added to a scope already. Rather, put a strict
assert in place there.
* src/abg-reader.cc (push_decl_to_current_scope): Take a an extra
flag saying if the current decl should be added to the current
scope as well (in addition to being pushed onto the stack of
scopes maintained in the reader context).
(push_and_key_type_decl): Likewise, take that extra flag and pass
it to push_decl_to_current_scope.
(build_function_decl, build_var_decl, build_type_decl)
(build_qualified_type_decl, build_pointer_type_def)
(build_reference_type_def, build_enum_type_decl, build_typedef_decl)
(build_function_tdecl, build_class_tdecl): Likewise.
(build_class_decl): Likewise. When building member data, types,
and functions, make sure /not/ to add the data, type of function to
the current scope before adding it to the class_decl. This was
making the member not being added to the class because it already
had a scope.
(build_type_tparameter, build_type_composition)
(build_non_type_tparameter, build_template_tparameter)
(build_type): Adjust to add the template parm to the current scope
explicitly, like previously.
(handle_type_decl): Use build_type_decl function. Add the
type_decl to the current scope, like previously.
(handle_namespace_decl, handle_qualified_type_decl)
(handle_pointer_type_def, handle_reference_type_def)
(handle_enum_type_decl, handle_typedef_decl, handle_var_decl)
(handle_function_decl, handle_class_decl, handle_function_tdecl)
(handle_class_tdecl): Adjust to add the decl to the current scope,
like previously.
* tests/data/test-read-write/test21.xml: New test input with
member type(def).
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Avoid tabs and add const/virtual/offsets to class member diff reports
* include/abg-ir.h (class_decl::get_num_virtual_functions): New
declaration.
* src/abg-ir.cc (class_decl::get_num_virtual_functions): New
definition.
(function_decl::get_pretty_representation): Represent
destructors and const member functions.
* src/abg-writer.cc (write_cdtor_const_static): Take a new bool
parm for constness and serialize it.
(write_class_decl): Serialize member functions & function template
const-ness.
* src/abg-reader.cc (read_cdtor_const): Read the "const" xml
attribute, rather than "is_const".
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Fix num insertions reporting in member functions
* src/abg-comparison.cc (class_diff::report): Fix num insertions
reporting.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Serialize vtable offset for virtual functions
* include/abg-ir.h
(class_decl::member_function::get_vtable_offset): Renamed
class_decl::member_function::get_vtable_offset_in_bits into this.
The offset is an index into a table; it's not a value in bits.
* src/abg-hash.cc (class_decl::member_function::hash): Update wrt
function name change above.
* src/abg-ir.cc (class_decl::member_function::operator==):
Likewise.
* src/abg-reader.cc (build_class_decl): Rename the attribute
vtable-offset-in-bits into vtable-offset.
* src/abg-writer.cc (write_voffset): New function.
(write_class_decl): Use the new write_voffset. Cleanup.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
White space and style fixes
* include/abg-ir.h (class_decl::member_function::member_function):
Align function parameters.
* src/abg-ir.cc (type_decl::operator==): Remove useless white spaces
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Do not report added/removed type_decls
* src/abg-comparison.cc (scope_diff::report): Do not report
added/removed type_decls.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Fix string representation for variables and methods
* src/abg-ir.cc (var_decl::get_pretty_representation): Don't use
the pretty representation for the type of the variable; just use
its qualified name.
(method_type::set_class_type): I wonder what I was thinking when
setting the first parameter's type to being the type of the
class. Remove this.
(function_decl::get_pretty_representation): Use the "method "
prefix for methods. Avoid printing the first parameter of
methods. Use the qualified name of the parameter type, rather
than its pretty representation.
* src/abg-writer.cc (write_class_decl): Do not skip the first
function parameter when serializing the method.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Support reporting removed types/decls
* include/abg-comparison.h (scope_diff::{removed_types,
removed_decls, added_types, added_decls}): New accessor methods
declarations.
* src/abg-comparison.cc (scope_diff::{removed_types,
removed_decls, added_types, added_decls}): New accessor methods
definitions.
(scope_diff::report): Report removed & added types/decls.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Fix erratic reporting of changed types & decls in scopes
* src/abg-comparison.cc
(scope_diff::ensure_lookup_tables_populated): A changed type/decl
is not only one that has been both deleted and inserted (as is a
type/decl with a given name N has been deleted and a type/decl
with that same name N has been inserted), but we must also ensure
that both inserted and deleted type/decl are not the same.
Otherwise, it might has been a type/decl that has been shuffled
around.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Fix some class & scope diff reports formatting glitchs
* src/abg-comparison.cc (class_diff::report): Quote data members.
(scope_diff::report): Simplify how we report changed types. Avoid
unnecessary vertical spaces.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Pretty representation for variables and types by default
* include/abg-ir.h (var_decl::get_pretty_representation): New
method declaration.
* src/abg-ir.cc (decl_base::get_pretty_representation): Prefix
types with the "type " string.
(var_decl::get_pretty_representation): New method definition.
2013-10-24 Dodji Seketeli <dodji@redhat.com>
Re-write middle snakes management in core diff algorithms
* include/abg-diff-utils.h (point::set): New overload..
(point::{add, operator<, operator>, operator<=, operator>=}): New
methods.
(point::operator!=): Constify.
(point::operator==): Constify. Cleanup.
(point::operator=): Keep emptiness.
(class snake): New class definition
(d_path_vec::{over_bounds, offset}): New methods.
(d_path_vec::check_index_against_bound): Don't take a bound
parameter anymore. Use the new over_bound method above. Fix up
error reporting.
(d_path_vec::d_path_vec): Fix d_path_vec size allocation.
(d_path_vec::operator[]): Use the d_path_vec::at method to check
all accesses against the bounds. This is slower, but at least we
can expect to have something that is more robust. We can remove
the bound checking later when we are sure the code has been tested
enough. Also use the new offset() method.
(d_path_vec::at): Take long long.
(ends_of_furthest_d_paths_overlap): Constify input parameters.
(end_of_fr_d_path_in_k, end_of_frr_d_path_in_k_plus_delta): Take
an instance of the new snake in parameter, rather than a bare end
point that wasn't carrying enough information about the snake.
Record the snake which consists of up to four points: a begin
point, an intermediate point, a diagonal start point and an end
point. Return that snake upon successful completion.
(compute_middle_snake): Take an instance of snake, rather than the
two points that were supposed to represent a snake and with which
we were loosing information before. Revisit/simplify the logic of
this function; this literally goes forward or in reverse, gets the
resulting snake returned by the end_of_fr_d_path_in_k and
end_of_frr_d_path_in_k_plus_delta functions, detect if these snakes
overlap and just return the current snake. Much simpler. The
caller now gets a snake, which has much more information than the
previous snake approximation made of just two points. Bonus
point, this follows almost to the word, what the paper says.
(maybe_record_match_point, find_snake_start_point): Remove these
as there are not used by compute_middle_snake anymore.
(print_snake, ses_len): Update these to take/handle a snake.
(snake_end_points): New declaration.
(compute_diff): When we are getting an empty first sequence, this
means that we are inserting the second sequence *before* the
beginning of the first sequence; keep this information by setting
the insertion point index to -1, rather than zero. Update this to
get/handle snakes, rather than free points vaguely representing
snakes. Now that compute_middle_snake returns real snakes, handle
the information we are getting. Basically for edit scripts of
length equal to 1, as the snake carries all the necessary
information about the non-diagonal edge (as well as the diagonal
edges), we (can) now precisely update the current edit script (as
well as the longest common sub-sequence). For edit scripts of
length greater than 1, better at which points to divide the
problem and consequently, at which points to conquer it back --
better following The Paper to the letter.
(display_edit_script): Update this for the use of instances of
snake.
* src/abg-diff-utils.cc (ends_of_furthest_d_paths_overlap): Update
for constification of inputs.
(snake_end_points): Define new function.
(compute_middle_snake): Adapt for the taking an instance of snake.
* tests/test-diff2.cc (main): Update for using instances of snake.
* tests/test-core-diff.cc: Add new tests.
* tests/data/test-core-diff/report0.txt: Update for output
adaptation.
* tests/data/test-core-diff/report6.txt: Likewise.
* tests/data/test-core-diff/report7.txt: Likewise.
* tests/data/test-core-diff/report8.txt: New test data.
* tests/data/test-core-diff/report9.txt: Likewise.
* tests/data/test-core-diff/report10.txt: Likewise.
* tests/data/test-core-diff/report11.txt: Likewise.
* tests/data/test-core-diff/report12.txt: Likewise.
* tests/data/test-core-diff/report3.txt: Likewise.
2013-10-19 Dodji Seketeli <dodji@redhat.com>
Support diff/reporting for functions & better diff/report in general
* include/abg-ir.h ({decl_base, class_decl,
function_decl}::get_pretty_representation): New virtual member to
get a pretty string name for decls & types.
(class_decl::parameter): Add an index to the parameter type.
(class_decl::parameter::parameter): Update the constructor for the
change above.
(class_decl::parameter::{get_index, set_index}): Accessors for the
new index.
(class_decl::parameter::operator==): Take in account the index.
(function_type::append_parameter): Set the index of the parameter
here.
* include/abg-fwd.h (get_type_name): New declaration.
* src/abg-ir.cc (get_type_name): New definition.
({decl_base, function_decl,
class_decl}::get_pretty_representation): New implementations.
(method_type::set_class_type): Update this to set function
parameter's index by default.
(function_decl::append_parameters): Use the append_parameter
method from function_type.
* include/abg-comparison.h (class function_decl_diff): New type
declaration.
* src/abg-comparison.cc (compute_diff_for_decls, compute_diff):
New definitions.
({pointer_diff, class_diff, scope_diff}::report): Use the new
get_pretty_representation. Output a prettier report.
(function_decl_diff::priv): New type.
(function_decl_diff::{deleted_parameter_at, inserted_parameter_at,
ensure_lookup_tables_populated, function_decl_diff,
first_function_decl, second_function_decl, changed_parms,
removed_parms, added_parms, length, report}): New member function
definitions.
* src/abg-hash.cc (function_decl::parameter::hash): Update this to
take the index in account.
2013-10-19 Dodji Seketeli <dodji@redhat.com>
Misc style & white space fixes
* include/abg-fwd.h (is_global_scope, is_at_global_scope)
(is_at_class_scope, is_at_template_scope, is_template_parameter)
(is_type, is_var_decl, is_template_parm_composition_type)
(is_template_decl, is_function_template_pattern)
(add_decl_to_scope, get_global_scope, get_translation_unit):
Remove parameter names from declarations.
* include/abg-ir.h (decl_base::set_location): Remove useless white
space.
(struct type_shared_ptr_equal): Fix comment filling.
2013-10-16 Dodji Seketeli <dodji@redhat.com>
Avoid useless hashing during serialization
* src/abg-writer.cc (write_context::get_id_for_type): Avoid the
useless hashing incurred by the [] operator on the map, when we
already have the value we want.
2013-10-16 Dodji Seketeli <dodji@redhat.com>
Add more IR nodes dumping routines
* include/abg-fwd.h (dump): Declare 4 overloads for the dumping
routines.
* include/abg-ir.h (var_decl_sptr): New typedef.
* src/abg-writer.cc (dump(const decl_base_sptr)): Add comments.
(dump(const type_base_sptr)): New dumping routines.
(dump(const var_decl_sptr)): Likewise.
2013-10-16 Dodji Seketeli <dodji@redhat.com>
Fix IR node comparison bugs
* include/abg-ir.h (type_shared_ptr_equal::operator()): Fix thinko
in checking for the boolean value of the pointers to types.
* src/abg-ir.cc (type_decl::operator==(const decl_base&)): Do not
forget to compare the decl_base part of the type too.
(type_decl::operator==(const type_base&)): To ease maintenance,
re-use the equality operator that takes a decl_base.
(scope_type_decl::operator==(const type_base&)): Likewise.
(qualified_type_def::operator==(const type_base&)): Likewise.
(compare_function_types): New sub-routine to compare function
types. It fixes an infinite recursion when comparing two methods
of the same class.
(function_type::operator==(const type_base&)): Use the new
compare_function_types function.
(class_decl::operator==(const decl_base&)): Fix a thinko in the
first test of the function. Use a dedicated scope for each class
section comparison; that way, there won't be any chance to misuse
the variables pertaining to a different section. Fix the member
function sections; we were mistakenly using the variables for the
*data* section there.
(class_decl::operator==(const type_base&)): Re-use the operator
that takes a decl_base.
(class_decl::operator==(const class_decl&)): Don't remove
const-ness during the static cast.
(class_decl::member_function::operator==(const member_function&)):
Do not remove the reference from the static cast.
(class_decl::member_class_template::operator==(const
member_base&)): Likewise.
(type_tparameter::operator==(const template_parameter&)):
Likewise.
(template_tparameter::operator==(const template_parameter&)):
Likewise.
(function_tdecl::operator==(const template_decl&)): Likewise.
(class_tdecl::operator==(const template_decl&)): Likewise.
(class_tdecl::operator==(const class_tdecl&)): Likewise.
* tests/data/test-read-write/test12.xml: Update this because the
test now correctly considers two type template parameters at the
same index as being equivalent.
* tests/data/test-read-write/test13.xml: Likewise.
2013-10-16 Dodji Seketeli <dodji@redhat.com>
On going white space cleanups
* include/abg-ir.h: Remove useless white spaces.
* src/abg-ir.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-writer.cc: Likewise.
2013-10-15 Dodji Seketeli <dodji@redhat.com>
Finish reporting about class_diff
* src/abg-comparison.cc (report_num_dels_or_ins): Factorize out
the header of each of inserted/deleted parts of the class into
this new function.
(class_diff::report): Use the new report_num_dels_or_ins. Cleanup
the code. Add support for reporting about member functions,
member function templates and member class templates.
2013-10-15 Dodji Seketeli <dodji@redhat.com>
White space cleanup in abg-ir.h
* include/abg-ir.h
(class_decl::member_function_template::member_function_template):
Remove useless white space.
2013-10-15 Dodji Seketeli <dodji@redhat.com>
Progress on diffing pointers, references and classes
* include/abg-comparison.h (diff::{first_subject,second_subject): Changed
first_scope/second_scope into these; so that this diff class now works on
stuff that are not scope. Changed the type of these to
decl_base_sptr
(diff::diff): Update for the change above.
(diff::{length, report}): New virtual pure methods.
(class pointer_diff, reference_diff): New classes declarations.
(compute_diff): New overloads for the new classes above. Make the
existing overloads take shared_pointers instead of references.
Also make them return shared pointers of the computed diff, rather
than just populating diff references passed in parameter.
(class class_diff): Renamed class class_decl_diff into this.
(report_changes): Change these functions into member functions.
* src/abg-comparison.cc (compute_diff_for_types): New static
function.
(pointer_diff::pointer_diff, pointer_diff::first_pointer)
(pointer_diff::second_pointer, pointer_diff::length)
(pointer_diff::underlying_type_diff)
(pointer_diff::underlying_type_diff, pointer_diff::report)
(pointer_diff::report, compute_diff)
(reference_diff::reference_diff, reference_diff::first_reference)
(reference_diff::second_reference)
(reference_diff::underlying_type_diff)
(reference_diff::underlying_type_diff, reference_diff::length)
(reference_diff::report, compute_diff): New functions.
(class_diff::class_diff, class_diff::length)
(class_diff::first_class_decl, class_diff::second_class_decl)
(class_diff::base_changes, class_diff::base_changes)
(class_diff::member_types_changes)
(class_diff::member_types_changes)
(class_diff::data_members_changes)
(class_diff::data_members_changes, class_diff::member_fns_changes)
(class_diff::member_fns_changes)
(class_diff::member_fn_tmpls_changes)
(class_diff::member_class_tmpls_changes)
Update wrt class_decl_diff -> class_diff renaming.
(class_diff::report): Make the report function be a member
function. Add an indentation parameter. Add support for member
types and data members.
(compute_diff): New overload for class_decl_sptr.
(scope_diff::first_scope, scope_diff::second_scope)
(scope_diff::length, scope_diff::report): New member functions.
(scope_diff::{deleted_member_at, inserted_member_at}): Update wrt
first_scope -> first_subject change.
(compute_diff): New overload for scope_decl_sptr.
(translation_unit_diff::report): Change the report function into
this member function.
(compute_diff): Change the overload for translation_unit to take a
translation_unit_sptr rather than a reference.
* tools/bidiff.cc (main): Update this wrt the change of the
signature of compute_diff.
2013-10-15 Dodji Seketeli <dodji@redhat.com>
Fix construction of class_decl::member_type
* include/abg-ir.h (class_decl::member_type::member_type): Remove
inline body from here.
* src/abg-ir.cc (class_decl::member_type::member_type): Move
implementation here. Also, properly set the name of the the
member_type at construction time.
2013-10-15 Dodji Seketeli <dodji@redhat.com>
Few typedef additions to abg-ir.h
* include/abg-ir.h (pointer_type_def_sptr)
(reference_type_def_sptr): New typedefs.
2013-10-11 Dodji Seketeli <dodji@redhat.com>
Add debugging routines for decl_base_sptr and translation_unit
* src/abg-writer.cc (dump): Add two version of this; on for
decl_base_sptr, one for translation_unit&.
2013-10-11 Dodji Seketeli <dodji@redhat.com>
Initial implementation of tu diffing & bidiff cmd line program
* include/abg-comparison.h (class translation_unit_diff): New type.
(compute_diff): Make this take class_decl&, rather than
class_decl_sptr. Add new overloads for scope_decl& and
translation_unit&.
(report_changes): New overload for scope_diff& and
translation_unit&.
* src/abg-comparison.cc (struct class_decl_diff::priv): New type.
(class class_decl_diff): Add comments to methods.
(class translation_unit_diff): Implement methods.
(compute_diff, report_changes): Implement the new overloads.
(scope_diff::ensure_lookup_tables_populated): Fix a thinko here.
* src/abg-ir.cc (is_var_decl): Add new predicate.
* tools/abg-tools-utils.h (file_exists, is_regular_file)
(check_file): Declare new functions.
* tools/abg-tools-utils.cc (get_stat, file_exists, check_file)
(is_regular_file): Define new functions.
(is_dir): Use the new get_stat.
* tools/bidiff.cc: New file.
* tools/Makefile.am: Add tools/bidiff.cc to the build system; make it
produce the bidiff tool.
2013-10-10 Dodji Seketeli <dodji@redhat.com>
Fix inheritance of operator== on decl_base and type_base
* include/abg-ir.h (*lots of descendants of decl_base, type_decl)
(template_decl, class_decl::member_base): Replace the previous classical
*::operator==(*&) with an overload of decl_base::operator==(const
decl_base&), type_base::operator==(const type_base),
template_decl::operator==(const template_decl&) or
class_decl::member_base::operator==(const
class_decl::member_base&). This makes the descendant operator be
the one called when a comparison involves references the parent
class.
* src/abg-ir.cc: Write the implementation of the above. Remove
the useless static_casts from the previous operator== code.
2013-10-10 Dodji Seketeli <dodji@redhat.com>
On going misc white spaces and style fixes
* include/abg-ir.h: Add author. Remove many useless white
spaces. Add missing end-of-class comments. Move function
declaration comments from here to their definition point.
* include/abg-fwd.h: Remove useless indentation. Also move
doxygen comments to *definition* points in src/abg-ir.cc.
* src/abg-ir.cc: Remove many useless white spaces. Move comments
from declaration points to here.
2013-10-06 Dodji Seketeli <dodji@redhat.com>
Fix middle snake determination & ses len computation for d == 1
* include/abg-diff-utils.h (compute_middle_snake): After the
overlap determination happened, finding the middle snake can
require keep on building the current path until the "end". The
end meaning reaching the max of D. And that max is (M + N)/2 + 1.
In the extreme cases were middle snake was on the very last step
(M + N) + 1, we were not finding the middle snake. Fix this.
(compute_diff): When d == 1 and the first edge on the edit graph
is a non-diagonal edge and when a_base != a_begin, we were failing
to properly initialize x,y to find that non-diagonal edge. Also
we were failing to correctly compute the size of the sequence.
Fix these.
* tests/test-core-diff.cc: Add a new regression test for the two
cases above.
* tests/data/test-core-diff/report7.txt: New reference data for
the new regression test.
2013-10-05 Dodji Seketeli <dodji@redhat.com>
Initial un-debugged implementation of scope diffing
* include/abg-comparison.h (class scope_diff): New type.
(compute_diff(scope_decl_sptr, scope_decl_sptr, scope_diff)): New
declaration.
(report_changes): New declaration.
* src/abg-comparison.cc (struct scope_diff::priv): Define.
(scope_diff::{clear_lookup_tables, lookup_tables_empty,
ensure_lookup_tables_populated, scope_diff, member_changes,
deleted_member_at, inserted_member_at, changed_types,
changed_decls}): Define these new member functions.
(compute_diff): Define.
* include/abg-ir.h (decl_base_sptr): New typedef.
(operator==(decl_base_sptr, decl_base_sptr)): Declare new
operator.
* src/abg-ir.cc (operator==(decl_base_sptr, decl_base_sptr)):
Define.
(scope_decl::{operator==, traverse}): Adjust for using vectors to
store scope members now, rather than lists.
(scope_decl::{declarations, scopes}): Make these types be vector.
This makes the members of a scopes be vector, rather than lists.
This enables them to be diffed.
2013-10-05 Dodji Seketeli <dodji@redhat.com>
Simplify & cleanup compute_diff core api
* include/abg-diff-utils.h (insertion::inserted_): Changed the
type of this from vector<int> to vector<unsigned>.
(insertion::{insertion, inserted_indexes}): Adjust.
(compute_diff): Add two new simpler overloads. Implement them in
term of the former more complex overload.
(compute_lcs): Adjust for the vector<int> -> vector<unsigned>
change.
* src/abg-diff-utils.cc (compute_lcs, compute_ses): Adjust for the
compute_diff change above.
* src/abg-comparison.cc (compute_diff, report_changes): Adjust for
the compute_diff & vector<unsigned> changes above..
2013-10-05 Dodji Seketeli <dodji@redhat.com>
Misc white space, style and comments cleanup
* include/abg-ir.h (class scope_decl): Add end of class comment.
(class type_base): Add a _sptr typedef and end of class comment.
* src/abg-ir.cc (operator==(class_decl_sptr, class_decl_sptr)):
Fix comment.
2013-10-04 Dodji Seketeli <dodji@redhat.com>
Un-debugged initial implementation of class diffing.
* include/abg-ir.h (decl_base::get_qualified_name): New
declaration.
(class_decl::{base_specs, member_types, data_members,
member_functions, member_function_templates,
member_class_templates}): Make all these containers be vectors,
rather than list. This makes these containers (like
class_decl::base_specs, class_decl::member_types, etc) be suitable
to be used by the core diffing algorithms to diff their content.
(operator==(class_decl_sptr, class_decl_sptr))
(operator==(class_decl::member_type_sptr, class_decl::member_type_sptr))
(operator==(class_decl::base_spec_sptr,
class_decl::base_spec_sptr))
(operator==(class_decl::data_member_sptr,
class_decl::data_member_sptr))
(operator==(class_decl::member_function_sptr,
class_decl::member_function_sptr))
(operator==(class_decl::member_function_template_sptr,
class_decl::member_function_template_sptr))
(operator==(class_decl::member_class_template_sptr,
class_decl::member_class_template_sptr)): Declare
these new equality operators. These are to be used by the core
diffing algorithms when comparing two vectors of shared pointers
of members of class_decls.
* src/abg-ir.cc (decl_base::get_qualified_name): Define.
(class_decl::class_decl, class_decl::operator==(class_decl&)): Adjust for the
containers type change to a vector.
(operator==(class_decl_sptr, class_decl_sptr))
(operator==(class_decl::member_type_sptr, class_decl::member_type_sptr))
(operator==(class_decl::base_spec_sptr,
class_decl::base_spec_sptr))
(operator==(class_decl::data_member_sptr,
class_decl::data_member_sptr))
(operator==(class_decl::member_function_sptr,
class_decl::member_function_sptr))
(operator==(class_decl::member_function_template_sptr,
class_decl::member_function_template_sptr))
(operator==(class_decl::member_class_template_sptr,
class_decl::member_class_template_sptr)): Define
these.
* include/abg-comparison.h (diff::scope_): Remove
(diff::{first_scope_, second_scope_}): New members.
(class_decl_diff::class_decl_diff): Pass the new scopes to this
constructor.
(class_decl_diff::{first_class_decl, second_class_decl})
(report_changes): New declarations.
* src/abg-comparison.cc (class_decl_diff::class_decl_diff): Update
as per the declaration.
(class_decl_diff::{first_class_decl, second_class_decl}): Define
as per the declaration.
(compute_diff): Initial implementation for this.
(report_changes): Define.
2013-10-04 Dodji Seketeli <dodji@redhat.com>
Change the diff::changes_type back to just edit_script
* include/abg-comparison.h (diff::changes_type):
Remove this typedef.
(class_decl_diff::data_members_changes): Rename
class_decl_diff::data_member_changes into this.
(class_decl_diff::member_fn_tmpls_changes): Renamed
class_decl_diff::member_fn_tmpl_changes into this.
(class_decl_diff::member_class_tmpls_changes): Renamed
class_decl_diff::member_class_tmpl_changes into this.
(class_decl_diff::{base_changes, member_types_changes,
data_members_changes, member_fns_changes, member_fn_tmpls_changes,
member_fn_tmpls_changes, member_class_tmpls_changes}): Adjust
these declarations for the use of edit_script.
* src/abg-comparison.cc (class_decl_diff::priv::*): Likewise.
(class_decl_diff::{base_changes, member_types_changes,
data_members_changes, member_fns_changes, member_fn_tmpls_changes,
member_fn_tmpls_changes, member_class_tmpls_changes}): Adjust
these definitions for the above.
2013-10-04 Dodji Seketeli <dodji@redhat.com>
Misc white space, style and comment fixes
* include/abg-ir.h: Lots of useless white space removals and
comments adding.
(class class_decl::member_base): Fix comment.
* src/abg-hash.cc: Lots of useless white space removals too.
* src/abg-ir.cc: Remove useless white space too.
2013-10-04 Dodji Seketeli <dodji@redhat.com>
Fix middle snake determination
* include/abg-diff-utils.h (point::{operator!=,operator==}): New
operators.
(end_of_fr_d_path_in_k, end_of_frr_d_path_in_k_plus_delta): Allow
the initial point (-1,-1) that is not a point addressing elements
of the input sequences, but that is the starting point of the
forward paths and the ending point of reverse paths in the "Linear
Refinement" of the algorithm.
(is_match_point, maybe_record_match_point)
(find_snake_start_point): New functions.
(find_last_snake_in_path): Remove this. It's not used anymore.
(compute_middle_snake): Allow checking for overlapping paths even
on points that are outside of the edit graph boundaries. Once the
overlap is detected, if a non-empty snake has been seen already,
report it as the middle snake. Otherwise, keep building the path
until the end and report the last snake encountered as the middle
snake. Add comments.
(compute_diff): For the d == 1 case, fix the logic of the finding
the non-diagonal edge. Fix typos. Add comments.
(display_edit_script): Fix report glitches.
* tests/data/test-core-diff/report3.txt: Update as per the report
glitch above.
* tests/data/test-core-diff/report4.txt: Likewise.
* tests/data/test-core-diff/report5.txt: Likewise.
* tests/data/test-core-diff/report6.txt: New reference report for
a new test.
* tests/test-core-diff.cc: Add a new test for negative delta.
2013-10-03 Dodji Seketeli <dodji@redhat.com>
Initial regression test facility for core diff algorithms
* tests/data/test-core-diff/report0.txt: New test reference data.
* tests/data/test-core-diff/report1.txt: Likewise.
* tests/data/test-core-diff/report2.txt: Likewise.
* tests/data/test-core-diff/report3.txt: Likewise.
* tests/data/test-core-diff/report4.txt: Likewise.
* tests/data/test-core-diff/report5.txt: Likewise.
* tests/test-core-diff.cc: New regression test program.
* tests/Makefile.am: Add these new files to the build system.
2013-10-02 Dodji Seketeli <dodji@redhat.com>
Initial command line testing facility for core diff algorithms
* tests/test-diff2.cc: New command line testing facility.
* tests/Makefile.am: Add this to the build system.
2013-10-02 Dodji Seketeli <dodji@redhat.com>
Fix core diff algorithms for negative deltas
* diff2.h (point::point): New copy constructor.
(point::{operator+=, operator=}): Use point::set.
(point::{operator--, operator++,}): New operators.
(d_path_vec::{a_size_, b_size_}): New members.
(d_path_vec::max_d_): Remove this member.
(d_path_vec::max_d): Compute this, now that max_d_ was removed.
(point_is_valid_in_graph): Declare this new function.
(end_of_fr_d_path_in_k, ): Return
a bool when the end of furthest reaching past found is within the
bounds of the edit graph. Add comments.
(end_of_frr_d_path_in_k_plus_delta): Likewise. Also, delta can be
negative; support that. Do not cross the boundaries of the edit
graph when following a diagonal edge.
(find_last_snake_in_path): New function.
(compute_middle_snake): Make forward/reverse d_path_vec be big
enough to hold paths for M+N differences. Normally M+N/2 should
be enough, but we were getting weird out of bound errors. Let's
handle it this way for now. Do not require that we check for
overlap only when we are on a diagonal edge. Once we detected an
overlap, use the new find_last_snake_in_path to find the
boundaries of the snake.
(ses_len): Delta can be negative.
(display_edit): Small minor English nit.
2013-09-28 Dodji Seketeli <dodji@redhat.com>
Lay down the foundations of computing the diff between two class_decl
* include/abg-diff-utils.h: New file.
* src/abg-diff-utils.cc: Likewise. Implement the code diffing
algorithms from Eugene Myers.
* include/abg-comparison.h: New file. First short at defining the
basic APIs to compute the diff of two classes.
* src/abg-comparison.cc: New file. Start the implementation of
the above header.
2013-09-26 Dodji Seketeli <dodji@redhat.com>
Prepare node visitors to be usable on things other than IR nodes
* include/abg-fwd.h (node_visitor_base): Renamed ir_node_visitor
into this.
* include/abg-traverse.h (struct node_visitor_base): New base for
the visitors.
(struct traversable_base): Update comments.
(traversable_base::traverse): Change this into non-pure virtual.
Make it take a reference to node_visitor_base, rather than a
reference to ir_node_visitor.
* src/abg-traverse.cc (traversable_base::traverse): New empty
default implementation.
* include/abg-ir.h: Make ir_node_visitor inherit from new
node_visitor_base.
2013-09-26 Dodji Seketeli <dodji@redhat.com>
Renamed data members from m_something to something_
* src/abg-ir.{cc,h}: Renamed data members from m_something to
something_ and update their usage.
2013-08-29 Dodji Seketeli <dodji@redhat.com>
Initial version of an archive manipulation program: biar
* tests/test-utils.h (is_dir, ensure_dir_path_created)
(ensure_parent_dir_created): Move these directories manipulation
utilities from here to ...
* tools/abg-tools-utils.h (is_dir, ensure_dir_path_created)
(ensure_parent_dir_created): ... here in this new file.
(dir_name, base_name): Declare these new functions.
* tests/test-utils.cc (is_dir, ensure_dir_path_created)
(ensure_parent_dir_created): Likewise, move these to ...
* tools/abg-tools-utils.cc (is_dir, ensure_dir_path_created)
(ensure_parent_dir_created): ... here in this new file.
(dir_name, base_name): Define these.
* tools/Makefile.am: New file. Create a new libtoolsutils.la
static library with stuff from tools/abg-tools-utils.cc in it.
Also create a new 'biar' program with the stuff from the new
tools/biar.cc in it.
* tools/biar.cc: New file. Contains the code for the new "biar"
archive manipulation command line utility.
* tests/test-read-write.cc (main): Adjust for the change about
ensure_parent_dir_created above.
* tests/test-write-read-archive.cc (main): Likewise.
* Makefile.am (SUBDIRS): Add the new tools/ sub-directory to the
build system.
* configure.ac (AC_CONFIG_FILES): Generate tools/Makefile.
* tests/Makefile.am: Make libtestutils.la link with the new
libtoolsutils.la. Make sure to express the dependencies between
libtestutils.la and the binaries that depend on it. Otherwise
parallel builds can go awry.
2013-08-29 Dodji Seketeli <dodji@redhat.com>
Define translation_unit{_sptr,s} types in abigail::
* include/abg-corpus.h (abigail::corpus::{translation_unit_sptr,
translation_units): Do not define these typedefs here. Rather)
(define them ...
* include/abg-ir.h
(abigail::{translation_units,translation_unit_sptr): ... here.
This is because a translation unit can be manipulated
independently from an abi corpus.
* src/abg-corpus.cc (corpus::get_translation_units): Adjust return
type to comply with the change above.
2013-08-29 Dodji Seketeli <dodji@redhat.com>
Fix header inclusion in abg-corpus.h
* include/abg-corpus.h: Drop incomplete abg-traverse.h and
abg-fwd.h. Use abg-ir.h proper and be done with it. Users of the
library will just have to use abg-corpus.h to manipulate and the
archives and the IR they contain.
2013-08-29 Dodji Seketeli <dodji@redhat.com>
Add error message to translation_unit::write
* src/abg-writer.cc (translation_unit::write): Add an error
message to stderr if something ultimately went wrong.
2013-08-29 Dodji Seketeli <dodji@redhat.com>
Rename abigail::corpus::{get_file_path --> get_path}
* include/abg-corpus.h (corpus::{get_path, set_path): Renamed
corpus::get_file_path and corpus::set_file_path into these as
get_path/set_path is what is used elsewhere as well.
* src/abg-corpus.cc (corpus::{get_path, set_path}): Likewise.
* tests/test-write-read-archive.cc (main): Adjust for the change
above.
2013-08-29 Dodji Seketeli <dodji@redhat.com>
Cleanup src/Makefile.am
* src/Makefile.am: Fix library naming and remove useless trailing
space from directory path.
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Initial writing/reading of an ABI corpus to an archive
* configure.ac: Support detection of libzip dependency. Define
new DEPS_CFLAGS and DEPS_LIBS variables for use in
Makefile.am to refer to the dependency headers and
libraries.
* doc/website/mainpage.txt: Update this to talk about the new
libzip dependency.
* include/Makefile.am: Add abg-libzip-utils.h to the build system.
* include/abg-corpus.h (corps): Hide abigail::corpus's private behind a
pimpl idiom.
(corpus::{drop_translation_units, get_file_path, set_file_path,
write, read}): New methods.
* include/abg-libxml-utils.h (new_reader_from_buffer): Declare new
function.
* include/abg-libzip-utils.h: New file.
* src/Makefile.am: Add abg-corpus.cc and abg-libzip-utils.cc to
the build system. Refer to the library and headers dependencies
via the new DEPS_LIBS and DEPS_CFLAGS variables.
* src/abg-corpus.cc: New file.
* src/abg-ir.cc (translation::set_path): New method.
* src/abg-libxml-utils.cc (new_reader_from_buffer): Define new
function.
* src/abg-libzip-utils.cc: New file.
* src/abg-reader.cc (translation_unit::read): New overload.
* src/abg-writer.cc: Inject the names from the std namespace into
the abigail namespace, rather than into abigail::writer.
(abigail::translation_unit::write): New overload. This can now
use ofstream and the other stuff from std that are injected in the
abigail:: namespace.
* tests/Makefile.am: Add tests/test-write-read-archive.cc to the
build system; use that to build runtestwritereadarchive. Also add
the input test data from
tests/data/test-write-read-archive/test[0-4].xml.
* /tests/data/test-write-read-archive/test[0-4].xml: New test
input data files.
* tests/test-write-read-archive.cc: New test for this archive
write/read support.
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Fix & add missing API documentation
* src/abg-ir.cc (location_manager::create_new_location): Fix
documentation comment. (translation_unit::translation_unit)
(translation_uni::get_global_scope, translation_unit::get_path)
(translation_unit::traverse, translation_unit::get_loc_mgr)
(translation_unit::is_empty, translation_unit::traverse): Add
missing documentation comments.
* src/abg-libxml-utils.cc (new_reader_from_file): Fix comment.
* src/abg-reader.cc (translation_unit::read): Likewise.
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Remove useless header inclusion
* include/abg-traverse.h: Remove useless #include <tr1/memory>
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Misc white space cleanups
* include/abg-corpus.h: Cleanup white spaces.
* include/abg-fwd.h: Likewise.
* include/abg-ir.h: Likewise.
* include/abg-libxml-utils.h: Likewise.
* src/abg-config.cc: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-writer.cc: Likewise.
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Small cleanup in abg-config.cc
* src/abg-config.cc: Include auto-generated
$(top_builddir)/config.h file.
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Pass absolute paths to the compiler during the build
* src/Makefile.am: Pass absolute file paths to the compiler during
the build. This helps in e.g in emacs' compilation mode, when the
output shows an error reported by GCC's diagnostics, setting point
to the error line and hitting 'enter' transports the user to the
file location where the error happened; as the file path is nows
absolute, emacs can always find it. Otherwise, finding it depends
on $PWD and whatnot.
* tests/Makefile.am: Likewise.
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Misc cleanups in abg-fwd.h
* include/abg-fwd.h: Move location, location_manager and
translation_unit in the ir section. Remove stuff that was
commented out anyway.
2013-08-27 Dodji Seketeli <dodji@redhat.com>
Move location, location_manager & translation_unit back into abg-ir.h
* include/abg-corpus.h: Move location location_manager,
translation_unit from here ...
* include/abg-ir.h: ... to here. The reason being that these are
really constructs of the Internal Representation of the ABI/API of
a translation unit. What is left in abg-corpus is really
exclusively related to an ABI Corpus, which I see more as a
"packaging" construct that abstracts the bundling of several
translation units together. Also, I fixed some comments about the
location/location_manger types; now a location is made specific to
a translation unit; to an abi corpus. A location of a given
translation unit has to be decoded by the location manager of that
same translation unit.
2013-08-22 Dodji Seketeli <dodji@redhat.com>
Make libxml2 a private dependency wrt pkconfig
* libabigail.pc.in: Libxml2 is not exposed to clients so make it
be a private dependency.
2013-08-22 Dodji Seketeli <dodji@redhat.com>
White space fix in COMPILING
* COMPILING: White space fix.
2013-08-22 Dodji Seketeli <dodji@redhat.com>
Add abg-version.h.in to the source distribution & cleanup
* include/Makefile.am: Add abg-version.h.in to the source
distribution.
* configure.ac: Generate abg-version.h in using the existing
AC_CONFIG_FILES macro call.
2013-08-22 Dodji Seketeli <dodji@redhat.com>
Support pkgconfig through a new libabigail.pc file
* libabigail.pc.in: New pkgconfig file.
* configure.ac: Define the LIBXML2_VERSION variable that is used
in the libabigail.pc.in file. Generate the libabigail.pc file
from its libabigail.pc.in template.
* Makefile.am: Add libabigail.pc.in to the source distribution.
Install the generated libabigail.pc to the right destination.
2013-08-21 Dodji Seketeli <dodji@redhat.com>
Tweak the apidoc mainpage
* include/abg-fwd.h<doxygen markup>: Fix link to the project web
page and for git check-out.
2013-08-21 Dodji Seketeli <dodji@redhat.com>
Initial website generation-fu using Doxygen
* doc/website/mainpage.txt: New file representing the input for
the website.
* doc/website/libabigail-website.doxy: New file representing the
doxygen configuration for the website generation.
* doc/api/libabigail.doxy: Output doxygen generation warnings into
a file.
* doc/Makefile.am: Support generating the website from doxygen.
Update the api generation relevant macros names for better
consistency. Make "make html" generate the website too. Make
"make clean" erase the website bits too. Add a 'website'
target to make the website.
2013-08-21 Dodji Seketeli <dodji@redhat.com>
Fix typo in CONTRIBUTING file
* CONTRIBUTING: Fix typo, courtesy of Mark Wielaard.
2013-08-19 Dodji Seketeli <dodji@redhat.com>
Remove autotools-generated files
* Makefile.in: Remove this autotools-generated file. I know that
people in the GCC-realm like storing these autotools-generated
files into the source control system, but I believe in this day
and age, this is annoying (to say the least) for the project
developers for no good reason. Requiring (the ubiquitous)
autoconf for building from source is no big deal today, and typing
"autoreconf" is not hard to do, really. And it saves the
developers for having to update a bunch of boilerplate
automatically generated files into the source control system; this
is really unnecessary noise and it is a commonly accepted good
practice to avoid doing it these days. To help people who do not
know how to handle this, there is a COMPILING file in the source
tree that explains how to build the project from sources.
* aclocal.m4: Likewise.
* configure: Likewise.
* include/Makefile.in: Likewise.
* src/Makefile.in: Likewise.
* doc/Makefile.in: Likewise.
* tests/Makefile.in: Likewise.
2013-08-19 Dodji Seketeli <dodji@redhat.com>
Add a new COMPILING file explaining how to build the package
* COMPILING: New file.
2013-08-14 Dodji Seketeli <dodji@redhat.com>
Remove name of unused parameter in decl_base::traverse.
* src/abg-ir.c (decl_base::traverse): Remove name of unused parameter.
2013-08-14 Dodji Seketeli <dodji@redhat.com>
install headers in $includedir/libabigail
* include/Makefile.am: Install headers in $includedir/libabigail
2013-08-14 Dodji Seketeli <dodji@redhat.com>
For usage from within GCC set header path to $includedir/libabigail
* abigail.m4: The include path used for compilation goes to
$includedir/libabigail.
2013-08-08 Benjamin Kosnik <bkoz@redhat.com>
Separate out bits from the ir header.
* include/abg-irfwd.h: Move to...
* include/abg-fwd.h: ...this.
* include/abg-ir.h (traverse_base): Move to...
* include/abg-traverse.h: ...here. New.
* include/abg-ir.h (location, location_manager, translation_unit):
Move to...
* include/abg-corpus.h: ...here.
* include/Makefile.am: Adjust.
* include/Makefile.in: Regenerate.
2013-08-07 Benjamin Kosnik <bkoz@redhat.com>
Template naming compression.
* include/abg-ir.h: Template naming compressions.
(class_template_decl): To class_tdecl.
(function_template_decl): To function_tdecl.
(template_type_parameter): To type_tparameter.
(template_non_type_parameter): To non_type_tparameter.
(template_template_parameter): To template_tparameter.
(tmpl_parm_type_composition): To type_composition.
* include/abg-irfwd.h: Same.
* src/abg-hash.cc: Same.
* src/abg-ir.cc: Same.
* src/abg-reader.cc: Same.
2013-08-07 Benjamin Kosnik <bkoz@redhat.com>
Slight change to doxy config.
* doc/api/libabigail.doxy: Turn off namespace scopes, on all the viz.
2013-08-07 Benjamin Kosnik <bkoz@redhat.com>
Move class_decl nested types out-of-line.
* include/abg-ir.h (class_decl): Move nested types out of line.
2013-08-07 Benjamin Kosnik <bkoz@redhat.com>
Rename class_decl::method to class_decl::method_base.
* include/abg-ir.h (class_decl::member): To member_base.
* src/abg-hash.cc: Same.
* src/abg-ir.cc: Same.
* src/abg-writer.cc: Same.
2013-08-07 Benjamin Kosnik <bkoz@redhat.com>
Nest hashers.
* include/abg-ir.h: Nest all hashers.
* include/abg-irfwd.h (abigail): Don't inject std::tr1::hash.
Remove hasher forward declarations.
* include/abg-hash.h: Tweak.
* src/abg-hash.cc: Define hashers here.
* src/abg-ir.cc: Adjust for above.
* src/abg-reader.cc: Same.
* src/abg-writer.cc: Same.
2013-08-06 Benjamin Kosnik <bkoz@redhat.com>
Rename abi_corpus to corpus
* include/abg-corpus.h (abi_corpus): Change to corpus.
* include/abg-hash.h: Tweaks.
* include/abg-libxml-utils.h: Same.
2013-08-06 Benjamin Kosnik <bkoz@redhat.com>
Simplify interface for serializing/deserializing translation_units.
* include/abg-ir.h (translation_unit::read): New member function.
(translation_unit::write): Same.
* src/abg-reader.cc (translation_unit::read): Define.
* src/abg-writer.cc (translation_unit::write): Define.
* include/abg-reader.h: Remove.
* include/abg-writer.h: Remove.
* include/Makefile.am (headers): Same.
* include/Makefile.in: Regenerate.
2013-08-06 Benjamin Kosnik <bkoz@redhat.com>
First pass clean reading API.
* include/abg-reader.h (read_file): Remove extraneous file parameter.
* src/abg-reader.cc: Same.
* tests/test-read-write.cc: Adjust.
2013-08-06 Benjamin Kosnik <bkoz@redhat.com>
Rename traversable to traversable_base, move up the _decl hierarchy via decl_base derivation.
* include/abg-ir.h (traversable): To traversable_base.
(decl_base): Inherit from traversable_base.
(decl_base::traverse): Null definition.
(function_decl, etc.): Remove traversable_base as base class.
2013-08-06 Benjamin Kosnik <bkoz@redhat.com>
Standardize typedef naming. Plural form is the container form, smart_ptr types are type + _sptr.
* include/abg-ir.h (scope_decl): Add declarations, scopes as types.
(function_type): Add parameter_sptr, parameters as types.
(enum_type_decl): Add type_sptr, enumerators as types.
(class_decl): Adjust typedefs for consistency. Change
base_specs_type to base_specs, member_types_type to member_types,
data_members_type to data_members, member_functions_type to
member_functions, member_function_templates_type to
member_function_templates, member_class_templates_type to
member_class_templates.
2013-08-02 Benjamin Kosnik <bkoz@redhat.com>
Doxygen markup fixes final.
* include/abg-config.h: Doxygen cleanups round two.
* include/abg-hash.h: Same.
* include/abg-ir.h: Same.
* include/abg-irfwd.h: Same.
* include/abg-libxml-utils.h: Same.
* src/abg-config.cc: Same.
* src/abg-hash.cc: Same.
* src/abg-ir.cc: Same.
* src/abg-reader.cc: Same.
* src/abg-writer.cc: Same.
2013-08-01 Benjamin Kosnik <bkoz@redhat.com>
Forward decls for abg-ir.h, doxygen fixups, restyle.
* include/abg-irfwd.h: New file for forward declarations.
* include/Makefile.am: Add new header.
* include/Makefile.in: Regenerate.
* include/*: Forward declare, doxygen fixups, restyle.
* src/*: Same.
* src/abg-corpus.cc: Empty, removed.
* doc/api/libabigail.doxy: Tweak.
2013-08-01 Benjamin Kosnik <bkoz@redhat.com>
Add virtual dtor to translation_unit.
* include/abg-ir.h (translation_unit): Add virtual dtor.
* src/abg-ir.cc: Define.
2013-08-01 Benjamin Kosnik <bkoz@redhat.com>
Adjust doxygen input path.
* doc/api/libabigail.doxy: Adjust include directory.
2013-08-01 Benjamin Kosnik <bkoz@redhat.com>
Collapse subdir of include to include.
* include/libabigail/abg-*.h: Move to...
* include/abg-*.h
* include/libabigail: Remove.
* configure.ac: Adjust include location from libabigail/include to
include.
* Makefile.in: Same.
* aclocal.m4: Same.
* configure: Same.
* doc/Makefile.in: Same.
* include/Makefile.am: Same.
* src/Makefile.am: Same.
* src/Makefile.in: Same.
* tests/Makefile.am: Same.
* tests/Makefile.in: Same.
2013-07-23 Dodji Seketeli <dodji@seketeli.org>
Update autotool auto-generated files
* Makefile.in: Updated.
* aclocal.m4: Likewise.
* configure: Likewise.
* doc/Makefile.in: Likewise.
* src/Makefile.in: Likewise.
* tests/Makefile.in: Likewise.
2013-07-20 Dodji Seketeli <dodji@seketeli.org>
Implement a translation unit traversal API
* include/libabigail/abg-ir.h (struct ir_node_visitor, struct
traversable): New interfaces.
(translation_unit, scope_decl, type_decl, qualified_type_def)
(pointer_type_def, reference_type_def, enum_type_decl)
(typedef_decl, var_decl, function_decl, data_member)
(member_function, member_function_template)
(member_class_template): Implement the traversable interface,
overload the traversable::traverse pure virtual function.
* src/abg-ir.cc ({translation_unit, scope_decl, type_decl,
namespace_decl, qualified_type_def, pointer_type_def,
reference_type_def, enum_type_decl, typedef_decl, var_decl,
function_decl, class_decl::member_function, class_decl,
class_decl::data_member, class_decl::member_function_template,
class_decl::member_class_template, function_template_decl,
class_template_decl, }::traverse): Implement traversal.
(ir_node_visitor::visit): New method, overloaded for the types
above, which implement the traversable interface.
* tests/test-walker.cc: New test case program to showcase how to
use the new traversal API.
* tests/makefile.am: Add test-walker.cc to the build system.
2013-07-19 Dodji Seketeli <dodji@seketeli.org>
By default, statically link libabigail with whoever uses abigail.m4
* abigail.m4: Make $abigaillibs statically link libabigail by default.
2013-07-19 Dodji Seketeli <dodji@seketeli.org>
Move static member definition to abg-viz-dot.cc file
* include/libabigail/abg-viz-dot.h: Move definition of
node_base::_M_count_total to ...
* src/abg-viz-dot.cc: ... here.
2013-07-19 Dodji Seketeli <dodji@seketeli.org>
Put headers in include/libabigail
* include/libabigail: New directory.
* include/Makefile.am: New file.
* include/libabigail/Makefile.am: New file.
* src/abg-*.h: Move these in include/libabigail/*.h
* src/Makefile.am: Set -I option to look for headers in include/libabigail
* doc/api/libabigail.doxy: Look for headers in include/libabigail
* tests/Makefile.am: Set -I option to look for headers in include/libabigail
* abigail.m4: Set includedir to $prefix/include/libabigail for
library used as a dep, or to srcdir/libabigail/include/libabigail
in GCC source tree.
* configure.ac: Add Makefile.am in include and include/libabigail
* abigail.m4: Look for headers in include/libabigail when the
libabigail is in in the source tree and in $incdir/libabigail when
it is installed as a dependency.
2013-07-18 Benjamin Kosnik <bkoz@redhat.com>
Install into docdir, turn off collaboration graphs.
* doc/Makefile.am (doc-install-html-doxygen): Install generated
files into docdir.
* doc/api/libabigail.doxy (COLLABORATION_GRAPH): Turn off.
2013-07-18 Benjamin Kosnik <bkoz@redhat.com>
Fix dependencies for api/html output directory.
* doc/Makefile.am: Create abi output directory.
2013-07-16 Dodji Seketeli <dodji@seketeli.org>
Prepare for publishing
* COMMIT-LOG-GUIDELINES: New file.
* CONTRIBUTING: New file.
* README: Amended to refer to the first files above.
2013-07-16 Dodji Seketeli <dodji@seketeli.org>
LGPLv3 License the library
* COPYING-LGPLV3: New file.
* abg-config.cc: License the file to LGPLv3.
* abg-config.h: Likewise.
* abg-corpus.cc: Likewise.
* abg-corpus.h: Likewise.
* abg-hash.cc: Likewise.
* abg-hash.h: Likewise.
* abg-ir.cc: Likewise.
* abg-ir.h: Likewise.
* abg-libxml-utils.cc: Likewise.
* abg-libxml-utils.h: Likewise.
* abg-reader.cc: Likewise.
* abg-reader.h: Likewise.
* abg-writer.cc: Likewise.
* abg-writer.h: Likewise.
* src/abg-viz-common.cc: Likewise.
* src/abg-viz-common.h: Likewise.
* src/abg-viz-dot.cc: Likewise.
* src/abg-viz-dot.h: Likewise.
* src/abg-viz-svg.cc: Likewise.
* src/abg-viz-svg.h: Likewise.
* tests/test-read-write.cc: Likewise.
* tests/test-utils.cc: Likewise.
* tests/test-utils.h: Likewise.
2013-07-17 Dodji Seketeli <dodji@seketeli.org>
Add assert.h in abg-ir.cc
* src/abg-ir.cc: Add missing assert.h
2013-07-17 Dodji Seketeli <dodji@seketeli.org>
Fix missing license blurbs
* src/abg-config.cc: Fix licensing blurb.
* src/abg-config.h: Likewise.
* src/abg-corpus.cc: Likewise.
* src/abg-corpus.h: Likewise.
* src/abg-ir.cc: Likewise.
* src/abg-ir.h: Likewise.
* src/abg-reader.cc: Likewise.
* src/abg-writer.cc: Likewise.
2013-07-02 Benjamin Kosnik <bkoz@redhat.com>
Correct DOT merge.
* src/abg-viz-common.h: Use _M_attributes for attribute overflows.
* src/abg-viz-dot.h: Merge in correct node_base.
* src/abg-viz-dot.cc: Same.
* tests/test-dot.cc: Correct examples.
* tests/Makefile.am: Add .gv to CLEANFILES.
* tests/Makefile.in: Regenerate.
2013-07-02 Benjamin Kosnik <bkoz@redhat.com>
Pull out common style type.
* src/abg-viz-common.h: Pull out common style type.
* src/abg-viz-dot.cc: Adjust scoping.
* src/abg-viz-common.cc: Same.
* src/abg-viz-dot.h: Use common style class.
* src/abg-viz-svg.h: Same.
2013-07-02 Benjamin Kosnik <bkoz@redhat.com>
Commonize visualization support.
* src/abg-viz-svg.h: Move common code to...
* src/abg-viz-dot.h: Move common code to...
* src/abg-viz-common.h: ...here. New.
* src/abg-viz-svg.cc: Move common code to...
* src/abg-viz-common.cc: ...here. New.
* src/Makefile.am: Add abg-viz-common.cc, abg-viz-common.h
* src/Makefile.in: Regenerate.
2013-07-01 Benjamin Kosnik <bkoz@redhat.com>
Initial DOT work.
* doc/vizualization/layout/scripts/
(inkscape_export_svg_to_plain_svg.sh): Move...
(inkscape_export_svg_to_png_and_pdf.sh): Move...
* scripts: ..here. New toplevel directory.
* scripts/scripts/dot_to_png.sh: New.
* scripts/scripts/dot_to_svg.sh: New.
* src/Makefile.am: Add abg-viz-dot.cc, abg-viz-dot.h.
* tests/Makefile.am: Add test-dot.cc.
* src/abg-viz-dot.cc: New.
* src/abg-viz-dot.h: New.
* tests/test-dot.cc: New.
* doc/vizualization/graph: New.
* doc/vizualization/graph/gv/sa-A.gv: New.
* doc/vizualization/graph/gv/sa-B.gv: New.
* doc/vizualization/graph/gv/sa-C1.gv: New.
* doc/vizualization/graph/gv/sa-C2.gv: New.
* doc/vizualization/graph/gv/sa-C3.gv: New.
* doc/vizualization/graph/gv/sa-C4.gv: New.
* doc/vizualization/graph/gv/sa-D1.gv: New.
* doc/vizualization/graph/gv/sa-D2.gv: New.
* doc/vizualization/graph/gv/sa-D2v.gv: New.
* doc/vizualization/graph/gv/sa-D3.gv: New.
* doc/vizualization/graph/gv/sa-D3v.gv: New.
* doc/vizualization/graph/gv/sa-D4v.gv: New.
* doc/vizualization/graph/gv/sa-D5v1.gv: New.
* doc/vizualization/graph/gv/sa-D5v2.gv: New.
* doc/vizualization/graph/gv/sa-DD1.gv: New.
* doc/vizualization/graph/gv/sa-DD2.gv: New.
* doc/vizualization/graph/gv/sa-DD3.gv: New.
* doc/vizualization/graph/gv/sa-DD4.gv: New.
* doc/vizualization/graph/gv/sa-DD5.gv: New.
* doc/vizualization/graph/gv/sa-base.gv: New.
* doc/vizualization/graph/png/sa-A.png: New.
* doc/vizualization/graph/png/sa-B.png: New.
* doc/vizualization/graph/png/sa-C1.png: New.
* doc/vizualization/graph/png/sa-C2.png: New.
* doc/vizualization/graph/png/sa-C3.png: New.
* doc/vizualization/graph/png/sa-C4.png: New.
* doc/vizualization/graph/png/sa-D1.png: New.
* doc/vizualization/graph/png/sa-D2.png: New.
* doc/vizualization/graph/png/sa-D2v.png: New.
* doc/vizualization/graph/png/sa-D3.png: New.
* doc/vizualization/graph/png/sa-D3v.png: New.
* doc/vizualization/graph/png/sa-D4v.png: New.
* doc/vizualization/graph/png/sa-D5v1.png: New.
* doc/vizualization/graph/png/sa-D5v2.png: New.
* doc/vizualization/graph/png/sa-DD1.png: New.
* doc/vizualization/graph/png/sa-DD2.png: New.
* doc/vizualization/graph/png/sa-DD3.png: New.
* doc/vizualization/graph/png/sa-DD4.png: New.
* doc/vizualization/graph/png/sa-DD5.png: New.
* doc/vizualization/graph/png/sa-base.png: New.
* doc/vizualization/graph/sources/sa-A.cc: New.
* doc/vizualization/graph/sources/sa-B.cc: New.
* doc/vizualization/graph/sources/sa-C.cc: New.
* doc/vizualization/graph/sources/sa-D.cc: New.
* doc/vizualization/graph/sources/sa-DD.cc: New.
* doc/vizualization/graph/sources/sa-base.cc: New.
* doc/vizualization/graph/svg/sa-A.svg: New.
* doc/vizualization/graph/svg/sa-B.svg: New.
* doc/vizualization/graph/svg/sa-C1.svg: New.
* doc/vizualization/graph/svg/sa-C2.svg: New.
* doc/vizualization/graph/svg/sa-C3.svg: New.
* doc/vizualization/graph/svg/sa-C4.svg: New.
* doc/vizualization/graph/svg/sa-D1.svg: New.
* doc/vizualization/graph/svg/sa-D2.svg: New.
* doc/vizualization/graph/svg/sa-D2v.svg: New.
* doc/vizualization/graph/svg/sa-D3.svg: New.
* doc/vizualization/graph/svg/sa-D3v.svg: New.
* doc/vizualization/graph/svg/sa-D4v.svg: New.
* doc/vizualization/graph/svg/sa-D5v1.svg: New.
* doc/vizualization/graph/svg/sa-D5v2.svg: New.
* doc/vizualization/graph/svg/sa-DD1.svg: New.
* doc/vizualization/graph/svg/sa-DD2.svg: New.
* doc/vizualization/graph/svg/sa-DD3.svg: New.
* doc/vizualization/graph/svg/sa-DD4.svg: New.
* doc/vizualization/graph/svg/sa-DD5.svg: New.
* doc/vizualization/graph/svg/sa-base.svg: New.
2013-07-01 Benjamin Kosnik <bkoz@redhat.com>
Regenerate build/configure.
* aclocal.m4: Regenerate build/configure.
* configure: Regenerate build/configure.
2013-06-06 Benjamin Kosnik <bkoz@redhat.com>
Regenerate configure files.
* Makefile.in: Regenerate configure files.
* aclocal.m4: Regenerate configure files.
* configure: Regenerate configure files.
* doc/Makefile.in: Regenerate configure files.
* src/Makefile.in: Regenerate configure files.
* tests/Makefile.in: Regenerate configure files.
2013-05-28 Benjamin Kosnik <bkoz@redhat.com>
Add svg generation.
* src/Makefile.am: Add abg-viz-svg.cc, abg-viz-svg.h.
* tests/Makefile.am: Add test-svg.cc.
* src/abg-viz-svg.cc: New.
* src/abg-viz-svg.h: New.
* tests/test-svg.cc: New.
2013-05-22 Benjamin Kosnik <bkoz@redhat.com>
Remove ChangeLog
* ChangeLog: Remove content.
2013-05-21 Benjamin Kosnik <bkoz@redhat.com>
Fixup abg-version.h merge duplicate.
* configure.ac: Remove src/abg-version.h merge duplicate.
2013-05-20 Benjamin Kosnik <bkoz@redhat.com>
Add doc/visualization/layout.
* doc/vizualization/layout: New.
* doc/vizualization/layout/pdf/sa-A.pdf: New.
* doc/vizualization/layout/pdf/sa-B.pdf: New.
* doc/vizualization/layout/pdf/sa-C1.pdf: New.
* doc/vizualization/layout/pdf/sa-C2.pdf: New.
* doc/vizualization/layout/pdf/sa-C3.pdf: New.
* doc/vizualization/layout/pdf/sa-D1.pdf: New.
* doc/vizualization/layout/pdf/sa-D2.pdf: New.
* doc/vizualization/layout/pdf/sa-D2v.pdf: New.
* doc/vizualization/layout/pdf/sa-D3.pdf: New.
* doc/vizualization/layout/pdf/sa-D3v.pdf: New.
* doc/vizualization/layout/pdf/sa-D4v.pdf: New.
* doc/vizualization/layout/pdf/sa-DD1.pdf: New.
* doc/vizualization/layout/pdf/sa-DD2.pdf: New.
* doc/vizualization/layout/pdf/sa-DD3.pdf: New.
* doc/vizualization/layout/pdf/sa-DD4.pdf: New.
* doc/vizualization/layout/pdf/sa-DD5.pdf: New.
* doc/vizualization/layout/pdf/sa-base.pdf: New.
* doc/vizualization/layout/png/sa-A.png: New.
* doc/vizualization/layout/png/sa-B.png: New.
* doc/vizualization/layout/png/sa-C1.png: New.
* doc/vizualization/layout/png/sa-C2.png: New.
* doc/vizualization/layout/png/sa-C3.png: New.
* doc/vizualization/layout/png/sa-D1.png: New.
* doc/vizualization/layout/png/sa-D2.png: New.
* doc/vizualization/layout/png/sa-D2v.png: New.
* doc/vizualization/layout/png/sa-D3.png: New.
* doc/vizualization/layout/png/sa-D3v.png: New.
* doc/vizualization/layout/png/sa-D4v.png: New.
* doc/vizualization/layout/png/sa-DD1.png: New.
* doc/vizualization/layout/png/sa-DD2.png: New.
* doc/vizualization/layout/png/sa-DD3.png: New.
* doc/vizualization/layout/png/sa-DD4.png: New.
* doc/vizualization/layout/png/sa-DD5.png: New.
* doc/vizualization/layout/png/sa-base.png: New.
* doc/vizualization/layout/scripts/
(inkscape_export_svg_to_plain_svg.sh): New.
(inkscape_export_svg_to_png_and_pdf.sh): New.
* doc/vizualization/layout/sources/sa-A.cc: New.
* doc/vizualization/layout/sources/sa-B.cc: New.
* doc/vizualization/layout/sources/sa-C.cc: New.
* doc/vizualization/layout/sources/sa-D.cc: New.
* doc/vizualization/layout/sources/sa-DD.cc: New.
* doc/vizualization/layout/sources/sa-base.cc: New.
* doc/vizualization/layout/svg/sa-A.svg: New.
* doc/vizualization/layout/svg/sa-B.svg: New.
* doc/vizualization/layout/svg/sa-C1.svg: New.
* doc/vizualization/layout/svg/sa-C2.svg: New.
* doc/vizualization/layout/svg/sa-C3.svg: New.
* doc/vizualization/layout/svg/sa-D1.svg: New.
* doc/vizualization/layout/svg/sa-D2.svg: New.
* doc/vizualization/layout/svg/sa-D2v.svg: New.
* doc/vizualization/layout/svg/sa-D3.svg: New.
* doc/vizualization/layout/svg/sa-D3v.svg: New.
* doc/vizualization/layout/svg/sa-D4v.svg: New.
* doc/vizualization/layout/svg/sa-DD1.svg: New.
* doc/vizualization/layout/svg/sa-DD2.svg: New.
* doc/vizualization/layout/svg/sa-DD3.svg: New.
* doc/vizualization/layout/svg/sa-DD4.svg: New.
* doc/vizualization/layout/svg/sa-DD5.svg: New.
* doc/vizualization/layout/svg/sa-base.svg: New.
2013-05-20 Benjamin Kosnik <bkoz@redhat.com>
Generate abg-version.h at configure time.
* configure.ac: Add src/abg-version.h to AC_CONFIG_FILES.
* src/Makefile.am: Remove abg-version.h generation rules.
* src/abg-version.h.in: New.
2013-04-02 Benjamin Kosnik <bkoz@redhat.com>
Add doc dir. Add Doxgen api generation rules.
* doc: Add.
* doc/Makefile.am (html, install-html): Add.
* doc/Makefile.in: Add.
* doc/api/libabigail.doxy: Add doxygen config.
* src/abg-*: Add @file markup.
2013-03-27 Benjamin Kosnik <bkoz@redhat.com>
Add configure to source control
* configure: Add.
* src/abg-corpus.cc: include stdexcept
2013-06-25 Dodji Seketeli <dodji@redhat.com>
Support offsets and virtual attribute in base class specifiers
* src/abg-ir.h (class_decl::base_spec::base_spec): Take an offset
and a is_virtual flag.
(class_decl::base_spec::{get_is_virtual, get_offset_in_bits}): New
methods.
(class_decl::has_no_base_nor_member): New method declaration..
* src/abg-ir.cc (class_decl::base_spec::base_spec): Take an offset
and a is_virtual flag
(class_decl::has_no_base_nor_member): Define it.
* src/abg-reader.cc (read_offset_in_bits): Renamed
read_var_offset_in_bits into this.
(read_is_virtual): New static function.
(build_class_decl): Read the 'layout-offset-in-bits' and the
'is-virtual' of the base class specifier. Adjust for the
read_var_offset_in_bits -> read_offset_in_bits rename.
* src/abg-writer.cc (write_layout_offset): New overload for the
base class specifiers.
(write_class_decl): If the class has no member or base class, make
it a proper empty xml element. Write the offset and the
is-virtual attribute.
* tests/data/test-read-write/test20.xml: New test input data.
* tests/test-read-write.cc: De-serialize the test above, serialize
it back and compare that both versions are the same.
2013-06-22 Dodji Seketeli <dodji@redhat.com>
Iron out support for simple base classes.
* src/abg-ir.h (class_decl::base_spec::base_spec): Move this
out-of-line. Add a new constructor for clients compiled without
RTTI.
* src/abg-ir.cc (class_decl::base_spec::base_spec): This is now
here out-of-line. Define the new constructor for clients compiled
without RTTI.
* tests/data/test-read-write/test19.xml: New test case input for
base classes.
* tests/test-read-write.cc: De-serialize and serialize the new
test case input above.
2013-06-21 Dodji Seketeli <dodji@redhat.com>
Fix handling of forward decl of classes
* abg-ir.h (class_decl::set_earlier_declaration): Move this
out-of-line and add an overload.
* src/abg-ir.cc (class_decl::set_earlier_declaration): Moved this
out-of-line here and add an overload.
* src/abg-reader.cc (build_class_decl): Really read the
'decl-of-decl-id' property. Do not make the definition use the id
of the declaration. Both have their id.
* src/abg-writer.cc (write_class_decl): Put a space before the
property "def-of-decl-id".
* tests/data/test-read-write/test18.xml: New test input.
* tests/test-read-write.cc: De-serialize this new input, serialize
it back and make sure both versions are identical.
2013-06-21 Dodji Seketeli <dodji@redhat.com>
Serialize the layout offset of class data members.
* src/abg-writer.cc (write_layout_offset): New function.
(write_class_decl): Serialize the layout offset.
2013-06-21 Dodji Seketeli <dodji@redhat.com>
Support Bitwise OR for qualified_type_def::CV better
* src/abg-ir.h (qualified_type_def::CV_RESTRICT): New enumerator
for the qualified_type_def::CV enum.
(operator|(qualified_type_def::CV, qualified_type_def::CV)): New
declaration.
* src/abg-ir.cc (operator|(qualified_type_def::CV,
qualified_type_def::CV)): New definition.
* src/abg-reader.cc (build_qualified_type_decl): No need for
casting the result of bitwise or between instances of
qualified_type_def::CV.
2013-06-14 Dodji Seketeli <dodji@seketeli.org>
Support method type/decl, variadic functions, class declarations-only
* src/abg-ir.h (function_decl::parameter::parameter): New
constructor with variadic parameter marker.
(function_decl::m_type): Make this protected to let method_decl
inheriting class to access it.
(function_decl::get_type): Move this out-of-line.
(class method_type, method_type_hash): New types.
(enum class_decl::access_specifier): Add no_access new enumerator.
(class_decl::data_member::data_member): Move this out-of-line.
(class_decl::data_member::~data_member): Declare virtual
destructor.
(class method_decl): New class.
(class member_function): Make this inherit method_decl, instead of
function_decl.
(class_decl::class_decl): New constructors.
(class_decl::{hashing_started, is_declaration_only,
set_earlier_declaration, get_earlier_declaration}): New methods.
* src/abg-ir.cc (add_decl_to_scope): If a decl is already in a
scope, don't add it to this scope.
(get_global_scope): Make this work when passed an instance of
global_scope.
(dynamic_type_hash::operator()): Add support for method_type.
(method_type::{method_type, set_class_type, ~method_type, })
(method_type_hash::operator()): New defintions.
(function_decl::get_type, class_decl::class_decl): Move these
out-of-line here.
(class_decl::method_decl::{method_decl, ~method_decl, get_type}):
New definitions.
(class_decl::member_function::member_function): Move this
out-of-line here. Support method_decl.
(class_decl::data_member::data_member): Likewise.
(class_decl_hash::operator()): Guard this against endless loop.
* src/abg-reader.cc (write_class_is_declaration_only): New static
function.
(write_var_decl): Take a flag to write the mangled name or not.
(write_function_decl): Take a flag to skip the first parameter.
(write_cdtor_const_static): Use 'yes' instead of 'true' as value
of the properties.
(write_decl, write_function_template_decl): Adjust wrt the new
signatures of write_var_decl and write_function_decl.
(write_enum_type_decl): Simplify call to write_location.
(write_class_decl): Support serializing declaration-only classes.
* src/abg-writer.cc:
* tests/data/test-read-write/test17.xml: New test input.
* tests/test-read-write.cc: De-serialize the above, and serialize it back.
* tests/data/test-read-write/test10.xml: Update this test.
2013-06-01 Dodji Seketeli <dodji@redhat.com>
Support function_type and adapt a function_decl to use it
* src/abg-ir.h (class function_type): Forward decl prior to class
function_decl.
(function_decl::parameter): Pass string by const reference. Add a
variadic marker member and initialize it.
(function_decl::parameter::get_type): Add a non-const overload.
(function_decl::parameter::get_variadic_marker): New getter.
(function_decl::function_decl) Take a const reference to a vector
for parameters, type size/alignment. Add two overloads that takes a
pointer to function_type.
(function_decl::get_parameters): Move this out-of-line.
(function_decl::append_parameter(s)): Renamed
function_decl::add_parameter(s) into these. Move it out-of-line.
Add an overload.
(function_decl::{get_type, set_type}): New declaration.
(function_decl::get_return_type): Move this out-of-line.
(function_decl::is_variadic): New in-line function.
(function_decl::m_type): New data member.
(function_decl::{m_parms, m_return_type}): Remove. This are now
carried by function_decl::m_type.
(class function_type, struct function_type_hash): New
declarations.
(member_function::member_function): Take a vector of pointers to
parameters. Take size/align of the type of the member function.
Adjust initialization.
* src/abg-ir.cc (dynamic_type_hash): Hash instance of
function_type accessed through a pointer.
(function_type::{operator==, ~function_type})
(function_type_hash::operaror(), function_decl::{get_return_type,
}, function_decl::parameter::hash::operator()): New definitions.
(function_decl::function_decl): The out-of-line definitions of the
declarations above.
(function_decl::append_parameter): Moved this out-of-line from
inline function_decl::add_parameter. Make this rely on the
underlying m_type.
(function_decl::operator==): Adjust for use of vector for the
parameters. Also, there is no need anymore to compare the
parameters or the return types as they are compared by the
comparison of the function types.
* src/abg-reader.cc (build_function_decl): Read the new size/alignment
attributes on the function-decl element. Build a function_type
and use it to build the function_decl. Parameters and return type
are now hung off of the function_type.
(handle_function_decl): use build_function_decl.
* src/abg-writer.cc (write_function_decl): Write the new
size/alignment properties of the function-decl element. Adjust
for the use of vectors for function parameters now.
* tests/data/test-read-write/test10.xml: Adjust for the presence
of size/alignment properties in the function-decl element now.
* tests/data/test-read-write/test11.xml: Likewise.
* tests/data/test-read-write/test12.xml: Likewise.
* tests/data/test-read-write/test13.xml: Likewise.
* tests/data/test-read-write/test14.xml: Likewise.
* tests/data/test-read-write/test9.xml: Likewise.
2013-06-01 Dodji Seketeli <dodji@redhat.com>
Support null type hashing
* src/abg-ir.cc (dynamic_type_hash::operator()(const type_base* t)
const): Support hashing null type.
2013-05-23 Dodji Seketeli <dodji@redhat.com>
Add a couple of output file suffix configuration properties
* src/abg-config.h (config::{get_tu_instr_suffix,
set_tu_instr_suffix, get_tu_instr_archive_suffix,
set_tu_instr_archive_suffix}): New decls.
* src/abg-config.cc (config::{get_tu_instr_suffix,
set_tu_instr_suffix, get_tu_instr_archive_suffix,
set_tu_instr_archive_suffix}): New defs.
2013-05-23 Dodji Seketeli <dodji@redhat.com>
Add a new add_decl_to_scope overload
* src/abg-ir.h (add_decl_to_scope): New declaration.
* src/abg-ir.cc (add_decl_to_scope): New definition.
2013-05-23 Dodji Seketeli <dodji@redhat.com>
Ensure add_decl_to_scope properly updates the scope
* src/abg-ir.h (scope_decl::m_member_scopes)
(scope_decl::get_member_scopes): New declarations.
(scope_decl::add_member_decl): Move this to ...
* src/abg-ir.cc (scope_decl::add_member_decl): ... here. Make it
update the new scope_decl::m_member_scopes too.
2013-05-23 Dodji Seketeli <dodji@redhat.com>
Add translation_unit::get_path
* src/abg-ir.cc (translation_unit::get_path): New declaration.
* src/abg-ir.cc (translation_unit::get_path): New definition.
2013-05-23 Dodji Seketeli <dodji@redhat.com>
Link the global scope to its translation unit
* src/abg-ir.h (global_scope::global_scope): Take a translation
unit and initialize the tu member with it.
* src/abg-ir.cc (translation_unit::get_global_scope): Initialize
the global scope with its actual translation unit.
2013-05-23 Dodji Seketeli <dodji@redhat.com>
Have location numbers that are stable throughout translation unit editing
* src/abg-irc.cc (location_manager::create_new_location): Just
append the new expanded location to the end of the location
vectors, and return the new size of the vector as the location
number. That way we don't change the location number of an
expanded location that is already in the vector -- that change
happens if we keep the vector sorted during the insertion.
(location_manager::expand_location): The index of the expanded
location is the location number - 1.
2013-05-23 Dodji Seketeli <dodji@redhat.com>
Fix in-source detection of the library for GCC
* abigail.m4 (ABIGAIL_INIT): Don't forget to set abigaillibs when
we detect the library in the source tree, particularly for GCC.
2013-05-21 Dodji Seketeli <dodji@redhat.com>
Re-generate aclocal.m4
* aclocal.m4: Re-generate with autoconf 2.64.
2013-05-21 Benjamin Kosnik <bkoz@redhat.com>
Generate abg-version at configure time in builddir
* configure.ac: Add src/abg-version.h to AC_CONFIG_FILES.
* src/Makefile.am: Remote ad-hoc generation of abg-version.h from
here.
* src/abg-version.h.in: New file.
* configure: Re-generate.
* src/Makefile.in: Likewise.
2013-05-21 Dodji Seketeli <dodji@redhat.com>
add abigail.m4 to the distribution
* Makefile.am: Add abigail.m4 to the distribution.
* Makefile.in: Re-generate.
2013-05-10 Dodji Seketeli <dodji@redhat.com>
Pedantic fixes
* src/abg-ir.h (enum decl_base::binding): Remove trailing space.
(enum class_decl::access_specifier): Likewise.
2013-05-07 Dodji Seketeli <dodji@redhat.com>
Fix for building libabigail inside the GCC tree
* abigail.m4: Detect when we are in the GCC tree; disable version
check in that case.
2013-05-07 Dodji Seketeli <dodji@redhat.com>
Re-generate configury with autoconf 2.64
* abigail.m4: Add licence header.
* configure.ac: Re-generate configure script with autoconf 2.64
like for GCC.
2013-05-07 Dodji Seketeli <dodji@redhat.com>
Allow autoconf-based clients to detect the library
* configure.ac: Define the components of the version number as
autoconf variables. Set the version number to 0.1.0
* abigail.m4: New file
* Makefile.am: Add abigail.m4 to the build system. Install it in
$(datadir)/aclocal.
* src/Makefile.am: Generate and add abg-version.h from the version
number autoconf variable defined in configure.ac. Re-generate
abg-version.h each time configure.ac changes.
* src/abg-config.h (abigail_get_library_version): Declare ...
* src/abg-config.cc (abigail_get_library_version): ... and define
this wirth C linkage. This is useful for autoconf tests to test
for the presence of the library.
* configure: Re-generate.
* Makefile.in: Likewise.
* src/Makefile.in: Likewise.
* tests/Makefile.in: Likewise.
2013-05-03 Dodji Seketeli <dodji@redhat.com>
Build system fix for make distcheck
* Makefile.am: Support the doc sub-directory. We don't have a
COPYRIGHT file.
* src/Makefile.am: Don't prefix the file paths by the absolute
path of the src dir; current autotools know how to deal with it,
otherwise and it break them.
* tests/Makefile.am: Likewise. Make sure to remove the output of
the tests upon make clean.
* Makefile.in: Re-generate.
* aclocal.m4: Likewise.
* configure: Likewise.
* src/Makefile.in: Likewise.
* tests/Makefile.in: Likewise.
2013-05-02 Dodji Seketeli <dodji@redhat.com>
Initial support for member class templates
* src/abg-ir.cc (class_decl::add_member_function_template): Fix
comment.
(class_decl::add_member_class_template)
(class_decl::member_class_template::operator==)
(class_decl::member_class_template_hash::operator()): New
definitions.
(class_decl::operator==): Compare member templates. Fix logic.
(class_decl::data_member_hash::operator())
(class_decl::member_function_hash::operator())
(class_decl::member_function_template_hash::operator()): Don't
hash the is_static boolean as it's hashed as part of the 'member'
sub-object hashing.
(class_decl::member_function_template::operator==): Move this out
of line here, from the header file.
(class_decl_hash::operator()): Hash member class templates.
* src/abg-ir.h (class_decl::member::{m_is_static,is_static}): Add the is_static
boolean here, so that it's factorized out of the inherited classes
of this class.
(class_decl::data_member::{is_static, m_is_static})
(class_decl::member_function::{is_static, m_is_static})
(class_decl::member_function_template::{is_static, m_is_static}): Remove this
as it's now part of the base 'member' class.
(class_decl::data_member::operator==)
(class_decl::member_function::operator==): Don't compare the
is_static boolean as it's now compared as part of the 'member'
sub-object comparison.
(class_decl::member_function_template::operator==): Move this
out-of-line into src/abg-ir.cc.
(class class_decl::member_class_template, struct
class_decl::member_class_template_hash)
(class_decl::{add_member_class_template,
get_member_class_templates}): New declarations.
(class_decl::member_class_templates_type): New typedef.
* src/abg-reader.cc (build_class_decl): Support de-serializing
member class templates.
* src/abg-writer.cc (write_class_decl): Likewise, support
serializing member class templates.
* tests/data/test-read-write/test16.xml: New test input.
* tests/test-read-write.cc (int_out_specs[]): Add the new test
input to the list of inputs that are de-serialized and serialized
back.
* tests/Makefile.am: Add the new test input to the distribution.
2013-05-02 Dodji Seketeli <dodji@redhat.com>
Initial support of class templates
* src/abg-ir.cc (class_template_decl::class_template_decl)
(class_template_decl::set_pattern)
(class_template_decl::operator==)
(class_template_decl::~class_template_decl)
(class_template_decl_hash::operator())
(class_tmpl_shared_ptr_hash::operator()): New definitions.
* src/abg-ir.h (class class_template_decl, struct
class_tmpl_shared_ptr_hash, struct class_tmpl_shared_ptr_hash):
New declarations.
* src/abg-reader.cc (read_context::const_class_tmpl_map_it): New
typedef.
(read_context::get_fn_tmpl_decl): Fix comment.
(read_context::{get_class_tmpl_decl,key_class_tmpl_decl})
(build_class_template_decl, handle_class_template_decl): New
definitions.
(read_context::m_class_tmpl_map): New member.
(handle_element): Support "class-template-decl" xml elements
nodes.
(build_class_decl): Add missing bits to comment.
(build_function_template_decl): Fix spacing.
* src/abg-writer.cc (class_tmpl_shared_ptr_map): New typedef.
(write_context::m_class_tmpl_map): New member.
(write_context::get_id_for_class_tmpl, write_class_template_decl):
New definitions.
(write_template_parameters): Factorize this this out from ...
(write_function_template_decl): ... here.
(write_decl): Support writing instances of class_template_decl.
Fix spacing.
* tests/data/test-read-write/test15.xml: New test input.
* tests/Makefile.am: Add the new test15.xml input to the
distribution.
* tests/test-read-write.cc (in_out_specs): Add the new test15.xml
test to the list of serialized output to be de-serialized and
serialized back.
2013-05-02 Dodji Seketeli <dodji@redhat.com>
Fix function_tempalte_decl init & hashing
* src/abg-ir.cc (function_template_decl::operator==): Compare the
patterns, not a pointer to them.
(function_template_decl_hash::operator()): Don't try to hash null
patterns.
* src/abg-ir.h (function_template_decl::function_template_decl):
Use function_template_decl::set_pattern to set the pattern here.
2013-04-30 Dodji Seketeli <dodji@redhat.com>
Support member function templates
* src:abg-ir.h: Move template declarations before class
class_decl, so that class_decl can have member templates.
(class class_decl::member_function_template)
(class_decl::add_member_function_template)
(class_decl::{base_specs_type, member_types_type,
data_members_types, member_functions_type,
member_function_templates_type}): New declarations.
* src/abg-ir.cc (class_decl::add_member_function_template)
(class_decl::member_function_template_hash::operator()): New
definitions.
(class_decl_hash::operator()): Support hashing for member
function templates.
* src/abg-reader.cc (build_class_decl): Use the new
class_decl::{member_types_type, data_members_type,
member_functions_type, base_specs_type} types. Support member
function templates.
* src/abg-writer.cc (write_cdtor_const_static): New definition.
(write_class_decl): Support member function templates.
* tests/data/test-read-write/test14.xml: New input data.
* tests/Makefile.am: Add it to the distribution.
* tests/test-read-write.cc (InOutSpec int_out_specs): De-serialize
the new test input file, serialize it back and diff both results.
2013-04-25 Dodji Seketeli <dodji@redhat.com>
Inheritance fix
* src/abg-ir.h (class template_non_type_parameter): Make this
inherit decl_base virtually.
2013-04-25 Dodji Seketeli <dodji@redhat.com>
Small comment fix
* src/abg-ir.h (class template_decl): Fix comment.
2013-04-25 Dodji Seketeli <dodji@redhat.com>
Add some decl predicates
* src/abg-ir.h (is_at_global_scope): Rename
is_decl_at_global_scope into this.
(is_at_class_scope, is_at_template_scope)
(is_template_parameter, is_type)
(is_template_parm_composition_type)
(is_function_template_pattern, is_template_decl): New
declarations.
* src/abg-ir.cc (is_at_global_scope): Rename
is_decl_at_global_scope into this.
(is_at_class_scope, is_at_template_scope, is_template_parameter)
(is_type, is_template_parm_composition_type)
(is_function_template_pattern, is_template_decl): New definitions.
* src/abg-reader.cc (update_depth_info_of_read_context): Use the
new is_at_class_scope decl.
2013-04-25 Dodji Seketeli <dodji@redhat.com>
Support composing template type parameters
* src/abg-ir.h (class tmpl_parm_type_composition): New
declaration.
* src/abg-ir.cc
(tmpl_parm_type_composition::tmpl_parm_type_composition)
(tmpl_parm_type_composition::~tmpl_parm_type_composition): New
definitions.
* src/abg-reader.cc (build_tmpl_parm_type_composition): New
function.
(build_template_parameter): Support template parameter type
composition.
* src/abg-writer.cc (write_tmpl_parm_type_composition): New
function.
(write_template_non_type_parameter): Fix type-id attribute.
(write_template_parameter): Support template parameter type
composition.
* tests/data/test-read-write/test13.xml: New test input.
* tests/Makefile.am: Add it to the distribution.
* tests/test-read-write.cc (InOutSpec in_out_spec): Add test13.xml
to the list of xml file that are de-serialized and serialized back.
2013-04-24 Dodji Seketeli <dodji@redhat.com>
Fix depth management during the parsing
* src/abg-ir.cc (decl_base_hash::operator()): Don't hash the
context for decls in general.
* src/abg-reader.cc (read_context::push_decl_to_current_scope)
(read_context::push_and_key_type_decl): Add an overload that takes
a node and update_depth_info boolean.
(build_var_decl, build_type_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_enum_type_decl, build_type_decl)
(build_template_type_parameter, build_template_non_type_parameter)
(build_template_template_parameter, build_template_parameter)
(build_type): Make these functions take an update_depth_info
parameter. Pass it do read_context::push_and_key_type_decl or
read_context::push_decl_to_current_scope rather than call
update_read_context.
(build_function_decl, build_class_decl)
(build_function_template_decl): Change the seen_by_reader
parameter into update_depth_info. Pass the update_depth_info bool
to read_context::push_decl_to_current_scope rather than call
update_depth_info here.
(handle_class, handle_function_template_decl): Adjust.
* tests/data/test-read-write/test12.xml: Add new test input.
* tests/test-read-write.cc (InOutSpec in_out_specs): Add it to the
list of input to de-serialize, serialize back and compare the two.
* tests/Makefile.am: Add the new test input to the distribution.
2013-04-23 Dodji Seketeli <dodji@redhat.com>
Initial support for function templates
* src/abg-ir.h (function_decl::set_return_type): New inline
definition.
(class template_decl, struct template_decl_hash, class
template_parameter, struct template_parameter_hash, struct
dynamic_template_parameter_hash, struct
template_parameter_shared_ptr_hash, class template_type_parameter)
(struct template_type_parameter_hash, class
template_non_type_parameter, struct
template_non_type_parameter_hash, class
template_template_parameter, struct
template_template_parameter_hash, class function_template_decl)
(struct function_template_decl_hash, struct
fn_tmpl_shared_ptr_hash): New declarations.
* src/abg-ir.cc (dynamic_type_hash::operator()): Add hashing for
template template, and template type parameters.
(template_decl_hash::operator, template_decl::~template_decl)
(template_decl::operator==, template_parameter::operator==)
(template_parameter_hash::operator())
(dynamic_template_parameter_hash::operator())
(template_type_parameter::operator==)
(template_type_parameter::~template_type_parameter)
(template_type_parameter_hash::operator())
(template_non_type_parameter::operator==)
(template_non_type_parameter::~template_non_type_parameter)
(template_non_type_parameter_hash::operator())
(template_template_parameter::operator==)
(template_template_parameter::~template_template_parameter)
(template_template_parameter_hash::operator())
(function_template_decl::operator==)
(function_template_decl_hash::operator())
(fn_tmpl_shared_ptr_hash::operator())
(function_template_decl::~function_template_decl()): New
definitions.
* src/abg-reader.cc (read_context::get_fn_tmpl_decl)
(read_context::key_fn_tmpl_decl): New functions.
(read_context::m_fn_tmpl_map): New data member.
(read_context::key_type_decl): Renamed read_context::add_type_decl
into this.
(read_context::push_decl_to_current_scope): Renamed
read_context::finish_decl_creation into this. Add an assert.
(read_context::push_and_key_type_decl): Renamed
read_context::finish_type_decl_creation into this. Adjust to the
use of push_decl_to_current_scope and key_type_decl.
(build_function_template_decl, build_template_type_parameter)
(build_template_non_type_parameter)
(build_template_template_parameter, build_template_parameter)
(handle_function_template_decl): New functions.
(handle_element): Call handle_function_template_decl.
(build_function_decl): Take a bool parameter to update depth
information in parsing context. Move instantiation of
function_decl before parsing its xml sub-nodes. Update the depth
info in the parsing context if necessary. Push the newly
intantiated decl to scope. And then parse the sub nodes. Do not
forget to add the fn parameters and return type using
function_decl::add_parameter and function_decl::set_return_type.
(build_var_decl, build_type_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_enum_type_decl, build_typedef_decl, handled_type_decl)
(handle_qualified_type_decl, handle_pointer_type_def)
(handle_reference_type_def, handle_enum_type_decl)
(handle_typedef_decl, handle_var_decl, handle_function_decl)
(handle_class_decl): Adjust.
(build_class_decl): Take a bool parameter to update depth
information in parsing context. Add comment. Wait for the class
members to be built, before keying (and thus hashing it) the
class.
(build_type): Fix logic, and adjust.
* src/abg-writer.cc (write_context::type_has_existing_id)
(write_context::get_id_for_fn_tmpl, write_template_type_parameter)
(write_template_non_type_parameter)
(write_template_template_parameter, write_template_parameter)
(write_function_template_decl): New functions.
(write_context::get_id_for_type): Simplify logic.
(write_decl): Support writing function template.
* tests/data/test-read-write/test11.xml: New test input.
* tests/test-read-write.cc (InoutSpec in_out_specs[]):
De-serialize the new test11.xml test, serialize it back and diff
output and input.
* tests/Makefile.am: Add test11.xml to the distribution.
2013-04-23 Dodji Seketeli <dodji@redhat.com>
Mangled name of a scope_decl is its name
* src/abg-ir.h (scope_decl::scope_decl): The mangled name is the name.
2013-04-23 Dodji Seketeli <dodji@redhat.com>
Update scope when adding class members
* src/abg-ir.h (class_decl::add_member_type)
(class_decl::add_data_member, class_decl::add_member_function):
Move the inline implementation of these functions ...
* src:abg-ir.cc (class_decl::add_member_type)
(class_decl::add_data_member, class_decl::add_member_function):
... here. Augment their implementation to properly update the
scope of the member.
2013-04-23 Dodji Seketeli <dodji@redhat.com>
Rename class_decl::member_type::get_type into as_type
* src/abg-ir.h (class_decl::member_type::get_type): Rename this
into class_decl::member_type::as_type.
* src/abg-writer.cc (write_class_decl): Adjust.
2013-04-23 Dodji Seketeli <dodji@redhat.com>
Avoid having multiple sub-objects of base classes
* src/abg-ir.cc (decl_base::decl_base): Remove useless definition.
(type_base::type_base): Remove default arguments from parameters.
(scope_type_decl::scope_type_decl)
(namespace_decl::namespace_decl): Call the constructors for the
virtual bases explicitly.
* src/abg-ir.h (class scope_decl): Perform virtual inheritance of
decl_base.
(global_scope::global_scope): Call virtual base decl_base's
constructor directly.
(class type_decl): Inherit from decl_base and type_base
virtually.
(class scope_type_decl): Inherit from type_base virtually.
(class qualified_type_def, pointer_type_def, reference_type_def)
(class enum_type_decl, typedef_decl): Inherit from type_base and
decl_base virtually.
(class var_decl, function_decl): Inherit from decl_base virtually.
(class class_decl::member): Don't inherit from anything and adjust
constructor's mem-initializer accordingly.
(class class_decl::member_type): Inherit from decl_base virtually
and adjust constructor's mem-initializer accordingly.
(class_decl::{data_member::data_member,member_function::member_function)
(class_decl::class_decl): Call virtual base's constructor
explicitly.
2013-04-22 Dodji Seketeli <dodji@redhat.com>
Move inline hashing functions out of line
* src/abg-ir.h (decl_base_hash::operator())
(type_base_hash::operator(), type_decl_hash::operator())
(scope_type_decl_hash::operator())
(qualified_type_def_hash::operator())
(pointer_type_def_hash::operator())
(reference_type_def_hash::operator())
(enum_type_decl_hash::operator(), typedef_decl_hash::operator())
(var_decl_hash::operator(), function_decl_hash::operator())
(class_decl::member_type_hash::operator())
(class_decl::base_spec_hash::operator())
(class_decl::data_member_hash::operator())
(class_decl::member_function_hash::operator()): Move these inline
definition ...
* src/abg-ir.cc: ... here.
2013-04-22 Dodji Seketeli <dodji@redhat.com>
Various style nit fixes
* src/abg-ir.cc: Move the emacs mode specifier for the file to the
top of the file, otherwise, it's not effective.
(struct location_manager::priv): Add end of struct comment.
(class_decl_hash::operator()): Add fn comment.
* src/abg-ir.h: Move the emacs mode specifier for the file to the
top of the file, otherwise, it's not effective.
(class scope_decl): Add end of class comment.
* src/abg-reader.cc: Move the emacs mode specifier for the file to the
top of the file, otherwise, it's not effective.
(read_context::{get_type_decl,add_type_decl): Add comment.
(handle_namespace_decl): Fix indent.
* src/abg-writer.cc: Move the emacs mode specifier for the file to
the top of the file, otherwise, it's not effective.
2013-04-12 Dodji Seketeli <dodji@redhat.com>
Remove .gitignore from VCS
* .gitignore: Remove from revision control as different
programmers might want to ignore different things.
2013-04-08 Benjamin Kosnik <bkoz@redhat.com>
Add license
* src/abg-*: Add license.
* tests/test-*: Same.
2013-04-11 Dodji Seketeli <dodji@redhat.com>
Initial Support for class declarations
* src/abg-ir.h (scope_decl::scope_decl)
(scope_type_decl::scope_type_decl): Don't set mangled name for
scope_decl instances as it doesn't make sense.
(var_decl::var_decl): Pass the type shared pointer by value.
(struct var_decl_hash, function_decl::parameter::operator==)
(struct function_decl::parameter_hash, function_decl::operator==)
(struct function_decl_hash, class class_decl, struct
class_decl_hash): New declarations.
* src/abg-ir.cc (scope_type_decl::scope_type_decl): Don't set the
mangled name. It doesn't make sense for scope_decls.
(dynamic_type_hash::operator): Fix comment. Run the hashing for
scope_type_decl instances *after* running it for class_decl
instance, otherwise, the class_decl instances case will never get
hit.
(var_decl::var_decl): Pass the type shared pointer by value.
(function_decl::operator==, class_decl::operator==)
(class_decl_hash::operator()): New fns.
* src/abg-libxml-utils.h (get_xml_node_depth): Declare new fn.
(XML_READER_GET_ATTRIBUTE): Fix comment.
(XML_NODE_GET_ATTRIBUTE): New getter macro.
* src/abg-libxml-utils.cc (get_xml_node_depth): New definition.
* src/abg-reader.cc (update_read_context)
(update_depth_info_of_read_context, read_visibility, read_binding)
(read_access, read_size_and_alignment, read_static)
(read_var_offset_in_bits, read_cdtor_const, build_function_decl)
( build_var_decl, build_type_decl, build_qualified_type_decl)
(build_pointer_type_def, build_reference_type_def)
(build_enum_type_decl, build_typedef_decl, build_class_decl)
(build_type, handle_class_decl): New functions or overloads.
(handle_element): Update to handle "class-decl" xml elements.
* src/abg-writer.cc (write_size_and_alignment, write_access)
(write_class, do_indent_to_level, get_indent_to_level): New fns.
(write_decl): Update to serialize instances of class_decl.
(write_type_decl, write_pointer_type_def)
(write_reference_type_def): Use the new write_size_and_alignment instead of
writing the attributes directly.
* tests/data/test-read-write/test10.xml: New test file.
* tests/Makefile.am: Add tests/data/test-read-write/test10.xml to
the build system.
* tests/test-read-write.cc (in_out_spec): De-serialize
data/test-read-write/test10.xml, serialize it back into
output/test-read-write/test10.xml, and compare the two output that
should be identical.
2013-04-11 Dodji Seketeli <dodji@redhat.com>
Update enum decl representation as per the schema
* src/abg-reader.cc (handle_enum_type_decl): The name of the
element holding the underlying type is now "underlying-type", no
more "base".
* src/abg-writer.cc (write_enum_type_decl): Likewise.
* tests/data/test-read-write/test6.xml: Likewise.
2013-04-10 Dodji Seketeli <dodji@redhat.com>
Add tests/data/test-read-write/test9.xml
* tests/data/test-read-write/test9.xml: (Forgot to) Add this new
test file.
2013-04-04 Dodji Seketeli <dodji@redhat.com>
Support function declarations
* src/abg-ir.h (class function_decl): New declaration & inline
definitions.
* src/abg-ir.cc (function_decl::~function_decl): New definition.
* src/abg-reader.cc (read_location): New overload to read location
from an xmlNodePtr.
(build_function_parameter, handle_function_decl):
New definitions.
(handle_element): Support "function-decl" elements.
* src/abg-writer.cc (write_location): New overload to write a
location directly, not from a decl.
(write_function_decl): New definition.
(write_binding): Support writing the binding attribute from a
function_decl instance.
(write_decl): support serializing function
* tests/data/test-read-write/test9.xml: New test input file.
* tests/Makefile.am: Add data/test-read-write/test9.xml to the
build system.
* tests/test-read-write.cc: De-serialize
data/test-read-write/test9.xml, serialize it back and diff the
output from the input.
2013-04-03 Dodji Seketeli <dodji@redhat.com>
Update in-vcs configure and docs/Makefile.in to recent configure
* configure: Updated as re-generated by autoconf 2.69.
* doc/Makefile.in: Updated as re-generated by automake 1.12.2.
2013-04-02 Benjamin Kosnik <bkoz@redhat.com>
Add doc dir. Add Doxgen api generation rules.
* doc: Add.
* doc/Makefile.am (html, install-html): Add.
* doc/Makefile.in: Add.
* doc/api/libabigail.doxy: Add doxygen config.
* src/abg-*: Add @file markup.
2013-04-03 Dodji Seketeli <dodji@redhat.com>
Introduce/use translation_unit & global_scope types
* abg-corpus.h (abi_corpus::{get_decls, get_loc_mgr}): Remove.
(abi_corpus::add): New function to add a translation unit.
(abi_corpus::get_translation_units): New declaration.
* abg-corpus.cc (abi_corpus::*): Remove all the definitions of
abi_corpus for now, as the abi_corpus type is not used anymore --
for now at least.
* src/abg-ir.h (add_decl_to_scope, get_global_scope)
(get_translation_unit, is_global_scope, is_decl_at_global_scope)
(class translation_unit, class global_scope): New declarations
* src/abg-ir.cc (translation_unit::translation_unit)
(translation_unit::get_global_scope)
(translation_unit::get_loc_mgr, translation_unit::get_loc_mgr)
(translation_unit::is_empty, get_global_scope)
(get_translation_unit, is_global_scope, is_global_scope)
(is_decl_at_global_scope, global_scope::~global_scope): New
definitions.
(scope_decl::scope_decl, scope_decl::scope_decl)
(scope_decl::add_member_decl, scope_decl::get_member_decls): Move
to abg-ir.h, inline.
* src/abg-reader.h (read_file): Don't use abi_corpus in the api.
Rather, use translation_unit.
* src/abg-reader.cc (read_context::get_cur_scope): Now that we
have a specific instance of global_scope to represent global
scope, don't play games with empty scopes to detect a global
scope.
(read_context::get_translation_unit): New definition.
(read_context::finish_decl_creation, finish_type_decl_creation):
(read_input, read_file, read_location, handle_element)
(handle_type_decl)
(handle_namespace_decl, handle_qualified_type_decl)
(handle_pointer_type_def, handle_reference_type_def)
(handle_enum_type_decl, handle_typedef_decl, handle_var_decl):
Don't use abi_corpus anymore. Rather, the translation unit a decl
belongs to is accessible from the decl itself.
* src/abg-writer.h (write_to_ostream): Use translation_unit in
this API, rather than abi_corpus.
* src/abg-writer.cc (write_translation_unit): Rename write_corpus
into this. And stop using abi_corpus here.
(write_to_ostream, write_corpus, write_location, write_decl)
(write_type_decl, write_namespace_decl, write_qualified_type_def)
(write_pointer_type_def, write_reference_type_def)
(write_enum_type_decl, write_typedef_decl, write_var_decl): Stop
using abi_corpus. Use the translation_unit that is accessible
from the decl being serialized, if need be.
* test-read-write.cc (main): De-serialize the input into an
instance of translation_unit, not an abi_corpus anymore, and
serialize that translation_unit.
2013-04-02 Dodji Seketeli <dodji@redhat.com>
Support var decl & mangled_name attributes
* src/abg-ir.h (decl_base::binding, decl_base::get_mangled_name)
(decl_base::set_mangled_name, decl_base::m_mangled_name): New
declarations.
(scope_decl::scope_decl: type_decl::type_decl)
(scope_type_decl::scope_type_decl, typedef_decl::typedef_decl):
Initialize mangled_name.
(namespace_decl::namespace_decl): Initialize visibility.
(class var_decl): New declaration.
* src/abg-ir.cc (decl_base::decl_base, scope_decl::scope_decl)
(type_decl::type_decl, scope_type_decl::scope_type_decl):
Initialize mangled name.
(namespace_decl::namespace_decl): Initialize visibility.
(qualified_type_def::qualified_type_def)
(pointer_type_def::pointer_type_def)
(reference_type_def::reference_type_def): By default, set the
visibility to the same as for the underlying type.
(enum_type_decl::enum_type_decl, typedef_decl::typedef_decl):
Initialize mangled name.
(var_decl::var_decl, var_decl::operator==, var_decl::~var_decl):
New definitions.
* src/abg-reader.cc (read_visibility, read_binding, handle_var_decl): New
definitions.
(read_file): Handle var-decl elements.
* src/abg-writer.cc (write_location): Rename write_decl_location
into this.
(write_var_decl, write_visibility, write_binding): New definitions.
(write_decl, write_type_decl, write_qualified_type_def)
(write_pointer_type_def, write_reference_type_def)
(write_enum_type_decl, write_typedef_decl): Adjust to use
write_location.
* tests/data/test-read-write/test8.xml: New test input.
* tests/test-read-write.cc: De-serialize the above and serialize
it back and ensure both are equal.
* tests/Makefile.am: add tests/data/test-read-write/test8.xml to
the distribution.
2013-04-02 Dodji Seketeli <dodji@redhat.com>
Don't forget to init context & visibility in decl_base
* src/abg-ir.cc (decl_base::decl_base): Initialize context and
visibility on all the overloads of the constructor.
2013-03-31 Dodji Seketeli <dodji@redhat.com>
Fix some style
* src/abg-ir.h (decl_base::get_scope): Really re-style.
2013-03-31 Dodji Seketeli <dodji@redhat.com>
Fix some style
* src/abg-ir.h (decl_base::{get_location, set_location, get_name,
set_name}): Re-style.
2013-03-31 Dodji Seketeli <dodji@redhat.com>
Basic support for type/decl visibility
* src/abg-ir.h (enum decl_base::visibility)
(decl_base::get_visibility, decl_base::set_visibility)
(decl_base::m_visibility): New.
(decl_base::decl_base, scope_decl::scope_decl)
(type_decl::type_decl, enum_type_decl::enum_type_decl)
(typedef_decl::typedef_decl): Pass visibility.
* src/abg-ir.cc (decl_base::decl_base, scope_decl::scope_decl)
(type_decl::type_decl, enum_type_decl::enum_type_decl)
(typedef_decl::typedef_decl): Pass visibility.
(qualified_type_def::qualified_type_def)
(pointer_type_def::pointer_type_def)
(reference_type_def::reference_type_def): Initialize visibility.
2013-03-31 Dodji Seketeli <dodji@redhat.com>
A type/decl shouldn't hold a reference on its scope
* src/abg-ir.h (decl_base::m_context): Make this a naked pointer.
(decl_base::set_scope, add_decl_to_scope): Pass the
scope as a naked pointer.
* src/abg-ir.cc (decl_base::decl_base): Initialize the context to
0.
(decl_base::set_scope, add_decl_to_scope): Pass the scope as a
naked pointer.
* src/abg-reader.cc (read_context::get_cur_scope): Return a naked
pointer.
(handle_namespace_decl): Adjust accordingly.
2013-03-30 Dodji Seketeli <dodji@redhat.com>
Support typedef declarations
* src/abg-ir.cc (dynamic_type_hash::operator()): Handle hashing of
a pointer to an instance of typedef_decl.
(typedef_decl::typedef_decl, typedef_decl::operator==)
(typedef_decl::operator==, typedef_decl::get_underlying_type)
(typedef_decl::~typedef_decl): New definitions.
* src/abg-ir.h (class typedef_decl, struct typedef_decl_hash): New
declarations.
* src/abg-reader.cc (handle_typedef_decl): New definition.
(handle_element): Handle de-serialization of typedef-decl element.
* src/abg-writer.cc (write_typedef_decl): New definition.
(write_decl): Handle serialization of an instance of typedef_decl.
* tests/data/test-read-write/test7.xml: New test.
* tests/Makefile.am: Add it to the distribution.
* tests/test-read-write.cc: De-serialize the content of the new
test, serialize it back and diff both.
2013-03-30 Dodji Seketeli <dodji@redhat.com>
Remove useless static_cast from hashing code
* src/abg-ir.h (scope_type_decl_hash::operator())
(qualified_type_def_hash::operator())
(pointer_type_def_hash::operator())
(reference_type_def_hash::operator()): Remove useless static_cast.
2013-03-30 Dodji Seketeli <dodji@redhat.com>
Simplify equality operators
* src/abg-ir.cc (qualified_type_def::operator==)
(pointer_type_def::operator==, reference_type_def::operator==)
(enum_type_decl::operator==): Simplify the code by safely assuming
the underlying type is non-null.
2013-03-30 Dodji Seketeli <dodji@redhat.com>
Support enum type declarations
* src/abg-ir.h (class enum_type_decl, struct enum_type_decl_hash):
New declarations.
* src/abg-ir.cc (dynamic_type_hash::operator()): Add hashing
support for enum_type_decl.
(enum_type_decl::enum_type_decl)
(enum_type_decl::get_underlying_type)
(enum_type_decl::get_enumerators, enum_type_decl::~enum_type_decl)
(enum_type_decl::operator==): New definitions.
* src/abg-reader.cc (handle_enum_type_decl): New definition.
(handle_element): Handle "enum-decl" element.
* src/abg-writer.cc (write_enum_type_decl): New.
(write_decl): Add support to serialize enum_type_decl.
* tests/test-read-write.cc: De-serialize and serialize
data/test-read-write/test6.xml back.
* tests/data/test-read-write/test6.xml: New test input.
* tests/Makefile.am: Add it to the distribution.
2013-03-30 Dodji Seketeli <dodji@redhat.com>
Fix reference-type-def serialization
* tests/test-read-write.cc: Really de-serialize and then serialize
back data/test-read-write/test5.xml, not test4.xml. Sigh.
* src/abg-writer.cc (write_reference_type_def): As a result of
really trying to serialize reference type definitions fix the
serialization code here.
2013-03-29 Dodji Seketeli <dodji@redhat.com>
Support reference types
* src/abg-ir.h (class reference_type_def, struct pointer_type_def)
(struct reference_type_def): New declaration.
(type_base_hash::operator(), type_decl_hash::operator())
(scope_type_decl_hash::operator())
(qualified_type_def_hash::operator()): Include the typeid name in
the hash.
* src/abg-ir.cc (reference_type_def::reference_type_def)
(reference_type_def::operator==)
(reference_type_def::get_pointed_to_type)
(reference_type_def::is_lvalue)
(reference_type_def::~reference_type_def): New definitions.
(dynamic_type_hash::operator): Hash pointer_type_def and
reference_type_def instances.
* src/abg-reader.cc (read_context::finish_decl_creation)
(read_context::finish_type_decl_creation)
(handle_reference_type_def): New definitions.
(read_file): Handle "reference-type-def" elements.
(handle_type_decl, handle_namespace_decl)
(handle_qualified_type_decl, handle_pointer_type_def): Use the new
read_context::finish_type_decl_creation or
read_context::finish_decl_creation.
* src/abg-writer.cc (write_reference_type_def): New definition.
(write_decl): Supporting writing a pointer to an instance of
reference_type_def.
* tests/data/test-read-write/test5.xml: New test file.
* tests/test-read-write.cc: (De)Serialize it.
* tests/Makefile.am: Add it to the build system.
2013-03-28 Dodji Seketeli <dodji@redhat.com>
Support pointer types & Fix IR types equality
* src/abg-ir.h (location::{operator==, operator<})
(decl_base::operator==, scope_decl::operator==)
(type_base::operator==, struct type_shared_ptr_equal)
(type_decl::operator==, scope_type::operator==)
(qualified_type_def::operator==, class pointer_type_def): New
declarations..
* src/abg-ir.cc (decl_base::operator==, scope_decl::operator==)
(type_base::operator==, type_decl::operator==)
(scope_type_decl::operator==, namespace_decl::operator==)
(qualified_type_def::operator==)
(pointer_type_def::pointer_type_def, pointer_type_def::operator==)
(pointer_type_def::get_pointed_to_type)
(pointer_type_def::~pointer_type_def): New definitions.
* src/abg-reader.cc (handle_pointer_type_def): New definition.
(read_input): Handle pointer-type-def
elements.
* src/abg-writer.cc (type_shared_ptr_map): Make this map use the
use type_shared_ptr_equal predicate.
(write_pointer_type_def): New definition.
(write_decl): Improve logic. Support serializing a pointer to
pointer_type_def.
* tests/data/test-read-write/test4.xml: New test input file.
* tests/Makefile.am: Add tests/data/test-read-write/test4.xml to
the build system.
* tests/test-read-write.cc: (De)serialize the new test file.
2013-03-27 Dodji Seketeli <dodji@seketeli.org>
Support qualified types & Misc ancillary fixes
* src/abg-ir.h (struct type_base_hash, struct dynamic_type_hash)
(struct type_shared_ptr_hash, struct scope_type_decl_hash, class
qualified_type_def, struct qualified_type_def_hash): New.
(decl_base_hash::operator()): Constify. Don't crash if the scope
of the decl we are hashing is null.
(class type_decl): Add comment at the end.
(type_decl_hash::operator()): Constify. Reuse the new
type_base_hash hasher.
(class namespace_decl): Add comment.
* src/abg-ir.cc (qualified_type_def::qualified_type_def)
(qualified_type_def::~qualified_type_def)
(qualified_type_def::get_cv_quals)
(qualified_type_def::set_cv_quals)
(qualified_type_def::get_underlying_type)
(dynamic_type_hash::operator()): New function definitions.
* src/abg-reader.cc (handle_qualified_type_decl): New.
(read_file): Handle elements named "qualified-type-def".
(read::context::add_type_decl): Assert that
the type being associated to the unique ID is non-null.
(handle_type_decl): Fix this in the process; don't crash if some
attributes are not present. Associate the unique id present in
the xml document with the type we just parsed.
(handle_namespace_decl): Add some comments. Don't crash if the
name attribute is not present.
* src/abg-writer.cc (write_context::get_id_for_type)
(write_context::m_type_id_map, write_decl_location)
(write_qualified_type_def): New.
(write_decl): Handle instances of qualified_type_def.
(write_type_decl): Use the new write_decl_location and
write_context::get_id_for_type.
* tests/data/test-read-write/test0.xml: Update id format since we
are now using the new write_context::get_id_for_type to generate
it.
* tests/data/test-read-write/test1.xml: Likewise.
* tests/data/test-read-write/test2.xml: Likewise.
* tests/data/test-read-write/test3.xml: New test.
* tests/test-read-write.cc: Test De-serializing
tests/data/test-read-write/test3.xml and serializing it back.
Also don't bail out if we fail on one input.
* tests/Makefile.am: Add tests/data/test-read-write/test3.xml to the
distribution.
2013-03-27 Benjamin Kosnik <bkoz@redhat.com>
Various autotool adjustments
* configure: Add.
* configure.ac (AM_INIT_AUTOMAKE): Use gcc versions.
(PKG_CHECK_MODULES): Re-use libjava/classpath solution, naming.
* m4/pkg.m4: Add, take from classpath.
* src/Makefile.am: Adjust names.
2013-03-26 Dodji Seketeli <dodji@seketeli.org>
Remove the 'm_kind' member from the IR
* src/abg-ir.{h,cc}: Remove use of the m_kind field. We are using
full blown rtti so this uselessly just clutter the code.
2013-03-26 Dodji Seketeli <dodji@seketeli.org>
Fix parallel build
* tests/Makefile.am: Remove useless absolute reference to the
current directory.
2013-03-26 Dodji Seketeli <dodji@seketeli.org>
Fix depth handling during the parsing
* src/abg-reader.cc (read_context::get_cur_scope): Remove useless
const overload. Don't make this rely on m_cur_scope. Rather, use
the path to the current decl (from the root element) to compute
the cur scope.
(read_context::m_cur_scope, read_context::set_cur_scope): Remove
these.
(update_read_context): Re-think logic.
* tests/data/test-read-write/test2.xml: Add new test input.
* tests/Makefile.am: Add data/test-read-write/test2.xml to the
distribution.
* tests/test-read-write.cc: Add data/test-read-write/test2.xml to
the harness.
2013-03-25 Dodji Seketeli <dodji@seketeli.org>
Debug read-write of a type-decl in a namespace-decl
* abg-ir.{h,cc} (decl_base::decl_base, scope_decl::scope_decl)
(type_decl::type_decl, namespace_decl::namespace_decl): Do not
append a decl to its context from within its constructor. It's
better doing that in a function that takes shared_ptrs to decl and
context. That way we avoid memory management havoc.
(decl_base::set_scope): New private function.
(scope_decl::add_member_decl): Make this private.
(add_decl_to_scope): New function, friend of decl_base and
scope_decl.
* abg-reader.cc (read_context::get_cur_scope): Add a non-const
overload.
(handle_type_decl, handle_namespace_decl): Use add_decl_to_scope.
Adjust to new type_decl and namespace_decl constructor signature.
* src/abg-writer.cc (write_type): Emit 'id', not 'xml:id'.
(write_namespace_decl): Emit "namespace-decl", not
"namespace-decl-name", as the name of namespace element.
* tests/Makefile.am (test0.xml): Rename input0.xml into this.
(test1.xml): New test input.
* tests/data/test-read-write/test0.xml: Update to use 'id' as id
attribute, rather than xml:id.
* tests/data/test-read-write/test1.xml: New test.
* test-read-write.cc (struct InOutSpec): New
(main): Reorganize to give a list of input files to read and to
write to an output file, have the test read the input files, write
them, and diff the two.
2013-03-22 Dodji Seketeli <dodji@seketeli.org>
Update tests/data/test-read-write/input0.xml
* tests/data/test-read-write/input0.xml: Make this identical to
how it would look like when serialized.
2013-03-22 Dodji Seketeli <dodji@seketeli.org>
Debug type-decl serialization
* src/abg-writer.cc (do_indent): New function.
(write_corpus&): Use do_indent. Don't forget to close the
abi-instr tag.
(write_type_decl): Use do_indent. Handle null decls pointers.
Emit the id at the end of the element.
(write_namespace_decl): Use do_indent. Handle null decls
pointers.
* tests/test-utils.{h,cc} (get_src_dir,get_build_dir): Constify
the returned reference to string.
(is_dir, ensure_dir_path_created, ensure_parent_dir_created): New
function definitions.
* tests/test-read-write.cc (main): Augment the test to serialize
the corpus too.
2013-03-21 Dodji Seketeli <dodji@seketeli.org>
Debugged type-decl de-serialization
* src/abg-ir.cc (namespace_decl::~namespace_decl): Add this
missing virtual constructor definition.
* src/abg-reader.cc (read_context::{get_cur_decl,pop_decl}):
Return a null pointer when the decls stack is empty.
(update_read_context): Don't try to de-reference a NULL cur_decl.
(read_input): Don't try to poke at file validity here. What was I
thinking. Really test for advance_cursor to return 1, expressing
success.
* src/abg-reader.h (read_file): Fix style.
* Makefile.am: Add tests sub-directory.
* configure.ac: Build with debugging-friendly options if the
ABIGAIL_DEBUG env variable is set. Generate tests/Makefile.
* tests/Makefile.am: New file.
* tests/test-read-write.cc: Likewise.
* tests/test-utils.{h,cc}: Likewise.
* tests/data/test-read-write/input0.xml: Likewise.
2013-03-21 Dodji Seketeli <dodji@seketeli.org>
Initial implementation of serialization of basic types and namespaces.
* src/Makefile.am: Add abg-writer.{h,cc} and abg-config.{h,cc}.
* src/abg-config.{h,cc}: New files.
* src/abg-corpus.h (abi_corpus::decls_type): New typedef.
(abi_corpus::{add,get_decls,get_loc_mgr}): Fix style.
(abi_corpus::is_empty): Declare new function.
* src/abg-corpus.cc (abi_corpus::add): really add the declaration
to the corpus.
(abi_corpus::is_empty): Define new function.
* src/abg-ir.{h,cc} (location_manager::expand_location): Consti-fy
this function.
* src/abg-reader.cc (read_file): Add a corpus parameter.
* src/abg-serialize.cc: Delete this file.
* src/abg-writer.h (write_to_ostream): Rename write into this.
Make it take a corpus and an ostream as parameters.
* abg-writer.cc: New file.
2013-03-08 Dodji Seketeli <dodji@seketeli.org>
Parse type-decl and namespace-decl elements
* configure.ac: Add libxml2 dependencies.
* src/abg-corpus.{h,cc}: New files.
* src/abg-hash.{h,cc}: Likewise.
* src/abg-libxml-utils.{h,cc}: Likewise.
* src/abg-reader.{h,cc}: Likewise.
* src/abg-serialize.{h,cc}: Likewise.
* src/abg-writer.h: Likewise.
* src/Makefile.am: Build the new files above.
* src/abg-ir.h (class location): Add public accessors for the value, and
a truth operator. Make the methods be inline.
(class decl_base): Renamed decl into this. Renamed what_decl_kind
into what_kind. Renamed get_context into get_scope. Add virtual
destructor, accessors for location and name.
(class {scope_decl, type_base, type_decl} ): Add virtual dtor.
Re-style.
(struct {decl_base_hash, type_decl_hash}): New hashing functors.
(class {scope_type_decl, namespace_decl}): Add virtual dtor.
* src/abg-ir.cc (location::*): Remove location definitions. There
are now inline in the header.
(class decl_base): Renamed decl into this. Remove most of the
definitions from here as their are now inline in the header.
(scope_decl::~scope_decl, type_base::~type_base)
(type_decl::~type_decl, scope_type_decl::~scope_type_decl): New
definitions.
2013-03-04 Dodji Seketeli <dodji@seketeli.org>
Updated hierarchy up to namespace_decl
* src/abg-ir.h (location): Make the default ctor public.
(class decl): Declare data member and proper constructors. Make the
context be a shared_ptr. Add a kind data member to avoid RTTI for
now.
(class scope_decl): Added protected constructor to handle the kind data
member.
(class type_base): Add data members proper and clean the iface up.
(class type_decl, scope_type_decl, namespace_decl): Iron out
constructors.
* src/abg-ir.cc (class location): Fix style.
(class decl, scope_decl, type_base, type_decl, scope_type_decl)
(namespace_decl): Define these types.
2013-03-01 Dodji Seketeli <dodji@seketeli.org>
Add missing autoconfiscation files into version control
* config.guess: Added to VCS.
* config.sub: Likewise.
* depcomp: Likewise.
* install-sh: Likewise.
* ltmain.sh: Likewise.
* missing: Likewise
2013-03-01 Dodji Seketeli <dodji@seketeli.org>
Upload m4 file
* m4/: Import this directory into version control.
2013-03-01 Dodji Seketeli <dodji@seketeli.org>
Create and expand locations
* src/abg-ir.h (class {location, location_manager, decl,
scoped_decl, type_base, type_decl, scope_type_decl): Declare new
types.
* src/abg-ir.cc (class {location, location_manager}): Define new types.
2013-03-01 Dodji Seketeli <dodji@seketeli.org>
Adjust src/Makefile.am after some file rename
* src/Makefile.am: Update build system for renaming files from
abgl-* into abg-*.
2013-03-01 Dodji Seketeli <dodji@seketeli.org>
Update the README file
* README: Update.
2013-02-28 Dodji Seketeli <dodji@seketeli.org>
Initial AUTHORS and README
* AUTHORS: Initial AUTHORS and README
* README: Initial AUTHORS and README
2013-02-28 Dodji Seketeli <dodji@seketeli.org>
Leave license stuff for later
* COPYING: Leave license stuff for later
2013-02-28 Dodji Seketeli <dodji@seketeli.org>
Initial import Abigail
* AUTHORS: Initial import Abigail
* COPYING: Initial import Abigail
* ChangeLog: Initial import Abigail
* INSTALL: Initial import Abigail
* Makefile.am: Initial import Abigail
* NEWS: Initial import Abigail
* README: Initial import Abigail
* config.h.in: Initial import Abigail
* configure.ac: Initial import Abigail
* src/Makefile.am: Initial import Abigail
* src/abg-ir.cc: Initial import Abigail
* src/abg-ir.h: Initial import Abigail
|