]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
gas: libsframe: use SFRAME_V2_* macro where available
authorIndu Bhagat <indu.bhagat@oracle.com>
Tue, 7 Jan 2025 23:50:58 +0000 (15:50 -0800)
committerIndu Bhagat <indu.bhagat@oracle.com>
Tue, 9 Dec 2025 08:26:11 +0000 (00:26 -0800)
No functional change.

gas/
        * sframe-opt.c (sframe_convert_frag): Use SFRAME_V2_
prefixed macro instead.
libsframe/
* sframe-dump.c (dump_sframe_func_with_fres): Likewise.
        * sframe.c (sframe_get_fre_type): Likewise.
        (sframe_get_fde_type): Likewise.
        (sframe_fde_create_func_info): Likewise.

gas/sframe-opt.c
libsframe/sframe-dump.c
libsframe/sframe.c

index 655207348282dbc36fe1027f7e4a58495b1714f0..690617fab44a705651bbb0d177b4a9637fd1936d 100644 (file)
@@ -116,8 +116,8 @@ sframe_convert_frag (fragS *frag)
         the fre_type.  */
       dataS = exp->X_add_symbol;
       rest_of_data = (symbol_get_value_expression(dataS))->X_add_number;
-      fde_type = SFRAME_V1_FUNC_FDE_TYPE (rest_of_data);
-      pauth_key = SFRAME_V1_FUNC_PAUTH_KEY (rest_of_data);
+      fde_type = SFRAME_V2_FUNC_FDE_TYPE (rest_of_data);
+      pauth_key = SFRAME_V2_FUNC_PAUTH_KEY (rest_of_data);
       gas_assert (fde_type == SFRAME_FDE_TYPE_PCINC);
 
       /* Calculate the applicable fre_type.  */
@@ -131,8 +131,8 @@ sframe_convert_frag (fragS *frag)
        fre_type = SFRAME_FRE_TYPE_ADDR4;
 
       /* Create the new function info.  */
-      value = SFRAME_V1_FUNC_INFO (fde_type, fre_type);
-      value = SFRAME_V1_FUNC_INFO_UPDATE_PAUTH_KEY (pauth_key, value);
+      value = SFRAME_V2_FUNC_INFO (fde_type, fre_type);
+      value = SFRAME_V2_FUNC_INFO_UPDATE_PAUTH_KEY (pauth_key, value);
 
       frag->fr_literal[frag->fr_fix] = value;
     }
index a1a67e98fe6c05db5328d844c8ee7781217a52b2..dc856cd13563d5e217f2198082e590181b0e17bf 100644 (file)
@@ -156,7 +156,7 @@ dump_sframe_func_with_fres (sframe_decoder_ctx *sfd_ctx,
 
   /* Mark FDEs with [m] where the FRE start address is interpreted as a
      mask.  */
-  int fde_type_addrmask_p = (SFRAME_V1_FUNC_FDE_TYPE (func_info)
+  int fde_type_addrmask_p = (SFRAME_V2_FUNC_FDE_TYPE (func_info)
                             == SFRAME_FDE_TYPE_PCMASK);
   const char *fde_type_marker
     = (fde_type_addrmask_p ? "[m]" : "   ");
@@ -167,7 +167,7 @@ dump_sframe_func_with_fres (sframe_decoder_ctx *sfd_ctx,
          func_size);
 
   if (is_sframe_abi_arch_aarch64 (sfd_ctx)
-      && (SFRAME_V1_FUNC_PAUTH_KEY (func_info) == SFRAME_AARCH64_PAUTH_KEY_B))
+      && (SFRAME_V2_FUNC_PAUTH_KEY (func_info) == SFRAME_AARCH64_PAUTH_KEY_B))
     printf (", pauth = B key");
 
   char temp[100];
index 8c4159e27b5335a1a08c6463acd42092937001b6..16fc3a3f11bf25292bae8cbb7e3506daac3f731d 100644 (file)
@@ -209,7 +209,7 @@ sframe_get_fre_type (sframe_func_desc_entry_int *fdep)
 {
   uint32_t fre_type = 0;
   if (fdep)
-    fre_type = SFRAME_V1_FUNC_FRE_TYPE (fdep->func_info);
+    fre_type = SFRAME_V2_FUNC_FRE_TYPE (fdep->func_info);
   return fre_type;
 }
 
@@ -218,7 +218,7 @@ sframe_get_fde_type (sframe_func_desc_entry_int *fdep)
 {
   uint32_t fde_type = 0;
   if (fdep)
-    fde_type = SFRAME_V1_FUNC_FDE_TYPE (fdep->func_info);
+    fde_type = SFRAME_V2_FUNC_FDE_TYPE (fdep->func_info);
   return fde_type;
 }
 
@@ -806,7 +806,7 @@ sframe_fde_create_func_info (uint32_t fre_type,
                   || fre_type == SFRAME_FRE_TYPE_ADDR4);
   sframe_assert (fde_type == SFRAME_FDE_TYPE_PCINC
                    || fde_type == SFRAME_FDE_TYPE_PCMASK);
-  func_info = SFRAME_V1_FUNC_INFO (fde_type, fre_type);
+  func_info = SFRAME_V2_FUNC_INFO (fde_type, fre_type);
   return func_info;
 }