[PATCH] [AArch64] support -mfentry feature for arm64
Andrew Haley
aph@redhat.com
Mon Apr 18 17:17:00 GMT 2016
On 04/18/2016 06:13 PM, Michael Matz wrote:
> On Mon, 18 Apr 2016, Andrew Haley wrote:
>
>> On 04/15/2016 06:29 PM, Alexander Monakov wrote:
>>
>>> Alternatively: replace first nop with a short forward branch that
>>> jumps over the rest of the pad, patch rest of the pad, patch the
>>> initial forward branch.
>>
>> That may not be safe. Consider an implementation which looks ahead in
>> the instruction stream and decodes the instructions speculatively.
>
> It should go without saying that patching instructions is followed by
> whatever means necessary to flush any such caches on a particular
> implementation (here after patching the jump, after patching the rest, and
> after patching the first insn again, i.e. three times).
That doesn't necessarily help you, though, without an ISB in the reading
thread.
Andrew.
More information about the Gcc-patches
mailing list