mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-19 05:37:54 +00:00
5db2971903
In case of arm_v7a Kernel::call64 the syscall will use both r0 and r1 as output registers. Unfortunately the inline asm does not reflect this and only r0 is explicitly specified as output. GCC manages to produce output which we'd like to see. Clang on the other hand takes adventage of the fact r1 should not be touched by swi and produces fewer instructions which do what the code describes, but not what we actually want. Basically the code which we want and is generated by GCC is: svc 0 mov r2, r0 mov r0, r1 mov r1, r2 bx lr Clang on the other hand generates correct assembly given the code, but incorrect given what the function is supposed to do: svc 0 mov r1, r0 mov r0, #0 bx lr Both GCC and clang generate the same, expected assembly output when r1 is marked as output register from the inline asm swi call. Fixes #3951 |
||
---|---|---|
.. | ||
doc | ||
etc | ||
include | ||
lib/mk | ||
patches | ||
ports | ||
recipes | ||
run | ||
src |