This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Signal Trampoline Frames


Andrew,

It's probably too late now, but I have the feeling this new
tramp-frame.c is not generic enough.  It assumes fixed-length
instructions (which makes it unsuitable for IA-32 and AMD64)

I didn't forget IA-32, I figured that it is always little endian so a sequence of one byte "insns" would work.


> and uses
the arbitrary number 8 for the number of instructions (which makes it
not quite suitable for SPARC).

I'm assuming people will increase it (It's like the arbitrary number 16 for the largest possible size of an instruction).


> The whole thing seems a bit
over-engineered to me :-(.

In what way?


I wrote it after churn out 4 almost identical signal trampolines - so it works for one type but not for others. You also haven't seen my test cases :-)

Anyway, you might want to conseider the attached patch, which makes
the comments catch up with reality.  The extra whitespace is there to
guide the eye and make the distinction between the instruction
sequence members and the initialization function clear.

Andrew




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]