https://bugzilla.novell.com/show_bug.cgi?id=781992 https://bugzilla.novell.com/show_bug.cgi?id=781992#c0 Summary: coreutils-8.9-singlethreaded-sort.patch disables OMP_NUM_THREADS Classification: openSUSE Product: openSUSE 12.2 Version: Final Platform: All OS/Version: openSUSE 12.2 Status: NEW Severity: Normal Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: froh@suse.com QAContact: qa-bugs@suse.de Found By: --- Blocker: --- Created an attachment (id=506930) --> (http://bugzilla.novell.com/attachment.cgi?id=506930) this is the new version of the patch. User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.57 Safari/537.1 Multithreaded sort had bugs around coreutils 8.9. since then, we disable auto-detection of the number of threads to be used by sort(1), so it runs single threaded all time, except the user explicitely requests mutlithreaded sort. GNU sort(1) allows this in two ways: * provide a --parallel=N command line option * set the OMP_NUM_THREADS environment varible, named in the spirit of openmp.org, but not using their library. our patch to default the number of threads to 1 kept the command line switch alife, but it disabled the environment variable. this has created some chagrin on opensuse-factory@. I've modified the patch like this, to re-enable OMP_NUM_THREADS for sort(1) --- src/sort.c.orig +++ src/sort.c @@ -5288,7 +5288,11 @@ main (int argc, char **argv) { if (!nthreads) { - unsigned long int np = num_processors (NPROC_CURRENT_OVERRIDABLE); + unsigned long int np; + if (getenv("OMP_NUM_THREADS")) + np = num_processors (NPROC_CURRENT_OVERRIDABLE); + else + np = 1; nthreads = MIN (np, DEFAULT_MAX_THREADS); } Reproducible: Always -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.