Here is a follow-on patch. I noticed that dwarf2_emit_label() can also use the new dwarf2_consume_line_info function. Is this OK? I forgot to say how I tested this. I built binutils for xtensa-elf, ia64-unknown-linux-gnu and i686-pc-linux-gnu targets, all hosted on i686-pc-linux-gnu, and ran the testsuite. I've rerun those tests now with this follow-on patch. Everything passed as expected with one exception: the ld-ia64/line.exp test fails but I see the same failure without any of my changes. ld fails to show the source line number in an error message. That does seem suspicious. Is this a known problem? gas/ * dwarf2dbg.c (dwarf2_emit_label): Use dwarf2_consume_line_info.