AARCH64: 8139041: Redundant DMB instructions (CORRECTED )

Roland Westrelin roland.westrelin at oracle.com
Fri Oct 9 16:37:10 UTC 2015

>> Isn’t your new field a bit like:
>>  address       insts_mark() const       { return _insts.mark();       }
>>  void      set_insts_mark()             {        _insts.set_mark();   }
>>  void    clear_insts_mark()             {        _insts.clear_mark(); }
>> which is used in very few locations AFAIK. Do you think you could reuse that one?
> Yes, that's what it's based on.  I guess that is possible in theory,
> but AbstractAssembler::InstructionMark() looks like this:
>    InstructionMark(AbstractAssembler* assm) : _assm(assm) {
>      assert(assm->inst_mark() == NULL, "overlapping instructions");
>      _assm->set_inst_mark();
>    }
> so any instruction which leaves the mark set will trigger an assertion
> failure the next time InstructionMark is used.  I suppose that in
> extremis I could make every instruction which is not a memory barrier
> clear the mark, but ewww.  :(
> I suppose I could define an AArch64-specific version of
> InstructionMark which does not have this assert, but I'm not sure I
> like that either.


I don’t see a way around the shared code change so even if it’s not great, that’s ok with me.

Let’s see what (if) others have (something) to say.


More information about the hotspot-compiler-dev mailing list