windows 哪些 IDE 对使用 CUDA 编程有很好的支持?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/8642017/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Which IDEs have good support for programming with CUDA?
提问by Chan Le
I'm starting to do programming with CUDA C. Are there any IDE that are especially good for programming with it?
我开始用 CUDA C 编程。有没有特别适合用它编程的 IDE?
I'm using a windows machine and a personal macbook :D (But I want to know what people use in linux and mac also)
我正在使用 Windows 机器和个人 macbook :D(但我想知道人们在 linux 和 mac 中也使用什么)
采纳答案by codemaster
I've used CUDA 2.1, and VS2008, and haven't had any problems. Just make sure after you install the toolkit and the SDK, that you do the following:
我使用过 CUDA 2.1 和 VS2008,没有任何问题。只需确保在安装工具包和 SDK 后执行以下操作:
- Open "My Computer" (or explorer, or whatever) and navigate to C:\ProgramData\NVIDIA Corporation\NVIDIA CUDA SDK\common
- Double-click on cutil_vc90.sln (assuming you're using CUDA 2.1 and VS2008); when the solution loads up, you will see a drop-down menu for the build configuration. If you are on a 64-bit platform, you need to change this from Win32 to x64.
- Build the solution.
- Look up top again -- you should see the build configuration menu that says "Debug". Change it to "Release" and build the solution again.
- Close Visual Studio.
- Back in the explorer window, find the file "paramgl_vc90.sln". Double-click it to open that solution.
- Repeat the same configuration setup and build process as described above, then close Visual Studio.
- 打开“我的电脑”(或资源管理器,或其他)并导航到 C:\ProgramData\NVIDIA Corporation\NVIDIA CUDA SDK\common
- 双击 cutil_vc90.sln(假设您使用的是 CUDA 2.1 和 VS2008);当解决方案加载时,您将看到构建配置的下拉菜单。如果您使用的是 64 位平台,则需要将其从 Win32 更改为 x64。
- 构建解决方案。
- 再次查找顶部——您应该会看到显示“调试”的构建配置菜单。将其更改为“发布”并再次构建解决方案。
- 关闭 Visual Studio。
- 返回资源管理器窗口,找到文件“paramgl_vc90.sln”。双击它以打开该解决方案。
- 重复上述相同的配置设置和构建过程,然后关闭 Visual Studio。
At this point, you should be able to compile the SDK projects; if you are using VS2008, make sure you open the solutions ending in _vc90.sln. Again, if you're on x64, you need to also make sure to set the build platform to "x64" in that drop-down menu.
至此,您应该可以编译SDK项目了;如果您使用的是 VS2008,请确保打开以 _vc90.sln 结尾的解决方案。同样,如果您使用的是 x64,您还需要确保在该下拉菜单中将构建平台设置为“x64”。
If you get this far, and you're ready to write your own projects, check out the "template" project that comes with the SDK. You should be able to make a copy of that and use it for your own stuff, with the compiler settings (for CUDA, that is) already set up.
如果您到此为止,并且已准备好编写自己的项目,请查看 SDK 附带的“模板”项目。您应该能够制作一个副本并将其用于您自己的东西,并且已经设置了编译器设置(用于 CUDA)。
there is a thread on nvidia for this as well http://forums.nvidia.com/index.php?showtopic=91057
在 nvidia 上也有一个线程http://forums.nvidia.com/index.php?showtopic=91057
回答by eLRuLL
Definitely the better way to code CUDA in Windows right now is Nsight Visual Studio Edition environment. With the release of CUDA 5, comes also the Nvidia Nsight Eclipse Edition, with the same programming capabilities but with the IDE of Eclipse. Nsight Eclipse Edition is available on Linux and MacOS (but not Windows). You can try it already with the CUDA 5 release candidate: http://developer.nvidia.com/cuda/cuda-toolkit
现在在 Windows 中编写 CUDA 的更好方法绝对是 Nsight Visual Studio Edition 环境。随着 CUDA 5 的发布,还有 Nvidia Nsight Eclipse 版,具有相同的编程功能,但带有 Eclipse 的 IDE。Nsight Eclipse 版可在 Linux 和 MacOS(但不是 Windows)上使用。您可以尝试使用CUDA 5 候选版本:http: //developer.nvidia.com/cuda/cuda-toolkit
回答by Agnius Vasiliauskas
In windows you can use NVIDIA Parallel NsightVisual Studio solution. I think there is no better alternative for GPU development on windows. And Linux + GPU development == SUX
.
There are some attempts to make some Linux distrowhich would be GPU-development friendly, but given that these are first steps to this goal - I don't expect too much from this product. (Also they have broken links)
在 Windows 中,您可以使用NVIDIA Parallel NsightVisual Studio 解决方案。我认为在 Windows 上进行 GPU 开发没有更好的选择。并且Linux + GPU development == SUX
。有一些尝试制作一些对 GPU 开发友好的Linux 发行版,但鉴于这些是实现这一目标的第一步 - 我对该产品的期望不高。(他们也断开了链接)
回答by Yappie
Under my Win7 I use MSVS 10 with NVidia debugger and Parallel Nsight integrated. I have cross-platform build with cmake. It's so easy with cmake. Under Linux (I use Fedora 16) I work in QT creator because it integrates well with cmake and debugger (and looks better than other IMXO). Inder Linux you can attach NVidia debugger, too.
在我的 Win7 下,我使用集成了 NVidia 调试器和 Parallel Nsight 的 MSVS 10。我使用 cmake 进行跨平台构建。cmake 就是这么简单。在 Linux(我使用 Fedora 16)下,我在 QT creator 中工作,因为它与 cmake 和调试器很好地集成(并且看起来比其他 IMXO 更好)。在 Linux 下,您也可以附加 NVidia 调试器。