public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
From: Indu Bhagat <indu.bhagat@oracle.com>
To: Jan Beulich <jbeulich@suse.com>
Cc: binutils@sourceware.org
Subject: Re: [COMMITTED] libsframe: revisit sframe_find_fre API
Date: Fri, 26 May 2023 00:43:48 -0700	[thread overview]
Message-ID: <7116fffa-c436-b2d7-3c0a-acbb0283f048@oracle.com> (raw)
In-Reply-To: <b27b6d81-1b10-9e2f-98c9-5285161f1a23@suse.com>

On 5/26/23 00:30, Jan Beulich wrote:
> On 26.05.2023 09:01, Indu Bhagat via Binutils wrote:
>> @@ -1022,40 +1049,28 @@ sframe_find_fre (sframe_decoder_ctx *ctx, int32_t pc,
>>       bitmask = 0xff;
>>   
>>     fres = ctx->sfd_fres + fdep->sfde_func_start_fre_off;
>> +  func_start_addr = fdep->sfde_func_start_address;
>> +
>>     for (i = 0; i < fdep->sfde_func_num_fres; i++)
>>      {
>> -     err = sframe_decode_fre (fres, &next_fre, fre_type, &esz);
>> -     start_address = next_fre.fre_start_addr;
>> +     err = sframe_decode_fre (fres, &cur_fre, fre_type, &size);
>> +     if (err)
>> +       return sframe_set_errno (&err, SFRAME_ERR_FRE_INVAL);
>>   
>> -     if (((fdep->sfde_func_start_address
>> -	   + (int32_t) start_address) & bitmask) <= (pc & bitmask))
>> +     start_ip = func_start_addr + cur_fre.fre_start_addr;
>> +     end_ip_offset = sframe_fre_get_end_ip_offset (fdep, i, fres + size);
>> +     end_ip = func_start_addr + end_ip_offset;
>> +
>> +     if ((start_ip & bitmask) > (pc & bitmask))
>> +       return sframe_set_errno (&err, SFRAME_ERR_FRE_INVAL);
>> +
>> +     if (((start_ip & bitmask) <= (pc & bitmask))
>> +	 && (end_ip & bitmask) >= (pc & bitmask))
>>          {
>> -	 sframe_frame_row_entry_copy (&cur_fre, &next_fre);
>> -
>> -	 /* Get the next FRE in sequence.  */
>> -	 if (i < fdep->sfde_func_num_fres - 1)
>> -	   {
>> -	     sp += esz;
> 
> The buildbot failure just reported was found on the commit prior to this
> one, which removed the declaration of sp. Please try to make sure that
> every patch builds (and works) okay individually.
> 
> Jan

[(Re)Sending to binutils@sourceware, I earlier sent my apologies to the 
builder@ ;-) ]

Yes, my apologies. Turns out the 4 commits I just did were not 
bisectable truly. I split a change into two logical commits, and missed 
testing them one by one.

Revision: 812d868850126d8e791795c7e248ffbf580925f6 causes build 
failures, but the subsequent commit (Revision: 
83c219872b2131546ccec7edc57eb47c64b8911d) fixes the issue.

Will take care in future.

Indu

  reply	other threads:[~2023-05-26  7:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-26  7:01 [COMMITTED] libsframe: use uint8_t data type for FRE info related stubs Indu Bhagat
2023-05-26  7:01 ` [COMMITTED] libsframe: use const char * consistently for immutable FRE buffers Indu Bhagat
2023-05-26  7:01 ` [COMMITTED] libsframe: revisit sframe_find_fre API Indu Bhagat
2023-05-26  7:30   ` Jan Beulich
2023-05-26  7:43     ` Indu Bhagat [this message]
2023-05-26  7:01 ` [COMMITTED] sframe/doc: minor improvements for readability Indu Bhagat

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7116fffa-c436-b2d7-3c0a-acbb0283f048@oracle.com \
    --to=indu.bhagat@oracle.com \
    --cc=binutils@sourceware.org \
    --cc=jbeulich@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).