strange segfault i386-dis.c:9815:28

Jan Beulich jbeulich@suse.com
Mon Mar 20 10:41:08 GMT 2023


On 20.03.2023 11:26, Alan Modra wrote:
> On Mon, Mar 20, 2023 at 06:27:20PM +1030, Alan Modra wrote:
>> On Mon, Mar 20, 2023 at 08:29:44AM +0100, Jan Beulich wrote:
>>> Does this actually go far enough? Functions called may be inlined, and
>>> hence further accesses of struct fields held in registers may occur.
>>
>> I think we are OK.  The fields accessed are ins.address_mode and
>> ins.info, which are set up early in print_insn and read-only past the
>> setjmp.
> 
> Perhaps you are correct that my change doesn't go far enough for a
> different reason.  Accessing these local var structs using a volatile
> qualified pointer may indeed read the object, but I don't think
> changed values are guaranteed to be written back to the object unless
> the actual object is declared volatile.

I was indeed wondering about that as well, but ...

> I'm going to revert my change.  It didn't cure the oss-fuzz testcase
> fails.

... had assumed you already knew it helped. Now that we know it doesn't,
maybe we indeed want to look into getting rid of this setjmp/longjmp
use.

Jan


More information about the Binutils mailing list