This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Set thumb MODE_RECORDED flag for non-elf


Daniel Jacobowitz wrote:
In the patch that introduced the failing assertion, the assertion in
arm_handle_align was not conditionalized on OBJ_ELF.  It looks like
Nick added that #ifdef a couple of weeks after I checked in the
previous patch.  Can that #ifdef be removed with this change?

Looks like it can - I just tried without it and it seems fine.


Updated patch below - OK to commit?

Thanks,

Andrew Jenner
CodeSourcery


gas/ChangeLog


2009-12-10 Andrew Jenner <andrew@codesourcery.com>

	* config/tc-arm.c (arm_init_frag): Set thumb MODE_RECORDED flag
	for non-elf.
	(arm_handle_align): Re-enable assert for non-elf.


Index: config/tc-arm.c =================================================================== RCS file: /cvs/src/src/gas/config/tc-arm.c,v retrieving revision 1.418 diff -u -p -r1.418 tc-arm.c --- config/tc-arm.c 2 Dec 2009 20:26:30 -0000 1.418 +++ config/tc-arm.c 11 Dec 2009 00:24:16 -0000 @@ -18574,9 +18574,7 @@ arm_handle_align (fragS * fragP) if (bytes > MAX_MEM_FOR_RS_ALIGN_CODE) bytes &= MAX_MEM_FOR_RS_ALIGN_CODE;

-#ifdef OBJ_ELF
   gas_assert ((fragP->tc_frag_data.thumb_mode & MODE_RECORDED) != 0);
-#endif

   if (fragP->tc_frag_data.thumb_mode & (~ MODE_RECORDED))
     {
@@ -18682,7 +18680,7 @@ void
 arm_init_frag (fragS * fragP, int max_chars ATTRIBUTE_UNUSED)
 {
   /* Record whether this frag is in an ARM or a THUMB area.  */
-  fragP->tc_frag_data.thumb_mode = thumb_mode;
+  fragP->tc_frag_data.thumb_mode = thumb_mode | MODE_RECORDED;
 }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]