【问题标题】:Using Cilk Plus with MinGW-w64 (gcc 4.9.2)?将 Cilk Plus 与 MinGW-w64 (gcc 4.9.2) 一起使用?
【发布时间】:2015-03-10 20:13:54
【问题描述】:

是否可以将 Cilk PlusMinGW-w64 (x86_64-4.9.2-posix-sjlj-rt_v3-rev0) 一起使用?

当我不使用-fcilkplus 选项时,编译器会给我一个错误"-fcilkplus must be enabled to use '_Cilk_spawn'" - 所以很明显它可以识别扩展关键字。另一方面,在编译器安装文件夹中没有任何'cilk.h' 的痕迹,也没有任何其他名称中包含"cilk" 的文件。

如果使用选项-fcilkplus -lcilkrts 编译,我会收到错误:

"libcilkrts.spec: No such file or directory".

编译自 Code::Blocks,错误日志:

undefined reference to `__cilkrts_enter_frame_1'|
undefined reference to `__cilkrts_save_fp_ctrl_state'|
undefined reference to `__cilkrts_save_fp_ctrl_state'|
undefined reference to `__cilkrts_sync'|
undefined reference to `__cilkrts_rethrow'|
undefined reference to `__cilkrts_save_fp_ctrl_state'|
undefined reference to `__cilkrts_sync'|
undefined reference to `__cilkrts_rethrow'|
undefined reference to `__cilkrts_leave_frame'|
undefined reference to `__cilkrts_save_fp_ctrl_state'|
undefined reference to `__cilkrts_sync'|
undefined reference to `__cilkrts_rethrow'|
undefined reference to `__cilkrts_leave_frame'|
undefined reference to `__cilkrts_enter_frame_fast_1'|
undefined reference to `__cilkrts_leave_frame'|
||=== Build failed: 15 error(s), 2 warning(s) (0 minute(s), 1 second(s)) ===|

MinGW 和 TDM-MinGW 都使用较旧的 gcc 版本(4.8 系列),因此它们无法识别 cilk 关键字。

【问题讨论】:

    标签: c++ mingw mingw-w64 cilk-plus


    【解决方案1】:

    Windows 上的 MinGW 似乎不支持 Intel Cilk。

    【讨论】:

      猜你喜欢
      • 2015-09-30
      • 1970-01-01
      • 2011-01-23
      • 1970-01-01
      • 2015-10-26
      • 1970-01-01
      • 1970-01-01
      • 2015-09-17
      • 1970-01-01
      相关资源
      最近更新 更多