On 2023-07-31 21:41, Max Filippov wrote:
Hi Daniel,
On Mon, Jul 31, 2023 at 12:21 PM <daniel@xxxxxxxxxxx> wrote:
I would like to modify the relaxation behavior of Xtensa assembly.
Furthermore, I only want to modify the last relaxation of a call8
instruction.
So my question is: how do I know which is the last relaxation in a
function?
Could you elaborate a bit on the "last" part. Last in what sense?
In case a function calls multiple other functions I would like to be
able to modify the relaxation of the "last" call8 instruction happening
in this function.
BTW: I'm compiling with -mlongcalls.
I don't think so. On the other hand windowed functions always begin
with the entry instruction and end with either retw or retw.n
instruction.
For this I would need to be able to look into the "future". Can I
traverse fragP->fr_next for that? Does fr_opcode contain the opcode of
"retw" instructions as well?
Thanks,
Daniel