This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
[Xtensa] preserve assembly no-transform flag for data
- From: Bob Wilson <bwilson at tensilica dot com>
- To: binutils at sources dot redhat dot com
- Date: Thu, 20 Dec 2007 09:28:21 -0800
- Subject: [Xtensa] preserve assembly no-transform flag for data
This patch fixes an obscure case where the Xtensa "no-transform" directive was
not being honored by the linker for data included inside the no-tranform region.
The property table flags used to mark such a region were only being set for
instructions and literals. Committed.
2007-12-20 Bob Wilson <bob.wilson@acm.org>
* config/tc-xtensa.c (xtensa_elf_cons): Set frag flags for
expressions without suffixes.
(get_frag_property_flags): Preserve is_no_transform flag for frags
not marked as either instructions or literals.
Index: config/tc-xtensa.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-xtensa.c,v
retrieving revision 1.95
diff -u -p -r1.95 tc-xtensa.c
--- config/tc-xtensa.c 13 Dec 2007 19:03:44 -0000 1.95
+++ config/tc-xtensa.c 20 Dec 2007 17:13:56 -0000
@@ -1558,7 +1558,10 @@ xtensa_elf_cons (int nbytes)
}
}
else
- emit_expr (&exp, (unsigned int) nbytes);
+ {
+ xtensa_set_frag_assembly_state (frag_now);
+ emit_expr (&exp, (unsigned int) nbytes);
+ }
}
while (*input_line_pointer++ == ',');
@@ -10670,7 +10673,11 @@ get_frag_property_flags (const fragS *fr
prop_flags->is_literal = TRUE;
if (fragP->tc_frag_data.is_specific_opcode
|| fragP->tc_frag_data.is_no_transform)
- prop_flags->is_no_transform = TRUE;
+ {
+ prop_flags->is_no_transform = TRUE;
+ if (xtensa_frag_flags_is_empty (prop_flags))
+ prop_flags->is_data = TRUE;
+ }
if (fragP->tc_frag_data.is_unreachable)
prop_flags->is_unreachable = TRUE;
else if (fragP->tc_frag_data.is_insn)