https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69985

--- Comment #14 from David Malcolm <dmalcolm at gcc dot gnu.org> ---
(gdb) p *map
$8 = {<line_map> = {start_location = 98229568, reason = LC_RENAME_VERBATIM},
to_file = 0x2709850 "cmds-check.c", to_line = 7836, 
  included_from = -1, sysp = 0 '\000', m_column_and_range_bits = 12,
m_range_bits = 5}

(gdb) call linemap_lookup (set, r)
$9 = (const line_map *) 0x7ffff15baf40
(gdb) p *(const line_map_ordinary *)$9
$11 = {<line_map> = {start_location = 98233888, reason = LC_RENAME}, to_file =
0x2709850 "cmds-check.c", to_line = 7837, 
  included_from = -1, sysp = 0 '\000', m_column_and_range_bits = 13,
m_range_bits = 5}


The .i file has:

   if (!silent)
    fprintf(
# 7836 "cmds-check.c" 3 4
           stderr
# 7836 "cmds-check.c"
                 ,
     "Chunk[%llu, %u, %llu]: length(%llu), offset(%llu), type(%llu) mismatch
with block group[%llu, %u, %llu]: offset(%llu), objectid(%llu), flags(%llu)\n",

The relevant code in cmds-check.c looks like this:

  7835                          if (!silent)
  7836                                  fprintf(stderr,
  7837                                          "Chunk[%llu, %u, %llu]:
length(%llu), offset(%llu), type(%llu) mismatch with block group[%llu, %u,
%llu]: offset(%llu), objectid(%llu), flags(%llu)\n",
  7838                                          chunk_rec->objectid,
  7839                                          chunk_rec->type,
  7840                                          chunk_rec->offset,
  7841                                          chunk_rec->length,
  7842                                          chunk_rec->offset,
  7843                                          chunk_rec->type_flags,
  7844                                          block_group_rec->objectid,
  7845                                          block_group_rec->type,
  7846                                          block_group_rec->offset,
  7847                                          block_group_rec->offset,
  7848                                          block_group_rec->objectid,
  7849                                          block_group_rec->flags);

Within the .i it looks like this:

   if (!silent)
    fprintf(
# 7836 "cmds-check.c" 3 4
           stderr
# 7836 "cmds-check.c"
                 ,
     "Chunk[%llu, %u, %llu]: length(%llu), offset(%llu), type(%llu) mismatch
with block group[%llu, %u, %llu]: offset(%llu), objectid(%llu), flags(%llu)\n",

Note that the very long line containing the format string was 191 chars long;
looks like it triggered a transition to a new ordinary line map, since the
default 7 bits of length, for a maximum column number of 127.

Reply via email to