Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#59295 closed defect (fixed)

pari does not work in catalina

Reported by: kontogar Owned by: wbl (Watson Ladd)
Priority: Normal Milestone:
Component: ports Version: 2.6.1
Keywords: catalina Cc:
Port: pari

Description (last modified by jmroot (Joshua Root))

Pari gp compiled without any problems.

However, even at the simplest calculation, it breaks with a segmentation fault:

 GP/PARI CALCULATOR Version 2.11.2 (released)
          i386 running darwin (x86-64/GMP-6.1.2 kernel) 64-bit version
     compiled: Oct 13 2019, Apple clang version 11.0.0 (clang-1100.0.33.8)
                            threading engine: single
                 (readline v8.0 enabled, extended help enabled)

                     Copyright (C) 2000-2018 The PARI Group

PARI/GP is free software, covered by the GNU General Public License, and comes
WITHOUT ANY WARRANTY WHATSOEVER.

Type ? for help, \q to quit.
Type ?17 for how to get moral (and possibly technical) support.

parisize = 8000000, primelimit = 500000
? 1+1
  ***   bug in PARI/GP (Segmentation Fault), please report.
  ***   Break loop: type 'break' to go back to GP prompt
break>

Change History (6)

comment:1 Changed 5 years ago by kencu (Ken)

first thought again is -f-no-stack-check

shame we can't hotfix this in base somehow rather than add the same fix to dozens of ports.

comment:2 Changed 5 years ago by jmroot (Joshua Root)

Description: modified (diff)
Keywords: pari gp segmentation fault removed
Owner: set to wbl
Port: pari added
Status: newassigned

comment:3 in reply to:  1 Changed 5 years ago by ryandesign (Ryan Carsten Schmidt)

Keywords: catalina added

comment:4 Changed 5 years ago by wbl (Watson Ladd)

I've let the upstream project know about this bug. What exactly is the stack check breaking and why?

comment:5 Changed 5 years ago by Chris Jones <jonesc@…>

Resolution: fixed
Status: assignedclosed

In ca7443e31929add47796829cac677a6fdc390f87/macports-ports (master):

pari: Blacklist Xcode 11 clang due to 'stack check' issues
Closes: #59295

comment:6 in reply to:  4 Changed 5 years ago by jmroot (Joshua Root)

Replying to wbl:

What exactly is the stack check breaking and why?

I haven't seen a definitive analysis from anyone, but it seems to be a compiler bug and there has been speculation it's related to incorrectly requiring a certain stack alignment. What's known is that older versions of Apple clang don't turn on -fstack-check by default, and the current version only turns it on when using a deployment target of 10.15, and using -fno-stack-check seems to work around the crash (though the jury's out on whether there is still incorrect behaviour otherwise).

Note: See TracTickets for help on using tickets.