simfactory doesn't support multi-core setup using setup-silent

Issue #1348 closed
Frank Löffler created an issue

It is easy to see why a complete multi-core setup using setup-silent isn't the best way to go. Editing the resulting file is usually so much more convenient.

However, the attached patch adds the possibility to have the options --ppn and --num-threads being taken into account for setup-silent.

--ppn sets 'ppn', 'max-num-threads' to it's value, and 'make' to 'nice make -j'+value.

--num-threads sets 'num-threads'.

Keyword:

Comments (7)

  1. Roland Haas
    • removed comment

    Fine with the 'ppn', 'max-num-threads' changes and 'num-threads'. I disagree with changing the "make" field however since the patch hard codes the assumption that the make call is "nice make -j %d" which is not necessarily true: the make invocation could set environment variables (eg INTEL_LICENSE), load extra modules, call envsetup or use a make in different location (eg. version 3.82 which finally reports just which dependency is missing when aborting with error 2). Also there is no need for a head node to have the same number of cores as a compute node so tying the number of make processes to the number of compute node cores seems to be unnecessary.

  2. Frank Löffler reporter
    • removed comment

    I agree that 'make' might not be the correct way to call 'make', but then not setting it (which is what happens without the patch) also just uses 'make', which isn't worse than 'make -j NUMBER'. If 'nice' is what is of concern, we could remove that, although I didn't come across a system which doesn't provide this. This is not about providing the perfect value for 'make'. There is usually not a good way to find that perfect value on a cluster automatically. The attempt here is to find something better than just 'make', for most but not all systems.

    Concerning the number of cores I agree, however usually the number of cores on a headnode is closer to the number on the compute nodes than to 1 - which otherwise would be the default. Again, this isn't about finding the perfect value, but a better one than the current one.

    Also, setup-silent isn't really meant to provide a good solution for new clusters. Work by hand is usually needed there anyway. I would expect that setup-silent is usually called for single development machines, where 'make' is usually available (and called 'make'), as well as the number of cores is the one you also use to build.

  3. Roland Haas
    • removed comment

    I agree (and retract my objection) to the form of the make call "nice make" should always be fine. I'd still a bit unhappy about using ppn" for the "-j" option in make though. Personally I still rather let the user pass "-j<something>" in as part of a "--make" option to setup. However this seems to lead to a proliferation of options. So in the end: Please apply.

    Another question: currently macro_CREATE_MACHINE bases the created machine file on generic.ini which (in my checkout at least) sets ppn=max-num-threads=1 which seems to defeat the purpose of using more than one core. Is this correct?

  4. Frank Löffler reporter
    • changed status to resolved
    • removed comment

    Applied as r2122.

    As to max-num-threads: Is there the option of not setting it at all? But maybe this should be discussed in another place.

  5. Log in to comment