public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
@ 2012-01-18 15:42 ` iains at gcc dot gnu.org
  2012-01-18 18:30 ` mrs at gcc dot gnu.org
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 11+ messages in thread
From: iains at gcc dot gnu.org @ 2012-01-18 15:42 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901

Iain Sandoe <iains at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |iains at gcc dot gnu.org
      Known to fail|                            |

--- Comment #23 from Iain Sandoe <iains at gcc dot gnu.org> 2012-01-18 14:16:31 UTC ---
I have a fix for this in progress see also PR 51784.

JFTR, I suspect the issue is moot in clang/llvm because they don't support
nested functions AFAICT - but use 'blocks' instead.

BTW, is there any access to the 'positron' branch - was it ever on an FSF
server?


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
  2012-01-18 15:42 ` [Bug target/10901] non-local goto's don't work on darwin iains at gcc dot gnu.org
@ 2012-01-18 18:30 ` mrs at gcc dot gnu.org
  2012-01-18 19:20 ` iains at gcc dot gnu.org
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 11+ messages in thread
From: mrs at gcc dot gnu.org @ 2012-01-18 18:30 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901

mrs@gcc.gnu.org <mrs at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mrs at gcc dot gnu.org

--- Comment #24 from mrs at gcc dot gnu.org <mrs at gcc dot gnu.org> 2012-01-18 17:19:07 UTC ---
apple-branch is what's on the FSF server.  The positron branch should be on the
Apple open source website, though, just grabbing the top of the tree (latest
version of gcc-4.2) I think would be preferable.  There is a version in the
llvm repo, though, it does have all the llvm goop in it as well.


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
  2012-01-18 15:42 ` [Bug target/10901] non-local goto's don't work on darwin iains at gcc dot gnu.org
  2012-01-18 18:30 ` mrs at gcc dot gnu.org
@ 2012-01-18 19:20 ` iains at gcc dot gnu.org
  2012-01-20 16:30 ` dominiq at lps dot ens.fr
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 11+ messages in thread
From: iains at gcc dot gnu.org @ 2012-01-18 19:20 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901

--- Comment #25 from Iain Sandoe <iains at gcc dot gnu.org> 2012-01-18 18:29:12 UTC ---
Created attachment 26370
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=26370
initial fix

this shares some changes with the fix to PR51784 (and that is somewhere to read
about the issues that prevent an easier fix).

AFAICT, the bugs are still present in the Apple OS tree - at least they are
with 4.2.1/5577 - which postdates the comments here.

Anyway, this is a starting point - I expect that there is scope to tidy it up.

As things stand we need to differentiate the load-picbase from the
reload-picbase on PPC because more of the work is done in the md.  On x86 it's
hidden away in i386.c - which made it easier to fix there.


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2012-01-18 19:20 ` iains at gcc dot gnu.org
@ 2012-01-20 16:30 ` dominiq at lps dot ens.fr
  2013-09-28 10:52 ` iains at gcc dot gnu.org
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 11+ messages in thread
From: dominiq at lps dot ens.fr @ 2012-01-20 16:30 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901

--- Comment #26 from Dominique d'Humieres <dominiq at lps dot ens.fr> 2012-01-20 16:24:34 UTC ---
I have done a clean bootstrap of r183305 on  powerpc-apple-darwin9 with the
patch in comment #25.
Regtesting in progress (allow for ~20 more hours), but gcc at -m32 has only 28
failures (including 16 for gcc.dg/simulate-thread/atomic-* instead of usually
12: I cannot say presently if it is due to some slow down due to the patch or
because I am using the machine while usually it is only devoted to the test
suite).


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
                   ` (3 preceding siblings ...)
  2012-01-20 16:30 ` dominiq at lps dot ens.fr
@ 2013-09-28 10:52 ` iains at gcc dot gnu.org
  2013-09-29 20:14 ` iains at gcc dot gnu.org
  2013-09-29 23:52 ` mrs at gcc dot gnu.org
  6 siblings, 0 replies; 11+ messages in thread
From: iains at gcc dot gnu.org @ 2013-09-28 10:52 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901

--- Comment #27 from Iain Sandoe <iains at gcc dot gnu.org> ---
patch posted.
http://gcc.gnu.org/ml/gcc-patches/2013-09/msg02066.html


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
                   ` (4 preceding siblings ...)
  2013-09-28 10:52 ` iains at gcc dot gnu.org
@ 2013-09-29 20:14 ` iains at gcc dot gnu.org
  2013-09-29 23:52 ` mrs at gcc dot gnu.org
  6 siblings, 0 replies; 11+ messages in thread
From: iains at gcc dot gnu.org @ 2013-09-29 20:14 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901

--- Comment #28 from Iain Sandoe <iains at gcc dot gnu.org> ---
Author: iains
Date: Sun Sep 29 20:14:39 2013
New Revision: 203019

URL: http://gcc.gnu.org/viewcvs?rev=203019&root=gcc&view=rev
Log:
gcc:

    PR target/10901
    * config/darwin-protos.h (machopic_get_function_picbase): New.
    * config/darwin.c (machopic_get_function_picbase): New.
    * config/rs6000/darwin.md (load_macho_picbase_si): Update picbase
    label for a new func.  (load_macho_picbase_di): Likewise.
    (reload_macho_picbase): New expand.
    (reload_macho_picbase_si): New insn.
    (reload_macho_picbase_di): New insn.
    (nonlocal_goto_receiver): New define and split.
    * config/rs6000/rs6000.md (unspec enum): Add UNSPEC_RELD_MPIC.
    (unspecv enum): Add UNSPECV_NLGR.


Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/config/darwin-protos.h
    trunk/gcc/config/darwin.c
    trunk/gcc/config/rs6000/darwin.md
    trunk/gcc/config/rs6000/rs6000.md


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
                   ` (5 preceding siblings ...)
  2013-09-29 20:14 ` iains at gcc dot gnu.org
@ 2013-09-29 23:52 ` mrs at gcc dot gnu.org
  6 siblings, 0 replies; 11+ messages in thread
