2 // { dg-additional-options "-fno-exceptions --param=logical-op-non-short-circuit=0" }
4 typedef unsigned int location_t;
5 const location_t MAX_LOCATION_T = 0x7FFFFFFF;
7 unsigned int info_ordinary;
12 inline location_t LINEMAPS_MACRO_LOWEST_LOCATION(const line_maps *set) {
14 ? set->maps[set->used - 1]
17 const location_t *linemap_lookup(const line_maps *set, location_t line) {
18 int mn = set->info_ordinary;
20 if ((unsigned int)mn < set->used)
22 __builtin_unreachable();
24 bool linemap_location_from_macro_expansion_p(const class line_maps *set,
25 location_t location) {
26 if (location > MAX_LOCATION_T)
27 location = set->data[location & MAX_LOCATION_T];
28 return location >= LINEMAPS_MACRO_LOWEST_LOCATION(set);
30 void first_map_in_common_1(line_maps *set, location_t *loc0,
32 linemap_lookup(set, 0);
33 __builtin_unreachable();
35 int linemap_compare_locations(line_maps *set, location_t pre, location_t post) {
37 location_t l0 = pre, l1 = post;
38 if (l0 > MAX_LOCATION_T)
39 l0 = set->data[l0 & MAX_LOCATION_T];
40 if (l1 > MAX_LOCATION_T)
41 l1 = set->data[l1 & MAX_LOCATION_T];;
44 if ((pre_virtual_p = linemap_location_from_macro_expansion_p(set, l0)))
45 l0 = set->data[l0 & MAX_LOCATION_T];
46 if (linemap_location_from_macro_expansion_p(set, l1))
47 l1 = set->data[l1 & MAX_LOCATION_T];
50 first_map_in_common_1(set, &l0, &l1);
51 if (l0 > MAX_LOCATION_T)
52 if (l1 > MAX_LOCATION_T)
53 l1 = set->data[l1 & MAX_LOCATION_T];