History

Update dwarf2 support

tccgen.c: - add anon support. So tcc_state in tcc works now. - add function pointer support - remove DW_FORM_implicit_const from DW_TAG_pointer_type tccrun.c: - set initial file name - correctly use pc in DW_LNE_set_address (see lib/bt-exe.c) - add DW_LNE_define_file support (even if it is deprecated) tccelf.c - do not include debug/test_coverage information for stub functions lib/bt-exe.c - use num_callers=-1 to mark dll

herman ten brugge committed 4 years ago

Commit 18808e31 parent f0df48f4 files · +224 −23Browse files

Unified · Split

4 files
  1. lib/bt-exe.c +1 −0
  2. tccelf.c +15 −2
  3. tccgen.c +188 −16
  4. tccrun.c +20 −5
lib/bt-exe.c+1−0
@@ -29,6 +29,7 @@ void __bt_init(rt_context *p, int num_callers) · 28 unmodified lines
2929 __rt_error = _rt_error;
3030 set_exception_handler();
3131 } else {
32+ p->num_callers = -1;
3233 p->next = rc->next, rc->next = p;
3334 }
3435 }
tccelf.c+15−2
@@ -1426,6 +1426,19 @@ static void set_local_sym(TCCState *s1, const char *name, Section *s, int offset · 1425 unmodified lines
14261426 }
14271427 }
14281428
1429+/* avoid generating debug/test_coverage code for stub functions */
1430+static void tcc_compile_string_no_debug(TCCState *s, const char *str)
1431+{
1432+ int save_do_debug = s->do_debug;
1433+ int save_test_coverage = s->test_coverage;
1434+
1435+ s->do_debug = 0;
1436+ s->test_coverage = 0;
1437+ tcc_compile_string(s, str);
1438+ s->do_debug = save_do_debug;
1439+ s->test_coverage = save_test_coverage;
1440+}
1441+
14291442 #ifdef CONFIG_TCC_BACKTRACE
14301443 static void put_ptr(TCCState *s1, Section *s, int offs, const char *name)
14311444 {
@@ -1489,7 +1502,7 @@ ST_FUNC void tcc_add_btstub(TCCState *s1) · 57 unmodified lines
14891502 #endif
14901503 cstr_printf(&cstr, "__bt_init(__rt_info,%d);}",
14911504 s1->output_type == TCC_OUTPUT_DLL ? 0 : s1->rt_num_callers + 1);
1492− tcc_compile_string(s1, cstr.data);
1505+ tcc_compile_string_no_debug(s1, cstr.data);
14931506 cstr_free(&cstr);
14941507 set_local_sym(s1, &"___rt_info"[!s1->leading_underscore], s, o);
14951508 }
@@ -1528,7 +1541,7 @@ static void tcc_tcov_add_file(TCCState *s1, const char *filename) · 32 unmodified lines
15281541 "__attribute__((destructor)) static void __tcov_exit() {"
15291542 "__store_test_coverage(__tcov_data);"
15301543 "}");
1531− tcc_compile_string(s1, cstr.data);
1544+ tcc_compile_string_no_debug(s1, cstr.data);
15321545 cstr_free(&cstr);
15331546 set_local_sym(s1, &"___tcov_data"[!s1->leading_underscore], tcov_section, 0);
15341547 }
tccgen.c+188−16
@@ -187,7 +187,7 @@ static const struct { · 186 unmodified lines
187187 { VT_BYTE | VT_UNSIGNED, 1, DW_ATE_unsigned_char, "unsigned char:t25=r25;0;255;" },
188188 /* boolean type */
189189 { VT_BOOL, 1, DW_ATE_unsigned_char, "bool:t26=r26;0;255;" },
190− { VT_VOID, 1, DW_ATE_void, "void:t27=27" },
190+ { VT_VOID, 1, DW_ATE_unsigned_char, "void:t27=27" },
191191 };
192192
193193 #define N_DEFAULT_DEBUG (sizeof (default_debug) / sizeof (default_debug[0]))
@@ -199,7 +199,14 @@ static struct debug_hash { · 5 unmodified lines
199199 Sym *type;
200200 } *debug_hash;
201201
202+static struct debug_anon_hash {
203+ Sym *type;
204+ int n_debug_type;
205+ int *debug_type;
206+} *debug_anon_hash;
207+
202208 static int n_debug_hash;
209+static int n_debug_anon_hash;
203210
204211 static struct debug_info {
205212 int start;
@@ -251,7 +258,12 @@ static struct debug_info { · 45 unmodified lines
251258 #define DWARF_ABBREV_SUBPROGRAM_EXTERNAL 17
252259 #define DWARF_ABBREV_SUBPROGRAM_STATIC 18
253260 #define DWARF_ABBREV_LEXICAL_BLOCK 19
261+#define DWARF_ABBREV_SUBROUTINE_TYPE 20
262+#define DWARF_ABBREV_FORMAL_PARAMETER2 21
254263
264+/* all entries should have been generated with dwarf_uleb128 except
265+ has_children. All values are currently below 128 so this currently
266+ works. */
255267 static const unsigned char dwarf_abbrev_init[] = {
256268 DWARF_ABBREV_COMPILE_UNIT, DW_TAG_compile_unit, 1,
257269 DW_AT_producer, DW_FORM_strp,
@@ -298,7 +310,6 @@ static const unsigned char dwarf_abbrev_init[] = { · 40 unmodified lines
298310 0, 0,
299311 DWARF_ABBREV_POINTER, DW_TAG_pointer_type, 0,
300312 DW_AT_byte_size, DW_FORM_data1,
301− DW_AT_byte_size, DW_FORM_implicit_const, 8,
302313 DW_AT_type, DW_FORM_ref4,
303314 0, 0,
304315 DWARF_ABBREV_ARRAY_TYPE, DW_TAG_array_type, 1,
@@ -394,6 +405,13 @@ static const unsigned char dwarf_abbrev_init[] = { · 89 unmodified lines
394405 DW_AT_high_pc, DW_FORM_data8,
395406 #endif
396407 0, 0,
408+ DWARF_ABBREV_SUBROUTINE_TYPE, DW_TAG_subroutine_type, 1,
409+ DW_AT_type, DW_FORM_ref4,
410+ DW_AT_sibling, DW_FORM_ref4,
411+ 0, 0,
412+ DWARF_ABBREV_FORMAL_PARAMETER2, DW_TAG_formal_parameter, 0,
413+ DW_AT_type, DW_FORM_ref4,
414+ 0, 0,
397415 0
398416 };
399417
@@ -945,7 +963,9 @@ ST_FUNC void tcc_debug_start(TCCState *s1) · 545 unmodified lines
945963 func_ind = -1;
946964 debug_next_type = N_DEFAULT_DEBUG;
947965 debug_hash = NULL;
966+ debug_anon_hash = NULL;
948967 n_debug_hash = 0;
968+ n_debug_anon_hash = 0;
949969 /* we're currently 'including' the <command line> */
950970 tcc_debug_bincl(s1);
951971 }
@@ -963,12 +983,35 @@ ST_FUNC void tcc_debug_end(TCCState *s1) · 11 unmodified lines
963983 if (!s1->do_debug)
964984 return;
965985 if (s1->dwarf) {
966− int i;
986+ int i, j;
967987 int start_aranges;
968988 unsigned char *ptr;
969989 int text_size = text_section->data_offset;
970990
971991 /* dwarf_info */
992+ for (i = 0; i < n_debug_anon_hash; i++) {
993+ Sym *t = debug_anon_hash[i].type;
994+ int pos = dwarf_info_section->data_offset;
995+
996+ dwarf_data1(dwarf_info_section,
997+ IS_UNION (t->type.t) ? DWARF_ABBREV_UNION_TYPE
998+ : DWARF_ABBREV_STRUCTURE_TYPE);
999+ dwarf_strp(dwarf_info_section,
1000+ (t->v & ~SYM_STRUCT) >= SYM_FIRST_ANOM
1001+ ? "" : get_tok_str(t->v & ~SYM_STRUCT, NULL));
1002+ dwarf_uleb128(dwarf_info_section, 0);
1003+ dwarf_uleb128(dwarf_info_section, dwarf_line.cur_file);
1004+ dwarf_uleb128(dwarf_info_section, file->line_num);
1005+ j = dwarf_info_section->data_offset + 5 - dwarf_info.start;
1006+ dwarf_data4(dwarf_info_section, j);
1007+ dwarf_data1(dwarf_info_section, 0);
1008+ for (j = 0; j < debug_anon_hash[i].n_debug_type; j++)
1009+ write32le(dwarf_info_section->data +
1010+ debug_anon_hash[i].debug_type[j],
1011+ pos - dwarf_info.start);
1012+ tcc_free (debug_anon_hash[i].debug_type);
1013+ }
1014+ tcc_free (debug_anon_hash);
9721015 dwarf_data1(dwarf_info_section, 0);
9731016 ptr = dwarf_info_section->data + dwarf_info.start;
9741017 write32le(ptr, dwarf_info_section->data_offset - dwarf_info.start - 4);
@@ -1276,16 +1319,69 @@ static void tcc_debug_stabn(TCCState *s1, int type, int value) · 301 unmodified lines
12761319 }
12771320 }
12781321
1279−static int tcc_debug_find(Sym *t)
1322+static int tcc_get_dwarf_info(TCCState *s1, Sym *s);
1323+
1324+static int tcc_debug_find(Sym *t, int dwarf)
12801325 {
12811326 int i;
12821327
1328+ if (!debug_info && dwarf &&
1329+ (t->type.t & VT_BTYPE) == VT_STRUCT && t->c == -1) {
1330+ for (i = 0; i < n_debug_anon_hash; i++)
1331+ if (t == debug_anon_hash[i].type)
1332+ return 0;
1333+ debug_anon_hash = (struct debug_anon_hash *)
1334+ tcc_realloc (debug_anon_hash,
1335+ (n_debug_anon_hash + 1) * sizeof(*debug_anon_hash));
1336+ debug_anon_hash[n_debug_anon_hash].n_debug_type = 0;
1337+ debug_anon_hash[n_debug_anon_hash].debug_type = NULL;
1338+ debug_anon_hash[n_debug_anon_hash++].type = t;
1339+ return 0;
1340+ }
12831341 for (i = 0; i < n_debug_hash; i++)
12841342 if (t == debug_hash[i].type)
12851343 return debug_hash[i].debug_type;
12861344 return -1;
12871345 }
12881346
1347+static void tcc_debug_check_anon(Sym *t, int debug_type)
1348+{
1349+ int i;
1350+
1351+ if (!debug_info && (t->type.t & VT_BTYPE) == VT_STRUCT && t->type.ref->c == -1)
1352+ for (i = 0; i < n_debug_anon_hash; i++)
1353+ if (t->type.ref == debug_anon_hash[i].type) {
1354+ debug_anon_hash[i].debug_type =
1355+ tcc_realloc(debug_anon_hash[i].debug_type,
1356+ (debug_anon_hash[i].n_debug_type + 1) * sizeof(int));
1357+ debug_anon_hash[i].debug_type[debug_anon_hash[i].n_debug_type++] =
1358+ debug_type;
1359+ }
1360+}
1361+
1362+static void tcc_debug_fix_anon(CType *t)
1363+{
1364+ int i, j, debug_type;
1365+ TCCState *s1 = tcc_state;
1366+
1367+ if (!s1->do_debug || !s1->dwarf || debug_info)
1368+ return;
1369+ if ((t->t & VT_BTYPE) == VT_STRUCT && t->ref->c != -1)
1370+ for (i = 0; i < n_debug_anon_hash; i++)
1371+ if (t->ref == debug_anon_hash[i].type) {
1372+ Sym sym = { .type = *t };
1373+
1374+ debug_type = tcc_get_dwarf_info(s1, &sym);
1375+ for (j = 0; j < debug_anon_hash[i].n_debug_type; j++)
1376+ write32le(dwarf_info_section->data +
1377+ debug_anon_hash[i].debug_type[j], debug_type);
1378+ tcc_free(debug_anon_hash[i].debug_type);
1379+ n_debug_anon_hash--;
1380+ for (; i < n_debug_anon_hash; i++)
1381+ debug_anon_hash[i] = debug_anon_hash[i + 1];
1382+ }
1383+}
1384+
12891385 static int tcc_debug_add(Sym *t, int dwarf)
12901386 {
12911387 int offset = dwarf ? dwarf_info_section->data_offset : ++debug_next_type;
@@ -1331,7 +1427,7 @@ static void tcc_get_debug_info(TCCState *s1, Sym *s, CString *result) · 39 unmodified lines
13311427 Sym *e = t;
13321428
13331429 t = t->type.ref;
1334− debug_type = tcc_debug_find(t);
1430+ debug_type = tcc_debug_find(t, 0);
13351431 if (debug_type == -1) {
13361432 debug_type = tcc_debug_add(t, 0);
13371433 cstr_new (&str);
@@ -1369,7 +1465,7 @@ static void tcc_get_debug_info(TCCState *s1, Sym *s, CString *result) · 31 unmodified lines
13691465 else if (IS_ENUM(type)) {
13701466 Sym *e = t = t->type.ref;
13711467
1372− debug_type = tcc_debug_find(t);
1468+ debug_type = tcc_debug_find(t, 0);
13731469 if (debug_type == -1) {
13741470 debug_type = tcc_debug_add(t, 0);
13751471 cstr_new (&str);
@@ -1430,6 +1526,8 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 54 unmodified lines
14301526 int debug_type = -1;
14311527 Sym *e, *t = s;
14321528 int i;
1529+ int last_pos = -1;
1530+ int retval;
14331531
14341532 for (;;) {
14351533 type = t->type.t & ~(VT_STORAGE | VT_CONSTANT | VT_VOLATILE);
@@ -1442,7 +1540,7 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 6 unmodified lines
14421540 }
14431541 if ((type & VT_BTYPE) == VT_STRUCT) {
14441542 t = t->type.ref;
1445− debug_type = tcc_debug_find(t);
1543+ debug_type = tcc_debug_find(t, 1);
14461544 if (debug_type == -1) {
14471545 int pos_sib, i, *pos_type;
14481546
@@ -1504,6 +1602,7 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 55 unmodified lines
15041602 while (e->next) {
15051603 e = e->next;
15061604 type = tcc_get_dwarf_info(s1, e);
1605+ tcc_debug_check_anon(e, pos_type[i]);
15071606 write32le(dwarf_info_section->data + pos_type[i++],
15081607 type - dwarf_info.start);
15091608 }
@@ -1514,7 +1613,7 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 4 unmodified lines
15141613 }
15151614 else if (IS_ENUM(type)) {
15161615 t = t->type.ref;
1517− debug_type = tcc_debug_find(t);
1616+ debug_type = tcc_debug_find(t, 1);
15181617 if (debug_type == -1) {
15191618 int pos_sib, pos_type;
15201619 CType ct = { VT_INT | (type & VT_UNSIGNED) , NULL };
@@ -1569,8 +1668,9 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 48 unmodified lines
15691668 *strchr(name, ':') = 0;
15701669 dwarf_strp(dwarf_info_section, name);
15711670 dwarf_info.base_type_used[i - 1] = debug_type;
1572− }
1671+ }
15731672 }
1673+ retval = debug_type;
15741674 t = s;
15751675 for (;;) {
15761676 type = t->type.t & ~(VT_STORAGE | VT_CONSTANT | VT_VOLATILE);
@@ -1578,10 +1678,18 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 1 unmodified line
15781678 type &= ~VT_DEFSIGN;
15791679 if (type == VT_PTR) {
15801680 i = dwarf_info_section->data_offset;
1681+ if (retval == debug_type)
1682+ retval = i;
15811683 dwarf_data1(dwarf_info_section, DWARF_ABBREV_POINTER);
15821684 dwarf_data1(dwarf_info_section, PTR_SIZE);
1583− dwarf_data4(dwarf_info_section, debug_type - dwarf_info.start);
1584− debug_type = i;
1685+ if (last_pos != -1) {
1686+ tcc_debug_check_anon(e, last_pos);
1687+ write32le(dwarf_info_section->data + last_pos,
1688+ i - dwarf_info.start);
1689+ }
1690+ last_pos = dwarf_info_section->data_offset;
1691+ e = t->type.ref;
1692+ dwarf_data4(dwarf_info_section, 0);
15851693 }
15861694 else if (type == (VT_PTR | VT_ARRAY)) {
15871695 int sib_pos, sub_type;
@@ -1590,8 +1698,17 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 2 unmodified lines
15901698
15911699 sub_type = tcc_get_dwarf_info(s1, &sym);
15921700 i = dwarf_info_section->data_offset;
1701+ if (retval == debug_type)
1702+ retval = i;
15931703 dwarf_data1(dwarf_info_section, DWARF_ABBREV_ARRAY_TYPE);
1594− dwarf_data4(dwarf_info_section, debug_type - dwarf_info.start);
1704+ if (last_pos != -1) {
1705+ tcc_debug_check_anon(e, last_pos);
1706+ write32le(dwarf_info_section->data + last_pos,
1707+ i - dwarf_info.start);
1708+ }
1709+ last_pos = dwarf_info_section->data_offset;
1710+ e = t->type.ref;
1711+ dwarf_data4(dwarf_info_section, 0);
15951712 sib_pos = dwarf_info_section->data_offset;
15961713 dwarf_data4(dwarf_info_section, 0);
15971714 for (;;) {
@@ -1607,16 +1724,66 @@ static int tcc_get_dwarf_info(TCCState *s1, Sym *s) · 9 unmodified lines
16071724 dwarf_data1(dwarf_info_section, 0);
16081725 write32le(dwarf_info_section->data + sib_pos,
16091726 dwarf_info_section->data_offset - dwarf_info.start);
1610− debug_type = i;
16111727 }
16121728 else if (type == VT_FUNC) {
1613− return tcc_get_dwarf_info (s1, t->type.ref);
1729+ int sib_pos, *pos_type;
1730+ Sym *f;
1731+
1732+ i = dwarf_info_section->data_offset;
1733+ debug_type = tcc_get_dwarf_info(s1, t->type.ref);
1734+ if (retval == debug_type)
1735+ retval = i;
1736+ dwarf_data1(dwarf_info_section, DWARF_ABBREV_SUBROUTINE_TYPE);
1737+ if (last_pos != -1) {
1738+ tcc_debug_check_anon(e, last_pos);
1739+ write32le(dwarf_info_section->data + last_pos,
1740+ i - dwarf_info.start);
1741+ }
1742+ last_pos = dwarf_info_section->data_offset;
1743+ e = t->type.ref;
1744+ dwarf_data4(dwarf_info_section, 0);
1745+ sib_pos = dwarf_info_section->data_offset;
1746+ dwarf_data4(dwarf_info_section, 0);
1747+ f = t->type.ref;
1748+ i = 0;
1749+ while (f->next) {
1750+ f = f->next;
1751+ i++;
1752+ }
1753+ pos_type = (int *) tcc_malloc(i * sizeof(int));
1754+ f = t->type.ref;
1755+ i = 0;
1756+ while (f->next) {
1757+ f = f->next;
1758+ dwarf_data1(dwarf_info_section, DWARF_ABBREV_FORMAL_PARAMETER2);
1759+ pos_type[i++] = dwarf_info_section->data_offset;
1760+ dwarf_data4(dwarf_info_section, 0);
1761+ }
1762+ dwarf_data1(dwarf_info_section, 0);
1763+ write32le(dwarf_info_section->data + sib_pos,
1764+ dwarf_info_section->data_offset - dwarf_info.start);
1765+ f = t->type.ref;
1766+ i = 0;
1767+ while (f->next) {
1768+ f = f->next;
1769+ type = tcc_get_dwarf_info(s1, f);
1770+ tcc_debug_check_anon(f, pos_type[i]);
1771+ write32le(dwarf_info_section->data + pos_type[i++],
1772+ type - dwarf_info.start);
1773+ }
1774+ tcc_free(pos_type);
16141775 }
1615− else
1776+ else {
1777+ if (last_pos != -1) {
1778+ tcc_debug_check_anon(e, last_pos);
1779+ write32le(dwarf_info_section->data + last_pos,
1780+ debug_type - dwarf_info.start);
1781+ }
16161782 break;
1783+ }
16171784 t = t->type.ref;
16181785 }
1619− return debug_type;
1786+ return retval;
16201787 }
16211788
16221789 static void tcc_debug_finish (TCCState *s1, struct debug_info *cur)
@@ -1787,6 +1954,7 @@ static void tcc_debug_funcend(TCCState *s1, int size) · 164 unmodified lines
17871954 dwarf_strp(dwarf_info_section, funcname);
17881955 dwarf_uleb128(dwarf_info_section, dwarf_line.cur_file);
17891956 dwarf_uleb128(dwarf_info_section, dwarf_info.line);
1957+ tcc_debug_check_anon(sym->type.ref, dwarf_info_section->data_offset);
17901958 dwarf_data4(dwarf_info_section, debug_info - dwarf_info.start);
17911959 dwarf_reloc(dwarf_info_section, section_sym, R_DATA_PTR);
17921960 #if PTR_SIZE == 4
@@ -1843,6 +2011,7 @@ static void tcc_debug_extern_sym(TCCState *s1, Sym *sym, int sh_num, int sym_bin · 50 unmodified lines
18432011 dwarf_strp(dwarf_info_section, get_tok_str(sym->v, NULL));
18442012 dwarf_uleb128(dwarf_info_section, dwarf_line.cur_file);
18452013 dwarf_uleb128(dwarf_info_section, file->line_num);
2014+ tcc_debug_check_anon(sym, dwarf_info_section->data_offset);
18462015 dwarf_data4(dwarf_info_section, debug_type - dwarf_info.start);
18472016 if (sym_bind == STB_GLOBAL)
18482017 dwarf_data1(dwarf_info_section, 1);
@@ -1888,6 +2057,7 @@ static void tcc_debug_typedef(TCCState *s1, Sym *sym) · 39 unmodified lines
18882057 dwarf_strp(dwarf_info_section, get_tok_str(sym->v & ~SYM_FIELD, NULL));
18892058 dwarf_uleb128(dwarf_info_section, dwarf_line.cur_file);
18902059 dwarf_uleb128(dwarf_info_section, file->line_num);
2060+ tcc_debug_check_anon(sym, dwarf_info_section->data_offset);
18912061 dwarf_data4(dwarf_info_section, debug_type - dwarf_info.start);
18922062 }
18932063 return;
@@ -6106,6 +6276,8 @@ do_decl: · 4212 unmodified lines
61066276 check_fields(type, 1);
61076277 check_fields(type, 0);
61086278 struct_layout(type, &ad);
6279+ if (debug_modes)
6280+ tcc_debug_fix_anon(type);
61096281 }
61106282 }
61116283 }
tccrun.c+20−5
@@ -754,14 +754,14 @@ next: · 753 unmodified lines
754754 }
755755 }
756756 else {
757− while ((i = DW_GETC(ln, end))) {
757+ while ((DW_GETC(ln, end))) {
758758 #if 0
759759 if (++dir_size < DIR_TABLE_SIZE)
760760 dirs[dir_size - 1] = (char *)ln - 1;
761761 #endif
762762 while (DW_GETC(ln, end)) {}
763763 }
764− while ((i = DW_GETC(ln, end))) {
764+ while ((DW_GETC(ln, end))) {
765765 if (++filename_size < FILE_TABLE_SIZE) {
766766 filename_table[filename_size - 1].name = (char *)ln - 1;
767767 while (DW_GETC(ln, end)) {}
@@ -776,6 +776,8 @@ next: · 8 unmodified lines
776776 dwarf_read_uleb128(&ln, end); // size
777777 }
778778 }
779+ if (filename_size >= 2)
780+ filename = filename_table[1].name;
779781 while (ln < end) {
780782 last_pc = pc;
781783 switch (DW_GETC(ln, end)) {
@@ -790,14 +792,27 @@ next: · 8 unmodified lines
790792 goto next_line;
791793 case DW_LNE_set_address:
792794 #if PTR_SIZE == 4
793− dwarf_read_32(&cp, end);
795+ pc = dwarf_read_32(&cp, end);
794796 #else
795− dwarf_read_64(&cp, end);
797+ pc = dwarf_read_64(&cp, end);
796798 #endif
797− pc = rc->dwarf_text;
799+ if (rc->num_callers < 0)
800+ pc = rc->dwarf_text; /* dll */
798801 opindex = 0;
799802 break;
800803 case DW_LNE_define_file: /* deprecated */
804+ if (++filename_size < FILE_TABLE_SIZE) {
805+ filename_table[filename_size - 1].name = (char *)ln - 1;
806+ while (DW_GETC(ln, end)) {}
807+ filename_table[filename_size - 1].dir_entry =
808+ dwarf_read_uleb128(&ln, end);
809+ }
810+ else {
811+ while (DW_GETC(ln, end)) {}
812+ dwarf_read_uleb128(&ln, end);
813+ }
814+ dwarf_read_uleb128(&ln, end); // time
815+ dwarf_read_uleb128(&ln, end); // size
801816 break;
802817 case DW_LNE_set_discriminator:
803818 dwarf_read_uleb128(&cp, end);

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t