From: mrs at gcc dot gnu.org @ 2013-09-29 23:52 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901

mrs at gcc dot gnu.org <mrs at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #29 from mrs at gcc dot gnu.org <mrs at gcc dot gnu.org> ---
Thanks all.


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-6064@http.gcc.gnu.org/bugzilla/>
                   ` (2 preceding siblings ...)
  2009-06-04  8:02 ` gcc at microbizz dot nl
@ 2010-05-01 22:41 ` howarth at nitro dot med dot uc dot edu
  3 siblings, 0 replies; 11+ messages in thread
From: howarth at nitro dot med dot uc dot edu @ 2010-05-01 22:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #22 from howarth at nitro dot med dot uc dot edu  2010-05-01 22:41 -------
This issue also appears to exist in llvm-gcc-4.2-2.7...

llvm-gcc -O3 -fnested-functions pr10901.c
pr10901.c: In function 'main':
pr10901.c:5: sorry, unimplemented: non-local gotos not supported by LLVM


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-6064@http.gcc.gnu.org/bugzilla/>
  2009-06-03 21:47 ` fxcoudert at gcc dot gnu dot org
  2009-06-03 21:51 ` fxcoudert at gcc dot gnu dot org
@ 2009-06-04  8:02 ` gcc at microbizz dot nl
  2010-05-01 22:41 ` howarth at nitro dot med dot uc dot edu
  3 siblings, 0 replies; 11+ messages in thread
From: gcc at microbizz dot nl @ 2009-06-04  8:02 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #21 from gcc at microbizz dot nl  2009-06-04 08:01 -------
No problem that it still fails. It will be fixed after the next big-bang, in
thirty billion years.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-6064@http.gcc.gnu.org/bugzilla/>
  2009-06-03 21:47 ` fxcoudert at gcc dot gnu dot org
@ 2009-06-03 21:51 ` fxcoudert at gcc dot gnu dot org
  2009-06-04  8:02 ` gcc at microbizz dot nl
  2010-05-01 22:41 ` howarth at nitro dot med dot uc dot edu
  3 siblings, 0 replies; 11+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2009-06-03 21:51 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #20 from fxcoudert at gcc dot gnu dot org  2009-06-03 21:50 -------
*** Bug 22119 has been marked as a duplicate of this bug. ***


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug target/10901] non-local goto's don't work on darwin
       [not found] <bug-10901-6064@http.gcc.gnu.org/bugzilla/>
@ 2009-06-03 21:47 ` fxcoudert at gcc dot gnu dot org
  2009-06-03 21:51 ` fxcoudert at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 11+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2009-06-03 21:47 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #19 from fxcoudert at gcc dot gnu dot org  2009-06-03 21:47 -------
Still fails on both ppc-darwin and i386-darwin, for 4.3.2, 4.4.0 and current
trunk:

$ cat a.c
extern int puts (const char *);
extern void abort (void);

int main ()
{
  __label__ l1;

  void foo ()
  {
    void bar ()
    {
      puts ("goto l1");
      goto l1;
    }

    bar ();
  }

  foo ();
  abort ();
l1:
  puts ("label l1");
  return 0;
}

$ gcc -O3 a.c && ./a.out 
goto l1
label l1

$ gcc -O0 a.c && ./a.out
goto l1


(It also fails with Apple's gcc.)


-- 

fxcoudert at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 GCC target triplet|powerpc-darwin              |darwin
      Known to fail|                            |4.2.0 4.3.2 4.4.0 4.5.0
   Last reconfirmed|2005-12-10 05:32:24         |2009-06-03 21:47:19
               date|                            |
            Summary|non-local goto's don't work |non-local goto's don't work
                   |on powerpc-darwin           |on darwin


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=10901


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2013-09-29 23:52 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-10901-4@http.gcc.gnu.org/bugzilla/>
2012-01-18 15:42 ` [Bug target/10901] non-local goto's don't work on darwin iains at gcc dot gnu.org
2012-01-18 18:30 ` mrs at gcc dot gnu.org
2012-01-18 19:20 ` iains at gcc dot gnu.org
2012-01-20 16:30 ` dominiq at lps dot ens.fr
2013-09-28 10:52 ` iains at gcc dot gnu.org
2013-09-29 20:14 ` iains at gcc dot gnu.org
2013-09-29 23:52 ` mrs at gcc dot gnu.org
     [not found] <bug-10901-6064@http.gcc.gnu.org/bugzilla/>
2009-06-03 21:47 ` fxcoudert at gcc dot gnu dot org
2009-06-03 21:51 ` fxcoudert at gcc dot gnu dot org
2009-06-04  8:02 ` gcc at microbizz dot nl
2010-05-01 22:41 ` howarth at nitro dot med dot uc dot edu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).