cilkscreen showing races on reducers

cilkscreen showing races on reducers

This seems weird, but cilkscreen reports data race on reducer variable. The code, and corresponding output of cilkscreen is shown below.user@velour:~/tmp/cilk_tests$ cat reducer_test.c#include #include #include #include #include using namespace std;cilk::reducer_opadd total(0);int main() {const int STAT_SIZE = 2;const int N=10;cilk_for(int i=0 ; i total += 1;}cout << "total =" << total.get_value() << endl;return 0;}user@velour:~/tmp/cilk_tests$ icpc -g reducer_test.cuser@velour:~/tmp/cilk_tests$ icpc -VIntel C++ Intel 64 Compiler XE for applications running on Intel 64, Version 12.0.1.107 Build 20101116Copyright (C) 1985-2010 Intel Corporation. All rights reserved.user@velour:~/tmp/cilk_tests$ cilkscreen ./a.outCilkscreen Race Detector V2.0.0, Build 1113Race condition on location 0x6024c0write access at 0x4014a8: (~/aamirshafi/intel/composerxe-2011.1.107/compiler/include/cilk/reducer_opadd.h:320, cilk::reducer_opadd::operator+=+0x30)read access at 0x4014a2: (~/aamirshafi/intel/composerxe-2011.1.107/compiler/include/cilk/reducer_opadd.h:320, cilk::reducer_opadd::operator+=+0x2a) called by 0x7f7d6110860d: (__$U2+0x9d) called by 0x7f7d611083a0: (cilk_for_recursive+0x100) called by 0x7f7d61108739: (__$U0+0x99) called by 0x7f7d61108089: (__cilkrts_cilk_for_32+0xf9) called by 0x400fa1: (~/aamirshafi/tmp/cilk_tests/reducer_test.c:16, main+0x65)Race condition on location 0x6024c0write access at 0x4014a8: (~/aamirshafi/intel/composerxe-2011.1.107/compiler/include/cilk/reducer_opadd.h:320, cilk::reducer_opadd::operator+=+0x30)write access at 0x4014a8: (~/aamirshafi/intel/composerxe-2011.1.107/compiler/include/cilk/reducer_opadd.h:320, cilk::reducer_opadd::operator+=+0x30) called by 0x7f7d6110860d: (__$U2+0x9d) called by 0x7f7d611083a0: (cilk_for_recursive+0x100) called by 0x7f7d61108739: (__$U0+0x99) called by 0x7f7d61108089: (__cilkrts_cilk_for_32+0xf9) called by 0x400fa1: (~/aamirshafi/tmp/cilk_tests/reducer_test.c:16, main+0x65)total =102 errors found by CilkscreenCilkscreen suppressed 16 duplicate error messagesCant tell the version of the cilkscreen since using -v option gives an error. But the cilkview version info is below:user@velour:~/tmp/cilk_tests$ cilkscreen -vE:Unable to load ~/aamirshafi/work/install/cilkutil/bin/../lib32/cilkscreen-tool.so: libimf.so: wrong ELF class: ELFCLASS64user@velour:~/tmp/cilk_tests$ cilkview -vcilkview v2.0.1049.0Copyright (c) 2010 Intel Corp. All rights reserveduser@velour:~/tmp/cilk_tests$ uname -aLinux velour 2.6.29-tps+perfctr+fpufix #1 SMP Sat Sep 4 22:20:28 EDT 2010 x86_64 GNU/Linux--Aamir

3 posts / 0 nouveau(x)
Dernière contribution
Reportez-vous à notre Notice d'optimisation pour plus d'informations sur les choix et l'optimisation des performances dans les produits logiciels Intel.

Hi Aamir,

I can reproduce the problem with Cilkscreen, and I've submitted a problem report to the Cilk Plus team. I'll update the thread when they have any updates.

Brandon Hewitt
Technical Consulting Engineer

For 1:1 technical support: http://premier.intel.com

Software Product Support info: http://www.intel.com/software/support

If you compile now with the C++ Composer XE 2011 update 8 and get the latest version of the Cilk Plus SDK, this problem should now be resolved.

Brandon Hewitt
Technical Consulting Engineer

For 1:1 technical support: http://premier.intel.com

Software Product Support info: http://www.intel.com/software/support

Laisser un commentaire

Veuillez ouvrir une session pour ajouter un commentaire. Pas encore membre ? Rejoignez-nous dès aujourd’hui