Home | History | Annotate | Download | only in dwarf

Lines Matching full:abbrev

67 	Abbrev        int // Either DW_ABRV_AUTO[_LOCLIST] or DW_ABRV_PARAM[_LOCLIST]
292 * always write them out in the order of declaration in the abbrev.
824 Abbrev int
831 func putattr(ctxt Context, s Sym, abbrev int, form int, cls int, value int64, data interface{}) error {
912 return fmt.Errorf("dwarf: null reference in %d", abbrev)
934 // only the ones actually listed in the Abbrev will be written out.
935 func PutAttrs(ctxt Context, s Sym, abbrev int, attr *DWAttr) {
937 for _, f := range abbrevs[abbrev].attr {
940 putattr(ctxt, s, abbrev, int(f.form), int(ap.Cls), ap.Value, ap.Data)
945 putattr(ctxt, s, abbrev, int(f.form), 0, 0, nil)
949 // HasChildren returns true if 'die' uses an abbrev that supports children.
951 return abbrevs[die.Abbrev].children != 0
1083 abbrev := DW_ABRV_FUNCTION_ABSTRACT
1084 Uleb128put(ctxt, s.Absfn, int64(abbrev))
1097 putattr(ctxt, s.Absfn, abbrev, DW_FORM_string, DW_CLS_STRING, int64(len(fullname)), fullname)
1100 putattr(ctxt, s.Absfn, abbrev, DW_FORM_data1, DW_CLS_CONSTANT, int64(DW_INL_inlined), nil)
1106 putattr(ctxt, s.Absfn, abbrev, DW_FORM_flag, DW_CLS_FLAG, ev, 0)
1165 abbrev := DW_ABRV_INLINED_SUBROUTINE_RANGES
1167 abbrev = DW_ABRV_INLINED_SUBROUTINE
1169 Uleb128put(ctxt, s.Info, int64(abbrev))
1172 ctxt.Logf("PutInlinedFunc(caller=%v,callee=%v,abbrev=%d)\n", callersym, callee, abbrev)
1176 putattr(ctxt, s.Info, abbrev, DW_FORM_ref_addr, DW_CLS_REFERENCE, 0, callee)
1178 if abbrev == DW_ABRV_INLINED_SUBROUTINE_RANGES {
1179 putattr(ctxt, s.Info, abbrev, DW_FORM_sec_offset, DW_CLS_PTR, s.Ranges.Len(), s.Ranges)
1184 putattr(ctxt, s.Info, abbrev, DW_FORM_addr, DW_CLS_ADDRESS, st, s.StartPC)
1185 putattr(ctxt, s.Info, abbrev, DW_FORM_addr, DW_CLS_ADDRESS, en, s.StartPC)
1190 putattr(ctxt, s.Info, abbrev, DW_FORM_udata, DW_CLS_CONSTANT, int64(ic.CallLine), nil)
1201 putvar(ctxt, s, v, callee, abbrev, inlIndex, encbuf[:0])
1228 abbrev := DW_ABRV_FUNCTION_CONCRETE
1229 Uleb128put(ctxt, s.Info, int64(abbrev))
1232 putattr(ctxt, s.Info, abbrev, DW_FORM_ref_addr, DW_CLS_REFERENCE, 0, s.Absfn)
1235 putattr(ctxt, s.Info, abbrev, DW_FORM_addr, DW_CLS_ADDRESS, 0, s.StartPC)
1236 putattr(ctxt, s.Info, abbrev, DW_FORM_addr, DW_CLS_ADDRESS, s.Size, s.StartPC)
1239 putattr(ctxt, s.Info, abbrev, DW_FORM_block1, DW_CLS_BLOCK, 1, []byte{DW_OP_call_frame_cfa})
1242 if err := putPrunedScopes(ctxt, s, abbrev); err != nil {
1268 abbrev := DW_ABRV_FUNCTION
1269 Uleb128put(ctxt, s.Info, int64(abbrev))
1272 putattr(ctxt, s.Info, abbrev, DW_FORM_addr, DW_CLS_ADDRESS, 0, s.StartPC)
1273 putattr(ctxt, s.Info, abbrev, DW_FORM_addr, DW_CLS_ADDRESS, s.Size, s.StartPC)
1274 putattr(ctxt, s.Info, abbrev, DW_FORM_block1, DW_CLS_BLOCK, 1, []byte{DW_OP_call_frame_cfa})
1281 putattr(ctxt, s.Info, abbrev, DW_FORM_flag, DW_CLS_FLAG, ev, 0)
1284 if err := putPrunedScopes(ctxt, s, abbrev); err != nil {
1339 // Given a default var abbrev code, select corresponding concrete code.
1355 // Pick the correct abbrev code for variable or parameter DIE.
1357 abbrev := v.Abbrev
1363 case abbrev == DW_ABRV_AUTO_LOCLIST && len(v.LocationList) == 0:
1365 abbrev = DW_ABRV_AUTO
1366 case abbrev == DW_ABRV_PARAM_LOCLIST && len(v.LocationList) == 0:
1368 abbrev = DW_ABRV_PARAM
1380 // then use the default (non-concrete) abbrev for this param.
1389 // Select proper abbrev based on concrete/non-concrete
1391 abbrev = concreteVarAbbrev(abbrev)
1394 return abbrev, missing, concrete
1397 func abbrevUsesLoclist(abbrev int) bool {
1398 switch abbrev {
1409 // Remap abbrev
1410 abbrev := v.Abbrev
1411 switch abbrev {
1413 abbrev = DW_ABRV_AUTO_ABSTRACT
1415 abbrev = DW_ABRV_PARAM_ABSTRACT
1418 Uleb128put(ctxt, info, int64(abbrev))
1419 putattr(ctxt, info, abbrev, DW_FORM_string, DW_CLS_STRING, int64(len(v.Name)), v.Name)
1422 if abbrev == DW_ABRV_PARAM_ABSTRACT {
1427 putattr(ctxt, info, abbrev, DW_FORM_flag, DW_CLS_FLAG, isReturn, nil)
1431 if abbrev != DW_ABRV_PARAM_ABSTRACT {
1433 putattr(ctxt, info, abbrev, DW_FORM_udata, DW_CLS_CONSTANT, int64(v.DeclLine), nil)
1437 putattr(ctxt, info, abbrev, DW_FORM_ref_addr, DW_CLS_REFERENCE, 0, v.Type)
1443 // Remap abbrev according to parent DIE abbrev
1444 abbrev, missing, concrete := determineVarAbbrev(v, fnabbrev)
1446 Uleb128put(ctxt, s.Info, int64(abbrev))
1454 putattr(ctxt, s.Info, abbrev, DW_FORM_ref_addr, DW_CLS_REFERENCE, 0, absfn)
1459 putattr(ctxt, s.Info, abbrev, DW_FORM_string, DW_CLS_STRING, int64(len(n)), n)
1460 if abbrev == DW_ABRV_PARAM || abbrev == DW_ABRV_PARAM_LOCLIST || abbrev == DW_ABRV_PARAM_ABSTRACT {
1465 putattr(ctxt, s.Info, abbrev, DW_FORM_flag, DW_CLS_FLAG, isReturn, nil)
1467 putattr(ctxt, s.Info, abbrev, DW_FORM_udata, DW_CLS_CONSTANT, int64(v.DeclLine), nil)
1468 putattr(ctxt, s.Info, abbrev, DW_FORM_ref_addr, DW_CLS_REFERENCE, 0, v.Type)
1471 if abbrevUsesLoclist(abbrev) {
1472 putattr(ctxt, s.Info, abbrev, DW_FORM_sec_offset, DW_CLS_PTR, int64(s.Loc.Len()), s.Loc)
1485 putattr(ctxt, s.Info, abbrev, DW_FORM_block1, DW_CLS_BLOCK, int64(len(loc)), loc)