[llvm-commits] proposed patch to make mips16 exception handling work
rkotler at mips.com
Sun Nov 4 11:07:19 PST 2012
The main idea is to distinguish between emitting normal labels and debug
labels. This is the nomenclature chosen by the gcc people working on
this same problem.
I have just added one EmitDebugLabel call, because that is all that is
needed for now to get exceptions to work.
For the general dwarf, the call needs to be made most likely for all
labels apart from the landing pad label.
By default normal and debug labels will be the same.
For Mips, I emit debug labels as:
On 11/04/2012 11:00 AM, Reed Kotler wrote:
> I have posted some notes on this subject in the llvm developer area.
> Probably this patch should be comitted in two pieces, if accepted. The
> general change to mcstreamer and dwarf emitter, and the target specific
> mips16 piece. The mcstreamer and dwarf emitter part could also be split
> in two.
> There may be a better way to do this but this works and is reasonably
> See discussion of "symbols for exception handling" in the developers list.
> The crux of the problem is that the linker adds a 1 to addresses of
> mips16 routines.
> When you call a function, the ISA determines whether you are in mips16
> or mips32 by the presence
> or absence of this bit.
> Some notes from the gcc mips16 checkins for this explain a lot of the
> I will add a test case for the mips specific part.
> I have post commit review privilege for the mips area but not for any
> target independent areas.
> llvm-commits mailing list
> llvm-commits-Tmj1lob9twqVc3sceRu5cw at public.gmane.org
More information about the llvm-commits