Re: False positive permanent breakpoints

Ofir Cohen <[email protected]>
Newsgroups gmane.comp.gdb.devel
Message-ID <CAHOBVAc9CdUbKoc01fi_00=HyEmHeNwqnGQ6fyVm2a33mRUUvg@mail.gmail.com>
> I'd rather that upstreaming that bit was done when the
> rest of the port is submitted as well.
Alright, will do.

As a temporary mitigation,
Is it OK for the target to return NULL from gdbarch_breakpoint_from_pc
to state that it doesn't support software breakpoints ?


There are some places that check that return value, like:
/* Software breakpoints unsupported?  */
if (bpoint == NULL)
  return 0;

in bp_loc_is_permanent(), and others that don't, like breakpoint_xfer_memory().
Furthermore, it performs pointer arithmetic based on the returned value.

Currently the tests we have pass, but I'm concerned about other corner
cases are not covered
that might pop up as a result of this change.

Thanks,
Ofir

On 26 October 2016 at 17:50, Pedro Alves <[email protected]> wrote:
> On 10/26/2016 03:42 PM, Ofir Cohen wrote:
>> Hi Pedro,
>> Thanks for the reply.
>> Let me provide some clarifications :-).
>>
>> 1) The product is part of the "Intel SDK for OpenCL" [1] for Windows and Linux.
>>      You can see how it looks in [2].
>
> Ah, OK.
>
>>
>> 2) iGPU - Yes, Integrated GPU
>>
>> 3) Upstream is in our plans and actually we are preparing a clean
>>     series of patches on top of 7.12 (currently we are rebased on top
>> of 7.6, yeah I know...).
>
> Nice!
>
> (FAOD, for upstream you'll need to rebase on master.)
>
>>
>> 4) Software breakpoints are officially supported by the HW, but
>>     haven't been tested and used yet, so we're OK with them being
>> "disabled" at the moment.
>>
>> The sources for gdb (as well as other components) are provided with
>> the installer script,
>> which can be downloaded _free of charge_ via [1] --> "Download" .
>>
>> Is that good enough for making an upstream change?
>>
>> I can try and prepare a small patch.
>
> I'd rather that upstreaming that bit was done when the
> rest of the port is submitted as well.
>
> Thanks,
> Pedro Alves
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.