diff mbox

Fix v850 builds with current trunk

Message ID 18283fd1-6669-e6fe-6a12-aafd65108ca8@redhat.com
State New
Headers show

Commit Message

Jeff Law Oct. 25, 2016, 2:39 p.m. UTC
Two issues in the v850 port.  One is just a comment tweak to make the 
fallthru bits happy.  The other appears to be a real bug caught by the 
fallthru bits.

The v850 has various data sections and we have the ability to place 
uninitialized commons in each of them.  Of course to do that we have to 
switch to the appropriate section.

For something in the TDA section, the code, as written, would switch 
into the TDA section, then immediately switch to the default bss section 
because of the missing break.

I've confirmed the various v850 targets from config-list.mk build after 
this patch.  Installed on the trunk.

Jeff
commit aee9c0c19174d8be33a36f1cf45a370a8e3d8134
Author: law <law@138bc75d-0d04-0410-961f-82ee72b054a4>
Date:   Tue Oct 25 14:39:34 2016 +0000

    	* config/v850/v850.c (v850_handle_data_area_attribute): Fix fallthru
    	comment.
    	(v850_output_aligned_bss): Add missing break.
    
    git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@241513 138bc75d-0d04-0410-961f-82ee72b054a4
diff mbox

Patch

diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 6bbb32c..9715896 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,9 @@ 
 2016-10-25  Jeff Law  <law@redhat.com>
 
+	* config/v850/v850.c (v850_handle_data_area_attribute): Fix fallthru
+	comment.
+	(v850_output_aligned_bss): Add missing break.
+
 	* config/m68k/m68k.c (m68k_get_reloc_decoration): Add gcc_unreachable.
 
 2016-10-25  Martin Liska  <mliska@suse.cz>
diff --git a/gcc/config/v850/v850.c b/gcc/config/v850/v850.c
index 47344fc..91e182f 100644
--- a/gcc/config/v850/v850.c
+++ b/gcc/config/v850/v850.c
@@ -2122,7 +2122,7 @@  v850_handle_data_area_attribute (tree* node,
 	  *no_add_attrs = true;
 	}
 
-      /* Drop through.  */
+      /* FALLTHRU */
 
     case FUNCTION_DECL:
       area = v850_get_data_area (decl);
@@ -2477,6 +2477,7 @@  v850_output_aligned_bss (FILE * file,
 
     case DATA_AREA_TDA:
       switch_to_section (tdata_section);
+      break;
       
     default:
       switch_to_section (bss_section);