[mvapich-discuss] How do I patch mvapich2-2.2 to set MV2_ENABLE_AFFINITY default 0
Maksym Planeta
mplaneta at os.inf.tu-dresden.de
Fri Sep 30 14:10:45 EDT 2016
Yes, I see that. But my guess for name "external_visible" would be that
the variable should not be changed by user, instead it is used by a
process launcher. And "default on/off" I interpret differently.
So, I do not understand the meaning of the field. It is never used, even
inside printing routine (mv2_show_all_params). And also there is a typo.
The field is called "extrenal_visible", not external.
On 09/30/2016 08:02 PM, Hari Subramoni wrote:
> Neither is wrong. That structure is just for displaying the list of
> env vars. It does not modify the value of the variable.
>
> Thx,
> Hari.
>
> On Fri, Sep 30, 2016 at 1:56 PM, Maksym Planeta
> <mplaneta at os.inf.tu-dresden.de <mailto:mplaneta at os.inf.tu-dresden.de>>
> wrote:
>
> Limin tried to change value 1 to 0 in param_list structure. The comment
> on the top in ibv_env_params.c says that the field with 0 means "default
> on/off", which I would interpret as default value. But field name in
> ibv_param.h is "external_visible". I think either is wrong.
>
> On 09/30/2016 07:48 PM, Hari Subramoni wrote:
>
> Hi Limin,
>
> I agree with Maksym's observations.
>
> That patch will not work. I'd recommend the following.
>
> diff --git a/src/mpid/ch3/channels/common/src/affinity/hwloc_bind.c
> b/src/mpid/ch3/channels/common/src/affinity/hwl index
> cdcec6f..80698c8 100644 ---
> a/src/mpid/ch3/channels/common/src/affinity/hwloc_bind.c +++
> b/src/mpid/ch3/channels/common/src/affinity/hwloc_bind.c @@ -51,7
> +51,7 @@ int *local_core_ids = NULL; int mv2_user_defined_mapping =
> FALSE;
>
>
> -unsigned int mv2_enable_affinity = 1; +unsigned int
> mv2_enable_affinity = 0; unsigned int mv2_enable_leastload = 0;
> unsigned int mv2_hca_aware_process_mapping = 1;
>
> Thx, Hari.
>
> On Fri, Sep 30, 2016 at 1:36 PM, Limin Gu
> <lgu at penguincomputing.com <mailto:lgu at penguincomputing.com>
> <mailto:lgu at penguincomputing.com
> <mailto:lgu at penguincomputing.com>>> wrote:
>
> Thank Maksym!
>
> I am building mvapich2 for customers, and would like to have default
> to 0 instead of asking everybody to change their .bashrc.
>
> But will the patch work?
>
> Limin
>
> On Fri, Sep 30, 2016 at 1:26 PM, Maksym Planeta
> <mplaneta at os.inf.tu-dresden.de
> <mailto:mplaneta at os.inf.tu-dresden.de>
> <mailto:mplaneta at os.inf.tu-dresden.de
> <mailto:mplaneta at os.inf.tu-dresden.de>>> wrote:
>
> Hi,
>
> you can put this variable in a script you use to submit your jobs.
> Or put it in .bashrc. Patching a library for that looks like a huge
> overkill.
>
>
> On 09/30/2016 07:21 PM, Limin Gu wrote:
>
> Hello all,
>
> I would like to set MV2_ENABLE_AFFINITY default to 0, what's the
> best
> way to do it?
>
> I do not want to configure with --disable-hwloc, or have user
> have to
> specify MV2_ENABLE_AFFINITY=0 on command line.
>
> Will following patch effectively change the default to 0?
>
> diff -Nur src.orig/mpid/ch3/channels/mrail/src/gen2/ibv_env_params.c
> src/mpid/ch3/channels/mrail/src/gen2/ibv_env_params.c
>
> ---
> src.orig/mpid/ch3/channels/mrail/src/gen2/ibv_env_params.c2016-09-30
> 10:11:30.288322611 -0700
>
> +++ src/mpid/ch3/channels/mrail/src/gen2/ibv_env_params.c2016-09-30
> 10:11:44.909321846 -0700
>
> @@ -1473,7 +1473,7 @@
>
> MV2_PARAM_GROUP_intranode,
>
> "MV2_ENABLE_AFFINITY",
>
> &mv2_enable_affinity,
>
> - 1,
>
> + 0,
>
> NULL },
>
> {
>
> MV2_HCA_AWARE_PROCESS_MAPPING,
>
>
>
>
>
> Thank you!
>
>
>
>
>
> _______________________________________________ mvapich-discuss
> mailing list mvapich-discuss at cse.ohio-state.edu
> <mailto:mvapich-discuss at cse.ohio-state.edu>
> <mailto:mvapich-discuss at cse.ohio-state.edu
> <mailto:mvapich-discuss at cse.ohio-state.edu>>
> http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss>
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss>>
>
>
> -- Regards, Maksym Planeta
>
>
> _______________________________________________ mvapich-discuss
> mailing list mvapich-discuss at cse.ohio-state.edu
> <mailto:mvapich-discuss at cse.ohio-state.edu>
> <mailto:mvapich-discuss at cse.ohio-state.edu
> <mailto:mvapich-discuss at cse.ohio-state.edu>>
> http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss>
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss>>
>
>
>
> _______________________________________________ mvapich-discuss
> mailing list mvapich-discuss at cse.ohio-state.edu
> <mailto:mvapich-discuss at cse.ohio-state.edu>
> <mailto:mvapich-discuss at cse.ohio-state.edu
> <mailto:mvapich-discuss at cse.ohio-state.edu>>
> http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss>
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss
> <http://mailman.cse.ohio-state.edu/mailman/listinfo/mvapich-discuss>>
>
>
>
> --
> Regards,
> Maksym Planeta
>
>
--
Regards,
Maksym Planeta
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5174 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://mailman.cse.ohio-state.edu/pipermail/mvapich-discuss/attachments/20160930/89680efb/attachment-0001.p7s>
More information about the mvapich-discuss
mailing list