File tree Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Expand file tree Collapse file tree 1 file changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -190,6 +190,8 @@ func (fi *frameInfo) exec(bytecode []byte) ([]frameInfoLine, error) {
190190 }
191191 return nil , err
192192 }
193+ // For details on the various opcodes, see:
194+ // http://dwarfstd.org/doc/DWARF5.pdf (page 239)
193195 highBits := op >> 6 // high order 2 bits
194196 lowBits := op & 0x1f
195197 switch highBits {
@@ -217,6 +219,17 @@ func (fi *frameInfo) exec(bytecode []byte) ([]frameInfoLine, error) {
217219 fi .loc += uint64 (offset ) * fi .cie .codeAlignmentFactor
218220 entries = append (entries , fi .newLine ())
219221 // TODO: DW_CFA_advance_loc2 etc
222+ case 0x05 : // DW_CFA_offset_extended
223+ // Semantics are the same as DW_CFA_offset, but the encoding is
224+ // different. Ignore it just like DW_CFA_offset.
225+ _ , err := readULEB128 (r ) // ULEB128 register
226+ if err != nil {
227+ return nil , err
228+ }
229+ _ , err = readULEB128 (r ) // ULEB128 offset
230+ if err != nil {
231+ return nil , err
232+ }
220233 case 0x07 : // DW_CFA_undefined
221234 // Marks a single register as undefined. This is used to stop
222235 // unwinding in tinygo_startTask using:
You can’t perform that action at this time.
0 commit comments