Patchwork [sdbout] : Fix regression in sdbout.c

login
register
mail settings
Submitter Kai Tietz
Date March 5, 2013, 5:31 p.m.
Message ID <CAEwic4aUvRRejf10UVDLuxZr8LMvrHg9oXwSGZuJDqGQemfCxA@mail.gmail.com>
Download mbox | patch
Permalink /patch/225110/
State New
Headers show

Comments

Kai Tietz - March 5, 2013, 5:31 p.m.
Hello,

this patch fixes a regression in gcc.dg/debug/tls-1.c testcase for -gcoff<n>.

ChangeLog

2013-03-05  Kai Tietz  <ktietz@redhat.com>

	* sdbout.c (sdbout_one_type): Switch to current function's section
	supporting cold/hot.

Tested for x86_64-w64-mingw32.  Ok for apply?
Richard Henderson - March 5, 2013, 5:57 p.m.
On 03/05/2013 09:31 AM, Kai Tietz wrote:
> 2013-03-05  Kai Tietz  <ktietz@redhat.com>
> 
> 	* sdbout.c (sdbout_one_type): Switch to current function's section
> 	supporting cold/hot.

Ok.


r~

Patch

Index: sdbout.c
===================================================================
--- sdbout.c	(Revision 196451)
+++ sdbout.c	(Arbeitskopie)
@@ -1017,7 +1017,7 @@  sdbout_one_type (tree type)
       && DECL_SECTION_NAME (current_function_decl) != NULL_TREE)
     ; /* Don't change section amid function.  */
   else
-    switch_to_section (text_section);
+    switch_to_section (current_function_section ());

   switch (TREE_CODE (type))
     {