[Users] Possible performance issue

Haas, Roland rhaas at illinois.edu
Wed Oct 9 07:49:05 CDT 2019


Hello Vaishak,

> 1. In the link (
> https://docs.einsteintoolkit.org/et-docs/Configuring_a_new_machine), I see
> that not only optimization flags but also CFLAGS, CXXFLAGS, FPPFLAGS are
> set to ( -g3 -march=native ...) . Would it help to change these too?
-g3 gives you extra debugging information. Usually just -g is enough.
-march=native is important to set (if possible given your cluster
setup), since otherwise the compiler will compile for the simplest
x86_64 processor available (something like a core 2 from 2005) which
gives sub-optimal performance.

> 2. Also,  in CFLAGS and CXXFLAGS, "-std=gnu99" and "-std=gnu++0x " are used
> ( -std=gnu++11 in mine). Other alternatives I am aware of are "c99" and
> "c++11" . What are  good safe choices for these keeping in mind that I am
> using intel libraries??
Please use the gnu variants even with the Intel compilers. The compiler
accepts them and then sets preprocessor defines (_GNU_SOURCE in
particular) that make some functionality available that is often used
by Einstein Toolkit codes (such as M_PI for the value of pi=3.14152...).

I have updated the wiki to request gnu++11 since Cacus now requires
(at least part of) C++11.

Setting only c++11 and c99 can lead to strange errors at compile time
and (occasionally) hard to debug errors when eg the strdup function
(not in c09) is used without a proper prototype.

> 3. I am leaving CPP_OPTIMIZE_FLAGS blank. On the link (configurina a new
> machine), they use "-DKRANC_VECTORS". Should I consider this?
I have to admit I am not sure what that option would do. My suspicion
is that it is no longer needed as vectorization use by Kranc is
determined at the time the code is generated, not when it is compiled.
I also cannot find the string KRANC_VECTORS anywhere in the Kranc
generated code or in Kranc itself.

Yours,
Roland

-- 
My email is as private as my paper mail. I therefore support encrypting
and signing email messages. Get my PGP key from http://pgp.mit.edu .
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
Url : http://lists.einsteintoolkit.org/pipermail/users/attachments/20191009/d40d8f3a/attachment.bin 


More information about the Users mailing list