Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-devel / 2009-08

arm eabi test suite

3 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Henry Vermaak

I've managed to run a native testsuite on my nslu2, I can email the tarball if anyone is interested (I think the mailing list will reject it).

There are a couple of backtraces also in the longlog, which I attach, too. Not sure if it is helpful.

I spotted some asm in ossysc.inc that will not work on eabi:

swi syscall_nr_sigreturn (same for rt_sigreturn)

For eabi this should probably be:

mov r7,syscall_nr_sigreturn
swi #0x0

But should r7 saved before and restored afterwards? I don't know how to test this code.

Thanks

Henry

Reply by email

Jonas Maebe
to Henry Vermaak
Henry Vermaak wrote
I've managed to run a native testsuite on my nslu2, I can email the tarball if anyone is interested (I think the mailing list will reject it).

Is it different from the tarball you attached to http://bugs.freepascal.org/view.php?id=14386 ? I already imported that one into the testsuite database: http://www.freepascal.org/testsuite/cgi-bin/testsuite.cgi?action=1&run1id=42245&run2id=&noskipped=1&failedonly=1

There are a couple of backtraces also in the longlog, which I attach, too. Not sure if it is helpful.

Not really.

Show quoted text 10 lines
I spotted some asm in ossysc.inc that will not work on eabi: swi syscall_nr_sigreturn (same for rt_sigreturn) For eabi this should probably be: mov r7,syscall_nr_sigreturn swi #0x0 But should r7 saved before and restored afterwards?

There is no "afterwards" for a sigreturn system call, as it restores the context that was saved when the signal was triggered (so code coming after the swi is never executed, except possibly in case of an error that didn't crash the program).

I don't know how to test this code.

You normally never need to explicitly use this system call. The kernel usually puts a stub somewhere in memory containing this system call and makes the return address of signal handlers point to that stub.

Jonas

Reply by email

Henry Vermaak
to Jonas Maebe

2009/8/22 Jonas Maebe :

Show quoted text 6 lines
Is it different from the tarball you attached to http://bugs.freepascal.org/view.php?id=14386 ? I already imported that one into the testsuite database: http://www.freepascal.org/testsuite/cgi-bin/testsuite.cgi?action=1&run1id=42245&run2id=&noskipped=1&failedonly=1

Yes, this time I ran the testsuite natively, so I think a lot more of the tests have run (and passed), consequently taking much longer (3.5 hours). I guess the same tests would have failed again, so maybe there's no use.

This run also includes the sigreturn patch below.

Show quoted text 17 lines
> For eabi this should probably be: > > mov   r7,syscall_nr_sigreturn > swi   #0x0 > > But should r7 saved before and restored afterwards? There is no "afterwards" for a sigreturn system call, as it restores the context that was saved when the signal was triggered (so code coming after the swi is never executed, except possibly in case of an error that didn't crash the program). > I don't know how to test this code. You normally never need to explicitly use this system call. The kernel usually puts a stub somewhere in memory containing this system call and makes the return address of signal handlers point to that stub.

Thanks for the explanation. I guess the DoSyscall function can then be used instead of this assembler code? Then there won't be yet another ifdef here.

Henry

Reply by email