diff mbox

PR51280 LTO/trans-mem ICE with TM builtins

Message ID 4F1B42CC.60808@gmail.com
State New
Headers show

Commit Message

Patrick Marlier Jan. 21, 2012, 10:57 p.m. UTC
On 01/20/2012 08:04 AM, Dominique Dhumieres wrote:
>> The following patch fixes the problem.
>
> The test fails on *-apple-darwin*: pr51916.
>
> TIA
>
> Dominique

Dominique or Iain, may I ask you to test this patch on darwin? I have a 
sporadic access to a darwin machine.

Bootstrapped and tested on x86_64-unknown-linux-gnu.
--
Patrick.

	PR lto/51916
	* lto-object.c (LTO_SEGMENT_NAME): Define segment name.
	(lto_obj_file_open): Use it.

Comments

Dominique d'Humières Jan. 22, 2012, 11:10 a.m. UTC | #1
> Dominique or Iain, may I ask you to test this patch on darwin? I have a
> sporadic access to a darwin machine.

The patch fixes the PR without regression on x86_64-apple-darwin10.
Bootstraping on powerpc-apple-darwin9 will finish in a couple hours.

Thanks for the debugging and the patch,

Dominique
Iain Sandoe Jan. 22, 2012, 11:29 a.m. UTC | #2
Hi Patrick,

thanks for doing this,

On 21 Jan 2012, at 22:57, Patrick Marlier wrote:

> Dominique or Iain, may I ask you to test this patch on darwin? I  
> have a sporadic access to a darwin machine.

bootstrapped on i686-darwin9 - tests in progress...

minor observations:
> 	PR lto/51916
> 	* lto-object.c (LTO_SEGMENT_NAME): Define segment name.
	* lto-wrapper.c (

> 	(lto_obj_file_open): Use it.
	(run_gcc):

cheers
Iain
diff mbox

Patch

Index: lto-wrapper.c
===================================================================
--- lto-wrapper.c	(revision 183345)
+++ lto-wrapper.c	(working copy)
@@ -54,6 +54,11 @@  along with GCC; see the file COPYING3.  If not see
 
 /* End of lto-streamer.h copy.  */
 
+/* Segment name for LTO sections.  This is only used for Mach-O.
+   FIXME: This needs to be kept in sync with darwin.c.  */
+
+#define LTO_SEGMENT_NAME "__GNU_LTO"
+
 int debug;				/* true if -save-temps.  */
 int verbose;				/* true if -v.  */
 
@@ -479,7 +484,8 @@  run_gcc (unsigned argc, char *argv[])
       fd = open (argv[i], O_RDONLY);
       if (fd == -1)
 	continue;
-      sobj = simple_object_start_read (fd, file_offset, NULL, &errmsg, &err);
+      sobj = simple_object_start_read (fd, file_offset, LTO_SEGMENT_NAME,
+				       &errmsg, &err);
       if (!sobj)
 	{
 	  close (fd);