简体   繁体   English

在solaris-sparc平台上将openMp支持添加到现有C项目

[英]on solaris-sparc platform adding openMp support to an existing C project

I need some advise and help for re-compiling of an existing C project (which is a huge project) on a solaris8-sparc platform with "OpenMP". 我需要一些建议和帮助,以在带有“ OpenMP”的solaris8-sparc平台上重新编译现有C项目(这是一个巨大的项目)。 The point is im not familiar neither with compiling nor parallel programing issues. 我不熟悉编译问题或并行编程问题。 With a little google search i see that sun-studio 11 and 12 has openMP infrastructure already. 通过少量的Google搜索,我发现sun-studio 11和12已经具有openMP基础架构。 so how can i start compiling c files with openMP. 所以我该如何开始用openMP编译C文件。

on the other hand 另一方面

Can this be done by downloading a gcc compiler with an openMP support ( in a bundle) and renaming and linking it with the previous cc's location and including openmp headers to project files.. this is what i suppose but sure its not that simple. 是否可以通过下载具有openMP支持的gcc编译器(捆绑提供)并重命名并将其与先前cc的位置链接,并将openmp标头包含到项目文件中来完成此操作。我想这是可确定的,但要确保它不是那么简单。 so what should i do ? 所以我该怎么做 ? can you please kindly offer me a road map about it. 能否请您提供一份有关它的路线图。

Openmp support is compiler dependent. Openmp支持取决于编译器。 So you can't just take omp.h from gcc and use it with sun pro. 因此,您不能只从gcc中获取omp.h并将其与sun pro一起使用。

Use option -xopenmp in sun pro (read more at http://developers.sun.com/solaris/articles/studio_openmp.html ) 在sun pro中使用选项-xopenmp(有关更多信息,请参见http://developers.sun.com/solaris/articles/studio_openmp.html

And you can take Full installation of recent gcc (4.2 and later) and use it for compiling all your programs with openmp pragmas. 您可以完整安装最新的gcc(4.2和更高版本),并使用它来编译带有openmp编译指示的所有程序。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM