I think I get it all now.....

https://github.com/python-
greenlet/greenlet/commit/9c8a65fddcffe161f38679a0b3289de9b25e2bc6.patch
-> unbreaks with new gcc-7, but broken again with old gcc-5 again

And hence you are stuck between a rock and a hard-place.... either hack-
up a Frankenstein toolchain or somehow revert future-proof correct
upstream code, for sake of older buggy gcc.

I wonder if greenlet could somehow detect buggy compiler and still build
with it... 😂

** Also affects: python-greenlet (Ubuntu Xenial)
   Importance: Undecided
       Status: New

** Also affects: gcc-5 (Ubuntu Xenial)
   Importance: Undecided
       Status: New

** Changed in: gcc-5 (Ubuntu Xenial)
       Status: New => Triaged

** Changed in: gcc-5 (Ubuntu Xenial)
   Importance: Undecided => High

** Changed in: gcc-5 (Ubuntu Xenial)
   Importance: High => Wishlist

** Changed in: gcc-5 (Ubuntu)
       Status: Incomplete => Won't Fix

** No longer affects: python-greenlet (Ubuntu Xenial)

** Description changed:

+ [Impact]
+ 
+  * GCC has a minor bug w.r.t. clobber r30 register in PIC binaries.
+  * A patch to fix this has been upstream in 6+
+  * But it is not in gcc-5.4 as used on xenial
+  * This prevents compiling future-proof and correct greenlet code, on Ubuntu 
16.04 LTS as used by current and supported Openstack Queens release on ppc64el
+  * Whilst backported greenlet is available via the cloud archive for binary 
usage, the toolchain is still technically incorrect, and thus hinders using 
Ubuntu 16.04 LTS as workers in upstream Openstack CI
+  * As a wishlist it would be nice to backport this one small gcc patch as an 
SRU
+ 
+ [Test Case]
+ 
+  * git clone https://github.com/python-greenlet/greenlet
+  * cd greenlet
+  * ./setup.py build
+ Expect success
+ 
+ Current result failure:
+ 
+ creating build/temp.linux-ppc64le-2.7
+ powerpc64le-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g 
-fstack-protector-strong -Wformat -Werror=format-security -fPIC 
-I/usr/include/python2.7 -c greenlet.c -o 
build/temp.linux-ppc64le-2.7/greenlet.o -fno-tree-dominator-opts
+ In file included from slp_platformselect.h:16:0,
+                  from greenlet.c:343:
+ platform/switch_ppc64_linux.h: In function 'slp_switch':
+ platform/switch_ppc64_linux.h:80:5: error: PIC register clobbered by 'r30' in 
'asm'
+      __asm__ volatile ("" : : : REGS_TO_SAVE);
+      ^
+ platform/switch_ppc64_linux.h:95:5: error: PIC register clobbered by 'r30' in 
'asm'
+      __asm__ volatile ("" : : : REGS_TO_SAVE);
+      ^
+ error: command 'powerpc64le-linux-gnu-gcc' failed with exit status 1
+ 
+ 
+ [Regression Potential] 
+ 
+  * Upstream cherrypick present in later releases including bionic
+ 
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=9213244550335bcb2b8590a0d7d58ac74c932361
+ 
+ 
+ [Other Info]
+  
+  * Original bug report
+ 
+ 
  == Comment: #0 - William M. Edmonds <edmon...@us.ibm.com> - 2018-07-23 
16:21:41 ==
  ---Problem Description---
  greenlet 0.4.14 will not build on ppc64le
  
  Opened https://github.com/python-greenlet/greenlet/issues/136 because
  attempting to build bdist_wheel for greenlet 0.4.14 on ppc64le Ubuntu
  16.04 LTS yields the following error:
  
  running build
  running build_ext
  building 'greenlet' extension
  creating build
  creating build/temp.linux-ppc64le-2.7
  powerpc64le-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g 
-fstack-protector-strong -Wformat -Werror=format-security -fPIC 
-I/usr/include/python2.7 -c greenlet.c -o 
build/temp.linux-ppc64le-2.7/greenlet.o -fno-tree-dominator-opts
  In file included from slp_platformselect.h:16:0,
-                     from greenlet.c:343:
-    platform/switch_ppc64_linux.h: In function 'slp_switch':
-    platform/switch_ppc64_linux.h:80:5: error: PIC register clobbered by 'r30' 
in 'asm'
-         __asm__ volatile ("" : : : REGS_TO_SAVE);
-         ^
-    platform/switch_ppc64_linux.h:95:5: error: PIC register clobbered by 'r30' 
in 'asm'
-         __asm__ volatile ("" : : : REGS_TO_SAVE);
-         ^
-    error: command 'powerpc64le-linux-gnu-gcc' failed with exit status 1```
+                     from greenlet.c:343:
+    platform/switch_ppc64_linux.h: In function 'slp_switch':
+    platform/switch_ppc64_linux.h:80:5: error: PIC register clobbered by 'r30' 
in 'asm'
+         __asm__ volatile ("" : : : REGS_TO_SAVE);
+         ^
+    platform/switch_ppc64_linux.h:95:5: error: PIC register clobbered by 'r30' 
in 'asm'
+         __asm__ volatile ("" : : : REGS_TO_SAVE);
+         ^
+    error: command 'powerpc64le-linux-gnu-gcc' failed with exit status 1```
  
- But the greenlet community is saying this is a gcc bug and it would not be 
safe to revert the greenlet change that exposed this issue. I have no idea 
whether that is true or not. Supposedly this should be fixed by 
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=9213244550335bcb2b8590a0d7d58ac74c932361
 but that fix is not present in the latest version of gcc (5.4.0) available for 
Ubuntu 16.04 LTS.
-  
+ But the greenlet community is saying this is a gcc bug and it would not
+ be safe to revert the greenlet change that exposed this issue. I have no
+ idea whether that is true or not. Supposedly this should be fixed by
+ 
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=9213244550335bcb2b8590a0d7d58ac74c932361
+ but that fix is not present in the latest version of gcc (5.4.0)
+ available for Ubuntu 16.04 LTS.
+ 
  ---uname output---
  unavailable due to lab outage
-  
- Machine Type = unavailable due to lab outage 
-  
+ 
+ Machine Type = unavailable due to lab outage
+ 
  ---Debugger---
  A debugger is not configured
-  
+ 
  ---Steps to Reproduce---
  This should be reproducible with `git clone 
git://github.com/python-greenlet/greenlet; cd greenlet; python setup.py 
bdist_wheel`, though it was originally found using pypi rather than github and 
with a more complicated (scripted) command as detailed in the greenlet bug 
description.
-  
- Contact Information = Matthew Edmonds / edmon...@us.ibm.com 
-  
- Userspace tool common name: greenlet 
-  
- The userspace tool has the following bit modes: no idea 
+ 
+ Contact Information = Matthew Edmonds / edmon...@us.ibm.com
+ 
+ Userspace tool common name: greenlet
+ 
+ The userspace tool has the following bit modes: no idea
  
  Userspace rpm: N/A
  
- Userspace tool obtained from project website:  0.4.14 
-  
+ Userspace tool obtained from project website:  0.4.14
+ 
  *Additional Instructions for Matthew Edmonds / edmon...@us.ibm.com:
  -Attach ltrace and strace of userspace application.

** Summary changed:

- greenlet 0.4.14 will not build on ppc64le
+ gcc on ppc64le has bogus r30 register handling, as exposed by greenlet 0.4.14 
will not build on ppc64le

** Changed in: gcc-5 (Ubuntu)
       Status: Won't Fix => Fix Released

** Changed in: gcc-5 (Ubuntu)
       Status: Fix Released => Won't Fix

-- 
You received this bug notification because you are a member of नेपाली
भाषा समायोजकहरुको समूह, which is subscribed to Xenial.
Matching subscriptions: Ubuntu 16.04 Bugs
https://bugs.launchpad.net/bugs/1783252

Title:
  gcc on ppc64le has bogus r30 register handling, as exposed by greenlet
  0.4.14 will not build on ppc64le

Status in The Ubuntu-power-systems project:
  Won't Fix
Status in gcc-5 package in Ubuntu:
  Won't Fix
Status in python-greenlet package in Ubuntu:
  Fix Released
Status in gcc-5 source package in Xenial:
  Triaged

Bug description:
  [Impact]

   * GCC has a minor bug w.r.t. clobber r30 register in PIC binaries.
   * A patch to fix this has been upstream in 6+
   * But it is not in gcc-5.4 as used on xenial
   * This prevents compiling future-proof and correct greenlet code, on Ubuntu 
16.04 LTS as used by current and supported Openstack Queens release on ppc64el
   * Whilst backported greenlet is available via the cloud archive for binary 
usage, the toolchain is still technically incorrect, and thus hinders using 
Ubuntu 16.04 LTS as workers in upstream Openstack CI
   * As a wishlist it would be nice to backport this one small gcc patch as an 
SRU

  [Test Case]

   * git clone https://github.com/python-greenlet/greenlet
   * cd greenlet
   * ./setup.py build
  Expect success

  Current result failure:

  creating build/temp.linux-ppc64le-2.7
  powerpc64le-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g 
-fstack-protector-strong -Wformat -Werror=format-security -fPIC 
-I/usr/include/python2.7 -c greenlet.c -o 
build/temp.linux-ppc64le-2.7/greenlet.o -fno-tree-dominator-opts
  In file included from slp_platformselect.h:16:0,
                   from greenlet.c:343:
  platform/switch_ppc64_linux.h: In function 'slp_switch':
  platform/switch_ppc64_linux.h:80:5: error: PIC register clobbered by 'r30' in 
'asm'
       __asm__ volatile ("" : : : REGS_TO_SAVE);
       ^
  platform/switch_ppc64_linux.h:95:5: error: PIC register clobbered by 'r30' in 
'asm'
       __asm__ volatile ("" : : : REGS_TO_SAVE);
       ^
  error: command 'powerpc64le-linux-gnu-gcc' failed with exit status 1

  
  [Regression Potential] 

   * Upstream cherrypick present in later releases including bionic
  
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=9213244550335bcb2b8590a0d7d58ac74c932361

  
  [Other Info]
   
   * Original bug report

  
  == Comment: #0 - William M. Edmonds <edmon...@us.ibm.com> - 2018-07-23 
16:21:41 ==
  ---Problem Description---
  greenlet 0.4.14 will not build on ppc64le

  Opened https://github.com/python-greenlet/greenlet/issues/136 because
  attempting to build bdist_wheel for greenlet 0.4.14 on ppc64le Ubuntu
  16.04 LTS yields the following error:

  running build
  running build_ext
  building 'greenlet' extension
  creating build
  creating build/temp.linux-ppc64le-2.7
  powerpc64le-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g 
-fstack-protector-strong -Wformat -Werror=format-security -fPIC 
-I/usr/include/python2.7 -c greenlet.c -o 
build/temp.linux-ppc64le-2.7/greenlet.o -fno-tree-dominator-opts
  In file included from slp_platformselect.h:16:0,
                      from greenlet.c:343:
     platform/switch_ppc64_linux.h: In function 'slp_switch':
     platform/switch_ppc64_linux.h:80:5: error: PIC register clobbered by 'r30' 
in 'asm'
          __asm__ volatile ("" : : : REGS_TO_SAVE);
          ^
     platform/switch_ppc64_linux.h:95:5: error: PIC register clobbered by 'r30' 
in 'asm'
          __asm__ volatile ("" : : : REGS_TO_SAVE);
          ^
     error: command 'powerpc64le-linux-gnu-gcc' failed with exit status 1```

  But the greenlet community is saying this is a gcc bug and it would
  not be safe to revert the greenlet change that exposed this issue. I
  have no idea whether that is true or not. Supposedly this should be
  fixed by
  
https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=9213244550335bcb2b8590a0d7d58ac74c932361
  but that fix is not present in the latest version of gcc (5.4.0)
  available for Ubuntu 16.04 LTS.

  ---uname output---
  unavailable due to lab outage

  Machine Type = unavailable due to lab outage

  ---Debugger---
  A debugger is not configured

  ---Steps to Reproduce---
  This should be reproducible with `git clone 
git://github.com/python-greenlet/greenlet; cd greenlet; python setup.py 
bdist_wheel`, though it was originally found using pypi rather than github and 
with a more complicated (scripted) command as detailed in the greenlet bug 
description.

  Contact Information = Matthew Edmonds / edmon...@us.ibm.com

  Userspace tool common name: greenlet

  The userspace tool has the following bit modes: no idea

  Userspace rpm: N/A

  Userspace tool obtained from project website:  0.4.14

  *Additional Instructions for Matthew Edmonds / edmon...@us.ibm.com:
  -Attach ltrace and strace of userspace application.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-power-systems/+bug/1783252/+subscriptions

_______________________________________________
Mailing list: https://launchpad.net/~group.of.nepali.translators
Post to     : group.of.nepali.translators@lists.launchpad.net
Unsubscribe : https://launchpad.net/~group.of.nepali.translators
More help   : https://help.launchpad.net/ListHelp

Reply via email to