------- Comment #17 from jakub at gcc dot gnu dot org 2008-03-04 15:10 ------- .cfi_* doesn't create .dwarf_frame, but perhaps it could be taught to do that optionally (some flag on .cfi_startproc that would switch on additional creation of .dwarf_frame). The plan with save/restore was that you could do say .text .cfi_startproc .cfi_personality 3, __gxx_personality_v0 .cfi_lsda 3, .LLSDA2 some code plus .cfi_* instructions for it jmp 1f .cfi_save .L0123 .section .text.unlikely .cfi_startproc .cfi_personality 3, __gxx_personality_v0 .cfi_lsda .LLSDA2 .cfi_restore .L0123 1: some code plus .cfi_* instructions for it .cfi_endproc .previous .cfi_endproc
where that .cfi_save would add a list of .cfi_* instructions from .cfi_startproc till that .cfi_save into .L0123 queue, then .cfi_restore would just add those queued .cfi directives all at the same location (with some optimizations, e.g. .cfi_* instructions that clearly cancel themselves would be optimized out, any location advances of course taken out, etc.). You can of course do that in dwarf2out.c, but we eventually want to use inline .cfi_* instructions for other reasons - e.g. so that inline asm code can add its unwind info. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34999